@font-face { font-family: "Instrument Sans"; font-weight: 400 700; font-display: swap; src: url(/fonts/instrument-sans.woff2) format("woff2"); }
@font-face { font-family: "JetBrains Mono"; font-weight: 400 700; font-display: swap; src: url(/fonts/jetbrains-mono.woff2) format("woff2"); }

:root {
  --bg: #09090A;
  --ink: #EDEBE6;
  --dim: rgba(237, 235, 230, .80);
  --faint: rgba(237, 235, 230, .76);
  --line: rgba(237, 235, 230, .24);
  --accent: #C7FF3D;
  --body: "Instrument Sans", system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, monospace;
  --pad: clamp(24px, 6vw, 80px);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 72px; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 17px/1.6 var(--body); -webkit-font-smoothing: antialiased; overflow-x: hidden; }
h1, h2, h3, p, ul, ol, figure { margin: 0; padding: 0; }
ul, ol { list-style: none; }
a { color: inherit; text-decoration: none; }
code { font: 400 .88em/1 var(--mono); }
:focus-visible { outline: 1px solid var(--accent); outline-offset: 4px; }
::selection { background: var(--accent); color: var(--bg); }

.bg { position: fixed; inset: 0; width: 100%; height: 100%; image-rendering: pixelated; pointer-events: none; z-index: 0; opacity: 0; transition: opacity 1.6s ease; }
.bg.on { opacity: 1; }
.nav, main, .foot { position: relative; z-index: 1; }

/* underline-on-hover, as on seyser.org */
.u, .nav-links a, .foot a {
  background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat;
  transition: background-size .35s ease, color .2s;
}
.u { background-size: 100% 1px; }
.nav-links a:hover, .foot a:hover, .u:hover { background-size: 100% 1px; color: var(--ink); }

.nav { position: sticky; top: 0; display: flex; align-items: center; justify-content: space-between; gap: 24px; height: 64px; padding: 0 var(--pad); background: rgba(9, 9, 10, .96); }
.logo { display: inline-flex; align-items: center; gap: 10px; font: 600 17px/1 var(--body); letter-spacing: -.01em; }
.nav-links { display: flex; gap: 28px; font-size: 14px; color: var(--dim); }

.eyebrow, .tag, .hint, figcaption, .n { font: 400 11px/1.4 var(--mono); letter-spacing: .16em; text-transform: uppercase; color: var(--faint); }

.hero { min-height: calc(100dvh - 64px); display: flex; flex-direction: column; justify-content: flex-end; padding: 0 var(--pad) clamp(40px, 9vh, 112px); max-width: 900px; }
.hero > * { animation: rise 1s cubic-bezier(.2, .8, .2, 1) both; }
.hero > :nth-child(2) { animation-delay: .06s; }
.hero > :nth-child(3) { animation-delay: .12s; }
.hero > :nth-child(4) { animation-delay: .18s; }
.hero > :nth-child(5) { animation-delay: .6s; }
@keyframes rise { from { opacity: 0; transform: translateY(10px); } }
h1 { margin-top: 20px; font: 500 clamp(42px, 7vw, 92px)/.95 var(--body); letter-spacing: -.04em; text-wrap: balance; }
.lede { margin-top: 24px; max-width: 46ch; font-size: clamp(16px, 1.4vw, 19px); color: var(--dim); text-wrap: pretty; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 40px; }
.btn { display: inline-flex; align-items: center; height: 44px; padding: 0 22px; border-radius: 999px; font: 500 15px/1 var(--body); border: 1px solid var(--line); transition: transform .2s, background .2s, border-color .2s; }
.btn-light { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.btn-light:hover { background: #fff; transform: translateY(-1px); }
.btn-ghost { backdrop-filter: blur(6px); }
.btn-ghost:hover { border-color: var(--dim); }
.hint { margin-top: 48px; }
@media (hover: none) { .hint { display: none; } }

.sec { padding: clamp(96px, 14vh, 160px) var(--pad); max-width: 1280px; }
.sec-head { display: flex; align-items: center; gap: 20px; margin-bottom: 40px; }
.rule { flex: 1; height: 1px; background: var(--line); }
h2 { font: 500 clamp(32px, 4.4vw, 56px)/1.02 var(--body); letter-spacing: -.035em; text-wrap: balance; }
h3 { font: 500 18px/1.3 var(--body); letter-spacing: -.01em; }
.sec p:not(.lede):not(.note) { margin-top: 8px; font-size: 15px; color: var(--dim); }

.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); margin-top: 64px; border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.grid li { padding: 28px 24px 32px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); background: rgba(9, 9, 10, .72); backdrop-filter: blur(4px); transition: background .3s; }
.grid li:hover { background: rgba(20, 20, 22, .85); }
.grid h3 { margin-top: 28px; font-family: var(--mono); font-size: 15px; }
.grid li:hover h3 { color: var(--accent); }

.rows { margin-top: 56px; border-top: 1px solid var(--line); }
.rows li { display: grid; grid-template-columns: 64px 1fr; gap: 24px; padding: 28px 0; border-bottom: 1px solid var(--line); }
.rows .n { padding-top: 4px; }
.rows div { max-width: 60ch; }

.code-pair { display: grid; grid-template-columns: repeat(auto-fit, minmax(340px, 1fr)); gap: 16px; margin-top: 56px; }
.code { position: relative; border: 1px solid var(--line); border-radius: 12px; background: rgba(14, 14, 16, .9); backdrop-filter: blur(6px); overflow: hidden; }
figcaption { padding: 14px 20px; border-bottom: 1px solid var(--line); }
pre { margin: 0; padding: 20px; overflow-x: auto; font: 400 13px/1.7 var(--mono); color: var(--ink); }
pre code { font: inherit; }
pre s { text-decoration: none; color: var(--accent); }
.copy { position: absolute; top: 9px; right: 12px; font: 400 11px/1 var(--mono); letter-spacing: .1em; text-transform: uppercase; color: var(--dim); background: none; border: 1px solid var(--line); border-radius: 999px; padding: 6px 10px; cursor: pointer; }
.copy:hover { color: var(--ink); border-color: var(--dim); }
.note { margin-top: 24px; font-size: 14px; color: var(--faint); }

.foot { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 16px; padding: 32px var(--pad); border-top: 1px solid var(--line); font: 400 12px/1 var(--mono); color: var(--faint); }
.foot ul { display: flex; gap: 20px; }

@media (max-width: 640px) {
  .nav-links { gap: 12px; font-size: 13px; } .nav-links a:last-child { display: none; }
  .logo { font-size: 0; gap: 0; }
  .rows li { grid-template-columns: 1fr; gap: 8px; }
}
@media (prefers-reduced-motion: reduce) {
  .hero > * { animation: none; }
  .bg { transition: none; }
  html { scroll-behavior: auto; }
}


/* Home: the hero is the whole page, exactly one screen, no scrolling. */
body.home { height: 100vh; height: 100dvh; overflow: hidden; display: flex; flex-direction: column; }
body.home main { flex: 1; min-height: 0; display: flex; }
body.home .hero { min-height: 0; flex: 1; padding-bottom: clamp(24px, 6vh, 80px); }
body.home .foot { border-top: 0; padding-top: 0; padding-bottom: 24px; }
@media (max-height: 620px) { body.home .hint { display: none; } body.home h1 { font-size: clamp(36px, 9vh, 72px); } }

/* Subpages */
body.page { min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; }
body.page main { flex: 1; }
body.page .sec { padding-top: clamp(48px, 10vh, 120px); }
.nav-links a[aria-current="page"] { color: var(--ink); background-size: 100% 1px; }
.foot { justify-content: flex-start; gap: 28px; }
body.page h2 { max-width: 16ch; }
body.page .lede { max-width: 42ch; }
.code-pair { grid-template-columns: repeat(auto-fit, minmax(min(340px, 100%), 1fr)); }

/* Every page is exactly one screen on desktop-sized viewports; content is sized to fit. */
@media (min-width: 900px) and (min-height: 640px) {
  body.page { height: 100vh; height: 100dvh; min-height: 0; overflow: hidden; }
  body.page main { min-height: 0; display: flex; flex-direction: column; justify-content: center; }
  body.page .sec { padding-block: clamp(16px, 4vh, 48px); width: 100%; }
  body.page .foot { padding-block: 20px; }
  body.page .sec-head { margin-bottom: clamp(12px, 2.5vh, 32px); }
  body.page h2 { font-size: clamp(30px, min(4.4vw, 6vh), 56px); }
  body.page .lede { margin-top: clamp(10px, 2vh, 24px); font-size: clamp(15px, 2vh, 18px); }

  body.page .grid { margin-top: clamp(20px, 4vh, 56px); grid-template-columns: repeat(4, 1fr); }
  body.page .grid li { padding: clamp(14px, 2.2vh, 26px) 20px; }
  body.page .grid h3 { margin-top: clamp(8px, 1.6vh, 20px); }
  body.page .grid p { font-size: 14px; line-height: 1.5; }

  body.page .rows { margin-top: clamp(20px, 4vh, 56px); display: grid; grid-template-columns: 1fr 1fr; column-gap: 48px; }
  body.page .rows li { padding: clamp(16px, 3vh, 32px) 0; grid-template-columns: 40px 1fr; }

  body.page .code-pair { margin-top: clamp(20px, 4vh, 56px); }
  body.page h2 br { display: none; }
}
pre { scrollbar-width: thin; scrollbar-color: var(--line) transparent; }
@media (min-width: 900px) and (min-height: 640px) {
  body.page h2 { max-width: none; }
  body.page .code-pair { grid-template-columns: 1fr; max-width: 880px; }
  body.page .code pre { padding-block: 14px; }
}
@media (min-width: 900px) and (min-height: 640px) and (max-height: 800px) {
  body.page .grid p { font-size: 13px; }
  body.page .grid .tag { display: none; }
  body.page .grid h3 { margin-top: 0; }
}

/* Docs: fixed sidebar + independently scrolling content, page itself never scrolls on desktop. */
body.docs { height: 100vh; height: 100dvh; overflow: hidden; display: flex; flex-direction: column; }
.docs-wrap { flex: 1; min-height: 0; display: grid; grid-template-columns: 260px minmax(0, 1fr); padding-left: var(--pad); }
.side { padding: 40px 32px 40px 0; border-right: 1px solid var(--line); overflow-y: auto; background: var(--bg); }
.side .eyebrow { margin-bottom: 14px; }
.side ol, .side ul { display: grid; gap: 2px; margin-bottom: 36px; }
.side a { display: flex; align-items: center; gap: 12px; padding: 7px 0; font-size: 15px; color: var(--dim); transition: color .2s; }
.side a::before { content: "–"; font-family: var(--mono); color: var(--faint); transition: color .2s, transform .2s; }
.side a:hover { color: var(--ink); }
.side a[aria-current="page"] { color: var(--ink); }
.side a[aria-current="page"]::before { content: "—"; color: var(--accent); }
.side ul a { font-size: 14px; }

.doc { overflow-y: auto; padding: 40px clamp(24px, 5vw, 72px) 0; scrollbar-width: thin; scrollbar-color: var(--line) transparent; }
.doc article { max-width: 72ch; background: var(--bg); }
.doc-title { margin: 12px 0 0; font: 500 clamp(34px, 4vw, 52px)/1.05 var(--body); letter-spacing: -.035em; }
.doc .lede { max-width: none; }
.doc h2 { margin: 56px 0 14px; font-size: 26px; letter-spacing: -.02em; max-width: none; }
.doc p { margin-top: 12px; color: var(--dim); }
.doc b { color: var(--ink); font-weight: 600; }
.doc code { color: var(--ink); }
.doc .code { margin-top: 18px; }
.doc pre i { font-style: normal; color: var(--faint); }
.bul { display: grid; gap: 10px; margin-top: 16px; }
.bul li { position: relative; padding-left: 24px; color: var(--dim); }
.bul li::before { content: "–"; position: absolute; left: 0; color: var(--faint); font-family: var(--mono); }
.flow { margin-top: 16px; padding: 18px 20px; border: 1px solid var(--line); border-radius: 12px; font-size: 12.5px; color: var(--accent); }
.tbl { width: 100%; margin-top: 16px; border-collapse: collapse; font-size: 15px; }
.tbl td { padding: 12px 0; border-bottom: 1px solid var(--line); vertical-align: top; color: var(--dim); }
.tbl td:first-child { width: 34%; padding-right: 20px; white-space: nowrap; }

.pn { display: flex; justify-content: space-between; gap: 16px; max-width: 72ch; margin-top: 72px; padding-top: 24px; border-top: 1px solid var(--line); }
.pn a { display: grid; gap: 4px; padding: 14px 18px; border: 1px solid var(--line); border-radius: 12px; min-width: 200px; transition: border-color .2s; background: var(--bg); }
.pn a:hover { border-color: var(--dim); }
.pn a.next { text-align: right; margin-left: auto; }
.pn span { font: 400 11px/1.4 var(--mono); letter-spacing: .16em; text-transform: uppercase; color: var(--faint); }
.doc .foot { margin: 48px calc(-1 * clamp(24px, 5vw, 72px)) 0; padding-inline: clamp(24px, 5vw, 72px); background: var(--bg); }

@media (max-width: 860px) {
  body.docs { height: auto; overflow: visible; }
  .docs-wrap { display: block; padding: 0; }
  .side { padding: 20px var(--pad); border-right: 0; border-bottom: 1px solid var(--line); }
  .side ol { display: flex; flex-wrap: wrap; gap: 4px 20px; margin-bottom: 0; }
  .side ul, .side .eyebrow:not(:first-child) { display: none; }
  .doc { overflow: visible; padding: 32px var(--pad) 0; }
  .doc .foot { margin-inline: calc(-1 * var(--pad)); padding-inline: var(--pad); }
  .tbl td:first-child { white-space: normal; }
}
@media (max-width: 860px) {
  body.docs { overflow-x: hidden; }
  .pn a { min-width: 0; flex: 1; }
  .doc article, .pn { max-width: 100%; }
}
.docs-wrap { position: relative; z-index: 1; }

/* Roadmap: stations on a planned path. */
body.roadmap h2 { max-width: none; }
.track { position: relative; margin-top: clamp(28px, 6vh, 72px); }
.track-svg { position: absolute; left: 0; top: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; }
.track-svg path { fill: none; vector-effect: non-scaling-stroke; }
.tr-done { stroke: var(--accent); stroke-width: 2; }
.tr-future { stroke: var(--faint); stroke-width: 1.5; stroke-dasharray: 2 6; stroke-linecap: round; }
.follower { position: absolute; width: 10px; height: 10px; margin: -5px 0 0 -5px; border-radius: 50%; background: var(--ink); box-shadow: 0 0 0 4px rgba(199, 255, 61, .18); pointer-events: none; }

.stations { position: relative; display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); gap: 0 clamp(12px, 1.6vw, 28px); }
.st { position: relative; display: flex; flex-direction: column; padding-top: calc(var(--y) + 40px); --y: 0px; animation: rise .9s cubic-bezier(.2, .8, .2, 1) both; animation-delay: calc(var(--i) * 70ms); }
.st:nth-child(even) { --y: 46px; }
.node { position: absolute; left: 0; top: calc(var(--y) + 10px); width: 14px; height: 14px; margin-left: -1px; border-radius: 50%; border: 1.5px solid var(--faint); background: var(--bg); z-index: 1; }
.st-done .node { background: var(--accent); border-color: var(--accent); }
.st-close .node { border-color: var(--accent); background: radial-gradient(circle, var(--accent) 0 3px, var(--bg) 3.5px); }
.st-now .node { border-color: var(--accent); background: var(--bg); }
.st-now .node::after { content: ""; position: absolute; inset: -7px; border-radius: 50%; border: 1px solid var(--accent); animation: ping 2.2s ease-out infinite; }
@keyframes ping { from { transform: scale(.6); opacity: 1; } to { transform: scale(1.8); opacity: 0; } }
.st-tag { font: 400 11px/1.4 var(--mono); letter-spacing: .16em; text-transform: uppercase; color: var(--faint); }
.st-done .st-tag, .st-close .st-tag, .st-now .st-tag { color: var(--accent); }
.st h3 { margin-top: 10px; font-size: clamp(15px, 1.25vw, 18px); }
.st p { margin-top: 8px; font-size: 13.5px; line-height: 1.5; color: var(--dim); }
.st-next h3 { color: var(--dim); }
.st-next p { color: var(--faint); }

.nogo { display: flex; flex-wrap: wrap; align-items: baseline; gap: 10px 24px; margin-top: clamp(28px, 6vh, 64px); padding-top: 20px; border-top: 1px solid var(--line); font-size: 14px; color: var(--faint); }
.nogo .eyebrow { margin: 0 8px 0 0; }
.nogo s { text-decoration-color: rgba(237, 235, 230, .35); }

@media (max-width: 1100px) {
  .stations { grid-template-columns: 1fr; gap: 0; padding-left: 36px; }
  .st, .st:nth-child(even) { --y: 0px; padding: 0 0 28px; }
  .node { left: -36px; top: 3px; }
  .track-svg, .follower { display: none; }
  .stations::before { content: ""; position: absolute; left: 6px; top: 10px; bottom: 30px; border-left: 1.5px dashed var(--faint); }
}
@media (prefers-reduced-motion: reduce) { .st { animation: none; } .st-now .node::after { animation: none; } }
.nogo s { color: var(--dim); }
