/* ============================================================
   Vivoso — Global Styles
   ============================================================ */

/* Trademark marker — proportional superscript for every `Vivoso<sup class="tm">™</sup>`
   in the app. Keeps the glyph crisp at any parent font size without
   disturbing line height. `font-weight: normal` is intentional so the ™
   stays a thin marker even when the parent is bold (logo, heading,
   strong, brand-mark) — the base "Vivoso" retains the parent weight. */
sup.tm {
  font-size: 0.55em;
  vertical-align: super;
  line-height: 0;
  margin-left: 0.08em;
  font-weight: normal;
  font-style: normal;
  letter-spacing: normal;
}

:root {
  /* === VIVOSO BRAND IDENTITY SYSTEM v1.2 === */
  /* Source of truth. Do not redefine these elsewhere. */

  --vivoso-purple: #6B46A0;
  --deep-purple: #4A2D7A;
  --mission-gold: #A07800;
  --learning-teal: #0D7A72;
  --vitality-pink: #C0396A;

  /* v1.26.0 — Marketing brand refresh tokens. */
  --oxford: #02122F;

  /* v1.28.0 — In-app brand evolution tokens (full color system).
     Marketing tokens above are reconciled via aliases below so a single
     source of truth drives both surfaces. */

  /* === FLAGSHIP === */
  --moonlight: #F0ECDD;
  --moonlight-tint: #FAF8F2;
  --amber: #D4882A;
  --steel: #495B7D;

  /* === GREEN / SAGE & FOREST (Finance/Money pathways) === */
  --linen-sage: #EFF2E8;
  --mist-sage:  #D8DFC7;
  --sage:       #A7B594;
  --olive-sage: #7C8D6A;
  --moss:       #566849;
  --forest:     #384A33;
  --pine:       #1F2E1E;

  /* === RED / BRICK & CLAY (Safety/Legal/Civic pathways) === */
  --blush-linen: #F5E8E0;
  --sandstone:   #E6C6B5;
  --clay:        #D49A82;
  --terracotta:  #B8694F;
  --brick:       #964432;
  --oxblood:     #6E2C20;
  --mahogany:    #421913;

  /* === PURPLE / PLUM & HEATHER (Wellness/Mental Health/Relationships) === */
  --lavender-mist: #EEE8EE;
  --heather:       #D4C5D6;
  --thistle:       #A695AC;
  --mauve:         #7A6383;
  --plum:          #54405E;
  --aubergine:     #372541;
  --ink-plum:      #1F1428;

  /* === ORANGE / EMBER & RUST (Life Skills/Health/Education-stage) === */
  --cream-honey: #FAEED7;
  --honey:       #F2D9A8;
  --wheat:       #E5B872;
  --ember:       #AE6418;
  --rust:        #854810;
  --burnt-umber: #522C0A;

  /* === BLUE / HARBOR & SLATE (Career/Professional/Digital + Steel flagship) === */
  --powder:      #E8EDF4;
  --frost-tint:  #CDD8E8;
  --frost-blue:  #8BA3C5;
  --harbor:      #5577A8;
  --storm:       #23354D;

  /* === NEUTRALS (Moonlight extended) === */
  --bone:      #DCD7C5;
  --sand-gray: #B8B19A;

  /* Token reconciliation: v1.26.x marketing surfaces use --warm-amber.
     Alias it to --amber so both surfaces share one canonical Amber. */
  --warm-amber: var(--amber);

  --purple-tint: #ECE7F3;
  --teal-tint: #DDEEEC;
  --gold-tint: #F5EFD9;
  --pink-tint: #F5DDE5;

  --brand-bg: #F8F7FA;
  --brand-surface: #FFFFFF;
  --brand-body-text: #1F1B2E;
  --brand-subtext: #6B6878;
  --brand-rule: #E5E2EC;

  --font-wordmark: 'Inter', system-ui, sans-serif;
  --font-display: 'Playfair Display', Georgia, serif;
  --font-body: 'DM Sans', system-ui, -apple-system, sans-serif;

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-pill: 999px;

  --shadow-sm: 0 1px 2px rgba(31, 27, 46, 0.06);
  --shadow-md: 0 4px 12px rgba(31, 27, 46, 0.08);
  --shadow-lg: 0 12px 32px rgba(31, 27, 46, 0.12);

  /* === LEGACY TOKEN ALIASES === */
  /* These keep existing consumers working. Migrate them away in later phases,
     then delete each line as its consumers are updated. */

  --primary: var(--amber);
  --primary-light: var(--gold-tint);
  --primary-dark: #B8741F;          /* amber-dark for hover/pressed (tech debt #17) */
  --success: var(--learning-teal);
  --success-light: var(--teal-tint);
  --bg: var(--brand-bg);
  --surface: var(--brand-surface);
  --border: var(--brand-rule);
  --text: var(--brand-body-text);
  --text-secondary: var(--brand-subtext);
  --text-muted: var(--brand-subtext);
  --font: var(--font-body);

  /* === Other preserved tokens — left as-is per BIS v1.2 Phase 1 spec === */
  --accent: #F59E0B;
  --accent-light: #FEF3C7;
  --danger: #DC2626;
  --danger-light: #FEE2E2;
  --radius: 16px;
  --shadow: 0 1px 3px rgba(0,0,0,.08), 0 4px 16px rgba(0,0,0,.06);

  /* Earlier brand color aliases (v1.13.0 Phase 1) — kept for any consumers
     still referencing them; later phases consolidate to the BIS v1.2 names above. */
  --color-primary-purple: #6B46A0;
  --color-deep-purple:    #4A2D7A;
  --color-mission-gold:   #A07800;
  --color-learning-teal:  #0D7A72;
  --color-vitality-pink:  #C0396A;

  /* Track colors */
  --finance: #F59E0B;
  --career: #3B82F6;
  --wellness: #10B981;
  --digital: #8B5CF6;
  --civic: #EF4444;
  --core: #7C3AED;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 16px;
  line-height: 1.6;
  color: var(--brand-body-text);
  background: var(--brand-bg);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

/* === DISPLAY UTILITY (opt-in) === */
/* Apply to course titles, section headers, certificate names, emotional
   headlines. NOT applied globally — each surface adds .display deliberately. */

.display {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--vivoso-purple);
  line-height: 1.2;
  letter-spacing: -0.01em;
}

.display--xl { font-size: clamp(2rem, 4vw, 3rem); }
.display--lg { font-size: clamp(1.5rem, 3vw, 2.25rem); }
.display--md { font-size: clamp(1.25rem, 2.5vw, 1.5rem); }
.display--sm { font-size: 1.125rem; }

/* === TAGLINE COMPONENT === */
/* Reserved exclusively for "The life skills nobody taught you."
   Playfair Italic + Mission Gold. Never used for any other phrase. */

.tagline {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 400;
  color: var(--mission-gold);
  letter-spacing: 0.01em;
  line-height: 1.3;
}

.tagline--lg { font-size: clamp(1.25rem, 2.5vw, 1.75rem); }
.tagline--md { font-size: 1.125rem; }
.tagline--sm { font-size: 1rem; }

.tagline--on-dark {
  color: #C9A23A;  /* Brightened gold for Deep Purple surfaces */
}

/* === WORDMARK COMPONENT === */
/* "Vivoso" — Inter SemiBold 600, mixed case, with superscript ™.
   Six approved lockups, matched to surface type. */

.wordmark {
  font-family: var(--font-wordmark);
  font-weight: 600;
  letter-spacing: -0.01em;
  display: inline-block;
  line-height: 1;
  text-transform: none;
  font-style: normal;
}

.wordmark .tm {
  font-size: 0.45em;
  vertical-align: super;
  font-weight: 600;
  margin-left: 0.05em;
  letter-spacing: 0;
}

/* Six approved lockups */
.wordmark--primary-dark   { color: #FFFFFF; }                  /* Deep Purple bg */
.wordmark--primary-light  { color: var(--vivoso-purple); }     /* White/light bg */
.wordmark--reversed       { color: #FFFFFF; }                  /* Vivoso Purple bg */
.wordmark--warm           { color: var(--mission-gold); }      /* Gold tint bg */
.wordmark--minimal        { color: #FFFFFF; }                  /* Black/B&W */
.wordmark--on-surface     { color: var(--vivoso-purple); }     /* Purple Tint card */

/* Size scale */
.wordmark--xl { font-size: clamp(3rem, 8vw, 5rem); }
.wordmark--lg { font-size: clamp(2rem, 5vw, 3rem); }
.wordmark--md { font-size: 1.5rem; }
.wordmark--sm { font-size: 1.125rem; }

/* ---- HEADER ---- */
.app-header {
  /* BIS v1.2 Phase 3 — Deep Purple bar across all surfaces (signed-out
     landing/schools/orgs nav + signed-in app nav). Same height, padding,
     and sticky behavior as before — only color treatment changed. */
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--deep-purple);
  color: #FFFFFF;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  height: 64px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.25rem;
  /* v1.13.0 Phase 1 — wordmark spec: Inter 600, letter-spacing 1px,
     primary purple on light surfaces. */
  font-family: var(--font-wordmark);
  font-weight: 600;
  letter-spacing: 1px;
  color: var(--color-primary-purple);
  cursor: pointer;
  text-decoration: none;
}

.logo-icon { font-size: 1.5rem; }

.header-nav { display: flex; gap: 8px; align-items: center; }

.nav-btn {
  background: none;
  border: 1.5px solid transparent;
  padding: 8px 18px;
  border-radius: 8px;
  font-size: .9rem;
  font-weight: 600;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all .15s;
  font-family: var(--font);
}

.nav-btn:hover { color: var(--primary); background: var(--primary-light); }

.nav-btn-certs {
  color: var(--primary);
  border-color: var(--primary);
}
.nav-btn-certs:hover { background: var(--primary); color: white; }

/* === BIS v1.2 Phase 3 — Top nav children on Deep Purple === */
/* Scoped to .app-header so global .nav-btn / .btn-primary stay unchanged
   for any non-nav reuse elsewhere in the app. */

.app-header .nav-btn {
  color: rgba(255, 255, 255, 0.85);
  font-family: var(--font-body);
  font-weight: 500;
  background: none;
  border-color: transparent;
  transition: color 150ms ease, background 150ms ease;
}
.app-header .nav-btn:hover {
  color: #FFFFFF;
  background: rgba(255, 255, 255, 0.06);
}
.app-header .nav-btn-section.active,
.app-header .nav-btn-profile.active {
  color: #FFFFFF;
  background: rgba(255, 255, 255, 0.10);
  border-color: transparent;
}
.app-header .nav-btn-section.active::after {
  background: #FFFFFF;
}

/* "Get Started" CTA in the signed-out nav — Amber pill, smaller
   than the hero version. */
.app-header .btn-primary {
  background: var(--amber);
  color: #FFFFFF;
  font-family: var(--font-body);
  font-weight: 600;
  border: none;
  border-radius: var(--radius-pill);
  cursor: pointer;
  transition: background 150ms ease;
}
.app-header .btn-primary:hover {
  background: #B8741F;
  color: #FFFFFF;
  transform: none;
  box-shadow: none;
}

/* Hamburger bars — switch from --text (dark) to white on Deep Purple. */
.app-header .nav-hamburger span {
  background: #FFFFFF;
}

/* ---- MAIN ---- */
#app { max-width: 1100px; margin: 0 auto; padding: 32px 20px 80px; }

/* ---- SECTION HEADERS ---- */
.section-header {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin-bottom: 20px;
}

.section-title {
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -0.3px;
}

.section-badge {
  background: var(--border);
  color: var(--text-secondary);
  font-size: .75rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 100px;
  text-transform: uppercase;
  letter-spacing: .5px;
}

/* ---- "Foundations" sub-label inside the Courses section ----
   Visually subordinate to the Courses section header — a navigational
   signpost above the F-course grid, NOT a separate section header. */
.courses-sub-label {
  /* v1.28.5 — Oxford DM Sans 600 uppercase, matches /courses section
     header pattern. Was Vivoso Purple #6B46A0 / 700 weight. */
  font-family: var(--font-body, 'DM Sans', sans-serif);
  font-size: .85rem;
  font-weight: 600;
  color: var(--oxford);
  letter-spacing: 1px;
  text-transform: uppercase;
  margin: 0 0 14px;
}

/* ---- COURSE GRID ---- */
.course-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
  margin-bottom: 48px;
}

.course-card {
  background: var(--surface);
  border-radius: var(--radius);
  border: 1.5px solid var(--border);
  padding: 20px;
  cursor: pointer;
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
  display: flex;
  flex-direction: column;
  gap: 10px;
  position: relative;
  overflow: hidden;
  box-shadow: 0 2px 4px rgba(0,0,0,0.06), 0 4px 12px rgba(0,0,0,0.08);
}

.course-card:hover {
  border-color: var(--track-color, var(--primary));
  transform: translateY(-6px);
  box-shadow: 0 8px 16px rgba(0,0,0,0.10), 0 16px 32px rgba(0,0,0,0.08);
}

.course-card.completed {
  border-color: var(--success);
  background: #FAFFFE;
}

.course-card.is-locked { opacity: .75; }
.course-card.is-locked:hover { opacity: 1; }

.course-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.course-icon {
  display: inline-block;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--text-muted);
  box-shadow: 0 0 0 3px rgba(255,255,255,0.9), 0 2px 6px -2px rgba(17,24,39,.2);
  flex-shrink: 0;
}

.course-id {
  font-size: .7rem;
  font-weight: 800;
  letter-spacing: 1px;
  color: var(--text-muted);
  text-transform: uppercase;
}

.status-badge {
  font-size: .72rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 100px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.status-badge.not-started { background: var(--border); color: var(--text-muted); }
.status-badge.completed { background: var(--success-light); color: var(--success); }
.status-badge.locked { background: #FEF3C7; color: #B45309; padding: 4px 8px; }
.status-badge.free { background: var(--success-light); color: var(--success); }

.lock-icon { display: block; }
.unlock-icon { display: block; }

.status-badge.unlocked { background: var(--success-light); color: var(--success); padding: 4px 8px; }
.elective-status-badge.unlocked { background: var(--success-light); color: var(--success); }

/* Free-tier card blurb (replaces the old <ul> bullet list on both landing and pricing page Free cards). */
.lp-price-free-blurb {
  font-size: .9rem;
  color: var(--text-secondary);
  line-height: 1.5;
  margin: 12px 0 18px;
  padding: 0 6px;
}
.pricing-card-free-blurb {
  font-size: .9rem;
  color: var(--text-secondary);
  line-height: 1.5;
  margin: 12px 0 14px;
  padding: 0 4px;
}

.course-title {
  /* v1.13.0 Phase 2 — display header treatment for course titles. */
  font-size: 1rem;
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--text);
  line-height: 1.3;
  letter-spacing: -0.2px;
}

.course-desc {
  font-size: .83rem;
  color: var(--text-secondary);
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.course-footer {
  margin-top: 4px;
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Limited Time Course card decoration. The card itself reuses .course-card
   so layout and hover behavior stay consistent with cores; these two classes
   add the LT-specific signals (amber badge in the top-right slot, availability
   line under the title). Brand amber gradient — no new color tokens. */
.lt-card-badge {
  display: inline-flex;
  align-items: center;
  font-size: .65rem;
  font-weight: 800;
  letter-spacing: .5px;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 100px;
  background: linear-gradient(135deg, #F59E0B, #D97706);
  color: white;
  white-space: nowrap;
}

.lt-card-availability {
  font-size: .76rem;
  color: var(--text-secondary);
  font-weight: 600;
  font-style: italic;
  margin-top: -4px;
  margin-bottom: 4px;
}

.course-pathways {
  font-size: .72rem;
  color: var(--text-secondary);
  font-style: italic;
  margin-top: 6px;
  line-height: 1.4;
  opacity: .85;
}

/* Elective cards have no parent padding — children handle their own inset.
   Match the 18px horizontal inset used by .elective-card-header and
   .elective-session so "Part of:" aligns with the rest of the card body. */
.elective-card .course-pathways {
  padding: 0 18px 14px;
}

.lesson-header-info .course-pathways {
  margin-top: 4px;
  font-size: .78rem;
}

.track-tag {
  font-size: .7rem;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: 6px;
  background: var(--primary-light);
  color: var(--primary);
}

/* ---- ELECTIVE GRID ---- */
.elective-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 16px;
  margin-bottom: 48px;
}

.elective-card {
  background: var(--surface);
  border-radius: var(--radius);
  border: 1.5px solid var(--border);
  overflow: hidden;
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
  box-shadow: 0 2px 4px rgba(0,0,0,0.06), 0 4px 12px rgba(0,0,0,0.08);
}

.elective-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 8px 16px rgba(0,0,0,0.10), 0 16px 32px rgba(0,0,0,0.08);
}

.elective-card.active {
  border-color: var(--elective-color, var(--primary));
}

.elective-card.coming-soon { opacity: .8; }

.elective-card-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 18px 14px;
  border-bottom: 1px solid var(--border);
  background: color-mix(in srgb, var(--elective-color, var(--primary)) 5%, white);
}

.elective-icon {
  display: inline-block;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--text-muted);
  flex-shrink: 0;
  margin-top: 6px;
  box-shadow: 0 0 0 3px rgba(255,255,255,0.9), 0 2px 6px -2px rgba(17,24,39,.2);
}
.elective-id { font-size: .68rem; font-weight: 800; letter-spacing: 1.2px; text-transform: uppercase; color: var(--text-muted); margin-bottom: 3px; }
.elective-title { font-size: .92rem; font-weight: 700; color: var(--text); line-height: 1.3; }
.elective-session-count { font-size: .7rem; color: var(--text-muted); font-weight: 600; white-space: nowrap; }

.elective-status-badge {
  font-size: .68rem;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 100px;
  text-transform: uppercase;
  letter-spacing: .4px;
  white-space: nowrap;
}

.elective-status-badge.soon { background: var(--border); color: var(--text-muted); }
.elective-status-badge.available { background: var(--success-light); color: var(--success); }
.elective-status-badge.plus { background: #FEF3C7; color: #B45309; }

.elective-sessions { display: flex; flex-direction: column; }

.elective-session {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 18px;
  border-bottom: 1px solid var(--border);
  font-size: .82rem;
  transition: background .12s;
}

.elective-session:last-child { border-bottom: none; }

.elective-session.locked { opacity: .55; cursor: default; }

.elective-session:not(.locked) {
  cursor: pointer;
}

.elective-session:not(.locked):hover {
  background: color-mix(in srgb, var(--elective-color, var(--primary)) 8%, white);
}

.elective-session.done { background: var(--success-light); }
.elective-session.done:hover { background: color-mix(in srgb, var(--success) 12%, white); }

.session-id {
  font-size: .68rem;
  font-weight: 800;
  letter-spacing: .8px;
  color: var(--text-muted);
  flex-shrink: 0;
  min-width: 36px;
}

.session-title {
  flex: 1;
  color: var(--text);
  font-weight: 500;
  line-height: 1.4;
}

.elective-session.done .session-title { color: var(--success); font-weight: 600; }

.session-status {
  font-size: .8rem;
  flex-shrink: 0;
  color: var(--text-muted);
}

.elective-session:not(.locked):hover .session-status { color: var(--elective-color, var(--primary)); }
.elective-session.done .session-status { color: var(--success); }

/* ---- TRACK PROGRESS ---- */
.tracks-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 16px;
  margin-bottom: 48px;
}

.track-card {
  background: var(--surface);
  border-radius: var(--radius);
  border: 1.5px solid var(--border);
  padding: 20px;
  transition: box-shadow .2s;
}

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

.track-card-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
}

.track-icon-wrap {
  width: 44px; height: 44px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  flex-shrink: 0;
}

.track-card-title { font-size: .95rem; font-weight: 700; }
.track-card-sub { font-size: .8rem; color: var(--text-secondary); margin-top: 2px; }

.track-progress-bar {
  height: 8px;
  background: var(--border);
  border-radius: 100px;
  overflow: hidden;
  margin-bottom: 10px;
}

.track-progress-fill {
  height: 100%;
  border-radius: 100px;
  transition: width .6s cubic-bezier(.4,0,.2,1);
}

.track-progress-label {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: .8rem;
}

.track-progress-pct { font-weight: 700; }
.track-progress-count { color: var(--text-secondary); }

.cert-btn {
  width: 100%;
  margin-top: 12px;
  padding: 10px;
  border: none;
  border-radius: var(--radius-sm);
  font-size: .85rem;
  font-weight: 700;
  cursor: pointer;
  transition: all .15s;
  font-family: var(--font);
}

.cert-btn.ready {
  background: linear-gradient(135deg, var(--track-col, var(--primary)), color-mix(in srgb, var(--track-col, var(--primary)) 70%, white));
  color: white;
}

.cert-btn.ready:hover { opacity: .9; transform: translateY(-1px); box-shadow: 0 4px 12px rgba(0,0,0,.15); }

.cert-btn.not-ready {
  background: var(--border);
  color: var(--text-muted);
  cursor: not-allowed;
}

/* ============================================================================
   v1.30.11 — Tier 1 pathway cert card color treatment.
   Replaces the 8px grey progress bar + grey footer pill with a 3px static
   top accent bar plus a self-progress-bar pill. Tier 2 Master Graduate card
   does NOT receive these classes — it keeps its prior .track-progress-*
   markup and CSS unchanged.
   ============================================================================ */
.cert-static-bar {
  height: 3px;
  width: 100%;
  border-radius: 100px;
  margin-bottom: 12px;
}

.cert-certified-label {
  font-size: .8rem;
  font-weight: 700;
}

.cert-progress-pill {
  position: relative;
  overflow: hidden;
  padding: 10px;
  border-radius: var(--radius-sm);
  font-size: .85rem;
  font-weight: 700;
  font-family: var(--font);
  text-align: center;
  cursor: default;
}

.cert-progress-pill-fill {
  position: absolute;
  left: 0;
  top: 0;
  height: 100%;
  transition: width .6s cubic-bezier(.4, 0, .2, 1);
}

.cert-progress-pill-text {
  position: relative;
  z-index: 1;
}

/* FTUX build 2 — in-progress pill is a <button>; reset UA chrome so it looks
   identical to the div form at rest, then add interactive affordances. */
button.cert-progress-pill {
  appearance: none;
  -webkit-appearance: none;
  width: 100%;
  margin: 0;
  border: 1px solid transparent;
  background: transparent;
  text-align: center;
  cursor: pointer;
}
button.cert-progress-pill:hover {
  filter: brightness(.97);
}
button.cert-progress-pill:focus-visible {
  outline: 2px solid var(--steel);
  outline-offset: 2px;
}

/* FTUX build 3 — Three-step journey strip (Courses / Pathways / Certificates).
   Reuses existing brand tokens; no new :root tokens. */
.journey-strip {
  width: 100%;
  background: var(--moonlight-tint);
  border: 1px solid var(--brand-rule);
  border-radius: var(--radius-sm);
  padding: 16px 18px;
  margin-bottom: 20px;
}
.journey-steps {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
}
.journey-step {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: inherit;
  font-size: .9rem;
  font-weight: 600;
  color: var(--steel);
  appearance: none;
  -webkit-appearance: none;
  margin: 0;
  padding: 4px 8px;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  background: transparent;
  cursor: pointer;
}
.journey-step:hover {
  background: var(--moonlight);
  border-color: var(--mist-sage);
}
.journey-step:focus-visible {
  outline: 2px solid var(--steel);
  outline-offset: 2px;
}
.journey-step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  width: 28px;
  height: 28px;
  border-radius: 999px;
  background: var(--mist-sage);
  color: var(--steel);
  font-size: .9rem;
  font-weight: 700;
}
.journey-step-label {
  font-size: .95rem;
  color: var(--text-secondary);
}
.journey-step--active .journey-step-num {
  background: var(--amber);
  color: #fff;
}
.journey-step--active .journey-step-label {
  color: var(--oxford);
  font-weight: 800;
}
.journey-here {
  font-size: .65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .5px;
  color: var(--amber);
}
.journey-arrow {
  color: var(--text-muted);
  font-size: .9rem;
}
.journey-line {
  margin-top: 8px;
  font-size: .8rem;
  color: var(--text-secondary);
}
/* FTUX build 5 — Get Started CTA button pair. Shared box metrics so the amber
   primary and the ghost secondary sit balanced (same height/padding/shape). */
.gs-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: var(--radius-sm);
  font-family: var(--font);
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  transition: all .15s;
  text-decoration: none;
}
.gs-btn-primary {
  background: var(--amber);
  color: #FFFFFF;
  border: 1.5px solid var(--amber);
}
.gs-btn-primary:hover {
  filter: brightness(.95);
  transform: translateY(-1px);
}
.gs-btn-secondary {
  background: transparent;
  color: var(--oxford);
  border: 1.5px solid var(--steel);
}
.gs-btn-secondary:hover {
  background: var(--moonlight-tint);
  border-color: var(--oxford);
}

/* ---- AGE INPUT SCREEN ---- */
.screen-card {
  max-width: 520px;
  margin: 40px auto;
  background: var(--surface);
  border-radius: 24px;
  padding: 40px;
  box-shadow: var(--shadow-lg);
  text-align: center;
}

.screen-card .course-icon-lg {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  margin: 0 auto 16px;
  box-shadow: 0 0 0 6px rgba(255,255,255,0.9), 0 6px 16px -6px rgba(17,24,39,.25);
}
.course-icon-lg {
  display: block;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--text-muted);
}
.screen-card .course-id-tag {
  font-size: .75rem;
  font-weight: 800;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.screen-card h2 { font-size: 1.6rem; font-weight: 800; margin-bottom: 12px; letter-spacing: -0.5px; }
.screen-card .desc { color: var(--text-secondary); margin-bottom: 32px; font-size: .95rem; }

.age-label { font-size: .85rem; font-weight: 700; color: var(--text); margin-bottom: 12px; display: block; text-align: left; }

.age-input {
  width: 100%;
  padding: 14px 18px;
  font-size: 1.1rem;
  font-weight: 600;
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  font-family: var(--font);
  color: var(--text);
  transition: border-color .15s;
  margin-bottom: 24px;
  text-align: center;
  appearance: none;
}

.age-input:focus { outline: none; border-color: var(--primary); }

.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: var(--primary);
  color: white;
  border: none;
  padding: 14px 32px;
  border-radius: var(--radius-sm);
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  transition: all .15s;
  font-family: var(--font);
  text-decoration: none;
}

.btn-primary:hover { background: var(--primary-dark); transform: translateY(-1px); box-shadow: 0 4px 16px rgba(212,136,42,.4); }
.btn-primary:disabled { background: var(--border); color: var(--text-muted); cursor: not-allowed; transform: none; box-shadow: none; }

.btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: transparent;
  color: var(--text-secondary);
  border: 1.5px solid var(--border);
  padding: 12px 24px;
  border-radius: var(--radius-sm);
  font-size: .9rem;
  font-weight: 600;
  cursor: pointer;
  transition: all .15s;
  font-family: var(--font);
}

.btn-secondary:hover { border-color: var(--amber); color: var(--amber); background: transparent; }

/* ============================================================
   v1.14.0 — Pathway Certification (intro / take / results)
   ============================================================ */

/* ---- Intro screen ---- */
.pathway-certification-intro-wrapper {
  max-width: 740px;
  margin: 0 auto;
}
.pathway-certification-intro-header {
  border-radius: var(--radius);
  padding: 28px 26px;
  margin-bottom: 14px;
  text-align: center;
  color: #fff;
}
.pathway-certification-intro-header-icon {
  display: flex;
  justify-content: center;
  margin-bottom: 12px;
}
.pathway-certification-intro-eyebrow {
  display: inline-block;
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  opacity: .85;
  margin-bottom: 6px;
}
.pathway-certification-intro-header h2 {
  font-size: 1.5rem;
  font-family: var(--font-display);
  font-weight: 800;
  margin: 0;
  letter-spacing: -0.3px;
  color: #fff;
}
.pathway-certification-intro-meta {
  color: var(--text-secondary);
  font-size: .9rem;
  margin: 0 0 18px;
  text-align: center;
}
.pathway-certification-intro-card {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  margin-bottom: 24px;
  overflow: hidden;
}
.pathway-certification-intro-card-headline {
  padding: 22px 28px 14px;
}
.pathway-certification-intro-card-headline h3 {
  font-size: 1.15rem;
  font-weight: 800;
  margin: 0;
}
.pathway-certification-intro-card-body {
  padding: 0 28px 8px;
  color: var(--text);
  font-size: .98rem;
  line-height: 1.55;
}
.pathway-certification-intro-card-body p { margin: 0 0 8px; }
.pathway-certification-intro-score-line {
  margin: 12px 0 0;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  font-size: .9rem;
  font-weight: 700;
}
.pathway-certification-intro-score-line.passed {
  background: var(--success-light);
  color: var(--success);
}
.pathway-certification-intro-score-line.failed {
  background: var(--bg);
  color: var(--text-secondary);
  border: 1px solid var(--border);
}
.pathway-certification-intro-state-note {
  margin: 12px 0 0;
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  background: #FFFBEB;
  border: 1px solid #FCD34D;
  color: #78350F;
  font-size: .9rem;
  line-height: 1.5;
}
.pathway-certification-intro-actions {
  display: flex;
  gap: 12px;
  padding: 18px 28px 24px;
  flex-wrap: wrap;
}
.pathway-certification-intro-actions .btn-primary,
.pathway-certification-intro-actions .btn-secondary { flex: 1; }
@media (max-width: 600px) {
  .pathway-certification-intro-header { padding: 22px 18px; }
  .pathway-certification-intro-header h2 { font-size: 1.3rem; }
  .pathway-certification-intro-card-headline { padding: 18px 20px 10px; }
  .pathway-certification-intro-card-body { padding: 0 20px 6px; font-size: .95rem; }
  .pathway-certification-intro-actions { padding: 14px 20px 20px; }
}

/* ---- Take screen ---- */
.pathway-certification-take-wrapper {
  max-width: 740px;
  margin: 0 auto;
  padding-bottom: 96px;
}
.pathway-certification-take-loading {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 48px 24px;
  margin-bottom: 24px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}
.pathway-certification-take-loading-msg {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text);
  margin: 0;
}
.pathway-certification-take-loading-sub {
  font-size: .88rem;
  color: var(--text-secondary);
  margin: 0;
  max-width: 380px;
}
.pathway-certification-take-error {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 32px 28px;
  margin-bottom: 24px;
  text-align: center;
}
.pathway-certification-take-error h3 {
  margin: 0 0 8px;
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--danger);
}
.pathway-certification-take-error p {
  margin: 0 auto 20px;
  max-width: 440px;
  color: var(--text-secondary);
  font-size: .92rem;
  line-height: 1.5;
}
.pathway-certification-take-error-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}
.pathway-certification-take-instructions {
  color: var(--text-secondary);
  font-size: .92rem;
  line-height: 1.5;
  margin: 0 0 12px;
  text-align: center;
}
.pathway-certification-progress {
  text-align: center;
  font-size: .8rem;
  font-weight: 700;
  color: var(--text-secondary);
  letter-spacing: .04em;
  text-transform: uppercase;
  margin-bottom: 18px;
}
.pathway-certification-questions {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.pathway-certification-question {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 22px 24px;
}
.pathway-certification-question-num {
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 6px;
}
.pathway-certification-question-text {
  font-size: 1rem;
  font-weight: 700;
  margin: 0 0 14px;
  line-height: 1.45;
}
.pathway-certification-choices {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.pathway-certification-choice {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  min-height: 48px;
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px 16px;
  font-family: var(--font);
  font-size: .95rem;
  font-weight: 600;
  color: var(--text);
  text-align: left;
  cursor: pointer;
  transition: border-color .15s, background .15s;
}
.pathway-certification-choice:hover { border-color: var(--text-secondary); }
.pathway-certification-choice .pathway-certification-choice-text { flex: 1; min-width: 0; }
.pathway-certification-choice .pathway-certification-choice-check {
  font-size: 1rem;
  color: var(--success);
  font-weight: 800;
  opacity: 0;
  flex-shrink: 0;
  transition: opacity .15s;
}
.pathway-certification-choice.selected {
  background: var(--success-light);
  border-color: var(--success);
  color: var(--success);
}
.pathway-certification-choice.selected .pathway-certification-choice-check { opacity: 1; }
.pathway-certification-submit-bar {
  position: sticky;
  bottom: 0;
  left: 0;
  right: 0;
  margin: 24px -16px 0;
  padding: 14px 16px;
  background: var(--surface);
  border-top: 1.5px solid var(--border);
  display: flex;
  justify-content: center;
  z-index: 20;
}
.pathway-certification-submit-btn {
  width: 100%;
  max-width: 440px;
}
.pathway-certification-submit-btn.is-disabled,
.pathway-certification-submit-btn:disabled {
  background: var(--border);
  color: var(--text-muted);
  cursor: not-allowed;
  box-shadow: none;
  transform: none;
}

/* ---- Results screen ---- */
.pathway-certification-results-wrapper {
  max-width: 740px;
  margin: 0 auto;
}
.pathway-certification-results-breadcrumb {
  text-align: center;
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--text-muted);
  margin: 0 0 18px;
}
.pathway-certification-results-headline-card {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 32px 28px;
  margin-bottom: 24px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}
.pathway-certification-results-headline-card.pass {
  background: var(--success-light);
  border-color: var(--success);
}
.pathway-certification-results-icon {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 4px;
}
.pathway-certification-results-icon.pass { background: var(--success); color: #fff; }
.pathway-certification-results-icon.pass svg { width: 30px; height: 30px; }
.pathway-certification-results-icon.fail {
  background: transparent;
  border: 2px solid var(--text-muted);
  color: var(--text-muted);
}
.pathway-certification-results-icon.fail svg { width: 26px; height: 26px; }
.pathway-certification-results-title {
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: -0.3px;
  margin: 4px 0 6px;
}
.pathway-certification-results-headline-card.pass .pathway-certification-results-title { color: var(--success); }
.pathway-certification-results-sub {
  font-size: 1rem;
  color: var(--text);
  margin: 0;
}
.pathway-certification-results-note-positive {
  font-size: .95rem;
  color: var(--success);
  font-weight: 700;
  margin: 8px 0 0;
}
.pathway-certification-results-encouragement {
  font-size: .92rem;
  color: var(--text-secondary);
  margin: 6px 0 0;
  line-height: 1.5;
}
.pathway-certification-review { margin-bottom: 24px; }
.pathway-certification-review-heading {
  font-size: 1.05rem;
  font-weight: 800;
  margin: 0 0 14px;
  letter-spacing: -0.1px;
}
.pathway-certification-review-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.pathway-certification-review-item {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 22px 24px;
}
.pathway-certification-review-item.correct { border-left: 4px solid var(--success); }
.pathway-certification-review-item.incorrect { border-left: 4px solid var(--text-muted); }
.pathway-certification-review-item-num {
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 6px;
}
.pathway-certification-review-item-question {
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.45;
  margin-bottom: 14px;
}
.pathway-certification-review-choices {
  list-style: none;
  padding: 0;
  margin: 0 0 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.pathway-certification-review-choice {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 14px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  font-size: .94rem;
  color: var(--text);
}
.pathway-certification-review-choice.is-correct {
  background: var(--success-light);
  border-color: var(--success);
  color: var(--success);
  font-weight: 600;
}
.pathway-certification-review-choice.is-selected:not(.is-correct) {
  background: var(--bg);
  border-color: var(--text-muted);
  color: var(--text);
}
.pathway-certification-review-choice-text { flex: 1; min-width: 0; }
.pathway-certification-review-choice-tag {
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: .04em;
  text-transform: uppercase;
  padding: 3px 8px;
  border-radius: 100px;
  flex-shrink: 0;
  background: rgba(0,0,0,0.06);
  color: var(--text-secondary);
}
.pathway-certification-review-choice.is-correct .pathway-certification-review-choice-tag {
  background: var(--success);
  color: #fff;
}
.pathway-certification-review-choice.is-selected:not(.is-correct) .pathway-certification-review-choice-tag {
  background: var(--text-muted);
  color: #fff;
}
.pathway-certification-review-compact {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 16px;
}
.pathway-certification-review-row {
  padding: 12px 14px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
}
.pathway-certification-review-row.is-correct {
  background: var(--success-light);
  border-color: var(--success);
}
.pathway-certification-review-row.is-selected {
  background: var(--bg);
  border-color: var(--text-muted);
}
.pathway-certification-review-row-label {
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 4px;
}
.pathway-certification-review-row.is-correct .pathway-certification-review-row-label { color: var(--success); }
.pathway-certification-review-row-value {
  font-size: .95rem;
  color: var(--text);
  line-height: 1.4;
}
.pathway-certification-review-row.is-correct .pathway-certification-review-row-value {
  color: var(--success);
  font-weight: 600;
}
.pathway-certification-review-explanation {
  background: var(--bg);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
}
.pathway-certification-review-explanation-label {
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 4px;
}
.pathway-certification-review-explanation p {
  font-size: .9rem;
  color: var(--text);
  line-height: 1.5;
  margin: 0;
}
.pathway-certification-results-actions {
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 24px;
}
.pathway-certification-results-actions .btn-primary,
.pathway-certification-results-actions .btn-secondary { min-width: 200px; }

@media (max-width: 600px) {
  .pathway-certification-take-wrapper { padding-bottom: 88px; }
  .pathway-certification-question { padding: 18px 18px; }
  .pathway-certification-question-text { font-size: .95rem; }
  .pathway-certification-choice { font-size: .92rem; padding: 12px 14px; min-height: 52px; }
  .pathway-certification-submit-bar { margin: 18px -12px 0; padding: 12px 12px; }
  .pathway-certification-results-headline-card { padding: 26px 18px; }
  .pathway-certification-results-title { font-size: 1.3rem; }
  .pathway-certification-results-sub { font-size: .95rem; }
  .pathway-certification-review-item { padding: 18px 18px; }
  .pathway-certification-review-item-question { font-size: .95rem; }
  .pathway-certification-review-choice { font-size: .9rem; }
  .pathway-certification-results-actions { flex-direction: column; }
  .pathway-certification-results-actions .btn-primary,
  .pathway-certification-results-actions .btn-secondary { width: 100%; min-width: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .pathway-certification-choice,
  .pathway-certification-choice .pathway-certification-choice-check,
  .pathway-certification-results-headline-card,
  .pathway-certification-review-item { transition: none; }
}

/* ---- Cert "just earned" highlight after View certificate navigation ---- */
.cert-card-just-earned,
.master-cert-card.cert-card-just-earned {
  animation: cert-just-earned-flash 2.4s ease;
}
@keyframes cert-just-earned-flash {
  0%   { box-shadow: 0 0 0 0 rgba(16,185,129,0); }
  20%  { box-shadow: 0 0 0 8px rgba(16,185,129,.45); }
  100% { box-shadow: 0 0 0 0 rgba(16,185,129,0); }
}

/* ---- Certificate celebration overlay ---- */
.cert-celebration-overlay {
  position: fixed;
  inset: 0;
  background: rgba(17, 24, 39, 0.78);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px 16px;
  z-index: 9999;
  opacity: 0;
  transition: opacity .32s ease;
  overscroll-behavior: contain;
}
.cert-celebration-overlay.visible { opacity: 1; }
.cert-celebration-card {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 36px 36px 28px;
  max-width: 520px;
  width: 100%;
  text-align: center;
  box-shadow: 0 20px 60px rgba(0,0,0,.35);
  transform: scale(0.95);
  opacity: 0;
  transition: transform .6s cubic-bezier(.2,.8,.2,1), opacity .6s ease;
  max-height: calc(100vh - 48px);
  overflow-y: auto;
}
.cert-celebration-overlay.visible .cert-celebration-card {
  transform: scale(1);
  opacity: 1;
}
.cert-celebration-headline {
  font-size: 1.4rem;
  font-family: var(--font-display);
  font-weight: 700;
  margin: 0 0 18px;
  letter-spacing: -0.3px;
  line-height: 1.25;
  color: var(--text);
  line-height: 1.3;
}
.cert-celebration-medallion {
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 18px;
  min-height: 200px;
}
.cert-celebration-sub {
  font-size: 1rem;
  color: var(--text-secondary);
  line-height: 1.5;
  margin: 0 0 22px;
}
.cert-celebration-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}
.cert-celebration-actions .btn-primary,
.cert-celebration-actions .btn-secondary { min-width: 160px; }

@media (max-width: 600px) {
  .cert-celebration-card { padding: 28px 22px 22px; }
  .cert-celebration-headline { font-size: 1.1rem; }
  .cert-celebration-medallion { min-height: 150px; }
  .cert-celebration-medallion svg { width: 150px; height: 150px; }
  .cert-celebration-sub { font-size: .92rem; }
  .cert-celebration-actions { flex-direction: column; }
  .cert-celebration-actions .btn-primary,
  .cert-celebration-actions .btn-secondary { width: 100%; min-width: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .cert-celebration-overlay { transition: opacity .15s linear; }
  .cert-celebration-card { transition: opacity .15s linear; transform: none; }
  .cert-celebration-overlay.visible .cert-celebration-card { transform: none; }
  .cert-card-just-earned { animation: none; box-shadow: 0 0 0 4px rgba(16,185,129,.45); }
}

/* ============================================================
   v1.12 Phase B5 — Badges (toast notifications + Profile section)
   ============================================================ */

/* Lower-right toast stack — lives on document.body so it survives every
   re-render. Stacks vertically with oldest at top; each toast independently
   auto-dismisses after 3s. */
.badge-toast-stack {
  position: fixed;
  right: 24px;
  bottom: 24px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  z-index: 10000;
  pointer-events: none; /* let the rest of the UI stay interactive */
}
.badge-toast {
  width: 320px;
  max-width: calc(100vw - 48px);
  background: var(--success-light);
  border: 1.5px solid var(--success);
  border-radius: var(--radius);
  padding: 14px 16px 14px 14px;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  position: relative;
  box-shadow: 0 8px 24px rgba(0,0,0,.12);
  pointer-events: auto;
  opacity: 0;
  transform: translateY(12px);
  transition: opacity .28s ease, transform .28s cubic-bezier(.2,.8,.2,1);
}
.badge-toast.visible {
  opacity: 1;
  transform: translateY(0);
}
.badge-toast-icon {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--surface);
  border-radius: 50%;
  color: var(--success);
  font-weight: 800;
  font-size: 1rem;
  box-shadow: inset 0 0 0 1px rgba(0,0,0,.04);
}
.badge-toast-icon svg { width: 24px; height: 24px; }
.badge-toast-body {
  flex: 1;
  min-width: 0;
  padding-right: 18px; /* clearance for the close X */
}
.badge-toast-eyebrow {
  font-size: .68rem;
  font-weight: 800;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--success);
  margin-bottom: 2px;
}
.badge-toast-title {
  font-size: .92rem;
  font-weight: 700;
  color: var(--text);
  line-height: 1.35;
}
.badge-toast-close {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 32px;
  height: 32px;
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 1.4rem;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
  border-radius: 6px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.badge-toast-close:hover { background: rgba(0,0,0,.05); color: var(--text); }

@media (max-width: 600px) {
  .badge-toast-stack { right: 16px; bottom: 16px; left: 16px; }
  .badge-toast { width: auto; max-width: 100%; }
  .badge-toast-close { width: 44px; height: 44px; top: 4px; right: 4px; font-size: 1.5rem; }
  .badge-toast-body { padding-right: 36px; }
}

@media (prefers-reduced-motion: reduce) {
  .badge-toast { transition: opacity .15s linear; transform: none; }
  .badge-toast.visible { transform: none; }
}

/* ---- Profile page badge section ---- */
/* v1.28.41 — BIS v1.3 achievement treatment. Outer container keeps a Steel
   1.5px border for hierarchy; inner badge cards use a 1.5px Amber border
   on a white surface so each earned badge reads as an achievement card. */
.profile-badges-section {
  background: #ffffff;
  border: 1.5px solid var(--steel);
}
.profile-badges-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}
.profile-badges-header h2 { margin: 0; }
.profile-badges-count {
  font-size: .85rem;
  font-weight: 700;
  color: var(--text-secondary);
  letter-spacing: .02em;
}
.profile-badges-empty {
  color: var(--text-secondary);
  font-size: .92rem;
  line-height: 1.5;
  margin: 0;
}
.profile-badges-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.profile-badge-row {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 12px 14px;
  background: #ffffff;
  border: 1.5px solid var(--amber);
  border-radius: var(--radius-sm);
}
.profile-badge-icon {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.profile-badge-icon svg { width: 36px; height: 36px; }
.profile-badge-body {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.profile-badge-title {
  font-size: .96rem;
  font-weight: 700;
  color: var(--text);
  line-height: 1.35;
}
.profile-badge-meta {
  font-size: .75rem;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--text-muted);
}
.profile-badge-date {
  font-size: .82rem;
  color: var(--text-secondary);
  margin-top: 2px;
}
@media (max-width: 600px) {
  .profile-badge-row { padding: 12px; }
  .profile-badge-title { font-size: .92rem; }
}

/* ---- LESSON SCREEN ---- */
.lesson-wrapper {
  max-width: 740px;
  margin: 0 auto;
}

.lesson-header {
  background: var(--surface);
  border-radius: var(--radius);
  border: 1.5px solid var(--border);
  padding: 24px 28px;
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  gap: 16px;
}

.lesson-header-icon {
  display: inline-block;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--text-muted);
  box-shadow: 0 0 0 4px rgba(255,255,255,0.9), 0 3px 10px -3px rgba(17,24,39,.22);
  flex-shrink: 0;
}
.lesson-header-info { flex: 1; }
.lesson-header-info h2 { font-size: 1.3rem; font-family: var(--font-display); font-weight: 700; letter-spacing: -0.3px; line-height: 1.25; margin-bottom: 4px; }
.lesson-header-info p { font-size: .85rem; color: var(--text-secondary); }

.lesson-age-badge {
  background: var(--primary-light);
  color: var(--primary);
  font-size: .8rem;
  font-weight: 700;
  padding: 6px 14px;
  border-radius: 100px;
  flex-shrink: 0;
}

.lesson-body {
  background: var(--surface);
  border-radius: var(--radius);
  border: 1.5px solid var(--border);
  padding: 36px 40px;
  margin-bottom: 24px;
  min-height: 300px;
}

/* v1.11.3 — "What you'll learn" outline panel. Renders immediately on
   course click (no API call) so the user sees what's coming while Section 1
   generates in the background. Persists above the section content for the
   lifetime of the lesson view. */
.lesson-outline {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 22px 26px;
  margin-bottom: 24px;
}
.lesson-outline-heading {
  font-size: 1rem;
  font-weight: 800;
  margin: 0 0 14px;
  letter-spacing: .01em;
}
.lesson-outline-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
  counter-reset: outline-step;
}
.lesson-outline-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  counter-increment: outline-step;
}
.lesson-outline-item::before {
  content: counter(outline-step);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--primary-light);
  color: var(--primary);
  font-size: .8rem;
  font-weight: 800;
  flex-shrink: 0;
  margin-top: 1px;
}
.lesson-outline-item-body { flex: 1; min-width: 0; }
.lesson-outline-item-title {
  font-weight: 700;
  font-size: .92rem;
  line-height: 1.35;
}
.lesson-outline-item-desc {
  font-size: .84rem;
  color: var(--text-secondary);
  line-height: 1.4;
  margin-top: 2px;
}
@media (max-width: 600px) {
  .lesson-outline { padding: 18px 18px; }
  .lesson-outline-heading { font-size: .95rem; }
  .lesson-outline-item-title { font-size: .9rem; }
  .lesson-outline-item-desc { font-size: .82rem; }
}

/* Markdown styles inside lesson */
.lesson-body h1, .lesson-body h2, .lesson-body h3 {
  font-weight: 800;
  letter-spacing: -0.3px;
  margin-top: 28px;
  margin-bottom: 12px;
  color: var(--text);
}
.lesson-body h1 { font-size: 1.5rem; margin-top: 0; }
.lesson-body h2 { font-size: 1.2rem; color: var(--primary); }
.lesson-body h3 { font-size: 1rem; }
.lesson-body p { margin-bottom: 16px; line-height: 1.75; }
.lesson-body ul, .lesson-body ol { margin-bottom: 16px; padding-left: 24px; }
.lesson-body li { margin-bottom: 8px; line-height: 1.65; }
.lesson-body strong { font-weight: 700; color: var(--text); }
.lesson-body em { font-style: italic; }
.lesson-body blockquote {
  border-left: 4px solid var(--primary);
  padding: 12px 20px;
  margin: 20px 0;
  background: var(--primary-light);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  color: var(--primary-dark);
  font-style: italic;
}

/* ---- Concept Callout Box ---- */
.concept-callout {
  background: linear-gradient(135deg, #ECFDF5 0%, #F0FDF4 100%);
  border-left: 4px solid #1D9E75;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  padding: 18px 22px;
  margin: 20px 0;
  box-shadow: 0 1px 4px rgba(29,158,117,.08);
}

.concept-callout-name {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: .88rem;
  font-weight: 800;
  color: #1D9E75;
  text-transform: uppercase;
  letter-spacing: .4px;
  margin-bottom: 6px;
}
.concept-callout-name::before {
  content: '';
  display: inline-block;
  width: 7px; height: 7px;
  background: #1D9E75;
  border-radius: 50%;
  flex-shrink: 0;
}

.concept-callout-desc {
  font-size: .9rem;
  color: #1F2937;
  line-height: 1.65;
  font-weight: 500;
}

/* ---- In-lesson sensitive-topic disclaimer ---- */
.lesson-disclaimer {
  background-color: #fff8e6;
  border-left: 4px solid #f59e0b;
  border-radius: 8px;
  padding: 14px 16px;
  margin: 24px 0 8px 0;
  font-size: 0.88rem;
  color: #4b5563;
  line-height: 1.6;
}

.disclaimer-label {
  font-weight: 700;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #b45309;
  margin-right: 6px;
}

/* ---- Share Your Win ---- */
.share-win-section {
  margin: 28px auto 0;
  max-width: 640px;
  text-align: center;
}
.share-win-heading {
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-secondary);
  margin-bottom: 12px;
}
.share-win-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
}
.share-win-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  background: transparent;
  color: var(--text-secondary);
  border: 1.5px solid var(--border);
  padding: 10px 16px;
  min-height: 44px;
  border-radius: var(--radius-sm);
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  font-family: var(--font);
  transition: border-color .15s, color .15s, background .15s;
  text-decoration: none;
}
.share-win-btn:hover {
  border-color: var(--amber);
  color: var(--amber);
  background: transparent;
}
.share-win-btn.copied {
  border-color: var(--success);
  color: var(--success);
  background: #ecfdf5;
}
@media (max-width: 767px) {
  /* On mobile, stack the three share buttons full-width so each one is a
     big tap target with no risk of accidental taps between them. */
  .share-win-row {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }
  .share-win-btn {
    width: 100%;
    min-height: 48px;
    font-size: .88rem;
    padding: 12px 16px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .share-win-btn { transition: none; }
}

/* ---- Course Rating ---- */
.rating-section {
  margin: 24px auto 0;
  max-width: 520px;
  text-align: center;
  padding: 18px 20px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.rating-heading {
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-secondary);
  margin-bottom: 10px;
}
.rating-stars {
  display: inline-flex;
  gap: 2px;
  margin-bottom: 10px;
}
.rating-star {
  background: transparent;
  border: none;
  padding: 6px 4px;
  min-width: 40px;
  min-height: 40px;
  font-size: 28px;
  line-height: 1;
  color: #d1d5db;
  cursor: pointer;
  font-family: inherit;
  transition: color .15s, transform .15s;
}
.rating-star:hover { transform: scale(1.08); }
.rating-star.filled { color: #f59e0b; }
.rating-stars.readonly .rating-star { cursor: default; }
.rating-stars.readonly .rating-star:hover { transform: none; }
.rating-comment {
  display: block;
  width: 100%;
  margin: 8px 0 10px;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-family: var(--font);
  font-size: 0.88rem;
  color: var(--text);
  resize: vertical;
  background: white;
}
.rating-comment:focus {
  outline: none;
  border-color: var(--amber);
}
.rating-submit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  background: var(--amber);
  color: white;
  border: 1.5px solid var(--amber);
  padding: 11px 20px;
  min-height: 44px;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
  font-family: var(--font);
  transition: background .15s, border-color .15s;
}
.rating-submit:hover { background: #B8741F; border-color: #B8741F; }
.rating-thanks {
  font-size: 0.88rem;
  color: var(--text-secondary);
  margin-top: 4px;
}
@media (max-width: 767px) {
  /* Mobile — bump star tap targets to a full 44px minimum (they were
     already ~48×52 due to padding, but make the minimum explicit) and
     give the comment textarea full width. */
  .rating-section { padding: 16px 16px; }
  .rating-star {
    min-width: 44px;
    min-height: 44px;
    padding: 8px 6px;
    font-size: 30px;
  }
  .rating-stars { gap: 4px; }
  .rating-comment {
    width: 100%;
    font-size: 16px; /* prevents iOS auto-zoom on focus */
    padding: 12px 14px;
  }
  .rating-submit {
    width: 100%;
    max-width: 260px;
    min-height: 48px;
    font-size: .9rem;
  }
}
@media (prefers-reduced-motion: reduce) {
  .rating-star, .rating-submit { transition: none; }
  .rating-star:hover { transform: none; }
}

/* ---- Takeaway Summary Card ---- */
/* Clean, infographic-style card at the end of every lesson.
   Uses Vivoso green (#1D9E75) as primary accent. Designed to look
   good enough to screenshot and share. */
.takeaway-card {
  position: relative;
  margin: 40px 0 16px;
  padding: 0;
  background: #fff;
  border: 1.5px solid #D1FAE5;
  border-radius: 20px;
  box-shadow:
    0 20px 50px -20px rgba(29,158,117,.18),
    0 4px 12px -4px rgba(29,158,117,.08);
  overflow: hidden;
}

.takeaway-card > * { position: relative; }

.takeaway-card-head {
  background: linear-gradient(135deg, #1D9E75 0%, #16A34A 100%);
  padding: 28px 32px 24px;
  text-align: center;
}

.takeaway-star {
  width: 32px;
  height: 32px;
  fill: rgba(255,255,255,.9);
  margin: 0 auto 10px;
  display: block;
  filter: drop-shadow(0 2px 4px rgba(0,0,0,.15));
}

.takeaway-card-title {
  margin: 0;
  font-size: 1.45rem;
  line-height: 1.25;
  font-weight: 900;
  color: #fff;
  letter-spacing: -.02em;
}

.takeaway-card-sub {
  margin: 6px 0 0;
  font-size: .85rem;
  font-weight: 600;
  color: rgba(255,255,255,.75);
}

.takeaway-card-items {
  list-style: none;
  margin: 0;
  padding: 24px 28px;
  display: flex;
  flex-direction: column;
  gap: 0;
}

.takeaway-item {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 16px 0;
  border-bottom: 1px solid #F0FDF4;
}
.takeaway-item:last-child { border-bottom: none; }

.takeaway-check {
  flex-shrink: 0;
  width: 22px;
  height: 22px;
  margin-top: 1px;
}
.takeaway-check circle { fill: #1D9E75; }

.takeaway-text {
  flex: 1;
  font-size: .93rem;
  line-height: 1.6;
  color: #1F2937;
  font-weight: 500;
}

.takeaway-disclaimer {
  font-family: 'DM Sans', var(--font);
  font-size: 10px;
  font-style: italic;
  color: #6B6878;
  text-align: center;
  margin: 0 0 8px;
  padding: 0 28px;
  line-height: 1.5;
}

.takeaway-card-footer {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 16px 28px;
  background: #F0FDF4;
  border-top: 1px solid #D1FAE5;
}

.takeaway-card-brand {
  font-size: .85rem;
  font-weight: 900;
  color: #1D9E75;
  letter-spacing: -.01em;
}

.takeaway-card-sep {
  color: #A7F3D0;
  font-weight: 700;
}

.takeaway-card-tagline {
  /* v1.13.0 Phase 2 — Phase 1 contrast fix: subtle warm tint behind the
     tagline so Mission Gold reads cleanly against the white card. Inline
     padded pill, doesn't disrupt surrounding card layout. */
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 400;
  font-size: .78rem;
  color: var(--color-mission-gold);
  background: rgba(160, 120, 0, 0.08);
  padding: 3px 10px;
  border-radius: 6px;
  display: inline-block;
}

/* Secondary action row (Print + Download) at the very bottom of the card. */
.takeaway-card-print-row {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  padding: 14px 28px 20px;
  background: #F0FDF4;
  border-top: 1px dashed #D1FAE5;
}
/* Fallback body shown when Haiku returned the takeaway section as
   paragraphs instead of a bullet list — the card still renders, with
   the raw parsed markdown inside. */
.takeaway-card-items--fallback {
  padding: 20px 28px;
  color: #1F2937;
  font-size: .95rem;
  line-height: 1.65;
}
.takeaway-card-items--fallback p { margin-bottom: 10px; }
.takeaway-card-items--fallback ol,
.takeaway-card-items--fallback ul { margin-left: 20px; margin-bottom: 10px; }
.takeaway-print-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font);
  font-size: .82rem;
  font-weight: 700;
  color: #1D9E75;
  background: transparent;
  border: 1.5px solid #1D9E75;
  border-radius: 100px;
  padding: 10px 18px;
  min-height: 44px;
  cursor: pointer;
  transition: background .15s ease, color .15s ease, box-shadow .15s ease;
}
.takeaway-print-btn:hover,
.takeaway-print-btn:focus-visible {
  background: #1D9E75;
  color: #fff;
  box-shadow: 0 3px 12px rgba(29,158,117,.3);
  outline: none;
}
.takeaway-print-icon { display: none; }

@media (max-width: 600px) {
  .takeaway-card { margin: 32px 0 12px; border-radius: 16px; }
  .takeaway-card-head { padding: 22px 20px 18px; }
  .takeaway-star { width: 26px; height: 26px; }
  .takeaway-card-title { font-size: 1.2rem; }
  .takeaway-card-items { padding: 18px 20px; }
  .takeaway-item { padding: 14px 0; gap: 12px; }
  .takeaway-check { width: 20px; height: 20px; }
  .takeaway-text { font-size: .88rem; }
  .takeaway-card-footer { padding: 14px 20px; flex-wrap: wrap; justify-content: center; }
  .takeaway-card-print-row { padding: 12px 16px 16px; }
  .takeaway-print-btn {
    font-size: .78rem;
    padding: 10px 18px;
    min-height: 44px;
    width: 100%;
    max-width: 260px;
  }
}

/* ---- Lesson Completion Celebration ----
   Lightweight warm moment that renders directly below the takeaway card on
   section 5. Light Vivoso green tint; a gentle fade-in on mount, skipped
   under prefers-reduced-motion. Stacks cleanly on narrow viewports. The
   share buttons reuse .share-win-section (see above); the share heading
   serves as the "Share your win:" label so no duplicate label is rendered. */
.lesson-celebration-card {
  position: relative;
  margin: 20px 0 8px;
  padding: 28px 32px 32px;
  background: #F0FDF4;
  border: 1.5px solid #D1FAE5;
  border-radius: 20px;
  text-align: center;
  animation: lesson-celebration-fade-in .45s ease both;
}
@keyframes lesson-celebration-fade-in {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: none; }
}
.celebration-headline {
  margin: 0;
  font-size: 1.6rem;
  font-weight: 900;
  letter-spacing: -.02em;
  color: #1D9E75;
  line-height: 1.2;
}
.celebration-sub {
  margin: 6px 0 0;
  font-size: .95rem;
  color: var(--text-secondary);
}
.celebration-rating { margin-top: 22px; }
/* v1.15.6 — Single instructional headline above the 5-star widget.
   Replaces the prior "How was this lesson?" label + "Disliked/Loved"
   scale row. Body color (not subtext gray) so it reads as a directive. */
.celebration-rating-instruction {
  font-family: var(--font);
  font-size: 14.5px;
  font-weight: 500;
  color: var(--text);
  text-align: center;
  margin: 0 auto 12px;
  line-height: 1.4;
}
.celebration-stars {
  display: inline-flex;
  gap: 4px;
  justify-content: center;
}
.celebration-star {
  position: relative;
  background: transparent;
  border: none;
  padding: 4px;
  min-width: 44px;
  min-height: 44px;
  font-size: 36px;
  line-height: 1;
  color: #d1d5db;
  cursor: pointer;
  font-family: inherit;
  transition: color .15s ease, transform .15s ease;
}
.celebration-star:hover { transform: scale(1.08); }
.celebration-star:focus-visible {
  outline: 2px solid #1D9E75;
  outline-offset: 2px;
  border-radius: 6px;
}
.celebration-star.filled { color: #1D9E75; }
/* The unicode ★ glyph is the visible star; the number is layered atop
   it absolutely-centered. The button itself stays the click target so
   pointer events on the number forward to the button via inherit. */
.celebration-star-glyph {
  display: inline-block;
  line-height: 1;
}
.celebration-star-number {
  position: absolute;
  top: 50%;
  left: 50%;
  /* Nudge ~10% down because the ★ glyph's optical center sits a touch
     below its bounding-box center (typography quirk). */
  transform: translate(-50%, -42%);
  font-family: var(--font);
  font-size: 13px;
  font-weight: 600;
  line-height: 1;
  color: #1F1B2E;
  pointer-events: none;
  text-shadow: 0 0 2px rgba(255, 255, 255, 0.85);
}
.celebration-star.filled .celebration-star-number {
  color: #fff;
  text-shadow: 0 0 2px rgba(0, 0, 0, 0.35);
}

.celebration-share { margin-top: 22px; }
/* Neutralize the standalone margin on .share-win-section when it is nested
   inside the celebration card — the card already controls its own spacing. */
.celebration-share .share-win-section { margin-top: 0; }

@media (max-width: 600px) {
  .lesson-celebration-card {
    margin: 16px 0 8px;
    padding: 22px 18px 24px;
    border-radius: 16px;
  }
  .celebration-headline { font-size: 1.3rem; }
  .celebration-sub { font-size: .88rem; }
  .celebration-rating { margin-top: 18px; }
  .celebration-share { margin-top: 18px; }
  .celebration-stars { gap: 6px; }
  .celebration-star { font-size: 32px; }
  .celebration-star-number { font-size: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  .lesson-celebration-card { animation: none; }
  .celebration-star { transition: none; }
  .celebration-star:hover { transform: none; }
}

/* ---- v1.25.0 — Post-completion routing ("What's next?") ----
   Sits inside .lesson-celebration-card below the share buttons. Styled to
   feel like a continuation of the celebration moment, not a separate
   surface — same green tint, no new card, just a soft top divider. */
.whats-next-section {
  margin-top: 26px;
  padding-top: 22px;
  border-top: 1px solid #D1FAE5;
  text-align: center;
}
.whats-next-acknowledgment {
  margin: 0 0 14px;
  font-family: 'DM Sans', var(--font);
  font-size: 1.05rem;
  font-weight: 500;
  color: var(--text);
  line-height: 1.4;
}
.whats-next-heading {
  margin: 0 0 16px;
  font-family: 'Playfair Display', Georgia, serif;
  font-weight: 700;
  font-size: 1.2rem;
  color: var(--vivoso-purple);
  line-height: 1.2;
}
.whats-next-ctas {
  display: flex;
  flex-direction: column;
  gap: 12px;
  align-items: stretch;
  max-width: 460px;
  margin: 0 auto;
}
.whats-next-cta {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  width: 100%;
  background: var(--learning-teal);
  color: #ffffff;
  border: none;
  padding: 14px 20px;
  border-radius: var(--radius-sm);
  font-family: var(--font);
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  transition: transform .15s ease, box-shadow .15s ease, background .15s ease;
  text-align: center;
}
.whats-next-cta:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(13, 122, 114, .35);
}
.whats-next-cta:focus-visible {
  outline: 2px solid var(--vivoso-purple);
  outline-offset: 2px;
}
.whats-next-cta-label { display: block; }
.whats-next-cta-sub {
  display: block;
  font-size: .82rem;
  font-weight: 500;
  opacity: .92;
}
/* Certification CTA — same prominence, distinct visual signal via a left
   accent bar and a leading star badge so the user reads it as a different
   action than a generic Continue. */
.whats-next-cta--cert {
  background: var(--vivoso-purple);
  box-shadow: inset 4px 0 0 #F4E4A8;
}
.whats-next-cta--cert:hover {
  box-shadow: inset 4px 0 0 #F4E4A8, 0 4px 16px rgba(107, 70, 160, .35);
}
.whats-next-cta-badge {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1.1rem;
  color: #F4E4A8;
  line-height: 1;
}
.whats-next-back {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  color: var(--text-secondary);
  border: none;
  padding: 10px 16px;
  font-family: var(--font);
  font-size: .9rem;
  font-weight: 600;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 3px;
  margin-top: 4px;
  transition: color .15s ease;
}
.whats-next-back:hover { color: var(--text); }
.whats-next-back:focus-visible {
  outline: 2px solid var(--vivoso-purple);
  outline-offset: 2px;
  border-radius: 4px;
}
@media (max-width: 600px) {
  .whats-next-section {
    margin-top: 22px;
    padding-top: 18px;
  }
  .whats-next-acknowledgment { font-size: .95rem; }
  .whats-next-heading { font-size: 1.05rem; margin-bottom: 14px; }
  .whats-next-cta { font-size: .95rem; padding: 13px 18px; }
  .whats-next-cta-sub { font-size: .78rem; }
}
@media (prefers-reduced-motion: reduce) {
  .whats-next-cta { transition: none; }
  .whats-next-cta:hover { transform: none; }
}

/* ---- Hidden print-only takeaways container ----
   Populated on demand by printTakeaways(). Hidden on screen at all times;
   the @media print block below hides everything else and reveals only this. */
#print-takeaways,
.takeaway-print-container {
  display: none;
}

@media print {
  /* Single-page takeaways output. The previous version used
     `visibility: hidden` which kept hidden elements in the layout flow —
     that's why the lesson page was spitting out 11 pages. `display: none`
     actually removes elements from the layout so only the takeaway print
     container occupies paginated space. */
  @page { size: Letter; margin: 0.5in; }
  html, body {
    background: #fff !important;
    color: #000 !important;
    margin: 0 !important;
    padding: 0 !important;
    height: auto !important;
    overflow: visible !important;
  }
  /* Hide everything by default. */
  body * {
    display: none !important;
  }
  /* Then specifically reveal only the takeaway print container and every
     descendant inside it. */
  .takeaway-print-container,
  .takeaway-print-container * {
    display: block !important;
  }
  /* Flex restore for elements that need row layout inside the print tree. */
  .takeaway-print-container .print-takeaway-item {
    display: flex !important;
  }
  /* Root print container — flows naturally as the only visible block on the
     page. Earlier iterations used `position: absolute; top: 0` which combined
     with the page-break-inside hints below pushed content to page 2 (header
     committed to page 1, list got bumped). Natural flow is the most reliable
     single-page pagination. */
  .takeaway-print-container {
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    background: #fff !important;
    color: #000 !important;
    box-shadow: none !important;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    font-size: 12pt !important;
    page-break-after: avoid !important;
    page-break-before: avoid !important;
    page-break-inside: avoid !important;
    orphans: 3;
    widows: 3;
  }
  /* Strip every color, shadow, and background across the print subtree so
     the output renders cleanly in black on white. */
  .takeaway-print-container,
  .takeaway-print-container * {
    background: #fff !important;
    background-color: #fff !important;
    background-image: none !important;
    color: #000 !important;
    box-shadow: none !important;
    text-shadow: none !important;
    border-color: #000 !important;
  }
  /* The on-screen "Print Takeaways" button is NOT inside the print
     container, so `body * { display: none }` already hides it. These
     explicit rules are belt-and-braces in case either button ever ends up
     inside the tree. */

  /* ---- Content layout inside the single printed page ---- */
  .print-takeaways-page {
    max-width: 100% !important;
    margin: 0 auto !important;
    padding: 0 !important;
    page-break-inside: avoid !important;
  }
  .print-takeaways-head {
    text-align: center !important;
    margin-bottom: 18pt !important;
    page-break-inside: avoid !important;
  }
  .print-takeaways-brand {
    font-size: 20pt !important;
    font-weight: 900 !important;
    color: #7C3AED !important;
    letter-spacing: -0.5px;
    margin-bottom: 4pt !important;
  }
  .print-takeaways-course {
    font-size: 12pt !important;
    font-weight: 700 !important;
    color: #000 !important;
    margin-bottom: 4pt !important;
  }
  .print-takeaways-tagline {
    font-family: 'Playfair Display', Georgia, serif !important;
    font-style: italic !important;
    font-weight: 400 !important;
    font-size: 10pt !important;
    color: #6B6878 !important;
    text-align: center !important;
    margin: 0 0 8pt !important;
  }
  .print-takeaways-rule {
    height: 0 !important;
    border-top: 1pt solid #000 !important;
    margin: 0 auto !important;
    width: 100% !important;
  }
  .print-takeaways-list {
    list-style: none !important;
    margin: 16pt 0 14pt !important;
    padding: 0 !important;
  }
  .print-takeaway-item {
    display: flex !important;
    align-items: flex-start !important;
    gap: 10pt !important;
    margin-bottom: 10pt !important;
    page-break-inside: avoid !important;
    font-size: 12pt !important;
    line-height: 1.45 !important;
    color: #000 !important;
  }
  .print-takeaway-box {
    flex-shrink: 0 !important;
    width: 12pt !important;
    height: 12pt !important;
    border: 1pt solid #000 !important;
    border-radius: 2pt;
    margin-top: 2pt !important;
    background: #fff !important;
  }
  .print-takeaway-text {
    flex: 1 !important;
    font-size: 12pt !important;
    color: #000 !important;
    font-weight: 500 !important;
  }
  .print-takeaways-disclaimer {
    font-family: 'DM Sans', sans-serif !important;
    font-size: 9pt !important;
    font-style: italic !important;
    color: #6B6878 !important;
    text-align: center !important;
    margin: 12pt 0 0 !important;
    line-height: 1.5 !important;
    page-break-inside: avoid !important;
  }
}

/* ---- Financial Charts ---- */
.lesson-chart {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  margin: 24px 0;
}

.lesson-chart-title {
  font-size: .95rem;
  font-weight: 800;
  color: var(--text);
  margin-bottom: 16px;
  text-align: center;
}

/* Pie chart (F01) */
.budget-pie {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 28px;
  flex-wrap: wrap;
}

.budget-pie-ring {
  width: 120px;
  height: 120px;
}

.budget-pie-ring svg {
  transform: rotate(-90deg);
}

.budget-pie-legend {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.budget-pie-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: .85rem;
  font-weight: 600;
  color: var(--text);
}

.budget-dot {
  width: 12px;
  height: 12px;
  border-radius: 3px;
  flex-shrink: 0;
}

/* Budget calculator (E38) */
.budget-calc-label {
  display: block;
  font-size: .85rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 8px;
}

.budget-calc-input-row {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-bottom: 16px;
}

.budget-calc-dollar {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-secondary);
}

.budget-calc-input {
  padding: 10px 14px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 1rem;
  font-weight: 700;
  font-family: var(--font);
  width: 160px;
  color: var(--text);
  background: var(--surface);
}

.budget-calc-input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(124,58,237,.1);
}

.budget-calc-bars {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.budget-calc-bar {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.budget-calc-bar-fill {
  height: 24px;
  border-radius: 4px;
  transition: width .4s ease;
  width: 0%;
}

.budget-calc-bar-label {
  font-size: .8rem;
  color: var(--text-secondary);
}

.budget-calc-bar-label strong {
  color: var(--text);
}

/* Spending bars (F09) */
.spending-bars {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.spending-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.spending-label {
  font-size: .78rem;
  font-weight: 600;
  color: var(--text);
  width: 100px;
  flex-shrink: 0;
  text-align: right;
}

.spending-bar-track {
  flex: 1;
  height: 20px;
  background: var(--border);
  border-radius: 4px;
  overflow: hidden;
}

.spending-bar-fill {
  height: 100%;
  border-radius: 4px;
  transition: width .4s ease;
}

.spending-pct {
  font-size: .72rem;
  font-weight: 700;
  color: var(--text-secondary);
  width: 32px;
  flex-shrink: 0;
}

.streaming-cursor::after {
  content: '▋';
  animation: blink .7s infinite;
  color: var(--primary);
}

@keyframes blink { 0%,50% { opacity: 1 } 51%,100% { opacity: 0 } }

.lesson-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 20px;
  gap: 16px;
  color: var(--text-secondary);
}

.spinner {
  width: 36px; height: 36px;
  border: 3px solid var(--border);
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* Personalized Loading Screen */
.lesson-gen-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  padding: 60px 24px;
  text-align: center;
  transition: opacity .4s ease;
}

.lesson-gen-loading.lesson-gen-fade-out {
  opacity: 0;
}

.lesson-gen-fade-in {
  animation: lessonFadeIn .5s ease;
}

@keyframes lessonFadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Streaming cursor — appended to the live element while text is still
   arriving from /api/lesson. Removed once the final render runs. */
.lesson-md-streaming::after {
  content: '▍';
  display: inline-block;
  margin-left: 2px;
  color: var(--primary, #7C3AED);
  font-weight: 400;
  animation: lessonStreamCursor 1s steps(2, start) infinite;
  vertical-align: baseline;
  transform: translateY(-1px);
}

@keyframes lessonStreamCursor {
  0%, 50% { opacity: 1; }
  51%, 100% { opacity: 0; }
}

/* Inline error strip shown when streaming fails partway through. The
   already-rendered text stays on screen so the user doesn't lose progress. */
.lesson-stream-error {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 24px;
  padding: 16px 20px;
  background: #FEF2F2;
  border: 1.5px solid #FCA5A5;
  border-radius: var(--radius);
}
.lesson-stream-error-icon { font-size: 1.6rem; }
.lesson-stream-error-body { flex: 1; min-width: 0; }
.lesson-stream-error-title { font-weight: 800; color: #991B1B; margin-bottom: 2px; }
.lesson-stream-error-msg { font-size: .85rem; color: #B91C1C; line-height: 1.4; }

.lesson-gen-brand {
  font-size: .85rem;
  font-weight: 800;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 28px;
}

/* v1.15.0 — Personalization-aware lesson loading screen. Replaces the
   previous spinner + rotating message pattern. Static copy, pulsing dots
   indicator, generous padding so it breathes on mobile. */
.lesson-loading-screen {
  max-width: 540px;
  margin: 0 auto;
  padding: 15vh 24px 64px;
  text-align: center;
}
.lesson-loading-screen-headline {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.4rem, 4vw, 1.6rem);
  color: #6B46A0;
  line-height: 1.25;
  margin: 0 0 24px;
}
.lesson-loading-screen-body {
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 0.9rem;
  color: var(--text-secondary, #6B6878);
  line-height: 1.5;
  margin: 0 0 28px;
}
.lesson-loading-screen-checks {
  list-style: none;
  padding: 0;
  margin: 0 auto 28px;
  max-width: 320px;
  text-align: left;
}
.lesson-loading-step {
  display: flex;
  align-items: center;
  margin: 8px 0;
  font-family: var(--font-body);
  font-size: 1rem;
  color: #1F1B2E;
  line-height: 1.6;
  transition: color .25s ease;
}
.lesson-loading-step.is-complete {
  color: var(--amber);
}
.lesson-loading-step-track {
  width: 80px;
  height: 3px;
  flex-shrink: 0;
  background: #E5E2EC;
  border-radius: 2px;
  overflow: hidden;
  margin-right: 12px;
}
.lesson-loading-step-fill {
  width: 0%;
  height: 100%;
  background: var(--amber);
  border-radius: 2px;
  transform-origin: left;
}
.lesson-loading-step-fill.is-active {
  animation: lesson-loading-fill-fast 3.5s ease-out forwards,
             lesson-loading-fill-slow 8s ease-out 3.5s forwards;
}
.lesson-loading-step-fill.is-complete {
  width: 100% !important;
  transition: width 0.3s ease-out;
  animation: none;
}
.lesson-loading-step-label {
  flex: 0 1 auto;
}
.lesson-loading-step-check {
  margin-left: 8px;
  color: var(--amber);
  font-weight: 700;
  opacity: 0;
  transition: opacity 0.3s ease 0.2s;
}
.lesson-loading-step.is-complete .lesson-loading-step-check {
  opacity: 1;
}
@keyframes lesson-loading-fill-fast {
  from { width: 0%; }
  to { width: 85%; }
}
@keyframes lesson-loading-fill-slow {
  from { width: 85%; }
  to { width: 95%; }
}
@media (min-width: 768px) {
  .lesson-loading-step-track { width: 120px; }
}
.lesson-loading-screen-tag {
  font-family: var(--font-body);
  font-size: 0.95rem;
  color: var(--text-secondary, #6B6878);
  margin: 0;
}
/* Hidden mount slot — section 1 markup lives here briefly so blockTexts
   can be populated for the TTS prefetch before the loading screen
   dismisses. CSS-hidden, not HTML-hidden, so layout/measurement works. */
.lesson-md-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
}
@media (prefers-reduced-motion: reduce) {
  .lesson-loading-step { transition: none; }
  .lesson-loading-step-fill.is-active {
    animation: none;
    width: 50%;
  }
  .lesson-loading-step-fill.is-complete {
    transition: none;
  }
  .lesson-loading-step-check {
    transition: none;
  }
}
@media (min-width: 768px) {
  .lesson-loading-screen { padding-top: 8vh; }
}

.lesson-actions {
  display: flex;
  gap: 12px;
  justify-content: flex-end;
  flex-wrap: wrap;
}

/* ---- QUIZ SCREEN ---- */
.quiz-wrapper {
  max-width: 740px;
  margin: 0 auto;
}

.quiz-header {
  background: linear-gradient(135deg, #7C3AED, #9F67FA);
  border-radius: var(--radius);
  padding: 24px 28px;
  color: white;
  margin-bottom: 24px;
}

.quiz-header h2 { font-size: 1.4rem; font-weight: 800; margin-bottom: 4px; }
.quiz-header p { opacity: .85; font-size: .9rem; }

.question-card {
  background: var(--surface);
  border-radius: var(--radius);
  border: 1.5px solid var(--border);
  padding: 28px;
  margin-bottom: 16px;
}

.question-num {
  font-size: .75rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-muted);
  margin-bottom: 10px;
}

.question-text {
  font-size: 1.05rem;
  font-weight: 600;
  margin-bottom: 18px;
  line-height: 1.5;
}

.options-list { display: flex; flex-direction: column; gap: 10px; }

.option-btn {
  width: 100%;
  text-align: left;
  background: var(--bg);
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  font-size: .92rem;
  font-family: var(--font);
  color: var(--text);
  cursor: pointer;
  transition: all .15s;
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 500;
}

.option-btn:hover { border-color: var(--primary); background: var(--primary-light); color: var(--primary); }
.option-btn.selected { border-color: var(--primary); background: var(--primary-light); color: var(--primary); font-weight: 600; }
.option-btn.correct { border-color: var(--success); background: var(--success-light); color: var(--success); font-weight: 600; }
.option-btn.wrong { border-color: var(--danger); background: var(--danger-light); color: var(--danger); font-weight: 600; }

.option-letter {
  width: 28px; height: 28px;
  border-radius: 50%;
  background: white;
  border: 1.5px solid currentColor;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .75rem;
  font-weight: 800;
  flex-shrink: 0;
}

.explanation-box {
  margin-top: 14px;
  padding: 12px 16px;
  background: var(--success-light);
  border-left: 4px solid var(--success);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-size: .85rem;
  color: #065F46;
  line-height: 1.6;
}

.explanation-box.wrong-explanation {
  background: #EFF6FF;
  border-left-color: #93C5FD;
  color: #1E3A5F;
}

/* Question type label */
.question-type-label {
  font-size: .68rem;
  font-weight: 800;
  letter-spacing: .8px;
  text-transform: uppercase;
  color: var(--primary);
  background: var(--primary-light);
  display: inline-block;
  padding: 3px 10px;
  border-radius: 100px;
  margin-bottom: 10px;
}

/* Scenario box */
.question-scenario {
  background: linear-gradient(135deg, #FFFBEB, #FEF3C7);
  border: 1.5px solid #FCD34D;
  border-radius: var(--radius-sm);
  padding: 14px 18px;
  font-size: .88rem;
  line-height: 1.6;
  color: #451A03;
  margin-bottom: 14px;
}

/* True/False buttons */
.tf-options {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.tf-btn {
  padding: 18px 20px;
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  font-size: 1rem;
  font-weight: 800;
  font-family: var(--font);
  color: var(--text);
  cursor: pointer;
  transition: all .15s;
  text-align: center;
  min-height: 56px;
}

.tf-btn:hover {
  border-color: var(--primary);
  color: var(--primary);
  background: var(--primary-light);
}

.tf-btn.selected {
  border-color: var(--primary);
  background: var(--primary);
  color: white;
}

.tf-btn.correct {
  border-color: var(--success);
  background: var(--success-light);
  color: var(--success);
}

.tf-btn.wrong {
  border-color: var(--danger);
  background: var(--danger-light);
  color: var(--danger);
}

/* Smart Retry */
.quiz-retry-banner {
  background: linear-gradient(135deg, #EFF6FF, #DBEAFE);
  border: 1.5px solid #93C5FD;
  border-radius: var(--radius-sm);
  padding: 16px 20px;
  font-size: .9rem;
  line-height: 1.5;
  color: #1E40AF;
  margin-bottom: 20px;
  text-align: center;
}

.quiz-retry-banner span:first-child {
  font-weight: 800;
}

.question-locked {
  opacity: .5;
  border-style: dashed;
}

.question-locked-badge {
  display: inline-block;
  background: var(--success-light);
  color: var(--success);
  font-size: .68rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 100px;
  margin-left: 8px;
}

@media (max-width: 600px) {
  .tf-options { grid-template-columns: 1fr; }
  .tf-btn { min-height: 52px; }
}

.quiz-submit-area {
  display: flex;
  justify-content: flex-end;
  margin-top: 8px;
}

/* ---- RESULTS SCREEN ---- */
.results-wrapper {
  max-width: 600px;
  margin: 0 auto;
}

.results-card {
  background: var(--surface);
  border-radius: 24px;
  border: 1.5px solid var(--border);
  overflow: hidden;
  margin-bottom: 24px;
}

.results-hero {
  padding: 40px;
  text-align: center;
}

.results-hero.pass { background: linear-gradient(135deg, #059669, #34D399); color: white; }
.results-hero.retry { background: linear-gradient(135deg, #6B7280, #9CA3AF); color: white; }

.score-circle {
  width: 100px; height: 100px;
  border-radius: 50%;
  background: rgba(255,255,255,.2);
  border: 3px solid rgba(255,255,255,.5);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin: 0 auto 20px;
}

.score-num { font-size: 2rem; font-weight: 900; line-height: 1; }
.score-denom { font-size: .8rem; opacity: .85; }
.results-title { font-size: 1.6rem; font-weight: 900; margin-bottom: 8px; }
.results-sub { opacity: .9; font-size: .95rem; }

.results-actions {
  padding: 24px;
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: center;
}

/* ---- CERTIFICATES SCREEN ---- */
.certs-wrapper { max-width: 1060px; width: 100%; margin: 0 auto; margin-bottom: 48px; }
.certs-hero {
  background: linear-gradient(135deg, #1F2937, #374151);
  border-radius: 24px;
  padding: 40px;
  color: white;
  margin-bottom: 32px;
  text-align: center;
}
.certs-hero h1 { font-size: 2rem; font-family: var(--font-display); font-weight: 700; letter-spacing: -0.5px; line-height: 1.2; margin-bottom: 8px; }
.certs-hero p { opacity: .8; max-width: 500px; margin: 0 auto; }

.certs-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
}

.cert-card {
  background: var(--surface);
  border-radius: var(--radius);
  border: 1.5px solid var(--border);
  overflow: hidden;
  /* v1.28.16 — Equal-height cards across each grid row. Combined with the
     grid's default align-items:stretch and margin-top:auto on the footer,
     description-length variations push extra whitespace ABOVE the footer,
     never below it. Button rows align horizontally across the row. */
  display: flex;
  flex-direction: column;
  height: 100%;
}

.cert-card-top {
  padding: 24px;
  display: flex;
  gap: 16px;
  align-items: flex-start;
}

.cert-card-icon {
  width: 52px; height: 52px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  flex-shrink: 0;
}

/* Mini medallion on each Tier-1 pathway card on the certificates page. */
.cert-card-medallion {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  filter: drop-shadow(0 3px 10px rgba(17, 24, 39, .14));
}
.cert-card-medallion svg { display: block; }
.cert-card--master .cert-card-medallion .cert-seal { width: 64px; height: 64px; }

.cert-card-info h3 { font-size: 1rem; font-family: var(--font-display); font-weight: 700; letter-spacing: -0.2px; line-height: 1.25; margin-bottom: 4px; }
.cert-card-info p { font-size: .82rem; color: var(--text-secondary); line-height: 1.5; }

.cert-card-progress {
  padding: 0 24px 16px;
}

.cert-courses-list {
  padding: 0 24px 16px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

/* v1.28.7 — Per-course completion indicator inside cert cards. Amber
   outline with white interior. (DOM consumers may be reintroduced; the
   styling is positioned for that future render path.) */
.cert-course-pill {
  font-size: .72rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 100px;
  background: #FFFFFF;
  border: 1px solid var(--amber);
  color: var(--steel);
}

.cert-course-pill.done {
  background: #FFFFFF;
  border: 1px solid var(--amber);
  color: var(--oxford);
}

.cert-card-footer {
  padding: 16px 24px;
  border-top: 1px solid var(--border);
  /* v1.28.16 — Pin the button row to the bottom of the card. The space
     above expands to absorb height differences between sibling cards. */
  margin-top: auto;
}

.cert-card-footer .cert-btn { margin-top: 0; }

/* ---- CERTIFICATE PRINT DESIGN ---- */
.certificate {
  font-family: 'Georgia', 'Times New Roman', serif;
  width: 800px;
  min-height: 580px;
  padding: 50px 60px;
  border: 3px solid;
  border-radius: 8px;
  position: relative;
  text-align: center;
  background: white;
  box-shadow: none;
}

.certificate::before {
  content: '';
  position: absolute;
  inset: 8px;
  border: 1px solid;
  border-radius: 4px;
  opacity: .4;
  pointer-events: none;
}

.cert-logo { font-family: var(--font); font-size: 1rem; font-weight: 900; letter-spacing: 3px; text-transform: uppercase; margin-bottom: 8px; opacity: .7; }
.cert-pretitle { font-size: .8rem; letter-spacing: 4px; text-transform: uppercase; opacity: .6; margin-bottom: 32px; }
.cert-main-title { font-size: 2.6rem; font-weight: 700; line-height: 1.2; margin-bottom: 28px; }
.cert-certifies { font-size: .9rem; letter-spacing: 2px; text-transform: uppercase; opacity: .6; margin-bottom: 12px; }
.cert-name { font-size: 2.2rem; font-style: italic; border-bottom: 1px solid; display: inline-block; padding-bottom: 4px; min-width: 300px; margin-bottom: 24px; }
.cert-completed-text { font-size: .85rem; letter-spacing: 1px; text-transform: uppercase; opacity: .6; margin-bottom: 8px; }
.cert-track-name { font-size: 1.4rem; font-weight: 700; margin-bottom: 28px; }
.cert-courses-completed { font-size: .8rem; opacity: .7; margin-bottom: 28px; max-width: 600px; margin-left: auto; margin-right: auto; }
.cert-footer { display: flex; justify-content: space-between; align-items: flex-end; margin-top: 32px; border-top: 1px solid; padding-top: 20px; opacity: .6; font-size: .78rem; letter-spacing: 1px; }
.cert-seal { font-size: 3rem; opacity: .5; margin-bottom: 8px; }

/* ---- NAME MODAL ---- */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.5);
  backdrop-filter: blur(4px);
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.modal-box {
  background: var(--surface);
  border-radius: 20px;
  padding: 36px;
  max-width: 460px;
  width: 100%;
  box-shadow: var(--shadow-lg);
}

.modal-box h3 { font-size: 1.3rem; font-weight: 800; margin-bottom: 8px; }
.modal-box p { color: var(--text-secondary); font-size: .9rem; margin-bottom: 24px; }
.modal-actions { display: flex; gap: 12px; justify-content: flex-end; margin-top: 20px; }

/* ---- F01 Signup Prompt — v1.28.47 BIS v1.3 conversion ----
   Class names retain the c01- prefix as internal style hooks. */
.c01-signup-overlay {
  background: rgba(2, 18, 47, .85);
  animation: c01-signup-fade .25s ease-out;
}
.c01-signup-box {
  background: #ffffff;
  border: 2px solid var(--amber);
  border-radius: 14px;
  box-shadow: 0 24px 60px -20px rgba(212, 136, 42, .35), 0 8px 24px rgba(2, 18, 47, .25);
  text-align: center;
  max-width: 460px;
  padding: 36px 32px 28px;
  animation: c01-signup-rise .3s ease-out;
}
.c01-signup-headline {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.6rem, 3.5vw, 2rem);
  letter-spacing: -0.01em;
  line-height: 1.2;
  color: var(--oxford);
  margin: 0 0 12px;
}
.c01-signup-sub {
  font-family: var(--font);
  font-weight: 400;
  color: var(--steel);
  font-size: .98rem;
  line-height: 1.55;
  margin: 0 0 24px;
}
/* Annual — Amber-filled primary CTA. Overrides the default .btn-primary
   teal chain since the F01 prompt sits inside Oxford-tinted overlay. */
.c01-signup-cta {
  width: 100%;
  padding: 14px 20px;
  font-family: var(--font);
  font-size: 1rem;
  font-weight: 600;
  background: var(--amber);
  color: #ffffff;
  border: 1.5px solid var(--amber);
  border-radius: var(--radius-sm);
  margin-bottom: 12px;
  transition: background .15s, border-color .15s, transform .12s;
}
.c01-signup-cta:hover {
  background: #B8741F;
  border-color: #B8741F;
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(212, 136, 42, .35);
}
/* Monthly — Steel ghost secondary. Same width pattern, lighter weight. */
.c01-signup-link {
  display: block;
  width: 100%;
  box-sizing: border-box;
  background: transparent;
  color: var(--steel);
  font-family: var(--font);
  font-size: .92rem;
  font-weight: 500;
  cursor: pointer;
  padding: 12px 18px;
  border: 1.5px solid var(--steel);
  border-radius: var(--radius-sm);
  text-decoration: none;
  text-align: center;
  transition: border-color .15s, color .15s;
}
.c01-signup-link:hover,
.c01-signup-link:focus-visible {
  border-color: var(--amber);
  color: var(--amber);
  text-decoration: none;
  outline: none;
}
/* Dismiss — quiet text link, smallest visual weight. */
.c01-signup-dismiss {
  display: block;
  background: transparent;
  border: none;
  color: var(--steel);
  font-family: var(--font);
  font-weight: 400;
  font-size: .85rem;
  cursor: pointer;
  margin: 16px auto 0;
  padding: 6px;
  text-decoration: none;
  opacity: .75;
  transition: opacity .15s;
}
.c01-signup-dismiss:hover,
.c01-signup-dismiss:focus-visible {
  opacity: 1;
  text-decoration: underline;
  text-underline-offset: 3px;
  outline: none;
}
@keyframes c01-signup-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes c01-signup-rise { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: translateY(0); } }
@media (max-width: 540px) {
  .c01-signup-box { padding: 26px 20px; border-radius: 16px; }
  .c01-signup-headline { font-size: 1.35rem; }
}
@media (prefers-reduced-motion: reduce) {
  .c01-signup-overlay, .c01-signup-box { animation: none; }
}

/* ---- BACK BUTTON ---- */
.back-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--text-secondary);
  font-size: .85rem;
  font-weight: 600;
  cursor: pointer;
  background: none;
  border: none;
  font-family: var(--font);
  margin-bottom: 20px;
  padding: 6px 0;
  transition: color .15s;
}
.back-btn:hover { color: var(--text); }

/* ---- UTILITY ---- */
.mt-4 { margin-top: 16px; }
.text-center { text-align: center; }
.full-width { width: 100%; }

/* ---- PREVIEW MODE ---- */
.preview-toggle {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}

.preview-btn {
  background: none;
  border: 1.5px dashed var(--text-muted);
  color: var(--text-muted);
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  font-size: .78rem;
  font-weight: 700;
  font-family: var(--font);
  cursor: pointer;
  transition: all .15s;
}

.preview-btn:hover {
  border-color: var(--text-secondary);
  color: var(--text-secondary);
}

.preview-btn.active {
  background: #FEF3C7;
  border: 1.5px solid #F59E0B;
  color: #B45309;
}

.preview-hint {
  font-size: .75rem;
  color: #B45309;
  font-weight: 600;
}

/* ---- COURSE HOOKS ---- */
.course-hook {
  margin-top: 32px;
  padding: 28px 24px;
  background: linear-gradient(135deg, #FFF7ED, #FEF3C7);
  border: 2px solid #F59E0B;
  border-radius: var(--radius);
  text-align: center;
}

.course-hook-icon {
  display: none;
}

.course-hook h3 {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text);
  margin-bottom: 8px;
}

.course-hook p {
  font-size: .9rem;
  color: var(--text-secondary);
  max-width: 500px;
  margin: 0 auto 16px;
  line-height: 1.6;
}

/* ---- TEXT-TO-SPEECH ---- */
/* v1.15.0 / Stage 2.6 — fixed positioning so the bar pins to the viewport
   top regardless of scroll position.

   Stage 2 tried `position: sticky; top: 8px;`, but sticky never activated
   because the bar's immediate parent (`#tts-slot`) is exactly bar-sized —
   sticky requires the parent to be TALLER than the sticky element so there
   is a "sticky range" for the browser to operate in. Slot height === bar
   height meant zero range, and the bar effectively rendered as static.

   `position: fixed` sidesteps the parent-container constraint entirely.
   The bar pins below the existing `.app-header` (sticky, 64px, z-index
   100) with an 8px gap. We reserve the bar's vertical space in the flow
   via the `.tts-slot-active` rule below so lesson content doesn't slide
   under the bar on initial reveal.

   Centered horizontally to match `.lesson-wrapper`'s 740px max-width. */
.tts-bar {
  background: linear-gradient(135deg, #1E293B 0%, #0F172A 100%);
  border-radius: var(--radius);
  padding: 18px 24px;
  margin: 0;
  position: fixed;
  top: 72px;
  left: 50%;
  transform: translateX(-50%);
  width: calc(100% - 32px);
  max-width: 740px;
  z-index: 50;
  box-shadow: 0 8px 24px rgba(0,0,0,.18);
}

/* Reserve in-flow space matching the bar's height so the lesson-header
   doesn't end up underneath the fixed bar at the top of the lesson. The
   class is added by `_mountAudioBar()` only after audio is ready, so
   text-only failsafe layouts don't get a phantom gap. */
#tts-slot.tts-slot-active {
  min-height: 96px;
  margin-bottom: 8px;
}
@media (max-width: 767px) {
  .tts-bar { top: 68px; }
  #tts-slot.tts-slot-active { min-height: 76px; }
}

/* v1.15.0 — Skip-back button (-10s rewind). Matches existing TTS button
   theming: pill shape, light-on-dark, 44px+ tap target. */
.tts-skipback-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: rgba(255,255,255,.08);
  color: #fff;
  border: 1px solid rgba(255,255,255,.18);
  border-radius: 100px;
  padding: 8px 12px;
  min-height: 40px;
  min-width: 44px;
  font-family: var(--font-body);
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  transition: background .15s ease, transform .12s ease;
}
.tts-skipback-btn:hover { background: rgba(255,255,255,.16); }
.tts-skipback-btn:active { transform: scale(.96); }
.tts-skipback-btn .tts-svg { width: 18px; height: 18px; }
.tts-skipback-label { font-size: 0.72rem; letter-spacing: 0.5px; }

/* v1.15.0 — Minimize/Expand toggle button. Icon swaps based on bar state. */
.tts-minimize-btn {
  background: transparent;
  color: rgba(255,255,255,.7);
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 100px;
  padding: 8px 10px;
  min-height: 40px;
  min-width: 40px;
  cursor: pointer;
  transition: background .15s ease, color .15s ease, transform .12s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.tts-minimize-btn:hover { background: rgba(255,255,255,.08); color: #fff; }
.tts-minimize-btn:active { transform: scale(.94); }
.tts-minimize-btn .tts-svg { width: 18px; height: 18px; }
.tts-minimize-btn .tts-expand-icon { display: none; }
.tts-bar.tts-bar-minimized .tts-minimize-btn .tts-minimize-icon { display: none; }
.tts-bar.tts-bar-minimized .tts-minimize-btn .tts-expand-icon { display: inline; }

/* Compact bar state: hide the speaker icon, guide line, prep msg, speed
   row, and skip-back button. Keep play/pause + section indicator + the
   minimize-now-expand toggle. */
.tts-bar.tts-bar-minimized {
  padding: 8px 14px;
}
.tts-bar.tts-bar-minimized .tts-guide,
.tts-bar.tts-bar-minimized .tts-prep-msg,
.tts-bar.tts-bar-minimized .tts-icon-col,
.tts-bar.tts-bar-minimized .tts-speed-row,
.tts-bar.tts-bar-minimized .tts-speed-cycle,
.tts-bar.tts-bar-minimized .tts-skipback-btn,
.tts-bar.tts-bar-minimized .tts-progress {
  display: none !important;
}
.tts-bar.tts-bar-minimized .tts-top-row { gap: 10px; }
.tts-bar.tts-bar-minimized .tts-text-col { flex: 1; min-width: 0; }
.tts-bar.tts-bar-minimized .tts-hint {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-size: 0.85rem;
}
.tts-bar.tts-bar-minimized .tts-controls { gap: 8px; }

/* When bar is minimized, the in-flow spacer can shrink to match. */
#tts-slot.tts-slot-active:has(.tts-bar-minimized) {
  min-height: 64px;
}

/* v1.15.0 — Start over link (auto-resume only). Quiet treatment so it
   doesn't compete with the back button. */
.lesson-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}
.lesson-start-over-link {
  background: transparent;
  border: none;
  color: var(--text-secondary, #6B6878);
  font-family: var(--font-body);
  font-size: 0.85rem;
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
  padding: 6px 8px;
  border-radius: 6px;
  transition: color .15s ease, background .15s ease;
}
.lesson-start-over-link:hover { color: var(--text, #1F1B2E); background: rgba(0,0,0,.04); }
.lesson-start-over-link:focus-visible { outline: 2px solid var(--primary, #6B46A0); outline-offset: 2px; }

@media (prefers-reduced-motion: reduce) {
  .tts-skipback-btn, .tts-minimize-btn, .lesson-start-over-link {
    transition: none;
  }
  .tts-skipback-btn:active, .tts-minimize-btn:active { transform: none; }
}

.tts-top-row {
  display: flex;
  align-items: center;
  gap: 16px;
}

.tts-icon-col {
  flex-shrink: 0;
}

.tts-bar-icon {
  width: 28px;
  height: 28px;
  fill: rgba(255,255,255,.5);
}

.tts-text-col {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.tts-hint {
  font-size: .95rem;
  color: white;
  font-weight: 700;
}

.tts-hint-sub {
  font-size: .78rem;
  color: rgba(255,255,255,.45);
  font-weight: 500;
}

/* Permanent gentle guide line above the audio controls — visible whether
   audio is loading or ready. */
.tts-guide {
  font-size: .78rem;
  color: rgba(255,255,255,.55);
  font-weight: 500;
  text-align: center;
  letter-spacing: .15px;
  padding-bottom: 10px;
  margin-bottom: 12px;
  border-bottom: 1px solid rgba(255,255,255,.08);
}

/* Warm rotating pre-load strip with the animated dots. Removed once ready. */
.tts-prep-msg {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  font-size: .85rem;
  color: rgba(255,255,255,.85);
  font-weight: 600;
  line-height: 1.45;
  padding-bottom: 12px;
  margin-bottom: 14px;
  border-bottom: 1px solid rgba(255,255,255,.08);
  letter-spacing: .1px;
  min-height: 1.6em;
}

/* Smooth cross-fade when the rotating prep text swaps. */
#tts-prep-text {
  display: inline-block;
  transition: opacity .22s ease;
}

/* "Tap to resume" prompt — appears when the audio element pauses without the
   user pressing pause (autoplay block, focus loss, OS interruption, etc.). */
.tts-resume-prompt {
  display: none;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  margin-top: 12px;
  padding: 14px 18px;
  background: #FBBF24;
  color: #1E293B;
  border: none;
  border-radius: 10px;
  font-family: var(--font);
  font-size: .95rem;
  font-weight: 700;
  cursor: pointer;
  text-align: left;
  box-shadow: 0 4px 14px rgba(251,191,36,.35);
  animation: tts-resume-pulse 1.8s ease-in-out infinite;
}
.tts-resume-prompt:hover,
.tts-resume-prompt:active {
  background: #F59E0B;
}
.tts-resume-prompt .tts-svg {
  width: 22px;
  height: 22px;
  fill: #1E293B;
  flex-shrink: 0;
}
@keyframes tts-resume-pulse {
  0%, 100% { box-shadow: 0 4px 14px rgba(251,191,36,.35); }
  50%      { box-shadow: 0 4px 22px rgba(251,191,36,.65); }
}

/* Animated three-dot indicator. Inherits color from its parent so it works
   on the dark prep message AND on the play button. */
.tts-dots {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-left: 8px;
  vertical-align: middle;
}
.tts-dots span {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: currentColor;
  opacity: .25;
  animation: ttsDotPulse 1.2s ease-in-out infinite;
}
.tts-dots span:nth-child(2) { animation-delay: .2s; }
.tts-dots span:nth-child(3) { animation-delay: .4s; }

/* Slightly larger and brighter when sitting inside the play button. */
.tts-dots-light {
  margin-left: 0;
}
.tts-dots-light span {
  width: 6px;
  height: 6px;
  background: #fff;
  opacity: .35;
}

@keyframes ttsDotPulse {
  0%, 60%, 100% { opacity: .25; transform: scale(1); }
  30%           { opacity: 1;    transform: scale(1.25); }
}
.tts-dots-light span {
  animation-name: ttsDotPulseLight;
}
@keyframes ttsDotPulseLight {
  0%, 60%, 100% { opacity: .35; transform: scale(1); }
  30%           { opacity: 1;    transform: scale(1.25); }
}

/* Visually-hidden but screen-reader-accessible label for the loading state. */
.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;
}

.tts-controls {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

/* Play/pause button — prominent pill */
.tts-play-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: none;
  border-radius: 100px;
  padding: 12px 28px;
  min-height: 48px;
  font-size: .92rem;
  font-weight: 800;
  font-family: var(--font);
  cursor: pointer;
  transition: all .15s;
  background: linear-gradient(135deg, #D97706, #F59E0B);
  color: white;
  box-shadow: 0 2px 12px rgba(245,158,11,.3);
}

.tts-play-btn:hover {
  background: linear-gradient(135deg, #B45309, #D97706);
  box-shadow: 0 4px 18px rgba(245,158,11,.4);
  transform: translateY(-1px);
}

.tts-play-btn.playing {
  background: linear-gradient(135deg, #D97706, #F59E0B);
  color: white;
}

.tts-play-btn.playing:hover { opacity: .9; }

.tts-play-btn.paused {
  background: rgba(255,255,255,.1);
  border: 2px solid #F59E0B;
  color: #FCD34D;
  animation: tts-pulse 2s ease-in-out infinite;
}

.tts-play-btn.disabled {
  background: rgba(255,255,255,.08);
  color: rgba(255,255,255,.3);
  cursor: not-allowed;
  box-shadow: none;
}
.tts-play-btn.disabled:hover { background: rgba(255,255,255,.08); color: rgba(255,255,255,.3); transform: none; box-shadow: none; }

@keyframes tts-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: .6; }
}

/* SVG icons */
.tts-svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
  flex-shrink: 0;
}

/* Stop button */
.tts-stop-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1.5px solid rgba(255,255,255,.3);
  border-radius: 100px;
  padding: 10px 18px;
  min-height: 44px;
  font-size: .82rem;
  font-weight: 700;
  font-family: var(--font);
  cursor: pointer;
  transition: all .15s;
  background: transparent;
  color: rgba(255,255,255,.7);
}

.tts-stop-btn:hover { background: rgba(255,255,255,.1); color: white; border-color: rgba(255,255,255,.5); }
.tts-stop-btn .tts-svg { width: 14px; height: 14px; }

/* Speed controls — desktop row */
.tts-speed-row {
  display: flex;
  gap: 4px;
  margin-left: 8px;
}

.tts-speed-btn {
  border: 1.5px solid rgba(255,255,255,.15);
  border-radius: 100px;
  padding: 5px 10px;
  font-size: .7rem;
  font-weight: 700;
  font-family: var(--font);
  cursor: pointer;
  transition: all .15s;
  background: transparent;
  color: rgba(255,255,255,.4);
  white-space: nowrap;
}

.tts-speed-btn:hover {
  border-color: rgba(255,255,255,.35);
  color: rgba(255,255,255,.7);
}

.tts-speed-btn.active {
  background: linear-gradient(135deg, #D97706, #F59E0B);
  border-color: transparent;
  color: white;
}

/* Speed controls — mobile cycle button (hidden on desktop) */
.tts-speed-cycle {
  display: none;
  align-items: center;
  gap: 4px;
  border: 1.5px solid rgba(255,255,255,.2);
  border-radius: 100px;
  padding: 8px 14px;
  font-size: .78rem;
  font-weight: 700;
  font-family: var(--font);
  cursor: pointer;
  background: transparent;
  color: rgba(255,255,255,.6);
  white-space: nowrap;
  transition: all .15s;
}

.tts-speed-cycle:hover {
  border-color: rgba(255,255,255,.4);
  color: rgba(255,255,255,.85);
}

.tts-speed-cycle-val {
  color: #FCD34D;
  font-weight: 800;
}

/* Progress bar */
.tts-progress {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 12px;
}

.tts-progress-bar {
  flex: 1;
  height: 4px;
  background: rgba(255,255,255,.1);
  border-radius: 100px;
  overflow: hidden;
}

.tts-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #D97706, #F59E0B);
  border-radius: 100px;
  transition: width .4s ease;
  min-width: 0;
}

.tts-progress-text {
  font-size: .72rem;
  font-weight: 600;
  color: rgba(255,255,255,.45);
  white-space: nowrap;
}

/* TTS paragraph highlight */
.tts-active {
  background: #FEF9C3 !important;
  border-left: 4px solid #F59E0B !important;
  padding-left: 14px !important;
  margin-left: -14px !important;
  border-radius: 0 8px 8px 0;
  transition: background .25s ease, border-left .25s ease, padding-left .25s ease;
  box-shadow: inset 0 0 0 1px rgba(245,158,11,.12);
}

/* ---- PROMO CODES ---- */
.promo-section {
  border-top: 1px solid var(--border);
  padding-top: 16px;
  margin-top: 8px;
}

.promo-label {
  font-size: .82rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

.promo-row {
  display: flex;
  gap: 8px;
}

.promo-input {
  flex: 1;
  padding: 10px 14px;
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: .9rem;
  font-weight: 600;
  font-family: var(--font);
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text);
}

.promo-input:focus { outline: none; border-color: var(--primary); }

.promo-apply-btn { padding: 10px 18px; font-size: .85rem; flex-shrink: 0; }

.promo-result { margin-top: 10px; font-size: .85rem; min-height: 20px; }
.promo-success { color: var(--success); font-weight: 600; background: var(--success-light); padding: 10px 14px; border-radius: var(--radius-sm); }
.promo-error { color: var(--danger); font-weight: 600; }
.promo-checking { color: var(--text-muted); }

/* Admin promo list */
.admin-promo-row {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px 18px;
  margin-bottom: 10px;
}

.admin-promo-main {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 6px;
}

.admin-promo-code {
  font-family: monospace;
  font-size: .95rem;
  font-weight: 800;
  color: var(--text);
  letter-spacing: 1px;
}

.admin-promo-type {
  font-size: .75rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 100px;
  background: var(--primary-light);
  color: var(--primary);
}

.admin-promo-uses {
  font-size: .78rem;
  color: var(--text-secondary);
  font-weight: 600;
}

.admin-promo-status {
  font-size: .72rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 100px;
  text-transform: uppercase;
  letter-spacing: .4px;
}

.admin-promo-status.promo-active { background: var(--success-light); color: var(--success); }
.admin-promo-status.promo-inactive { background: var(--danger-light); color: var(--danger); }

.admin-promo-desc {
  font-size: .78rem;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.admin-promo-actions {
  display: flex;
  gap: 8px;
}

/* ---- LANDING PAGE ---- */
.landing { overflow-x: hidden; }

/* === BIS v1.2 Phase 2 — Landing hero on Deep Purple === */
.lp-hero {
  background: var(--deep-purple);
  padding: 80px 24px 72px;
  text-align: center;
  color: #FFFFFF;
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  margin: 16px 16px 0;
}

/* Single decorative motif — subtle white circle, upper-right.
   Replaces the prior dual purple/amber orbs. */
.lp-hero::after {
  content: '';
  position: absolute;
  top: -120px;
  right: -120px;
  width: 480px;
  height: 480px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.04);
  pointer-events: none;
  z-index: 0;
}

/* Lift hero contents above the decorative layer. */
.lp-hero > * {
  position: relative;
  z-index: 1;
}

@media (max-width: 768px) {
  .lp-hero::after {
    width: 280px;
    height: 280px;
    top: -80px;
    right: -80px;
  }
}

.lp-hero-inner { position: relative; z-index: 1; max-width: 680px; margin: 0 auto; }

.lp-hero-badge {
  /* BIS v1.2 Phase 2 — pill on Deep Purple, refined contrast. */
  display: inline-flex;
  align-items: center;
  padding: 6px 16px;
  background: rgba(255, 255, 255, 0.08);
  color: #FFFFFF;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: var(--radius-pill);
  font-family: var(--font-body);
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: .3px;
  margin-bottom: 2rem;
}

.lp-hero-brand {
  font-size: clamp(2.4rem, 6.5vw, 3.6rem);
  /* v1.13.0 Phase 2 — wordmark on dark navy hero. Phase 1 used deep-purple
     #4A2D7A which was too dark. Switched to a brand-aligned light lavender
     #B89FD9 per Phase 2 spec recommendation; reads cleanly at WCAG AA. */
  font-family: var(--font-wordmark);
  font-weight: 600;
  letter-spacing: 1px;
  line-height: 1;
  color: #B89FD9;
  margin: 0 0 14px;
  text-align: center;
}

.lp-hero-h1 {
  /* BIS v1.2 Phase 2 — this h1 IS the canonical tagline ("The life skills
     nobody taught you"). The .tagline + .tagline--on-dark + .tagline--lg
     classes (added to the markup) handle font-family, font-style, font-weight,
     color, line-height, letter-spacing. We override only the size at hero
     scale and the bottom margin. */
  font-size: clamp(1.8rem, 5vw, 2.8rem);
  margin-bottom: 16px;
}

.lp-hero-sub {
  /* BIS v1.2 Phase 2 — Playfair Display Bold white subheading on Deep Purple.
     Visibly smaller than the wordmark, larger than body. */
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.25rem, 2.5vw, 1.75rem);
  color: #FFFFFF;
  line-height: 1.3;
  letter-spacing: -0.01em;
  margin: 0.5em auto 1em;
  max-width: 520px;
}

.lp-hero-tagline {
  /* BIS v1.2 Phase 2 — descriptor line softened to DM Sans 400, semi-
     transparent white. Italic removed (italic on this line competed with
     the tagline italic above). */
  font-family: var(--font-body);
  font-weight: 400;
  font-style: normal;
  color: rgba(255, 255, 255, 0.75);
  font-size: 1rem;
  line-height: 1.6;
  margin: 0 auto 2rem;
  max-width: 36rem;
  opacity: 1;
}

.lp-hero-cta {
  margin-top: 20px;
  text-align: center;
}

.lp-hero-btns { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
/* v1.19.2 — small "Already have an account? Sign in" link below the
   primary "Get Started Free" CTA so returning users (the cohort that
   v1.19.1 sign-out cleanup left without a top-nav affordance on /)
   can find /login from the landing hero. White-on-purple, DM Sans
   to match the hero typography. */
.lp-hero-signin-prompt {
  font-family: 'DM Sans', system-ui, sans-serif;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.78);
  margin: 12px 0 0;
  text-align: center;
}
.lp-hero-signin-prompt a {
  color: #ffffff;
  text-decoration: underline;
  text-underline-offset: 2px;
  font-weight: 500;
}
.lp-hero-signin-prompt a:hover { text-decoration: none; }
.lp-hero-signin-prompt a:focus-visible {
  outline: 2px solid #ffffff;
  outline-offset: 3px;
  border-radius: 2px;
}
.lp-hero-learn-btns {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 14px;
}
.lp-btn-lg { padding: 16px 32px; font-size: 1.05rem; }

/* === BIS v1.2 Phase 2 — hero button hierarchy ===
   Primary CTA gets a full pill radius and a hero-scoped hover; the 6
   secondary buttons recede to a quiet ghost style on Deep Purple so the
   eye lands on Get Started Free first. Scoped to .lp-hero so reuses of
   .btn-primary / .lp-btn-outline elsewhere stay untouched. */

.lp-hero .btn-primary {
  background: var(--amber);
  color: #FFFFFF;
  font-family: var(--font-body);
  font-weight: 600;
  border: none;
  border-radius: var(--radius-pill);
  cursor: pointer;
  transition: background 150ms ease, transform 100ms ease;
}
.lp-hero .btn-primary:hover {
  background: #B8741F;
  transform: none;       /* override the global lift effect on dark hero */
  box-shadow: none;
}
.lp-hero .btn-primary:active {
  transform: scale(0.97);
}

/* Ghost secondary buttons on Deep Purple — replace the teal-outlined treatment
   from the global .lp-btn-outline (which still applies to other surfaces). */
.lp-hero .lp-btn-outline {
  background: rgba(255, 255, 255, 0.06);
  color: #FFFFFF;
  font-family: var(--font-body);
  font-weight: 500;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: var(--radius-md);
  font-size: 1rem;
  transition: background 150ms ease, border-color 150ms ease;
}
.lp-hero .lp-btn-outline:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #FFFFFF;
  border-color: rgba(255, 255, 255, 0.32);
  box-shadow: none;
  transform: none;
}

/* Hero twin outline buttons — Vivoso green, identical style */
.lp-btn-outline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: transparent;
  color: #1D9E75;
  border: 2px solid #1D9E75;
  border-radius: var(--radius-sm);
  font-weight: 700;
  font-family: var(--font);
  cursor: pointer;
  transition: all .15s;
}
.lp-btn-outline:hover {
  background: #1D9E75;
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(29, 158, 117, .25);
}
.lp-hero-learn-btns .lp-btn-outline {
  flex: 0 1 240px;
}

/* Landing hero rotator — visible on /, separate from the tabbed "What You'll Learn" rotator. */
.lp-hero-taught-section { text-align: center; }
.lp-hero-taught-rotator {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin: 24px auto 0;
  max-width: 920px;
}
.lp-hero-taught-card {
  --taught-color: #1D9E75;
  flex: 1;
  position: relative;
  padding: 36px 28px 44px;
  border-radius: 20px;
  background: color-mix(in srgb, var(--taught-color) 8%, #fff);
  border: 1.5px solid color-mix(in srgb, var(--taught-color) 25%, #fff);
  box-shadow: 0 6px 24px color-mix(in srgb, var(--taught-color) 18%, transparent);
  transition: background .6s ease, border-color .6s ease, box-shadow .6s ease;
  overflow: hidden;
}
.lp-hero-taught-stage {
  position: relative;
  min-height: 180px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.lp-hero-taught-item {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  opacity: 0;
  transition: opacity .6s ease;
  font-size: clamp(1.4rem, 3.2vw, 2.2rem);
  font-weight: 800;
  line-height: 1.3;
  color: var(--taught-color, #1D9E75);
  padding: 0 12px;
  pointer-events: none;
  text-align: center;
}
.lp-hero-taught-item.active { opacity: 1; pointer-events: auto; }
.lp-hero-taught-dot {
  display: inline-block;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #F59E0B;
  box-shadow: 0 0 0 4px rgba(245, 158, 11, .18);
  flex-shrink: 0;
}
.lp-hero-taught-text { display: inline-block; max-width: 860px; }
.lp-hero-taught-nav {
  background: #fff;
  border: 1.5px solid var(--border, #E5E7EB);
  width: 48px;
  height: 48px;
  border-radius: 999px;
  font-size: 1.8rem;
  line-height: 1;
  cursor: pointer;
  color: var(--text-secondary, #6B7280);
  flex: 0 0 auto;
  transition: all .15s ease;
}
.lp-hero-taught-nav:hover { color: #1D9E75; border-color: #1D9E75; }
.lp-hero-taught-list-fallback { display: none; }
@media (max-width: 540px) {
  .lp-hero-taught-nav { width: 40px; height: 40px; font-size: 1.5rem; }
  .lp-hero-taught-stage { min-height: 200px; }
  .lp-hero-taught-card { padding: 28px 18px 38px; }
  .lp-hero-taught-dot { width: 10px; height: 10px; }
}
@media (prefers-reduced-motion: reduce) {
  .lp-hero-taught-rotator { display: none; }
  .lp-hero-taught-list-fallback {
    display: block; list-style: none; padding: 0; margin: 24px auto 0;
    max-width: 640px; text-align: left;
  }
  .lp-hero-taught-list-fallback li {
    padding: 12px 4px; border-bottom: 1px solid var(--border);
    font-size: 1rem; display: flex; align-items: center; gap: 10px;
  }
  .lp-hero-taught-list-fallback li:last-child { border-bottom: none; }
}

/* Sections */
.lp-section {
  padding: 64px 24px;
  max-width: 960px;
  margin: 0 auto;
}

.lp-section-dark {
  background: #0F172A;
  max-width: 100%;
  padding: 64px 24px;
}

.lp-section-dark .lp-section-title,
.lp-section-dark .lp-section-sub {
  max-width: 960px;
  margin-left: auto;
  margin-right: auto;
}

.lp-section-light { background: var(--bg); max-width: 100%; padding: 64px 24px; }
.lp-section-light > * { max-width: 960px; margin-left: auto; margin-right: auto; }

.lp-section-title {
  font-size: 1.8rem;
  font-weight: 900;
  text-align: center;
  letter-spacing: -0.5px;
  margin-bottom: 12px;
}

.lp-section-sub {
  text-align: center;
  color: var(--text-secondary);
  font-size: 1rem;
  margin-bottom: 36px;
}

/* Steps */
.lp-steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
}

.lp-step {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 24px;
  text-align: center;
}

.lp-step-num {
  width: 44px; height: 44px;
  border-radius: 50%;
  background: var(--primary);
  color: white;
  font-size: 1.1rem;
  font-weight: 900;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px;
}

.lp-step h3 { font-size: 1rem; font-weight: 800; margin-bottom: 8px; }
.lp-step p { font-size: .88rem; color: var(--text-secondary); line-height: 1.6; }

/* Pathway cards on landing */
.lp-pathways-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 12px;
  max-width: 960px;
  margin: 0 auto;
}

.lp-pathway-card {
  position: relative;
  overflow: hidden;
  background: var(--surface);
  /* v1.28.7 — Border-width standardized to 1.5px (matches /pathways);
     border-color is set inline per pathway from PATHWAYS.outlineColor. */
  border-width: 1.5px;
  border-style: solid;
  border-radius: var(--radius-sm);
  padding: 20px 16px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  text-align: center;
  color: var(--text);
  box-shadow: 0 2px 4px rgba(0,0,0,0.06), 0 4px 12px rgba(0,0,0,0.08);
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}

.lp-pathway-card:hover {
  box-shadow: 0 6px 12px rgba(0,0,0,0.08), 0 12px 24px rgba(0,0,0,0.10);
}

@media (prefers-reduced-motion: no-preference) {
  .lp-pathway-card:hover { transform: translateY(-2px); }
}

.lp-pathway-name { font-size: .85rem; font-weight: 700; color: var(--text); }

/* ---- Course Structure (See What You'll Learn tab) ---- */
.course-structure {
  margin-top: 64px;
  text-align: center;
}
.course-structure-heading { margin-top: 0; }
.course-structure-flow {
  display: flex;
  align-items: stretch;
  justify-content: center;
  gap: 8px;
  flex-wrap: nowrap;
  margin: 32px auto 24px;
  max-width: 1080px;
}
.course-structure-step {
  flex: 1 1 0;
  min-width: 0;
  background: #ECE7F3;
  border: 1px solid #D9CEE8;
  border-radius: var(--radius-sm);
  padding: 20px 14px 18px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  box-shadow: 0 2px 4px rgba(0,0,0,0.04), 0 4px 10px rgba(107,70,160,0.08);
  transition: transform .25s ease, box-shadow .25s ease;
}
.course-structure-num {
  font-family: var(--font);
  font-size: 2.4rem;
  font-weight: 900;
  line-height: 1;
  color: #6B46A0;
  margin-bottom: 8px;
}
.course-structure-step-title {
  font-family: var(--font);
  font-size: .95rem;
  font-weight: 800;
  color: var(--text);
  margin: 0 0 6px;
  line-height: 1.3;
}
.course-structure-step-desc {
  font-family: var(--font);
  font-size: .82rem;
  font-weight: 500;
  color: var(--text-secondary);
  line-height: 1.45;
  margin: 0;
}
.course-structure-chevron {
  flex: 0 0 auto;
  align-self: center;
  font-size: 1.6rem;
  font-weight: 700;
  color: #6B46A0;
  opacity: .55;
  user-select: none;
}
.course-structure-tagline {
  font-size: .9rem;
  font-weight: 600;
  color: var(--text-secondary);
  text-align: center;
  margin: 8px auto 0;
}

@media (prefers-reduced-motion: no-preference) {
  .course-structure-step:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.06), 0 10px 20px rgba(107,70,160,0.14);
  }
}

@media (max-width: 880px) {
  .course-structure-flow {
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
    max-width: 460px;
  }
  .course-structure-step { padding: 18px 16px; }
  .course-structure-chevron {
    transform: rotate(90deg);
    margin: 2px auto;
  }
}

/* ---- "EXAMPLE" pill badge for mockup cards ---- */
.mockup-example-pill {
  position: absolute;
  top: 12px;
  right: 12px;
  background: #ECE7F3;
  color: #8B7AAB;
  font-size: 10px;
  letter-spacing: 0.08em;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 12px;
  text-transform: uppercase;
  pointer-events: none;
  z-index: 2;
}

/* ---- In-Section Quizzes mockup ---- */
.in-section-quiz-mockup {
  margin-top: 64px;
  padding: 48px 32px 44px;
  background: #F8F6FB;
  border-radius: var(--radius);
  text-align: center;
}
.in-section-quiz-mockup-explainer {
  font-size: .98rem;
  line-height: 1.6;
  color: var(--text-secondary);
  max-width: 720px;
  margin: 16px auto 28px;
}
.in-section-quiz-mockup-card {
  position: relative;
  max-width: 640px;
  margin: 0 auto;
  background: #fff;
  border: 2px solid rgba(107, 70, 160, 0.25);
  border-radius: var(--radius);
  padding: 24px 26px 22px;
  text-align: left;
  box-shadow: 0 4px 20px rgba(107, 70, 160, 0.10), 0 2px 6px rgba(0, 0, 0, 0.04);
}
.in-section-quiz-mockup-eyebrow {
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: #6B46A0;
  margin-bottom: 12px;
}
.in-section-quiz-mockup-question {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 1.18rem;
  font-weight: 700;
  line-height: 1.4;
  color: var(--text);
  margin: 0 0 18px;
}
.in-section-quiz-mockup-choices {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.in-section-quiz-mockup-choice {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 14px;
  background: #fff;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: .92rem;
  line-height: 1.45;
  color: var(--text);
  cursor: default;
  transition: border-color .15s ease;
}
.in-section-quiz-mockup-choice:hover {
  border-color: #C9B7E0;
}
.in-section-quiz-mockup-choice-letter {
  flex: 0 0 auto;
  width: 24px;
  height: 24px;
  border-radius: 999px;
  background: #ECE7F3;
  color: #6B46A0;
  font-weight: 800;
  font-size: .78rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.in-section-quiz-mockup-choice-text { flex: 1; min-width: 0; }
.in-section-quiz-mockup-caption {
  font-size: .78rem;
  color: var(--text-muted);
  text-align: center;
  margin: 14px 0 0;
  font-style: italic;
}
.in-section-quiz-mockup-tagline {
  font-size: .9rem;
  font-weight: 600;
  color: var(--text-secondary);
  text-align: center;
  margin: 22px auto 0;
}

@media (max-width: 540px) {
  .in-section-quiz-mockup {
    padding: 36px 18px 32px;
    margin-left: -24px;
    margin-right: -24px;
    border-radius: 0;
  }
  .in-section-quiz-mockup-card { padding: 20px 18px 18px; }
  .in-section-quiz-mockup-question { font-size: 1.05rem; }
}

/* ---- Pathway Certification mockup ---- */
.pathway-cert-mockup {
  margin-top: 64px;
  padding: 48px 32px 44px;
  background: #F8F6FB;
  border-radius: var(--radius);
  text-align: center;
}
.pathway-cert-mockup-explainer {
  font-size: .98rem;
  line-height: 1.6;
  color: var(--text-secondary);
  max-width: 720px;
  margin: 16px auto 28px;
}
.pathway-cert-mockup-card {
  position: relative;
  max-width: 720px;
  margin: 0 auto;
  background: #fff;
  border: 2px solid rgba(107, 70, 160, 0.25);
  border-radius: var(--radius);
  padding: 26px 24px 0;
  text-align: left;
  box-shadow: 0 4px 20px rgba(107, 70, 160, 0.10), 0 2px 6px rgba(0, 0, 0, 0.04);
  overflow: hidden;
}
.pathway-cert-mockup-header {
  text-align: center;
  margin-bottom: 22px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--border);
}
.pathway-cert-mockup-title {
  font-family: var(--font);
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--text);
  margin: 0 0 6px;
  letter-spacing: -0.01em;
}
.pathway-cert-mockup-meta {
  font-size: .82rem;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--text-secondary);
}
.pathway-cert-mockup-questions {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.pathway-cert-mockup-question {
  background: #FBFAFD;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 18px 20px;
}
.pathway-cert-mockup-q-num {
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 6px;
}
.pathway-cert-mockup-q-text {
  font-size: .98rem;
  font-weight: 700;
  line-height: 1.45;
  color: var(--text);
  margin: 0 0 12px;
}
.pathway-cert-mockup-choices {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.pathway-cert-mockup-choice {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 14px;
  background: #fff;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: .9rem;
  line-height: 1.4;
  color: var(--text);
  cursor: default;
}
.pathway-cert-mockup-choice-letter {
  flex: 0 0 auto;
  width: 22px;
  height: 22px;
  border-radius: 999px;
  background: #ECE7F3;
  color: #6B46A0;
  font-weight: 800;
  font-size: .74rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.pathway-cert-mockup-choice-text { flex: 1; min-width: 0; }
.pathway-cert-mockup-ellipsis {
  text-align: center;
  font-size: .85rem;
  font-weight: 600;
  color: var(--text-muted);
  letter-spacing: .03em;
  padding: 14px 0 6px;
}
.pathway-cert-mockup-submit-bar {
  margin: 18px -24px 0;
  padding: 14px 16px;
  background: var(--surface);
  border-top: 1.5px solid var(--border);
  display: flex;
  justify-content: center;
}
.pathway-cert-mockup-submit-btn {
  width: 100%;
  max-width: 440px;
  padding: 12px 20px;
  font-family: var(--font);
  font-size: .95rem;
  font-weight: 800;
  letter-spacing: .01em;
  background: var(--border);
  color: var(--text-muted);
  border: none;
  border-radius: var(--radius-sm);
  cursor: not-allowed;
  box-shadow: none;
}
.pathway-cert-mockup-tagline {
  font-size: .9rem;
  font-weight: 600;
  color: var(--text-secondary);
  text-align: center;
  margin: 22px auto 0;
}

@media (max-width: 540px) {
  .pathway-cert-mockup {
    padding: 36px 18px 32px;
    margin-left: -24px;
    margin-right: -24px;
    border-radius: 0;
  }
  .pathway-cert-mockup-card { padding: 22px 18px 0; }
  .pathway-cert-mockup-question { padding: 16px 14px; }
  .pathway-cert-mockup-submit-bar { margin: 18px -18px 0; }
}

/* Certificate tiers */
.lp-cert-tiers {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
}

.lp-cert-tier {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 24px;
  text-align: center;
}

.lp-cert-icon {
  width: 56px; height: 56px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  margin: 0 auto 16px;
  color: white;
}

/* Wrapper for the SVG centerpiece on each of the three landing-page
   "tier" teaser cards. Keeps the SVG centered and gives it a little
   breathing room. */
.lp-cert-icon-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px;
  min-height: 100px;
}
.lp-cert-icon-wrap svg { display: block; filter: drop-shadow(0 4px 14px rgba(17, 24, 39, .15)); }

.lp-cert-tier h3 { font-size: 1rem; font-weight: 800; margin-bottom: 8px; }
.lp-cert-tier p { font-size: .85rem; color: var(--text-secondary); line-height: 1.6; }

/* Pricing */
.lp-pricing-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  max-width: 1180px;
  margin: 24px auto 0;
}

/* ---- Landing Testimonials ---- */
.lp-testimonials { padding-top: 40px; padding-bottom: 40px; }
.lp-testimonial-group { margin-top: 32px; }
.lp-testimonial-group + .lp-testimonial-group { margin-top: 40px; }
.lp-testimonial-group-label {
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--primary);
  text-align: center;
  margin-bottom: 16px;
}
.lp-testimonial-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
  max-width: 880px;
  margin: 0 auto;
}
.lp-testimonial-card {
  position: relative;
  margin: 0;
  padding: 28px 26px 22px;
  background: #faf7ff;
  border: 1px solid #ede9fe;
  border-radius: 16px;
  overflow: hidden;
  opacity: 0;
  transform: translateY(12px);
  animation: lp-testimonial-fade-in .6s ease-out forwards;
}
.lp-testimonial-card::before {
  content: '\201C';
  position: absolute;
  top: -28px;
  left: 10px;
  font-family: Georgia, 'Times New Roman', serif;
  font-size: 11rem;
  line-height: 1;
  color: rgba(124, 58, 237, 0.08);
  pointer-events: none;
  user-select: none;
}
.lp-testimonial-quote {
  position: relative;
  margin: 0 0 14px;
  font-size: 1.02rem;
  line-height: 1.55;
  color: var(--text);
  font-weight: 500;
}
.lp-testimonial-attribution {
  position: relative;
  font-size: 0.82rem;
  color: var(--text-muted);
  font-weight: 600;
  letter-spacing: 0.01em;
}
.lp-testimonial-grid .lp-testimonial-card:nth-child(1) { animation-delay: .00s; }
.lp-testimonial-grid .lp-testimonial-card:nth-child(2) { animation-delay: .12s; }
.lp-testimonial-grid .lp-testimonial-card:nth-child(3) { animation-delay: .24s; }
.lp-testimonial-grid .lp-testimonial-card:nth-child(4) { animation-delay: .36s; }
@keyframes lp-testimonial-fade-in {
  to { opacity: 1; transform: translateY(0); }
}
@media (max-width: 720px) {
  .lp-testimonial-grid { grid-template-columns: minmax(0, 1fr); }
  .lp-testimonial-card::before { font-size: 9rem; top: -22px; }
}
@media (prefers-reduced-motion: reduce) {
  .lp-testimonial-card {
    opacity: 1;
    transform: none;
    animation: none;
  }
}

.lp-price-card {
  background: var(--surface);
  border: 1.5px solid var(--primary);
  border-radius: var(--radius);
  padding: 28px 24px;
  display: flex;
  flex-direction: column;
  position: relative;
}

.lp-price-featured {
  border-color: var(--primary);
}

.lp-price-popular {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--primary);
  color: white;
  font-size: .72rem;
  font-weight: 800;
  padding: 4px 14px;
  border-radius: 100px;
  text-transform: uppercase;
  letter-spacing: .8px;
  white-space: nowrap;
}

.lp-price-badge {
  font-size: .8rem;
  font-weight: 700;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: .5px;
  margin-bottom: 12px;
}

.lp-price-amount {
  font-size: 2.2rem;
  font-weight: 900;
  color: var(--text);
  margin-bottom: 4px;
}

.lp-price-amount span { font-size: 1rem; font-weight: 600; color: var(--text-secondary); }

.lp-price-period {
  font-size: .82rem;
  color: var(--text-muted);
  margin-bottom: 20px;
}

.lp-price-features {
  list-style: none;
  padding: 0;
  margin: 0 0 20px;
  flex: 1;
}

.lp-price-features li {
  font-size: .85rem;
  color: var(--text-secondary);
  padding: 8px 0;
  border-bottom: 1px solid var(--border);
  line-height: 1.5;
}

.lp-price-features li:last-child { border-bottom: none; }

.lp-price-features li::before {
  content: '✓ ';
  color: var(--success);
  font-weight: 700;
}

/* CTA */
.lp-cta {
  text-align: center;
  background: linear-gradient(135deg, #7C3AED 0%, #5B21B6 100%);
  max-width: 100%;
  padding: 64px 24px;
  color: white;
  border-radius: 24px;
  margin: 16px;
  overflow: hidden;
}

.lp-cta-title {
  font-size: clamp(1.5rem, 4vw, 2rem);
  font-weight: 900;
  margin-bottom: 24px;
  letter-spacing: -0.5px;
}

/* Certificate Showcase — borderless banner-band layout (v1.14.4) */
.lp-cert-showcase {
  display: flex;
  justify-content: center;
  align-items: flex-start;
  gap: 28px;
  flex-wrap: wrap;
  margin-bottom: 32px;
}

.lp-cert-preview {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}

/* Certificate document — borderless, paper-like depth via shadow only.
   Inset gray outline (offset -16px) defines the document area without
   hugging the paper edge — won't print-clip like the heavy borders did. */
/* v1.37.x — Simplified v4-evocation preview card. Neutral Moonlight-tint base,
   thin Bone frame + inset accent border. Tier accent (Steel = Pathway default,
   Amber = Master override below) via tokens — these render in the main document,
   so var() resolves (unlike the printed cert window). */
.lp-cert-doc {
  width: 400px;
  aspect-ratio: 1.4 / 1;
  background: var(--moonlight-tint);
  border-radius: 6px;
  box-shadow: 0 6px 24px rgba(15, 23, 42, .10), 0 1px 3px rgba(15, 23, 42, .06);
  border: 1px solid var(--bone);
  text-align: center;
  position: relative;
  overflow: hidden;
  padding: 26px 24px 22px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 9px;
  /* Neutralize the body { line-height: 1.6 } cascade for the compact card. */
  line-height: 1.2;
}
.lp-cert-master-wrap .lp-cert-doc,
.lp-cert-pathway-wrap .lp-cert-doc { width: 400px; }

/* Thin inset accent frame — Steel default (Pathway); Amber for Master below. */
.lp-cert-doc::after {
  content: '';
  position: absolute;
  inset: 7px;
  border: 0.75px solid var(--steel);
  border-radius: 4px;
  pointer-events: none;
}

/* VIVOSO wordmark */
.lp-cert-doc-wordmark {
  font-family: var(--font);
  font-weight: 700;
  font-size: .62rem;
  letter-spacing: 4px;
  color: var(--oxford);
  padding-left: 4px;
}

/* Thin accent rule */
.lp-cert-doc-rule {
  width: 44px;
  height: 2px;
  background: var(--steel);
}

/* Tier eyebrow */
.lp-cert-doc-eyebrow {
  font-family: var(--font);
  font-weight: 600;
  font-size: .5rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--steel);
}

/* Recipient name — Playfair, Oxford */
.lp-cert-doc-name {
  font-family: 'Playfair Display', Georgia, serif;
  font-weight: 600;
  font-size: 1.15rem;
  color: var(--oxford);
  line-height: 1.1;
}

/* Mini "V" seal — simple ring + center V (no arc text; legible at thumbnail
   size). Colors via CSS tokens per tier (so the inline SVG needs no hex). */
.lp-cert-doc-seal { display: flex; align-items: center; justify-content: center; }
.lp-cert-seal-mini { display: block; width: 50px; height: 50px; }
.lp-cert-seal-ring { fill: var(--moonlight-tint); stroke: var(--steel); stroke-width: 2; }
.lp-cert-seal-ring-inner { fill: none; stroke: var(--steel); stroke-width: 0.75; }
.lp-cert-seal-v { font-family: 'Playfair Display', Georgia, serif; font-weight: 700; font-size: 28px; fill: var(--oxford); }

/* Tier label */
.lp-cert-doc-tier {
  font-family: var(--font);
  font-weight: 600;
  font-size: .5rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--steel);
}

/* Master tier = Amber accent (overrides the Steel defaults above). */
.lp-cert-doc.lp-cert-master::after { border-color: var(--amber); }
.lp-cert-master .lp-cert-doc-rule { background: var(--amber); }
.lp-cert-master .lp-cert-doc-eyebrow { color: var(--amber); }
.lp-cert-master .lp-cert-seal-ring { stroke: var(--amber); }
.lp-cert-master .lp-cert-seal-ring-inner { stroke: var(--amber); }
.lp-cert-master .lp-cert-doc-tier { color: var(--amber); }

/* Captions */
.lp-cert-caption {
  text-align: center;
  max-width: 220px;
}

.lp-cert-caption strong {
  display: block;
  font-size: .85rem;
  font-weight: 800;
  margin-bottom: 4px;
}

.lp-cert-caption span {
  font-size: .78rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

.lp-cert-note {
  text-align: center;
  font-size: .88rem;
  color: var(--text-secondary);
  line-height: 1.6;
  max-width: 560px;
  margin: 0 auto 12px;
}

/* The landing previews are clickable triggers that open the real full-size
   certificate in a lightbox (openCertLightbox). Subtle lift + accent ring. */
.lp-cert-preview {
  cursor: pointer;
  transition: transform .18s ease;
  outline: none;
}
.lp-cert-preview:hover .lp-cert-doc,
.lp-cert-preview:focus-visible .lp-cert-doc {
  transform: translateY(-4px);
  box-shadow: 0 14px 34px rgba(15, 23, 42, .16), 0 2px 6px rgba(15, 23, 42, .08);
}
.lp-cert-doc { transition: transform .18s ease, box-shadow .18s ease; }
.lp-cert-preview:focus-visible .lp-cert-doc {
  outline: 2px solid var(--amber);
  outline-offset: 3px;
}
.lp-cert-clickhint {
  text-align: center;
  font-size: .82rem;
  font-weight: 600;
  letter-spacing: .2px;
  color: var(--amber);
  margin: 0 auto 14px;
}

/* v1.39.8 — Prominent "view a sample" buttons that replace the old clickable
   fake-cert thumbnails. Amber solid fill (mirrors .gift-buy-btn /
   .c01-signup-cta), NOT the legacy teal .btn-primary. */
.lp-cert-view-btn {
  font-family: var(--font);
  font-size: 1rem;
  font-weight: 700;
  color: #ffffff;
  background: var(--amber);
  border: 1.5px solid var(--amber);
  border-radius: var(--radius-sm);
  padding: 14px 28px;
  cursor: pointer;
  transition: background .15s, border-color .15s, transform .12s, box-shadow .15s;
}
.lp-cert-view-btn:hover {
  background: #B8741F;
  border-color: #B8741F;
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(212, 136, 42, .35);
}
.lp-cert-view-btn:focus-visible {
  outline: 2px solid var(--amber);
  outline-offset: 3px;
}
/* Each tier = button stacked over its caption; these are the grid items of
   .lp-cert-showcase. */
.lp-cert-view-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

/* ---- Sample-certificate lightbox (renders the real cert in an iframe) ---- */
.cert-lightbox-overlay {
  z-index: 240; /* above the standard .modal-overlay (200) */
  overflow: auto;
}
/* Wide variant of the modal box — the cert is far wider than the 460px
   .modal-box cap, so this box sizes to its (scaled) contents instead. */
.cert-lightbox-box {
  position: relative;
  background: transparent;
  box-shadow: none;
  padding: 0;
  width: auto;
  max-width: none;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.cert-lightbox-stage {
  position: relative;
  background: #FAF8F2;
  border-radius: 4px;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}
.cert-lightbox-frame {
  position: absolute;
  top: 0;
  left: 0;
  border: 0;
  background: #FAF8F2;
  transform-origin: top left;
}
.cert-lightbox-close {
  position: absolute;
  top: -42px;
  right: 0;
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, .94);
  color: #02122F;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 10px rgba(0, 0, 0, .3);
}
.cert-lightbox-close:hover { background: #fff; }

@media (max-width: 720px) {
  /* On small screens the close button has no room above the cert; tuck it
     into the top-right corner of the stage instead. */
  .cert-lightbox-close { top: 8px; right: 8px; }
}

.lp-cert-share-icons {
  display: flex;
  justify-content: center;
  gap: 12px;
  font-size: 1.2rem;
  opacity: .5;
}

/* About page cert mini */
.about-feature-cert {
  position: relative;
}

.about-cert-mini {
  margin-bottom: 8px;
}

.about-cert-mini-doc {
  width: 90px;
  margin: 0 auto;
  padding: 8px 6px;
  background: white;
  border: 2px solid #1a2e5a;
  border-radius: 3px;
  box-shadow: 0 2px 8px rgba(0,0,0,.08);
  text-align: center;
}

.about-cert-mini-doc::before {
  content: '';
  position: absolute;
  inset: 2px;
  border: 1px solid #ca8a04;
  border-radius: 2px;
  pointer-events: none;
}

.about-cert-tagline {
  font-size: .75rem !important;
  font-weight: 700 !important;
  color: var(--primary) !important;
  margin-top: 6px;
}

@media (max-width: 720px) {
  .lp-cert-showcase { flex-direction: column; align-items: center; }
  .lp-cert-doc,
  .lp-cert-master-wrap .lp-cert-doc,
  .lp-cert-pathway-wrap .lp-cert-doc { width: 280px; }
}

/* Landing Footer */
.lp-footer {
  background: #0F172A;
  padding: 24px;
}

.lp-footer-inner {
  max-width: 960px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.lp-footer-brand {
  color: rgba(255,255,255,.6);
  font-size: .85rem;
  font-weight: 700;
}

.lp-footer-link {
  color: rgba(255,255,255,.5);
  font-size: .82rem;
  cursor: pointer;
  text-decoration: none;
  transition: color .15s;
}

.lp-footer-link:hover {
  color: rgba(255,255,255,.8);
}

/* ---- PARENTS PAGE ---- */
.parents-page {
  max-width: 740px;
  margin: 0 auto;
  padding: 0 20px 60px;
}

.parents-header {
  text-align: center;
  margin-bottom: 40px;
}

.parents-header h1 {
  font-size: 2rem;
  font-weight: 900;
  letter-spacing: -0.5px;
  margin-bottom: 16px;
}

.parents-header p {
  color: var(--text-secondary);
  font-size: 1rem;
  line-height: 1.7;
  max-width: 600px;
  margin: 0 auto;
}

.parents-section {
  margin-bottom: 40px;
}

.parents-section h2 {
  font-size: 1.4rem;
  font-weight: 800;
  margin-bottom: 16px;
  letter-spacing: -0.3px;
}

.parents-section p {
  color: var(--text-secondary);
  font-size: .92rem;
  line-height: 1.7;
  margin-bottom: 12px;
}

/* Topics Grid */
.parents-topics-grid {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.parents-topic {
  /* v1.28.37 — White interior + 1.5px Amber border per BIS v1.3.
     Matches the v1.28.17 .about-feature treatment for visual consistency
     across "What X Teaches" cards on About and Parents pages. */
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 16px 18px;
  background: #FFFFFF;
  border: 1.5px solid var(--amber);
  border-radius: var(--radius-sm);
}

.parents-topic-icon {
  font-size: 1.4rem;
  flex-shrink: 0;
  line-height: 1;
  margin-top: 2px;
}

.parents-topic strong {
  display: block;
  font-size: .9rem;
  font-weight: 700;
  margin-bottom: 4px;
  color: var(--text);
}

.parents-topic p {
  font-size: .83rem;
  color: var(--text-secondary);
  line-height: 1.5;
  margin: 0;
}

/* Content Promise Box — v1.28.37 reconciled to BIS v1.3.
   Replaces the legacy green gradient + emerald-200 border + dark green
   text with white interior, 2px Amber border, Oxford heading, Steel
   body, Amber check-mark accent on each list item. Matches the v1.28.17
   "Why This Price?" callout treatment. */
.parents-promise-box {
  background: #FFFFFF;
  border: 2px solid var(--amber);
  border-radius: var(--radius);
  padding: 28px 24px;
}

.parents-promise-box h3 {
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--oxford);
  margin-bottom: 16px;
}

.parents-promise-box ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.parents-promise-box li {
  padding: 10px 0;
  font-size: .9rem;
  color: var(--steel);
  line-height: 1.6;
  border-bottom: 1px solid rgba(212, 136, 42, 0.20);
}

.parents-promise-box li:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.parents-promise-box li::before {
  content: '✓ ';
  color: var(--amber);
  font-weight: 800;
}

/* Age Tiers */
.parents-age-tiers {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.parents-age-tier {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
}

.parents-age-badge {
  display: inline-block;
  padding: 4px 14px;
  border-radius: 100px;
  color: white;
  font-size: .78rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .5px;
  margin-bottom: 12px;
}

.parents-age-tier p {
  margin: 0;
}

/* Contact Section */
.parents-contact-info {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 16px 20px;
  margin-bottom: 20px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.parents-contact-info div {
  font-size: .9rem;
  color: var(--text-secondary);
}

.parents-contact-info a {
  color: var(--primary);
  text-decoration: none;
  font-weight: 600;
}

.parents-contact-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.parents-contact-form input,
.parents-contact-form textarea {
  padding: 12px 16px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: .9rem;
  font-family: inherit;
  background: var(--surface);
  color: var(--text);
  transition: border-color .15s;
}

.parents-contact-form input:focus,
.parents-contact-form textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(124,58,237,.1);
}

.parents-contact-form textarea {
  resize: vertical;
  min-height: 100px;
}

/* For Young Adults Note */
.parents-note {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
}

.parents-note h2 {
  font-size: 1.1rem;
}

.parents-note p {
  margin: 0;
}

/* ---- APP FOOTER ---- */
.app-footer {
  margin-top: 48px;
  border-top: 1px solid var(--border);
  padding: 24px 20px;
}

.app-footer-inner {
  max-width: 960px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}

.app-footer-brand {
  font-size: .82rem;
  font-weight: 700;
  color: var(--text-muted);
}

.app-footer-links {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
}

.app-footer-link {
  font-size: .8rem;
  color: var(--text-secondary);
  cursor: pointer;
  text-decoration: none;
  transition: color .15s;
}

.app-footer-link:hover {
  color: var(--primary);
}

.app-footer-copyright {
  max-width: 960px;
  margin: 16px auto 0;
  padding-top: 16px;
  border-top: 1px solid var(--border);
  text-align: center;
  font-size: .75rem;
  color: var(--text-muted);
}

.app-footer-legal-row {
  max-width: 960px;
  margin: 14px auto 0;
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
}

/* ---- Minimal in-app footer (post-signup course/lesson pages) ---- */
.app-footer-minimal {
  margin-top: 48px;
  padding: 16px 20px;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  font-size: .7rem;
  color: var(--text-muted);
  opacity: .75;
}

.app-footer-minimal-link {
  color: var(--text-muted);
  text-decoration: none;
  cursor: pointer;
  transition: color .15s;
}

.app-footer-minimal-link:hover {
  color: var(--primary);
}

.app-footer-minimal-sep {
  color: var(--text-muted);
  opacity: .5;
}

.app-footer-minimal-version {
  color: var(--text-muted);
  opacity: .8;
}

/* ---- Audience tabs (Schools / Organizations) ---- */
.audience-tabs {
  display: flex;
  justify-content: center;
  gap: 8px;
  padding: 20px 16px 0;
  max-width: 1100px;
  margin: 0 auto;
}

.audience-tab {
  flex: 0 1 260px;
  text-align: center;
  padding: 12px 20px;
  border-radius: 999px;
  border: 1.5px solid var(--border, #E5E7EB);
  background: #fff;
  color: var(--text-secondary, #6B7280);
  font-weight: 700;
  font-size: .92rem;
  text-decoration: none;
  transition: all .15s ease;
}

.audience-tab:hover {
  border-color: var(--primary, #7C3AED);
  color: var(--primary, #7C3AED);
}

.audience-tab.active {
  background: var(--primary, #7C3AED);
  border-color: var(--primary, #7C3AED);
  color: #fff;
  box-shadow: 0 4px 14px rgba(124, 58, 237, .18);
}

@media (max-width: 540px) {
  .audience-tab { flex: 1; padding: 10px 14px; font-size: .85rem; }
}

/* ---- Post-signup top navigation layout ---- */
.header-nav-app {
  display: flex;
  align-items: center;
  gap: 16px;
  flex: 1;
  justify-content: space-between;
}

.header-nav-sections {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.header-nav-right {
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-btn-section {
  position: relative;
}

.nav-btn-section.active {
  color: var(--primary);
  background: var(--primary-light, rgba(124,58,237,.08));
  border-color: transparent;
}

.nav-btn-section.active::after {
  content: '';
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: -6px;
  height: 2px;
  background: var(--primary);
  border-radius: 2px;
}

.nav-btn-profile.active {
  color: var(--primary);
  background: var(--primary-light, rgba(124,58,237,.08));
}

/* ---- Refer a Friend prompt cards ---- */
.refer-prompt-card {
  display: flex;
  align-items: center;
  gap: 14px;
  background: linear-gradient(135deg, #FEF3C7, #FDE68A);
  border: 1.5px solid #F59E0B;
  border-radius: var(--radius);
  padding: 16px 20px;
  margin-top: 16px;
  cursor: pointer;
  transition: transform .15s, box-shadow .15s;
}

.refer-prompt-card:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(245,158,11,.18);
}

.refer-prompt-celebrate {
  background: linear-gradient(135deg, #DBEAFE, #E0E7FF);
  border-color: #6366F1;
  margin: 0 0 20px;
}

.refer-prompt-icon { font-size: 1.6rem; }
.refer-prompt-body { flex: 1; min-width: 0; }
.refer-prompt-title { font-weight: 800; color: #92400E; margin-bottom: 2px; }
.refer-prompt-celebrate .refer-prompt-title { color: #3730A3; }
.refer-prompt-msg { font-size: .85rem; color: #78350F; line-height: 1.4; }
.refer-prompt-celebrate .refer-prompt-msg { color: #4338CA; }
.refer-prompt-arrow { font-size: 1.3rem; color: #92400E; font-weight: 800; }
.refer-prompt-celebrate .refer-prompt-arrow { color: #3730A3; }

/* ---- Referral activity card (Refer a Friend page) — v1.28.42 BIS v1.3
   White interior with a 1.5px Amber outer border. Inner stat cells are clean
   white surfaces with a light Steel border so the numbers carry the visual
   weight. Replaces the legacy honey-cream gradient + inner Coming Soon hints. */
.referral-activity-card {
  background: #ffffff;
  border: 1.5px solid var(--amber);
  border-radius: var(--radius);
  padding: 22px 24px;
}
.referral-activity-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-bottom: 16px;
}
@media (max-width: 640px) {
  .referral-activity-grid { grid-template-columns: 1fr; }
}
.referral-stat {
  background: #ffffff;
  border: 1px solid rgba(73,91,125,.25);
  border-radius: 12px;
  padding: 14px 16px;
  text-align: center;
}
.referral-stat-label {
  font-size: .72rem;
  font-weight: 500;
  letter-spacing: .4px;
  text-transform: uppercase;
  color: var(--steel);
  margin-bottom: 6px;
}
.referral-stat-value {
  font-size: 2rem;
  font-weight: 800;
  color: var(--oxford);
  line-height: 1.1;
}
.referral-stat-value-sm { font-size: 1.1rem; }
.referral-activity-note {
  margin: 0;
  font-size: .88rem;
  color: var(--steel);
  line-height: 1.5;
  text-align: center;
}

/* ---- Profile subscription block ---- */
/* v1.28.41 — BIS v1.3 quiet status pill. Moonlight-tinted surface with a
   1px Amber border + Steel text reads as a "coming" indicator without
   competing with action buttons. Replaces the legacy teal/purple pill. */
.phase-tag {
  display: inline-block;
  margin-left: 6px;
  background: var(--moonlight);
  color: var(--steel);
  border: 1px solid var(--amber);
  font-size: .62rem;
  font-weight: 700;
  letter-spacing: .4px;
  padding: 2px 8px;
  border-radius: 999px;
  text-transform: uppercase;
  vertical-align: middle;
}
.profile-section-footnote {
  margin-top: 12px;
  font-size: .8rem;
  color: var(--text-secondary);
  line-height: 1.5;
  font-style: italic;
}

/* ---- Header profile button ---- */
.nav-btn-profile {
  display: inline-flex !important;
  align-items: center;
  gap: 8px;
}
.nav-profile-avatar { font-size: 1.05rem; }
.nav-profile-name { font-weight: 600; }

/* v1.19.3 — Account dropdown (Profile + Sign Out) replacing the buried
   Sign Out button on /profile. Standard SaaS pattern: trigger + chevron,
   absolute-positioned menu right-aligned below the trigger, click outside
   or Escape to close. */
.nav-account { position: relative; display: inline-flex; }
.nav-account-chevron {
  font-size: 0.7rem;
  margin-left: 2px;
  opacity: 0.7;
  transition: transform 120ms ease;
}
.nav-account-trigger[aria-expanded="true"] .nav-account-chevron,
#nav-account-trigger[aria-expanded="true"] .nav-account-chevron {
  transform: rotate(180deg);
}
.nav-account-menu {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  min-width: 180px;
  background: var(--surface, #ffffff);
  border: 1.5px solid var(--border, #E5E2EC);
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.12), 0 2px 6px rgba(15, 23, 42, 0.06);
  padding: 6px;
  z-index: 200;
  display: flex;
  flex-direction: column;
}
.nav-account-menu[hidden] { display: none; }
.nav-account-item {
  display: block;
  width: 100%;
  text-align: left;
  padding: 10px 14px;
  background: transparent;
  border: none;
  border-radius: 8px;
  font-family: var(--font);
  font-size: 14px;
  font-weight: 500;
  color: var(--text-primary, #1F1B2E);
  cursor: pointer;
  transition: background 120ms ease, color 120ms ease;
}
.nav-account-item:hover { background: var(--surface-alt, #F5F2FA); }
.nav-account-item:focus-visible {
  outline: 2px solid var(--primary, #6B46A0);
  outline-offset: -2px;
}
.nav-account-item--danger { color: var(--danger, #B91C1C); }
.nav-account-item--danger:hover { background: rgba(185, 28, 28, 0.08); }

/* Mobile menu danger variant for the Sign Out item we now also expose
   in the hamburger panel (the dropdown isn't reachable on mobile). */
.mobile-nav-link--danger { color: var(--danger, #B91C1C); }

/* ---- Profile page ---- */
.profile-page {
  max-width: 720px;
  margin: 0 auto;
  padding: 0 16px;
}
.profile-hero {
  text-align: center;
  padding: 32px 16px 24px;
}
.profile-hero-avatar {
  font-size: 3rem;
  margin-bottom: 8px;
}
.profile-hero h1 { margin: 0 0 6px; font-family: var(--font-display); font-weight: 700; letter-spacing: -0.4px; line-height: 1.2; }
.profile-hero-sub { color: var(--text-secondary); font-size: .9rem; line-height: 1.55; }
@media (max-width: 600px) {
  /* v1.12 Phase B5.2 — four-stat summary line can grow long on phones; allow
     natural wrapping with a touch more line-height for readability. */
  .profile-hero-sub { font-size: .85rem; padding: 0 6px; }
}

.profile-section {
  background: var(--bg, #fff);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 24px;
  margin-bottom: 16px;
}
.profile-section h2 {
  font-size: 1.05rem;
  margin: 0 0 8px;
}
/* v1.25.1 — Help & Support buttons. Flex with gap so all three buttons
   sit identically (replaces inline margin-left that left "Help Center"
   visually offset). Stacks full-width on mobile. */
.profile-help-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.profile-help-btn {
  text-align: center;
}
@media (max-width: 600px) {
  .profile-help-buttons { flex-direction: column; }
  .profile-help-btn { width: 100%; }
}
.profile-section-sub {
  color: var(--text-secondary);
  font-size: .88rem;
  margin: 0 0 14px;
  line-height: 1.5;
}

.refer-link-box {
  display: flex;
  gap: 8px;
  align-items: stretch;
}
.refer-link-input {
  flex: 1;
  min-width: 0;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-family: inherit;
  font-size: .85rem;
  background: #F9FAFB;
}
/* v1.28.41 — Amber-filled override (default .btn-primary resolves to teal).
   Matches the BIS v1.3 primary action treatment from the v1.28.40 sweep. */
.refer-copy-btn {
  white-space: nowrap;
  background: var(--amber);
  border: 1.5px solid var(--amber);
}
.refer-copy-btn:hover {
  background: #B8741F;
  border-color: #B8741F;
}
.refer-copy-status {
  font-size: .8rem;
  color: #059669;
  min-height: 1.2em;
  margin-top: 6px;
}
.redeem-submit-btn { white-space: nowrap; background: var(--amber); border: 1.5px solid var(--amber); }
.redeem-submit-btn:hover { background: #B8741F; border-color: #B8741F; }
.redeem-status { font-size: .8rem; min-height: 1.2em; margin-top: 6px; }
.redeem-status.is-success { color: var(--success, #059669); }
.redeem-status.is-error { color: #DC2626; }
.redeem-status.is-info { color: var(--amber, #D4882A); }
/* v1.39.49 — Redeem row stacks on phones. The base .refer-link-box rules
   (6497-6511) have no mobile scope anywhere in this file: at narrow widths the
   Apply button's inherited width crushes .refer-link-input, whose flex-basis is
   0, down to a few pixels. Column direction removes the row-axis competition
   entirely, so the button's width declaration no longer matters. font-size is
   raised to 16px here only to stop iOS Safari force-zooming on focus (.85rem
   base is under Safari's 16px threshold). Scoped to .redeem-code-box so the
   referral-link copy row that shares .refer-link-box is untouched. */
@media (max-width: 600px) {
  .refer-link-box.redeem-code-box {
    flex-direction: column;
    align-items: stretch;
  }
  .refer-link-box.redeem-code-box .refer-link-input {
    width: 100%;
    flex: 0 0 auto;
    font-size: 1rem;
  }
  .refer-link-box.redeem-code-box .redeem-submit-btn {
    width: 100%;
    flex: 0 0 auto;
  }
}

.profile-row {
  display: flex;
  justify-content: space-between;
  padding: 8px 0;
  border-bottom: 1px solid var(--border);
  font-size: .9rem;
}
.profile-row:last-child { border-bottom: none; }
.profile-row span:first-child { color: var(--text-secondary); }
.profile-row span:last-child { font-weight: 600; }

/* v1.15.7 — Editable account rows + multi-line interests row.
   Layout: label | value | pencil. The pencil button is a 44x44 tap
   target with a smaller visible glyph centered inside. The multi-row
   variant keeps the label top-aligned and stacks selected interests
   one-per-line in the value column. */
.profile-row--editable {
  align-items: center;
  gap: 12px;
}
.profile-row--editable > span:first-child {
  flex-shrink: 0;
}
.profile-row-value {
  flex: 1 1 auto;
  text-align: right;
  font-weight: 600;
  color: var(--text);
}
.profile-row--multi {
  align-items: flex-start;
}
.profile-row--multi > span:first-child {
  padding-top: 2px;
}
.profile-row-multi-values {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  gap: 4px;
  text-align: right;
}
.profile-row-multi-item {
  font-weight: 600;
  color: var(--text);
  font-size: .9rem;
}
.profile-edit-pencil {
  background: transparent;
  border: none;
  padding: 0;
  width: 44px;
  height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--text-secondary);
  border-radius: 8px;
  flex-shrink: 0;
  transition: color .15s ease, background-color .15s ease;
}
.profile-edit-pencil:hover {
  color: var(--vivoso-purple);
  background-color: var(--purple-tint);
}
.profile-edit-pencil:focus-visible {
  outline: 2px solid var(--vivoso-purple);
  outline-offset: 2px;
}
.profile-edit-pencil-svg {
  pointer-events: none;
}
.profile-agreement-check {
  color: #059669;
  font-weight: 700;
  margin-right: 4px;
}

/* Profile-edit screen action row — Cancel/Save sit side-by-side at
   the bottom of the screen, replacing the onboarding back-arrow +
   single Continue button. Re-uses .ob-screen layout otherwise. */
.profile-edit-screen .ob-heading,
.profile-edit-screen .ob-sub {
  text-align: center;
}
.profile-edit-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  align-items: center;
  margin-top: 24px;
  flex-wrap: wrap;
}
.profile-edit-cancel,
.profile-edit-save {
  min-width: 120px;
}

.lp-footer-copyright {
  max-width: 960px;
  margin: 16px auto 0;
  padding-top: 16px;
  border-top: 1px solid rgba(255,255,255,.08);
  text-align: center;
  font-size: .75rem;
  color: rgba(255,255,255,.4);
}

.footer-version {
  max-width: 960px;
  margin: 6px auto 0;
  text-align: center;
  font-size: .68rem;
  color: var(--text-muted);
  opacity: .7;
  letter-spacing: .5px;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
}
.lp-footer .footer-version {
  color: rgba(255,255,255,.3);
}

/* ---- PRICING PAGE ---- */
/* ---- Gift page (Give the gift of Vivoso) — mirrors .pricing-page conventions ---- */
.gift-page {
  max-width: 720px;
  margin: 0 auto;
  padding: 0 20px 60px;
}

.gift-hero {
  text-align: center;
  padding: 40px 0 32px;
}

.gift-hero h1 {
  font-size: clamp(1.6rem, 4vw, 2.2rem);
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: -0.5px;
  line-height: 1.2;
  color: var(--oxford);
  margin-bottom: 12px;
}

.gift-subtitle {
  font-size: 1rem;
  color: var(--text-secondary);
  line-height: 1.6;
  max-width: 480px;
  margin: 0 auto;
}

.gift-body {
  line-height: 1.7;
}

.gift-body p {
  margin: 0 0 16px;
  color: var(--text-secondary);
}

.gift-body h2 {
  font-size: 1.25rem;
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--oxford);
  margin: 28px 0 12px;
}

.gift-moments {
  list-style: none;
  margin: 0 0 8px;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 8px 20px;
}

.gift-moments li {
  position: relative;
  padding-left: 22px;
  color: var(--text-secondary);
  line-height: 1.5;
}

.gift-moments li::before {
  content: '\2713'; /* checkmark */
  position: absolute;
  left: 0;
  color: var(--amber);
  font-weight: 700;
}

.gift-cta-wrap {
  text-align: center;
  margin-top: 32px;
  padding: 28px 20px;
  background: var(--moonlight-tint);
  border: 1px solid var(--amber);
  border-radius: var(--radius-md);
}

.gift-buy-btn {
  display: inline-block;
  margin: 0 6px;
  font-size: 1.05rem;
  padding: 14px 32px;
  background: var(--amber);
  border: 1.5px solid var(--amber);
}
.gift-buy-btn:hover {
  background: #B8741F;
  border-color: #B8741F;
}

.gift-fineprint {
  font-size: .82rem;
  color: var(--text-secondary);
  line-height: 1.6;
  margin: 14px 0 0;
  text-align: left;
}

/* ============================================================
   Hidden social-landing pages (/tt /ins /psm) — paid-social funnels.
   BIS v1.3: Oxford headline, Moonlight Tint bg, Amber CTA fill / white text.
   ============================================================ */
.social-landing {
  background: var(--moonlight-tint);
  min-height: 60vh;
  padding: 64px 24px 80px;
}
.social-hero {
  max-width: 680px;
  margin: 0 auto;
  text-align: center;
}
.social-hero-h1 {
  font-family: var(--font-display);
  color: var(--oxford);
  font-size: clamp(1.9rem, 5vw, 2.6rem);
  font-weight: 800;
  letter-spacing: -0.5px;
  line-height: 1.15;
  margin: 0 0 20px;
}
.social-hero-sub {
  color: var(--steel);
  font-size: 1.15rem;
  line-height: 1.55;
  margin: 0 auto 36px;
  max-width: 600px;
}
.social-cta-wrap {
  display: flex;
  justify-content: center;
}
/* Amber solid fill (mirrors .gift-buy-btn / .c01-signup-cta / .lp-cert-view-btn),
   NOT the legacy teal .btn-primary (tech debt #17). */
.social-cta {
  font-family: var(--font);
  font-size: 1.05rem;
  font-weight: 700;
  color: #ffffff;
  background: var(--amber);
  border: 1.5px solid var(--amber);
  border-radius: var(--radius-sm);
  padding: 14px 32px;
  cursor: pointer;
  transition: background .15s, border-color .15s, transform .15s, box-shadow .15s;
}
.social-cta:hover {
  background: #B8741F;
  border-color: #B8741F;
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(212, 136, 42, .35);
}
.social-cta:focus-visible {
  outline: 2px solid var(--amber);
  outline-offset: 3px;
}
/* /psm — two equal-weight CTAs, 50/50 side by side on desktop, stacked on mobile. */
.social-cta-row {
  display: flex;
  gap: 16px;
  justify-content: center;
}
.social-cta-row .social-cta {
  flex: 1 1 0;
  max-width: 260px;
}
@media (max-width: 560px) {
  .social-cta-row {
    flex-direction: column;
  }
  .social-cta-row .social-cta {
    max-width: none;
  }
}

.pricing-page {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 20px 60px;
}

.pricing-hero {
  text-align: center;
  padding: 40px 0 40px;
}

.pricing-hero h1 {
  font-size: clamp(1.6rem, 4vw, 2.2rem);
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: -0.5px;
  line-height: 1.2;
  margin-bottom: 12px;
}

.pricing-hero p {
  font-size: 1rem;
  color: var(--text-secondary);
  line-height: 1.6;
  max-width: 460px;
  margin: 0 auto;
}

/* Pricing Audience Tabs (Individuals / Schools / Organizations) */
.pricing-audience-tabs {
  display: flex;
  justify-content: center;
  gap: 24px;
  margin: 16px auto 36px;
  padding: 0 16px;
  flex-wrap: wrap;
  max-width: 1100px;
}
.pricing-audience-tab {
  flex: 0 1 280px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 22px 28px;
  border-radius: 18px;
  /* BIS v1.3 — Steel ghost for inactive tabs, Amber hover, Amber-filled for active. */
  border: 2.5px solid var(--steel);
  background: transparent;
  color: var(--steel);
  font-family: var(--font);
  cursor: pointer;
  transition: all .18s ease;
  text-align: center;
}
.pricing-audience-tab:hover {
  border-color: var(--amber);
  color: var(--amber);
  background: rgba(212, 136, 42, .06);
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(212, 136, 42, .18);
}
.pricing-audience-tab.active {
  background: var(--amber);
  border-color: var(--amber);
  color: #fff;
  box-shadow: 0 8px 24px rgba(212, 136, 42, .32);
}
.pricing-audience-tab.active:hover {
  background: #B8741F;
  border-color: #B8741F;
  color: #fff;
}
.pricing-audience-tab-icon {
  font-size: 1.9rem;
  line-height: 1;
  margin-bottom: 2px;
}
.pricing-audience-tab-label {
  font-size: 1.2rem;
  font-weight: 800;
  letter-spacing: .01em;
}
.pricing-audience-tab-sub {
  font-size: .85rem;
  font-weight: 600;
  opacity: .85;
}
.pricing-audience-panel { display: none; }
.pricing-audience-panel.active { display: block; }

@media (max-width: 720px) {
  .pricing-audience-tabs { gap: 14px; }
  .pricing-audience-tab { flex: 1 1 100%; padding: 18px 22px; }
  .pricing-audience-tab-icon { font-size: 1.6rem; }
  .pricing-audience-tab-label { font-size: 1.1rem; }
}

/* Pricing Tabs (legacy / landing page) */
.pricing-tabs {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin: 8px auto 28px;
  flex-wrap: wrap;
  max-width: 720px;
}
.pricing-tab {
  flex: 0 1 210px;
  padding: 12px 20px;
  border-radius: 999px;
  border: 1.5px solid var(--border, #E5E7EB);
  background: #fff;
  color: var(--text-secondary, #6B7280);
  font-weight: 700;
  font-size: .92rem;
  cursor: pointer;
  transition: all .15s ease;
}
.pricing-tab:hover {
  border-color: var(--primary, #7C3AED);
  color: var(--primary, #7C3AED);
}
.pricing-tab.active {
  background: var(--primary, #7C3AED);
  border-color: var(--primary, #7C3AED);
  color: #fff;
  box-shadow: 0 4px 14px rgba(124, 58, 237, .18);
}
.pricing-tab-panel { display: none; }
.pricing-tab-panel.active { display: block; }

.pricing-audience-intro {
  text-align: center;
  margin-bottom: 24px;
}
.pricing-audience-intro h2 {
  font-size: 1.6rem;
  font-weight: 800;
  margin-bottom: 8px;
}
.pricing-audience-intro p {
  color: var(--text-secondary, #6B7280);
  max-width: 640px;
  margin: 0 auto;
}
.pricing-tier-table {
  max-width: 640px;
  margin: 0 auto 16px;
  border: 1.5px solid var(--border, #E5E7EB);
  border-radius: var(--radius, 12px);
  overflow: hidden;
  background: var(--surface, #fff);
}
.pricing-tier-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 22px;
  border-bottom: 1px solid var(--border, #E5E7EB);
  gap: 12px;
  flex-wrap: wrap;
}
.pricing-tier-row:last-child { border-bottom: none; }
.pricing-tier-label { font-weight: 700; }
.pricing-tier-price { font-weight: 800; color: var(--primary, #7C3AED); }
.pricing-tier-row-highlight {
  background: rgba(124, 58, 237, .05);
}
.pricing-tier-note {
  max-width: 640px;
  margin: 0 auto 24px;
  text-align: center;
  font-size: .88rem;
  color: var(--text-secondary, #6B7280);
}
.pricing-audience-cta {
  text-align: center;
  margin: 16px auto 32px;
}
.pricing-audience-cta-hint {
  margin-top: 12px;
  font-size: .85rem;
  color: var(--text-secondary, #6B7280);
}

/* #17: .pricing-audience-cta .btn-primary override removed — base .btn-primary
   now resolves to Amber, so the scoped Amber re-fill was redundant. */
.pricing-audience-cta-hint a {
  color: var(--amber);
  text-decoration: underline;
}
.pricing-audience-cta-hint a:hover {
  color: #B8741F;
}

@media (max-width: 540px) {
  .pricing-tab { flex: 1 1 100px; padding: 10px 14px; font-size: .85rem; }
}

/* Card Grid */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 16px;
  margin-top: 24px;
  margin-bottom: 40px;
}

.pricing-card {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 24px;
  display: flex;
  flex-direction: column;
  position: relative;
}

.pricing-card-name {
  font-size: .8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .5px;
  color: var(--text-secondary);
  margin-bottom: 12px;
}

.pricing-card-price {
  font-size: 2.2rem;
  font-weight: 900;
  color: var(--text);
  line-height: 1;
  margin-bottom: 4px;
}

.pricing-card-period {
  font-size: .85rem;
  color: var(--text-secondary);
  margin-bottom: 4px;
}

/* v1.14.5 — Subtext shown under the Annual price when a Monthly subscriber
   is viewing /pricing ("Monthly upgrade rate"). Quiet explanatory line, not
   a marketing call-out. */
.pricing-upgrade-note {
  font-family: 'DM Sans', system-ui, sans-serif;
  font-size: 0.8rem;
  color: #6B6878;
  margin-top: 4px;
  font-weight: 400;
}

.pricing-card-note {
  font-size: .78rem;
  color: var(--text-muted);
  margin-bottom: 20px;
}

.pricing-card-features {
  list-style: none;
  padding: 0;
  margin: 0 0 20px;
  flex: 1;
}

.pricing-card-features li {
  font-size: .85rem;
  color: var(--text-secondary);
  padding: 7px 0;
  border-bottom: 1px solid var(--border);
  line-height: 1.5;
}

.pricing-card-features li:last-child { border-bottom: none; }

.pricing-card-features li::before {
  content: '✓ ';
  color: var(--success);
  font-weight: 700;
}

.pricing-btn {
  width: 100%;
  font-size: .88rem;
}

/* #17: .btn-primary.pricing-btn override removed — base .btn-primary now
   resolves to Amber, so the scoped Amber re-fill was redundant. */

/* BIS v1.3 — "You are on this plan" disabled-state button on the Free card.
   Subdued Moonlight Tint background + Steel border + Steel text, signalling
   "status indicator, not a CTA". */
.btn-secondary.pricing-btn:disabled {
  background: var(--moonlight-tint);
  border: 1px solid var(--steel);
  color: var(--steel);
  opacity: 1;
  cursor: not-allowed;
}

/* Featured card — BIS v1.3 Amber border for the Most Popular Annual card. */
.pricing-featured {
  border-color: var(--amber);
  box-shadow: 0 0 0 2px var(--amber), var(--shadow-lg);
}

/* BIS v1.3 — Most Popular badge is solid Amber, not the gradient
   (D97706 → F59E0B drifts toward Mission Gold and looked legacy-teal in
   the wild). Durable token-based fill so the v1.26.1 regression doesn't
   resurface. */
.pricing-popular-badge {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--amber);
  color: white;
  font-size: .7rem;
  font-weight: 800;
  padding: 4px 16px;
  border-radius: 100px;
  text-transform: uppercase;
  letter-spacing: .8px;
  white-space: nowrap;
}

/* Current plan highlight — BIS v1.3 Amber accent. */
.pricing-current {
  border-color: var(--amber);
}

.pricing-current-badge {
  position: absolute;
  top: -12px;
  right: 16px;
  background: var(--amber);
  color: white;
  font-size: .68rem;
  font-weight: 800;
  padding: 4px 12px;
  border-radius: 100px;
  text-transform: uppercase;
  letter-spacing: .5px;
}

/* Mission Statement */
.pricing-mission {
  background: linear-gradient(135deg, #FFFBEB, #FEF3C7);
  border: 2px solid #FCD34D;
  border-radius: var(--radius);
  padding: 32px 28px;
  margin-bottom: 24px;
}

.pricing-mission h2 {
  font-size: 1.3rem;
  font-weight: 900;
  color: #92400E;
  margin-bottom: 14px;
}

.pricing-mission p {
  font-size: .92rem;
  color: #451A03;
  line-height: 1.7;
  margin-bottom: 12px;
}

.pricing-mission p:last-child { margin-bottom: 0; }

.pricing-mission-highlight {
  font-weight: 800 !important;
  font-size: 1rem !important;
}

/* Educator Section */
.pricing-educator {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 24px;
  text-align: center;
}

.pricing-educator h2 {
  font-size: 1.2rem;
  font-weight: 800;
  margin-bottom: 10px;
}

.pricing-educator p {
  font-size: .9rem;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 16px;
}

/* ---- ABOUT PAGE ---- */
.about-page {
  max-width: 740px;
  margin: 0 auto;
  padding: 0 20px 60px;
}

/* Hero */
.about-hero {
  text-align: center;
  padding: 40px 0 48px;
}

.about-hero h1 {
  font-size: clamp(1.8rem, 5vw, 2.4rem);
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: -0.5px;
  margin-bottom: 14px;
  line-height: 1.2;
}

.about-hero p {
  font-size: 1.05rem;
  color: var(--text-secondary);
  line-height: 1.6;
  max-width: 500px;
  margin: 0 auto;
}

.about-hero-btns {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
  margin: 28px auto 0;
}

@media (max-width: 720px) {
  .about-hero-btns { flex-direction: column; gap: 10px; align-items: center; }
  .about-hero-btns .lp-btn-outline { width: 100%; max-width: 320px; }
}

/* ---- FAQ Accordion (used on /faq via renderFaq()) ---- */
.faq-page .about-section { padding: 0; background: transparent; border: none; }
.faq-section { margin: 0 0 36px; }
.faq-section:last-child { margin-bottom: 0; }
.faq-section-title {
  font-size: 1.05rem;
  font-weight: 800;
  color: #1D9E75;
  text-transform: uppercase;
  letter-spacing: 1.2px;
  margin: 0 0 14px;
  padding-bottom: 8px;
  border-bottom: 2px solid #D1FAE5;
}
.faq-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.faq-item {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden;
  transition: border-color .2s ease, box-shadow .2s ease;
}
.faq-item.open {
  border-color: #1D9E75;
  box-shadow: 0 2px 10px rgba(29,158,117,.08);
}
.faq-question {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  width: 100%;
  background: transparent;
  border: none;
  padding: 16px 20px;
  font-family: var(--font);
  font-size: 1rem;
  font-weight: 600;
  color: #0F172A;
  text-align: left;
  cursor: pointer;
  min-height: 56px;
  transition: background .15s ease;
}
.faq-question:hover { background: #f7faf9; }
.faq-question:focus-visible {
  outline: 2px solid #1D9E75;
  outline-offset: -2px;
}
.faq-question-text { flex: 1; line-height: 1.45; }
.faq-chevron {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  color: #1D9E75;
  background: #ECFDF5;
  transition: transform .25s ease, background .2s ease;
}
.faq-chevron svg { width: 18px; height: 18px; }
.faq-item.open .faq-chevron {
  transform: rotate(180deg);
  background: #D1FAE5;
}
.faq-answer {
  max-height: 0;
  overflow: hidden;
  padding: 0 20px;
  transition: max-height .3s ease, padding .3s ease;
}
.faq-item.open .faq-answer {
  max-height: 800px;
  padding: 0 20px 18px;
}
.faq-answer p {
  margin: 0;
  font-size: .95rem;
  line-height: 1.7;
  color: var(--text-secondary);
}
@media (max-width: 600px) {
  .faq-section-title { font-size: .95rem; letter-spacing: 1px; }
  .faq-question { font-size: .95rem; padding: 14px 16px; min-height: 56px; }
  .faq-chevron { width: 30px; height: 30px; }
  .faq-answer { padding: 0 16px; }
  .faq-item.open .faq-answer { padding: 0 16px 16px; }
  .faq-answer p { font-size: .9rem; }
}
@media (prefers-reduced-motion: reduce) {
  .faq-item, .faq-question, .faq-chevron, .faq-answer { transition: none !important; }
}

/* Sections */
.about-section {
  margin-bottom: 16px;
}

.about-section h2 {
  font-size: 1.5rem;
  font-weight: 900;
  letter-spacing: -0.4px;
  margin-bottom: 20px;
}

.about-section-sub {
  color: var(--text-secondary);
  font-size: 1rem;
  line-height: 1.6;
  margin-bottom: 24px;
}

.about-divider {
  height: 1px;
  background: var(--border);
  margin: 40px 0;
}

/* "Things nobody taught us" rotator */
.about-taught { text-align: center; }
.about-taught-rotator {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin: 28px auto 0;
  max-width: 920px;
}
.about-taught-card {
  --taught-color: #1D9E75;
  flex: 1;
  position: relative;
  padding: 36px 28px 44px;
  border-radius: 20px;
  background: color-mix(in srgb, var(--taught-color) 8%, #fff);
  border: 1.5px solid color-mix(in srgb, var(--taught-color) 25%, #fff);
  box-shadow: 0 6px 24px color-mix(in srgb, var(--taught-color) 18%, transparent);
  transition: background .6s ease, border-color .6s ease, box-shadow .6s ease;
  overflow: hidden;
}
.about-taught-card::after {
  content: '';
  position: absolute;
  left: 50%;
  bottom: 22px;
  transform: translateX(-50%);
  height: 3px;
  width: 0;
  background: var(--taught-color);
  border-radius: 3px;
}
.about-taught-card.taught-underline-go::after {
  animation: taught-underline-draw .9s ease forwards;
}
.about-taught-stage {
  position: relative;
  min-height: 200px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.about-taught-item {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  opacity: 0;
  transition: opacity .6s ease;
  font-size: clamp(1.6rem, 3.6vw, 2.5rem);
  font-weight: 800;
  line-height: 1.3;
  color: var(--taught-color, #1D9E75);
  padding: 0 16px;
  pointer-events: none;
  text-align: center;
}
.about-taught-item.active {
  opacity: 1;
  pointer-events: auto;
}
.about-taught-dot {
  display: inline-block;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #F59E0B;
  box-shadow: 0 0 0 4px rgba(245, 158, 11, .18);
  flex-shrink: 0;
}
.about-taught-text {
  display: inline-block;
  max-width: 860px;
}
.about-taught-nav {
  background: #fff;
  border: 1.5px solid var(--border, #E5E7EB);
  width: 48px;
  height: 48px;
  border-radius: 999px;
  font-size: 1.8rem;
  line-height: 1;
  cursor: pointer;
  color: var(--text-secondary, #6B7280);
  flex: 0 0 auto;
  transition: all .15s ease;
}
.about-taught-nav:hover {
  color: #1D9E75;
  border-color: #1D9E75;
}
.about-taught-list-fallback { display: none; }

@media (max-width: 540px) {
  .about-taught-nav { width: 40px; height: 40px; font-size: 1.5rem; }
  .about-taught-stage { min-height: 220px; }
  .about-taught-card { padding: 28px 18px 38px; }
  .about-taught-dot { width: 10px; height: 10px; }
}

@media (prefers-reduced-motion: reduce) {
  .about-taught-item { transition: none; }
  .about-taught-card { transition: none; }
  .about-taught-card::after { animation: none; width: 0; }
  .about-taught-rotator { display: none; }
  .about-taught-list-fallback {
    display: block;
    list-style: none;
    padding: 0;
    margin: 24px auto 0;
    max-width: 640px;
    text-align: left;
  }
  .about-taught-list-fallback li {
    padding: 12px 16px;
    border-bottom: 1px solid var(--border, #E5E7EB);
    font-size: 1rem;
    color: var(--text, #111);
  }
  .about-taught-list-fallback li:last-child { border-bottom: none; }
}

/* Prose */
.about-prose p {
  font-size: .95rem;
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: 16px;
}

.about-prose p:last-child { margin-bottom: 0; }

.about-prose em {
  color: var(--text);
  font-style: italic;
}

.about-story .about-prose p:last-child {
  font-weight: 700;
  color: var(--text);
  font-size: 1.05rem;
}

/* Pricing Philosophy Box — v1.28.17 reconciled to BIS v1.3.
   Replaces the legacy cream gradient + warm-amber-200 border + dark
   brown text with white interior, 2px Amber border (slightly thicker
   than the .about-feature 1.5px border to match the prose weight of
   this single larger callout), Steel body text, and Amber emphasis. */
.about-pricing-box {
  background: #FFFFFF;
  border: 2px solid var(--amber);
  border-radius: var(--radius);
  padding: 32px 28px;
}

.about-pricing-box p {
  font-size: .95rem;
  color: var(--steel);
  line-height: 1.8;
  margin-bottom: 16px;
}

.about-pricing-box p:last-child { margin-bottom: 0; }

.about-pricing-highlight {
  font-size: 1.2rem !important;
  font-weight: 900 !important;
  color: var(--amber) !important;
  text-align: center;
  padding: 8px 0;
}

.about-pricing-promise {
  font-weight: 800 !important;
  font-size: 1.05rem !important;
  color: var(--amber) !important;
  text-align: center;
  padding-top: 4px;
}

/* Features Grid */
.about-features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
}

.about-feature {
  /* v1.28.17 — White interior + 1.5px Amber border per BIS v1.3.
     Replaces v1.28.3 Moonlight + Bone (which was reconciled from the
     legacy v1.27.7 green/cream tint preservation). No green or cream
     tint anywhere on the card. */
  background: #FFFFFF;
  border: 1.5px solid var(--amber);
  border-radius: var(--radius);
  padding: 24px 20px;
  text-align: center;
}

.about-feature-icon {
  font-size: 2rem;
  margin-bottom: 12px;
}

.about-feature h3 {
  font-size: .92rem;
  font-weight: 800;
  margin-bottom: 8px;
}

.about-feature p {
  font-size: .82rem;
  color: var(--steel);
  line-height: 1.6;
}

/* Value Comparison */
.about-comparison {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-width: 480px;
}

.about-compare-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 20px;
  border-radius: var(--radius-sm);
}

.about-compare-other {
  background: var(--surface);
  border: 1px solid var(--border);
}

.about-compare-us {
  background: linear-gradient(135deg, #F5F3FF, #EDE9FE);
  border: 2px solid var(--primary);
}

.about-compare-label {
  font-size: .9rem;
  font-weight: 700;
}

.about-compare-us .about-compare-label {
  color: var(--primary);
}

.about-compare-price {
  font-size: 1.1rem;
  font-weight: 900;
}

.about-compare-us .about-compare-price {
  color: var(--primary);
  font-size: 1.3rem;
}

.about-compare-price small {
  font-size: .72rem;
  font-weight: 500;
  color: var(--text-secondary);
}

/* Promises */
.about-promises {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 10px;
}

.about-promise-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 18px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: .9rem;
  line-height: 1.4;
}

.about-promise-check {
  color: var(--primary);
  font-weight: 800;
  font-size: 1.1rem;
  flex-shrink: 0;
}

/* Families */
.about-families {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 32px 28px;
}

.about-families h2 { margin-bottom: 16px; }

.about-families .btn-secondary {
  margin-top: 20px;
}

/* Contact Grid */
.about-contact-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 12px;
  margin-bottom: 20px;
}

.about-contact-card {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 20px;
  text-align: center;
}

.about-contact-type {
  font-size: .78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .5px;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.about-contact-email {
  font-size: .92rem;
  font-weight: 700;
  color: var(--primary);
  text-decoration: none;
}

.about-contact-email:hover {
  text-decoration: underline;
}

.about-contact-note {
  font-size: .85rem;
  color: var(--text-secondary);
  text-align: center;
  line-height: 1.6;
  font-style: italic;
}

/* Footer links row */
.lp-footer-links {
  display: flex;
  gap: 20px;
}

/* ---- AMBASSADOR PAGE ---- */
.amb-page {
  max-width: 800px;
  margin: 0 auto;
  padding: 0 20px 60px;
}

/* Hero — Playfair Bold Oxford via .display class on the h1 itself. */
.amb-hero {
  text-align: center;
  padding: 24px 0 48px;
}

.amb-hero-h1.display {
  font-size: clamp(1.8rem, 5vw, 2.6rem);
  color: var(--oxford);
  letter-spacing: -0.01em;
  line-height: 1.15;
  margin-bottom: 16px;
}

.amb-hero-sub {
  font-family: var(--font);
  font-size: 1.05rem;
  color: var(--steel);
  line-height: 1.6;
  max-width: 560px;
  margin: 0 auto;
}

/* Sections */
.amb-section {
  margin-bottom: 48px;
}

/* Section titles — Playfair Bold Oxford via .display class. Override the
   default .display purple color so headings on /ambassador stay BIS v1.3. */
.amb-section-title {
  font-size: 1.5rem;
  text-align: center;
  letter-spacing: -0.01em;
  margin-bottom: 24px;
}
.amb-section-title.display { color: var(--oxford); }

/* Steps */
.amb-steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}

.amb-step-card {
  background: #ffffff;
  border: 1.5px solid rgba(73,91,125,.25);
  border-radius: var(--radius);
  padding: 28px 24px;
  text-align: center;
}

.amb-step-num {
  width: 44px; height: 44px;
  border-radius: 50%;
  background: var(--amber);
  color: white;
  font-size: 1.1rem;
  font-weight: 700;
  font-family: var(--font);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 14px;
}

.amb-step-card h3 {
  font-family: var(--font);
  font-size: 1rem;
  font-weight: 600;
  color: var(--oxford);
  margin-bottom: 8px;
}

.amb-step-card p {
  font-family: var(--font);
  font-size: .88rem;
  color: var(--steel);
  line-height: 1.6;
}

/* Who Can Participate — body copy. Mirrors the How-It-Works step paragraph
   treatment (DM Sans, Steel, readable line-height), centered and width-capped
   like the hero sub. */
.amb-who-copy {
  font-family: var(--font);
  font-size: .95rem;
  color: var(--steel);
  line-height: 1.7;
  max-width: 620px;
  margin: 0 auto;
  text-align: center;
}

/* Live referral counter (#referral-stats) — a modest status line, not a loud
   badge: Oxford text on a subtle Moonlight-tint line, centered under the
   referral link box. Collapses when empty (the logged-out / non-ok states set
   textContent to '' so no empty box shows). */
#referral-stats {
  font-family: var(--font);
  font-size: .92rem;
  color: var(--oxford);
  line-height: 1.5;
  text-align: center;
  margin-top: 14px;
  padding: 10px 16px;
  background: var(--moonlight-tint);
  border-radius: var(--radius);
}
#referral-stats:empty { display: none; }

/* Lives Changed — Moonlight Tint surface, Steel body, Oxford tagline. */
.amb-lives {
  text-align: center;
  background: var(--moonlight-tint);
  border-radius: var(--radius);
  padding: 40px 32px;
}
.amb-lives-sub {
  font-family: var(--font);
  font-size: 1rem;
  color: var(--steel);
  line-height: 1.7;
  max-width: 560px;
  margin: 0 auto 16px;
}
.amb-lives-tagline {
  font-family: var(--font);
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--oxford);
}

/* FAQ */
.amb-faq {
  max-width: 600px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.amb-faq-item {
  background: #ffffff;
  border: 1.5px solid rgba(73,91,125,.25);
  border-radius: var(--radius-sm);
  cursor: pointer;
  overflow: hidden;
  transition: border-color .15s;
}

.amb-faq-item:hover { border-color: var(--amber); }

.amb-faq-q {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 20px;
  font-family: var(--font);
  font-size: .92rem;
  font-weight: 600;
  color: var(--oxford);
}

.amb-faq-arrow {
  font-size: 1.3rem;
  color: var(--text-secondary);
  transition: transform .2s;
  line-height: 1;
}

.amb-faq-item.open .amb-faq-arrow {
  transform: rotate(90deg);
}

.amb-faq-a {
  max-height: 0;
  overflow: hidden;
  transition: max-height .3s ease, padding .3s ease;
  font-family: var(--font);
  font-size: .88rem;
  color: var(--steel);
  line-height: 1.7;
  padding: 0 20px;
}

.amb-faq-item.open .amb-faq-a {
  max-height: 200px;
  padding: 0 20px 16px;
}

/* ---- ONBOARDING ---- */
.ob-container {
  max-width: 540px;
  margin: 0 auto;
  padding: 40px 20px 60px;
  min-height: calc(100vh - 64px);
  display: flex;
  flex-direction: column;
  align-items: center;
}

.ob-dots {
  display: flex;
  gap: 8px;
  justify-content: center;
  margin-bottom: 40px;
}

.ob-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--border);
  transition: all .2s;
}

.ob-dot.active {
  background: var(--primary);
  width: 28px;
  border-radius: 100px;
}

.ob-dot.done { background: var(--success); }

.ob-screen {
  width: 100%;
  text-align: center;
  animation: ob-fade .3s ease;
}

@keyframes ob-fade {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

.ob-welcome-icon { font-size: 4rem; margin-bottom: 16px; }
.ob-welcome-title { font-size: 2.4rem; font-family: var(--font-wordmark); font-weight: 600; color: var(--color-primary-purple); letter-spacing: 1px; margin-bottom: 12px; }
/* v1.13.0 Phase 2 — onboarding welcome tagline contrast fix: warm gold tint
   behind the tagline as a soft padded band, keeps the welcome screen serene
   without changing the wider layout. */
.ob-welcome-tagline {
  font-size: 1.3rem;
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 400;
  color: var(--color-mission-gold);
  background: rgba(160, 120, 0, 0.08);
  padding: 8px 16px;
  border-radius: 8px;
  line-height: 1.4;
  max-width: 400px;
  margin: 0 auto 8px;
  display: inline-block;
}
.ob-welcome-sub { font-size: 1rem; color: var(--text-secondary); line-height: 1.6; max-width: 400px; margin: 0 auto 36px; }

.ob-brand-mark {
  font-size: clamp(1.8rem, 5vw, 2.4rem);
  /* v1.13.0 Phase 1 — wordmark spec on light onboarding surface. */
  font-family: var(--font-wordmark);
  font-weight: 600;
  letter-spacing: 1px;
  color: var(--color-primary-purple);
  letter-spacing: -1px;
  text-align: center;
  line-height: 1;
  margin: 0 0 18px;
}
.ob-heading { font-size: 1.5rem; font-weight: 800; letter-spacing: -0.3px; margin-bottom: 8px; color: var(--text); }
.ob-sub { font-size: .92rem; color: var(--text-secondary); margin-bottom: 24px; line-height: 1.5; }

.ob-input {
  width: 100%;
  padding: 16px 20px;
  font-size: 1.1rem;
  font-weight: 600;
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  font-family: var(--font);
  color: var(--text);
  text-align: center;
  transition: border-color .15s;
  margin-bottom: 8px;
}

.ob-input:focus { outline: none; border-color: var(--primary); }

.ob-select {
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='8' viewBox='0 0 14 8'%3E%3Cpath fill='%237C3AED' d='M1 1l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
  padding-right: 44px;
  cursor: pointer;
}

.ob-location-fields {
  display: flex;
  flex-direction: column;
  gap: 14px;
  max-width: 420px;
  margin: 0 auto 16px;
}

.ob-name-fields {
  display: flex;
  gap: 12px;
  margin-bottom: 8px;
}

.ob-field {
  flex: 1;
  text-align: left;
}

.ob-field-label {
  display: block;
  font-size: .8rem;
  font-weight: 700;
  color: var(--text-secondary);
  margin-bottom: 6px;
  letter-spacing: .3px;
}

.ob-field .ob-input {
  text-align: left;
}

.ob-field-note {
  font-size: .78rem;
  color: var(--text-secondary);
  margin-top: 8px;
  line-height: 1.4;
  opacity: .8;
}

.ob-error {
  font-size: .82rem;
  color: var(--danger);
  font-weight: 600;
  min-height: 20px;
  margin-bottom: 8px;
}

.ob-btn { width: 100%; padding: 16px; font-size: 1.05rem; margin-top: 8px; }

.ob-back {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: none;
  border: none;
  color: var(--text-secondary);
  font-size: .85rem;
  font-weight: 600;
  font-family: var(--font);
  cursor: pointer;
  padding: 6px 0;
  margin-bottom: 20px;
  transition: color .15s;
}

.ob-back:hover { color: var(--text); }

/* Terms acceptance */
.ob-terms-box {
  display: flex;
  flex-direction: column;
  gap: 14px;
  text-align: left;
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 18px 18px;
  margin: 18px 0 20px;
}
.ob-terms-row {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-size: 0.92rem;
  line-height: 1.5;
  color: var(--text);
  cursor: pointer;
}
.ob-terms-row input[type="checkbox"] {
  margin-top: 3px;
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  cursor: pointer;
  accent-color: var(--primary);
}
.ob-terms-row a {
  color: var(--primary);
  text-decoration: underline;
}

/* v1.15.5 — Important Disclaimer block on the terms screen. Sits below
   the existing terms checkbox and (conditional) guardian checkbox; the
   acceptance checkbox lives just below the box (.ob-disclaimer-accept).
   Uses the brand amber tokens (--accent / --accent-light) so the visual
   weight reads as "important warning" without introducing new colors. */
.ob-disclaimer-box {
  background: var(--accent-light);
  border: 1px solid color-mix(in srgb, var(--accent) 35%, transparent);
  border-left: 4px solid var(--accent);
  border-radius: 8px;
  padding: 18px 20px;
  margin: 16px 0;
  text-align: left;
}
.ob-disclaimer-heading {
  font-family: var(--font);
  font-weight: 600;
  color: var(--vivoso-purple);
  font-size: 16px;
  margin-bottom: 8px;
}
.ob-disclaimer-body {
  font-family: var(--font);
  font-weight: 400;
  font-size: 14.5px;
  line-height: 1.55;
  color: var(--text);
  margin: 0;
}
.ob-disclaimer-note {
  font-family: var(--font);
  font-style: italic;
  font-size: 13px;
  color: var(--text-secondary);
  margin: 10px 0 0;
}
.ob-disclaimer-accept {
  margin: 4px 0 18px;
}

/* Topic cards */
.ob-topic-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin-bottom: 8px;
}

.ob-topic-card {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 16px;
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  cursor: pointer;
  transition: all .15s;
  text-align: left;
}

.ob-topic-card:hover { border-color: var(--primary); }

.ob-topic-card.selected {
  border-color: var(--primary);
  background: var(--primary-light);
}

.ob-topic-icon { font-size: 1.4rem; flex-shrink: 0; }
.ob-topic-label { font-size: .85rem; font-weight: 600; color: var(--text); line-height: 1.3; }

.ob-counter {
  font-size: .8rem;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 4px;
}

/* Attribution options */
.ob-attr-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  margin-bottom: 8px;
}

.ob-attr-btn {
  padding: 10px 18px;
  border: 1.5px solid var(--border);
  border-radius: 100px;
  background: var(--surface);
  font-size: .85rem;
  font-weight: 600;
  font-family: var(--font);
  color: var(--text-secondary);
  cursor: pointer;
  transition: all .15s;
}

.ob-attr-btn:hover { border-color: var(--primary); color: var(--primary); }
.ob-attr-btn.selected { border-color: var(--primary); background: var(--primary); color: white; }

/* v1.15.0 — Birth picker (onboarding step 3 + birth-date migration screen).
   Two dropdowns side-by-side on ≥640px, stacked on mobile. The feedback
   line below the inputs updates live: teal when the computed age is
   valid (13–30 or 30+), red when under 13, hidden otherwise. */
.ob-birth-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  margin: 0 auto 16px;
  max-width: 480px;
  text-align: left;
}
@media (min-width: 640px) {
  .ob-birth-row { grid-template-columns: 1fr 1fr; gap: 16px; }
}
.ob-birth-feedback {
  font-family: var(--font-body);
  font-size: 1.05rem;
  font-weight: 600;
  line-height: 1.4;
  margin: 0 auto 18px;
  max-width: 480px;
  min-height: 1.4em;
  text-align: center;
}
.ob-birth-feedback--ok { color: var(--learning-teal); }
.ob-birth-feedback--error { color: var(--danger); }

/* v1.15.0 — Life Stage screen (single-select). 1-col on mobile, 2-col on
   ≥640px. Larger tappable surface than attribution chips since these are
   full sentences, not single words. */
.ob-lifestage-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
  margin: 0 auto 8px;
  max-width: 480px;
}
@media (min-width: 640px) {
  .ob-lifestage-grid { grid-template-columns: 1fr 1fr; }
}
.ob-lifestage-btn {
  padding: 16px 18px;
  border: 1.5px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
  font-size: 1rem;
  font-weight: 600;
  font-family: var(--font);
  color: var(--text);
  cursor: pointer;
  text-align: center;
  transition: all .15s;
}
.ob-lifestage-btn:hover { border-color: var(--primary); color: var(--primary); }
.ob-lifestage-btn.selected {
  border-color: var(--primary);
  background: var(--primary);
  color: white;
}

/* v1.15.0 — Topic Interests screen (multi-select, max 3). Selected state
   shows Vivoso Purple background with a leading checkmark. When the cap
   is hit, remaining buttons get .at-cap which dims them and disables
   pointer events; the title attribute carries an explanation. */
.ob-interests-counter {
  font-size: .9rem;
  color: var(--text-secondary);
  margin: 0 auto 16px;
  font-weight: 600;
}
.ob-interests-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
  margin: 0 auto 8px;
  max-width: 480px;
}
@media (min-width: 640px) {
  .ob-interests-grid { grid-template-columns: 1fr 1fr; }
}
.ob-interests-btn {
  padding: 14px 16px;
  border: 1.5px solid var(--primary);
  border-radius: 12px;
  background: var(--surface);
  font-size: .95rem;
  font-weight: 600;
  font-family: var(--font);
  color: var(--primary);
  cursor: pointer;
  text-align: center;
  transition: all .15s;
}
.ob-interests-btn:hover { background: rgba(124, 58, 237, 0.06); }
.ob-interests-btn.selected {
  background: var(--primary);
  color: white;
}
.ob-interests-btn.selected::before {
  content: "\2713";
  margin-right: 6px;
  font-weight: 800;
}
/* Summary tags on final screen */
.ob-summary-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  margin: 20px 0 28px;
}

.ob-summary-tag {
  padding: 8px 16px;
  background: var(--primary-light);
  color: var(--primary);
  border-radius: 100px;
  font-size: .85rem;
  font-weight: 700;
}

/* ---- PATHWAYS PAGE ---- */
.pathways-hero {
  border-radius: 24px;
  padding: 40px;
  color: white;
  margin-bottom: 32px;
  text-align: center;
}

.pathways-hero h1 { font-size: 2rem; font-weight: 900; margin-bottom: 8px; }
.pathways-hero p { opacity: .8; max-width: 500px; margin: 0 auto; }

.pathway-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
}

.pathway-card {
  background: var(--surface);
  border-radius: var(--radius);
  border: 1.5px solid var(--border);
  overflow: hidden;
  cursor: pointer;
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
  box-shadow: 0 2px 4px rgba(0,0,0,0.06), 0 4px 12px rgba(0,0,0,0.08);
  position: relative;
}

.pathway-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 8px 16px rgba(0,0,0,0.10), 0 16px 32px rgba(0,0,0,0.08);
  /* v1.28.7 — outline stays at the per-pathway color set inline via
     border-color on the .pathway-card itself; no extra hover swap. */
}

.pathway-card-stripe {
  height: 6px;
}

.pathway-card-body {
  padding: 20px;
}

.pathway-card-top {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 10px;
}

.pathway-icon-wrap {
  width: 44px; height: 44px;
  border-radius: 12px;
  flex-shrink: 0;
  box-shadow: 0 2px 10px -4px rgba(17,24,39,.25);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
}

.pathway-id {
  font-size: .65rem;
  font-weight: 800;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: var(--text-muted);
}

.pathway-name {
  /* v1.13.0 Phase 2 — display header treatment for pathway names. */
  font-size: 1.05rem;
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: -0.2px;
  color: var(--text);
  line-height: 1.25;
}

.pathway-complete-badge {
  font-size: .72rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 100px;
  background: var(--success-light);
  color: var(--success);
  white-space: nowrap;
}
/* Pathway recommendation - suggestion layer, never gates access. */
.pathway-reco-badge {
  font-size: .72rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 100px;
  background: rgba(212, 136, 42, .14);
  color: #A8641C;
  white-space: nowrap;
}
.pathways-reco-box {
  margin: 20px 0 28px;
  padding: 18px 20px;
  background: #fff;
  border: 1px solid #E8DFD0;
  border-left: 4px solid #D4882A;
  border-radius: 10px;
  box-shadow: 0 1px 3px rgba(0,0,0,.05);
}
.pathways-reco-text {
  margin: 0 0 12px;
  font-size: .95rem;
  line-height: 1.5;
  color: var(--text-secondary);
}
.pathways-reco-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.pathways-reco-chip {
  font-family: inherit;
  font-size: .88rem;
  font-weight: 700;
  padding: 7px 14px;
  border-radius: 100px;
  border: 1.5px solid var(--chip, #D4882A);
  background: transparent;
  color: var(--chip, #D4882A);
  cursor: pointer;
  transition: background .15s, color .15s;
}
.pathways-reco-chip:hover {
  background: var(--chip, #D4882A);
  color: #fff;
}

.pathway-desc {
  font-size: .83rem;
  color: var(--text-secondary);
  line-height: 1.5;
  margin-bottom: 10px;
  min-height: 4.5em;
}

.pathway-meta {
  display: flex;
  gap: 12px;
  font-size: .75rem;
  color: var(--text-muted);
  font-weight: 600;
}

.pathway-color-block {
  height: 6px;
  width: 100%;
  border-radius: 999px;
  background: var(--pw-color);
  margin: 10px 0 12px;
}

/* ---- PATHWAY DETAIL PAGE ---- */
.pathway-detail-hero {
  border-radius: 24px;
  padding: 40px;
  color: white;
  text-align: center;
  margin-bottom: 24px;
}

.pathway-detail-hero-icon {
  width: 88px;
  height: 88px;
  margin: 0 auto 16px;
  border-radius: 50%;
  background: rgba(255,255,255,0.15);
  border: 1.5px solid rgba(255,255,255,0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 18px -6px rgba(0,0,0,0.25);
}

.pathway-course-row {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 20px;
  border-bottom: 1px solid var(--border);
  cursor: pointer;
  transition: background .12s;
}

.pathway-course-row:last-child { border-bottom: none; }

.pathway-course-row:hover { background: var(--bg); }
.pathway-course-row.done { background: var(--success-light); }
.pathway-course-row.done:hover { background: color-mix(in srgb, var(--success) 12%, white); }
.pathway-course-row.locked { opacity: .55; cursor: default; }
.pathway-course-row.locked:hover { background: transparent; }

.pathway-course-icon {
  display: inline-block;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--text-muted);
  flex-shrink: 0;
  box-shadow: 0 0 0 3px rgba(255,255,255,0.9), 0 2px 6px -2px rgba(17,24,39,.2);
}

.pathway-course-info {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  min-width: 0;
}

.pathway-course-id {
  font-size: .68rem;
  font-weight: 800;
  letter-spacing: .8px;
  color: var(--text-muted);
  flex-shrink: 0;
}

.pathway-course-title {
  font-size: .88rem;
  font-weight: 600;
  color: var(--text);
  line-height: 1.4;
}

.pathway-course-desc {
  flex-basis: 100%;
  font-size: .78rem;
  color: var(--text-secondary);
  line-height: 1.4;
  margin-top: 2px;
}

.pathway-course-tag {
  font-size: .65rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 100px;
  text-transform: uppercase;
  letter-spacing: .4px;
}

.pathway-course-tag.completed { background: var(--success-light); color: var(--success); }
.pathway-course-tag.coming-soon { background: var(--border); color: var(--text-muted); }

.pathway-course-status {
  font-size: .9rem;
  flex-shrink: 0;
  color: var(--text-muted);
}

.pathway-course-row.done .pathway-course-title { color: var(--success); }
.pathway-course-row.done .pathway-course-status { color: var(--success); }

/* ---- CERTIFICATE TIER SECTIONS ---- */
.tier-section {
  margin-bottom: 32px;
}

.tier-label {
  font-size: .8rem;
  font-weight: 800;
  letter-spacing: 1px;
  text-transform: uppercase;
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  margin-bottom: 16px;
  display: inline-block;
}

.tier-description {
  font-size: .9rem;
  color: var(--text-secondary);
  line-height: 1.5;
  margin: -8px 0 20px;
  max-width: 640px;
}

.tier-1-label { background: var(--primary-light); color: var(--primary); }
.tier-2-label { background: #6d28d918; color: #6d28d9; }

/* Master cert card */
.master-cert-card {
  background: linear-gradient(135deg, #2d1357, #4c1d95, #6d28d9);
  border-radius: var(--radius);
  padding: 40px;
  text-align: center;
  color: white;
  position: relative;
  overflow: hidden;
}

.master-cert-card::before {
  content: '';
  position: absolute;
  top: -60px; right: -60px;
  width: 250px; height: 250px;
  background: rgba(202,138,4,.08);
  border-radius: 50%;
}

.master-cert-card::after {
  content: '';
  position: absolute;
  bottom: -80px; left: -40px;
  width: 200px; height: 200px;
  background: rgba(202,138,4,.06);
  border-radius: 50%;
}

.master-cert-glow {
  display: none;
}

.master-cert-card.unlocked .master-cert-glow {
  display: block;
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 300px; height: 300px;
  background: radial-gradient(circle, rgba(202,138,4,.2) 0%, transparent 70%);
  pointer-events: none;
}

.master-cert-content {
  position: relative;
  z-index: 1;
}

.master-cert-title {
  font-size: 1.5rem;
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: -0.4px;
  line-height: 1.2;
  margin-bottom: 8px;
}

.master-cert-sub {
  font-size: .9rem;
  opacity: .75;
  max-width: 400px;
  margin: 0 auto;
}

/* ---- RESPONSIVE ---- */
@media (max-width: 600px) {
  #app { padding: 20px 14px 60px; }
  .course-grid { grid-template-columns: 1fr; }
  .tracks-grid { grid-template-columns: 1fr; }
  .certs-grid { grid-template-columns: 1fr; }
  .pathway-grid { grid-template-columns: 1fr; }
  .elective-grid { grid-template-columns: 1fr; }
  .lesson-body { padding: 24px 20px; }
  .tts-bar { padding: 16px 18px; }
  .tts-top-row { flex-wrap: wrap; gap: 12px; }
  .tts-icon-col { display: none; }
  .tts-text-col { flex-basis: 100%; }
  .tts-hint { text-align: center; }
  .tts-hint-sub { text-align: center; }
  .tts-controls { justify-content: center; flex-basis: 100%; flex-wrap: wrap; gap: 8px; }
  .tts-play-btn { padding: 14px 32px; min-height: 54px; font-size: .95rem; flex: 1; justify-content: center; }
  .tts-stop-btn { padding: 12px 20px; min-height: 48px; }
  .tts-speed-row { display: none; }
  .tts-speed-cycle { display: inline-flex; min-height: 44px; }
  .ob-container { padding: 24px 16px 40px; }
  .lp-hero { padding: 48px 18px 40px; }
  .lp-hero-btns { flex-direction: column; }
  .lp-hero-learn-btns { flex-direction: column; gap: 10px; }
  .lp-hero-learn-btns .lp-btn-outline { flex: 1 1 auto; width: 100%; }
  .lp-btn-lg { width: 100%; }
  .lp-section, .lp-section-dark, .lp-section-light { padding: 40px 18px; }
  .lp-pathways-grid { grid-template-columns: repeat(2, 1fr); }
  .lp-pricing-grid { grid-template-columns: 1fr; }
  .ob-name-fields { flex-direction: column; }
  .ob-topic-grid { grid-template-columns: 1fr; }
  .ob-welcome-title { font-size: 1.8rem; }
  .screen-card { padding: 28px 22px; }
  .lesson-actions { flex-direction: column-reverse; }
  .btn-primary, .btn-secondary { width: 100%; }
}

@media (max-width: 420px) {
  .app-header { padding: 0 14px; }
  .logo { font-size: 1.1rem; }
}

/* ============================================================
   MOBILE NAV (hamburger + slide-down panel + bottom nav)
   ============================================================ */

.nav-hamburger {
  display: none;
  background: none;
  border: none;
  padding: 10px;
  cursor: pointer;
  width: 44px;
  height: 44px;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  align-items: center;
}
.nav-hamburger span {
  display: block;
  width: 24px;
  height: 2.5px;
  background: var(--text);
  border-radius: 2px;
  transition: transform .2s, opacity .2s;
}
body.mobile-menu-open .nav-hamburger span:nth-child(1) {
  transform: translateY(7.5px) rotate(45deg);
}
body.mobile-menu-open .nav-hamburger span:nth-child(2) {
  opacity: 0;
}
body.mobile-menu-open .nav-hamburger span:nth-child(3) {
  transform: translateY(-7.5px) rotate(-45deg);
}

.mobile-nav-backdrop {
  display: none;
  position: fixed;
  inset: 64px 0 0 0;
  background: rgba(0,0,0,.35);
  z-index: 98;
}
body.mobile-menu-open .mobile-nav-backdrop { display: block; }

.mobile-nav-panel {
  display: none;
  position: fixed;
  top: 64px;
  left: 0;
  right: 0;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  box-shadow: 0 8px 24px rgba(0,0,0,.15);
  padding: 12px;
  z-index: 99;
  flex-direction: column;
  gap: 4px;
  max-height: calc(100vh - 64px);
  overflow-y: auto;
}
body.mobile-menu-open .mobile-nav-panel {
  display: flex;
  animation: mobileNavSlide .2s ease-out;
}
@keyframes mobileNavSlide {
  from { transform: translateY(-10px); opacity: 0; }
  to   { transform: translateY(0);     opacity: 1; }
}
.mobile-nav-link {
  background: none;
  border: none;
  text-align: left;
  padding: 14px 18px;
  font-size: 1rem;
  font-weight: 600;
  color: var(--text);
  border-radius: 10px;
  cursor: pointer;
  min-height: 48px;
  font-family: var(--font);
}
.mobile-nav-link:hover,
.mobile-nav-link:active {
  background: var(--primary-light, rgba(124,58,237,.08));
  color: var(--primary);
}
.mobile-nav-cta {
  background: var(--primary);
  color: white;
  margin-top: 8px;
  text-align: center;
}
.mobile-nav-cta:hover,
.mobile-nav-cta:active {
  background: var(--primary);
  color: white;
  opacity: .92;
}

.bottom-nav {
  /* BIS v1.2 Phase 3 — bottom nav matches the top nav's Deep Purple bar
     so signed-in mobile users see one continuous brand frame. */
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--deep-purple);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: none;
  z-index: 90;
  padding: 6px 4px calc(6px + env(safe-area-inset-bottom, 0px));
}
.bottom-nav-btn {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  background: none;
  border: none;
  padding: 6px 4px;
  min-height: 56px;
  cursor: pointer;
  color: rgba(255, 255, 255, 0.7);
  font-family: var(--font-body);
  font-weight: 500;
  border-radius: 8px;
  transition: color 150ms ease;
}
.bottom-nav-btn:hover,
.bottom-nav-btn.active { color: #FFFFFF; }
.bottom-nav-btn svg,
.bottom-nav-btn i {
  color: inherit;
  stroke: currentColor;
}
.bottom-nav-icon { font-size: 1.35rem; line-height: 1; }
.bottom-nav-label { font-size: .7rem; font-weight: 600; letter-spacing: .2px; }

@media (max-width: 767px) {
  .header-nav-app .header-nav-sections,
  .header-nav-app .header-nav-right { display: none; }
  .header-nav > .nav-btn,
  .header-nav > .btn-primary { display: none; }
  .nav-hamburger { display: flex; }
  body.signed-in .bottom-nav { display: flex; }
  body.signed-in { padding-bottom: 72px; }

  /* Landing hero — stack buttons full-width through 767px so phones in landscape
     (and tablets up to the hamburger breakpoint) don't cramp the five outline buttons. */
  .lp-hero-btns { flex-direction: column; }
  .lp-hero-learn-btns { flex-direction: column; gap: 10px; }
  .lp-hero-learn-btns .lp-btn-outline { flex: 1 1 auto; width: 100%; max-width: 360px; margin: 0 auto; }
  .lp-btn-lg { width: 100%; max-width: 360px; }
  .lp-hero-btns .btn-primary.lp-btn-lg { margin: 0 auto; }

  /* Pricing audience tabs — full-width stack so each tab is an easy tap target. */
  .pricing-audience-tabs { gap: 12px; }
  .pricing-audience-tab { flex: 1 1 100%; }

  /* About hero outline buttons stack the same way when present. */
  .about-hero-btns { flex-direction: column; gap: 10px; align-items: center; }
  .about-hero-btns .lp-btn-outline { width: 100%; max-width: 360px; }
}

/* ============================================================
   LEVEL 1 ANIMATIONS — Polish pass
   All animations live inside `prefers-reduced-motion: no-preference`
   so users with reduced-motion enabled see none of them.
   ============================================================ */

@media (prefers-reduced-motion: no-preference) {

  /* ---- Keyframes ---- */
  @keyframes lvl1FadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
  }
  @keyframes lvl1FadeUp {
    from { opacity: 0; transform: translateY(8px); }
    to   { opacity: 1; transform: translateY(0); }
  }
  @keyframes lvl1CardEnter {
    from { opacity: 0; transform: translateY(12px); }
    to   { opacity: 1; transform: translateY(0); }
  }
  @keyframes lvl1QuizCorrectPulse {
    0%   { box-shadow: 0 0 0 0 rgba(5,150,105,.55); }
    60%  { box-shadow: 0 0 0 10px rgba(5,150,105,0); }
    100% { box-shadow: 0 0 0 0 rgba(5,150,105,0); }
  }
  @keyframes lvl1QuizWrongShake {
    0%, 100% { transform: translateX(0); }
    20%      { transform: translateX(-6px); }
    40%      { transform: translateX(5px); }
    60%      { transform: translateX(-3px); }
    80%      { transform: translateX(2px); }
  }
  @keyframes lvl1CelebrateIn {
    0%   { opacity: 0; transform: scale(.92); }
    60%  { opacity: 1; transform: scale(1.02); }
    100% { opacity: 1; transform: scale(1); }
  }
  @keyframes lvl1TakeawayReveal {
    0%   { opacity: 0; transform: translateY(24px); }
    100% { opacity: 1; transform: translateY(0); }
  }
  @keyframes lvl1ProgressFill {
    from { width: 0; }
  }
  @keyframes lvl1CertReveal {
    from { opacity: 0; transform: scale(.95); }
    to   { opacity: 1; transform: scale(1); }
  }

  /* ---- Page transitions ----
     Each top-level screen wrapper fades in when render() rebuilds it. We
     target the actual wrapper classes used by the various render*() funcs
     so we don't accidentally animate persistent chrome (header, bottom nav). */
  .lesson-wrapper,
  .quiz-wrapper,
  .results-wrapper,
  .ob-container,
  .screen-card,
  .pathways-hero,
  .pathway-detail-hero {
    animation: lvl1FadeIn .2s ease both;
  }

  /* ---- Course card stagger entrance + lift on hover ----
     Override the existing -2px lift with a -4px lift and a stronger shadow.
     The stagger uses nth-child so card N appears N*60ms after the previous. */
  .course-grid .course-card,
  .elective-grid .elective-card,
  .pathway-grid .pathway-card {
    animation: lvl1CardEnter .35s cubic-bezier(.22,1,.36,1) both;
  }
  .course-grid .course-card:nth-child(1),
  .elective-grid .elective-card:nth-child(1),
  .pathway-grid .pathway-card:nth-child(1) { animation-delay: 0ms; }
  .course-grid .course-card:nth-child(2),
  .elective-grid .elective-card:nth-child(2),
  .pathway-grid .pathway-card:nth-child(2) { animation-delay: 60ms; }
  .course-grid .course-card:nth-child(3),
  .elective-grid .elective-card:nth-child(3),
  .pathway-grid .pathway-card:nth-child(3) { animation-delay: 120ms; }
  .course-grid .course-card:nth-child(4),
  .elective-grid .elective-card:nth-child(4),
  .pathway-grid .pathway-card:nth-child(4) { animation-delay: 180ms; }
  .course-grid .course-card:nth-child(5),
  .elective-grid .elective-card:nth-child(5),
  .pathway-grid .pathway-card:nth-child(5) { animation-delay: 240ms; }
  .course-grid .course-card:nth-child(6),
  .elective-grid .elective-card:nth-child(6),
  .pathway-grid .pathway-card:nth-child(6) { animation-delay: 300ms; }
  .course-grid .course-card:nth-child(n+7),
  .elective-grid .elective-card:nth-child(n+7),
  .pathway-grid .pathway-card:nth-child(n+7) { animation-delay: 360ms; }

  .course-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 8px 16px rgba(0,0,0,0.10), 0 16px 32px rgba(0,0,0,0.08);
  }
  .pathway-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 8px 16px rgba(0,0,0,0.10), 0 16px 32px rgba(0,0,0,0.08);
  }

  /* ---- Buttons: tactile press + smooth hover ---- */
  .btn-primary,
  .btn-secondary,
  .cert-btn,
  .option-btn {
    transition: background .15s ease, color .15s ease, border-color .15s ease,
                box-shadow .15s ease, transform .12s ease, opacity .15s ease;
  }
  .btn-primary:active:not(:disabled),
  .btn-secondary:active:not(:disabled),
  .cert-btn.ready:active {
    transform: scale(.97);
  }

  /* ---- Quiz interactions ---- */
  .option-btn.correct { animation: lvl1QuizCorrectPulse .55s ease; }
  .option-btn.wrong   { animation: lvl1QuizWrongShake .35s ease; }
  .quiz-retry-banner  { animation: lvl1FadeIn .3s ease both; }

  /* ---- Celebration / pass screen ---- */
  .results-hero.pass,
  .results-hero.retry {
    animation: lvl1CelebrateIn .45s cubic-bezier(.34,1.56,.64,1) both;
  }

  /* ---- Takeaway card reveal at end of lesson ---- */
  .takeaway-card {
    animation: lvl1TakeawayReveal .55s cubic-bezier(.22,1,.36,1) both;
  }

  /* ---- Progress bar fills animate from 0 to their inline width ---- */
  .track-progress-fill,
  .tts-progress-fill,
  .lesson-gen-bar-fill,
  .spending-bar-fill,
  .budget-calc-bar-fill {
    animation: lvl1ProgressFill .8s cubic-bezier(.4,0,.2,1) both;
  }

  /* ---- Certificate cards / sheet reveal ---- */
  .cert-card,
  .certs-grid .cert-card {
    animation: lvl1CertReveal .4s cubic-bezier(.22,1,.36,1) both;
  }
  .certs-grid .cert-card:nth-child(2) { animation-delay: 70ms; }
  .certs-grid .cert-card:nth-child(3) { animation-delay: 140ms; }
  .certs-grid .cert-card:nth-child(n+4) { animation-delay: 210ms; }
}

/* ================================================================
   Nobody Taught Me page
   ================================================================ */
.ntm-page {
  --ntm-green: #1D9E75;
  --ntm-green-dark: #147a58;
  --ntm-green-light: #E6F6EF;
  max-width: 980px;
  margin: 0 auto;
  padding: 0 20px 60px;
}
.ntm-page .back-btn { margin-top: 16px; }

.ntm-hero {
  text-align: center;
  padding: 60px 16px 48px;
  position: relative;
}
.ntm-hero-eyebrow {
  display: inline-block;
  font-size: .75rem;
  font-weight: 800;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--ntm-green);
  background: var(--ntm-green-light);
  padding: 8px 16px;
  border-radius: 100px;
  margin-bottom: 20px;
}
.ntm-hero-h1 {
  font-size: clamp(2.6rem, 7vw, 5rem);
  font-weight: 900;
  line-height: 1;
  letter-spacing: -.03em;
  margin: 0 0 18px;
  color: var(--text-primary, #111);
}
.ntm-hero-accent {
  color: var(--ntm-green);
  position: relative;
  white-space: nowrap;
}
.ntm-hero-accent::after {
  content: '';
  position: absolute;
  left: 0; right: 0; bottom: .05em;
  height: .18em;
  background: var(--ntm-green);
  opacity: .18;
  border-radius: 4px;
  z-index: -1;
}
.ntm-hero-sub {
  font-size: clamp(1.05rem, 2vw, 1.3rem);
  color: var(--text-secondary, #555);
  max-width: 640px;
  margin: 0 auto 28px;
  line-height: 1.5;
}
.ntm-hero-cta { margin-bottom: 22px; }
.ntm-cta-btn {
  background: var(--ntm-green) !important;
  border-color: var(--ntm-green) !important;
}
.ntm-cta-btn:hover {
  background: var(--ntm-green-dark) !important;
  border-color: var(--ntm-green-dark) !important;
}
.ntm-hero-hint {
  font-size: .85rem;
  color: var(--text-secondary, #888);
  opacity: .75;
}

.ntm-list-section { padding: 20px 0; }
.ntm-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.ntm-card {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 20px;
  width: 100%;
  background: var(--surface, #fff);
  border: 1.5px solid var(--border, #e5e7eb);
  border-left: 5px solid var(--ntm-card-color, #1D9E75);
  border-radius: 18px;
  padding: 22px 24px;
  text-align: left;
  font: inherit;
  color: inherit;
  cursor: pointer;
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
  box-shadow: 0 1px 3px rgba(0,0,0,.04);
}
.ntm-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 30px rgba(29,158,117,.15);
  border-color: var(--ntm-card-color, #1D9E75);
}
.ntm-card:focus-visible {
  outline: 3px solid var(--ntm-green);
  outline-offset: 3px;
}
.ntm-card-num {
  font-size: .78rem;
  font-weight: 800;
  color: var(--ntm-card-color, #1D9E75);
  background: rgba(29,158,117,.08);
  padding: 6px 10px;
  border-radius: 8px;
  letter-spacing: 1px;
  align-self: flex-start;
}
.ntm-card-body { min-width: 0; }
.ntm-statement {
  font-size: clamp(1.15rem, 2.2vw, 1.55rem);
  font-weight: 800;
  line-height: 1.28;
  color: var(--text-primary, #111);
  margin-bottom: 10px;
  letter-spacing: -.01em;
}
.ntm-course-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  font-size: .9rem;
  color: var(--text-secondary, #666);
}
.ntm-course-icon {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--brand-amber, #F59E0B);
  flex-shrink: 0;
}
.ntm-course-id {
  font-weight: 800;
  color: var(--ntm-card-color, #1D9E75);
  font-size: .78rem;
  letter-spacing: .5px;
  background: rgba(29,158,117,.08);
  padding: 2px 8px;
  border-radius: 6px;
}
.ntm-course-title { font-weight: 600; }

.ntm-card-cta {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--ntm-card-color, #1D9E75);
  font-weight: 800;
  font-size: .88rem;
  white-space: nowrap;
}
.ntm-card-arrow {
  font-size: 1.3rem;
  transition: transform .18s ease;
}
.ntm-card:hover .ntm-card-arrow { transform: translateX(4px); }

.ntm-outro {
  text-align: center;
  padding: 60px 20px 40px;
  margin-top: 30px;
  background: var(--ntm-green-light);
  border-radius: 22px;
}
.ntm-outro-h2 {
  font-size: clamp(1.6rem, 3.5vw, 2.2rem);
  font-weight: 900;
  margin: 0 0 14px;
  color: var(--text-primary, #111);
  letter-spacing: -.02em;
}
.ntm-outro-sub {
  font-size: 1.05rem;
  color: var(--text-secondary, #555);
  max-width: 560px;
  margin: 0 auto 26px;
  line-height: 1.55;
}

/* Discovery links that point into the NTM page from other marketing pages */
.lp-hero-textlink {
  display: inline-block;
  margin-top: 18px;
  color: #1D9E75;
  font-weight: 800;
  font-size: .95rem;
  cursor: pointer;
  text-decoration: none;
  border-bottom: 2px solid rgba(29,158,117,.3);
  padding-bottom: 2px;
  transition: border-color .18s ease, transform .18s ease;
}
.lp-hero-textlink:hover {
  border-bottom-color: #1D9E75;
  transform: translateX(2px);
}
.about-mission-link {
  margin-top: 20px;
}
.about-mission-link a {
  color: #1D9E75;
  font-weight: 800;
  cursor: pointer;
  border-bottom: 2px solid rgba(29,158,117,.3);
  padding-bottom: 2px;
  transition: border-color .18s ease;
}
.about-mission-link a:hover { border-bottom-color: #1D9E75; }
.pricing-card-link {
  display: inline-block;
  margin: -4px 0 12px;
  /* BIS v1.3 — "See what's covered" link, Amber. */
  color: var(--amber);
  font-weight: 800;
  font-size: .85rem;
  cursor: pointer;
  text-decoration: none;
  border-bottom: 1.5px solid rgba(212, 136, 42, .3);
  padding-bottom: 1px;
  align-self: flex-start;
}
.pricing-card-link:hover { border-bottom-color: var(--amber); }

/* Highlight pulse applied after navigation from NTM card */
.ntm-pulse {
  animation: ntmPulse 1.8s ease-in-out 2;
  box-shadow: 0 0 0 0 rgba(29,158,117,.5);
}
@keyframes ntmPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(29,158,117,0); }
  50%      { box-shadow: 0 0 0 14px rgba(29,158,117,.18); }
}

@media (max-width: 640px) {
  .ntm-page { padding: 0 14px 40px; }
  .ntm-hero { padding: 40px 10px 32px; }
  .ntm-card {
    grid-template-columns: auto 1fr;
    gap: 12px 14px;
    padding: 18px 18px;
    border-radius: 16px;
  }
  .ntm-card-cta {
    grid-column: 1 / -1;
    justify-content: flex-end;
    font-size: .8rem;
  }
  .ntm-card-num { font-size: .7rem; padding: 4px 8px; }
  .ntm-outro { padding: 44px 18px 30px; border-radius: 18px; }
}

/* ---- Lesson intro line (replaces the old progress bar) ---- */
.lesson-intro {
  font-size: .85rem;
  color: var(--text-secondary);
  margin: 0 0 16px;
}

/* ---- Strong section landmarks in lesson body ---- */
.lesson-section-divider {
  border: none;
  border-top: 2px solid var(--border);
  margin: 52px 0 28px 0;
}
.lesson-body h2.lesson-section-heading,
.lesson-body h3.lesson-section-heading {
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: 1.75rem;
  font-weight: 900;
  letter-spacing: -0.6px;
  line-height: 1.2;
  color: #0F172A;
  margin-top: 0;
  margin-bottom: 24px;
  scroll-margin-top: 264px;
}
.lesson-section { scroll-margin-top: 264px; }
@media (max-width: 767px) {
  .lesson-body h2.lesson-section-heading,
  .lesson-body h3.lesson-section-heading,
  .lesson-section {
    scroll-margin-top: 80px;
  }
}
/* Audio-active section highlight (v2 — container-based).
   Each section's content is wrapped in a `<div class="lesson-section"
   data-section-index="N">` by wrapLessonSections(). When the audio system
   advances to a section, `.section-active` is flipped on that wrapper —
   concept callouts, paragraphs, lists, everything inside inherits the
   highlight automatically. Subtle left border + light green wash, no
   layout shift. */
.lesson-body .lesson-section {
  padding: 2px 0;
  border-left: 4px solid transparent;
  padding-left: 14px;
  margin-left: -18px;
  border-radius: 2px;
  transition: border-color .25s ease, background .25s ease;
}
.lesson-body .lesson-section.section-active {
  border-left-color: #1D9E75;
  background: #f0faf6;
}
.lesson-body .lesson-section--takeaway {
  /* The takeaway card brings its own strong visual treatment; keep the
     container padding minimal so the card's rounded corners stay clean. */
  padding: 0;
  padding-left: 14px;
  margin-left: -18px;
  border-left: 4px solid transparent;
}
.lesson-body .lesson-section--takeaway.section-active {
  border-left-color: #1D9E75;
  background: transparent;
}

.lesson-body h2.lesson-section-heading::before,
.lesson-body h3.lesson-section-heading::before {
  content: attr(data-section-index);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  min-width: 44px;
  border-radius: 50%;
  background: #1D9E75;
  color: #fff;
  font-size: 1.2rem;
  font-weight: 800;
  line-height: 1;
  flex-shrink: 0;
  box-shadow: 0 4px 12px rgba(29,158,117,.35), 0 0 0 4px rgba(29,158,117,.12);
}

/* ---- Audio player (inline, scrolls with page on all viewports) ---- */
.lesson-wrapper {
  padding-top: 0;
  padding-bottom: 40px;
}
@media (max-width: 767px) {
  /* ---- Compact audio player on mobile ---- */
  .tts-bar {
    margin: 8px 0 16px;
    padding: 10px 14px;
    box-shadow: 0 6px 18px rgba(0,0,0,.18), 0 2px 6px rgba(0,0,0,.1);
  }
  .tts-bar .tts-guide { display: none; }
  .tts-bar .tts-hint-sub { display: none; }
  .tts-bar .tts-prep-msg {
    padding-bottom: 8px;
    margin-bottom: 10px;
    font-size: .78rem;
  }
  .tts-bar .tts-top-row { flex-wrap: nowrap; gap: 10px; }
  .tts-bar .tts-text-col { flex: 1 1 auto; min-width: 0; flex-basis: auto; }
  .tts-bar .tts-text-col .tts-hint {
    text-align: left;
    font-size: .85rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .tts-bar .tts-controls {
    flex: 0 0 auto;
    flex-basis: auto;
    flex-wrap: nowrap;
    gap: 8px;
    justify-content: flex-end;
  }
  .tts-bar .tts-play-btn {
    padding: 10px 18px;
    min-height: 48px;
    min-width: 48px;
    font-size: .88rem;
    flex: 0 0 auto;
  }
  .tts-bar .tts-stop-btn {
    padding: 8px 14px;
    min-height: 44px;
    min-width: 44px;
    font-size: .78rem;
  }
  .tts-bar .tts-speed-cycle {
    padding: 8px 12px;
    min-height: 44px;
    font-size: .72rem;
  }
  .tts-bar .tts-progress { margin-top: 8px; }
  /* Mobile: bar is inline, so no extra top padding needed. Keep bottom
     room for the global bottom nav (72px). */
  body.signed-in .lesson-wrapper {
    padding-top: 0;
    padding-bottom: 96px;
  }
  .lesson-wrapper {
    padding-top: 0;
  }
  .lesson-body h2.lesson-section-heading,
  .lesson-body h3.lesson-section-heading {
    font-size: 1.35rem;
    gap: 12px;
  }
  .lesson-body h2.lesson-section-heading::before,
  .lesson-body h3.lesson-section-heading::before {
    width: 36px;
    height: 36px;
    min-width: 36px;
    font-size: 1.05rem;
    box-shadow: 0 2px 8px rgba(29,158,117,.28), 0 0 0 3px rgba(29,158,117,.12);
  }
  /* Mobile — tighter section wrapper indent so the green bar doesn't
     bleed past the lesson body padding on narrow screens. */
  .lesson-body .lesson-section {
    padding-left: 10px;
    margin-left: -14px;
    border-left-width: 3px;
  }
  .lesson-body .lesson-section--takeaway {
    padding-left: 10px;
    margin-left: -14px;
  }
}
/* ---- Persistent mini-player (appears on non-lesson pages when a lesson
   is paused mid-playback). Lives outside #app so it survives every
   re-render. Sits above the bottom nav on mobile, above the viewport
   bottom on desktop. */
#mini-player-root {
  position: fixed;
  left: 50%;
  transform: translateX(-50%) translateY(140%);
  bottom: 20px;
  width: calc(100% - 32px);
  max-width: 680px;
  z-index: 85;
  pointer-events: none;
  transition: transform .32s cubic-bezier(.2,.7,.25,1), opacity .28s ease;
  opacity: 0;
}
#mini-player-root.mini-player-visible {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
  pointer-events: auto;
}
.mini-player {
  display: flex;
  align-items: center;
  gap: 12px;
  background: linear-gradient(135deg, #1E293B 0%, #0F172A 100%);
  border-radius: 14px;
  padding: 10px 14px;
  box-shadow: 0 14px 36px rgba(0,0,0,.38), 0 2px 8px rgba(0,0,0,.2);
  color: #fff;
}
.mini-player-icon {
  font-size: 1.6rem;
  line-height: 1;
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  background: rgba(255,255,255,.08);
}
.mini-player-text {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.mini-player-course {
  font-size: .92rem;
  font-weight: 800;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  letter-spacing: .1px;
}
.mini-player-section {
  font-size: .75rem;
  font-weight: 600;
  color: rgba(255,255,255,.6);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.mini-player-playbtn {
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  min-width: 44px;
  border-radius: 50%;
  border: none;
  background: #1D9E75;
  color: #fff;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 12px rgba(29,158,117,.45);
  transition: transform .15s ease, box-shadow .15s ease, background .15s ease;
}
.mini-player-playbtn:hover {
  background: #16A34A;
  transform: scale(1.05);
}
.mini-player-playbtn:active { transform: scale(.96); }
.mini-player-playbtn svg {
  width: 20px;
  height: 20px;
  fill: #fff;
}
.mini-player-resumebtn {
  flex-shrink: 0;
  border: 1.5px solid rgba(255,255,255,.25);
  background: transparent;
  color: #fff;
  font-family: var(--font);
  font-size: .82rem;
  font-weight: 700;
  padding: 10px 16px;
  min-height: 44px;
  border-radius: 100px;
  cursor: pointer;
  white-space: nowrap;
  transition: background .15s ease, border-color .15s ease;
}
.mini-player-resumebtn:hover {
  background: rgba(255,255,255,.1);
  border-color: rgba(255,255,255,.45);
}
.mini-player-dismiss {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  min-width: 36px;
  border-radius: 50%;
  border: none;
  background: rgba(255,255,255,.06);
  color: rgba(255,255,255,.7);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background .15s ease, color .15s ease;
}
.mini-player-dismiss:hover {
  background: rgba(255,255,255,.14);
  color: #fff;
}
.mini-player-dismiss svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
}
@media (max-width: 767px) {
  #mini-player-root {
    bottom: calc(72px + env(safe-area-inset-bottom, 0px) + 8px);
    width: calc(100% - 16px);
  }
  .mini-player {
    padding: 8px 10px;
    gap: 8px;
    border-radius: 12px;
  }
  .mini-player-icon {
    width: 36px;
    height: 36px;
    font-size: 1.35rem;
    border-radius: 8px;
    flex-shrink: 0;
  }
  .mini-player-text { min-width: 0; }
  .mini-player-course {
    font-size: .85rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .mini-player-section {
    font-size: .7rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  /* All three buttons now meet the 44px minimum touch target. */
  .mini-player-playbtn {
    width: 44px;
    height: 44px;
    min-width: 44px;
  }
  .mini-player-playbtn svg { width: 18px; height: 18px; }
  .mini-player-resumebtn {
    padding: 10px 12px;
    font-size: .75rem;
    min-height: 44px;
  }
  .mini-player-dismiss {
    width: 44px;
    height: 44px;
    min-width: 44px;
  }
}
@media (max-width: 480px) {
  /* On very narrow screens trim the Resume label font but keep the 44px
     touch target — users still have play/dismiss. */
  .mini-player-resumebtn {
    padding: 10px 10px;
    font-size: .7rem;
    min-height: 44px;
  }
}
@media (prefers-reduced-motion: reduce) {
  #mini-player-root { transition: none; }
}

/* ---- Auto-resume toast (shown briefly after a scenario answer unlocks
   the next section and audio is about to pick back up). */
.audio-resume-toast {
  position: fixed;
  left: 50%;
  bottom: calc(72px + env(safe-area-inset-bottom, 0px) + 24px);
  transform: translateX(-50%) translateY(20px);
  background: linear-gradient(135deg, #1D9E75 0%, #16A34A 100%);
  color: #fff;
  font-weight: 700;
  font-size: .88rem;
  padding: 12px 18px;
  border-radius: 100px;
  box-shadow: 0 12px 30px rgba(29,158,117,.4), 0 2px 8px rgba(0,0,0,.18);
  display: inline-flex;
  align-items: center;
  gap: 10px;
  z-index: 90;
  opacity: 0;
  pointer-events: none;
  transition: opacity .25s ease, transform .25s cubic-bezier(.2,.7,.25,1);
}
.audio-resume-toast.visible {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}
.audio-resume-toast svg {
  width: 16px;
  height: 16px;
  fill: #fff;
}
@media (max-width: 767px) {
  .audio-resume-toast {
    bottom: calc(72px + env(safe-area-inset-bottom, 0px) + 16px);
    font-size: .82rem;
    padding: 10px 16px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .audio-resume-toast { transition: opacity .2s ease; }
}

/* Very narrow phones — trim the progress-bar label down one more step so
   "Section X of 8 · Long Title" doesn't ellipsis the title entirely, and
   hide the "Listen to this lesson" hint text so the three control buttons
   get all the available horizontal room. */
@media (max-width: 420px) {
  .tts-bar .tts-text-col { display: none; }
  .tts-bar .tts-controls { flex: 1 1 auto; justify-content: space-between; }
  .tts-bar .tts-play-btn { padding: 10px 14px; font-size: .85rem; flex: 1 1 auto; justify-content: center; }
}


/* ========================================================================
   Section gating + scenario question cards
   ======================================================================== */

/* Hidden-until-unlocked sections. display:none so they take no space and
   aren't read by audio highlight logic until reveal. */
.lesson-section.section-locked {
  display: none !important;
}

/* Reveal animation when a section just flipped to unlocked. */
@keyframes section-unlock-fade {
  0%   { opacity: 0; transform: translateY(14px); }
  100% { opacity: 1; transform: translateY(0); }
}
.lesson-section.section-just-unlocked {
  animation: section-unlock-fade .55s cubic-bezier(.2,.8,.2,1);
}

/* Scenario question card — lives inside its section at the bottom. */
.scenario-question {
  margin: 28px 0 8px;
  padding: 22px 24px 20px;
  background: #ffffff;
  border: 1px solid #E5E7EB;
  border-left: 4px solid #10B981;
  border-radius: 14px;
  box-shadow: 0 6px 18px -12px rgba(16, 185, 129, .45), 0 2px 6px -2px rgba(17, 24, 39, .06);
  animation: section-unlock-fade .45s cubic-bezier(.2,.8,.2,1);
}
.scenario-question-head {
  display: flex;
  align-items: center;
  margin-bottom: 10px;
}
.scenario-question-label {
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: .9px;
  text-transform: uppercase;
  color: #047857;
}
.scenario-question-text {
  font-size: 1.02rem;
  line-height: 1.55;
  color: #111827;
  font-weight: 500;
  margin-bottom: 16px;
}
.scenario-options {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.scenario-option-btn {
  display: block;
  width: 100%;
  min-height: 52px;
  padding: 14px 16px;
  border: 1.5px solid #E5E7EB;
  border-radius: 12px;
  background: #FAFAFA;
  color: #1F2937;
  font-size: .96rem;
  font-family: inherit;
  font-weight: 500;
  text-align: left;
  cursor: pointer;
  transition: background .15s, border-color .15s, transform .15s, box-shadow .15s;
}
.scenario-option-btn:hover:not(:disabled) {
  background: #F0FDF4;
  border-color: #34D399;
  transform: translateY(-1px);
  box-shadow: 0 4px 10px -6px rgba(16, 185, 129, .35);
}
.scenario-option-btn:active:not(:disabled) {
  transform: translateY(0);
}
.scenario-option-btn:disabled {
  cursor: default;
  opacity: .75;
}
.scenario-option-btn.scenario-option-selected-correct {
  background: #D1FAE5;
  border-color: #10B981;
  color: #065F46;
  font-weight: 700;
  opacity: 1;
}
.scenario-option-btn.scenario-option-selected-wrong {
  background: #FEF3C7;
  border-color: #F59E0B;
  color: #92400E;
}

.scenario-feedback { margin-top: 14px; }
.scenario-confirm,
.scenario-encourage {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding: 12px 14px;
  border-radius: 10px;
  font-size: .92rem;
  line-height: 1.5;
  animation: section-unlock-fade .35s cubic-bezier(.2,.8,.2,1);
}
.scenario-confirm {
  background: #ECFDF5;
  border: 1px solid #A7F3D0;
  color: #065F46;
}
.scenario-confirm-check {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #10B981;
  color: #fff;
  font-weight: 800;
  font-size: .8rem;
  flex-shrink: 0;
}
.scenario-encourage {
  background: #FFFBEB;
  border: 1px solid #FDE68A;
  color: #92400E;
}
.scenario-encourage-icon { font-size: 1.05rem; flex-shrink: 0; }

.scenario-transition {
  margin-top: 10px;
  padding: 10px 14px;
  background: #F5F3FF;
  border-left: 3px solid #7C3AED;
  border-radius: 8px;
  color: #5B21B6;
  font-size: .9rem;
  font-weight: 500;
  line-height: 1.5;
  animation: section-unlock-fade .45s cubic-bezier(.2,.8,.2,1);
}

.scenario-question--loading {
  border-left-color: #D1D5DB;
}
.scenario-question-loading-row {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #6B7280;
  font-size: .9rem;
}

/* v1.11.1 — Subtle "Loading question…" placeholder shown while we wait
   to see if the scenario card will mount. Replaced by the scenario card
   on success, or by the manual Continue button on timeout. */
.scenario-pending-loader {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin: 24px 0 6px;
  padding: 10px 14px;
  color: #9CA3AF;
  font-size: .88rem;
  font-style: italic;
}
.scenario-pending-text {
  letter-spacing: .01em;
}
.scenario-pending-continue {
  display: flex;
  justify-content: center;
  margin: 24px 0 6px;
}
.scenario-spinner {
  width: 16px;
  height: 16px;
  border: 2px solid #E5E7EB;
  border-top-color: #10B981;
  border-radius: 50%;
  animation: spin 0.9s linear infinite;
  display: inline-block;
}

@media (max-width: 600px) {
  .scenario-question { padding: 18px 16px 16px; margin: 24px 0 6px; }
  .scenario-question-text { font-size: .98rem; }
  .scenario-option-btn { font-size: .92rem; min-height: 56px; padding: 14px; }
}

/* Small "answer the question above to continue" nudge shown at the bottom
   of every scenario card until the user answers correctly. Styled in
   Vivoso green with an upward arrow pointing at the options. */
.scenario-nudge {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-top: 18px;
  margin-bottom: 14px;
  padding: 12px 16px;
  color: #047857;
  font-size: .98rem;
  font-weight: 800;
  text-align: center;
}
.scenario-nudge-arrow {
  display: inline-block;
  font-size: 1.25rem;
  font-weight: 900;
  line-height: 1;
  animation: scenario-nudge-bounce 1.6s ease-in-out infinite;
}
.scenario-nudge-text { letter-spacing: .01em; }
@keyframes scenario-nudge-bounce {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-3px); }
}
/* Once the user picks the right answer the nudge is no longer needed, but it
   sits ABOVE the options (v1.39.50) rather than in the confirmation's slot, so
   display:none would collapse its box and shift the whole option list upward at
   the moment the user is looking at their selection. visibility:hidden keeps the
   box and the layout still. */
.scenario-question.scenario-correct .scenario-nudge { visibility: hidden; }

/* Audio-ended nudge — shown at the top of the scenario card when audio
   playback naturally reaches the end of the currently-unlocked content on
   sections 1-4. Warm Vivoso green, NOT an error. Arrow points down at the
   scenario question below. Auto-hidden when the section is answered
   correctly (via the .scenario-correct parent selector). */
.audio-ended-nudge {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin: -4px 0 14px 0;
  padding: 12px 16px;
  background: #ECFDF5;
  border: 1.5px solid #A7F3D0;
  border-radius: 12px;
  color: #047857;
  font-size: .95rem;
  font-weight: 700;
  text-align: center;
  line-height: 1.4;
  animation: audio-ended-nudge-fade .45s cubic-bezier(.2,.8,.2,1);
}
.audio-ended-nudge[hidden] { display: none; }
.audio-ended-nudge-arrow {
  display: inline-block;
  font-size: 1.2rem;
  font-weight: 900;
  line-height: 1;
  color: #047857;
  animation: audio-ended-nudge-bounce 1.6s ease-in-out infinite;
}
.audio-ended-nudge-text { letter-spacing: .01em; }
@keyframes audio-ended-nudge-fade {
  from { opacity: 0; transform: translateY(-4px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes audio-ended-nudge-bounce {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(3px); }
}
@media (prefers-reduced-motion: reduce) {
  .audio-ended-nudge,
  .audio-ended-nudge-arrow { animation: none; }
}
.scenario-question.scenario-correct .audio-ended-nudge { display: none; }

/* Placeholder shown when a section has been unlocked but its content is
   still being fetched from the server. */
.lesson-section-loading {
  margin: 32px 0 12px;
  padding: 24px;
  background: #FAFAFA;
  border: 1px dashed #E5E7EB;
  border-radius: 14px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
  animation: section-unlock-fade .45s cubic-bezier(.2,.8,.2,1);
}
.lesson-section-loading-head {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #6B7280;
  font-size: .95rem;
}

/* ---- TTS Fallback Warning ---- */
.tts-fallback-warning {
  position: fixed;
  top: 72px;
  left: 50%;
  transform: translateX(-50%) translateY(-20px);
  z-index: 9000;
  background: #FEF3C7;
  color: #92400E;
  border: 1px solid #FCD34D;
  border-radius: 10px;
  padding: 10px 18px;
  font-size: .85rem;
  font-weight: 600;
  box-shadow: 0 4px 14px rgba(0,0,0,.12);
  opacity: 0;
  transition: opacity .3s, transform .3s;
  pointer-events: none;
  white-space: nowrap;
  max-width: 90vw;
  text-align: center;
}
.tts-fallback-warning.visible {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* ---- Feedback Button & Modal ---- */
.feedback-fab,
button.feedback-fab {
  position: fixed !important;
  bottom: 20px !important;
  right: 20px !important;
  left: auto !important;
  z-index: 9999 !important;
  display: flex !important;
  align-items: center;
  gap: 5px;
  background: var(--steel) !important;
  color: #fff !important;
  border: none !important;
  border-radius: 9999px !important;
  padding: 7px 13px !important;
  font-size: .75rem;
  font-weight: 600;
  font-family: var(--font);
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(0,0,0,.14);
  transition: transform .15s, box-shadow .15s;
}
.feedback-fab:hover,
button.feedback-fab:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0,0,0,.25);
  background: #3B4A66 !important;
}
.feedback-fab-icon {
  font-size: .85rem;
  line-height: 1;
}

@media (max-width: 767px) {
  body.signed-in .feedback-fab,
  body.signed-in button.feedback-fab { bottom: 80px !important; }
}

.feedback-overlay {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(0,0,0,.45);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  animation: feedback-fade-in .2s ease;
}
@keyframes feedback-fade-in {
  from { opacity: 0; }
  to   { opacity: 1; }
}
.feedback-modal {
  background: #fff;
  border-radius: 16px;
  width: 100%;
  max-width: 480px;
  padding: 28px 24px 20px;
  box-shadow: 0 20px 60px rgba(0,0,0,.25);
  animation: feedback-slide-up .25s ease;
}
@keyframes feedback-slide-up {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}
.feedback-modal h2 {
  margin: 0 0 4px;
  font-size: 1.25rem;
  color: #1a1a1a;
}
.feedback-modal .feedback-subtitle {
  margin: 0 0 20px;
  font-size: .9rem;
  color: #6B7280;
}
.feedback-modal label {
  display: block;
  font-size: .85rem;
  font-weight: 600;
  color: #374151;
  margin-bottom: 6px;
}
.feedback-modal select,
.feedback-modal textarea {
  width: 100%;
  border: 1px solid #D1D5DB;
  border-radius: 10px;
  padding: 10px 12px;
  font-size: .95rem;
  font-family: var(--font);
  background: #FAFAFA;
  color: #1a1a1a;
  transition: border-color .15s;
  box-sizing: border-box;
}
.feedback-modal select:focus,
.feedback-modal textarea:focus {
  outline: none;
  border-color: var(--amber);
}
.feedback-modal textarea {
  resize: vertical;
  min-height: 140px;
}
.feedback-field + .feedback-field {
  margin-top: 16px;
}
.feedback-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 20px;
}
.feedback-btn-cancel {
  padding: 10px 20px;
  border: 1px solid #D1D5DB;
  border-radius: 10px;
  background: #fff;
  color: #374151;
  font-size: .9rem;
  font-weight: 600;
  font-family: var(--font);
  cursor: pointer;
}
.feedback-btn-cancel:hover { background: #F3F4F6; }
.feedback-btn-submit {
  padding: 10px 20px;
  border: none;
  border-radius: 10px;
  background: var(--amber);
  color: #fff;
  font-size: .9rem;
  font-weight: 600;
  font-family: var(--font);
  cursor: pointer;
  transition: opacity .15s;
}
.feedback-btn-submit:disabled {
  opacity: .45;
  cursor: not-allowed;
}
.feedback-btn-submit:not(:disabled):hover {
  background: #B8741F;
}
.feedback-confirmation {
  text-align: center;
  padding: 32px 16px;
  font-size: 1.1rem;
  color: var(--oxford);
  font-weight: 600;
}

/* Phase 2.1 — Signup / email verification / auth-callback screens.
   White card on the page background, brand-aligned. Reuses existing
   .btn-primary and .btn-secondary; introduces .signup-* for the
   form and copy. Sized for mobile-first; widens at 600px+. */
.signup-page {
  min-height: 60vh;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 32px 16px 64px;
}
.signup-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px 24px;
  width: 100%;
  max-width: 440px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}
.signup-card--centered { text-align: center; }
.signup-brand {
  text-align: center;
  margin-bottom: 24px;
}
.signup-tagline {
  font-family: 'Playfair Display', Georgia, serif;
  font-style: italic;
  font-size: 14px;
  color: #A07800;
  margin: 6px 0 0;
}
.signup-headline {
  font-family: 'Playfair Display', Georgia, serif;
  font-weight: 700;
  font-size: 28px;
  line-height: 1.2;
  color: var(--vivoso-purple);
  margin: 0 0 12px;
  text-align: center;
}
.signup-intro {
  font-family: var(--font);
  font-size: 15px;
  color: var(--text);
  text-align: center;
  margin: 0 0 24px;
  line-height: 1.5;
}
.signup-subtext {
  font-family: var(--font);
  font-size: 13px;
  color: var(--text-secondary);
  text-align: center;
  margin: 16px 0 0;
  line-height: 1.5;
}
.signup-subtext a { color: var(--primary); text-decoration: underline; }
.signup-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin: 0 0 16px;
}
.signup-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  text-align: left;
}
.signup-field-label {
  font-family: var(--font);
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
}
.signup-field input {
  font-family: var(--font);
  font-size: 16px;
  padding: 11px 14px;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  background: #fff;
  color: var(--text);
  width: 100%;
  box-sizing: border-box;
  transition: border-color .15s ease;
}
.signup-field input:focus {
  outline: none;
  border-color: var(--primary);
}
.signup-field-help {
  font-family: var(--font);
  font-size: 12.5px;
  color: var(--text-secondary);
  line-height: 1.4;
}
.signup-submit {
  width: 100%;
  margin-top: 4px;
}
.signup-submit:disabled {
  opacity: 0.65;
  cursor: not-allowed;
}
.signup-alert {
  background: #FEE2E2;
  border: 1px solid #F87171;
  color: #991B1B;
  border-radius: 8px;
  padding: 10px 14px;
  font-size: 14px;
  line-height: 1.45;
  margin: 0 0 16px;
}
.signup-alert:focus { outline: 2px solid #F87171; outline-offset: 2px; }
.signup-footer-line {
  font-family: var(--font);
  font-size: 14px;
  color: var(--text-secondary);
  text-align: center;
  margin: 12px 0 0;
}
.signup-footer-line a { color: var(--primary); text-decoration: none; font-weight: 600; }
.signup-footer-line a:hover { text-decoration: underline; }
.signup-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 20px;
}
.signup-resend-status {
  font-family: var(--font);
  font-size: 13px;
  color: var(--text-secondary);
  text-align: center;
  margin: 12px 0 0;
  min-height: 1.2em;
}
@media (min-width: 600px) {
  .signup-card { padding: 40px 36px; }
  .signup-headline { font-size: 32px; }
}

/* Phase 2.1 Group B — /login screen */
.login-divider {
  display: flex;
  align-items: center;
  text-align: center;
  font-family: var(--font);
  font-size: 12px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--text-muted);
  margin: 18px 0;
}
.login-divider::before,
.login-divider::after {
  content: "";
  flex: 1;
  border-top: 1px solid var(--border);
}
.login-divider span { padding: 0 12px; }

.login-google-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  padding: 12px 16px;
  background: #ffffff;
  color: #202124;
  border: 1px solid var(--border);
  border-radius: 12px;
  font-family: var(--font);
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  transition: background 120ms ease, border-color 120ms ease, box-shadow 120ms ease;
}
.login-google-btn:hover { background: #F8FAFC; border-color: #94A3B8; box-shadow: 0 1px 2px rgba(0,0,0,.04); }
.login-google-btn:disabled { opacity: .55; cursor: not-allowed; }

.login-google-icon { display: inline-block; flex: 0 0 18px; }

.login-forgot-link {
  display: block;
  text-align: right;
  margin-top: 6px;
  font-family: var(--font);
  font-size: 12px;
  color: var(--primary);
  text-decoration: none;
  font-weight: 600;
}
.login-forgot-link:hover { text-decoration: underline; }

.nav-btn-signin { font-weight: 600; }

/* Phase 2.1 Group C — sign-out button on /profile */
.profile-signout-btn {
  color: var(--danger);
  border-color: var(--danger);
}
.profile-signout-btn:hover {
  background: var(--danger);
  color: #ffffff;
}

/* ===========================================================
   v1.21.0 — Content transparency
   =========================================================== */

/* Soft callout used on About + Landing — a quiet pointer to /our-approach.
   3px Vivoso Purple left rail + rounded right side; surface bg. */
.soft-callout {
  background: var(--surface);
  border-left: 3px solid var(--vivoso-purple);
  padding: 16px 20px;
  margin: 32px 0;
  border-radius: 0 8px 8px 0;
}
.soft-callout p {
  font-family: var(--font);
  font-size: 15px;
  color: var(--text-primary);
  margin: 0;
  line-height: 1.55;
}
.soft-callout a {
  color: var(--learning-teal);
  text-decoration: underline;
  font-weight: 500;
  cursor: pointer;
}
.soft-callout a:hover { text-decoration: none; }

/* Landing-page wrapper around the callout — keeps the content centered
   inside the lp-section grid (no card chrome, just spacing). */
.lp-soft-callout-section {
  max-width: 720px;
  margin: 0 auto;
  padding: 0 20px;
}

/* v1.22.3 — Shared "Curious how our content is created?" section.
   Lives on landing, /about, /parents, /schools, /organizations with
   audience-specific subhead copy. Replaces the old .soft-callout on
   landing and /about with a louder two-button credibility moment. */
.content-transparency-section {
  padding: 56px 20px;
  text-align: center;
  max-width: 720px;
  margin: 0 auto;
}
.content-transparency-heading {
  font-size: clamp(1.5rem, 3vw, 2rem);
  margin: 0 0 12px;
}
.content-transparency-sub {
  font-family: var(--font-body);
  color: var(--text-secondary);
  font-size: 1rem;
  font-weight: 400;
  line-height: 1.6;
  margin: 0 auto 24px;
  max-width: 620px;
}
.content-transparency-actions {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}
.btn-content-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  color: var(--vivoso-purple);
  border: 2px solid var(--vivoso-purple);
  border-radius: var(--radius-sm);
  font-family: var(--font);
  font-weight: 700;
  font-size: 0.95rem;
  padding: 12px 28px;
  cursor: pointer;
  transition: background .15s, color .15s, transform .15s, box-shadow .15s;
  text-decoration: none;
  min-width: 180px;
}
.btn-content-ghost:hover {
  background: var(--vivoso-purple);
  color: #FFFFFF;
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(107, 70, 160, 0.25);
}
@media (max-width: 600px) {
  .content-transparency-section { padding: 40px 20px; }
  .content-transparency-actions { flex-direction: column; align-items: stretch; }
  .btn-content-ghost { width: 100%; min-width: 0; }
}

/* Shared shell for /our-approach and /editorial-principles. Reuses the
   existing display class on the hero; everything else is local. */
.content-page {
  max-width: 760px;
  margin: 0 auto;
  padding: 0 20px 56px;
}
.content-page-hero {
  text-align: center;
  margin: 32px 0 28px;
}
.content-page-title {
  color: var(--vivoso-purple);
  font-size: 2.2rem;
  margin: 0 0 12px;
}
.content-page-subtitle {
  font-family: var(--font);
  font-size: 16px;
  color: var(--text-secondary);
  margin: 0;
}
.content-page-section { margin: 28px 0; }
.content-page-section h2 {
  font-family: var(--font);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--vivoso-purple);
  margin: 0 0 12px;
}
.content-page-section p {
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.65;
  color: var(--text-primary);
  margin: 0 0 14px;
}
.content-page-lede { font-size: 17px; line-height: 1.6; }
.content-page-list {
  list-style: disc;
  margin: 8px 0 14px 22px;
  padding: 0;
}
.content-page-list li {
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.65;
  color: var(--text-primary);
  margin-bottom: 10px;
}
.content-page-link {
  color: var(--learning-teal);
  text-decoration: underline;
  font-weight: 500;
  cursor: pointer;
}
.content-page-link:hover { text-decoration: none; }
.content-page-quote {
  margin: 12px 0;
  padding: 12px 16px;
  border-left: 3px solid var(--border);
  background: var(--surface);
  font-style: italic;
  color: var(--text-secondary);
  border-radius: 0 6px 6px 0;
}
.content-page-cta {
  text-align: center;
  margin-top: 36px;
}

/* Lesson personalization label — visible at full opacity, fades to 30%
   after 4s. prefers-reduced-motion users get the dimmed state from the
   start with no transition. */
.lesson-personalization-label {
  font-family: var(--font);
  font-size: 13px;
  color: #6B6878;
  margin: 8px 0 24px;
  opacity: 1;
  transition: opacity 0.6s ease;
}
.lesson-personalization-label.dimmed { opacity: 0.3; }
@media (prefers-reduced-motion: reduce) {
  .lesson-personalization-label {
    opacity: 0.3;
    transition: none;
  }
}

/* Lesson footer note — sub-footer link to /our-approach, deliberately
   easy to miss but available. */
.lesson-footer-note {
  margin: 48px 0 24px;
  text-align: center;
  font-family: var(--font);
  font-size: 12px;
  color: #6B6878;
  opacity: 0.7;
}
.lesson-footer-note p { margin: 0; line-height: 1.5; }
.lesson-footer-note a {
  color: var(--learning-teal);
  text-decoration: underline;
  cursor: pointer;
}
.lesson-footer-note a:hover { text-decoration: none; }

/* ===========================================================
   v1.21.4 — BETA indicators
   =========================================================== */

/* BETA pill that sits to the right of the Vivoso wordmark in the top
   nav and the landing hero. Default is the brightened-gold variant
   used on Deep Purple surfaces (top nav, landing hero). The
   --on-light modifier swaps in Mission Gold for use on light
   surfaces (onboarding welcome screen). White text in both. */
.beta-pill {
  display: inline-block;
  margin-left: 8px;
  padding: 2px 8px;
  border-radius: 4px;
  font-family: 'DM Sans', system-ui, sans-serif;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  background: #C9A23A;
  color: #ffffff;
  vertical-align: middle;
  position: relative;
  top: -2px;
  line-height: 1.4;
}
.beta-pill--on-light {
  background: var(--mission-gold, #A07800);
}
.beta-pill--xl {
  /* Slight bump for the landing hero where the wordmark is xl. */
  font-size: 11px;
  padding: 3px 10px;
  margin-left: 10px;
  top: -8px;
}

/* v1.28.99 — /courses ribbon for free-tier signed-in users. Moonlight box
   with 2px Amber border and an Amber CTA, rendered above the catalog grid.
   Mirrors the same audience as the conversion strip (free + signed-in +
   no gate bypass), conditional applied at the renderCourses call site. */
.courses-free-ribbon {
  background: var(--moonlight);
  border: 2px solid var(--amber);
  border-radius: 8px;
  padding: 16px 20px;
  margin: 0 0 24px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  font-family: 'DM Sans', system-ui, sans-serif;
  font-size: 15px;
  color: var(--steel);
  flex-wrap: wrap;
}
.courses-free-ribbon span {
  flex: 1;
  min-width: 200px;
}
/* #17: .courses-free-ribbon .btn-primary color override removed — redundant
   with the now-Amber base .btn-primary. Responsive width rule kept below. */
@media (max-width: 640px) {
  .courses-free-ribbon {
    flex-direction: column;
    align-items: stretch;
    text-align: center;
  }
  .courses-free-ribbon .btn-primary {
    width: 100%;
  }
}

/* v1.28.99 — Free-tier conversion strip. Sticky Amber bar below the main
   nav, populated by renderHeader() only for signed-in free-tier users
   (annual/monthly/comp/admin/tester/signed-out see nothing). The :empty
   rule hides the host div for everyone else without needing a separate
   display toggle. */
#conversion-strip:empty {
  display: none;
}
.conversion-strip {
  width: 100%;
  background: var(--amber);
  color: #ffffff;
  padding: 8px 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  font-family: 'DM Sans', system-ui, sans-serif;
  font-size: 14px;
  font-weight: 500;
  position: sticky;
  top: 64px;
  z-index: 99;
  box-shadow: 0 2px 6px rgba(2, 18, 47, 0.12);
}
.conversion-strip-text {
  color: #ffffff;
}
.conversion-strip-cta {
  color: #ffffff;
  text-decoration: underline;
  cursor: pointer;
  font-weight: 600;
  white-space: nowrap;
}
.conversion-strip-cta:hover {
  color: var(--moonlight);
}
@media (max-width: 640px) {
  .conversion-strip {
    font-size: 13px;
    padding: 6px 12px;
    gap: 8px;
  }
}

/* Phase 2.3c.4 — ADMIN / TESTER indicator pill. Sits to the right of the
   Vivoso wordmark (and the BETA pill, when present) when the user has
   gate bypass. Steel #495B7D background per BIS v1.3 brand tokens, white
   DM Sans 500 small caps. */
.role-pill {
  display: inline-block;
  margin-left: 8px;
  padding: 4px 10px;
  border-radius: 12px;
  font-family: 'DM Sans', system-ui, sans-serif;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  background: #495B7D;
  color: #ffffff;
  vertical-align: middle;
  position: relative;
  top: -2px;
  line-height: 1.3;
}

/* Beta context paragraph on the onboarding welcome screen. Subtle
   subtext color, centered, capped width so it doesn't span too wide. */
.ob-welcome-beta-note {
  font-family: 'DM Sans', system-ui, sans-serif;
  font-size: 14px;
  color: #6B6878;
  margin: 16px auto 24px;
  line-height: 1.5;
  text-align: center;
  max-width: 420px;
}

/* ---- Schools page (v1.22.0 — ported from public/schools.html on SPA conversion) ---- */
.schools-page { max-width: 1100px; margin: 0 auto; padding: 0 20px 80px; }

.schools-hero {
  background: linear-gradient(135deg, #7C3AED 0%, #9F67FA 50%, #C084FC 100%);
  border-radius: 24px;
  padding: 64px 40px;
  color: white;
  margin: 32px 0 0;
  position: relative;
  overflow: hidden;
  text-align: center;
}
.schools-hero::before {
  content: '';
  position: absolute;
  top: -50px; right: -50px;
  width: 300px; height: 300px;
  background: rgba(255,255,255,.06);
  border-radius: 50%;
}
.schools-hero::after {
  content: '';
  position: absolute;
  bottom: -80px; left: -30px;
  width: 200px; height: 200px;
  background: rgba(255,255,255,.04);
  border-radius: 50%;
}
.schools-hero-content { position: relative; z-index: 1; }
.schools-hero h1 {
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  font-weight: 900;
  letter-spacing: -1px;
  margin-bottom: 16px;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
}
.schools-hero p {
  font-size: 1.1rem;
  opacity: .9;
  max-width: 600px;
  margin: 0 auto 28px;
  line-height: 1.6;
}
.schools-hero-cta {
  display: inline-block;
  background: white;
  color: var(--primary);
  font-size: 1.05rem;
  font-weight: 800;
  padding: 16px 36px;
  border-radius: 12px;
  border: none;
  cursor: pointer;
  font-family: var(--font);
  transition: all .15s;
  text-decoration: none;
}
.schools-hero-cta:hover { transform: translateY(-2px); box-shadow: 0 4px 20px rgba(0,0,0,.2); }

.schools-section { padding: 64px 0; }
.schools-section-alt {
  background: var(--bg);
  margin: 0 -20px;
  padding: 64px 20px;
}
.schools-section-dark {
  background: #0F172A;
  margin: 0 -20px;
  padding: 64px 20px;
  color: white;
}
.schools-section-purple {
  background: linear-gradient(135deg, #7C3AED 0%, #5B21B6 100%);
  margin: 0 -20px;
  padding: 64px 20px;
  color: white;
}
.schools-section h2,
.schools-section-alt h2,
.schools-section-dark h2,
.schools-section-purple h2 {
  font-size: 1.8rem;
  font-weight: 900;
  text-align: center;
  letter-spacing: -0.5px;
  margin-bottom: 12px;
}
.schools-section-sub {
  text-align: center;
  color: var(--text-secondary);
  font-size: 1rem;
  margin-bottom: 40px;
  max-width: 640px;
  margin-left: auto;
  margin-right: auto;
  line-height: 1.6;
}
.schools-section-dark .schools-section-sub { color: rgba(255,255,255,.6); }
.schools-section-purple .schools-section-sub { color: rgba(255,255,255,.7); }

.schools-problem-body {
  max-width: 680px;
  margin: 0 auto;
  font-size: 1.02rem;
  line-height: 1.8;
  color: var(--text-secondary);
  text-align: center;
}
.schools-problem-body p { margin-bottom: 16px; }

.schools-columns {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  max-width: 960px;
  margin: 0 auto;
}
.schools-column {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 24px;
  text-align: center;
}
.schools-column-icon {
  display: inline-block;
  width: 28px;
  height: 4px;
  border-radius: 2px;
  background: #F59E0B;
  margin-bottom: 16px;
}
.schools-column h3 { font-size: 1.05rem; font-weight: 800; margin-bottom: 10px; }
.schools-column p { font-size: .88rem; color: var(--text-secondary); line-height: 1.6; }

.schools-section-dark .schools-column {
  background: rgba(255,255,255,.06);
  border-color: rgba(255,255,255,.1);
}
.schools-section-dark .schools-column h3 { color: white; }
.schools-section-dark .schools-column p { color: rgba(255,255,255,.6); }

.schools-steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 20px;
  max-width: 960px;
  margin: 0 auto;
}
.schools-step {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 24px;
  text-align: center;
}
.schools-step-num {
  width: 44px; height: 44px;
  border-radius: 50%;
  background: var(--primary);
  color: white;
  font-size: 1.1rem;
  font-weight: 900;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px;
}
.schools-step h3 { font-size: .95rem; font-weight: 800; margin-bottom: 8px; }
.schools-step p { font-size: .85rem; color: var(--text-secondary); line-height: 1.6; }

.schools-pricing-table {
  max-width: 640px;
  margin: 0 auto;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1.5px solid var(--border);
  background: var(--surface);
}
.schools-pricing-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 28px;
  border-bottom: 1px solid var(--border);
  font-size: .95rem;
}
.schools-pricing-row:last-child { border-bottom: none; }
.schools-pricing-tier { font-weight: 700; color: var(--text); }
.schools-pricing-price { font-weight: 800; color: var(--primary); font-size: 1.05rem; }
.schools-pricing-row-highlight {
  background: var(--primary-light);
  border-bottom: none;
}
.schools-pricing-row-highlight .schools-pricing-tier {
  color: var(--primary-dark);
  font-weight: 800;
}
.schools-pricing-row-highlight .schools-pricing-price {
  color: var(--primary-dark);
}
.schools-pricing-note {
  text-align: center;
  font-size: .88rem;
  color: var(--text-muted);
  margin-top: 20px;
}
.schools-pricing-note-wrap {
  max-width: 680px;
  margin: 0 auto;
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 32px 28px;
  text-align: center;
}
.schools-pricing-note-wrap p {
  font-size: .98rem;
  line-height: 1.8;
  color: var(--text-secondary);
  margin-bottom: 0;
}

.schools-benefits {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
  max-width: 960px;
  margin: 0 auto;
}
.schools-benefit {
  background: rgba(255,255,255,.08);
  border: 1.5px solid rgba(255,255,255,.12);
  border-radius: var(--radius);
  padding: 28px 24px;
}
.schools-benefit h3 {
  font-size: .95rem;
  font-weight: 800;
  margin-bottom: 8px;
  color: white;
}
.schools-benefit p {
  font-size: .85rem;
  color: rgba(255,255,255,.65);
  line-height: 1.6;
}

.schools-form-wrap {
  max-width: 600px;
  margin: 0 auto;
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 36px 32px;
}
.schools-form-row { margin-bottom: 18px; }
.schools-form-row label {
  display: block;
  font-size: .85rem;
  font-weight: 700;
  margin-bottom: 6px;
  color: var(--text);
}
.schools-form-row input,
.schools-form-row select,
.schools-form-row textarea {
  width: 100%;
  padding: 12px 14px;
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  font-family: var(--font);
  font-size: .92rem;
  color: var(--text);
  background: var(--surface);
  transition: border-color .15s;
}
.schools-form-row input:focus,
.schools-form-row select:focus,
.schools-form-row textarea:focus {
  outline: none;
  border-color: var(--primary);
}
.schools-form-row textarea { resize: vertical; min-height: 80px; }
.schools-form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}
.schools-form-submit {
  width: 100%;
  background: var(--primary);
  color: white;
  border: none;
  padding: 16px;
  border-radius: var(--radius-sm);
  font-size: 1rem;
  font-weight: 800;
  font-family: var(--font);
  cursor: pointer;
  transition: all .15s;
  margin-top: 8px;
}
.schools-form-submit:hover { background: var(--primary-dark); transform: translateY(-1px); box-shadow: 0 4px 16px rgba(124,58,237,.4); }
.schools-form-success {
  display: none;
  text-align: center;
  padding: 40px 20px;
}
.schools-form-success h3 {
  font-size: 1.3rem;
  font-weight: 900;
  margin-bottom: 8px;
  color: var(--success);
}
.schools-form-success p {
  color: var(--text-secondary);
  font-size: .95rem;
}

@media (max-width: 600px) {
  .schools-hero { padding: 40px 24px; }
  .schools-form-grid { grid-template-columns: 1fr; }
  .schools-pricing-row { padding: 14px 18px; flex-wrap: wrap; gap: 4px; }
}

/* ---- Organizations page (v1.22.0 — ported from public/organizations.html) ---- */
.orgs-page { max-width: 1100px; margin: 0 auto; padding: 0 20px 80px; }

.orgs-hero {
  background: linear-gradient(135deg, #7C3AED 0%, #9F67FA 50%, #C084FC 100%);
  border-radius: 24px;
  padding: 64px 40px;
  color: white;
  margin: 32px 0 0;
  position: relative;
  overflow: hidden;
  text-align: center;
}
.orgs-hero::before {
  content: '';
  position: absolute;
  top: -50px; right: -50px;
  width: 300px; height: 300px;
  background: rgba(255,255,255,.06);
  border-radius: 50%;
}
.orgs-hero::after {
  content: '';
  position: absolute;
  bottom: -80px; left: -30px;
  width: 200px; height: 200px;
  background: rgba(255,255,255,.04);
  border-radius: 50%;
}
.orgs-hero-content { position: relative; z-index: 1; }
.orgs-hero h1 {
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  font-weight: 900;
  letter-spacing: -1px;
  margin-bottom: 16px;
  max-width: 750px;
  margin-left: auto;
  margin-right: auto;
}
.orgs-hero p {
  font-size: 1.1rem;
  opacity: .9;
  max-width: 640px;
  margin: 0 auto 28px;
  line-height: 1.6;
}
.orgs-hero-cta {
  display: inline-block;
  background: white;
  color: var(--primary);
  font-size: 1.05rem;
  font-weight: 800;
  padding: 16px 36px;
  border-radius: 12px;
  border: none;
  cursor: pointer;
  font-family: var(--font);
  transition: all .15s;
  text-decoration: none;
}
.orgs-hero-cta:hover { transform: translateY(-2px); box-shadow: 0 4px 20px rgba(0,0,0,.2); }

.orgs-section { padding: 64px 0; }
.orgs-section-alt {
  background: var(--bg);
  margin: 0 -20px;
  padding: 64px 20px;
}
.orgs-section-dark {
  background: #0F172A;
  margin: 0 -20px;
  padding: 64px 20px;
  color: white;
}
.orgs-section-purple {
  background: linear-gradient(135deg, #7C3AED 0%, #5B21B6 100%);
  margin: 0 -20px;
  padding: 64px 20px;
  color: white;
}
.orgs-section h2,
.orgs-section-alt h2,
.orgs-section-dark h2,
.orgs-section-purple h2 {
  font-size: 1.8rem;
  font-weight: 900;
  text-align: center;
  letter-spacing: -0.5px;
  margin-bottom: 12px;
}
.orgs-section-sub {
  text-align: center;
  color: var(--text-secondary);
  font-size: 1rem;
  margin-bottom: 40px;
  max-width: 640px;
  margin-left: auto;
  margin-right: auto;
  line-height: 1.6;
}
.orgs-section-dark .orgs-section-sub { color: rgba(255,255,255,.6); }
.orgs-section-purple .orgs-section-sub { color: rgba(255,255,255,.7); }

.orgs-types-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
  max-width: 960px;
  margin: 0 auto;
}
.orgs-type-card {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 22px 20px;
  text-align: center;
  transition: all .15s;
}
.orgs-type-card:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.orgs-type-icon { display: none; }
.orgs-type-card h3 { font-size: .9rem; font-weight: 800; color: var(--text); }

.orgs-problem-body {
  max-width: 680px;
  margin: 0 auto;
  font-size: 1.02rem;
  line-height: 1.8;
  color: var(--text-secondary);
  text-align: center;
}
.orgs-problem-body p { margin-bottom: 16px; }

.orgs-columns {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  max-width: 960px;
  margin: 0 auto;
}
.orgs-column {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 24px;
  text-align: center;
}
.orgs-column-icon { display: inline-block; width: 28px; height: 4px; border-radius: 2px; background: #F59E0B; margin-bottom: 16px; }
.orgs-column h3 { font-size: 1.05rem; font-weight: 800; margin-bottom: 10px; }
.orgs-column p { font-size: .88rem; color: var(--text-secondary); line-height: 1.6; }

.orgs-section-dark .orgs-column {
  background: rgba(255,255,255,.06);
  border-color: rgba(255,255,255,.1);
}
.orgs-section-dark .orgs-column h3 { color: white; }
.orgs-section-dark .orgs-column p { color: rgba(255,255,255,.6); }

.orgs-steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 20px;
  max-width: 960px;
  margin: 0 auto;
}
.orgs-step {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 24px;
  text-align: center;
}
.orgs-step-num {
  width: 44px; height: 44px;
  border-radius: 50%;
  background: var(--primary);
  color: white;
  font-size: 1.1rem;
  font-weight: 900;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px;
}
.orgs-step h3 { font-size: .95rem; font-weight: 800; margin-bottom: 8px; }
.orgs-step p { font-size: .85rem; color: var(--text-secondary); line-height: 1.6; }

.orgs-pricing-note-wrap {
  max-width: 680px;
  margin: 0 auto;
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 32px 28px;
  text-align: center;
}
.orgs-pricing-note-wrap p {
  font-size: .98rem;
  line-height: 1.8;
  color: var(--text-secondary);
  margin-bottom: 0;
}
.orgs-pricing-callout {
  max-width: 680px;
  margin: 20px auto 0;
  background: var(--primary-light);
  border: 2px solid var(--primary);
  border-radius: var(--radius);
  padding: 24px 28px;
  text-align: center;
}
.orgs-pricing-callout p {
  font-size: .95rem;
  font-weight: 600;
  color: var(--primary-dark);
  line-height: 1.6;
  margin: 0;
}

.orgs-benefits {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
  max-width: 960px;
  margin: 0 auto;
}
.orgs-benefit {
  background: rgba(255,255,255,.08);
  border: 1.5px solid rgba(255,255,255,.12);
  border-radius: var(--radius);
  padding: 28px 24px;
}
.orgs-benefit h3 {
  font-size: .95rem;
  font-weight: 800;
  margin-bottom: 8px;
  color: white;
}
.orgs-benefit p {
  font-size: .85rem;
  color: rgba(255,255,255,.65);
  line-height: 1.6;
}

.orgs-form-wrap {
  max-width: 600px;
  margin: 0 auto;
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 36px 32px;
}
.orgs-form-row { margin-bottom: 18px; }
.orgs-form-row label {
  display: block;
  font-size: .85rem;
  font-weight: 700;
  margin-bottom: 6px;
  color: var(--text);
}
.orgs-form-row input,
.orgs-form-row select,
.orgs-form-row textarea {
  width: 100%;
  padding: 12px 14px;
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  font-family: var(--font);
  font-size: .92rem;
  color: var(--text);
  background: var(--surface);
  transition: border-color .15s;
}
.orgs-form-row input:focus,
.orgs-form-row select:focus,
.orgs-form-row textarea:focus {
  outline: none;
  border-color: var(--primary);
}
.orgs-form-row textarea { resize: vertical; min-height: 80px; }
.orgs-form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}
.orgs-form-toggle { display: flex; gap: 12px; }
.orgs-form-toggle label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: .92rem;
  font-weight: 600;
  cursor: pointer;
  padding: 10px 20px;
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  transition: all .15s;
}
.orgs-form-toggle input[type="radio"] { display: none; }
.orgs-form-toggle input[type="radio"]:checked + span { color: var(--primary); }
.orgs-form-toggle label:has(input:checked) {
  border-color: var(--primary);
  background: var(--primary-light);
}
.orgs-form-submit {
  width: 100%;
  background: var(--primary);
  color: white;
  border: none;
  padding: 16px;
  border-radius: var(--radius-sm);
  font-size: 1rem;
  font-weight: 800;
  font-family: var(--font);
  cursor: pointer;
  transition: all .15s;
  margin-top: 8px;
}
.orgs-form-submit:hover { background: var(--primary-dark); transform: translateY(-1px); box-shadow: 0 4px 16px rgba(124,58,237,.4); }
.orgs-form-success {
  display: none;
  text-align: center;
  padding: 40px 20px;
}
.orgs-form-success h3 {
  font-size: 1.3rem;
  font-weight: 900;
  margin-bottom: 8px;
  color: var(--success);
}
.orgs-form-success p {
  color: var(--text-secondary);
  font-size: .95rem;
  line-height: 1.6;
}

.orgs-bottom-cta {
  background: var(--primary-light);
  margin: 0 -20px;
  padding: 48px 20px;
  text-align: center;
}
.orgs-bottom-cta p {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text);
  max-width: 640px;
  margin: 0 auto 24px;
  line-height: 1.6;
}
.orgs-bottom-cta-btn {
  display: inline-block;
  background: var(--primary);
  color: white;
  font-size: 1.05rem;
  font-weight: 800;
  padding: 16px 36px;
  border-radius: 12px;
  border: none;
  cursor: pointer;
  font-family: var(--font);
  transition: all .15s;
  text-decoration: none;
}
.orgs-bottom-cta-btn:hover { background: var(--primary-dark); transform: translateY(-2px); box-shadow: 0 4px 20px rgba(124,58,237,.3); }

@media (max-width: 600px) {
  .orgs-hero { padding: 40px 24px; }
  .orgs-form-grid { grid-template-columns: 1fr; }
  .orgs-types-grid { grid-template-columns: 1fr 1fr; }
}

/* ============================================================================
   v1.26.0 — MARKETING BRAND REFRESH (Oxford + Warm Amber + Frost Blue)
   ============================================================================
   Scope:
   - Global chrome (top nav, footer, BETA pill) — converts everywhere.
   - Light-surface wordmark — converts everywhere it appears on white/light bg.
   - Marketing-only surfaces: landing, about, parents, schools, organizations.

   Out of scope (preserved on Vivoso Purple identity):
   - /courses, /pathways, /pathways/*, /certificates, /profile,
     all lesson views, takeaway/celebration content, onboarding flow body.

   Cascade strategy: this block sits at the file end so its rules override
   the per-surface declarations above without editing them in place. Any
   future v1.26.0 follow-up can grep "v1.26.0" to locate the entire change.
   ============================================================================ */

/* === Tokens — already added at :root above (--oxford, --warm-amber, --frost-blue) === */

/* === GLOBAL CHROME — top nav (every page) === */
.app-header {
  background: var(--oxford);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
/* #17: warm-amber .app-header .btn-primary override removed — the .app-header
   pill rule above + base already give Amber; hover standardized to #B8741F. */

/* === GLOBAL CHROME — BETA pill (everywhere) === */
.beta-pill,
.beta-pill--on-light,
.beta-pill--xl {
  background: var(--warm-amber);
  color: #FFFFFF;
}

/* === GLOBAL CHROME — footer (signed-in minimal + signed-out full + landing) === */
.lp-footer {
  background: var(--oxford);
}
.lp-footer-brand {
  color: rgba(255, 255, 255, 0.7);
}
.lp-footer-link {
  color: rgba(255, 255, 255, 0.85);
}
.lp-footer-link:hover {
  color: #FFFFFF;
}
.lp-footer-copyright,
.lp-footer .footer-version {
  color: rgba(255, 255, 255, 0.5);
}

.app-footer,
.app-footer-pre {
  background: var(--oxford);
  border-top: none;
  color: rgba(255, 255, 255, 0.7);
}
.app-footer-brand,
.app-footer-copyright,
.app-footer .footer-version {
  color: rgba(255, 255, 255, 0.5);
}
.app-footer-link {
  color: rgba(255, 255, 255, 0.85);
}
.app-footer-link:hover {
  color: #FFFFFF;
}
.app-footer-copyright {
  border-top: 1px solid rgba(255, 255, 255, 0.10);
}

.app-footer-minimal {
  background: var(--oxford);
  border-top: none;
  color: rgba(255, 255, 255, 0.7);
  opacity: 1;
}
.app-footer-minimal .app-footer-minimal-copy,
.app-footer-minimal .app-footer-minimal-version {
  color: rgba(255, 255, 255, 0.5);
}
.app-footer-minimal-link {
  color: rgba(255, 255, 255, 0.85);
}
.app-footer-minimal-link:hover {
  color: #FFFFFF;
}
.app-footer-minimal-sep {
  color: rgba(255, 255, 255, 0.35);
}

/* === LIGHT-SURFACE WORDMARK — Oxford instead of Vivoso Purple === */
.wordmark--primary-light,
.wordmark--on-surface {
  color: var(--oxford);
}

/* === LANDING HERO — Oxford solid + Warm Amber tagline + Frost Blue descriptor === */
.lp-hero {
  background: var(--oxford);
}
/* Wordmark on hero — switch from light lavender to true white for editorial feel. */
.lp-hero-brand {
  color: #FFFFFF;
}
/* Tagline "The life skills nobody taught you" — Warm Amber on Oxford. */
.lp-hero-h1.tagline.tagline--on-dark,
.lp-hero-h1 {
  color: var(--warm-amber);
}
/* Descriptor — DM Sans, Frost Blue, not italic. */
.lp-hero-tagline {
  color: var(--frost-blue);
  font-family: var(--font-body);
  font-style: normal;
  opacity: 1;
}
/* Six secondary buttons — barely-visible white tint with Frost Blue text. */
.lp-hero .lp-btn-outline {
  background: rgba(255, 255, 255, 0.05);
  color: var(--frost-blue);
  border: 1px solid rgba(255, 255, 255, 0.15);
}
.lp-hero .lp-btn-outline:hover {
  background: rgba(255, 255, 255, 0.10);
  color: #FFFFFF;
  border-color: rgba(255, 255, 255, 0.25);
}

/* === LANDING — "I never learned..." rotating section on Oxford === */
.lp-hero-taught-section {
  background: var(--oxford);
  color: #FFFFFF;
  max-width: 100%;
  padding: 64px 24px;
  margin: 0;
}
.lp-hero-taught-section .lp-section-title,
.lp-hero-taught-section .lp-section-sub {
  color: #FFFFFF;
}
.lp-hero-taught-section .lp-section-sub {
  color: rgba(255, 255, 255, 0.7);
}
.lp-hero-taught-card {
  background: rgba(255, 255, 255, 0.04);
  border-color: rgba(255, 255, 255, 0.10);
  box-shadow: none;
}
/* Statement text white; category color rendered separately on the dot. */
.lp-hero-taught-section .lp-hero-taught-item {
  color: #FFFFFF;
}
.lp-hero-taught-section .lp-hero-taught-nav {
  background: transparent;
  border-color: rgba(255, 255, 255, 0.25);
  color: var(--warm-amber);
}
.lp-hero-taught-section .lp-hero-taught-nav:hover {
  color: #FFFFFF;
  border-color: var(--warm-amber);
}
.lp-hero-taught-list-fallback li {
  border-bottom-color: rgba(255, 255, 255, 0.10);
}

/* === LANDING — section headings + step accents on light surfaces === */
.landing .lp-section-title {
  font-family: var(--font-display);
  color: var(--oxford);
}
/* Don't override headings inside the dark rotating section. */
.landing .lp-hero-taught-section .lp-section-title {
  color: #FFFFFF;
}
.landing .lp-step-num {
  background: var(--warm-amber);
}

/* #17: warm-amber .lp-pricing-grid .btn-primary override removed — redundant with base Amber. */
.lp-price-features li::before {
  color: var(--warm-amber);
}
.lp-price-card .lp-section-title,
.lp-price-card .lp-price-amount,
.lp-price-card .lp-price-badge {
  color: var(--oxford);
}

/* === LANDING — final CTA section in Oxford === */
.lp-cta {
  background: var(--oxford);
}
/* #17: warm-amber .lp-cta .btn-primary override removed — redundant with base Amber. */

/* === SOFT CALLOUTS + content-transparency on marketing pages === */
.soft-callout {
  border-left-color: var(--oxford);
}
.soft-callout a {
  color: var(--warm-amber);
}
.content-transparency-heading {
  color: var(--oxford);
}
.btn-content-ghost {
  color: var(--oxford);
  border-color: var(--oxford);
}
.btn-content-ghost:hover {
  background: var(--oxford);
  color: #FFFFFF;
  box-shadow: 0 4px 14px rgba(2, 18, 47, 0.25);
}

/* === ABOUT PAGE === */
.about-hero h1 {
  color: var(--oxford);
}
.about-section h2 {
  color: var(--oxford);
}
.about-feature h3 {
  color: var(--oxford);
}
.about-contact-email {
  color: var(--warm-amber);
}
.about-promise-check {
  color: var(--warm-amber);
}
.about-compare-us {
  background: linear-gradient(135deg, #F4F7FB, #E5ECF5);
  border-color: var(--oxford);
}
.about-compare-us .about-compare-label,
.about-compare-us .about-compare-price {
  color: var(--oxford);
}

/* === PARENTS PAGE === */
.parents-header h1 {
  color: var(--oxford);
}
.parents-section h2 {
  color: var(--oxford);
}
.parents-contact-info a {
  color: var(--warm-amber);
}
/* #17: warm-amber .parents-page .btn-primary override removed — redundant with base Amber. */

/* === SCHOOLS PAGE — Oxford hero + Warm Amber CTAs === */
.schools-hero {
  background: var(--oxford);
}
.schools-hero h1 {
  color: #FFFFFF;
}
.schools-hero p {
  color: var(--frost-blue);
  opacity: 1;
}
.schools-hero-cta {
  background: var(--warm-amber);
  color: #FFFFFF;
}
.schools-hero-cta:hover {
  background: #A6701A;
  color: #FFFFFF;
}
.schools-section h2,
.schools-section-alt h2 {
  color: var(--oxford);
}
.schools-section-dark {
  background: var(--oxford);
}
/* Schools "Built for Schools" section — convert from purple gradient to Oxford. */
.schools-section-purple {
  background: var(--oxford);
}
.schools-column-icon {
  background: var(--warm-amber);
}
.schools-step-num {
  background: var(--warm-amber);
}
.schools-pricing-note-wrap a {
  color: var(--warm-amber);
}
.schools-form-submit {
  background: var(--warm-amber);
}
.schools-form-submit:hover {
  background: #A6701A;
  box-shadow: 0 4px 16px rgba(200, 134, 30, 0.35);
}
.schools-form-row a {
  color: var(--warm-amber);
}

/* === ORGANIZATIONS PAGE — Oxford hero + Warm Amber CTAs === */
.orgs-hero {
  background: var(--oxford);
}
.orgs-hero h1 {
  color: #FFFFFF;
}
.orgs-hero p {
  color: var(--frost-blue);
  opacity: 1;
}
.orgs-hero-cta {
  background: var(--warm-amber);
  color: #FFFFFF;
}
.orgs-hero-cta:hover {
  background: #A6701A;
  color: #FFFFFF;
}
.orgs-section h2,
.orgs-section-alt h2 {
  color: var(--oxford);
}
.orgs-section-dark {
  background: var(--oxford);
}
.orgs-section-purple {
  background: var(--oxford);
}
.orgs-column-icon {
  background: var(--warm-amber);
}
.orgs-step-num {
  background: var(--warm-amber);
}
.orgs-bottom-cta-btn {
  background: var(--warm-amber);
}
.orgs-bottom-cta-btn:hover {
  background: #A6701A;
  box-shadow: 0 4px 20px rgba(200, 134, 30, 0.30);
}
/* #17: warm-amber .orgs-page .btn-primary override removed — redundant with base Amber. */
/* === END v1.26.0 brand refresh ============================================ */

/* ============================================================================
   v1.26.1 — BRAND REFRESH CLEANUP
   ============================================================================
   Fixes to v1.26.0:
   - Rotating "things nobody taught us" section moves Oxford → light surface
     (overrides the v1.26.0 dark treatment above)
   - Pricing tab toggle: active pill Teal → Warm Amber
   - Pricing card "MOST POPULAR" badge + Annual featured border: Teal → Amber
   - Pricing "Coming Soon" disabled buttons: clarified disabled visual state
   - Footer proportions corrected for visual balance with top nav
   - Bottom landing CTA gets breathing room before the footer
   - Marketing-page link sweep: Learning Teal / Vivoso green → Warm Amber on
     /our-approach, /editorial-principles, /faq
   ============================================================================ */

/* === Rotating "I never learned..." section back to LIGHT surface === */
.lp-hero-taught-section {
  background: var(--surface);
  color: var(--text);
}
.lp-hero-taught-section .lp-section-title {
  color: var(--oxford);
}
.lp-hero-taught-section .lp-section-sub {
  color: var(--text-secondary);
}
.lp-hero-taught-card {
  background: var(--surface);
  border: 1.5px solid var(--border);
  box-shadow: var(--shadow-md);
}
.lp-hero-taught-section .lp-hero-taught-item {
  color: var(--text);
}
.lp-hero-taught-section .lp-hero-taught-nav {
  background: rgba(2, 18, 47, 0.06);
  border-color: rgba(2, 18, 47, 0.18);
  color: var(--oxford);
}
.lp-hero-taught-section .lp-hero-taught-nav:hover {
  background: rgba(2, 18, 47, 0.12);
  color: var(--oxford);
  border-color: var(--oxford);
}
.lp-hero-taught-list-fallback li {
  border-bottom-color: var(--border);
}

/* === Pricing tab toggle (How It Works / See What You'll Learn) === */
.pricing-tab.active {
  background: var(--warm-amber);
  border-color: var(--warm-amber);
  color: #FFFFFF;
  box-shadow: 0 4px 14px rgba(200, 134, 30, 0.20);
}
.pricing-tab {
  color: var(--oxford);
  border-color: rgba(2, 18, 47, 0.30);
}
.pricing-tab:hover:not(.active) {
  background: rgba(2, 18, 47, 0.04);
  border-color: var(--oxford);
  color: var(--oxford);
}

/* === Pricing card MOST POPULAR badge + Annual featured border === */
.lp-price-popular {
  background: var(--warm-amber);
  color: #FFFFFF;
}
.lp-price-featured {
  border-color: var(--warm-amber);
  box-shadow: 0 0 0 2px var(--warm-amber), var(--shadow-lg);
}

/* === Footer proportions — make footer feel deliberate (~96-120px tall) === */
.lp-footer {
  padding: 36px 24px 32px;
}
.lp-footer-inner {
  gap: 16px 24px;
  flex-wrap: wrap;
}
.lp-footer-copyright {
  margin-top: 24px;
  padding-top: 20px;
  color: rgba(255, 255, 255, 0.60);
  font-size: .8rem;
  border-top-color: rgba(255, 255, 255, 0.10);
}
.lp-footer .footer-version {
  color: rgba(255, 255, 255, 0.40);
  font-size: .72rem;
  margin-top: 8px;
  opacity: 1;
}

.app-footer,
.app-footer-pre {
  padding: 36px 20px 32px;
  margin-top: 56px;
}
.app-footer-legal-row {
  margin-top: 4px;
  gap: 24px;
}
.app-footer-copyright {
  margin-top: 24px;
  padding-top: 20px;
  font-size: .8rem;
  color: rgba(255, 255, 255, 0.60);
  border-top-color: rgba(255, 255, 255, 0.10);
}
.app-footer .footer-version {
  color: rgba(255, 255, 255, 0.40);
  font-size: .72rem;
  margin-top: 8px;
  opacity: 1;
}

.app-footer-minimal {
  padding: 28px 20px;
  margin-top: 56px;
  font-size: .78rem;
  gap: 10px;
}
.app-footer-minimal-version {
  color: rgba(255, 255, 255, 0.40);
}

@media (max-width: 600px) {
  .lp-footer {
    padding: 28px 18px;
  }
  .lp-footer-inner {
    flex-direction: column;
    gap: 10px;
    text-align: center;
  }
  .app-footer,
  .app-footer-pre {
    padding: 28px 18px;
  }
  .app-footer-inner {
    flex-direction: column;
    gap: 10px;
    text-align: center;
  }
}

/* === Bottom landing CTA — breathing room above the footer === */
.lp-cta {
  margin-bottom: 32px;
}

/* === Content pages (/our-approach, /editorial-principles) — link sweep === */
.content-page-link {
  color: var(--warm-amber);
}

/* === FAQ — green/teal accents → Warm Amber on a marketing page === */
.faq-section-title {
  color: var(--warm-amber);
  border-bottom-color: rgba(200, 134, 30, 0.25);
}
.faq-item.open {
  border-color: var(--warm-amber);
  box-shadow: 0 2px 10px rgba(200, 134, 30, 0.10);
}
.faq-question:focus-visible {
  outline-color: var(--warm-amber);
}
.faq-chevron {
  color: var(--warm-amber);
  background: rgba(200, 134, 30, 0.10);
}
.faq-item.open .faq-chevron {
  background: rgba(200, 134, 30, 0.20);
}
/* === END v1.26.1 cleanup ================================================== */

/* ============================================================================
   v1.26.2 — Marketing certificate showcase + footer width
   ============================================================================
   - Master Graduate cert (landing showcase only) banner Vivoso Purple → Oxford
   - "Vivoso Master Graduate" subtitle below banner → Oxford
   - Footer breaks out of the #app max-width container to span the full
     viewport, matching the .app-header bar above it
   In-app /certificates printable cert (printMasterCert) and the /pathways
   pathway cert (printPathwayCert) build self-contained HTML in their own
   windows — those keep Vivoso Purple per v1.26.0 scope.
   ============================================================================ */

/* v1.37.x — Master Graduate showcase band override removed: the v4 preview
   redesign dropped the .lp-cert-doc-band element (now a neutral card + Amber
   accent, set in the base .lp-cert-* block above). */

/* Footer width breakout — escape the #app { max-width: 1100px; padding: 32px 20px } box.
   .app-header sits OUTSIDE #app and naturally fills the viewport; the footers
   sit INSIDE #app so they inherited the 1100px constraint. The negative-margin
   pattern below extends them to the viewport edges without changing layout flow.
   .lp-footer-inner / .app-footer-inner already cap content at max-width 960px,
   so the link row stays centered and only the Oxford background bleeds out. */
.lp-footer,
.app-footer,
.app-footer-pre,
.app-footer-minimal {
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
}
/* === END v1.26.2 ========================================================== */

/* ============================================================================
   v1.26.3 — Rotating statement card refinement
   ============================================================================
   After v1.26.1 moved the section to a light surface, the card was carrying
   forward sizing and chrome built for the dark variant. This block:
   - Tightens the card scale (max 720px wide, 40px vertical / 48px horizontal)
   - Reduces statement text from clamp(22.4px,3.2vw,35.2px) bold to
     clamp(20px,2.4vw,26px) semibold for editorial weight
   - Replaces the category-tinted background+border+shadow with a defined
     white card: 1px Vivoso rule border + soft Oxford-tinted shadow
   - Removes the orange category dot above each statement (cleaner read)
   - Shrinks the navigation arrows to 44x44 and tightens the gap so they
     visually anchor to the card with an Oxford outline + fill-on-hover
   ============================================================================ */

.lp-hero-taught-rotator {
  gap: 8px;
  max-width: 820px;
  margin: 28px auto 0;
}

.lp-hero-taught-card {
  flex: 1;
  max-width: 720px;
  padding: 40px 48px;
  border-radius: 16px;
  background: #FFFFFF;
  border: 1px solid var(--border);
  box-shadow: 0 4px 12px rgba(2, 18, 47, 0.06);
  transition: none;
}

.lp-hero-taught-stage {
  min-height: 140px;
}

.lp-hero-taught-section .lp-hero-taught-item {
  font-size: clamp(20px, 2.4vw, 26px);
  font-weight: 600;
  line-height: 1.45;
  color: var(--text);
  font-family: var(--font-body);
  gap: 0;
  padding: 0;
  letter-spacing: -0.005em;
}

/* Drop the category dot — statement text alone reads more cleanly. */
.lp-hero-taught-dot {
  display: none;
}

/* Nav arrows tighten to the card with an Oxford outline + fill-on-hover. */
.lp-hero-taught-section .lp-hero-taught-nav {
  width: 44px;
  height: 44px;
  background: #FFFFFF;
  border: 1px solid var(--oxford);
  color: var(--oxford);
  font-size: 22px;
  font-weight: 700;
  box-shadow: 0 2px 8px rgba(2, 18, 47, 0.08);
}
.lp-hero-taught-section .lp-hero-taught-nav:hover {
  background: var(--oxford);
  color: #FFFFFF;
  border-color: var(--oxford);
}

@media (max-width: 600px) {
  .lp-hero-taught-rotator { gap: 6px; }
  .lp-hero-taught-card {
    padding: 32px 32px;
    max-width: none;
  }
  .lp-hero-taught-stage { min-height: 160px; }
  .lp-hero-taught-section .lp-hero-taught-item { font-size: 18px; }
  /* Re-assert the 44x44 tap target — the original 540px breakpoint above
     shrinks .lp-hero-taught-nav to 40x40, which is below WCAG minimum. */
  .lp-hero-taught-section .lp-hero-taught-nav {
    width: 44px;
    height: 44px;
    font-size: 22px;
  }
}
/* === END v1.26.3 ========================================================== */

/* ============================================================================
   v1.27.0 — /courses page header
   ============================================================================
   The signed-in catalog page. Header is title +
   subtitle + a single horizontal toolbar row containing filter tabs (left)
   and completion-stat navigation pills (right). Mobile stacks the two
   groups vertically and lets each scroll horizontally if needed.
   Filter behavior is CSS-driven via [data-filter] on the grid wrapper.
   ============================================================================ */

.courses-page-header {
  margin: 0 0 28px;
}
.courses-page-title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.8rem, 3.5vw, 2.4rem);
  color: var(--oxford);
  letter-spacing: -0.5px;
  line-height: 1.15;
  margin: 0 0 8px;
}
.courses-page-sub {
  font-family: var(--font-body);
  font-size: .95rem;
  color: var(--text-secondary);
  margin: 0 0 20px;
  line-height: 1.5;
}

.courses-page-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}
.courses-page-filters,
.courses-page-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.courses-page-stats { justify-content: flex-end; }

/* Filter tabs — pill shape, Oxford text on white, active is filled Oxford. */
.courses-page-filter-tab {
  background: #FFFFFF;
  color: var(--oxford);
  border: 1px solid rgba(2, 18, 47, 0.20);
  border-radius: var(--radius-pill);
  padding: 8px 16px;
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: background .15s ease, border-color .15s ease, color .15s ease;
}
.courses-page-filter-tab:hover {
  background: rgba(2, 18, 47, 0.04);
  border-color: var(--oxford);
}
.courses-page-filter-tab.active {
  background: var(--oxford);
  color: #FFFFFF;
  border-color: var(--oxford);
}
.courses-page-filter-tab:focus-visible {
  outline: 2px solid var(--warm-amber);
  outline-offset: 2px;
}

/* Completion stat pills — same pill shape, Frost Blue tint border so they
   read as related but distinct from the filter tabs (and never appear
   "active" — they're navigation shortcuts, not selectable states). */
.courses-stat-pill {
  background: #FFFFFF;
  color: var(--oxford);
  border: 1px solid rgba(139, 163, 197, 0.30);
  border-radius: var(--radius-pill);
  padding: 8px 16px;
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: background .15s ease, border-color .15s ease;
}
.courses-stat-pill:hover {
  background: rgba(139, 163, 197, 0.10);
  border-color: rgba(139, 163, 197, 0.50);
}
.courses-stat-pill:focus-visible {
  outline: 2px solid var(--warm-amber);
  outline-offset: 2px;
}

/* Filter behavior: hide non-matching .courses-group children. */
#courses-page-grid[data-filter="foundation"]   .courses-group:not([data-group="foundation"])   { display: none; }
#courses-page-grid[data-filter="elective"]     .courses-group:not([data-group="elective"])     { display: none; }
#courses-page-grid[data-filter="limited-time"] .courses-group:not([data-group="limited-time"]) { display: none; }

/* Section headers inside .courses-group keep the existing .section-header
   chrome — only the wrapping element is new. */

@media (max-width: 720px) {
  .courses-page-toolbar {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
  }
  /* v1.29.1 — Wrap to a second row instead of horizontal-scrolling so the
     last tab ("Limited Time") shows its full label at 320-430px viewports. */
  .courses-page-filters,
  .courses-page-stats {
    flex-wrap: wrap;
    justify-content: flex-start;
    row-gap: 8px;
  }
  .courses-page-filter-tab,
  .courses-stat-pill {
    min-height: 44px;
    padding: 10px 16px;
  }
}
/* === END v1.27.0 ========================================================== */

/* ============================================================================
   v1.27.1 — Sticky footer when content is shorter than the viewport
   ============================================================================
   Make #app a flex column with min-height filling the area below the sticky
   64px top nav. The footer gets margin-top: auto so it pushes to the
   viewport bottom on short pages and sits naturally after content on long
   pages. On mobile when the fixed bottom-nav is visible (signed-in),
   subtract another 72px so the footer doesn't slide behind the nav.

   Two footer-host arrangements exist:
   - In-app screens via wrap(): footer is a direct child of #app.
   - Landing: <div class="landing"> wraps everything including .lp-footer,
     so .landing also becomes a flex column to host the same pattern.

   Layers cleanly on top of v1.26.2's footer full-bleed treatment — the
   negative horizontal margin (calc(50% - 50vw)) is independent of flex
   item sizing and continues to extend the footer to viewport edges.
   ============================================================================ */

#app {
  display: flex;
  flex-direction: column;
  min-height: calc(100vh - 64px);
}
#app > .app-footer,
#app > .app-footer-pre,
#app > .app-footer-minimal {
  margin-top: auto;
}

.landing {
  display: flex;
  flex-direction: column;
  flex: 1 0 auto;
}
.landing > .lp-footer {
  margin-top: auto;
}

@media (max-width: 767px) {
  body.signed-in #app {
    min-height: calc(100vh - 64px - 72px);
  }
}
/* === END v1.27.1 ========================================================== */

/* ============================================================================
   v1.27.3 — Compact horizontal "Your Progress" pill row
   ============================================================================
   Replaces the v1.27.2 vertical stats board (which created dead space next
   to the title block). Sits to the right of the filter tabs in the
   /courses toolbar — same row, looks like a sibling of the tabs since
   both share the pill shape. The Warm Amber border alone signals purpose
   so no explicit "Your Progress" header label is needed.

   /pathways and /certificates no longer carry a progress element; their
   page headers simplify to a plain title + subtitle block (h1/p chrome
   below). The .pathways-hero / .certs-hero dark gradient blocks introduced
   pre-v1.27.2 are gone for good.
   ============================================================================ */

/* Simplified page headers for /pathways and /certificates (no right column). */
.pathways-page-header,
.certs-page-header {
  margin-bottom: 28px;
}
.pathways-page-header > h1,
.certs-page-header > h1 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.8rem, 3.5vw, 2.4rem);
  color: var(--oxford);
  letter-spacing: -0.5px;
  line-height: 1.15;
  margin: 0 0 8px;
}
.pathways-page-header > p,
.certs-page-header > p {
  font-family: var(--font-body);
  font-size: .95rem;
  color: var(--text-secondary);
  margin: 0;
  line-height: 1.5;
  max-width: 620px;
}
/* v1.28.7 — "How Certificates Work" plain-prose paragraph that replaced
   the .certs-explainer Moonlight+Amber callout. Sits under the page sub. */
.certs-page-explainer {
  font-family: var(--font-body);
  font-size: .92rem;
  color: var(--steel);
  line-height: 1.55;
  margin: 14px 0 0;
  max-width: 720px;
}

/* Horizontal stats pill — sits in .courses-page-toolbar to the right of
   the filter tabs. The .courses-page-toolbar inherited from v1.27.0
   already uses justify-content: space-between with flex-wrap, so the pill
   naturally lands at the right edge and wraps below the filters at narrow
   widths. */
.progress-pill-row {
  display: inline-flex;
  align-items: center;
  background: #FFFFFF;
  border: 1px solid var(--warm-amber);
  border-radius: var(--radius-pill);
  padding: 8px 18px;
  font-family: var(--font-body);
  font-size: 13px;
  line-height: 1;
  flex-wrap: nowrap;
}
.progress-pill-row-stat {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: transparent;
  border: none;
  padding: 0;
  font-family: var(--font-body);
  font-size: 13px;
  cursor: pointer;
  text-decoration: none;
  color: var(--oxford);
  white-space: nowrap;
}
.progress-pill-row-stat:focus-visible {
  outline: 2px solid var(--warm-amber);
  outline-offset: 4px;
  border-radius: 4px;
}
.progress-pill-row-label {
  font-weight: 500;
  color: var(--oxford);
  opacity: 0.75;
  transition: color .15s ease, opacity .15s ease, text-decoration-color .15s ease;
}
.progress-pill-row-value {
  font-weight: 600;
  color: var(--oxford);
  transition: color .15s ease;
}
.progress-pill-row-stat:hover .progress-pill-row-label,
.progress-pill-row-stat:hover .progress-pill-row-value {
  color: var(--warm-amber);
  opacity: 1;
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-thickness: 1px;
}
.progress-pill-row-sep {
  color: var(--warm-amber);
  opacity: 0.50;
  margin: 0 12px;
  font-weight: 400;
  user-select: none;
}

@media (max-width: 600px) {
  .progress-pill-row {
    padding: 8px 14px;
    font-size: 12px;
  }
  .progress-pill-row-stat { font-size: 12px; }
  .progress-pill-row-sep { margin: 0 8px; }
}
/* === END v1.27.3 ========================================================== */

/* ============================================================================
   v1.27.4 — Stats box header, rotating card border, landing footer width
   ============================================================================
   1) "Your Progress" label sits above the stats box. Toolbar uses
      align-items: flex-end so the box bottom aligns with the filter tab
      bottom; the label hangs above the filter tabs (toolbar height grows).
   2) Landing rotating "things nobody taught us" card swaps its 1px
      var(--border) for var(--warm-amber); nav arrows match.
   3) Landing footer width — root cause was .landing { overflow-x: hidden }
      clipping the negative-margin breakout. Fixed by moving <footer
      class="lp-footer"> outside <div class="landing"> in the markup so the
      footer is a direct sibling of .landing inside #app, then folding
      .lp-footer into the #app sticky-footer rule. The v1.27.1 .landing
      flex column rules are no longer needed (footer is no longer inside
      .landing) and are neutralized here.
   ============================================================================ */

/* --- 1) Stats box: label above + bottom-align toolbar --- */
.progress-pill-row-wrap {
  display: inline-flex;
  flex-direction: column;
  align-items: flex-start;
}
.progress-pill-row-label-above {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 13px;
  color: var(--oxford);
  opacity: 0.80;
  margin: 0 0 5px 4px;
  letter-spacing: 0.01em;
  line-height: 1;
}
/* Bottom-align so the box sits at the same level as the filter tabs,
   leaving the "Your Progress" label hanging above. Scoped to /courses. */
.courses-page-header .courses-page-toolbar {
  align-items: flex-end;
}

/* --- 2) Rotating statement card on landing — Warm Amber border --- */
.lp-hero-taught-card {
  border-color: var(--warm-amber);
}
.lp-hero-taught-section .lp-hero-taught-nav {
  border-color: var(--warm-amber);
}
.lp-hero-taught-section .lp-hero-taught-nav:hover {
  background: var(--warm-amber);
  border-color: var(--warm-amber);
  color: #FFFFFF;
}

/* --- 3) Landing footer — full viewport width via #app sibling pattern ---
   .lp-footer is now a direct child of #app (markup edit moved it out of
   .landing). Apply the same sticky-footer auto margin to it; the v1.26.2
   horizontal negative margin already on .lp-footer can now bleed to
   viewport edges since it's no longer trapped behind overflow-x:hidden. */
#app > .lp-footer {
  margin-top: auto;
}

/* Neutralize the v1.27.1 .landing flex column rules — no longer needed
   (the footer is outside .landing, so .landing doesn't need to host
   sticky-footer logic). Returning .landing to normal block flow keeps
   .lp-cta margins and other section spacing untouched. */
.landing {
  display: block;
  flex: none;
}
.landing > .lp-footer {
  margin-top: 0;
}
/* === END v1.27.4 ========================================================== */

/* ============================================================================
   v1.27.5 — Hero subheading font: Playfair → DM Sans
   ============================================================================
   "For teens and young adults who want to be ready for anything" shifts off
   Playfair Display 700 to DM Sans 600. Google Fonts ladder loaded in
   index.html is DM Sans 300/400/500/600 — 700 isn't loaded, so 600 is the
   correct max weight. Size, color, alignment unchanged.
   ============================================================================ */
.lp-hero-sub {
  font-family: var(--font-body);
  font-weight: 600;
}
/* === END v1.27.5 ========================================================== */

/* ============================================================================
   v1.27.6 — Stats label center, Schools/Orgs Teal sweep, /our-approach +
             /editorial-principles brand refresh
   ============================================================================ */

/* --- 1) "Your Progress" label centered above the stats box --- */
.progress-pill-row-wrap {
  align-items: stretch;
}
.progress-pill-row-label-above {
  margin: 0 0 5px 0;
  text-align: center;
}

/* --- 2) Schools/Organizations audience tabs — match the landing toggle ---
   Active pill: Warm Amber (replaces var(--primary) = Learning Teal).
   Inactive pill: Oxford text on white. Both pills equal size, single line. */
.audience-tab {
  color: var(--oxford);
  border-color: rgba(2, 18, 47, 0.30);
  white-space: nowrap;
}
.audience-tab:hover {
  background: rgba(2, 18, 47, 0.04);
  border-color: var(--oxford);
  color: var(--oxford);
}
.audience-tab.active {
  background: var(--warm-amber);
  border-color: var(--warm-amber);
  color: #FFFFFF;
  box-shadow: 0 4px 14px rgba(200, 134, 30, 0.20);
}

/* --- 3) Schools/Organizations — remaining Learning Teal accents --- */
.orgs-form-submit {
  background: var(--warm-amber);
}
.orgs-form-submit:hover {
  background: #A6701A;
  box-shadow: 0 4px 16px rgba(200, 134, 30, 0.35);
}
.schools-form-submit:hover {
  background: #A6701A;
  box-shadow: 0 4px 16px rgba(200, 134, 30, 0.35);
}
.schools-form-row input:focus,
.schools-form-row select:focus,
.schools-form-row textarea:focus,
.orgs-form-row input:focus,
.orgs-form-row select:focus,
.orgs-form-row textarea:focus {
  border-color: var(--warm-amber);
}
.schools-pricing-price {
  color: var(--warm-amber);
}
.orgs-form-toggle input[type="radio"]:checked + span {
  color: var(--warm-amber);
}
/* Bottom callout box on /organizations: was teal-tint background. Warm
   Amber tint at low alpha keeps it subtle and on-palette. Body text
   already uses var(--text), which is the dark Oxford-near-black tone. */
.orgs-bottom-cta {
  background: rgba(200, 134, 30, 0.08);
}

/* --- 4) /our-approach + /editorial-principles full color sweep ---
   Headings: Vivoso Purple → Oxford, Playfair on h2s for editorial weight.
   The .content-page-link rule from v1.26.1 already handles inline links
   (Learning Teal → Warm Amber). Hero h1 (.content-page-title.display)
   needs the color override since both .display and .content-page-title
   set Vivoso Purple. */
.content-page-title,
.content-page-title.display {
  color: var(--oxford);
}
.content-page-section h2 {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--oxford);
  letter-spacing: -0.01em;
}
/* #17: warm-amber .content-page-cta .btn-primary override removed — base .btn-primary
   now resolves to Amber (was Learning Teal when this rule was written). */
/* Quote block left rail picks up an Oxford accent so it matches the rest
   of the marketing palette instead of the neutral border default. */
.content-page-quote {
  border-left-color: var(--oxford);
}
/* === END v1.27.6 ========================================================== */

/* v1.28.0 — v1.27.7 override block removed. Original .pathway-grid (line
   ~8126) and .certs-grid (line ~3395) declarations now use minmax(280px, 1fr)
   directly. Single source of truth, no cascade ambiguity. */

/* ============================================================================
   v1.27.8 — Comprehensive marketing brand color scrub
   ============================================================================
   Findings from an exhaustive grep across style.css for legacy color values
   (Learning Teal #0D7A72, Vivoso Purple #6B46A0, Deep Purple #4A2D7A,
   Mission Gold #A07800, Vivoso Purple tint #ECE7F3, light lavenders #faf7ff
   / #ede9fe / #F8F6FB) — all unconverted instances on MARKETING surfaces
   listed below. In-app surfaces (course/elective cards, pathway cards in
   /pathways details, /certificates printable cert windows, lesson body,
   takeaway, scenario, onboarding, dashboard hero, .courses-sub-label,
   .bottom-nav, etc.) preserved per v1.26.0 scope decision.
   ============================================================================ */

/* --- Testimonials section (.lp-testimonials) --- */
.lp-testimonial-group-label {
  color: var(--oxford);
}
.lp-testimonial-card {
  background: #FFFFFF;
  border: 1px solid rgba(139, 163, 197, 0.30);
}
.lp-testimonial-card::before {
  color: rgba(200, 134, 30, 0.18);
}

/* --- Landing "How Each Course Is Built" mockup (.course-structure-*) --- */
.course-structure-step {
  background: rgba(2, 18, 47, 0.03);
  border-color: rgba(139, 163, 197, 0.30);
  box-shadow: 0 2px 4px rgba(0,0,0,0.04), 0 4px 10px rgba(2, 18, 47, 0.06);
}
.course-structure-num {
  color: var(--oxford);
}
.course-structure-chevron {
  color: var(--warm-amber);
}
@media (prefers-reduced-motion: no-preference) {
  .course-structure-step:hover {
    box-shadow: 0 4px 8px rgba(0,0,0,0.06), 0 10px 20px rgba(2, 18, 47, 0.10);
  }
}

/* --- Landing in-section quiz mockup (.in-section-quiz-mockup-*) --- */
.in-section-quiz-mockup {
  background: rgba(139, 163, 197, 0.06);
}
.in-section-quiz-mockup-card {
  border-color: rgba(2, 18, 47, 0.15);
  box-shadow: 0 4px 20px rgba(2, 18, 47, 0.08), 0 2px 6px rgba(0, 0, 0, 0.04);
}
.in-section-quiz-mockup-eyebrow {
  color: var(--oxford);
}
.in-section-quiz-mockup-choice:hover {
  border-color: rgba(139, 163, 197, 0.50);
}
.in-section-quiz-mockup-choice-letter {
  background: rgba(200, 134, 30, 0.12);
  color: var(--oxford);
}

/* --- Landing pathway-cert mockup (.pathway-cert-mockup-*) --- */
.pathway-cert-mockup {
  background: rgba(139, 163, 197, 0.06);
}
.pathway-cert-mockup-card {
  border-color: rgba(2, 18, 47, 0.15);
  box-shadow: 0 4px 20px rgba(2, 18, 47, 0.08), 0 2px 6px rgba(0, 0, 0, 0.04);
}
.pathway-cert-mockup-choice-letter {
  background: rgba(200, 134, 30, 0.12);
  color: var(--oxford);
}

/* --- Landing "EXAMPLE" pill (.mockup-example-pill) --- */
.mockup-example-pill {
  background: rgba(200, 134, 30, 0.15);
  color: var(--oxford);
}

/* --- Auth/signup pages tagline (.signup-tagline) --- */
.signup-tagline {
  color: var(--warm-amber);
}
/* === END v1.27.8 ========================================================== */

/* ============================================================================
   v1.28.0 — In-app brand evolution Phase 1
   ============================================================================
   Phase 1 scope (per spec):
   - Token system (added at :root above)
   - body.in-app class scoping (toggled in render() in app.js)
   - Page background → Moonlight Tint on in-app surfaces
   - PATHWAYS array rewritten with new spectrum colors (in app.js)
   - Master Graduate certificate → Oxford+Amber treatment
   - Printable certs updated to match (in app.js, supersedes v1.26.2)
   - Pathway cards on /pathways listing/detail pick up new colors via PATHWAYS data injection

   NOT in Phase 1 (saved for v1.28.x patches):
   - Lesson view (audio bar, scenario cards, disclaimer color-coding)
   - Takeaway card / celebration block
   - Onboarding flow
   - Profile page details
   - F01 signup modal
   - Pathway certification quiz flow
   - Course card category dot remapping
   ============================================================================ */

/* === Page background: Moonlight Tint on in-app surfaces only === */
body.in-app {
  background: var(--moonlight-tint);
}

/* === Master Graduate certificate — Oxford+Amber flagship treatment === */
/* Replaces the v1.x dark-purple gradient panel with an Oxford-anchored,
   Amber-accented unified credential. The wreath SVG itself draws its own
   gold strokes (out of CSS scope); the panel chrome and progress bar are
   what we control here. */
.master-cert-card {
  background: linear-gradient(135deg, var(--oxford), var(--storm));
}
.master-cert-card::before {
  background: rgba(212, 136, 42, 0.10);
}
.master-cert-card::after {
  background: rgba(212, 136, 42, 0.06);
}

/* === Pathway cert seal accent (Phase 1: keep medallion gold for visual
       consistency across all pathway certs per spec section 5). The
       pathway-specific banner color comes from PATHWAYS data injection;
       no extra CSS needed here since .lp-cert-master and on-screen cert
       cards consume the inline `--cert-color` set per pathway. === */

/* === Pathway cards/details inherit new spectrum colors automatically
       through the PATHWAYS data array (color/accent/gradient consumed
       inline). No additional CSS overrides needed for Phase 1; if any
       in-app pathway-detail accent still leaks Vivoso Purple after
       PATHWAYS data update, surface that in the next batch. === */
/* === END v1.28.0 ========================================================== */

/* ============================================================================
   v1.28.4 — Brand cleanup across /courses, /pathways, /certificates
   ============================================================================
   1. /courses course cards: Frost Blue outline; Amber course icons; Moss
      unlocked / Storm locked badge colors; pathway category labels untouched.
   2. /pathways pathway cards: Amber outline (border + left stripe + hover);
      icon stays category-colored via PATHWAYS data injection.
   3. /certificates: Master Graduate banner removed (now plain h2 + description
      + progress line, or a cert-card when earned); tier-section h2's are
      Oxford Playfair; cert cards get Steel border; "How Certificates Work"
      explainer Moonlight bg + Amber border.
   4. Sweep: any residual --vivoso-*/--learning-teal/--mission-gold within
      these surfaces caught and reconciled.
   ============================================================================ */

/* --- 1) /courses course cards (border updated to Steel in v1.28.7;
   v1.30.12: 3px Amber left bar always + 2px Amber outline + Amber-tinted
   shadow on hover. Left-side color preserved through Steel border-color
   overrides via explicit border-left-color longhand declarations. --- */
.course-card {
  border: 1.5px solid var(--steel);
  border-left-width: 3px;
  border-left-color: var(--amber);
}
.course-card:hover {
  border-color: var(--steel);
  border-left-color: var(--amber);
  outline: 2px solid var(--amber);
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.10),
              0 16px 32px rgba(0, 0, 0, 0.08),
              0 4px 14px rgba(212, 136, 42, 0.18);
}
.course-card.completed {
  border-color: var(--steel);
  border-left-color: var(--amber);
}
/* Course icon SVG: spectrum-aware stroke comes from inline `stroke="..."`
   in the SVG itself. CSS `stroke` property overrides the inline attribute
   per SVG presentation-attribute precedence rules. */
.course-card .course-category-icon {
  stroke: var(--amber);
}

/* Lock icons: Moss for unlocked, Storm for locked. The icon glyph itself
   uses currentColor, so changing the badge color flows through. */
.course-card .status-badge.unlocked {
  background: var(--linen-sage);
  color: var(--moss);
}
.course-card .status-badge.locked {
  background: var(--moonlight);
  color: var(--storm);
}
.course-card .status-badge.completed {
  background: var(--linen-sage);
  color: var(--moss);
}

/* --- 2) /pathways pathway cards (v1.28.7: per-pathway outlineColor inline;
   v1.30.10: 3px left bar in pathway outlineColor, other sides stay 1.5px) --- */
/* Border-width stays at 1.5px on top/right/bottom; left side widens to 3px
   for a chunky color bar. Border-color is set inline per pathway from
   PATHWAYS.outlineColor — see renderPathways. */
.pathway-card {
  border-width: 1.5px;
  border-left-width: 3px;
  border-style: solid;
}

/* --- 3) /certificates --- */
/* Tier section heading: Playfair Bold + Oxford (overrides .display's
   Vivoso Purple). Generous top spacing matches /our-approach pattern. */
.tier-section-title.display,
.tier-section > h2.display {
  color: var(--oxford);
  font-size: 1.4rem;
  margin-top: 12px;
  margin-bottom: 12px;
}
.tier-section + .tier-section .tier-section-title.display,
.tier-section + .tier-section > h2.display {
  margin-top: 32px;
}

/* Tier 2 progress line when Master Graduate not yet earned. */
.tier-progress-line {
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--steel);
  margin: 4px 0 24px;
}

/* Cert cards: Oxford border in v1.28.7 (replaces v1.28.4 Steel). */
.cert-card {
  border: 1.5px solid var(--oxford);
}
/* === END v1.28.4 ========================================================== */

/* ============================================================================
   v1.28.9 — Master Graduate cert-card modifier
   ============================================================================
   Reverts the v1.28.8 Oxford ceremonial card. The Master Graduate cert now
   uses the standard .cert-card layout (same icon, typography, progress and
   footer treatment as Pathway Cert cards) with two modifier overrides:
     • 3px Oxford border (Tier 1 cards have 1.5px) — capstone signal
     • grid-column: 1 / -1 — spans all columns of .certs-grid (full row)
   ============================================================================ */

.cert-card--master {
  border-width: 3px;
  border-color: var(--oxford);
  grid-column: 1 / -1;
}
/* === END v1.28.9 ========================================================== */

/* ============================================================================
   v1.28.35 — My Progress relocated from /courses toolbar to top of /profile
   ============================================================================
   /courses toolbar gets a small inline summary line linking to /profile.
   /profile gains a prominent stats box section above the badges/account
   blocks. The progressPillRowHtml() function is unchanged in shape — it
   just renders in a different host now.
   ============================================================================ */

/* Inline summary line on /courses toolbar — replaces the v1.27.3 full
   pill row that lived in this slot. Right-aligned next to the filter
   tabs via the existing .courses-page-toolbar space-between flex. */
.courses-progress-summary {
  font-family: var(--font-body);
  font-size: 0.92rem;
  font-weight: 400;
  color: var(--steel);
  text-decoration: none;
  white-space: nowrap;
  align-self: center;
  margin-left: auto;
  transition: color .15s ease;
}
.courses-progress-summary:hover {
  color: var(--amber);
}
.courses-progress-summary:focus-visible {
  outline: 2px solid var(--amber);
  outline-offset: 2px;
  border-radius: 4px;
}
@media (max-width: 600px) {
  .courses-progress-summary { font-size: 0.85rem; }
}

/* /profile dashboard stats section — wraps progressPillRowHtml() output
   plus a subtitle. Sits above the badges section as the visual anchor. */
.profile-progress-section {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  margin: 0 auto 32px;
  text-align: center;
}
.profile-progress-sub {
  font-family: var(--font-body);
  font-size: 0.9rem;
  color: var(--steel);
  margin: 0;
  line-height: 1.5;
}
/* === END v1.28.35 ========================================================= */

/* ============================================================================
   v1.28.38 — Contact form on /contact
   ============================================================================
   Single form with category-based routing. No email addresses in client
   HTML — the topic dropdown sends a key (general/technical/parent/etc.)
   that the server maps to a recipient alias. */

.contact-page {
  max-width: 640px;
  margin: 0 auto;
  padding: 0 0 64px;
}
.contact-form {
  display: flex;
  flex-direction: column;
  gap: 18px;
  background: #FFFFFF;
  border: 1.5px solid var(--steel);
  border-radius: var(--radius);
  padding: 28px;
  margin-top: 24px;
}
.contact-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.contact-label {
  font-family: var(--font-body);
  font-size: .9rem;
  font-weight: 600;
  color: var(--oxford);
}
.contact-form input,
.contact-form select,
.contact-form textarea {
  font-family: var(--font-body);
  font-size: 1rem;
  color: var(--oxford);
  background: #FFFFFF;
  border: 1.5px solid var(--steel);
  border-radius: 8px;
  padding: 10px 14px;
  width: 100%;
  transition: border-color .15s ease, box-shadow .15s ease;
}
.contact-form textarea {
  resize: vertical;
  min-height: 140px;
  font-family: var(--font-body);
}
.contact-form input:focus,
.contact-form select:focus,
.contact-form textarea:focus {
  outline: none;
  border-color: var(--amber);
  box-shadow: 0 0 0 3px rgba(212, 136, 42, 0.15);
}
.contact-help {
  font-family: var(--font-body);
  font-size: .8rem;
  color: var(--steel);
  opacity: 0.8;
}
.contact-error {
  font-family: var(--font-body);
  font-size: .92rem;
  color: #B91C1C;
  background: #FEF2F2;
  border: 1px solid #FECACA;
  border-radius: 6px;
  padding: 10px 14px;
}
.contact-submit {
  background: var(--amber);
  color: #FFFFFF;
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 600;
  border: none;
  border-radius: 8px;
  padding: 12px 28px;
  cursor: pointer;
  align-self: flex-start;
  min-width: 160px;
  transition: opacity .15s ease;
}
.contact-submit:hover { opacity: 0.9; }
.contact-submit:disabled { opacity: 0.6; cursor: not-allowed; }

.contact-success {
  background: #FFFFFF;
  border: 1.5px solid var(--amber);
  border-radius: var(--radius);
  padding: 36px 28px;
  text-align: center;
  margin-top: 24px;
}
.contact-success h2 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.5rem;
  color: var(--oxford);
  margin: 0 0 10px;
}
.contact-success p {
  font-family: var(--font-body);
  color: var(--steel);
  margin: 0 0 18px;
}
.contact-success-link {
  background: transparent;
  border: 1.5px solid var(--steel);
  color: var(--steel);
  font-family: var(--font-body);
  font-size: .95rem;
  padding: 10px 20px;
  border-radius: var(--radius-pill);
  cursor: pointer;
  transition: border-color .15s ease, color .15s ease;
}
.contact-success-link:hover { border-color: var(--amber); color: var(--amber); }

@media (max-width: 600px) {
  .contact-form { padding: 20px; }
  .contact-submit { width: 100%; align-self: stretch; }
}
/* About Get In Touch CTA — replaces the v1.28.0-era 7-card email grid with
   a single button routing to /contact. */
.about-contact-cta {
  background: var(--amber);
  color: #FFFFFF;
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 600;
  border: none;
  border-radius: 8px;
  padding: 12px 28px;
  cursor: pointer;
  margin-top: 16px;
  transition: opacity .15s ease;
}
.about-contact-cta:hover { opacity: 0.9; }
/* === END v1.28.38 ========================================================= */

/* ============================================================================
   v1.28.19 — /courses search bar + pathway filter chips + no-results state
   ============================================================================
   Adds three new layout rows above the existing filter tabs row:
   1. Full-width search input
   2. Horizontal scrollable pathway filter chip row
   3. (Existing) filter tabs + progress pills row stays
   All three filters AND together against each .course-card via JS.
   ============================================================================ */

.courses-search-row {
  margin: 16px 0 12px;
}
.courses-search-input {
  width: 100%;
  max-width: 1060px;
  font-family: var(--font-body);
  font-size: .95rem;
  color: var(--oxford);
  background: #FFFFFF;
  border: 1.5px solid rgba(73, 91, 125, 0.30);
  border-radius: 8px;
  padding: 10px 14px;
  transition: border-color .15s ease, box-shadow .15s ease;
}
.courses-search-input::placeholder {
  color: var(--steel);
  opacity: 0.7;
}
.courses-search-input:focus {
  outline: none;
  border-color: var(--amber);
  box-shadow: 0 0 0 3px rgba(212, 136, 42, 0.15);
}

/* Pathway chips — wrapping flex row (v1.28.23). Tints driven by inline
   per-pathway outlineColor styles set in renderCourses. Wraps to multiple
   lines instead of horizontal scroll so all 15 pathways are visible at
   any viewport width. */
/* FTUX build 4a — Browse-by (Category / Pathway) segmented toggle. */
.courses-browse-toggle {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin: 4px 0 12px;
  max-width: 1060px;
}
.courses-browse-label {
  font-size: .85rem;
  font-weight: 600;
  color: var(--text-secondary);
}
.courses-browse-btn {
  appearance: none;
  -webkit-appearance: none;
  font: inherit;
  font-size: .85rem;
  font-weight: 700;
  padding: 6px 14px;
  border: 1px solid var(--brand-rule);
  border-radius: var(--radius-pill);
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
}
.courses-browse-btn:hover {
  border-color: var(--amber);
  color: var(--amber);
}
.courses-browse-btn.is-active {
  background: var(--amber);
  border-color: var(--amber);
  color: #fff;
}
.courses-browse-btn:focus-visible {
  outline: 2px solid var(--steel);
  outline-offset: 2px;
}
.courses-browse-desc {
  margin-top: 8px;
  font-size: .85rem;
  color: var(--text-secondary);
  text-align: center;
}

/* FTUX build 4b — collapsible course-group sections (Category mode).
   Mirrors the FAQ accordion pattern with NEW classes. Bodies use the
   grid-template-rows 0fr→1fr technique so they animate AND grow to the
   content's natural height (no max-height cap → never clips tall groups). */
.courses-collapsible {
  border: 1px solid var(--brand-rule);
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--surface);
  margin-bottom: 16px;
}
.courses-group-header {
  display: flex;
  align-items: center;
  gap: 16px;
  width: 100%;
  text-align: left;
  appearance: none;
  -webkit-appearance: none;
  font: inherit;
  border: 1px solid transparent;
  background: transparent;
  padding: 16px 20px;
  cursor: pointer;
  transition: background .15s ease;
}
.courses-group-header:hover {
  background: var(--moonlight-tint);
}
.courses-group-header:focus-visible {
  outline: 2px solid var(--steel);
  outline-offset: -2px;
}
.courses-group-heading {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1;
  min-width: 0;
}
.courses-group-title {
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--oxford);
}
.courses-group-subtitle {
  display: block;
  font-size: .82rem;
  font-weight: 400;
  line-height: 1.4;
  color: var(--text-secondary);
}
.courses-group-chevron {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  color: var(--steel);
  transition: transform .25s ease;
}
.courses-group-chevron svg { width: 18px; height: 18px; }
.courses-collapsible.open .courses-group-chevron {
  transform: rotate(180deg);
}
/* Collapsing wrapper: 0fr (closed) → 1fr (open) animates to natural height. */
.courses-group-body {
  display: grid;
  grid-template-rows: 0fr;
  overflow: hidden;
  transition: grid-template-rows .3s ease;
}
.courses-collapsible.open .courses-group-body {
  grid-template-rows: 1fr;
}
/* The direct grid child must collapse fully: min-height:0 + overflow clip.
   Padding lives on this wrapper (NOT on .course-grid, the grid item) so the
   0fr track can reach a true 0 height — a border-box element can never be
   shorter than its own padding, which is what left a sliver before. */
.courses-group-inner {
  min-height: 0;
  overflow: hidden;
}
/* Neutralize the base .course-grid margin-bottom:48px ONLY inside a
   collapsible body (the global rule is left intact for other pages), and
   put the section padding HERE — on the nested grid, not the sized grid
   item (.courses-group-inner). As a plain nested child its padding forms no
   collapse floor; it's clipped by .courses-group-inner's overflow at 0fr. */
.courses-group-body .course-grid {
  margin-bottom: 0;
  padding: 4px 20px 20px;
}
/* Non-collapsible "Additional Courses" umbrella label — heading row only
   (no chevron, no pointer). Reuses .section-header for the title/badge row. */
.courses-section-label {
  margin: 24px 0 8px;
}
@media (prefers-reduced-motion: reduce) {
  .courses-group-body,
  .courses-group-chevron,
  .courses-group-header {
    transition: none !important;
  }
}

.courses-pathway-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 4px 0 8px;
  margin: 0 0 8px;
  max-width: 1060px;
}
.courses-pathway-chip {
  font-family: var(--font-body);
  font-size: .82rem;
  font-weight: 500;
  white-space: nowrap;
  flex-shrink: 0;
  padding: 6px 14px;
  border-radius: var(--radius-pill);
  cursor: pointer;
  transition: background .15s ease, color .15s ease, border-color .15s ease;
}
.courses-pathway-chip:hover { filter: brightness(0.95); }
.courses-pathway-chip:focus-visible {
  outline: 2px solid var(--amber);
  outline-offset: 2px;
}

/* Clear chip — only visible when at least one pathway chip is active. */
.courses-pathway-clear {
  font-family: var(--font-body);
  font-size: .82rem;
  font-weight: 500;
  white-space: nowrap;
  flex-shrink: 0;
  padding: 6px 14px;
  border-radius: var(--radius-pill);
  cursor: pointer;
  background: transparent;
  color: var(--steel);
  border: 1px solid var(--steel);
  display: none;
}
.courses-pathway-clear.visible { display: inline-flex; }
.courses-pathway-clear:hover {
  border-color: var(--amber);
  color: var(--amber);
}

/* No-results state — shown when all filters combine to zero matching cards. */
.courses-no-results {
  text-align: center;
  padding: 48px 20px;
  max-width: 520px;
  margin: 0 auto;
}
.courses-no-results h3 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--oxford);
  margin: 0 0 8px;
}
.courses-no-results p {
  font-family: var(--font-body);
  font-size: .95rem;
  color: var(--steel);
  margin: 0 0 20px;
  line-height: 1.5;
}
.courses-no-results-clear {
  font-family: var(--font-body);
  font-size: .92rem;
  font-weight: 500;
  background: transparent;
  border: 1.5px solid var(--steel);
  color: var(--steel);
  padding: 10px 22px;
  border-radius: var(--radius-pill);
  cursor: pointer;
  transition: border-color .15s ease, color .15s ease;
}
.courses-no-results-clear:hover {
  border-color: var(--amber);
  color: var(--amber);
}

@media (max-width: 600px) {
  .courses-search-input { font-size: 1rem; }
  .courses-pathway-chip { font-size: .78rem; padding: 6px 12px; }
}
/* === END v1.28.19 ========================================================= */

/* ============================================================================
   v1.28.20 — Course cluster banners
   ============================================================================
   Restores visual grouping for the elective sessions that v1.28.19 promoted
   to standalone cards. A cluster banner is a grid-row-spanning heading
   inserted above a parent's children when the parent has 2+ sessions.
   It's purely visual — children remain independent course entries with
   their own ids, completion tracking, and pathway memberships.
   ============================================================================ */

.course-cluster-header {
  /* v1.28.34 — Reverted to single-grid layout for the Additional section
     so visible cards reflow consecutively when filters hide siblings.
     Banner is a grid-column: 1 / -1 item again (was per-cluster sibling
     in v1.28.23/v1.28.31); display:flex column-direction stacks the
     title + subtitle inside the spanning row.
     v1.28.30 — Reverted the v1.28.28 left-side Harbor accent bar; visual
     rhythm now comes from the heading text color (Harbor on .course-
     cluster-title) instead of an accent element. */
  grid-column: 1 / -1;
  margin: 24px 0 12px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(73, 91, 125, 0.20);
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.course-cluster-title {
  /* v1.28.26 — DM Sans 600 instead of Playfair Bold so the banner reads
     as a quiet organizing label. Card titles within the cluster stay
     Playfair (the visual anchor); the banner is now sans-serif so the
     two don't compete.
     v1.28.30 — Color shifted Oxford → Harbor so cluster headings carry
     their own visual rhythm distinct from the Oxford card titles below.
     Heading reads as a Frost Blue category label; cards remain anchored
     in Oxford. */
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 1.125rem;
  letter-spacing: -0.1px;
  color: var(--harbor);
  margin: 0;
}
.course-cluster-subtitle {
  font-family: var(--font-body);
  font-size: .92rem;
  font-weight: 400;
  line-height: 1.5;
  color: var(--steel);
  margin: 0;
  max-width: 720px;
}

/* v1.28.21 — Lucide icons used on /courses cluster banners and elective
   cards. Lucide SVGs render with stroke="currentColor" so the Amber stroke
   comes from CSS color inheritance. Sizing is set inline per call site
   (32px on cards, 24px on cluster banners). */
.course-lucide-icon {
  color: var(--amber);
  display: inline-block;
  vertical-align: middle;
}
.course-lucide-icon svg {
  width: 100%;
  height: 100%;
  display: block;
}

@media (max-width: 600px) {
  .course-cluster-title { font-size: 1rem; }
}
/* === END v1.28.20 ========================================================= */

/* ============================================================================
   v1.28.10 — Landing certificate showcase: 2-column grid (Tier 1 | Tier 2)
   ============================================================================
   Adds a Finance Ready Pathway Cert preview alongside the Master Graduate
   preview in the "Earn Certificates You Can Actually Be Proud Of" section.
   The showcase becomes a 2-column grid (max-width 1060px, 32px gap, centered);
   below 768px it stacks vertically in Tier 1 → Tier 2 order with a 16px gap.
   ============================================================================ */

.lp-cert-showcase {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  justify-items: center;
  align-items: start;
  gap: 32px;
  max-width: 760px;
  margin: 0 auto 32px;
}

@media (max-width: 768px) {
  .lp-cert-showcase {
    grid-template-columns: 1fr;
    gap: 16px;
  }
}

/* v1.37.x — Pathway showcase band override removed: the v4 preview redesign
   dropped the .lp-cert-doc-band element (now a neutral card + Steel accent, set
   in the base .lp-cert-* block). The .lp-cert-showcase grid above is retained;
   card width parity is handled by the base .lp-cert-*-wrap rules. */
/* === END v1.28.10 ========================================================= */


/* === v1.28.43 — Lesson view BIS v1.3 conversion ============================
   Single override block applied at end of stylesheet so legacy color rules
   above stay intact (in case any are reused outside the lesson view). All
   selectors target lesson-experience surfaces only.
   ========================================================================= */

/* 1. Loading screen — Oxford headline, Amber progress fill, Steel completes */
.lesson-loading-screen-headline { color: var(--oxford); }
.lesson-loading-step.is-complete { color: var(--steel); }
.lesson-loading-step-fill { background: var(--amber); }
.lesson-loading-step-check { color: var(--amber); }

/* 2. Lesson header — course icon now sized + Amber. Replaces orange dot. */
.lesson-header-icon {
  width: auto;
  height: auto;
  background: transparent !important;
  box-shadow: none !important;
  border-radius: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.lesson-header-icon svg,
.lesson-header-icon i {
  width: 28px;
  height: 28px;
  color: var(--amber);
  stroke: var(--amber);
}
.lesson-header-info h2 { color: var(--oxford); }

/* 3. Age pill — Moonlight + Steel border (was teal/purple tint) */
.lesson-age-badge {
  background: var(--moonlight-tint);
  color: var(--steel);
  border: 1px solid var(--steel);
  font-family: var(--font);
  font-weight: 500;
  letter-spacing: .04em;
  text-transform: uppercase;
  font-size: .72rem;
}

/* 4. Lesson body markdown — Oxford h2 + Amber blockquote */
.lesson-body h2 { color: var(--oxford); }
.lesson-body blockquote {
  border-left-color: var(--amber);
  background: var(--moonlight-tint);
  color: var(--steel);
}

/* 5. Lesson outline counter chips — Moonlight + Amber */
.lesson-outline-item::before {
  background: var(--moonlight);
  color: var(--amber);
}

/* 6. Concept callout (key term boxes) — Harbor accent on Moonlight */
.concept-callout {
  background: var(--moonlight-tint);
  border-left: 4px solid var(--harbor);
  box-shadow: none;
}
.concept-callout-name { color: var(--steel); font-weight: 500; letter-spacing: .04em; }
.concept-callout-name::before { background: var(--harbor); }
.concept-callout-desc { color: var(--steel); }

/* 7. Section unlock buttons — Amber primary (was teal/purple).
   #17: dropped the redundant .lesson-actions .btn-primary scope (base is now
   Amber); .lesson-section-unlock-btn is a non-btn-primary class and stays. */
.lesson-section-unlock-btn {
  background: var(--amber);
  border: 1.5px solid var(--amber);
  color: white;
}
.lesson-section-unlock-btn:hover {
  background: #B8741F;
  border-color: #B8741F;
  box-shadow: 0 4px 16px rgba(212,136,42,.35);
}

/* 8. Scenario quiz cards — Frost Blue + Harbor for correct (was greens).
   Wrong/encouragement keeps Amber-warning. Transition swap purple to Amber. */
.scenario-question {
  border-left-color: var(--harbor);
  box-shadow: 0 6px 18px -12px rgba(85,119,168,.45), 0 2px 6px -2px rgba(2,18,47,.06);
}
.scenario-question-label { color: var(--steel); font-weight: 500; letter-spacing: .04em; }
.scenario-question-text { color: var(--oxford); }
.scenario-option-btn {
  background: #ffffff;
  border-color: rgba(73,91,125,.25);
  color: var(--oxford);
}
.scenario-option-btn:hover:not(:disabled) {
  background: var(--moonlight-tint);
  border-color: var(--amber);
  box-shadow: 0 4px 10px -6px rgba(212,136,42,.25);
}
.scenario-option-btn.scenario-option-selected-correct {
  background: #CDD8E8;
  border-color: var(--harbor);
  color: var(--harbor);
}
.scenario-option-btn.scenario-option-selected-wrong {
  background: #FEE2E2;
  border-color: #DC2626;
  color: #991B1B;
}
.scenario-confirm {
  background: rgba(139,163,197,.18);
  border: 1px solid var(--harbor);
  color: var(--harbor);
}
.scenario-confirm-check { background: var(--harbor); }
.scenario-encourage {
  background: var(--moonlight-tint);
  border: 1px solid var(--amber);
  color: var(--steel);
}
.scenario-transition {
  background: var(--moonlight-tint);
  border-left-color: var(--amber);
  color: var(--steel);
}
.scenario-spinner { border-top-color: var(--amber); }
.scenario-nudge { color: var(--steel); }
.audio-ended-nudge {
  background: var(--moonlight-tint);
  border-color: var(--amber);
  color: var(--steel);
}
.audio-ended-nudge-arrow { color: var(--amber); }

/* 9. Takeaway card — Amber border, Oxford header, Steel/Amber bullets */
.takeaway-card {
  border-color: var(--amber);
  box-shadow:
    0 20px 50px -20px rgba(2,18,47,.18),
    0 4px 12px -4px rgba(2,18,47,.08);
}
.takeaway-card-head {
  background: var(--oxford);
}
.takeaway-check circle { fill: var(--amber); }
.takeaway-item { border-bottom-color: var(--moonlight); }
.takeaway-card-footer {
  background: var(--moonlight-tint);
  border-top-color: var(--moonlight);
}
.takeaway-card-print-row {
  background: var(--moonlight-tint);
  border-top: 1px dashed var(--moonlight);
}
.takeaway-card-brand { color: var(--oxford); }
.takeaway-card-sep { color: var(--moonlight); }
.takeaway-print-btn {
  color: var(--steel);
  border-color: var(--steel);
}
.takeaway-print-btn:hover,
.takeaway-print-btn:focus-visible {
  background: var(--amber);
  border-color: var(--amber);
  color: white;
  box-shadow: 0 3px 12px rgba(212,136,42,.3);
}

/* 10. Celebration block — Moonlight bg, Oxford headline, Amber stars */
.lesson-celebration-card {
  background: var(--moonlight);
  border-color: var(--moonlight-tint);
}
.celebration-headline {
  color: var(--oxford);
  font-family: var(--font-display);
  font-weight: 700;
}
.celebration-star.filled { color: var(--amber); }
.celebration-star:focus-visible { outline-color: var(--amber); }
.celebration-star.filled .celebration-star-number { color: white; }

/* 11. What's next CTAs — Amber primary, Oxford for cert variant */
.whats-next-section { border-top-color: var(--moonlight-tint); }
.whats-next-heading {
  color: var(--oxford);
  font-family: var(--font-display);
}
.whats-next-cta {
  background: var(--amber);
}
.whats-next-cta:hover {
  box-shadow: 0 4px 16px rgba(212,136,42,.35);
}
.whats-next-cta:focus-visible { outline-color: var(--amber); }
.whats-next-cta--cert {
  background: var(--oxford);
  box-shadow: inset 4px 0 0 var(--amber);
}
.whats-next-cta--cert:hover {
  box-shadow: inset 4px 0 0 var(--amber), 0 4px 16px rgba(2,18,47,.35);
}
.whats-next-cta-badge { color: var(--amber); }
.whats-next-back:focus-visible { outline-color: var(--amber); }

/* 12. Audio bar (TTS) — Oxford bar with Amber accents */
.tts-bar {
  background: var(--oxford);
}
.tts-play-btn {
  background: var(--amber);
  box-shadow: 0 2px 12px rgba(212,136,42,.3);
}
.tts-play-btn:hover {
  background: #B8741F;
  box-shadow: 0 4px 18px rgba(212,136,42,.4);
}
.tts-play-btn.playing { background: var(--amber); }
.tts-play-btn.paused {
  border-color: var(--amber);
  color: #FCD34D;
}
.tts-progress-fill { background: var(--amber); }
.tts-speed-btn.active {
  background: var(--amber);
  border-color: transparent;
}
.tts-speed-cycle-val { color: var(--amber); }
.tts-active {
  background: rgba(212,136,42,.10) !important;
  border-left-color: var(--amber) !important;
  box-shadow: inset 0 0 0 1px rgba(212,136,42,.18) !important;
}

/* 13. Streaming cursor — Amber instead of legacy purple */
.lesson-md-streaming::after { color: var(--amber); }
.lesson-start-over-link:focus-visible { outline-color: var(--amber); }

/* === END v1.28.43 ========================================================= */


/* === v1.28.44 — Lesson section number circles green to Amber ============== */
.lesson-body h2.lesson-section-heading::before,
.lesson-body h3.lesson-section-heading::before {
  background: var(--amber);
  color: #ffffff;
  box-shadow: 0 4px 12px rgba(212,136,42,.35), 0 0 0 4px rgba(212,136,42,.12);
}
@media (max-width: 767px) {
  .lesson-body h2.lesson-section-heading::before,
  .lesson-body h3.lesson-section-heading::before {
    box-shadow: 0 2px 8px rgba(212,136,42,.28), 0 0 0 3px rgba(212,136,42,.12);
  }
}
.lesson-body .lesson-section--takeaway.section-active { border-left-color: var(--amber); }
/* === END v1.28.44 ========================================================= */


/* === v1.28.48 — Onboarding flow BIS v1.3 conversion =======================
   Single override block applied at end of stylesheet so legacy .ob-* rules
   above stay unchanged. Targets every onboarding screen + the four
   /profile/edit/* pickers that reuse the same .ob-* classes.
   Amber for primary CTAs, Frost Blue/Harbor for selected multi-select chips,
   Steel for ghost/secondary, Oxford headings on Moonlight Tint surface.
   ========================================================================= */

/* Surface — page background + container chrome */
.ob-container {
  background: var(--moonlight-tint);
  border-radius: 0;
}

/* Progress dots */
.ob-dot { background: rgba(73,91,125,.35); }
.ob-dot.active { background: var(--amber); }
.ob-dot.done { background: var(--amber); }

/* Welcome screen — Playfair Oxford wordmark + brand mark */
.ob-welcome-title,
.ob-brand-mark {
  color: var(--oxford);
}

/* Heading + sub copy */
.ob-heading {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--oxford);
  letter-spacing: -0.01em;
}
.ob-sub { color: var(--steel); font-family: var(--font); }
.ob-field-label { color: var(--oxford); font-weight: 500; letter-spacing: 0; }
.ob-field-note { color: var(--steel); }
.ob-counter { color: var(--steel); }

/* Inputs — Steel default border, Amber focus.
   v1.28.49 — switched from  (shorthand) to
    so the .ob-select chevron shorthand
   defined in the main stylesheet (background-repeat: no-repeat etc)
   survives the cascade. The shorthand was resetting background-repeat
   to its initial  value, tiling the SVG arrow across the
   entire dropdown. */
.ob-input {
  border: 1.5px solid var(--steel);
  background-color: #ffffff;
  color: var(--oxford);
}
.ob-input::placeholder { color: rgba(73,91,125,.55); }
.ob-input:focus {
  outline: none;
  border-color: var(--amber);
  box-shadow: 0 0 0 3px rgba(212,136,42,.18);
}
/* Re-assert no-repeat + size + position so the SVG sits once on the
   right side regardless of cascade interactions. */
.ob-select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='8' viewBox='0 0 14 8'%3E%3Cpath fill='%23495B7D' d='M1 1l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
  background-size: 14px 8px;
}

/* Primary CTA on onboarding — Amber filled. Scoped to .ob-container so
   the global .btn-primary teal chain is overridden only here. */
.ob-container .btn-primary {
  background: var(--amber);
  border: 1.5px solid var(--amber);
  color: #ffffff;
  box-shadow: none;
}
.ob-container .btn-primary:hover {
  background: #B8741F;
  border-color: #B8741F;
  box-shadow: 0 4px 16px rgba(212,136,42,.35);
}
.ob-container .btn-primary:disabled {
  background: var(--steel);
  border-color: var(--steel);
  color: #ffffff;
  opacity: .4;
  box-shadow: none;
  transform: none;
}

/* Back link — Steel (was secondary text) */
.ob-back { color: var(--steel); }
.ob-back:hover { color: var(--amber); }

/* Birth feedback row — Steel/Amber for ok (was teal) */
.ob-birth-feedback--ok { color: var(--amber); }

/* Attribution chips — Steel default, Amber selected */
.ob-attr-btn {
  border-color: var(--steel);
  color: var(--steel);
  background: #ffffff;
}
.ob-attr-btn:hover { border-color: var(--amber); color: var(--amber); }
.ob-attr-btn.selected {
  background: var(--amber);
  border-color: var(--amber);
  color: #ffffff;
}

/* Life stage cards (single-select, primary choice → Amber selected) */
.ob-lifestage-btn {
  border-color: var(--steel);
  color: var(--oxford);
  background: #ffffff;
}
.ob-lifestage-btn:hover {
  border-color: var(--harbor);
  color: var(--oxford);
}
.ob-lifestage-btn.selected {
  background: var(--moonlight-tint);
  border: 2px solid var(--amber);
  color: var(--oxford);
}

/* Topic interests (multi-select → Frost Blue/Harbor selected per spec) */
.ob-interests-btn {
  border-color: var(--steel);
  color: var(--oxford);
  background: #ffffff;
}
.ob-interests-btn:hover {
  border-color: var(--harbor);
  background: rgba(139,163,197,.10);
}
.ob-interests-btn.selected {
  background: var(--harbor);
  border-color: var(--harbor);
  color: #ffffff;
}
.ob-interests-counter { color: var(--steel); }
/* Legacy ob-topic-card (older selector used in some flows) */
.ob-topic-card { border-color: var(--steel); background: #ffffff; }
.ob-topic-card:hover { border-color: var(--harbor); }
.ob-topic-card.selected {
  border-color: var(--harbor);
  background: rgba(139,163,197,.15);
}
.ob-topic-label { color: var(--oxford); }

/* Terms screen — checkboxes Amber, links Frost Blue → Amber on hover */
.ob-terms-box {
  background: #ffffff;
  border-color: rgba(73,91,125,.25);
}
.ob-terms-row { color: var(--oxford); }
.ob-terms-row input[type="checkbox"] { accent-color: var(--amber); }
.ob-terms-row a { color: var(--harbor); }
.ob-terms-row a:hover { color: var(--amber); }

/* Disclaimer block — keep amber-warning treatment but reconcile heading */
.ob-disclaimer-heading { color: var(--oxford); }
.ob-disclaimer-body { color: var(--oxford); }
.ob-disclaimer-note { color: var(--steel); }

/* Summary tags on Done screen — Frost Blue tint instead of purple */
.ob-summary-tag {
  background: rgba(139,163,197,.18);
  color: var(--harbor);
  font-family: var(--font);
}

/* === END v1.28.48 ========================================================= */


/* === v1.28.50 — /pathways/:id BIS v1.3 conversion =========================
   Course list rows on the pathway detail page. Hero gradient stays per the
   v1.28.7 lock (pathway outlineColor is the hero brand signal); this block
   only touches the list rows below the hero.
   ========================================================================= */

/* Course rows on Moonlight Tint surface — Steel divider, Frost Blue done */
.pathway-course-list .pathway-course-row { border-bottom-color: rgba(73,91,125,.18); }
.pathway-course-list .pathway-course-row:hover { background: #ffffff; }
.pathway-course-row.done {
  background: rgba(139,163,197,.15);
}
.pathway-course-row.done:hover {
  background: rgba(139,163,197,.22);
}

/* Course icon — Amber dot uniform across all courses (was per-track legacy) */
.pathway-course-list .pathway-course-icon {
  background: var(--pw-color, var(--amber));
  box-shadow: 0 0 0 3px rgba(250,248,242,0.95), 0 2px 6px -2px rgba(2,18,47,.18);
}

/* Course code small caps — Steel small letterspacing */
.pathway-course-id {
  color: var(--steel);
  font-family: var(--font);
  letter-spacing: .06em;
}

/* Course title — Oxford. Done state stays Oxford (Frost Blue row tint
   already signals completion). */
.pathway-course-title {
  color: var(--oxford);
  font-family: var(--font);
}
.pathway-course-row.done .pathway-course-title { color: var(--oxford); }
.pathway-course-row.done .pathway-course-status { color: var(--harbor); }

.pathway-course-desc {
  color: var(--steel);
  font-family: var(--font);
}

/* Status pills — Frost Blue COMPLETED, Steel COMING SOON */
.pathway-course-tag {
  font-family: var(--font);
  font-weight: 600;
  letter-spacing: .06em;
}
.pathway-course-tag.completed {
  background: var(--harbor);
  color: #ffffff;
}
.pathway-course-tag.coming-soon {
  background: transparent;
  color: var(--steel);
  border: 1px solid var(--steel);
}

/* Status arrow — Steel default, Amber on row hover */
.pathway-course-status { color: var(--steel); }
.pathway-course-list .pathway-course-row:hover:not(.locked) .pathway-course-status { color: var(--amber); }

/* === END v1.28.50 ========================================================= */


/* === v1.28.51 — Pathway Certification flow BIS v1.3 conversion ============
   Three pages share the .pathway-certification-* class family. Hero
   gradient + outlineColor stay per the v1.28.7 lock. This block targets
   the intro card, take-page choices/submit/loading, scroll progress bar
   (new), and results page tints + buttons.
   ========================================================================= */

/* Intro page — Begin Certification + Try Again primary buttons.
   #17: scoped Amber override removed — redundant with the now-Amber base. */
.pathway-certification-intro-card {
  background: #ffffff;
  border: 1.5px solid var(--steel);
}

/* Score line — Frost Blue passed, Amber failed (was teal/red) */
.pathway-certification-intro-score-line.passed { color: var(--harbor); }
.pathway-certification-intro-score-line.failed { color: var(--amber); }

/* Take page — Sticky scroll progress bar (NEW v1.28.51) */
.pathway-cert-scroll-progress {
  position: sticky;
  top: 80px;
  z-index: 30;
  background: #ffffff;
  border: 1.5px solid var(--amber);
  border-radius: 100px;
  padding: 10px 18px;
  margin: 0 0 20px;
  box-shadow: 0 4px 14px rgba(2,18,47,.08);
}
.pathway-cert-scroll-progress-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: var(--font);
  font-size: .8rem;
  font-weight: 600;
  color: var(--steel);
  margin-bottom: 8px;
  letter-spacing: .02em;
}
.pathway-cert-scroll-progress-answered { color: var(--oxford); }
.pathway-cert-scroll-progress-current { color: var(--steel); }
.pathway-cert-scroll-progress-track {
  height: 4px;
  background: rgba(139,163,197,.3);
  border-radius: 100px;
  overflow: hidden;
}
.pathway-cert-scroll-progress-fill {
  height: 100%;
  background: var(--amber);
  border-radius: 100px;
  transition: width .35s cubic-bezier(.2,.8,.2,1);
}
@media (max-width: 767px) {
  .pathway-cert-scroll-progress { top: 68px; padding: 9px 14px; }
  .pathway-cert-scroll-progress-row { font-size: .74rem; }
}

/* Take page — choices: white default, Frost Blue/Harbor selected */
.pathway-certification-choice {
  background: #ffffff;
  border-color: var(--steel);
  color: var(--oxford);
  font-family: var(--font);
}
.pathway-certification-choice:hover { border-color: var(--harbor); }
.pathway-certification-choice .pathway-certification-choice-check {
  color: var(--harbor);
}
.pathway-certification-choice.selected {
  background: #CDD8E8;
  border-color: var(--harbor);
  color: var(--harbor);
}

/* Take page — Submit bar / button */
.pathway-certification-submit-bar {
  background: var(--moonlight-tint);
  border-top-color: var(--steel);
}
.pathway-certification-submit-btn {
  background: var(--amber);
  border: 1.5px solid var(--amber);
  color: #ffffff;
  font-family: var(--font);
  font-weight: 600;
  box-shadow: none;
}
.pathway-certification-submit-btn:hover {
  background: #B8741F;
  border-color: #B8741F;
  box-shadow: 0 4px 16px rgba(212,136,42,.35);
}
.pathway-certification-submit-btn.is-disabled,
.pathway-certification-submit-btn:disabled {
  background: #CDD8E8;
  border-color: #CDD8E8;
  color: var(--steel);
  cursor: not-allowed;
  box-shadow: none;
  transform: none;
}
.pathway-certification-submit-btn.is-disabled:hover,
.pathway-certification-submit-btn:disabled:hover {
  background: #CDD8E8;
  border-color: #CDD8E8;
  box-shadow: none;
}

/* Take page — Loading screen (Amber growing line; reuses .lesson-loading-*
   tokens from the v1.28.43 lesson loading sweep, so headline is already
   Oxford and the fill is already Amber via that block). Hide the legacy
   spinner if it ever ends up rendered anywhere via this class. */
.pathway-certification-take-loading .spinner { display: none; }
.pathway-certification-take-loading.lesson-loading-screen {
  padding: 60px 24px;
}
.pathway-certification-take-loading .pathway-certification-take-loading-msg.lesson-loading-screen-headline {
  color: var(--oxford);
  font-family: var(--font-display);
  font-weight: 700;
}
.pathway-certification-take-loading .pathway-certification-take-loading-sub.lesson-loading-screen-body {
  color: var(--steel);
}

/* Results page — pass tints Frost Blue/Amber (was teal --success) */
.pathway-certification-results-icon.pass {
  background: var(--amber);
  color: #ffffff;
}
.pathway-certification-results-headline-card.pass .pathway-certification-results-title {
  color: var(--oxford);
}
.pathway-certification-results-headline-card.pass {
  background: #ffffff;
  border: 2px solid var(--amber);
}
.pathway-certification-results-note-positive {
  color: var(--harbor);
  font-weight: 600;
}
.pathway-certification-review-item.correct {
  border-left-color: var(--harbor);
}
.pathway-certification-review-item.incorrect {
  border-left-color: #DC2626;
}
.pathway-certification-review-choice.is-correct {
  background: rgba(139,163,197,.18);
  border-color: var(--harbor);
  color: var(--harbor);
}
.pathway-certification-review-choice.is-correct .pathway-certification-review-choice-tag {
  background: var(--harbor);
  color: #ffffff;
}
.pathway-certification-review-row.is-correct .pathway-certification-review-row-label {
  color: var(--harbor);
}
.pathway-certification-review-row.is-correct .pathway-certification-review-row-value {
  color: var(--oxford);
}

/* === END v1.28.51 ========================================================= */

/* === v1.28.52 — Two modal CTAs missed in v1.28.51 sweep =================== */

/* Pass celebration overlay (showCertificateCelebration) — "View certificate" */
.cert-celebration-actions .btn-primary {
  background: var(--amber);
  border: 1.5px solid var(--amber);
  color: #ffffff;
  box-shadow: none;
}
.cert-celebration-actions .btn-primary:hover {
  background: #B8741F;
  border-color: #B8741F;
  box-shadow: 0 4px 16px rgba(212,136,42,.35);
}

/* Certificate-name entry modal (showNameModal) — "View Certificate" CTA */
#name-modal .btn-primary {
  background: var(--amber);
  border: 1.5px solid var(--amber);
  color: #ffffff;
  box-shadow: none;
}
#name-modal .btn-primary:hover {
  background: #B8741F;
  border-color: #B8741F;
  box-shadow: 0 4px 16px rgba(212,136,42,.35);
}

/* === END v1.28.52 ========================================================= */

/* === v1.28.54 — Multi-step certification loading staggered fill ===========
   The certification render emits three .lesson-loading-step rows, all with
   .is-active. These overrides stagger the animation-delay on rows 2 and 3
   so the user sees one Amber line fill (~3.5s), then the next, then the
   third — phased progress perception across the 20-30s Sonnet 4 window.

   The lesson loading screen (Phase 1 v1.15.0) uses event-driven progression
   via JS, so its three lines don't need delays; this scope keeps the
   stagger from leaking onto that screen.
   ========================================================================= */
.pathway-certification-take-loading .lesson-loading-step:nth-child(2) .lesson-loading-step-fill.is-active {
  animation-delay: 3.5s, 7s;
}
.pathway-certification-take-loading .lesson-loading-step:nth-child(3) .lesson-loading-step-fill.is-active {
  animation-delay: 7s, 10.5s;
}
@media (prefers-reduced-motion: reduce) {
  .pathway-certification-take-loading .lesson-loading-step .lesson-loading-step-fill.is-active {
    animation: none;
    width: 50%;
  }
}
/* === END v1.28.54 ========================================================= */

/* === v1.28.55 — Cert results review cards: fail-state + explanation =======
   v1.28.51 converted label colors on the review rows but the bg/border on
   .is-correct still inherited --success-light / --success teal from the
   base CSS. This block finishes the conversion: fail-state "You selected"
   pill (red tint, semantic), "Correct answer" pill (Frost Blue), and the
   explanation box (Moonlight Tint, Steel text).
   ========================================================================= */

/* Compact review row — "Correct answer" Frost Blue (was --success teal) */
.pathway-certification-review-row.is-correct {
  background: rgba(139,163,197,.18);
  border-color: var(--harbor);
}

/* Compact review row — "You selected" red tint (was neutral grey) */
.pathway-certification-review-row.is-selected {
  background: rgba(220,38,38,.08);
  border-color: #DC2626;
}
.pathway-certification-review-row.is-selected .pathway-certification-review-row-label {
  color: #B91C1C;
}
.pathway-certification-review-row.is-selected .pathway-certification-review-row-value {
  color: var(--oxford);
}

/* Pass-state choice list — "You selected" non-correct stays neutral, just
   reconcile to BIS tokens. */
.pathway-certification-review-choice.is-selected:not(.is-correct) {
  background: rgba(73,91,125,.08);
  border-color: var(--steel);
  color: var(--oxford);
}
.pathway-certification-review-choice.is-selected:not(.is-correct) .pathway-certification-review-choice-tag {
  background: var(--steel);
  color: #ffffff;
}

/* Why this is the answer — Moonlight Tint surface, Steel small caps,
   Steel body. Was --bg neutral grey + --text-muted label. */
.pathway-certification-review-explanation {
  background: var(--moonlight-tint);
  border: 1px solid rgba(73,91,125,.18);
}
.pathway-certification-review-explanation-label {
  color: var(--steel);
  font-family: var(--font);
  font-weight: 500;
  letter-spacing: .06em;
}
.pathway-certification-review-explanation p {
  color: var(--steel);
  font-family: var(--font);
}

/* Review row labels in DM Sans 500 small caps so the type weight matches
   v1.28.43 scenario quiz styling. */
.pathway-certification-review-row-label {
  font-family: var(--font);
  font-weight: 500;
  letter-spacing: .06em;
}

/* === END v1.28.55 ========================================================= */

/* ============================================================================
   v1.28.80 — Mobile signed-in bottom nav to BIS v1.3 Oxford
   ============================================================================
   .bottom-nav was explicitly preserved on legacy --deep-purple per the
   v1.26.0 scope decision (see comment at ~12172). The desktop top nav was
   converted to Oxford in v1.26.0; this block does the same for the mobile
   bottom nav so signed-in mobile users see one continuous brand frame.
   Mirrors .nav-btn-section.active::after (~5997) for the active indicator.
   ============================================================================ */

.bottom-nav {
  background: var(--oxford);
}
.bottom-nav-btn {
  position: relative;
  color: rgba(255, 255, 255, 0.85);
}
.bottom-nav-btn.active::after {
  content: '';
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 0;
  height: 2px;
  background: #FFFFFF;
  border-radius: 2px;
}
/* === END v1.28.80 ========================================================== */

/* ============================================================================
   v1.28.81 — Auth flow pages to BIS v1.3
   ============================================================================
   Covers every render that uses the .signup-page wrapper: renderLogin,
   renderSignup, renderSignupEmailVerify, renderForgotPassword,
   renderResetPassword, renderAuthCallback{Pending,Error,Rejected}.
   Wordmark already converts via the v1.26.0 .wordmark--primary-light rule
   (~11071); .signup-tagline already converts to Warm Amber via v1.27.8
   (~12243).
   ============================================================================ */

/* Page background — Moonlight Tint on the body when an auth page renders.
   :has() avoids needing a body class toggle in app.js. */
body:has(.signup-page) {
  background: var(--moonlight-tint);
}

/* Card surface — keep white, swap to 1.5px Steel border. */
.signup-card {
  border: 1.5px solid var(--steel);
}

/* Heading — Oxford (.display defaults to Vivoso Purple; .signup-headline at
   ~9835 also sets --vivoso-purple, so override that here). */
.signup-page .signup-headline {
  color: var(--oxford);
}

/* Body copy — DM Sans Steel */
.signup-page .signup-intro,
.signup-page .signup-subtext,
.signup-page .signup-field-help,
.signup-page .signup-footer-line,
.signup-page .signup-resend-status {
  font-family: var(--font-body);
  color: var(--steel);
}

/* Field label — DM Sans Oxford */
.signup-page .signup-field-label {
  font-family: var(--font-body);
  color: var(--oxford);
}

/* Form inputs — Steel border, Amber focus + subtle glow */
.signup-page .signup-field input {
  border-color: var(--steel);
  color: var(--oxford);
}
.signup-page .signup-field input:focus {
  border-color: var(--amber);
  box-shadow: 0 0 0 3px rgba(212, 136, 42, 0.18);
}

/* Primary CTA — Amber filled, white DM Sans 600 (scoped to .signup-page so
   global .btn-primary stays unchanged). */
.signup-page .btn-primary {
  background: var(--amber);
  color: #FFFFFF;
  font-family: var(--font-body);
  font-weight: 600;
}
.signup-page .btn-primary:hover {
  background: #A6701A;
  color: #FFFFFF;
}

/* Secondary CTA — Steel ghost, Amber on hover */
.signup-page .btn-secondary {
  background: transparent;
  color: var(--steel);
  border-color: var(--steel);
  font-family: var(--font-body);
  font-weight: 600;
}
/* Inline links — Amber */
.signup-page .signup-subtext a,
.signup-page .signup-footer-line a,
.signup-page .login-forgot-link {
  color: var(--amber);
}
.signup-page .signup-subtext a:hover,
.signup-page .signup-footer-line a:hover,
.signup-page .login-forgot-link:hover {
  color: #A6701A;
}

/* Login divider — Steel rules + Steel text */
.signup-page .login-divider {
  color: var(--steel);
}
.signup-page .login-divider::before,
.signup-page .login-divider::after {
  border-top-color: rgba(73, 91, 125, 0.3);
}

/* Google button — Steel border (Amber on hover); preserve white bg +
   Google's #202124 brand text color so the colored logomark stays legible.
   Specificity: .signup-page .login-google-btn (0,2,0) ties with the inline
   .signup-page .btn-secondary rule above, but later source order wins. */
.signup-page .login-google-btn {
  background: #FFFFFF;
  border-color: var(--steel);
  color: #202124;
}
.signup-page .login-google-btn:hover {
  background: #F8FAFC;
  border-color: var(--amber);
  color: #202124;
}
/* === END v1.28.81 ========================================================== */

/* ============================================================================
   v1.29.1 — Mobile responsive fixes
   ============================================================================
   1) Prevent horizontal viewport scroll. Without this, any wide descendant
      (e.g., the /profile progressPillRowHtml() pill row at narrow viewports)
      pushes body width past the viewport. The visible symptom is the
      app-header and footer chrome appearing to shrink and shift left while
      page content bleeds right (May 11 mobile audit: /schools, /organizations,
      /profile on iOS Safari).
      overflow-x: clip (not hidden) is used deliberately — it clips without
      establishing a new scroll/formatting context, so the .app-header
      position: sticky behavior is preserved.
   2) /profile pill row wraps on narrow viewports. The /courses toolbar
      already lets .courses-page-filters scroll horizontally, but the
      .profile-progress-section is a centered column with no scroll
      affordance, so the inline-flex pill row's intrinsic width overflowed
      on mobile. Wrap + row-gap keeps all four stats visible.
   ============================================================================ */
html, body {
  overflow-x: clip;
}

@media (max-width: 600px) {
  .profile-progress-section .progress-pill-row {
    flex-wrap: wrap;
    justify-content: center;
    max-width: 100%;
    row-gap: 6px;
  }
}
/* === END v1.29.1 ========================================================== */

/* ============================================================================
   v1.29.2 — /schools and /organizations hero card mobile overflow fix
   ============================================================================
   v1.29.1's html/body overflow-x: clip stopped page-level horizontal scroll
   but masked an underlying issue: at narrow viewports the hero card's
   headline, body copy, and inline-block CTA were sized wider than the
   card's content area, getting clipped at the viewport edge.
   Verified on iPhone Safari at ~390px (May 12).

   The existing ≤600px media query reduces hero padding to 40px 24px but the
   headline clamp(1.8rem, 4vw, 2.6rem) still resolves to 1.8rem (=28.8px) on
   a 390px viewport, and the inline-block CTA "Request Organization Pricing"
   doesn't reliably shrink-to-fit on iOS Safari. Below 480px we tighten
   padding further, scale the headline down, force overflow-wrap on copy,
   and make the CTA a width-capped block so it never overhangs.

   Desktop and ≥600px tablet appearance is unchanged.
   ============================================================================ */
@media (max-width: 480px) {
  .schools-hero,
  .orgs-hero {
    padding: 32px 18px;
    border-radius: 20px;
    margin: 20px 0 0;
  }
  .schools-hero h1,
  .orgs-hero h1 {
    font-size: clamp(1.4rem, 5.6vw, 1.9rem);
    line-height: 1.2;
    letter-spacing: -0.4px;
    overflow-wrap: break-word;
    hyphens: auto;
  }
  .schools-hero p,
  .orgs-hero p {
    font-size: 1rem;
    line-height: 1.55;
    overflow-wrap: break-word;
  }
  .schools-hero-cta,
  .orgs-hero-cta {
    display: block;
    width: 100%;
    max-width: 280px;
    margin: 0 auto;
    padding: 14px 18px;
    box-sizing: border-box;
    font-size: 1rem;
    text-align: center;
  }
}
/* === END v1.29.2 ========================================================== */

/* ============================================================================
   v1.29.3 — /schools and /organizations hero card overflow — actual root cause
   ============================================================================
   v1.29.2 targeted the hero's internal elements (h1, p, CTA) but the bug
   persisted. Diagnostic revealed the hero itself is fine — it's being
   stretched by an over-wide parent.

   Root cause: .schools-columns, .schools-steps, .schools-benefits,
   .orgs-columns, .orgs-steps, .orgs-benefits all use
   `grid-template-columns: repeat(auto-fit, minmax(210-280px, 1fr))`. The
   210-280px minimum-track size propagates as min-content up through the
   surrounding .schools-section-dark/-purple/-alt wrappers (each with their
   own padding) and into .schools-page / .orgs-page. With min-width: auto on
   flex items (the default in #app's flex column), the page can't shrink
   below its intrinsic min-content, so on narrow viewports it overflows
   #app horizontally. The hero, a block child of the page, stretches with
   it and gets clipped at the viewport edge by v1.29.1's overflow-x: clip.

   Fix: collapse all six grids to a single 1fr column at <=600px. Desktop
   (>600px) keeps the existing responsive multi-column behavior intact.
   ============================================================================ */
@media (max-width: 600px) {
  .schools-columns,
  .schools-steps,
  .schools-benefits,
  .orgs-columns,
  .orgs-steps,
  .orgs-benefits {
    grid-template-columns: 1fr;
  }
}
/* === END v1.29.3 ========================================================== */

/* ============================================================================
   Public no-account SAMPLE surface (/sample, /sample/:key).
   Reuses the existing lesson-player styles; only the landing page, the sample
   personalization label, the WA money-note, and the end-of-sample CTA are new.
   ============================================================================ */
.sample-landing {
  max-width: 760px;
  margin: 0 auto;
  padding: 40px 20px 64px;
}
.sample-landing-head { text-align: center; margin-bottom: 32px; }
.sample-landing-title {
  font-family: var(--font-display, var(--font));
  color: var(--oxford, var(--text));
  font-size: clamp(1.7rem, 4vw, 2.4rem);
  line-height: 1.15;
  margin: 0 0 12px;
}
.sample-landing-sub {
  color: var(--text-secondary);
  font-size: 1.02rem;
  line-height: 1.55;
  max-width: 620px;
  margin: 0 auto;
}
.sample-card-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-top: 8px;
}
@media (max-width: 600px) { .sample-card-grid { grid-template-columns: 1fr; } }
.sample-card {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  text-align: left;
  padding: 20px;
  background: var(--surface, #fff);
  border: 1px solid var(--border);
  border-radius: var(--radius, 14px);
  cursor: pointer;
  transition: border-color .15s ease, box-shadow .15s ease, transform .15s ease;
  font: inherit;
  width: 100%;
}
.sample-card:hover {
  border-color: var(--amber, #F59E0B);
  box-shadow: 0 6px 20px rgba(0,0,0,.06);
  transform: translateY(-1px);
}
.sample-card-icon { flex: 0 0 auto; margin-top: 2px; }
.sample-card-body { display: flex; flex-direction: column; gap: 4px; }
.sample-card-title {
  font-weight: 700;
  color: var(--oxford, var(--text));
  font-size: 1.05rem;
}
.sample-card-desc {
  color: var(--text-secondary);
  font-size: .9rem;
  line-height: 1.45;
}
.sample-card-cta {
  color: var(--amber, #C77D0A);
  font-weight: 600;
  font-size: .9rem;
  margin-top: 6px;
}
.sample-landing-foot { text-align: center; margin-top: 40px; }
.sample-landing-foot-line { color: var(--text-secondary); margin: 0 0 12px; }
.sample-boot-loading {
  text-align: center;
  color: var(--text-secondary);
  padding: 80px 20px;
}

/* Frozen sample personalization label + WA money-note in the reused player. */
.lesson-sample-label { font-style: normal; }
.lesson-sample-state-note {
  margin: 6px 0 0;
  color: var(--text-muted, var(--text-secondary));
  font-size: .85rem;
  font-style: italic;
}

/* End-of-sample signup CTA, injected after the scenario is answered. */
.sample-end-cta {
  margin: 28px 0 8px;
  padding: 24px;
  text-align: center;
  background: var(--primary-light, var(--moonlight-tint, #F6F5FF));
  border: 1px solid var(--border);
  border-radius: var(--radius, 14px);
}
.sample-end-cta-title {
  font-family: var(--font-display, var(--font));
  color: var(--oxford, var(--text));
  font-size: 1.2rem;
  margin: 0 0 8px;
}
.sample-end-cta-body {
  color: var(--text-secondary);
  font-size: .95rem;
  line-height: 1.5;
  max-width: 460px;
  margin: 0 auto 16px;
}
.sample-cta-btn { text-decoration: none; }

/* "Try A Course" → "See a real lesson" card (hero pricing grid + /pricing). */
.sample-price-card { text-align: left; }
.sample-price-headline {
  font-family: var(--font-display, var(--font));
  color: var(--oxford, var(--text));
  font-weight: 700;
  font-size: 1.15rem;
  margin: 6px 0 8px;
}
.sample-price-body {
  color: var(--text-secondary);
  font-size: .9rem;
  line-height: 1.45;
  margin: 0 0 10px;
}
.sample-price-links {
  list-style: none;
  padding: 0;
  margin: 0 0 10px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.sample-price-links a {
  color: var(--amber, #C77D0A);
  font-weight: 600;
  font-size: .92rem;
  text-decoration: none;
  cursor: pointer;
}
.sample-price-links a:hover { text-decoration: underline; }
.sample-price-foot {
  color: var(--text-muted, var(--text-secondary));
  font-size: .82rem;
  margin: 0;
}

/* #122 Bookmarks */
.course-footer { display: flex; justify-content: flex-end; margin-top: 8px; }
.bookmark-btn {
  background: transparent;
  border: none;
  padding: 4px;
  cursor: pointer;
  color: var(--steel, #495B7D);
  opacity: 0.55;
  line-height: 0;
  border-radius: 6px;
  transition: opacity 0.15s ease, color 0.15s ease, transform 0.1s ease;
}
.bookmark-btn:hover { opacity: 1; background: rgba(212, 136, 42, 0.10); }
.bookmark-btn:active { transform: scale(0.9); }
.bookmark-btn svg { fill: none; stroke: currentColor; stroke-width: 2; }
.bookmark-btn.is-bookmarked { opacity: 1; color: var(--amber, #D4882A); }
.bookmark-btn.is-bookmarked svg { fill: var(--amber, #D4882A); stroke: var(--amber, #D4882A); }
.bookmark-filter-btn {
  background: transparent;
  border: 1.5px solid var(--steel, #495B7D);
  color: var(--steel, #495B7D);
  border-radius: 999px;
  padding: 6px 14px;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}
.bookmark-filter-btn:hover { border-color: var(--amber, #D4882A); color: var(--amber, #D4882A); }
.bookmark-filter-btn.active { background: var(--amber, #D4882A); border-color: var(--amber, #D4882A); color: #fff; }

/* === v1.39.50 — Scenario post-answer advance control ======================
   The correct-answer confirmation and transition were scrolled past on a
   650/1400ms timer. The next section now renders on that timer but the
   viewport holds until the reader taps this. Amber explicit, matching
   .lesson-section-unlock-btn / .gift-buy-btn / .social-cta. */
.scenario-advance {
  margin-top: 14px;
  display: flex;
  justify-content: flex-start;
}
.scenario-advance-btn {
  font-family: var(--font);
  font-size: .95rem;
  font-weight: 700;
  color: #ffffff;
  background: var(--amber);
  border: 1.5px solid var(--amber);
  border-radius: var(--radius-sm);
  padding: 12px 24px;
  min-height: 44px;
  cursor: pointer;
  transition: background .15s, border-color .15s, transform .12s, box-shadow .15s;
}
.scenario-advance-btn:hover {
  background: #B8741F;
  border-color: #B8741F;
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(212, 136, 42, .35);
}
.scenario-advance-btn:focus-visible {
  outline: 2px solid var(--amber);
  outline-offset: 3px;
}
@media (max-width: 600px) {
  .scenario-advance { justify-content: stretch; }
  .scenario-advance-btn { width: 100%; min-height: 48px; }
}
/* === END v1.39.50 ========================================================= */

/* === v1.39.52 — Spoken scenario cue ======================================
   Narrated by the TTS walker, not read on screen. Deliberately NOT using the
   existing .visually-hidden (style.css:4187): that sets position:absolute and
   collapses the box to 1px, which would send speakBlock's scrollIntoView and
   its .tts-active highlight to a 1px out-of-flow element while this line is
   being spoken. This stays in normal flow with a real box so both land on the
   scenario card. Text is clipped rather than removed. */
.scenario-audio-cue {
  color: transparent;
  overflow: hidden;
  max-height: 1.4em;
  margin: 0;
  padding: 0;
  font-size: .95rem;
  line-height: 1.4;
  user-select: none;
  pointer-events: none;
}
.scenario-question.scenario-correct .scenario-audio-cue { visibility: hidden; }
/* === END v1.39.52 ========================================================= */

/* ── LAUNCH25 promo banner (landing) — added 2026-08-02, self-retires after Sep 3 via renderLanding date guard ── */
.lp-promo-banner {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 16px;
  padding: 12px 20px;
  background: var(--amber);
  color: var(--oxford);
  text-align: center;
  font-size: 0.95rem;
  line-height: 1.4;
}
.lp-promo-text {
  color: var(--oxford);
}
.lp-promo-text strong {
  font-weight: 700;
}
.lp-promo-cta {
  flex: 0 0 auto;
  padding: 8px 18px;
  border: 2px solid var(--oxford);
  border-radius: 8px;
  background: var(--oxford);
  color: var(--moonlight);
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.15s ease, color 0.15s ease;
}
.lp-promo-cta:hover {
  background: transparent;
  color: var(--oxford);
}
@media (max-width: 560px) {
  .lp-promo-banner { flex-direction: column; gap: 10px; padding: 12px 16px; }
}
