/* ============================================================
   CAPSKIT — CONSOLIDATED STYLESHEET
   Theme tokens, base resets, nav, buttons, hero, sections,
   features, coverage, subjects, final CTA, footer, cookie
   banner, doc/legal-page styles.

   This file is the single source of truth for CAPSKit visual
   identity. Inlined styles in templates have been removed.
   ============================================================ */

:root {
  /* ---- Colour: brand teal ---- */
  --teal-900: #0A2540;
  --teal-800: #0E3556;
  --teal-700: #0E6E78;
  --teal-600: #119AA6;
  --teal-500: #16C0C9;
  --teal-400: #38D6DC;
  --teal-300: #7FE5E8;
  --teal-100: #D4F2F4;
  --teal-50:  #EEF9FA;

  /* ---- Colour: magenta accent ---- */
  --magenta-700: #B81B5C;
  --magenta-600: #E51A6F;
  --magenta-500: #F23F89;
  --magenta-300: #F9A4C4;
  --magenta-100: #FBDDE8;

  /* ---- Colour: warm gold ---- */
  --gold-500: #D9A441;
  --gold-300: #ECCC8A;
  --gold-100: #F8EBCB;

  /* ---- Colour: neutrals ---- */
  --paper:    #FBF9F5;
  --paper-2:  #F4F1EA;
  --card:     #FFFFFF;
  --ink-900:  #0A2540;
  --ink-700:  #234157;
  --ink-500:  #5A6E7E;
  --ink-400:  #8597A4;
  --line:     #E6E1D6;

  /* ---- Type ---- */
  --font-display: 'Fraunces', Georgia, 'Times New Roman', serif;
  --font-hero:    'Newsreader', 'Fraunces', Georgia, serif;
  --font-body:    'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;

  /* ---- Radius ---- */
  --radius-sm: 8px;
  --radius:    14px;
  --radius-lg: 20px;
  --radius-pill: 999px;

  /* ---- Shadows: teal- and magenta-tinted, never pure black ---- */
  --shadow-xs: 0 1px 2px rgba(14,110,120,0.06);
  --shadow-sm: 0 2px 6px rgba(14,110,120,0.08), 0 1px 2px rgba(14,110,120,0.04);
  --shadow-md: 0 8px 20px rgba(14,110,120,0.10), 0 2px 6px rgba(14,110,120,0.06);
  --shadow-lg: 0 20px 40px rgba(14,110,120,0.14), 0 6px 12px rgba(14,110,120,0.08);
  --shadow-btn: 0 6px 14px rgba(229,26,111,0.30), 0 2px 4px rgba(229,26,111,0.18);
  --shadow-btn-hover: 0 12px 24px rgba(229,26,111,0.38), 0 3px 6px rgba(229,26,111,0.22);

  /* ---- Layout ---- */
  --container: 1180px;
}

/* ============================================================
   RESET / BASE
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.55;
  color: var(--ink-900);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; border: 0; background: none; color: inherit; }
input { font: inherit; color: inherit; }
.serif { font-family: var(--font-display); font-optical-sizing: auto; }
::selection { background: var(--teal-300); color: var(--teal-900); }

/* ============================================================
   LAYOUT
   ============================================================ */
.wrap { max-width: var(--container); margin: 0 auto; padding: 0 24px; }
section { padding: 88px 0; }
@media (max-width: 720px) {
  section { padding: 56px 0; }
  .wrap { padding: 0 18px; }
}

/* ============================================================
   NAVIGATION (used on every page)
   ============================================================ */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(251,249,245,.86);
  backdrop-filter: saturate(160%) blur(12px);
  -webkit-backdrop-filter: saturate(160%) blur(12px);
  border-bottom: 1px solid rgba(230,225,214,.6);
}
.nav-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 88px;
  max-width: var(--container); margin: 0 auto; padding: 0 24px;
}
.brand { display: flex; align-items: center; gap: 6px; text-decoration: none; color: var(--ink-900); }
.brand .mark {
  width: 56px; height: 56px; flex-shrink: 0;
  filter: drop-shadow(0 2px 4px rgba(14,110,120,0.18));
  transition: transform .25s cubic-bezier(.2,.7,.2,1);
}
.brand:hover .mark { transform: rotate(-4deg) scale(1.04); }
.brand-name {
  font-family: var(--font-display); font-weight: 500;
  font-size: 1.95rem; letter-spacing: -0.015em;
  display: inline-flex; align-items: center; gap: 6px;
  margin-left: -4px;
}
.brand-name .kit-pill {
  font-family: var(--font-body); font-weight: 600;
  font-size: 16px; letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--teal-700); background: var(--teal-100);
  padding: 5px 13px; border-radius: 7px;
  position: relative; top: 1px;
}
.brand-name .beta-badge {
  font-family: var(--font-body); font-weight: 500;
  font-size: 9px; letter-spacing: 0.04em; text-transform: uppercase;
  color: var(--teal-700); background: transparent;
  border: 1px solid var(--teal-700);
  padding: 2px 5px; border-radius: 4px;
  position: relative; top: -8px;
  margin-left: 4px;
  line-height: 1;
}
@media (max-width: 560px) {
  .brand-name .beta-badge {
    font-size: 8px;
    padding: 2px 4px;
    top: -6px;
  }
}

.nav-links { display: flex; gap: 28px; align-items: center; }
.nav-links a {
  color: var(--ink-700); text-decoration: none;
  font-weight: 500; font-size: 0.92rem;
  transition: color .15s;
}
.nav-links a:hover { color: var(--teal-700); }
.nav-links a.nav-cta,
.nav-cta {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 13.5px; font-weight: 600;
  padding: 9px 20px; border-radius: 12px;
  background: var(--magenta-600); color: #fff;
  border: none;
  text-decoration: none; letter-spacing: 0.005em;
  box-shadow: 0 4px 10px rgba(229,26,111,0.25);
  transition: background .15s, transform .15s, box-shadow .15s;
}
.nav-links a.nav-cta:hover,
.nav-cta:hover {
  background: var(--magenta-500); color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 8px 18px rgba(229,26,111,0.34);
}
.nav-cta svg { transition: transform .2s; }
.nav-cta:hover svg { transform: translateX(2px); }
@media (max-width: 960px) {
  .nav-links a:not(.nav-cta) { display: none; }
}

/* ============================================================
   BUTTONS
   ============================================================ */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 14px 26px; border-radius: 12px;
  font-weight: 500; font-size: 1rem;
  text-decoration: none; cursor: pointer; border: none;
  font-family: inherit; letter-spacing: 0.005em;
  transition: transform .15s cubic-bezier(.2,.7,.2,1), box-shadow .15s, background .15s, color .15s, border-color .15s;
}
.btn-primary {
  background: var(--magenta-600); color: #fff;
  box-shadow: var(--shadow-btn);
}
.btn-primary:hover { background: var(--magenta-500); transform: translateY(-2px); box-shadow: var(--shadow-btn-hover); }
.btn-primary:active { transform: translateY(0); }
.btn-secondary {
  background: var(--card); color: var(--ink-900);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-xs);
}
.btn-secondary:hover { border-color: var(--teal-300); color: var(--teal-700); transform: translateY(-1px); box-shadow: 0 4px 12px rgba(14,110,120,0.10); }
.btn .arrow { transition: transform .15s; }
.btn:hover .arrow { transform: translateX(3px); }

/* ============================================================
   HERO (landing page)
   ============================================================ */
.hero {
  position: relative; overflow: hidden;
  padding: 96px 0 80px;
  background:
    radial-gradient(800px 400px at 85% -10%, rgba(229,26,111,.07), transparent 60%),
    radial-gradient(700px 500px at 10% 110%, rgba(22,192,201,.12), transparent 60%);
}
.hero-grid { display: grid; grid-template-columns: 1.1fr 1fr; gap: 64px; align-items: center; }
@media (max-width: 880px) {
  .hero { padding: 64px 0 56px; }
  .hero-grid { grid-template-columns: 1fr; gap: 40px; }
}
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--teal-100); color: var(--teal-700);
  padding: 6px 14px; border-radius: 999px;
  font-size: 0.78rem; font-weight: 600; letter-spacing: 0.05em; text-transform: uppercase;
  margin-bottom: 22px;
}
.eyebrow .dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--teal-600);
  box-shadow: 0 0 0 4px rgba(22,192,201,.22);
  animation: pulse 2s ease-in-out infinite;
}
@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: .55; } }
.hero h1 {
  font-family: var(--font-hero);
  font-weight: 500;
  font-size: clamp(2.4rem, 5.4vw, 3.9rem);
  line-height: 1.05; letter-spacing: -0.02em;
  color: var(--ink-900);
  margin-bottom: 22px;
  text-wrap: balance;
}
.hero h1 .accent { color: var(--teal-700); font-style: italic; font-weight: 400; }
.hero h1 .accent-pink { color: var(--magenta-600); font-style: italic; font-weight: 500; }
.hero p.lead {
  font-size: 1.18rem; color: var(--ink-700);
  max-width: 560px; margin-bottom: 36px; line-height: 1.55;
}
.hero-ctas { display: flex; gap: 14px; flex-wrap: wrap; margin-bottom: 32px; }
.hero-trust { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; color: var(--ink-500); font-size: 0.88rem; }
.hero-trust .pill { display: inline-flex; align-items: center; gap: 6px; }
.hero-trust .check {
  display: inline-flex; align-items: center; justify-content: center;
  width: 18px; height: 18px; border-radius: 50%;
  background: var(--teal-100); color: var(--teal-700);
  font-size: 11px; font-weight: 700;
}

/* Hero visual: prompt-card mockup */
.hero-visual { position: relative; }
.prompt-card {
  background: var(--card);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  padding: 0; overflow: hidden; position: relative;
  border: 1px solid var(--line);
  transform: rotate(-1deg);
  transition: transform .3s ease;
}
.prompt-card:hover { transform: rotate(0deg) scale(1.01); }
.prompt-card-head {
  background: linear-gradient(135deg, var(--teal-700) 0%, var(--teal-500) 100%);
  color: #fff;
  padding: 18px 22px;
  display: flex; align-items: center; justify-content: space-between;
}
.prompt-card-head .label { font-size: 0.78rem; font-weight: 600; letter-spacing: 0.05em; opacity: .92; text-transform: uppercase; }
.prompt-card-head .meta { font-size: 0.78rem; opacity: .85; }
.prompt-card-body { padding: 22px 24px; font-family: var(--font-display); }
.prompt-line { display: block; padding: 5px 0; font-size: 0.92rem; line-height: 1.55; color: var(--ink-700); }
.prompt-line .k {
  color: var(--magenta-700); font-weight: 600; font-style: normal;
  font-family: var(--font-body); font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.06em;
  background: var(--magenta-100);
  padding: 2px 8px; border-radius: 5px;
  margin-right: 6px; display: inline-block;
}
.prompt-line .k.teal { color: var(--teal-700); background: var(--teal-100); }
.prompt-card-foot {
  border-top: 1px solid var(--line);
  padding: 14px 22px;
  display: flex; align-items: center; justify-content: space-between;
  background: var(--paper);
}
.prompt-card-foot .copy-btn {
  background: var(--magenta-600); color: #fff;
  font-size: 0.82rem; font-weight: 600;
  padding: 8px 14px; border-radius: 8px;
  display: inline-flex; align-items: center; gap: 6px;
}
.prompt-card-foot .word-count { font-size: 0.78rem; color: var(--ink-500); }

.float-badge {
  position: absolute;
  background: var(--card);
  border-radius: 14px;
  padding: 12px 16px;
  box-shadow: var(--shadow-md);
  display: flex; align-items: center; gap: 10px;
  font-size: 0.85rem;
  border: 1px solid var(--line);
}
.float-badge .icon {
  width: 32px; height: 32px; border-radius: 8px;
  background: var(--magenta-100); color: var(--magenta-700);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.05rem; flex-shrink: 0;
}
.float-badge .icon.teal { background: var(--teal-100); color: var(--teal-700); }
.float-badge.bb1 { top: -18px; right: -12px; transform: rotate(4deg); }
.float-badge.bb2 { bottom: -18px; left: -22px; transform: rotate(-3deg); }
.float-badge strong { display: block; font-weight: 600; color: var(--ink-900); font-size: 0.86rem; }
.float-badge span { color: var(--ink-500); font-size: 0.76rem; }

/* ============================================================
   SECTION HEADERS
   ============================================================ */
.section-head { text-align: center; max-width: 680px; margin: 0 auto 56px; }
.section-eyebrow {
  font-size: 0.78rem; font-weight: 500; color: var(--teal-700);
  text-transform: uppercase; letter-spacing: 0.18em;
  margin-bottom: 14px;
}
.section-head h2 {
  font-family: var(--font-display); font-weight: 500;
  font-size: clamp(1.9rem, 3.6vw, 2.7rem);
  line-height: 1.15; letter-spacing: -0.02em;
  color: var(--ink-900); margin-bottom: 14px;
  text-wrap: balance;
}
.section-head h2 em { font-style: italic; font-weight: 400; color: var(--teal-700); }
.section-head p { font-size: 1.08rem; color: var(--ink-500); }

/* ============================================================
   HOW IT WORKS (steps)
   ============================================================ */
.steps-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
@media (max-width: 880px) { .steps-grid { grid-template-columns: 1fr; gap: 18px; } }
.step-card {
  background: var(--card);
  border-radius: var(--radius);
  padding: 30px 26px;
  box-shadow: var(--shadow-xs);
  border: 1px solid var(--line);
  transition: transform .2s, box-shadow .2s, border-color .2s;
  position: relative;
}
.step-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); border-color: transparent; }
.step-num {
  display: inline-flex; align-items: center; justify-content: center;
  width: 42px; height: 42px; border-radius: 12px;
  background: var(--teal-100); color: var(--teal-700);
  font-family: var(--font-display); font-size: 1.4rem; font-weight: 500;
  margin-bottom: 18px;
}
.step-card h3 {
  font-family: var(--font-display); font-weight: 500;
  font-size: 1.25rem; letter-spacing: -0.01em;
  color: var(--ink-900); margin-bottom: 8px;
}
.step-card p { color: var(--ink-500); font-size: 0.95rem; line-height: 1.6; }

/* ============================================================
   FEATURES
   ============================================================ */
.features { background: linear-gradient(180deg, var(--paper) 0%, var(--paper-2) 100%); }
.feat-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
@media (max-width: 880px) { .feat-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .feat-grid { grid-template-columns: 1fr; } }
.feat {
  background: var(--card);
  border-radius: var(--radius);
  padding: 26px 24px;
  box-shadow: var(--shadow-xs);
  border: 1px solid var(--line);
  transition: transform .2s, box-shadow .2s, border-color .2s;
}
.feat:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); border-color: transparent; }
.feat-icon {
  width: 44px; height: 44px; border-radius: 11px;
  background: var(--teal-100); color: var(--teal-700);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.3rem; margin-bottom: 16px;
}
.feat:nth-child(2) .feat-icon { background: var(--magenta-100); color: var(--magenta-700); }
.feat:nth-child(4) .feat-icon { background: var(--gold-100); color: #8A6420; }
.feat:nth-child(5) .feat-icon { background: var(--magenta-100); color: var(--magenta-700); }
.feat h3 {
  font-family: var(--font-display); font-weight: 500;
  font-size: 1.15rem; color: var(--ink-900);
  margin-bottom: 6px; letter-spacing: -0.005em;
}
.feat p { color: var(--ink-500); font-size: 0.92rem; line-height: 1.55; }

/* ============================================================
   COVERAGE STRIP (dark teal)
   ============================================================ */
.coverage { background: var(--teal-900); color: #fff; padding: 64px 0; }
.coverage-inner { display: grid; grid-template-columns: 1fr 1.2fr; gap: 48px; align-items: center; }
@media (max-width: 880px) { .coverage-inner { grid-template-columns: 1fr; gap: 32px; text-align: center; } }
.coverage h2 {
  font-family: var(--font-display); font-weight: 500;
  font-size: clamp(1.7rem, 3.2vw, 2.3rem);
  line-height: 1.15; letter-spacing: -0.015em;
  margin-bottom: 14px; text-wrap: balance;
}
.coverage h2 em { font-style: italic; font-weight: 400; color: var(--teal-300); }
.coverage p { color: rgba(255,255,255,.78); font-size: 1.02rem; max-width: 420px; line-height: 1.6; }
@media (max-width: 880px) { .coverage p { margin: 0 auto; } }
.cov-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.cov-stat {
  background: rgba(255,255,255,.05);
  border: 1px solid rgba(255,255,255,.10);
  border-radius: var(--radius);
  padding: 24px 18px; text-align: center;
  backdrop-filter: blur(8px);
}
.cov-stat .num {
  font-family: var(--font-display); font-weight: 500;
  font-size: 2.4rem; color: var(--teal-300);
  line-height: 1; margin-bottom: 6px; letter-spacing: -0.02em;
}
.cov-stat .label { font-size: 0.82rem; color: rgba(255,255,255,.78); font-weight: 500; }

/* ============================================================
   SUBJECTS PILL CLOUD
   ============================================================ */
.subjects { padding: 40px 0 88px; }
.subj-grid { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; max-width: 920px; margin: 0 auto; }
.subj-pill {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 8px 18px;
  font-size: 0.86rem; font-weight: 500;
  color: var(--ink-700);
  box-shadow: var(--shadow-xs);
  transition: all .15s;
}
.subj-pill:hover { border-color: var(--teal-300); color: var(--teal-700); transform: translateY(-1px); }
.subj-pill.accent { background: var(--teal-100); color: var(--teal-700); border-color: var(--teal-100); }
.subj-pill.accent-magenta { background: var(--magenta-100); color: var(--magenta-700); border-color: var(--magenta-100); }

/* ============================================================
   FINAL CTA BLOCK
   ============================================================ */
.final-cta {
  background: linear-gradient(135deg, var(--teal-600) 0%, var(--teal-800) 50%, var(--teal-900) 100%);
  color: #fff;
  border-radius: var(--radius-lg);
  padding: 64px 48px;
  text-align: center;
  position: relative; overflow: hidden;
  margin: 0 24px;
}
.final-cta::before {
  content: ''; position: absolute;
  top: -100px; right: -100px;
  width: 340px; height: 340px; border-radius: 50%;
  background: radial-gradient(circle, rgba(229,26,111,.22), transparent 70%);
  pointer-events: none;
}
.final-cta::after {
  content: ''; position: absolute;
  bottom: -140px; left: -100px;
  width: 380px; height: 380px; border-radius: 50%;
  background: radial-gradient(circle, rgba(127,229,232,.10), transparent 70%);
  pointer-events: none;
}
.final-cta-inner { position: relative; z-index: 1; max-width: 680px; margin: 0 auto; }
.final-cta h2 {
  font-family: var(--font-display); font-weight: 500;
  font-size: clamp(1.9rem, 3.6vw, 2.6rem);
  line-height: 1.15; letter-spacing: -0.015em;
  margin-bottom: 14px; text-wrap: balance;
}
.final-cta h2 em { font-style: italic; font-weight: 400; color: var(--teal-300); }
.final-cta p { font-size: 1.08rem; color: rgba(255,255,255,.85); margin-bottom: 28px; }
.final-cta .btn-primary { box-shadow: 0 12px 32px rgba(229,26,111,.36); }

/* ============================================================
   FOOTER (used on every page)
   ============================================================ */
.site-footer {
  padding: 48px 0 36px;
  border-top: 1px solid var(--line);
  margin-top: 88px;
  background: var(--paper);
}
.foot-inner {
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 20px;
  max-width: var(--container); margin: 0 auto; padding: 0 24px;
}
.foot-brand { display: flex; align-items: center; gap: 6px; text-decoration: none; color: var(--ink-900); }
.foot-brand .mark { width: 56px; height: 56px; flex-shrink: 0; filter: drop-shadow(0 2px 4px rgba(14,110,120,0.18)); }
.foot-brand .brand-name { font-family: var(--font-display); font-weight: 500; font-size: 1.95rem; letter-spacing: -0.015em; display: inline-flex; align-items: center; gap: 6px; margin-left: -4px; color: var(--ink-900); }
.foot-meta { font-size: 0.86rem; color: var(--ink-500); }
.foot-meta a { color: var(--ink-700); text-decoration: none; margin: 0 10px; border-bottom: 1px solid var(--line); transition: color .15s, border-color .15s; }
.foot-meta a:hover { color: var(--teal-700); border-color: var(--teal-300); }
.foot-copyright {
  margin-top: 24px; padding-top: 18px;
  border-top: 1px solid var(--line);
  text-align: center; font-size: 0.78rem; color: var(--ink-400);
  letter-spacing: 0.02em;
  max-width: var(--container); margin-left: auto; margin-right: auto;
  padding-left: 24px; padding-right: 24px;
}
.foot-disclaimer {
  text-align: center; font-size: 0.74rem; font-style: italic;
  color: var(--ink-400); max-width: 680px; margin: 8px auto 0;
  line-height: 1.5; padding: 0 16px;
}

/* ============================================================
   DOC / LEGAL PAGES (terms.html, privacy.html)
   ============================================================ */
.doc-wrap { max-width: 780px; margin: 0 auto; padding: 64px 24px 96px; }
.doc-header { margin-bottom: 48px; }
.doc-eyebrow { font-size: 0.78rem; font-weight: 600; color: var(--teal-700); text-transform: uppercase; letter-spacing: 0.18em; margin-bottom: 14px; }
.doc-header h1 {
  font-family: var(--font-display); font-weight: 600;
  font-size: clamp(2rem, 4vw, 3rem);
  line-height: 1.15; letter-spacing: -0.02em;
  color: var(--ink-900); margin-bottom: 14px;
}
.doc-meta { font-size: 0.92rem; color: var(--ink-500); }

.doc-content { font-size: 16.5px; line-height: 1.65; }
.doc-content a { color: var(--teal-700); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 2px; }
.doc-content a:hover { color: var(--teal-600); }
.doc-content h2 {
  font-family: var(--font-display); font-weight: 600;
  font-size: 1.45rem; color: var(--ink-900);
  margin-top: 40px; margin-bottom: 14px; letter-spacing: -0.005em;
}
.doc-content h3 {
  font-family: var(--font-display); font-weight: 500;
  font-size: 1.15rem; color: var(--ink-900);
  margin-top: 24px; margin-bottom: 8px;
}
.doc-content p { margin-bottom: 14px; color: var(--ink-700); }
.doc-content ul { margin: 0 0 16px 22px; padding: 0; }
.doc-content li { margin-bottom: 8px; color: var(--ink-700); }
.doc-content strong { color: var(--ink-900); font-weight: 600; }

.disclaimer-box {
  background: var(--gold-100);
  border: 1.5px solid var(--gold-500);
  border-left: 4px solid var(--gold-500);
  border-radius: 10px;
  padding: 16px 20px; margin-bottom: 36px;
  font-size: 0.92rem; color: #6B4D14; line-height: 1.6;
  display: flex; align-items: flex-start; gap: 12px;
}
.disclaimer-box .icon { font-size: 1.2rem; flex-shrink: 0; }
.disclaimer-box strong { display: block; font-size: 1rem; font-weight: 700; color: #5A3F0C; margin-bottom: 4px; }

.summary-box {
  background: var(--teal-50);
  border: 1.5px solid var(--teal-300);
  border-left: 4px solid var(--teal-700);
  border-radius: 10px;
  padding: 16px 22px; margin-bottom: 36px;
  font-size: 0.94rem; color: var(--teal-900); line-height: 1.65;
}
.summary-box strong { display: block; font-family: var(--font-display); font-weight: 600; font-size: 1.05rem; color: var(--teal-900); margin-bottom: 6px; letter-spacing: -0.005em; }

.toc {
  background: var(--card); border: 1px solid var(--line);
  border-radius: 14px; padding: 22px 28px; margin-bottom: 36px;
}
.toc-title { font-family: var(--font-display); font-weight: 600; font-size: 1rem; color: var(--ink-900); margin-bottom: 10px; }
.toc ol { margin: 0 0 0 20px; padding: 0; font-size: 0.94rem; color: var(--ink-700); line-height: 1.85; }
.toc a { color: var(--ink-700); text-decoration: none; }
.toc a:hover { color: var(--teal-700); text-decoration: underline; }

.subprocessor-table { border-collapse: collapse; width: 100%; margin: 14px 0; font-size: 0.92rem; }
.subprocessor-table th { background: var(--paper-2); border: 1px solid var(--line); padding: 10px 12px; font-weight: 600; text-align: left; color: var(--ink-900); }
.subprocessor-table td { border: 1px solid var(--line); padding: 10px 12px; color: var(--ink-700); vertical-align: top; }

/* ============================================================
   COOKIE CONSENT BANNER
   ============================================================ */
.cookie-banner {
  position: fixed; bottom: 24px; right: 24px; z-index: 1000;
  width: min(260px, calc(100vw - 32px));
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: 0 12px 32px rgba(14,110,120,0.14), 0 4px 12px rgba(15,23,42,0.06);
  padding: 20px 22px 18px;
  font-family: var(--font-body); font-size: 0.86rem;
  color: var(--ink-700); line-height: 1.55;
  opacity: 0; transform: translateY(20px);
  transition: opacity .35s ease, transform .35s ease;
  pointer-events: none;
}
.cookie-banner.visible { opacity: 1; transform: none; pointer-events: auto; }
.cookie-banner h3 {
  font-family: var(--font-display); font-weight: 600; font-size: 1.05rem;
  color: var(--ink-900); margin: 0 0 8px; letter-spacing: -0.005em;
  display: flex; justify-content: center; align-items: center; gap: 8px;
}
.cookie-banner h3 .cookie-icon { font-size: 1.2rem; }
.cookie-banner p { margin: 0 0 14px; color: var(--ink-700); font-size: 0.86rem; }
.cookie-banner p a { color: var(--teal-700); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 2px; }
.cookie-banner p a:hover { color: var(--teal-600); }
.cookie-banner .cookie-actions {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 8px;
}
.cookie-banner .cookie-btn {
  font-family: var(--font-body); font-weight: 600; font-size: 0.82rem;
  padding: 8px 16px; border-radius: 9px; border: none; cursor: pointer;
  text-decoration: none; letter-spacing: 0.005em;
  transition: transform .12s, box-shadow .15s, background .15s, border-color .15s;
}
.cookie-banner .cookie-btn-primary {
  background: var(--magenta-600); color: #fff;
  box-shadow: 0 3px 8px rgba(229,26,111,0.25);
}
.cookie-banner .cookie-btn-primary:hover {
  background: var(--magenta-500);
  transform: translateY(-1px);
  box-shadow: 0 6px 14px rgba(229,26,111,0.34);
}
.cookie-banner .cookie-btn-secondary {
  background: #fff; color: var(--ink-700);
  border: 1px solid var(--line);
}
.cookie-banner .cookie-btn-secondary:hover { border-color: var(--teal-300); color: var(--teal-700); transform: translateY(-1px); }
.cookie-banner .cookie-btn-link {
  background: transparent; color: var(--ink-500);
  font-weight: 500; padding: 8px 16px;
  border: 1px solid transparent;
}
.cookie-banner .cookie-btn-link:hover {
  color: var(--teal-700);
  border-color: var(--teal-100);
  background: var(--teal-50);
}

.cookie-manage { display: none; margin-top: 14px; padding-top: 14px; border-top: 1px dashed var(--line); }
.cookie-banner.managing .cookie-manage { display: block; }
.cookie-banner.managing .cookie-actions { display: none; }
.cookie-row { display: flex; justify-content: space-between; align-items: flex-start; gap: 14px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.cookie-row:last-of-type { border-bottom: none; }
.cookie-row-info { flex: 1; }
.cookie-row-title { font-weight: 600; font-size: 0.86rem; color: var(--ink-900); margin-bottom: 3px; }
.cookie-row-desc { font-size: 0.74rem; color: var(--ink-500); line-height: 1.45; }
.cookie-row .switch { position: relative; width: 38px; height: 21px; flex-shrink: 0; margin-top: 2px; }
.cookie-row .switch input { opacity: 0; width: 0; height: 0; }
.cookie-row .slider { position: absolute; inset: 0; background: #cbd5d8; border-radius: 21px; cursor: pointer; transition: .18s; }
.cookie-row .slider::before { content: ''; position: absolute; width: 15px; height: 15px; left: 3px; top: 3px; background: #fff; border-radius: 50%; transition: .18s; box-shadow: 0 1px 2px rgba(0,0,0,0.10); }
.cookie-row .switch input:checked + .slider { background: var(--teal-700); }
.cookie-row .switch input:checked + .slider::before { transform: translateX(17px); }
.cookie-row .switch input:disabled + .slider { background: var(--teal-100); cursor: not-allowed; opacity: .7; }
.cookie-row .switch input:disabled + .slider::before { background: var(--teal-300); }
.cookie-manage-actions { display: flex; gap: 8px; justify-content: flex-end; margin-top: 14px; }
@media (max-width: 480px) {
  .cookie-banner { bottom: 16px; right: 16px; left: 16px; width: auto; }
  .cookie-banner .cookie-actions { flex-direction: column; align-items: stretch; }
  .cookie-banner .cookie-actions .cookie-btn { width: 100%; text-align: center; }
  .cookie-banner .cookie-btn-link { width: auto; align-self: center; }
}

/* ============================================================
   REVEAL-ON-SCROLL ANIMATION
   ============================================================ */
@media (prefers-reduced-motion: no-preference) {
  .reveal { opacity: 0; transform: translateY(16px); transition: opacity .6s ease, transform .6s ease; }
  .reveal.in { opacity: 1; transform: none; }
}
@media (prefers-reduced-motion: reduce) {
  .eyebrow .dot { animation: none; }
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
}

/* ============================================================
   ACCESSIBILITY
   ============================================================ */
.sr {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0);
  border: 0;
}

/* ============================================================
   AUTH PAGES (login, login_sent, login_invalid)
   ============================================================ */
.auth-wrap {
  min-height: calc(100vh - 88px - 280px);
  display: grid;
  place-items: center;
  padding: 48px 24px;
}
.auth-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  padding: 44px 40px;
  width: 100%;
  max-width: 480px;
}
.auth-card-narrow {
  max-width: 420px;
  text-align: center;
}
.auth-card .doc-eyebrow { margin-bottom: 10px; }
.auth-title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(1.6rem, 3.2vw, 2.1rem);
  line-height: 1.2;
  letter-spacing: -0.015em;
  color: var(--ink-900);
  margin-bottom: 12px;
  text-wrap: balance;
}
.auth-lead {
  color: var(--ink-700);
  font-size: 1rem;
  margin-bottom: 28px;
  line-height: 1.55;
}
.auth-form { display: flex; flex-direction: column; gap: 14px; }
.auth-label {
  font-size: 0.86rem;
  font-weight: 500;
  color: var(--ink-700);
  margin-bottom: -8px;
}
.form-input {
  width: 100%;
  padding: 13px 16px;
  font-size: 1rem;
  font-family: var(--font-body);
  color: var(--ink-900);
  background: var(--paper);
  border: 1.5px solid var(--line);
  border-radius: var(--radius);
  transition: border-color .15s, box-shadow .15s, background .15s;
}
.form-input:focus {
  outline: none;
  border-color: var(--teal-700);
  background: #fff;
  box-shadow: 0 0 0 4px rgba(14,110,120,0.10);
}
.auth-error {
  color: #9B1C1C;
  font-size: 0.86rem;
  font-weight: 500;
  margin-top: 4px;
  display: flex;
  align-items: flex-start;
  gap: 6px;
  line-height: 1.4;
}
.auth-error::before {
  content: "\26A0";
  font-size: 0.95rem;
  flex-shrink: 0;
  line-height: 1;
}
.auth-checkbox {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  font-size: 0.92rem;
  color: var(--ink-700);
  cursor: pointer;
  padding: 8px 0;
  line-height: 1.5;
}
.auth-checkbox input[type="checkbox"] {
  width: 18px;
  height: 18px;
  margin-top: 2px;
  accent-color: var(--teal-700);
  cursor: pointer;
  flex-shrink: 0;
}
.auth-submit {
  margin-top: 8px;
  width: 100%;
  justify-content: center;
}
.auth-footnote {
  margin-top: 16px;
  font-size: 0.82rem;
  color: var(--ink-500);
  text-align: center;
  line-height: 1.55;
}
.auth-footnote a {
  color: var(--teal-700);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
}
.auth-footnote a:hover { color: var(--teal-600); }
.auth-icon-circle {
  width: 56px; height: 56px;
  border-radius: 50%;
  background: var(--teal-100);
  color: var(--teal-700);
  font-size: 1.6rem;
  display: grid; place-items: center;
  margin: 0 auto 18px;
}
.auth-icon-warn { background: var(--gold-100); color: #8A6420; }
@media (max-width: 480px) {
  .auth-card { padding: 32px 24px; }
}

/* ============================================================
   BUILDER (Step 1+ wizard)
   ============================================================ */
.builder-wrap {
  min-height: calc(100vh - 88px - 280px);
  display: grid;
  place-items: start center;
  padding: 64px 24px;
}
.builder-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  padding: 44px 40px;
  width: 100%;
  max-width: 580px;
}
.step-pill {
  display: inline-block;
  background: var(--teal-100);
  color: var(--teal-700);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 5px 12px;
  border-radius: 999px;
  margin-bottom: 14px;
}
.builder-title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(1.7rem, 3.4vw, 2.3rem);
  line-height: 1.18;
  letter-spacing: -0.015em;
  color: var(--ink-900);
  margin-bottom: 12px;
  text-wrap: balance;
}
.builder-lead {
  color: var(--ink-700);
  font-size: 1rem;
  margin-bottom: 28px;
}
.builder-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.builder-form select.form-input {
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox=\'0 0 12 8\' fill=\'none\'><path d=\'M1 1.5L6 6.5L11 1.5\' stroke=\'%230E6E78\' stroke-width=\'1.6\' stroke-linecap=\'round\' stroke-linejoin=\'round\'/></svg>");
  background-repeat: no-repeat;
  background-position: right 16px center;
  background-size: 12px 8px;
  padding-right: 40px;
}
@media (max-width: 480px) {
  .builder-card { padding: 32px 24px; }
}

/* ============================================================
   STEP NAV
   ============================================================ */
.step-nav { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.step-back-links { font-size: 0.86rem; color: var(--ink-500); }
.step-back-links a { color: var(--teal-700); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 2px; }
.step-back-links a:hover { color: var(--teal-600); }
.step-back-links .sep { margin: 0 6px; color: var(--ink-400); }

.builder-card-wide { max-width: 760px; }

/* ============================================================
   STEP 2 — TERM TABS + STRAND PICKER
   ============================================================ */
.term-tabs {
  display: flex; gap: 6px; flex-wrap: wrap;
  margin-bottom: 18px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 6px;
}
.term-tab {
  background: transparent;
  border: 1px solid var(--line);
  color: var(--ink-700);
  padding: 8px 16px;
  border-radius: 999px;
  font-size: 0.86rem;
  font-weight: 500;
  cursor: pointer;
  transition: background .15s, border-color .15s, color .15s;
}
.term-tab:hover { border-color: var(--teal-300); color: var(--teal-700); }
.term-tab.is-active { background: var(--teal-700); border-color: var(--teal-700); color: #fff; }

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

.block-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 14px 16px;
  transition: border-color .15s, box-shadow .15s, background .15s;
}
.block-card.is-selected {
  border-color: var(--teal-300);
  background: var(--teal-50);
  box-shadow: 0 2px 6px rgba(14,110,120,0.08);
}
.block-card-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }

.block-toggle {
  background: transparent; border: 0; padding: 4px 0; cursor: pointer;
  display: inline-flex; align-items: center; gap: 10px;
  font-family: inherit; text-align: left;
  color: var(--ink-900);
}
.block-toggle:hover .check-pill { border-color: var(--teal-700); }

.check-pill {
  display: inline-flex; align-items: center; justify-content: center;
  width: 22px; height: 22px;
  border-radius: 6px;
  border: 1.5px solid var(--ink-400);
  color: transparent;
  font-weight: 700; font-size: 0.9rem;
  transition: background .15s, border-color .15s, color .15s;
  flex-shrink: 0;
}
.check-pill.is-on { background: var(--teal-700); border-color: var(--teal-700); color: #fff; }

.block-name { font-weight: 500; font-size: 0.96rem; color: var(--ink-900); }
.muted { color: var(--ink-500); font-size: 0.82rem; }

.substrand-details { margin-top: 10px; }
.substrand-details summary {
  cursor: pointer;
  font-size: 0.84rem;
  color: var(--teal-700);
  font-weight: 500;
  padding: 4px 0;
  list-style: none;
}
.substrand-details summary::marker { display: none; }
.substrand-details summary::before { content: "+ "; font-weight: 700; }
.substrand-details[open] summary::before { content: "\2212 "; }
.substrand-details summary:hover { color: var(--teal-600); }

.substrand-list {
  list-style: none; padding: 8px 0 0; margin: 0;
  display: flex; flex-wrap: wrap; gap: 6px;
}
.substrand-pill {
  display: inline-flex; align-items: center; gap: 4px;
  background: #fff;
  border: 1px solid var(--line);
  color: var(--ink-700);
  padding: 5px 12px;
  border-radius: 999px;
  font-size: 0.82rem;
  cursor: pointer;
  transition: border-color .15s, background .15s, color .15s;
  font-family: inherit;
}
.substrand-pill:hover { border-color: var(--teal-300); }
.substrand-pill.is-on { background: var(--teal-700); border-color: var(--teal-700); color: #fff; }

.extra-topic-details { margin-top: 24px; }
.extra-topic-details summary {
  cursor: pointer;
  font-size: 0.92rem;
  color: var(--ink-700);
  font-weight: 500;
  padding: 8px 0;
  list-style: none;
}
.extra-topic-details summary::marker { display: none; }
.extra-topic-details summary::before { content: "+ "; font-weight: 700; color: var(--teal-700); }
.extra-topic-details[open] summary::before { content: "\2212 "; }
.extra-topic-details textarea { margin-top: 8px; resize: vertical; min-height: 80px; }

.step2-actions {
  display: flex; gap: 12px; justify-content: space-between;
  margin-top: 32px; padding-top: 20px; border-top: 1px solid var(--line);
}
.step2-actions .btn-secondary { padding: 12px 22px; }
.step2-actions .btn-primary { flex: 1; justify-content: center; }
@media (max-width: 480px) {
  .step2-actions { flex-direction: column; }
  .step2-actions .btn { width: 100%; }
}

/* Step 2: separate check-pill click target from name click target */
.check-pill-btn {
  background: transparent;
  border: 0;
  padding: 4px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  transition: background .15s;
}
.check-pill-btn:hover { background: rgba(14,110,120,0.06); }
.check-pill-btn:hover .check-pill { border-color: var(--teal-700); }
.check-pill-btn:focus-visible { outline: 2px solid var(--teal-700); outline-offset: 2px; }
/* Make the actual pill bigger and more checkbox-like */
.check-pill-btn .check-pill {
  width: 26px;
  height: 26px;
  border-width: 2px;
}
.block-name-btn {
  background: transparent;
  border: 0;
  padding: 6px 0;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: inherit;
  text-align: left;
  color: var(--ink-900);
  flex: 1;
}
.block-name-btn:hover .block-name { color: var(--teal-700); }
.block-name-static {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex: 1;
  padding: 6px 0;
}
.block-count { white-space: nowrap; }
.block-card-head { gap: 10px; }

/* Step 3-5: builder sub-headings */
.builder-subhead {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.05rem;
  color: var(--ink-900);
  margin: 8px 0 12px;
  letter-spacing: -0.005em;
}

/* Pick-cards (used for Purpose, CogMix, Output Language, Output Format, Paper Style) */
.card-grid {
  display: grid;
  gap: 10px;
}
.card-grid-2 { grid-template-columns: repeat(2, 1fr); }
.card-grid-3 { grid-template-columns: repeat(3, 1fr); }
.card-grid-4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 720px) {
  .card-grid-3, .card-grid-4 { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 480px) {
  .card-grid-2, .card-grid-3, .card-grid-4 { grid-template-columns: 1fr; }
}

.pick-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  text-align: left;
  gap: 4px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 14px 16px;
  cursor: pointer;
  transition: border-color .15s, background .15s, box-shadow .15s, transform .12s;
  font-family: inherit;
  color: var(--ink-900);
  min-height: 64px;
}
.pick-card:hover { border-color: var(--teal-300); background: var(--teal-50); transform: translateY(-1px); }
.pick-card.is-selected {
  border-color: var(--teal-700);
  background: var(--teal-50);
  box-shadow: 0 0 0 2px rgba(14,110,120,0.18);
}
.pick-card .pick-icon { font-size: 1.4rem; line-height: 1; margin-bottom: 2px; }
.pick-card .pick-label { font-weight: 600; font-size: 0.96rem; color: var(--ink-900); }
.pick-card .pick-desc { font-size: 0.78rem; color: var(--ink-500); line-height: 1.4; }
.pick-card-compact { padding: 12px 14px; min-height: 52px; }
.pick-card-compact .pick-label { font-size: 0.92rem; }
.pick-card-compact .pick-desc { font-size: 0.74rem; }

/* Step 4: 3-column row of marks/qty/time inputs */
.three-col-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-bottom: 18px;
}
@media (max-width: 600px) { .three-col-row { grid-template-columns: 1fr; } }

.format-icon { font-size: 1.1rem; margin-right: 4px; }

/* Step 6 summary */
.summary-list { list-style: none; padding: 0; margin: 0 0 24px; display: flex; flex-direction: column; gap: 8px; }
.summary-list li { padding: 10px 14px; background: var(--paper-2); border-radius: 8px; font-size: 0.94rem; color: var(--ink-700); }
.summary-list strong { color: var(--ink-900); margin-right: 6px; }

/* Step 6 chips & generate CTA */
.summary-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 22px; }
.chip {
  display: inline-flex; align-items: center;
  padding: 6px 12px; border-radius: 999px;
  background: var(--teal-100); color: var(--teal-900);
  font-size: 0.82rem; font-weight: 600; letter-spacing: 0.01em;
}
.chip.ind { background: var(--magenta-100); color: var(--magenta-700); }
.chip.grn { background: #E6F4EA; color: #1A6E3E; }
.chip.amb { background: var(--gold-100); color: #8A6A1F; }

.generate-cta {
  display: flex; flex-direction: column; align-items: center; gap: 12px;
  padding: 28px 18px; margin: 18px 0 22px;
  background: linear-gradient(180deg, var(--teal-50), var(--paper));
  border: 1px solid var(--line); border-radius: var(--radius);
  text-align: center;
}
.btn-large { font-size: 1.05rem; padding: 14px 28px; min-width: 220px; }
.generate-help { color: var(--ink-500); font-size: 0.88rem; margin: 0; }
.htmx-indicator { display: none; color: var(--ink-500); font-style: italic; font-size: 0.9rem; }
.htmx-request .htmx-indicator { display: inline-block; }
.htmx-request.htmx-indicator { display: inline-block; }

/* Prompt panel (revealed after Generate when logged in) */
.prompt-panel {
  margin: 18px 0 22px;
  padding: 22px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: 0 2px 6px rgba(10,37,64,0.04);
}
.prompt-panel-head {
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 10px; margin-bottom: 8px;
}
.prompt-help { color: var(--ink-500); font-size: 0.92rem; margin: 4px 0 14px; }
.prompt-textarea {
  width: 100%; min-height: 380px; padding: 14px;
  border: 1px solid var(--line); border-radius: var(--radius-sm);
  font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;
  font-size: 0.85rem; line-height: 1.5; color: var(--ink-900);
  background: var(--paper);
  resize: vertical; box-sizing: border-box;
}
.prompt-meta { color: var(--ink-400); font-size: 0.8rem; margin: 8px 0 0; text-align: right; }
.copy-btn { white-space: nowrap; }

/* Email gate (anon teacher) */
.email-gate, .email-sent {
  margin: 18px 0 22px;
  padding: 26px;
  background: var(--card);
  border: 1px solid var(--magenta-100);
  border-radius: var(--radius);
  box-shadow: 0 2px 6px rgba(229,26,111,0.05);
}
.email-gate-lead, .email-sent-lead {
  color: var(--ink-700); font-size: 0.98rem; line-height: 1.55;
  margin: 0 0 18px;
}
.email-gate-form { display: flex; flex-direction: column; gap: 10px; }
.email-gate-form label { font-weight: 600; color: var(--ink-900); font-size: 0.9rem; }
.email-gate-form input[type="email"] {
  padding: 12px 14px; border: 1px solid var(--line); border-radius: var(--radius-sm);
  font-size: 1rem; font-family: var(--font-body);
}
.email-gate-form input[type="email"]:focus {
  outline: 2px solid var(--teal-400); outline-offset: 1px; border-color: var(--teal-500);
}
.email-gate-form .checkbox-row {
  display: flex; align-items: flex-start; gap: 10px; font-weight: 400;
  color: var(--ink-700); font-size: 0.9rem; margin: 4px 0;
}
.email-gate-form .checkbox-row input { margin-top: 4px; }
.email-gate-form .btn { align-self: flex-start; margin-top: 6px; }
.email-gate-fineprint {
  color: var(--ink-400); font-size: 0.8rem; margin: 14px 0 0;
}
.email-gate-fineprint a { color: var(--ink-500); text-decoration: underline; }
.email-sent-tip { color: var(--ink-500); font-size: 0.9rem; margin: 8px 0 0; }
.form-error {
  background: #FBE8E8; color: #9B1C1C; border: 1px solid #F5C6C6;
  padding: 10px 14px; border-radius: var(--radius-sm); font-size: 0.9rem; margin-bottom: 12px;
}

/* Soft (de-emphasised) checkbox row used below primary button on email gate */
.email-gate-form .checkbox-row-soft {
  margin-top: 14px;
  font-size: 0.82rem;
  color: var(--ink-500);
  font-weight: 400;
}
.email-gate-form .checkbox-row-soft input { margin-top: 3px; }
.email-gate-form .btn { align-self: flex-start; margin-top: 10px; }

/* ============================================================
   Week 8 - My recent prompts collapsible + viewer modal
   ============================================================ */
.my-prompts-details {
  max-width: 760px; margin: 0 auto 16px;
  background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius); overflow: hidden;
}
.my-prompts-summary {
  display: flex; align-items: center; gap: 10px;
  padding: 12px 18px; cursor: pointer; list-style: none;
  font-weight: 500; color: var(--ink-900); font-size: 0.95rem;
  user-select: none;
}
.my-prompts-summary::-webkit-details-marker { display: none; }
.my-prompts-summary:hover { background: var(--paper); }
.my-prompts-summary .mp-icon { color: var(--gold-500); font-size: 1.1rem; }
.my-prompts-summary .mp-chev {
  margin-left: auto; transition: transform 0.15s ease;
  color: var(--ink-400); font-size: 0.85rem;
}
.my-prompts-details[open] .my-prompts-summary .mp-chev { transform: rotate(180deg); }
.my-prompts-body { padding: 8px 12px 14px; border-top: 1px solid var(--line); }
.mp-loading, .mp-empty { color: var(--ink-500); font-size: 0.9rem; text-align: center; padding: 14px 0; margin: 0; }
.mp-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 6px; }
.mp-row { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: var(--radius-sm); transition: background 0.12s ease; }
.mp-row:hover { background: var(--paper); }
.mp-row-starred { background: rgba(217, 164, 65, 0.06); }
.mp-row-starred:hover { background: rgba(217, 164, 65, 0.12); }
.mp-star-btn {
  background: transparent; border: 0; cursor: pointer;
  font-size: 1.2rem; color: var(--ink-400);
  padding: 4px 6px; border-radius: 4px;
  transition: color 0.12s ease, background 0.12s ease;
}
.mp-star-btn:hover { color: var(--gold-500); background: rgba(217, 164, 65, 0.1); }
.mp-star-btn.is-on { color: var(--gold-500); }
.mp-row-meta { flex: 1; min-width: 0; }
.mp-row-title { font-weight: 500; color: var(--ink-900); font-size: 0.92rem; }
.mp-row-sub { color: var(--ink-500); font-size: 0.78rem; margin-top: 2px; }
.mp-view-btn {
  background: var(--card); border: 1px solid var(--line); color: var(--ink-700);
  padding: 6px 14px; border-radius: var(--radius-sm);
  font-size: 0.82rem; font-weight: 500; cursor: pointer;
  transition: background 0.12s ease, border-color 0.12s ease;
}
.mp-view-btn:hover { background: var(--teal-50); border-color: var(--teal-500); color: var(--teal-700); }

.prompt-modal-backdrop {
  position: fixed; inset: 0;
  background: rgba(10, 37, 64, 0.5);
  display: flex; align-items: center; justify-content: center;
  padding: 20px; z-index: 9999;
  animation: mp-fade-in 0.15s ease;
}
@keyframes mp-fade-in { from { opacity: 0; } to { opacity: 1; } }
.prompt-modal {
  background: var(--card); border-radius: var(--radius);
  max-width: 760px; width: 100%; max-height: 90vh; overflow-y: auto;
  padding: 24px; box-shadow: 0 20px 50px rgba(10, 37, 64, 0.25);
}
.prompt-modal-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 14px; margin-bottom: 14px; }
.prompt-modal-title { font-family: var(--font-display); font-size: 1.3rem; color: var(--ink-900); margin: 0; line-height: 1.3; }
.prompt-modal-meta { color: var(--ink-500); font-size: 0.85rem; margin: 4px 0 0; }
.prompt-modal-close { background: transparent; border: 0; cursor: pointer; font-size: 1.6rem; color: var(--ink-500); padding: 0 6px; line-height: 1; }
.prompt-modal-close:hover { color: var(--ink-900); }
.prompt-modal-star-row { margin: 8px 0 16px; }
.mp-star-btn-large { font-size: 0.85rem; padding: 6px 12px; border: 1px solid var(--line); background: var(--paper); color: var(--ink-700); font-weight: 500; }
.mp-star-btn-large:hover { color: var(--gold-500); border-color: var(--gold-500); }
.mp-star-btn-large.is-on { color: var(--gold-500); border-color: var(--gold-500); background: rgba(217, 164, 65, 0.08); }
.prompt-modal-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 14px; align-items: center; }
.btn-danger-soft {
  background: transparent; border: 1px solid #E5C0C0; color: #9B1C1C;
  padding: 8px 14px; border-radius: var(--radius-sm);
  font-size: 0.88rem; font-weight: 500; cursor: pointer;
  margin-left: auto;
}
.btn-danger-soft:hover { background: #FBE8E8; border-color: #C77777; }

/* Week 8 tweak: when "My recent prompts" sits BELOW the wizard, give it top breathing room */
.builder-wrap > .my-prompts-details { margin-top: 24px; margin-bottom: 0; }

/* Week 9: nav sign-out button (logged-in users only) */
.nav-signout-form { display: inline; margin: 0; padding: 0; }
.nav-signout-btn {
  background: transparent; border: 0; cursor: pointer;
  color: var(--ink-500); font-size: 0.85rem; font-weight: 400;
  padding: 8px 12px; margin-left: 8px; font-family: inherit;
}
.nav-signout-btn:hover { color: var(--ink-900); text-decoration: underline; }

/* Week 9: branded 404 / 500 error pages */
.error-wrap {
  max-width: 640px; margin: 80px auto; padding: 0 20px;
  text-align: center;
}
.error-card {
  background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 48px 32px;
}
.error-code {
  font-family: var(--font-display); font-size: 4rem; font-weight: 600;
  color: var(--teal-500); margin: 0 0 4px; letter-spacing: -0.02em; line-height: 1;
}
.error-title {
  font-family: var(--font-display); font-size: 1.6rem; color: var(--ink-900);
  margin: 0 0 12px; line-height: 1.2;
}
.error-lead {
  color: var(--ink-700); font-size: 1rem; line-height: 1.55;
  margin: 0 0 24px; max-width: 460px; margin-left: auto; margin-right: auto;
}
.error-actions { display: flex; justify-content: center; gap: 12px; flex-wrap: wrap; }

/* Week 9: Help / FAQ page spacing */
.doc-page .faq-item { margin: 28px 0; padding-bottom: 24px; border-bottom: 1px solid var(--line); }
.doc-page .faq-item:last-child { border-bottom: 0; }
.doc-page .faq-item h2 { font-size: 1.15rem; color: var(--ink-900); margin: 0 0 8px; }
.doc-page .faq-item p, .doc-page .faq-item ol, .doc-page .faq-item ul { color: var(--ink-700); line-height: 1.6; }
.doc-page .faq-item ol, .doc-page .faq-item ul { padding-left: 20px; }

/* Week 9: first-visit onboarding overlay on Step 1 */
.onboarding-overlay {
  position: fixed; inset: 0;
  background: rgba(10, 37, 64, 0.55);
  display: flex; align-items: center; justify-content: center;
  padding: 20px; z-index: 10000;
  animation: ob-fade 0.18s ease;
}
@keyframes ob-fade { from { opacity: 0; } to { opacity: 1; } }
.onboarding-card {
  background: var(--card); border-radius: var(--radius);
  max-width: 520px; width: 100%;
  padding: 28px 32px;
  box-shadow: 0 24px 60px rgba(10, 37, 64, 0.3);
}
.onboarding-card h2 {
  font-family: var(--font-display); font-size: 1.4rem; color: var(--ink-900);
  margin: 0 0 12px;
}
.onboarding-card p { color: var(--ink-700); line-height: 1.55; margin: 0 0 14px; }
.onboarding-card ul { padding-left: 20px; color: var(--ink-700); line-height: 1.6; margin: 0 0 18px; }
.onboarding-card .btn { width: 100%; }

/* Week 10: form input error state */
.form-input-error { border: 2px solid #9B1C1C !important; background: #FFF5F5 !important; padding: 9px 11px !important; }
.form-input-error:focus { outline: 2px solid #9B1C1C !important; outline-offset: 1px; }

/* Week 10: Step 1 hero text above the wizard */
.builder-hero { max-width: 760px; margin: 0 auto 28px; text-align: center; padding: 12px 16px 0; }
.builder-hero-title {
  font-family: var(--font-display); font-weight: 500;
  font-size: clamp(1.6rem, 4vw, 2.4rem);
  color: var(--ink-900); margin: 0 0 12px; line-height: 1.18;
}
.builder-hero-title em {
  font-style: italic; color: var(--magenta-600); font-weight: 500;
}
.builder-hero-title .hero-teal { color: var(--teal-700); font-style: italic; font-weight: 500; }
.builder-hero-lead {
  font-size: 0.98rem; color: var(--ink-500); line-height: 1.55;
  max-width: 580px; margin: 0 auto;
}

/* Week 10: nav mobile fixes + signout icon spacing + footer logo size */
.nav-cta { white-space: nowrap; }
.nav-signout-btn { display: inline-flex; align-items: center; }

/* Footer logo: smaller than nav logo */
.foot-brand .mark { width: 28px; height: 28px; }
.foot-brand .brand-name { font-size: 0.92rem; }

/* Tighter nav on smaller widths */
@media (max-width: 700px) {
  .nav-link-quiet { display: none; }
  .nav-cta { padding: 6px 12px; font-size: 0.82rem; }
  .nav-cta svg { display: none; }
  .nav-signout-btn { padding: 6px 8px; font-size: 0.78rem; }
}

/* Week 10 v2: footer brand — coherent shrink (icon + text together) */
.foot-brand { font-size: 0.78rem; gap: 6px; }
.foot-brand .mark { width: 22px; height: 22px; }
.foot-brand .brand-name { font-size: 0.95rem; letter-spacing: 0.01em; }
.foot-brand .kit-pill { font-size: 0.7rem; padding: 1px 6px; }

/* Week 10 v3: footer brand — middle ground (smaller than nav, but still readable) */
.foot-brand { font-size: 0.9rem; gap: 8px; }
.foot-brand .mark { width: 30px; height: 30px; }
.foot-brand .brand-name { font-size: 1.05rem; letter-spacing: 0.02em; line-height: 1; }
.foot-brand .kit-pill { font-size: 0.78rem; padding: 2px 8px; vertical-align: 2px; }

/* Week 10 v4: tighter mobile nav — hide CTA on small screens entirely */
@media (max-width: 760px) {
  .nav-link-quiet { display: none; }
.nav-inner { gap: 12px; }
  .nav-signout-btn { padding: 6px 8px; font-size: 0.8rem; }
}
@media (max-width: 480px) {
  .brand-name { font-size: 1.55rem; }
  .brand-name .kit-pill { font-size: 0.7rem; padding: 3px 9px; }
.brand-name .beta-badge {
  font-family: var(--font-body); font-weight: 600;
  font-size: 11px; letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--teal-700); background: transparent;
  border: 1px solid var(--teal-700);
  padding: 3px 8px; border-radius: 6px;
  position: relative; top: 1px;
  margin-left: 2px;
}
@media (max-width: 560px) {
  .brand-name .beta-badge {
    font-size: 10px;
    padding: 2px 6px;
    letter-spacing: 0.14em;
  }
}

  .brand .mark { width: 32px; height: 32px; }
}

/* Week 10 v5: footer layout — mobile-first, properly stacked */
.foot-inner {
  display: flex; flex-wrap: wrap; align-items: center;
  gap: 16px 24px; justify-content: space-between;
}
.foot-tagline { color: var(--ink-500); font-size: 0.88rem; }
.foot-nav { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.foot-nav a { color: var(--ink-700); text-decoration: none; font-size: 0.88rem; }
.foot-nav a:hover { color: var(--teal-700); text-decoration: underline; }
.foot-sep { color: var(--ink-400); }
@media (max-width: 600px) {
  .foot-inner { flex-direction: column; align-items: flex-start; gap: 12px; text-align: left; }
  .foot-nav { gap: 8px; }
}

/* Week 10 v6: bullet-proof mobile nav hide (the earlier rule was getting overridden) */
@media (max-width: 760px) {
.nav-link-quiet { display: none !important; }
}

/* Week 10 v7: keep "Prompt" CTA visible on mobile, just smaller */
@media (max-width: 480px) {
  .nav-cta { padding: 5px 10px; font-size: 0.78rem; gap: 4px; }
  .nav-cta svg { width: 10px; height: 10px; }
  .nav-inner { gap: 8px; }
  .nav-links { gap: 8px; }
}

/* ============================================================
   Wizard backdrop (gradient + slow drift) — Step 1-6 only.
   Scoped via body:has(.builder-wrap) so marketing pages stay flat.
   ============================================================ */

body:has(.builder-wrap) {
  position: relative;
  background: var(--paper);
  overflow-x: hidden;
}

body:has(.builder-wrap)::before {
  content: "";
  position: fixed;
  inset: -10%;
  z-index: -1;
  background:
    radial-gradient(ellipse 60% 50% at 15% 18%, rgba(22, 192, 201, 0.18) 0%, transparent 60%),
    radial-gradient(ellipse 55% 50% at 85% 22%, rgba(236, 204, 138, 0.18) 0%, transparent 60%),
    radial-gradient(ellipse 60% 50% at 50% 90%, rgba(229, 26, 111, 0.13) 0%, transparent 60%),
    var(--paper);
  animation: capskit-drift 45s ease-in-out infinite alternate;
  will-change: background-position;
}

@keyframes capskit-drift {
  0%   { background-position: 0% 0%, 100% 0%, 50% 100%, 0 0; }
  50%  { background-position: 30% 20%, 70% 10%, 30% 80%, 0 0; }
  100% { background-position: 5% 30%, 95% 35%, 60% 95%, 0 0; }
}

@media (prefers-reduced-motion: reduce) {
  body:has(.builder-wrap)::before { animation: none; }
}

/* Step accent: 3px top border on the builder card, cycling per step.
   Default is teal; per-step overrides set in builder/_step_nav.html via the body class on data-step. */
.builder-wrap .builder-card { border-top: 3px solid var(--teal-500); }
.builder-wrap.step-2 .builder-card,
.builder-wrap[data-step="2"] .builder-card { border-top-color: var(--magenta-500); }
.builder-wrap.step-3 .builder-card,
.builder-wrap[data-step="3"] .builder-card { border-top-color: var(--gold-500); }
.builder-wrap.step-4 .builder-card,
.builder-wrap[data-step="4"] .builder-card { border-top-color: var(--teal-500); }
.builder-wrap.step-5 .builder-card,
.builder-wrap[data-step="5"] .builder-card { border-top-color: var(--magenta-500); }
.builder-wrap.step-6 .builder-card,
.builder-wrap[data-step="6"] .builder-card { border-top-color: var(--gold-500); }

/* "Step N of 6" pill picks up the same accent */
.builder-wrap .step-pill { background: var(--teal-100); color: var(--teal-700); }
.builder-wrap[data-step="2"] .step-pill { background: var(--magenta-100); color: var(--magenta-700); }
.builder-wrap[data-step="3"] .step-pill { background: var(--gold-100); color: #8A6A1F; }
.builder-wrap[data-step="4"] .step-pill { background: var(--teal-100); color: var(--teal-700); }
.builder-wrap[data-step="5"] .step-pill { background: var(--magenta-100); color: var(--magenta-700); }
.builder-wrap[data-step="6"] .step-pill { background: var(--gold-100); color: #8A6A1F; }

/* Tiny softer card shadow so the white card sits properly on the gradient */
.builder-wrap .builder-card {
  box-shadow: 0 1px 3px rgba(10, 37, 64, 0.04), 0 8px 28px rgba(10, 37, 64, 0.06);
}

/* ============================================================
   Step 5: rich pick cards with icons + stronger selected state
   ============================================================ */
.pick-card-rich {
  position: relative;
  display: flex !important;
  flex-direction: column;
  align-items: flex-start;
  gap: 6px;
  padding: 14px 16px !important;
  border: 1.5px solid var(--line);
  background: var(--card);
  border-radius: var(--radius-sm);
  text-align: left;
  cursor: pointer;
  transition: all 0.15s ease;
}
.pick-card-rich:hover {
  border-color: var(--teal-400);
  background: var(--teal-50);
  transform: translateY(-1px);
  box-shadow: 0 6px 14px rgba(10,37,64,0.08);
}
.pick-card-rich.is-selected {
  border-color: var(--teal-600);
  background: linear-gradient(135deg, var(--teal-50) 0%, rgba(212, 242, 244, 0.55) 100%);
  box-shadow: 0 4px 12px rgba(17, 154, 166, 0.15);
}
.pick-card-rich .pick-icon {
  font-size: 1.4rem;
  line-height: 1;
  margin-bottom: 2px;
}
.pick-card-rich .pick-label {
  font-weight: 600; font-size: 0.92rem; color: var(--ink-900);
}
.pick-card-rich .pick-desc {
  font-size: 0.78rem; color: var(--ink-500); line-height: 1.4;
}
.pick-card-rich .pick-check {
  position: absolute; top: 8px; right: 10px;
  width: 22px; height: 22px;
  background: var(--teal-600); color: #fff;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.85rem; font-weight: 700;
  box-shadow: 0 2px 6px rgba(17, 154, 166, 0.4);
}

/* Step 5: "More options" details summary — kill the default ndash marker */
.settings-extra-summary {
  list-style: none;
  cursor: pointer;
  padding: 12px 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--paper-2);
  font-weight: 500;
  color: var(--ink-700);
  user-select: none;
  display: flex; align-items: center; gap: 8px;
  transition: background 0.12s ease;
}
.settings-extra-summary::-webkit-details-marker { display: none; }
.settings-extra-summary::marker { display: none; content: ""; }
.settings-extra-summary:hover { background: var(--teal-50); color: var(--teal-700); }
.settings-extra-summary .chev {
  display: inline-block;
  transition: transform 0.18s ease;
  color: var(--teal-600);
  font-size: 0.7rem;
}
details[open] > .settings-extra-summary .chev { transform: rotate(90deg); }

/* Section subhead spacing on Step 5 */
.builder-card-wide .builder-subhead {
  font-family: var(--font-display);
  font-size: 1.05rem;
  color: var(--ink-900);
  margin-bottom: 12px;
}


/* Stronger hide of native details marker (Firefox + Safari quirks) */
details summary { list-style: none !important; }
details summary::-webkit-details-marker { display: none !important; }
details summary::marker { content: none !important; display: none !important; }

/* Style the language code badges (replacement for flag emoji that some browsers refuse to render) */
.pick-card-rich .pick-icon {
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--teal-100); color: var(--teal-700);
  font-size: 0.72rem; font-weight: 700; letter-spacing: 0.04em;
  padding: 4px 8px; border-radius: 4px;
  min-height: 24px;
}


/* Step 5 compact pick-card override (Week 11 v2 — much shorter cards) */
.pick-card-rich {
  padding: 10px 12px !important;
  gap: 4px !important;
  flex-direction: row !important;
  align-items: center !important;
  min-height: 0;
}
.pick-card-rich .pick-icon {
  font-size: 0.7rem !important; padding: 3px 6px !important;
  min-height: 0 !important; line-height: 1.2;
  flex-shrink: 0;
}
.pick-card-rich .pick-label { font-size: 0.88rem; font-weight: 600; }
.pick-card-rich .pick-check { top: 6px; right: 8px; width: 18px; height: 18px; font-size: 0.72rem; }

/* Step 5 v2: button-style More options trigger (replaces <details>) */
.more-options-toggle {
  background: transparent; border: 0; cursor: pointer;
  display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 0; margin-top: 22px;
  color: var(--teal-700); font-weight: 600; font-size: 0.95rem;
  font-family: inherit;
  transition: color 0.15s ease;
}
.more-options-toggle:hover { color: var(--magenta-600); }
.more-options-plus {
  display: inline-flex; align-items: center; justify-content: center;
  width: 22px; height: 22px;
  border: 1.5px solid currentColor; border-radius: 50%;
  font-weight: 600; font-size: 0.95rem; line-height: 1;
}
.more-options-body { display: none; padding-top: 6px; }
.more-options-body.is-open { display: block; }

/* Step 5 v3: iOS-style toggle switches */
.toggle-row {
  display: flex; align-items: center; justify-content: space-between;
  gap: 14px; padding: 12px 0;
  border-bottom: 1px solid var(--line);
  cursor: pointer; user-select: none;
}
.toggle-row:last-child { border-bottom: 0; }
.toggle-row:hover .toggle-slider { box-shadow: 0 0 0 4px rgba(17,154,166,0.06); }
.toggle-text { color: var(--ink-700); font-size: 0.92rem; line-height: 1.4; flex: 1; }
.toggle-switch { position: relative; flex-shrink: 0; width: 44px; height: 24px; }
.toggle-switch input {
  position: absolute; opacity: 0; width: 100%; height: 100%; margin: 0; cursor: pointer;
  z-index: 2;
}
.toggle-slider {
  position: absolute; inset: 0; background: var(--ink-400); border-radius: 999px;
  transition: background 0.18s ease;
}
.toggle-slider::before {
  content: ""; position: absolute; top: 3px; left: 3px;
  width: 18px; height: 18px; background: #fff; border-radius: 50%;
  transition: transform 0.18s ease;
  box-shadow: 0 1px 3px rgba(10,37,64,0.2);
}
.toggle-switch input:checked + .toggle-slider { background: var(--teal-600); }
.toggle-switch input:checked + .toggle-slider::before { transform: translateX(20px); }
.toggle-switch input:focus-visible + .toggle-slider { box-shadow: 0 0 0 3px rgba(17,154,166,0.35); }

/* Step progress indicator (6 nodes with connectors) */
.step-progress { margin: 0 0 28px; }
.step-progress-list {
  list-style: none; padding: 0; margin: 0;
  display: flex; align-items: flex-start; justify-content: space-between;
  gap: 0; position: relative;
}
.step-node {
  flex: 1; position: relative;
  display: flex; align-items: center; justify-content: center;
}
.step-node:not(:last-child)::after {
  content: ""; position: absolute; top: 14px; left: 50%; right: -50%;
  height: 2px; background: var(--line); z-index: 0;
}
.step-node.is-done:not(:last-child)::after { background: var(--teal-500); }

.step-node-link, .step-node-current, .step-node-future {
  position: relative; z-index: 1;
  display: flex; flex-direction: column; align-items: center; gap: 5px;
  text-decoration: none; padding: 0; cursor: default;
}
.step-node-link { cursor: pointer; }
.step-node-link:hover .step-node-circle { transform: scale(1.08); }
.step-node-link:hover .step-node-label { color: var(--teal-700); }

.step-node-circle {
  display: inline-flex; align-items: center; justify-content: center;
  width: 30px; height: 30px;
  border-radius: 50%;
  font-weight: 600; font-size: 0.82rem;
  background: var(--card); border: 2px solid var(--line);
  color: var(--ink-400);
  transition: all 0.18s ease;
}
.step-node-label {
  font-size: 0.72rem; font-weight: 500; color: var(--ink-400);
  white-space: nowrap; transition: color 0.18s ease;
}
.step-node.is-done .step-node-circle {
  background: var(--teal-500); border-color: var(--teal-500); color: #fff;
}
.step-node.is-done .step-node-label { color: var(--teal-700); }
.step-node.is-current .step-node-circle {
  background: var(--magenta-600); border-color: var(--magenta-600); color: #fff;
  width: 36px; height: 36px; font-size: 0.92rem;
  box-shadow: 0 0 0 4px rgba(229, 26, 111, 0.12);
}
.step-node.is-current .step-node-label { color: var(--ink-900); font-weight: 600; }
.step-node.is-upcoming .step-node-circle { background: var(--card); border-color: var(--line); color: var(--ink-400); }
.step-node.is-skipped .step-node-label,
.step-node.is-skipped .step-node-circle {
  text-decoration: line-through;
  opacity: 0.5;
}

@media (max-width: 600px) {
  .step-node-label { display: none; }
  .step-node-circle { width: 26px; height: 26px; font-size: 0.78rem; }
  .step-node.is-current .step-node-circle { width: 32px; height: 32px; }
}

/* Step 6 email gate redesign: layered sample-blur + floating card */
.gate-stage {
  position: relative;
  margin: 18px 0 22px;
  min-height: 460px;
}

/* Blurred sample prompt sitting behind */
.gate-blurred {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, var(--paper) 0%, var(--paper-2) 100%);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 30px;
  overflow: hidden;
  filter: blur(7px) saturate(1.05);
  pointer-events: none;
  user-select: none;
  -webkit-user-select: none;
}
.gate-blurred-label {
  font-size: 0.75rem; font-weight: 600;
  color: var(--ink-500); margin-bottom: 14px;
  text-transform: uppercase; letter-spacing: 0.06em;
}
.gate-blurred-prompt {
  font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;
  font-size: 0.78rem; line-height: 1.55; color: var(--ink-700);
  margin: 0; white-space: pre-wrap; word-break: break-word;
}

/* Floating gate card */
.gate-card {
  position: relative;
  max-width: 460px; margin: 36px auto;
  background: #fff;
  border-radius: var(--radius);
  padding: 32px 30px 26px;
  box-shadow:
    0 4px 12px rgba(10, 37, 64, 0.06),
    0 24px 60px rgba(10, 37, 64, 0.18);
  text-align: center;
}
.gate-icon {
  display: inline-flex; align-items: center; justify-content: center;
  width: 56px; height: 56px;
  background: linear-gradient(135deg, var(--teal-100), var(--teal-50));
  color: var(--teal-700);
  border-radius: 50%;
  margin: 0 auto 14px;
}
.gate-title {
  font-family: var(--font-display);
  font-size: 1.5rem; color: var(--ink-900);
  margin: 0 0 8px; line-height: 1.2;
}
.gate-lead {
  color: var(--ink-700); font-size: 0.95rem; line-height: 1.5;
  margin: 0 0 20px;
}
.gate-form { display: flex; flex-direction: column; gap: 10px; text-align: left; }
.gate-label {
  font-size: 0.82rem; font-weight: 600;
  color: var(--ink-900); margin: 0; padding: 0;
}
.gate-form .form-input {
  width: 100%; box-sizing: border-box;
  padding: 11px 14px;
  border: 1.5px solid var(--line); border-radius: var(--radius-sm);
  font-size: 0.95rem; font-family: var(--font-body);
  background: var(--paper);
  transition: border-color 0.15s, background 0.15s;
}
.gate-form .form-input:focus {
  outline: none; border-color: var(--teal-500); background: #fff;
  box-shadow: 0 0 0 3px rgba(22, 192, 201, 0.18);
}
.gate-submit {
  width: 100%; margin-top: 6px; padding: 13px;
  font-size: 1rem; font-weight: 600;
}
.gate-newsletter {
  margin-top: 4px;
  font-size: 0.78rem;
  color: var(--ink-500);
  font-weight: 400;
}
.gate-fineprint {
  margin-top: 16px;
  font-size: 0.78rem;
  color: var(--ink-400);
  text-align: center;
}
.gate-fineprint a { color: var(--ink-500); text-decoration: underline; }

@media (max-width: 600px) {
  .gate-card { padding: 24px 20px 22px; margin: 18px auto; }
  .gate-blurred { padding: 18px; }
  .gate-blurred-prompt { font-size: 0.72rem; }
}

/* Email-sent variant of the gate card */
.gate-card-sent { padding: 30px 28px 26px; }
.gate-card-sent .gate-icon {
  background: linear-gradient(135deg, var(--magenta-100), var(--teal-50));
  color: var(--magenta-700);
}
.gate-sent-tip {
  margin-top: 14px;
  font-size: 0.82rem;
  color: var(--ink-500);
  text-align: center;
}
.gate-sent-tip a { color: var(--teal-700); text-decoration: underline; }

/* Fix Step 6 fancy prompt panel — width, copy button states, AI launchers */
.prompt-panel-fancy {
  margin: 18px 0 22px;
  padding: 24px;
  background: var(--card);
  border-radius: var(--radius);
  border: 1px solid var(--line);
  position: relative;
  overflow: hidden;
}
.prompt-panel-shimmer {
  position: absolute; top: 0; left: -100%;
  width: 100%; height: 4px;
  background: linear-gradient(90deg, transparent, var(--gold-300), transparent);
  animation: prompt-shimmer 1.2s ease-out 1;
}
@keyframes prompt-shimmer { from { left: -100%; } to { left: 100%; } }

.prompt-panel-head {
  display: flex; justify-content: space-between; align-items: flex-start;
  flex-wrap: wrap; gap: 12px; margin-bottom: 6px;
}
.prompt-panel-titlewrap {
  display: flex; align-items: center; gap: 10px;
}
.prompt-panel-spark {
  font-size: 1.3rem; color: var(--gold-500);
  animation: spark-pop 0.6s ease-out 1;
}
@keyframes spark-pop {
  0% { transform: scale(0) rotate(-30deg); opacity: 0; }
  60% { transform: scale(1.2) rotate(10deg); opacity: 1; }
  100% { transform: scale(1) rotate(0); opacity: 1; }
}
.prompt-panel-title {
  font-family: var(--font-display);
  font-size: 1.35rem; color: var(--ink-900);
  margin: 0; line-height: 1.2;
}
.prompt-help { color: var(--ink-500); font-size: 0.92rem; margin: 4px 0 14px; }

.prompt-textarea-fancy {
  width: 100% !important;
  min-height: 380px;
  padding: 16px 18px;
  border: 1px solid var(--line); border-radius: var(--radius-sm);
  font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;
  font-size: 0.85rem; line-height: 1.55; color: var(--ink-900);
  background: var(--paper);
  resize: vertical;
  box-sizing: border-box;
}
.prompt-meta { color: var(--ink-400); font-size: 0.8rem; margin: 8px 0 0; text-align: right; }

/* Copy button two-state */
.copy-btn { white-space: nowrap; min-width: 130px; }
.copy-btn .copy-done { display: none; }
.copy-btn.is-done .copy-default { display: none; }
.copy-btn.is-done .copy-done { display: inline; }
.copy-btn.is-done {
  background: var(--teal-600) !important;
  border-color: var(--teal-700) !important;
}

/* AI launcher buttons */
.prompt-launchers {
  margin-top: 22px; padding-top: 18px;
  border-top: 1px solid var(--line);
}
.prompt-launchers-label {
  font-size: 0.85rem; font-weight: 600; color: var(--ink-700);
  margin: 0 0 10px;
}
.prompt-launchers-row {
  display: flex; flex-wrap: wrap; gap: 10px;
}
.ai-launcher {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 9px 16px; border-radius: 999px;
  background: var(--card);
  border: 1.5px solid var(--line);
  color: var(--ink-700);
  font-size: 0.88rem; font-weight: 500;
  text-decoration: none;
  transition: all 0.15s ease;
}
.ai-launcher:hover {
  background: var(--paper);
  border-color: var(--teal-500);
  color: var(--teal-700);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(10,37,64,0.06);
}
.ai-launcher-icon {
  display: inline-flex; align-items: center; justify-content: center;
  width: 22px; height: 22px;
  border-radius: 50%;
  background: var(--paper-2);
  font-size: 0.78rem; font-weight: 700;
  color: var(--ink-700);
}
.ai-chatgpt .ai-launcher-icon { background: #10a37f; color: #fff; }
.ai-claude .ai-launcher-icon { background: #d97757; color: #fff; }
.ai-gemini .ai-launcher-icon { background: linear-gradient(135deg, #4285F4, #9B72F2); color: #fff; }
.prompt-launchers-tip {
  margin: 12px 0 0;
  font-size: 0.78rem; color: var(--ink-400);
}


/* AI accuracy callout (Help + Terms) */
.accuracy-callout {
  background: linear-gradient(180deg, #FAEEDA 0%, #FFFCF6 100%);
  border: 1px solid #ECCC8A;
  border-left: 4px solid var(--gold-500);
  border-radius: var(--radius-sm);
  padding: 16px 20px;
  margin: 14px 0 18px;
  color: var(--ink-700);
  font-size: 0.95rem;
  line-height: 1.55;
}
.accuracy-callout strong {
  display: block;
  color: var(--ink-900);
  font-size: 1rem;
  margin-bottom: 6px;
}
.accuracy-callout p { margin: 0 0 8px; color: var(--ink-700); }
.accuracy-callout p:last-child { margin-bottom: 0; }


/* Step 4 v2 — recommended/other groups + visual polish */
.format-group-label {
  font-size: 0.85rem; color: var(--ink-500);
  margin: 14px 0 8px;
}
.format-group-label strong { color: var(--teal-700); }

.more-formats-toggle {
  background: transparent; border: 0; cursor: pointer;
  display: inline-flex; align-items: center; gap: 8px;
  padding: 12px 0; margin-top: 14px;
  color: var(--teal-700); font-weight: 600; font-size: 0.92rem;
  font-family: inherit;
  transition: color 0.15s ease;
}
.more-formats-toggle:hover { color: var(--magenta-600); }
.more-formats-plus {
  display: inline-flex; align-items: center; justify-content: center;
  width: 22px; height: 22px;
  border: 1.5px solid currentColor; border-radius: 50%;
  font-weight: 600; font-size: 0.95rem; line-height: 1;
}
.more-formats-body { margin-top: 6px; }

/* Step 4 card visual polish */
.format-card {
  position: relative;
  display: flex; flex-direction: column;
  gap: 8px;
  padding: 14px 16px;
  background: var(--card);
  border: 1.5px solid var(--line);
  border-radius: var(--radius-sm);
  margin-bottom: 10px;
  transition: border-color 0.15s, background 0.15s, box-shadow 0.15s, transform 0.12s;
  min-height: 76px;
}
.format-card:hover:not(.is-selected) {
  border-color: var(--teal-400);
  box-shadow: 0 4px 12px rgba(10, 37, 64, 0.06);
  transform: translateY(-1px);
}
.format-card.is-selected {
  border-color: var(--teal-600);
  background: linear-gradient(135deg, var(--teal-50) 0%, rgba(212, 242, 244, 0.55) 100%);
  box-shadow: 0 4px 12px rgba(17, 154, 166, 0.12);
}
.format-card.is-selected .check-pill-btn {
  background: var(--teal-600); color: #fff; border-color: var(--teal-600);
}

/* Step 4: collapsed-by-default for [hidden] on .block-list (display rules override hidden by default) */
.block-list[hidden] { display: none !important; }

/* Step 4: kill the dash on Pick sub-types summary */
.block-card details summary { list-style: none; cursor: pointer; }
.block-card details summary::-webkit-details-marker { display: none !important; }
.block-card details summary::marker { content: none !important; display: none !important; }
.block-card details > summary {
  font-size: 0.78rem; color: var(--teal-700);
  font-weight: 500; padding: 6px 10px;
  display: inline-flex; align-items: center; gap: 4px;
  border-radius: 4px;
  transition: background 0.12s;
}
.block-card details > summary:hover { background: var(--teal-50); }
.block-card details > summary::before {
  content: "+"; display: inline-block;
  font-weight: 600; font-size: 0.95rem;
  width: 14px; text-align: center;
  transition: transform 0.18s;
}
.block-card details[open] > summary::before { content: "−"; }


/* ============================================================
   Step 4 redesign — accordion header + chip sub-types + fade-out
   Replaces the old .block-card / .more-formats-toggle styling for Step 4.
   ============================================================ */

/* Format card */
.fmt-card {
  background: var(--card);
  border: 1.5px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  margin-bottom: 10px;
  transition: border-color 0.15s, background 0.15s, box-shadow 0.15s, transform 0.12s;
}
.fmt-card:hover:not(.is-selected) {
  border-color: var(--teal-400);
  box-shadow: 0 4px 12px rgba(10, 37, 64, 0.06);
  transform: translateY(-1px);
}
.fmt-card.is-selected {
  border-color: var(--teal-600);
  background: linear-gradient(135deg, var(--teal-50) 0%, rgba(212, 242, 244, 0.55) 100%);
  box-shadow: 0 4px 12px rgba(17, 154, 166, 0.12);
}

.fmt-card-head {
  display: flex; align-items: center; gap: 12px;
}

.fmt-checkbox {
  flex-shrink: 0;
  width: 26px; height: 26px;
  background: var(--card);
  border: 1.5px solid var(--line);
  border-radius: 5px;
  cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center;
  color: transparent;
  font-weight: 700; font-size: 0.9rem;
  transition: all 0.15s;
}
.fmt-checkbox:hover { border-color: var(--teal-500); }
.fmt-checkbox.is-on {
  background: var(--teal-600); border-color: var(--teal-600); color: #fff;
}

.fmt-icon {
  flex-shrink: 0;
  font-size: 1rem;
  line-height: 1;
}

.fmt-text { flex: 1; min-width: 0; }
.fmt-name {
  font-weight: 600; color: var(--ink-900);
  font-size: 0.95rem;
}
.fmt-desc {
  font-size: 0.78rem; color: var(--ink-500);
  margin-top: 2px;
}

.fmt-count {
  flex-shrink: 0;
  font-size: 0.75rem; color: var(--ink-400);
  white-space: nowrap;
}

/* Sub-type chip row */
.fmt-subtype-chips {
  list-style: none; padding: 12px 0 4px 38px; margin: 8px 0 0;
  display: flex; flex-wrap: wrap; gap: 6px;
  border-top: 1px solid rgba(17, 154, 166, 0.18);
}
.fmt-chip {
  background: var(--card);
  border: 1px solid var(--line);
  color: var(--ink-700);
  font-size: 0.78rem; font-weight: 500;
  padding: 5px 12px;
  border-radius: 999px;
  cursor: pointer;
  transition: all 0.12s;
  display: inline-flex; align-items: center; gap: 4px;
  font-family: inherit;
}
.fmt-chip:hover { border-color: var(--teal-500); color: var(--teal-700); }
.fmt-chip.is-on {
  background: var(--teal-600); border-color: var(--teal-600); color: #fff;
}
.fmt-chip-tick { font-weight: 700; font-size: 0.78rem; }

/* Accordion: Other formats — same palette as the format cards (no magenta clash with CTA) */
.fmt-other-wrap { margin-top: 18px; position: relative; }
.fmt-accordion-header {
  display: flex; justify-content: space-between; align-items: center;
  width: 100%;
  background: var(--card);
  border: 1.5px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 14px 18px;
  cursor: pointer;
  font-family: inherit;
  font-size: 0.92rem; font-weight: 600;
  color: var(--ink-900);
  transition: background 0.15s, border-color 0.15s, transform 0.12s;
}
.fmt-accordion-header:hover {
  background: var(--teal-50);
  border-color: var(--teal-500);
  color: var(--teal-700);
  transform: translateY(-1px);
}
.fmt-accordion-label { display: inline-flex; align-items: center; gap: 6px; }
.fmt-accordion-count { color: var(--ink-500); font-weight: 500; font-size: 0.85rem; }
.fmt-accordion-chevron {
  display: inline-flex; align-items: center;
  color: var(--ink-500);
  transition: transform 0.2s ease;
}
.fmt-other-wrap[data-collapsed="false"] .fmt-accordion-chevron {
  transform: rotate(180deg);
  color: var(--teal-700);
}

.fmt-accordion-body {
  position: relative;
  overflow: hidden;
  transition: max-height 0.32s cubic-bezier(0.4, 0, 0.2, 1);
}
.fmt-other-wrap[data-collapsed="true"] .fmt-accordion-body {
  max-height: 70px;
  pointer-events: none;
}
.fmt-other-wrap[data-collapsed="false"] .fmt-accordion-body {
  max-height: 4000px;
  pointer-events: auto;
  margin-top: 10px;
}

/* The fade strip — shown when collapsed, hidden when open */
.fmt-fade {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 70px;
  pointer-events: none;
  background: linear-gradient(180deg,
    rgba(251, 249, 245, 0) 0%,
    rgba(251, 249, 245, 0.85) 60%,
    rgba(251, 249, 245, 1) 100%);
  transition: opacity 0.32s;
}
.fmt-other-wrap[data-collapsed="false"] .fmt-fade { opacity: 0; }

/* The body keeps a small padding so cards aren't flush with the header */
.fmt-other-wrap[data-collapsed="false"] .fmt-accordion-body { padding-top: 4px; }

/* Mobile compaction */
@media (max-width: 600px) {
  .fmt-card-head { flex-wrap: wrap; }
  .fmt-count { width: 100%; padding-left: 38px; margin-top: 4px; }
  .fmt-subtype-chips { padding-left: 0; }
}
