.ion-ambient-layer {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  overflow: hidden;
}

.ion-ambient-layer span {
  position: absolute;
  left: calc((var(--i) * 53px) % 100vw);
  top: calc((var(--i) * 97px) % 100vh);
  width: 3px;
  height: 3px;
  border-radius: 999px;
  background: rgba(53,231,255,0.72);
  box-shadow: 0 0 14px rgba(53,231,255,0.62), 0 0 26px rgba(255,79,216,0.18);
  opacity: 0.28;
  animation: ionMoteDrift calc(9s + (var(--i) * 0.37s)) linear infinite;
  animation-delay: calc(var(--i) * -0.42s);
}

.ion-ambient-layer span:nth-child(3n) {
  background: rgba(246,200,95,0.74);
  box-shadow: 0 0 14px rgba(246,200,95,0.48);
}

.ion-ambient-layer span:nth-child(4n) {
  background: rgba(255,79,216,0.64);
  box-shadow: 0 0 14px rgba(255,79,216,0.42);
}

.nav-toggle {
  position: fixed;
  right: max(18px, env(safe-area-inset-right));
  top: max(18px, calc(env(safe-area-inset-top) + 18px));
  z-index: 70;
  width: 68px;
  height: 68px;
  isolation: isolate;
  border: 1px solid rgba(246, 200, 95, 0.48);
  border-radius: 50%;
  background:
    radial-gradient(circle at 32% 22%, rgba(255,255,255,0.38), transparent 25%),
    radial-gradient(circle at 74% 78%, rgba(53,231,255,0.42), transparent 42%),
    conic-gradient(from 210deg, #f6c85f, #35e7ff, #26d3a2, #ff4fd8, #f6c85f);
  color: #f8fbff;
  display: grid;
  place-items: center;
  gap: 0;
  padding: 0;
  cursor: pointer;
  box-shadow:
    0 24px 54px rgba(0,0,0,0.46),
    0 0 34px rgba(53,231,255,0.34),
    inset 0 0 0 7px rgba(4, 9, 18, 0.72),
    inset 0 0 26px rgba(255,255,255,0.16);
  backdrop-filter: blur(16px) saturate(1.2);
  -webkit-backdrop-filter: blur(16px) saturate(1.2);
  transition: transform 180ms ease, box-shadow 180ms ease, filter 180ms ease, border-color 180ms ease;
  animation: navButtonFloat 4.4s ease-in-out infinite;
}

.nav-toggle::before,
.nav-toggle::after {
  content: "";
  position: absolute;
  pointer-events: none;
  border-radius: inherit;
}

.nav-toggle::before {
  inset: -6px;
  z-index: -2;
  background: conic-gradient(from 0deg, rgba(53,231,255,0), rgba(53,231,255,0.58), rgba(255,79,216,0), rgba(246,200,95,0.5), rgba(53,231,255,0));
  opacity: 0.78;
  filter: blur(10px);
  animation: navButtonOrbit 4.8s linear infinite;
}

.nav-toggle::after {
  inset: 9px;
  z-index: -1;
  background:
    linear-gradient(145deg, rgba(8, 14, 26, 0.94), rgba(4, 8, 17, 0.98)),
    rgba(4, 8, 17, 0.96);
  box-shadow: inset 0 0 18px rgba(53,231,255,0.18);
}

.nav-toggle span {
  position: absolute;
  width: 25px;
  height: 2px;
  border-radius: 999px;
  background: currentColor;
  box-shadow: 0 0 10px rgba(53,231,255,0.64);
  transition: transform 240ms cubic-bezier(.2,.86,.2,1), opacity 160ms ease, width 180ms ease;
}

.nav-toggle span:nth-child(1) { transform: translateY(-8px); }
.nav-toggle span:nth-child(2) { transform: translateY(0); }
.nav-toggle span:nth-child(3) { transform: translateY(8px); }

.nav-toggle.open span:nth-child(1) { transform: rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; transform: scaleX(0.2); }
.nav-toggle.open span:nth-child(3) { transform: rotate(-45deg); }

.nav-toggle:hover {
  transform: translateY(-4px) scale(1.045);
  filter: brightness(1.08);
  border-color: rgba(53,231,255,0.72);
  box-shadow:
    0 28px 66px rgba(0,0,0,0.52),
    0 0 52px rgba(53,231,255,0.48),
    inset 0 0 0 7px rgba(4, 9, 18, 0.7),
    inset 0 0 28px rgba(255,255,255,0.19);
}

.nav-toggle:active {
  transform: translateY(-1px) scale(0.98);
}

.nav-toggle.open {
  animation-play-state: paused;
  border-color: rgba(255,79,216,0.58);
}

.quick-jump-rail {
  position: fixed;
  right: max(20px, env(safe-area-inset-right));
  top: max(96px, calc(env(safe-area-inset-top) + 96px));
  z-index: 64;
  display: grid;
  gap: 10px;
  padding: 8px;
  border: 1px solid rgba(62,210,255,0.24);
  border-radius: 18px;
  background: rgba(3, 12, 24, 0.42);
  backdrop-filter: blur(18px) saturate(1.2);
  -webkit-backdrop-filter: blur(18px) saturate(1.2);
  box-shadow: 0 16px 42px rgba(0,0,0,0.28), inset 0 1px 0 rgba(157,239,255,0.12);
}

.quick-jump-button {
  position: relative;
  min-width: 148px;
  min-height: 46px;
  border-radius: 16px;
  display: inline-grid;
  grid-template-columns: 24px minmax(0, 1fr);
  align-items: center;
  gap: 9px;
  padding: 0 13px 0 11px;
  color: #eaffff;
  border: 1px solid rgba(53,231,255,0.42);
  background:
    linear-gradient(90deg, rgba(53,231,255,0.18) 1px, transparent 1px),
    linear-gradient(rgba(53,231,255,0.11) 1px, transparent 1px),
    radial-gradient(circle at 16% 24%, rgba(53,231,255,0.22), transparent 34%),
    linear-gradient(145deg, rgba(8, 18, 36, 0.95), rgba(3, 8, 18, 0.91));
  background-size: 12px 12px, 12px 12px, auto, auto;
  box-shadow:
    0 18px 38px rgba(0,0,0,0.36),
    0 0 26px rgba(53,231,255,0.16),
    inset 0 0 24px rgba(53,231,255,0.12);
  text-decoration: none;
  backdrop-filter: blur(14px) saturate(1.25);
  -webkit-backdrop-filter: blur(14px) saturate(1.25);
  overflow: hidden;
  transition: transform 180ms ease, border-color 180ms ease, box-shadow 180ms ease, color 180ms ease, filter 180ms ease;
}

.quick-jump-button::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(110deg, transparent 10%, rgba(255,255,255,0.18) 42%, transparent 68%);
  transform: translateX(-120%);
  opacity: 0.72;
  pointer-events: none;
}

.quick-jump-button::after {
  content: "";
  position: absolute;
  left: 10px;
  right: 10px;
  bottom: 7px;
  height: 2px;
  border-radius: 999px;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.72), transparent);
  opacity: 0.7;
  pointer-events: none;
}

.quick-jump-button--world {
  border-color: rgba(53,231,255,0.56);
  box-shadow: 0 20px 44px rgba(0,0,0,0.38), 0 0 34px rgba(53,231,255,0.2), inset 0 0 24px rgba(53,231,255,0.14);
}

.quick-jump-button--feed {
  border-color: rgba(246,200,95,0.58);
  box-shadow: 0 20px 44px rgba(0,0,0,0.38), 0 0 34px rgba(246,200,95,0.18), inset 0 0 24px rgba(246,200,95,0.14);
}

.quick-jump-button svg {
  position: relative;
  z-index: 1;
  width: 24px;
  height: 24px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  filter: drop-shadow(0 0 10px rgba(53,231,255,0.62));
}

.quick-jump-button span {
  position: relative;
  z-index: 1;
  font-size: 0.74rem;
  font-weight: 1000;
  line-height: 1;
  text-transform: uppercase;
}

.quick-jump-button:hover,
.quick-jump-button.active {
  transform: translateY(-3px) scale(1.018);
  color: #fff7bc;
  border-color: rgba(246,200,95,0.72);
  filter: brightness(1.06);
  box-shadow:
    0 24px 54px rgba(0,0,0,0.44),
    0 0 36px rgba(246,200,95,0.24),
    inset 0 0 28px rgba(53,231,255,0.16);
}

.quick-jump-button:hover::before,
.quick-jump-button.active::before {
  animation: quickJumpSheen 900ms ease;
}

.ion-news-ticker {
  position: fixed;
  left: 50%;
  bottom: max(9px, env(safe-area-inset-bottom));
  z-index: 63;
  width: min(1120px, calc(100vw - 24px));
  min-height: 38px;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  overflow: hidden;
  border: 1px solid rgba(53,231,255,0.36);
  border-radius: 14px;
  background:
    linear-gradient(90deg, rgba(53,231,255,0.12) 1px, transparent 1px),
    linear-gradient(145deg, rgba(4,11,24,0.92), rgba(2,7,17,0.88));
  background-size: 18px 18px, auto;
  color: #d9fbff;
  box-shadow:
    0 16px 36px rgba(0,0,0,0.34),
    0 0 28px rgba(53,231,255,0.16),
    inset 0 1px 0 rgba(157,239,255,0.12);
  transform: translateX(-50%);
  backdrop-filter: blur(16px) saturate(1.2);
  -webkit-backdrop-filter: blur(16px) saturate(1.2);
}

.ion-news-label {
  position: relative;
  z-index: 1;
  align-self: stretch;
  display: grid;
  place-items: center;
  padding: 0 14px;
  background: linear-gradient(135deg, rgba(246,200,95,0.95), rgba(53,231,255,0.9));
  color: #031014;
  font-size: 0.68rem;
  font-weight: 1000;
  text-transform: uppercase;
  white-space: nowrap;
}

.ion-news-window {
  min-width: 0;
  overflow: hidden;
  mask-image: linear-gradient(90deg, transparent, #000 5%, #000 95%, transparent);
}

.ion-news-track {
  display: inline-flex;
  align-items: center;
  gap: 28px;
  width: max-content;
  min-width: 200%;
  padding: 0 18px;
  animation: ionNewsScroll 62s linear infinite;
}

.ion-news-track span {
  position: relative;
  display: inline-flex;
  align-items: center;
  min-height: 38px;
  color: #eaffff;
  font-size: 0.78rem;
  font-weight: 900;
  white-space: nowrap;
  text-shadow: 0 0 12px rgba(53,231,255,0.32);
}

.ion-news-track span::before {
  content: "";
  width: 7px;
  height: 7px;
  margin-right: 10px;
  border-radius: 50%;
  background: #f6c85f;
  box-shadow: 0 0 12px rgba(246,200,95,0.72);
}

.ion-news-ticker:hover .ion-news-track {
  animation-play-state: paused;
}

.player-hud {
  position: fixed;
  top: max(12px, env(safe-area-inset-top));
  left: 50%;
  transform: translateX(-50%);
  z-index: 62;
  display: grid;
  grid-template-columns: minmax(210px, 1fr) auto auto auto auto;
  align-items: center;
  gap: 9px;
  width: min(980px, calc(100vw - 24px));
  min-height: 64px;
  padding: 8px;
  border: 1px solid rgba(255, 255, 255, 0.76);
  border-radius: 22px;
  background:
    linear-gradient(145deg, rgba(255,255,255,0.5), transparent 34%),
    radial-gradient(circle at 12% 0%, rgba(210, 241, 255, 0.46), transparent 15rem),
    radial-gradient(circle at 92% 28%, rgba(240, 250, 226, 0.42), transparent 14rem),
    linear-gradient(180deg, rgba(247, 252, 255, 0.92), rgba(230, 241, 247, 0.86));
  box-shadow:
    0 22px 62px rgba(51, 73, 94, 0.18),
    0 4px 24px rgba(67, 92, 118, 0.1),
    0 0 36px rgba(53,231,255,0.14),
    0 0 0 1px rgba(246,200,95,0.08),
    inset 0 1px 0 rgba(255,255,255,0.9);
  backdrop-filter: blur(22px) saturate(1.3);
  -webkit-backdrop-filter: blur(22px) saturate(1.3);
  overflow: hidden;
}

.hud-timer[hidden] {
  display: none !important;
}

.player-hud > * {
  min-width: 0;
}

.player-hud::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(115deg, transparent 0 35%, rgba(53,231,255,0.14), transparent 66%);
  transform: translateX(-80%);
  animation: hudScan 5.8s ease-in-out infinite;
}

.hud-profile:hover,
.hud-pill:hover,
.hud-timer:hover,
.hud-inbox:hover {
  transform: translateY(-2px) scale(1.01);
  box-shadow:
    0 12px 28px rgba(53,231,255,0.14),
    inset 0 1px 0 rgba(255,255,255,0.84);
}

.player-hud::after {
  content: "";
  position: absolute;
  inset: auto 18px 0;
  height: 2px;
  border-radius: 999px;
  background: linear-gradient(90deg, transparent, rgba(53,231,255,0.75), rgba(246,200,95,0.65), transparent);
  opacity: 0.55;
  pointer-events: none;
}

.hud-profile {
  position: relative;
  z-index: 1;
  min-height: 48px;
  min-width: 0;
  border: 1px solid rgba(255,255,255,0.72);
  border-radius: 16px;
  padding: 5px 12px 5px 5px;
  background:
    linear-gradient(135deg, rgba(255,255,255,0.52), transparent),
    rgba(255,255,255,0.54);
  color: #273449;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font: inherit;
  font-weight: 1000;
  cursor: pointer;
  overflow: hidden;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.86), 0 10px 22px rgba(77,98,122,0.08);
}

.hud-avatar {
  flex: 0 0 auto;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: linear-gradient(135deg, #35e7ff, #ff4fd8);
  color: #06110e;
  font-size: 0.88rem;
  font-weight: 1000;
  box-shadow: 0 0 22px rgba(53,231,255,0.32), inset 0 0 0 2px rgba(255,255,255,0.12);
}

.hud-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.hud-identity {
  min-width: 0;
  display: grid;
  gap: 3px;
  text-align: left;
  line-height: 1.05;
}

.hud-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 0.95rem;
}

.hud-level {
  color: #1a92a7;
  font-size: 0.68rem;
  font-weight: 1000;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.hud-xp-track {
  width: min(160px, 100%);
  height: 4px;
  border-radius: 999px;
  overflow: hidden;
  background: rgba(151,172,198,0.24);
}

.hud-xp-fill {
  display: block;
  width: 0%;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #35e7ff, #26d3a2, #f6c85f);
  box-shadow: 0 0 12px rgba(53,231,255,0.34);
  transition: width 320ms ease;
}

.hud-pill {
  position: relative;
  z-index: 1;
  min-height: 48px;
  border-radius: 16px;
  padding: 0 13px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  white-space: nowrap;
  background:
    linear-gradient(180deg, rgba(255,255,255,0.64), transparent 52%),
    rgba(255,255,255,0.56);
  color: #273449;
  font-size: 0.82rem;
  font-weight: 1000;
  border: 1px solid rgba(255,255,255,0.72);
  font-variant-numeric: tabular-nums;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.86), 0 10px 22px rgba(77,98,122,0.08);
}

.hud-pill::after,
.hud-inbox::after,
.hud-profile::after,
.hud-timer::after {
  content: "";
  position: absolute;
  inset: 1px;
  border-radius: inherit;
  background: linear-gradient(135deg, rgba(255,255,255,0.16), transparent 42%);
  opacity: 0.48;
  pointer-events: none;
}

.hud-stat-icon {
  position: relative;
  z-index: 1;
  width: 28px;
  height: 28px;
  flex: 0 0 auto;
  filter: drop-shadow(0 0 10px rgba(53,231,255,0.28));
}

.ion-credit-logo {
  overflow: visible;
  filter: drop-shadow(0 0 10px rgba(246,200,95,0.32));
}

.ion-energy-logo {
  overflow: visible;
  filter: drop-shadow(0 0 12px rgba(53,231,255,0.34));
}

.hud-stat-value {
  position: relative;
  z-index: 1;
}

.hud-stat-copy {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 2px;
  line-height: 1;
}

.hud-stat-label {
  color: #718196;
  font-size: 0.58rem;
  font-weight: 1000;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.hud-credits {
  color: #f6c85f;
  min-width: 136px;
}

.hud-energy {
  min-width: 132px;
  overflow: hidden;
}

.hud-energy::before {
  content: "";
  position: absolute;
  inset: 0;
  width: var(--energy-fill, 0%);
  background: linear-gradient(90deg, rgba(38,211,162,0.34), rgba(53,231,255,0.22));
  pointer-events: none;
}

.hud-energy span {
  position: relative;
  z-index: 1;
}

.hud-time {
  color: #1a92a7;
  min-width: 92px;
}

.hud-timer {
  position: relative;
  z-index: 1;
  min-height: 48px;
  min-width: 126px;
  border: 1px solid rgba(255,255,255,0.72);
  border-radius: 16px;
  padding: 4px 12px;
  display: grid;
  align-content: center;
  gap: 1px;
  background:
    linear-gradient(135deg, rgba(246,200,95,0.22), rgba(53,231,255,0.13)),
    rgba(255,255,255,0.56);
  color: #273449;
  font: inherit;
  cursor: pointer;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.86), 0 10px 22px rgba(77,98,122,0.08);
}

.hud-timer-title {
  color: #f6c85f;
  font-size: 0.62rem;
  font-weight: 1000;
  line-height: 1;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.hud-timer-value {
  color: #273449;
  font-size: 0.82rem;
  line-height: 1;
  font-weight: 1000;
  font-variant-numeric: tabular-nums;
}

.hud-timer.complete {
  color: #031014;
  background: linear-gradient(135deg, #f6c85f, #35e7ff, #26d3a2);
  border-color: rgba(255,255,255,0.42);
  box-shadow: 0 0 26px rgba(246,200,95,0.26), 0 0 22px rgba(53,231,255,0.2);
  animation: timerReadyPulse 1.3s ease-in-out infinite;
}

.hud-timer.complete .hud-timer-title,
.hud-timer.complete .hud-timer-value {
  color: #031014;
}

.hud-inbox {
  position: relative;
  z-index: 1;
  min-height: 48px;
  min-width: 52px;
  border: 1px solid rgba(255,255,255,0.72);
  border-radius: 16px;
  padding: 0 11px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  background:
    linear-gradient(180deg, rgba(255,255,255,0.64), transparent 52%),
    rgba(255,255,255,0.56);
  color: #273449;
  font: inherit;
  font-size: 0.82rem;
  font-weight: 1000;
  cursor: pointer;
  transition: transform 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.hud-inbox-icon {
  width: 25px;
  height: 25px;
  display: block;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
  filter: drop-shadow(0 0 10px rgba(53,231,255,0.28));
}

.hud-inbox:hover {
  transform: translateY(-1px);
  box-shadow: 0 0 22px rgba(53,231,255,0.18);
}

.hud-inbox.has-unread {
  color: #031014;
  background:
    radial-gradient(circle at 72% 18%, rgba(255,255,255,0.54), transparent 30%),
    linear-gradient(135deg, #f6c85f, #35e7ff 54%, #ff4fd8);
  box-shadow: 0 0 28px rgba(246,200,95,0.32), 0 0 24px rgba(53,231,255,0.22);
  animation: socialPulse 1.8s ease-in-out infinite;
}

.hud-unread {
  min-width: 20px;
  height: 20px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  padding: 0 5px;
  background: #ff4f7a;
  color: #fff;
  font-size: 0.68rem;
  line-height: 1;
  box-shadow: 0 0 0 2px rgba(3,13,31,0.9), 0 0 18px rgba(255,79,122,0.44);
}

.nav-backdrop {
  position: fixed;
  inset: 0;
  z-index: 50;
  background:
    radial-gradient(circle at 18% 12%, rgba(246, 255, 223, 0.4), transparent 22rem),
    radial-gradient(circle at 88% 18%, rgba(218, 242, 255, 0.42), transparent 24rem),
    linear-gradient(135deg, rgba(226, 239, 218, 0.48), rgba(201, 223, 242, 0.36)),
    rgba(218, 230, 232, 0.28);
  backdrop-filter: blur(14px) saturate(1.08);
  -webkit-backdrop-filter: blur(14px) saturate(1.08);
  opacity: 0;
  pointer-events: none;
  transition: opacity 190ms ease;
}

.nav-backdrop.open {
  opacity: 1;
  pointer-events: auto;
}

.game-nav {
  position: fixed;
  right: max(18px, env(safe-area-inset-right));
  top: calc(max(96px, env(safe-area-inset-top) + 96px));
  bottom: auto;
  z-index: 60;
  width: min(396px, calc(100vw - 28px));
  max-height: min(620px, calc(100vh - 118px));
  overflow-y: auto;
  display: grid;
  gap: 16px;
  padding: 24px 22px 28px;
  border: 1px solid rgba(255, 255, 255, 0.74);
  border-radius: 30px;
  background:
    linear-gradient(145deg, rgba(255,255,255,0.48), transparent 34%),
    radial-gradient(circle at 18% 0%, rgba(210, 241, 255, 0.44), transparent 15rem),
    radial-gradient(circle at 100% 28%, rgba(240, 250, 226, 0.42), transparent 15rem),
    linear-gradient(180deg, rgba(247, 252, 255, 0.93), rgba(230, 241, 247, 0.9));
  box-shadow:
    0 26px 70px rgba(51, 73, 94, 0.22),
    0 4px 24px rgba(67, 92, 118, 0.12),
    inset 0 1px 0 rgba(255,255,255,0.9),
    inset 0 -26px 60px rgba(191, 211, 224, 0.16);
  transform: translate3d(18px, -14px, 0) scale(0.94);
  transform-origin: top right;
  opacity: 0;
  pointer-events: none;
  transition: transform 260ms cubic-bezier(.17,.92,.22,1), opacity 170ms ease, filter 170ms ease;
  backdrop-filter: blur(28px) saturate(1.18);
  -webkit-backdrop-filter: blur(28px) saturate(1.18);
  scrollbar-width: thin;
  scrollbar-color: rgba(130, 149, 171, 0.42) rgba(255,255,255,0.26);
}

.game-nav::before {
  content: "";
  position: absolute;
  inset: 10px;
  border-radius: 24px;
  pointer-events: none;
  border: 1px solid rgba(255,255,255,0.58);
  background:
    linear-gradient(115deg, rgba(255,255,255,0.32), transparent 38%),
    linear-gradient(180deg, rgba(255,255,255,0.2), transparent 62%);
  opacity: 0.76;
}

.game-nav.open {
  transform: translate3d(0, 0, 0) scale(1) rotateX(0);
  opacity: 1;
  pointer-events: auto;
}

.nav-head {
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  min-height: 26px;
  padding: 0 2px;
  color: #7d8898;
  font-size: 0.72rem;
  font-weight: 900;
}

.nav-head strong,
.nav-head span {
  display: inline-flex;
}

.nav-head strong {
  color: #6d7889;
  font-size: 0.78rem;
  font-weight: 1000;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(255,255,255,0.55);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.84), 0 8px 16px rgba(87,104,124,0.1);
}

.nav-head span {
  color: #8d98a8;
}

.nav-copy {
  width: 32px;
  height: 32px;
  border: 0;
  border-radius: 12px;
  display: grid;
  place-items: center;
  color: #728094;
  background: rgba(255,255,255,0.68);
  cursor: pointer;
  box-shadow: 0 8px 18px rgba(83, 101, 122, 0.13), inset 0 1px 0 rgba(255,255,255,0.88);
  transition: transform 150ms ease, color 150ms ease, background 150ms ease;
}

.nav-copy svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.nav-copy:hover,
.nav-copy.copied {
  color: #2c3e54;
  background: rgba(255,255,255,0.9);
  transform: translateY(-1px);
}

.nav-player-card {
  position: relative;
  z-index: 1;
  width: 100%;
  min-height: 76px;
  border: 1px solid rgba(255,255,255,0.7);
  border-radius: 999px;
  padding: 10px 18px 10px 12px;
  display: grid;
  grid-template-columns: 56px 1fr auto;
  align-items: center;
  gap: 14px;
  color: #344155;
  background:
    linear-gradient(120deg, rgba(255,255,255,0.72), rgba(246,251,255,0.42)),
    rgba(255,255,255,0.5);
  box-shadow:
    0 14px 30px rgba(86, 105, 126, 0.14),
    inset 0 1px 0 rgba(255,255,255,0.92);
  cursor: pointer;
  transition: transform 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.nav-player-card:hover {
  transform: translateY(-1px);
  box-shadow: 0 18px 34px rgba(80, 101, 124, 0.18), inset 0 1px 0 rgba(255,255,255,0.94);
}

.nav-player-avatar {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  overflow: hidden;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, #dff7ff, #f3ffd9);
  color: #304258;
  font-size: 1.05rem;
  font-weight: 1000;
  box-shadow: 0 10px 20px rgba(85, 104, 127, 0.16), inset 0 0 0 2px rgba(255,255,255,0.72);
}

.nav-player-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.nav-player-copy {
  min-width: 0;
  display: grid;
  gap: 3px;
  text-align: left;
}

.nav-player-copy strong {
  color: #334054;
  font-size: 1.05rem;
  font-weight: 1000;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.nav-player-copy small {
  color: #8a96a8;
  font-size: 0.72rem;
  font-weight: 900;
}

.nav-chevron {
  color: #758399;
  font-size: 2.1rem;
  line-height: 1;
}

.nav-pass {
  position: relative;
  z-index: 1;
  width: min(280px, calc(100% - 40px));
  min-height: 54px;
  margin: -3px auto 6px;
  border-radius: 999px;
  display: grid;
  grid-template-columns: 52px 1fr;
  align-items: center;
  gap: 10px;
  padding: 7px 20px 7px 9px;
  color: #7b8798;
  background: rgba(255,255,255,0.72);
  box-shadow:
    0 12px 24px rgba(79, 98, 120, 0.14),
    inset 0 1px 0 rgba(255,255,255,0.9),
    inset 0 -12px 24px rgba(196, 213, 225, 0.2);
  font-weight: 1000;
}

.nav-pass img {
  width: 42px;
  height: 32px;
  object-fit: contain;
  filter: drop-shadow(0 6px 10px rgba(78, 101, 126, 0.18));
}

.nav-link-list {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 6px;
  padding: 8px 18px 2px;
}

.game-nav a {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 18px;
  min-height: 54px;
  border-radius: 999px;
  padding: 0 18px;
  color: #758297;
  text-decoration: none;
  font-weight: 1000;
  border: 1px solid transparent;
  background: transparent;
  box-shadow: none;
  overflow: hidden;
  transition: transform 150ms ease, background 150ms ease, border-color 150ms ease, color 150ms ease, box-shadow 150ms ease;
}

.nav-icon {
  position: relative;
  flex: 0 0 auto;
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  color: #7d899b;
}

.nav-icon svg {
  width: 25px;
  height: 25px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.nav-icon.has-dot::after {
  content: "";
  position: absolute;
  top: 0;
  right: 1px;
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: #ff4f85;
  box-shadow: 0 0 0 3px rgba(255,255,255,0.8), 0 4px 10px rgba(255,79,133,0.34);
}

.game-nav a > span:last-child {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.game-nav a:hover,
.game-nav a.active {
  background: rgba(255,255,255,0.58);
  color: #304057;
  border-color: rgba(255,255,255,0.7);
  transform: translateX(-3px);
  box-shadow: 0 12px 24px rgba(82, 101, 122, 0.12), inset 0 1px 0 rgba(255,255,255,0.9);
}

.game-nav a:hover .nav-icon,
.game-nav a.active .nav-icon {
  color: #41526a;
}

body.nav-ready {
  padding-top: max(82px, calc(env(safe-area-inset-top) + 82px)) !important;
}

@keyframes hudScan {
  0%, 45% { transform: translateX(-90%); opacity: 0; }
  58% { opacity: 1; }
  100% { transform: translateX(90%); opacity: 0; }
}

@keyframes navButtonFloat {
  0%, 100% { translate: 0 0; }
  50% { translate: 0 -4px; }
}

@keyframes navButtonOrbit {
  to { transform: rotate(360deg); }
}

@keyframes quickJumpSheen {
  0% { transform: translateX(-120%); }
  100% { transform: translateX(120%); }
}

@keyframes ionNewsScroll {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

@keyframes miniMapPing {
  0%, 100% { transform: scale(0.86); opacity: 0.58; }
  50% { transform: scale(1.18); opacity: 1; }
}

@keyframes timerReadyPulse {
  0%, 100% { transform: translateY(0); filter: brightness(1); }
  50% { transform: translateY(-1px); filter: brightness(1.12); }
}

@keyframes creditLogoSheen {
  0%, 100% { transform: rotate(-3deg) scale(1); filter: drop-shadow(0 0 10px rgba(246,200,95,0.32)); }
  50% { transform: rotate(3deg) scale(1.05); filter: drop-shadow(0 0 18px rgba(246,200,95,0.52)); }
}

@keyframes energyLogoPulse {
  0%, 100% { transform: scale(1); filter: drop-shadow(0 0 10px rgba(53,231,255,0.3)); }
  50% { transform: scale(1.08); filter: drop-shadow(0 0 20px rgba(38,211,162,0.48)); }
}

@keyframes socialPulse {
  0%, 100% { transform: translateY(0) scale(1); }
  50% { transform: translateY(-1px) scale(1.035); }
}

@keyframes ionMoteDrift {
  0% { transform: translate3d(0, 18px, 0) scale(0.8); opacity: 0; }
  18% { opacity: 0.3; }
  70% { opacity: 0.5; }
  100% { transform: translate3d(38px, -110vh, 0) scale(1.35); opacity: 0; }
}

.player-hud {
  border-color: rgba(62, 210, 255, 0.34);
  background:
    linear-gradient(rgba(32,231,255,0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(32,231,255,0.04) 1px, transparent 1px),
    linear-gradient(145deg, rgba(32,231,255,0.14), rgba(71,119,255,0.1) 46%, rgba(255,232,107,0.06)),
    rgba(4, 15, 34, 0.9);
  background-size: 18px 18px, 18px 18px, auto, auto;
  color: #e8fbff;
  box-shadow:
    0 22px 62px rgba(0, 18, 48, 0.44),
    0 0 36px rgba(32,231,255,0.2),
    0 0 0 1px rgba(255,232,107,0.1),
    inset 0 1px 0 rgba(157,239,255,0.18);
}

.player-hud:hover {
  box-shadow:
    0 24px 68px rgba(0, 18, 48, 0.52),
    0 0 44px rgba(32,231,255,0.26),
    0 0 0 1px rgba(255,232,107,0.13),
    inset 0 1px 0 rgba(157,239,255,0.2);
}

.hud-profile,
.hud-pill,
.hud-inbox,
.hud-timer,
.nav-player-card,
.nav-pass,
.nav-copy,
.nav-head strong {
  border-color: rgba(62, 210, 255, 0.26);
  background:
    linear-gradient(135deg, rgba(32,231,255,0.12), transparent 44%),
    linear-gradient(180deg, rgba(10, 41, 82, 0.88), rgba(4, 15, 34, 0.9));
  color: #e8fbff;
  box-shadow: inset 0 1px 0 rgba(157,239,255,0.16), 0 10px 22px rgba(0,18,48,0.26);
}

.hud-pill,
.hud-inbox {
  isolation: isolate;
}

.hud-pill::before,
.hud-inbox::before {
  content: "";
  position: absolute;
  inset: -1px;
  z-index: -1;
  border-radius: inherit;
  background: linear-gradient(135deg, rgba(32,231,255,0.52), rgba(255,232,107,0.24), rgba(255,79,216,0.28));
  opacity: 0.28;
  filter: blur(8px);
  transition: opacity 160ms ease;
}

.hud-pill:hover::before,
.hud-inbox:hover::before {
  opacity: 0.58;
}

.hud-level,
.hud-time {
  color: #20e7ff;
}

.hud-xp-track {
  background: rgba(62,210,255,0.16);
}

.hud-xp-fill {
  background: linear-gradient(90deg, #20e7ff, #4777ff, #ffe86b);
}

.hud-stat-label,
.nav-head,
.nav-head span,
.nav-player-copy small,
.game-nav a,
.nav-icon,
.nav-copy,
.nav-chevron {
  color: #8fb9cc;
}

.hud-credits,
.hud-timer-title {
  color: #ffe86b;
}

.hud-credits .ion-credit-logo {
  animation: creditLogoSheen 4.2s ease-in-out infinite;
}

.hud-energy .ion-energy-logo {
  animation: energyLogoPulse 2.8s ease-in-out infinite;
}

.hud-timer-value,
.nav-player-copy strong {
  color: #e8fbff;
}

.hud-energy::before {
  background: linear-gradient(90deg, rgba(77,255,154,0.34), rgba(32,231,255,0.2));
}

.nav-backdrop {
  background:
    radial-gradient(circle at 18% 12%, rgba(32,231,255,0.2), transparent 22rem),
    radial-gradient(circle at 88% 18%, rgba(71,119,255,0.18), transparent 24rem),
    linear-gradient(135deg, rgba(2, 7, 19, 0.74), rgba(6, 18, 37, 0.72));
}

.game-nav {
  border-color: rgba(62, 210, 255, 0.34);
  background:
    linear-gradient(rgba(32,231,255,0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(32,231,255,0.04) 1px, transparent 1px),
    radial-gradient(circle at 18% 0%, rgba(32,231,255,0.18), transparent 15rem),
    radial-gradient(circle at 100% 28%, rgba(255,232,107,0.09), transparent 15rem),
    linear-gradient(180deg, rgba(8, 30, 60, 0.96), rgba(3, 13, 31, 0.94));
  background-size: 18px 18px, 18px 18px, auto, auto, auto;
  box-shadow:
    0 26px 70px rgba(0, 18, 48, 0.54),
    0 0 42px rgba(32,231,255,0.22),
    inset 0 1px 0 rgba(157,239,255,0.18),
    inset 0 -26px 60px rgba(0, 7, 18, 0.26);
  scrollbar-color: rgba(32,231,255,0.48) rgba(5,22,48,0.72);
}

.game-nav::before {
  border-color: rgba(62,210,255,0.22);
  background:
    linear-gradient(115deg, rgba(32,231,255,0.14), transparent 38%),
    linear-gradient(180deg, rgba(255,232,107,0.08), transparent 62%);
}

.nav-player-avatar {
  background: linear-gradient(135deg, #20e7ff, #4777ff 54%, #ffe86b);
  color: #02101f;
  box-shadow: 0 10px 24px rgba(32,231,255,0.22), inset 0 0 0 2px rgba(157,239,255,0.18);
}

.game-nav a:hover,
.game-nav a.active {
  background:
    linear-gradient(135deg, rgba(32,231,255,0.18), rgba(255,232,107,0.08)),
    rgba(5,22,48,0.84);
  color: #e8fbff;
  border-color: rgba(62,210,255,0.34);
  box-shadow: 0 12px 24px rgba(0,18,48,0.3), inset 0 1px 0 rgba(157,239,255,0.16);
}

.game-nav a:hover .nav-icon,
.game-nav a.active .nav-icon,
.nav-copy:hover,
.nav-copy.copied {
  color: #20e7ff;
}

@media (max-width: 760px) {
  .nav-toggle {
    width: 60px;
    height: 60px;
    right: max(14px, env(safe-area-inset-right));
    top: max(14px, calc(env(safe-area-inset-top) + 14px));
    z-index: 90;
  }

  .quick-jump-rail {
    right: max(10px, env(safe-area-inset-right));
    top: max(172px, calc(env(safe-area-inset-top) + 172px));
    gap: 6px;
  }

  .quick-jump-button {
    min-width: 48px;
    width: 48px;
    min-height: 42px;
    grid-template-columns: 1fr;
    justify-items: center;
    padding: 0;
    border-radius: 14px;
  }

  .quick-jump-button span {
    position: absolute;
    inline-size: 1px;
    block-size: 1px;
    overflow: hidden;
    clip-path: inset(50%);
  }

  .ion-news-ticker {
    width: min(100vw - 16px, 720px);
    min-height: 34px;
    border-radius: 12px;
    grid-template-columns: auto minmax(0, 1fr);
  }

  .ion-news-label {
    padding: 0 10px;
    font-size: 0.58rem;
  }

  .ion-news-track {
    gap: 22px;
    padding: 0 12px;
    animation-duration: 54s;
  }

  .ion-news-track span {
    min-height: 34px;
    font-size: 0.7rem;
  }

  .player-hud {
    top: max(6px, env(safe-area-inset-top));
    left: max(8px, env(safe-area-inset-left));
    right: max(8px, env(safe-area-inset-right));
    transform: none;
    width: auto;
    min-height: 0;
    grid-template-columns: minmax(0, 1fr) 58px 58px;
    grid-template-rows: 46px 34px 28px;
    grid-template-areas:
      "profile credits energy"
      "inbox timer timer"
      "time timer timer";
    align-items: stretch;
    justify-content: stretch;
    gap: 7px;
    padding: 8px;
    border-radius: 24px;
    border-color: rgba(62,210,255,0.34);
    background:
      linear-gradient(rgba(32,231,255,0.05) 1px, transparent 1px),
      linear-gradient(90deg, rgba(32,231,255,0.04) 1px, transparent 1px),
      linear-gradient(145deg, rgba(32,231,255,0.14), rgba(71,119,255,0.1) 46%, rgba(255,232,107,0.06)),
      rgba(4,15,34,0.92);
    background-size: 18px 18px, 18px 18px, auto, auto;
    box-shadow:
      0 16px 42px rgba(0,18,48,0.42),
      0 0 30px rgba(32,231,255,0.18),
      inset 0 1px 0 rgba(157,239,255,0.18);
  }

  .hud-profile {
    grid-area: profile;
    width: 100%;
    max-width: none;
    justify-self: stretch;
    min-width: 0;
    min-height: 0;
    padding: 5px 10px 5px 5px;
    border-radius: 19px;
    background:
      linear-gradient(135deg, rgba(32,231,255,0.12), transparent 44%),
      linear-gradient(180deg, rgba(10,41,82,0.88), rgba(4,15,34,0.9));
  }

  .hud-avatar {
    width: 36px;
    height: 36px;
    font-size: 0.76rem;
  }

  .hud-name {
    max-width: none;
    font-size: 0.78rem;
  }

  .hud-level {
    font-size: 0.56rem;
  }

  .hud-xp-track {
    width: min(142px, 100%);
    height: 3px;
  }

  .hud-pill {
    width: 100%;
    min-width: 0;
    min-height: 0;
    padding: 0;
    gap: 0;
    font-size: 0.62rem;
    justify-self: stretch;
    border-radius: 18px;
    flex-direction: column;
    background:
      linear-gradient(135deg, rgba(32,231,255,0.12), transparent 44%),
      linear-gradient(180deg, rgba(10,41,82,0.88), rgba(4,15,34,0.9));
  }

  .hud-credits {
    grid-area: credits;
    min-width: 0;
    border-color: rgba(62,210,255,0.26);
    box-shadow: inset 0 1px 0 rgba(157,239,255,0.16), 0 8px 18px rgba(0,18,48,0.24);
  }

  .hud-energy {
    grid-area: energy;
    min-width: 0;
    border-color: rgba(62,210,255,0.26);
    box-shadow: inset 0 1px 0 rgba(157,239,255,0.16), 0 8px 18px rgba(0,18,48,0.24);
  }

  .hud-stat-icon {
    width: 19px;
    height: 19px;
    margin-top: 3px;
  }

  .hud-stat-value {
    min-width: 0;
    max-width: 52px;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1;
    font-size: 0.56rem;
  }

  .hud-stat-copy {
    display: block;
    text-align: center;
    line-height: 1;
  }

  .hud-stat-label {
    display: none;
  }

  .hud-time {
    grid-area: time;
    display: inline-flex;
    justify-self: stretch;
    width: 100%;
    min-width: 0;
    min-height: 0;
    padding: 0 7px;
    border-radius: 15px;
    font-size: 0.6rem;
    letter-spacing: 0;
  }

  .hud-timer {
    grid-area: timer;
    justify-self: stretch;
    width: auto;
    margin-left: 0;
    min-width: 0;
    min-height: 0;
    padding: 5px 9px;
    border-radius: 19px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 4px;
    border-color: rgba(62,210,255,0.26);
    background:
      linear-gradient(135deg, rgba(255,232,107,0.16), rgba(32,231,255,0.12)),
      linear-gradient(180deg, rgba(10,41,82,0.88), rgba(4,15,34,0.9));
  }

  .hud-timer-title {
    display: block;
    max-width: 100%;
    font-size: 0.54rem;
    text-align: center;
  }

  .hud-timer-value {
    font-size: 0.88rem;
  }

  .hud-inbox {
    grid-area: inbox;
    min-height: 0;
    min-width: 0;
    width: 100%;
    padding: 0;
    gap: 0;
    font-size: 0.68rem;
    border-radius: 19px;
    background:
      linear-gradient(135deg, rgba(32,231,255,0.12), transparent 44%),
      linear-gradient(180deg, rgba(10,41,82,0.88), rgba(4,15,34,0.9));
  }

  .hud-inbox-icon {
    width: 19px;
    height: 19px;
  }

  .hud-unread {
    position: absolute;
    top: -5px;
    right: -4px;
    min-width: 18px;
    height: 18px;
    padding: 0 4px;
    font-size: 0.62rem;
    box-shadow: 0 0 14px rgba(255,79,122,0.38);
  }

  .game-nav {
    right: max(12px, env(safe-area-inset-right));
    top: calc(max(82px, env(safe-area-inset-top) + 82px));
    bottom: auto;
    width: min(360px, calc(100vw - 20px));
    max-height: min(520px, calc(100dvh - 176px));
    border-radius: 28px;
    padding: 18px 16px 22px;
    gap: 13px;
    z-index: 80;
  }

  .nav-head {
    padding: 0 3px;
    font-size: 0.66rem;
  }

  .nav-head strong {
    max-width: 116px;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .nav-player-card {
    min-height: 70px;
    grid-template-columns: 50px 1fr auto;
    gap: 11px;
    padding: 10px 15px 10px 10px;
  }

  .nav-player-avatar {
    width: 50px;
    height: 50px;
  }

  .nav-pass {
    width: min(260px, calc(100% - 26px));
    min-height: 50px;
  }

  .nav-link-list {
    padding: 4px 8px 0;
    gap: 4px;
  }

  .game-nav a {
    min-height: 48px;
    border-radius: 999px;
    padding: 0 14px;
    gap: 14px;
    font-size: 0.92rem;
  }

  .nav-icon {
    width: 28px;
    height: 28px;
  }

  .nav-icon svg {
    width: 23px;
    height: 23px;
  }

  body.nav-ready {
    padding-top: max(132px, calc(env(safe-area-inset-top) + 132px)) !important;
  }
}

@media (max-width: 390px) {
  .player-hud {
    left: max(5px, env(safe-area-inset-left));
    right: max(5px, env(safe-area-inset-right));
    grid-template-columns: minmax(0, 1fr) 50px 50px;
    grid-template-rows: 42px 32px 26px;
    gap: 5px;
    padding: 6px;
    border-radius: 21px;
  }

  .hud-pill {
    width: 100%;
    min-height: 0;
    padding: 0;
    font-size: 0.58rem;
    border-radius: 16px;
  }

  .hud-stat-icon {
    width: 16px;
    height: 16px;
  }

  .hud-stat-label {
    display: none;
  }

  .hud-timer-title {
    display: none;
  }

  .hud-inbox {
    width: 100%;
    min-width: 0;
    min-height: 0;
    padding: 0;
    border-radius: 16px;
  }

  .hud-time {
    font-size: 0.54rem;
    min-height: 0;
    padding: 0 5px;
  }

  .hud-timer {
    min-height: 0;
    padding: 4px 7px;
    width: auto;
    margin-left: 0;
    border-radius: 16px;
  }

  .hud-timer-value {
    font-size: 0.76rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .nav-toggle,
  .nav-toggle::before,
  .game-nav a::after,
  .quick-jump-button:hover::before,
  .ion-news-track,
  .ion-ambient-layer span {
    animation: none;
  }

  .nav-toggle,
  .game-nav,
  .game-nav a,
  .quick-jump-button,
  .nav-backdrop {
    transition-duration: 1ms;
  }
}
