/* ==========================================================================
   Ironman Mentorship · styles
   Mobile-first. One accent colour. Dark hero + ink form section, warm paper elsewhere.
   ========================================================================== */

:root {
  /* Palette (all text pairings checked for WCAG AA) */
  --ink: #0D1321;
  --ink-2: #151D2E;
  --ink-3: #1F2A40;
  --paper: #F6F3EE;
  --paper-2: #ECE7DF;
  --white: #FFFFFF;
  --text: #141A26;
  --muted: #4A5262;            /* 7.1:1 on paper */
  --on-dark: #F6F3EE;
  --on-dark-muted: #A9B1C1;    /* 8.6:1 on ink */
  --accent: #FF5A1F;           /* the one accent: buoy orange (5.9:1 with ink text) */
  --accent-on-dark: #FF7A45;   /* accent for text on ink (7.2:1) */
  --accent-on-light: #B83A0B;  /* accent for text on paper/white (5.2:1+) */
  --error: #B42318;            /* 6.6:1 on white */
  --error-on-dark: #FF8A8A;
  --line: rgba(20, 26, 38, 0.14);
  --line-dark: rgba(246, 243, 238, 0.14);

  --focus: var(--accent-on-light);

  /* Type */
  --font: "Archivo", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --step--1: clamp(0.875rem, 0.85rem + 0.1vw, 0.9375rem);
  --step-0: clamp(1rem, 0.97rem + 0.15vw, 1.0625rem);
  --step-1: clamp(1.125rem, 1.07rem + 0.3vw, 1.3125rem);
  --step-2: clamp(1.375rem, 1.25rem + 0.6vw, 1.75rem);
  --step-3: clamp(1.875rem, 1.5rem + 1.8vw, 3rem);
  --step-4: clamp(3.5rem, 2.2rem + 7vw, 8.5rem);

  /* Space */
  --gutter: 1rem;
  --section-y: clamp(4rem, 3rem + 5vw, 7.5rem);
  --radius: 14px;
  --radius-sm: 10px;

  --ease: cubic-bezier(.2, .7, .2, 1);
}

/* ---------- Reset-ish ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 4.5rem; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: var(--step-0);
  line-height: 1.6;
  color: var(--text);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
[hidden] { display: none !important; }
img, svg { display: block; max-width: 100%; }
img { height: auto; }
h1, h2, h3, p, ul, ol, dl, dd, figure { margin: 0; }
ul[role="list"], ol[role="list"] { list-style: none; padding: 0; }
a { color: inherit; }
button, input, textarea, select { font: inherit; color: inherit; }
em { font-style: italic; }

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

.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: absolute; left: 1rem; top: -100px; z-index: 100;
  background: var(--accent); color: var(--ink);
  padding: .75rem 1rem; border-radius: var(--radius-sm);
  font-weight: 700; text-decoration: none;
}
.skip-link:focus { top: 1rem; }

.container {
  width: 100%;
  max-width: 1200px;
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* ---------- Buttons & links ---------- */
.btn {
  --btn-bg: var(--ink);
  --btn-fg: var(--on-dark);
  display: inline-flex; align-items: center; justify-content: center; gap: .6rem;
  min-height: 48px;
  padding: .8rem 1.4rem;
  border: 2px solid transparent;
  border-radius: 999px;
  background: var(--btn-bg);
  color: var(--btn-fg);
  font-weight: 700;
  font-size: var(--step-0);
  line-height: 1.1;
  text-decoration: none;
  cursor: pointer;
  transition: transform .2s var(--ease), background-color .2s var(--ease), box-shadow .2s var(--ease);
}
.btn svg { width: 1.15em; height: 1.15em; flex: none; }
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }
.btn-accent { --btn-bg: var(--accent); --btn-fg: var(--ink); }
.btn-accent:hover { --btn-bg: #FF6E3A; box-shadow: 0 10px 30px -10px rgba(255, 90, 31, .7); }
.btn-outline { --btn-bg: transparent; --btn-fg: var(--text); border-color: currentColor; }
.btn-outline:hover { --btn-bg: rgba(20, 26, 38, .06); }
.btn-sm { min-height: 40px; padding: .55rem 1rem; font-size: var(--step--1); white-space: nowrap; }
.btn-lg { min-height: 56px; padding: 1rem 1.75rem; font-size: var(--step-1); }
.btn-block { width: 100%; }

.text-link {
  background: none; border: 0; padding: .25rem 0; cursor: pointer;
  font-weight: 600;
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: .3em;
  text-decoration-color: var(--accent);
}
.text-link:hover { text-decoration-thickness: 3px; }
.text-link-dark { color: var(--on-dark); }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(13, 19, 33, .88);
  -webkit-backdrop-filter: saturate(140%) blur(12px);
  backdrop-filter: saturate(140%) blur(12px);
  border-bottom: 1px solid var(--line-dark);
  color: var(--on-dark);
  --focus: var(--accent-on-dark);
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  min-height: 64px;
}
.wordmark {
  display: inline-flex; align-items: center; gap: .55rem;
  text-decoration: none;
  font-weight: 500;
  letter-spacing: -.01em;
  white-space: nowrap;
}
.wordmark strong { font-weight: 800; }
.wordmark-mark { width: 28px; height: 28px; color: var(--accent); }
.site-nav { display: none; }
.site-nav ul { display: flex; gap: 1.75rem; list-style: none; margin: 0; padding: 0; }
.site-nav a {
  text-decoration: none; font-size: var(--step--1); font-weight: 600;
  color: var(--on-dark-muted);
  padding: .5rem 0;
  transition: color .2s;
}
.site-nav a:hover { color: var(--on-dark); }

/* ---------- Eyebrows & headings ---------- */
.eyebrow {
  display: inline-flex; align-items: center; gap: .6rem;
  font-size: var(--step--1);
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--accent-on-light);
  margin-bottom: 1rem;
}
.eyebrow::before {
  content: ""; width: 28px; height: 2px; background: currentColor;
}
.eyebrow-num { font-variant-numeric: tabular-nums; opacity: .9; }
.eyebrow-num + * { margin-left: 0; }
.eyebrow-dark { color: var(--accent-on-dark); }

.section-title {
  font-size: var(--step-3);
  font-weight: 800;
  font-stretch: 80%;
  line-height: 1.04;
  letter-spacing: -.02em;
  text-wrap: balance;
  max-width: 20ch;
}
.lede { font-size: var(--step-1); line-height: 1.55; color: var(--text); }
.lede-dark { color: var(--on-dark); }

/* ---------- Sections ---------- */
.section { padding-block: var(--section-y); }
.section-paper { background: var(--paper); }
.section-paper-2 { background: var(--paper-2); }
.section-ink {
  background: var(--ink);
  color: var(--on-dark);
  --focus: var(--accent-on-dark);
}
.section-head { margin-bottom: clamp(2.25rem, 1.5rem + 3vw, 4rem); }
.section-head .lede { margin-top: 1.25rem; max-width: 60ch; color: var(--muted); }

/* ---------- 1. Hero ---------- */
.hero {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(120% 80% at 100% 0%, rgba(255, 90, 31, .16), transparent 60%),
    linear-gradient(180deg, var(--ink) 0%, var(--ink-2) 100%);
  color: var(--on-dark);
  padding-block: clamp(3.5rem, 2rem + 8vw, 8rem) clamp(3rem, 2rem + 4vw, 5.5rem);
  --focus: var(--accent-on-dark);
}
.hero::before {
  /* faint lane lines: a nod to the pool, without a stock photo */
  content: "";
  position: absolute; inset: 0;
  background-image: repeating-linear-gradient(180deg, transparent 0 63px, rgba(246, 243, 238, .045) 63px 64px);
  -webkit-mask-image: linear-gradient(180deg, transparent, #000 30%, #000 70%, transparent);
  mask-image: linear-gradient(180deg, transparent, #000 30%, #000 70%, transparent);
  pointer-events: none;
}
.hero-glow {
  position: absolute; right: -20vmax; bottom: -30vmax;
  width: 60vmax; height: 60vmax; border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 90, 31, .18), transparent 65%);
  pointer-events: none;
}
.hero-inner { position: relative; }
.hero-title {
  font-weight: 900;
  line-height: .9;
  letter-spacing: -.035em;
  margin-bottom: 1.5rem;
}
.hero-num {
  display: block;
  font-size: var(--step-4);
  font-stretch: 72%;
  color: var(--accent);
}
.hero-line {
  display: block;
  font-size: clamp(2.25rem, 1.4rem + 4.6vw, 5.5rem);
  font-stretch: 78%;
  margin-top: .1em;
  text-wrap: balance;
}
.hero-lede {
  font-size: var(--step-1);
  color: var(--on-dark-muted);
  max-width: 34ch;
  line-height: 1.5;
}
.hero-actions {
  display: flex; flex-wrap: wrap; align-items: center; gap: 1rem 1.75rem;
  margin-top: 2rem;
}

/* course line */
.course { margin-top: clamp(2.5rem, 1.5rem + 4vw, 4rem); }
.course-svg { width: 100%; height: auto; overflow: visible; }
.course-svg path, .course-svg line {
  fill: none;
  stroke-linecap: round; stroke-linejoin: round;
  stroke-width: 6;
}
.course-swim { stroke: #7FB2FF; }
.course-bike { stroke: var(--accent); }
.course-run { stroke: var(--on-dark); stroke-dasharray: 2 16; stroke-width: 7 !important; }
.course-finish line { stroke: var(--on-dark); stroke-width: 4; }
.course-finish path { fill: var(--accent); stroke: none; }
.course-finish circle, .course-start { fill: var(--ink); stroke: var(--on-dark); stroke-width: 4; }

.distances {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: .75rem;
  margin-top: 1.25rem;
  border-top: 1px solid var(--line-dark);
  padding-top: 1.25rem;
}
.distance dt {
  font-size: .75rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase;
  color: var(--on-dark-muted);
}
.distance dd { font-size: var(--step-0); color: var(--on-dark-muted); }
.distance-num {
  font-size: var(--step-3); font-weight: 800; font-stretch: 75%;
  color: var(--on-dark); letter-spacing: -.02em;
}

/* ---------- 2. Challenge ---------- */
.split { display: grid; gap: 3rem; }
.split-main > p + p { margin-top: 1.1rem; }
.split-main .lede { margin-block: 1.5rem 1.25rem; }
.split-main p:not(.lede):not(.eyebrow) { color: var(--muted); max-width: 62ch; }
.split-main em { color: var(--text); font-weight: 600; font-style: normal; }

.ratio-card {
  background: var(--ink);
  color: var(--on-dark);
  border-radius: var(--radius);
  padding: 1.5rem;
}
.ratio-title { font-size: var(--step-2); font-weight: 800; font-stretch: 85%; line-height: 1.1; letter-spacing: -.01em; }
.ratio-copy { margin-top: .75rem; color: var(--on-dark-muted); }
.ratio-bar {
  display: flex; gap: 3px;
  height: 18px; margin-top: 1.5rem;
}
.ratio-seg { width: var(--w); border-radius: 3px; }
.ratio-swim { background: #7FB2FF; min-width: 5px; }
.ratio-bike { background: var(--accent); }
.ratio-run { background: var(--on-dark); }
.ratio-legend {
  display: flex; flex-wrap: wrap; gap: .5rem 1.25rem;
  list-style: none; padding: 0; margin-top: .9rem;
  font-size: var(--step--1); color: var(--on-dark-muted);
}
.ratio-legend li { display: inline-flex; align-items: center; gap: .45rem; }
.key { width: 10px; height: 10px; border-radius: 2px; }
.key-swim { background: #7FB2FF; }
.key-bike { background: var(--accent); }
.key-run { background: var(--on-dark); }

.truths { list-style: none; padding: 0; margin-top: 1.75rem; display: grid; gap: 1rem; }
.truths li {
  padding-left: 1.25rem;
  border-left: 3px solid var(--accent);
  color: var(--muted);
}
.truths strong { display: block; color: var(--text); }

.wide-photo { margin-top: clamp(3rem, 2rem + 4vw, 5rem); }
.wide-photo img, .mentor-photo img {
  width: 100%;
  border-radius: var(--radius);
  background: var(--paper-2);
}
.wide-photo img { aspect-ratio: 16 / 7; object-fit: cover; }

/* ---------- 3. A person in your corner (intro + feature photo) ---------- */
.corner { display: grid; gap: 0 4rem; }
.corner-photo { max-width: 420px; margin-bottom: clamp(2.25rem, 1.5rem + 3vw, 4rem); }
.corner-photo img {
  width: 100%;
  aspect-ratio: 4 / 5; object-fit: cover;
  border-radius: var(--radius);
  background: var(--paper);
}
.corner-photo figcaption {
  margin-top: .9rem;
  padding-left: 1rem;
  border-left: 3px solid var(--accent);
  font-size: var(--step--1);
  color: var(--muted);
  max-width: 44ch;
}

/* ---------- 3. Pillars ---------- */
.pillars {
  display: grid; gap: 1rem;
  counter-reset: pillar;
}
.pillar {
  position: relative;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.75rem 1.5rem 1.6rem;
  transition: transform .3s var(--ease), box-shadow .3s var(--ease);
}
.pillar:hover { transform: translateY(-4px); box-shadow: 0 18px 40px -24px rgba(13, 19, 33, .45); }
.pillar::after {
  counter-increment: pillar;
  content: "0" counter(pillar);
  position: absolute; top: 1.4rem; right: 1.5rem;
  font-weight: 800; font-size: var(--step--1); letter-spacing: .1em;
  color: var(--muted);
}
.pillar-icon {
  width: 48px; height: 48px; margin-bottom: 1.25rem;
  fill: none; stroke: var(--accent-on-light); stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round;
}
.pillar-icon .fill { fill: var(--accent); stroke: none; }
.pillar h3 { font-size: var(--step-2); font-weight: 800; font-stretch: 85%; letter-spacing: -.01em; line-height: 1.15; margin-bottom: .6rem; }
.pillar p { color: var(--muted); }

/* ---------- 4. Who it's for ---------- */
.who-grid { display: grid; gap: 1rem; }
.who-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.5rem;
}
.who-card p { color: var(--muted); margin-top: .9rem; }
.who-tag {
  display: inline-block;
  font-weight: 800; font-stretch: 85%;
  font-size: var(--step-2);
  line-height: 1.15;
  letter-spacing: -.01em;
}
.who-card-accent { background: var(--ink); color: var(--on-dark); border-color: var(--ink); }
.who-card-accent .who-tag { color: var(--accent-on-dark); }
.who-card-accent p { color: var(--on-dark-muted); }

.not-for {
  margin-top: 2.5rem;
  padding: 1.5rem;
  border: 2px dashed var(--line);
  border-radius: var(--radius);
  max-width: 760px;
}
.not-for h3 { font-size: var(--step-1); font-weight: 800; margin-bottom: .4rem; }
.not-for p { color: var(--muted); }

/* ---------- 5. Mentor ---------- */
.mentor { display: grid; gap: 2.5rem; align-items: center; }
.mentor-photo { max-width: 460px; }
.mentor-photo img { aspect-ratio: 4 / 5; object-fit: cover; }
.mentor-copy .lede { margin-block: 1.5rem 1rem; }
.mentor-copy > p + p { margin-top: 1rem; }
.mentor-copy p:not(.lede):not(.eyebrow) { color: var(--muted); }
.mentor-facts {
  display: grid; gap: .75rem;
  margin-top: 2rem; padding-top: 1.5rem;
  border-top: 1px solid var(--line);
}
.mentor-facts li { display: grid; gap: .15rem; }

/* Swim · Bike · Run strip under the mentor bio */
.disciplines {
  list-style: none; padding: 0;
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: .5rem;
  margin-top: clamp(3rem, 2rem + 4vw, 5rem);
}
.discipline img {
  width: 100%;
  aspect-ratio: 1; object-fit: cover;
  border-radius: var(--radius-sm);
  background: var(--paper);
}
.discipline figcaption {
  display: flex; align-items: center; gap: .45rem;
  margin-top: .6rem;
  font-size: .75rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase;
  color: var(--text);
}
.discipline .key-run { background: var(--ink); }
.fact-label {
  font-size: .75rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase;
  color: var(--accent-on-light);
}

/* Placeholder markers: deliberately obvious so nothing ships unreplaced */
.ph {
  background: rgba(255, 90, 31, .12);
  outline: 1.5px dashed var(--accent-on-light);
  outline-offset: 2px;
  border-radius: 3px;
  padding: 0 .2em;
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
}
.ph-inline { font-size: .8em; opacity: .75; }

/* ---------- 6. Steps ---------- */
.steps { display: grid; gap: 1rem; counter-reset: none; }
.step {
  position: relative;
  padding: 1.5rem;
  border: 1px solid var(--line-dark);
  border-radius: var(--radius);
  background: var(--ink-2);
}
.step-num {
  display: inline-grid; place-items: center;
  width: 44px; height: 44px; border-radius: 50%;
  background: var(--accent); color: var(--ink);
  font-weight: 900; font-size: 1.25rem;
  margin-bottom: 1.1rem;
}
.step h3 { font-size: var(--step-2); font-weight: 800; font-stretch: 85%; line-height: 1.15; margin-bottom: .5rem; }
.step p { color: var(--on-dark-muted); }

/* ---------- 7. Form ---------- */
.section-form { padding-top: 0; }
.form-layout { display: grid; gap: 2.5rem; }
.form-intro .lede { margin-top: 1.25rem; }
.reassure { display: grid; gap: .75rem; margin-top: 1.75rem; }
.reassure li {
  position: relative; padding-left: 1.9rem; color: var(--on-dark-muted);
}
.reassure li::before {
  content: ""; position: absolute; left: 0; top: .3em;
  width: 1.1rem; height: 1.1rem; border-radius: 50%;
  background: var(--accent)
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5.5 10.5l3 3 6-7' fill='none' stroke='%230D1321' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 80% no-repeat;
}

.form-card {
  background: var(--white);
  color: var(--text);
  border-radius: calc(var(--radius) + 6px);
  padding: 1.5rem 1.25rem;
  box-shadow: 0 30px 80px -30px rgba(0, 0, 0, .6);
  --focus: var(--accent-on-light);
}
.form { display: grid; gap: 1.5rem; }
.form-required-note { font-size: var(--step--1); color: var(--muted); }
.req { color: var(--accent-on-light); font-weight: 700; }
.optional { color: var(--muted); font-weight: 500; }

.field { border: 0; padding: 0; margin: 0; min-width: 0; }
.field > label, .field > legend {
  display: block;
  font-weight: 700;
  margin-bottom: .5rem;
  padding: 0;
  line-height: 1.35;
}
.hint { font-size: var(--step--1); color: var(--muted); margin: -.25rem 0 .5rem; }
.hint-right { text-align: right; margin: .35rem 0 0; }

input[type="text"], input[type="tel"], input[type="email"], textarea {
  width: 100%;
  min-height: 52px;
  padding: .8rem 1rem;
  font-size: 1rem; /* ≥16px stops iOS zooming */
  background: var(--paper);
  border: 2px solid #8E95A3; /* 3:1 against white for the field boundary */
  border-radius: var(--radius-sm);
  transition: border-color .15s, background-color .15s;
  -webkit-appearance: none;
  appearance: none;
}
textarea { resize: vertical; min-height: 120px; line-height: 1.5; }
input:hover, textarea:hover { border-color: var(--text); }
input:focus-visible, textarea:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 1px;
  border-color: var(--text);
  background: var(--white);
}
[aria-invalid="true"] { border-color: var(--error) !important; background: #FFF6F5; }

.error {
  display: flex; align-items: flex-start; gap: .4rem;
  margin-top: .5rem;
  color: var(--error);
  font-size: var(--step--1);
  font-weight: 600;
}
.error::before {
  content: "!";
  flex: none;
  display: inline-grid; place-items: center;
  width: 1.15rem; height: 1.15rem; margin-top: .1em;
  border-radius: 50%;
  background: var(--error); color: var(--white);
  font-size: .75rem; font-weight: 900;
}
.error[hidden] { display: none; }

/* Method toggle: large tappable tiles built on native radios */
.method-options { display: grid; grid-template-columns: 1fr 1fr; gap: .75rem; }
.method { position: relative; }
.method input, .chips input, .checkbox input {
  position: absolute; opacity: 0; width: 1px; height: 1px; margin: 0;
}
.method label {
  display: grid; gap: .25rem;
  height: 100%;
  padding: 1rem;
  border: 2px solid #8E95A3;
  border-radius: var(--radius);
  background: var(--paper);
  cursor: pointer;
  transition: border-color .15s, background-color .15s, box-shadow .15s;
}
.method label svg { width: 28px; height: 28px; margin-bottom: .35rem; color: var(--text); }
.method-name { font-weight: 800; font-size: var(--step-1); line-height: 1.2; }
.method-desc { font-size: .8125rem; line-height: 1.35; color: var(--muted); }
.method label:hover { border-color: var(--text); }
.method input:checked + label {
  border-color: var(--accent-on-light);
  background: #FFF1EA;
  box-shadow: inset 0 0 0 1px var(--accent-on-light);
}
.method input:checked + label svg { color: var(--accent-on-light); }
.method input:checked + label::after {
  content: "";
  position: absolute; top: .75rem; right: .75rem;
  width: 1.25rem; height: 1.25rem; border-radius: 50%;
  background: var(--accent-on-light)
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5.5 10.5l3 3 6-7' fill='none' stroke='white' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 80% no-repeat;
}
.method input:focus-visible + label,
.chips input:focus-visible + label,
.checkbox input:focus-visible + label::before {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
}
.field[data-invalid="true"] .method label { border-color: var(--error); }

/* Chips */
.chips { position: relative; display: flex; flex-wrap: wrap; gap: .5rem; }
.chips label {
  display: inline-flex; align-items: center;
  min-height: 44px;
  padding: .55rem 1rem;
  border: 2px solid #8E95A3;
  border-radius: 999px;
  background: var(--paper);
  font-weight: 600;
  font-size: var(--step--1);
  cursor: pointer;
  transition: border-color .15s, background-color .15s, color .15s;
}
.chips label:hover { border-color: var(--text); }
.chips input:checked + label {
  background: var(--ink); border-color: var(--ink); color: var(--on-dark);
}

/* Checkbox */
.checkbox { position: relative; }
.checkbox label {
  display: flex; align-items: flex-start; gap: .85rem;
  cursor: pointer; font-weight: 600; line-height: 1.4;
}
.checkbox label::before {
  content: "";
  flex: none;
  width: 26px; height: 26px;
  border: 2px solid #8E95A3;
  border-radius: 7px;
  background: var(--paper) center / 80% no-repeat;
  transition: background-color .15s, border-color .15s;
}
.checkbox label:hover::before { border-color: var(--text); }
.checkbox input:checked + label::before {
  background-color: var(--accent-on-light);
  border-color: var(--accent-on-light);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5 10.5l3.2 3.2L15 7' fill='none' stroke='white' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
}
.field[data-invalid="true"] .checkbox label::before { border-color: var(--error); }

.field.conditional { animation: field-in .35s var(--ease); }
@keyframes field-in { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: none; } }

.form-footnote { font-size: var(--step--1); color: var(--muted); text-align: center; margin-top: -.5rem; }

/* Confirmation state */
.confirmation { text-align: center; padding: 1rem 0 .5rem; }
.confirmation:focus { outline: none; }
.confirm-mark {
  width: 72px; height: 72px; margin: 0 auto 1.25rem;
  fill: none; stroke-linecap: round; stroke-linejoin: round;
}
.confirm-mark circle { stroke: var(--accent); stroke-width: 4; }
.confirm-mark path { stroke: var(--text); stroke-width: 5; stroke-dasharray: 40; stroke-dashoffset: 40; animation: tick .6s .2s var(--ease) forwards; }
@keyframes tick { to { stroke-dashoffset: 0; } }
.confirm-title { font-size: var(--step-3); font-weight: 900; font-stretch: 80%; line-height: 1.05; letter-spacing: -.02em; text-wrap: balance; }
.confirm-copy { margin: 1rem auto 0; max-width: 46ch; color: var(--muted); }
.confirm-actions {
  display: flex; flex-wrap: wrap; justify-content: center; gap: .75rem;
  margin-top: 1.75rem;
}
.copy-status { min-height: 1.6em; margin-top: .75rem; font-weight: 600; font-size: var(--step--1); color: var(--text); }
.message-preview {
  margin-top: 1rem; text-align: left;
  border: 1px solid var(--line); border-radius: var(--radius-sm);
  background: var(--paper);
}
.message-preview summary { cursor: pointer; padding: .85rem 1rem; font-weight: 700; }
.message-preview pre {
  margin: 0; padding: 0 1rem 1rem;
  white-space: pre-wrap; word-break: break-word;
  font-family: inherit; font-size: var(--step--1); color: var(--muted);
}
.confirm-direct { margin-top: 1.5rem; font-size: var(--step--1); color: var(--muted); }
.confirm-direct a { font-weight: 700; color: var(--text); }
.confirmation .text-link { margin-top: .75rem; }

/* ---------- 8. FAQ ---------- */
.faq { border-top: 1px solid var(--line); }
.faq-item { border-bottom: 1px solid var(--line); }
.faq-item summary {
  list-style: none;
  display: flex; justify-content: space-between; align-items: center; gap: 1rem;
  padding: 1.25rem 0;
  font-weight: 700;
  font-size: var(--step-1);
  line-height: 1.35;
  cursor: pointer;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: "";
  flex: none;
  width: 32px; height: 32px; border-radius: 50%;
  border: 2px solid var(--text);
  background:
    linear-gradient(var(--text), var(--text)) center / 12px 2px no-repeat,
    linear-gradient(var(--text), var(--text)) center / 2px 12px no-repeat;
  transition: transform .3s var(--ease), background-color .2s;
}
.faq-item[open] summary::after {
  transform: rotate(45deg);
  background-color: var(--accent);
  border-color: var(--accent);
}
.faq-item summary:hover { color: var(--accent-on-light); }
.faq-body { padding: 0 0 1.5rem; max-width: 64ch; color: var(--muted); }

/* ---------- 9. Footer ---------- */
.site-footer {
  background: var(--ink);
  color: var(--on-dark-muted);
  padding-block: 4rem 2rem;
  --focus: var(--accent-on-dark);
}
.footer-inner { display: grid; gap: 2.5rem; }
.footer-title { color: var(--on-dark); font-weight: 900; font-stretch: 80%; font-size: var(--step-2); letter-spacing: -.01em; }
.footer-tag { margin: .5rem 0 1.25rem; max-width: 32ch; }
.footer-heading {
  font-size: .75rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase;
  color: var(--on-dark); margin-bottom: 1rem;
}
.footer-col ul { display: grid; gap: .6rem; }
.footer-col a { text-decoration: none; color: var(--on-dark); font-weight: 600; word-break: break-word; }
.footer-col a:hover { text-decoration: underline; text-decoration-color: var(--accent); text-underline-offset: .25em; }
.footer-privacy p { font-size: var(--step--1); max-width: 48ch; }
.footer-base { margin-top: 3rem; font-size: .8125rem; }
.footer-base p { padding-top: 1.5rem; border-top: 1px solid var(--line-dark); }

/* ---------- Scroll reveal (only when JS is on AND motion is welcome) ---------- */
@media (prefers-reduced-motion: no-preference) {
  .js .reveal {
    opacity: 0;
    transform: translateY(22px);
    transition: opacity .7s var(--ease), transform .7s var(--ease);
  }
  .js .reveal.is-visible { opacity: 1; transform: none; }

  .js .course-svg {
    clip-path: inset(0 100% 0 0);
    animation: draw-course 2.2s .3s var(--ease) forwards;
  }
  @keyframes draw-course { to { clip-path: inset(0 0 0 0); } }

  .js .hero-title, .js .hero-lede, .js .hero-actions, .js .hero .eyebrow {
    animation: rise .8s var(--ease) both;
  }
  .js .hero-title { animation-delay: .08s; }
  .js .hero-lede { animation-delay: .18s; }
  .js .hero-actions { animation-delay: .28s; }
  @keyframes rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
  .btn:hover, .pillar:hover { transform: none; }
  .confirm-mark path { stroke-dashoffset: 0; }
}

/* ==========================================================================
   Breakpoints (mobile-first)
   ========================================================================== */
@media (max-width: 389px) {
  .wordmark { font-size: .9375rem; gap: .4rem; }
  .wordmark-mark { width: 24px; height: 24px; }
  .header-inner .btn-sm { padding-inline: .85rem; }
}

@media (min-width: 480px) {
  .form-card { padding: 2rem 1.75rem; }
  .method-desc { font-size: var(--step--1); }
}

@media (min-width: 720px) {
  :root { --gutter: 2rem; }
  .pillars { grid-template-columns: repeat(2, 1fr); gap: 1.25rem; }
  .who-grid { grid-template-columns: repeat(2, 1fr); gap: 1.25rem; }
  .steps { grid-template-columns: repeat(3, 1fr); gap: 1.25rem; }
  .mentor { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 4rem; }
  .corner { grid-template-columns: minmax(0, 1fr) 380px; align-items: center; }
  .corner .section-head, .corner-photo { margin-bottom: clamp(2.5rem, 1.5rem + 3vw, 4rem); }
  .disciplines { gap: 1.25rem; }
  .discipline img { border-radius: var(--radius); }
  .footer-inner { grid-template-columns: repeat(2, 1fr); }
  .footer-brand { grid-column: 1 / -1; }
  .distances { gap: 2rem; }
  .ratio-card { padding: 2rem; }
  .who-card { padding: 2rem; }
  .pillar { padding: 2.25rem 2rem 2rem; }
}

@media (min-width: 1024px) {
  :root { --gutter: 2.5rem; }
  .site-nav { display: block; }
  .split { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 5rem; align-items: start; }
  .split-side { position: sticky; top: 6rem; }
  .corner { grid-template-columns: minmax(0, 1fr) 420px; }
  .pillars { grid-template-columns: repeat(4, 1fr); }
  .pillars .pillar:nth-child(even) { margin-top: 2.5rem; }
  .who-grid { grid-template-columns: repeat(4, 1fr); }
  .form-layout { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 5rem; align-items: start; }
  .form-intro { position: sticky; top: 7rem; }
  .form-card { padding: 2.75rem; }
  .faq-layout { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 5rem; align-items: start; }
  .faq-layout .section-head { margin-bottom: 0; position: sticky; top: 7rem; }
  .footer-inner { grid-template-columns: 1.2fr 1fr 1.4fr; gap: 4rem; }
  .footer-brand { grid-column: auto; }
}
