:root {
  --bg: #04060d;
  --glass: rgba(13, 18, 36, 0.55);
  --line: rgba(170, 190, 255, 0.14);
  --line-strong: rgba(170, 190, 255, 0.28);
  --text: #eef1fb;
  --muted: #9aa5c8;
  --accent: #ff7a45;
  --accent-2: #6aa8ff;
  --violet: #9b7bff;
  --danger: #ff5c7a;
  --ok: #4fd1a5;
  --radius: 20px;
  --font-head: "Space Grotesk", system-ui, sans-serif;
  --font-body: "Inter", system-ui, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 84px; color-scheme: dark; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font: 16px/1.65 var(--font-body); min-height: 100vh;
  overflow-x: hidden; -webkit-font-smoothing: antialiased;
}

/* ---------- scene layers ---------- */
#starfield { position: fixed; inset: 0; width: 100%; height: 100%; z-index: -2; display: block; }
.nebula { position: fixed; inset: 0; z-index: -1; pointer-events: none; overflow: hidden; }
.nebula i { position: absolute; border-radius: 50%; will-change: transform; }
.nebula i:nth-child(1) {
  width: 70vw; height: 70vw; left: -20vw; top: -25vw;
  background: radial-gradient(circle, rgba(70, 90, 230, 0.30), transparent 65%);
  transform: translate3d(calc(var(--px, 0) * -26px), calc(var(--py, 0) * -18px), 0);
}
.nebula i:nth-child(2) {
  width: 60vw; height: 60vw; right: -18vw; top: 5vh;
  background: radial-gradient(circle, rgba(170, 70, 200, 0.21), transparent 65%);
  transform: translate3d(calc(var(--px, 0) * 40px), calc(var(--py, 0) * 26px), 0);
}
.nebula i:nth-child(3) {
  width: 80vw; height: 50vw; left: 10vw; bottom: -28vw;
  background: radial-gradient(ellipse, rgba(255, 110, 60, 0.14), transparent 65%);
  transform: translate3d(calc(var(--px, 0) * -16px), calc(var(--py, 0) * -30px), 0);
}
.progress {
  position: fixed; top: 0; left: 0; width: 100%; height: 2px; z-index: 40;
  transform: scaleX(0); transform-origin: 0 50%;
  background: linear-gradient(90deg, var(--accent), var(--violet), var(--accent-2));
}

a { color: var(--accent-2); }
a:hover { color: #a9ccff; }
code { background: #ffffff14; padding: 1px 5px; border-radius: 4px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.muted { color: var(--muted); }

/* ---------- header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 30;
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 16px;
  padding: 12px clamp(16px, 4vw, 40px);
}
.site-header::before { /* frosted fade instead of a hard-edged bar */
  content: ""; position: absolute; inset: 0 0 -22px; z-index: -1; pointer-events: none;
  background: linear-gradient(to bottom, rgba(4, 6, 13, 0.9), rgba(4, 6, 13, 0));
  backdrop-filter: blur(10px);
  -webkit-mask-image: linear-gradient(#000 60%, transparent); mask-image: linear-gradient(#000 60%, transparent);
}
.brand { display: inline-flex; align-items: center; font: 700 1.1rem var(--font-head); color: var(--text); text-decoration: none; letter-spacing: 0.01em; }
.brand:hover { color: #fff; }
.logo-dot {
  width: 14px; height: 14px; margin-right: 9px; border-radius: 50%;
  background: radial-gradient(circle at 30% 30%, #ffd1b3, var(--accent) 45%, var(--violet));
  box-shadow: 0 0 14px rgba(255, 122, 69, 0.7);
}
.pill-nav {
  display: inline-flex; gap: 2px; padding: 4px; border-radius: 99px;
  background: rgba(255, 255, 255, 0.04); border: 1px solid var(--line);
}
.pill-nav a {
  color: var(--muted); text-decoration: none; font-size: 0.88rem; font-weight: 500;
  padding: 7px 15px; border-radius: 99px; transition: color 0.2s, background 0.2s;
}
.pill-nav a:hover { color: var(--text); }
.pill-nav a.active { color: var(--text); background: rgba(255, 255, 255, 0.1); }
.key-btn { justify-self: end; }

/* ---------- buttons & inputs ---------- */
button, .btn {
  font: 600 0.93rem var(--font-body); border: 0; border-radius: 12px; padding: 10px 18px; cursor: pointer;
  display: inline-flex; align-items: center; gap: 8px; text-decoration: none;
  color: #1b0a03; background: linear-gradient(135deg, #ffa176, var(--accent));
  box-shadow: 0 8px 24px -10px rgba(255, 122, 69, 0.7);
  transition: transform 0.15s, box-shadow 0.15s, background 0.15s;
}
button:hover, .btn:hover { transform: translateY(-2px); box-shadow: 0 14px 30px -12px rgba(255, 122, 69, 0.85); color: #1b0a03; }
button.ghost, .btn.ghost {
  background: rgba(255, 255, 255, 0.04); color: var(--text);
  border: 1px solid var(--line-strong); box-shadow: none;
}
button.ghost:hover, .btn.ghost:hover { background: rgba(255, 255, 255, 0.1); color: var(--text); box-shadow: none; }
button:focus-visible, a:focus-visible, input:focus-visible { outline: 2px solid var(--accent-2); outline-offset: 3px; }
input[type="date"], input[type="search"], dialog input {
  background: rgba(8, 12, 28, 0.8); color: var(--text); color-scheme: dark;
  border: 1px solid var(--line-strong); border-radius: 12px; padding: 9px 13px; font: inherit;
}
input[type="search"] { min-width: 240px; }
.controls { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.check { display: flex; gap: 8px; align-items: center; color: var(--muted); font-size: 0.92rem; cursor: pointer; }

/* ---------- hero ---------- */
main { max-width: 1240px; margin: 0 auto; padding: 0 clamp(16px, 4vw, 32px) 72px; }
.hero {
  position: relative; min-height: min(860px, calc(100vh - 60px));
  display: grid; grid-template-columns: minmax(0, 1.02fr) minmax(0, 0.98fr);
  align-items: center; gap: clamp(8px, 3vw, 48px); padding: clamp(24px, 5vh, 64px) 0 64px;
}
.eyebrow {
  display: inline-flex; align-items: center; gap: 10px; margin: 0;
  font: 600 0.72rem var(--font-body); letter-spacing: 0.18em; text-transform: uppercase; color: #bccaff;
  padding: 7px 14px; border: 1px solid var(--line); border-radius: 99px; background: rgba(255, 255, 255, 0.03);
}
.pulse { width: 8px; height: 8px; border-radius: 50%; background: var(--ok); animation: ping 2.2s infinite; }
@keyframes ping { 0% { box-shadow: 0 0 0 0 rgba(79, 209, 165, 0.55); } 70%, 100% { box-shadow: 0 0 0 10px rgba(79, 209, 165, 0); } }
.hero h1 {
  font: 700 clamp(2.6rem, 6.3vw, 5.3rem)/0.98 var(--font-head); letter-spacing: -0.035em; margin: 22px 0 22px;
}
.hero h1 em {
  font-style: normal; display: inline-block;
  background: linear-gradient(95deg, #fff 0%, #ffc9a8 34%, var(--accent) 66%, var(--violet) 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  filter: drop-shadow(0 10px 34px rgba(255, 122, 69, 0.35));
}
.lede { color: #b4bedd; font-size: clamp(1rem, 1.5vw, 1.18rem); max-width: 540px; margin: 0 0 28px; }
.hero-cta { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 34px; }
.hero-cta .btn { padding: 13px 24px; font-size: 1rem; }

.status { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.status li {
  display: inline-flex; align-items: center; gap: 8px; font-size: 0.82rem; color: var(--muted);
  padding: 6px 12px; border-radius: 99px; border: 1px solid var(--line); background: rgba(255, 255, 255, 0.03);
}
.status i { width: 7px; height: 7px; border-radius: 50%; background: #6b7699; animation: blink 1.2s ease-in-out infinite; }
.status li[data-state="ok"] { color: var(--text); }
.status li[data-state="ok"] i { background: var(--ok); box-shadow: 0 0 8px var(--ok); animation: none; }
.status li[data-state="fail"] { color: #ffc2cd; border-color: rgba(255, 92, 122, 0.35); }
.status li[data-state="fail"] i { background: var(--danger); box-shadow: 0 0 8px var(--danger); animation: none; }
@keyframes blink { 50% { opacity: 0.3; } }

.hero-scene { position: relative; width: 100%; max-width: 640px; aspect-ratio: 1; justify-self: center; }
.hero-scene canvas { width: 100%; height: 100%; display: block; }
.scroll-cue {
  position: absolute; left: 50%; bottom: 14px; width: 24px; height: 38px; margin-left: -12px;
  border: 1.5px solid var(--line-strong); border-radius: 14px; opacity: 0.8;
}
.scroll-cue span { position: absolute; left: 50%; top: 7px; width: 3px; height: 7px; margin-left: -1.5px; border-radius: 2px; background: var(--text); animation: cue 1.8s ease-in-out infinite; }
@keyframes cue { 0% { opacity: 0; transform: translateY(0); } 30% { opacity: 1; } 100% { opacity: 0; transform: translateY(12px); } }

/* ---------- glass panels ---------- */
.panel {
  position: relative; margin-top: 40px; padding: clamp(20px, 3.2vw, 38px); overflow: hidden;
  background: var(--glass); border: 1px solid var(--line); border-radius: var(--radius);
  backdrop-filter: blur(14px) saturate(1.25);
  box-shadow: 0 30px 80px -40px rgba(0, 0, 0, 0.8), inset 0 1px 0 rgba(255, 255, 255, 0.05);
}
.panel::before { /* cursor-following glow */
  content: ""; position: absolute; inset: 0; pointer-events: none; border-radius: inherit;
  background: radial-gradient(520px circle at var(--mx, 50%) var(--my, -20%), rgba(106, 168, 255, 0.10), transparent 60%);
}
.panel::after { /* cursor-following border light */
  content: ""; position: absolute; inset: 0; pointer-events: none; border-radius: inherit; padding: 1px; opacity: 0;
  background: radial-gradient(280px circle at var(--mx, 50%) var(--my, 0), rgba(255, 160, 110, 0.65), transparent 60%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor;
  mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0); transition: opacity 0.3s;
}
.panel:hover::after { opacity: 1; }
.panel > * { position: relative; }
.panel-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin-bottom: 26px; }
.panel h2 { font: 700 clamp(1.5rem, 2.6vw, 2.1rem)/1.15 var(--font-head); letter-spacing: -0.02em; margin: 0; }
.kicker { font: 600 0.72rem var(--font-body); letter-spacing: 0.18em; text-transform: uppercase; color: var(--accent); margin: 0 0 8px; }
.sub { color: var(--muted); margin: 6px 0 0; font-size: 0.95rem; max-width: 640px; }

/* reveal on scroll (only active when fx.js adds .fx) */
.fx .reveal {
  opacity: 0; transform: translateY(34px) scale(0.985); filter: blur(8px);
  transition: opacity 0.9s ease, transform 0.9s cubic-bezier(0.2, 0.7, 0.2, 1), filter 0.9s ease;
  transition-delay: var(--d, 0s);
}
.fx .reveal.in { opacity: 1; transform: none; filter: none; }

/* 3D tilt + glare */
.tilt { position: relative; transition: transform 0.22s ease-out, box-shadow 0.22s; will-change: transform; }
.tilt::after {
  content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; opacity: 0; transition: opacity 0.25s;
  background: radial-gradient(circle at var(--gx, 50%) var(--gy, 50%), rgba(255, 255, 255, 0.2), transparent 55%);
}
.tilt.is-tilting::after { opacity: 1; }
.tilt.is-tilting { transition: transform 0.05s linear; }

/* states */
.loading, .error, .empty { padding: 32px; text-align: center; border-radius: 12px; color: var(--muted); grid-column: 1 / -1; }
.loading::before {
  content: ""; display: inline-block; width: 14px; height: 14px; margin-right: 10px; vertical-align: -2px;
  border: 2px solid var(--muted); border-top-color: transparent; border-radius: 50%; animation: spin 0.8s linear infinite;
}
.error { color: #ffc2cd; background: rgba(255, 92, 122, 0.08); border: 1px solid rgba(255, 92, 122, 0.3); }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- APOD ---------- */
.apod { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: clamp(20px, 3vw, 40px); align-items: start; }
.apod-media { border-radius: 14px; overflow: hidden; box-shadow: 0 30px 80px -24px rgba(80, 120, 255, 0.45), 0 0 0 1px var(--line); }
.apod-media img, .apod-media iframe, .apod-media video { width: 100%; display: block; background: #000; }
.apod-media img { min-height: 220px; object-fit: cover; }
.apod-media iframe { aspect-ratio: 16 / 9; border: 0; }
.apod h3 { font: 700 clamp(1.4rem, 2.3vw, 1.9rem)/1.2 var(--font-head); letter-spacing: -0.01em; margin: 0 0 6px; }
.meta { color: var(--accent); font-size: 0.8rem; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; margin-bottom: 16px; }
.apod-text p { margin: 0 0 14px; color: #ced5ee; }
.apod-text .credit { color: var(--muted); font-size: 0.86rem; }
.apod-text .teaser { color: var(--muted); font-size: 0.9rem; padding-top: 12px; border-top: 1px solid var(--line); }

/* ---------- asteroids ---------- */
.neo-top { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(220px, 0.5fr); gap: 20px; margin-bottom: 22px; align-items: stretch; }
.radar-wrap { position: relative; }
#neoViz {
  width: 100%; aspect-ratio: 16 / 10; display: block; border-radius: 16px; cursor: crosshair;
  background: radial-gradient(ellipse at 50% 55%, rgba(40, 62, 140, 0.32), rgba(6, 9, 22, 0.55) 72%);
  border: 1px solid var(--line);
}
.radar-legend { margin: 10px 2px 0; font-size: 0.8rem; color: var(--muted); display: flex; flex-wrap: wrap; gap: 6px 14px; align-items: center; }
.radar-legend .dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-right: 6px; }
.dot.safe { background: #78c8ff; box-shadow: 0 0 8px #78c8ff; }
.dot.haz { background: var(--danger); box-shadow: 0 0 8px var(--danger); }
.tip {
  position: absolute; z-index: 3; pointer-events: none; left: 0; top: 0; white-space: nowrap;
  background: rgba(8, 12, 28, 0.92); border: 1px solid var(--line-strong); border-radius: 10px;
  padding: 6px 10px; font-size: 0.8rem; box-shadow: 0 10px 30px -10px #000;
}
.stats { display: grid; gap: 10px; align-content: stretch; grid-auto-rows: 1fr; }
.stat { border: 1px solid var(--line); border-radius: 14px; padding: 12px 16px; background: rgba(255, 255, 255, 0.03); }
.stat b { display: block; font: 700 1.55rem/1.2 var(--font-head); letter-spacing: -0.01em; }
.stat span { color: var(--muted); font-size: 0.82rem; }
.table-wrap { overflow-x: auto; border-radius: 12px; }
table { width: 100%; border-collapse: collapse; font-size: 0.92rem; }
th, td { text-align: left; padding: 11px 14px; border-bottom: 1px solid var(--line); white-space: nowrap; }
th { color: var(--muted); font-weight: 500; font-size: 0.76rem; text-transform: uppercase; letter-spacing: 0.08em; }
tbody tr { transition: background 0.15s; }
tbody tr:hover { background: rgba(255, 255, 255, 0.05); }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; }
.badge { display: inline-block; padding: 2px 10px; border-radius: 99px; font-size: 0.76rem; background: rgba(79, 209, 165, 0.12); color: var(--ok); }
.badge.haz { background: rgba(255, 92, 122, 0.15); color: var(--danger); }
.bar { height: 6px; border-radius: 3px; background: linear-gradient(90deg, var(--accent), var(--accent-2)); min-width: 3px; }

/* ---------- EPIC ---------- */
.epic { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(24px, 4vw, 56px); align-items: center; }
.epic-main { position: relative; width: 100%; max-width: 520px; aspect-ratio: 1; margin: 18px auto; border-radius: 50%; }
.epic-main::before { /* atmosphere glow */
  content: ""; position: absolute; inset: -14%; border-radius: 50%; pointer-events: none;
  background: radial-gradient(circle, rgba(90, 150, 255, 0.34) 40%, rgba(90, 150, 255, 0.10) 60%, transparent 72%);
}
.epic-main img { position: relative; width: 100%; height: 100%; display: block; border-radius: 50%; object-fit: cover; box-shadow: 0 0 90px rgba(60, 120, 255, 0.35); }
.epic-main .hud {
  position: absolute; inset: -5%; border-radius: 50%; pointer-events: none;
  border: 1px dashed rgba(150, 190, 255, 0.32); animation: spin 90s linear infinite;
}
.epic-main .hud.two { inset: -10%; border-style: solid; border-color: rgba(150, 190, 255, 0.10); animation-duration: 140s; animation-direction: reverse; }
.epic-strip { display: flex; gap: 8px; flex-wrap: wrap; margin: 16px 0; }
.epic-strip button {
  padding: 0; width: 54px; height: 54px; border-radius: 50%; overflow: hidden; background: none; box-shadow: none;
  border: 2px solid transparent; transition: border-color 0.15s, transform 0.15s;
}
.epic-strip button:hover { box-shadow: none; transform: scale(1.08); }
.epic-strip button[aria-pressed="true"] { border-color: var(--accent); }
.epic-strip img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* ---------- library ---------- */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 16px; }
.card {
  display: flex; flex-direction: column; overflow: hidden; text-decoration: none; color: var(--text);
  border: 1px solid var(--line); border-radius: 14px; background: rgba(8, 12, 28, 0.7);
}
.card:hover { color: var(--text); border-color: var(--line-strong); box-shadow: 0 24px 50px -24px rgba(80, 120, 255, 0.55); }
.card .thumb { overflow: hidden; aspect-ratio: 4 / 3; background: #000; }
.card img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform 0.5s ease; }
.card:hover img { transform: scale(1.07); }
.card .cap { padding: 12px 14px; font-size: 0.88rem; }
.card .cap small { display: block; color: var(--muted); margin-top: 4px; }
.more-wrap { text-align: center; margin-top: 22px; }

/* ---------- about ---------- */
.about-grid { list-style: none; margin: 22px 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 14px; counter-reset: n; }
.about-grid li {
  counter-increment: n; padding: 18px; border: 1px solid var(--line); border-radius: 14px; color: var(--muted); font-size: 0.92rem;
  background: rgba(255, 255, 255, 0.03);
}
.about-grid li::before { content: "0" counter(n); display: block; font: 700 0.8rem var(--font-head); color: var(--accent); letter-spacing: 0.12em; margin-bottom: 8px; }
.about-grid b { display: block; color: var(--text); font: 600 1rem var(--font-head); margin-bottom: 6px; }


/* ---------- game ---------- */
.game-hud { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; font-size: 0.88rem; color: var(--muted); }
.game-hud > span { display: inline-flex; align-items: center; gap: 8px; padding: 7px 14px; border: 1px solid var(--line); border-radius: 99px; background: rgba(255, 255, 255, 0.03); }
.game-hud b { color: var(--text); font: 700 1rem var(--font-head); font-variant-numeric: tabular-nums; }
.pips { display: inline-flex; gap: 5px; }
.pip { width: 10px; height: 10px; border-radius: 50%; border: 1.5px solid var(--line-strong); }
.pip.on { background: var(--accent-2); border-color: var(--accent-2); box-shadow: 0 0 8px var(--accent-2); }
.game-wrap {
  position: relative; max-width: 960px; margin: 0 auto; overflow: hidden; border-radius: 16px; border: 1px solid var(--line);
  background: radial-gradient(ellipse at 50% 0%, rgba(40, 62, 140, 0.28), rgba(4, 6, 13, 0.82) 70%);
}
.game-wrap canvas { display: block; width: 100%; height: auto; cursor: crosshair; outline: none; }
.game-wrap.playing canvas { touch-action: none; cursor: none; }
.game-overlay { position: absolute; inset: 0; display: grid; place-items: center; padding: 20px; background: rgba(4, 6, 13, 0.62); backdrop-filter: blur(3px); }
.game-overlay[hidden] { display: none; }
.game-card { max-width: 440px; text-align: center; }
.game-card h3 { font: 700 clamp(1.4rem, 3vw, 1.8rem) var(--font-head); letter-spacing: -0.02em; margin: 0 0 10px; }
.game-card p { color: #c4cce8; margin: 0 0 10px; font-size: 0.95rem; }
.game-card .game-note { color: var(--muted); font-size: 0.85rem; margin-bottom: 18px; }
.game-card button { padding: 12px 26px; font-size: 1rem; }
.game-foot { max-width: 960px; margin: 22px auto 0; }
.log-title { font: 600 0.74rem var(--font-body); letter-spacing: 0.16em; text-transform: uppercase; color: var(--muted); margin: 0; }
.game-log { list-style: none; margin: 10px 0 0; padding: 0; display: grid; gap: 6px; font-size: 0.88rem; color: var(--muted); min-height: 24px; }
.game-log li { padding: 8px 12px; border: 1px solid var(--line); border-radius: 10px; background: rgba(255, 255, 255, 0.03); }
.game-log b { color: var(--text); font-weight: 600; }
.game-log em { font-style: normal; color: var(--danger); font-size: 0.74rem; border: 1px solid rgba(255, 92, 122, 0.4); padding: 1px 8px; border-radius: 99px; }

/* ---------- dialog & footer ---------- */
dialog { background: #0b1124; color: var(--text); border: 1px solid var(--line-strong); border-radius: var(--radius); padding: 26px; max-width: 460px; width: calc(100% - 32px); }
dialog::backdrop { background: rgba(0, 0, 0, 0.65); backdrop-filter: blur(4px); }
dialog h3 { font: 700 1.25rem var(--font-head); margin: 0 0 8px; }
dialog p { color: var(--muted); font-size: 0.92rem; }
dialog label { display: block; font-size: 0.85rem; color: var(--muted); margin-bottom: 6px; }
dialog input { width: 100%; }
.dialog-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 18px; }
.site-footer { text-align: center; color: var(--muted); font-size: 0.85rem; padding: 28px 16px 44px; border-top: 1px solid var(--line); background: rgba(4, 6, 13, 0.6); }

/* ---------- responsive ---------- */
@media (max-width: 960px) {
  .hero { grid-template-columns: 1fr; min-height: 0; padding-bottom: 40px; }
  .hero-scene { order: -1; max-width: 420px; margin-bottom: -20px; }
  .scroll-cue { display: none; }
  .apod, .epic, .neo-top { grid-template-columns: 1fr; }
  .stats { grid-template-columns: repeat(2, 1fr); grid-auto-rows: auto; }
  .pill-nav { display: none; }
  .site-header { grid-template-columns: 1fr auto; }
}
@media (max-width: 520px) {
  input[type="search"] { min-width: 0; width: 100%; flex: 1; }
  .stats { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
