/* ===== MarioFlux — gallery theme. Dark neutral canvas, warm ivory, one amber accent. ===== */
:root {
  --bg: #0b0d10;
  --surface: #12151a;
  --surface-2: #191d24;
  --ink: #f4f1ea;
  --dim: #9aa1ac;
  --faint: #6a7280;
  --accent: #e0a13a;          /* warm amber — the only accent */
  --accent-soft: rgba(224, 161, 58, .14);
  --line: rgba(244, 241, 234, .12);
  --line-soft: rgba(244, 241, 234, .07);
  --max: 1240px;
  --ease: cubic-bezier(.22, .9, .27, 1);
  /* Archivo — a grotesk with squarish terminals and real character, chosen over
     the Inter/Geist default that every generated site converges on. */
  --sans: "Archivo", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --mono: "Archivo", ui-monospace, "SF Mono", Menlo, Consolas, monospace;
}

* { margin: 0; padding: 0; box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html { scroll-behavior: smooth; }
body {
  background: var(--bg); color: var(--ink); overflow-x: hidden;
  font-family: var(--sans);
  font-size: 17px; line-height: 1.6; -webkit-font-smoothing: antialiased;
}
body.locked { overflow: hidden; }
a { color: inherit; text-decoration: none; }
::selection { background: var(--accent); color: #14100a; }

#bg { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none; opacity: .8; }

/* living aurora wash — slow drifting colour behind everything */
.aurora { position: fixed; inset: -20%; z-index: 0; pointer-events: none; filter: blur(90px); opacity: .5; }
.aurora i {
  position: absolute; border-radius: 50%; mix-blend-mode: screen;
  animation: drift 26s var(--ease) infinite alternate;
}
.aurora i:nth-child(1) { width: 46vw; height: 46vw; left: -6%; top: 4%;  background: #4d9dff; animation-duration: 24s; }
.aurora i:nth-child(2) { width: 40vw; height: 40vw; right: -4%; top: 22%; background: #a855f7; animation-duration: 31s; animation-delay: -6s; }
.aurora i:nth-child(3) { width: 38vw; height: 38vw; left: 24%; bottom: 4%; background: #19c6b0; animation-duration: 28s; animation-delay: -12s; }
.aurora i:nth-child(4) { width: 30vw; height: 30vw; right: 16%; bottom: 16%; background: #ff5a3c; animation-duration: 35s; animation-delay: -18s; }
@keyframes drift {
  0%   { transform: translate3d(0,0,0) scale(1); opacity: .30; }
  50%  { transform: translate3d(6vw,-5vh,0) scale(1.22); opacity: .52; }
  100% { transform: translate3d(-5vw,6vh,0) scale(.92); opacity: .26; }
}

/* scroll progress */
#progress {
  /* scaleX rather than width — compositor-only, no layout on every scroll frame */
  position: fixed; top: 0; left: 0; height: 2px; width: 100%; z-index: 95;
  transform: scaleX(0); transform-origin: left; will-change: transform;
  background: linear-gradient(90deg, #4d9dff, #a855f7 30%, #ff5a3c 62%, #19c6b0);
  box-shadow: 0 0 14px rgba(168,85,247,.55);
}

/* cursor halo */
#halo {
  position: fixed; width: 340px; height: 340px; border-radius: 50%; pointer-events: none; z-index: 1;
  background: radial-gradient(circle, rgba(168,85,247,.16), rgba(77,157,255,.07) 45%, transparent 68%);
  transform: translate(-50%, -50%); transition: opacity .5s; opacity: 0;
}

/* split-text reveal */
.split { display: inline-block; overflow: hidden; vertical-align: bottom; }
.split > span { display: inline-block; transform: translateY(110%); transition: transform .95s var(--ease); }
.in .split > span, .split.in > span { transform: translateY(0); }
main, footer { position: relative; z-index: 2; }
.wrap { width: min(100% - 48px, var(--max)); margin-inline: auto; }
.mono { font-family: var(--mono); font-size: 11px; letter-spacing: .14em; text-transform: uppercase; }

/* ---------- loader ---------- */
#loader { position: fixed; inset: 0; z-index: 200; background: var(--bg); display: grid; place-items: center; transition: opacity .8s var(--ease), visibility .8s; }
#loader.done { opacity: 0; visibility: hidden; }
.loader-mark { font-family: var(--mono); font-size: 10.5px; letter-spacing: .45em; margin-bottom: 18px; color: var(--dim); }
.loader-bar { width: 160px; height: 1px; background: var(--line); overflow: hidden; }
.loader-bar i { display: block; height: 100%; width: 35%; background: var(--accent); animation: load 1.15s var(--ease) infinite; }
@keyframes load { 0% { transform: translateX(-110%);} 100% { transform: translateX(320%);} }

/* ---------- nav ---------- */
#nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 90; display: flex; align-items: center;
  justify-content: space-between; gap: 20px; padding: 22px max(24px, calc((100vw - var(--max)) / 2));
  /* no padding transition — animating box metrics thrashes layout every frame */
  transition: background .35s, border-color .35s, transform .35s var(--ease);
  border-bottom: 1px solid transparent; will-change: transform;
}
#nav.stuck {
  background: rgba(11, 13, 16, .82); backdrop-filter: blur(16px);
  border-bottom-color: var(--line-soft); transform: translateY(-8px);
}
#nav.stuck .brand, #nav.stuck .links, #nav.stuck .btn-sm { transform: translateY(4px); }
#nav .brand, #nav .links, #nav .btn-sm { transition: transform .35s var(--ease); }
.brand { display: flex; align-items: center; gap: 9px; font-weight: 600; letter-spacing: -.02em; font-size: 19px; }
.brand .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--accent); }
.links { display: flex; gap: 30px; font-size: 15px; color: var(--dim); }
.links a { position: relative; padding-bottom: 3px; transition: color .3s; }
.links a::after {
  content: ''; position: absolute; left: 0; bottom: 0; width: 100%; height: 1px;
  background: var(--accent); transform: scaleX(0); transform-origin: right;
  transition: transform .35s var(--ease);
}
.links a:hover { color: var(--ink); }
.links a:hover::after { transform: scaleX(1); transform-origin: left; }

/* ---- portfolio dropdown: every project reachable from the header ---- */
.nav-drop { position: relative; }
.nav-trig {
  font: inherit; color: var(--dim); background: none; border: 0; cursor: pointer;
  padding: 0 0 3px; display: inline-flex; align-items: center; gap: 6px;
  transition: color .3s;
}
.nav-trig span { font-size: 9px; opacity: .7; transition: transform .3s var(--ease); display: inline-block; }
.nav-drop.on .nav-trig, .nav-trig:hover { color: var(--ink); }
.nav-drop.on .nav-trig span { transform: rotate(180deg); }
.nav-panel {
  position: absolute; top: calc(100% + 16px); left: 50%; translate: -50% 0;
  display: grid; grid-template-columns: repeat(2, minmax(184px, 1fr)); gap: 4px 26px;
  padding: 20px; border-radius: 18px; width: max-content; max-width: min(92vw, 520px);
  background: rgba(16, 19, 24, .93); border: 1px solid var(--line);
  box-shadow: 0 30px 70px rgba(0, 0, 0, .55);
  opacity: 0; visibility: hidden; transform: translateY(-6px);
  transition: opacity .28s var(--ease), transform .28s var(--ease), visibility .28s;
  z-index: 60;
}
@supports (backdrop-filter: blur(20px)) {
  .nav-panel { backdrop-filter: blur(22px) saturate(1.3); background: rgba(16, 19, 24, .74); }
}
.nav-drop.on .nav-panel { opacity: 1; visibility: visible; transform: translateY(0); }
.nav-panel::before {           /* keeps hover alive across the gap to the trigger */
  content: ''; position: absolute; left: 0; right: 0; top: -16px; height: 16px;
}
.np-col { display: flex; flex-direction: column; gap: 2px; }
.np-stack { display: flex; flex-direction: column; gap: 14px; }
.np-stack .np-col b { padding-top: 0; }
.np-col b {
  font-family: var(--mono); font-size: 9px; letter-spacing: .16em; text-transform: uppercase;
  color: var(--faint); padding: 0 10px 8px;
}
.np-item {
  display: flex; align-items: center; gap: 10px; width: 100%; text-align: left;
  padding: 9px 10px; border-radius: 10px; border: 0; background: none; cursor: pointer;
  color: var(--dim); font: inherit; transition: background .25s, color .25s;
}
.np-item i { width: 7px; height: 7px; border-radius: 50%; background: var(--c); flex: none; }
.np-item span { display: flex; flex-direction: column; gap: 2px; line-height: 1.2; }
.np-item em {
  font-style: normal; font-size: 14px; font-weight: 600; color: var(--ink);
  letter-spacing: -.015em;
}
.np-item small {
  font-family: var(--mono); font-size: 9px; letter-spacing: .13em;
  text-transform: uppercase; color: var(--faint);
}
.np-item:hover { background: rgba(244, 241, 234, .07); color: var(--ink); }
.np-all {
  grid-column: 1 / -1; margin-top: 8px; padding: 12px 10px 2px;
  border-top: 1px solid var(--line-soft); color: var(--accent);
  font-size: 13.5px; font-weight: 600;
}
.np-all:hover { color: var(--ink); }

/* mobile menu project list */
.mm-projects { display: grid; grid-template-columns: 1fr 1fr; gap: 4px 14px; margin: 4px 0 14px; }
.mm-item {
  display: flex; align-items: center; gap: 9px; padding: 9px 0; border: 0; background: none;
  color: var(--dim); font: inherit; font-size: 16px; text-align: left; cursor: pointer;
}
.mm-item i { width: 6px; height: 6px; border-radius: 50%; background: var(--c); flex: none; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px; padding: 15px 28px;
  border-radius: 100px; font-size: 15.5px; font-weight: 600; cursor: pointer; border: 1px solid var(--accent);
  background: var(--accent); color: #14100a; transition: transform .3s var(--ease), box-shadow .3s, background .3s, color .3s;
}
.btn:hover { transform: translateY(-2px); box-shadow: 0 12px 32px rgba(224, 161, 58, .22); }
.btn-sm { padding: 10px 20px; font-size: 14px; }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--ink); box-shadow: none; }
.btn-full { width: 100%; margin-top: 10px; }

#burger { display: none; background: none; border: 0; cursor: pointer; width: 32px; height: 28px; padding: 6px 2px; }
#burger span { display: block; height: 1.5px; background: var(--ink); transition: transform .35s var(--ease); }
#burger span + span { margin-top: 7px; }
body.menu #burger span:first-child { transform: translateY(4.2px) rotate(45deg); }
body.menu #burger span:last-child { transform: translateY(-4.2px) rotate(-45deg); }
#mobile-menu {
  position: fixed; inset: 0; z-index: 85; background: var(--bg); display: flex; flex-direction: column;
  align-items: flex-start; justify-content: center; gap: 8px; padding: 0 34px; opacity: 0; visibility: hidden;
  transition: opacity .4s, visibility .4s;
}
#mobile-menu a { font-size: 38px; font-weight: 600; letter-spacing: -.03em; }
#mobile-menu a:hover { color: var(--accent); }
body.menu #mobile-menu { opacity: 1; visibility: visible; }

/* ---------- hero ---------- */
.hero { min-height: 100svh; display: flex; flex-direction: column; justify-content: center; padding: 140px 0 44px; }
.hero-inner { width: min(100% - 48px, var(--max)); margin-inline: auto; }
.eyebrow { display: inline-flex; align-items: center; gap: 10px; font-family: var(--mono); font-size: 10.5px; letter-spacing: .18em; text-transform: uppercase; color: var(--dim); border: 1px solid var(--line); padding: 8px 16px; border-radius: 100px; margin-bottom: 34px; }
.eyebrow i { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }
.hero-title { font-size: clamp(50px, 10.4vw, 142px); line-height: .95; font-weight: 600; letter-spacing: -.045em; max-width: 15ch; }
.hero-title .line { display: block; overflow: hidden; }
.hero-title .w { display: inline-block; transform: translateY(105%); animation: rise 1.05s var(--ease) forwards; }
.hero-title .line:nth-child(2) .w { animation-delay: .1s; }
.hero-title .line:nth-child(3) .w { animation-delay: .2s; }
@keyframes rise { to { transform: translateY(0); } }
/* Solid accent, not gradient text. Colour still carries the brand; the site gets
   its vibrancy from the live 3D and the aurora rather than from painted type. */
.hero-title .acc { color: var(--accent); }
.hero-title .acc::after {
  content: ''; display: block; height: 5px; margin-top: .12em; border-radius: 3px;
  background: var(--accent); transform: scaleX(0); transform-origin: left;
  animation: swipe 1.1s var(--ease) .55s forwards;
}
@keyframes swipe { to { transform: scaleX(1); } }
h2 .acc { color: var(--accent); }
.hero-row { display: flex; justify-content: space-between; align-items: flex-end; gap: 40px; flex-wrap: wrap; margin-top: 42px; }
.hero-sub { color: var(--dim); font-size: 18.5px; max-width: 46ch; }
.hero-cta { display: flex; gap: 12px; flex-wrap: wrap; }
.hero-foot { width: min(100% - 48px, var(--max)); margin: 60px auto 0; display: flex; justify-content: space-between; gap: 20px; border-top: 1px solid var(--line-soft); padding-top: 16px; color: var(--faint); }

/* ---------- marquee ---------- */
.marquee { overflow: hidden; padding: 18px 0; border-block: 1px solid var(--line-soft); background: var(--surface); }
.marquee-track { display: flex; gap: 30px; align-items: center; width: max-content; will-change: transform; }
.marquee span { font-family: var(--mono); font-size: 11.5px; letter-spacing: .18em; text-transform: uppercase; color: var(--dim); white-space: nowrap; }
.marquee em { color: var(--accent); font-size: 9px; font-style: normal; }

/* ---------- sections ---------- */
.section { padding: clamp(80px, 10vw, 150px) 0; }
.sec-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 32px; flex-wrap: wrap; margin-bottom: clamp(40px, 5vw, 66px); }
.tag { font-family: var(--mono); font-size: 10.5px; letter-spacing: .18em; text-transform: uppercase; color: var(--accent); display: block; margin-bottom: 18px; }
h2 { font-size: clamp(33px, 5vw, 61px); line-height: 1.06; font-weight: 600; letter-spacing: -.04em; max-width: 18ch; }
h2 .acc { color: var(--accent); }
.sec-note { color: var(--dim); font-size: 15.5px; max-width: 34ch; }

/* ---------- stats ---------- */
.stats { border-block: 1px solid var(--line-soft); background: var(--surface); }
.stat-grid { display: grid; grid-template-columns: repeat(4, 1fr); }
.stat { padding: clamp(34px, 4vw, 54px) 26px; border-left: 1px solid var(--line-soft); }
.stat:first-child { border-left: 0; padding-left: 0; }
.stat b { display: block; font-size: clamp(35px, 4.8vw, 59px); font-weight: 500; letter-spacing: -.045em; line-height: 1; }
.stat:nth-child(1) b { color: #4d9dff; }
.stat:nth-child(2) b { color: #19c6b0; }
.stat:nth-child(3) b { color: #f0a13a; }
.stat:nth-child(4) b { color: #f472b6; }
.stat span { display: block; margin-top: 10px; font-size: 14px; color: var(--dim); max-width: 22ch; }

/* ---------- work filter ---------- */
.work-filter { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 26px; }
.work-filter button {
  font-family: var(--mono); font-size: 10.5px; letter-spacing: .14em; text-transform: uppercase;
  color: var(--dim); background: transparent; border: 1px solid var(--line-soft);
  border-radius: 100px; padding: 9px 16px; cursor: pointer; min-height: 34px;
  transition: color .3s, border-color .3s, background .3s;
}
.work-filter button:hover { color: var(--ink); border-color: var(--line); }
.work-filter button.on {
  color: #14100a; background: var(--accent); border-color: var(--accent); font-weight: 700;
}
.work-card.filtered-out { display: none; }

/* ---------- work gallery ---------- */
.work-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 22px; }
.work-card {
  --c: var(--accent); --c2: var(--accent);
  position: relative; border: 1px solid var(--line-soft); border-radius: 16px; overflow: hidden;
  background: var(--surface); cursor: pointer; text-align: left; color: inherit; font: inherit;
  transition: transform .5s var(--ease), border-color .4s, box-shadow .5s;
}
.work-card::after {
  content: ''; position: absolute; inset: 0; pointer-events: none; border-radius: 16px;
  background: linear-gradient(135deg, color-mix(in srgb, var(--c) 12%, transparent), transparent 55%);
  opacity: 0; transition: opacity .45s;
}
.work-card:hover::after { opacity: 1; }
.work-card:hover {
  transform: translateY(-6px);
  border-color: color-mix(in srgb, var(--c) 55%, transparent);
  box-shadow: 0 22px 60px color-mix(in srgb, var(--c) 18%, transparent);
}
.work-card.feature { grid-column: 1 / -1; border-color: color-mix(in srgb, var(--c) 30%, transparent); }
.work-card.feature .poster { aspect-ratio: 16 / 6.4; }

/* end-to-end scope list in the viewer */
.v-scope { list-style: none; margin: 0 0 26px; padding: 0; }
.v-scope li {
  position: relative; font-size: 13.5px; color: var(--dim); padding: 7px 0 7px 22px;
  border-bottom: 1px solid var(--line-soft);
}
.v-scope li::before {
  content: ''; position: absolute; left: 2px; top: 14px; width: 8px; height: 8px;
  border-radius: 2px; background: linear-gradient(135deg, var(--c, var(--accent)), var(--c2, var(--accent)));
}
.work-card.feature::before {
  content: 'Featured'; position: absolute; top: 14px; right: 14px; z-index: 4;
  font-family: var(--mono); font-size: 9px; letter-spacing: .16em; text-transform: uppercase;
  color: #0a0c10; background: linear-gradient(100deg, var(--c), var(--c2));
  padding: 6px 11px; border-radius: 100px; font-weight: 700;
}
.poster {
  position: relative; aspect-ratio: 16 / 9; overflow: hidden;
  background: linear-gradient(135deg, #141922, #0a0d12);
}
/* the SVG is the instant-paint fallback; the live canvas fades in over it */
.poster svg { position: absolute; inset: 0; width: 100%; height: 100%; display: block; opacity: .5; }
.poster-live {
  position: absolute; inset: 0; width: 100%; height: 100%; display: block;
  object-fit: cover; opacity: 0; animation: fadeIn 1.1s var(--ease) .35s forwards;
}
@keyframes fadeIn { to { opacity: 1; } }
.work-card:hover .poster-live { transform: scale(1.03); }
.poster-live { transition: transform .7s var(--ease); }
.poster .live {
  position: absolute; top: 14px; left: 14px; z-index: 3; display: inline-flex; align-items: center; gap: 7px;
  font-family: var(--mono); font-size: 9.5px; letter-spacing: .16em; text-transform: uppercase;
  background: rgba(11,13,16,.72); backdrop-filter: blur(8px); padding: 6px 11px; border-radius: 100px;
  border: 1px solid var(--line);
}
.poster .live i { width: 6px; height: 6px; border-radius: 50%; background: var(--c, var(--accent)); box-shadow: 0 0 10px var(--c, var(--accent)); animation: blip 1.8s ease-in-out infinite; }
@keyframes blip { 50% { opacity: .3; } }
.poster .open {
  position: absolute; inset: 0; z-index: 2; display: grid; place-items: center; opacity: 0;
  background: rgba(11, 13, 16, .55); backdrop-filter: blur(2px); transition: opacity .4s;
}
.work-card:hover .poster .open { opacity: 1; }
.poster .open span {
  border: 1px solid var(--c, var(--ink)); border-radius: 100px; padding: 12px 26px; font-size: 13.5px;
  font-weight: 600; color: #0a0c10;
  background: linear-gradient(100deg, var(--c), var(--c2));
  box-shadow: 0 10px 30px color-mix(in srgb, var(--c) 35%, transparent);
}
.card-body { padding: 22px 24px 26px; }
.card-body h3 { font-size: clamp(20px, 2.3vw, 28px); font-weight: 600; letter-spacing: -.028em; }
.card-body p { color: var(--dim); font-size: 15px; margin-top: 9px; max-width: 58ch; }
.card-meta { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 16px; align-items: center; }
.card-meta span { font-family: var(--mono); font-size: 9.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--faint); border: 1px solid var(--line-soft); padding: 5px 10px; border-radius: 100px; }
.card-meta .kind {
  color: #0a0c10; border-color: transparent; font-weight: 600;
  background: linear-gradient(100deg, var(--c), var(--c2));
}
.card-meta .kind.concept {
  color: var(--c); background: none;
  border-color: color-mix(in srgb, var(--c) 45%, transparent);
}
.card-body h3 { transition: color .35s; }
.work-card:hover .card-body h3 { color: var(--c); }

/* ---------- project viewer (in-page) ---------- */
#viewer {
  --c: var(--accent); --c2: var(--accent);
  position: fixed; inset: 0; z-index: 150; background: rgba(6, 8, 10, .96); backdrop-filter: blur(14px);
  opacity: 0; visibility: hidden; transition: opacity .45s var(--ease), visibility .45s;
  display: flex; flex-direction: column;
}
#viewer.on { opacity: 1; visibility: visible; }
.v-top {
  display: flex; align-items: center; justify-content: space-between; gap: 20px;
  padding: 16px max(20px, calc((100vw - var(--max)) / 2)); border-bottom: 1px solid var(--line-soft); flex-shrink: 0;
}
.v-title { font-size: 17px; font-weight: 600; letter-spacing: -.02em; }
.v-title em { font-style: normal; color: var(--c); font-family: var(--mono); font-size: 10px; letter-spacing: .14em; text-transform: uppercase; margin-left: 12px; }
.v-top { background: linear-gradient(180deg, color-mix(in srgb, var(--c) 9%, transparent), transparent); }
.v-close:hover { background: var(--c) !important; border-color: var(--c) !important; }
.v-actions { display: flex; align-items: center; gap: 10px; }
.v-close { width: 38px; height: 38px; border-radius: 50%; border: 1px solid var(--line); background: none; color: var(--ink); font-size: 17px; cursor: pointer; transition: background .3s, color .3s, border-color .3s; }
.v-close:hover { background: var(--accent); color: #14100a; border-color: var(--accent); }
.v-body { flex: 1; min-height: 0; display: grid; grid-template-columns: 1fr 330px; }
.v-stage { position: relative; background: #05070a; overflow: hidden; }
.v-stage iframe { width: 100%; height: 100%; border: 0; display: block; }
.v-stage canvas { width: 100%; height: 100%; display: block; }
.v-loading { position: absolute; inset: 0; display: grid; place-items: center; color: var(--faint); font-family: var(--mono); font-size: 10.5px; letter-spacing: .18em; text-transform: uppercase; pointer-events: none; transition: opacity .5s; }

/* ---------- playable-game HUD ---------- */
.v-hud { position: absolute; inset: 0; pointer-events: none; font-family: var(--mono); }
.hud-top {
  position: absolute; top: 16px; left: 16px; right: 16px; display: flex;
  justify-content: space-between; align-items: flex-start; gap: 12px;
}
.hud-chip {
  background: rgba(8,10,14,.72); backdrop-filter: blur(10px); border: 1px solid var(--line);
  border-radius: 10px; padding: 9px 13px; font-size: 10px; letter-spacing: .14em;
  text-transform: uppercase; color: var(--dim); line-height: 1.5;
}
.hud-chip b { display: block; font-size: 21px; letter-spacing: -.01em; color: var(--ink); font-weight: 600; margin-top: 3px; }
.hud-chip.accent b { color: var(--c, var(--accent)); }
.hud-objective {
  position: absolute; left: 50%; bottom: 20px; transform: translateX(-50%);
  background: rgba(8,10,14,.72); backdrop-filter: blur(10px); border: 1px solid var(--line);
  border-radius: 100px; padding: 9px 18px; font-size: 10.5px; letter-spacing: .14em;
  text-transform: uppercase; color: var(--dim); white-space: nowrap; max-width: calc(100% - 32px);
  overflow: hidden; text-overflow: ellipsis;
}
.hud-combo {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%,-50%) scale(.7);
  font-size: 46px; font-weight: 700; letter-spacing: -.03em; color: var(--c, var(--accent));
  opacity: 0; transition: opacity .25s, transform .25s var(--ease); font-family: inherit;
  text-shadow: 0 0 26px color-mix(in srgb, var(--c) 60%, transparent);
}
.hud-combo.pop { opacity: 1; transform: translate(-50%,-50%) scale(1); }
.hud-panel {
  position: absolute; inset: 0; display: grid; place-items: center; pointer-events: auto;
  background: rgba(6,8,11,.74); backdrop-filter: blur(8px); text-align: center; padding: 24px;
}
.hud-panel .inner { max-width: 340px; }
.hud-panel h5 { font-family: var(--sans); font-size: 26px; font-weight: 600; letter-spacing: -.03em; color: var(--ink); margin-bottom: 10px; }
.hud-panel p { font-family: var(--sans); font-size: 14px; color: var(--dim); margin-bottom: 20px; line-height: 1.55; letter-spacing: 0; text-transform: none; }
.hud-panel .score { font-size: 52px; font-weight: 700; color: var(--c, var(--accent)); letter-spacing: -.04em; margin-bottom: 4px; font-family: var(--sans); }
.hud-btn {
  pointer-events: auto; cursor: pointer; border: 0; border-radius: 100px; padding: 13px 30px;
  font-family: var(--sans); font-size: 15px; font-weight: 600; color: #0a0c10;
  background: linear-gradient(100deg, var(--c, var(--accent)), var(--c2, var(--accent)));
  transition: transform .25s var(--ease), filter .25s;
}
.hud-btn:hover { transform: translateY(-2px); filter: brightness(1.07); }
.hud-flash { position: absolute; inset: 0; background: var(--c, #fff); opacity: 0; pointer-events: none; transition: opacity .35s; }
.hud-flash.on { opacity: .18; transition: opacity .05s; }
.hud-btn.ghost {
  background: transparent; color: var(--ink); border: 1px solid var(--line);
  margin-top: 9px; font-weight: 500;
}
.hud-btn.ghost:hover { border-color: var(--c, var(--accent)); color: var(--c, var(--accent)); }

/* draft panels (level-up, turret build) — a column of equal-width choices, so the
   gradient stays on one primary action instead of shouting three times over */
.hud-panel .inner .hud-choice {
  display: block; width: 100%; margin: 9px 0 0; padding: 13px 20px; text-align: left;
  background: rgba(255, 255, 255, .045); color: var(--ink);
  border: 1px solid var(--line); border-radius: 14px; font-weight: 500;
}
.hud-panel .inner .hud-choice b { display: block; font-weight: 650; margin-bottom: 2px; }
.hud-panel .inner .hud-choice:hover {
  border-color: var(--c, var(--accent)); background: rgba(255, 255, 255, .07);
}

/* first-person crosshair */
.hud-cross { position: absolute; left: 50%; top: 50%; width: 22px; height: 22px; transform: translate(-50%,-50%); opacity: 0; transition: opacity .3s; }
.hud-cross.on { opacity: .9; }
.hud-cross i { position: absolute; background: var(--c, var(--accent)); box-shadow: 0 0 8px color-mix(in srgb, var(--c) 70%, transparent); }
.hud-cross i:first-child { left: 50%; top: 0; width: 1.5px; height: 100%; transform: translateX(-50%); }
.hud-cross i:last-child { top: 50%; left: 0; height: 1.5px; width: 100%; transform: translateY(-50%); }

/* incoming challenge banner */
.challenge {
  position: fixed; left: 50%; bottom: 22px; transform: translate(-50%, 130%); z-index: 120;
  display: flex; align-items: center; gap: 12px; max-width: calc(100% - 32px);
  background: rgba(14,17,22,.94); backdrop-filter: blur(16px); border: 1px solid var(--line);
  border-radius: 100px; padding: 11px 12px 11px 20px; font-size: 14px; color: var(--ink);
  box-shadow: 0 20px 50px rgba(0,0,0,.5); transition: transform .6s var(--ease);
}
.challenge.in { transform: translate(-50%, 0); }
.challenge .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 10px var(--accent); flex-shrink: 0; }
.challenge b { color: var(--accent); }
.challenge button { cursor: pointer; border: 0; font-family: inherit; }
.challenge .ch-play {
  background: linear-gradient(100deg, #e0a13a, #ff7d5c); color: #14100a; font-weight: 700;
  font-size: 13.5px; padding: 9px 18px; border-radius: 100px; white-space: nowrap;
}
.challenge .ch-x { background: none; color: var(--faint); font-size: 15px; padding: 4px 8px; }
.challenge .ch-x:hover { color: var(--ink); }
@media (max-width: 560px) { .challenge { font-size: 12.5px; padding-left: 14px; gap: 8px; } }
.v-side { border-left: 1px solid var(--line-soft); padding: 28px 26px; overflow-y: auto; background: var(--surface); }
.v-side h4 { font-family: var(--mono); font-size: 10px; letter-spacing: .18em; text-transform: uppercase; color: var(--faint); margin-bottom: 10px; }
.v-side p { font-size: 14.5px; color: var(--dim); margin-bottom: 26px; }
.v-side p.lead { color: var(--ink); font-size: 15.5px; }
.v-facts { border-top: 1px solid var(--line-soft); }
.v-facts div { display: flex; justify-content: space-between; gap: 16px; padding: 13px 0; border-bottom: 1px solid var(--line-soft); font-size: 13.5px; }
.v-facts b { color: var(--faint); font-weight: 400; font-family: var(--mono); font-size: 10px; letter-spacing: .12em; text-transform: uppercase; padding-top: 3px; }
.v-facts span { text-align: right; color: var(--ink); }

/* ---------- capabilities ---------- */
.cap-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(252px, 1fr)); gap: 1px; background: var(--line-soft); border: 1px solid var(--line-soft); border-radius: 16px; overflow: hidden; }
.cap { position: relative; padding: 32px 26px 28px; background: var(--surface); transition: background .4s; }
.cap::before { content: ''; position: absolute; top: 0; left: 0; right: 0; height: 2px; background: var(--cc); opacity: .8; }
.cap:nth-child(1) { --cc: #4d9dff; } .cap:nth-child(2) { --cc: #ff5a3c; }
.cap:nth-child(3) { --cc: #a78bfa; } .cap:nth-child(4) { --cc: #19c6b0; }
.cap:hover { background: var(--surface-2); }
.cap:hover h3 { color: var(--cc); }
.cap h3 { transition: color .35s; }
.cap .n { font-family: var(--mono); font-size: 10px; letter-spacing: .16em; color: var(--cc); }
.cap h3 { font-size: 20px; margin: 18px 0 11px; font-weight: 600; letter-spacing: -.02em; }
.cap p { color: var(--dim); font-size: 14px; margin-bottom: 18px; }
.cap ul { list-style: none; display: flex; flex-direction: column; gap: 6px; border-top: 1px solid var(--line-soft); padding-top: 14px; }
.cap li { font-family: var(--mono); font-size: 10px; letter-spacing: .1em; text-transform: uppercase; color: var(--faint); }

/* ---------- process ---------- */
.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(212px, 1fr)); gap: 28px; }
.step { border-top: 1px solid var(--line); padding-top: 20px; }
.step b { font-family: var(--mono); font-size: 10px; letter-spacing: .16em; color: var(--accent); display: block; margin-bottom: 24px; }
.step h3 { font-size: 19px; margin-bottom: 9px; font-weight: 600; letter-spacing: -.02em; }
.step p { color: var(--dim); font-size: 13.5px; }

/* ---------- studio ---------- */
.studio-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: clamp(30px, 5vw, 74px); align-items: start; }
.studio-grid p { color: var(--dim); margin-top: 18px; max-width: 52ch; }
.pills { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 26px; }
.pills span { font-family: var(--mono); font-size: 10px; letter-spacing: .1em; text-transform: uppercase; padding: 7px 13px; border: 1px solid var(--line-soft); border-radius: 100px; color: var(--dim); }
.studio-card { border-top: 1px solid var(--line); }
.sc-row { display: flex; justify-content: space-between; gap: 18px; padding: 16px 0; border-bottom: 1px solid var(--line-soft); font-size: 14px; }
.sc-row b { color: var(--faint); font-weight: 400; font-family: var(--mono); font-size: 10px; letter-spacing: .12em; text-transform: uppercase; padding-top: 3px; }
.sc-row span { text-align: right; }

/* ---------- faq ---------- */
.faq { border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line-soft); }
.faq summary { list-style: none; cursor: pointer; padding: 22px 0; font-size: clamp(16px, 2vw, 21px); font-weight: 600; letter-spacing: -.02em; display: flex; justify-content: space-between; align-items: center; gap: 20px; transition: color .3s; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: '+'; font-size: 21px; font-weight: 300; color: var(--accent); transition: transform .35s var(--ease); }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq summary:hover { color: var(--accent); }
.faq details p { color: var(--dim); font-size: 14.5px; max-width: 64ch; padding-bottom: 24px; margin-top: -4px; }

/* ---------- contact ---------- */
.contact { border-top: 1px solid var(--line-soft); }
h2.big { font-size: clamp(40px, 8.4vw, 108px); max-width: none; letter-spacing: -.05em; }
.contact-sub { color: var(--dim); max-width: 46ch; margin-top: 22px; font-size: 16.5px; }
.form { margin-top: 46px; max-width: 720px; display: flex; flex-direction: column; gap: 18px; }
.f-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.form label { display: flex; flex-direction: column; gap: 8px; font-family: var(--mono); font-size: 10px; letter-spacing: .14em; text-transform: uppercase; color: var(--faint); }
.form input, .form select, .form textarea {
  background: var(--surface); border: 1px solid var(--line-soft); border-radius: 10px; padding: 13px 15px;
  color: var(--ink); font-size: 15.5px; font-family: inherit; letter-spacing: 0; text-transform: none; transition: border-color .3s;
}
.form input::placeholder, .form textarea::placeholder { color: var(--faint); }
.form input:focus, .form select:focus, .form textarea:focus { outline: 0; border-color: var(--accent); }
.form select option { background: var(--surface); }
.form textarea { resize: vertical; }
.form-note { font-family: var(--mono); font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--accent); min-height: 18px; }

/* ---------- footer ---------- */
footer { border-top: 1px solid var(--line); padding: 58px 0 26px; background: var(--surface); }
.foot-grid { display: grid; grid-template-columns: 1.7fr .65fr .65fr; gap: 40px; }
.foot-grid p { color: var(--dim); font-size: 14px; max-width: 40ch; margin-top: 14px; }
.foot-links { display: flex; flex-direction: column; gap: 10px; font-size: 14px; color: var(--dim); }
.foot-links b { font-family: var(--mono); font-size: 10px; letter-spacing: .16em; text-transform: uppercase; color: var(--ink); margin-bottom: 6px; font-weight: 400; }
.foot-links a:hover { color: var(--accent); }
.foot-base { display: flex; justify-content: space-between; gap: 16px; margin-top: 52px; padding-top: 18px; border-top: 1px solid var(--line-soft); color: var(--faint); }

/* ---------- reveals ---------- */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity .85s var(--ease), transform .85s var(--ease); }
.reveal.in { opacity: 1; transform: none; }

@media (max-width: 980px) {
  .links, #nav .btn-sm { display: none; }
  #burger { display: block; }
  .work-grid { grid-template-columns: 1fr; }
  .stat-grid { grid-template-columns: repeat(2, 1fr); }
  .stat:nth-child(3) { border-left: 0; padding-left: 0; }
  .stat { padding-inline: 18px; }
  .stat:first-child, .stat:nth-child(3) { padding-left: 0; }
  .studio-grid, .foot-grid { grid-template-columns: 1fr; }
  .f-row { grid-template-columns: 1fr; }
  .v-body { grid-template-columns: 1fr; grid-template-rows: 1fr auto; }
  .v-side { border-left: 0; border-top: 1px solid var(--line-soft); max-height: 42vh; }
}
@media (max-width: 560px) {
  .hero-foot, .foot-base { flex-direction: column; gap: 5px; }
  .stat { border-left: 0; padding-left: 0; }
}
@media (prefers-reduced-motion: reduce) {
  * { animation-duration: .01ms !important; transition-duration: .01ms !important; }
  .hero-title .w { transform: none; }
}
