:root {
  color-scheme: light dark;
  --bg: #f4f1ea;
  --surface: #fbfaf6;
  --band: #ebe6da;
  --ink: #14213d;
  --muted: #5b6474;
  --line: #d8d1c1;
  --accent: #1f7a72;
  --accent-ink: #ffffff;
  --warm: #d9822b;
  --ok: #2f7d4f;
  --bad: #a3392f;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #101826;
    --surface: #16213a;
    --band: #131e33;
    --ink: #e7ecf4;
    --muted: #9aa6b8;
    --line: #2a3853;
    --accent: #4fb3a8;
    --accent-ink: #0d1a1f;
    --warm: #f0a050;
    --ok: #6fcf97;
    --bad: #f08a80;
  }
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 24px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 16px/1.6 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  -webkit-text-size-adjust: 100%;
}
a { color: inherit; }
button { font: inherit; color: inherit; }
img, svg { display: block; }
:focus-visible { outline: 3px solid var(--warm); outline-offset: 3px; border-radius: 3px; }
.wrap { max-width: 1180px; margin: 0 auto; padding: 0 40px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -64px; z-index: 10; padding: 10px 14px; background: var(--ink); color: var(--bg); }
.skip:focus { top: 12px; }

/* Header */
.top { border-bottom: 1px solid var(--line); }
.top-row { display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: 76px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 700; font-size: 19px; letter-spacing: -.3px; }
.brand-mark { width: 34px; height: 34px; color: var(--ink); }
.brand small { font: 500 11px var(--mono); letter-spacing: 1.5px; text-transform: uppercase; color: var(--muted); padding-top: 4px; }
nav { display: flex; gap: 26px; font-size: 14px; }
nav a { text-decoration: none; color: var(--muted); }
nav a:hover { color: var(--ink); text-decoration: underline; text-underline-offset: 4px; }
.edge-pill { display: flex; align-items: center; gap: 8px; margin: 0; padding: 5px 12px; border: 1px solid var(--line); border-radius: 999px; font: 11px var(--mono); color: var(--muted); white-space: nowrap; }
.pulse { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 25%, transparent); }

/* Hero */
.hero { display: grid; grid-template-columns: 1fr minmax(0, 460px); gap: 64px; align-items: center; padding-top: 72px; padding-bottom: 80px; }
.kicker { margin: 0 0 10px; font: 600 11px/1.4 var(--mono); letter-spacing: 1.6px; text-transform: uppercase; color: var(--accent); }
h1 { margin: 0 0 22px; font-size: clamp(40px, 5.4vw, 64px); line-height: 1.04; letter-spacing: -2px; font-weight: 650; }
h2 { margin: 0 0 10px; font-size: clamp(26px, 3vw, 34px); line-height: 1.15; letter-spacing: -.8px; font-weight: 650; }
h3 { margin: 0 0 6px; font-size: 16px; letter-spacing: -.2px; }
.lead { max-width: 520px; margin: 0; color: var(--muted); font-size: 17px; }
.facts { display: flex; gap: 0; margin: 30px 0 0; padding: 0; list-style: none; border: 1px solid var(--line); border-radius: 10px; width: fit-content; background: var(--surface); }
.facts li { padding: 12px 22px; }
.facts li + li { border-left: 1px solid var(--line); }
.facts strong { display: block; font-size: 18px; }
.facts span { font: 11px var(--mono); color: var(--muted); }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin: 30px 0 0; }
.btn { display: inline-flex; align-items: center; gap: 8px; padding: 12px 20px; border: 1px solid var(--accent); border-radius: 8px; background: var(--accent); color: var(--accent-ink); font-size: 14px; font-weight: 600; text-decoration: none; cursor: pointer; }
.btn:hover { filter: brightness(1.08); }
.btn:disabled { opacity: .6; cursor: progress; }
.btn.ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn.ghost:hover { border-color: var(--ink); }

.map-card { margin: 0; border: 1px solid var(--line); border-radius: 14px; overflow: hidden; background: var(--surface); box-shadow: 0 18px 40px -24px rgba(20, 33, 61, .35); }
.map-bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 14px; border-bottom: 1px solid var(--line); font: 11px var(--mono); color: var(--muted); }
.zoom { display: inline-flex; border: 1px solid var(--line); border-radius: 6px; overflow: hidden; }
.zoom button { border: 0; background: transparent; padding: 4px 12px; font: 11px var(--mono); cursor: pointer; }
.zoom button + button { border-left: 1px solid var(--line); }
.zoom button[aria-pressed="true"] { background: var(--ink); color: var(--bg); }
.map { display: grid; grid-template-columns: 1fr 1fr; aspect-ratio: 1; background: #cfe1e4; }
.map[data-zoom="0"] { grid-template-columns: 1fr; }
.map img { width: 100%; height: 100%; }
.map-card figcaption { display: flex; flex-direction: column; gap: 2px; padding: 14px 16px; border-top: 1px solid var(--line); font-size: 13px; }
.map-card figcaption span { color: var(--muted); font-size: 12px; }

/* Sections */
.band { background: var(--band); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: 64px 0; }
.head { max-width: 620px; margin-bottom: 28px; }
.head p:not(.kicker) { margin: 0; color: var(--muted); }
.endpoints { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; margin: 0; padding: 0; list-style: none; }
.endpoints li { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; padding: 18px 20px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); }
.endpoints li > div { min-width: 0; }
.endpoints code { display: block; font: 13px var(--mono); color: var(--accent); overflow-wrap: anywhere; }
.endpoints p { margin: 6px 0 0; color: var(--muted); font-size: 13px; }
.copy { flex-shrink: 0; padding: 6px 12px; border: 1px solid var(--line); border-radius: 6px; background: transparent; font-size: 12px; cursor: pointer; }
.copy:hover { border-color: var(--ink); }
.note { margin: 14px 0 0; font: 12px/1.6 var(--mono); color: var(--muted); overflow-wrap: anywhere; }
.note:empty { margin: 0; }

.files { padding-top: 64px; padding-bottom: 64px; }
.head a { color: var(--accent); }
.table-wrap { border: 1px solid var(--line); border-radius: 10px; overflow-x: auto; background: var(--surface); }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th, td { padding: 14px 18px; text-align: left; vertical-align: middle; }
thead th { font: 600 11px var(--mono); letter-spacing: 1px; text-transform: uppercase; color: var(--muted); border-bottom: 1px solid var(--line); }
tbody tr + tr > * { border-top: 1px solid var(--line); }
tbody th { font-weight: 400; }
.fname { display: block; font: 600 14px var(--mono); }
.fdesc { display: block; color: var(--muted); font-size: 12px; }
td[data-size] { font-family: var(--mono); font-size: 12px; white-space: nowrap; }
tr.ok .fname::after { content: " ✓"; color: var(--ok); }
tr.bad .fname::after { content: " ✕"; color: var(--bad); }
.act { text-align: right; white-space: nowrap; }
.act a, .verify { display: inline-block; margin-left: 8px; padding: 6px 12px; border-radius: 6px; font-size: 12px; text-decoration: none; }
.act a { border: 1px solid var(--accent); color: var(--accent); font-weight: 600; }
.act a:hover { background: var(--accent); color: var(--accent-ink); }
.verify { border: 1px solid transparent; background: transparent; color: var(--muted); cursor: pointer; }
.verify:hover:not(:disabled) { color: var(--ink); text-decoration: underline; }
.verify:disabled { opacity: .5; cursor: default; }

.status-grid { display: grid; grid-template-columns: 1fr 1.1fr; gap: 48px; align-items: start; }
.status-grid .btn { margin-top: 22px; }
.panel { padding: 8px 22px 18px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); }
dl { margin: 0; }
dl > div { display: flex; justify-content: space-between; gap: 16px; padding: 11px 0; border-bottom: 1px solid var(--line); font-size: 13px; }
dt { color: var(--muted); }
dd { margin: 0; font-family: var(--mono); text-align: right; overflow-wrap: anywhere; }
.bars { display: grid; gap: 6px; margin: 14px 0 0; padding: 0; list-style: none; }
.bars:empty { display: none; }
.bars li { display: flex; align-items: center; gap: 10px; }
.bar { height: 8px; border-radius: 4px; background: var(--accent); }
.bar-label { font: 11px var(--mono); color: var(--muted); white-space: nowrap; }

.faq { padding-top: 64px; padding-bottom: 56px; display: grid; grid-template-columns: 1fr 1.6fr; gap: 48px; }
details { border-bottom: 1px solid var(--line); padding: 14px 0; }
details:first-child { padding-top: 0; }
summary { display: flex; justify-content: space-between; gap: 16px; font-weight: 600; font-size: 15px; cursor: pointer; list-style: none; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; color: var(--muted); font-weight: 400; }
details[open] summary::after { content: "−"; }
details p { margin: 10px 0 0; color: var(--muted); font-size: 14px; }

.foot { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; padding-top: 22px; padding-bottom: 32px; border-top: 1px solid var(--line); font: 12px var(--mono); color: var(--muted); }
.foot-brand { color: var(--ink); font-weight: 700; }

@media (max-width: 920px) {
  .wrap { padding: 0 24px; }
  nav { gap: 16px; }
  .edge-pill { display: none; }
  .hero { grid-template-columns: 1fr; gap: 40px; padding-top: 48px; padding-bottom: 56px; }
  .map-card { max-width: 520px; }
  .status-grid, .faq { grid-template-columns: 1fr; gap: 24px; }
}
@media (max-width: 640px) {
  .wrap { padding: 0 16px; }
  .top-row { min-height: 64px; }
  nav a:first-child { display: none; }
  nav { gap: 12px; font-size: 13px; }
  .lead { font-size: 16px; }
  h1 br { display: none; }
  .facts { width: 100%; }
  .facts li { flex: 1; padding: 10px 12px; }
  .band { padding: 44px 0; }
  .files, .faq { padding-top: 44px; padding-bottom: 44px; }
  .endpoints { grid-template-columns: 1fr; }
  .endpoints li { flex-direction: column; }
  thead { display: none; }
  table, tbody, tr, th, td { display: block; width: 100%; }
  tbody tr { padding: 12px 14px; }
  tbody tr + tr > * { border-top: 0; }
  tbody tr + tr { border-top: 1px solid var(--line); }
  th, td { padding: 2px 0; }
  td:nth-child(2) { display: inline; width: auto; color: var(--muted); font-size: 12px; }
  td[data-size] { display: inline; width: auto; margin-left: 8px; }
  .act { text-align: left; margin-top: 8px; }
  .act a, .verify { margin: 0 8px 0 0; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
