/* Marrow marketing site — Warm Library design system.
   Values mirror the app's src/theme/tokens.ts exactly. Shared by index/privacy/terms. */

:root {
  /* Surfaces */
  --bg: #F7F5EE;            /* Warm Off-White */
  --surface: #FDFCF0;       /* Rich Cream card */
  --surface-alt: #F1EFE3;   /* tinted sections / chips */
  --surface-sunken: #EDEBDF;
  /* Ink */
  --ink: #1B1C15;
  --on-accent: #F7F5EE;
  --muted: #434843;
  --border: #C3C8C1;
  --border-strong: #8A8A8A;
  --stone: #A8A29E;
  /* Brand */
  --green: #1B3022;
  --green-pressed: #061B0E;
  --green-soft: #D0E9D4;
  --gold: #C5A059;         /* accent only (dots, borders) — NOT text (fails AA as text) */
  --gold-text: #7D6222;    /* AA-safe gold for text (>=4.5:1 on cream/surface-alt) */
  --gold-soft: #F1E4C6;
  --olive: #707751;
  --olive-soft: #E0E7B9;
  --danger: #BA1A1A;
  /* Type */
  --serif: 'Source Serif 4', Georgia, 'Times New Roman', serif;
  --sans: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  /* Radius */
  --r-sm: 8px; --r-md: 16px; --r-lg: 20px; --r-xl: 28px; --r-pill: 999px;
  /* Elevation (forest @ low opacity) */
  --shadow-card: 0 4px 12px rgba(27,48,34,.05);
  --shadow-float: 0 8px 20px rgba(27,48,34,.10);
  --maxw: 1080px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
a { color: var(--green); text-decoration: none; }
a:hover { text-decoration: underline; }
img, svg { display: block; max-width: 100%; }

/* ---- Layout ---- */
.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }
.section { padding: 88px 0; }
.section--tight { padding: 56px 0; }

/* ---- Type ---- */
h1, h2, h3 { font-family: var(--serif); font-weight: 600; letter-spacing: -0.5px; margin: 0; line-height: 1.1; }
.eyebrow {
  font-family: var(--sans); font-weight: 600; font-size: 12px; letter-spacing: 0.09em;
  text-transform: uppercase; color: var(--gold-text); margin: 0 0 14px;
}
.lede { font-size: 20px; color: var(--muted); line-height: 1.55; }

/* ---- Header ---- */
.site-header {
  position: sticky; top: 0; z-index: 20;
  background: rgba(247,245,238,.86); backdrop-filter: saturate(120%) blur(10px);
  border-bottom: 1px solid var(--border);
}
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; height: 68px; }
.brand { display: flex; align-items: center; gap: 10px; }
.brand svg { height: 30px; width: auto; }
.brand .mark { height: 30px; width: 30px; }
.nav { display: flex; align-items: center; gap: 28px; }
.nav a { color: var(--muted); font-size: 15px; font-weight: 500; }
.nav a:hover { color: var(--ink); text-decoration: none; }

/* ---- Buttons ---- */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--sans); font-weight: 600; font-size: 16px;
  padding: 15px 26px; border-radius: var(--r-pill); border: 1px solid transparent;
  cursor: pointer; transition: transform .16s ease, background .16s ease;
}
.btn:hover { text-decoration: none; }
.btn--primary { background: var(--green); color: var(--on-accent); }
.btn--primary:hover { background: var(--green-pressed); transform: translateY(-1px); }
.btn--ghost { background: transparent; color: var(--green); border-color: var(--border-strong); }
.btn--ghost:hover { background: var(--surface-alt); }
.btn[aria-disabled="true"] { opacity: .6; cursor: default; }
.btn[aria-disabled="true"]:hover { transform: none; background: var(--green); }

/* Visible keyboard focus (design-system ring). */
a:focus-visible, .btn:focus-visible { outline: 2px solid var(--green); outline-offset: 3px; border-radius: 4px; }
.site-footer a:focus-visible { outline-color: var(--on-accent); }
.cta-band a:focus-visible { outline-color: var(--on-accent); }

/* ---- Footer ---- */
.site-footer { background: var(--green); color: var(--on-accent); padding: 56px 0 40px; }
.site-footer a { color: var(--on-accent); opacity: .85; }
.site-footer a:hover { opacity: 1; }
.footer-grid { display: flex; flex-wrap: wrap; gap: 40px; justify-content: space-between; align-items: flex-start; }
.footer-brand .wm { font-family: var(--serif); font-weight: 600; font-size: 26px; letter-spacing: -1px; }
.footer-brand p { color: #A9B7AC; font-size: 14px; margin: 8px 0 0; max-width: 320px; }
.footer-links { display: flex; gap: 48px; flex-wrap: wrap; }
.footer-col h3 { font-family: var(--sans); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: #A9B7AC; margin: 0 0 12px; font-weight: 600; }
.footer-col a { display: block; font-size: 15px; padding: 4px 0; }
.footer-legal { margin-top: 40px; padding-top: 24px; border-top: 1px solid rgba(247,245,238,.15); font-size: 13px; color: #A9B7AC; }

/* ---- Prose (privacy/terms) ---- */
.prose { max-width: 760px; margin: 0 auto; padding: 64px 24px 88px; }
.prose h1 { font-size: 40px; margin: 0 0 6px; }
.prose .updated { color: var(--muted); font-size: 15px; margin: 0 0 8px; }
.prose h2 { font-size: 23px; margin: 40px 0 12px; }
.prose h3 { font-size: 18px; margin: 28px 0 8px; }
.prose p, .prose li { font-size: 16px; color: #2c2b24; margin: 0 0 14px; }
.prose ul { padding-left: 22px; }
.prose strong { font-weight: 600; }
.prose .note {
  background: var(--surface-alt); border-left: 3px solid var(--olive);
  padding: 14px 18px; border-radius: var(--r-sm); font-size: 15px; color: var(--muted);
}
.prose code { background: var(--surface-alt); padding: 1px 6px; border-radius: 5px; font-size: 14px; }

/* ---- Motion (respect reduce-motion) ---- */
@media (prefers-reduced-motion: no-preference) {
  .reveal { opacity: 0; transform: translateY(14px); animation: rise .6s ease forwards; }
  .reveal.d1 { animation-delay: .08s; }
  .reveal.d2 { animation-delay: .16s; }
  .reveal.d3 { animation-delay: .24s; }
  .reveal.d4 { animation-delay: .32s; }
  @keyframes rise { to { opacity: 1; transform: none; } }
}

/* ---- Responsive ---- */
@media (max-width: 720px) {
  body { font-size: 16px; }
  .section { padding: 60px 0; }
  .nav { gap: 16px; }
  .nav .nav-hide { display: none; }
}
