/* Fonts are served from this site and preloaded in <head>, so text renders in them from the first paint.
   Inter, Outfit and JetBrains Mono are under the SIL Open Font License. */
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 100 900; font-display: swap; src: url(/fonts/inter-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-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Inter'; font-style: normal; font-weight: 100 900; font-display: swap; src: url(/fonts/inter-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: 'Outfit'; font-style: normal; font-weight: 100 900; font-display: swap; src: url(/fonts/outfit-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-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Outfit'; font-style: normal; font-weight: 100 900; font-display: swap; src: url(/fonts/outfit-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-style: normal; 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-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'JetBrains Mono'; font-style: normal; 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 {
  --ink: #0b0d12;
  --surface: #151922;
  --line: #262c38;
  --text: #e8ebf2;
  --muted: #9aa3b5;
  --brand: #c04482;
  --brand-soft: #e875af;
  --brand-pale: #f3a5cb;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--ink); }
img { max-width: 100%; }

.page {
  background: var(--ink);
  color: var(--text);
  font-family: Inter, system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  min-height: 100vh;
  overflow: hidden;
}

a { color: var(--brand-soft); text-decoration: none; transition: filter 150ms ease, color 150ms ease; }
a:hover { color: var(--brand-pale); filter: brightness(1.12); }

/* Keyboard focus: visible on every link, 2px ring with offset. */
:focus { outline: none; }
:focus-visible { outline: 2px solid var(--brand-pale); outline-offset: 3px; border-radius: 6px; }
main:focus { outline: none; }

/* Skip link: hidden until focused. */
.skip-link {
  position: absolute;
  left: 16px;
  top: -64px;
  z-index: 10;
  padding: 12px 16px;
  border-radius: 10px;
  background: var(--text);
  color: var(--ink);
  font-weight: 600;
}
.skip-link:focus-visible { top: 16px; color: var(--ink); }

/* Anchored sections land below the top edge, not glued to it. */
section[id] { scroll-margin-top: -40px; }

/* Horizontal scroll areas (tables, roadmap, code on small screens). */
.hscroll-wrap { position: relative; }
.hscroll { scrollbar-width: thin; scrollbar-color: #3A4150 transparent; }
.hscroll::-webkit-scrollbar { height: 8px; }
.hscroll::-webkit-scrollbar-thumb { background: #3A4150; border-radius: 8px; }
.hscroll::-webkit-scrollbar-track { background: transparent; }
.hscroll-wrap::before, .hscroll-wrap::after {
  content: ""; position: absolute; top: 0; bottom: 12px; width: 56px; z-index: 1;
  pointer-events: none; opacity: 0; transition: opacity 200ms ease;
}
.hscroll-wrap::before { left: 0; background: linear-gradient(to right, var(--surface), transparent); }
.hscroll-wrap::after { right: 0; background: linear-gradient(to left, var(--surface), transparent); }
.hscroll-wrap.more-left::before, .hscroll-wrap.more-right::after { opacity: 1; }

/* "Sound familiar?" stage */
.why-stage { display: grid; grid-template-columns: minmax(0, 1.2fr) auto minmax(0, 1fr); gap: 32px; align-items: center; }
.why-pile { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 4px; padding: 14px 10px; }
.ow {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 10px;
  box-shadow: 0 18px 40px -18px rgba(0, 0, 0, 0.8);
  transform: translate(var(--x), var(--y)) rotate(var(--r));
  margin: -6px;
}
.why-arrow { display: flex; justify-content: center; }

@media (max-width: 900px) {
  .why-stage { grid-template-columns: minmax(0, 1fr); }
  .why-arrow svg { transform: rotate(90deg); }
}
@media (max-width: 820px) {
  .nav-link { display: none; }
  .nav-items { gap: 12px !important; }
}
@media (max-width: 560px) {
  .why-grid th:nth-child(7), .why-grid td:nth-child(7) { display: none; }
  .why-pile { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ow { --x: 0px !important; --y: 0px !important; margin: -3px; }
  .ow:nth-child(n + 7) { display: none; }
}
/* Phones: tighter vertical rhythm. Sections carry inline spacing, so these override it. */
@media (max-width: 640px) {
  main [style*="padding: 80px 24px 80px"] { padding-top: 40px !important; padding-bottom: 40px !important; }
  main [style*="padding: 80px 24px 0"] { padding-top: 40px !important; }
  main [style*="padding-top: 80px"] { padding-top: 40px !important; }
  main [style*="padding: 0 24px 80px"] { padding-bottom: 40px !important; }
  main [style*="margin-top: 72px"] { margin-top: 40px !important; }
  main #top { padding-top: 48px !important; padding-bottom: 40px !important; }
  main [style*="margin-bottom: 40px"],
  main [style*="margin-bottom: 48px"],
  main [style*="margin-bottom: 56px"] { margin-bottom: 28px !important; }
  section[id] { scroll-margin-top: -16px; }
}
@media (max-width: 420px) {
  .nav-gh-label { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  a { transition: none; }
  .hscroll-wrap::before, .hscroll-wrap::after { transition: none; }
}
