/* DeepWord 3.0 marketing — tokens from app constants/theme.ts and constants/type.ts */
:root {
  --violet-top: #423A95;
  --violet-bottom: #221C54;
  --violet-mid: #322E78;
  --violet-bright: #5C52B0;
  --violet-light: #9C95D5;
  --violet-lighter: #BEB8E5;
  --cream: #E8DFC8;
  --cream-light: #F5F1E8;
  --ink-brand: #1A1530;

  --primary: #5C52B0;
  --on-primary: #ffffff;
  --primary-bg: #F1F0FA;
  --primary-bg-strong: #E6E4F6;
  --primary-bg-subtle: #F7F6FC;
  --primary-dark: #322E78;
  --primary-border: #D9D6EE;

  --text: #23202E;
  --text-secondary: #3A3648;
  --text-muted: #585e6a;
  --text-faint: #666d7a;

  --bg: #FBFAF7;
  --bg-secondary: #F4F2EE;
  --bg-tertiary: #ECE9E3;
  --border: #E6E2DA;
  --border-light: #F0EDE7;
  --border-strong: #cbd2da;

  --success: #059669;
  --zone3: #4A6638;
  --zone3-band: #ECEEE2;

  --summary-surface: #F5F1E8;
  --summary-rule: #ded2b4;
  --summary-text: #4a4438;

  --hero-surface: #2E2A5C;
  --hero-text: #FFFFFF;
  --hero-text-soft: rgba(255, 255, 255, 0.72);
  --tint-cream: #F5F1E8;
  --tint-sage: #ECEEE2;
  --tint-mist: #EAEEF4;
  --tint-warm: #F1EEE8;
  --orig-rule: #DCE2EA;
  --panel-rim: rgba(35, 32, 46, 0.10);
  --study-word: #E6E1D8;
  --study-word-rim: #8A8478;

  --brand-divider: rgba(34, 28, 84, 0.08);
  --brand-border: rgba(34, 28, 84, 0.12);

  /* Type scale (app TypeScale), stepped up one for marketing reading */
  --fs-micro: 11px;
  --fs-small: 13px;
  --fs-body: 15px;
  --fs-reading: 17px;
  --fs-title: 20px;
  --fs-subdisplay: 23px;
  --fs-display: 27px;
  --fs-hero: 36px;
  --fs-giant: 48px;

  --sans: "Inter", -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", system-ui, sans-serif;
  --serif: "Source Serif 4", "Iowan Old Style", Palatino, "Palatino Linotype", "Book Antiqua", Georgia, serif;
  --hebrew: "Noto Serif Hebrew", "Times New Roman", serif;

  --space-4: 4px;
  --space-8: 8px;
  --space-16: 16px;
  --space-24: 24px;
  --space-page: 20px;
  --space-zone: 24px;
  --space-panel: 12px;
  --target: 44px;

  --radius-card: 16px;
  --radius-panel: 14px;
  --radius-pill: 999px;
  --radius-device: 36px;
  --radius-screen: 26px;
  --button-rim: 1px;

  --wrap: 1120px;
  --reading: 700px;
  --nav-h: 72px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--sans);
  font-size: var(--fs-reading);
  font-weight: 400;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--primary); font-weight: 600; text-decoration: none; }
a:hover { text-decoration: underline; }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 24px; }
.reading { width: 100%; max-width: var(--reading); margin: 0 auto; padding: 0 24px; }

/* Eyebrow / section header — app sectionHeader: 15 italic 600 */
.eyebrow {
  font-size: var(--fs-body);
  font-weight: 600;
  font-style: italic;
  color: var(--primary);
  margin-bottom: 10px;
}
.section-title {
  font-family: var(--serif);
  font-size: clamp(28px, 4.2vw, 48px);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.15;
  color: var(--text);
  margin-bottom: 14px;
}
.section-sub {
  font-size: var(--fs-reading);
  color: var(--text-secondary);
  max-width: 38em;
  line-height: 1.65;
}
.section-sub + .section-sub, .lead { margin-top: 12px; }

/* Buttons — 44pt target, 1pt rim in a deeper shade of the fill, pill */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: var(--target);
  padding: 0 22px;
  border-radius: var(--radius-pill);
  font-family: var(--sans);
  font-size: var(--fs-body);
  font-weight: 600;
  line-height: 1;
  text-decoration: none;
  border: var(--button-rim) solid transparent;
  cursor: pointer;
  transition: transform 150ms ease, background 150ms ease, box-shadow 150ms ease;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }
.btn-primary {
  background: var(--primary);
  color: var(--on-primary);
  border-color: #4B4399; /* buttonStroke of #5C52B0 on light */
  box-shadow: 0 8px 20px rgba(92, 82, 176, 0.28);
}
.btn-primary:hover { background: var(--violet-mid); }
.btn-on-hero {
  background: var(--cream);
  color: var(--ink-brand);
  border-color: #d4c9ae;
}
.btn-on-hero:hover { background: #F5F1E8; }
.btn-ghost {
  background: transparent;
  color: var(--hero-text);
  border-color: rgba(255,255,255,0.35);
}
.btn-ghost:hover { background: rgba(255,255,255,0.08); }
.btn-large { min-height: 52px; padding: 0 28px; font-size: var(--fs-reading); }

/* NAV */
.site-nav {
  position: sticky;
  top: 0;
  z-index: 40;
  height: var(--nav-h);
  background: rgba(251, 250, 247, 0.88);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--panel-rim);
}
.site-nav .wrap {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  text-decoration: none;
  font-family: var(--serif);
  font-weight: 600;
  font-size: 22px;
  letter-spacing: -0.02em;
}
.logo:hover { text-decoration: none; color: var(--text); }
.logo svg, .logo img { width: 32px; height: 32px; border-radius: 8px; }
.nav-links { display: flex; align-items: center; gap: 22px; }
.nav-links a {
  color: var(--text-secondary);
  font-weight: 600;
  font-size: var(--fs-body);
}
.nav-links a:hover { color: var(--primary); text-decoration: none; }

/* Hero — app heroSurface #2E2A5C, with the previous site's scribe background */
.hero {
  position: relative;
  background: var(--hero-surface);
  color: var(--hero-text);
  padding: 56px 0 72px;
  overflow: hidden;
}
.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}
.hero-bg video,
.hero-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center right;
  display: block;
  opacity: 0.26;
}
.hero-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg,
    var(--hero-surface) 0%,
    rgba(46, 42, 92, 0.88) 34%,
    rgba(46, 42, 92, 0.40) 58%,
    rgba(46, 42, 92, 0.10) 82%,
    rgba(46, 42, 92, 0.00) 100%);
}
.hero .wrap,
.hero-grid { position: relative; z-index: 1; }
.hero-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: center;
}
.hero h1 {
  font-family: var(--serif);
  font-size: clamp(36px, 5.4vw, 64px);
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1.08;
  color: var(--hero-text);
  margin: 0 0 18px;
}
.hero h1 .hl { color: var(--cream); }
.hero-subnote, .hero-note {
  font-size: var(--fs-reading);
  color: var(--hero-text-soft);
  max-width: 36em;
  margin-bottom: 16px;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.hero-kicker {
  font-size: var(--fs-micro);
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--violet-light);
  margin-bottom: 14px;
}

/* Feature bands */
.band { padding: 88px 0; }
.band-page { background: var(--bg); }
.band-cream { background: var(--tint-cream); }
.band-mist { background: var(--tint-mist); }
.band-warm { background: var(--tint-warm); }
.band-sage { background: var(--tint-sage); }
.band-ink {
  background: var(--hero-surface);
  color: var(--hero-text);
}
.band-ink .section-title,
.band-ink .eyebrow { color: var(--cream); }
.band-ink .section-sub { color: var(--hero-text-soft); }

.feature {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}
.feature.flip { direction: rtl; }
.feature.flip > * { direction: ltr; }
.feature-copy h2 { margin-bottom: 16px; }
.feature-copy p { color: var(--text-secondary); margin-bottom: 14px; max-width: 36em; }
.feature-copy p strong { color: var(--text); font-weight: 600; }

/* Device frame */
.device {
  width: min(100%, 340px);
  margin: 0 auto;
  background: var(--ink-brand);
  border-radius: var(--radius-device);
  padding: 10px;
  box-shadow:
    0 0 0 1px rgba(255,255,255,0.06),
    0 24px 60px rgba(26, 21, 48, 0.28);
}
.device-screen {
  border-radius: var(--radius-screen);
  overflow: hidden;
  background: var(--bg);
  aspect-ratio: 1179 / 2396;
  position: relative;
}
.device-screen img {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: top center;
}
.device-caption {
  text-align: center;
  font-size: var(--fs-small);
  color: var(--text-muted);
  margin-top: 14px;
  font-style: italic;
}

/* Panel cards — tinted, hairline rim, like Word Study */
.panel {
  background: var(--bg);
  border: 0.5px solid var(--panel-rim);
  border-radius: var(--radius-panel);
  padding: 22px 24px;
  box-shadow: 0 1px 0 var(--panel-rim);
}
.panel-mist { background: var(--tint-mist); }
.panel-cream { background: var(--tint-cream); }
.panel-sage { background: var(--tint-sage); }
.panel-warm { background: var(--tint-warm); }
.panel h3, .panel-title {
  font-size: var(--fs-reading);
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--text);
}
.panel p, .panel-body { color: var(--text-secondary); font-size: var(--fs-body); }
.panel-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-panel);
  margin-top: 32px;
}

/* Compare */
.compare { padding: 88px 0; background: var(--bg-secondary); }
.compare-table { overflow-x: auto; margin-top: 32px; border-radius: var(--radius-card); border: 0.5px solid var(--panel-rim); background: var(--bg); }
.compare-table table { width: 100%; border-collapse: collapse; font-size: var(--fs-small); }
.compare-table th, .compare-table td {
  padding: 12px 10px;
  text-align: center;
  border-bottom: 0.5px solid var(--panel-rim);
  color: var(--text-secondary);
}
.compare-table th { font-weight: 600; color: var(--text); background: var(--tint-mist); }
.compare-table td:first-child, .compare-table th:first-child {
  text-align: left; font-weight: 600; color: var(--text); min-width: 180px;
}
.compare-table td.deepword { background: var(--primary-bg-subtle); color: var(--text); font-weight: 600; }
.compare-table th.deepword { background: var(--hero-surface); color: var(--cream); }
.compare-table .check { color: var(--zone3); font-weight: 600; }
.compare-table .dash { color: var(--text-faint); }
.compare-table .row-note { display: block; font-weight: 400; font-size: 11px; color: var(--text-muted); margin-top: 2px; }
.dw-head { display: inline-flex; align-items: center; gap: 6px; }
.dw-mark { width: 18px; height: 18px; }

/* FAQ */
.faq { padding: 88px 0; background: var(--tint-cream); }
.faq details {
  background: var(--bg);
  border: 0.5px solid var(--panel-rim);
  border-radius: var(--radius-panel);
  padding: 4px 20px;
  margin-bottom: 10px;
}
.faq summary {
  cursor: pointer;
  font-weight: 600;
  font-size: var(--fs-reading);
  padding: 14px 0;
  list-style: none;
  color: var(--text);
}
.faq summary::-webkit-details-marker { display: none; }
.faq .faq-answer, .faq details > div {
  padding: 0 0 16px;
  color: var(--text-secondary);
  font-size: var(--fs-body);
  line-height: 1.65;
}

/* Keep / CTA */
.keep { padding: 88px 0; background: var(--hero-surface); color: var(--hero-text); text-align: center; }
.keep .section-title { color: var(--cream); }
.keep .section-sub { color: var(--hero-text-soft); margin: 0 auto 28px; }
.keep .price-note { color: var(--hero-text-soft); font-size: var(--fs-small); margin-top: 24px; max-width: 36em; margin-left: auto; margin-right: auto; }
.keep .price-note a { color: var(--cream); }

/* Made by */
.made-by {
  max-width: 640px;
  margin: 48px auto 0;
  text-align: center;
  padding: 32px;
  background: rgba(255,255,255,0.06);
  border: 0.5px solid rgba(255,255,255,0.12);
  border-radius: var(--radius-card);
  color: var(--hero-text-soft);
}
.made-by img { width: 96px; height: 96px; border-radius: 50%; object-fit: contain; margin: 0 auto 16px; border: 3px solid var(--cream); }
.made-by strong { color: var(--cream); }

/* Footer */
.site-footer {
  background: var(--violet-bottom);
  color: var(--cream);
  padding: 48px 0 40px;
  text-align: center;
}
.site-footer .logo { color: var(--cream); justify-content: center; margin-bottom: 14px; }
.site-footer p { color: var(--cream); opacity: 0.78; font-size: var(--fs-small); line-height: 1.7; }
.site-footer a { color: var(--cream); font-weight: 500; }
.site-footer .foot-links { margin-top: 14px; display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; }
.site-footer .dot { opacity: 0.4; }

/* Inner pages */
.page-main { padding: 72px 0 100px; }
.page-main h1 {
  font-family: var(--serif);
  font-size: clamp(32px, 5vw, 56px);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.1;
  margin-bottom: 16px;
  color: var(--text);
}
.page-main h2 {
  font-family: var(--serif);
  font-size: var(--fs-display);
  font-weight: 600;
  margin: 48px 0 14px;
  color: var(--text);
}
.page-main p { margin-bottom: 14px; }
.page-main .lede, .page-main .intro {
  font-family: var(--serif);
  font-size: 22px;
  line-height: 1.45;
  color: var(--violet-mid);
  background: var(--bg);
  border-left: 4px solid var(--hero-surface);
  padding: 20px 24px;
  border-radius: 8px;
  margin-bottom: 24px;
}
.last-updated, .page-main .updated { color: var(--text-muted); font-size: var(--fs-small); font-style: italic; margin-bottom: 36px; }

/* Sticky mobile CTA */
.mobile-sticky-cta {
  display: none;
  position: fixed;
  left: 16px; right: 16px; bottom: 16px;
  z-index: 30;
}
.mobile-sticky-cta a {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  border-radius: var(--radius-pill);
  background: var(--primary);
  color: #fff;
  font-weight: 600;
  box-shadow: 0 10px 28px rgba(92, 82, 176, 0.35);
  border: 1px solid #4B4399;
}
.mobile-sticky-cta a:hover { text-decoration: none; }

/* Reveal */
.reveal { opacity: 0; transform: translateY(14px); animation: rise 700ms ease forwards; }
@keyframes rise { to { opacity: 1; transform: none; } }

@media (max-width: 880px) {
  .hero-grid, .feature, .feature.flip { grid-template-columns: 1fr; direction: ltr; gap: 36px; }
  .hero:has(.hero-grid) { padding: 36px 0 48px; text-align: left; }
  .hero-bg::after {
    background: linear-gradient(180deg,
      var(--hero-surface) 0%,
      rgba(46, 42, 92, 0.92) 38%,
      rgba(46, 42, 92, 0.55) 62%,
      rgba(46, 42, 92, 0.18) 100%);
  }
  .band { padding: 64px 0; }
  .panel-grid { grid-template-columns: 1fr; }
  .nav-links a:not(.btn) { display: none; }
  .mobile-sticky-cta { display: block; }
  body { padding-bottom: 84px; }
  .device { width: min(100%, 280px); }
}
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; animation: none; }
  .btn:hover { transform: none; }
  html { scroll-behavior: auto; }
  .hero-bg {
    background: url('/screenshots/hero-scribe.jpg') no-repeat center right;
    background-size: cover;
  }
  .hero-bg video { display: none; }
}

/* Inner-page bridges */
header.hero {
  background: var(--hero-surface) !important;
}
.feature-list li,
.highlight-box,
.igc-price, .reassure {
  background: var(--tint-cream) !important;
  border-color: var(--panel-rim) !important;
}
.cta-box {
  background: var(--hero-surface) !important;
  color: var(--cream) !important;
  border-radius: var(--radius-card) !important;
}
.page-main ul li, main .feature-list li {
  background: var(--bg);
}

/* Chrome shields — leftover page CSS must not restyle the 3.0 bar */
.site-nav { background: rgba(251, 250, 247, 0.88) !important; color: var(--text); }
.site-nav .logo, .site-nav .logo span, .site-nav .logo-text { color: var(--text) !important; }
.site-nav .nav-links a { color: var(--text-secondary) !important; }
.site-nav .btn-primary { background: var(--primary) !important; color: var(--on-primary) !important; border-color: #4B4399 !important; display: inline-flex !important; }
@media (max-width: 880px) {
  .site-nav .nav-links a:not(.btn) { display: none !important; }
}
.site-footer { background: var(--violet-bottom) !important; color: var(--cream) !important; }
.site-footer .logo, .site-footer .logo span, .site-footer .logo-text, .site-footer a, .site-footer p { color: var(--cream) !important; }
