:root {
  color-scheme: light dark;
  --background: #f7f8fa;
  --surface: #ffffff;
  --text: #181b20;
  --muted: #5b6470;
  --border: #dce1e8;
  --accent: #5b3fd7;
  --accent-soft: #eeeafe;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html { background: var(--background); color: var(--text); }
body { margin: 0; min-height: 100vh; line-height: 1.65; }
a { color: var(--accent); text-underline-offset: 0.2em; }
a:hover { text-decoration-thickness: 0.12em; }
a:focus-visible { outline: 3px solid var(--accent); outline-offset: 4px; border-radius: 2px; }

.site-header,
main,
footer {
  width: min(72rem, calc(100% - 2rem));
  margin-inline: auto;
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-block: 1.5rem;
  border-bottom: 1px solid var(--border);
}

.brand { color: var(--text); font-size: 1.1rem; font-weight: 750; text-decoration: none; }
nav { display: flex; gap: 1.25rem; }
nav a { color: var(--muted); font-weight: 650; text-decoration: none; }
nav a[aria-current="page"] { color: var(--text); }

main { padding-block: clamp(3rem, 7vw, 6.5rem); }
.hero { max-width: 52rem; }
.eyebrow { color: var(--accent); font-size: 0.8rem; font-weight: 800; letter-spacing: 0.12em; text-transform: uppercase; }
h1, h2, h3 { line-height: 1.15; letter-spacing: -0.025em; }
h1 { max-width: 18ch; margin: 0.4rem 0 1.25rem; font-size: clamp(2.5rem, 7vw, 5.25rem); }
h2 { margin-top: 4rem; font-size: clamp(1.65rem, 3vw, 2.25rem); }
h3 { margin-top: 0; font-size: 1.15rem; }
.lead { max-width: 44rem; color: var(--muted); font-size: clamp(1.1rem, 2vw, 1.35rem); }
.grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.grid article,
.boundary {
  border: 1px solid var(--border);
  border-radius: 1rem;
  background: var(--surface);
  padding: 1.5rem;
}
.grid p { color: var(--muted); margin-bottom: 0; }
.boundary { margin-top: 4rem; }
.boundary h2 { margin-top: 0; }
.document { max-width: 48rem; }
.document h1 { font-size: clamp(2.4rem, 6vw, 4.5rem); }
.document h2 { margin-top: 3rem; }
code { border-radius: 0.25rem; background: var(--accent-soft); padding: 0.1rem 0.35rem; color: var(--text); }
footer { border-top: 1px solid var(--border); padding-block: 2rem 3rem; color: var(--muted); font-size: 0.9rem; }
.error-page { max-width: 44rem; padding-top: 16vh; }
.button { display: inline-block; margin-top: 1rem; border-radius: 0.65rem; background: var(--accent); padding: 0.75rem 1rem; color: white; font-weight: 700; text-decoration: none; }

@media (max-width: 46rem) {
  .grid { grid-template-columns: 1fr; }
  .site-header { align-items: flex-start; flex-direction: column; }
}

@media (prefers-color-scheme: dark) {
  :root {
    --background: #111318;
    --surface: #181b21;
    --text: #f2f4f7;
    --muted: #b4bdc8;
    --border: #323842;
    --accent: #b8a7ff;
    --accent-soft: #2a2348;
  }
}
