/* ==========================================================================
   Chest Tube Simulator microsite — styles.css
   Single stylesheet. Implements the tokens/components in 06-design-system.md.
   System font stack only. No external requests.
   ========================================================================== */

/* ---------- Design tokens ---------- */
:root {
  /* Color */
  --brand: #1D4ED8;
  --brand-strong: #1E40AF;
  --brand-deep: #1E3A8A;
  --ink: #0F172A;
  --body: #1F2937;
  --muted: #475569;
  --muted-soft: #64748B;
  --bg: #FFFFFF;
  --surface: #F6F8FC;
  --surface-2: #EEF3FB;
  --line: #E2E8F0;
  --line-strong: #CBD5E1;
  --alert: #B91C1C;
  --alert-tint: #FEF2F2;
  --teal: #0E7490;
  --focus: #1D4ED8;

  /* Typography */
  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, "Apple Color Emoji", sans-serif;
  --fs-hero: clamp(2.25rem, 5.5vw, 3.5rem);
  --fs-h1: clamp(2rem, 4.5vw, 2.75rem);
  --fs-h2: clamp(1.5rem, 3.2vw, 2rem);
  --fs-h3: 1.25rem;
  --fs-lead: clamp(1.05rem, 1.6vw, 1.25rem);
  --fs-body: 1.0625rem;
  --fs-small: 0.9375rem;

  /* Spacing (8-pt scale) */
  --s1: 4px;
  --s2: 8px;
  --s3: 12px;
  --s4: 16px;
  --s5: 24px;
  --s6: 32px;
  --s7: 48px;
  --s8: 64px;
  --s9: 96px;

  /* Radius / shadow / layout */
  --radius-sm: 8px;
  --radius: 14px;
  --radius-lg: 22px;
  --radius-pill: 999px;
  --shadow-sm: 0 1px 2px rgba(15,23,42,.06), 0 1px 3px rgba(15,23,42,.05);
  --shadow: 0 10px 30px -12px rgba(15,23,42,.18);
  --shadow-card-hover: 0 16px 40px -16px rgba(30,64,175,.28);
  --content-max: 1120px;
  --measure: 68ch;

  --header-h: 64px;
}

/* ---------- Reset / base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html {
  -webkit-text-size-adjust: 100%;
  scroll-padding-top: calc(var(--header-h) + 12px);
  scroll-behavior: smooth;
}
body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: var(--fs-body);
  line-height: 1.6;
  color: var(--body);
  background: var(--bg);
}
img { max-width: 100%; height: auto; display: block; }
svg { display: block; }
ul, ol { margin: 0; padding: 0; }
p { margin: 0 0 var(--s4); }
p:last-child { margin-bottom: 0; }

h1, h2, h3 {
  font-family: var(--font-sans);
  font-weight: 800;
  color: var(--ink);
  line-height: 1.15;
  letter-spacing: -0.01em;
  margin: 0 0 var(--s4);
}
h1 { font-size: var(--fs-hero); }
h2 { font-size: var(--fs-h2); }

.guide-article h1 { font-size: var(--fs-h1); }

/* Card/item titles are NOT real headings (09-page-manifest.json's headingsOutline
   contains only H1/H2 on every page) — styled to read like an h3 without adding
   one to the accessibility/heading tree. */
.card-title {
  font-size: var(--fs-h3);
  font-weight: 700;
  color: var(--ink);
  line-height: 1.25;
  margin: 0;
}

a { color: var(--brand); text-decoration: underline; text-underline-offset: 2px; }
a:hover { color: var(--brand-strong); }

:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
  border-radius: 4px;
}

strong { color: var(--ink); }

/* Skip link (a11y utility, not marketing copy) */
.skip-link {
  position: absolute;
  left: var(--s4);
  top: -60px;
  z-index: 100;
  background: var(--brand);
  color: #fff;
  padding: var(--s3) var(--s5);
  border-radius: var(--radius-sm);
  text-decoration: none;
  font-weight: 600;
  transition: top 160ms ease;
}
.skip-link:focus { top: var(--s4); }

.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border: 0;
}

/* ---------- Layout ---------- */
.wrap {
  max-width: var(--content-max);
  margin-inline: auto;
  padding-inline: var(--s5);
}
.section {
  padding-block: var(--s8);
}
@media (min-width: 1024px) {
  .section { padding-block: var(--s9); }
}
.section-bg      { background: var(--bg); }
.section-surface { background: var(--surface); }
.section-tint2   { background: var(--surface-2); }
.section-deep    { background: var(--brand-deep); color: #fff; }

.section-head { max-width: var(--measure); margin: 0 0 var(--s6); }
.section-head.center { margin-inline: auto; text-align: center; }
.section-head p { color: var(--muted); font-size: var(--fs-lead); }

.measure { max-width: var(--measure); }
.center-col { max-width: var(--measure); margin-inline: auto; text-align: left; }

/* ---------- Buttons & CTAs ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--s2);
  padding: 10px 18px;
  border-radius: var(--radius-pill);
  font-weight: 600;
  font-size: var(--fs-small);
  text-decoration: none;
  line-height: 1.2;
  white-space: nowrap;
  cursor: pointer;
  border: none;
  transition: background-color 160ms ease, color 160ms ease, border-color 160ms ease, transform 160ms ease;
}
.btn-primary { background: var(--brand); color: #fff; }
.btn-primary:hover { background: var(--brand-strong); color: #fff; }
.btn-primary:active { transform: scale(.98); }
.btn-secondary {
  background: transparent;
  color: var(--brand);
  border: 1.5px solid var(--brand);
  text-decoration: none;
}
.btn-secondary:hover { background: var(--surface-2); color: var(--brand-strong); border-color: var(--brand-strong); }
.section-deep .btn-secondary { color: #fff; border-color: rgba(255,255,255,.7); }
.section-deep .btn-secondary:hover { background: rgba(255,255,255,.12); border-color: #fff; }

/* Official App Store badge image, wrapped in <a>. Never restyled/recolored. */
.badge-link { display: inline-block; line-height: 0; border-radius: var(--radius-sm); }
.badge-link img { height: 48px; width: auto; display: block; }
.badge-link.badge-lg img { height: 52px; }
.badge-link.badge-sm img { height: 40px; }

.badge-chip {
  display: inline-flex;
  background: var(--bg);
  padding: var(--s3);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}

.cta-micro {
  display: block;
  margin-top: var(--s3);
  font-size: var(--fs-small);
  color: var(--muted);
  font-weight: 500;
}
.section-deep .cta-micro { color: rgba(255,255,255,.85); }

.cta-group { display: flex; flex-direction: column; align-items: flex-start; gap: 0; }
.cta-group.center { align-items: center; text-align: center; }

.trustline {
  margin-top: var(--s5);
  font-size: var(--fs-small);
  color: var(--muted);
  font-weight: 500;
}

/* ---------- C1: Site header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  height: var(--header-h);
  display: flex;
  align-items: center;
  background: rgba(255,255,255,.9);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
  width: 100%;
}
@supports not (backdrop-filter: blur(1px)) {
  .site-header { background: var(--bg); }
}
.site-header.is-scrolled { box-shadow: var(--shadow-sm); }

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s4);
  width: 100%;
}

.logo {
  display: flex;
  align-items: center;
  gap: var(--s2);
  text-decoration: none;
  color: var(--ink);
  font-weight: 700;
  font-size: clamp(0.875rem, 3.6vw, 1.0625rem);
  flex-shrink: 1;
  min-width: 0;
}
.logo:hover { color: var(--ink); }
.logo img {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-sm);
  flex-shrink: 0;
}
.logo-word { white-space: nowrap; }

.nav-primary {
  display: none;
  align-items: center;
  gap: var(--s6);
  list-style: none;
  margin: 0 var(--s5);
  padding: 0;
}
.nav-primary a {
  color: var(--body);
  text-decoration: none;
  font-weight: 600;
  font-size: var(--fs-small);
  white-space: nowrap;
}
.nav-primary a:hover { color: var(--brand); }

.header-actions { display: flex; align-items: center; gap: var(--s4); flex-shrink: 0; margin-left: auto; }

/* Tight phones: trim the gutters/gaps a touch and let the header button hug its
   text so the logo wordmark + Download button never overflow the viewport. */
@media (max-width: 400px) {
  .wrap { padding-inline: var(--s4); }
  .header-inner { gap: var(--s3); }
  .header-actions .btn { padding: 9px 14px; }
}

@media (min-width: 720px) {
  .nav-primary { display: flex; }
}

/* ---------- C2: Hero ---------- */
.hero { padding-block: var(--s7); }
@media (min-width: 1024px) { .hero { padding-block: var(--s9); } }

.hero-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--s7);
  align-items: center;
}
@media (min-width: 900px) {
  .hero-grid { grid-template-columns: minmax(0,560px) 1fr; gap: var(--s8); }
}

.hero-copy h1 { font-size: var(--fs-hero); }
.hero-lead {
  font-size: var(--fs-lead);
  color: var(--muted);
  max-width: 56ch;
  margin: 0 0 var(--s6);
}
.hero-cta-row { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s5); margin-top: var(--s2); }

.hero-media { display: flex; justify-content: center; }
@media (min-width: 900px) { .hero-media { justify-content: flex-end; } }

/* ---------- Phone / iPad screenshot frame ---------- */
.phone-frame {
  display: inline-block;
  background: var(--bg);
  padding: 6px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  max-width: 100%;
}
.phone-frame img {
  border-radius: var(--radius);
  display: block;
  width: 100%;
  height: auto;
}
.phone-frame.size-hero { width: 100%; max-width: 320px; }
@media (min-width: 480px) { .phone-frame.size-hero { max-width: 340px; } }
@media (min-width: 900px) { .phone-frame.size-hero { max-width: 380px; } }

.phone-frame.size-gallery { width: 100%; max-width: 300px; }
@media (min-width: 480px) { .phone-frame.size-gallery { max-width: 320px; } }

.phone-frame.size-inline { width: 100%; max-width: 320px; margin-inline: auto; }

.tablet-frame {
  display: inline-block;
  background: var(--bg);
  padding: 6px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  width: 100%;
  max-width: 420px;
}
@media (min-width: 900px) { .tablet-frame { max-width: 520px; } }
.tablet-frame img { border-radius: var(--radius); display: block; width: 100%; height: auto; }

/* ---------- C3: Trust strip ---------- */
.trust-strip { background: var(--surface-2); padding-block: var(--s6); }
.trust-list {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--s6) var(--s7);
  margin: 0;
  padding: 0;
}
.trust-item {
  display: flex;
  align-items: center;
  gap: var(--s2);
  font-weight: 600;
  font-size: var(--fs-small);
  color: var(--ink);
  white-space: nowrap;
}
.icon { width: 24px; height: 24px; flex-shrink: 0; color: var(--brand); }
.icon-teal { color: var(--teal); }

/* ---------- Cinematic 3D showcase ---------- */
.cinematic-showcase {
  padding-block: var(--s8);
  background: #050a13;
  color: #fff;
}

.cinematic-intro {
  display: grid;
  max-width: 850px;
  gap: var(--s3);
  margin-bottom: var(--s6);
}

.cinematic-eyebrow {
  margin: 0;
  color: #7dd3fc;
  font-size: 0.8125rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  line-height: 1.3;
  text-transform: uppercase;
}

.cinematic-intro h2 {
  margin: 0;
  color: #fff;
  font-size: clamp(2rem, 5vw, 3.5rem);
  line-height: 1.03;
}

.cinematic-intro > p:last-child {
  max-width: 720px;
  margin: 0;
  color: #cbd5e1;
  font-size: var(--fs-lead);
  line-height: 1.6;
}

.cinematic-stage {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.28);
  border-radius: var(--radius-sm);
  background: #000;
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.45);
}

.cinematic-stage video {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.cinematic-scrub-track,
.cinematic-scrub-sticky {
  position: relative;
}

.cinematic-showcase.is-scrub-ready .cinematic-scrub-track {
  height: 320svh;
}

.cinematic-showcase.is-scrub-ready .cinematic-scrub-sticky {
  position: sticky;
  top: calc(var(--header-h) + var(--s5));
  display: grid;
  gap: var(--s4);
  max-width: var(--content-max);
  margin-inline: auto;
}

.cinematic-showcase.is-scrub-ready .cinematic-stage video {
  pointer-events: none;
}

.cinematic-scrub-hud {
  position: absolute;
  z-index: 2;
  inset: var(--s4) var(--s4) auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s4);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 800;
  line-height: 1.2;
  text-shadow: 0 1px 12px rgba(0, 0, 0, 0.78);
  text-transform: uppercase;
}

.cinematic-scrub-hud span,
.cinematic-scrub-hud strong {
  white-space: nowrap;
}

.cinematic-scrub-controls {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: var(--s4);
}

.cinematic-scrub-controls p {
  margin: 0;
  color: #e2e8f0;
  font-size: 0.8125rem;
  font-weight: 700;
  line-height: 1.2;
  white-space: nowrap;
}

.cinematic-scrub-progress {
  position: relative;
  height: 3px;
  overflow: hidden;
  background: rgba(148, 163, 184, 0.32);
}

.cinematic-scrub-progress span {
  position: absolute;
  inset: 0;
  background: #38bdf8;
  box-shadow: 0 0 18px rgba(56, 189, 248, 0.72);
  transform: scaleX(0);
  transform-origin: left center;
  will-change: transform;
}

.cinematic-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s5);
  margin-top: var(--s5);
}

.cinematic-footer p {
  max-width: 680px;
  margin: 0;
  color: #94a3b8;
  font-size: var(--fs-small);
  line-height: 1.55;
}

.cinematic-footer-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: var(--s3);
}

.cinematic-playback-link {
  color: #bae6fd;
  border-color: rgba(125, 211, 252, 0.58);
}

.cinematic-playback-link:hover {
  color: #fff;
  border-color: #7dd3fc;
  background: rgba(125, 211, 252, 0.12);
}

@media (min-width: 1024px) {
  .cinematic-showcase {
    padding-block: var(--s9);
  }
}

@media (max-height: 820px) and (min-width: 768px) {
  .cinematic-showcase.is-scrub-ready .cinematic-scrub-sticky {
    max-width: 980px;
  }
}

@media (max-width: 639px) {
  .cinematic-showcase {
    padding-block: var(--s7);
  }

  .cinematic-footer {
    align-items: flex-start;
    flex-direction: column;
  }

  .cinematic-showcase.is-scrub-ready .cinematic-scrub-track {
    height: 280svh;
  }

  .cinematic-showcase.is-scrub-ready .cinematic-scrub-sticky {
    top: calc(var(--header-h) + var(--s3));
  }

  .cinematic-scrub-hud {
    inset: var(--s3) var(--s3) auto;
    font-size: 0.6875rem;
  }

  .cinematic-footer-actions {
    width: 100%;
    align-items: stretch;
    flex-direction: column;
  }

  .cinematic-footer-actions .btn {
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  .cinematic-scrub-track,
  .cinematic-scrub-sticky {
    height: auto;
    position: relative;
    top: auto;
  }
}

/* ---------- Prose sections (problem/outcome, what-it-is, who) ---------- */
.prose-section .measure { color: var(--body); }
.prose-section h2 { font-size: var(--fs-h2); }
.prose-two-col {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--s6);
  align-items: center;
}
@media (min-width: 900px) {
  .prose-two-col { grid-template-columns: 1fr minmax(0,360px); gap: var(--s8); }
  .prose-two-col.reverse { grid-template-columns: minmax(0,360px) 1fr; }
  .prose-two-col.reverse .prose-two-col-media { order: -1; }
}
.prose-two-col-media { display: flex; justify-content: center; }

/* ---------- C4: Feature grid ---------- */
.feature-grid {
  list-style: none;
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--s5);
  margin: 0 0 var(--s7);
  padding: 0;
}
@media (min-width: 600px) {
  .feature-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 1024px) {
  .feature-grid { grid-template-columns: repeat(3, 1fr); }
}
.feature-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: var(--s5);
  display: flex;
  flex-direction: column;
  gap: var(--s3);
}
.feature-card .icon { width: 28px; height: 28px; }
.feature-card p:not(.card-title) { margin: 0; color: var(--muted); font-size: var(--fs-small); }
.features-cta { display: flex; justify-content: center; }

/* ---------- C5: Screenshot gallery ---------- */
.gallery-track {
  display: flex;
  gap: var(--s5);
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding: var(--s2) var(--s1) var(--s5);
  margin: 0;
  -webkit-overflow-scrolling: touch;
  list-style: none;
}
.gallery-item {
  scroll-snap-align: start;
  flex: 0 0 auto;
  width: 78%;
  max-width: 300px;
  text-align: center;
}
@media (min-width: 480px) {
  .gallery-item { width: 300px; }
}
@media (min-width: 860px) {
  .gallery-track {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    overflow: visible;
    scroll-snap-type: none;
    padding: 0;
  }
  .gallery-item { width: auto; max-width: none; }
}
.gallery-item figcaption {
  margin-top: var(--s3);
  font-size: var(--fs-small);
  color: var(--muted);
}

/* ---------- C6: How it works ---------- */
.how-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--s8);
  align-items: center;
}
@media (min-width: 900px) {
  .how-grid { grid-template-columns: 1fr minmax(0,420px); }
}
.how-items {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--s5);
}
@media (min-width: 560px) {
  .how-items { grid-template-columns: repeat(2, 1fr); }
}
.how-item .card-title { margin: 0 0 var(--s2); }
.how-item p:not(.card-title) { margin: 0; color: var(--muted); font-size: var(--fs-small); }
.how-media { display: flex; flex-direction: column; align-items: center; gap: var(--s4); text-align: center; }
.how-media .platform-line { color: var(--muted); font-size: var(--fs-small); max-width: 34ch; }
.how-cta { display: flex; justify-content: center; margin-top: var(--s7); }

/* ---------- C8: Guides & resources ---------- */
.guides-grid {
  list-style: none;
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--s5);
  margin: 0;
  padding: 0;
}
@media (min-width: 600px) {
  .guides-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 900px) {
  .guides-grid { grid-template-columns: repeat(3, 1fr); }
}
.guide-card {
  display: block;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: var(--s5);
  text-decoration: none;
  color: inherit;
  transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
}
.guide-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-card-hover);
  border-color: var(--line-strong);
}
.guide-card .card-title { margin: 0 0 var(--s2); }
.guide-card p:not(.card-title) { margin: 0 0 var(--s3); color: var(--muted); font-size: var(--fs-small); }
.guide-card .guide-link-label { color: var(--brand); font-weight: 600; font-size: var(--fs-small); }

/* ---------- C9: FAQ ---------- */
.faq-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: var(--s4); max-width: var(--measure); }
.faq-item {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--bg);
  padding: var(--s5);
}
.faq-item summary {
  cursor: pointer;
  font-weight: 700;
  color: var(--ink);
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s4);
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-chevron { flex-shrink: 0; width: 20px; height: 20px; color: var(--brand); transition: transform 160ms ease; }
.faq-item[open] .faq-chevron { transform: rotate(180deg); }
.faq-item p { margin-top: var(--s4); margin-bottom: 0; color: var(--body); }
.faq-item p + p { margin-top: var(--s3); }

/* ---------- C10: Final CTA band ---------- */
.cta-band { text-align: center; }
.cta-band h2 { max-width: 30ch; margin-inline: auto; }
.cta-band p { color: var(--muted); max-width: 52ch; margin: 0 auto var(--s6); font-size: var(--fs-lead); }
.cta-band .cta-group { align-items: center; }
/* section-deep + cta-band are classes on the SAME <section> element (compound
   selector, no descendant space) — must win over the base h2/p color rules. */
.section-deep.cta-band h2,
.section-deep.cta-band p { color: #fff; }

/* ---------- C11: Footer ---------- */
.site-footer { background: var(--surface-2); border-top: 1px solid var(--line); padding-block: var(--s8); }
.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--s7);
}
@media (min-width: 720px) {
  .footer-grid { grid-template-columns: repeat(3, 1fr); }
}
.footer-label { font-size: var(--fs-small); text-transform: uppercase; letter-spacing: .04em; color: var(--muted); margin: 0 0 var(--s4); font-weight: 700; }
.footer-app { display: flex; align-items: center; gap: var(--s3); margin-bottom: var(--s3); }
.footer-app img { width: 40px; height: 40px; border-radius: var(--radius-sm); }
.footer-app strong { color: var(--ink); font-size: 1.0625rem; }
.footer-col p { color: var(--muted); font-size: var(--fs-small); }
.footer-links { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: var(--s3); }
.footer-links a { color: var(--body); text-decoration: none; font-size: var(--fs-small); font-weight: 500; }
.footer-links a:hover { color: var(--brand); text-decoration: underline; }
.footer-badge { margin-top: var(--s4); }

.footer-bottom {
  margin-top: var(--s8);
  padding-top: var(--s6);
  border-top: 1px solid var(--line);
}
.footer-disclaimer {
  font-size: var(--fs-small);
  color: var(--muted);
  max-width: 90ch;
  margin: 0 0 var(--s4);
}
.footer-copyright { font-size: var(--fs-small); color: var(--muted); margin: 0; }

/* ---------- C12: Sticky mobile CTA ---------- */
.sticky-cta {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  z-index: 60;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s3);
  background: var(--bg);
  border-top: 1px solid var(--line);
  box-shadow: var(--shadow);
  padding: var(--s3) var(--s4) calc(var(--s3) + env(safe-area-inset-bottom)) var(--s4);
}
.sticky-cta-label {
  font-weight: 700;
  color: var(--ink);
  font-size: clamp(0.8125rem, 3.6vw, 0.9375rem);
  white-space: nowrap;
  flex-shrink: 1;
  min-width: 0;
}
@media (min-width: 720px) { .sticky-cta { display: none; } }
@media print { .sticky-cta { display: none !important; } }

/* Sticky CTA is present on every page ≤719px — reserve space unconditionally
   (CSS-only) so the page works identically with JavaScript disabled. */
@media (max-width: 719px) {
  body { padding-bottom: calc(80px + env(safe-area-inset-bottom)); }
}

/* ---------- Breadcrumb ---------- */
.breadcrumb { padding-block: var(--s5) 0; }
.breadcrumb ol {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s2);
  margin: 0;
  padding: 0;
  font-size: var(--fs-small);
  color: var(--muted);
}
.breadcrumb a { color: var(--muted); text-decoration: none; font-weight: 500; }
.breadcrumb a:hover { color: var(--brand); text-decoration: underline; }
.breadcrumb li:not(:last-child)::after {
  content: "";
  display: inline-block;
  width: 14px; height: 14px;
  margin-left: var(--s2);
  vertical-align: -2px;
  background: currentColor;
  opacity: .35;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='9 18 15 12 9 6'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='9 18 15 12 9 6'/%3E%3C/svg%3E") center / contain no-repeat;
}
.breadcrumb [aria-current="page"] { color: var(--ink); font-weight: 600; }

/* ---------- C13: Guide article ---------- */
.guide-article { padding-block: var(--s6) var(--s7); }
.guide-article .intro {
  font-size: var(--fs-lead);
  color: var(--muted);
  max-width: var(--measure);
  margin: var(--s5) 0 var(--s6);
}
.guide-top-cta { margin-bottom: var(--s7); }
.guide-hero-media { margin-bottom: var(--s7); display: flex; justify-content: center; }

.article-body { max-width: var(--measure); }
.article-body h2 { margin-top: var(--s8); }
.article-body h2:first-child { margin-top: 0; }
.article-body h3 { margin-top: var(--s6); }
.article-body p { margin-bottom: var(--s4); }
.article-body ul, .article-body ol { margin: 0 0 var(--s5); padding-left: 1.25em; }
.article-body li { margin-bottom: var(--s3); }
.article-body li:last-child { margin-bottom: 0; }
.article-body blockquote {
  margin: 0 0 var(--s5);
  padding-left: var(--s4);
  border-left: 3px solid var(--line-strong);
  color: var(--muted);
  font-style: italic;
}
.article-figure { margin: var(--s6) 0; text-align: center; }

.safety-callout {
  background: var(--alert-tint);
  border-left: 4px solid var(--alert);
  border-radius: var(--radius-sm);
  padding: var(--s5);
  margin: var(--s6) 0 var(--s7);
  max-width: var(--measure);
  color: var(--ink);
}
.safety-callout p { margin: 0; }
.safety-callout p + p { margin-top: var(--s3); }

.guide-bottom-cta { margin: var(--s7) 0; }
.guide-faq-heading { margin-top: var(--s8); }

.related-guides { margin-top: var(--s8); }
.related-guides .section-label {
  font-size: var(--fs-small);
  text-transform: uppercase;
  letter-spacing: .04em;
  color: var(--muted);
  font-weight: 700;
  margin: 0 0 var(--s5);
}
.related-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--s4);
}
@media (min-width: 600px) {
  .related-list { grid-template-columns: repeat(2, 1fr); }
}

/* ---------- Utility: CTA row alignment for guide top/bottom ---------- */
.cta-row { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s5); }

/* ---------- Motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    transition-duration: 0.001ms !important;
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
  }
  html { scroll-behavior: auto; }
  .guide-card:hover { transform: none; }
}

/* ---------- Print ---------- */
@media print {
  .site-header, .sticky-cta, .badge-link, .btn { display: none !important; }
  body.has-sticky-cta { padding-bottom: 0; }
  a { color: #000; text-decoration: underline; }
}
