:root {
  --bg: #fbfaf7;
  --bg-alt: #f1efe8;
  --surface: #ffffff;
  --text: #1b1f23;
  --muted: #4a525a;
  --line: #d9d5c9;
  --accent: #0b6b63;
  --accent-text: #ffffff;
  --accent-soft: #dff1ee;
  --focus: #1a4fd6;
  --radius: 12px;
  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0f1417;
    --bg-alt: #151c20;
    --surface: #1a2227;
    --text: #e8ecef;
    --muted: #aab4bb;
    --line: #2d3940;
    --accent: #6fd6c9;
    --accent-text: #08201d;
    --accent-soft: #14312e;
    --focus: #8fb2ff;
  }
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 1.0625rem/1.65 var(--font);
}
img, svg { max-width: 100%; height: auto; }
a { color: var(--accent); text-underline-offset: 0.18em; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 4px; }
.skip {
  position: absolute; left: 1rem; top: -4rem; z-index: 10;
  background: var(--text); color: var(--bg); padding: 0.6rem 1rem; border-radius: 8px;
}
.skip:focus { top: 1rem; }
.wrap { width: 100%; max-width: 70rem; margin: 0 auto; padding: 0 1rem; }
@media (min-width: 40em) { .wrap { padding: 0 1.5rem; } }

header.site { border-bottom: 1px solid var(--line); }
header.site .wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.5rem 1.5rem; padding-top: 0.9rem; padding-bottom: 0.9rem; }
.brand { display: inline-flex; align-items: center; gap: 0.55rem; font-weight: 700; font-size: 1.2rem; color: var(--text); text-decoration: none; }
.brand svg { width: 28px; height: 28px; flex: none; }
nav ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 0.25rem 1.25rem; }
nav a { color: var(--text); text-decoration: none; padding: 0.35rem 0; display: inline-block; }
nav a:hover { color: var(--accent); text-decoration: underline; }

h1, h2, h3 { line-height: 1.2; margin: 0 0 0.6em; letter-spacing: -0.01em; }
h1 { font-size: clamp(2rem, 5vw, 3.1rem); }
h2 { font-size: clamp(1.5rem, 3.4vw, 2.1rem); }
h3 { font-size: 1.15rem; }
p { margin: 0 0 1em; }
.lead { font-size: 1.2rem; color: var(--muted); max-width: 40rem; }
.eyebrow { font-size: 0.85rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--accent); margin-bottom: 0.8rem; }

section { padding: 3.5rem 0; }
section.alt { background: var(--bg-alt); }
.hero { padding: 3rem 0 3.5rem; }
.hero-grid { display: grid; gap: 2.5rem; align-items: center; }
@media (min-width: 58em) { .hero-grid { grid-template-columns: 1.05fr 1fr; } }

.btn {
  display: inline-flex; flex-wrap: wrap; align-items: baseline; gap: 0.4rem;
  padding: 0.85rem 1.4rem; border-radius: 999px; font-weight: 700; text-decoration: none;
  background: var(--accent); color: var(--accent-text); border: 2px solid var(--accent);
}
a.btn:hover { filter: brightness(1.08); text-decoration: none; }
.btn small { font-weight: 600; font-size: 0.8rem; opacity: 0.9; }
.btn-pending { background: transparent; color: var(--text); border-color: var(--text); cursor: default; }
.btn-ghost { background: transparent; color: var(--accent); }
.cta-row { display: flex; flex-wrap: wrap; gap: 0.8rem 1rem; align-items: center; margin: 1.6rem 0 1rem; }
.note { font-size: 0.95rem; color: var(--muted); }

.figure { margin: 0; }
.figure figcaption { font-size: 0.9rem; color: var(--muted); margin-top: 0.6rem; }
.mock { width: 100%; border-radius: var(--radius); border: 1px solid var(--line); background: var(--surface); box-shadow: 0 10px 30px rgba(0,0,0,0.08); }

.steps { list-style: none; counter-reset: s; padding: 0; margin: 2rem 0 0; display: grid; gap: 1rem; }
@media (min-width: 50em) { .steps { grid-template-columns: repeat(3, 1fr); } }
.steps li { counter-increment: s; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.3rem; }
.steps li::before { content: counter(s); display: inline-grid; place-items: center; width: 2rem; height: 2rem; border-radius: 50%; background: var(--accent); color: var(--accent-text); font-weight: 700; margin-bottom: 0.7rem; }
.steps h3 { margin-bottom: 0.3em; }
.steps p { margin: 0; color: var(--muted); }

.grid { display: grid; gap: 1rem; margin-top: 2rem; }
@media (min-width: 46em) { .grid.two { grid-template-columns: repeat(2, 1fr); } .grid.three { grid-template-columns: repeat(3, 1fr); } }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.3rem; }
.card h3 { margin-bottom: 0.4em; }
.card p:last-child { margin-bottom: 0; }
.card p { color: var(--muted); }

ul.ticks { list-style: none; padding: 0; margin: 1rem 0 0; display: grid; gap: 0.7rem; }
ul.ticks li { padding-left: 1.7rem; position: relative; }
ul.ticks li::before { content: ""; position: absolute; left: 0; top: 0.5em; width: 0.9rem; height: 0.5rem; border-left: 3px solid var(--accent); border-bottom: 3px solid var(--accent); transform: rotate(-45deg) translateY(-30%); }

.table-wrap { overflow-x: auto; margin-top: 1.5rem; }
table { border-collapse: collapse; width: 100%; min-width: 38rem; background: var(--surface); border: 1px solid var(--line); }
caption { text-align: left; padding: 0 0 0.6rem; color: var(--muted); font-size: 0.95rem; caption-side: top; }
th, td { text-align: left; vertical-align: top; padding: 0.8rem 0.9rem; border-bottom: 1px solid var(--line); font-size: 0.97rem; }
thead th { background: var(--accent-soft); }
tbody th { font-weight: 600; }

details { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 0 1.1rem; margin-bottom: 0.7rem; }
summary { cursor: pointer; font-weight: 600; padding: 0.95rem 0; }
details[open] summary { margin-bottom: 0.2rem; }
details p, details ul { color: var(--muted); }
details > :last-child { margin-bottom: 1rem; }

.badge { display: inline-block; font-size: 0.8rem; font-weight: 700; padding: 0.15rem 0.6rem; border-radius: 999px; background: var(--accent-soft); color: var(--text); border: 1px solid var(--accent); vertical-align: middle; }
code { font-family: var(--mono); font-size: 0.92em; background: var(--bg-alt); padding: 0.1em 0.35em; border-radius: 5px; }

footer.site { border-top: 1px solid var(--line); padding: 2.2rem 0 3rem; font-size: 0.95rem; color: var(--muted); }
footer.site .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1rem 2rem; }
footer.site ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 0.3rem 1.2rem; }
footer.site p { margin: 0; }

.prose { max-width: 44rem; }
.prose h2 { margin-top: 2.2rem; font-size: 1.5rem; }
.prose ul { padding-left: 1.2rem; }
.prose li { margin-bottom: 0.4rem; }
.page-head { padding: 3rem 0 0.5rem; }
.center { text-align: center; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
@media (forced-colors: active) {
  .btn { border: 2px solid ButtonText; }
}

/* Illustration (inline SVG) colours follow the theme */
.m-frame { fill: var(--surface); stroke: var(--line); }
.m-bar { fill: var(--bg-alt); }
.m-text { fill: var(--text); font-family: var(--font); }
.m-muted { fill: var(--muted); font-family: var(--font); }
.m-field { fill: var(--bg); stroke: var(--muted); }
.m-btn { fill: var(--accent); }
.m-btn-text { fill: var(--accent-text); font-family: var(--font); font-weight: 700; }
.m-ok { fill: var(--accent-soft); stroke: var(--accent); }
.spaced { margin-top: 2rem; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.prose, details { overflow-wrap: anywhere; }
