:root {
  color-scheme: light;
  --ink: #132238;
  --muted: #5b6b80;
  --line: #dce5f0;
  --paper: #f7f9fc;
  --brand: #245ea8;
  --brand-dark: #123a70;
  --accent: #dcecff;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; color: var(--ink); background: var(--paper); font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; }
a { color: var(--brand); }
.topbar { min-height: 68px; padding: 0 5vw; display: flex; align-items: center; justify-content: space-between; gap: 24px; background: #0f1d2f; color: white; }
.topbar a { color: inherit; text-decoration: none; }
.brand { font-size: 1.15rem; font-weight: 800; white-space: nowrap; }
.topbar nav { display: flex; flex-wrap: wrap; gap: 20px; font-size: .92rem; }
.topbar nav a:hover { color: #a9d1ff; }
.portal { max-width: 1120px; margin: 0 auto; padding: 72px 24px; }
.hero { padding: 64px; border-radius: 28px; color: white; background: radial-gradient(circle at top right, #357bc9, transparent 40%), linear-gradient(135deg, #10233c, #173f70); box-shadow: 0 30px 70px rgba(15, 29, 47, .2); }
.eyebrow { color: #9cc9ff; font-size: .8rem; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; }
.hero h1 { max-width: 760px; margin: 18px 0; font-size: clamp(2.4rem, 6vw, 4.8rem); line-height: 1.02; letter-spacing: -.045em; }
.hero p { max-width: 720px; color: #d7e8fb; font-size: 1.15rem; line-height: 1.75; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.button { padding: 13px 20px; border: 1px solid rgba(255,255,255,.4); border-radius: 999px; color: white; text-decoration: none; font-weight: 700; }
.button.primary { border-color: white; color: var(--brand-dark); background: white; }
.cards { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; margin-top: 28px; }
.card { min-height: 240px; padding: 28px; border: 1px solid var(--line); border-radius: 20px; color: inherit; background: white; text-decoration: none; transition: transform .2s ease, box-shadow .2s ease; }
.card:hover { transform: translateY(-4px); box-shadow: 0 18px 40px rgba(24, 54, 91, .1); }
.card > span { color: var(--brand); font-size: .8rem; font-weight: 800; letter-spacing: .15em; }
.card h2 { margin: 32px 0 10px; }
.card p { color: var(--muted); line-height: 1.7; }
.notice { margin-top: 28px; padding: 22px 26px; border: 1px solid #b9d6f7; border-radius: 16px; background: var(--accent); line-height: 1.65; }
.document-layout { width: min(1320px, 100%); margin: 0 auto; padding: 44px 24px 88px; display: grid; grid-template-columns: 220px minmax(0, 850px); justify-content: center; gap: 48px; }
.toc-card { position: sticky; top: 24px; align-self: start; display: grid; gap: 14px; padding: 20px; border: 1px solid var(--line); border-radius: 16px; background: white; }
.toc-card a { text-decoration: none; }
.prose { min-width: 0; padding: 42px 56px; border: 1px solid var(--line); border-radius: 20px; background: white; box-shadow: 0 15px 50px rgba(20, 42, 70, .06); }
.prose h1 { margin-top: 0; font-size: clamp(2.2rem, 5vw, 3.5rem); line-height: 1.08; letter-spacing: -.035em; }
.prose h2 { margin-top: 2.4em; padding-top: .5em; border-top: 1px solid var(--line); font-size: 1.8rem; }
.prose h3 { margin-top: 1.8em; font-size: 1.3rem; }
.prose p, .prose li { color: #33465e; line-height: 1.75; }
.prose code { padding: .15em .4em; border-radius: 5px; background: #edf2f8; font-size: .9em; }
.prose pre { overflow-x: auto; padding: 20px; border-radius: 14px; color: #eaf3ff; background: #101d2e; }
.prose pre code { padding: 0; color: inherit; background: transparent; }
.prose table { width: 100%; border-collapse: collapse; }
.prose th, .prose td { padding: 12px; border: 1px solid var(--line); text-align: left; vertical-align: top; }
.prose blockquote { margin-left: 0; padding: 10px 20px; border-left: 4px solid var(--brand); background: var(--accent); }
.api-shell { min-height: calc(100vh - 116px); background: white; }
.footer { padding: 24px; color: #738197; background: #0f1d2f; text-align: center; font-size: .85rem; }
@media (max-width: 900px) {
  .topbar { align-items: flex-start; padding-top: 18px; padding-bottom: 18px; flex-direction: column; }
  .cards { grid-template-columns: 1fr; }
  .document-layout { display: block; }
  .toc-card { position: static; margin-bottom: 20px; }
  .prose { padding: 30px 22px; }
  .hero { padding: 38px 28px; }
}
