/* Marrowe — marketing site styles
   Editorial minimalism, warm neutrals, ember accent.
   Type: Fraunces (display) + Inter (body) via Google Fonts. */

:root {
  --bg: #FAF8F4;
  --surface: #FCFAF7;
  --text: #1A1612;
  --text-muted: #6B6358;
  --border: #E8E2D7;
  --accent: #B8472E;
  --accent-hover: #9A3A24;
  --accent-soft: #FBF1EA;
  --severe: #B91C1C;
  --moderate: #C2410C;
  --preference: #1F2937;

  --serif: "Fraunces", Georgia, "Times New Roman", serif;
  --sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SF Mono", Consolas, monospace;

  --max-w: 1120px;
  --reading-w: 720px;
}

* { box-sizing: border-box; }
html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-hover); }

.container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 24px;
}
.reading {
  max-width: var(--reading-w);
  margin: 0 auto;
}

/* Utility spacing — sparingly */
.mt-4 { margin-top: 16px; }
.mt-5 { margin-top: 20px; }
.mt-6 { margin-top: 24px; }
.mb-12 { margin-bottom: 48px; }
.center { text-align: center; }

/* ─── Nav ─────────────────────────────────────────────────────── */

nav {
  position: sticky;
  top: 0;
  background: rgba(250, 248, 244, 0.85);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--border);
  z-index: 10;
}
nav .inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 24px;
  max-width: var(--max-w);
  margin: 0 auto;
}
nav .brand {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 22px;
  letter-spacing: -0.01em;
  color: var(--text);
  font-variation-settings: "opsz" 60;
}
nav .brand::before {
  content: "";
  display: inline-block;
  width: 22px;
  height: 22px;
  margin-right: 9px;
  vertical-align: -4px;
  background: url("logo.svg") center / contain no-repeat;
}
nav .links a {
  color: var(--text-muted);
  font-size: 15px;
  font-weight: 500;
  margin-left: 24px;
}
nav .links a:hover { color: var(--text); }

/* ─── Sections ────────────────────────────────────────────────── */

section { padding: 96px 0; }
@media (max-width: 720px) { section { padding: 64px 0; } }

.band {
  background: var(--surface);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.eyebrow {
  font-family: var(--sans);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 16px 0;
}

h1, h2, h3 {
  font-family: var(--serif);
  color: var(--text);
  letter-spacing: -0.02em;
  line-height: 1.1;
  margin: 0;
  font-variation-settings: "opsz" 144;
}
h1 { font-size: clamp(40px, 7vw, 72px); font-weight: 500; }
h2 { font-size: clamp(28px, 4.2vw, 44px); font-weight: 500; }
h3 { font-size: 22px; font-weight: 600; font-variation-settings: "opsz" 60; }

p { margin: 0; }
p.lede {
  font-size: clamp(18px, 2.4vw, 22px);
  line-height: 1.5;
  color: var(--text);
  max-width: 560px;
}
p.lede.center { margin-left: auto; margin-right: auto; }
p.caption {
  font-size: 15px;
  color: var(--text-muted);
  max-width: 540px;
}

/* ─── Hero ────────────────────────────────────────────────────── */

.hero {
  padding-top: 120px;
  padding-bottom: 120px;
}
.hero h1 { margin-bottom: 28px; }
.hero p.lede { margin-bottom: 40px; }

.cta-row {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  margin-top: 24px;
}
.cta {
  background: var(--text);
  color: var(--bg);
  border: 0;
  padding: 14px 22px;
  font-family: var(--sans);
  font-size: 15px;
  font-weight: 600;
  border-radius: 999px;
  cursor: pointer;
  transition: transform 200ms cubic-bezier(0.2, 0.8, 0.2, 1), background 160ms;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  line-height: 1;
}
.cta:hover { background: var(--accent); }
.cta:active { transform: scale(0.97); }
.cta .check {
  width: 16px; height: 16px;
  opacity: 0;
  transform: translateX(-6px);
  transition: opacity 160ms, transform 160ms cubic-bezier(0.2, 0.8, 0.2, 1);
}
.cta.copied .check { opacity: 1; transform: translateX(0); }

.hero .meta {
  font-size: 14px;
  color: var(--text-muted);
  margin-top: 16px;
}

/* ─── Mock cards ──────────────────────────────────────────────── */

.mock {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 28px;
  box-shadow: 0 1px 2px rgba(26, 22, 18, 0.04), 0 8px 32px rgba(26, 22, 18, 0.06);
  max-width: 580px;
  margin: 48px auto 0;
}
.mock--flush { margin: 0; }

.mock .mock-title {
  font-family: var(--serif);
  font-size: 22px;
  font-weight: 600;
  color: var(--text);
  margin: 0 0 6px 0;
  font-variation-settings: "opsz" 60;
}
.mock-title--lg { font-size: 28px; }

.mock .mock-meta {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.05em;
  color: var(--text-muted);
  margin-bottom: 20px;
  text-transform: uppercase;
}

.mock .allergen-block {
  background: var(--accent-soft);
  border: 1px solid #f5dac9;
  border-radius: 8px;
  padding: 14px 16px;
  margin-bottom: 20px;
}
.mock .allergen-block .label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: var(--severe);
  text-transform: uppercase;
  margin-bottom: 6px;
}
.mock .allergen-row {
  display: flex;
  align-items: baseline;
  gap: 12px;
  font-size: 14px;
  margin: 4px 0;
}
.mock .badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 3px;
  background: var(--severe);
  color: #F5F0E8;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.05em;
  min-width: 64px;
  text-align: center;
}
.mock .badge.moderate { background: var(--moderate); }
.mock .badge.pref { background: var(--preference); }

.mock .mock-section { margin-top: 18px; }
.mock .mock-section h4 {
  font-family: var(--sans);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  text-transform: uppercase;
  margin: 0 0 8px 0;
}
.mock .mock-section ul {
  list-style: none;
  margin: 0;
  padding: 0;
}
.mock .mock-section li {
  font-size: 15px;
  margin: 4px 0;
}
.mock .mock-section li .count {
  font-family: var(--mono);
  color: var(--text-muted);
  font-size: 13px;
}
.mock .timeline {
  display: grid;
  grid-template-columns: 60px 1fr;
  gap: 6px 16px;
  font-size: 14px;
}
.mock .timeline .t {
  font-family: var(--mono);
  color: var(--text);
  font-weight: 500;
}

/* Event-page mock specifics */
.page-date {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  text-transform: uppercase;
  margin-bottom: 8px;
}
.page-meta {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--text-muted);
  margin: 6px 0 20px 0;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.photo-placeholder {
  aspect-ratio: 16 / 10;
  background: linear-gradient(135deg, #2A2018, #4A3A2E);
  border-radius: 6px;
  margin-bottom: 20px;
}
.quote {
  font-family: var(--serif);
  font-style: italic;
  font-size: 16px;
  line-height: 1.5;
  color: var(--text);
  margin: 0;
  font-variation-settings: "opsz" 24;
}
.page-footer {
  margin-top: 24px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  text-transform: uppercase;
}

/* ─── Two-column section ──────────────────────────────────────── */

.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
}
@media (max-width: 880px) {
  .split { grid-template-columns: 1fr; gap: 48px; }
}

/* ─── Book mock ───────────────────────────────────────────────── */

.book {
  aspect-ratio: 4 / 5;
  background: linear-gradient(135deg, #2A2018 0%, #1A1612 100%);
  border-radius: 4px;
  padding: 48px 32px;
  color: #F5F0E8;
  box-shadow:
    0 1px 2px rgba(0, 0, 0, 0.2),
    0 20px 60px rgba(26, 22, 18, 0.3),
    inset 4px 0 0 0 rgba(184, 71, 46, 0.6);
  max-width: 360px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.book .book-top {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  opacity: 0.6;
}
.book .book-top.mt-4 { margin-top: 16px; }
.book .book-title {
  font-family: var(--serif);
  font-size: 36px;
  font-weight: 500;
  line-height: 1.05;
  font-variation-settings: "opsz" 144;
}
.book .book-bottom {
  font-family: var(--serif);
  font-size: 14px;
  letter-spacing: 0.02em;
  opacity: 0.8;
  font-variation-settings: "opsz" 14;
}

/* ─── Pricing ─────────────────────────────────────────────────── */

.pricing {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 8px;
}
.pricing .row {
  display: grid;
  grid-template-columns: 200px 1fr auto;
  gap: 24px;
  align-items: center;
  padding: 24px;
  border-radius: 8px;
}
.pricing .row + .row { border-top: 1px solid var(--border); }
.pricing .label {
  font-family: var(--serif);
  font-size: 22px;
  font-weight: 600;
  font-variation-settings: "opsz" 60;
}
.pricing .desc {
  color: var(--text-muted);
  font-size: 15px;
}
.pricing .price {
  font-family: var(--mono);
  font-size: 18px;
  font-weight: 500;
  white-space: nowrap;
}
@media (max-width: 720px) {
  .pricing .row { grid-template-columns: 1fr; gap: 8px; }
  .pricing .price { font-size: 16px; }
}

/* ─── Founder ─────────────────────────────────────────────────── */

.founder {
  background: var(--accent-soft);
  border-radius: 12px;
  padding: 48px;
}
@media (max-width: 720px) {
  .founder { padding: 32px 24px; }
}
.founder p {
  font-family: var(--serif);
  font-size: clamp(18px, 2.4vw, 22px);
  font-weight: 400;
  line-height: 1.5;
  color: var(--text);
  font-variation-settings: "opsz" 24;
  max-width: 620px;
}
.founder p + p { margin-top: 16px; }
.founder .sig {
  margin-top: 28px;
  font-family: var(--sans);
  font-size: 14px;
  color: var(--text-muted);
}

/* ─── Footer ──────────────────────────────────────────────────── */

footer {
  border-top: 1px solid var(--border);
  padding: 48px 24px;
  color: var(--text-muted);
  font-size: 13px;
}
footer .inner {
  max-width: var(--max-w);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}
footer .brand {
  font-family: var(--serif);
  font-weight: 600;
  color: var(--text);
  font-size: 18px;
  font-variation-settings: "opsz" 24;
}
footer .links a { color: var(--text-muted); margin-left: 20px; }
footer .links a:hover { color: var(--text); }

/* ─── Legal pages (privacy, terms) ────────────────────────────── */

main.legal {
  padding: 64px 0 96px;
}
main.legal .legal-crumb {
  margin: 0 0 32px 0;
  font-size: 14px;
}
main.legal .legal-crumb a {
  color: var(--text-muted);
}
main.legal .legal-crumb a:hover {
  color: var(--text);
}
main.legal h1 {
  font-size: clamp(36px, 5vw, 52px);
  margin: 0 0 8px 0;
  font-weight: 500;
}
main.legal .legal-meta {
  color: var(--text-muted);
  font-size: 14px;
  margin: 0 0 48px 0;
}
main.legal .legal-meta .mono {
  font-family: var(--mono);
  font-size: 13px;
}
main.legal section {
  padding: 0;
  margin-top: 40px;
  border-top: 1px solid var(--border);
  padding-top: 28px;
}
main.legal section:first-of-type {
  border-top: 0;
  padding-top: 0;
  margin-top: 0;
}
main.legal h2 {
  font-size: clamp(20px, 2.6vw, 26px);
  font-weight: 600;
  margin: 0 0 16px 0;
  font-variation-settings: "opsz" 24;
}
main.legal h3 {
  font-size: 16px;
  font-weight: 600;
  font-family: var(--sans);
  letter-spacing: 0.01em;
  margin: 20px 0 8px 0;
  color: var(--text);
}
main.legal p,
main.legal li {
  font-size: 16px;
  line-height: 1.65;
  color: var(--text);
}
main.legal p + p {
  margin-top: 12px;
}
main.legal ul,
main.legal ol {
  padding-left: 20px;
  margin: 12px 0;
}
main.legal li + li {
  margin-top: 6px;
}
main.legal a {
  text-decoration: underline;
  text-underline-offset: 2px;
  text-decoration-color: rgba(184, 71, 46, 0.4);
}
main.legal a:hover {
  text-decoration-color: var(--accent);
}
main.legal code {
  font-family: var(--mono);
  font-size: 0.9em;
  background: var(--accent-soft);
  padding: 1px 6px;
  border-radius: 3px;
  color: var(--text);
}
main.legal strong {
  font-weight: 600;
  color: var(--text);
}
main.legal em {
  font-style: italic;
}
main.legal .legal-callout {
  background: var(--accent-soft);
  border-radius: 6px;
  padding: 20px 24px;
  margin: 0 0 40px 0;
}
main.legal .legal-callout p {
  margin: 0;
  font-size: 15px;
  line-height: 1.6;
}

/* ─── Scroll-reveal motion (Apple-style, IntersectionObserver-driven) ─

   data-reveal           default state: hidden + 24px below resting position
   .is-visible           applied by IntersectionObserver when 15% in view
   data-reveal-delay     stagger for hero composition (0..4)

   Easing: ease-out-expo (0.16, 1, 0.3, 1) is Apple's go-to long-tail
   decelerator. Quick start, gentle settle.
*/

[data-reveal] {
  opacity: 0;
  transform: translate3d(0, 24px, 0);
  transition:
    opacity 700ms cubic-bezier(0.16, 1, 0.3, 1),
    transform 700ms cubic-bezier(0.16, 1, 0.3, 1);
  will-change: opacity, transform;
}
[data-reveal].is-visible {
  opacity: 1;
  transform: translate3d(0, 0, 0);
}

[data-reveal-delay="1"] { transition-delay: 70ms; }
[data-reveal-delay="2"] { transition-delay: 140ms; }
[data-reveal-delay="3"] { transition-delay: 210ms; }
[data-reveal-delay="4"] { transition-delay: 280ms; }

/* ─── Reduced motion ──────────────────────────────────────────── */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
  [data-reveal] {
    opacity: 1;
    transform: none;
  }
}
