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

:root {
  /* After the Feed teal palette */
  --sage-dark:   #02484C;   /* nav / hero — darkened teal */
  --sage-mid:    #058287;   /* primary accent — exact deck color */
  --sage-light:  #91D7BE;   /* mint highlight from deck */
  --sage-pale:   #EAF6F5;   /* very light teal tint */
  --sage-rule:   #B9EBDC;   /* light mint border */

  /* Module accents — complementary earthy tones */
  --m1: #058287;   /* teal */
  --m2: #8B4A35;   /* terracotta */
  --m3: #2E6B8A;   /* ocean blue */
  --m4: #7A5C28;   /* amber */
  --m5: #4A4A75;   /* slate purple */

  --ink:   #1A1A1A;
  --mid:   #4A5568;
  --muted: #718096;
  --rule:  #E2E8E4;
  --white: #FFFFFF;
  --bg:    #F8FAF8;

  --display: 'Space Grotesk', system-ui, sans-serif;
  --serif:   'Fraunces', Georgia, serif;
  --sans:    'Inter', system-ui, sans-serif;
}

html { scroll-behavior: smooth; }

body {
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.75;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

/* ── Nav ───────────────────────────────── */
.site-nav {
  position: sticky; top: 0; z-index: 100;
  background: var(--sage-dark);
  padding: 0 28px;
  display: flex; align-items: center; justify-content: space-between;
  min-height: 52px; gap: 16px;
}
.nav-brand {
  font-size: 12px; font-weight: 700; letter-spacing: 0.08em;
  text-transform: uppercase; color: rgba(255,255,255,0.85);
  text-decoration: none; white-space: nowrap; flex-shrink: 0;
}
.nav-links { display: flex; gap: 2px; list-style: none; flex-wrap: wrap; justify-content: flex-end; }
.nav-links a {
  font-size: 12px; font-weight: 500;
  color: rgba(255,255,255,0.6);
  text-decoration: none; padding: 6px 10px; border-radius: 4px;
  transition: background 0.15s, color 0.15s;
}
.nav-links a:hover, .nav-links a.active {
  background: rgba(255,255,255,0.1); color: #fff;
}
@media (max-width: 600px) { .nav-links { display: none; } }

/* ── Hero ──────────────────────────────── */
.hero {
  background: var(--sage-dark);
  padding: 80px 28px 88px;
  position: relative; overflow: hidden;
}
.hero::after {
  content: '';
  position: absolute; bottom: 0; left: 0; right: 0; height: 6px;
  background: linear-gradient(90deg, var(--sage-mid), var(--sage-light));
}
.hero-inner { max-width: 820px; margin: 0 auto; }
.hero-eyebrow {
  font-size: 11px; font-weight: 700; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--sage-light);
  margin-bottom: 24px;
}
.hero h1 {
  font-family: var(--display); font-size: clamp(44px, 7.5vw, 80px);
  font-weight: 700; letter-spacing: -0.03em; line-height: 1.0;
  color: #fff; margin-bottom: 20px;
}
.hero-sub {
  font-size: clamp(16px, 2.2vw, 20px); font-weight: 300;
  color: rgba(255,255,255,0.7); max-width: 56ch;
  line-height: 1.5; margin-bottom: 44px;
}
.hero-meta { font-size: 13px; color: rgba(255,255,255,0.4); }

/* ── Intro ─────────────────────────────── */
.intro-section {
  max-width: 820px; margin: 0 auto;
  padding: 64px 28px 0;
}
.intro-section p {
  font-size: 18px; line-height: 1.85; color: var(--ink);
  margin-bottom: 22px; max-width: 68ch;
}

/* ── Big Stat Bar ──────────────────────── */
.stat-bar {
  background: var(--sage-pale);
  border-top: 3px solid var(--sage-rule);
  border-bottom: 3px solid var(--sage-rule);
  padding: 40px 28px;
  margin: 56px 0 0;
}
.stat-bar-inner {
  max-width: 820px; margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 32px 48px;
}
.stat-item { text-align: center; }
.stat-num {
  font-family: var(--display); font-size: clamp(40px, 6vw, 60px);
  font-weight: 700; letter-spacing: -0.03em; color: var(--sage-mid); line-height: 1;
  margin-bottom: 8px;
}
.stat-label {
  font-size: 13px; color: var(--muted); line-height: 1.4; max-width: 18ch; margin: 0 auto;
}

/* ── Module Grid ───────────────────────── */
.module-grid {
  max-width: 820px; margin: 72px auto 0;
  padding: 0 28px 80px;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 14px;
}
.module-card {
  border: 1.5px solid var(--rule); border-radius: 10px;
  padding: 22px 22px 26px; cursor: pointer;
  text-decoration: none; color: inherit; display: block;
  background: var(--white); position: relative; overflow: hidden;
  transition: box-shadow 0.15s, transform 0.12s;
}
.module-card::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px;
  background: var(--card-accent);
}
.module-card:hover {
  box-shadow: 0 6px 24px rgba(0,0,0,0.09); transform: translateY(-3px);
}
.card-num {
  font-size: 10px; font-weight: 700; letter-spacing: 0.1em;
  text-transform: uppercase; color: var(--card-accent); margin-bottom: 10px;
}
.card-title {
  font-family: var(--display); font-size: 15px; font-weight: 600; letter-spacing: -0.01em;
  line-height: 1.3; color: var(--ink); margin-bottom: 10px;
}
.card-desc { font-size: 13px; line-height: 1.55; color: var(--muted); }
.card-cta {
  display: inline-flex; align-items: center; gap: 5px;
  margin-top: 14px; font-size: 12px; font-weight: 600;
  color: var(--card-accent);
}
.module-card:hover .card-cta svg { transform: translateX(3px); }
.card-cta svg { transition: transform 0.15s; }

/* ── Divider ───────────────────────────── */
.divider { max-width: 820px; margin: 0 auto; padding: 0 28px; }
.divider hr { border: none; border-top: 1px solid var(--rule); }

/* ── Module Sections ───────────────────── */
.module-section {
  padding: 88px 28px 72px;
  scroll-margin-top: 52px;
}
.module-section:nth-child(even) { background: var(--white); }
.module-inner { max-width: 820px; margin: 0 auto; }

.module-eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 11px; font-weight: 700; letter-spacing: 0.1em;
  text-transform: uppercase; color: var(--ma); margin-bottom: 16px;
}
.eyebrow-pip {
  width: 8px; height: 8px; border-radius: 50%; background: var(--ma);
}
.module-section h2 {
  font-family: var(--display);
  font-size: clamp(28px, 4.5vw, 44px); font-weight: 700; letter-spacing: -0.025em;
  color: var(--ink); margin-bottom: 14px; max-width: 22ch; line-height: 1.1;
}
.module-intro {
  font-family: var(--serif); font-size: clamp(17px, 2vw, 20px);
  font-weight: 300; font-style: italic; color: var(--mid);
  max-width: 58ch; line-height: 1.55; margin-bottom: 16px;
}
.module-rule {
  width: 44px; height: 3px; background: var(--ma);
  margin-bottom: 52px; border-radius: 2px;
}

/* ── Prose ─────────────────────────────── */
.prose p {
  font-size: 17px; line-height: 1.8; color: var(--ink);
  max-width: 66ch; margin-bottom: 20px;
}
.prose h3 {
  font-family: var(--display); font-size: 22px; font-weight: 700; letter-spacing: -0.02em;
  color: var(--sage-dark); margin: 56px 0 14px;
}

/* ── Pull Quote ────────────────────────── */
.pull-quote {
  border-left: 4px solid var(--ma);
  padding: 4px 0 4px 28px;
  margin: 44px 0;
}
.pull-quote p {
  font-family: var(--serif); font-size: clamp(19px, 2.5vw, 25px);
  font-weight: 300; font-style: italic; line-height: 1.45;
  color: var(--ink); margin-bottom: 10px; max-width: 52ch;
}
.pull-quote cite {
  font-size: 13px; font-weight: 500; font-style: normal;
  color: var(--muted);
}

/* ── Stat Callouts (inline) ────────────── */
.stat-callouts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 16px; margin: 40px 0;
}
.stat-callout {
  background: var(--sage-pale);
  border: 1px solid var(--sage-rule); border-radius: 8px;
  padding: 20px 18px; text-align: center;
}
.sc-num {
  font-family: var(--display); font-size: 38px; font-weight: 700; letter-spacing: -0.03em;
  color: var(--ma); line-height: 1; margin-bottom: 8px;
}
.sc-label { font-size: 13px; color: var(--mid); line-height: 1.4; }

/* ── Highlight Box ─────────────────────── */
.highlight-box {
  background: var(--sage-pale); border-left: 4px solid var(--ma);
  border-radius: 0 8px 8px 0; padding: 22px 26px; margin: 36px 0;
  max-width: 66ch;
}
.highlight-box-label {
  font-size: 10px; font-weight: 700; letter-spacing: 0.1em;
  text-transform: uppercase; color: var(--ma); margin-bottom: 10px;
}
.highlight-box p {
  font-size: 15.5px; color: var(--ink); margin: 0; line-height: 1.7;
  max-width: 100%;
}

/* ── Tactic Cards Grid ─────────────────── */
.tactic-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 14px; margin: 32px 0;
}
.tactic-card {
  background: var(--white); border: 1.5px solid var(--rule);
  border-radius: 8px; padding: 20px 20px 22px;
}
.tactic-icon {
  width: 34px; height: 34px; border-radius: 8px;
  background: var(--ma); display: flex; align-items: center;
  justify-content: center; margin-bottom: 14px; flex-shrink: 0;
}
.tactic-icon svg { width: 18px; height: 18px; stroke: white; fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.tactic-card h4 {
  font-size: 14px; font-weight: 600; color: var(--ink); margin-bottom: 8px;
}
.tactic-card p {
  font-size: 13.5px; line-height: 1.6; color: var(--mid); margin: 0;
}
.tactic-result {
  display: inline-block; margin-top: 10px;
  font-size: 11px; font-weight: 700; letter-spacing: 0.05em;
  color: var(--ma); background: var(--sage-pale);
  padding: 3px 9px; border-radius: 20px;
}

/* ── Definition List ───────────────────── */
.def-list { margin: 28px 0; }
.def-item {
  display: grid; grid-template-columns: auto 1fr;
  gap: 0 20px; padding: 20px 0; border-bottom: 1px solid var(--rule);
  max-width: 66ch;
}
.def-item:first-child { border-top: 1px solid var(--rule); }
.def-pip {
  width: 10px; height: 10px; border-radius: 50%;
  background: var(--ma); margin-top: 7px; flex-shrink: 0;
}
.def-content h4 {
  font-size: 15px; font-weight: 600; color: var(--ink); margin-bottom: 6px;
}
.def-content p {
  font-size: 15px; color: var(--mid); line-height: 1.65; margin: 0; max-width: 100%;
}

/* ── Question Box ──────────────────────── */
.question-box {
  background: var(--sage-dark); border-radius: 10px;
  padding: 36px 40px; margin: 64px 0 0;
}
.q-label {
  font-size: 10px; font-weight: 700; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--sage-light); margin-bottom: 14px;
}
.question-box p {
  font-family: var(--serif); font-size: clamp(18px, 2.2vw, 22px);
  font-weight: 300; font-style: italic; line-height: 1.5;
  color: rgba(255,255,255,0.9); margin: 0; max-width: 52ch;
}

/* ── Back to top ───────────────────────── */
.back-to-top {
  display: inline-flex; align-items: center; gap: 6px;
  margin-top: 52px; font-size: 13px; font-weight: 500;
  color: var(--ma); text-decoration: none;
  transition: opacity 0.15s;
}
.back-to-top:hover { opacity: 0.6; }

/* ── About ─────────────────────────────── */
.about-section {
  background: var(--sage-dark); color: #fff; padding: 80px 28px;
}
.about-inner { max-width: 820px; margin: 0 auto; }
.about-section h2 {
  font-family: var(--display); font-size: 28px; font-weight: 700; letter-spacing: -0.02em;
  color: #fff; margin-bottom: 32px;
}
.about-section p {
  font-size: 15px; line-height: 1.85; color: rgba(255,255,255,0.7);
  margin-bottom: 20px; max-width: 68ch;
}
.about-section strong { color: #fff; }

footer {
  background: #131F18; padding: 22px 28px; text-align: center;
}
footer p { font-size: 12px; color: rgba(255,255,255,0.3); margin: 0; }

/* ── Diagnostic Router ─────────────────── */
.diagnostic {
  background: var(--sage-pale);
  border-top: 3px solid var(--sage-rule);
  border-bottom: 3px solid var(--sage-rule);
  padding: 52px 28px;
  margin: 52px 0 0;
}
.diag-inner { max-width: 820px; margin: 0 auto; }
.diag-label {
  font-size: 11px; font-weight: 700; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--sage-mid); margin-bottom: 10px;
}
.diag-heading {
  font-family: var(--display); font-size: clamp(20px, 2.8vw, 28px);
  font-weight: 700; letter-spacing: -0.02em; color: var(--sage-dark);
  margin-bottom: 32px; line-height: 1.2;
}
.diag-list { list-style: none; }
.diag-item { border-top: 1px solid var(--sage-rule); }
.diag-item:last-child { border-bottom: 1px solid var(--sage-rule); }
.diag-link {
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 0; text-decoration: none; color: var(--ink); gap: 16px;
  transition: color 0.15s;
}
.diag-link:hover { color: var(--sage-dark); }
.diag-link:hover .diag-arrow { transform: translateX(4px); color: var(--sage-dark); }
.diag-link:hover .diag-module { border-color: var(--sage-mid); color: var(--sage-mid); }
.diag-left { display: flex; align-items: center; gap: 14px; }
.diag-arrow {
  font-size: 18px; color: var(--sage-mid); flex-shrink: 0;
  transition: transform 0.15s, color 0.15s;
}
.diag-text { font-size: 16px; font-weight: 500; line-height: 1.4; }
.diag-module {
  font-size: 11px; font-weight: 700; letter-spacing: 0.08em;
  text-transform: uppercase; color: var(--muted);
  background: var(--white); border: 1.5px solid var(--rule);
  border-radius: 20px; padding: 4px 14px; white-space: nowrap; flex-shrink: 0;
  transition: border-color 0.15s, color 0.15s;
}

/* ── Module Header Row ──────────────────── */
.module-header-row {
  display: flex; align-items: flex-start;
  justify-content: space-between; gap: 16px; margin-bottom: 14px;
}
.module-header-row h2 { margin-bottom: 0; }
.copy-link-btn {
  display: inline-flex; align-items: center; gap: 6px; flex-shrink: 0;
  margin-top: 6px; font-size: 12px; font-weight: 600; color: var(--muted);
  background: none; border: 1.5px solid var(--rule);
  border-radius: 6px; padding: 6px 12px; cursor: pointer;
  transition: border-color 0.15s, color 0.15s, background 0.15s;
  font-family: var(--sans); white-space: nowrap;
}
.copy-link-btn:hover { border-color: var(--ma); color: var(--ma); background: var(--sage-pale); }
.copy-link-btn svg { flex-shrink: 0; }

/* ── In Practice Box ────────────────────── */
.in-practice {
  border: 2px solid var(--ma); border-radius: 10px;
  overflow: hidden; margin: 48px 0;
}
.ip-header {
  background: var(--ma); padding: 10px 22px;
  display: flex; align-items: center; gap: 10px;
}
.ip-header-label {
  font-family: var(--sans); font-size: 11px; font-weight: 700;
  letter-spacing: 0.1em; text-transform: uppercase; color: white;
}
.ip-items { background: var(--white); }
.ip-item {
  padding: 18px 24px; border-bottom: 1px solid var(--rule);
}
.ip-item:last-child { border-bottom: none; }
.ip-org {
  font-family: var(--display); font-size: 12px; font-weight: 700;
  color: var(--ma); text-transform: uppercase; letter-spacing: 0.06em;
  margin-bottom: 6px;
}
.ip-text {
  font-size: 15px; line-height: 1.65; color: var(--ink); max-width: 62ch;
}
.ip-result {
  display: inline-block; margin-top: 8px;
  font-size: 11px; font-weight: 700; letter-spacing: 0.04em;
  color: var(--ma); background: var(--sage-pale);
  padding: 3px 10px; border-radius: 20px;
}

/* ── Toast ──────────────────────────────── */
.copy-toast {
  position: fixed; bottom: 24px; left: 50%;
  transform: translateX(-50%) translateY(12px);
  background: var(--sage-dark); color: white;
  font-size: 13px; font-weight: 500; padding: 10px 20px;
  border-radius: 24px; opacity: 0;
  transition: opacity 0.2s, transform 0.2s;
  pointer-events: none; z-index: 999;
}
.copy-toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ── Citations ─────────────────────────── */
a.cite {
  color: inherit;
  text-decoration: underline;
  text-decoration-style: dotted;
  text-decoration-color: var(--sage-mid);
  text-underline-offset: 3px;
  transition: text-decoration-style 0.15s;
}
a.cite:hover {
  text-decoration-style: solid;
}
.cite-tag {
  display: inline-block;
  font-size: 10px; font-weight: 600; letter-spacing: 0.04em;
  vertical-align: super; line-height: 1;
  color: var(--sage-mid);
  text-decoration: none;
  margin-left: 2px;
  opacity: 0.8;
}
.cite-tag:hover { opacity: 1; }

/* ── Module Hero (module pages) ─────────── */
.module-hero {
  background: var(--sage-dark); padding: 52px 28px 56px;
  position: relative; overflow: hidden;
  border-bottom: 4px solid var(--ma);
}
.module-hero-inner { max-width: 820px; margin: 0 auto; }
.module-back {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 12px; font-weight: 600; color: rgba(255,255,255,0.5);
  text-decoration: none; letter-spacing: 0.02em; margin-bottom: 24px;
  transition: color 0.15s;
}
.module-back:hover { color: rgba(255,255,255,0.85); }
.module-hero .module-eyebrow { color: var(--sage-light); margin-bottom: 12px; }
.module-hero h1 {
  font-family: var(--display); font-size: clamp(28px, 4.5vw, 46px);
  font-weight: 700; letter-spacing: -0.025em; color: white;
  max-width: 20ch; line-height: 1.1; margin-bottom: 16px;
}
.module-hero .module-intro {
  color: rgba(255,255,255,0.7); margin-bottom: 0;
}
.module-hero-actions {
  margin-top: 24px; display: flex; align-items: center; gap: 12px;
}
.copy-link-btn-hero {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 12px; font-weight: 600; color: rgba(255,255,255,0.6);
  background: rgba(255,255,255,0.08); border: 1.5px solid rgba(255,255,255,0.2);
  border-radius: 6px; padding: 7px 14px; cursor: pointer;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
  font-family: var(--sans);
}
.copy-link-btn-hero:hover {
  background: rgba(255,255,255,0.15); color: white; border-color: rgba(255,255,255,0.4);
}

/* ── Module Pager ───────────────────────── */
.module-pager {
  background: var(--sage-dark); padding: 0;
}
.module-pager-inner {
  max-width: 820px; margin: 0 auto;
  display: grid; grid-template-columns: 1fr 1fr;
  border-top: 1px solid rgba(255,255,255,0.1);
}
.pager-link {
  display: block; padding: 28px 32px; text-decoration: none;
  transition: background 0.15s; color: white;
}
.pager-link:hover { background: rgba(255,255,255,0.06); }
.pager-link.pager-next { text-align: right; border-left: 1px solid rgba(255,255,255,0.1); }
.pager-dir {
  font-size: 11px; font-weight: 700; letter-spacing: 0.1em;
  text-transform: uppercase; color: var(--sage-light); margin-bottom: 8px;
}
.pager-title {
  font-family: var(--display); font-size: 15px; font-weight: 600;
  color: rgba(255,255,255,0.85); line-height: 1.3; letter-spacing: -0.01em;
}

@media (max-width: 640px) {
  .hero, .intro-section, .module-section, .about-inner { padding-left: 20px; padding-right: 20px; }
  .module-grid { padding: 0 20px 64px; grid-template-columns: 1fr; }
  .tactic-grid { grid-template-columns: 1fr; }
  .stat-bar { padding: 32px 20px; }
  .question-box { padding: 28px 24px; }
  .module-section { padding: 64px 20px 56px; }
}
