/* ChapterDues design system. Chapter formal: ivory ground, soft slate, heritage burgundy.
   Light only. Contrast comes from type scale, ruled lines, engraved borders and tints. */

:root {
  --bg: #FAF9F7;
  --surface: #FFFFFF;
  --ink: #1E1D21;
  --primary: #6B2C3E;
  --accent: #C3B097;
  --muted: #63616A;

  --primary-tint-04: #F6EFF1;
  --primary-tint-08: #F0E4E8;
  --primary-tint-16: #E2CBD3;
  --primary-deep: #55222F;
  --accent-tint: #F4EEE5;
  --accent-line: #E3D6C4;
  --rule: #E4E1DC;
  --rule-strong: #CFCAC2;
  --ivory: #F3F0EA;
  --slate-soft: #EDEDF0;

  --ff-display: "Trirong", "Playfair Display", Georgia, "Times New Roman", serif;
  --ff-body: "Roboto", "Helvetica Neue", Arial, system-ui, sans-serif;

  --fs-xs: 0.78rem;
  --fs-sm: 0.875rem;
  --fs-base: 1rem;
  --fs-md: 1.0625rem;
  --fs-lg: 1.25rem;
  --fs-xl: 1.5rem;
  --fs-2xl: 1.9rem;
  --fs-3xl: 2.4rem;
  --fs-4xl: 3.1rem;
  --fs-5xl: 3.75rem;

  --sp-1: 4px;
  --sp-2: 8px;
  --sp-3: 12px;
  --sp-4: 16px;
  --sp-5: 24px;
  --sp-6: 32px;
  --sp-7: 48px;
  --sp-8: 64px;
  --sp-9: 88px;
  --sp-10: 120px;

  --r-sm: 2px;
  --r-md: 4px;
  --r-lg: 8px;

  --shadow-card: 0 1px 2px rgba(30, 29, 33, 0.05), 0 12px 28px rgba(30, 29, 33, 0.06);
  --shadow-lift: 0 2px 4px rgba(30, 29, 33, 0.06), 0 22px 44px rgba(30, 29, 33, 0.09);
  --maxw: 1200px;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background-color: var(--bg);
  background-image:
    repeating-linear-gradient(0deg, rgba(107, 44, 62, 0.028) 0 1px, rgba(255, 255, 255, 0) 1px 34px),
    radial-gradient(circle at 12% 0%, rgba(195, 176, 151, 0.16), rgba(255, 255, 255, 0) 42%);
  color: var(--ink);
  font-family: var(--ff-body);
  font-size: var(--fs-md);
  line-height: 1.68;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  font-family: var(--ff-display);
  font-weight: 600;
  line-height: 1.16;
  letter-spacing: -0.006em;
  margin: 0 0 var(--sp-4);
  color: var(--ink);
}

h1 { font-size: clamp(2.25rem, 1.2rem + 3.6vw, var(--fs-5xl)); font-weight: 700; }
h2 { font-size: clamp(1.7rem, 1.1rem + 2vw, var(--fs-3xl)); }
h3 { font-size: var(--fs-lg); }
p { margin: 0 0 var(--sp-4); }
a { color: var(--primary); text-underline-offset: 3px; }
a:hover { color: var(--primary-deep); }
img { max-width: 100%; height: auto; display: block; }
ul, ol { margin: 0 0 var(--sp-4); padding-left: 1.15rem; }
li { margin-bottom: var(--sp-2); }
strong { font-weight: 700; }
hr { border: 0; border-top: 1px solid var(--rule); margin: var(--sp-7) 0; }

::selection { background: var(--primary-tint-16); color: var(--ink); }

.wrap { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 var(--sp-5); }
.narrow { max-width: 800px; }

.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: var(--sp-4); top: -60px; z-index: 200;
  background: var(--primary); color: #FFFFFF; padding: 10px 18px;
  border-radius: var(--r-md); font-weight: 700; text-decoration: none;
  transition: top 0.18s ease;
}
.skip-link:focus { top: var(--sp-3); color: #FFFFFF; }

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

/* ---------- engraved crest rule motif ---------- */
.crest-rule {
  display: flex; align-items: center; gap: var(--sp-3);
  margin: 0 0 var(--sp-5); color: var(--primary);
}
.crest-rule::before, .crest-rule::after {
  content: ""; height: 1px; flex: 1 1 auto;
  background: linear-gradient(90deg, rgba(195, 176, 151, 0), var(--accent-line), rgba(195, 176, 151, 0));
}
.crest-rule span {
  font-family: var(--ff-body); font-size: var(--fs-xs); font-weight: 700;
  letter-spacing: 0.22em; text-transform: uppercase; white-space: nowrap;
}
.eyebrow {
  font-size: var(--fs-xs); font-weight: 700; letter-spacing: 0.2em;
  text-transform: uppercase; color: var(--primary); margin: 0 0 var(--sp-3);
  display: inline-flex; align-items: center; gap: var(--sp-2);
}
.eyebrow::before {
  content: ""; width: 26px; height: 2px; background: var(--accent);
  display: inline-block;
}

/* the slow rule draw */
.draw-rule {
  height: 2px; border: 0; background: var(--primary);
  width: 0; max-width: 96px; margin: 0 0 var(--sp-5);
  transition: width 1.5s cubic-bezier(0.19, 1, 0.22, 1);
}
.is-visible .draw-rule, .draw-rule.is-visible { width: 96px; }

/* ---------- header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(250, 249, 247, 0.94);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--rule);
  transition: box-shadow 0.25s ease, border-color 0.25s ease;
}
.site-header.is-scrolled {
  box-shadow: 0 1px 0 var(--accent-line), 0 10px 26px rgba(30, 29, 33, 0.06);
  border-bottom-color: var(--accent-line);
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  gap: var(--sp-5); min-height: 74px;
}
.wordmark {
  display: inline-flex; align-items: center; gap: 10px;
  text-decoration: none; color: var(--ink); font-family: var(--ff-display);
  font-size: 1.3rem; font-weight: 700; letter-spacing: -0.01em;
}
.wordmark svg { flex: none; }
.wordmark em { font-style: normal; color: var(--primary); }

.nav-list {
  display: flex; align-items: center; gap: var(--sp-5);
  list-style: none; margin: 0; padding: 0;
}
.nav-list a {
  text-decoration: none; color: var(--ink); font-size: var(--fs-sm);
  font-weight: 500; letter-spacing: 0.02em; padding: 6px 0;
  border-bottom: 2px solid transparent;
}
.nav-list a:hover { border-bottom-color: var(--accent); color: var(--primary); }
.header-cta { display: flex; align-items: center; gap: var(--sp-3); }

.nav-toggle {
  display: none; align-items: center; gap: 8px;
  background: var(--surface); border: 1px solid var(--rule-strong);
  border-radius: var(--r-md); padding: 9px 12px; color: var(--ink);
  font: inherit; font-size: var(--fs-sm); font-weight: 600; cursor: pointer;
}

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-family: var(--ff-body); font-size: var(--fs-sm); font-weight: 700;
  letter-spacing: 0.04em; text-transform: uppercase;
  padding: 13px 22px; border-radius: var(--r-md); text-decoration: none;
  border: 1px solid transparent; cursor: pointer;
  transition: transform 0.16s ease, background 0.18s ease, box-shadow 0.18s ease, color 0.18s ease;
}
.btn-primary { background: var(--primary); color: #FFFFFF; box-shadow: inset 0 -2px 0 rgba(85, 34, 47, 0.55); }
.btn-primary:hover { background: var(--primary-deep); color: #FFFFFF; transform: translateY(-1px); }
.btn-outline {
  background: var(--surface); color: var(--primary); border-color: var(--primary-tint-16);
}
.btn-outline:hover { background: var(--primary-tint-04); border-color: var(--primary); color: var(--primary-deep); }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--rule-strong); }
.btn-ghost:hover { border-color: var(--primary); color: var(--primary); }
.btn-sm { padding: 10px 16px; font-size: var(--fs-xs); }
.btn-block { width: 100%; }

/* ---------- sections ---------- */
.section { padding: var(--sp-9) 0; border-top: 1px solid var(--rule); }
.section-ivory { background: var(--ivory); }
.section-tint { background: var(--primary-tint-04); }
.section-head { max-width: 760px; margin-bottom: var(--sp-7); }
.section-head p { color: var(--muted); font-size: var(--fs-lg); margin-bottom: 0; }

/* ---------- hero ---------- */
.hero { padding: var(--sp-8) 0 var(--sp-9); position: relative; overflow: hidden; }
.hero::before {
  content: ""; position: absolute; inset: 0;
  background-image: repeating-linear-gradient(90deg, rgba(195, 176, 151, 0.22) 0 1px, rgba(255, 255, 255, 0) 1px 96px);
  pointer-events: none;
}
.hero-grid {
  position: relative; display: grid; gap: var(--sp-8);
  grid-template-columns: 1.05fr 0.95fr; align-items: center;
}
.hero h1 { margin-bottom: var(--sp-5); }
.hero-lede { font-size: var(--fs-lg); color: var(--muted); max-width: 34em; }
.hero-actions { display: flex; flex-wrap: wrap; gap: var(--sp-3); margin: var(--sp-6) 0 var(--sp-7); }
.trust-strip {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr));
  border-top: 1px solid var(--accent-line); border-bottom: 1px solid var(--accent-line);
}
.trust-strip div { padding: var(--sp-4) var(--sp-4) var(--sp-4) 0; }
.trust-strip div + div { border-left: 1px solid var(--rule); padding-left: var(--sp-4); }
.trust-strip b { display: block; font-family: var(--ff-display); font-size: var(--fs-xl); color: var(--primary); }
.trust-strip span { font-size: var(--fs-sm); color: var(--muted); }

.hero-figure { position: relative; }
.hero-figure img {
  width: 100%; border-radius: var(--r-lg);
  border: 1px solid var(--accent-line);
  box-shadow: var(--shadow-lift);
}
.hero-figure::after {
  content: ""; position: absolute; left: -14px; top: -14px; right: 22px; bottom: 22px;
  border: 1px solid var(--accent); border-radius: var(--r-lg); z-index: -1;
}
.hero-seal {
  position: absolute; right: -10px; bottom: -22px;
  background: var(--surface); border: 1px solid var(--accent-line);
  border-radius: 50%; width: 118px; height: 118px;
  display: grid; place-content: center; text-align: center;
  box-shadow: var(--shadow-card);
}
.hero-seal b { font-family: var(--ff-display); font-size: 1.5rem; color: var(--primary); display: block; line-height: 1; }
.hero-seal span { font-size: 0.66rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); }

/* ---------- cards ---------- */
.grid { display: grid; gap: var(--sp-5); }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

.card {
  background: var(--surface); border: 1px solid var(--rule);
  border-top: 3px solid var(--primary-tint-16);
  border-radius: var(--r-md); padding: var(--sp-6);
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}
.card:hover { border-top-color: var(--primary); box-shadow: var(--shadow-card); transform: translateY(-2px); }
.card h3 { margin-bottom: var(--sp-3); }
.card p { color: var(--muted); margin-bottom: 0; font-size: var(--fs-base); }
.cost {
  display: inline-block; margin-top: var(--sp-4); padding: 5px 10px;
  background: var(--primary-tint-08); color: var(--primary-deep);
  border-radius: var(--r-sm); font-size: var(--fs-xs); font-weight: 700;
  letter-spacing: 0.06em; text-transform: uppercase;
}

.icon-badge {
  width: 46px; height: 46px; border: 1px solid var(--accent-line);
  border-radius: 50%; display: grid; place-content: center;
  background: var(--accent-tint); margin-bottom: var(--sp-4); color: var(--primary);
}
.icon-badge svg { stroke: currentColor; fill: none; stroke-width: 1.4; }

/* ---------- steps ---------- */
.steps-layout { display: grid; grid-template-columns: 1fr 1fr; gap: var(--sp-8); align-items: start; }
.step { display: grid; grid-template-columns: 58px 1fr; gap: var(--sp-4); padding: var(--sp-5) 0; border-bottom: 1px solid var(--rule); }
.step:first-child { border-top: 1px solid var(--rule); }
.step-num {
  font-family: var(--ff-display); font-size: var(--fs-2xl); color: var(--primary);
  line-height: 1; border-right: 1px solid var(--accent-line); padding-right: var(--sp-4);
}
.step h3 { margin-bottom: 6px; }
.step p { color: var(--muted); margin: 0; font-size: var(--fs-base); }
.section-figure img { border-radius: var(--r-lg); border: 1px solid var(--accent-line); box-shadow: var(--shadow-card); }
.section-figure figcaption { font-size: var(--fs-sm); color: var(--muted); margin-top: var(--sp-3); border-left: 2px solid var(--accent); padding-left: var(--sp-3); }

/* ---------- roster table motif ---------- */
.roster {
  width: 100%; border-collapse: collapse; background: var(--surface);
  border: 1px solid var(--rule-strong); font-size: var(--fs-sm);
}
.roster caption {
  text-align: left; font-family: var(--ff-display); font-size: var(--fs-lg);
  padding-bottom: var(--sp-3); color: var(--ink);
}
.roster th, .roster td { padding: 11px 14px; border-bottom: 1px solid var(--rule); text-align: left; }
.roster thead th {
  background: var(--accent-tint); font-size: var(--fs-xs); letter-spacing: 0.14em;
  text-transform: uppercase; color: var(--primary-deep); border-bottom: 1px solid var(--accent-line);
}
.roster tbody tr { opacity: 0; transform: translateY(6px); }
.is-visible .roster tbody tr { animation: roster-fill 0.55s ease forwards; }
.is-visible .roster tbody tr:nth-child(1) { animation-delay: 0.05s; }
.is-visible .roster tbody tr:nth-child(2) { animation-delay: 0.20s; }
.is-visible .roster tbody tr:nth-child(3) { animation-delay: 0.35s; }
.is-visible .roster tbody tr:nth-child(4) { animation-delay: 0.50s; }
.is-visible .roster tbody tr:nth-child(5) { animation-delay: 0.65s; }
.roster tbody tr:nth-child(even) { background: var(--bg); }
@keyframes roster-fill { to { opacity: 1; transform: none; } }
.pill {
  display: inline-block; padding: 2px 9px; border-radius: 999px;
  font-size: 0.72rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase;
  border: 1px solid var(--accent-line); background: var(--accent-tint); color: var(--primary-deep);
}
.pill-open { background: var(--primary-tint-08); border-color: var(--primary-tint-16); }

/* ---------- outcomes ---------- */
.outcome {
  background: var(--surface); border: 1px solid var(--rule); border-radius: var(--r-md);
  padding: var(--sp-6); position: relative; overflow: hidden;
}
.outcome::before {
  content: ""; position: absolute; top: 0; left: 0; width: 100%; height: 4px;
  background: linear-gradient(90deg, var(--primary), var(--accent));
}
.outcome b {
  display: block; font-family: var(--ff-display); font-weight: 700;
  font-size: clamp(2.2rem, 1.4rem + 2.2vw, 3rem); color: var(--primary); line-height: 1;
  margin-bottom: var(--sp-3);
}
.outcome h3 { font-size: var(--fs-base); text-transform: uppercase; letter-spacing: 0.12em; font-family: var(--ff-body); font-weight: 700; }
.outcome p { color: var(--muted); font-size: var(--fs-base); margin: 0; }

/* ---------- testimonials ---------- */
.testimonial {
  background: var(--surface); border: 1px solid var(--rule); border-radius: var(--r-md);
  padding: var(--sp-6); margin: 0; position: relative;
}
.testimonial::before {
  content: ""; display: block; width: 34px; height: 1px; background: var(--accent); margin-bottom: var(--sp-4);
}
.testimonial p { font-size: var(--fs-md); margin-bottom: var(--sp-5); }
.testimonial footer { border-top: 1px solid var(--rule); padding-top: var(--sp-4); font-size: var(--fs-sm); }
.testimonial cite { font-style: normal; font-weight: 700; display: block; color: var(--ink); }
.testimonial span { color: var(--muted); }
.results-strip {
  margin-top: var(--sp-7); display: grid; grid-template-columns: repeat(3, minmax(0, 1fr));
  border: 1px solid var(--accent-line); background: var(--surface);
}
.results-strip div { padding: var(--sp-5); text-align: center; }
.results-strip div + div { border-left: 1px solid var(--rule); }
.results-strip b { display: block; font-family: var(--ff-display); font-size: var(--fs-2xl); color: var(--primary); }
.results-strip span { font-size: var(--fs-sm); color: var(--muted); }

/* ---------- pricing ---------- */
.price-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--sp-5); align-items: start; }
.tier {
  background: var(--surface); border: 1px solid var(--rule-strong); border-radius: var(--r-md);
  padding: var(--sp-6); display: flex; flex-direction: column; height: 100%;
}
.tier-featured {
  border: 2px solid var(--primary); box-shadow: var(--shadow-lift);
  background: linear-gradient(180deg, var(--primary-tint-04), var(--surface) 190px);
}
.tier-flag {
  display: inline-block; background: var(--primary); color: #FFFFFF;
  font-size: var(--fs-xs); font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase;
  padding: 5px 12px; border-radius: var(--r-sm); margin-bottom: var(--sp-4);
}
.tier h3 { font-size: var(--fs-xl); margin-bottom: var(--sp-2); }
.tier .amount { font-family: var(--ff-display); font-size: 2.8rem; font-weight: 700; color: var(--ink); line-height: 1; }
.tier .per { color: var(--muted); font-size: var(--fs-sm); }
.tier .fit { color: var(--muted); font-size: var(--fs-sm); border-bottom: 1px solid var(--rule); padding-bottom: var(--sp-4); margin: var(--sp-4) 0; }
.tier ul { list-style: none; padding: 0; margin: 0 0 var(--sp-6); font-size: var(--fs-sm); }
.tier li { padding-left: 26px; position: relative; color: var(--ink); }
.tier li::before {
  content: ""; position: absolute; left: 0; top: 8px; width: 13px; height: 7px;
  border-left: 2px solid var(--primary); border-bottom: 2px solid var(--primary);
  transform: rotate(-45deg);
}
.tier .btn { margin-top: auto; }
.billing-note {
  margin-top: var(--sp-6); text-align: center; color: var(--muted); font-size: var(--fs-sm);
  border-top: 1px solid var(--rule); padding-top: var(--sp-5);
}

/* ---------- faq ---------- */
.faq-list { border-top: 1px solid var(--rule-strong); max-width: 880px; }
.faq-item { border-bottom: 1px solid var(--rule); }
.faq-q {
  width: 100%; display: flex; gap: var(--sp-4); align-items: flex-start; justify-content: space-between;
  background: none; border: 0; padding: var(--sp-5) 0; text-align: left; cursor: pointer;
  font-family: var(--ff-display); font-size: var(--fs-lg); font-weight: 600; color: var(--ink);
}
.faq-q:hover { color: var(--primary); }
.faq-q .mark { flex: none; width: 22px; height: 22px; position: relative; margin-top: 6px; }
.faq-q .mark::before, .faq-q .mark::after {
  content: ""; position: absolute; background: var(--primary); transition: transform 0.25s ease;
}
.faq-q .mark::before { top: 10px; left: 0; width: 22px; height: 2px; }
.faq-q .mark::after { left: 10px; top: 0; width: 2px; height: 22px; }
.faq-q[aria-expanded="true"] .mark::after { transform: scaleY(0); }
.faq-a { padding: 0 0 var(--sp-5); max-width: 68ch; color: var(--muted); }
.faq-a p:last-child { margin-bottom: 0; }

/* ---------- contact ---------- */
.contact-layout { display: grid; grid-template-columns: 0.85fr 1.15fr; gap: var(--sp-8); align-items: start; }
.form-card {
  background: var(--surface); border: 1px solid var(--rule-strong); border-radius: var(--r-md);
  padding: var(--sp-7); box-shadow: var(--shadow-card);
}
.field { margin-bottom: var(--sp-5); }
.field label { display: block; font-size: var(--fs-sm); font-weight: 700; margin-bottom: 6px; }
.field .hint { display: block; font-weight: 400; color: var(--muted); font-size: var(--fs-xs); margin-top: 2px; }
input[type="text"], input[type="email"], select, textarea {
  width: 100%; font: inherit; font-size: var(--fs-base); color: var(--ink);
  background: var(--bg); border: 1px solid var(--rule-strong); border-radius: var(--r-sm);
  padding: 11px 13px;
}
input:focus, select:focus, textarea:focus { border-color: var(--primary); background: var(--surface); }
textarea { min-height: 132px; resize: vertical; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: var(--sp-4); }
.consent { display: flex; gap: var(--sp-3); align-items: flex-start; font-size: var(--fs-sm); }
.consent input { margin-top: 5px; }
.error-msg { display: none; color: var(--primary-deep); font-size: var(--fs-sm); font-weight: 700; margin-top: 5px; }
[aria-invalid="true"] { border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-tint-08); }
[aria-invalid="true"] + .error-msg, .error-msg.is-shown { display: block; }
.form-foot { margin-top: var(--sp-5); font-size: var(--fs-sm); color: var(--muted); }
.contact-aside ul { list-style: none; padding: 0; }
.contact-aside li { border-bottom: 1px solid var(--rule); padding: var(--sp-4) 0; font-size: var(--fs-base); }

/* ---------- footer ---------- */
.site-footer {
  background: var(--ivory); border-top: 3px solid var(--primary);
  padding: var(--sp-9) 0 var(--sp-5); margin-top: var(--sp-4);
}
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: var(--sp-7); }
.footer-col h2 { font-family: var(--ff-body); font-size: var(--fs-xs); letter-spacing: 0.18em; text-transform: uppercase; color: var(--primary-deep); margin-bottom: var(--sp-4); }
.footer-col ul { list-style: none; padding: 0; margin: 0; }
.footer-col li { margin-bottom: 10px; }
.footer-col a { color: var(--ink); text-decoration: none; font-size: var(--fs-sm); border-bottom: 1px solid transparent; }
.footer-col a:hover { color: var(--primary); border-bottom-color: var(--accent); }
.footer-note { color: var(--muted); font-size: var(--fs-sm); max-width: 32ch; }
.social { display: flex; gap: var(--sp-3); margin-top: var(--sp-4); }
.social a {
  width: 38px; height: 38px; border: 1px solid var(--accent-line); border-radius: 50%;
  display: grid; place-content: center; color: var(--primary); background: var(--surface);
}
.social a:hover { background: var(--primary-tint-08); border-color: var(--primary); }
.social svg { stroke: currentColor; fill: none; stroke-width: 1.5; }
.footer-base {
  margin-top: var(--sp-8); border-top: 1px solid var(--rule-strong); padding-top: var(--sp-5);
  display: flex; flex-wrap: wrap; gap: var(--sp-3); justify-content: space-between;
  font-size: var(--fs-sm); color: var(--muted);
}
.byline {
  margin-top: var(--sp-8); border-top: 1px solid var(--rule); padding-top: var(--sp-5);
  font-size: var(--fs-sm); color: var(--muted);
}

/* ---------- prose pages ---------- */
.page-head { padding: var(--sp-8) 0 var(--sp-6); border-bottom: 1px solid var(--rule); }
.prose { padding: var(--sp-8) 0 var(--sp-9); }
.prose h2 { font-size: var(--fs-xl); margin-top: var(--sp-7); }
.prose h3 { font-size: var(--fs-lg); margin-top: var(--sp-6); }
.prose dl { margin: 0 0 var(--sp-5); }
.prose dt { font-weight: 700; margin-top: var(--sp-3); }
.prose dd { margin: 0 0 var(--sp-2); color: var(--muted); }
.fact-table { width: 100%; border-collapse: collapse; margin-bottom: var(--sp-6); }
.fact-table th, .fact-table td { border: 1px solid var(--rule); padding: 10px 13px; text-align: left; font-size: var(--fs-sm); vertical-align: top; }
.fact-table th { background: var(--accent-tint); width: 34%; }
.author-layout { display: grid; grid-template-columns: 300px 1fr; gap: var(--sp-8); align-items: start; }
.author-portrait img { border-radius: var(--r-md); border: 1px solid var(--accent-line); box-shadow: var(--shadow-card); }
.map-group { border: 1px solid var(--rule); background: var(--surface); border-radius: var(--r-md); padding: var(--sp-6); }
.map-group li { margin-bottom: var(--sp-3); }
.big-code { font-family: var(--ff-display); font-size: 4rem; color: var(--primary); line-height: 1; }

/* ---------- reveal ---------- */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity 0.7s ease, transform 0.7s cubic-bezier(0.19, 1, 0.22, 1); }
.reveal.is-visible { opacity: 1; transform: none; }

/* ---------- responsive ---------- */
@media (max-width: 1020px) {
  .hero-grid, .steps-layout, .contact-layout { grid-template-columns: 1fr; }
  .grid-3, .grid-4, .price-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .author-layout { grid-template-columns: 1fr; }
}
@media (max-width: 860px) {
  .nav-toggle { display: inline-flex; }
  .primary-nav {
    display: none; position: absolute; left: 0; right: 0; top: 100%;
    background: var(--surface); border-bottom: 1px solid var(--rule-strong);
    padding: var(--sp-5); box-shadow: var(--shadow-card);
  }
  .primary-nav.is-open { display: block; }
  .nav-list { flex-direction: column; align-items: flex-start; gap: var(--sp-4); }
  .header-cta .btn { display: none; }
  .site-header { position: sticky; }
  .header-inner { position: relative; }
}
@media (max-width: 680px) {
  .section { padding: var(--sp-8) 0; }
  .grid-3, .grid-4, .price-grid, .grid-2 { grid-template-columns: 1fr; }
  .trust-strip, .results-strip { grid-template-columns: 1fr; }
  .trust-strip div + div { border-left: 0; border-top: 1px solid var(--rule); padding-left: 0; }
  .results-strip div + div { border-left: 0; border-top: 1px solid var(--rule); }
  .footer-grid { grid-template-columns: 1fr; }
  .form-card { padding: var(--sp-5); }
  .field-row { grid-template-columns: 1fr; }
  .hero-seal { display: none; }
  .roster { font-size: 0.8rem; }
  .roster th, .roster td { padding: 8px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
  .reveal { opacity: 1; transform: none; }
  .roster tbody tr { opacity: 1; transform: none; }
  .draw-rule { width: 96px; }
}

@media print {
  .site-header, .site-footer, .hero-figure { display: none; }
}

/* ================================================================
   The Chapter Ledger: magazine index, article page and cards.
   Built only from the tokens above. Light only, ruled and engraved
   in the same chapter formal language as the rest of the site.
   ================================================================ */

/* ---------- breadcrumb ---------- */
.mag-crumb { border-bottom: 1px solid var(--rule); background: var(--ivory); }
.mag-crumb ol {
  display: flex; flex-wrap: wrap; align-items: center; gap: var(--sp-2);
  list-style: none; margin: 0; padding: var(--sp-3) 0;
  font-size: var(--fs-xs); letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--muted);
}
.mag-crumb li { margin: 0; }
.mag-crumb li + li::before { content: "/"; color: var(--accent); margin-right: var(--sp-2); }
.mag-crumb a { color: var(--primary); text-decoration: none; }
.mag-crumb a:hover { text-decoration: underline; }
.mag-crumb li[aria-current] {
  color: var(--muted); max-width: 46ch; overflow: hidden;
  text-overflow: ellipsis; white-space: nowrap;
}

/* ---------- magazine masthead ---------- */
.mag-masthead { padding: var(--sp-8) 0 var(--sp-6); }
.mag-masthead h1 { max-width: 16ch; margin-bottom: var(--sp-5); }
.mag-masthead-note { max-width: 62ch; color: var(--muted); font-size: var(--fs-base); margin: 0; }

.mag-standfirst {
  font-family: var(--ff-display); font-size: var(--fs-lg);
  line-height: 1.5; color: var(--muted); max-width: 40em;
  border-left: 2px solid var(--accent); padding-left: var(--sp-4);
}

/* ---------- index grid and cards ---------- */
.mag-index { border-top: 1px solid var(--rule); padding-top: var(--sp-7); }
.mag-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--sp-6) var(--sp-5); }

.mag-card {
  display: flex; flex-direction: column;
  background: var(--surface); border: 1px solid var(--rule);
  border-top: 3px solid var(--primary-tint-16); border-radius: var(--r-md);
  overflow: hidden;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}
.mag-card:hover { border-top-color: var(--primary); box-shadow: var(--shadow-card); transform: translateY(-2px); }
.mag-card-media { display: block; border-bottom: 1px solid var(--accent-line); }
.mag-card-media img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; }
.mag-card-body { padding: var(--sp-5); display: flex; flex-direction: column; flex: 1 1 auto; }
.mag-kicker {
  font-size: var(--fs-xs); font-weight: 700; letter-spacing: 0.18em;
  text-transform: uppercase; color: var(--primary); margin: 0 0 var(--sp-3);
}
.mag-card-title { font-size: var(--fs-lg); line-height: 1.25; margin: 0 0 var(--sp-3); }
.mag-card-title a { color: var(--ink); text-decoration: none; }
.mag-card-title a:hover { color: var(--primary); text-decoration: underline; }
.mag-card-dek { color: var(--muted); font-size: var(--fs-base); margin: 0 0 var(--sp-4); }
.mag-card-meta {
  margin: auto 0 0; padding-top: var(--sp-3); border-top: 1px solid var(--rule);
  display: flex; flex-wrap: wrap; align-items: center; gap: var(--sp-2);
  font-size: var(--fs-xs); letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted);
}
.mag-card-meta span[aria-hidden] { color: var(--accent); }

.mag-card.lead {
  grid-column: 1 / -1; flex-direction: row; align-items: stretch;
  border-top-width: 4px; background: var(--surface);
}
.mag-card.lead .mag-card-media { flex: 0 0 56%; border-bottom: 0; border-right: 1px solid var(--accent-line); }
.mag-card.lead .mag-card-media img { height: 100%; aspect-ratio: auto; min-height: 340px; }
.mag-card.lead .mag-card-body { padding: var(--sp-7); justify-content: center; }
.mag-card.lead .mag-card-title { font-size: clamp(1.6rem, 1.1rem + 1.4vw, var(--fs-2xl)); }
.mag-card.lead .mag-card-dek { font-size: var(--fs-md); max-width: 44ch; }

.mag-index-cta { text-align: center; }
.mag-index-cta h2 { margin-bottom: var(--sp-4); }
.mag-index-cta p { color: var(--muted); margin: 0 auto var(--sp-5); max-width: 56ch; }

/* ---------- article header ---------- */
.mag-article { padding: var(--sp-8) 0 var(--sp-9); }
.mag-head { max-width: 46rem; margin: 0 auto var(--sp-6); }
.mag-head h1 { font-size: clamp(2rem, 1.2rem + 2.6vw, var(--fs-4xl)); margin-bottom: var(--sp-5); }
.mag-head .mag-standfirst { margin-bottom: var(--sp-5); }

.mag-byline {
  display: flex; flex-wrap: wrap; align-items: baseline;
  gap: var(--sp-2) var(--sp-5); margin: 0 0 var(--sp-5);
}
.mag-byline p { margin: 0; }
.mag-byline-name { font-family: var(--ff-display); font-size: var(--fs-md); color: var(--ink); }
.mag-byline-name a { text-decoration: none; border-bottom: 1px solid var(--accent); }
.mag-byline-meta {
  display: flex; flex-wrap: wrap; gap: var(--sp-2) var(--sp-4);
  font-size: var(--fs-xs); letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted);
}
.mag-byline-meta span + span { position: relative; }
.mag-byline-meta span + span::before {
  content: ""; position: absolute; left: calc(var(--sp-2) * -1 - 4px); top: 0.45em;
  width: 4px; height: 1px; background: var(--accent);
}

.mag-figure { margin: 0 auto var(--sp-7); max-width: 68rem; }
.mag-figure img {
  width: 100%; border-radius: var(--r-lg);
  border: 1px solid var(--accent-line); box-shadow: var(--shadow-card);
}

/* ---------- article body typography ---------- */
.mag-body { max-width: 40rem; margin: 0 auto; font-size: 1.075rem; line-height: 1.72; }
.mag-body > p { margin: 0 0 var(--sp-5); }
.mag-body h2 {
  font-size: clamp(1.45rem, 1.1rem + 1.2vw, var(--fs-xl));
  margin: var(--sp-8) 0 var(--sp-4); padding-top: var(--sp-4);
  border-top: 1px solid var(--rule);
}
.mag-body h3 { font-size: var(--fs-lg); margin: var(--sp-6) 0 var(--sp-3); color: var(--primary-deep); }
.mag-body ul, .mag-body ol { margin: 0 0 var(--sp-5); padding-left: 1.3rem; }
.mag-body li { margin-bottom: var(--sp-3); }
.mag-body li::marker { color: var(--primary); }
.mag-body a { color: var(--primary); text-decoration: underline; text-underline-offset: 3px; }
.mag-body a:hover { color: var(--primary-deep); }
.mag-body blockquote {
  margin: var(--sp-6) 0; padding: var(--sp-5) var(--sp-6);
  background: var(--primary-tint-04); border-left: 3px solid var(--primary);
  border-radius: 0 var(--r-md) var(--r-md) 0;
  font-family: var(--ff-display); font-size: var(--fs-lg); line-height: 1.5; color: var(--ink);
}
.mag-body blockquote p:last-child { margin-bottom: 0; }
.mag-body table {
  width: 100%; border-collapse: collapse; background: var(--surface);
  border: 1px solid var(--rule-strong); font-size: var(--fs-sm); margin: 0 0 var(--sp-6);
}
.mag-body th, .mag-body td { padding: 10px 13px; border-bottom: 1px solid var(--rule); text-align: left; }
.mag-body thead th {
  background: var(--accent-tint); font-size: var(--fs-xs); letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--primary-deep); border-bottom: 1px solid var(--accent-line);
}
.mag-body tbody tr:nth-child(even) { background: var(--bg); }

/* ---------- inline read more ---------- */
.mag-body .inline-read {
  margin: var(--sp-6) 0; padding: var(--sp-4) var(--sp-5);
  background: var(--accent-tint); border: 1px solid var(--accent-line);
  border-left: 3px solid var(--accent); border-radius: 0 var(--r-md) var(--r-md) 0;
  font-size: var(--fs-sm); line-height: 1.55; color: var(--muted);
}
.mag-body .inline-read a { font-weight: 700; color: var(--primary-deep); }

/* ---------- call to action ---------- */
.mag-cta {
  margin: var(--sp-8) 0 var(--sp-7); padding: var(--sp-6);
  background: var(--primary-tint-04);
  border: 1px solid var(--primary-tint-16); border-top: 3px solid var(--primary);
  border-radius: var(--r-md);
}
.mag-cta h2 { border: 0; padding: 0; margin: 0 0 var(--sp-3); font-size: var(--fs-xl); }
.mag-cta p { color: var(--muted); font-size: var(--fs-base); margin-bottom: var(--sp-5); }

/* ---------- author box ---------- */
.mag-author {
  display: grid; grid-template-columns: 120px 1fr; gap: var(--sp-5);
  padding: var(--sp-6) 0; border-top: 1px solid var(--rule-strong); border-bottom: 1px solid var(--rule-strong);
}
.mag-author img {
  width: 120px; height: 120px; border-radius: 50%; object-fit: cover;
  border: 1px solid var(--accent-line); background: var(--ivory);
}
.mag-author p { font-size: var(--fs-base); color: var(--muted); margin: 0 0 var(--sp-3); }
.mag-author-name {
  font-family: var(--ff-display); font-size: var(--fs-lg); font-weight: 600;
  color: var(--ink) !important;
}
.mag-author-link { margin-bottom: 0; }

/* ---------- Read also ---------- */
.mag-also h2 { margin-bottom: var(--sp-6); }
.mag-related-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--sp-5); }
.mag-rel {
  background: var(--surface); border: 1px solid var(--rule);
  border-radius: var(--r-md); overflow: hidden; padding-bottom: var(--sp-5);
  transition: box-shadow 0.2s ease, transform 0.2s ease, border-color 0.2s ease;
}
.mag-rel:hover { box-shadow: var(--shadow-card); transform: translateY(-2px); border-color: var(--accent-line); }
.mag-rel-media { display: block; border-bottom: 1px solid var(--accent-line); }
.mag-rel-media img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; }
.mag-rel-title { font-size: var(--fs-base); line-height: 1.35; margin: var(--sp-5) var(--sp-5) var(--sp-3); }
.mag-rel-title a { color: var(--ink); text-decoration: none; }
.mag-rel-title a:hover { color: var(--primary); text-decoration: underline; }
.mag-rel-dek {
  font-size: var(--fs-sm); color: var(--muted); margin: 0 var(--sp-5) var(--sp-3);
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.mag-rel-meta {
  margin: 0 var(--sp-5); font-size: var(--fs-xs); letter-spacing: 0.1em;
  text-transform: uppercase; color: var(--muted);
}
.mag-also-all { margin: var(--sp-6) 0 0; font-weight: 700; }

/* ---------- home page magazine strip ---------- */
.magazine-strip { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--sp-5); }
.magazine-more { margin: var(--sp-6) 0 0; font-weight: 700; }

/* ---------- author page and site map listings ---------- */
.mag-list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--rule); }
.mag-list li {
  margin: 0; padding: var(--sp-4) 0; border-bottom: 1px solid var(--rule);
  display: flex; flex-wrap: wrap; align-items: baseline; gap: var(--sp-2) var(--sp-4);
}
.mag-list a { font-weight: 500; }
.mag-list time, .mag-list .mag-list-note {
  font-size: var(--fs-sm); color: var(--muted); flex: 1 1 14rem;
}

/* ---------- responsive ---------- */
@media (max-width: 1000px) {
  .mag-grid, .mag-related-grid, .magazine-strip { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .mag-card.lead { flex-direction: column; }
  .mag-card.lead .mag-card-media { flex: none; border-right: 0; border-bottom: 1px solid var(--accent-line); }
  .mag-card.lead .mag-card-media img { min-height: 0; aspect-ratio: 3 / 2; }
  .mag-card.lead .mag-card-body { padding: var(--sp-6); }
}
@media (max-width: 700px) {
  .mag-grid, .mag-related-grid, .magazine-strip { grid-template-columns: minmax(0, 1fr); }
  .mag-article { padding: var(--sp-6) 0 var(--sp-8); }
  .mag-head h1 { font-size: clamp(1.7rem, 1.1rem + 3.4vw, 2.3rem); }
  .mag-body { font-size: 1.02rem; }
  .mag-standfirst { font-size: var(--fs-md); padding-left: var(--sp-3); }
  .mag-author { grid-template-columns: minmax(0, 1fr); }
  .mag-author img { width: 96px; height: 96px; }
  .mag-cta { padding: var(--sp-5); }
  .mag-crumb li[aria-current] { max-width: 100%; white-space: normal; }
  .mag-card.lead .mag-card-body { padding: var(--sp-5); }
  .mag-body blockquote { padding: var(--sp-4); font-size: var(--fs-md); }
  .mag-body table { display: block; overflow-x: auto; }
}


/* Network column: five sibling products, rotated so every site is linked the same
   number of times. Sits in the footer link grid and inherits its type and colour. */
.site-network ul { list-style: none; margin: 0; padding: 0; }
.site-network li + li { margin-top: 0.4rem; }
.site-network a { text-decoration: none; border-bottom: 1px solid transparent; }
.site-network a:hover, .site-network a:focus-visible { border-bottom-color: currentColor; }
