/* ═══════════════════════════════════════════════════════════════════════════
   FIGHTING FORWARD — /learn page styles
   Reading-first layout with the visual polish of the landing page.
   ═══════════════════════════════════════════════════════════════════════════ */

/* ── Tokens (shared with landing page) ─────────────────────────────────── */
:root {
  --bg:          #080D16;
  --bg-subtle:   #0d1520;
  --gold:        #C9A84C;
  --gold-bright: #E4C76B;
  --text:        #F2EEE6;
  --text-muted:  #8A857B;
  --text-dim:    #4a4640;
  --serif:       'Fraunces', Georgia, 'Times New Roman', serif;
  --sans:        -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  --ease:        cubic-bezier(0.25, 0.46, 0.45, 0.94);
  --content-max: 680px;
}

/* ── Reset ──────────────────────────────────────────────────────────────── */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.7;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; }

/* ── Scroll Progress Bar ────────────────────────────────────────────────── */
#progress-bar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--gold);
  transform-origin: left;
  transform: scaleX(0);
  z-index: 1000;
  pointer-events: none;
}

/* ── Header ─────────────────────────────────────────────────────────────── */
#learn-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 0 20px;
  transition: background 0.4s var(--ease), box-shadow 0.4s var(--ease);
}
#learn-header.scrolled {
  background: rgba(8, 13, 22, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 1px 0 rgba(201, 168, 76, 0.08);
}
.header-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 56px;
}
.wordmark {
  font-family: var(--serif);
  font-size: 12px;
  font-weight: 400;
  letter-spacing: 4px;
  color: var(--text);
  text-decoration: none;
  text-transform: uppercase;
}
.wordmark--small {
  font-size: 11px;
  letter-spacing: 3px;
  color: var(--text-muted);
}
.header-nav {
  display: flex;
  align-items: center;
  gap: 24px;
}
.nav-link {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--text-muted);
  transition: color 0.3s var(--ease);
}
.nav-link:hover { color: var(--text); }
.nav-link--active { color: var(--gold); }
.nav-link--wide { display: none; }
@media (min-width: 600px) { .nav-link--wide { display: inline; } }
.header-cta {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--gold);
  padding: 8px 16px;
  border: 1px solid rgba(201, 168, 76, 0.3);
  border-radius: 3px;
  transition: all 0.3s var(--ease);
}
.header-cta:hover {
  background: rgba(201, 168, 76, 0.1);
  border-color: var(--gold);
}

/* ── Buttons ────────────────────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--sans);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  text-decoration: none;
  padding: 16px 32px;
  border-radius: 3px;
  transition: all 0.3s var(--ease);
  cursor: pointer;
  border: none;
}
.btn--gold {
  background: linear-gradient(135deg, var(--gold), #8a6820);
  color: var(--bg);
  box-shadow: 0 4px 24px rgba(201, 168, 76, 0.2);
}
.btn--gold:hover {
  background: linear-gradient(135deg, var(--gold-bright), var(--gold));
  box-shadow: 0 6px 32px rgba(201, 168, 76, 0.3);
  transform: translateY(-1px);
}
.btn--outline {
  background: transparent;
  color: var(--gold);
  border: 1px solid rgba(201, 168, 76, 0.3);
  padding: 14px 28px;
}
.btn--outline:hover {
  background: rgba(201, 168, 76, 0.08);
  border-color: var(--gold);
}

/* ── Section Labels (matching landing page) ─────────────────────────────── */
.section-label {
  display: block;
  font-family: var(--sans);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 16px;
}

/* ── TOC — Desktop sidebar ──────────────────────────────────────────────── */
.toc {
  display: none;
}
@media (min-width: 1100px) {
  .toc {
    display: block;
    position: fixed;
    top: 50%;
    left: max(20px, calc((100vw - var(--content-max)) / 2 - 220px));
    transform: translateY(-50%);
    z-index: 50;
    opacity: 0;
    transition: opacity 0.4s var(--ease);
  }
  .toc.visible { opacity: 1; }
  .toc__list {
    list-style: none;
  }
  .toc__link {
    display: block;
    font-size: 11px;
    letter-spacing: 1px;
    text-decoration: none;
    color: var(--text-dim);
    padding: 6px 0;
    border-left: 2px solid transparent;
    padding-left: 12px;
    transition: all 0.3s var(--ease);
  }
  .toc__link:hover { color: var(--text-muted); }
  .toc__link.active {
    color: var(--gold);
    border-left-color: var(--gold);
  }
}

/* ── TOC — Mobile toggle ────────────────────────────────────────────────── */
.toc-toggle {
  display: flex;
  align-items: center;
  gap: 6px;
  position: fixed;
  bottom: 20px;
  right: 20px;
  z-index: 200;
  background: rgba(8, 13, 22, 0.95);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(201, 168, 76, 0.2);
  color: var(--gold);
  padding: 10px 16px;
  border-radius: 24px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  font-family: var(--sans);
  cursor: pointer;
  transition: all 0.3s var(--ease);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
}
.toc-toggle:hover {
  border-color: var(--gold);
  background: rgba(8, 13, 22, 1);
}
@media (min-width: 1100px) {
  .toc-toggle { display: none; }
}
/* Mobile TOC panel */
@media (max-width: 1099px) {
  .toc {
    position: fixed;
    bottom: 64px;
    right: 20px;
    z-index: 199;
    background: rgba(8, 13, 22, 0.98);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(201, 168, 76, 0.15);
    border-radius: 12px;
    padding: 16px 20px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
    transform: translateY(10px);
    opacity: 0;
    pointer-events: none;
    transition: all 0.25s var(--ease);
  }
  .toc.open {
    display: block;
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }
  .toc__list { list-style: none; }
  .toc__link {
    display: block;
    font-size: 13px;
    text-decoration: none;
    color: var(--text-muted);
    padding: 8px 0;
    transition: color 0.2s;
  }
  .toc__link.active { color: var(--gold); }
}

/* ── Main content ───────────────────────────────────────────────────────── */
.learn-main {
  max-width: var(--content-max);
  margin: 0 auto;
  padding: 0 24px;
  padding-top: 100px;
  padding-bottom: 60px;
}

/* ── Intro — with atmospheric glow ──────────────────────────────────────── */
.learn-intro {
  position: relative;
  margin-bottom: 64px;
  padding-bottom: 48px;
  border-bottom: 1px solid rgba(201, 168, 76, 0.1);
}
.learn-intro__glow {
  position: absolute;
  top: -60px;
  left: 50%;
  transform: translateX(-50%);
  width: 500px;
  height: 300px;
  background: radial-gradient(ellipse 80% 60% at 50% 40%, rgba(201, 168, 76, 0.05) 0%, transparent 70%);
  pointer-events: none;
}
.learn-intro h1 {
  position: relative;
  font-family: var(--serif);
  font-size: clamp(28px, 6vw, 44px);
  font-weight: 300;
  line-height: 1.2;
  letter-spacing: -0.5px;
  color: var(--text);
  margin-bottom: 20px;
}
.learn-intro__sub {
  position: relative;
  font-size: 17px;
  color: var(--text-muted);
  line-height: 1.7;
  max-width: 560px;
}

/* ── Sections ───────────────────────────────────────────────────────────── */
.learn-section {
  margin-bottom: 0;
  padding: 48px 0;
  border-bottom: none;
  position: relative;
}
/* Gradient divider between sections */
.learn-section::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(to right, transparent, rgba(201, 168, 76, 0.15) 20%, rgba(201, 168, 76, 0.15) 80%, transparent);
}
.learn-section:last-child::after {
  display: none;
}
/* Alternating background */
.learn-section--alt {
  background: linear-gradient(to bottom, var(--bg-subtle), rgba(13, 21, 32, 0.4));
  margin-left: -24px;
  margin-right: -24px;
  padding-left: 24px;
  padding-right: 24px;
  border-radius: 0;
}
.learn-section h2 {
  font-family: var(--serif);
  font-size: clamp(22px, 4vw, 32px);
  font-weight: 300;
  letter-spacing: -0.3px;
  color: var(--text);
  margin-bottom: 20px;
}
.learn-section p {
  color: var(--text-muted);
  margin-bottom: 16px;
  line-height: 1.75;
}
.learn-section p:last-child {
  margin-bottom: 0;
}
.learn-section strong {
  color: var(--text);
  font-weight: 600;
}
.learn-section em {
  font-style: italic;
  color: var(--gold);
}

/* ── Stat highlight cards ───────────────────────────────────────────────── */
.stat-highlight-group {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  margin: 28px 0;
}
@media (min-width: 480px) {
  .stat-highlight-group {
    grid-template-columns: 1fr 1fr 1fr;
  }
}
.stat-highlight {
  background: rgba(201, 168, 76, 0.04);
  border: 1px solid rgba(201, 168, 76, 0.1);
  border-radius: 8px;
  padding: 20px;
  text-align: center;
  transition: border-color 0.3s var(--ease);
}
.stat-highlight:hover {
  border-color: rgba(201, 168, 76, 0.25);
}
.stat-highlight__number {
  display: block;
  font-family: var(--serif);
  font-size: clamp(22px, 4vw, 28px);
  font-weight: 300;
  color: var(--gold-bright);
  margin-bottom: 6px;
}
.stat-highlight__label {
  display: block;
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.5;
}

/* ── Stat contrast (survival rates) ─────────────────────────────────────── */
.stat-contrast {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
  margin: 32px 0;
  padding: 32px 24px;
  background: rgba(201, 168, 76, 0.03);
  border: 1px solid rgba(201, 168, 76, 0.08);
  border-radius: 12px;
}
.stat-contrast__item {
  text-align: center;
  flex: 1;
}
.stat-contrast__number {
  display: block;
  font-family: var(--serif);
  font-size: clamp(32px, 6vw, 48px);
  font-weight: 300;
  line-height: 1;
  margin-bottom: 8px;
}
.stat-contrast__item--good .stat-contrast__number {
  color: var(--gold-bright);
}
.stat-contrast__item--urgent .stat-contrast__number {
  color: var(--text-muted);
}
.stat-contrast__label {
  display: block;
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.4;
}
.stat-contrast__divider {
  width: 1px;
  height: 60px;
  background: rgba(201, 168, 76, 0.2);
  flex-shrink: 0;
}

/* ── Check list ─────────────────────────────────────────────────────────── */
.check-list {
  list-style: none;
  margin: 20px 0;
}
.check-list li {
  color: var(--text-muted);
  padding: 10px 0 10px 28px;
  position: relative;
  line-height: 1.7;
}
.check-list li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 18px;
  width: 12px;
  height: 12px;
  border: 1.5px solid var(--gold);
  border-radius: 2px;
}

/* ── Callout ────────────────────────────────────────────────────────────── */
.callout {
  margin-top: 24px;
  padding: 20px 24px;
  background: rgba(201, 168, 76, 0.06);
  border-left: 3px solid var(--gold);
  border-radius: 0 6px 6px 0;
  color: var(--text);
  font-weight: 500;
}

/* ═══ SAVE CARD — the self-exam centerpiece ═══════════════════════════════ */
.save-card {
  background: var(--bg-subtle);
  border: 1.5px solid rgba(201, 168, 76, 0.25);
  border-radius: 12px;
  overflow: hidden;
  margin: 8px 0 40px;
  box-shadow:
    0 0 40px rgba(201, 168, 76, 0.06),
    0 0 80px rgba(201, 168, 76, 0.03),
    0 8px 32px rgba(0, 0, 0, 0.3);
}
.save-card__header {
  padding: 28px 28px 0;
}
.save-card__badge {
  display: inline-block;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: var(--gold);
  background: rgba(201, 168, 76, 0.08);
  padding: 6px 14px;
  border-radius: 20px;
  margin-bottom: 16px;
}
.save-card__title {
  font-family: var(--serif);
  font-size: clamp(22px, 4vw, 30px);
  font-weight: 300;
  color: var(--text);
  margin-bottom: 0;
}
.save-card__body {
  padding: 24px 28px;
}
.save-card__step {
  margin-bottom: 24px;
  padding-bottom: 20px;
  border-bottom: 1px solid rgba(138, 133, 123, 0.08);
}
.save-card__step:last-child {
  margin-bottom: 0;
  padding-bottom: 0;
  border-bottom: none;
}
.save-card__step h3 {
  font-family: var(--serif);
  font-size: 16px;
  font-weight: 400;
  color: var(--gold);
  margin-bottom: 6px;
  letter-spacing: 0.5px;
}
.save-card__step p {
  color: var(--text-muted);
  font-size: 16px;
  line-height: 1.7;
  margin: 0;
}
.save-card__step strong {
  color: var(--text);
}
.save-card__footer {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 16px 28px;
  background: rgba(201, 168, 76, 0.04);
  border-top: 1px solid rgba(201, 168, 76, 0.1);
  color: var(--gold);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.5px;
}
.save-card__icon {
  flex-shrink: 0;
}

/* ── Anatomy diagram ────────────────────────────────────────────────────── */
.anatomy-diagram {
  max-width: 340px;
  margin: 32px auto 0;
  opacity: 0.8;
}
.anatomy-diagram svg {
  width: 100%;
  height: auto;
}

/* ── Myth cards (replacing simple bordered text) ─────────────────────────── */
.myth-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  margin-top: 24px;
}
@media (min-width: 540px) {
  .myth-grid {
    grid-template-columns: 1fr 1fr;
  }
}
.myth-card {
  background: rgba(13, 21, 32, 0.6);
  border: 1px solid rgba(201, 168, 76, 0.06);
  border-radius: 8px;
  padding: 24px;
  transition: all 0.3s var(--ease);
}
.myth-card:hover {
  border-color: rgba(201, 168, 76, 0.2);
  background: rgba(13, 21, 32, 0.8);
}
.myth-card__claim {
  font-family: var(--serif);
  font-size: 17px;
  font-style: italic;
  color: var(--text);
  margin-bottom: 8px !important;
  line-height: 1.4;
}
.myth-card__truth {
  color: var(--gold) !important;
  font-weight: 500;
  font-size: 14px;
  line-height: 1.6;
}

/* ── Resource list ──────────────────────────────────────────────────────── */
.resource-list {
  list-style: none;
  margin: 20px 0;
}
.resource-list li {
  padding: 14px 16px;
  border: 1px solid rgba(201, 168, 76, 0.06);
  border-radius: 6px;
  margin-bottom: 8px;
  transition: all 0.3s var(--ease);
}
.resource-list li:hover {
  border-color: rgba(201, 168, 76, 0.15);
  background: rgba(201, 168, 76, 0.03);
}
.resource-list a {
  color: var(--gold);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.2s;
}
.resource-list a:hover { color: var(--gold-bright); }

/* ── Gold link ──────────────────────────────────────────────────────────── */
.gold-link {
  color: var(--gold);
  text-decoration: underline;
  text-decoration-color: rgba(201, 168, 76, 0.3);
  text-underline-offset: 3px;
  font-weight: 500;
  transition: text-decoration-color 0.2s;
}
.gold-link:hover {
  text-decoration-color: var(--gold);
}

/* ── The Ask / Share section ────────────────────────────────────────────── */
.learn-section--ask {
  text-align: center;
  padding-top: 48px;
}
.learn-section--ask h2 {
  font-size: clamp(26px, 5vw, 38px);
}
.learn-section--ask > p {
  font-size: 18px;
  margin-bottom: 28px;
}
.share-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
  margin-bottom: 16px;
}
.share-toast {
  font-size: 13px;
  font-weight: 600;
  color: var(--gold);
  margin-bottom: 24px;
}
.ask-support {
  font-size: 14px;
  color: var(--text-dim);
}

/* ── Footer ─────────────────────────────────────────────────────────────── */
.learn-footer {
  max-width: var(--content-max);
  margin: 0 auto;
  padding: 40px 24px 60px;
  border-top: 1px solid rgba(138, 133, 123, 0.08);
  text-align: center;
}
.footer-links {
  display: flex;
  gap: 24px;
  justify-content: center;
  margin: 16px 0;
}
.footer-links a {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--text-muted);
  transition: color 0.2s;
}
.footer-links a:hover { color: var(--text); }
.disclaimer {
  font-size: 12px;
  color: var(--text-dim);
  line-height: 1.7;
  max-width: 480px;
  margin: 24px auto 0;
  font-style: italic;
}

/* ── Reveal animation (with stagger support) ────────────────────────────── */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}
.reveal.visible {
  opacity: 1;
  transform: none;
}
/* Stagger children inside sections */
.reveal .section-label,
.reveal h2,
.reveal p,
.reveal .stat-highlight-group,
.reveal .stat-contrast,
.reveal .check-list,
.reveal .callout,
.reveal .myth-grid,
.reveal .resource-list,
.reveal .gold-link {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.5s var(--ease), transform 0.5s var(--ease);
}
.reveal.visible .section-label,
.reveal.visible h2,
.reveal.visible p,
.reveal.visible .stat-highlight-group,
.reveal.visible .stat-contrast,
.reveal.visible .check-list,
.reveal.visible .callout,
.reveal.visible .myth-grid,
.reveal.visible .resource-list,
.reveal.visible .gold-link {
  opacity: 1;
  transform: none;
}
/* Stagger delays */
.reveal.visible .section-label { transition-delay: 0s; }
.reveal.visible h2 { transition-delay: 0.08s; }
.reveal.visible p:nth-of-type(1) { transition-delay: 0.16s; }
.reveal.visible .stat-highlight-group,
.reveal.visible .stat-contrast,
.reveal.visible .check-list,
.reveal.visible .myth-grid { transition-delay: 0.2s; }
.reveal.visible p:nth-of-type(2) { transition-delay: 0.24s; }
.reveal.visible .callout { transition-delay: 0.28s; }
.reveal.visible .resource-list { transition-delay: 0.2s; }

/* ── Reduced motion ─────────────────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  .reveal,
  .reveal .section-label,
  .reveal h2,
  .reveal p,
  .reveal .stat-highlight-group,
  .reveal .stat-contrast,
  .reveal .check-list,
  .reveal .callout,
  .reveal .myth-grid,
  .reveal .resource-list,
  .reveal .gold-link {
    opacity: 1;
    transform: none;
    transition: none;
  }
  #progress-bar { display: none; }
}

/* ── Mobile adjustments ─────────────────────────────────────────────────── */
@media (max-width: 480px) {
  .learn-main { padding: 0 18px; padding-top: 88px; }
  .save-card__header { padding: 20px 20px 0; }
  .save-card__body { padding: 20px; }
  .save-card__footer { padding: 14px 20px; }
  .share-controls { flex-direction: column; align-items: center; }
  .btn { width: 100%; justify-content: center; }
  .stat-contrast { flex-direction: column; gap: 16px; padding: 24px 20px; }
  .stat-contrast__divider { width: 60px; height: 1px; }
  .learn-section--alt { margin-left: -18px; margin-right: -18px; padding-left: 18px; padding-right: 18px; }
}
