/* Marketing + SEO pages. Tokens come from shared/tokens.css. */
.wrap { width: min(1120px, 100% - 32px); margin-inline: auto; }
.narrow { width: min(760px, 100% - 32px); margin-inline: auto; }

.glow { position: relative; isolation: isolate; overflow: hidden; }
.glow::before {
  content: ""; position: absolute; inset: -20% -10% auto; height: 640px; z-index: -1; pointer-events: none;
  background:
    radial-gradient(40% 50% at 20% 30%, var(--glow-a), transparent 70%),
    radial-gradient(35% 45% at 80% 20%, var(--glow-b), transparent 70%),
    radial-gradient(30% 40% at 55% 70%, var(--glow-c), transparent 70%);
  filter: blur(8px);
}

/* Header */
.site-header { position: sticky; top: 0; z-index: 40; backdrop-filter: saturate(1.4) blur(12px);
  background: color-mix(in srgb, var(--bg) 82%, transparent); border-bottom: 1px solid var(--border); }
.site-header .wrap { display: flex; align-items: center; gap: 1.5rem; height: 64px; }
.logo { display: inline-flex; align-items: center; gap: .55rem; font-weight: 700; font-size: 1.1rem; text-decoration: none; letter-spacing: -0.03em; }
.logo-mark { width: 28px; height: 28px; border-radius: 9px; background: var(--text); color: var(--bg); display: grid; place-items: center; font: 700 .8rem var(--mono); }
.nav { display: flex; gap: 1.25rem; margin-left: .5rem; }
.nav a { text-decoration: none; color: var(--text-muted); font-size: .92rem; font-weight: 500; }
.nav a:hover, .nav a[aria-current="page"] { color: var(--text); }
.header-cta { margin-left: auto; display: flex; gap: .5rem; align-items: center; }
.menu-btn { display: none; margin-left: auto; background: none; border: 1px solid var(--border-strong); border-radius: 10px; width: 40px; height: 40px; color: var(--text); }
@media (max-width: 860px) {
  .nav, .header-cta .btn-ghost { display: none; }
  .menu-btn { display: grid; place-items: center; margin-left: 0; }
  .header-cta { margin-left: auto; }
  .nav.open { display: flex; position: absolute; top: 64px; left: 0; right: 0; flex-direction: column; gap: 0;
    background: var(--bg); border-bottom: 1px solid var(--border); padding: .5rem 16px 1rem; margin: 0; }
  .nav.open a { padding: .7rem 0; border-bottom: 1px solid var(--border); }
}

/* Hero */
.hero { padding: 5.5rem 0 4rem; text-align: center; }
.hero h1 { font-size: clamp(2.3rem, 6vw, 4.4rem); letter-spacing: -0.045em; font-weight: 700; max-width: 15ch; margin: 1rem auto .9rem; }
.hero p.lead { font-size: clamp(1.05rem, 2vw, 1.25rem); color: var(--text-muted); max-width: 52ch; margin: 0 auto 2rem; }
.hero .ctas { display: flex; gap: .75rem; justify-content: center; flex-wrap: wrap; }
.hero .sub { margin-top: .9rem; font-size: .85rem; color: var(--text-faint); }
.pill-badge { display: inline-flex; gap: .5rem; align-items: center; padding: .3rem .4rem .3rem .8rem; border-radius: 999px;
  border: 1px solid var(--border); background: var(--surface); font-size: .82rem; color: var(--text-muted); text-decoration: none; }
.pill-badge b { background: var(--accent-soft); color: var(--accent); border-radius: 999px; padding: .1rem .55rem; font-weight: 600; }

/* Product preview */
.preview { margin: 3.5rem auto 0; max-width: 980px; border-radius: var(--radius-xl); border: 1px solid var(--border);
  background: var(--surface); box-shadow: var(--shadow-lg); padding: 1rem; text-align: left; }
.preview-bar { display: flex; gap: .4rem; padding: .2rem .3rem .8rem; }
.preview-bar span { width: 10px; height: 10px; border-radius: 50%; background: var(--border-strong); }
.preview-grid { display: grid; grid-template-columns: 1.3fr 1fr; gap: 1rem; }
@media (max-width: 760px) { .preview-grid { grid-template-columns: 1fr; } }
.ring-row { display: flex; gap: 1rem; flex-wrap: wrap; }
.ring { width: 92px; text-align: center; font-size: .78rem; color: var(--text-muted); }
.ring svg { width: 92px; height: 92px; margin-bottom: .3rem; }

/* Sections */
section.block { padding: 4.5rem 0; }
.section-head { max-width: 640px; margin-bottom: 2.5rem; }
.section-head h2 { font-size: clamp(1.7rem, 3.6vw, 2.6rem); letter-spacing: -0.035em; margin-top: .7rem; }
.section-head p { color: var(--text-muted); font-size: 1.08rem; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1rem; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; }
@media (max-width: 900px) { .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .grid-3, .grid-2, .grid-4 { grid-template-columns: 1fr; } }
.feature { padding: 1.5rem; }
.feature .num { font: 500 .78rem var(--mono); color: var(--text-faint); }
.feature h3 { font-size: 1.15rem; margin: .7rem 0 .4rem; }
.feature p { color: var(--text-muted); margin: 0; font-size: .96rem; }
.ticker { display: flex; gap: .5rem; flex-wrap: wrap; justify-content: center; }
.link-card { display: block; text-decoration: none; transition: border-color .15s, transform .15s; }
.link-card:hover { border-color: var(--border-strong); transform: translateY(-2px); }
.link-card h3 { font-size: 1.02rem; margin-bottom: .3rem; }
.link-card p { color: var(--text-muted); font-size: .9rem; margin: 0; }
.cta-band { text-align: center; padding: 4rem 1.5rem; border-radius: var(--radius-xl); background: var(--text); color: var(--bg); }
.cta-band h2 { font-size: clamp(1.7rem, 4vw, 2.6rem); }
.cta-band p { opacity: .75; max-width: 46ch; margin: 0 auto 1.6rem; }
.cta-band .btn-accent { background: var(--accent); }

/* Articles */
.crumbs { font-size: .85rem; color: var(--text-faint); padding: 1.5rem 0 0; display: flex; gap: .4rem; flex-wrap: wrap; }
.crumbs a { color: var(--text-muted); text-decoration: none; }
.crumbs a:hover { text-decoration: underline; }
.article-head { padding: 1.5rem 0 1.5rem; }
.article-head h1 { font-size: clamp(2rem, 5vw, 3rem); letter-spacing: -0.04em; margin: .8rem 0 .8rem; }
.article-head .dek { font-size: 1.15rem; color: var(--text-muted); }
.meta-row { display: flex; gap: .5rem 1rem; flex-wrap: wrap; font-size: .85rem; color: var(--text-faint); margin-top: 1rem; }
.prose { font-size: 1.05rem; padding-bottom: 2rem; }
.prose h2 { font-size: 1.55rem; margin: 2.4rem 0 .8rem; }
.prose h3 { font-size: 1.2rem; margin: 1.8rem 0 .6rem; }
.prose ul, .prose ol { padding-left: 1.3rem; margin: 0 0 1.2rem; }
.prose li { margin-bottom: .4rem; }
.prose a { color: var(--accent); text-underline-offset: 3px; }
.prose table, table.data { width: 100%; border-collapse: collapse; margin: 1rem 0 1.6rem; font-size: .95rem; }
.prose th, .prose td, table.data th, table.data td { text-align: left; padding: .6rem .7rem; border-bottom: 1px solid var(--border); vertical-align: top; }
.prose th, table.data th { font-weight: 600; background: var(--surface-sunken); }
table.data tbody th { background: none; font-weight: 500; }
.table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.callout { border: 1px solid var(--border); border-left: 3px solid var(--accent); background: var(--surface); border-radius: var(--radius); padding: 1rem 1.1rem; margin: 1.4rem 0; font-size: .98rem; }
.callout.warn { border-left-color: var(--carb); }
.callout p:last-child { margin: 0; }
.key-facts { display: grid; grid-template-columns: repeat(4, 1fr); gap: .75rem; margin: 1.5rem 0; }
@media (max-width: 640px) { .key-facts { grid-template-columns: repeat(2, 1fr); } }
.fact { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: .9rem 1rem; }
.fact b { display: block; font-size: 1.5rem; letter-spacing: -0.03em; }
.fact span { font-size: .8rem; color: var(--text-muted); }
.bar { height: 10px; border-radius: 99px; background: var(--surface-muted); overflow: hidden; }
.bar > i { display: block; height: 100%; border-radius: 99px; }
.faq details { border-bottom: 1px solid var(--border); padding: 1rem 0; }
.faq summary { font-weight: 600; cursor: pointer; list-style: none; display: flex; justify-content: space-between; gap: 1rem; }
.faq summary::after { content: "+"; color: var(--text-faint); font-weight: 400; }
.faq details[open] summary::after { content: "–"; }
.faq details p { margin: .7rem 0 0; color: var(--text-muted); }
.toc { font-size: .92rem; }
.toc a { color: var(--text-muted); text-decoration: none; display: block; padding: .2rem 0; }
.sources { font-size: .88rem; color: var(--text-muted); }
.sources a { color: var(--text-muted); }

/* Tools */
.tool { padding: 1.5rem; margin: 1rem 0 2rem; }
.tool-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0 1rem; }
@media (max-width: 560px) { .tool-grid { grid-template-columns: 1fr; } }
.result { margin-top: 1rem; padding: 1.1rem; border-radius: var(--radius); background: var(--surface-sunken); border: 1px solid var(--border); }
.result[hidden] { display: none; }
.result-big { font-size: 2rem; font-weight: 700; letter-spacing: -0.03em; }
.seg { display: inline-flex; border: 1px solid var(--border-strong); border-radius: 999px; padding: 3px; gap: 2px; }
.seg button { border: 0; background: none; padding: .35rem .8rem; border-radius: 999px; font: 500 .85rem var(--font); color: var(--text-muted); cursor: pointer; }
.seg button[aria-pressed="true"] { background: var(--text); color: var(--bg); }

/* Pricing */
.price-card { padding: 1.75rem; display: flex; flex-direction: column; gap: 1rem; }
.price-card.featured { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent), var(--shadow-lg); }
.price { font-size: 2.6rem; font-weight: 700; letter-spacing: -0.04em; }
.price small { font-size: 1rem; color: var(--text-muted); font-weight: 500; }
.checks { list-style: none; padding: 0; margin: 0; display: grid; gap: .55rem; font-size: .95rem; }
.checks li { display: flex; gap: .55rem; }
.checks li::before { content: "✓"; color: var(--accent); font-weight: 700; }

/* Footer */
.site-footer { border-top: 1px solid var(--border); padding: 3.5rem 0 2rem; margin-top: 4rem; font-size: .9rem; }
.footer-grid { display: grid; grid-template-columns: 1.4fr repeat(4, 1fr); gap: 2rem; }
@media (max-width: 860px) { .footer-grid { grid-template-columns: repeat(2, 1fr); } }
.footer-grid .foot-h, .footer-grid h4 { font-size: .8rem; font-family: var(--mono); text-transform: uppercase; letter-spacing: .08em; color: var(--text-faint); font-weight: 500; }
.footer-grid a { display: block; color: var(--text-muted); text-decoration: none; padding: .2rem 0; }
.footer-grid a:hover { color: var(--text); }
.legal-line { margin-top: 2.5rem; padding-top: 1.5rem; border-top: 1px solid var(--border); color: var(--text-faint); font-size: .82rem; display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.theme-toggle { background: none; border: 1px solid var(--border-strong); border-radius: 999px; color: var(--text-muted); padding: .3rem .8rem; font: 500 .8rem var(--font); cursor: pointer; }
@media (max-width: 560px) { .ring-row { flex-wrap: nowrap; gap: .4rem; justify-content: space-between; } .ring { width: 31%; } .ring svg { width: 100%; height: auto; } }

@media print {
  .site-header, .site-footer, .cta-band, .crumbs, .no-print, .faq, .sources, section.block { display: none !important; }
  body { background: #fff; color: #000; font-size: 12pt; }
  .fact, .card { border: 1px solid #ccc; box-shadow: none; }
  a { color: #000; text-decoration: none; }
}

.link-card .card-title { font-size: 1.02rem; margin: 0 0 .3rem; letter-spacing: -0.02em; }

/* ── Hero: split layout with live calculator */
.hero-split { text-align: left; padding: 4.5rem 0 3rem; background:
  linear-gradient(180deg, color-mix(in srgb, var(--accent-soft) 55%, transparent) 0%, transparent 70%); }
.hero-split .wrap { display: grid; grid-template-columns: 1.05fr .95fr; gap: 3rem; align-items: center; }
.hero-split h1 { margin: 1rem 0 .9rem; max-width: 13ch; }
.hero-split .lead { margin: 0 0 1.4rem; }
@media (max-width: 900px) { .hero-split .wrap { grid-template-columns: 1fr; gap: 2rem; } .hero-split { padding-top: 3rem; } }
.trust-row { list-style: none; padding: 0; margin: 0 0 1rem; display: grid; gap: .5rem; }
.trust-row li { display: flex; gap: .6rem; align-items: center; font-weight: 500; }
.trust-row li::before { content: ""; width: 20px; height: 20px; border-radius: 50%; flex: none; background: var(--accent-soft) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230f7a55' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12l5 5 9-10'/%3E%3C/svg%3E") center/12px no-repeat; }
.hero-calc { padding: 1.5rem; box-shadow: var(--shadow-lg); }
.hc-head { display: flex; justify-content: space-between; align-items: flex-start; gap: .8rem; margin-bottom: .8rem; }
.hc-head h2 { font-size: 1.15rem; margin: 0; letter-spacing: -0.02em; }
.hc-form { display: grid; grid-template-columns: 1fr 1fr; gap: 0 .8rem; }
.hc-form .field { margin-bottom: .7rem; } .hc-form .btn { grid-column: span 2; margin-top: .2rem; }
.hero-calc .key-facts { grid-template-columns: repeat(2, 1fr); margin: .4rem 0 .6rem; }
.hc-note { font-size: .78rem; margin: .8rem 0 0; }

/* ── Motion: reveal on scroll (only when JS runs; off for reduced motion) */
.js .reveal { opacity: 0; transform: translateY(14px); transition: opacity .6s cubic-bezier(.2,.7,.2,1), transform .6s cubic-bezier(.2,.7,.2,1); }
.js .reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .js .reveal { opacity: 1; transform: none; transition: none; } .ring circle { transition: none !important; } }
.link-card, .card.feature { transition: transform .2s cubic-bezier(.2,.7,.2,1), border-color .2s, box-shadow .2s; }
.card.feature:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.btn-primary, .btn-accent { box-shadow: 0 1px 0 #ffffff1a inset, 0 6px 16px -8px color-mix(in srgb, var(--accent) 60%, transparent); }

/* ── Sticky CTA on content pages (mobile only, dismissible) */
.sticky-cta { position: fixed; left: 12px; right: 12px; bottom: 12px; z-index: 50; display: none; align-items: center; justify-content: space-between; gap: .6rem;
  padding: .7rem .7rem .7rem 1rem; border-radius: 16px; background: var(--text); color: var(--bg); box-shadow: var(--shadow-lg);
  transform: translateY(140%); transition: transform .35s cubic-bezier(.2,.7,.2,1); }
.sticky-cta.show { transform: none; }
.sticky-cta b { font-size: .9rem; } .sticky-cta .btn { height: 2.3rem; background: var(--accent); color: var(--accent-contrast); }
.sticky-cta button.x { background: none; border: 0; color: inherit; opacity: .6; font-size: 1.1rem; cursor: pointer; padding: .2rem .4rem; }
@media (max-width: 760px) { .sticky-cta { display: flex; } }
@media print { .sticky-cta { display: none !important; } }

/* Answer-first block (AEO): one self-contained, quotable answer near the top */
.answer { font-size: 1.06rem; line-height: 1.6; padding: 1rem 1.15rem; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--border); border-left: 4px solid var(--accent); margin: 0 0 1.3rem; }
.answer b { color: var(--text); }

/* Real-screen showcase */
.showcase { max-width: 1040px; margin: 0 auto; text-align: center; }
.showcase-tabs { margin-bottom: 1rem; }
.shot-frame { margin: 0; border-radius: 18px; border: 1px solid var(--border); background: var(--surface); padding: 10px; box-shadow: var(--shadow-lg); }
.shot-frame img { width: 100%; height: auto; border-radius: 10px; display: block; }
.shot-frame figcaption { font-size: .8rem; padding: .6rem 0 .1rem; }
.shot-frame img[hidden] { display: none; }
.seg button[aria-selected="true"] { background: var(--text); color: var(--bg); }
.per-day { margin: -.6rem 0 0; font-size: .88rem; color: var(--accent); font-weight: 550; }
.recipe-actions { display: flex; flex-wrap: wrap; gap: .6rem; align-items: center; }
.home-check { display: flex; gap: .5rem; max-width: 460px; margin: 0 0 1.2rem; }
.home-check .input { flex: 1; min-width: 0; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
@media print { .toc, .answer, .sticky-cta, .theme-toggle { display: none !important; } .prose table { font-size: 10pt; } }
.recipe-tools { display: flex; flex-wrap: wrap; gap: .75rem; align-items: center; }
.hc-head .chip { white-space: nowrap; flex: none; }
