/* ==========================================================================
   PlatformSTL — Design v5
   Structure: 1 Fonts · 2 Tokens · 3 Base · 4 Layout · 5 Components
              6 Header · 7 Hero · 8 Sections · 9 Illustrations · 10 Pages
              11 Footer · 12 Motion · 13 Responsive · 14 Preferences
   Color pairs are checked against WCAG 2.2 AA (4.5:1 text, 3:1 UI/large).
   ========================================================================== */

/* 1. Fonts ---------------------------------------------------------------- */
@font-face {
  font-family: "Work Sans";
  src: url("../fonts/WorkSans-Regular.woff") format("woff"),
       url("../Work%20Sans/WorkSans-Regular.otf") format("opentype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Work Sans";
  src: url("../fonts/WorkSans-Medium.woff") format("woff"),
       url("../Work%20Sans/WorkSans-Medium.otf") format("opentype");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Work Sans";
  src: url("../fonts/WorkSans-SemiBold.woff") format("woff"),
       url("../Work%20Sans/WorkSans-SemiBold.otf") format("opentype");
  font-weight: 600 700;
  font-style: normal;
  font-display: swap;
}

/* 2. Tokens --------------------------------------------------------------- */
:root {
  /* brand */
  --navy-950: #0b1830;
  --navy-900: #12243f;
  --navy-800: #1a3358;   /* primary ink + brand navy */
  --navy-700: #274472;
  --gold-300: #f9ba48;
  --gold-400: #f0a15a;   /* labels on dark: 6.3:1 on navy */
  --gold-500: #e8872f;   /* decorative only on light backgrounds */
  --gold-700: #96490d;   /* labels on light: ≥5.2:1 on the warm sand surfaces */
  --clay-600: #c2462f;   /* CTA: 5:1 with white text */
  --clay-700: #a63a26;

  /* neutrals */
  --white: #ffffff;        /* light pages only — never on dark backgrounds */
  --ice: #e6eef8;          /* text on dark: 15:1 on navy-950, 7.7:1 on lightest card */
  --ice-soft: #c9d5e5;     /* secondary text on dark */
  --cream-btn: #f3ecdf;    /* light buttons/panels on dark: navy text 10.8:1 */
  --cream-btn-hover: #e9dfcc;
  --cream-ink: #fbf6ec;    /* text on clay CTA: 4.6:1 */
  --paper: #ede7dd;      /* warm sand page background (inner pages) */
  --surface: #f6f2eb;    /* soft card surface — replaces pure white on light pages */
  --cream: #f7f4ee;
  --mist: #e7eef6;
  --line: #ddd3c4;
  --line-warm: #e3d8c8;
  --field-border: #7d776d; /* 3.6:1 on sand — meets 1.4.11 */
  --ink: #2b3c55;          /* softer navy text: 9:1 on sand (was 12:1 navy on white) */
  --muted: #5a5d63;        /* warm grey: ≥5.3:1 on sand and card surfaces */
  --success: #1c7a45;
  --danger: #b42318;

  /* type */
  --font: "Work Sans", "Avenir Next", "Segoe UI", system-ui, sans-serif;
  --step--1: 0.875rem;
  --step-0: clamp(1rem, 0.96rem + 0.2vw, 1.0625rem);
  --step-1: clamp(1.125rem, 1.07rem + 0.25vw, 1.25rem);
  --step-2: clamp(1.3rem, 1.18rem + 0.6vw, 1.65rem);
  --step-3: clamp(1.8rem, 1.5rem + 1.4vw, 2.5rem);
  --step-4: clamp(2.2rem, 1.6rem + 3vw, 4.15rem);

  /* space + shape */
  --gutter: clamp(1.25rem, 4vw, 2.5rem);
  --section: clamp(3.25rem, 2.4rem + 3.6vw, 5.5rem);
  --max: 1160px;
  --radius-sm: 10px;
  --radius: 16px;
  --radius-lg: 22px;
  --shadow-sm: 0 6px 14px rgb(60 46 30 / 0.07);
  --shadow: 0 18px 44px rgb(60 46 30 / 0.08);
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);

  /* runtime (set by JS) */
  --header-h: 5.5rem;
  --focus: var(--navy-800);
}

/* 3. Base ----------------------------------------------------------------- */
*,
*::before,
*::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 1rem); /* 2.4.11 focus not obscured */
  color-scheme: light;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font);
  font-size: var(--step-0);
  line-height: 1.6;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

img,
svg,
canvas { display: block; max-width: 100%; }
img { height: auto; }

h1, h2, h3 {
  margin: 0;
  color: var(--ink);
  font-weight: 600;
  letter-spacing: -0.02em;
  text-wrap: balance;
}
h1 { font-size: var(--step-4); line-height: 1.06; letter-spacing: -0.035em; }
h2 { font-size: var(--step-3); line-height: 1.15; max-width: 20em; }
h3 { font-size: 1.15rem; line-height: 1.3; margin-block-end: 0.35rem; }
p { margin: 0; text-wrap: pretty; }

a { color: inherit; text-underline-offset: 0.18em; }

:where(ul[role="list"]) { list-style: none; margin: 0; padding: 0; }

:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
  border-radius: 4px;
}

.on-dark { --focus: var(--gold-300); }

[hidden] { display: none !important; }

.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: fixed;
  inset-block-start: 0.75rem;
  inset-inline-start: 0.75rem;
  z-index: 100;
  padding: 0.65rem 1rem;
  border-radius: 999px;
  background: var(--cream-btn);
  color: var(--navy-800);
  font-weight: 600;
  text-decoration: none;
  box-shadow: var(--shadow);
  transform: translateY(-160%);
  transition: transform 0.2s var(--ease-out);
}
.skip-link:focus { transform: none; }

/* 4. Layout --------------------------------------------------------------- */
.wrap {
  width: min(var(--max), 100% - 2 * var(--gutter));
  margin-inline: auto;
}

.section { padding-block: var(--section); }
.section--white { background: var(--surface); }
.section--cream { background: var(--cream); }
.section--mist { background: var(--mist); }
.section--paper { background: var(--paper); }

.split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
  gap: clamp(1.75rem, 4vw, 3.5rem);
  align-items: center;
}

/* 5. Components ----------------------------------------------------------- */
.eyebrow {
  margin: 0 0 0.7rem;
  color: var(--gold-700);
  font-size: var(--step--1);
  font-weight: 600;
  letter-spacing: 0.12em;
  line-height: 1.4;
  text-transform: uppercase;
}
.on-dark .eyebrow { color: var(--gold-400); }

.lede {
  max-width: 40rem;
  margin-block-start: 1rem;
  color: var(--muted);
  font-size: var(--step-1);
  line-height: 1.55;
}

.section-intro {
  max-width: 44rem;
  margin-block-start: 0.9rem;
  color: var(--muted);
}

.rule::after {
  content: "";
  display: block;
  width: 2.75rem;
  height: 3px;
  margin-block-start: 1.1rem;
  border-radius: 3px;
  background: var(--gold-500);
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-block-start: 1.6rem;
}

.button {
  --btn-bg: var(--clay-600);
  --btn-fg: var(--cream-ink);
  --btn-border: transparent;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  min-height: 3rem;
  padding: 0.8rem 1.6rem;
  border: 1px solid var(--btn-border);
  border-radius: 999px;
  background: var(--btn-bg);
  color: var(--btn-fg);
  font: inherit;
  font-weight: 600;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  box-shadow: var(--shadow-sm);
  transition: transform 0.18s ease, background-color 0.18s ease, color 0.18s ease, box-shadow 0.18s ease;
}
.button:hover { transform: translateY(-2px); box-shadow: 0 12px 24px rgb(30 38 51 / 0.16); }
.button:active { transform: none; }
.button:disabled { opacity: 0.7; cursor: progress; transform: none; }

.button--primary:hover { --btn-bg: var(--clay-700); }
.button--light { --btn-bg: var(--cream-btn); --btn-fg: var(--navy-800); --btn-border: var(--cream-btn); }
.button--light:hover { --btn-bg: var(--cream-btn-hover); --btn-border: var(--cream-btn-hover); }
.button--orange { /* navy text ≥5.7:1 across the gradient */
  --btn-fg: var(--navy-900);
  --btn-border: transparent;
  background: linear-gradient(180deg, rgb(248 169 76 / 0.95) 0%, rgb(238 138 48 / 0.95) 100%);
  box-shadow: inset 0 1px 0 rgb(255 240 215 / 0.55), 0 6px 18px rgb(238 138 48 / 0.32);
}
.button--orange:hover {
  background: linear-gradient(180deg, rgb(255 180 88 / 0.95) 0%, rgb(242 145 58 / 0.95) 100%);
  box-shadow: inset 0 1px 0 rgb(255 240 215 / 0.6), 0 10px 28px rgb(238 138 48 / 0.45);
}
.button--ghost { --btn-bg: transparent; --btn-fg: var(--ice); --btn-border: rgb(230 238 248 / 0.55); box-shadow: none; }
.button--ghost:hover { --btn-bg: rgb(230 238 248 / 0.1); --btn-border: var(--ice); }

.button .arrow { transition: transform 0.18s ease; }
.button:hover .arrow { transform: translateX(3px); }

.card {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.5rem 1.35rem;
  transition: transform 0.25s var(--ease-out), box-shadow 0.25s ease, border-color 0.25s ease;
}
.card p:not(.meta) { color: var(--muted); }
.card:hover { border-color: #cbbfae; box-shadow: var(--shadow); transform: translateY(-3px); }

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 18rem), 1fr));
  gap: 1rem;
  margin-block-start: 2rem;
}

.icon {
  display: grid;
  place-items: center;
  width: 3rem;
  height: 3rem;
  margin-block-end: 1rem;
  border-radius: 14px;
}
.icon svg {
  width: 1.45rem;
  height: 1.45rem;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.icon--gold { background: #fff4dc; color: #8d5e10; }
.icon--clay { background: #fde8e0; color: #a84b2c; }
.icon--slate { background: #e8edf3; color: #3c4654; }

.text-link {
  font-weight: 600;
  color: var(--navy-800);
  text-decoration-thickness: 1px;
}
.text-link:hover { text-decoration-thickness: 2px; }

/* Forms */
.form-card {
  background: var(--surface);
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(1.25rem, 3vw, 1.75rem);
  box-shadow: var(--shadow);
  --focus: var(--navy-800);
}

.form { display: grid; gap: 1.1rem; }
.field { display: grid; gap: 0.35rem; }
.field label { font-size: 0.92rem; font-weight: 600; }
.field .req { color: var(--muted); font-weight: 500; }

.field input,
.field textarea {
  width: 100%;
  min-height: 2.9rem;
  padding: 0.7rem 0.85rem;
  border: 1px solid var(--field-border);
  border-radius: var(--radius-sm);
  background: #fbf8f3;
  color: var(--ink);
  font: inherit;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.field textarea { min-height: 8.5rem; resize: vertical; }
.field input:focus-visible,
.field textarea:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 1px;
  border-color: var(--navy-800);
}
.field [aria-invalid="true"] { border-color: var(--danger); box-shadow: 0 0 0 1px var(--danger); }
.field-error { color: var(--danger); font-size: 0.9rem; font-weight: 500; }
.field-error:empty { display: none; }

.form .button { justify-self: start; }
.form-status { min-height: 1.5rem; font-weight: 500; }
.form-status.is-success { color: var(--success); }
.form-status.is-error { color: var(--danger); }

/* honeypot: kept in the DOM for bots, removed from focus and the a11y tree via [inert] */
.hp { position: absolute; inset-inline-start: -9999px; }

/* 6. Header --------------------------------------------------------------- */
.site-header {
  --solid: 1;
  position: fixed;
  inset: 0 0 auto;
  z-index: 50;
  color: var(--ice);
  background: rgb(14 27 48 / calc(var(--solid) * 0.94));
  border-block-end: 1px solid rgb(230 238 248 / calc(var(--solid) * 0.1));
  box-shadow: 0 10px 28px rgb(8 16 32 / calc(var(--solid) * 0.22));
  -webkit-backdrop-filter: blur(calc(var(--solid) * 16px)) saturate(1.15);
  backdrop-filter: blur(calc(var(--solid) * 16px)) saturate(1.15);
}
.site-header[data-overlay] { --solid: var(--lock, 0); }

.header-row {
  display: flex;
  align-items: center;
  gap: 1.75rem;
  min-height: 5.5rem;
  width: min(1240px, 100% - 2 * var(--gutter));
  margin-inline: auto;
}

.brand {
  flex: none;
  display: block;
  width: 11rem;
  border-radius: 6px;
  transform-origin: 0 0;
}
.brand img { width: 100%; }
.brand.is-flying { will-change: transform; }
.brand.is-tucked { visibility: hidden; }
.offer .art-panel { padding: 0.5rem; }

.nav { margin-inline-start: auto; }
.nav ul { display: flex; gap: clamp(1.25rem, 3vw, 3rem); }
.nav a {
  position: relative;
  display: inline-block;
  padding-block: 0.5rem;
  color: var(--ice);
  font-weight: 500;
  text-decoration: none;
  text-shadow: 0 1px 12px rgb(6 12 22 / calc((1 - var(--solid)) * 0.55));
}
.nav a::after {
  content: "";
  position: absolute;
  inset: auto 0 0.15rem;
  height: 2px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.22s ease;
}
.nav a:hover::after { transform: scaleX(1); }
.nav a[aria-current="page"]::after { transform: scaleX(1); background: var(--gold-500); }

.header-cta { min-height: 2.75rem; padding: 0.55rem 2rem; }

.page-main { padding-block-start: var(--header-h); }

/* 7. Hero ----------------------------------------------------------------- */
.hero {
  position: relative;
  isolation: isolate;
  display: flex;
  align-items: center;
  min-height: 100vh;
  min-height: 100svh;
  padding-block: calc(var(--header-h) + 2rem) 5rem;
  overflow: hidden;
  color: var(--ice);
  background:
    radial-gradient(80% 60% at 78% 18%, rgb(39 68 114 / 0.9), transparent 70%),
    linear-gradient(165deg, var(--navy-900) 0%, var(--navy-800) 55%, var(--navy-950) 100%);
}

.hero-canvas {
  position: absolute;
  inset: 0;
  z-index: -2;
  width: 100%;
  height: 100%;
}

/* scrim keeps headline contrast well above AA regardless of what the canvas draws */
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    linear-gradient(90deg, rgb(13 26 48 / 0.45) 0%, rgb(13 26 48 / 0.25) 40%, rgb(13 26 48 / 0) 70%),
    linear-gradient(0deg, rgb(11 24 48 / 0.45) 0%, rgb(11 24 48 / 0) 14%);
}

.hero-inner { width: min(var(--max), 100% - 2 * var(--gutter)); margin-inline: auto; }

.hero-logo {
  width: min(26rem, 72vw);
  margin-block-end: 1.5rem;
}
.hero-logo img { width: 100%; }
html.js-fly .hero-logo { visibility: hidden; }

.hero h1,
.theme-dark .hero h1 { color: #95abc7; max-width: none; } /* ≥5.4:1 on the hero navy */
.hero h1 span { display: block; }
.hero h1::after { margin-block-start: 1.25rem; }

.hero-proof {
  margin-block-start: 1.1rem;
  color: #e6b98a; /* warm apricot accent: ≥7:1 on the hero navy */
  font-size: var(--step-1);
  font-weight: 500;
}

.motion-toggle {
  position: absolute;
  inset-block-end: 1.25rem;
  inset-inline-end: var(--gutter);
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  min-height: 2.5rem;
  padding: 0.4rem 0.9rem 0.4rem 0.7rem;
  border: 1px solid rgb(230 238 248 / 0.35);
  border-radius: 999px;
  background: rgb(11 24 48 / 0.55);
  color: var(--ice);
  font: inherit;
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}
.motion-toggle:hover { background: rgb(11 24 48 / 0.8); border-color: var(--ice); }
.motion-toggle svg { width: 1rem; height: 1rem; fill: currentColor; }
.motion-toggle .icon-play { display: none; }
.motion-toggle[data-state="paused"] .icon-play { display: block; }
.motion-toggle[data-state="paused"] .icon-pause { display: none; }

/* 8. Home sections ------------------------------------------------------- */
.capability .icon { margin-inline: 0; }

.offer-note {
  max-width: 36rem;
  margin-block-start: 1.5rem;
  padding-block-start: 1.25rem;
  border-block-start: 1px solid var(--line-warm);
}
.offer-note p + p { margin-block-start: 0.6rem; color: var(--muted); }
.offer-note p:first-child { font-size: var(--step-1); font-weight: 500; letter-spacing: -0.01em; }
.offer .section-intro { color: var(--ink); font-size: var(--step-1); }

.case-panel {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  gap: 1.5rem;
  margin-block-start: 2.25rem;
  padding: 0.9rem;
  background: var(--surface);
  border: 1px solid #d5deea;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
}
.case-proof { align-self: center; padding: clamp(0.75rem, 2vw, 1.5rem); }
.case-proof h3 { max-width: 16em; font-size: var(--step-2); line-height: 1.25; }
.case-proof p { margin-block-start: 0.8rem; color: var(--muted); }

.partners { text-align: center; }
.partners h2.eyebrow { max-width: none; font-size: var(--step--1); line-height: 1.4; letter-spacing: 0.12em; }
.partners .section-intro { margin-inline: auto; }
.logo-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 1.5rem 4rem;
  margin-block-start: 1.75rem;
}
.logo-row img { width: auto; height: 4.6rem; max-width: 18rem; object-fit: contain; }

.closer { background: #1d2a40; color: var(--ice); }
.closer h2 { color: var(--ice); }
.closer-copy p:not(.eyebrow) { max-width: 34rem; margin-block-start: 0.85rem; color: #d5dbe3; }
.closer-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1fr);
  gap: 2rem clamp(2rem, 5vw, 4rem);
  align-items: start;
}

/* 9. Illustrations ------------------------------------------------------- */
.art-panel {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 20rem;
  padding: clamp(1rem, 3vw, 2rem);
  overflow: hidden;
  border-radius: var(--radius-lg);
}
.art-panel--light {
  background:
    radial-gradient(70% 60% at 70% 30%, rgb(249 186 72 / 0.12), transparent 70%),
    var(--surface);
  border: 1px solid var(--line-warm);
}
.art-panel--dark {
  background:
    radial-gradient(60% 50% at 50% 30%, rgb(143 179 227 / 0.22), transparent 70%),
    radial-gradient(50% 40% at 80% 90%, rgb(249 186 72 / 0.12), transparent 70%),
    var(--navy-800);
}
.art-panel--dark::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgb(230 238 248 / 0.08) 1px, transparent 1.4px);
  background-size: 22px 22px;
  -webkit-mask-image: radial-gradient(circle at 50% 45%, #000 20%, transparent 75%);
  mask-image: radial-gradient(circle at 50% 45%, #000 20%, transparent 75%);
}
.blocks-art { position: relative; width: 100%; height: auto; overflow: visible; }

/* growth scene */
.bk-plate { fill: #f3f6fa; }
.bk-grid line { stroke: #d5dde8; stroke-width: 1; }
.bk-path { fill: none; stroke: var(--navy-800); stroke-opacity: 0.16; stroke-width: 8; stroke-linecap: round; stroke-linejoin: round; }
.bk-flow { fill: none; stroke: var(--gold-500); stroke-width: 3.5; stroke-linecap: round; stroke-dasharray: 9 91; stroke-dashoffset: 100; opacity: 0; }

/* platform scene */
.pl-grid line { stroke: var(--ice); stroke-opacity: 0.08; stroke-width: 1; }
.pl-grid-light line { stroke: var(--navy-800); stroke-opacity: 0.1; }
.pl-link { stroke: #8fb3e3; stroke-opacity: 0.45; stroke-width: 1.5; }
.pl-pulse { fill: none; stroke: var(--gold-300); stroke-width: 3; stroke-linecap: round; stroke-dasharray: 12 88; stroke-dashoffset: 100; opacity: 0; }
.pl-node { fill: var(--gold-300); }

/* 10. Inner pages -------------------------------------------------------- */
.page-intro { padding-block: clamp(3rem, 6vw, 4.5rem) var(--section); }

.feature-project {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  margin-block-start: 2.25rem;
  overflow: hidden;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
}
.feature-project .art-panel { border-radius: 0; min-height: 18rem; }
.feature-project .copy { align-self: center; padding: clamp(1.5rem, 3vw, 2.25rem); }
.feature-project h2 { margin-block-end: 0.6rem; }
.feature-project p { color: var(--muted); }

.meta {
  margin-block-end: 0.4rem;
  color: var(--gold-700);
  font-size: var(--step--1);
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.project { overflow: hidden; }
.project::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 3px;
  background: linear-gradient(90deg, var(--gold-500), #e07040);
}
.project .text-link,
.feature-project .text-link { display: inline-block; margin-block-start: 0.9rem; }

.feature-project + .card-grid { margin-block-start: 1.25rem; }
.card-grid--two { grid-template-columns: repeat(auto-fit, minmax(min(100%, 24rem), 1fr)); }

.also { margin-block-start: 1.75rem; border-block-start: 1px solid var(--line); }
.also article {
  display: grid;
  grid-template-columns: 16rem 1fr;
  gap: 1.25rem;
  padding-block: 1rem;
  border-block-end: 1px solid var(--line);
}
.also h3 { font-size: 1.02rem; }
.also p { color: var(--muted); }

.about-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 0.75fr);
  gap: 1.5rem 2.25rem;
  align-items: start;
  margin-block-start: 1.5rem;
}
.about-grid .lede { margin-block-start: 0; }
.about-copy p + p { margin-block-start: 1rem; color: var(--muted); }

.note-card {
  padding: 1.6rem 1.5rem;
  border-radius: var(--radius-lg);
  background: #34465f;
  color: var(--ice-soft);
}
.note-card .note-lead {
  margin-block-end: 0.75rem;
  color: var(--ice);
  font-size: var(--step-2);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.28;
}

.people { margin-block-start: clamp(2.5rem, 5vw, 3.5rem); }
.people > .lede { margin-block-start: 0.25rem; max-width: 46rem; }

.roster {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 18rem), 1fr));
  gap: 1.25rem;
  margin-block-start: 1.75rem;
}
.roster img {
  width: 7.25rem;
  height: 7.25rem;
  margin-block-end: 1rem;
  object-fit: cover;
  object-position: center 16%;
  border-radius: 50%;
}
.roster .kevin img { object-position: center 28%; }
.roster h3 { margin: 0; }
.roster .role { display: block; color: #4a5465; font-size: 0.92rem; font-weight: 600; }
.roster p { margin-block-start: 0.5rem; font-size: 0.98rem; }

.contact-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: 1.5rem 2rem;
  align-items: start;
  margin-block-start: 2rem;
}
.aspects { display: grid; gap: 0.75rem; }
.aspects li {
  padding: 1rem 1.15rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.aspects h2 { font-size: 1.05rem; line-height: 1.35; letter-spacing: -0.01em; margin-block-end: 0.2rem; }
.aspects p { color: var(--muted); font-size: 0.97rem; }

/* 11. Footer ------------------------------------------------------------- */
.site-footer {
  padding-block: 3rem 1.5rem;
  background: #132743;
  color: var(--ice-soft);
  font-size: 0.98rem;
}
.footer-brand {
  max-width: 36rem;
  padding-block-end: 1.5rem;
  margin-block-end: 1.5rem;
  border-block-end: 1px solid rgb(230 238 248 / 0.14);
}
.footer-name { color: var(--ice); font-size: 1.55rem; font-weight: 600; letter-spacing: -0.03em; }
.footer-brand p + p { margin-block-start: 0.4rem; }
.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 14rem), 1fr));
  gap: 1.75rem 2.5rem;
}
.footer-label {
  margin-block-end: 0.55rem;
  color: var(--gold-400);
  font-size: var(--step--1);
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.site-footer address { font-style: normal; }
.site-footer a { color: var(--ice); text-decoration: none; }
.site-footer a:hover { color: var(--gold-400); text-decoration: underline; }
.footer-links ul { display: grid; gap: 0.45rem; }
.footer-base {
  margin-block-start: 1.75rem;
  padding-block-start: 1rem;
  border-block-start: 1px solid rgb(230 238 248 / 0.14);
  color: #9fadc0;
  font-size: 0.92rem;
}
.design-version { margin-inline-start: 0.75rem; font-size: 0.78rem; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; }

/* 12. Motion ------------------------------------------------------------- */
/* Content is fully visible without JS; JS opts elements into reveal. */
html.js [data-reveal] {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.7s var(--ease-out), transform 0.7s var(--ease-out);
  transition-delay: var(--d, 0ms);
}
html.js [data-reveal].is-in { opacity: 1; transform: none; }

.hero-inner > * { animation: rise 0.8s var(--ease-out) both; }
.hero-inner > :nth-child(2) { animation-delay: 0.05s; }
.hero-inner > :nth-child(3) { animation-delay: 0.12s; }
.hero-inner > :nth-child(4) { animation-delay: 0.2s; }

@keyframes rise {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: none; }
}

/* growth scene: blocks drop into place in story order, then data runs the route (finite: < 5s) */
html.js .blocks-grow .bk {
  opacity: 0;
  transform: translateY(-26px);
  transition: opacity 0.45s ease, transform 0.6s var(--ease-out);
  transition-delay: calc(var(--i) * 55ms + 150ms);
}
html.js .is-in .blocks-grow .bk { opacity: 1; transform: none; }
html.js .is-in .bk-flow { animation: route-flow 2.2s linear 1.6s 2 both; }
@keyframes route-flow {
  0% { stroke-dashoffset: 100; opacity: 0; }
  8% { opacity: 1; }
  92% { opacity: 1; }
  100% { stroke-dashoffset: 9; opacity: 0; }
}

/* platform scene: layers rise, modules settle, pulses travel between layers (finite) */
html.js .blocks-platform .pl-layer {
  opacity: 0;
  transform: translateY(34px);
  transition: opacity 0.6s ease, transform 0.9s var(--ease-out);
  transition-delay: calc(var(--l) * 160ms + 100ms);
}
html.js .blocks-platform .pl-mod {
  opacity: 0;
  transform: translateY(-14px);
  transition: opacity 0.4s ease, transform 0.5s var(--ease-out);
  transition-delay: calc(var(--i) * 35ms + 600ms);
}
html.js .blocks-platform .pl-links { opacity: 0; transition: opacity 0.6s ease 0.9s; }
html.js .is-in .blocks-platform .pl-layer,
html.js .is-in .blocks-platform .pl-mod { opacity: 1; transform: none; }
html.js .is-in .blocks-platform .pl-links { opacity: 1; }
html.js .is-in .pl-pulse { animation: pulse-up 1.5s ease-in calc(1.2s + var(--j) * 0.18s) 2 both; }
@keyframes pulse-up {
  0% { stroke-dashoffset: -88; opacity: 0; }
  15% { opacity: 1; }
  100% { stroke-dashoffset: 12; opacity: 0; }
}

/* 13. Responsive --------------------------------------------------------- */
@media (max-width: 900px) {
  .split,
  .case-panel,
  .closer-grid,
  .about-grid,
  .contact-layout,
  .feature-project { grid-template-columns: minmax(0, 1fr); }
  .case-panel .art-panel { order: 2; }
  .also article { grid-template-columns: 1fr; gap: 0.25rem; }
}

@media (max-width: 760px) {
  :root { --header-h: 7.25rem; }
  .header-row {
    display: grid;
    grid-template-columns: 1fr auto auto;
    gap: 0.25rem 0.5rem;
    min-height: 0;
    padding-block: 0.6rem 0.2rem;
  }
  .brand { width: 8rem; }
  .brand { grid-column: 1; grid-row: 1; }
  .theme-switch { grid-column: 3; grid-row: 1; margin: 0; }
  .header-cta { grid-column: 2; grid-row: 1; min-height: 2.5rem; padding: 0.45rem 1.1rem; font-size: 0.95rem; }
  .nav { grid-column: 1 / -1; grid-row: 2; margin: 0; }
  .nav ul { gap: 1.75rem; }
  .hero { align-items: flex-start; padding-block-start: calc(var(--header-h) + 1.5rem); }
  .hero::before {
    background:
      linear-gradient(180deg, rgb(13 26 48 / 0.75) 0%, rgb(13 26 48 / 0.55) 55%, rgb(13 26 48 / 0.1) 100%);
  }
  .hero-logo { width: min(13rem, 62vw); }
  .logo-row img { height: 3.4rem; max-width: 42vw; }
  .art-panel { min-height: 15rem; }
}

/* 14. User preferences --------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    transition-delay: 0ms !important;
  }
  html.js [data-reveal],
  html.js .blocks-grow .bk,
  html.js .blocks-platform .pl-layer,
  html.js .blocks-platform .pl-mod,
  html.js .blocks-platform .pl-links { opacity: 1; transform: none; }
  .bk-flow,
  .pl-pulse { display: none; }
  .card:hover,
  .button:hover { transform: none; }
}

@media (forced-colors: active) {
  .button,
  .card,
  .form-card,
  .motion-toggle { border: 1px solid CanvasText; }
  .hero::before { display: none; }
}

@media print {
  .site-header,
  .hero-canvas,
  .motion-toggle,
  .form-card { display: none; }
  .hero { min-height: 0; color: #000; background: none; }
  .hero h1 { color: #000; }
  .page-main { padding: 0; }
}

/* No-JS fallback: overlay header stays solid so it never sits transparently over content */
html:not(.js) .site-header[data-overlay] { --solid: 1; }
main:focus { outline: none; }

/* 15. Dark home theme ----------------------------------------------------
   The home page stays in the hero's navy all the way down, so there is no
   dark → light flip. Sections step between close navy surfaces and are
   separated by soft glows and hairlines rather than color changes.
   All text pairs ≥ 7:1 (body #b9c5d6 on #0b1830 = 10.1:1, on cards = 7.8:1). */
.theme-dark {
  --surface-0: #0b1830;          /* matches the bottom of the hero */
  --surface-1: #0e1d38;
  --surface-2: #12243f;
  --card-bg: #142a4a;
  --card-border: rgb(230 238 248 / 0.1);
  --text-soft: var(--ice-soft);
  --focus: var(--gold-300);
  background: var(--surface-0);
  color: var(--ice);
}
.theme-dark main h1,
.theme-dark main h2,
.theme-dark main h3 { color: var(--ice); }
.theme-dark .eyebrow { color: var(--gold-400); }
.theme-dark .section-intro,
.theme-dark .card p:not(.meta),
.theme-dark .case-proof p,
.theme-dark .offer-note p + p { color: var(--text-soft); }
.theme-dark .offer .section-intro,
.theme-dark .offer-note p:first-child { color: var(--ice); }
.theme-dark .text-link { color: var(--ice); }
.theme-dark .text-link:hover { color: var(--gold-300); }

/* Seamless transitions: every section starts on the exact colour the one above
   ends on and eases into its own tone over a long blend (no hard lines).
   Chain: hero → #0b1830 → capabilities → #0e1d38 → bench → #0b1830 → in action
   → #0e1d38 → partners → #12243f → closer → #091327 → footer. */
.theme-dark .section { position: relative; isolation: isolate; }
.theme-dark .section--white {
  /* Capabilities: a lighter steel-navy band that rises out of the hero and settles back down */
  --card-bg: rgb(16 30 52 / 0.38);             /* translucent: the band shows through */
  --card-border: rgb(230 238 248 / 0.12);
  padding-block: calc(var(--section) + 2rem);
  background:
    radial-gradient(60% 50% at 85% 18%, rgb(143 179 227 / 0.14), transparent 70%),
    linear-gradient(180deg, #0b1830 0%, #1b375e 14rem, #1d3a62 55%, #1a355b calc(100% - 14rem), #0e1d38 100%);
}
.theme-dark .section--cream {
  background:
    radial-gradient(50% 60% at 85% 50%, rgb(232 135 47 / 0.07), transparent 70%),
    linear-gradient(180deg, #0e1d38 0%, #0e1d38 60%, #0b1830 100%);
}
.theme-dark .section--mist {
  background:
    radial-gradient(55% 45% at 20% 10%, rgb(143 179 227 / 0.09), transparent 70%),
    linear-gradient(180deg, #0b1830 0%, #0b1830 55%, #0e1d38 100%);
}
.theme-dark .section--paper {
  background: linear-gradient(180deg, #0e1d38 0%, #10213d 50%, #12243f 100%);
}

/* hero melts into the first section: the last stretch fades to the same solid navy */
.theme-dark .hero::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 26%;
  z-index: -1;
  pointer-events: none;
  background: linear-gradient(0deg, #0b1830 0%, rgb(11 24 48 / 0.6) 40%, rgb(11 24 48 / 0) 100%);
}
.theme-dark .closer {
  background:
    radial-gradient(50% 60% at 90% 30%, rgb(249 186 72 / 0.07), transparent 70%),
    linear-gradient(180deg, #12243f 0%, #12243f 60%, #091327 100%);
}
.theme-dark .closer-copy p:not(.eyebrow) { color: var(--text-soft); }

/* cards */
.theme-dark .card {
  background: linear-gradient(180deg, rgb(230 238 248 / 0.035), transparent), var(--card-bg);
  border-color: var(--card-border);
}
.theme-dark .card:hover {
  border-color: rgb(249 186 72 / 0.45);
  box-shadow: 0 18px 44px rgb(0 0 0 / 0.35);
}
.theme-dark .icon--gold { background: rgb(249 186 72 / 0.14); color: var(--gold-300); }
.theme-dark .icon--clay { background: rgb(242 154 114 / 0.14); color: #f5a27e; }
.theme-dark .icon--slate { background: rgb(143 179 227 / 0.14); color: #a9c4ea; }

/* offer + case study */
.theme-dark .offer-note { border-block-start-color: rgb(230 238 248 / 0.14); }
.theme-dark .case-panel {
  background: var(--card-bg);
  border-color: var(--card-border);
  box-shadow: 0 24px 60px rgb(0 0 0 / 0.35);
}

/* growth illustration, re-lit for a dark panel */
.theme-dark .art-panel--light {
  background:
    radial-gradient(70% 60% at 70% 30%, rgb(249 186 72 / 0.1), transparent 70%),
    var(--navy-800);
  border-color: var(--card-border);
}
.theme-dark .bk-plate { fill: #20406c; }
.theme-dark .bk-grid line { stroke: rgb(230 238 248 / 0.09); }
.theme-dark .bk-path { stroke: var(--ice); stroke-opacity: 0.16; }
.theme-dark .art-panel--dark { box-shadow: inset 0 0 0 1px var(--card-border); }

/* partner logos are dark artwork, so they sit on light plates */
.theme-dark .logo-row li {
  display: grid;
  place-items: center;
  min-width: 13rem;
  padding: 1rem 1.75rem;
  border-radius: var(--radius);
  background: var(--cream-btn);
  box-shadow: 0 12px 30px rgb(0 0 0 / 0.25);
}
.theme-dark .logo-row img { height: 3.6rem; }

.theme-dark .site-footer { background: #091327; }

@media (max-width: 760px) {
  .theme-dark .logo-row li { min-width: 0; padding: 0.75rem 1.1rem; }
  .theme-dark .logo-row img { height: 2.8rem; }
}



/* 16. Interaction polish ------------------------------------------------- */
/* Pointer spotlight: cards and panels catch a soft light that follows the cursor
   (--mx/--my set by motion.js; fine pointers only, off for reduced motion). */
.theme-dark .card,
.theme-dark .case-panel { --mx: 50%; --my: 0%; --spot: 0; isolation: isolate; }
.theme-dark .card::after,
.theme-dark .case-panel::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: inherit;
  pointer-events: none;
  opacity: var(--spot);
  transition: opacity 0.35s ease;
  background: radial-gradient(22rem circle at var(--mx) var(--my), rgb(143 179 227 / 0.12), transparent 60%);
}
.theme-dark .case-panel { position: relative; }
.theme-dark .card::before {
  /* hairline that brightens toward the pointer */
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  padding: 1px;
  pointer-events: none;
  opacity: var(--spot);
  transition: opacity 0.35s ease;
  background: radial-gradient(14rem circle at var(--mx) var(--my), rgb(249 186 72 / 0.55), transparent 70%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0);
}
.theme-dark .card:hover { transform: translateY(-4px); }
.card .icon { transition: transform 0.4s var(--ease-out), background-color 0.3s ease; }
.card:hover .icon { transform: translateY(-2px) scale(1.06); }

/* Illustration panels tilt gently toward the pointer (--rx/--ry from motion.js) */
.art-panel { --rx: 0deg; --ry: 0deg; perspective: 1200px; }
.art-panel .blocks-art {
  transform: rotateX(var(--rx)) rotateY(var(--ry));
  transition: transform 0.6s var(--ease-out);
  will-change: transform;
}

/* Buttons: soft sheen sweeps across on hover */
.button { position: relative; overflow: hidden; isolation: isolate; }
.button::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(110deg, transparent 30%, rgb(255 255 255 / 0.28) 50%, transparent 70%);
  transform: translateX(-120%);
  transition: transform 0.7s var(--ease-out);
}
.button:hover::after { transform: translateX(120%); }

/* Text links: underline draws in from the left */
.text-link {
  text-decoration: none;
  background: linear-gradient(currentColor, currentColor) 0 100% / 100% 1px no-repeat;
  transition: background-size 0.35s var(--ease-out), color 0.2s ease;
}
.text-link:hover { background-size: 0% 1px; background-position: 100% 100%; }

/* Partner plates lift on hover */
.theme-dark .logo-row li { transition: transform 0.3s var(--ease-out), box-shadow 0.3s ease; }
.theme-dark .logo-row li:hover { transform: translateY(-3px); box-shadow: 0 18px 36px rgb(0 0 0 / 0.35); }

/* Form fields: soft focus glow in addition to the AA focus outline */
.field input:focus-visible,
.field textarea:focus-visible { box-shadow: 0 0 0 5px rgb(26 51 88 / 0.12); }

/* Header gains depth once it is solid */
.site-header { transition: box-shadow 0.3s ease; }

@media (prefers-reduced-motion: reduce) {
  .art-panel .blocks-art { transform: none !important; }
  .button::after { display: none; }
  .theme-dark .card:hover,
  .theme-dark .logo-row li:hover { transform: none; }
}
@media (hover: none) {
  .theme-dark .card::after,
  .theme-dark .card::before,
  .theme-dark .case-panel::after { display: none; }
}


/* 17. Dark mode everywhere -------------------------------------------------
   Every page uses the dark theme, so moving between pages never flips
   between light and dark. Tokens are re-pointed for dark surfaces. */
.theme-dark {
  --ink: var(--ice);
  --muted: var(--ice-soft);
  --line: rgb(230 238 248 / 0.12);
  --surface: var(--card-bg);
}
.theme-dark .page-intro {
  background:
    radial-gradient(60% 40% at 85% 0%, rgb(143 179 227 / 0.1), transparent 70%),
    linear-gradient(180deg, #0e1d38 0%, #0b1830 100%);
}
.theme-dark .meta { color: var(--gold-400); }
.theme-dark .feature-project,
.theme-dark .aspects li {
  background: var(--card-bg);
  border-color: var(--card-border);
  box-shadow: 0 18px 44px rgb(0 0 0 / 0.3);
}
.theme-dark .feature-project .art-panel--dark { box-shadow: none; }
.theme-dark .also,
.theme-dark .also article { border-color: var(--line); }
.theme-dark .roster .role { color: var(--gold-400); }
.theme-dark .note-card { background: #1d3355; box-shadow: inset 0 0 0 1px var(--card-border); }

/* Dark form */
.theme-dark .form-card {
  --focus: var(--gold-300);
  background: rgb(14 28 52 / 0.85);
  border: 1px solid var(--card-border);
  color: var(--ice);
  box-shadow: 0 24px 60px rgb(0 0 0 / 0.35);
}
.theme-dark .field .req { color: var(--ice-soft); }
.theme-dark .field input,
.theme-dark .field textarea {
  background: #0c1a33;                 /* ice text 14.8:1 */
  color: var(--ice);
  border-color: #7d93b2;               /* 5.5:1 against the field — meets 1.4.11 */
}
.theme-dark .field input:focus-visible,
.theme-dark .field textarea:focus-visible { border-color: var(--gold-300); box-shadow: 0 0 0 5px rgb(249 186 72 / 0.15); }
.theme-dark .field [aria-invalid="true"] { border-color: #ff8a7a; box-shadow: 0 0 0 1px #ff8a7a; }
.theme-dark .field-error,
.theme-dark .form-status.is-error { color: #ff8a7a; }   /* 6.8:1 */
.theme-dark .form-status.is-success { color: #6fd39b; } /* 8.5:1 */

/* Outline CTA: orange outline on 75%-opaque dark blue (Visit Trusted Kidney) */
.button--outline {
  --btn-bg: rgb(18 36 63 / 0.75);
  --btn-fg: var(--ice);
  --btn-border: var(--gold-500);
  border-width: 1.5px;
}
.button--outline:hover {
  --btn-bg: rgb(18 36 63 / 0.9);
  --btn-border: #f6a347;
  box-shadow: 0 10px 26px rgb(232 135 47 / 0.25);
}
.button--outline .arrow { color: var(--gold-400); }

/* Key Partners line: larger, and on one line wherever there is room */
.partners .partner-note {
  max-width: none;
  font-size: var(--step-1);
  line-height: 1.45;
}
@media (min-width: 1000px) {
  .partners .partner-note { white-space: nowrap; }
}

/* 18. Theme switch (rocker) --------------------------------------------- */
.theme-switch {
  flex: none;
  display: inline-grid;
  place-items: center;
  min-width: 2.75rem;
  min-height: 2.75rem;               /* 44px target */
  margin-inline-start: 0.25rem;
  padding: 0;
  border: 0;
  background: none;
  color: inherit;
  cursor: pointer;
  border-radius: 999px;
}
.theme-switch__track {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 4rem;
  height: 2rem;
  padding: 0 0.5rem;
  border-radius: 999px;
  background: rgb(230 238 248 / 0.1);
  box-shadow: inset 0 0 0 1px rgb(230 238 248 / 0.35), inset 0 2px 6px rgb(0 0 0 / 0.25);
  transition: background-color 0.3s ease, box-shadow 0.3s ease;
}
.theme-switch__icon { width: 0.95rem; height: 0.95rem; fill: none; stroke: currentColor; stroke-width: 1.4; stroke-linecap: round; position: relative; z-index: 1; }
.theme-switch__moon { fill: currentColor; stroke: none; }
.theme-switch__thumb {
  position: absolute;
  inset-block-start: 0.2rem;
  inset-inline-start: 0.2rem;
  width: 1.6rem;
  height: 1.6rem;
  border-radius: 50%;
  background: linear-gradient(180deg, #f8a94c, #ee8a30);
  box-shadow: 0 2px 6px rgb(0 0 0 / 0.35), inset 0 1px 0 rgb(255 240 215 / 0.6);
  transition: transform 0.35s var(--ease-out);
}
.theme-switch[aria-checked="true"] .theme-switch__thumb { transform: translateX(2rem); }
.theme-switch:hover .theme-switch__track { background: rgb(230 238 248 / 0.18); }
.theme-switch:focus-visible { outline-offset: 2px; }

/* logo swap: white logo on dark, full-colour logo on light */
.logo-on-light { display: none; }
.theme-light .logo-on-dark { display: none; }
.theme-light .logo-on-light { display: block; }

/* 19. Cream light theme --------------------------------------------------
   Same layout, cream base. Text pairs ≥4.8:1 (ink 10:1, muted 5.5:1, amber 5.3:1). */
.theme-light {
  --paper: #f8f3ea;
  --surface: #fdfaf4;
  --line: #e4d9c6;
  --ink: #2b3c55;
  --muted: #5a5d63;
  --gold-700: #96490d;
  --field-border: #8a7f6e;
  --focus: var(--navy-800);
  --card-bg: rgb(255 252 246 / 0.7);
  --card-border: #e4d9c6;
  background: var(--paper);
  color: var(--ink);
}
.theme-light main h1,
.theme-light main h2,
.theme-light main h3 { color: var(--ink); }
.theme-light .on-dark { --focus: var(--navy-800); }

/* header */
.theme-light .site-header {
  color: var(--ink);
  background: rgb(248 243 234 / calc(var(--solid) * 0.92));
  border-block-end-color: rgb(43 60 85 / calc(var(--solid) * 0.1));
  box-shadow: 0 10px 28px rgb(60 46 30 / calc(var(--solid) * 0.1));
}
.theme-light .nav a { color: var(--ink); text-shadow: none; }
.theme-light .theme-switch__track { background: rgb(43 60 85 / 0.06); box-shadow: inset 0 0 0 1px rgb(43 60 85 / 0.3), inset 0 2px 5px rgb(60 46 30 / 0.12); }
.theme-light .theme-switch:hover .theme-switch__track { background: rgb(43 60 85 / 0.1); }

/* hero — background mirrors the light palette in hero-flow.js */
.theme-light .hero {
  color: var(--ink);
  background:
    radial-gradient(80% 60% at 78% 18%, rgb(255 252 246 / 0.7), transparent 70%),
    linear-gradient(165deg, #f8f3ea 0%, #f1e9db 55%, #f5efe4 100%);
}
.theme-light .hero::before {
  background: linear-gradient(90deg, rgb(248 243 234 / 0.55) 0%, rgb(248 243 234 / 0.3) 40%, rgb(248 243 234 / 0) 70%);
}
.theme-light .hero::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 26%;
  z-index: -1;
  pointer-events: none;
  background: linear-gradient(0deg, #f5efe4 0%, rgb(245 239 228 / 0.6) 40%, rgb(245 239 228 / 0) 100%);
}
.theme-light .hero h1 { color: var(--ink); }
.theme-light .hero-proof { color: var(--gold-700); }
.theme-light .hero .button--light { --btn-bg: var(--ink); --btn-fg: #f8f3ea; --btn-border: var(--ink); }
.theme-light .hero .button--light:hover { --btn-bg: #1f2e44; --btn-border: #1f2e44; }
.theme-light .motion-toggle { color: var(--ink); background: rgb(248 243 234 / 0.7); border-color: rgb(43 60 85 / 0.3); }
.theme-light .motion-toggle:hover { background: rgb(248 243 234 / 0.95); border-color: var(--ink); }

/* home sections: seamless cream transitions (each starts where the last ended) */
.theme-light .section--white {
  --card-bg: rgb(255 252 246 / 0.6);
  padding-block: calc(var(--section) + 2rem);
  background: linear-gradient(180deg, #f5efe4 0%, #ede4d4 14rem, #ebe1d0 55%, #ede4d4 calc(100% - 14rem), #f8f3ea 100%);
}
.theme-light .section--cream { background: linear-gradient(180deg, #f8f3ea 0%, #f8f3ea 60%, #f3ecdf 100%); }
.theme-light .section--mist { background: linear-gradient(180deg, #f3ecdf 0%, #f3ecdf 55%, #f8f3ea 100%); }
.theme-light .section--paper { background: linear-gradient(180deg, #f8f3ea 0%, #f3ecdf 100%); }
.theme-light .closer { color: var(--ink); background: linear-gradient(180deg, #f3ecdf 0%, #ede4d4 100%); }
.theme-light .closer h2 { color: var(--ink); }
.theme-light .closer-copy p:not(.eyebrow) { color: var(--muted); }
.theme-light .on-dark .eyebrow,
.theme-light .eyebrow { color: var(--gold-700); }

/* cards and panels */
.theme-light .card {
  background: var(--card-bg);
  border-color: var(--card-border);
}
.theme-light .card:hover { border-color: #cdb999; box-shadow: 0 18px 40px rgb(60 46 30 / 0.1); }
.theme-light .card p:not(.meta) { color: var(--muted); }
.theme-light .icon--gold { background: #f6e3bd; color: #7d5410; }
.theme-light .icon--clay { background: #f6d9cc; color: #96401f; }
.theme-light .icon--slate { background: #e2e5e9; color: #36404d; }
.theme-light .case-panel { background: var(--surface); border-color: var(--line); box-shadow: 0 18px 44px rgb(60 46 30 / 0.08); }
.theme-light .case-proof p { color: var(--muted); }
.theme-light .text-link { color: var(--ink); }
.theme-light .offer-note { border-block-start-color: var(--line); }
.theme-light .offer .section-intro,
.theme-light .offer-note p:first-child { color: var(--ink); }
.theme-light .offer-note p + p { color: var(--muted); }
.theme-light .art-panel--light { background: radial-gradient(70% 60% at 70% 30%, rgb(249 186 72 / 0.12), transparent 70%), var(--surface); border-color: var(--line); }
.theme-light .logo-row li {
  display: grid; place-items: center; min-width: 13rem; padding: 1rem 1.75rem;
  border-radius: var(--radius); background: var(--surface); box-shadow: 0 10px 26px rgb(60 46 30 / 0.08);
  transition: transform 0.3s var(--ease-out), box-shadow 0.3s ease;
}
.theme-light .logo-row li:hover { transform: translateY(-3px); }
.theme-light .logo-row img { height: 3.6rem; }

/* spotlight in light: a soft warm light */
.theme-light .card,
.theme-light .case-panel { --mx: 50%; --my: 0%; --spot: 0; isolation: isolate; }
.theme-light .card::after,
.theme-light .case-panel::after {
  content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit; pointer-events: none;
  opacity: var(--spot); transition: opacity 0.35s ease;
  background: radial-gradient(22rem circle at var(--mx) var(--my), rgb(249 186 72 / 0.12), transparent 60%);
}

/* inner pages */
.theme-light .page-intro { background: linear-gradient(180deg, #f8f3ea 0%, #f3ecdf 100%); }
.theme-light .feature-project,
.theme-light .aspects li { background: var(--surface); border-color: var(--line); box-shadow: 0 18px 44px rgb(60 46 30 / 0.06); }
.theme-light .also,
.theme-light .also article { border-color: var(--line); }
.theme-light .note-card { background: #2b3c55; }
.theme-light .roster .role { color: var(--gold-700); }

/* form */
.theme-light .form-card { background: var(--surface); border: 1px solid var(--line); color: var(--ink); box-shadow: 0 18px 44px rgb(60 46 30 / 0.08); --focus: var(--navy-800); }
.theme-light .field input,
.theme-light .field textarea { background: #fffdf8; color: var(--ink); border-color: var(--field-border); }
.theme-light .field .req { color: var(--muted); }

/* footer */
.theme-light .site-footer { background: #ebe1d0; color: var(--muted); }
.theme-light .footer-name,
.theme-light .site-footer a { color: var(--ink); }
.theme-light .site-footer a:hover { color: var(--gold-700); }
.theme-light .footer-label { color: var(--gold-700); }
.theme-light .footer-brand,
.theme-light .footer-base { border-color: rgb(43 60 85 / 0.14); }
.theme-light .footer-base { color: var(--muted); }

/* the theme change itself is smooth (instant for reduced motion via section 14) */
body { transition: background-color 0.4s ease, color 0.4s ease; }
.theme-light .note-card .eyebrow { color: var(--gold-400); } /* label on the dark team card */
.theme-light .note-card .note-lead { color: var(--ice); }
.header-cta { white-space: nowrap; }
@media (max-width: 760px) {
  .theme-switch { min-width: 2.75rem; }
  .theme-switch__track { width: 3.4rem; height: 1.8rem; padding: 0 0.4rem; }
  .theme-switch__thumb { width: 1.4rem; height: 1.4rem; }
  .theme-switch[aria-checked="true"] .theme-switch__thumb { transform: translateX(1.6rem); }
  .header-cta { padding-inline: 0.9rem; font-size: 0.9rem; }
}

/* Theme switch, quieter: smaller, no orange, low-contrast track; still a 44px target */
.theme-switch__track {
  width: 3rem;
  height: 1.5rem;
  padding: 0 0.32rem;
  background: transparent;
  box-shadow: inset 0 0 0 1px rgb(230 238 248 / 0.3);
  opacity: 0.8;
  transition: opacity 0.2s ease, box-shadow 0.2s ease;
}
.theme-switch__icon { width: 0.72rem; height: 0.72rem; opacity: 0.7; }
.theme-switch__thumb {
  inset-block-start: 0.18rem;
  inset-inline-start: 0.18rem;
  width: 1.14rem;
  height: 1.14rem;
  background: rgb(230 238 248 / 0.85);
  box-shadow: 0 1px 3px rgb(0 0 0 / 0.3);
}
.theme-switch[aria-checked="true"] .theme-switch__thumb { transform: translateX(1.5rem); }
.theme-switch:hover .theme-switch__track { background: transparent; opacity: 1; box-shadow: inset 0 0 0 1px rgb(230 238 248 / 0.55); }
.theme-light .theme-switch__track { background: transparent; box-shadow: inset 0 0 0 1px rgb(43 60 85 / 0.3); }
.theme-light .theme-switch__thumb { background: rgb(43 60 85 / 0.8); box-shadow: 0 1px 3px rgb(60 46 30 / 0.25); }
.theme-light .theme-switch:hover .theme-switch__track { background: transparent; box-shadow: inset 0 0 0 1px rgb(43 60 85 / 0.55); }
@media (max-width: 760px) {
  .theme-switch__track { width: 3rem; height: 1.5rem; padding: 0 0.32rem; }
  .theme-switch__thumb { width: 1.14rem; height: 1.14rem; }
  .theme-switch[aria-checked="true"] .theme-switch__thumb { transform: translateX(1.5rem); }
}

/* Theme switch pinned to the far upper-right of the window (desktop/tablet).
   The header row narrows by the switch's width on both sides, so nothing overlaps. */
@media (min-width: 761px) {
  .theme-switch {
    position: absolute;
    inset-block-start: 50%;
    inset-inline-end: clamp(0.5rem, 1.2vw, 1.25rem);
    transform: translateY(-50%);
    margin: 0;
  }
  .header-row { width: min(1240px, 100% - 2 * var(--gutter) - 6rem); }
}
