:root {
  --ink: #0B0F14;
  --secondary: #5B6573;
  --tertiary: #8891A0;
  --line: #E6EAF0;
  --line-strong: #C0C7D1;
  --surface: #F5F7FA;
  --sidebar-bg: #F0EEF3;
  --white: #FFFFFF;
  --navy: #1F2A44;
  --navy-light: #2E3A5F;
  --dark: #0F141C;
  --cyan: #5FD1FF;
  --cyan-deep: #14708F;
  --cyan-soft: #CFEFFF;
  --coral: #F29F88;
  --coral-soft: #F3C6BB;
  --display: 'Onest', system-ui, sans-serif;
  --sans: 'Onest', system-ui, sans-serif;
  --mono: 'DM Mono', ui-monospace, Menlo, monospace;
  --sidebar-w: 296px;
  --ease: cubic-bezier(.44, 0, .56, 1);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }
html { scroll-behavior: smooth; }
body { font-family: var(--sans); font-size: 16px; line-height: 1.65; color: var(--ink); background: var(--white); }
img { max-width: 100%; display: block; }
a { color: inherit; }
:focus-visible { outline: 2px solid var(--cyan-deep); outline-offset: 2px; }
[hidden] { display: none !important; }

.skip-link { position: absolute; left: -9999px; top: 0; z-index: 60; background: var(--ink); color: var(--white); padding: 12px 18px; text-decoration: none; font-weight: 500; }
.skip-link:focus { left: 0; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* Sidebar */
.sidebar {
  position: fixed; inset: 0 auto 0 0; width: var(--sidebar-w); z-index: 40;
  background: var(--sidebar-bg); border-right: 1px solid var(--line);
  display: flex; flex-direction: column; padding: 32px 24px; overflow-y: auto;
}
.sidebar__logo { display: block; margin-bottom: 24px; }
.sidebar__logo img { height: 28px; width: auto; }
.sidebar__me { display: flex; align-items: center; gap: 12px; padding-bottom: 24px; margin-bottom: 24px; border-bottom: 1px solid var(--line); }
.sidebar__me img { width: 56px; height: 56px; border-radius: 50%; object-fit: cover; object-position: center 20%; flex-shrink: 0; }
.sidebar__name { font-family: var(--display); font-weight: 600; font-size: 14px; line-height: 1.3; }
.sidebar__role { font-size: 12px; color: var(--secondary); line-height: 1.4; }
.sidebar__place { font-family: var(--mono); font-size: 11px; color: var(--tertiary); }
.sidebar nav { display: flex; flex-direction: column; gap: 2px; }
.sidebar__section { font-family: var(--mono); font-size: 10px; letter-spacing: .12em; text-transform: uppercase; color: var(--tertiary); padding: 16px 12px 6px; }
.sidebar-link {
  display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 8px;
  font-size: 14px; color: var(--secondary); text-decoration: none;
  transition: color .2s ease, background .2s ease;
}
.sidebar-link svg { width: 16px; height: 16px; flex-shrink: 0; }
.sidebar-link:hover { color: var(--ink); background: rgba(0, 0, 0, .04); }
.sidebar-link.active { color: var(--ink); font-weight: 500; background: rgba(0, 0, 0, .05); }
.sidebar__foot { margin-top: auto; padding-top: 24px; border-top: 1px solid var(--line); display: flex; gap: 12px; }
.sidebar__foot a {
  width: 40px; height: 40px; border-radius: 8px; border: 1px solid var(--line);
  display: grid; place-items: center; color: var(--tertiary); transition: color .2s ease, border-color .2s ease;
}
.sidebar__foot a:hover { color: var(--ink); border-color: var(--line-strong); }
.sidebar__foot svg { width: 16px; height: 16px; }

/* Mobile top bar + drawer */
.topbar {
  display: none; position: fixed; top: 0; left: 0; right: 0; height: 64px; z-index: 50;
  background: rgba(255, 255, 255, .92); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line); padding: 0 20px; align-items: center; justify-content: space-between;
}
.topbar img { height: 24px; width: auto; }
.topbar button { background: none; border: 0; padding: 10px; color: var(--ink); cursor: pointer; }
.drawer-overlay { display: none; position: fixed; inset: 0; background: rgba(0, 0, 0, .3); z-index: 45; opacity: 0; transition: opacity .3s ease; }
.drawer-overlay.open { display: block; opacity: 1; }
.main { margin-left: var(--sidebar-w); }
@media (max-width: 1023px) {
  .sidebar { transform: translateX(-100%); transition: transform .4s var(--ease); z-index: 50; }
  .sidebar.open { transform: translateX(0); }
  .topbar { display: flex; }
  .main { margin-left: 0; padding-top: 64px; }
}

/* Layout + type */
.wrap { max-width: 1152px; margin: 0 auto; padding-inline: clamp(20px, 4vw, 48px); }
.section { padding-block: clamp(56px, 8vw, 96px); border-top: 1px solid var(--line); }
.section--alt { background: var(--surface); }
.section--navy { background: var(--navy); color: var(--white); border-top: 0; }
.eyebrow { font-family: var(--mono); font-size: 12px; font-weight: 500; letter-spacing: .12em; text-transform: uppercase; color: var(--cyan-deep); margin-bottom: 16px; }
.section--navy .eyebrow, .hero .eyebrow { color: var(--cyan); }
h1, h2, h3 { font-family: var(--display); letter-spacing: -.02em; line-height: 1.15; }
.h1 { font-size: clamp(34px, 4.6vw, 56px); font-weight: 700; line-height: 1.08; }
.h2 { font-size: clamp(26px, 3.2vw, 40px); font-weight: 700; }
.h3 { font-size: clamp(18px, 1.6vw, 21px); font-weight: 600; letter-spacing: -.01em; }
.lede { font-size: 17px; color: var(--secondary); line-height: 1.75; }
.section-head { max-width: 640px; margin-bottom: 40px; }
.section-head .lede { margin-top: 14px; }
.muted { color: var(--secondary); }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-family: var(--sans); font-size: 14px; font-weight: 500; text-decoration: none; cursor: pointer;
  padding: 13px 24px; border-radius: 8px; border: 1px solid transparent;
  transition: transform .4s var(--ease), background .3s ease, opacity .3s ease, color .3s ease;
}
.btn svg { width: 16px; height: 16px; }
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn--primary { background: var(--navy); color: var(--white); }
.btn--primary:hover { opacity: .9; }
.btn--light { background: var(--white); color: var(--ink); }
.btn--outline { border-color: rgba(255, 255, 255, .22); color: var(--white); }
.btn--outline:hover { background: rgba(255, 255, 255, .08); }
.btn--ghost { border-color: var(--line-strong); color: var(--ink); background: var(--white); }
.btn--ghost:hover { background: var(--surface); }
.btn[disabled] { opacity: .6; cursor: progress; transform: none; }

/* Cards */
.card { border: 1px solid var(--line); border-radius: 12px; padding: 28px; background: var(--white); transition: border-color .3s ease; }
.card:hover { border-color: var(--line-strong); }
.card__icon { width: 36px; height: 36px; border-radius: 8px; background: var(--cyan-soft); color: var(--cyan-deep); display: grid; place-items: center; margin-bottom: 18px; }
.card__icon svg { width: 17px; height: 17px; }
.card .h3 { margin-bottom: 8px; }
.card p { color: var(--secondary); font-size: 15px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.grid-4 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
@media (min-width: 1560px) { .grid-4 { grid-template-columns: repeat(4, 1fr); } }
@media (max-width: 860px) { .grid-2, .grid-3 { grid-template-columns: 1fr; } }
@media (max-width: 560px) { .grid-4 { grid-template-columns: 1fr; } }

/* Hero */
.hero { position: relative; overflow: hidden; background: var(--navy); min-height: 100vh; display: flex; align-items: center; }
.hero > .wrap { width: 100%; }
.hero canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero .wrap { position: relative; z-index: 1; padding-block: 96px; }
.hero__inner { max-width: 620px; }
.hero h1 { color: var(--white); }
.hero h1 .accent { color: var(--cyan); }
.hero__sub { margin-top: 18px; font-family: var(--display); font-size: clamp(18px, 1.9vw, 22px); font-weight: 500; color: rgba(255, 255, 255, .92); line-height: 1.4; }
.hero__actions { margin-top: 32px; display: flex; flex-wrap: wrap; gap: 12px; }
.page-hero { padding-block: clamp(48px, 7vw, 88px); }
.page-hero .h1 { max-width: 15ch; }
.page-hero .lede { margin-top: 18px; max-width: 620px; }
.page-hero .btn { margin-top: 28px; }
.backlink { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; color: var(--tertiary); text-decoration: none; margin-bottom: 24px; }
.backlink:hover { color: var(--secondary); }
.backlink svg { width: 14px; height: 14px; }

/* Credentials strip */
.creds { background: var(--white); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
/* One line, edge to edge. The gap is a floor; space-between spends the rest.
   Below 800px the four facts no longer fit a line and stack instead. */
.creds ul { list-style: none; display: flex; flex-wrap: nowrap; gap: 10px clamp(14px, 1.6vw, 32px); justify-content: space-between; padding-block: 18px; font-family: var(--mono); font-size: 11px; letter-spacing: .05em; text-transform: uppercase; color: var(--secondary); }
.creds li { white-space: nowrap; }
@media (max-width: 799px) { .creds ul { flex-wrap: wrap; gap: 10px 32px; } .creds li { white-space: normal; } }

/* Themes (audience pages) */
.theme-list { border-top: 1px solid var(--line); }
.theme { display: grid; grid-template-columns: minmax(180px, 22%) 1fr; gap: clamp(16px, 3vw, 40px); padding: 26px 0; border-bottom: 1px solid var(--line); }
.theme h3 { font-family: var(--display); font-size: clamp(17px, 1.5vw, 19px); font-weight: 600; letter-spacing: -.01em; }
.theme p { color: var(--secondary); font-size: 16px; max-width: 62ch; }
@media (max-width: 720px) { .theme { grid-template-columns: 1fr; gap: 6px; padding: 20px 0; } }

/* Steps */
.steps { list-style: none; display: grid; grid-template-columns: repeat(2, 1fr); gap: 28px 24px; counter-reset: step; }
.steps li::before { counter-increment: step; content: counter(step, decimal-leading-zero); display: block; margin-bottom: 10px; font-family: var(--mono); font-size: 12px; letter-spacing: .08em; color: var(--cyan); }
@media (min-width: 1560px) { .steps { grid-template-columns: repeat(4, 1fr); gap: 20px; } }
@media (max-width: 560px) { .steps { grid-template-columns: 1fr; } }
.steps li { border-top: 2px solid var(--cyan); padding-top: 18px; }
.steps .when { display: block; font-family: var(--mono); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--cyan-deep); margin-bottom: 8px; }
.steps p { color: var(--secondary); font-size: 15px; margin-top: 6px; }
.section--navy .steps li { border-top-color: var(--cyan); }
.section--navy .steps .when { color: var(--cyan); }
.section--navy .steps p { color: rgba(255, 255, 255, .7); }
.section--navy .lede { color: rgba(255, 255, 255, .7); }

/* Quote */
.quote-block { max-width: 860px; padding-left: clamp(20px, 4vw, 48px); border-left: 3px solid var(--coral); }
.quote { font-family: var(--display); font-size: clamp(22px, 2.6vw, 32px); font-weight: 600; letter-spacing: -.015em; line-height: 1.3; }
.quote::before { content: "\201C"; display: block; height: .62em; font-size: 2.4em; line-height: 1; color: var(--coral); }
.quote-by { display: block; margin-top: 18px; font-family: var(--mono); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--tertiary); }
.quote-after { margin-top: 24px; max-width: 560px; }
@media (max-width: 720px) { .quote-block { padding-left: 0; border-left: 0; border-top: 3px solid var(--coral); padding-top: 28px; } }

/* About */
.about { display: grid; grid-template-columns: 2fr 3fr; gap: clamp(32px, 5vw, 64px); align-items: start; }
@media (max-width: 860px) { .about { grid-template-columns: 1fr; } }
.about__photo img { border-radius: 12px; aspect-ratio: 4 / 5; object-fit: cover; object-position: center 18%; width: 100%; height: auto; filter: grayscale(1) contrast(1.05); }
.about__facts { list-style: none; margin-top: 18px; display: grid; gap: 6px; font-family: var(--mono); font-size: 12px; letter-spacing: .04em; color: var(--secondary); }
.about__body p + p { margin-top: 16px; }
.about__body p { color: var(--secondary); font-size: 16.5px; }
.text-link { display: inline-flex; align-items: center; gap: 8px; margin-top: 22px; font-weight: 500; font-size: 15px; color: var(--cyan-deep); text-decoration: none; border-bottom: 1px solid currentColor; padding-bottom: 2px; }
.text-link:hover { color: var(--ink); }
.about-brief { display: grid; grid-template-columns: 200px 1fr; gap: clamp(24px, 4vw, 48px); align-items: center; }
.about-brief img { border-radius: 12px; aspect-ratio: 4 / 5; object-fit: cover; object-position: center 18%; width: 100%; height: auto; filter: grayscale(1) contrast(1.05); }
.about-brief .h2 { margin-bottom: 14px; }
.about-brief p { color: var(--secondary); font-size: 16.5px; max-width: 64ch; }
@media (max-width: 720px) { .about-brief { grid-template-columns: 1fr; } .about-brief img { max-width: 176px; } }
.about-brief { border-left: 3px solid var(--coral); padding-left: clamp(20px, 3vw, 36px); }
@media (max-width: 720px) { .about-brief { border-left: 0; padding-left: 0; border-top: 3px solid var(--coral); padding-top: 28px; } }

/* Audience cards */
.audience { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
@media (max-width: 860px) { .audience { grid-template-columns: 1fr; } }
.audience a { text-decoration: none; display: block; }
.audience .more { display: inline-flex; align-items: center; gap: 6px; margin-top: 16px; font-size: 14px; font-weight: 500; color: var(--cyan-deep); }
.audience .more svg { width: 16px; height: 16px; flex-shrink: 0; }
.audience a:hover .more { color: var(--ink); }

/* Fit */
.fit .card--yes .pill { background: var(--cyan-soft); }
.fit .card--no .pill { background: var(--coral-soft); }
.pill { display: inline-block; font-family: var(--mono); font-size: 11px; letter-spacing: .1em; text-transform: uppercase; padding: 5px 10px; border-radius: 4px; margin-bottom: 14px; }
.fit p { font-size: 16px; }
.fit-close { margin-top: 24px; }

/* Contact */
.contact { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 5vw, 72px); align-items: start; }
@media (max-width: 900px) { .contact { grid-template-columns: 1fr; } }
.contact__meta { list-style: none; margin-top: 26px; display: grid; gap: 10px; font-size: 15px; color: var(--secondary); }
.contact__meta a { text-decoration: none; }
.contact__meta a:hover { color: var(--ink); }
.form { display: grid; gap: 14px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
@media (max-width: 520px) { .form-row { grid-template-columns: 1fr; } }
.field label { display: block; font-size: 14px; font-weight: 500; margin-bottom: 6px; }
.field input, .field textarea {
  width: 100%; font: inherit; font-size: 15px; color: var(--ink); background: var(--white);
  padding: 11px 14px; border: 1px solid var(--line); border-radius: 8px;
  transition: border-color .2s ease, box-shadow .2s ease;
}
.field textarea { resize: vertical; min-height: 120px; }
.field input:focus, .field textarea:focus { outline: none; border-color: var(--cyan); box-shadow: 0 0 0 3px rgba(95, 209, 255, .18); }
.form .btn { width: 100%; }
.form-status { font-size: 14px; padding: 11px 14px; border-radius: 8px; background: #FDECEA; color: #8A2C1F; }
.form-done { text-align: center; padding-block: 28px; }
.form-done p { color: var(--secondary); margin-top: 6px; }

/* CTA band */
.cta-card { background: var(--navy); border-radius: 12px; padding: clamp(28px, 4vw, 48px); color: var(--white); }
.cta-card .h2 { max-width: 18ch; }
.cta-card .lede { color: rgba(255, 255, 255, .7); margin-top: 14px; max-width: 560px; }
.cta-card .btn { margin-top: 26px; }

/* Footer */
.site-footer { border-top: 1px solid var(--line); padding-block: 28px; }
.site-footer .wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px 32px; }
.site-footer img { height: 20px; width: auto; }
.footer-links { list-style: none; display: flex; flex-wrap: wrap; gap: 8px 24px; font-size: 13px; }
.footer-links a { color: var(--secondary); text-decoration: none; padding-block: 6px; display: inline-block; }
.footer-links a:hover { color: var(--ink); }
.site-footer small { color: var(--tertiary); font-size: 12px; }

/* Notes essay */
.essay { max-width: 700px; margin-inline: auto; padding-inline: clamp(20px, 4vw, 48px); }
.essay section { padding-block: clamp(40px, 5vw, 64px); border-top: 1px solid var(--line); scroll-margin-top: 80px; }
.essay section:first-child { border-top: 0; }
.essay h2 { font-size: clamp(22px, 2.6vw, 30px); font-weight: 700; margin-bottom: 6px; }
.essay p { font-size: 18px; line-height: 1.8; color: #262C35; margin-top: 20px; }
.essay blockquote { margin-block: 32px; padding-left: 22px; border-left: 3px solid var(--cyan); font-family: var(--display); font-size: clamp(19px, 2.1vw, 24px); font-weight: 600; line-height: 1.4; }
.essay .signoff { text-align: center; font-family: var(--mono); font-size: 12px; color: var(--tertiary); margin-top: 40px; }

/* Motion */
@keyframes fadeUp { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }
.fade-up { animation: fadeUp .6s var(--ease) both; }
.fade-1 { animation-delay: .08s; }
.fade-2 { animation-delay: .16s; }
.fade-3 { animation-delay: .24s; }
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .6s var(--ease), transform .6s var(--ease); }
.reveal.is-in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .fade-up { animation: none; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .btn, .btn:hover { transition: none; transform: none; }
}

/* Booking */
.booking { background: var(--surface); }
.booking__embed { margin-top: 8px; }
/* The space is reserved only once booking.js is about to inject the embed:
   a reader with JS off sees no empty void, one with JS on sees no jump. */
.booking__embed.is-loading { min-height: 520px; }
.booking__alt { margin-top: 20px; font-size: 15px; color: var(--secondary); display: flex; flex-wrap: wrap; gap: 6px 18px; align-items: baseline; }
.booking__fallback { color: var(--cyan-deep); font-weight: 500; text-decoration: none; border-bottom: 1px solid currentColor; padding-bottom: 1px; }
.booking__fallback:hover { color: var(--ink); }
.booking__or a { color: var(--cyan-deep); }
.booking .section-head { position: relative; padding-top: 22px; }
.booking .section-head::before { content: ""; position: absolute; top: 0; left: 0; width: 48px; height: 3px; background: var(--coral); }

/* ── Open layout ─────────────────────────────────────────────────────────
   The unframed treatment: no sidebar panel, the page sits on one warm grey,
   a floating nav bar that scrolls away, and a sticky index of the page's own
   sections that highlights as you pass each one. Scoped to body.open-layout
   so the five framed pages are untouched. */
body.open-layout { background: var(--sidebar-bg); }
body.open-layout .main { margin-left: 0; padding-top: 0; }
body.open-layout .section { border-top-color: var(--line-strong); }
body.open-layout .section--alt { background: transparent; }
body.open-layout .creds { background: transparent; }

/* Floating nav bar. Sticky, so it rides along instead of scrolling away; the
   glass bar keeps the content behind it legible. The 16px margin stays so
   --nav-h (measured in site.js) still describes the landing frame exactly. */
.sitenav { position: sticky; top: 8px; z-index: 30; max-width: 1040px; margin: 16px auto 0; padding-inline: clamp(12px, 3vw, 24px); }
.sitenav__bar { display: flex; align-items: center; gap: clamp(12px, 2vw, 28px); background: rgba(255,255,255,.72); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); border: 1px solid var(--line); border-radius: 12px; padding: 10px 10px 10px 16px; }
.sitenav__logo { flex-shrink: 0; display: flex; }
.sitenav__logo img { height: 22px; width: auto; }
.sitenav__links { display: flex; flex: 1; align-items: center; gap: clamp(8px, 1.6vw, 22px); justify-content: center; flex-wrap: wrap; }
.sitenav__links a { padding: 6px 2px; font-size: 13px; white-space: nowrap; color: var(--secondary); text-decoration: none; border-bottom: 1px solid transparent; transition: color .2s ease, border-color .2s ease; }
.sitenav__links a:hover { color: var(--ink); }
.sitenav__links a[aria-current="page"] { color: var(--ink); font-weight: 500; border-bottom-color: var(--cyan-deep); }
.sitenav__cta { flex-shrink: 0; padding: 9px 16px; font-size: 13px; }
.sitenav__cta svg { width: 14px; height: 14px; }

/* Page body: sticky section index beside the content */
.open-body { max-width: 1152px; margin: 0 auto; padding-inline: clamp(20px, 4vw, 48px); display: grid; grid-template-columns: 172px 1fr; gap: clamp(24px, 5vw, 72px); align-items: start; }
.open-body > .open-main { min-width: 0; }
.open-body .wrap { max-width: none; padding-inline: 0; margin: 0; }

.sindex { position: sticky; top: 24px; padding-block: 8px; }
.sindex ol { list-style: none; display: grid; gap: 2px; }
.sindex a { display: block; padding: 5px 0 5px 12px; border-left: 1px solid transparent; font-size: 13px; line-height: 1.35; color: var(--secondary); text-decoration: none; transition: color .2s ease, border-color .2s ease; }
.sindex a:hover { color: var(--ink); }
.sindex a.is-current { color: var(--ink); font-weight: 500; border-left-color: var(--cyan-deep); }
@media (max-width: 1023px) { .open-body { grid-template-columns: 1fr; } .sindex { display: none; } }

/* Hero, inverted: the dot field reads navy on the page's own grey. */
body.open-layout .hero { background: var(--sidebar-bg); min-height: min(78vh, 720px); }
body.open-layout .hero h1 { color: var(--ink); }
body.open-layout .hero h1 .accent { color: var(--cyan-deep); }
body.open-layout .hero__sub { color: var(--ink); }
body.open-layout .hero .eyebrow { color: var(--cyan-deep); }
body.open-layout .hero .btn--light { background: var(--navy); color: var(--white); }
body.open-layout .hero .btn--outline { border-color: var(--line-strong); color: var(--ink); }
body.open-layout .hero .btn--outline:hover { background: rgba(0,0,0,.04); }
body.open-layout .hero .wrap { padding-block: clamp(56px, 8vw, 88px); }

/* In-column blocks need their own edges now that the page is tinted. */
body.open-layout .section--navy { border-radius: 12px; }
body.open-layout .booking { background: transparent; }

/* Sections that carry their own background still need inner gutters —
   .open-body zeroes .wrap padding for the transparent ones. */
body.open-layout .section--navy .wrap { padding-inline: clamp(20px, 3.5vw, 44px); }
body.open-layout .section--navy { padding-block: clamp(40px, 5vw, 64px); }

/* Narrow: the index collapses and the nav stacks its links under the logo. */
@media (max-width: 1023px) {
  body.open-layout .main { padding-top: 0; }
  .sitenav { margin-top: 12px; }
  .sitenav__bar { flex-wrap: wrap; padding: 12px; row-gap: 10px; }
  .sitenav__logo { order: 1; }
  .sitenav__cta { order: 2; margin-left: auto; }
  .sitenav__links { order: 3; flex: 1 0 100%; justify-content: flex-start; gap: 14px 18px; border-top: 1px solid var(--line); padding-top: 10px; }
}

/* Pages with too few sections to warrant an index run full width. */
.open-body--wide { grid-template-columns: 1fr; }

/* The landing frame: nav plus hero fill the viewport exactly, so nothing from
   the next section shows until the reader chooses to move. */
body.open-layout .hero { min-height: calc(100vh - var(--nav-h, 132px)); }
body.open-layout .hero .wrap { padding-block: clamp(32px, 5vw, 56px); }

/* The hero's text is framed by the nav bar above it: same width, same edges. */
body.open-layout .hero > .wrap { max-width: 1040px; display: block; padding-inline: clamp(12px, 3vw, 24px); }
body.open-layout .hero__inner { max-width: 820px; }

/* Page heroes are framed by the nav bar, exactly as the landing hero is. */
body.open-layout .page-hero > .wrap { max-width: 1040px; padding-inline: clamp(12px, 3vw, 24px); }
body.open-layout .page-hero .h1 { max-width: 20ch; }
body.open-layout .page-hero .lede { max-width: 66ch; }

/* The section index rides at the middle of the viewport. A transform would
   shift it up even before sticky engages, which let it poke into the landing
   frame; a full-height sticky box that centres its own content does not. */
.sindex { top: 0; height: 100vh; display: flex; align-items: center; padding-block: 0; }

@media (max-width: 1023px) {
  /* The rule above re-declares display, so it beat the earlier media query's
     display:none and left a 100vh index sitting on top of every phone. */
  .sindex { display: none; }
  /* The nav wraps to three rows at this width. Pinned, that is a fifth of a
     phone screen, so below the index breakpoint it scrolls away as before. */
  .sitenav { position: static; }
}

/* The nav is sticky here, so an in-page anchor has to stop clear of it. */
@media (min-width: 1024px) { html { scroll-padding-top: calc(var(--nav-h, 80px) + 8px); } }
