/* TGL design layer v2 — shared patterns for header, hero and sections.
   Loads after the compiled base (dist) and brand stylesheet (style.css). */

:root {
  --navy: #0a0e1a;
  --navy-2: #0e1324;
  --violet-glow: #8b6cff;
  --text-soft: #b6bfcf;
  --container-wide: 1600px;
  --header-blur: rgb(8 10 18 / 0.78);
}

/* ---------- Layout: wide container shared by header and hero ---------- */
.site-header > .container,
.hero--world .hero__intro { width: min(100% - 2 * var(--gutter), var(--container-wide)); }

/* ---------- Header ---------- */
.site-header {
  background: linear-gradient(180deg, rgb(5 7 12 / 0.7), rgb(5 7 12 / 0));
}
.site-header.is-scrolled {
  background: var(--header-blur);
  box-shadow: 0 1px 0 rgb(255 255 255 / 0.04), 0 18px 40px -24px rgb(0 0 0 / 0.8);
}
.site-header .container { gap: clamp(1rem, 2.5vw, 3rem); }
.primary-nav { margin-inline: auto; }
.nav-menu { gap: clamp(1.1rem, 2vw, 2.4rem); }
.nav-menu > li > a { font-size: 0.74rem; letter-spacing: 0.18em; padding-block: 12px; }
.nav-menu a::after { left: 50%; right: 50%; transform: none; transition: left var(--dur) var(--ease-out), right var(--dur) var(--ease-out); }
.nav-menu a:hover::after, .nav-menu .current-menu-item > a::after, .nav-menu a[aria-current="page"]::after,
.nav-menu .current-menu-ancestor > a::after { left: 0; right: 0; transform: none; }
.nav-menu .current-menu-ancestor > a { color: var(--fg); }

/* Dropdown: caret, glass panel and a soft reveal instead of an abrupt toggle. */
.nav-menu .menu-item-has-children > a { padding-right: 14px; }
.nav-menu .menu-item-has-children > a::before {
  content: ""; position: absolute; right: 0; top: 50%; width: 5px; height: 5px;
  border: solid currentColor; border-width: 0 1px 1px 0; translate: 0 -70%; rotate: 45deg; opacity: 0.7;
  transition: rotate var(--dur) var(--ease-out);
}
.nav-menu .menu-item-has-children:is(:hover, :focus-within) > a::before { rotate: 225deg; translate: 0 -20%; }
@media (min-width: 961px) {
  .nav-menu .sub-menu {
    display: grid; gap: 2px; top: calc(100% + 6px); left: 50%; min-width: 230px; padding: 10px;
    translate: -50% 6px; opacity: 0; visibility: hidden;
    background: rgb(12 14 26 / 0.92); backdrop-filter: blur(16px) saturate(140%);
    border: 1px solid rgb(255 255 255 / 0.07); border-radius: var(--radius-lg);
    box-shadow: 0 24px 50px -20px rgb(0 0 0 / 0.9), inset 0 1px 0 rgb(255 255 255 / 0.04);
    transition: opacity var(--dur-fast), translate var(--dur) var(--ease-out), visibility var(--dur-fast);
  }
  .nav-menu .sub-menu::before { content: ""; position: absolute; inset: -12px 0 auto; height: 12px; } /* hover bridge */
  .nav-menu > li:is(:hover, :focus-within) > .sub-menu {
    display: grid; opacity: 1; visibility: visible; translate: -50% 0;
    transition: opacity var(--dur-fast), translate var(--dur) var(--ease-out), visibility 0s; /* focusable immediately */
  }
  .nav-menu .sub-menu a {
    padding: 0.7rem 0.85rem; border-radius: 6px; font: 500 0.82rem/1.2 var(--font-sans);
    letter-spacing: 0.01em; text-transform: none; color: var(--text-soft);
  }
  .nav-menu .sub-menu a::after { display: none; }
  .nav-menu .sub-menu a:hover, .nav-menu .sub-menu a:focus-visible { background: rgb(43 228 255 / 0.07); color: var(--fg); }
}
.header-cta { min-height: 42px; padding-inline: 1.2rem; font-size: 0.7rem; }

/* Mobile menu: larger targets, clear grouping, CTA inside the panel. */
@media (max-width: 960px) {
  .primary-nav { margin: 0; background: rgb(7 9 16 / 0.98); }
  .nav-menu > li > a { font: 600 1.15rem/1 var(--font-display); letter-spacing: -0.01em; text-transform: none; color: var(--fg); padding: 20px 0; }
  .nav-menu .menu-item-has-children > a::before { display: none; }
  .nav-menu .sub-menu { margin: -0.25rem 0 0.75rem; padding-left: 1rem; }
  .nav-menu .sub-menu a { font: 500 0.98rem/1 var(--font-sans); text-transform: none; letter-spacing: 0; color: var(--text-soft); padding: 14px 0; border-bottom: 0; }
}

/* ---------- Hero: "The Lounge, after hours" ----------
   .hero__world is one photographic coordinate space: plate, light shaft, motes, spill and the
   official cube loop are positioned in image percentages, so they stay locked to the plinth at
   every aspect ratio. Scroll reads as a camera move: push-in towards the plinth, the room dims
   while the shaft brightens, near bokeh drifts faster than the room, copy lifts away and the
   scene dissolves into the next section. Inputs: --hero-progress/--hero-x (brand-motion.js). */
.hero--world {
  --hp: var(--hero-progress, 0);
  --he: calc(var(--hp) * (2 - var(--hp))); /* ease-out: the camera slows naturally towards the hand-off */
  --hx: var(--hero-x, 0);
  height: auto;
}
@media (min-width: 961px) and (prefers-reduced-motion: no-preference) {
  .hero--world { height: 210svh; } /* sticky runway for the camera move */
}
.hero--world .hero__stage { height: 100svh; min-height: 680px; background: var(--ink); }
.hero__scene { position: absolute; inset: 0; overflow: hidden; container-type: size; pointer-events: none; }

.hero__world {
  --w: max(100cqw, 177.68cqh); /* cover the stage with the 1.7768:1 plate */
  position: absolute; width: var(--w); height: calc(var(--w) / 1.7768);
  left: calc((100cqw - var(--w)) * 0.714);
  top: min(0px, calc((100cqh - var(--w) / 1.7768) * 0.32)); /* ultrawide: lift the floor into frame */
  transform-origin: 71.3% 50%;
  transform: translate3d(calc(var(--hx) * -10px), calc(var(--he) * -3.5%), 0) scale(calc(1 + var(--he) * 0.13));
  will-change: transform;
}
.hero__plate {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  animation: hero-settle 2.6s var(--ease-out) both;
}
@keyframes hero-settle { from { opacity: 0; scale: 1.045; } }
/* Lighting shift: the room falls away around the plinth as the camera pushes in. */
.hero__world::after {
  content: ""; position: absolute; inset: 0; z-index: 1;
  /* Light lens vignette only: the room stays visible and its detail grows as the camera moves in.
     The lit area covers the cube and the whole plinth so they never separate. */
  background: radial-gradient(34% 56% at 71.3% 50%, transparent 45%, rgb(3 5 10 / 0.7) 100%);
  opacity: calc(0.1 + var(--he) * 0.3);
}

/* Volumetric shaft from the photographed fixture to the plinth (cone half-angle ~24deg). */
.hero__shaft {
  position: absolute; z-index: 2; left: 71.3%; top: 5.6%; width: 36%; height: 58%; translate: -50% 0;
  background: conic-gradient(from 156deg at 50% 0%,
    transparent 0deg, rgb(43 228 255 / 0.045) 9deg, rgb(150 236 255 / 0.17) 20deg,
    rgb(210 248 255 / 0.22) 24deg, rgb(150 236 255 / 0.17) 28deg, rgb(43 228 255 / 0.045) 39deg,
    transparent 48deg 360deg);
  -webkit-mask-image: linear-gradient(#000, rgb(0 0 0 / 0.85) 40%, rgb(0 0 0 / 0.25) 86%, transparent);
  mask-image: linear-gradient(#000, rgb(0 0 0 / 0.85) 40%, rgb(0 0 0 / 0.25) 86%, transparent);
  mix-blend-mode: screen; opacity: calc(0.6 + var(--hp) * 0.4);
}
/* Dust motes, visible only inside the shaft, drifting slowly (composited transform only). */
.hero__motes {
  position: absolute; z-index: 3; left: 71.3%; top: 9%; width: 28%; height: 50%; translate: -50% 0; overflow: hidden;
  -webkit-mask-image: radial-gradient(48% 58% at 50% 46%, #000 30%, transparent 100%);
  mask-image: radial-gradient(48% 58% at 50% 46%, #000 30%, transparent 100%);
  mix-blend-mode: screen; opacity: calc(0.55 + var(--hp) * 0.45);
}
.hero__motes::before, .hero__motes::after {
  content: ""; position: absolute; inset: -30% -10%;
  background-image:
    radial-gradient(circle at 12% 18%, rgb(225 250 255 / 0.9) 0 0.6px, transparent 1.6px),
    radial-gradient(circle at 38% 62%, rgb(225 250 255 / 0.7) 0 0.8px, transparent 2px),
    radial-gradient(circle at 71% 27%, rgb(225 250 255 / 0.8) 0 0.5px, transparent 1.4px),
    radial-gradient(circle at 84% 78%, rgb(225 250 255 / 0.6) 0 0.9px, transparent 2.2px),
    radial-gradient(circle at 55% 44%, rgb(225 250 255 / 0.5) 0 0.6px, transparent 1.6px),
    radial-gradient(circle at 23% 88%, rgb(225 250 255 / 0.7) 0 0.7px, transparent 1.8px),
    radial-gradient(circle at 93% 9%, rgb(225 250 255 / 0.5) 0 0.5px, transparent 1.4px);
  background-size: 173px 211px;
  animation: motes-drift 46s linear infinite alternate;
}
.hero__motes::after { background-size: 241px 157px; opacity: 0.6; animation-duration: 63s; animation-direction: alternate-reverse; }
@keyframes motes-drift { to { transform: translate3d(-4%, -14%, 0); } }
/* Light spill on the plinth top and polished floor: grounds the cube in the room light. */
.hero__spill {
  position: absolute; z-index: 2; left: 71.3%; top: 50%; width: 40%; height: 24%; translate: -50% 0; border-radius: 50%;
  background: radial-gradient(closest-side, rgb(43 228 255 / 0.2), rgb(43 228 255 / 0.07) 55%, transparent);
  mix-blend-mode: screen; opacity: calc(0.75 + var(--hp) * 0.25);
}
/* Official cube loop, unchanged and in its approved plinth-aligned box. */
.hero__cube { position: absolute; z-index: 4; left: 71.4%; top: 20%; width: 37.15%; height: 48%; translate: -50% 0; }
/* The derivative's dark extraction fog is removed at source, so only the baked floor reflection is trimmed. */
.hero__cube-poster, .hero__cube-video {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  -webkit-mask-image: linear-gradient(180deg, #000 76%, transparent 79%);
  mask-image: linear-gradient(180deg, #000 76%, transparent 79%);
}
/* Emissive neon light around the cube: additive (screen), so it brightens the room like real light
   instead of laying a dark cloud over it. Sits behind the cube, centred on its faces. */
.hero__glow {
  position: absolute; z-index: 3; left: 71.4%; top: 22%; width: 26%; height: 40%; translate: -50% 0; border-radius: 50%;
  background: radial-gradient(closest-side, rgb(43 228 255 / 0.22), rgb(43 228 255 / 0.08) 50%, rgb(139 108 255 / 0.03) 75%, transparent);
  mix-blend-mode: screen; opacity: calc(0.85 + var(--hp) * 0.15);
}
.hero__cube-video { opacity: 0; transition: opacity 0.8s var(--ease-out); }
.hero__cube.is-loop-ready .hero__cube-video { opacity: 1; }
.hero__cube.is-loop-ready .hero__cube-poster { opacity: 0; } /* never stack translucent edges */

/* Near-camera bokeh: out-of-focus lounge lights travelling faster than the room (parallax). */
.hero__bokeh {
  position: absolute; inset: -12% -6%; z-index: 5; mix-blend-mode: screen; opacity: 0.6;
  background:
    radial-gradient(circle at 7% 80%, rgb(255 186 118 / 0.11) 0 26px, transparent 70px),
    radial-gradient(circle at 17% 95%, rgb(43 228 255 / 0.07) 0 36px, transparent 92px),
    radial-gradient(circle at 93% 88%, rgb(255 178 108 / 0.09) 0 30px, transparent 78px),
    radial-gradient(circle at 86% 66%, rgb(43 228 255 / 0.05) 0 18px, transparent 50px),
    radial-gradient(circle at 58% 100%, rgb(255 198 140 / 0.07) 0 40px, transparent 104px);
  transform: translate3d(calc(var(--hx) * 18px), calc(var(--hp) * -24vh), 0) scale(calc(1 + var(--hp) * 0.12));
  will-change: transform;
}
/* Framing in viewport space. ::before is the copy-readability band: it clears as the copy leaves,
   opening the lounge up. ::after is the hand-off veil, reaching the page colour exactly at release
   so the Discover section (which starts on --ink) continues without a seam or flash. */
.hero__shade {
  position: absolute; inset: 0; z-index: 6;
  background:
    linear-gradient(180deg, rgb(5 7 12 / 0.7) 0%, transparent 17%),
    linear-gradient(0deg, var(--ink) 0%, rgb(7 7 12 / 0.55) 11%, transparent 28%);
}
.hero__shade::before {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, rgb(5 7 12 / 0.9) 0%, rgb(5 7 12 / 0.68) 27%, rgb(5 7 12 / 0.18) 50%, transparent 62%);
  opacity: clamp(0, calc(1 - var(--hp) * 1.6), 1);
}
.hero__shade::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(0deg, var(--ink) 18%, rgb(7 7 12 / 0.4) 70%, rgb(7 7 12 / 0) 100%);
  opacity: clamp(0, calc((var(--hp) - 0.6) * 2.5), 1);
}

/* Copy */
.hero--world .hero__content { z-index: 7; justify-content: center; padding: calc(var(--nav-h) + 1.5rem) 0 clamp(4.5rem, 10vh, 7.5rem); }
.hero--world .hero__intro {
  max-width: none;
  opacity: calc(1 - var(--hp) * 2.5); /* fully clear by 40%, before the room opens up behind it */
  transform: translate3d(0, calc(var(--hp) * -14vh), 0);
}
.hero--world .hero__title {
  width: auto; max-width: 22ch; margin-block: 1.1rem 0;
  font-size: clamp(2.8rem, 3.3vw + 0.5rem, 5.4rem); line-height: 0.98; letter-spacing: -0.045em; text-wrap: balance;
  text-shadow: 0 2px 40px rgb(3 5 10 / 0.55);
}
.hero--world .hero__title em {
  display: block; color: transparent; -webkit-text-stroke: 0; text-shadow: none;
  background: linear-gradient(100deg, #e9fcff 0%, var(--accent) 45%, var(--violet-glow) 110%);
  -webkit-background-clip: text; background-clip: text;
}
.hero--world .hero__intro > .lede {
  max-width: 44ch; margin-top: 1.6rem; color: var(--text-soft);
  font-size: clamp(1.02rem, 0.5vw + 0.85rem, 1.25rem); line-height: 1.6;
}
.hero--world .hero__actions { display: flex; flex-wrap: wrap; gap: 0.9rem; margin-top: 2.4rem; }
.btn--ghost { --btn-bg: rgb(255 255 255 / 0.04); --btn-line: rgb(255 255 255 / 0.22); backdrop-filter: blur(8px); }
.btn--ghost:hover { --btn-bg: rgb(43 228 255 / 0.08); }
/* .btn's clip-path cuts away any outside outline, so keyboard focus is drawn inside the shape in the button's text colour. */
a.btn:focus-visible, button.btn:focus-visible { outline: 2px solid currentColor; outline-offset: -6px; }

/* Scroll cue: a light travelling down a hairline; links to the next section. */
.hero__cue {
  position: absolute; left: 50%; bottom: clamp(16px, 3vh, 32px); z-index: 8; translate: -50% 0;
  display: grid; justify-items: center; gap: 12px; padding: 6px; text-decoration: none;
  font: 500 0.62rem/1 var(--font-hud); letter-spacing: 0.32em; text-transform: uppercase; color: rgb(228 231 238 / 0.62);
  opacity: clamp(0, calc(1 - var(--hp) * 7), 1); transition: color var(--dur-fast);
}
.hero__cue:hover { color: var(--fg); }
.hero__cue:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }
.hero__cue i { position: relative; width: 1px; height: 46px; overflow: hidden; background: rgb(255 255 255 / 0.14); }
.hero__cue i::after { content: ""; position: absolute; inset: 0; background: linear-gradient(transparent, var(--accent)); translate: 0 -100%; animation: cue-travel 2.6s var(--ease-in-out) infinite; }
@keyframes cue-travel { to { translate: 0 100%; } }
.hero--world .hero__controls { z-index: 8; }
.is-motion-paused .hero__motes::before, .is-motion-paused .hero__motes::after, .is-motion-paused .hero__cue i::after { animation-play-state: paused; }

/* Tablet and mobile: the room becomes a cinematic band above the copy, plinth centred. */
@media (max-width: 960px) {
  .hero--world .hero__stage { position: relative; height: auto; min-height: 100svh; display: flex; flex-direction: column; }
  .hero--world .hero__scene { position: relative; inset: auto; flex: none; height: clamp(360px, 58svh, 620px); }
  .hero__world {
    --w: max(177.68cqh, 174cqw); /* wide enough that the room never ends short of the right edge */
    left: calc(50cqw - var(--w) * 0.713); top: 0;
    transform-origin: 71.3% 45%; transform: scale(calc(1 + var(--hp) * 0.08));
  }
  .hero__bokeh { display: none; }
  .hero__shade { background: linear-gradient(180deg, rgb(5 7 12 / 0.6) 0%, transparent 24%, transparent 58%, var(--ink) 100%); }
  .hero__shade::before, .hero__shade::after { display: none; }
  .hero--world .hero__content { position: relative; inset: auto; margin-top: -4rem; padding: 0 0 6.5rem; }
  .hero--world .hero__intro { opacity: 1; transform: none; }
  .hero--world .hero__title { max-width: 14ch; font-size: clamp(2.5rem, 8.6vw, 4.4rem); }
  .hero--world .hero__title em { display: inline; }
  .hero--world .hero__intro > .lede { margin-top: 1.25rem; }
  .hero__cue { display: none; }
}
@media (max-width: 560px) {
  .hero--world .hero__actions { display: grid; grid-template-columns: 1fr; gap: 0.75rem; }
  .hero--world .hero__actions .btn { justify-content: center; width: 100%; }
  .hero--world .hero__controls { bottom: 18px; }
}
@media (prefers-reduced-motion: reduce) {
  .hero__world, .hero__bokeh, .hero--world .hero__intro { transform: none; }
  .hero--world .hero__intro { opacity: 1; }
  .hero__plate, .hero__motes::before, .hero__motes::after, .hero__cue i::after { animation: none; }
  .hero__cube-video { display: none; }
  .hero__cube .hero__cube-poster { opacity: 1; }
}

/* ---------- Global fixes ---------- */
/* Social icons were only sized on community pages; size them everywhere. */
.site-footer__social svg { width: 22px; height: 22px; }
/* Footer polish: social icons as one row (the generic footer list rule stacked them), and the
   Community children grouped beneath their parent instead of reading as top-level links. */
.site-footer__social .social { display: flex; flex-wrap: wrap; gap: 0.9rem; margin-top: 0.9rem; }
.site-footer__social .social a { display: inline-grid; place-items: center; opacity: 0.85; transition: opacity var(--dur-fast); }
.site-footer__social .social a:hover { opacity: 1; }
.site-footer .sub-menu { margin: 8px 0 2px; padding-left: 0.9rem; border-left: 1px solid var(--line); }

/* Mobile menu CTA: the verified Discord invite inside the panel; hidden on desktop. */
.nav-cta { display: none; }
@media (max-width: 960px) {
  .nav-cta { display: flex; justify-content: center; width: 100%; min-height: 54px; margin-top: 2rem; }
}

/* ---------- Shared section patterns ---------- */
/* Editorial display heading: second clause carries the accent gradient. */
.display-title {
  font-size: clamp(2.3rem, 2.4vw + 1.2rem, 4rem); line-height: 1.02; letter-spacing: -0.04em; text-wrap: balance;
}
.display-title em {
  display: block; font-style: normal; color: transparent;
  background: linear-gradient(100deg, #e9fcff, var(--accent) 50%, var(--violet-glow) 120%);
  -webkit-background-clip: text; background-clip: text;
}
/* Sections fade from the previous one rather than meeting on a hard line. */
.discover { background: linear-gradient(180deg, var(--ink), var(--navy) 55%, var(--ink)); }
.games { background: radial-gradient(70% 50% at 85% 0%, rgb(139 108 255 / 0.07), transparent 70%), var(--ink); }

/* ---------- Discover ---------- */
.discover .display-title { font-size: clamp(2.2rem, 1.9vw + 1.2rem, 3.4rem); }
.discover__grid { display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 7fr); gap: clamp(2.5rem, 6vw, 6.5rem); align-items: center; }
.discover__copy { display: grid; gap: 1.25rem; justify-items: start; }
.discover__copy p { max-width: 54ch; color: var(--text-soft); font-size: clamp(1rem, 0.3vw + 0.95rem, 1.12rem); line-height: 1.75; }
.discover__copy .display-title { margin-bottom: 0.5rem; }
.discover__pillars {
  display: flex; flex-wrap: wrap; gap: 0.5rem 1.6rem; margin: 0.5rem 0 1rem; padding: 0; list-style: none;
  font: 600 0.72rem/1 var(--font-hud); letter-spacing: 0.16em; text-transform: uppercase; color: var(--fg);
}
.discover__pillars li { display: flex; align-items: center; gap: 0.6rem; }
.discover__pillars li::before { content: ""; width: 6px; height: 6px; rotate: 45deg; background: var(--accent); box-shadow: var(--glow); }

.discover__media { position: relative; margin: 0; padding-bottom: 12%; }
.discover__main {
  display: block; width: 100%; aspect-ratio: 16 / 10; object-fit: cover; object-position: 40% 60%;
  border-radius: var(--radius-lg); filter: saturate(1.05) contrast(1.05);
  box-shadow: 0 40px 80px -40px rgb(0 0 0 / 0.9);
}
/* Inset crops to the gaming-station row only. */
.discover__inset {
  position: absolute; left: -7%; bottom: 0; width: 46%; aspect-ratio: 4 / 3;
  background: var(--inset) 72% 38% / 300% auto no-repeat var(--surface);
  border-radius: var(--radius-lg); border: 1px solid rgb(255 255 255 / 0.1);
  box-shadow: 0 30px 60px -20px rgb(0 0 0 / 0.95), 0 0 0 6px var(--ink);
}
.discover__media figcaption {
  position: absolute; right: 1.25rem; top: 1.1rem;
  font: 500 0.66rem/1 var(--font-hud); letter-spacing: 0.2em; text-transform: uppercase; color: rgb(228 231 238 / 0.7);
}
@media (max-width: 960px) {
  .discover__grid { grid-template-columns: 1fr; }
  .discover__media { order: -1; padding-bottom: 18%; }
  .discover__inset { left: auto; right: 4%; width: 44%; }
}

/* ---------- Games ---------- */
.games__head { display: grid; gap: 1rem; max-width: 720px; margin-bottom: clamp(2.5rem, 4vw, 4rem); }
.games__head p { color: var(--text-soft); font-size: clamp(1rem, 0.3vw + 0.95rem, 1.15rem); line-height: 1.65; max-width: 52ch; }
.games__grid {
  display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); grid-template-rows: repeat(2, minmax(260px, auto));
  gap: clamp(1rem, 1.5vw, 1.5rem);
}
.game {
  position: relative; display: flex; align-items: flex-end; overflow: hidden; isolation: isolate;
  min-height: 280px; border-radius: var(--radius-lg); border: 1px solid rgb(255 255 255 / 0.07); background: var(--surface);
  transition: border-color var(--dur) var(--ease-out), translate var(--dur) var(--ease-out), box-shadow var(--dur) var(--ease-out);
}
.game--arma-reforger { grid-row: span 2; min-height: 560px; }
.game:hover { border-color: rgb(43 228 255 / 0.35); translate: 0 -3px; box-shadow: 0 30px 60px -30px rgb(0 0 0 / 0.9), 0 0 0 1px rgb(43 228 255 / 0.12); }
.game__art {
  position: absolute; inset: 0; z-index: -1;
  background: var(--game-art, none) center / cover no-repeat, var(--game-fallback);
  transition: scale 1.2s var(--ease-out);
}
.game:hover .game__art { scale: 1.04; }
/* Legibility gradient over any art, fallback or approved image. */
.game__art::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgb(7 7 12 / 0.05) 20%, rgb(7 7 12 / 0.7) 62%, rgb(7 7 12 / 0.96)); }
/* Large outline watermark gives each fallback panel its own typographic identity. */
.game__art::before {
  content: attr(data-mark); position: absolute; right: -0.04em; top: 0.12em;
  font: 700 clamp(5rem, 10vw, 12rem)/0.8 var(--font-display); letter-spacing: -0.06em;
  color: transparent; -webkit-text-stroke: 1px rgb(255 255 255 / 0.09);
}
.game--arma-reforger .game__art {
  --game-fallback:
    repeating-radial-gradient(circle at 70% 30%, transparent 0 22px, rgb(255 196 120 / 0.06) 23px 24px),
    radial-gradient(120% 70% at 75% 100%, rgb(255 150 70 / 0.32), transparent 60%),
    linear-gradient(160deg, #1c2117, #0d100c 55%, #08090b);
}
.game--minecraft .game__art {
  --game-fallback:
    linear-gradient(90deg, rgb(0 0 0 / 0.22) 1px, transparent 1px) 0 0 / 28px 28px,
    linear-gradient(0deg, rgb(0 0 0 / 0.22) 1px, transparent 1px) 0 0 / 28px 28px,
    radial-gradient(90% 90% at 85% 15%, rgb(95 220 140 / 0.3), transparent 60%),
    linear-gradient(150deg, #10261b, #0a1511 60%, #07090b);
}
.game--hell-let-loose .game__art {
  --game-fallback:
    repeating-linear-gradient(115deg, rgb(255 230 190 / 0.03) 0 2px, transparent 2px 9px),
    radial-gradient(90% 80% at 80% 20%, rgb(200 170 120 / 0.2), transparent 60%),
    linear-gradient(160deg, #221d17, #12100e 60%, #08080a);
  filter: grayscale(0.35);
}
.game__body { position: relative; display: grid; gap: 0.7rem; padding: clamp(1.4rem, 2.4vw, 2.4rem); max-width: 560px; }
.game__meta {
  display: flex; flex-wrap: wrap; gap: 0.5rem 1rem; align-items: center; margin: 0;
  font: 600 0.68rem/1 var(--font-hud); letter-spacing: 0.16em; text-transform: uppercase; color: var(--text-soft);
}
.game__status { display: inline-flex; align-items: center; gap: 0.5rem; padding: 0.45rem 0.7rem; border-radius: 999px; background: rgb(61 220 151 / 0.1); color: #7cf0bf; border: 1px solid rgb(61 220 151 / 0.25); }
.game__status i { width: 6px; height: 6px; border-radius: 50%; background: currentColor; box-shadow: 0 0 10px currentColor; }
.is-soon .game__status { background: rgb(139 108 255 / 0.12); color: #c3b5ff; border-color: rgb(139 108 255 / 0.3); }
.game__title { font-size: clamp(1.7rem, 1.4vw + 1rem, 2.5rem); line-height: 1.05; letter-spacing: -0.035em; }
.game--arma-reforger .game__title { font-size: clamp(2.2rem, 2.6vw + 1rem, 3.8rem); }
.game__text { color: var(--text-soft); line-height: 1.6; max-width: 46ch; }
.game__cta {
  justify-self: start; display: inline-flex; align-items: center; gap: 0.6rem; margin-top: 0.4rem; padding-block: 0.4rem;
  font: 600 0.74rem/1 var(--font-hud); letter-spacing: 0.16em; text-transform: uppercase; color: var(--accent); text-decoration: none;
  border-bottom: 1px solid rgb(43 228 255 / 0.35);
}
.game__cta::after { content: ""; position: absolute; inset: 0; } /* whole panel is the hit area */
.game__cta svg { width: 14px; height: 14px; transition: translate var(--dur) var(--ease-out); }
.game:hover .game__cta svg { translate: 4px 0; }
.game__cta:focus-visible { outline: none; }
.game:has(.game__cta:focus-visible) { outline: 2px solid var(--accent); outline-offset: 3px; }
.games__foot { margin-top: 2rem; color: var(--fg-muted); font-size: 0.95rem; }
.games__foot a { margin-left: 0.5rem; color: var(--accent); }
@media (max-width: 960px) {
  .games__grid { grid-template-columns: 1fr; grid-template-rows: none; }
  .game--arma-reforger { grid-row: auto; min-height: 440px; }
}
@media (prefers-reduced-motion: reduce) {
  .game, .game__art, .game__cta svg { transition: none; }
  .game:hover { translate: none; }
  .game:hover .game__art { scale: none; }
}

/* ---------- Shared: inline text link with arrow ---------- */
.text-link {
  display: inline-flex; align-items: center; gap: 0.55rem; padding-block: 0.45rem;
  font: 600 0.72rem/1 var(--font-hud); letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--accent); text-decoration: none; border-bottom: 1px solid rgb(43 228 255 / 0.32);
}
.text-link svg { width: 14px; height: 14px; transition: translate var(--dur) var(--ease-out); }
.text-link:hover svg { translate: 4px 0; }

/* ---------- Aether showcase (product launch) ----------
   Aether brand kit palette: Midnight #0B0F1A, Ice, Periwinkle, Violet, Deep Violet. #aether already
   switches --accent to Periwinkle (style.css), so buttons and links follow the sub-brand. */
.showcase {
  --midnight: #0b0f1a; --periwinkle: #a3b8ff; --violet: #8170f2;
  overflow: hidden;
  background:
    radial-gradient(55% 60% at 76% 40%, rgb(129 112 242 / 0.13), transparent 70%),
    linear-gradient(180deg, var(--ink), var(--midnight) 20%, var(--midnight) 80%, var(--ink));
}
.showcase__grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(2rem, 5vw, 6rem); align-items: center; }
.showcase__copy { display: grid; gap: 1.25rem; justify-items: start; }
.showcase__copy p:not(.showcase__status) { max-width: 50ch; color: var(--text-soft); line-height: 1.75; font-size: clamp(1rem, 0.3vw + 0.95rem, 1.12rem); }
.showcase .display-title { font-size: clamp(2.2rem, 2vw + 1.2rem, 3.6rem); }
.showcase .display-title em { background: linear-gradient(100deg, #e3eaff, var(--periwinkle) 42%, var(--violet) 78%, #6a4de3); -webkit-background-clip: text; background-clip: text; }
.showcase__status {
  display: inline-flex; align-items: center; gap: 0.6rem; margin: 0; padding: 0.5rem 0.85rem; border-radius: 999px; white-space: nowrap;
  border: 1px solid rgb(163 184 255 / 0.28); background: rgb(129 112 242 / 0.1); color: #cdd7ff;
  font: 600 0.68rem/1 var(--font-hud); letter-spacing: 0.16em; text-transform: uppercase;
}
.showcase__pulse { width: 7px; height: 7px; border-radius: 50%; background: var(--periwinkle); animation: status-pulse 2.6s var(--ease-out) infinite; }
@keyframes status-pulse { 0% { box-shadow: 0 0 0 0 rgb(163 184 255 / 0.55); } 70%, 100% { box-shadow: 0 0 0 8px rgb(163 184 255 / 0); } }
.showcase__actions { display: flex; flex-wrap: wrap; gap: 0.9rem; margin-top: 0.8rem; }
.showcase__release {
  position: relative; display: flex; flex-wrap: wrap; gap: 0.15em 0.3em;
  margin-top: clamp(2rem, 4vw, 3.75rem); padding-top: 1.1rem;
  color: #e3eaff; font: 750 clamp(1.8rem, 2.65vw, 3rem)/1.1 var(--font-sans); letter-spacing: -0.035em;
}
.showcase__release::before { content: ""; position: absolute; top: 0; left: 0; width: 2.5rem; height: 1px; background: linear-gradient(90deg, var(--periwinkle), var(--violet)); }
.showcase__release > * { white-space: nowrap; }
.showcase__release strong { font-weight: inherit; color: var(--periwinkle); background: linear-gradient(100deg, #c5d6ff, var(--periwinkle) 35%, #a08af8); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
/* The video and matching poster share one full-section cover frame. */
.showcase--cinematic { position: relative; isolation: isolate; min-height: clamp(900px, 42vw, 1350px); display: grid; align-content: center; }
.showcase__background { position: absolute; inset: 0; z-index: -2; overflow: hidden; pointer-events: none; background: #05050c; }
.showcase__poster, .showcase__video { position: absolute; inset: 0; display: block; width: 100%; height: 100%; max-width: none; object-fit: cover; object-position: 58% 50%; }
.showcase__video { opacity: 0; transition: opacity 0.6s ease; }
.showcase__background.is-loop-ready .showcase__video { opacity: 1; }
.showcase--cinematic::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: linear-gradient(90deg, rgb(3 4 10 / 0.94), rgb(3 4 10 / 0.88) 45%, rgb(3 4 10 / 0.2) 76%, transparent),
    linear-gradient(180deg, rgb(5 5 12 / 0.25), transparent 25%, transparent 70%, rgb(5 5 12 / 0.7));
}
.showcase--cinematic > .container { position: relative; z-index: 1; }
@media (min-width: 1200px) {
  .showcase--cinematic > .showcase__release-slot {
    position: absolute; z-index: 2; top: 42%; right: var(--gutter); translate: 0 -50%;
    width: min(19vw, 520px); margin: 0;
  }
  .showcase__release-slot .showcase__release {
    display: grid; gap: 0.18em; margin-top: 0; padding-top: 1.4rem;
    font-size: clamp(2.25rem, 3vw, 4.75rem);
  }
}
/* Feature strip: one joined panel with hairline dividers, distinct from the game panels and news. */
.showcase__features {
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1px; margin: clamp(3rem, 6vw, 5.5rem) 0 0; padding: 0; list-style: none;
  background: rgb(163 184 255 / 0.1); border: 1px solid rgb(163 184 255 / 0.1); border-radius: var(--radius-lg); overflow: hidden;
}
.feature { position: relative; display: grid; align-content: start; gap: 0.7rem; padding: clamp(1.4rem, 2vw, 2rem); background: rgb(11 15 26 / 0.94); transition: background var(--dur) var(--ease-out); }
.feature::before { content: ""; position: absolute; inset: 0 0 auto; height: 2px; background: linear-gradient(90deg, var(--periwinkle), var(--violet)); transform: scaleX(0); transform-origin: left; transition: transform var(--dur) var(--ease-out); }
.feature:hover { background: rgb(19 23 42 / 0.96); }
.feature:hover::before { transform: scaleX(1); }
.feature__icon { width: 28px; height: 28px; fill: none; stroke: var(--periwinkle); stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.feature h3 { margin-top: 0.3rem; font-size: 1.12rem; letter-spacing: -0.01em; color: var(--fg); }
.feature p { color: var(--text-soft); font-size: 0.95rem; line-height: 1.6; }
.feature__status { justify-self: start; margin-top: 0.4rem; padding: 0.4rem 0.6rem; border-radius: 999px; font: 600 0.62rem/1 var(--font-hud); letter-spacing: 0.16em; text-transform: uppercase; }
.feature__status--development { color: #c3b5ff; background: rgb(129 112 242 / 0.12); border: 1px solid rgb(129 112 242 / 0.32); }
.feature__status--available { color: #7cf0bf; background: rgb(61 220 151 / 0.1); border: 1px solid rgb(61 220 151 / 0.25); }

/* ---------- Events agenda ---------- */
.agenda { background: var(--ink); }
.agenda__grid { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 7fr); gap: clamp(2.5rem, 6vw, 6rem); align-items: start; }
.agenda__head { position: sticky; top: calc(var(--nav-h) + 2rem); display: grid; gap: 1.2rem; justify-items: start; }
.agenda__head p { max-width: 42ch; color: var(--text-soft); line-height: 1.7; }
.agenda .display-title, .newsroom .display-title { font-size: clamp(2.2rem, 1.8vw + 1.2rem, 3.4rem); }
.agenda__list { margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--line); }
.event {
  position: relative; display: grid; grid-template-columns: 5.5rem minmax(0, 1fr) auto; gap: clamp(1rem, 2.5vw, 2.5rem); align-items: center;
  padding: clamp(1.4rem, 2.2vw, 2rem) clamp(0.5rem, 1.5vw, 1.5rem); border-bottom: 1px solid var(--line);
  transition: background var(--dur) var(--ease-out);
}
.event::before { content: ""; position: absolute; left: 0; top: 18%; bottom: 18%; width: 2px; background: var(--accent); box-shadow: var(--glow); transform: scaleY(0); transition: transform var(--dur) var(--ease-out); }
.event:hover { background: linear-gradient(90deg, rgb(43 228 255 / 0.05), transparent 70%); }
.event:hover::before { transform: scaleY(1); }
.event__date { display: grid; justify-items: center; gap: 0.3rem; padding: 0.9rem 0.5rem; text-align: center; border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--surface); }
.event__day { font: 600 2.1rem/1 var(--font-display); letter-spacing: -0.04em; color: var(--fg); }
.event__month { font: 600 0.7rem/1 var(--font-hud); letter-spacing: 0.2em; text-transform: uppercase; color: var(--accent); }
.event__weekday { font: 500 0.6rem/1 var(--font-hud); letter-spacing: 0.18em; text-transform: uppercase; color: var(--fg-muted); }
.event__body { display: grid; gap: 0.45rem; min-width: 0; }
.event__meta { display: flex; flex-wrap: wrap; gap: 0.4rem 1rem; align-items: center; margin: 0; font: 600 0.64rem/1 var(--font-hud); letter-spacing: 0.16em; text-transform: uppercase; color: var(--text-soft); }
.event__type { color: var(--accent); }
.event__title { font-size: clamp(1.3rem, 0.8vw + 1rem, 1.75rem); line-height: 1.15; letter-spacing: -0.025em; }
.event__title a { color: var(--fg); text-decoration: none; }
.event__title a::after { content: ""; position: absolute; inset: 0; } /* whole row is the hit area */
.event__title a:focus-visible { outline: none; }
.event:has(a:focus-visible) { outline: 2px solid var(--accent); outline-offset: -2px; }
.event__text { color: var(--text-soft); line-height: 1.6; }
.event__cta, .story__cta { display: inline-flex; align-items: center; gap: 0.5rem; font: 600 0.68rem/1 var(--font-hud); letter-spacing: 0.16em; text-transform: uppercase; color: var(--accent); white-space: nowrap; }
.event__cta svg, .story__cta svg { width: 14px; height: 14px; transition: translate var(--dur) var(--ease-out); }
.event:hover .event__cta svg, .story:hover .story__cta svg { translate: 4px 0; }
/* Intentional empty state, shared by events and news. */
.agenda__empty {
  display: grid; justify-items: start; gap: 0.9rem; padding: clamp(2rem, 4vw, 3.5rem);
  border: 1px dashed rgb(255 255 255 / 0.14); border-radius: var(--radius-lg);
  background: radial-gradient(80% 120% at 0% 0%, rgb(43 228 255 / 0.06), transparent 60%), var(--surface);
}
.agenda__empty svg { width: 36px; height: 36px; fill: none; stroke: var(--accent); stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round; }
.agenda__empty h3 { font-size: 1.4rem; letter-spacing: -0.02em; }
.agenda__empty p { max-width: 46ch; color: var(--text-soft); line-height: 1.6; }
.agenda__empty .btn { margin-top: 0.4rem; }

/* ---------- News: magazine layout ---------- */
.newsroom { background: linear-gradient(180deg, var(--ink), var(--navy) 50%, var(--ink)); }
.newsroom__head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 1.5rem 3rem; margin-bottom: clamp(2.5rem, 4vw, 3.5rem); }
.newsroom__head > div { display: grid; gap: 1rem; }
.newsroom__grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: clamp(1.25rem, 3vw, 3rem); align-items: start; }
.story { position: relative; display: grid; gap: 1.1rem; }
.story__media { position: relative; aspect-ratio: 16 / 9; overflow: hidden; border-radius: var(--radius-lg); border: 1px solid rgb(255 255 255 / 0.07); background: var(--surface); }
.story__media > img { width: 100%; height: 100%; object-fit: cover; transition: scale 1.2s var(--ease-out); }
/* No featured image: a branded panel with the official TGL mark, never stock imagery. */
.story__brand {
  position: absolute; inset: 0; display: grid; place-items: center;
  background:
    radial-gradient(60% 80% at 70% 30%, rgb(43 228 255 / 0.14), transparent 60%),
    radial-gradient(70% 90% at 15% 100%, rgb(139 108 255 / 0.16), transparent 60%),
    linear-gradient(160deg, #0f1426, #080a12);
}
.story__brand::before {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(rgb(255 255 255 / 0.035) 1px, transparent 1px) 0 0 / 100% 44px, linear-gradient(90deg, rgb(255 255 255 / 0.035) 1px, transparent 1px) 0 0 / 44px 100%;
  -webkit-mask-image: radial-gradient(70% 70% at 60% 40%, #000, transparent); mask-image: radial-gradient(70% 70% at 60% 40%, #000, transparent);
}
.story__brand img { position: relative; width: clamp(72px, 8vw, 116px); height: auto; transition: scale 1.2s var(--ease-out); }
.story--lead:hover .story__media > img, .story--lead:hover .story__brand img { scale: 1.04; }
.story__body { display: grid; gap: 0.6rem; justify-items: start; }
.story__meta { display: flex; gap: 1rem; margin: 0; font: 600 0.64rem/1 var(--font-hud); letter-spacing: 0.16em; text-transform: uppercase; color: var(--fg-muted); }
.story__meta span { color: var(--accent); }
.story__title { font-size: clamp(1.2rem, 0.6vw + 1rem, 1.5rem); line-height: 1.2; letter-spacing: -0.02em; }
.story--lead .story__title { font-size: clamp(1.6rem, 1.4vw + 1rem, 2.4rem); line-height: 1.1; letter-spacing: -0.03em; }
.story__title a { color: var(--fg); text-decoration: none; background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat; transition: background-size var(--dur) var(--ease-out); }
.story:hover .story__title a { background-size: 100% 1px; }
.story__title a::after { content: ""; position: absolute; inset: 0; } /* whole story is the hit area */
.story__title a:focus-visible { outline: none; }
.story:has(a:focus-visible) { outline: 2px solid var(--accent); outline-offset: 6px; border-radius: var(--radius-lg); }
.story__text { max-width: 60ch; color: var(--text-soft); line-height: 1.65; }
.newsroom__list { display: grid; align-content: start; border-top: 1px solid var(--line); }
.newsroom__list .story { padding: 1.6rem 0; border-bottom: 1px solid var(--line); }
.newsroom__list .story:has(.story__thumb) { grid-template-columns: 7.5rem minmax(0, 1fr); align-items: start; }
.story__thumb { aspect-ratio: 1; overflow: hidden; border-radius: var(--radius); }
.story__thumb img { width: 100%; height: 100%; object-fit: cover; }

/* ---------- Closing invitation: a bookend to the hero (cube above a lit ring), no video ---------- */
.closing {
  overflow: hidden; text-align: center;
  background:
    radial-gradient(46% 55% at 50% 100%, rgb(43 228 255 / 0.09), transparent 70%),
    radial-gradient(36% 45% at 50% 34%, rgb(139 108 255 / 0.07), transparent 70%),
    var(--ink);
}
.closing__inner { display: grid; justify-items: center; gap: 1.4rem; max-width: 880px; }
.closing__emblem { position: relative; display: grid; place-items: center; width: clamp(150px, 15vw, 210px); aspect-ratio: 1; margin-bottom: 0.4rem; }
.closing__emblem::before { content: ""; position: absolute; inset: -20%; background: radial-gradient(closest-side, rgb(43 228 255 / 0.16), transparent 70%); }
.closing__emblem img { position: relative; z-index: 1; width: 56%; height: auto; margin-bottom: 4%; animation: emblem-float 6s var(--ease-in-out) infinite alternate; }
@keyframes emblem-float { to { translate: 0 -8px; } }
.closing__ring {
  position: absolute; left: 50%; bottom: 6%; width: 112%; height: 24%; translate: -50% 0; border-radius: 50%;
  border: 1.5px solid rgb(43 228 255 / 0.72);
  background: radial-gradient(closest-side, rgb(43 228 255 / 0.2), transparent);
  box-shadow: 0 0 18px rgb(43 228 255 / 0.4), inset 0 0 14px rgb(43 228 255 / 0.28);
}
.closing p { max-width: 46ch; color: var(--text-soft); font-size: clamp(1.05rem, 0.4vw + 0.95rem, 1.25rem); line-height: 1.65; }
.closing__cta { margin-top: 0.6rem; }

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
  .showcase__features { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 960px) {
  .showcase__grid, .agenda__grid, .newsroom__grid { grid-template-columns: 1fr; }
  .showcase--cinematic { min-height: 0; }
  .showcase__poster, .showcase__video { object-position: 52% 50%; }
  .showcase--cinematic::before {
    background: linear-gradient(90deg, rgb(3 4 10 / 0.93), rgb(3 4 10 / 0.78)),
      linear-gradient(180deg, rgb(5 5 12 / 0.4), rgb(5 5 12 / 0.3) 35%, rgb(5 5 12 / 0.85));
  }
  .agenda__head { position: static; }
}
@media (max-width: 560px) {
  .showcase__features { grid-template-columns: 1fr; }
  .showcase__actions { display: grid; grid-template-columns: 1fr; width: 100%; }
  .showcase__actions .btn, .closing__cta { justify-content: center; width: 100%; }
  .event { grid-template-columns: 4.25rem minmax(0, 1fr); }
  .event__cta { display: none; }
  .event__day { font-size: 1.7rem; }
}
@media (prefers-reduced-motion: reduce) {
  .showcase__pulse, .closing__emblem img { animation: none; }
  .showcase__video, .story__media > img, .story__brand img, .feature, .feature::before, .event, .event::before, .text-link svg, .event__cta svg, .story__cta svg { transition: none; }
  .story--lead:hover .story__media > img, .story--lead:hover .story__brand img { scale: none; }
}

/* ---------- Grouped navigation (premium phase) ----------
   Disclosure pattern: each group label is a button controlling its panel (interactions.ts keeps
   aria-expanded in sync; hover, outside click and Escape close it). Without JavaScript, hover and
   keyboard focus open the panels. Status words ("Planned", "Preview") are always visible text. */
.nav-groups { display: flex; align-items: center; gap: clamp(0.25rem, 1vw, 1.25rem); margin: 0; padding: 0; list-style: none; }
.nav-group { position: relative; }
.nav-group__toggle {
  position: relative; display: inline-flex; align-items: center; gap: 0.55rem; padding: 12px 8px;
  background: none; border: 0; border-radius: 6px; cursor: pointer; color: var(--fg-muted);
  font: 500 0.74rem/1 var(--font-hud); letter-spacing: 0.18em; text-transform: uppercase; transition: color var(--dur-fast);
}
.nav-group__toggle::after {
  content: ""; position: absolute; left: 50%; right: 50%; bottom: 3px; height: 1px; background: var(--accent); box-shadow: var(--glow);
  transition: left var(--dur) var(--ease-out), right var(--dur) var(--ease-out);
}
.nav-group__toggle:hover, .nav-group.is-open > .nav-group__toggle, .nav-group.is-current > .nav-group__toggle { color: var(--fg); }
.nav-group.is-open > .nav-group__toggle::after, .nav-group.is-current > .nav-group__toggle::after { left: 8px; right: 8px; }
.nav-group__caret { width: 5px; height: 5px; border: solid currentColor; border-width: 0 1px 1px 0; rotate: 45deg; translate: 0 -2px; opacity: 0.75; transition: rotate var(--dur) var(--ease-out), translate var(--dur) var(--ease-out); }
.nav-group.is-open .nav-group__caret { rotate: 225deg; translate: 0 2px; }
/* Lounges keeps its gradient dot as the commercial cue; text colour stays reserved for the current/open group. */
.nav-group--lounges > .nav-group__toggle::before {
  content: ""; width: 6px; height: 6px; border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), var(--violet-glow)); box-shadow: 0 0 10px rgb(43 228 255 / 0.6);
}
.nav-panel__links { display: grid; gap: 2px; margin: 0; padding: 0; list-style: none; }
.nav-link { display: grid; gap: 0.3rem; padding: 0.7rem 0.8rem; border-radius: 10px; text-decoration: none; transition: background var(--dur-fast); }
.nav-link:hover, .nav-link:focus-visible { background: rgb(43 228 255 / 0.07); }
.nav-link[aria-current="page"] { background: rgb(43 228 255 / 0.09); box-shadow: inset 2px 0 0 var(--accent); }
.nav-link__title { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem; color: var(--fg); font: 600 0.92rem/1.25 var(--font-sans); }
.nav-link__desc { color: var(--fg-muted); font: 400 0.8rem/1.4 var(--font-sans); }
.nav-tag {
  padding: 0.28rem 0.45rem; border: 1px solid rgb(139 108 255 / 0.4); border-radius: 999px;
  color: #c9bcff; font: 600 0.55rem/1 var(--font-hud); letter-spacing: 0.14em; text-transform: uppercase;
}
.nav-tag--preview { color: #a6f1ff; border-color: rgb(43 228 255 / 0.35); }
.nav-panel__intro { margin: 0 0 0.4rem; padding: 0.35rem 0.8rem 0.8rem; border-bottom: 1px solid rgb(255 255 255 / 0.06); color: var(--fg-muted); font: 500 0.8rem/1.45 var(--font-sans); }
.nav-feature { display: grid; align-content: start; gap: 0.65rem; padding: 1.1rem; border: 1px solid rgb(255 255 255 / 0.07); border-radius: 12px; }
.nav-feature--lounges { background: radial-gradient(120% 90% at 100% 0%, rgb(139 108 255 / 0.22), transparent 60%), linear-gradient(160deg, rgb(43 228 255 / 0.12), rgb(11 13 24 / 0.6)); }
.nav-feature--aether { background: radial-gradient(110% 90% at 80% 0%, rgb(129 112 242 / 0.28), transparent 65%), rgb(11 15 26 / 0.8); }
.nav-feature--aether img { width: 132px; height: auto; }
.nav-feature__kicker { color: var(--accent); font: 600 0.6rem/1 var(--font-hud); letter-spacing: 0.2em; text-transform: uppercase; }
.nav-feature__title { margin: 0; color: var(--fg); font: 600 1.05rem/1.25 var(--font-display); letter-spacing: -0.01em; }
.nav-feature__text { margin: 0; color: var(--text-soft); font-size: 0.8rem; line-height: 1.5; }

@media (min-width: 961px) {
  .nav-panel {
    position: absolute; z-index: 20; top: calc(100% + 12px); left: 50%; display: flex; gap: 0.75rem;
    width: max-content; max-width: min(660px, calc(100vw - 2 * var(--gutter))); padding: 0.8rem;
    translate: -50% 8px; opacity: 0; visibility: hidden; pointer-events: none;
    background: rgb(11 13 24 / 0.97); backdrop-filter: blur(18px) saturate(140%);
    border: 1px solid rgb(255 255 255 / 0.08); border-radius: 16px;
    box-shadow: 0 30px 60px -24px rgb(0 0 0 / 0.9), inset 0 1px 0 rgb(255 255 255 / 0.05);
    transition: opacity var(--dur-fast), translate var(--dur) var(--ease-out), visibility 0s linear var(--dur-fast);
  }
  .nav-panel::before { content: ""; position: absolute; inset: -16px 0 auto; height: 16px; } /* hover bridge */
  .nav-group.is-open > .nav-panel,
  .no-js .nav-group:hover > .nav-panel, .no-js .nav-group:focus-within > .nav-panel {
    opacity: 1; visibility: visible; pointer-events: auto; translate: -50% 0;
    transition: opacity var(--dur-fast), translate var(--dur) var(--ease-out), visibility 0s;
  }
  /* Edge groups align to their own edge so a panel never leaves the viewport. */
  .nav-group--community > .nav-panel { left: 0; translate: 0 8px; }
  /* Lounges now sits mid-row (Store and Support Us follow More), so its panel centres like Gaming and Aether. */
  .nav-group--more > .nav-panel { left: auto; right: 0; translate: 0 8px; }
  .nav-group--community.is-open > .nav-panel, .nav-group--more.is-open > .nav-panel,
  .no-js .nav-group--community:is(:hover, :focus-within) > .nav-panel,
  .no-js .nav-group--more:is(:hover, :focus-within) > .nav-panel { translate: 0 0; }
  .nav-panel__main { width: 340px; }
  .nav-group--community .nav-panel__main { width: 540px; }
  .nav-group--community .nav-panel__links { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .nav-feature { width: 220px; }
}
/* Compact header between tablet and wide desktop: smaller lockup and spacing keep one row. */
@media (min-width: 961px) and (max-width: 1199px) {
  .site-header .brand .brand__lockup { width: 176px; }
  .nav-groups { gap: 0.15rem; }
  .header-cta { padding-inline: 0.9rem; }
}
@media (max-width: 960px) {
  .nav-groups { flex-direction: column; align-items: stretch; gap: 0; }
  .nav-group { border-bottom: 1px solid var(--line-soft); }
  .nav-group__toggle {
    width: 100%; justify-content: space-between; padding: 20px 2px; color: var(--fg);
    font: 600 1.15rem/1 var(--font-display); letter-spacing: -0.01em; text-transform: none;
  }
  .nav-group--lounges > .nav-group__toggle { justify-content: flex-start; }
  .nav-group--lounges .nav-group__caret { margin-left: auto; }
  .nav-group__toggle::after { display: none; }
  .nav-group__caret { width: 8px; height: 8px; margin-right: 6px; }
  .nav-panel { display: none; padding: 0 0 1rem; }
  .nav-group.is-open > .nav-panel { display: block; }
  .nav-panel__intro, .nav-feature { display: none; }
  .nav-link { padding: 0.8rem 0.6rem; }
}
@media (prefers-reduced-motion: reduce) {
  .nav-panel, .nav-group__caret, .nav-group__toggle::after { transition: none; }
}

/* ---------- Direct top-level links: Store and Support Us ----------
   Always visible, no dropdown. Desktop: compact labels in the nav type, separated from the groups by a
   hairline and marked by a coloured icon, so they read as destinations rather than menus without adding a
   second button beside "Join the Discord". Mobile: two labelled tiles below the groups. */
.nav-direct { display: flex; align-items: center; }
.nav-direct__link {
  --direct-tint: var(--accent);
  position: relative; display: inline-flex; align-items: center; gap: 0.5rem; min-height: 40px; padding: 0 10px;
  border-radius: 999px; color: var(--fg-muted); text-decoration: none;
  font: 500 0.74rem/1 var(--font-hud); letter-spacing: 0.18em; text-transform: uppercase;
  transition: color var(--dur-fast), background var(--dur-fast);
}
.nav-direct--support .nav-direct__link { --direct-tint: var(--violet-glow, #8b6cff); }
.nav-direct__link .icon { flex: none; width: 16px; height: 16px; fill: none; stroke: var(--direct-tint); stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; filter: drop-shadow(0 0 6px color-mix(in srgb, var(--direct-tint) 55%, transparent)); }
.nav-direct--support .nav-direct__link .icon { fill: color-mix(in srgb, var(--direct-tint) 30%, transparent); }
.nav-direct__link::after {
  content: ""; position: absolute; left: 50%; right: 50%; bottom: 3px; height: 1px; background: var(--direct-tint);
  box-shadow: 0 0 8px var(--direct-tint); transition: left var(--dur) var(--ease-out), right var(--dur) var(--ease-out);
}
.nav-direct__link:hover, .nav-direct__link:focus-visible { color: var(--fg); background: color-mix(in srgb, var(--direct-tint) 9%, transparent); }
.nav-direct__link:focus-visible { outline: 2px solid var(--direct-tint); outline-offset: 2px; }
.nav-direct__link[aria-current="page"] { color: var(--fg); }
.nav-direct__link[aria-current="page"]::after { left: 12px; right: 12px; }
.nav-direct__meta { display: none; }

@media (min-width: 961px) {
  .nav-direct--first { margin-left: clamp(0.15rem, 0.6vw, 0.6rem); padding-left: clamp(0.4rem, 1vw, 1.1rem); border-left: 1px solid rgb(255 255 255 / 0.12); }
}
/* One row at every desktop width: nothing wraps, and spacing tightens in tiers as the row narrows. */
.nav-direct__link, .nav-group__toggle, .header-cta { white-space: nowrap; }
@media (min-width: 961px) and (max-width: 1365px) {
  .site-header .brand .brand__lockup { width: 176px; }
  .nav-groups { gap: 0.1rem; }
  .nav-group__toggle { padding-inline: 6px; letter-spacing: 0.14em; }
  .nav-direct__link { gap: 0.4rem; padding-inline: 7px; letter-spacing: 0.14em; }
  .header-cta { padding-inline: 0.9rem; }
}
/* Narrow desktop: tighter type and a short CTA label ("Discord"; its accessible name stays "Join the Discord"). */
@media (min-width: 961px) and (max-width: 1199px) {
  .nav-group__toggle, .nav-direct__link { font-size: 0.68rem; letter-spacing: 0.11em; }
  .nav-direct--first { margin-left: 0.15rem; padding-left: 0.45rem; }
  .header-cta__long { display: none; }
}
@media (min-width: 961px) and (max-width: 1099px) {
  .nav-group__toggle, .nav-direct__link { font-size: 0.64rem; letter-spacing: 0.08em; }
  .nav-group__toggle { gap: 0.3rem; padding-inline: 5px; }
  .nav-direct__link { gap: 0.3rem; padding-inline: 5px; }
  .site-header .brand .brand__lockup { width: 160px; }
}
@media (max-width: 960px) {
  .nav-groups { flex-flow: row wrap; }
  .nav-group { flex: 1 1 100%; }
  .nav-direct { flex: 1 1 calc(50% - 0.4rem); margin-top: 1.25rem; }
  .nav-direct + .nav-direct { margin-left: 0.8rem; }
  .nav-direct__link {
    display: grid; grid-template-columns: auto 1fr; align-items: center; gap: 0.35rem 0.65rem; width: 100%; min-height: 0; padding: 1rem;
    border: 1px solid color-mix(in srgb, var(--direct-tint) 35%, var(--line)); border-radius: 14px; color: var(--fg);
    background: radial-gradient(120% 120% at 0% 0%, color-mix(in srgb, var(--direct-tint) 14%, transparent), transparent 70%), rgb(255 255 255 / 0.02);
    font: 600 1.05rem/1.15 var(--font-display); letter-spacing: -0.01em; text-transform: none;
  }
  .nav-direct__link .icon { width: 22px; height: 22px; }
  .nav-direct__link::after { display: none; }
  .nav-direct__link[aria-current="page"] { box-shadow: inset 0 0 0 1px var(--direct-tint); }
  .nav-direct__meta { grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center; gap: 0.4rem; color: var(--fg-muted); font: 400 0.8rem/1.35 var(--font-sans); }
}
@media (max-width: 359px) {
  .nav-direct { flex-basis: 100%; }
  .nav-direct + .nav-direct { margin-left: 0; margin-top: 0.75rem; }
}
@media (prefers-reduced-motion: reduce) {
  .nav-direct__link, .nav-direct__link::after { transition: none; }
}
@media (forced-colors: active) {
  .nav-direct__link[aria-current="page"] { outline: 2px solid CanvasText; }
}

/* ---------- Footer sitemap (premium phase) ---------- */
.site-footer--sitemap { padding-block: clamp(3.5rem, 6vw, 5.5rem) 2rem; background: linear-gradient(180deg, var(--ink), #05060b); }
.site-footer--sitemap .container { grid-template-columns: minmax(0, 1.2fr) minmax(0, 3fr); gap: clamp(2.5rem, 5vw, 5rem); }
.site-footer__brand { display: grid; align-content: start; justify-items: start; gap: 1.25rem; }
.site-footer__about { max-width: 36ch; margin: 0; color: var(--fg-muted); font-size: 0.92rem; line-height: 1.65; }
.site-footer__contact { margin: 0; color: var(--fg-muted); }
.site-footer__contact a { color: var(--accent); }
.site-footer__map { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 2rem 1.5rem; }
.site-footer__heading { margin: 0 0 1.1rem; color: var(--fg); font: 600 0.68rem/1 var(--font-hud); letter-spacing: 0.2em; text-transform: uppercase; }
.site-footer__group ul { gap: 0.75rem; }
.site-footer__group a { color: var(--fg-muted); font-size: 0.9rem; line-height: 1.35; }
.site-footer__group a:hover { color: var(--accent); }
.site-footer__group a[aria-current="page"] { color: var(--fg); }
.site-footer--sitemap .site-footer__legal { margin-top: 0.5rem; }
@media (max-width: 1100px) {
  .site-footer--sitemap .container { grid-template-columns: 1fr; }
  .site-footer__map { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 560px) {
  .site-footer__map { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
