/* Self-hosted fonts (SIL Open Font License 1.1, see fonts/LICENSE.txt) */
@font-face { font-family: 'Chakra Petch'; font-weight: 400; font-display: swap; src: url('../fonts/chakra-petch-400-latin-ext.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Chakra Petch'; font-weight: 400; font-display: swap; src: url('../fonts/chakra-petch-400-latin.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Chakra Petch'; font-weight: 600; font-display: swap; src: url('../fonts/chakra-petch-600-latin-ext.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Chakra Petch'; font-weight: 600; font-display: swap; src: url('../fonts/chakra-petch-600-latin.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Chakra Petch'; font-weight: 700; font-display: swap; src: url('../fonts/chakra-petch-700-latin-ext.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Chakra Petch'; font-weight: 700; font-display: swap; src: url('../fonts/chakra-petch-700-latin.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'JetBrains Mono'; font-weight: 100 800; font-display: swap; src: url('../fonts/jetbrains-mono-latin-ext.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'JetBrains Mono'; font-weight: 100 800; font-display: swap; src: url('../fonts/jetbrains-mono-latin.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }

:root {
  color-scheme: dark;
  --bg: #05080F;
  --panel: #0A1220;
  --line: #17324A;
  --line-strong: #2A5270;
  --text: #DCEBF5;
  --text-soft: #B8CCDB;
  --muted: #8FA9BD;
  --cyan: #5CE1FF;
  --blaze: #FF6A2B;
  --blaze-text: #FF8552;
  --sans: 'Chakra Petch', system-ui, sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, Menlo, monospace;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

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

a { color: var(--cyan); }
a:hover { color: #FFFFFF; }
a:focus-visible { outline: 2px solid var(--blaze); outline-offset: 3px; }

h1, h2, h3, p { margin: 0; }
img { display: block; max-width: 100%; height: auto; }

.wrap { max-width: 1200px; margin: 0 auto; padding-left: max(24px, env(safe-area-inset-left, 0px)); padding-right: max(24px, env(safe-area-inset-right, 0px)); }
.label { font-family: var(--mono); font-size: 13px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--blaze-text); }
.cyan { color: var(--cyan); }

/* header */
.site-header { border-bottom: 1px solid var(--line); }
.site-header .wrap { display: flex; flex-wrap: wrap; align-items: center; column-gap: 32px; padding-top: 6px; padding-bottom: 6px; }
.brand { display: flex; align-items: center; gap: 10px; color: #FFFFFF; text-decoration: none; font-weight: 700; font-size: 20px; letter-spacing: 0.04em; text-transform: uppercase; padding: 10px 0; }
.brand::before { content: ""; width: 12px; height: 12px; border: 2px solid var(--blaze); transform: rotate(45deg); }
.nav { display: flex; flex-wrap: wrap; column-gap: 26px; margin-left: auto; font-family: var(--mono); font-size: 13px; letter-spacing: 0.08em; text-transform: uppercase; }
.nav a { color: var(--text); text-decoration: none; padding: 13px 0; }
.nav a:hover { color: var(--cyan); }

/* hero */
.hero { position: relative; overflow: hidden; border-bottom: 1px solid var(--line); }
.hero canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero-scrim { position: absolute; inset: 0; background: linear-gradient(90deg, var(--bg) 0%, rgba(5, 8, 15, 0.82) 38%, rgba(5, 8, 15, 0) 70%); }
.hero-inner { position: relative; display: flex; flex-wrap: wrap; gap: 40px; padding-top: 72px; padding-bottom: 64px; }
.hero-copy { flex: 1 1 460px; min-width: 0; display: flex; flex-direction: column; gap: 22px; align-items: flex-start; justify-content: center; }
.hero h1 { font-size: clamp(42px, 7.2vw, 100px); line-height: 0.95; font-weight: 700; letter-spacing: -0.01em; text-transform: uppercase; color: #FFFFFF; }
.lede { font-size: 20px; max-width: 520px; background: rgba(5, 8, 15, 0.7); }
.actions { display: flex; flex-wrap: wrap; gap: 14px; padding-top: 6px; }
.btn { display: inline-block; text-decoration: none; font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase; padding: 11px 22px; border: 1px solid var(--cyan); color: var(--cyan); background: rgba(5, 8, 15, 0.8); }
.btn:hover { background: rgba(92, 225, 255, 0.12); color: #FFFFFF; }
.btn-primary { background: var(--cyan); color: var(--bg); font-weight: 700; }
.btn-primary:hover { background: #FFFFFF; border-color: #FFFFFF; color: var(--bg); }

.hud { flex: 1 1 380px; min-width: 0; min-height: 440px; display: flex; flex-direction: column; justify-content: space-between; gap: 24px; font-family: var(--mono); font-size: 12px; letter-spacing: 0.06em; }
.hud-row { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 16px; }
.hud-panel { background: rgba(5, 8, 15, 0.82); border: 1px solid var(--line); border-top: 2px solid var(--cyan); padding: 12px 14px; display: flex; flex-direction: column; gap: 4px; }
.hud-panel.end { align-self: flex-end; min-width: 240px; }
.hud-panel.hot { border-top-color: var(--blaze); gap: 6px; min-width: 250px; }
.hud-panel .k { color: var(--muted); }
.hud-panel.hot .k { color: var(--blaze-text); }
.hud-panel .v { color: #FFFFFF; font-size: 14px; }
.hud-bar { display: block; height: 8px; border: 1px solid var(--blaze); padding: 1px; }
.hud-bar span { display: block; height: 100%; width: 100%; background: var(--blaze); }
.hud-status { color: var(--cyan); font-size: 18px; font-weight: 500; }
.hud-status i { font-style: normal; animation: blink 1.4s ease-in-out infinite; }
@keyframes blink { 50% { opacity: 0.25; } }

/* sections */
.section { padding-top: 84px; padding-bottom: 24px; display: flex; flex-direction: column; gap: 30px; }
.section-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 16px; border-bottom: 1px solid var(--line); padding-bottom: 18px; }
.section-head > div { display: flex; flex-direction: column; gap: 6px; }
.section-head h2 { font-size: clamp(32px, 4.6vw, 52px); line-height: 1; font-weight: 700; text-transform: uppercase; color: #FFFFFF; }
.section-head > p { max-width: 500px; color: var(--muted); }

/* research */
.research { gap: 8px; }
.why { display: flex; flex-wrap: wrap; gap: 20px 48px; padding: 26px 0 18px; }
.why-claim { flex: 1 1 340px; min-width: 0; font-size: clamp(24px, 3vw, 34px); line-height: 1.15; font-weight: 600; color: #FFFFFF; }
.why-body { flex: 1 1 400px; min-width: 0; display: flex; flex-direction: column; gap: 12px; color: var(--text-soft); }
.entry { display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px 28px; padding: 24px 0; border-top: 1px solid var(--line); }
.entry:last-of-type { border-bottom: 1px solid var(--line); }
.status { flex: 0 0 110px; font-family: var(--mono); font-size: 12px; letter-spacing: 0.06em; }
.status.ok { color: var(--cyan); }
.status.bad { color: var(--blaze-text); }
.status.dim { color: var(--muted); }
.entry-body { flex: 999 1 340px; min-width: 0; display: flex; flex-direction: column; gap: 10px; }
.entry h3 { font-size: 24px; font-weight: 600; color: #FFFFFF; }
.entry-body > p { max-width: 700px; color: var(--text-soft); }
.entry-links { flex: 0 0 auto; display: flex; gap: 20px; }
.mono-link { font-family: var(--mono); font-size: 13px; letter-spacing: 0.06em; text-transform: uppercase; padding: 11px 0; align-self: flex-start; }
p.mono-link { color: var(--muted); }
.bars { display: flex; flex-direction: column; gap: 5px; font-family: var(--mono); font-size: 13px; max-width: 520px; }
.bars .cap { color: var(--muted); }
.bar { display: flex; align-items: center; gap: 10px; }
.bar .who { flex: 0 0 52px; color: var(--muted); }
.bar .track { flex: 1 1 0; min-width: 0; }
.bar .fill { display: block; height: 10px; background: var(--line-strong); }
.bar .num { flex: 0 0 28px; }
.bar.after-ok .who, .bar.after-ok .num { color: var(--cyan); }
.bar.after-ok .fill { background: var(--cyan); }
.bar.after-bad .who, .bar.after-bad .num { color: var(--blaze-text); }
.bar.after-bad .fill { background: var(--blaze); }
.sources { margin-top: 14px; font-family: var(--mono); font-size: 13px; color: var(--muted); }

/* games */
.games { display: grid; grid-template-columns: repeat(auto-fit, minmax(max(300px, calc(50% - 11px)), 1fr)); gap: 22px; }
.game { background: var(--panel); border: 1px solid var(--line); border-top: 2px solid var(--cyan); padding: 16px; display: flex; flex-direction: column; gap: 12px; }
.game.pending { background: none; border: 1px dashed var(--line-strong); }
.game-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.game h3 { font-size: 22px; font-weight: 600; color: #FFFFFF; }
.tag { font-family: var(--mono); font-size: 12px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--cyan); white-space: nowrap; }
.tag.dim { color: var(--muted); }
.tag.soon { color: var(--blaze-text); }
.game > p { color: var(--text-soft); flex-grow: 1; }
.shot { width: 100%; aspect-ratio: 5 / 4; object-fit: cover; image-rendering: pixelated; }
.shot.smooth { image-rendering: auto; }
.shot-empty { display: flex; align-items: center; justify-content: center; border: 1px dashed var(--line-strong); font-family: var(--mono); font-size: 12px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); }

.feature { background: var(--panel); border: 1px solid var(--line); border-top: 2px solid var(--blaze); display: flex; flex-wrap: wrap; }
.feature img { flex: 3 1 420px; min-width: 0; align-self: flex-start; aspect-ratio: 16 / 9; object-fit: cover; }
.feature-copy { flex: 2 1 320px; min-width: 0; padding: 28px; display: flex; flex-direction: column; gap: 12px; justify-content: center; }
.feature-copy h3 { font-size: clamp(30px, 3.8vw, 44px); line-height: 1; font-weight: 700; text-transform: uppercase; color: #FFFFFF; }
.feature-copy p { color: var(--text-soft); }
.feature-copy .spec { font-family: var(--mono); font-size: 13px; color: var(--muted); }

/* tools */
.tool { background: var(--panel); border: 1px solid var(--line); border-top: 2px solid var(--cyan); display: flex; flex-wrap: wrap; }
.tool-copy { flex: 1 1 320px; min-width: 0; padding: 28px; display: flex; flex-direction: column; gap: 12px; }
.tool-copy h3 { font-size: clamp(26px, 3vw, 34px); line-height: 1.05; font-weight: 700; text-transform: uppercase; color: #FFFFFF; }
.tool-copy p { color: var(--text-soft); }
.tool-copy .spec { font-family: var(--mono); font-size: 13px; color: var(--muted); }
.tool-list { flex: 1.4 1 380px; min-width: 0; margin: 0; padding: 28px; list-style: none; display: flex; flex-direction: column; gap: 10px; border-left: 1px solid var(--line); color: var(--text-soft); }
.tool-list strong { color: #FFFFFF; font-weight: 600; }
.tool + .tool { margin-top: 20px; }

/* about + footer */
.about { flex-direction: row; flex-wrap: wrap; gap: 20px 32px; padding-bottom: 100px; }
.about .label { flex: 1 1 200px; }
.about-body { flex: 999 1 520px; min-width: 0; display: flex; flex-direction: column; gap: 22px; align-items: flex-start; }
.about-body p { font-size: clamp(24px, 3.4vw, 38px); line-height: 1.2; font-weight: 600; color: #FFFFFF; max-width: 800px; }

.site-footer { border-top: 1px solid var(--line); }
.site-footer .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; padding-top: 22px; padding-bottom: 22px; font-family: var(--mono); font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }

@media (max-width: 700px) {
  .hero-inner { padding-top: 48px; gap: 28px; }
  .hud { min-height: 0; }
  .hud-panel.end { align-self: flex-start; }
  .hero-scrim { background: rgba(5, 8, 15, 0.72); }
  .section { padding-top: 64px; }
  .nav { margin-left: 0; column-gap: 20px; }
  .tool-list { border-left: 0; border-top: 1px solid var(--line); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hud-status i { animation: none; }
}
