@import url('https://api.fontshare.com/v2/css?f[]=gambetta@400,500,600,700&f[]=switzer@300,400,500,600,700&display=swap');

:root {
  --text-xs: clamp(0.75rem, 0.7rem + 0.25vw, 0.875rem);
  --text-sm: clamp(0.875rem, 0.8rem + 0.35vw, 1rem);
  --text-base: clamp(1rem, 0.95rem + 0.25vw, 1.125rem);
  --text-lg: clamp(1.125rem, 1rem + 0.75vw, 1.5rem);
  --text-xl: clamp(1.5rem, 1.2rem + 1.25vw, 2.25rem);
  --text-2xl: clamp(2rem, 1.2rem + 2.5vw, 3.5rem);
  --text-3xl: clamp(2.5rem, 1.4rem + 3.4vw, 4.5rem);

  --space-1: 0.25rem;  --space-2: 0.5rem;   --space-3: 0.75rem;
  --space-4: 1rem;     --space-5: 1.25rem;  --space-6: 1.5rem;
  --space-8: 2rem;     --space-10: 2.5rem;  --space-12: 3rem;
  --space-16: 4rem;    --space-20: 5rem;    --space-24: 6rem;
  --space-32: 8rem;

  --font-display: 'Gambetta', 'Iowan Old Style', Georgia, serif;
  --font-body: 'Switzer', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

  --measure: 34rem;
  --wide: 74rem;
  --radius: 3px;
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
}

:root, [data-theme='light'] {
  --bg: #FCFBF8;
  --surface: #F5F2EB;
  --surface-2: #EFEBE1;
  --ink: #26221C;
  --body: #3A342C;
  --muted: #6E675D;
  --faint: #9C958A;
  --rule: #DED8CC;
  --accent: #7A4A2B;
  --accent-hover: #5E3720;
  --accent-soft: #F0E7DE;
  --inverse: #FCFBF8;
  --dark-panel: #26221C;
  --shadow: 0 1px 2px rgba(38,34,28,.05), 0 18px 44px -20px rgba(38,34,28,.22);
}

[data-theme='dark'] {
  --bg: #17150F;
  --surface: #1E1B15;
  --surface-2: #24211A;
  --ink: #F0EDE4;
  --body: #D6D1C5;
  --muted: #9A9385;
  --faint: #6E675B;
  --rule: #383328;
  --accent: #C98B5E;
  --accent-hover: #E0A578;
  --accent-soft: #2A2119;
  --inverse: #17150F;
  --dark-panel: #100E0A;
  --shadow: 0 1px 2px rgba(0,0,0,.4), 0 18px 44px -20px rgba(0,0,0,.7);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--body);
  font-family: var(--font-body);
  font-size: var(--text-base);
  font-weight: 400;
  line-height: 1.62;
  -webkit-font-smoothing: antialiased;
  font-feature-settings: 'kern' 1, 'liga' 1;
  transition: background-color .4s var(--ease), color .4s var(--ease);
}

h1, h2, h3 { font-family: var(--font-display); color: var(--ink); font-weight: 600; line-height: 1.08; letter-spacing: -0.015em; margin: 0; }
p { margin: 0 0 var(--space-5); }
strong { color: var(--ink); font-weight: 600; }
a { color: var(--accent); text-underline-offset: 3px; }

.wrap { width: 100%; max-width: var(--wide); margin-inline: auto; padding-inline: var(--space-6); }
.measure { max-width: var(--measure); }
section { padding-block: clamp(var(--space-16), 9vw, var(--space-32)); }

.eyebrow {
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 var(--space-5);
  display: flex; align-items: center; gap: var(--space-3);
}
.eyebrow::after { content: ''; height: 1px; flex: 1; background: var(--rule); max-width: 4rem; }

/* ---------- header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(14px) saturate(1.2);
  border-bottom: 1px solid transparent;
  transition: border-color .3s var(--ease), background-color .3s var(--ease);
}
.site-header.is-stuck { border-bottom-color: var(--rule); }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: var(--space-4); height: 68px; }
.brand { display: flex; align-items: center; gap: var(--space-3); color: var(--ink); text-decoration: none; }
.brand svg { color: var(--accent); flex: none; }
.brand-text { font-family: var(--font-display); font-size: var(--text-sm); font-weight: 600; letter-spacing: -0.01em; line-height: 1.15; }
.header-actions { display: flex; align-items: center; gap: var(--space-3); }

.theme-toggle {
  width: 36px; height: 36px; display: grid; place-items: center;
  border: 1px solid var(--rule); border-radius: var(--radius);
  background: transparent; color: var(--muted); cursor: pointer;
  transition: color .2s var(--ease), border-color .2s var(--ease);
}
.theme-toggle:hover { color: var(--ink); border-color: var(--muted); }
.theme-toggle .moon { display: none; }
[data-theme='dark'] .theme-toggle .sun { display: none; }
[data-theme='dark'] .theme-toggle .moon { display: block; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: var(--space-3);
  font-family: var(--font-body); font-size: var(--text-sm); font-weight: 600; letter-spacing: -0.005em;
  padding: var(--space-4) var(--space-8);
  border-radius: var(--radius); border: 1px solid transparent;
  text-decoration: none; cursor: pointer; white-space: nowrap;
  transition: background-color .2s var(--ease), transform .2s var(--ease), border-color .2s var(--ease), color .2s var(--ease);
}
.btn-primary { background: var(--accent); color: #FCFBF8; }
[data-theme='dark'] .btn-primary { color: #17150F; }
.btn-primary:hover { background: var(--accent-hover); transform: translateY(-1px); }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--rule); }
.btn-ghost:hover { border-color: var(--ink); }
.btn-sm { padding: var(--space-2) var(--space-5); font-size: var(--text-xs); }
.btn-lg { padding: var(--space-5) var(--space-10); font-size: var(--text-base); }
.btn:focus-visible, a:focus-visible, button:focus-visible, summary:focus-visible {
  outline: 2px solid var(--accent); outline-offset: 3px;
}

/* ---------- hero ---------- */
.hero { padding-top: clamp(var(--space-16), 8vw, var(--space-24)); padding-bottom: clamp(var(--space-16), 8vw, var(--space-24)); }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr); gap: clamp(var(--space-10), 6vw, var(--space-20)); align-items: center; }
.hero h1 { font-size: var(--text-3xl); font-weight: 600; letter-spacing: -0.03em; margin-bottom: var(--space-6); text-wrap: balance; }
.hero-sub { font-size: var(--text-lg); line-height: 1.45; color: var(--body); max-width: 30rem; margin-bottom: var(--space-8); }
.hero-cta { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-4); margin-bottom: var(--space-5); }
.hero-note { font-size: var(--text-xs); color: var(--muted); margin: 0; }
.hero-note span { color: var(--rule); margin-inline: var(--space-2); }

.cover-frame { position: relative; }
.cover-frame img {
  display: block; width: 100%; height: auto; border-radius: var(--radius);
  box-shadow: var(--shadow); border: 1px solid var(--rule);
}
[data-theme='dark'] .cover-frame img { border-color: #4A4438; }
.cover-frame::before {
  content: ''; position: absolute; inset: auto -6% -5% 12%; height: 60%;
  background: radial-gradient(ellipse at center, color-mix(in srgb, var(--accent) 16%, transparent), transparent 70%);
  filter: blur(30px); z-index: -1;
}
.cover-badge {
  position: absolute; top: var(--space-5); right: calc(-1 * var(--space-5));
  background: var(--dark-panel); color: #F0EDE4;
  font-size: var(--text-xs); font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase;
  padding: var(--space-2) var(--space-4); border-radius: var(--radius);
}

/* ---------- proof strip ---------- */
.strip { border-block: 1px solid var(--rule); background: var(--surface); padding-block: var(--space-10); }
.strip-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--space-8); }
.stat-n { font-family: var(--font-display); font-size: var(--text-xl); color: var(--ink); font-weight: 600; letter-spacing: -0.02em; line-height: 1.1; display: block; }
.stat-l { font-size: var(--text-xs); color: var(--muted); line-height: 1.4; display: block; margin-top: var(--space-2); }
.stat-l a { color: var(--muted); text-decoration-color: var(--rule); }
.stat-l a:hover { color: var(--accent); }

/* ---------- editorial ---------- */
.lede { font-family: var(--font-display); font-size: var(--text-lg); line-height: 1.42; color: var(--ink); }
.editorial p { font-size: var(--text-base); }
.pull {
  font-family: var(--font-display); font-size: var(--text-xl); line-height: 1.24; color: var(--ink);
  letter-spacing: -0.02em; border-left: 2px solid var(--accent);
  padding-left: var(--space-6); margin: var(--space-12) 0; max-width: 40rem;
}
.section-head { max-width: 40rem; margin-bottom: var(--space-12); }
.section-head h2 { font-size: var(--text-2xl); letter-spacing: -0.025em; margin-bottom: var(--space-5); text-wrap: balance; }
.section-head p { color: var(--muted); margin: 0; }

/* ---------- contents ---------- */
.parts { border-top: 1px solid var(--rule); }
.part {
  display: grid; grid-template-columns: 5rem minmax(0, 15rem) minmax(0, 1fr);
  gap: var(--space-6); padding-block: var(--space-8);
  border-bottom: 1px solid var(--rule);
}
.part-n { font-family: var(--font-display); font-size: var(--text-lg); color: var(--accent); line-height: 1.2; font-weight: 500; }
.part h3 { font-size: var(--text-lg); letter-spacing: -0.02em; }
.part p { font-size: var(--text-sm); color: var(--muted); margin: 0; }

/* ---------- spreads ---------- */
.spreads { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-8); margin-top: var(--space-12); }
.spreads img { width: 100%; height: auto; display: block; border: 1px solid var(--rule); border-radius: var(--radius); box-shadow: var(--shadow); }
.spread figcaption { font-size: var(--text-xs); color: var(--muted); margin-top: var(--space-4); }
.spread { margin: 0; }

/* ---------- two-col ---------- */
.cols { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(var(--space-10), 6vw, var(--space-20)); }
.card {
  background: var(--surface); border: 1px solid var(--rule); border-radius: var(--radius);
  padding: clamp(var(--space-6), 3vw, var(--space-10));
}
.card h3 { font-size: var(--text-lg); margin-bottom: var(--space-5); }
.card p:last-child { margin-bottom: 0; }

.list { list-style: none; padding: 0; margin: 0; }
.list li { position: relative; padding-left: var(--space-8); margin-bottom: var(--space-4); font-size: var(--text-sm); }
.list li:last-child { margin-bottom: 0; }
.list li::before {
  content: ''; position: absolute; left: 0; top: 0.62em;
  width: 14px; height: 1px; background: var(--accent);
}
.list-no li::before { background: var(--faint); }

/* ---------- lead magnet ---------- */
.magnet { background: var(--dark-panel); color: #D6D1C5; border-radius: var(--radius); padding: clamp(var(--space-8), 5vw, var(--space-16)); }
.magnet h2 { color: #F0EDE4; font-size: var(--text-xl); margin-bottom: var(--space-5); letter-spacing: -0.02em; }
.magnet p { color: #ABA396; max-width: 34rem; }
.magnet .eyebrow { color: #C98B5E; }
.magnet .eyebrow::after { background: #3A342C; }
.magnet .btn-ghost { color: #F0EDE4; border-color: #4A4438; }
.magnet .btn-ghost:hover { border-color: #F0EDE4; }
.magnet-note { font-size: var(--text-xs); color: #7E7668; margin: var(--space-4) 0 0; }

/* ---------- pricing ---------- */
.price-wrap { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 26rem); gap: clamp(var(--space-10), 6vw, var(--space-20)); align-items: start; }
.price-card {
  background: var(--surface); border: 1px solid var(--rule); border-radius: var(--radius);
  padding: clamp(var(--space-8), 4vw, var(--space-10)); box-shadow: var(--shadow); position: sticky; top: 92px;
}
.price-row { display: flex; align-items: baseline; gap: var(--space-3); margin-bottom: var(--space-2); }
.price-n { font-family: var(--font-display); font-size: var(--text-2xl); color: var(--ink); font-weight: 600; letter-spacing: -0.03em; line-height: 1; }
.price-unit { font-size: var(--text-sm); color: var(--muted); }
.price-card .btn { width: 100%; margin-top: var(--space-6); }
.price-meta { font-size: var(--text-xs); color: var(--muted); margin: var(--space-4) 0 0; text-align: center; }
.price-divider { height: 1px; background: var(--rule); margin-block: var(--space-8); }

/* ---------- faq ---------- */
.faq { border-top: 1px solid var(--rule); max-width: 46rem; }
.faq details { border-bottom: 1px solid var(--rule); }
.faq summary {
  list-style: none; cursor: pointer; padding-block: var(--space-6);
  font-family: var(--font-display); font-size: var(--text-lg); color: var(--ink);
  letter-spacing: -0.015em; display: flex; justify-content: space-between; align-items: center; gap: var(--space-6);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: '+'; font-family: var(--font-body); font-size: var(--text-lg); color: var(--accent); font-weight: 400; flex: none; transition: transform .25s var(--ease); }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq .answer { padding-bottom: var(--space-6); max-width: 40rem; }
.faq .answer p:last-child { margin-bottom: 0; }

/* ---------- footer ---------- */
.site-footer { border-top: 1px solid var(--rule); padding-block: var(--space-12); }
.footer-inner { display: flex; flex-wrap: wrap; gap: var(--space-8); justify-content: space-between; align-items: flex-start; }
.site-footer p { font-size: var(--text-xs); color: var(--muted); max-width: 34rem; margin: 0 0 var(--space-3); }
.footer-links { display: flex; gap: var(--space-6); font-size: var(--text-xs); }
.footer-links a { color: var(--muted); text-decoration: none; }
.footer-links a:hover { color: var(--accent); }

/* ---------- reveal ---------- */
.js .reveal { opacity: 0; transform: translateY(14px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.js .reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .js .reveal { opacity: 1; transform: none; } }

/* ---------- thank you ---------- */
.receipt { min-height: 100vh; display: grid; place-items: center; padding: var(--space-8); }
.receipt-card { max-width: 34rem; width: 100%; text-align: left; }
.receipt-card h1 { font-size: var(--text-2xl); margin-bottom: var(--space-5); letter-spacing: -0.025em; }
.dl-box { background: var(--surface); border: 1px solid var(--rule); border-radius: var(--radius); padding: var(--space-8); margin-block: var(--space-8); }
.dl-box .btn { width: 100%; }
.steps { counter-reset: s; list-style: none; padding: 0; margin: 0; }
.steps li { counter-increment: s; position: relative; padding-left: var(--space-10); margin-bottom: var(--space-5); font-size: var(--text-sm); }
.steps li::before {
  content: counter(s); position: absolute; left: 0; top: 0;
  width: 24px; height: 24px; border-radius: 50%; border: 1px solid var(--rule);
  display: grid; place-items: center; font-size: 11px; color: var(--accent); font-weight: 600;
}

/* ---------- responsive ---------- */
@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; gap: var(--space-12); }
  .cover-frame { max-width: 22rem; }
  .cover-badge { right: var(--space-5); }
  .strip-grid { grid-template-columns: 1fr 1fr; gap: var(--space-6); }
  .cols, .price-wrap, .spreads { grid-template-columns: 1fr; }
  .price-card { position: static; }
  .part { grid-template-columns: 1fr; gap: var(--space-3); }
  .part-n { font-family: var(--font-body); font-size: var(--text-xs); font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; }
}
@media (max-width: 560px) {
  .wrap { padding-inline: var(--space-5); }
  .hero-cta .btn { width: 100%; }
  .brand-text { font-size: var(--text-xs); }
}

/* Sample-by-email capture */
.magnet-form { margin: var(--space-6) 0 0; padding-top: var(--space-6); border-top: 1px solid #3A342C; }
.magnet-form label { display: block; font-size: var(--text-xs); color: #ABA396; margin-bottom: var(--space-3); max-width: 34rem; }
.magnet-row { display: flex; flex-wrap: wrap; gap: var(--space-3); align-items: stretch; }
.magnet-row input { flex: 1 1 16rem; min-width: 0; background: #221E19; border: 1px solid #4A4438; border-radius: 4px; color: #F0EDE4; padding: 0.85rem 1rem; font: inherit; font-size: var(--text-sm); }
.magnet-row input::placeholder { color: #6E675B; }
.magnet-row input:focus { outline: none; border-color: #C98B5E; }
.magnet-row .btn { flex: 0 0 auto; }
.magnet-status { font-size: var(--text-xs); margin: var(--space-3) 0 0; min-height: 1.2em; }
.magnet-status.ok { color: #9CBF8A; }
.magnet-status.err { color: #D99A8A; }
@media (max-width: 30rem) { .magnet-row .btn { width: 100%; } }
