:root {
  --paper: #faf8f3;
  --paper-2: #f3efe5;
  --card: #ffffff;
  --ink: #1a2330;
  --ink-2: #3a4554;
  --ink-3: #6b7280;
  --navy: #1a3a52;
  --navy-2: #122a3d;
  --navy-soft: #e6edf3;
  --gold: #8a6a1f;
  --gold-soft: #f5edd6;
  --rule: #d8cfbb;
  --ok: #2f6b3a;
  --ok-soft: #e0ecdf;
  --serif: "Source Serif 4", "Iowan Old Style", Georgia, serif;
  --sans: Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", "SFMono-Regular", Consolas, monospace;
  --shell: min(1180px, calc(100vw - 40px));
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: var(--sans); font-size: 16px; line-height: 1.65; }
a { color: inherit; }
img { display: block; max-width: 100%; }
.shell { width: var(--shell); margin-inline: auto; }
.skip-link { position: fixed; top: 12px; left: 12px; z-index: 100; padding: 10px 14px; background: var(--ink); color: white; transform: translateY(-160%); }
.skip-link:focus { transform: translateY(0); }

:focus-visible { outline: 3px solid #a97916; outline-offset: 4px; border-radius: 3px; }

.site-header { position: sticky; top: 0; z-index: 20; background: color-mix(in srgb, var(--paper) 94%, transparent); border-bottom: 1px solid rgba(202, 190, 159, .7); backdrop-filter: blur(14px); }
.nav { min-height: 76px; display: flex; align-items: center; gap: 30px; }
.brand { display: inline-flex; align-items: center; gap: 11px; font-weight: 760; letter-spacing: -.02em; text-decoration: none; }
.brand-mark { width: 30px; height: 30px; display: grid; grid-template-columns: repeat(3, 1fr); align-items: end; gap: 3px; padding: 5px; color: var(--navy); border: 1px solid var(--rule); background: var(--card); }
.brand-mark span { display: block; background: currentColor; }
.brand-mark span:nth-child(1) { height: 10px; }
.brand-mark span:nth-child(2) { height: 17px; }
.brand-mark span:nth-child(3) { height: 13px; }
.desktop-nav { display: flex; align-items: center; gap: 27px; margin-left: auto; }
.desktop-nav a { color: var(--ink-2); font-size: .91rem; font-weight: 650; text-decoration: none; }
.desktop-nav a:hover { color: var(--navy); }
.desktop-cta { margin-left: 8px; }
.mobile-nav { display: none; margin-left: auto; position: relative; }
.mobile-nav summary { cursor: pointer; font-weight: 700; list-style: none; padding: 8px 0; }
.mobile-nav summary::-webkit-details-marker { display: none; }
.mobile-panel { position: absolute; right: 0; top: 48px; min-width: 230px; padding: 12px; background: var(--card); border: 1px solid var(--rule); box-shadow: 0 18px 45px rgba(26, 35, 48, .14); }
.mobile-panel a { display: block; padding: 10px 12px; text-decoration: none; font-weight: 650; }

.button { display: inline-flex; min-height: 48px; align-items: center; justify-content: center; padding: 10px 19px; border: 1px solid var(--navy); background: var(--navy); color: white; font-weight: 720; line-height: 1.2; text-decoration: none; transition: transform .16s ease, background .16s ease, box-shadow .16s ease; }
.button:hover { background: var(--navy-2); transform: translateY(-2px); box-shadow: 0 8px 20px rgba(18, 42, 61, .14); }
.button-small { min-height: 40px; padding: 8px 15px; font-size: .9rem; }
.button-secondary { background: transparent; color: var(--navy); }
.button-secondary:hover { color: white; }
.button-light { background: var(--paper); border-color: var(--paper); color: var(--navy-2); }
.button-light:hover { background: white; color: var(--navy-2); }
.button-outline-light { background: transparent; border-color: rgba(255,255,255,.7); }
.button-outline-light:hover { background: white; color: var(--navy-2); }
.button-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }

.hero { position: relative; overflow: hidden; padding: 96px 0 88px; background: linear-gradient(105deg, var(--paper) 0 67%, var(--paper-2) 67%); }
.hero::before { content: ""; position: absolute; inset: auto -80px -220px auto; width: 480px; height: 480px; border: 1px solid var(--rule); border-radius: 50%; opacity: .75; }
.hero-grid { position: relative; display: grid; grid-template-columns: 1.05fr .95fr; gap: clamp(55px, 8vw, 110px); align-items: center; }
.eyebrow { margin: 0 0 17px; color: var(--gold); font-family: var(--mono); font-size: .74rem; font-weight: 800; letter-spacing: .13em; text-transform: uppercase; }
h1, h2, h3 { margin-top: 0; color: var(--ink); line-height: 1.04; letter-spacing: -.035em; }
h1 { max-width: 760px; margin-bottom: 25px; font-family: var(--serif); font-size: clamp(3.4rem, 6.2vw, 6.6rem); font-weight: 600; }
h2 { margin-bottom: 24px; font-family: var(--serif); font-size: clamp(2.2rem, 4.3vw, 4.35rem); font-weight: 600; }
h3 { font-size: 1.2rem; letter-spacing: -.02em; }
.lede { max-width: 680px; margin: 0; color: var(--ink-2); font-family: var(--serif); font-size: clamp(1.22rem, 2vw, 1.52rem); line-height: 1.48; }
.hero-note { margin: 22px 0 0; color: var(--ink-3); font-size: .9rem; }
.hero-note strong { color: var(--ink-2); }
.hero-proof { align-self: stretch; display: flex; flex-direction: column; justify-content: center; }
.proof-window { background: var(--card); border: 1px solid var(--rule); box-shadow: 18px 22px 0 var(--navy-soft), 0 28px 70px rgba(26, 35, 48, .09); }
.window-bar { height: 43px; display: flex; align-items: center; gap: 6px; padding: 0 15px; border-bottom: 1px solid var(--rule); }
.window-bar span { width: 7px; height: 7px; border-radius: 50%; background: var(--rule); }
.window-bar span:nth-child(2) { background: var(--gold); }
.proof-body { padding: clamp(25px, 4vw, 45px); }
.proof-kicker { color: var(--ink-3); font-family: var(--mono); font-size: .68rem; font-weight: 800; letter-spacing: .12em; }
.proof-path { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin: 27px 0 34px; }
.proof-path span { flex: 1; padding: 12px 8px; border: 1px solid var(--rule); background: var(--paper); font-size: .76rem; font-weight: 750; line-height: 1.25; text-align: center; }
.proof-path i { color: var(--gold); font-style: normal; }
.proof-body dl { margin: 0; }
.proof-body dl div { display: flex; justify-content: space-between; gap: 25px; padding: 11px 0; border-top: 1px solid var(--rule); }
.proof-body dt { color: var(--ink-3); }
.proof-body dd { margin: 0; color: var(--ok); font-weight: 750; text-align: right; }
.caption { margin: 32px 0 0; padding-left: 22px; color: var(--ink-3); font-size: .78rem; line-height: 1.55; }

.proof-strip { background: var(--navy-2); color: white; }
.proof-items { display: grid; grid-template-columns: repeat(3, 1fr); }
.proof-items div { min-height: 126px; display: flex; flex-direction: column; justify-content: center; padding: 25px 38px; border-left: 1px solid rgba(255,255,255,.17); }
.proof-items div:last-child { border-right: 1px solid rgba(255,255,255,.17); }
.proof-items strong { font-family: var(--serif); font-size: 1.18rem; font-weight: 600; }
.proof-items span { margin-top: 5px; color: rgba(255,255,255,.67); font-size: .83rem; }

.section { padding: clamp(85px, 10vw, 145px) 0; }
.problem-section { border-bottom: 1px solid var(--rule); }
.narrow-grid { display: grid; grid-template-columns: .9fr 1.1fr; gap: 10vw; align-items: start; }
.narrow-grid h2 { max-width: 590px; }
.body-copy { max-width: 600px; padding-top: 36px; color: var(--ink-2); font-family: var(--serif); font-size: 1.27rem; }
.body-copy p:first-child { margin-top: 0; }
.body-copy p:last-child { margin-bottom: 0; }
.suite-section { background: var(--paper-2); }
.section-heading { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(260px, .75fr); gap: 8vw; align-items: end; margin-bottom: 58px; }
.section-heading h2 { max-width: 730px; margin-bottom: 0; }
.section-heading > p { max-width: 430px; margin: 0 0 7px; color: var(--ink-2); }
.module-ledger { border-top: 2px solid var(--ink); }
.module { display: grid; grid-template-columns: 70px 1fr auto; gap: 25px; align-items: center; min-height: 112px; padding: 20px 10px; border-bottom: 1px solid var(--rule); text-decoration: none; transition: padding .18s ease, background .18s ease; }
.module:hover { padding-left: 22px; padding-right: 22px; background: var(--card); }
.module-index { color: var(--ink-3); font-family: var(--mono); font-size: .75rem; }
.module-copy { display: grid; grid-template-columns: minmax(170px, .35fr) minmax(260px, .65fr); gap: 20px; align-items: center; }
.module-copy strong { font-family: var(--serif); font-size: 1.45rem; font-weight: 600; }
.module-copy small { max-width: 590px; color: var(--ink-3); font-size: .88rem; }
.module-status { padding: 5px 9px; background: var(--ok-soft); color: var(--ok); font-family: var(--mono); font-size: .66rem; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; }
.module-core .module-status { background: var(--navy-soft); color: var(--navy); }

.architecture-section { background: var(--card); }
.architecture-grid { display: grid; grid-template-columns: .8fr 1.2fr; gap: 8vw; align-items: center; }
.architecture-copy h2 { max-width: 520px; }
.steps { margin: 45px 0 32px; padding: 0; list-style: none; }
.steps li { display: grid; grid-template-columns: 32px 1fr; gap: 16px; padding: 24px 0; border-top: 1px solid var(--rule); }
.steps li > span { width: 26px; height: 26px; display: grid; place-items: center; border: 1px solid var(--gold); color: var(--gold); font-family: var(--mono); font-size: .68rem; font-weight: 800; }
.steps strong { display: block; margin-bottom: 5px; }
.steps p { margin: 0; color: var(--ink-3); font-size: .9rem; }
.text-link { color: var(--navy); font-weight: 750; text-decoration-thickness: 1px; text-underline-offset: 4px; }
.text-link span { color: var(--gold); }
.architecture-figure { margin: 0; padding: clamp(22px, 4vw, 50px); border: 1px solid var(--rule); background: var(--paper); }
.architecture-figure figcaption { margin-top: 20px; color: var(--ink-3); font-size: .78rem; text-align: center; }

.principles-section { background: var(--navy-soft); }
.compact-heading { display: block; }
.principles-grid { display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid rgba(26,58,82,.3); }
.principles-grid article { padding: 35px 28px 15px; border-left: 1px solid rgba(26,58,82,.23); }
.principles-grid article:last-child { border-right: 1px solid rgba(26,58,82,.23); }
.principles-grid article > span { color: var(--gold); font-family: var(--mono); font-size: .7rem; font-weight: 800; }
.principles-grid h3 { margin: 48px 0 16px; font-family: var(--serif); font-size: 1.45rem; font-weight: 600; }
.principles-grid p { color: var(--ink-2); font-size: .9rem; }

.status-section { background: var(--paper); }
.status-card { display: grid; grid-template-columns: 1.1fr .9fr; border: 1px solid var(--rule); background: var(--card); box-shadow: 14px 14px 0 var(--gold-soft); }
.status-intro, .status-boundary { padding: clamp(35px, 5vw, 70px); }
.status-intro h2 { font-size: clamp(2.2rem, 3.5vw, 3.7rem); }
.status-intro > p:last-child { max-width: 610px; color: var(--ink-2); font-family: var(--serif); font-size: 1.15rem; }
.status-boundary { display: flex; flex-direction: column; justify-content: center; background: var(--gold-soft); border-left: 1px solid var(--rule); }
.boundary-label { margin: 0; color: var(--gold); font-family: var(--mono); font-size: .7rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; }
.boundary-main { margin: 12px 0; font-family: var(--serif); font-size: 2rem; font-weight: 650; line-height: 1.2; }
.status-boundary > p:nth-child(3) { color: var(--ink-2); }
.status-boundary .text-link { margin-top: 16px; }

.docs-section { background: var(--card); }
.doc-links { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--rule); border-left: 1px solid var(--rule); }
.doc-links a { position: relative; min-height: 210px; display: flex; flex-direction: column; padding: 30px; border-right: 1px solid var(--rule); border-bottom: 1px solid var(--rule); text-decoration: none; transition: background .18s ease; }
.doc-links a:hover { background: var(--paper-2); }
.doc-links span { color: var(--gold); font-family: var(--mono); font-size: .67rem; font-weight: 800; letter-spacing: .07em; text-transform: uppercase; }
.doc-links strong { margin-top: auto; font-family: var(--serif); font-size: 1.45rem; font-weight: 600; }
.doc-links small { margin-top: 7px; color: var(--ink-3); font-size: .8rem; }
.doc-links i { position: absolute; right: 24px; top: 24px; color: var(--ink-3); font-style: normal; }

.final-cta { padding: 95px 0; background: var(--navy-2); color: white; }
.final-cta .eyebrow { color: #dfc67f; }
.final-cta h2 { max-width: 650px; margin-bottom: 0; color: white; }
.final-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 9vw; align-items: end; }
.final-grid > div:last-child > p { max-width: 510px; margin-top: 0; color: rgba(255,255,255,.72); }
.site-footer { padding: 55px 0; border-top: 1px solid rgba(255,255,255,.1); background: #0d2231; color: white; }
.footer-grid { display: grid; grid-template-columns: 1.3fr .8fr 1fr; gap: 6vw; align-items: start; }
.footer-brand .brand-mark { color: white; border-color: rgba(255,255,255,.25); background: transparent; }
.footer-grid > div:first-child p, .footer-meta { color: rgba(255,255,255,.58); font-size: .78rem; }
.footer-grid > div:first-child p { max-width: 380px; }
.footer-links { display: grid; gap: 8px; }
.footer-links a { color: rgba(255,255,255,.78); font-size: .84rem; text-underline-offset: 3px; }
.footer-meta { margin: 0; text-align: right; }

@media (max-width: 920px) {
  .desktop-nav, .desktop-cta { display: none; }
  .mobile-nav { display: block; }
  .hero { padding: 75px 0; background: var(--paper); }
  .hero-grid, .narrow-grid, .architecture-grid, .status-card, .final-grid { grid-template-columns: 1fr; }
  .hero-grid { gap: 65px; }
  .hero-proof { max-width: 640px; }
  .proof-items { grid-template-columns: 1fr; }
  .proof-items div { min-height: 92px; border-right: 1px solid rgba(255,255,255,.17); border-bottom: 1px solid rgba(255,255,255,.17); }
  .body-copy { padding-top: 0; }
  .section-heading { grid-template-columns: 1fr; gap: 24px; }
  .module-copy { grid-template-columns: 1fr; gap: 2px; }
  .principles-grid { grid-template-columns: repeat(2, 1fr); }
  .status-boundary { border-left: 0; border-top: 1px solid var(--rule); }
  .doc-links { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .footer-meta { text-align: left; }
}

@media (max-width: 600px) {
  :root { --shell: min(100% - 28px, 1180px); }
  .nav { min-height: 66px; }
  .hero { padding: 58px 0 62px; }
  h1 { font-size: clamp(3rem, 15vw, 4.6rem); }
  .button-row { flex-direction: column; }
  .button-row .button { width: 100%; }
  .proof-window { box-shadow: 9px 11px 0 var(--navy-soft); }
  .proof-body { padding: 22px; }
  .proof-path { align-items: stretch; }
  .proof-path span { writing-mode: vertical-rl; min-height: 100px; }
  .section { padding: 78px 0; }
  .module { grid-template-columns: 38px 1fr; gap: 10px; padding: 20px 4px; }
  .module-status { grid-column: 2; justify-self: start; }
  .principles-grid, .doc-links { grid-template-columns: 1fr; }
  .principles-grid article { border-right: 1px solid rgba(26,58,82,.23); }
  .principles-grid h3 { margin-top: 24px; }
  .doc-links a { min-height: 175px; }
  .footer-grid { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
