/**
 * CurioChat Design System
 * =======================
 * Complete component library extracted from:
 *   - curiochat.ai  src/css/curio.css
 *   - curiochat.com src/css/curio.css, src/css/lab-portal.css
 *   - curiochat_blog themes/curio/static/css/style.css
 *   - curiochat.ai  src/css/academy-learn.css
 *   - Sales pages   src/software-engineer/foundation/default.php (inline CSS)
 *
 * Structure
 * ---------
 *  1. Reset & Base
 *  2. Typography
 *  3. Layout utilities
 *  4. Navigation
 *  5. Buttons
 *  6. Badges / Chips / Pills
 *  7. Cards & Sections
 *  8. Forms
 *  9. Callout / Content boxes (academy)
 * 10. Code blocks
 * 11. Tables
 * 12. Footer
 * 13. Blog components
 * 14. Academy / Lesson layout
 * 15. Sales page components
 * 16. Utility classes
 * 17. Accessibility helpers
 * 18. Print
 *
 * Requires: tokens.css (imported before this file)
 */

/* ════════════════════════════════════════════════════════════════════
   1. RESET & BASE
   ════════════════════════════════════════════════════════════════════ */

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

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

body {
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: var(--line-height);
  color: var(--ink);
  background-color: var(--bg-body);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

a {
  color: var(--link-color);
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color var(--transition-fast);
}

a:hover {
  color: var(--navy);
}

ul,
ol {
  padding-left: 1.5em;
}

/* ════════════════════════════════════════════════════════════════════
   2. TYPOGRAPHY
   ════════════════════════════════════════════════════════════════════ */

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  color: var(--navy);
  line-height: 1.2;
  letter-spacing: -0.01em;
}

h1 {
  font-size: var(--text-h1);
  font-weight: var(--weight-heading);
}

h2 {
  font-size: var(--text-h2);
  font-weight: var(--weight-heading);
}

h3 {
  font-size: var(--text-h3);
  font-weight: var(--weight-subhead);
}

h4 {
  font-size: var(--text-h4);
  font-weight: var(--weight-subhead);
}

h5, h6 {
  font-size: 1rem;
  font-weight: var(--weight-semi);
}

p {
  margin-bottom: var(--space-3);
}

p:last-child {
  margin-bottom: 0;
}

strong {
  font-weight: 700;
  color: inherit;
}

em {
  font-style: italic;
}

small {
  font-size: 0.875rem;
}

blockquote {
  border-left: 4px solid var(--sky);
  padding: var(--space-2) var(--space-3);
  margin: var(--space-4) 0;
  color: var(--slate);
  font-style: italic;
  background: var(--mist);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}

/* Lead / intro paragraph */
.lead {
  font-size: clamp(1.05rem, 2.2vw, 1.2rem);
  color: var(--graphite);
  line-height: 1.6;
  margin-bottom: var(--space-4);
}

/* Sub-heading / descriptor text */
.sub {
  font-size: 0.95rem;
  color: var(--slate);
  margin-top: calc(var(--space-1) * -1);
  margin-bottom: var(--space-3);
}

/* Muted / caption text */
.muted {
  font-size: 0.875rem;
  color: var(--slate);
}

/* ════════════════════════════════════════════════════════════════════
   3. LAYOUT UTILITIES
   ════════════════════════════════════════════════════════════════════ */

.container {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: var(--space-4);
}

@media (max-width: 600px) {
  .container {
    padding-inline: var(--space-3);
  }
}

.section {
  padding-block: var(--space-6);
}

.section--sm {
  padding-block: var(--space-5);
}

.section--lg {
  padding-block: calc(var(--space-6) * 1.5);
}

/* Two-column responsive grid */
.twocol {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-5);
  align-items: center;
}

@media (max-width: 768px) {
  .twocol {
    grid-template-columns: 1fr;
    gap: var(--space-4);
  }
}

/* Three-column card grid */
.threecol {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-4);
}

@media (max-width: 960px) {
  .threecol {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 600px) {
  .threecol {
    grid-template-columns: 1fr;
  }
}

/* ════════════════════════════════════════════════════════════════════
   4. NAVIGATION
   ════════════════════════════════════════════════════════════════════ */

.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--white);
  box-shadow: var(--shadow-1);
}

.nav__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: var(--maxw);
  margin-inline: auto;
  padding: var(--space-2) var(--space-4);
  gap: var(--space-3);
}

.nav__logo {
  font-family: var(--font-heading);
  font-weight: var(--weight-heading);
  font-size: 1.25rem;
  color: var(--navy);
  text-decoration: none;
  flex-shrink: 0;
}

.nav__logo:hover {
  color: var(--navy);
  opacity: 0.85;
}

.nav__links {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  list-style: none;
  padding: 0;
  margin: 0;
}

/* `:not(.btn)` so buttons used inside the nav (e.g. "My Account" with
   `.btn .btn--navy .btn--sm`) keep their own foreground colors. Without
   the guard, `.nav__links a` (specificity 0,2,1) wins over `.btn--navy`
   (0,1,0) and pushes the button text back to graphite — graphite on navy
   is ~3.6:1 and fails WCAG AA. (Audit 2026-04-30.) */
.nav__links a:not(.btn) {
  font-size: 0.95rem;
  font-weight: var(--weight-semi);
  color: var(--graphite);
  text-decoration: none;
  transition: color var(--transition-fast);
  white-space: nowrap;
}

.nav__links a:not(.btn):hover,
.nav__links a:not(.btn)[aria-current="page"] {
  color: var(--navy);
}

/* Mobile hamburger toggle */
.nav__toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: var(--space-1);
  color: var(--navy);
}

@media (max-width: 768px) {
  .nav__toggle {
    display: flex;
    flex-direction: column;
    gap: 5px;
  }

  .nav__toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background: currentColor;
    border-radius: 2px;
    transition: transform var(--transition-normal), opacity var(--transition-normal);
  }

  .nav__links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--white);
    flex-direction: column;
    padding: var(--space-3) var(--space-4);
    box-shadow: var(--shadow-2);
    gap: var(--space-2);
  }

  .nav__links.is-open {
    display: flex;
  }
}

/* ════════════════════════════════════════════════════════════════════
   5. BUTTONS
   ════════════════════════════════════════════════════════════════════ */

/* Base button — apply to <a> or <button> */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5em;
  padding: 0.75em 1.75em;
  font-family: var(--font-heading);
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.2;
  text-decoration: none;
  border: 2px solid transparent;
  border-radius: 8px;
  cursor: pointer;
  white-space: nowrap;
  min-height: 44px;   /* WCAG touch target */
  transition:
    background-color var(--transition-fast),
    border-color var(--transition-fast),
    color var(--transition-fast),
    transform var(--transition-fast),
    box-shadow var(--transition-fast);
}

.btn:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
}

.btn:active {
  transform: translateY(1px);
}

/* Primary — warm orange.
   Uses navy text (5.55:1 on warm, 3.90:1 on warm-hover) instead of white
   (which would be 2.06:1 — fails WCAG AA). */
.btn--orange {
  background: var(--warm);
  color: var(--navy);
  border-color: var(--warm);
}

.btn--orange:hover {
  background: var(--warm-hover);
  border-color: var(--warm-hover);
  color: var(--navy);
}

/* Teal — navy text for WCAG AA (5.28:1). White on teal is only 2.17:1. */
.btn--teal {
  background: var(--teal);
  color: var(--navy);
  border-color: var(--teal);
}

.btn--teal:hover {
  background: var(--teal-hover);
  border-color: var(--teal-hover);
  color: var(--navy);
}

/* Navy */
.btn--navy {
  background: var(--navy);
  color: var(--white);
  border-color: var(--navy);
}

.btn--navy:hover {
  background: #0a2f54;
  border-color: #0a2f54;
  color: var(--white);
}

/* Ghost (navy outline on white bg) */
.btn--ghost {
  background: transparent;
  color: var(--navy);
  border-color: var(--navy);
}

.btn--ghost:hover {
  background: var(--navy);
  color: var(--white);
}

/* Ghost ink (graphite outline on white bg) */
.btn--ghost-ink {
  background: transparent;
  color: var(--graphite);
  border-color: var(--light);
}

.btn--ghost-ink:hover {
  background: var(--mist);
  border-color: var(--slate);
  color: var(--navy);
}

/* Ghost on dark — for use ON dark hero/offer-band backgrounds.
   Use this instead of inline `style="color:var(--white)"` overrides. */
.btn--ghost-on-dark {
  background: transparent;
  color: var(--white);
  border-color: rgba(255, 255, 255, 0.5);
}

.btn--ghost-on-dark:hover {
  background: var(--white);
  color: var(--navy);
  border-color: var(--white);
}

/* Outline (mist bg, navy border) */
.btn--outline {
  background: var(--mist);
  color: var(--navy);
  border-color: var(--light);
}

.btn--outline:hover {
  background: var(--light);
  border-color: var(--slate);
}

/* Sizes */
.btn--sm {
  padding: 0.5em 1.25em;
  font-size: 0.875rem;
  min-height: 36px;
}

.btn--lg {
  padding: 1em 2.25em;
  font-size: 1.125rem;
  min-height: 52px;
}

/* Full-width */
.btn--full {
  width: 100%;
}

/* ════════════════════════════════════════════════════════════════════
   6. BADGES / CHIPS / PILLS
   ════════════════════════════════════════════════════════════════════ */

/* Badge — label with color band */
.badge {
  display: inline-block;
  padding: 0.25em 0.75em;
  font-family: var(--font-heading);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  border-radius: 100px;
  background: var(--amber);
  color: var(--navy);
  white-space: nowrap;
}

/* Badge variants — text colors chosen for WCAG AA (4.5:1+). */
.badge--teal  { background: var(--teal);      color: var(--navy);  }  /* 5.28:1 */
.badge--green { background: var(--sage);      color: var(--navy);  }  /* 5.07:1 */
.badge--sky   { background: var(--sky);       color: var(--navy);  }  /* 6.70:1 */
.badge--navy  { background: var(--navy);      color: var(--white); }  /* 11.45:1 */
.badge--rust  { background: var(--rust-dark); color: var(--white); }  /* 4.87:1 */

/* Chip — inline tag / category label */
.chip {
  display: inline-block;
  padding: 0.25em 0.75em;
  font-size: 0.8rem;
  font-weight: var(--weight-semi);
  background: var(--mist);
  color: var(--slate);
  border: 1px solid var(--light);
  border-radius: 100px;
  white-space: nowrap;
}

/* Pill — like chip but with brand color fill */
.pill {
  display: inline-block;
  padding: 0.3em 1em;
  font-size: 0.85rem;
  font-weight: 700;
  background: var(--sky);
  color: var(--navy);
  border-radius: 100px;
  white-space: nowrap;
}

/* ════════════════════════════════════════════════════════════════════
   7. CARDS & SECTIONS
   ════════════════════════════════════════════════════════════════════ */

/* Default card */
.card {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow-1);
  padding: var(--space-4);
  transition: box-shadow var(--transition-normal);
}

.card:hover {
  box-shadow: var(--shadow-2);
}

/* Soft section — mist background panel */
.soft-section {
  background: var(--mist);
  border-radius: var(--radius);
  padding: var(--space-5) var(--space-4);
}

/* Brand card — navy top accent border */
.brand-card {
  background: var(--white);
  border-radius: var(--radius);
  border-top: 4px solid var(--amber);
  box-shadow: var(--shadow-2);
  padding: var(--space-4);
}

/* Section divider — short pill above section titles
   Mirrors the curiochat.com .section-divider primitive. Use as a
   visual anchor that signals a new section beat — far softer than <hr>
   and keeps the rhythm tight. Default teal; .section-divider--amber
   for the warmer variant. */
.section-divider {
  width: 60px;
  height: 4px;
  background: var(--teal);
  border-radius: 2px;
  margin: 0 auto var(--space-2);
}

.section-divider--amber { background: var(--amber); }

/* When a divider sits in a left-aligned reading column, override the
   auto-margin so it hugs the left edge with the rest of the column. */
.section-divider--left { margin-left: 0; margin-right: 0; }

/* Headshot — Pierre photo treatment shared across sales pages.
   .headshot is the rectangular hero variant (max-width 420). */
.headshot {
  display: block;
  width: 100%;
  max-width: 420px;
  border-radius: 12px;
  outline: 4px solid var(--white);
  outline-offset: -2px;
  box-shadow: var(--shadow-3);
}

/* .proof-headshot is the circular bio variant — smaller, used inline
   with bio text or in a "trust signal" footer. */
.proof-headshot {
  display: block;
  width: 180px;
  height: 180px;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid var(--white);
  box-shadow: 0 8px 32px rgba(13, 59, 102, 0.15);
}

/* Headshot card — background-tinted wrapper for headshot + bio. */
.headshot-card {
  background: rgba(241, 250, 238, 0.98);   /* tinted off bg-body */
  border: 2px solid #cfe6df;
  border-radius: var(--radius);
  padding: var(--space-3);
  text-align: center;
  box-shadow: var(--shadow-3);
  max-width: 480px;
  margin-inline: auto;
  transition: transform var(--transition-slow), box-shadow var(--transition-slow);
}

.headshot-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 40px rgba(13, 59, 102, 0.2);
}

.headshot-card .bio p,
.headshot-card .bio strong { color: var(--navy); }
.headshot-card .bio strong { font-weight: 800; }
.headshot-card .bio p { margin: 0.35rem 0; }

/* Bio block — semantic typography for an author bio under a headshot. */
.bio {
  color: var(--graphite);
  margin: 0.75rem 0 0;
}

.bio-note {
  font-size: 0.95rem;
  margin: 0.5rem 0 0;
}

.bio-proof {
  font-size: 0.85rem;
  margin: 0.5rem 0 0;
  color: var(--slate);
}

.bio-link { font-size: 0.85rem; margin: 0.5rem 0 0; }
.bio-link a { color: var(--cta-blue); }
.bio-link a:hover { text-decoration: underline; }

/* Bundle card — for pricing/offer cards */
.bundle-card {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow-2);
  padding: var(--space-5) var(--space-4);
  text-align: center;
}

.bundle-card--featured {
  border: 2px solid var(--teal);
}

/* Note / tip box — light */
.note {
  background: var(--mist);
  border-left: 4px solid var(--sky);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  padding: var(--space-2) var(--space-3);
  font-size: 0.95rem;
  color: var(--graphite);
}

/* Offer band — full-width CTA strip */
.offer-band {
  background: var(--navy);
  color: var(--white);
  text-align: center;
  padding: var(--space-5) var(--space-4);
  border-radius: var(--radius);
}

.offer-band h2,
.offer-band h3 {
  color: var(--amber);
}

/* ════════════════════════════════════════════════════════════════════
   8. HERO SECTIONS
   ════════════════════════════════════════════════════════════════════ */

.hero {
  background: linear-gradient(135deg, var(--navy) 0%, #1a5a9a 100%);
  color: var(--white);
  padding-block: var(--space-6);
}

.hero h1,
.hero h2,
.hero h3 {
  color: var(--white);
}

.hero .lead {
  color: rgba(255,255,255,0.85);
}

/* Two-column hero with image/media on right */
.hero--split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-5);
  align-items: center;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: var(--space-4);
}

@media (max-width: 768px) {
  .hero--split {
    grid-template-columns: 1fr;
  }
}

/* Centered hero variant */
.hero--centered {
  text-align: center;
  max-width: 780px;
  margin-inline: auto;
  padding-inline: var(--space-4);
}

.hero-cta {
  display: flex;
  gap: var(--space-2);
  flex-wrap: wrap;
  margin-top: var(--space-4);
}

.hero--centered .hero-cta {
  justify-content: center;
}

/* ════════════════════════════════════════════════════════════════════
   9. FORMS
   ════════════════════════════════════════════════════════════════════ */

.form-fields {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.field {
  display: flex;
  flex-direction: column;
  gap: 0.4em;
}

.field label {
  font-size: 0.9rem;
  font-weight: var(--weight-semi);
  color: var(--graphite);
}

.field input,
.field select,
.field textarea {
  width: 100%;
  padding: 0.7em 1em;
  font-family: var(--font-body);
  font-size: 1rem;
  color: var(--ink);
  background: var(--white);
  border: 1.5px solid var(--light);
  border-radius: var(--radius-sm);
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
  min-height: 44px;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--sky);
  box-shadow: var(--focus-ring);
}

.field input::placeholder,
.field textarea::placeholder {
  color: var(--slate);
  opacity: 0.7;
}

.field textarea {
  resize: vertical;
  min-height: 120px;
}

/* Inline form (email + button side by side) */
.form--inline {
  display: flex;
  gap: var(--space-2);
}

.form--inline input {
  flex: 1;
}

@media (max-width: 500px) {
  .form--inline {
    flex-direction: column;
  }
}

/* Form feedback messages */
.form-message {
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  font-weight: var(--weight-semi);
}

.form-message--success {
  background: rgba(46, 196, 182, 0.12);
  color: #1a8a80;
  border: 1px solid rgba(46, 196, 182, 0.3);
}

.form-message--error {
  background: rgba(231, 111, 81, 0.12);
  color: #c0392b;
  border: 1px solid rgba(231, 111, 81, 0.3);
}

/* ════════════════════════════════════════════════════════════════════
   10. CALLOUT / CONTENT BOXES (Academy)
   ════════════════════════════════════════════════════════════════════ */

/* Shared callout base */
.info-box,
.callout-box,
.action-box,
.reflection-box,
.quote-box,
.framework-box,
.research-box {
  border-radius: var(--radius-sm);
  padding: var(--space-3) var(--space-4);
  margin-block: var(--space-4);
}

/* Info box — blue, informational */
.info-box {
  background: rgba(130, 207, 253, 0.15);
  border-left: 4px solid var(--sky);
  color: var(--graphite);
}

.info-box__title {
  font-weight: 700;
  color: var(--navy);
  margin-bottom: var(--space-1);
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* Callout box — amber, key insight */
.callout-box {
  background: rgba(226, 197, 71, 0.12);
  border-left: 4px solid var(--amber);
}

.callout-box__title {
  font-weight: 700;
  color: #856d10;
  margin-bottom: var(--space-1);
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* Action box — warm orange, do this */
.action-box {
  background: rgba(244, 162, 97, 0.12);
  border-left: 4px solid var(--warm);
}

.action-box__title {
  font-weight: 700;
  color: #a0531e;
  margin-bottom: var(--space-1);
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* Reflection box — sage green, reflect */
.reflection-box {
  background: rgba(133, 187, 101, 0.12);
  border-left: 4px solid var(--sage);
}

.reflection-box__title {
  font-weight: 700;
  color: #3d6b20;
  margin-bottom: var(--space-1);
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* Quote box — navy, testimonial/pullquote */
.quote-box {
  background: rgba(13, 59, 102, 0.06);
  border-left: 4px solid var(--navy);
  font-style: italic;
}

.quote-box__attribution {
  font-style: normal;
  font-size: 0.85rem;
  color: var(--slate);
  margin-top: var(--space-2);
}

/* Research box — purple, study/evidence */
.research-box {
  background: rgba(99, 102, 241, 0.08);
  border-left: 4px solid #6366f1;
}

.research-box__title {
  font-weight: 700;
  color: #4338ca;
  margin-bottom: var(--space-1);
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* Framework box — step-based learning */
.framework-box {
  background: var(--mist);
  border: 1px solid var(--light);
}

.framework-box__title {
  font-family: var(--font-heading);
  font-weight: var(--weight-heading);
  color: var(--navy);
  margin-bottom: var(--space-3);
}

.framework-step {
  display: flex;
  gap: var(--space-3);
  align-items: flex-start;
  margin-bottom: var(--space-3);
}

.framework-step:last-child {
  margin-bottom: 0;
}

.step-badge {
  flex-shrink: 0;
  width: 2rem;
  height: 2rem;
  background: var(--navy);
  color: var(--white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-heading);
  font-size: 0.85rem;
  font-weight: 700;
}

.step-badge--amber { background: var(--amber); color: var(--navy); }  /* 6.71:1 */
.step-badge--teal  { background: var(--teal);  color: var(--navy); }  /* 5.28:1 — was white (2.17:1 FAIL) */

/* ════════════════════════════════════════════════════════════════════
   11. CODE BLOCKS
   ════════════════════════════════════════════════════════════════════ */

.code-block {
  background: #1e293b;
  border-radius: var(--radius-sm);
  padding: var(--space-3) var(--space-4);
  margin-block: var(--space-4);
  overflow-x: auto;
  position: relative;
}

.code-block code,
.code-block pre {
  font-family: 'Cascadia Code', 'Fira Code', 'Courier New', monospace;
  font-size: 0.875rem;
  line-height: 1.6;
  color: #e2e8f0;
  background: none;
  padding: 0;
  border: none;
}

.code-label {
  display: inline-block;
  background: rgba(255,255,255,0.12);
  color: #94a3b8;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0.2em 0.6em;
  border-radius: 3px;
  margin-bottom: var(--space-2);
}

.copy-btn {
  position: absolute;
  top: var(--space-2);
  right: var(--space-2);
  background: rgba(255,255,255,0.1);
  color: #94a3b8;
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 4px;
  padding: 0.3em 0.75em;
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
  transition: background var(--transition-fast), color var(--transition-fast);
}

.copy-btn:hover {
  background: rgba(255,255,255,0.2);
  color: var(--white);
}

/* Inline code */
code {
  font-family: 'Cascadia Code', 'Fira Code', 'Courier New', monospace;
  font-size: 0.875em;
  background: rgba(13,59,102,0.07);
  color: var(--navy);
  padding: 0.1em 0.4em;
  border-radius: 3px;
}

pre code {
  background: none;
  color: inherit;
  padding: 0;
}

/* ════════════════════════════════════════════════════════════════════
   12. TABLES
   ════════════════════════════════════════════════════════════════════ */

/* Academy data table */
.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
  margin-block: var(--space-4);
}

.data-table th {
  background: var(--navy);
  color: var(--white);
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.85rem;
  text-align: left;
  padding: var(--space-2) var(--space-3);
  letter-spacing: 0.03em;
}

.data-table td {
  padding: var(--space-2) var(--space-3);
  border-bottom: 1px solid var(--light);
  color: var(--graphite);
  vertical-align: top;
}

.data-table tbody tr:last-child td {
  border-bottom: none;
}

.data-table tbody tr:hover td {
  background: var(--mist);
}

/* Comparison / sales table */
.comparison-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
  margin-block: var(--space-4);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-1);
}

.comparison-table th {
  background: var(--navy);
  color: var(--white);
  font-family: var(--font-heading);
  font-weight: 700;
  padding: var(--space-2) var(--space-3);
  text-align: center;
}

.comparison-table th:first-child {
  text-align: left;
}

.comparison-table td {
  padding: var(--space-2) var(--space-3);
  border-bottom: 1px solid var(--light);
  text-align: center;
}

.comparison-table td:first-child {
  text-align: left;
  font-weight: var(--weight-semi);
}

/* Responsive table wrapper */
.table-scroll {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

/* ════════════════════════════════════════════════════════════════════
   13. FOOTER
   ════════════════════════════════════════════════════════════════════ */

.footer {
  background: var(--sky);
  border-top: 3px solid var(--navy);
  padding-block: var(--space-6);
  color: var(--navy);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: var(--space-4);
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: var(--space-4);
}

@media (max-width: 960px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 600px) {
  .footer-grid {
    grid-template-columns: 1fr;
  }
}

.footer__brand {
  font-family: var(--font-heading);
  font-weight: var(--weight-heading);
  font-size: 1.25rem;
  color: var(--navy);
  margin-bottom: var(--space-2);
}

.footer__col-title {
  font-family: var(--font-heading);
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--navy);
  margin-bottom: var(--space-2);
}

.footer__links {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0.5em;
}

.footer__links a {
  font-size: 0.9rem;
  color: var(--navy);
  text-decoration: none;
  opacity: 0.85;                      /* effective 4.86:1 on --sky (AA); 0.80 fell to 4.33:1 */
  transition: opacity var(--transition-fast);
}

.footer__links a:hover {
  opacity: 1;
  color: var(--navy);
}

.footer__bottom {
  max-width: var(--maxw);
  margin-inline: auto;
  padding: var(--space-4) var(--space-4) 0;
  border-top: 1px solid rgba(13,59,102,0.2);
  margin-top: var(--space-5);
  font-size: 0.85rem;
  color: var(--navy);
  opacity: 0.85;                      /* effective 4.86:1 on --sky (AA); 0.70 fell to 3.53:1 */
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--space-2);
}

/* ── Minimal footer variant — for legal & sales pages ──────────────
   Single horizontal row: copyright (left) · compliance links (right).
   Pattern from /terms/, /workshop-upgrade/, /privacy/, /disclaimer/,
   /cookie-policy/, /accessibility/ — same .footer chrome with a
   slimmer payload. Reuses .footer-grid (overridden to two-up).      */
.footer--minimal {
  padding-block: var(--space-3);
}
.footer--minimal .footer-grid {
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: var(--space-3);
}
@media (max-width: 600px) {
  .footer--minimal .footer-grid {
    grid-template-columns: 1fr;
    text-align: center;
  }
}

.footer-copyright {
  font-family: var(--font-body);
  font-size: 0.9rem;
  color: var(--navy);                /* 6.70:1 on --sky */
  opacity: 0.85;
}

/* Tight horizontal link list — used inside .footer for legal pages.
   Pairs with .footer--minimal but works independently if you want
   tight legal links inside the standard four-column footer too.    */
.footer-links--tight {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-1) var(--space-3);
  align-items: center;
  list-style: none;
  padding: 0;
  margin: 0;
}
.footer-links--tight a {
  font-size: 0.9rem;
  color: var(--navy);
  text-decoration: none;
  opacity: 0.85;
  border-bottom: 1px solid transparent;
  transition: opacity var(--transition-fast),
              border-color var(--transition-fast);
}
.footer-links--tight a:hover {
  opacity: 1;
  border-bottom-color: var(--navy);
}
.footer-links--tight a:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
  border-radius: 2px;
}
@media (max-width: 600px) {
  .footer-links--tight {
    justify-content: center;
  }
}

/* ════════════════════════════════════════════════════════════════════
   14. BLOG COMPONENTS
   ════════════════════════════════════════════════════════════════════ */

/* Blog grid */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: var(--space-4);
}

/* Post card */
.post-card {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow-1);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: box-shadow var(--transition-normal), transform var(--transition-normal);
}

.post-card:hover {
  box-shadow: var(--shadow-2);
  transform: translateY(-2px);
}

.post-card__image {
  aspect-ratio: 16 / 9;
  object-fit: cover;
  width: 100%;
}

.post-card__body {
  padding: var(--space-3);
  flex: 1;
  display: flex;
  flex-direction: column;
}

.post-card__category {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--teal-text);   /* 5.20:1 on white. Brand --teal would be 2.17:1. */
  margin-bottom: var(--space-1);
}

.post-card__title {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: var(--space-2);
  line-height: 1.3;
}

.post-card__excerpt {
  font-size: 0.9rem;
  color: var(--slate);
  line-height: 1.5;
  flex: 1;
  margin-bottom: var(--space-2);
}

.post-card__meta {
  font-size: 0.8rem;
  color: var(--slate);
  display: flex;
  align-items: center;
  gap: 1em;
  margin-top: auto;
}

/* Article / blog post content */
.article-content {
  max-width: 720px;
  margin-inline: auto;
}

.article-content h2 {
  margin-top: var(--space-5);
  margin-bottom: var(--space-3);
}

.article-content h3 {
  margin-top: var(--space-4);
  margin-bottom: var(--space-2);
}

.article-content p + p {
  margin-top: var(--space-3);
}

.article-content ul,
.article-content ol {
  margin-block: var(--space-3);
  line-height: 1.7;
}

.article-content li + li {
  margin-top: 0.5em;
}

.article-content img {
  border-radius: var(--radius-sm);
  margin-block: var(--space-4);
}

/* Table of contents */
.table-of-contents {
  background: var(--mist);
  border: 1px solid var(--light);
  border-radius: var(--radius-sm);
  padding: var(--space-3) var(--space-4);
  margin-block: var(--space-4);
  font-size: 0.9rem;
}

.table-of-contents__title {
  font-family: var(--font-heading);
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--navy);
  margin-bottom: var(--space-2);
}

.table-of-contents ol,
.table-of-contents ul {
  padding-left: 1.25em;
  margin: 0;
}

.table-of-contents li + li {
  margin-top: 0.4em;
}

.table-of-contents a {
  color: var(--slate);
  text-decoration: none;
}

.table-of-contents a:hover {
  color: var(--navy);
}

/* Pagination */
.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding-block: var(--space-5);
}

.pagination a,
.pagination span {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  height: 40px;
  padding-inline: 0.75em;
  border: 1.5px solid var(--light);
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  font-weight: var(--weight-semi);
  color: var(--navy);
  text-decoration: none;
  transition: background var(--transition-fast), border-color var(--transition-fast);
}

.pagination a:hover {
  background: var(--mist);
  border-color: var(--navy);
  color: var(--navy);
}

.pagination .is-current {
  background: var(--navy);
  border-color: var(--navy);
  color: var(--white);
}

/* Related articles strip */
.related-articles {
  margin-top: var(--space-6);
  padding-top: var(--space-5);
  border-top: 2px solid var(--light);
}

.related-articles__title {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: var(--space-4);
}

/* Section summary (blog section intro) */
.section-summary {
  max-width: 620px;
  font-size: 1.05rem;
  color: var(--slate);
  line-height: 1.65;
  margin-bottom: var(--space-4);
}

/* Article CTA strip */
.article-cta {
  background: var(--navy);
  color: var(--white);
  border-radius: var(--radius);
  padding: var(--space-4) var(--space-5);
  text-align: center;
  margin-block: var(--space-6);
}

.article-cta h3 {
  color: var(--amber);
  margin-bottom: var(--space-2);
}

.article-cta p {
  color: rgba(255,255,255,0.8);
  margin-bottom: var(--space-4);
}

/* Permission / access card */
.permission-card {
  background: var(--white);
  border: 2px solid var(--light);
  border-radius: var(--radius);
  padding: var(--space-4);
  text-align: center;
}

.permission-card--locked {
  border-color: var(--rust);
  background: rgba(231,111,81,0.04);
}

.permission-card--unlocked {
  border-color: var(--sage);
  background: rgba(133,187,101,0.06);
}

/* ════════════════════════════════════════════════════════════════════
   15. ACADEMY / LESSON LAYOUT
   ════════════════════════════════════════════════════════════════════ */

.lesson-container {
  max-width: 840px;
  margin-inline: auto;
  padding-inline: var(--space-4);
}

.lesson-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-block: var(--space-3);
  border-top: 2px solid var(--light);
  margin-top: var(--space-5);
  gap: var(--space-3);
}

.lesson-nav__prev,
.lesson-nav__next {
  display: flex;
  align-items: center;
  gap: 0.5em;
  font-weight: var(--weight-semi);
  color: var(--navy);
  text-decoration: none;
  font-size: 0.95rem;
  transition: color var(--transition-fast);
}

.lesson-nav__prev:hover,
.lesson-nav__next:hover {
  color: var(--teal-text);   /* 5.20:1 on white card bg */
}

.completion-box {
  background: rgba(133,187,101,0.1);
  border: 2px solid var(--sage);
  border-radius: var(--radius);
  padding: var(--space-4);
  text-align: center;
  margin-top: var(--space-5);
}

.completion-box h3 {
  color: #3d6b20;
  margin-bottom: var(--space-2);
}

/* ════════════════════════════════════════════════════════════════════
   16. SALES PAGE COMPONENTS
   ════════════════════════════════════════════════════════════════════ */

/* Sales page container — narrow, high-conversion reading width */
.sales-container {
  max-width: 760px;
  margin-inline: auto;
  padding-inline: var(--space-4);
  font-family: var(--font-body);
  color: var(--sales-text);
  font-size: 1.1rem;
  line-height: 1.75;
}

/* CTA block — pricing + button group */
.cta-block {
  background: var(--mist);
  border-radius: var(--radius);
  padding: var(--space-5) var(--space-4);
  text-align: center;
  margin-block: var(--space-5);
  border: 1px solid var(--light);
}

.cta-block__price {
  font-family: var(--font-heading);
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 800;
  color: var(--navy);
  margin-bottom: var(--space-1);
}

.cta-block__price--original {
  font-size: 1.2rem;
  color: var(--slate);
  text-decoration: line-through;
  font-weight: 400;
  margin-bottom: var(--space-1);
}

.cta-block__savings {
  font-size: 0.9rem;
  color: var(--teal-text);   /* 4.56:1 on mist. Brand --teal would be 1.90:1. */
  font-weight: 700;
  margin-bottom: var(--space-4);
}

/* Sales CTA button — electric blue, high contrast */
.cta-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5em;
  padding: 1em 2.5em;
  font-family: var(--font-heading);
  font-size: 1.125rem;
  font-weight: 800;
  color: var(--white);
  background: var(--cta-blue);
  border: none;
  border-radius: 8px;
  text-decoration: none;
  cursor: pointer;
  min-height: 52px;
  min-width: 200px;
  transition:
    background-color var(--transition-fast),
    transform var(--transition-fast),
    box-shadow var(--transition-fast);
}

.cta-btn:hover {
  background: #1d4fd8;
  color: var(--white);
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(37,99,235,0.35);
}

.cta-btn:active {
  transform: translateY(0);
}

.cta-btn:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px rgba(37,99,235,0.4);
}

/* Guarantee badge */
.guarantee-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  background: var(--white);
  border: 2px solid var(--sage);
  border-radius: var(--radius);
  padding: var(--space-2) var(--space-3);
  font-size: 0.9rem;
  color: var(--graphite);
  margin-top: var(--space-3);
}

.guarantee-badge__icon {
  font-size: 1.5rem;
}

/* Social proof strip */
.proof-strip {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-4);
  flex-wrap: wrap;
  padding-block: var(--space-4);
  font-size: 0.9rem;
  color: var(--slate);
}

.proof-strip__item {
  display: flex;
  align-items: center;
  gap: 0.4em;
}

/* FAQ accordion */
.faq-item {
  border-bottom: 1px solid var(--light);
}

.faq-item:first-child {
  border-top: 1px solid var(--light);
}

.faq-question {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  padding-block: var(--space-3);
  font-weight: var(--weight-semi);
  color: var(--navy);
  cursor: pointer;
  list-style: none;
  font-size: 1rem;
}

.faq-question::-webkit-details-marker {
  display: none;
}

.faq-question::after {
  content: '+';
  font-size: 1.5rem;
  font-weight: 300;
  color: var(--slate);
  flex-shrink: 0;
  transition: transform var(--transition-fast);
}

details[open] .faq-question::after {
  transform: rotate(45deg);
}

.faq-answer {
  padding-bottom: var(--space-3);
  color: var(--graphite);
  font-size: 0.95rem;
  line-height: 1.7;
}

/* ════════════════════════════════════════════════════════════════════
   17. NARRATIVE, JOURNEY & LEGAL COMPONENTS
   ────────────────────────────────────────────────────────────────────
   Patterns harvested from curiochat.com/lab, /workshop-upgrade,
   /ecosystem, /the-way-of-the-weary, /terms (audited 2026-04-28).

   17.1  Path Cards            — three-up tier selector with "you are here"
   17.2  Persona Split         — Seeker / Driver self-id with quote
   17.3  Fit Lists             — Yes / No qualification (✓ / ✕)
   17.4  Numbered Steps        — large-numeral process flow
   17.5  Timeline Acts         — multi-act phased journey (Act I/II/III)
   17.6  Workshop Flow         — pre-work / live / after with durations
   17.7  Metric Arrow          — before → after metric pair
   17.8  Value Stack           — itemized deliverables + strike total
   17.9  Founding Banner       — limited-time tier indicator
   17.10 Named Concept         — bolded term with definition (Drift Tax)
   17.11 Scenario              — italic future-state narrative
   17.12 Audience Card         — "For: [persona]" tagged product card
   17.13 Arrow Link            — text + animated → utility
   17.14 Essay / Long-Form     — lede, dropcap, pullquote, byline
   17.15 Legal Document        — doc-meta, ToC, def-list, anchored sections
   ════════════════════════════════════════════════════════════════════ */

/* ── 17.1 Path Cards ─────────────────────────────────────────────── */
.path-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-3);
  margin: var(--space-4) 0;
}
@media (max-width: 768px) {
  .path-grid { grid-template-columns: 1fr; }
}
.path-card {
  position: relative;
  background: var(--white);
  border: 1px solid var(--light);
  border-radius: var(--radius);
  padding: var(--space-4);
  display: flex;
  flex-direction: column;
}
.path-card__eyebrow {
  font-family: var(--font-heading);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--slate);
  margin-bottom: var(--space-1);
}
.path-card h3 {
  font-size: 1.25rem;
  margin: 0 0 var(--space-1) 0;
  color: var(--navy);
}
.path-card__price {
  font-family: var(--font-heading);
  font-weight: 800;
  color: var(--navy);
  font-size: 1.4rem;
  margin: var(--space-1) 0;
}
.path-card__meta {
  font-size: 0.95rem;
  color: var(--slate);
  margin-bottom: var(--space-2);
}
.path-card__body {
  margin-bottom: var(--space-3);
  flex: 1;
  color: var(--graphite);
}
.path-card .arrow-link {
  margin-top: auto;
  align-self: flex-start;             /* prevent cross-axis stretch in flex-column parent */
}
.path-card--current {
  border-color: var(--navy);
  border-width: 2px;
  background: linear-gradient(180deg, #fffaf0 0%, var(--white) 60%);
  box-shadow: var(--shadow-2);
}
.path-card--current::before {
  content: "You are here";
  position: absolute;
  top: -0.7rem;
  left: var(--space-3);
  background: var(--navy);
  color: var(--amber);                /* 6.71:1 on navy */
  font-family: var(--font-heading);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  padding: 0.3rem 0.65rem;
  border-radius: 999px;
}

/* ── 17.2 Persona Split ──────────────────────────────────────────── */
.persona-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-3);
  margin: var(--space-4) 0 var(--space-2);
}
@media (max-width: 768px) {
  .persona-split { grid-template-columns: 1fr; }
}
.persona-card {
  background: var(--white);
  border-left: 4px solid var(--teal);
  border-radius: var(--radius);
  box-shadow: var(--shadow-1);
  padding: var(--space-3) var(--space-4);
}
.persona-card:nth-child(2) { border-left-color: var(--warm); }
.persona-card h3 {
  margin: 0 0 var(--space-1) 0;
  color: var(--navy);
  font-size: 1.2rem;
}
.persona-card__quote {
  font-style: italic;
  color: var(--graphite);
  margin: 0 0 var(--space-2) 0;
  position: relative;
  padding-left: 1.1rem;
}
.persona-card__quote::before {
  content: "\201C";                   /* curly left-double-quote */
  position: absolute;
  left: -0.1rem;
  top: -0.4rem;
  font-family: var(--font-heading);
  font-size: 2rem;
  color: var(--teal-text);
  line-height: 1;
}
.persona-resolve {
  text-align: center;
  font-style: italic;
  color: var(--slate);
  margin: 0 0 var(--space-3) 0;
}

/* ── 17.3 Fit Lists ──────────────────────────────────────────────── */
.fit-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-3);
  margin: var(--space-3) 0;
}
@media (max-width: 768px) {
  .fit-grid { grid-template-columns: 1fr; }
}
.fit-list {
  border-radius: var(--radius);
  padding: var(--space-3) var(--space-4);
  margin: 0;
}
.fit-list h4 {
  margin: 0 0 var(--space-2) 0;
  font-size: 1.05rem;
  color: var(--navy);
}
.fit-list ul {
  list-style: none;
  padding-left: 0;
  margin: 0;
}
.fit-list li {
  position: relative;
  padding-left: 1.75rem;
  margin-bottom: var(--space-1);
  line-height: 1.55;
}
.fit-list li::before {
  position: absolute;
  left: 0;
  top: 0.05em;
  font-weight: 800;
  font-size: 1.05rem;
  width: 1.25rem;
  text-align: center;
}
.fit-list--yes {
  background: var(--bg-sage-soft);
  border-left: 4px solid var(--sage);
}
.fit-list--yes li::before {
  content: "\2713";                   /* ✓ */
  color: #3d6b20;                     /* 5.4:1 on sage-soft */
}
.fit-list--no {
  background: var(--bg-rust-soft);
  border-left: 4px solid var(--rust-dark);
}
.fit-list--no li::before {
  content: "\2715";                   /* ✕ */
  color: #9a3a20;                     /* 6.11:1 on bg-rust-soft (full AA) */
}

/* ── 17.4 Numbered Steps ─────────────────────────────────────────── */
.numbered-steps {
  display: grid;
  gap: var(--space-3);
  counter-reset: step;
  margin: var(--space-4) 0;
  padding: 0;
  list-style: none;
}
.numbered-step {
  display: grid;
  grid-template-columns: 4rem 1fr;
  gap: var(--space-3);
  align-items: start;
}
.numbered-step::before {
  counter-increment: step;
  content: counter(step);
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 2.25rem;
  line-height: 1;
  color: var(--teal-text);
  background: var(--bg-light);
  border-radius: var(--radius);
  width: 4rem;
  height: 4rem;
  display: flex;
  align-items: center;
  justify-content: center;
}
.numbered-step h3 {
  margin: 0 0 var(--space-1) 0;
  color: var(--navy);
  font-size: 1.2rem;
}
.numbered-step__body { margin: 0; color: var(--graphite); }

/* ── 17.5 Timeline Acts ──────────────────────────────────────────── */
.timeline-acts {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-3);
  margin: var(--space-4) 0;
}
@media (max-width: 768px) {
  .timeline-acts { grid-template-columns: 1fr; }
}
.timeline-act {
  background: var(--white);
  border-radius: var(--radius);
  border-top: 4px solid var(--navy);
  padding: var(--space-3) var(--space-4);
  box-shadow: var(--shadow-1);
}
.timeline-act:nth-child(2) { border-top-color: var(--teal); }
.timeline-act:nth-child(3) { border-top-color: var(--warm); }
.timeline-act__range {
  display: block;
  font-family: var(--font-heading);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--slate);
  margin-bottom: var(--space-1);
}
.timeline-act h3 {
  margin: 0 0 var(--space-2) 0;
  color: var(--navy);
  font-size: 1.2rem;
}
.timeline-act h3 small {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--slate);
  margin-top: 0.15rem;
}
.timeline-act ul {
  padding-left: 1.1rem;
  margin: 0 0 var(--space-2) 0;
}
.timeline-act li { margin-bottom: 0.4rem; }
.timeline-act__deliverable {
  margin: var(--space-2) 0 0;
  padding: var(--space-2);
  background: var(--bg-light);
  border-radius: var(--radius-sm);
  font-size: 0.95rem;
}
.timeline-act__deliverable strong { color: var(--navy); }

/* ── 17.6 Workshop Flow ──────────────────────────────────────────── */
.workshop-flow {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  margin: var(--space-4) 0;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--light);
  background: var(--white);
}
@media (max-width: 768px) {
  .workshop-flow { grid-template-columns: 1fr; }
}
.flow-stage {
  padding: var(--space-3) var(--space-4);
  border-right: 1px solid var(--light);
}
.flow-stage:last-child { border-right: none; }
@media (max-width: 768px) {
  .flow-stage { border-right: none; border-bottom: 1px solid var(--light); }
  .flow-stage:last-child { border-bottom: none; }
}
.flow-stage__label {
  display: block;
  font-family: var(--font-heading);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--teal-text);
  margin-bottom: 0.25rem;
}
.flow-stage__duration {
  font-family: var(--font-heading);
  font-weight: 800;
  color: var(--navy);
  font-size: 1.4rem;
  margin: 0 0 var(--space-1);
}
.flow-stage h4 {
  margin: 0 0 var(--space-1) 0;
  color: var(--navy);
  font-size: 1.05rem;
}
.flow-stage p {
  margin: 0;
  color: var(--graphite);
  font-size: 0.95rem;
}

/* ── 17.7 Metric Arrow ───────────────────────────────────────────── */
.metric-arrow {
  display: inline-flex;
  align-items: baseline;
  gap: 0.5rem;
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 1.3rem;
  color: var(--navy);
}
.metric-arrow__before {
  color: var(--slate);
  text-decoration: line-through;
  text-decoration-thickness: 2px;
  text-decoration-color: var(--rust-dark);
}
.metric-arrow__arrow {
  color: var(--teal-text);
  font-weight: 800;
}
.metric-arrow__after { color: var(--navy); }
.metric-arrow__unit {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--slate);
}

/* ── 17.8 Value Stack ────────────────────────────────────────────── */
.value-stack {
  background: var(--white);
  border: 1px solid var(--light);
  border-radius: var(--radius);
  padding: var(--space-3) var(--space-4);
  margin: var(--space-3) 0;
}
.value-stack__row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: var(--space-2);
  padding: 0.6rem 0;
  border-bottom: 1px solid var(--rule-color);
}
.value-stack__row:last-of-type { border-bottom: none; }
.value-stack__label { flex: 1; color: var(--graphite); }
.value-stack__label strong {
  display: block;
  color: var(--navy);
  font-weight: 700;
  margin-bottom: 0.2rem;
}
.value-stack__amount {
  font-family: var(--font-heading);
  font-weight: 700;
  color: var(--navy);
  white-space: nowrap;
}
.value-stack__total {
  margin-top: var(--space-2);
  padding-top: var(--space-2);
  border-top: 2px solid var(--navy);
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: var(--space-2);
}
.value-stack__total-label {
  font-family: var(--font-heading);
  font-weight: 700;
  color: var(--navy);
}
.value-stack__total-amount {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 1.4rem;
  color: var(--navy);
}
.value-stack__total-amount s {
  color: var(--slate);              /* 7.9:1 on white */
  margin-right: 0.5rem;
  font-weight: 600;
  font-size: 1.1rem;
}

/* ── 17.9 Founding Banner ────────────────────────────────────────── */
.founding-banner {
  background: var(--bg-amber-soft);
  border: 1px solid var(--amber);
  border-left: 4px solid var(--amber);
  border-radius: var(--radius);
  padding: var(--space-3) var(--space-4);
  margin: var(--space-3) 0;
}
.founding-banner__label {
  display: inline-block;
  font-family: var(--font-heading);
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--navy);                /* 6.71:1 on amber */
  background: var(--amber);
  padding: 0.25rem 0.55rem;
  border-radius: var(--radius-sm);
  margin-bottom: var(--space-1);
}
.founding-banner h4 {
  margin: 0 0 var(--space-1) 0;
  color: var(--navy);
  font-size: 1.1rem;
}
.founding-banner__why {
  margin: var(--space-1) 0 0 0;
  font-size: 0.95rem;
  color: var(--graphite);
}
.founding-banner__why strong { color: var(--navy); }

/* ── 17.10 Named Concept ─────────────────────────────────────────── */
.named-concept {
  background: var(--mist);
  border-radius: var(--radius);
  padding: var(--space-3) var(--space-4);
  margin: var(--space-3) 0;
  border-left: 4px solid var(--navy);
}
.named-concept__term {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 1.15rem;
  color: var(--navy);
  margin: 0 0 var(--space-1) 0;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.named-concept__term::before {
  content: "\00A7";                   /* § */
  color: var(--teal-text);
  font-weight: 700;
}
.named-concept__def { margin: 0; color: var(--graphite); }
.named-concept__def strong { color: var(--navy); }

/* ── 17.11 Scenario ──────────────────────────────────────────────── */
.scenario {
  background: var(--bg-sky-soft);
  border-left: 4px solid var(--sky);
  border-radius: var(--radius);
  padding: var(--space-3) var(--space-4);
  font-style: italic;
  color: var(--graphite);
  margin: var(--space-3) 0;
}
.scenario::before {
  content: "Imagine";
  display: block;
  font-family: var(--font-heading);
  font-style: normal;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--navy);
  margin-bottom: var(--space-1);
}
.scenario p { margin: 0 0 var(--space-1) 0; }
.scenario p:last-child { margin-bottom: 0; }

/* ── 17.12 Audience Card ─────────────────────────────────────────── */
.audience-card {
  background: var(--white);
  border: 1px solid var(--light);
  border-radius: var(--radius);
  padding: var(--space-3) var(--space-4);
  display: flex;
  flex-direction: column;
}
.audience-card__for {
  font-family: var(--font-heading);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--teal-text);
  margin-bottom: var(--space-1);
}
.audience-card__for::before { content: "For: "; color: var(--slate); }
.audience-card h3 {
  margin: 0 0 var(--space-1) 0;
  color: var(--navy);
  font-size: 1.15rem;
}
.audience-card__price {
  font-family: var(--font-heading);
  font-weight: 800;
  color: var(--navy);
  margin: var(--space-1) 0;
}
.audience-card__body {
  flex: 1;
  margin-bottom: var(--space-2);
  color: var(--graphite);
}
.audience-card .arrow-link {
  align-self: flex-start;             /* prevent cross-axis stretch in flex-column parent */
}

/* ── 17.13 Arrow Link ────────────────────────────────────────────── */
.arrow-link {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  color: var(--link-color);
  font-weight: 600;
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: border-color var(--transition-fast);
}
.arrow-link::after {
  content: "\2192";                   /* → */
  display: inline-block;
  transition: transform var(--transition-fast);
}
.arrow-link:hover {
  border-bottom-color: var(--link-color);
}
.arrow-link:hover::after {
  transform: translateX(3px);
}
.arrow-link:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
  border-radius: 2px;
}
.arrow-link--lg { font-size: 1.05rem; }

/* ── 17.14 Essay / Long-Form Layout ──────────────────────────────── */
.essay {
  max-width: var(--essay-maxw);
  margin: 0 auto;
  padding: var(--space-4) var(--space-3);
  font-size: 1.125rem;
  line-height: 1.75;
  color: var(--ink);
}
.essay > p { margin: 0 0 var(--space-3) 0; }
.essay h2 {
  font-size: clamp(1.4rem, 3vw, 1.8rem);
  margin-top: var(--space-5);
  margin-bottom: var(--space-2);
  color: var(--navy);
}
.essay h3 {
  font-size: 1.25rem;
  margin-top: var(--space-4);
  margin-bottom: var(--space-2);
  color: var(--navy);
}
.essay__lede {
  font-size: 1.25rem;
  line-height: 1.65;
  color: var(--graphite);
  margin-bottom: var(--space-4);
}
.essay__lede--dropcap::first-letter {
  font-family: var(--font-heading);
  float: left;
  font-size: 4rem;
  line-height: 0.9;
  font-weight: 800;
  color: var(--navy);
  padding: 0.2rem 0.6rem 0 0;
  margin-top: 0.1rem;
}
.essay__divider {
  border: none;
  text-align: center;
  margin: var(--space-5) 0;
  height: 1rem;
}
.essay__divider::before {
  content: "* * *";
  letter-spacing: 0.6em;
  font-size: 0.9rem;
  color: var(--slate);
}
.pullquote {
  margin: var(--space-4) 0;
  padding: var(--space-2) var(--space-4);
  border-left: 3px solid var(--amber);
  font-family: var(--font-heading);
  font-size: 1.35rem;
  font-weight: 700;
  line-height: 1.4;
  color: var(--navy);
  font-style: normal;
}
.pullquote cite {
  display: block;
  margin-top: var(--space-1);
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 400;
  font-style: normal;
  color: var(--slate);
}
.pullquote cite::before { content: "\2014\00A0"; }   /* em-dash + nbsp */
.byline {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  margin: var(--space-3) 0 var(--space-4) 0;
  padding: var(--space-2) 0;
  border-top: 1px solid var(--rule-color);
  border-bottom: 1px solid var(--rule-color);
}
.byline__avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--mist);
  flex-shrink: 0;
  object-fit: cover;
}
.byline__name {
  font-family: var(--font-heading);
  font-weight: 700;
  color: var(--navy);
  margin: 0;
  font-size: 0.95rem;
}
.byline__meta {
  margin: 0;
  font-size: 0.85rem;
  color: var(--slate);
}

/* ── 17.15 Legal Document Layout ─────────────────────────────────── */
.legal-doc {
  max-width: 44rem;
  margin: 0 auto;
  padding: var(--space-4) var(--space-3);
  color: var(--ink);
}
.legal-doc h1 {
  margin-bottom: var(--space-2);
  color: var(--navy);
}
.doc-meta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2) var(--space-3);
  align-items: center;
  padding: var(--space-1) var(--space-2);
  background: var(--mist);
  border-radius: var(--radius-sm);
  margin: var(--space-2) 0 var(--space-4) 0;
  font-size: 0.9rem;
  color: var(--slate);
}
.doc-meta strong { color: var(--navy); font-weight: 700; }
.doc-meta__item { display: inline-flex; gap: 0.35rem; }

.legal-toc {
  background: var(--bg-light);
  border: 1px solid var(--light);
  border-radius: var(--radius);
  padding: var(--space-3) var(--space-4);
  margin: var(--space-3) 0 var(--space-4) 0;
}
.legal-toc h2 {
  margin: 0 0 var(--space-2) 0;
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--slate);
}
.legal-toc ol {
  list-style: none;
  padding: 0;
  margin: 0;
  columns: 2;
  column-gap: var(--space-4);
  counter-reset: toc;
}
@media (max-width: 600px) {
  .legal-toc ol { columns: 1; }
}
.legal-toc li {
  counter-increment: toc;
  margin-bottom: 0.35rem;
  break-inside: avoid;
}
.legal-toc li::before {
  content: counter(toc) ".";
  display: inline-block;
  width: 1.8rem;
  font-family: var(--font-heading);
  font-weight: 700;
  color: var(--slate);
  text-align: right;
  margin-right: 0.4rem;
}
.legal-toc a {
  color: var(--link-color);
  text-decoration: none;
  border-bottom: 1px dotted var(--light);
}
.legal-toc a:hover { border-bottom-style: solid; }

.numbered-section {
  scroll-margin-top: 5rem;
  margin-top: var(--space-4);
  padding-top: var(--space-2);
  border-top: 1px solid var(--rule-color);
}
.numbered-section > h2 {
  font-size: 1.3rem;
  color: var(--navy);
  margin: 0 0 var(--space-2) 0;
}
.numbered-section .anchor-link {
  opacity: 0;
  margin-left: 0.4rem;
  font-size: 0.85em;
  color: var(--slate);
  text-decoration: none;
  transition: opacity var(--transition-fast);
}
.numbered-section:hover .anchor-link,
.numbered-section .anchor-link:focus-visible { opacity: 1; }
.numbered-section p { margin: 0 0 var(--space-2) 0; }

.def-list { margin: var(--space-2) 0; }
.def-list dt {
  font-weight: 700;
  color: var(--navy);
  margin-top: var(--space-2);
}
.def-list dt:first-child { margin-top: 0; }
.def-list dd {
  margin: 0.25rem 0 var(--space-2) 0;
  padding-left: var(--space-2);
  color: var(--graphite);
}

.legal-ack {
  font-style: italic;
  background: var(--bg-amber-soft);
  border-left: 3px solid var(--amber);
  padding: var(--space-2) var(--space-3);
  border-radius: var(--radius-sm);
  margin: var(--space-2) 0;
  color: var(--graphite);
}

/* ════════════════════════════════════════════════════════════════════
   18. UTILITY CLASSES
   ════════════════════════════════════════════════════════════════════ */

/* Text alignment */
.text-left   { text-align: left; }
.text-center { text-align: center; }
.text-right  { text-align: right; }

/* Text color
   ----------
   .text-amber and .text-teal use the *-text companion tokens, not the
   raw brand tokens, because the raw --amber (#e2c547, 3.30:1 on white)
   and --teal (#2ec4b6, 3.07:1 on white) fail WCAG AA as text on light
   surfaces. --teal-text (#117a6f, 5.20:1) and a darkened amber stand-in
   (--graphite for .text-amber on white — keeps the brand vibe via the
   surrounding context) are the safe text choices. If you need bright
   amber/teal text, use them on a dark background and apply .text-white
   plus an explicit color rule scoped to that context. */
.text-navy     { color: var(--navy); }
.text-amber    { color: var(--graphite); }   /* See note above — was var(--amber), failed AA on white */
.text-teal     { color: var(--teal-text); }  /* See note above — was var(--teal), failed AA on white */
.text-slate    { color: var(--slate); }
.text-white    { color: var(--white); }
.text-success  { color: var(--success); }
.text-danger   { color: var(--danger); }

/* Background color */
.bg-navy   { background-color: var(--navy); }
.bg-sky    { background-color: var(--sky); }
.bg-mist   { background-color: var(--mist); }
.bg-white  { background-color: var(--white); }

/* Spacing utilities */
.mt-0 { margin-top: 0; }
.mt-1 { margin-top: var(--space-1); }
.mt-2 { margin-top: var(--space-2); }
.mt-3 { margin-top: var(--space-3); }
.mt-4 { margin-top: var(--space-4); }
.mt-5 { margin-top: var(--space-5); }
.mt-6 { margin-top: var(--space-6); }

.mb-0 { margin-bottom: 0; }
.mb-1 { margin-bottom: var(--space-1); }
.mb-2 { margin-bottom: var(--space-2); }
.mb-3 { margin-bottom: var(--space-3); }
.mb-4 { margin-bottom: var(--space-4); }
.mb-5 { margin-bottom: var(--space-5); }
.mb-6 { margin-bottom: var(--space-6); }

/* Display */
.hidden         { display: none !important; }
.sr-only        { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border-width: 0; }
.not-sr-only    { position: static; width: auto; height: auto; padding: 0; margin: 0; overflow: visible; clip: auto; white-space: normal; }

/* Flex helpers */
.flex           { display: flex; }
.flex-col       { display: flex; flex-direction: column; }
.items-center   { align-items: center; }
.justify-center { justify-content: center; }
.justify-between{ justify-content: space-between; }
.gap-1          { gap: var(--space-1); }
.gap-2          { gap: var(--space-2); }
.gap-3          { gap: var(--space-3); }
.gap-4          { gap: var(--space-4); }
.flex-wrap      { flex-wrap: wrap; }

/* ════════════════════════════════════════════════════════════════════
   19. ACCESSIBILITY HELPERS
   ════════════════════════════════════════════════════════════════════ */

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

/* Focus-visible: only show ring on keyboard nav */
:focus:not(:focus-visible) {
  outline: none;
}

:focus-visible {
  outline: 3px solid var(--focus-ring-color);
  outline-offset: 2px;
}

/* Skip to content link */
.skip-link {
  position: absolute;
  top: -100%;
  left: var(--space-2);
  background: var(--navy);
  color: var(--white);
  padding: var(--space-1) var(--space-3);
  border-radius: var(--radius-sm);
  font-weight: 700;
  text-decoration: none;
  z-index: 9999;
  transition: top var(--transition-fast);
}

.skip-link:focus {
  top: var(--space-2);
}

/* High-contrast mode support */
@media (forced-colors: active) {
  .btn,
  .cta-btn {
    border: 2px solid ButtonText;
  }

  .badge,
  .chip,
  .pill {
    border: 1px solid ButtonText;
  }
}

/* ════════════════════════════════════════════════════════════════════
   20. PRINT
   ════════════════════════════════════════════════════════════════════ */

@media print {
  .nav,
  .footer,
  .cta-btn,
  .btn,
  .cookie-banner {
    display: none !important;
  }

  body {
    font-size: 12pt;
    color: #000;
    background: #fff;
  }

  h1, h2, h3, h4 {
    page-break-after: avoid;
    color: #000;
  }

  a {
    color: #000;
    text-decoration: underline;
  }

  a[href]::after {
    content: " (" attr(href) ")";
    font-size: 0.75em;
  }
}
