/* =============================================================================
   LessonCadence — landing page styles
   The CSS :root below is the web half of the design tokens. It is the SAME
   palette as packages/ui/lib/src/tokens/app_colors.dart, expressed twice
   (UI Style Guide §10). Change one → change the other in the same PR.
   ========================================================================== */

:root {
  /* Core (mirror of app_colors.dart) */
  --lc-primary:            #2E4A8C;
  --lc-on-primary:         #FFFFFF;
  --lc-secondary:          #1B8A76;
  --lc-background:         #F6F7F9;
  --lc-surface:            #FFFFFF;
  --lc-surface-variant:    #EDF0F4;
  --lc-on-surface:         #1B2430;
  --lc-on-surface-variant: #4E5868;
  --lc-outline:            #D6DAE0;
  --lc-outline-variant:    #E7EAEE;
  --lc-error:              #B3261E;
  --lc-success:            #1B8A3A;
  --lc-warning:            #8A5A00;

  /* Warmth accent (classroom layer) */
  --lc-accent-warm:        #F2A03D;
  --lc-accent-warm-soft:   #FDF1DF;

  /* Type */
  --lc-font-body: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --lc-font-head: 'Nunito', var(--lc-font-body);

  /* Spacing (4pt) */
  --lc-xs: 4px;  --lc-sm: 8px;  --lc-md: 12px;
  --lc-lg: 16px; --lc-xl: 24px; --lc-xxl: 32px;

  /* Shape */
  --lc-radius-card: 16px;
  --lc-radius-control: 12px;
  --lc-maxw: 1200px;
}

/* ----------------------------------------------------------------------------
   Base
   ------------------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

body {
  margin: 0;
  font-family: var(--lc-font-body);
  font-size: 16px;
  line-height: 1.5;
  color: var(--lc-on-surface);
  background: var(--lc-background);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  /* Long brand/product names must break rather than push the page sideways
     when OS text scaling blows headings up (style guide section 9). */
  overflow-wrap: break-word;
}

h1, h2, h3 {
  font-family: var(--lc-font-head);
  color: var(--lc-on-surface);
  line-height: 1.2;
  margin: 0 0 var(--lc-md);
  font-weight: 700;
}
h1 { font-size: clamp(2rem, 5vw, 3rem); letter-spacing: -0.02em; }
h2 { font-size: clamp(1.6rem, 3.5vw, 2.25rem); letter-spacing: -0.01em; }
h3 { font-size: 1.2rem; font-weight: 700; }

p { margin: 0 0 var(--lc-md); }
a { color: var(--lc-primary); text-decoration: none; }
a:hover { text-decoration: underline; }

img, svg { max-width: 100%; height: auto; }

/* Visible focus for keyboard users (style guide §9). */
:focus-visible {
  outline: 3px solid var(--lc-primary);
  outline-offset: 2px;
  border-radius: 4px;
}

.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;
}

.skip-link {
  position: absolute; left: var(--lc-md); top: -60px;
  background: var(--lc-primary); color: var(--lc-on-primary);
  padding: var(--lc-sm) var(--lc-lg); border-radius: var(--lc-radius-control);
  z-index: 100; transition: top .15s ease;
}
.skip-link:focus { top: var(--lc-md); }

/* ----------------------------------------------------------------------------
   Layout helpers
   ------------------------------------------------------------------------- */
.wrap { width: 100%; max-width: var(--lc-maxw); margin-inline: auto; padding-inline: var(--lc-lg); }
@media (min-width: 840px) { .wrap { padding-inline: var(--lc-xl); } }

section { padding-block: clamp(48px, 8vw, 96px); }

.eyebrow {
  display: inline-block;
  font-size: 0.8125rem; font-weight: 600; letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--lc-secondary);
  margin-bottom: var(--lc-md);
}
.section-head { max-width: 62ch; }
.section-head.center { margin-inline: auto; text-align: center; }
.lede { font-size: 1.125rem; color: var(--lc-on-surface-variant); max-width: 62ch; }

/* ----------------------------------------------------------------------------
   Buttons
   ------------------------------------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: var(--lc-sm);
  min-height: 44px; padding: 0 var(--lc-xl);
  font-family: var(--lc-font-body); font-size: 1rem; font-weight: 600;
  border-radius: var(--lc-radius-control); border: 1px solid transparent;
  cursor: pointer; text-decoration: none; transition: background .15s ease, transform .05s ease;
}
.btn:hover { text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--lc-primary); color: var(--lc-on-primary); }
.btn-primary:hover { background: #263d75; }
.btn-warm { background: var(--lc-accent-warm); color: #3a2a10; }
.btn-warm:hover { background: #e8912b; }
.btn-outline { background: transparent; color: var(--lc-primary); border-color: var(--lc-outline); }
.btn-outline:hover { background: var(--lc-surface-variant); }
.btn-lg { min-height: 52px; font-size: 1.0625rem; padding-inline: var(--lc-xxl); }

/* ----------------------------------------------------------------------------
   Nav
   ------------------------------------------------------------------------- */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--lc-surface) 88%, transparent);
  backdrop-filter: saturate(160%) blur(10px);
  border-bottom: 1px solid var(--lc-outline-variant);
}
.nav .wrap {
  display: flex; align-items: center; justify-content: space-between;
  min-height: 64px;
  /* Wrap rather than overflow when the nav is crowded (narrow screens, or OS
     text scaled to 200% — style guide section 9). */
  flex-wrap: wrap; row-gap: var(--lc-sm); padding-block: var(--lc-sm);
}
.brand { display: inline-flex; align-items: center; gap: var(--lc-sm); font-family: var(--lc-font-head); font-weight: 800; font-size: 1.15rem; color: var(--lc-on-surface); }
.brand:hover { text-decoration: none; }
.brand .mark { flex: none; }
.nav-links { display: none; gap: var(--lc-xl); align-items: center; }
.nav-links a { color: var(--lc-on-surface-variant); font-weight: 500; }
.nav-links a:hover { color: var(--lc-on-surface); text-decoration: none; }
.nav-cta { display: inline-flex; }
@media (min-width: 840px) { .nav-links { display: inline-flex; } }

/* ----------------------------------------------------------------------------
   Hero
   ------------------------------------------------------------------------- */
.hero { background: linear-gradient(180deg, var(--lc-surface) 0%, var(--lc-background) 100%); }
.hero .wrap { display: grid; gap: var(--lc-xxl); align-items: center; }
@media (min-width: 840px) { .hero .wrap { grid-template-columns: 1.05fr 0.95fr; gap: 64px; } }
.hero h1 { margin-top: var(--lc-sm); }
.hero .lede { font-size: 1.1875rem; margin-bottom: var(--lc-xl); }
.hero-cta { display: flex; flex-wrap: wrap; gap: var(--lc-md); align-items: center; }
.hero-micro { margin-top: var(--lc-lg); color: var(--lc-on-surface-variant); font-size: 0.95rem; }
.hero-micro strong { color: var(--lc-on-surface); }
.trust-line { margin-top: var(--lc-md); font-size: 0.85rem; color: var(--lc-on-surface-variant); display: flex; gap: var(--lc-md); flex-wrap: wrap; }
.trust-line span { display: inline-flex; align-items: center; gap: 6px; }

/* ----------------------------------------------------------------------------
   Lesson-loop visual (the signature)
   ------------------------------------------------------------------------- */
.loop {
  background: var(--lc-surface); border: 1px solid var(--lc-outline-variant);
  border-radius: var(--lc-radius-card); padding: var(--lc-xl);
}
.loop-title { font-family: var(--lc-font-head); font-weight: 700; font-size: 0.95rem; color: var(--lc-on-surface-variant); margin-bottom: var(--lc-lg); }
.loop-steps { display: flex; flex-wrap: wrap; align-items: stretch; gap: var(--lc-sm); }
.loop-step {
  flex: 1 1 auto; display: flex; align-items: center; gap: var(--lc-sm);
  padding: var(--lc-md) var(--lc-lg);
  background: var(--lc-surface-variant); border-radius: var(--lc-radius-control);
  font-weight: 600; font-size: 0.95rem; white-space: nowrap;
}
.loop-step .dot { width: 10px; height: 10px; border-radius: 50%; background: var(--lc-primary); flex: none; }
.loop-step.paid { background: var(--lc-accent-warm-soft); }
.loop-step.paid .dot { background: var(--lc-accent-warm); }
.loop-arrow { align-self: center; color: var(--lc-outline); flex: none; }
.loop-caption { margin-top: var(--lc-lg); margin-bottom: 0; color: var(--lc-on-surface-variant); font-size: 0.95rem; }

/* ----------------------------------------------------------------------------
   Cards / grids
   ------------------------------------------------------------------------- */
.card {
  background: var(--lc-surface); border: 1px solid var(--lc-outline-variant);
  border-radius: var(--lc-radius-card); padding: var(--lc-xl);
}
.grid { display: grid; gap: var(--lc-lg); }
.grid-3 { grid-template-columns: 1fr; }
.grid-4 { grid-template-columns: 1fr; }
@media (min-width: 600px) { .grid-3 { grid-template-columns: repeat(2, 1fr); } .grid-4 { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 840px) { .grid-3 { grid-template-columns: repeat(3, 1fr); } .grid-4 { grid-template-columns: repeat(4, 1fr); } }

.icon-badge {
  width: 44px; height: 44px; border-radius: var(--lc-radius-control);
  display: grid; place-items: center; background: var(--lc-surface-variant);
  color: var(--lc-primary); margin-bottom: var(--lc-md);
}
.card h3 { margin-bottom: var(--lc-xs); }
.card p { color: var(--lc-on-surface-variant); margin-bottom: 0; }

.section-alt { background: var(--lc-surface); border-block: 1px solid var(--lc-outline-variant); }

/* Pillars (alternating) */
.pillar { display: grid; gap: var(--lc-xl); align-items: center; }
@media (min-width: 840px) {
  .pillar { grid-template-columns: 1fr 1fr; gap: 64px; }
  .pillar.reverse .pillar-visual { order: -1; }
}
.pillar + .pillar { margin-top: var(--lc-xxl); }
/* The pillar visuals reuse .loop-step but carry full sentences, so they must
   wrap — the nowrap that keeps the lesson-loop chain tidy would push the page
   sideways at 200% text scale. */
.pillar-visual .loop-step { white-space: normal; }
.pillar-visual { background: var(--lc-accent-warm-soft); border-radius: var(--lc-radius-card); min-height: 220px; display: grid; place-items: center; padding: var(--lc-xl); }

/* Personas */
.persona h3 { font-size: 1.05rem; }

/* ----------------------------------------------------------------------------
   Founding offer / counter
   ------------------------------------------------------------------------- */
.offer { background: var(--lc-accent-warm-soft); border-block: 1px solid var(--lc-accent-warm); }
.counter { margin: var(--lc-lg) 0; }
.counter-bar { height: 12px; border-radius: 999px; background: var(--lc-surface); border: 1px solid var(--lc-outline); overflow: hidden; max-width: 420px; }
.counter-fill { height: 100%; width: 0; background: var(--lc-accent-warm); transition: width .6s ease; }
@media (prefers-reduced-motion: reduce) { .counter-fill { transition: none; } }
.counter-label { font-weight: 600; margin-bottom: var(--lc-sm); }

/* ----------------------------------------------------------------------------
   Waitlist form
   ------------------------------------------------------------------------- */
.signup { background: var(--lc-surface); border: 1px solid var(--lc-outline-variant); border-radius: var(--lc-radius-card); padding: var(--lc-xl); }
.form-row { display: grid; gap: var(--lc-md); }
@media (min-width: 600px) { .form-row.two { grid-template-columns: 1fr 1fr; } }
/* min-width:0 stops an input's default intrinsic width from widening its grid
   column (and the page) once OS text scaling kicks in. */
.form-row > * { min-width: 0; }
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field label { font-size: 0.875rem; font-weight: 500; color: var(--lc-on-surface); }
.field input, .field select, .field textarea {
  font-family: var(--lc-font-body); font-size: 1rem; color: var(--lc-on-surface);
  padding: 12px var(--lc-lg); border: 1px solid var(--lc-outline);
  border-radius: var(--lc-radius-control); background: var(--lc-surface); min-height: 44px;
  width: 100%; min-width: 0;
}
.field textarea { min-height: 88px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--lc-primary); outline: none; box-shadow: 0 0 0 3px color-mix(in srgb, var(--lc-primary) 25%, transparent); }
.field input[aria-invalid="true"], .field select[aria-invalid="true"] { border-color: var(--lc-error); }
.field-error { display: none; align-items: center; gap: 6px; color: var(--lc-error); font-size: 0.85rem; }
.field-error.show { display: flex; }
.form-actions { margin-top: var(--lc-lg); }
.form-note { font-size: 0.85rem; color: var(--lc-on-surface-variant); margin-top: var(--lc-md); margin-bottom: 0; }
.dp-fields { display: none; }
.dp-fields.show { display: grid; gap: var(--lc-md); margin-top: var(--lc-md); }

.form-status { display: none; border-radius: var(--lc-radius-control); padding: var(--lc-lg); gap: var(--lc-sm); align-items: flex-start; }
.form-status.show { display: flex; }
.form-status.success { background: color-mix(in srgb, var(--lc-success) 12%, var(--lc-surface)); border: 1px solid var(--lc-success); color: #14522a; }
.form-status.info { background: var(--lc-surface-variant); border: 1px solid var(--lc-outline); color: var(--lc-on-surface); }
.form-status.error { background: color-mix(in srgb, var(--lc-error) 10%, var(--lc-surface)); border: 1px solid var(--lc-error); color: #7a1a15; }
.form-status strong { display: block; margin-bottom: 2px; }

/* Site-wide confirmed banner (after email confirm redirect) */
.confirm-banner { display: none; background: var(--lc-success); color: #fff; text-align: center; padding: var(--lc-md) var(--lc-lg); }
.confirm-banner.show { display: block; }
.confirm-banner a { color: #fff; text-decoration: underline; }

/* ----------------------------------------------------------------------------
   Pricing
   ------------------------------------------------------------------------- */
.plans { display: grid; gap: var(--lc-lg); }
/* Four tiers: 2-up on tablets, 4-up once there is room for them. */
@media (min-width: 840px) { .plans { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1080px) { .plans { grid-template-columns: repeat(4, 1fr); } }
.plan { display: flex; flex-direction: column; }
.plan.featured { border-color: var(--lc-primary); box-shadow: 0 0 0 1px var(--lc-primary); }
.plan .tag { align-self: flex-start; font-size: 0.75rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; color: var(--lc-accent-warm); margin-bottom: var(--lc-sm); }
.plan .price { font-family: var(--lc-font-head); font-size: 2rem; font-weight: 800; }
.plan .price small { font-size: 0.9rem; font-weight: 500; color: var(--lc-on-surface-variant); }
.plan .founding { color: var(--lc-secondary); font-weight: 600; font-size: 0.9rem; margin-bottom: var(--lc-md); }
.plan ul { list-style: none; padding: 0; margin: 0; color: var(--lc-on-surface-variant); }
.plan li { padding-left: 26px; position: relative; margin-bottom: var(--lc-sm); }
.plan li::before { content: ""; position: absolute; left: 0; top: 7px; width: 14px; height: 14px; border-radius: 50%; background: color-mix(in srgb, var(--lc-secondary) 20%, transparent); }
.pricing-note { text-align: center; color: var(--lc-on-surface-variant); font-size: 0.9rem; margin-top: var(--lc-xl); }

/* ----------------------------------------------------------------------------
   FAQ
   ------------------------------------------------------------------------- */
.faq { max-width: 760px; margin-inline: auto; }
.faq details { border: 1px solid var(--lc-outline-variant); border-radius: var(--lc-radius-control); background: var(--lc-surface); margin-bottom: var(--lc-md); }
.faq summary { cursor: pointer; padding: var(--lc-lg); font-weight: 600; list-style: none; display: flex; justify-content: space-between; align-items: center; gap: var(--lc-md); }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-size: 1.4rem; color: var(--lc-on-surface-variant); flex: none; }
.faq details[open] summary::after { content: "\2212"; }
.faq details > p { padding: 0 var(--lc-lg) var(--lc-lg); margin: 0; color: var(--lc-on-surface-variant); }

/* ----------------------------------------------------------------------------
   Final CTA band + footer
   ------------------------------------------------------------------------- */
.cta-band { background: var(--lc-primary); color: var(--lc-on-primary); text-align: center; }
.cta-band h2 { color: var(--lc-on-primary); }
.cta-band p { color: color-mix(in srgb, var(--lc-on-primary) 82%, transparent); }
.cta-band .btn-warm { margin-top: var(--lc-md); }

.footer { background: var(--lc-surface); border-top: 1px solid var(--lc-outline-variant); padding-block: var(--lc-xxl); font-size: 0.9rem; color: var(--lc-on-surface-variant); }
.footer .wrap { display: grid; gap: var(--lc-lg); }
@media (min-width: 600px) { .footer .wrap { grid-template-columns: 1fr auto; align-items: start; } }
.footer-links { display: flex; gap: var(--lc-lg); flex-wrap: wrap; }
.footer-links a { color: var(--lc-on-surface-variant); }
.footer .mission { max-width: 40ch; margin: var(--lc-sm) 0 0; }

/* ----------------------------------------------------------------------------
   Scroll-reveal (opt-in; JS adds .reveal, reduced-motion disables)
   ------------------------------------------------------------------------- */
.reveal { opacity: 0; transform: translateY(16px); transition: opacity .5s ease, transform .5s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
}

/* ----------------------------------------------------------------------------
   Legal / prose pages (privacy, terms)
   ------------------------------------------------------------------------- */
.legal { max-width: 760px; margin-inline: auto; }
.legal .updated { color: var(--lc-on-surface-variant); font-size: 0.9rem; margin-top: calc(-1 * var(--lc-sm)); }
.legal h2 { font-size: 1.3rem; margin-top: var(--lc-xxl); }
.legal h3 { font-size: 1.05rem; margin-top: var(--lc-xl); }
.legal p, .legal li { color: var(--lc-on-surface-variant); }
.legal ul { padding-left: var(--lc-xl); margin: 0 0 var(--lc-md); }
.legal li { margin-bottom: var(--lc-sm); }
.legal a { text-decoration: underline; }
.legal .toc { background: var(--lc-surface); border: 1px solid var(--lc-outline-variant); border-radius: var(--lc-radius-card); padding: var(--lc-lg) var(--lc-xl); margin-bottom: var(--lc-xl); }
.legal .toc ul { list-style: none; padding: 0; margin: 0; display: grid; gap: var(--lc-xs); }
.legal .toc a { color: var(--lc-primary); }
.legal .note { background: var(--lc-accent-warm-soft); border: 1px solid var(--lc-accent-warm); border-radius: var(--lc-radius-control); padding: var(--lc-lg); font-size: 0.9rem; }
.legal .note p { color: var(--lc-on-surface); margin: 0; }
.legal .back { display: inline-flex; align-items: center; gap: var(--lc-xs); margin-bottom: var(--lc-lg); font-weight: 600; text-decoration: none; }

/* ----------------------------------------------------------------------------
   Login area (nav dropdown panel)
   The marketing site never handles credentials: the panel is an *entry point*
   that hands off to the app's own sign-in screen on the app origin. See
   compare/README notes and PRD 07 FR-MKT-13.
   ------------------------------------------------------------------------- */
.nav-auth { position: relative; display: inline-flex; align-items: center; gap: var(--lc-sm); flex-wrap: wrap; }
.login-toggle {
  background: transparent; color: var(--lc-on-surface);
  border: 1px solid var(--lc-outline); font-weight: 600;
  padding-inline: var(--lc-lg);
}
.login-toggle:hover { background: var(--lc-surface-variant); }
.login-toggle .chev { transition: transform .15s ease; }
.login-toggle[aria-expanded="true"] .chev { transform: rotate(180deg); }
@media (prefers-reduced-motion: reduce) { .login-toggle .chev { transition: none; } }

.login-panel {
  position: absolute; top: calc(100% + var(--lc-sm)); right: 0; z-index: 60;
  width: min(320px, calc(100vw - var(--lc-xl)));
  background: var(--lc-surface); border: 1px solid var(--lc-outline);
  border-radius: var(--lc-radius-card); padding: var(--lc-xl);
  /* A transient floating layer — the one place a shadow is allowed (§5.3). */
  box-shadow: 0 12px 32px rgba(27, 36, 48, .14);
}
.login-panel[hidden] { display: none; }
.login-panel .login-title { font-family: var(--lc-font-head); font-weight: 700; font-size: 1.1rem; color: var(--lc-on-surface); margin-bottom: var(--lc-xs); }
.login-panel p { font-size: 0.9rem; color: var(--lc-on-surface-variant); }
.login-panel .btn { width: 100%; }
.login-panel .login-alt { margin: var(--lc-md) 0 0; font-size: 0.85rem; }
.login-panel hr { border: 0; border-top: 1px solid var(--lc-outline-variant); margin: var(--lc-lg) 0; }
.login-note {
  display: flex; gap: var(--lc-sm); align-items: flex-start;
  background: var(--lc-surface-variant); border-radius: var(--lc-radius-control);
  padding: var(--lc-md); font-size: 0.8125rem; color: var(--lc-on-surface-variant);
  margin: var(--lc-md) 0 0;
}
/* Pre-launch state: no public app yet, so we say so instead of linking nowhere. */
.login-panel .prelaunch { background: var(--lc-accent-warm-soft); border: 1px solid var(--lc-accent-warm); }
.login-panel .prelaunch p { color: var(--lc-on-surface); margin: 0; }

/* On phones the panel drops to full width under the sticky nav. */
@media (max-width: 599px) {
  .login-panel { position: fixed; left: var(--lc-md); right: var(--lc-md); width: auto; top: 72px; }
}

/* ----------------------------------------------------------------------------
   Comparison page (compare.html)
   ------------------------------------------------------------------------- */
.compare-hero { background: linear-gradient(180deg, var(--lc-surface) 0%, var(--lc-background) 100%); }
.compare-hero .wrap { max-width: 840px; }

/* Every claim on the page is dated + sourced; this is the standing disclosure. */
.verified {
  display: flex; gap: var(--lc-sm); align-items: flex-start;
  background: var(--lc-surface); border: 1px solid var(--lc-outline-variant);
  border-radius: var(--lc-radius-card); padding: var(--lc-lg);
  font-size: 0.9rem; color: var(--lc-on-surface-variant);
  margin-top: var(--lc-xl);
}
.verified strong { color: var(--lc-on-surface); }

/* Wide table scrolls inside its own container — the page never scrolls sideways. */
.table-scroll {
  overflow-x: auto;
  border: 1px solid var(--lc-outline-variant);
  border-radius: var(--lc-radius-card);
  background: var(--lc-surface);
  -webkit-overflow-scrolling: touch;
}
.table-scroll:focus-visible { outline: 3px solid var(--lc-primary); outline-offset: 2px; }
.table-hint { font-size: 0.85rem; color: var(--lc-on-surface-variant); margin: var(--lc-sm) 0 0; }
@media (min-width: 1040px) { .table-hint { display: none; } }

table.compare {
  border-collapse: collapse; width: 100%; min-width: 1080px;
  font-size: 0.9rem; text-align: left;
}
table.compare caption { text-align: left; padding: var(--lc-lg) var(--lc-lg) 0; color: var(--lc-on-surface-variant); font-size: 0.9rem; }
table.compare th, table.compare td {
  padding: var(--lc-md) var(--lc-lg);
  border-bottom: 1px solid var(--lc-outline-variant);
  vertical-align: top;
}
table.compare thead th {
  background: var(--lc-surface-variant); color: var(--lc-on-surface);
  font-family: var(--lc-font-head); font-weight: 700; font-size: 0.9rem;
  border-bottom: 1px solid var(--lc-outline);
}
table.compare tbody th {
  font-weight: 600; color: var(--lc-on-surface);
  background: var(--lc-surface); white-space: nowrap;
}
table.compare tbody tr:last-child th,
table.compare tbody tr:last-child td { border-bottom: 0; }
/* Our own column, gently highlighted — not shouted. */
table.compare .col-lc { background: color-mix(in srgb, var(--lc-primary) 6%, var(--lc-surface)); }
table.compare thead .col-lc { background: color-mix(in srgb, var(--lc-primary) 14%, var(--lc-surface-variant)); }
table.compare td small { display: block; color: var(--lc-on-surface-variant); font-size: 0.8125rem; margin-top: 2px; }
.vendor-sub { display: block; font-weight: 500; font-size: 0.78rem; color: var(--lc-on-surface-variant); }

/* Status marks — always icon + text, never colour alone (§3.4, §6.4). */
.mark-yes, .mark-no, .mark-partial { display: inline-flex; align-items: baseline; gap: 6px; font-weight: 600; }
.mark-yes { color: #14522a; }
.mark-no { color: var(--lc-on-surface-variant); font-weight: 500; }
.mark-partial { color: var(--lc-warning); }

/* Worked cost scenarios */
.scenarios { display: grid; gap: var(--lc-lg); margin-top: var(--lc-xl); }
@media (min-width: 840px) { .scenarios { grid-template-columns: repeat(3, 1fr); } }
.scenario h3 { font-size: 1.05rem; margin-bottom: var(--lc-xs); }
.scenario .setup { font-size: 0.85rem; color: var(--lc-on-surface-variant); margin-bottom: var(--lc-lg); }
.cost-list { list-style: none; padding: 0; margin: 0; }
.cost-list li {
  display: flex; justify-content: space-between; align-items: baseline; gap: var(--lc-md);
  padding: var(--lc-sm) 0; border-bottom: 1px solid var(--lc-outline-variant);
  font-size: 0.9rem; color: var(--lc-on-surface-variant);
}
.cost-list li:last-child { border-bottom: 0; }
.cost-list .amount { font-family: var(--lc-font-head); font-weight: 700; white-space: nowrap; color: var(--lc-on-surface); }
.cost-list li.us { color: var(--lc-on-surface); font-weight: 600; }
.cost-list li.us .amount { color: var(--lc-primary); }
.scenario .math { font-size: 0.8rem; color: var(--lc-on-surface-variant); margin: var(--lc-md) 0 0; }

/* Head-to-head cards */
.h2h { display: grid; gap: var(--lc-lg); margin-top: var(--lc-xl); }
@media (min-width: 840px) { .h2h { grid-template-columns: repeat(2, 1fr); } }
.h2h .card { display: flex; flex-direction: column; }
.h2h h3 { margin-bottom: var(--lc-sm); }
.h2h .verdict { color: var(--lc-on-surface); font-weight: 500; }
.h2h .fair {
  margin-top: auto; padding-top: var(--lc-md); border-top: 1px solid var(--lc-outline-variant);
  font-size: 0.875rem;
}
.h2h .fair strong { color: var(--lc-on-surface); }

/* Sources */
.sources { max-width: 840px; margin-inline: auto; }
.sources ol { padding-left: var(--lc-xl); margin: 0; color: var(--lc-on-surface-variant); font-size: 0.875rem; }
.sources li { margin-bottom: var(--lc-sm); }
.sources a { text-decoration: underline; word-break: break-word; }
