/* ==================================================================
   Dunora Labs: the lab (dunoralabs.xyz)
   Black + green terminal. Pixel display type, mono UI, grotesk body.
   Looping animations only run while html[data-motion="on"] (set by
   js/lab.js; off by default with prefers-reduced-motion, and the nav
   has a pause button).
   ================================================================== */

/* ---------- fonts (self-hosted, SIL OFL 1.1: see /fonts/OFL-*.txt) ---------- */
@font-face { font-family: "JetBrains Mono"; src: url("/fonts/jetbrains-mono-var.woff2") format("woff2"); font-weight: 400 700; font-style: normal; font-display: swap; }
@font-face { font-family: "Space Grotesk"; src: url("/fonts/space-grotesk-var.woff2") format("woff2"); font-weight: 300 700; font-style: normal; font-display: swap; }
@font-face { font-family: "Silkscreen"; src: url("/fonts/silkscreen-400.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }

:root {
  --bg: #050806;
  --surface: #0b120e;
  --surface-2: #0f1913;
  --surface-3: #142219;
  --line: rgba(61, 255, 143, .10);
  --line-2: rgba(61, 255, 143, .22);
  --line-3: rgba(61, 255, 143, .42);
  --text: #dcf5e6;
  --muted: #87a594;
  --dim: #73937f;
  --green: #3dff8f;
  --green-2: #1fd17a;
  --ink: #03140a;
  --lime: #c6ff4d;
  --amber: #ffc24d;
  --red: #ff5d6c;
  --glow: 0 0 18px rgba(61, 255, 143, .35);

  --mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --sans: "Space Grotesk", system-ui, -apple-system, "Segoe UI", sans-serif;
  --pixel: "Silkscreen", "JetBrains Mono", ui-monospace, monospace;
  --r: 3px;
  --wrap: 1240px;
  --gutter: clamp(16px, 4vw, 40px);
  --nav-h: 60px;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--nav-h) + 16px); -webkit-text-size-adjust: 100%; }
html.no-scroll { overflow: hidden; }
body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font: 400 16px/1.6 var(--sans);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
/* faint grid behind everything */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-image: linear-gradient(var(--line) 1px, transparent 1px), linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 48px 48px;
  opacity: .32;
  -webkit-mask-image: radial-gradient(ellipse 90% 70% at 50% 0%, #000 10%, transparent 80%);
  mask-image: radial-gradient(ellipse 90% 70% at 50% 0%, #000 10%, transparent 80%);
}
/* CRT: scanlines + vignette (toggle in the command palette) */
html[data-crt="on"] body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 90;
  pointer-events: none;
  background:
    repeating-linear-gradient(to bottom, rgba(0, 0, 0, .28) 0 1px, transparent 1px 3px),
    radial-gradient(ellipse at center, transparent 62%, rgba(0, 0, 0, .45) 100%);
  opacity: .5;
}
::selection { background: rgba(61, 255, 143, .3); color: #fff; }
a { color: inherit; }
img, svg, canvas { display: block; max-width: 100%; }
:focus-visible { outline: 2px solid var(--green); outline-offset: 3px; border-radius: 2px; }
h1, h2, h3 { margin: 0; font-weight: 400; }
p { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
button { font: inherit; color: inherit; }
kbd {
  display: inline-block;
  min-width: 1.6em;
  font: 500 11px/1 var(--mono);
  text-align: center;
  padding: 3px 5px;
  border: 1px solid var(--line-2);
  border-bottom-width: 2px;
  border-radius: 3px;
  color: var(--muted);
  background: var(--surface);
}
.sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }
.skip { position: absolute; left: -999px; top: 8px; z-index: 300; background: var(--green); color: var(--ink); padding: 8px 14px; font: 600 14px/1 var(--mono); text-decoration: none; }
.skip:focus { left: 8px; }
.muted { color: var(--muted); }
.todo, .todo-text { color: var(--amber); }
.todo em { font-style: normal; font: 500 11px/1 var(--mono); }

/* ---------- small pieces ---------- */
.cmd { font: 500 13px/1.4 var(--mono); color: var(--green); letter-spacing: .01em; }
.cmd::after { content: ""; }
.live-dot { position: relative; display: inline-block; width: 7px; height: 7px; background: var(--green); box-shadow: 0 0 10px var(--green); flex: none; }
html[data-motion="on"] .live-dot::after {
  content: "";
  position: absolute;
  inset: -4px;
  border: 1px solid var(--green);
  animation: ping 1.8s ease-out infinite;
}
@keyframes ping { from { transform: scale(.5); opacity: .9; } to { transform: scale(1.7); opacity: 0; } }
.chrome-dots { display: inline-flex; gap: 5px; }
.chrome-dots i { width: 7px; height: 7px; background: var(--surface-3); border: 1px solid var(--line-2); }
.chrome-dots i:first-child { background: var(--green); border-color: var(--green); box-shadow: 0 0 8px rgba(61, 255, 143, .6); }
.badge {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 3px 7px;
  border: 1px solid var(--line-2);
  border-radius: 2px;
  font: 500 10.5px/1.2 var(--mono);
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--green);
  white-space: nowrap;
}
.badge::before { content: ""; width: 5px; height: 5px; background: currentColor; }
.badge--prototype { color: var(--muted); border-color: var(--line); }
.badge--wip { color: var(--amber); border-color: rgba(255, 194, 77, .35); }
.badge--live { color: var(--lime); border-color: rgba(198, 255, 77, .35); }
.rule { overflow: hidden; white-space: nowrap; font: 12px/1 var(--mono); color: var(--line-3); user-select: none; }
.rule::before { content: "+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------"; }
.link-btn { padding: 0; border: 0; background: none; color: var(--muted); cursor: pointer; text-decoration: underline; text-underline-offset: 3px; text-decoration-color: var(--line-3); }
.link-btn:hover { color: var(--green); }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  height: 44px;
  padding: 0 18px;
  border: 1px solid transparent;
  border-radius: var(--r);
  font: 600 14px/1 var(--mono);
  letter-spacing: .01em;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: transform .15s, box-shadow .2s, border-color .2s, color .2s, background .2s;
}
.btn-sm { height: 34px; padding: 0 12px; font-size: 13px; }
.btn-lg { height: 52px; padding: 0 24px; font-size: 15px; }
.btn-primary { background: var(--green); color: var(--ink); box-shadow: 0 0 24px rgba(61, 255, 143, .22); }
.btn-primary:hover { transform: translate(-2px, -2px); box-shadow: 4px 4px 0 var(--green-2), 0 0 36px rgba(61, 255, 143, .35); }
.btn-primary:active { transform: none; box-shadow: 0 0 24px rgba(61, 255, 143, .22); }
.btn-ghost { background: rgba(11, 18, 14, .75); color: var(--text); border-color: var(--line-2); }
.btn-ghost:hover { border-color: var(--green); color: var(--green); }

/* ---------- icons (inline SVG, colour from currentColor) ---------- */
.ico { width: 16px; height: 16px; flex: none; fill: currentColor; }
.ico-line { fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: square; }
[data-state="paused"] .ico-pause, [data-state="playing"] .ico-play { display: none; }
[aria-pressed="true"] .ico-sound-on, [aria-pressed="false"] .ico-sound-off { display: none; }

/* ---------- nav ---------- */
.nav {
  position: fixed;
  inset: 0 0 auto;
  z-index: 50;
  height: var(--nav-h);
  border-bottom: 1px solid transparent;
  transition: background .25s, border-color .25s;
}
.nav.scrolled, .nav.open { background: rgba(5, 8, 6, .88); border-color: var(--line); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); }
.nav-inner { height: 100%; display: flex; align-items: center; gap: 20px; }
.logo { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; flex: none; }
.logo-mark { width: auto; height: 26px; overflow: visible; }
.logo-mark .lm-core, .logo-mark .lm-loose { fill: var(--green); }
.logo-mark .lm-bowl { fill: var(--text); }
.logo-mark .lm-loose rect { transition: transform .5s cubic-bezier(.2, .8, .2, 1), opacity .5s; transform-box: fill-box; }
.logo:hover .lm-loose rect, .logo:focus-visible .lm-loose rect { transform: translateX(var(--dx, 6px)); opacity: .35; }
.logo-word { font: 400 15px/1 var(--pixel); color: var(--text); letter-spacing: .02em; word-spacing: -.3em; white-space: nowrap; }
.logo-word b { font-weight: 400; color: var(--green); }
.nav-links { display: flex; align-items: center; gap: 2px; margin-left: auto; }
.nav-links a {
  display: inline-flex; align-items: baseline; gap: 6px;
  padding: 8px 10px;
  font: 500 13px/1 var(--mono);
  color: var(--muted);
  text-decoration: none;
  border-radius: 2px;
  transition: color .2s, background .2s;
}
.nav-links .k { font-size: 10px; color: var(--dim); border: 1px solid var(--line); padding: 1px 4px; border-radius: 2px; }
.nav-links a:hover, .nav-links a.active { color: var(--text); background: var(--surface-2); }
.nav-links a.active .k { color: var(--green); border-color: var(--line-2); }
.nav-links .hire { margin-left: 8px; color: var(--green); border: 1px solid var(--line-2); }
.nav-links .hire:hover { border-color: var(--green); background: rgba(61, 255, 143, .06); color: var(--green); }
.nav-tools { display: flex; align-items: center; gap: 6px; }
.tool {
  display: inline-flex; align-items: center; gap: 8px;
  height: 34px; padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 2px;
  background: var(--surface);
  color: var(--muted);
  font: 500 12px/1 var(--mono);
  cursor: pointer;
  transition: color .2s, border-color .2s;
}
.tool:hover { color: var(--green); border-color: var(--line-3); }
.tool--icon { width: 34px; padding: 0; justify-content: center; }
.tool-kbd { border-bottom-width: 1px; padding: 2px 4px; font-size: 10px; }
.nav-menu { display: none; }
.i-motion, .i-menu { position: relative; display: block; width: 12px; height: 12px; }
.i-motion::before, .i-motion::after { content: ""; position: absolute; top: 1px; bottom: 1px; width: 3px; background: currentColor; }
.i-motion::before { left: 2px; } .i-motion::after { right: 2px; }
html[data-motion="off"] .i-motion::before { left: 2px; width: 0; height: 0; top: 0; bottom: auto; background: none; border-style: solid; border-width: 6px 0 6px 10px; border-color: transparent transparent transparent currentColor; }
html[data-motion="off"] .i-motion::after { display: none; }
.i-menu { height: 10px; border-top: 2px solid currentColor; border-bottom: 2px solid currentColor; }
.i-menu::before { content: ""; position: absolute; left: 0; right: 0; top: 2px; height: 2px; background: currentColor; }

/* ---------- hero ---------- */
.hero {
  position: relative;
  isolation: isolate;
  display: flex;
  flex-direction: column;
  min-height: max(720px, 100svh);
  padding-top: var(--nav-h);
  overflow: hidden;
  background: radial-gradient(70% 55% at 50% 75%, rgba(61, 255, 143, .07), transparent 70%);
}
.hero::after { content: ""; position: absolute; inset: auto 0 0; height: 110px; background: linear-gradient(transparent, var(--bg)); pointer-events: none; z-index: 1; }
#wall { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0; cursor: grab; touch-action: pan-y; opacity: 0; transition: opacity .8s; }
#wall.on { opacity: 1; }
.hero-inner {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr);
  align-items: end;
  gap: 20px clamp(32px, 5vw, 72px);
  padding-top: clamp(28px, 5vh, 56px);
  pointer-events: none;
}
.hero-inner a, .hero-inner button { pointer-events: auto; }
.hero-line { font: 500 clamp(12px, 3.3vw, 15px)/1.4 var(--mono); color: var(--green); white-space: nowrap; }
.hero-line .prompt { color: var(--muted); }
.cursor { display: inline-block; width: .6em; height: 1.1em; margin-left: 2px; vertical-align: -.2em; background: var(--green); box-shadow: var(--glow); }
html[data-motion="on"] .cursor { animation: blink 1.05s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }
.typing .type { display: inline-block; vertical-align: bottom; overflow: hidden; white-space: nowrap; width: 0; animation: type calc(var(--n) * 38ms) steps(var(--n)) .35s forwards; }
@keyframes type { to { width: calc(var(--n) * 1ch); } }
.hero-title {
  margin-top: 18px;
  /* Silkscreen caps advance ~0.66em: 16 characters per line must fit the column */
  font: 400 clamp(26px, 7.4vw, 60px)/1.08 var(--pixel);
  letter-spacing: -.01em;
  white-space: nowrap;
}
@media (min-width: 981px) { .hero-title { font-size: clamp(40px, 4.3vw, 60px); } }
.hero-title span { color: var(--green); text-shadow: 0 0 28px rgba(61, 255, 143, .45); }
.hero-side { padding-bottom: 6px; }
.lede { max-width: 470px; color: var(--muted); font-size: clamp(1rem, 1.25vw, 1.0625rem); }
.hero-cta { margin-top: 20px; display: flex; flex-wrap: wrap; gap: 10px; }
.hero-stats { margin-top: 18px; display: flex; flex-wrap: wrap; gap: 6px 18px; font: 500 12px/1 var(--mono); color: var(--muted); text-transform: uppercase; letter-spacing: .08em; }
.hero-stats b { color: var(--green); font-weight: 700; margin-right: 4px; }

.stage { position: relative; z-index: 1; flex: 1; min-height: 420px; margin: 22px var(--gutter) 44px; pointer-events: none; }
.corner { position: absolute; width: 18px; height: 18px; border: 0 solid var(--line-3); }
.corner.tl { top: 0; left: 0; border-top-width: 1px; border-left-width: 1px; }
.corner.tr { top: 0; right: 0; border-top-width: 1px; border-right-width: 1px; }
.corner.bl { bottom: 0; left: 0; border-bottom-width: 1px; border-left-width: 1px; }
.corner.br { bottom: 0; right: 0; border-bottom-width: 1px; border-right-width: 1px; }
.hud { position: absolute; display: flex; align-items: center; gap: 8px; font: 500 11px/1 var(--mono); letter-spacing: .1em; text-transform: uppercase; color: var(--dim); }
.hud-sep { color: var(--line-3); }
.hud-tl { top: 14px; left: 26px; } .hud-tr { top: 14px; right: 26px; color: var(--muted); }
.hud-bl { bottom: 14px; left: 26px; } .hud-br { bottom: 14px; right: 26px; }
.hud .live-dot { width: 6px; height: 6px; }
.hud-key { color: var(--green); border: 1px solid var(--line-2); padding: 3px 6px; }
.wall-only { display: none; }
.has-wall .wall-only { display: flex; }
.wall-tip {
  position: absolute; top: 0; left: 0; z-index: 5;
  display: flex; flex-direction: column; gap: 4px;
  padding: 10px 14px;
  border: 1px solid var(--line-3);
  background: rgba(8, 14, 10, .94);
  box-shadow: 0 10px 30px rgba(0, 0, 0, .5), 0 0 24px rgba(61, 255, 143, .12);
  pointer-events: none; opacity: 0; transition: opacity .15s; white-space: nowrap;
}
.wall-tip.on { opacity: 1; }
.wall-tip .tip-code { font: 500 10px/1 var(--mono); letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.wall-tip strong { font: 400 16px/1.2 var(--pixel); }
.wall-tip .tip-cta { font: 500 11px/1 var(--mono); color: var(--green); }
/* flat grid when the 3D wall isn't loaded (small/low-power devices, no WebGL) */
.wall-fallback { position: absolute; inset: 44px 20px; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; align-content: center; pointer-events: auto; }
.has-wall .wall-fallback { display: none; }
.wall-fallback a { position: relative; display: block; border: 1px solid var(--line-2); background: var(--bg); overflow: hidden; }
.wall-fallback canvas { width: 100%; aspect-ratio: 16 / 10; }
.wall-fallback span { position: absolute; left: 8px; bottom: 6px; font: 400 11px/1 var(--pixel); color: var(--text); text-shadow: 0 1px 6px #000; }
.wall-fallback a:hover, .wall-fallback a:focus-visible { box-shadow: 0 0 0 1px var(--green), 0 0 24px rgba(61, 255, 143, .25); }

/* ---------- sections ---------- */
.sec { padding: clamp(72px, 9vw, 120px) 0 0; }
.sec > .wrap::before { grid-column: 1 / -1; content: "+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------"; display: block; margin-bottom: 28px; overflow: hidden; white-space: nowrap; font: 12px/1 var(--mono); color: var(--line-3); }
.sec--tight { padding-top: clamp(56px, 6vw, 80px); }
.sec--last { padding-bottom: clamp(72px, 9vw, 120px); }
.sec-head { margin-bottom: 32px; }
.sec-head h1, .sec-head h2 { margin-top: 10px; font: 400 clamp(32px, 4.4vw, 48px)/1.05 var(--pixel); letter-spacing: -.01em; }
.sec-sub { margin-top: 12px; max-width: 62ch; color: var(--muted); }
.sec-head--inline { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: end; gap: 6px 40px; }
.sec-head--inline .cmd { grid-column: 1 / -1; }
.sec-head--inline .sec-sub { margin: 0 0 4px; justify-self: end; text-align: right; max-width: 52ch; }
.section-foot { margin-top: 18px; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 20px; font: 500 12px/1.5 var(--mono); color: var(--dim); }
.section-foot a { color: var(--green); text-decoration: none; }
.section-foot a:hover { text-decoration: underline; text-underline-offset: 3px; }
.empty { color: var(--muted); font: 500 14px/1.5 var(--mono); }

/* ---------- games ---------- */
.games { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; }
.game {
  position: relative;
  display: flex;
  flex-direction: column;
  min-width: 0;
  background: var(--surface);
  border: 1px solid var(--line-2);
  border-radius: 2px;
  transition: border-color .25s, box-shadow .25s;
}
.game::before, .game::after { content: ""; position: absolute; width: 14px; height: 14px; border: 0 solid var(--green); opacity: 0; transition: opacity .2s, transform .25s; pointer-events: none; }
.game::before { top: -5px; left: -5px; border-top-width: 2px; border-left-width: 2px; transform: translate(4px, 4px); }
.game::after { bottom: -5px; right: -5px; border-bottom-width: 2px; border-right-width: 2px; transform: translate(-4px, -4px); }
.game:hover, .game:focus-within { border-color: var(--line-3); box-shadow: 0 0 48px -16px rgba(61, 255, 143, .35); }
.game:hover::before, .game:hover::after, .game:focus-within::before, .game:focus-within::after { opacity: 1; transform: none; }
.game--lead { grid-column: 1 / -1; display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(0, 1fr); }
.game-screen { background: var(--bg); border-bottom: 1px solid var(--line-2); min-width: 0; }
.game--lead .game-screen { border-bottom: 0; border-right: 1px solid var(--line-2); display: flex; flex-direction: column; }
.chrome { display: flex; align-items: center; gap: 12px; height: 32px; padding: 0 10px 0 12px; background: var(--surface-2); border-bottom: 1px solid var(--line); font: 500 11px/1 var(--mono); color: var(--dim); }
.chrome-path { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.game-shot, .gp-canvas { position: relative; display: block; aspect-ratio: 16 / 10; overflow: hidden; background: var(--bg); }
.game--lead .game-shot { flex: 1; aspect-ratio: auto; min-height: 320px; }
.poster, .preview { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.preview { opacity: 0; transition: opacity .4s, transform .6s cubic-bezier(.2, .7, .2, 1); }
.preview.ready { opacity: 1; }
.game:hover .preview { transform: scale(1.03); }
.play-chip {
  position: absolute; right: 12px; bottom: 12px;
  display: inline-flex; align-items: center; height: 32px; padding: 0 12px;
  background: var(--green); color: var(--ink);
  font: 700 12px/1 var(--mono); letter-spacing: .06em; text-transform: uppercase;
  box-shadow: 0 0 22px rgba(61, 255, 143, .5);
  opacity: 0; transform: translateY(6px); transition: opacity .2s, transform .25s;
}
.game:hover .play-chip, .gp-screen:hover .play-chip, .gp-screen:focus-visible .play-chip { opacity: 1; transform: none; }
.game-body { display: flex; flex-direction: column; gap: 12px; padding: 20px 20px 22px; min-width: 0; }
.game--lead .game-body { padding: 28px; justify-content: center; }
.game-num { font: 500 11px/1 var(--mono); color: var(--dim); letter-spacing: .1em; }
.game-title { font: 400 26px/1.1 var(--pixel); }
.game--lead .game-title { font-size: clamp(28px, 3vw, 40px); }
.game-blurb { color: var(--muted); }
.specs { margin: 2px 0 0; display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 6px 16px; font: 400 13px/1.45 var(--mono); }
.specs > div { display: contents; }
.specs dt { color: var(--dim); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; line-height: 1.75; }
.specs dd { margin: 0; color: var(--text); min-width: 0; }
.game-actions { margin-top: auto; padding-top: 8px; display: flex; flex-wrap: wrap; gap: 10px; }

/* ---------- experiments ---------- */
.xps { border-top: 1px dashed var(--line-2); }
.xp { border-bottom: 1px dashed var(--line-2); }
.xp-link {
  display: grid;
  grid-template-columns: 112px minmax(0, 1fr) 150px 80px;
  align-items: center;
  gap: 20px;
  padding: 14px 12px 14px 0;
  color: inherit;
  text-decoration: none;
  border-left: 2px solid transparent;
  transition: background .2s, border-color .2s, padding .2s;
}
.xp-link:hover, .xp-link:focus-visible { background: var(--surface); border-left-color: var(--green); padding-left: 12px; }
.xp-thumb { position: relative; display: block; height: 66px; border: 1px solid var(--line-2); background: var(--bg); overflow: hidden; }
.xp--app .xp-thumb { width: 40px; height: 84px; margin-left: 36px; border-radius: 6px; }
.xp-thumb canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.xp-main { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.xp-name { font: 400 18px/1.2 var(--pixel); }
.xp-blurb { color: var(--muted); font-size: 15px; }
.xp-kind { font: 500 11px/1.4 var(--mono); color: var(--dim); text-transform: uppercase; letter-spacing: .08em; }
.xp-open { font: 600 12px/1 var(--mono); color: var(--green); justify-self: end; opacity: .6; transition: opacity .2s; }
.xp-link:hover .xp-open { opacity: 1; }

/* ---------- repos ---------- */
.repo-filters { display: grid; gap: 10px; margin-bottom: 20px; padding: 14px 16px; border: 1px solid var(--line); background: var(--surface); }
.filter-row { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.filter-label { min-width: 52px; font: 500 11px/1 var(--mono); color: var(--dim); text-transform: uppercase; letter-spacing: .08em; }
.chip { height: 28px; padding: 0 10px; border: 1px solid var(--line-2); border-radius: 2px; background: transparent; color: var(--muted); font: 500 12px/1 var(--mono); cursor: pointer; }
.chip:hover { color: var(--text); border-color: var(--line-3); }
.chip[aria-pressed="true"] { background: var(--green); border-color: var(--green); color: var(--ink); }
.filter-search { display: flex; align-items: center; gap: 6px; }
.filter-search input { flex: 1; max-width: 320px; height: 32px; padding: 0 10px; border: 1px solid var(--line-2); border-radius: 2px; background: var(--bg); color: var(--text); font: 400 13px/1 var(--mono); }
.filter-search input:focus { outline: none; border-color: var(--green); box-shadow: 0 0 0 1px var(--green); }
.filter-count { font: 500 12px/1 var(--mono); color: var(--dim); }
.repos { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.repo { display: flex; flex-direction: column; gap: 8px; padding: 18px 20px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); min-width: 0; transition: background .2s; }
.repo:hover { background: var(--surface); }
.repo-head { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; }
.repo-name { font: 400 15px/1.3 var(--mono); color: var(--muted); text-decoration: none; overflow-wrap: anywhere; }
.repo-name b { font-weight: 700; color: var(--green); }
.repo-name:hover b { text-decoration: underline; text-underline-offset: 3px; }
.repo-pin { font: 600 10px/1 var(--mono); text-transform: uppercase; letter-spacing: .08em; color: var(--ink); background: var(--lime); padding: 3px 5px; }
.repo-desc { color: var(--muted); font-size: 15px; }
.repo-meta { display: flex; flex-wrap: wrap; gap: 4px 16px; font: 400 12px/1.4 var(--mono); color: var(--dim); }
.repo-lang { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); }
.lang-dot { width: 8px; height: 8px; background: var(--green); }
.lang-dot[data-lang="javascript"] { background: #f1e05a; } .lang-dot[data-lang="typescript"] { background: #3178c6; }
.lang-dot[data-lang="html"] { background: #e34c26; } .lang-dot[data-lang="css"] { background: #663399; }
.lang-dot[data-lang="python"] { background: #3572a5; } .lang-dot[data-lang="c"] { background: #178600; }
.lang-dot[data-lang="gdscript"] { background: #355570; } .lang-dot[data-lang="rust"] { background: #dea584; }
.repo-topics { display: flex; flex-wrap: wrap; gap: 6px; }
.repo-topics li { font: 500 11px/1 var(--mono); color: var(--green); padding: 4px 7px; background: rgba(61, 255, 143, .06); border: 1px solid var(--line); }
.repos-more { margin-top: 18px; max-width: 70ch; color: var(--muted); }
.repos-more a { color: var(--green); }

/* ---------- notes + now ---------- */
.split { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 32px clamp(32px, 5vw, 64px); align-items: start; }
.notes { display: grid; border-top: 1px solid var(--line); }
.note { display: grid; grid-template-columns: 104px minmax(0, 1fr); gap: 4px 20px; padding: 16px 0; border-bottom: 1px solid var(--line); }
.note time { font: 500 12px/1.9 var(--mono); color: var(--dim); }
.note-main { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.note-title { font: 600 18px/1.35 var(--sans); color: var(--text); text-decoration: none; }
.note-title:hover { color: var(--green); }
.note-main p { color: var(--muted); font-size: 15px; }
.note-tags { grid-column: 2; display: flex; flex-wrap: wrap; gap: 4px 12px; font: 500 12px/1 var(--mono); color: var(--green-2); }
.term { border: 1px solid var(--line-2); background: var(--surface); box-shadow: 0 0 60px -24px rgba(61, 255, 143, .3); min-width: 0; }
.term-bar { display: flex; align-items: center; gap: 12px; height: 34px; padding: 0 12px; border-bottom: 1px solid var(--line); background: var(--surface-2); font: 500 12px/1 var(--mono); color: var(--dim); }
.term-meta { margin-left: auto; }
.term-body { margin: 0; padding: 20px; overflow-x: auto; font: 400 clamp(12px, 1.15vw, 13.5px)/1.85 var(--mono); color: var(--text); }
.now-list { display: grid; }
.now-item { display: grid; gap: 6px; padding: 18px 18px 20px; border-bottom: 1px dashed var(--line-2); }
.now-item:last-child { border-bottom: 0; }
.now-title { font: 700 14px/1.4 var(--mono); color: var(--text); }
.now-title a { color: inherit; text-decoration-color: var(--line-3); text-underline-offset: 3px; }
.now-title a:hover { color: var(--green); }
.now-what { color: var(--muted); font-size: 15px; }
.now-bar { font: 400 12px/1.2 var(--mono); color: var(--green); white-space: nowrap; overflow: hidden; }
.now-bar b { color: var(--text); }
.now-next { font: 400 13px/1.5 var(--mono); color: var(--text); }
.now-next span { color: var(--amber); }

/* ---------- about ---------- */
.about { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 32px clamp(32px, 6vw, 80px); align-items: start; }
.about-copy > p { max-width: 58ch; color: var(--muted); }
.about-copy > p + p { margin-top: 14px; }
.about-links { margin-top: 24px; display: flex; flex-wrap: wrap; gap: 8px; }
.about-links a, .about-links .todo { display: inline-flex; align-items: center; gap: 6px; height: 34px; padding: 0 12px; border: 1px solid var(--line-2); border-radius: 2px; font: 500 13px/1 var(--mono); text-decoration: none; color: var(--text); }
.about-links a:hover { border-color: var(--green); color: var(--green); }
.about-links .todo { border-style: dashed; border-color: rgba(255, 194, 77, .35); }
.hire-card { margin-top: 28px; display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 6px 16px; padding: 18px 20px; border: 1px solid var(--line-2); border-left: 3px solid var(--green); background: var(--surface); text-decoration: none; transition: border-color .2s, background .2s; }
.hire-card:hover { border-color: var(--green); background: var(--surface-2); }
.hire-k { grid-column: 1; font: 500 11px/1 var(--mono); color: var(--green); letter-spacing: .08em; text-transform: uppercase; }
.hire-t { grid-column: 1; color: var(--muted); }
.hire-t b { color: var(--text); font-weight: 600; }
.hire-go { grid-column: 2; grid-row: 1 / 3; align-self: center; font: 400 24px/1 var(--mono); color: var(--green); }
.stack { margin-top: 64px; }
.t-p { color: var(--muted); } .t-k { color: var(--green); } .t-s { color: var(--text); } .t-g { color: var(--lime); }
.t-s.todo-text { color: var(--amber); }

/* ---------- contact ---------- */
.contact-body { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); gap: 24px clamp(24px, 4vw, 56px); align-items: start; }
.mail { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; padding: 16px 18px; border: 1px solid var(--line-3); background: var(--surface); box-shadow: 0 0 60px -24px rgba(61, 255, 143, .35); }
.mail-prompt { font: 500 13px/1 var(--mono); color: var(--dim); }
.mail-addr { font: 700 clamp(15px, 1.8vw, 20px)/1.2 var(--mono); color: var(--green); text-decoration: none; overflow-wrap: anywhere; text-shadow: 0 0 18px rgba(61, 255, 143, .35); }
.mail-addr:hover { text-decoration: underline; text-underline-offset: 4px; }
.mail .btn { margin-left: auto; }
.menu { display: grid; border-top: 1px solid var(--line); }
.menu-item { display: grid; grid-template-columns: 40px minmax(0, 1fr) auto; gap: 12px; align-items: start; padding: 16px 8px 16px 0; border-bottom: 1px solid var(--line); color: inherit; text-decoration: none; transition: background .2s, padding .2s; }
.menu-item:hover, .menu-item:focus-visible { background: var(--surface); padding-left: 10px; }
.menu-key { font: 700 13px/1.6 var(--mono); color: var(--green); }
.menu-main { display: flex; flex-direction: column; gap: 3px; }
.menu-main b { font: 600 17px/1.4 var(--sans); }
.menu-main span { color: var(--muted); font-size: 15px; }
.menu-go { font: 400 18px/1.4 var(--mono); color: var(--dim); transition: color .2s, transform .2s; }
.menu-item:hover .menu-go { color: var(--green); transform: translateX(3px); }

/* ---------- footer ---------- */
.footer { margin-top: clamp(48px, 6vw, 72px); padding-bottom: 36px; }
.footer .rule { margin-bottom: 28px; }
.footer-grid { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1.4fr) minmax(0, 1fr); gap: 24px 40px; align-items: start; }
.logo--sm .logo-mark { height: 22px; }
.footer-line { margin-top: 14px; font: 400 13px/1.5 var(--mono); color: var(--dim); }
.footer-links { display: flex; flex-wrap: wrap; gap: 8px 18px; font: 500 13px/1.5 var(--mono); }
.footer-links a { color: var(--muted); text-decoration: none; }
.footer-links a:hover { color: var(--green); }
.footer-links .todo { font: inherit; }
.footer-meta { font: 400 12px/1.9 var(--mono); color: var(--dim); text-align: right; }
.footer-meta .link-btn { color: var(--dim); text-decoration: none; }
.footer-meta .link-btn:hover { color: var(--green); }

/* ---------- inner pages (game, notes, 404) ---------- */
.crumbs { padding-top: calc(var(--nav-h) + 28px); font: 500 13px/1 var(--mono); color: var(--dim); }
.crumbs ol { display: flex; flex-wrap: wrap; gap: 6px; }
.crumbs li + li::before { content: "/"; margin-right: 6px; color: var(--line-3); }
.crumbs a { color: var(--muted); text-decoration: none; }
.crumbs a:hover { color: var(--green); }
.crumbs [aria-current] { color: var(--green); }
.gp-hero { margin-top: 28px; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); gap: 32px clamp(28px, 4vw, 56px); align-items: center; }
.gp-title { margin-top: 12px; font: 400 clamp(36px, 5.6vw, 64px)/1.05 var(--pixel); }
.gp-blurb { margin-top: 14px; color: var(--muted); font-size: 1.0625rem; max-width: 52ch; }
.gp-intro .specs { margin-top: 20px; }
.gp-actions { margin-top: 24px; display: flex; flex-wrap: wrap; gap: 10px; }
.gp-note { margin-top: 12px; font: 400 12px/1.5 var(--mono); color: var(--dim); }
.gp-screen { display: block; border: 1px solid var(--line-3); background: var(--bg); text-decoration: none; box-shadow: 0 0 80px -24px rgba(61, 255, 143, .35); }
.gp-screen .chrome { display: flex; }
.gp-sec { margin-top: clamp(56px, 7vw, 88px); }
.gp-sec h2 { margin: 8px 0 18px; font: 400 clamp(26px, 3vw, 34px)/1.1 var(--pixel); }
.gp-cols { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 48px; }
.shots { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.shot { margin: 0; }
.shot img { width: 100%; height: auto; border: 1px solid var(--line-2); background: var(--surface); }
.shot figcaption { margin-top: 8px; font: 400 12px/1.5 var(--mono); color: var(--dim); }
.prose { max-width: 70ch; color: var(--muted); }
.prose > * + * { margin-top: 14px; }
.prose h2, .prose h3 { margin-top: 32px; color: var(--text); font: 600 20px/1.3 var(--sans); }
.prose h3 { font-size: 17px; }
.prose strong { color: var(--text); font-weight: 600; }
.prose a { color: var(--green); text-underline-offset: 3px; }
.prose ul, .prose ol { display: grid; gap: 8px; }
.prose ul li { position: relative; padding-left: 20px; }
.prose ul li::before { content: "+"; position: absolute; left: 0; color: var(--green); font-family: var(--mono); }
.prose ol { counter-reset: n; }
.prose ol li { counter-increment: n; position: relative; padding-left: 28px; }
.prose ol li::before { content: counter(n, decimal-leading-zero); position: absolute; left: 0; color: var(--green); font: 500 13px/1.8 var(--mono); }
.prose code { font: 400 .88em/1 var(--mono); color: var(--lime); background: var(--surface-2); padding: 2px 5px; border: 1px solid var(--line); }
.prose pre { margin: 18px 0; padding: 16px; overflow-x: auto; background: var(--surface); border: 1px solid var(--line-2); }
.prose pre code { padding: 0; border: 0; background: none; color: var(--text); font-size: 13px; line-height: 1.7; }
.prose blockquote { margin: 18px 0; padding-left: 16px; border-left: 2px solid var(--green); color: var(--text); }
.prose img { height: auto; border: 1px solid var(--line-2); }
.prose hr { border: 0; height: 1px; background: var(--line-2); }
.gp-pager { margin-top: clamp(56px, 7vw, 88px); display: grid; grid-template-columns: 1fr auto 1fr; gap: 16px; padding-top: 20px; border-top: 1px solid var(--line-2); font: 500 14px/1.4 var(--mono); }
.gp-pager a { color: var(--text); text-decoration: none; }
.gp-pager a:hover { color: var(--green); }
.gp-pager a:last-child { text-align: right; }
.gp-pager small { display: block; font-size: 11px; color: var(--dim); text-transform: uppercase; letter-spacing: .08em; }
.post { max-width: 760px; }
.post-head { margin: 28px 0 32px; }
.post-head h1 { margin-top: 12px; font: 400 clamp(28px, 4.4vw, 46px)/1.12 var(--pixel); }
.post-meta { margin-top: 14px; display: flex; flex-wrap: wrap; gap: 12px; font: 500 13px/1 var(--mono); color: var(--dim); }
.post-meta span { color: var(--green-2); }
.post .prose { font-size: 17px; line-height: 1.7; }
.notes-page .sec-head { margin-top: 28px; }
.notes-page .sec-sub a { color: var(--green); }
.nf { padding-top: calc(var(--nav-h) + 72px); min-height: 70vh; }
.nf h1 { margin-top: 12px; font: 400 clamp(72px, 16vw, 160px)/1 var(--pixel); color: var(--green); text-shadow: 0 0 40px rgba(61, 255, 143, .45); }
.nf-err { margin: 10px 0 24px; font: 500 15px/1.5 var(--mono); color: var(--red); }
.nf-links { margin-top: 16px; display: flex; flex-wrap: wrap; gap: 10px 24px; font: 500 15px/1.5 var(--mono); }
.nf-links a { color: var(--green); }
.nf p:not(.cmd):not(.nf-err) { color: var(--muted); }

/* ---------- dialogs: shared ---------- */
dialog { color: var(--text); }
dialog::backdrop { background: rgba(2, 4, 3, .72); -webkit-backdrop-filter: blur(3px); backdrop-filter: blur(3px); }

/* ---------- command palette ---------- */
.palette { width: min(640px, calc(100% - 24px)); max-height: min(560px, calc(100% - 24px)); margin: 12vh auto auto; padding: 0; border: 1px solid var(--line-3); border-radius: 2px; background: var(--surface); box-shadow: 0 30px 80px rgba(0, 0, 0, .7), 0 0 60px -20px rgba(61, 255, 143, .35); }
.palette[open] { display: flex; }
.palette-box { position: relative; display: flex; flex-direction: column; width: 100%; min-height: 0; }
.palette-prompt { position: absolute; left: 16px; top: 17px; font: 700 16px/1 var(--mono); color: var(--green); }
.palette-input { width: 100%; height: 52px; padding: 0 16px 0 38px; border: 0; border-bottom: 1px solid var(--line-2); background: transparent; color: var(--text); font: 400 15px/1 var(--mono); }
.palette-input:focus { outline: none; }
.palette-input::placeholder { color: var(--dim); }
.palette-list { flex: 1; min-height: 0; overflow-y: auto; padding: 6px 0; }
.palette-group { padding: 10px 16px 4px; font: 500 10.5px/1 var(--mono); letter-spacing: .1em; text-transform: uppercase; color: var(--dim); }
.palette-opt { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 2px 12px; padding: 9px 16px; border-left: 2px solid transparent; cursor: pointer; }
.palette-opt b { font: 500 14px/1.35 var(--mono); color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.palette-opt small { grid-column: 1; font: 400 12px/1.3 var(--sans); color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.palette-opt i { grid-column: 2; grid-row: 1 / 3; align-self: center; font: 500 10.5px/1 var(--mono); font-style: normal; color: var(--dim); text-transform: uppercase; letter-spacing: .08em; }
.palette-opt[aria-selected="true"] { background: var(--surface-3); border-left-color: var(--green); }
.palette-opt[aria-selected="true"] b { color: var(--green); }
.palette-empty { padding: 18px 16px; font: 400 13px/1.5 var(--mono); color: var(--muted); }
.palette-foot { display: flex; gap: 6px; align-items: center; padding: 10px 16px; border-top: 1px solid var(--line); font: 400 11px/1 var(--mono); color: var(--dim); }
.palette-foot kbd { min-width: 0; }
.palette-foot kbd + kbd { margin-left: -2px; }

/* ---------- help ---------- */
.help { width: min(460px, calc(100% - 24px)); padding: 0; border: 1px solid var(--line-3); border-radius: 2px; background: var(--surface); box-shadow: 0 30px 80px rgba(0, 0, 0, .7); }
.help-box { padding: 24px; }
.help h2 { font: 400 22px/1.2 var(--pixel); }
.help h2 span { color: var(--green); }
.keys { margin: 18px 0; display: grid; grid-template-columns: max-content 1fr; gap: 10px 18px; align-items: center; }
.keys > div { display: contents; }
.keys dd { margin: 0; color: var(--muted); }
.help-note { margin-top: 10px; font-size: 14px; color: var(--muted); }
.help-egg { font: 400 12px/1.5 var(--mono); color: var(--dim); }
.help form { margin-top: 18px; }

/* ---------- toast ---------- */
.toast { position: fixed; left: 50%; bottom: 24px; z-index: 400; max-width: calc(100% - 32px); padding: 10px 16px; border: 1px solid var(--line-3); background: var(--surface); box-shadow: 0 10px 30px rgba(0, 0, 0, .5), var(--glow); font: 500 13px/1.4 var(--mono); color: var(--green); transform: translate(-50%, 20px); opacity: 0; pointer-events: none; transition: opacity .2s, transform .25s; }
.toast.on { opacity: 1; transform: translate(-50%, 0); }

/* ---------- player ---------- */
.player { position: fixed; inset: 0; width: 100%; height: 100%; max-width: none; max-height: none; margin: 0; padding: 0; border: 0; background: linear-gradient(var(--line) 1px, transparent 1px) 0 0 / 40px 40px, linear-gradient(90deg, var(--line) 1px, transparent 1px) 0 0 / 40px 40px, var(--bg); opacity: 0; transition: opacity .2s; }
.player[open] { display: flex; flex-direction: column; }
.player.on { opacity: 1; }
.player::backdrop { background: var(--bg); }
.player-bar { display: flex; align-items: center; gap: 12px; height: 56px; padding: 0 12px; border-bottom: 1px solid var(--line-2); background: var(--surface); flex: none; }
.player-title { display: flex; align-items: baseline; gap: 10px; min-width: 0; }
.player-code { font: 500 11px/1 var(--mono); color: var(--green); letter-spacing: .1em; text-transform: uppercase; white-space: nowrap; }
.player-title h2 { font: 400 17px/1.2 var(--pixel); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.player-status { flex: 1; min-width: 0; font: 500 12px/1.3 var(--mono); color: var(--dim); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.player-status b { color: var(--green); font-weight: 500; }
.player-actions { display: flex; gap: 4px; margin-left: auto; }
.pbtn {
  display: inline-flex; align-items: center; gap: 7px;
  height: 36px; padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 2px;
  background: var(--surface-2);
  color: var(--text);
  font: 500 12px/1 var(--mono);
  text-decoration: none;
  cursor: pointer;
  transition: border-color .2s, color .2s;
}
.pbtn:hover:not(:disabled) { border-color: var(--green); color: var(--green); }
.pbtn:disabled { opacity: .4; cursor: not-allowed; }
.pbtn[aria-pressed="false"][data-act="mute"] { color: var(--green); border-color: var(--line-2); }
.pbtn-icon { width: 36px; padding: 0; justify-content: center; font-size: 20px; }
.pbtn kbd { padding: 2px 4px; font-size: 10px; }
.player-stage { position: relative; flex: 1; min-height: 0; padding: clamp(6px, 1.6vw, 20px); }
.player-screen { position: relative; width: 100%; height: 100%; border: 1px solid var(--line-3); overflow: hidden; background: var(--bg); box-shadow: 0 0 80px -20px rgba(61, 255, 143, .25); }
.player-screen iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; background: var(--bg); }
.player-screen.is-phone { position: absolute; left: 50%; top: 50%; width: 418px; height: 872px; padding: 14px; border-radius: 56px; background: #0b110d; transform-origin: center; box-shadow: 0 40px 100px -30px #000, 0 0 80px -20px rgba(61, 255, 143, .3), inset 0 0 0 2px #050806; }
.player-screen.is-phone iframe { position: relative; inset: auto; width: 390px; height: 844px; border-radius: 42px; }
.player-screen:fullscreen { border: 0; }
.player-unmax { display: none; position: absolute; top: 10px; right: 10px; z-index: 4; width: 36px; height: 36px; border: 1px solid var(--line-3); background: rgba(5, 8, 6, .8); color: var(--text); font: 400 20px/1 var(--mono); cursor: pointer; }
.player.is-max .player-bar { display: none; }
.player.is-max .player-stage { padding: 0; }
.player.is-max .player-screen { border: 0; }
.player.is-max .player-unmax { display: block; }
.player-boot { position: absolute; inset: 0; z-index: 2; display: flex; flex-direction: column; justify-content: center; padding: 32px clamp(20px, 6vw, 64px); background: var(--bg); font: 400 13px/1.9 var(--mono); color: var(--muted); transition: opacity .3s; }
.is-phone .player-boot { inset: 14px; border-radius: 42px; padding: 32px; }
.player-boot.done { opacity: 0; pointer-events: none; }
.player-boot p { opacity: 0; animation: bootline .01s forwards; }
.player-boot p:nth-child(2) { animation-delay: .1s; }
.player-boot p:nth-child(3) { animation-delay: .2s; }
.player-boot p:nth-child(4) { animation-delay: .3s; }
.player-boot .ok { color: var(--green); }
@keyframes bootline { to { opacity: 1; } }
.player-help { position: absolute; top: clamp(6px, 1.6vw, 20px); right: clamp(6px, 1.6vw, 20px); z-index: 5; width: min(340px, calc(100% - 12px)); max-height: calc(100% - 24px); overflow: auto; padding: 18px; border: 1px solid var(--line-3); background: rgba(11, 18, 14, .96); box-shadow: 0 20px 60px rgba(0, 0, 0, .6); font-size: 14px; }
.player-help h3 { font: 400 16px/1.2 var(--pixel); margin-bottom: 12px; }
.player-help .specs { margin-bottom: 14px; }
.player-help p { color: var(--muted); }
.player-help p + p { margin-top: 8px; }

/* ---------- easter egg ---------- */
html.cheat { --green: #c6ff4d; --green-2: #9fd62e; --glow: 0 0 18px rgba(198, 255, 77, .4); }
.egg { position: fixed; inset: 0; z-index: 350; pointer-events: none; }

/* ---------- responsive ---------- */
@media (max-width: 1080px) {
  .nav-links a { padding: 8px 7px; }
  .tool-kbd { display: none; }
  .tool-label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  .tool[data-action="palette"] { width: 34px; padding: 0; justify-content: center; }
}
@media (max-width: 980px) {
  .hero-inner { grid-template-columns: 1fr; align-items: start; gap: 18px; }
  .split, .about, .contact-body, .gp-hero { grid-template-columns: 1fr; }
  .game--lead { grid-template-columns: 1fr; }
  .game--lead .game-screen { border-right: 0; border-bottom: 1px solid var(--line-2); }
  .game--lead .game-shot { aspect-ratio: 16 / 10; min-height: 0; }
  .stack { margin-top: 0; }
  .xp-link { grid-template-columns: 96px minmax(0, 1fr) 72px; }
  .xp-kind { display: none; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .footer-meta { grid-column: 1 / -1; text-align: left; }
  .player-status { display: none; }
  .sec-head--inline { grid-template-columns: 1fr; }
  .sec-head--inline .sec-sub { justify-self: start; text-align: left; margin-top: 8px; }
}
@media (max-width: 860px) {
  .nav-menu { display: inline-flex; }
  .nav-links { position: absolute; top: var(--nav-h); left: 0; right: 0; display: none; flex-direction: column; align-items: stretch; gap: 0; margin: 0; padding: 8px var(--gutter) 16px; background: rgba(5, 8, 6, .97); border-bottom: 1px solid var(--line-2); }
  .nav.open .nav-links { display: flex; }
  .nav-links a { padding: 13px 4px; font-size: 15px; border-bottom: 1px solid var(--line); }
  .nav-links .hire { margin: 12px 0 0; justify-content: center; border: 1px solid var(--line-2); }
  .nav-tools { margin-left: auto; }
}
@media (max-width: 760px) {
  .games, .repos, .shots, .gp-cols { grid-template-columns: 1fr; }
  .hero { min-height: auto; }
  .stage { flex: none; min-height: 0; margin: 20px var(--gutter) 36px; }
  .wall-fallback { position: static; padding: 40px 12px 36px; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .hud-tl { left: 14px; } .hud-tr { right: 14px; }
  .play-chip { opacity: 1; transform: none; }
  .note { grid-template-columns: 1fr; }
  .note-tags { grid-column: 1; }
  .xp-link { grid-template-columns: 80px minmax(0, 1fr); gap: 14px; }
  .xp-thumb { height: 52px; }
  .xp--app .xp-thumb { width: 30px; height: 62px; margin-left: 25px; }
  .xp-open { display: none; }
  .xp-blurb { font-size: 14px; }
  .pbtn kbd { display: none; }
  .pbtn-label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  .player-bar { gap: 8px; padding: 0 8px; }
  .player-actions { gap: 3px; overflow-x: auto; }
  .player-actions .pbtn { width: 34px; padding: 0; justify-content: center; flex: none; }
  .player-code { display: none; }
  .footer-grid { grid-template-columns: 1fr; }
  .mail-prompt { display: none; }
  .gp-pager { grid-template-columns: 1fr 1fr; }
  .gp-pager a:nth-child(2) { display: none; }
  .logo-word { font-size: 13px; }
  .logo-mark { height: 22px; }
}
@media (max-width: 480px) { .pbtn[data-act="prev"], .pbtn[data-act="next"] { display: none; } }
@media (max-width: 420px) {
  .hero-cta .btn { flex: 1 1 auto; }
  .game-actions .btn { flex: 1 1 auto; }
}
html[data-motion="off"] { scroll-behavior: auto; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: .01ms !important; }
}
