/* ==========================================================================
   Sinesters Studios — studio site and game pages
   The studio theme is deep space with cyan and violet light. Each game page
   swaps the accent tokens for its own palette (see .theme-orions).
   ========================================================================== */

:root {
  --bg: #04060f;
  --bg-2: #0a0d24;
  --bg-3: #141a44;
  --panel: rgba(14, 18, 48, 0.6);
  --panel-solid: #0c1030;
  --line: rgba(150, 160, 255, 0.14);
  --line-strong: rgba(150, 160, 255, 0.32);
  --text: #e8eaff;
  --muted: #a0a5cf;
  --white: #ffffff;
  --accent: #9d8cff;
  --accent-2: #6fe3ff;
  --accent-ink: #0a0722;
  --accent-grad: linear-gradient(120deg, #6fe3ff 0%, #9d8cff 55%, #d08cff 100%);
  --glow: rgba(140, 120, 255, 0.45);
  --eyebrow: #7fe3ff;
  --nebula-a: rgba(111, 227, 255, 0.1);
  --nebula-b: rgba(157, 140, 255, 0.16);
  --nebula-c: rgba(208, 140, 255, 0.1);
  --story: #f3b53f;
  --infinite: #45b8ff;
  --versus: #b07cff;
  --radius: 16px;
  --maxw: 1200px;
  --header-h: 66px;
  --bar-h: 58px;
  --font-display: "Rajdhani", "Segoe UI", system-ui, sans-serif;
  --font-body: "Inter", "Segoe UI", system-ui, -apple-system, sans-serif;
}

/* Orion's Reach palette: night-navy station, electric-blue planet, gold from the logo. */
.theme-orions {
  --bg: #050913;
  --bg-2: #09112a;
  --bg-3: #0f1b3d;
  --panel: rgba(11, 21, 48, 0.68);
  --line: rgba(110, 160, 255, 0.16);
  --line-strong: rgba(110, 160, 255, 0.34);
  --muted: #9aa8cc;
  --accent: #f3b53f;
  --accent-2: #ffd27a;
  --accent-ink: #1b1203;
  --accent-grad: linear-gradient(180deg, #ffd27a, #f3b53f);
  --glow: rgba(243, 181, 63, 0.38);
  --eyebrow: #f3b53f;
  --nebula-a: rgba(63, 140, 255, 0.14);
  --nebula-b: rgba(63, 100, 255, 0.1);
  --nebula-c: rgba(243, 181, 63, 0.06);
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 1rem); }
html.has-bar { scroll-padding-top: calc(var(--header-h) + var(--bar-h) + 1rem); }

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.65;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img, video { max-width: 100%; height: auto; display: block; }
[hidden] { display: none !important; }
a { color: var(--accent-2); text-decoration: none; }
a:hover { color: var(--white); }
:focus-visible { outline: 2px solid var(--accent-2); outline-offset: 3px; }

.container { width: min(100% - 2.5rem, var(--maxw)); margin-inline: auto; }

h1, h2, h3 { font-family: var(--font-display); font-weight: 700; letter-spacing: 0.03em; line-height: 1.1; margin: 0 0 0.6em; color: var(--white); }
h2 { font-size: clamp(2rem, 4.2vw, 3.1rem); text-transform: uppercase; }
h3 { font-size: 1.35rem; letter-spacing: 0.04em; }

.eyebrow {
  display: flex; align-items: center; gap: 0.75rem;
  font-family: var(--font-display); font-weight: 600;
  font-size: 0.85rem; letter-spacing: 0.3em; text-transform: uppercase;
  color: var(--eyebrow); margin: 0 0 0.9rem;
}
.eyebrow::before { content: ""; width: 30px; height: 2px; flex: none; background: linear-gradient(90deg, var(--eyebrow), transparent); }
.eyebrow.center { justify-content: center; }
.eyebrow.center::after { content: ""; width: 30px; height: 2px; flex: none; background: linear-gradient(270deg, var(--eyebrow), transparent); }

.gradient-text { background: var(--accent-grad); -webkit-background-clip: text; background-clip: text; color: transparent; }

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; border: 0;
}

.skip { position: absolute; left: -999px; top: 0; background: var(--accent); color: var(--accent-ink); padding: 0.5rem 1rem; z-index: 100; }
.skip:focus { left: 1rem; top: 1rem; }

/* ---------------- Space backdrop ----------------
   A drifting nebula (CSS) under a canvas starfield drawn by main.js.
   Without JavaScript a few CSS stars stand in for the canvas.            */
.nebula {
  position: fixed; inset: -15%; z-index: -10; pointer-events: none;
  background:
    radial-gradient(ellipse 38% 30% at 15% 18%, var(--nebula-a), transparent 70%),
    radial-gradient(ellipse 45% 36% at 88% 34%, var(--nebula-b), transparent 70%),
    radial-gradient(ellipse 55% 40% at 45% 100%, var(--nebula-c), transparent 70%),
    var(--bg);
  animation: nebula-drift 70s ease-in-out infinite alternate;
}
.nebula::after {
  content: ""; position: absolute; inset: 0;
  background-image:
    radial-gradient(1px 1px at 20% 30%, rgba(255,255,255,0.7) 50%, transparent 51%),
    radial-gradient(1px 1px at 60% 70%, rgba(255,255,255,0.5) 50%, transparent 51%),
    radial-gradient(1.5px 1.5px at 80% 20%, rgba(190,215,255,0.8) 50%, transparent 51%),
    radial-gradient(1px 1px at 40% 85%, rgba(255,255,255,0.6) 50%, transparent 51%),
    radial-gradient(1.5px 1.5px at 10% 75%, rgba(200,180,255,0.7) 50%, transparent 51%);
  background-size: 420px 420px, 560px 560px, 700px 700px, 380px 380px, 500px 500px;
  opacity: 0.5;
}
.js .nebula::after { display: none; }
.starfield { position: fixed; inset: 0; width: 100%; height: 100%; z-index: -9; pointer-events: none; }
@keyframes nebula-drift { from { transform: translate3d(-2%, -1%, 0) scale(1); } to { transform: translate3d(2%, 1.5%, 0) scale(1.06); } }

/* ---------------- Header ---------------- */
.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 60;
  height: var(--header-h); display: flex; align-items: center;
  background: transparent; border-bottom: 1px solid transparent;
  transition: background 0.3s, border-color 0.3s;
}
.site-header.scrolled, .site-header.solid {
  background: rgba(4, 6, 15, 0.82);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-bottom-color: var(--line);
}
.nav { display: flex; align-items: center; justify-content: space-between; gap: 1rem; position: relative; }
.brand {
  display: inline-flex; align-items: center; gap: 0.7rem;
  font-family: var(--font-display); font-weight: 700; font-size: 1.1rem;
  letter-spacing: 0.26em; text-transform: uppercase; color: var(--white);
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.7);
}
.brand img { width: 34px; height: auto; filter: drop-shadow(0 0 10px rgba(140, 200, 255, 0.35)); transition: transform 0.6s ease; }
.brand:hover img { transform: rotate(-20deg) scale(1.06); }
.brand small { font-size: inherit; font-weight: 500; color: var(--muted); }
.brand:hover { color: var(--white); }

.nav-links { display: flex; align-items: center; gap: 1.7rem; list-style: none; margin: 0; padding: 0; }
.nav-links > li > a, .menu-btn {
  font-family: var(--font-display); font-weight: 600; font-size: 1rem;
  letter-spacing: 0.12em; text-transform: uppercase; color: var(--text);
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.8);
}
.nav-links > li > a:hover, .nav-links > li > a[aria-current="page"], .menu-btn:hover, .has-menu.open .menu-btn { color: var(--white); }
.nav-links > li > a[aria-current="page"] { box-shadow: 0 2px 0 var(--accent-2); }
.nav-links .btn { text-shadow: none; }
.menu-btn { display: inline-flex; align-items: center; gap: 0.35rem; background: none; border: 0; padding: 0; cursor: pointer; }
.menu-btn svg { width: 14px; height: 14px; transition: transform 0.25s; }
.has-menu { position: relative; }
.has-menu.open .menu-btn svg { transform: rotate(180deg); }
.submenu {
  position: absolute; top: calc(100% + 1rem); left: 50%; z-index: 5;
  width: 320px; padding: 0.55rem; border-radius: var(--radius);
  background: rgba(10, 13, 36, 0.96); border: 1px solid var(--line-strong);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.55);
  opacity: 0; visibility: hidden; transform: translate(-50%, 8px);
  transition: opacity 0.2s, transform 0.2s, visibility 0.2s;
}
.submenu::before { content: ""; position: absolute; left: 0; right: 0; top: -1rem; height: 1rem; }
.has-menu.open .submenu { opacity: 1; visibility: visible; transform: translate(-50%, 0); }
@media (hover: hover) and (min-width: 1101px) {
  .has-menu:hover .submenu, .has-menu:focus-within .submenu { opacity: 1; visibility: visible; transform: translate(-50%, 0); }
  .has-menu:hover .menu-btn svg { transform: rotate(180deg); }
}
.submenu-label { display: block; padding: 0.4rem 0.7rem 0.5rem; font-family: var(--font-display); font-weight: 600; font-size: 0.75rem; letter-spacing: 0.24em; text-transform: uppercase; color: var(--muted); }
.submenu-item { display: flex; align-items: center; gap: 0.85rem; padding: 0.6rem 0.7rem; border-radius: 10px; color: var(--text); transition: background 0.2s; }
a.submenu-item:hover { background: rgba(150, 160, 255, 0.1); color: var(--white); }
.submenu-item img { width: 42px; height: 63px; object-fit: cover; border-radius: 6px; flex: none; box-shadow: 0 6px 16px rgba(0, 0, 0, 0.5); }
.submenu-item strong { display: block; font-family: var(--font-display); font-size: 1.05rem; letter-spacing: 0.06em; text-transform: uppercase; color: var(--white); }
.submenu-item small { display: block; font-size: 0.8rem; color: var(--muted); }
.submenu-item.is-locked { opacity: 0.75; cursor: default; }
.lock-thumb {
  width: 42px; height: 63px; flex: none; border-radius: 6px; position: relative; overflow: hidden;
  background: radial-gradient(circle at 50% 120%, rgba(63, 214, 160, 0.35), transparent 60%), #061620;
  box-shadow: inset 0 0 0 1px rgba(127, 240, 196, 0.25);
}
.lock-thumb::after {
  content: ""; position: absolute; left: 50%; top: 50%; width: 28px; height: 28px; margin: -14px 0 0 -14px; border-radius: 50%;
  background: radial-gradient(circle at 36% 32%, #a6ffd9 0%, #35c99a 30%, #0f6a62 62%, #04161b 100%);
  box-shadow: 0 0 12px rgba(63, 214, 160, 0.55);
}

.nav-toggle { display: none; background: rgba(4, 6, 15, 0.55); border: 1px solid var(--line-strong); border-radius: 8px; color: var(--white); padding: 0.45rem 0.6rem; cursor: pointer; }
.nav-toggle svg { display: block; }

@media (max-width: 1100px) {
  .nav-toggle { display: inline-flex; }
  .nav-links {
    position: absolute; top: calc(100% + 0.7rem); right: 0; left: 0;
    flex-direction: column; align-items: stretch; gap: 0;
    max-height: calc(100svh - var(--header-h) - 1.5rem); overflow-y: auto;
    background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius);
    padding: 0.6rem; display: none;
  }
  .nav-links.open { display: flex; }
  .nav-links > li { padding: 0.55rem 0.8rem; }
  .nav-links > li:has(> .btn) { padding-top: 0.9rem; border-top: 1px solid var(--line); }
  .nav-links .btn { width: 100%; justify-content: center; }
  .menu-btn { pointer-events: none; }
  .menu-btn svg { display: none; }
  .submenu { position: static; width: auto; margin-top: 0.4rem; padding: 0; background: none; border: 0; box-shadow: none; opacity: 1; visibility: visible; transform: none; }
  .submenu-label { display: none; }
}
@media (max-width: 420px) { .brand small { display: none; } }

/* ---------------- Buttons ---------------- */
.btn {
  position: relative; display: inline-flex; align-items: center; gap: 0.6rem;
  padding: 0.85rem 1.45rem; border-radius: 8px;
  font-family: var(--font-display); font-weight: 700; font-size: 1.02rem;
  letter-spacing: 0.12em; text-transform: uppercase; line-height: 1.2;
  border: 1px solid transparent; cursor: pointer; overflow: hidden;
  transition: transform 0.2s, box-shadow 0.2s, background 0.2s, border-color 0.2s, filter 0.2s;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--accent-grad); color: var(--accent-ink); border-color: rgba(255, 255, 255, 0.25); box-shadow: 0 10px 30px -12px var(--glow); }
.btn-primary::after {
  content: ""; position: absolute; top: 0; bottom: 0; left: -60%; width: 40%;
  background: linear-gradient(100deg, transparent, rgba(255, 255, 255, 0.45), transparent);
  transform: skewX(-20deg); transition: left 0.6s ease;
}
.btn-primary:hover { color: var(--accent-ink); filter: brightness(1.06); box-shadow: 0 14px 38px -10px var(--glow); }
.btn-primary:hover::after { left: 130%; }
.btn-ghost { border-color: var(--line-strong); color: var(--white); background: rgba(4, 6, 15, 0.45); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }
.btn-ghost:hover { border-color: var(--accent-2); background: rgba(150, 160, 255, 0.12); color: var(--white); }
.btn-sm { padding: 0.5rem 0.95rem; font-size: 0.88rem; }
.btn svg { width: 18px; height: 18px; flex: none; }
.btn .arrow { transition: transform 0.2s; }
.btn:hover .arrow { transform: translateX(4px); }

/* ---------------- Shared blocks ---------------- */
.section { padding: 7rem 0; position: relative; }
.section-alt { background: linear-gradient(180deg, transparent 0%, rgba(10, 13, 36, 0.65) 50%, transparent 100%); }
.section-head { max-width: 66ch; margin-bottom: 3.2rem; }
.section-head.center { text-align: center; margin-inline: auto; }
.section-head p { color: var(--muted); margin: 0; }
@media (max-width: 700px) { .section { padding: 4.8rem 0; } .section-head { margin-bottom: 2.2rem; } }
.lead { font-size: 1.14rem; color: var(--white); }
.chips { display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 0 0 1.6rem; padding: 0; list-style: none; }
.chips li { font-size: 0.78rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--accent-2); border: 1px solid var(--line-strong); border-radius: 999px; padding: 0.3rem 0.8rem; background: rgba(4, 6, 15, 0.35); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 0.9rem; }
.status-badge {
  display: inline-flex; align-items: center; gap: 0.55rem; padding: 0.4rem 0.85rem; border-radius: 999px;
  font-family: var(--font-display); font-weight: 700; font-size: 0.82rem; letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--accent-2); background: rgba(4, 6, 15, 0.6); border: 1px solid var(--line-strong);
}
.status-badge::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--accent-2); box-shadow: 0 0 0 0 var(--accent-2); animation: ping 2s ease-out infinite; }
@keyframes ping { 0% { box-shadow: 0 0 0 0 var(--accent-2); } 70% { box-shadow: 0 0 0 8px transparent; } 100% { box-shadow: 0 0 0 0 transparent; } }

/* Tilt + glare (driven by main.js on devices with a mouse) */
[data-tilt] { transform: perspective(1100px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)); transition: transform 0.4s ease; }
[data-tilt].tilting { transition: transform 0.08s linear; }
.glare { position: absolute; inset: 0; pointer-events: none; border-radius: inherit; opacity: 0; transition: opacity 0.3s; background: radial-gradient(circle at var(--mx, 50%) var(--my, 50%), rgba(255, 255, 255, 0.12), transparent 45%); }
.tilting .glare { opacity: 1; }

/* ---------------- Studio hero ---------------- */
.studio-hero {
  position: relative; isolation: isolate; overflow: hidden;
  min-height: max(640px, 100svh); display: grid; place-items: center;
  padding: calc(var(--header-h) + 3rem) 0 6rem; text-align: center;
}
.studio-hero-inner { position: relative; z-index: 2; }
.studio-hero .eyebrow { margin-bottom: 1.6rem; }
.studio-tagline { font-family: var(--font-display); font-weight: 600; font-size: clamp(1.5rem, 3.2vw, 2.3rem); line-height: 1.2; letter-spacing: 0.04em; color: var(--white); margin: 1.6rem auto 0.8rem; max-width: 24ch; }
.studio-sub { color: var(--muted); max-width: 46ch; margin: 0 auto 2.2rem; font-size: 1.05rem; }
.studio-hero .hero-actions { justify-content: center; }

/* Animated logo: each piece of the mark comes in, then the star keeps twinkling. */
.logo-anim { position: relative; display: inline-block; margin: 0; line-height: 0; }
.logo-anim svg { width: min(520px, 78vw); height: auto; overflow: visible; animation: float 8s 3.4s ease-in-out infinite; }
.logo-anim path { transform-box: fill-box; transform-origin: center; }
.logo-anim #star { animation: la-pop 0.9s 0.15s both cubic-bezier(0.2, 0.9, 0.3, 1.35), la-twinkle 3.4s 2.6s ease-in-out infinite; }
.logo-anim #S_top, .logo-anim #S_upper { animation: la-in-tr 1s 0.55s both cubic-bezier(0.2, 0.8, 0.2, 1); }
.logo-anim #S_mid, .logo-anim #S_bot { animation: la-in-bl 1s 0.55s both cubic-bezier(0.2, 0.8, 0.2, 1); }
.logo-anim #orbit_left, .logo-anim #orbit_right { animation: la-orbit 1.1s 1.15s both ease-out; }
.logo-anim #dot_a, .logo-anim #dot_b { animation: la-pop 0.6s 1.75s both cubic-bezier(0.2, 0.9, 0.3, 1.4), la-dot 2.8s 2.6s ease-in-out infinite; }
.logo-anim #dot_b { animation-delay: 1.85s, 3.4s; }
.logo-anim #wordmark path { animation: la-up 0.6s both ease-out; animation-delay: 1.95s; }
.logo-anim #wordmark path:nth-child(2) { animation-delay: 2.01s; }
.logo-anim #wordmark path:nth-child(3) { animation-delay: 2.07s; }
.logo-anim #wordmark path:nth-child(4) { animation-delay: 2.13s; }
.logo-anim #wordmark path:nth-child(5) { animation-delay: 2.19s; }
.logo-anim #wordmark path:nth-child(6) { animation-delay: 2.25s; }
.logo-anim #wordmark path:nth-child(7) { animation-delay: 2.31s; }
.logo-anim #wordmark path:nth-child(8) { animation-delay: 2.37s; }
.logo-anim #wordmark path:nth-child(9) { animation-delay: 2.43s; }
.logo-anim #studios path { animation: la-fade 0.7s 2.6s both ease-out; }
.logo-anim #line_l, .logo-anim #line_r { animation: la-line 0.8s 2.6s both ease-out; }
.logo-flare {
  position: absolute; left: 49.7%; top: 39%; width: 50%; aspect-ratio: 1; pointer-events: none;
  transform: translate(-50%, -50%);
  background: radial-gradient(circle, rgba(190, 240, 255, 0.85) 0%, rgba(140, 120, 255, 0.32) 24%, transparent 62%);
  mix-blend-mode: screen; animation: flare 1.6s 0.1s both ease-out, flare-pulse 4.5s 2.8s ease-in-out infinite;
}
.logo-flare::after {
  content: ""; position: absolute; left: -45%; right: -45%; top: 50%; height: 2px; margin-top: -1px;
  background: linear-gradient(90deg, transparent, rgba(210, 245, 255, 0.95), transparent);
  animation: flare-line 1.8s 0.15s both ease-out;
}
@keyframes la-pop { 0% { opacity: 0; transform: scale(0); } 60% { opacity: 1; transform: scale(1.35); } 100% { opacity: 1; transform: scale(1); } }
@keyframes la-twinkle { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.18) rotate(8deg); } }
@keyframes la-in-tr { from { opacity: 0; transform: translate(46px, -46px); } to { opacity: 1; transform: none; } }
@keyframes la-in-bl { from { opacity: 0; transform: translate(-46px, 46px); } to { opacity: 1; transform: none; } }
@keyframes la-orbit { from { opacity: 0; transform: scale(0.55) rotate(-30deg); } to { opacity: 1; transform: none; } }
@keyframes la-dot { 0%, 100% { opacity: 1; } 50% { opacity: 0.45; } }
@keyframes la-up { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: none; } }
@keyframes la-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes la-line { from { transform: scaleX(0); } to { transform: scaleX(1); } }
@keyframes flare { 0% { opacity: 0; transform: translate(-50%, -50%) scale(0.2); } 30% { opacity: 1; transform: translate(-50%, -50%) scale(1.25); } 100% { opacity: 0.32; transform: translate(-50%, -50%) scale(0.85); } }
@keyframes flare-pulse { 0%, 100% { opacity: 0.32; } 50% { opacity: 0.55; } }
@keyframes flare-line { 0% { opacity: 0; transform: scaleX(0.1); } 25% { opacity: 1; transform: scaleX(1); } 100% { opacity: 0; transform: scaleX(0.6); } }
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }

/* Spiral galaxy canvas behind the logo (drawn by main.js) */
.galaxy { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none; }
.studio-hero .galaxy { opacity: 0.95; }
.studio-hero-inner { z-index: 2; }

/* Orbits around the logo's star: circles tilted in 3D, each with a little moon. */
.orbits { position: absolute; left: 49.7%; top: 39%; width: min(980px, 140vw); aspect-ratio: 1; transform: translate(-50%, -50%); perspective: 1400px; pointer-events: none; z-index: 0; display: block; }
.logo-anim svg { position: relative; z-index: 1; }
.logo-flare { z-index: 2; }
.orbits-plane { position: absolute; inset: 0; transform: rotateX(64deg) rotateZ(-16deg); transform-style: preserve-3d; display: block; }
.logo-anim svg { filter: drop-shadow(0 0 18px rgba(4, 6, 15, 0.55)); }
.orbit { position: absolute; inset: 0; margin: auto; display: block; border-radius: 50%; border: 1px solid rgba(160, 190, 255, 0.13); animation: spin 60s linear infinite; }
.orbit::before { content: ""; position: absolute; top: -5px; left: 50%; width: 10px; height: 10px; margin-left: -5px; border-radius: 50%; background: var(--accent-2); box-shadow: 0 0 14px 4px rgba(111, 227, 255, 0.55); }
.orbit-1 { width: 56%; height: 56%; animation-duration: 38s; }
.orbit-2 { width: 78%; height: 78%; animation-duration: 64s; animation-direction: reverse; border-style: dashed; }
.orbit-2::before { background: #d08cff; box-shadow: 0 0 14px 4px rgba(208, 140, 255, 0.5); width: 7px; height: 7px; margin-left: -3.5px; top: -3.5px; }
.orbit-3 { width: 100%; height: 100%; animation-duration: 110s; border-color: rgba(160, 190, 255, 0.07); }
.orbit-3::before { background: #ffd27a; box-shadow: 0 0 12px 3px rgba(255, 210, 122, 0.45); width: 6px; height: 6px; margin-left: -3px; top: -3px; }
@keyframes spin { to { transform: rotate(360deg); } }


@media (max-width: 700px) {
  .studio-hero .eyebrow { font-size: 0.74rem; letter-spacing: 0.18em; }
  .studio-hero .eyebrow::before, .studio-hero .eyebrow::after { display: none; }
}

/* ---------------- Games (studio page) ---------------- */
.game-feature {
  position: relative; isolation: isolate; overflow: hidden;
  min-height: 540px; display: flex; align-items: center;
  border-radius: 22px; border: 1px solid var(--line-strong);
  box-shadow: 0 40px 100px -30px rgba(0, 0, 0, 0.8), 0 0 80px -30px var(--glow);
}
.game-feature-media { position: absolute; inset: 0; z-index: -2; }
.game-feature-media img { width: 100%; height: 100%; object-fit: cover; object-position: 66% 50%; transform: scale(1.02); transition: transform 1.2s ease; }
.game-feature:hover .game-feature-media img { transform: scale(1.07); }
.game-feature::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(90deg, rgba(5, 9, 19, 0.95) 0%, rgba(5, 9, 19, 0.78) 34%, rgba(5, 9, 19, 0.1) 64%, transparent 80%), linear-gradient(0deg, rgba(5, 9, 19, 0.7), transparent 40%);
}
.game-feature-body { position: relative; padding: 3rem clamp(1.5rem, 4vw, 3.5rem); max-width: 600px; }
.game-feature-logo { margin: 1.3rem 0 1rem; }
.game-feature-logo img { width: min(440px, 100%); height: auto; filter: drop-shadow(0 10px 24px rgba(0, 0, 0, 0.6)); }
.game-feature-tag { font-size: 1.12rem; color: var(--white); max-width: 38ch; margin: 0 0 1.2rem; }

.games-row { display: grid; grid-template-columns: 1.4fr 1fr; gap: 1.4rem; margin-top: 1.4rem; }
.game-next, .game-slot { position: relative; overflow: hidden; border-radius: 22px; border: 1px solid var(--line); background: var(--panel); }
.game-next { display: grid; grid-template-columns: 220px 1fr; gap: 2rem; align-items: center; padding: 2.4rem; min-height: 300px; }
.game-next h3 { font-size: 1.8rem; text-transform: uppercase; margin-bottom: 0.4rem; }
.game-next p { color: var(--muted); margin: 0 0 1.2rem; }
.game-next .chips { margin-bottom: 0; }
.game-next .chips li { color: #7ff0c4; border-color: rgba(127, 240, 196, 0.35); }
.game-next .status-badge { color: #7ff0c4; margin-bottom: 1rem; }
.game-next .status-badge::before { background: #7ff0c4; animation-name: ping-green; }
@keyframes ping-green { 0% { box-shadow: 0 0 0 0 rgba(127, 240, 196, 0.8); } 70% { box-shadow: 0 0 0 8px transparent; } 100% { box-shadow: 0 0 0 0 transparent; } }
/* Rotating alien planet (canvas drawn by main.js) with a moon on a tilted orbit.
   Everything shares one 3D context so the moon really passes behind the planet. */
.alien { position: relative; width: 210px; aspect-ratio: 1; margin: auto; transform-style: preserve-3d; perspective: 700px; }
.alien-planet {
  position: absolute; inset: 14%; width: 72%; height: 72%; border-radius: 50%;
  background: radial-gradient(circle at 38% 36%, #6fe0b6, #0f6a62 55%, #04161b 90%);
  box-shadow: 0 0 50px 4px rgba(63, 214, 160, 0.38), 0 0 120px rgba(63, 214, 160, 0.15);
  transform: translateZ(0);
}
.js .alien-planet { background: none; }
.alien-orbit { position: absolute; inset: -2%; transform: rotateX(74deg) rotateZ(-24deg); transform-style: preserve-3d; pointer-events: none; }
.alien-orbit::before { content: ""; position: absolute; inset: 0; border-radius: 50%; border: 1px dashed rgba(127, 240, 196, 0.45); }
.alien-orbit i { position: absolute; inset: 0; transform-style: preserve-3d; animation: spin 9s linear infinite; }
.alien-orbit i::before {
  content: ""; position: absolute; left: 50%; top: -9px; width: 18px; height: 18px; margin-left: -9px; border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #fff6e0, #c9b48a 45%, #3a2f1f 100%);
  box-shadow: 0 0 12px rgba(255, 230, 180, 0.4);
  transform: rotateX(-74deg);
}
.alien::after { content: ""; position: absolute; inset: -8%; border-radius: 50%; background: conic-gradient(from 0deg, transparent 0 80%, rgba(127, 240, 196, 0.3) 92%, transparent 100%); animation: spin 6s linear infinite; -webkit-mask: radial-gradient(circle, transparent 60%, #000 61%); mask: radial-gradient(circle, transparent 60%, #000 61%); pointer-events: none; }
.redacted { display: inline-block; height: 0.95em; vertical-align: -0.1em; border-radius: 3px; background: rgba(160, 165, 207, 0.35); }
.redacted.w1 { width: 5.5em; } .redacted.w2 { width: 3.5em; } .redacted.w3 { width: 7em; }
.stamp {
  position: absolute; right: 1.4rem; top: 1.3rem; padding: 0.25rem 0.7rem; border: 2px solid rgba(255, 110, 110, 0.6); border-radius: 6px;
  font-family: var(--font-display); font-weight: 700; font-size: 0.85rem; letter-spacing: 0.3em; color: rgba(255, 130, 130, 0.8); transform: rotate(6deg);
}
.game-slot { display: flex; flex-direction: column; justify-content: center; padding: 2.4rem; border-style: dashed; border-color: var(--line-strong); background: rgba(10, 13, 36, 0.35); }
.game-slot h3 { font-size: 1.5rem; text-transform: uppercase; }
.game-slot p { color: var(--muted); margin: 0 0 1.4rem; }
.slot-links { display: flex; flex-wrap: wrap; gap: 0.7rem; }

@media (max-width: 960px) {
  .games-row { grid-template-columns: 1fr; }
}
@media (max-width: 700px) {
  .game-feature { min-height: 0; align-items: flex-end; }
  .game-feature-media { position: relative; inset: auto; height: 240px; }
  .game-feature { flex-direction: column; align-items: stretch; }
  .game-feature::before { background: linear-gradient(180deg, transparent 0, transparent 140px, rgba(5, 9, 19, 0.96) 240px, rgba(5, 9, 19, 0.98) 100%); }
  .game-feature-body { padding: 0 1.4rem 1.8rem; margin-top: -3.5rem; }
  .game-next { grid-template-columns: 1fr; text-align: left; padding: 2rem 1.5rem; }
  .alien { width: 150px; margin: 0; }
}

/* ---------------- About (studio page) ---------------- */
.about-grid { display: grid; grid-template-columns: 1.05fr 1fr; gap: 4rem; align-items: start; }
.about-text p { color: var(--text); }
.pillars { display: grid; gap: 1.1rem; }
.pillar { position: relative; overflow: hidden; display: grid; grid-template-columns: 54px 1fr; gap: 1.1rem; align-items: start; padding: 1.5rem; border-radius: var(--radius); background: var(--panel); border: 1px solid var(--line); transition: border-color 0.25s, translate 0.25s; }
.pillar:hover { border-color: var(--line-strong); translate: 6px 0; }
.pillar .icon { width: 54px; height: 54px; display: grid; place-items: center; border-radius: 14px; background: linear-gradient(135deg, rgba(111, 227, 255, 0.18), rgba(157, 140, 255, 0.18)); color: var(--accent-2); }
.pillar .icon svg { width: 26px; height: 26px; }
.pillar h3 { margin-bottom: 0.3rem; }
.pillar p { margin: 0; color: var(--muted); font-size: 0.96rem; }
.origins { display: flex; gap: 1.4rem; align-items: center; margin-top: 2rem; padding: 1.2rem; border-radius: var(--radius); background: var(--panel); border: 1px solid var(--line); }
.origins img { width: 104px; flex: none; border-radius: 6px; box-shadow: 0 12px 30px rgba(0, 0, 0, 0.6); }
.origins p { margin: 0 0 0.9rem; font-size: 0.95rem; color: var(--muted); }
.origins strong { color: var(--white); font-weight: 600; }
@media (max-width: 900px) { .about-grid { grid-template-columns: 1fr; gap: 2.8rem; } }
@media (max-width: 520px) { .origins { flex-direction: column; align-items: flex-start; } }

/* ---------------- Connect (studio page) ---------------- */
.connect-grid { display: grid; gap: 1.3rem; grid-template-columns: repeat(3, 1fr); }
.connect-card { position: relative; overflow: hidden; display: flex; flex-direction: column; padding: 2rem; border-radius: 20px; background: var(--panel); border: 1px solid var(--line); }
.connect-card::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 2px; background: var(--accent-grad); opacity: 0.7; }
.connect-card .icon { width: 50px; height: 50px; display: grid; place-items: center; border-radius: 14px; background: rgba(150, 160, 255, 0.12); color: var(--accent-2); margin-bottom: 1.2rem; }
.connect-card .icon svg { width: 24px; height: 24px; }
.connect-card h3 { font-size: 1.45rem; text-transform: uppercase; }
.connect-card p { color: var(--muted); margin: 0 0 1.5rem; }
.connect-card .card-actions { margin-top: auto; display: flex; flex-wrap: wrap; gap: 0.7rem; }
@media (max-width: 960px) { .connect-grid { grid-template-columns: 1fr; } }

.pill-link, .social a, .social button, .card-actions .pill {
  display: inline-flex; align-items: center; gap: 0.5rem; padding: 0.65rem 1.15rem;
  border: 1px solid var(--line-strong); border-radius: 999px; color: var(--text);
  font: inherit; font-size: 0.92rem; font-weight: 500; background: rgba(4, 6, 15, 0.4); cursor: pointer;
  transition: border-color 0.2s, background 0.2s, color 0.2s;
}
.pill-link:hover, .social a:hover, .social button:hover, .card-actions .pill:hover { border-color: var(--accent-2); background: rgba(150, 160, 255, 0.12); color: var(--white); }
.pill-link svg, .social svg, .card-actions .pill svg { width: 18px; height: 18px; flex: none; }
.email-shown { border-color: var(--accent-2) !important; }
.social { display: flex; justify-content: center; flex-wrap: wrap; gap: 0.8rem; margin-top: 2rem; }

/* ---------------- Footer ---------------- */
.site-footer { position: relative; border-top: 1px solid var(--line); padding: 4rem 0 2rem; font-size: 0.92rem; color: var(--muted); background: linear-gradient(180deg, transparent, rgba(4, 6, 15, 0.85)); }
.footer-grid { display: grid; grid-template-columns: 1.6fr repeat(3, 1fr); gap: 2.5rem; }
.footer-brand p { margin: 1rem 0 0; max-width: 32ch; }
.site-footer h2 { font-size: 0.85rem; letter-spacing: 0.24em; color: var(--white); margin: 0.4rem 0 1rem; }
.site-footer nav { display: flex; flex-direction: column; align-items: flex-start; gap: 0.55rem; }
.site-footer a, .site-footer .linklike { color: var(--muted); }
.site-footer a:hover, .site-footer .linklike:hover { color: var(--white); }
.site-footer .soon { opacity: 0.6; }
.footer-bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.8rem; margin-top: 3rem; padding-top: 1.6rem; border-top: 1px solid var(--line); font-size: 0.85rem; }
.footer-bottom p { margin: 0; }
.linklike { background: none; border: 0; padding: 0; margin: 0; font: inherit; cursor: pointer; text-align: left; }
@media (max-width: 860px) { .footer-grid { grid-template-columns: 1fr 1fr; } .footer-brand { grid-column: 1 / -1; } }

/* ================= GAME PAGE ================= */
.game-hero {
  position: relative; isolation: isolate; overflow: hidden;
  min-height: clamp(620px, 100svh, 980px);
  display: flex; align-items: center;
  padding: calc(var(--header-h) + 2.5rem) 0 5rem;
}
.game-hero-media { position: absolute; inset: -4% 0 0 0; z-index: -2; translate: 0 var(--py, 0); }
.game-hero-media img { width: 100%; height: 100%; object-fit: cover; object-position: 62% 50%; }
.game-hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    linear-gradient(90deg, rgba(5, 9, 19, 0.94) 0%, rgba(5, 9, 19, 0.8) 28%, rgba(5, 9, 19, 0.28) 54%, rgba(5, 9, 19, 0) 70%),
    linear-gradient(180deg, rgba(5, 9, 19, 0.6) 0%, rgba(5, 9, 19, 0) 22%, rgba(5, 9, 19, 0) 72%, var(--bg) 100%);
}
.game-hero-content { max-width: 560px; }
.crumbs { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem; margin-bottom: 1.6rem; font-size: 0.85rem; color: var(--muted); }
.crumbs a { color: var(--muted); }
.crumbs a:hover { color: var(--white); }
.crumbs span[aria-current] { color: var(--accent-2); }
.game-logo { margin: 0 0 1.3rem; }
.game-logo img { width: 100%; max-width: 540px; height: auto; filter: drop-shadow(0 10px 30px rgba(0, 0, 0, 0.55)); }
.tagline { font-size: clamp(1.1rem, 1.6vw, 1.3rem); line-height: 1.55; color: var(--text); max-width: 32ch; margin: 0 0 1.3rem; }
.modes-line {
  display: flex; flex-wrap: wrap; gap: 0.4rem 1rem; list-style: none; padding: 0; margin: 0 0 2rem;
  font-family: var(--font-display); font-weight: 600; font-size: 0.95rem; letter-spacing: 0.24em; text-transform: uppercase;
}
.modes-line li:nth-child(1) { color: var(--story); }
.modes-line li:nth-child(2) { color: var(--infinite); }
.modes-line li:nth-child(3) { color: var(--versus); }
.modes-line li + li::before { content: "/"; margin-right: 1rem; color: var(--muted); }
.hero-note { margin: 1.3rem 0 0; font-size: 0.88rem; color: var(--muted); letter-spacing: 0.03em; }
.hero-note strong { color: var(--accent-2); font-weight: 600; }

/* Embers drifting up in the game hero */
.embers { position: absolute; inset: 0; z-index: -1; pointer-events: none; overflow: hidden; }
.embers i { position: absolute; bottom: -10px; width: 3px; height: 3px; border-radius: 50%; background: var(--accent-2); box-shadow: 0 0 8px 2px var(--glow); opacity: 0; animation: ember 9s linear infinite; }
.embers i:nth-child(1) { left: 58%; animation-delay: 0s; }
.embers i:nth-child(2) { left: 66%; animation-delay: 1.6s; animation-duration: 11s; }
.embers i:nth-child(3) { left: 74%; animation-delay: 3.2s; }
.embers i:nth-child(4) { left: 82%; animation-delay: 4.1s; animation-duration: 12s; }
.embers i:nth-child(5) { left: 90%; animation-delay: 5.5s; }
.embers i:nth-child(6) { left: 62%; animation-delay: 6.8s; animation-duration: 10s; }
.embers i:nth-child(7) { left: 78%; animation-delay: 7.7s; }
.embers i:nth-child(8) { left: 86%; animation-delay: 2.4s; animation-duration: 13s; }
@keyframes ember { 0% { opacity: 0; transform: translate(0, 0); } 10% { opacity: 0.9; } 100% { opacity: 0; transform: translate(-40px, -80vh); } }

@media (max-width: 899px) {
  .game-hero { display: block; min-height: 0; padding: 0 0 3.5rem; text-align: center; }
  .game-hero::before { display: none; }
  .game-hero-media { position: relative; inset: auto; z-index: auto; height: min(118vw, 64svh); translate: none; }
  .game-hero-media::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(5, 9, 19, 0.65) 0%, rgba(5, 9, 19, 0) 20%, rgba(5, 9, 19, 0) 60%, var(--bg) 100%); }
  .game-hero-media img { object-position: 50% 35%; }
  .game-hero > .container { position: relative; margin-top: -3.2rem; }
  .game-hero-content { max-width: 34rem; margin-inline: auto; }
  .crumbs { justify-content: center; margin-bottom: 1rem; }
  .game-hero .eyebrow { justify-content: center; font-size: 0.78rem; letter-spacing: 0.22em; }
  .game-hero .eyebrow::after { content: ""; width: 30px; height: 2px; flex: none; background: linear-gradient(270deg, var(--eyebrow), transparent); }
  .game-logo img { margin-inline: auto; max-width: min(88vw, 460px); }
  .tagline { margin-inline: auto; }
  .modes-line, .game-hero .hero-actions { justify-content: center; }
  .embers { display: none; }
}

/* Sticky game tab bar */
.game-bar {
  position: sticky; top: var(--header-h); z-index: 50; height: var(--bar-h);
  background: rgba(5, 9, 19, 0.88); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-block: 1px solid var(--line);
}
.game-bar-inner { height: 100%; display: flex; align-items: center; gap: 1.5rem; }
.game-bar-logo { flex: none; line-height: 0; }
.game-bar-logo img { width: 112px; height: auto; }
.game-tabs { flex: 1; display: flex; align-items: center; gap: 0.3rem; list-style: none; margin: 0; padding: 0; overflow-x: auto; overflow-anchor: none; scrollbar-width: none; height: 100%; }
.game-tabs::-webkit-scrollbar { display: none; }
.game-tabs li { height: 100%; flex: none; }
.game-tabs a {
  position: relative; height: 100%; display: flex; align-items: center; padding: 0 0.9rem;
  font-family: var(--font-display); font-weight: 600; font-size: 0.95rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted);
}
.game-tabs a::after { content: ""; position: absolute; left: 0.9rem; right: 0.9rem; bottom: -1px; height: 2px; background: var(--accent); transform: scaleX(0); transition: transform 0.25s; }
.game-tabs a:hover { color: var(--white); }
.game-tabs a.is-active { color: var(--white); }
.game-tabs a.is-active::after { transform: scaleX(1); }
.game-bar .btn { flex: none; }
@media (max-width: 760px) {
  .game-bar-logo { display: none; }
  .game-tabs, .press-tabs ul { -webkit-mask-image: linear-gradient(90deg, #000 85%, transparent); mask-image: linear-gradient(90deg, #000 85%, transparent); }
  .game-bar-inner { gap: 0.6rem; width: 100%; padding-left: 0.6rem; padding-right: 0.8rem; }
  .game-tabs a { padding: 0 0.7rem; font-size: 0.88rem; }
  .game-tabs a::after { left: 0.7rem; right: 0.7rem; }
  .game-bar .btn span { display: none; }
  .game-bar .btn { padding: 0.5rem 0.65rem; }
}

/* Overview */
.game-grid { display: grid; grid-template-columns: minmax(240px, 360px) 1fr; gap: 4rem; align-items: start; }
.game-cover { position: relative; margin: 0; }
.game-cover img { border-radius: 12px; box-shadow: 0 30px 80px rgba(0, 0, 0, 0.7), 0 0 60px rgba(63, 140, 255, 0.2); transform: perspective(1200px) rotateY(6deg); transition: transform 0.5s ease; }
.game-cover:hover img { transform: perspective(1200px) rotateY(0deg); }
.game-cover::before { content: ""; position: absolute; inset: 10% -10% -10% 10%; z-index: -1; background: radial-gradient(circle, rgba(63, 140, 255, 0.4), transparent 65%); filter: blur(30px); }
.game-text p { margin: 0 0 1.1rem; }
.wish {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1.1rem 1.5rem;
  margin-top: 2rem; padding: 1.3rem 1.5rem; border-radius: var(--radius);
  background: var(--panel); border: 1px solid rgba(243, 181, 63, 0.35);
}
.wish p { margin: 0; color: var(--muted); font-size: 0.95rem; max-width: 40ch; }
.wish strong { display: block; font-family: var(--font-display); font-size: 1.1rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--accent-2); }
@media (max-width: 860px) { .game-grid { grid-template-columns: 1fr; gap: 2.5rem; } .game-cover { max-width: 250px; margin-inline: auto; } }

/* Stats band */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); border-radius: 20px; border: 1px solid var(--line); background: var(--panel); overflow: hidden; }
.stat { position: relative; padding: 2rem 1.2rem; text-align: center; }
.stat + .stat::before { content: ""; position: absolute; left: 0; top: 22%; bottom: 22%; width: 1px; background: var(--line); }
.stat strong { display: block; font-family: var(--font-display); font-weight: 700; font-size: clamp(2.6rem, 5vw, 3.8rem); line-height: 1; background: var(--accent-grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.stat span { display: block; margin-top: 0.5rem; font-family: var(--font-display); font-weight: 600; font-size: 0.85rem; letter-spacing: 0.22em; text-transform: uppercase; color: var(--muted); }
@media (max-width: 700px) { .stats { grid-template-columns: repeat(2, 1fr); } .stat:nth-child(3)::before { display: none; } .stat:nth-child(n+3) { border-top: 1px solid var(--line); } }

/* Trailer */
.video-frame { position: relative; aspect-ratio: 16 / 9; overflow: hidden; border-radius: var(--radius); border: 1px solid var(--line-strong); background: #000; box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6), 0 0 70px rgba(63, 140, 255, 0.16); }
.video-frame video { width: 100%; height: 100%; object-fit: contain; }
.video-note { margin: 1rem 0 0; font-size: 0.88rem; color: var(--muted); }

/* Modes */
.modes { display: grid; gap: 1.4rem; grid-template-columns: repeat(auto-fit, minmax(290px, 1fr)); }
.mode {
  --mode: var(--story);
  position: relative; display: flex; flex-direction: column; overflow: hidden;
  border-radius: var(--radius); background: var(--panel);
  border: 1px solid var(--line); border-top: 2px solid var(--mode);
  transition: border-color 0.25s, box-shadow 0.25s, translate 0.25s;
}
.mode--infinite { --mode: var(--infinite); }
.mode--versus { --mode: var(--versus); }
.mode:hover { translate: 0 -4px; border-color: var(--mode); box-shadow: 0 18px 50px -20px var(--mode); }
.mode video { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; background: var(--bg-2); }
.mode-body { padding: 1.4rem 1.5rem 1.6rem; }
.mode .mode-tag { margin: 0 0 0.4rem; font-family: var(--font-display); font-weight: 700; font-size: 0.8rem; letter-spacing: 0.24em; text-transform: uppercase; color: var(--mode); }
.mode h3 { margin-bottom: 0.5rem; }
.mode p { margin: 0; color: var(--muted); font-size: 0.96rem; }

/* Features */
.cards { display: grid; gap: 1.2rem; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
.card { position: relative; overflow: hidden; padding: 1.6rem; border-radius: var(--radius); background: var(--panel); border: 1px solid var(--line); transition: translate 0.25s, border-color 0.25s; }
.card:hover { translate: 0 -4px; border-color: rgba(63, 140, 255, 0.5); }
.card .icon { width: 44px; height: 44px; display: grid; place-items: center; border-radius: 10px; background: rgba(243, 181, 63, 0.12); color: var(--accent-2); margin-bottom: 1rem; }
.card .icon svg { width: 22px; height: 22px; }
.card h3 { font-size: 1.25rem; margin-bottom: 0.4rem; }
.card p { margin: 0; color: var(--muted); font-size: 0.95rem; }

/* Screenshot gallery */
.gallery { display: grid; gap: 1rem; grid-template-columns: repeat(3, 1fr); }
.shot { display: block; position: relative; overflow: hidden; aspect-ratio: 16 / 9; border-radius: 10px; border: 1px solid var(--line); background: var(--bg-2); }
.shot img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s ease; }
.shot::after { content: ""; position: absolute; inset: 0; background: linear-gradient(0deg, rgba(5, 9, 19, 0.5), transparent 50%); opacity: 0; transition: opacity 0.3s; }
.shot:hover { border-color: var(--accent); }
.shot:hover img { transform: scale(1.05); }
.shot:hover::after { opacity: 1; }
.gallery figure { margin: 0; }
.gallery figcaption { margin-top: 0.55rem; font-size: 0.85rem; color: var(--muted); }
@media (max-width: 860px) { .gallery { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 480px) { .gallery { gap: 0.6rem; } }

/* Lightbox (a native <dialog>) */
.lightbox { padding: 0; border: 0; background: transparent; color: var(--text); max-width: none; max-height: none; overflow: visible; }
.lightbox::backdrop { background: rgba(2, 4, 10, 0.9); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); }
.lightbox figure { margin: 0; }
.lightbox img { width: auto; max-width: min(94vw, 1500px); max-height: 82vh; border-radius: 10px; border: 1px solid var(--line-strong); }
.lightbox figcaption { margin-top: 0.8rem; text-align: center; font-size: 0.92rem; color: var(--muted); }
.lb-btn { position: fixed; top: 50%; transform: translateY(-50%); width: 48px; height: 48px; display: grid; place-items: center; border-radius: 50%; border: 1px solid var(--line-strong); background: rgba(5, 9, 19, 0.75); color: var(--white); cursor: pointer; transition: border-color 0.2s, background 0.2s; }
.lb-btn:hover { border-color: var(--accent); background: rgba(150, 160, 255, 0.15); }
.lb-btn svg { width: 22px; height: 22px; }
.lb-prev { left: 1rem; }
.lb-next { right: 1rem; }
.lb-close { top: 1rem; right: 1rem; transform: none; }
@media (max-width: 600px) { .lb-prev, .lb-next { top: auto; bottom: 1rem; transform: none; } }

/* Starium band (cutscene art as backdrop) */
.starium { position: relative; isolation: isolate; overflow: hidden; padding: 7.5rem 0; border-block: 1px solid var(--line); }
.starium-bg { position: absolute; inset: -8% 0; z-index: -2; background: url("../images/sector7-m-900.jpg") 20% 50% / cover no-repeat; translate: 0 var(--py, 0); }
@media (min-width: 900px) { .starium-bg { background-image: url("../images/sector7-1600.jpg"); background-position: 0% 50%; } }
.starium::after {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    linear-gradient(90deg, rgba(5, 9, 19, 0.35) 0%, rgba(5, 9, 19, 0.8) 42%, rgba(5, 9, 19, 0.94) 62%),
    linear-gradient(180deg, var(--bg) 0%, rgba(5, 9, 19, 0) 18%, rgba(5, 9, 19, 0) 82%, var(--bg) 100%);
}
.starium-content { max-width: 590px; margin-left: auto; }
.starium-content > p { color: var(--text); }
.book { display: flex; gap: 1.4rem; align-items: center; margin-top: 2rem; padding: 1.2rem; border-radius: var(--radius); background: var(--panel); border: 1px solid var(--line); }
.book img { width: 112px; flex: none; border-radius: 6px; box-shadow: 0 12px 30px rgba(0, 0, 0, 0.6); }
.book p { margin: 0 0 0.9rem; font-size: 0.95rem; color: var(--muted); }
.book p strong { color: var(--white); font-weight: 600; }
@media (max-width: 899px) {
  .starium { padding: 5rem 0; }
  .starium::after { background: linear-gradient(180deg, var(--bg) 0%, rgba(5, 9, 19, 0.82) 30%, rgba(5, 9, 19, 0.92) 70%, var(--bg) 100%); }
  .starium-content { margin-inline: auto; }
}
@media (max-width: 520px) { .book { flex-direction: column; align-items: flex-start; } }

/* Closing call to action */
.cta-band { position: relative; isolation: isolate; overflow: hidden; padding: 8rem 0; text-align: center; }
.cta-bg { position: absolute; inset: -10% 0; z-index: -2; background: url("../images/hero-2000.jpg") 62% 50% / cover no-repeat; translate: 0 var(--py, 0); }
.cta-band::after { content: ""; position: absolute; inset: 0; z-index: -1; background: radial-gradient(ellipse at center, rgba(5, 9, 19, 0.55) 0%, rgba(5, 9, 19, 0.9) 70%), linear-gradient(180deg, var(--bg) 0%, transparent 25%, transparent 75%, var(--bg) 100%); }
.cta-band .game-logo img { margin-inline: auto; max-width: min(80vw, 420px); }
.cta-band p { max-width: 44ch; margin: 0 auto 2rem; color: var(--text); font-size: 1.1rem; }
.cta-band .hero-actions { justify-content: center; }

/* Gameplay loop over the key art (desktop only, started by main.js) */
.hero-video {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  transform: translateX(14%) scale(1.04); opacity: 0; transition: opacity 1.6s ease;
  filter: saturate(1.05) brightness(0.85);
}
.hero-video.is-playing { opacity: 1; }
.hero-video-tag {
  position: absolute; right: clamp(1rem, 4vw, 3rem); bottom: 6.5rem; z-index: 1;
  display: inline-flex; align-items: center; gap: 0.5rem; padding: 0.35rem 0.75rem; border-radius: 999px;
  font-family: var(--font-display); font-weight: 600; font-size: 0.75rem; letter-spacing: 0.22em; text-transform: uppercase;
  color: var(--white); background: rgba(5, 9, 19, 0.6); border: 1px solid var(--line-strong);
  opacity: 0; transition: opacity 0.8s ease;
}
.hero-video-tag::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: #ff5a5a; box-shadow: 0 0 8px #ff5a5a; animation: ping-red 1.6s ease-out infinite; }
.has-video .hero-video-tag { opacity: 1; }
@keyframes ping-red { 0%, 100% { opacity: 1; } 50% { opacity: 0.35; } }
@media (max-width: 899px) { .hero-video, .hero-video-tag { display: none; } }

/* ---------------- Mini game ---------------- */
.play-grid { display: grid; grid-template-columns: minmax(260px, 1fr) minmax(300px, 560px); gap: 4rem; align-items: center; }
.play-intro p { color: var(--text); }
.play-tips { list-style: none; padding: 0; margin: 1.6rem 0 2rem; display: grid; gap: 0.8rem; }
.play-tips li { display: flex; gap: 0.8rem; align-items: center; color: var(--muted); }
.play-tips li img { width: 34px; height: 34px; flex: none; }
.play-tips strong { color: var(--white); font-weight: 600; }
.play { position: relative; }
.play-hud { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.6rem; margin-bottom: 0.8rem; }
.play-hud div { padding: 0.55rem 0.9rem; border-radius: 12px; background: var(--panel); border: 1px solid var(--line); text-align: center; }
.play-hud span { display: block; font-family: var(--font-display); font-weight: 600; font-size: 0.72rem; letter-spacing: 0.22em; text-transform: uppercase; color: var(--muted); }
.play-hud strong { display: block; font-family: var(--font-display); font-size: 1.6rem; line-height: 1.1; color: var(--white); }
.play-hud [data-moves] { transition: color 0.3s; }
.play.is-low .play-hud [data-moves] { color: #ff7a6b; }
.play-board {
  position: relative; overflow: hidden; border-radius: 18px; border: 1px solid var(--line-strong);
  background: linear-gradient(rgba(5, 9, 19, 0.45), rgba(5, 9, 19, 0.65)), url("../images/play/board-bg.webp") center / cover;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6), 0 0 70px rgba(63, 140, 255, 0.16);
  padding: 3.5%;
}
.play-board canvas { display: block; width: 100%; aspect-ratio: 1; touch-action: manipulation; border-radius: 10px; }
.play.is-playing .play-board canvas { touch-action: none; cursor: pointer; }
.play-board canvas:focus { outline: none; }
.play-board canvas.kbd:focus { outline: 2px solid var(--accent-2); outline-offset: 4px; }
.play-overlay { position: absolute; inset: 0; display: grid; place-items: center; padding: 1.2rem; background: rgba(5, 9, 19, 0.72); backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px); }
.play-overlay[hidden] { display: none; }
.play-card { max-width: 30ch; text-align: center; }
.play-card h3 { font-size: clamp(1.8rem, 4vw, 2.4rem); text-transform: uppercase; margin-bottom: 0.4rem; }
.play-card p { color: var(--text); margin: 0 0 1.4rem; }
.play-kicker { font-family: var(--font-display); font-weight: 700; font-size: 0.8rem; letter-spacing: 0.26em; text-transform: uppercase; color: var(--accent) !important; margin-bottom: 0.6rem !important; }
.play-card .hero-actions { justify-content: center; }
@media (max-width: 900px) { .play-grid { grid-template-columns: 1fr; gap: 2.4rem; } .play { max-width: 560px; margin-inline: auto; width: 100%; } }

/* ---------------- Crew ---------------- */
.crew { display: grid; gap: 1.2rem; grid-template-columns: repeat(4, 1fr); }
.crew-card { position: relative; overflow: hidden; border-radius: var(--radius); background: var(--panel); border: 1px solid var(--line); transition: border-color 0.3s, box-shadow 0.3s; }
.crew-card:hover { border-color: rgba(243, 181, 63, 0.55); box-shadow: 0 20px 50px -20px rgba(243, 181, 63, 0.45); }
.crew-portrait { position: relative; aspect-ratio: 1; overflow: hidden; background: #0a0f24; }
.crew-portrait img { width: 100%; height: 100%; object-fit: cover; image-rendering: auto; transition: transform 0.7s ease, filter 0.7s ease; filter: saturate(0.92); }
.crew-card:hover .crew-portrait img { transform: scale(1.07); filter: saturate(1.1); }
.crew-portrait::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 55%, rgba(9, 17, 42, 0.95) 100%); }
.crew-portrait::before {
  content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none; opacity: 0; transition: opacity 0.3s;
  background: repeating-linear-gradient(180deg, rgba(140, 196, 255, 0.07) 0 2px, transparent 2px 5px);
}
.crew-card:hover .crew-portrait::before { opacity: 1; animation: scan 3s linear infinite; }
@keyframes scan { from { background-position: 0 0; } to { background-position: 0 60px; } }
.crew-body { position: relative; padding: 0 1.2rem 1.3rem; margin-top: -2.2rem; z-index: 2; }
.crew-role { margin: 0 0 0.25rem; font-family: var(--font-display); font-weight: 700; font-size: 0.75rem; letter-spacing: 0.22em; text-transform: uppercase; color: var(--accent); }
.crew-body h3 { font-size: 1.45rem; margin: 0 0 0.4rem; }
.crew-body p:last-child { margin: 0; font-size: 0.92rem; color: var(--muted); }
@media (max-width: 1000px) { .crew { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 460px) { .crew { gap: 0.8rem; } .crew-body { padding: 0 0.9rem 1rem; } .crew-body h3 { font-size: 1.2rem; } .crew-body p:last-child { font-size: 0.85rem; } }

/* ---------------- Sound toggle (header) ---------------- */
.nav-links { margin-left: auto; }
.sound-toggle {
  display: inline-grid; place-items: center; width: 40px; height: 40px; margin-left: 1rem; flex: none;
  border-radius: 50%; border: 1px solid var(--line-strong); background: rgba(4, 6, 15, 0.5); color: var(--white); cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
}
.sound-toggle:hover { border-color: var(--accent-2); }
.sound-toggle[aria-pressed="true"] { border-color: var(--accent-2); background: rgba(150, 160, 255, 0.14); }
.eq { display: flex; align-items: flex-end; gap: 2px; height: 14px; }
.eq i { display: block; width: 3px; height: 6px; border-radius: 1px; background: currentColor; opacity: 0.75; transition: height 0.3s, opacity 0.3s; }
.eq i:nth-child(2) { height: 11px; } .eq i:nth-child(3) { height: 8px; } .eq i:nth-child(4) { height: 13px; }
.sound-toggle[aria-pressed="true"] .eq i { opacity: 1; }
.sound-toggle[aria-pressed="true"] .eq i { animation: eq 0.9s ease-in-out infinite; }
.sound-toggle[aria-pressed="true"] .eq i:nth-child(2) { animation-delay: -0.3s; }
.sound-toggle[aria-pressed="true"] .eq i:nth-child(3) { animation-delay: -0.6s; }
.sound-toggle[aria-pressed="true"] .eq i:nth-child(4) { animation-delay: -0.15s; }
@keyframes eq { 0%, 100% { height: 4px; } 50% { height: 14px; } }
@media (max-width: 1100px) {
  .sound-toggle { margin-left: auto; margin-right: 0.6rem; order: 2; }
  .nav-toggle { order: 3; }
  .nav-links { margin-left: 0; }
}

/* Comet trail that follows the mouse (canvas drawn by main.js) */
.cursor-trail { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 90; pointer-events: none; }

/* ---------------- Keep Looking Up teaser ---------------- */
.signal { display: flex; align-items: center; gap: 0.8rem; margin: 0 0 0.9rem; font-family: var(--font-display); font-weight: 600; font-size: 0.78rem; letter-spacing: 0.2em; text-transform: uppercase; color: rgba(127, 240, 196, 0.85); }
.signal-wave { position: relative; width: 120px; height: 22px; overflow: hidden; flex: none; -webkit-mask-image: linear-gradient(90deg, transparent, #000 20%, #000 80%, transparent); mask-image: linear-gradient(90deg, transparent, #000 20%, #000 80%, transparent); }
.signal-wave svg { position: absolute; left: 0; top: 0; width: 240px; height: 22px; animation: wave 2.4s linear infinite; }
.signal-wave path { fill: none; stroke: #7ff0c4; stroke-width: 1.6; filter: drop-shadow(0 0 3px rgba(127, 240, 196, 0.8)); }
@keyframes wave { to { transform: translateX(-120px); } }
[data-decode] { white-space: nowrap; }

/* ================= PRESS PAGE ================= */
.page-hero { position: relative; isolation: isolate; overflow: hidden; padding: calc(var(--header-h) + 5rem) 0 4.5rem; }
.page-hero h1 { font-size: clamp(2.6rem, 6vw, 4.2rem); text-transform: uppercase; margin-bottom: 0.4em; }
.page-hero p { max-width: 62ch; margin: 0 0 1.8rem; color: var(--text); }
.page-hero > .container { position: relative; z-index: 1; }
.page-hero .galaxy { opacity: 0.85; }
@media (max-width: 860px) { .page-hero .galaxy { opacity: 0.4; } }
.press-tabs { position: sticky; top: var(--header-h); z-index: 40; background: rgba(4, 6, 15, 0.86); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-block: 1px solid var(--line); }
.press-tabs ul { display: flex; gap: 0.3rem; list-style: none; margin: 0; padding: 0; height: var(--bar-h); overflow-x: auto; scrollbar-width: none; }
.press-tabs li { flex: none; }
.press-tabs a { height: 100%; display: flex; align-items: center; gap: 0.6rem; padding: 0 1rem; font-family: var(--font-display); font-weight: 600; font-size: 0.98rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); }
.press-tabs a:hover, .press-tabs a.is-active { color: var(--white); }
.press-tabs a.is-active { box-shadow: inset 0 -2px 0 var(--accent-2); }
.press-tabs img { width: 22px; height: auto; }
.press-game-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1.5rem; margin-bottom: 3rem; padding-bottom: 2rem; border-bottom: 1px solid var(--line); }
.press-game-head img { width: min(340px, 70vw); height: auto; }
.press-game-head .hero-actions { gap: 0.7rem; }

.factsheet { display: grid; grid-template-columns: minmax(260px, 370px) 1fr; gap: 3.5rem; align-items: start; }
.facts { margin: 0; padding: 0.6rem 1.6rem; border-radius: var(--radius); background: var(--panel); border: 1px solid var(--line); }
.facts div { padding: 0.8rem 0; border-bottom: 1px solid var(--line); }
.facts div:last-child { border-bottom: 0; }
.facts dt { font-family: var(--font-display); font-weight: 600; font-size: 0.8rem; letter-spacing: 0.2em; text-transform: uppercase; color: var(--eyebrow); }
.facts dd { margin: 0.15rem 0 0; color: var(--white); }
.facts dd .linklike { color: var(--accent-2); text-decoration: underline; text-underline-offset: 3px; }
.facts dd .linklike:hover { color: var(--white); }
.prose > p { margin: 0 0 1.1rem; }
.prose h3 { margin-top: 2.2rem; }
.prose ul { padding-left: 1.2rem; margin: 0; }
.prose li { margin: 0.4rem 0; }
.prose li::marker { color: var(--accent); }
.quote-copy { padding: 1.1rem 1.3rem; border-left: 3px solid var(--accent); background: var(--panel); border-radius: 0 10px 10px 0; color: var(--white); }
@media (max-width: 860px) { .factsheet { grid-template-columns: 1fr; gap: 2.5rem; } }

.subhead { font-size: clamp(1.5rem, 2.6vw, 2rem); text-transform: uppercase; margin: 4rem 0 0.4rem; }
.subhead + p { color: var(--muted); margin: 0 0 1.6rem; }
.assets { display: grid; gap: 1.2rem; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); }
.asset { display: flex; flex-direction: column; overflow: hidden; border-radius: var(--radius); background: var(--panel); border: 1px solid var(--line); transition: border-color 0.25s; }
.asset:hover { border-color: var(--line-strong); }
.asset-thumb { height: 200px; display: flex; align-items: center; justify-content: center; overflow: hidden; padding: 1.4rem; background: radial-gradient(circle at 50% 40%, rgba(120, 140, 255, 0.18), transparent 70%), var(--bg-2); }
.asset-thumb.light { background: #eef1f8; }
.asset-thumb.photo { padding: 0; }
.asset-thumb picture { display: contents; }
.asset-thumb img { max-width: 100%; max-height: 100%; width: auto; height: auto; object-fit: contain; }
.asset-thumb.photo img { width: 100%; height: 100%; max-height: none; object-fit: cover; }
.asset-body { display: flex; flex: 1; flex-direction: column; gap: 0.25rem; padding: 1rem 1.2rem 1.2rem; }
.asset-body h3 { font-size: 1.1rem; margin: 0; }
.asset-body p { margin: 0; font-size: 0.85rem; color: var(--muted); }
.dl { display: inline-flex; align-items: center; gap: 0.4rem; margin-top: auto; padding-top: 0.7rem; font-weight: 600; font-size: 0.92rem; }
.dl svg { width: 16px; height: 16px; flex: none; }
.usage { margin-top: 2rem; font-size: 0.9rem; color: var(--muted); }
.studio-grid { display: grid; grid-template-columns: minmax(220px, 340px) 1fr; gap: 4rem; align-items: center; }
.studio-logo { padding: 2.6rem 2.4rem; border-radius: var(--radius); border: 1px solid var(--line); background: radial-gradient(circle at 50% 40%, rgba(120, 140, 255, 0.22), transparent 65%), var(--bg-2); }
.studio-logo img { width: 100%; height: auto; }
.studio-text p { color: var(--text); }
.studio-links { display: flex; flex-wrap: wrap; gap: 0.8rem; margin-top: 1.6rem; }
@media (max-width: 860px) { .studio-grid { grid-template-columns: 1fr; gap: 2.5rem; } .studio-logo { max-width: 300px; } }
.contact { text-align: center; }
.contact p { max-width: 54ch; margin-inline: auto; color: var(--muted); }

/* 404 */
.not-found { min-height: 100svh; display: grid; place-items: center; text-align: center; padding: 7rem 0 4rem; position: relative; overflow: hidden; isolation: isolate; }
.not-found > .container { position: relative; z-index: 1; }
.not-found .galaxy { opacity: 0.55; }
.not-found h1 { font-size: clamp(2.6rem, 8vw, 5rem); text-transform: uppercase; }
.not-found p { color: var(--muted); max-width: 46ch; margin: 0 auto 2rem; }
.not-found .hero-actions { justify-content: center; }

/* Reveal animation (uses `translate` so it never fights other transforms) */
.reveal { opacity: 0; translate: 0 26px; transition: opacity 0.8s ease, translate 0.8s ease; }
.reveal.in { opacity: 1; translate: 0 0; }
.reveal-d1 { transition-delay: 0.1s; } .reveal-d2 { transition-delay: 0.2s; } .reveal-d3 { transition-delay: 0.3s; }
/* Headings wipe in from the left and the eyebrow line draws itself. */
.js .reveal h2 { clip-path: inset(-20% 100% -20% 0); transition: clip-path 1.1s 0.15s cubic-bezier(0.2, 0.8, 0.2, 1); }
.js .reveal.in h2 { clip-path: inset(-20% -5% -20% -5%); }
.js .reveal .eyebrow::before, .js .reveal .eyebrow::after { transition: width 0.8s 0.35s ease; }
.js .reveal:not(.in) .eyebrow::before, .js .reveal:not(.in) .eyebrow::after { width: 0; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; translate: none; transition: none; }
  .js .reveal h2 { clip-path: none; transition: none; }
  *, *::before, *::after { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; animation-delay: 0s !important; }
  .orbit, .nebula { animation: none !important; }
  .btn:hover, .pillar:hover, .card:hover, .mode:hover { transform: none; translate: none; }
  .embers { display: none; }
}
