/* ==========================================================
   Jesus First — site styles
   Warm "morning paper" palette, serif display, clean sans body
   ========================================================== */

:root {
  --paper: #f8f2e7;
  --paper-2: #f1e8d7;
  --card: #fffaf1;
  --ink: #1d2131;
  --ink-soft: #4b5063;
  --ink-faint: #7a7d8a;
  --gold: #b5832a;
  --gold-soft: #e9c98f;
  --clay: #a14b2e;
  --night: #1a2036;
  --night-2: #232b47;
  --line: #e2d6c1;
  --ok: #3f7a4f;
  --on-gold: #fff;
  --on-night: #f3ecdf;
  --on-night-soft: #c9c3b7;
  --on-night-faint: #a9a49b;
  --cover-1: #232b47;
  --cover-2: #1a2036;
  --cover-ink: #f6eedf;
  --sun-1: #f5d59a;
  --sun-2: #e3a95a;
  --sheet: #fff;
  --notice-bg: #fff4d9;

  --font-display: "Fraunces", Georgia, "Times New Roman", serif;
  --font-body: "Instrument Sans", system-ui, -apple-system, "Segoe UI", sans-serif;

  --radius: 14px;
  --radius-lg: 22px;
  --shadow: 0 1px 2px rgba(29, 33, 49, .06), 0 10px 30px rgba(29, 33, 49, .08);
  --shadow-lg: 0 2px 4px rgba(29, 33, 49, .08), 0 24px 60px rgba(29, 33, 49, .16);
  --wrap: 1120px;
  --wrap-narrow: 720px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
img, svg { max-width: 100%; display: block; }
a { color: inherit; }
::selection { background: var(--gold-soft); }

.wrap { width: min(var(--wrap), 100% - 32px); margin-inline: auto; }
.wrap-narrow { width: min(var(--wrap-narrow), 100% - 32px); margin-inline: auto; }

.skip {
  position: absolute; left: -999px; top: 8px; background: var(--ink); color: var(--paper);
  padding: 8px 14px; border-radius: 8px; z-index: 100;
}
.skip:focus { left: 8px; }

/* ---------- Type ---------- */
h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 500;
  line-height: 1.12;
  letter-spacing: -0.01em;
  margin: 0 0 .5em;
  font-variation-settings: "SOFT" 60, "opsz" 72;
}
h1 { font-size: clamp(2.3rem, 5.6vw, 4.1rem); }
h2 { font-size: clamp(1.75rem, 3.6vw, 2.6rem); }
h3 { font-size: 1.35rem; }
p { margin: 0 0 1.1em; }
.lede { font-size: clamp(1.1rem, 1.8vw, 1.28rem); color: var(--ink-soft); }
.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-size: .78rem; letter-spacing: .16em; text-transform: uppercase;
  color: var(--gold); font-weight: 600; margin-bottom: 18px;
}
.eyebrow::before { content: ""; width: 28px; height: 1px; background: currentColor; }
em.gold, .gold { color: var(--gold); font-style: italic; }
.muted { color: var(--ink-faint); }
.center { text-align: center; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--paper) 88%, transparent);
  backdrop-filter: saturate(1.2) blur(10px);
  -webkit-backdrop-filter: saturate(1.2) blur(10px);
  border-bottom: 1px solid transparent;
  transition: border-color .2s;
}
.site-header.scrolled { border-bottom-color: var(--line); }
.nav { display: flex; align-items: center; justify-content: space-between; height: 68px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.brand-mark { width: 30px; height: 30px; }
.brand-name { font-family: var(--font-display); font-size: 1.32rem; font-weight: 600; letter-spacing: -0.01em; }
.nav-links { display: flex; align-items: center; gap: 28px; list-style: none; margin: 0; padding: 0; }
.nav-links a { text-decoration: none; font-size: .95rem; color: var(--ink-soft); }
.nav-links a:hover, .nav-links a[aria-current="page"] { color: var(--ink); }
.nav-links a[aria-current="page"] { text-decoration: underline; text-decoration-color: var(--gold); text-underline-offset: 6px; }
.nav-toggle {
  display: none; background: none; border: 0; padding: 8px; margin-right: -8px; cursor: pointer; color: var(--ink);
}
.nav-toggle svg { width: 26px; height: 26px; }

@media (max-width: 820px) {
  .nav-toggle { display: block; }
  .nav-links {
    position: absolute; top: 68px; left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 0;
    background: var(--paper); border-bottom: 1px solid var(--line);
    padding: 8px 16px 20px; display: none;
  }
  .nav-links.open { display: flex; }
  .nav-links li a { display: block; padding: 14px 4px; font-size: 1.05rem; border-bottom: 1px solid var(--line); }
  .nav-links li:last-child a { border: 0; }
  .nav-links .btn { margin-top: 14px; text-align: center; }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  padding: 14px 24px; border-radius: 999px; border: 1px solid transparent;
  font: 600 1rem/1 var(--font-body); text-decoration: none; cursor: pointer;
  transition: transform .15s ease, background .2s, box-shadow .2s, color .2s;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--ink); color: var(--paper); }
.btn-primary:hover { background: color-mix(in srgb, var(--ink) 86%, var(--paper)); box-shadow: var(--shadow); }
.btn-gold { background: var(--gold); color: var(--on-gold); }
.btn-gold:hover { background: color-mix(in srgb, var(--gold) 86%, #000); box-shadow: var(--shadow); }
.btn-ghost { background: transparent; border-color: var(--line); color: var(--ink); }
.btn-ghost:hover { border-color: var(--ink-soft); }
.btn-small { padding: 10px 18px; font-size: .92rem; }
.nav-links .btn-small { color: var(--paper); }
.btn[aria-disabled="true"] { opacity: .55; cursor: not-allowed; }
.btn svg { width: 18px; height: 18px; }

/* ---------- Sections ---------- */
section { padding: clamp(64px, 9vw, 112px) 0; }
.section-tight { padding: clamp(44px, 6vw, 72px) 0; }
.section-alt { background: var(--paper-2); }
.section-night { background: var(--night); color: var(--on-night); }
.section-night .lede, .section-night .muted { color: var(--on-night-soft); }
.section-night .eyebrow { color: var(--gold-soft); }

.section-head { max-width: 640px; margin-bottom: 44px; }
.section-head.center { margin-inline: auto; }

/* ---------- Hero ---------- */
.hero { position: relative; overflow: hidden; padding: clamp(48px, 8vw, 96px) 0 clamp(64px, 9vw, 112px); }
.hero::before {
  /* the dawn */
  content: ""; position: absolute; z-index: 0;
  width: 1100px; height: 1100px; border-radius: 50%;
  right: -380px; top: -520px;
  background: radial-gradient(circle at 50% 50%, color-mix(in srgb, var(--gold-soft) 55%, transparent) 0%, color-mix(in srgb, var(--gold-soft) 22%, transparent) 38%, transparent 66%);
  pointer-events: none;
}
.hero-grid { position: relative; z-index: 1; display: grid; grid-template-columns: 1.15fr .85fr; gap: clamp(32px, 6vw, 80px); align-items: center; }
.hero h1 { margin-bottom: 22px; }
.hero .lede { max-width: 34ch; margin-bottom: 30px; }
.hero-proof { margin-top: 22px; font-size: .92rem; color: var(--ink-faint); }
.hero-proof strong { color: var(--ink); }
@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero .lede { max-width: none; }
  .hero-visual { order: -1; width: 100%; max-width: 210px; margin: 0 auto; }
}

/* ---------- Booklet mockup (CSS cover of the free guide) ---------- */
.booklet { position: relative; perspective: 1400px; padding: 20px 10px 30px; }
.booklet-page, .booklet-cover {
  aspect-ratio: 3 / 4; border-radius: 6px 14px 14px 6px;
}
.booklet-page {
  position: absolute; inset: 20px 10px 30px 10px; background: var(--sheet); transform: rotate(5deg) translate(14px, 8px);
  box-shadow: var(--shadow); border: 1px solid var(--line);
}
.booklet-cover {
  position: relative;
  background:
    radial-gradient(120% 70% at 50% 108%, color-mix(in srgb, var(--gold-soft) 90%, transparent) 0%, color-mix(in srgb, var(--gold-soft) 25%, transparent) 45%, transparent 70%),
    linear-gradient(180deg, var(--cover-1) 0%, var(--cover-2) 100%);
  color: var(--cover-ink); box-shadow: var(--shadow-lg);
  padding: 13% 11%; display: flex; flex-direction: column; justify-content: space-between;
  transform: rotate(-3deg);
  overflow: hidden;
}
.booklet-cover::before {
  content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 7%;
  background: linear-gradient(90deg, rgba(0,0,0,.28), rgba(0,0,0,0));
}
.booklet-cover .bc-top { font-size: .68rem; letter-spacing: .22em; text-transform: uppercase; color: var(--gold-soft); }
.booklet-cover .bc-title { font-family: var(--font-display); font-size: clamp(1.6rem, 3vw, 2.2rem); line-height: 1.05; font-weight: 500; }
.booklet-cover .bc-title span { display: block; font-style: italic; color: var(--gold-soft); }
.booklet-cover .bc-sun {
  width: 46%; aspect-ratio: 2 / 1; margin: 0 auto -13%; border-radius: 999px 999px 0 0;
  background: linear-gradient(180deg, var(--sun-1), var(--sun-2));
  box-shadow: 0 0 60px 20px color-mix(in srgb, var(--sun-1) 35%, transparent);
}
.booklet-cover .bc-foot { font-size: .72rem; color: color-mix(in srgb, var(--cover-ink) 80%, transparent); letter-spacing: .06em; }
.booklet.large .bc-title { font-size: clamp(1.8rem, 3.6vw, 2.6rem); }

/* ---------- Signup form ---------- */
.signup { display: grid; gap: 10px; max-width: 460px; }
.signup .row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.signup.stack .row { grid-template-columns: 1fr; }
.signup input {
  width: 100%; padding: 15px 16px; border-radius: 12px; border: 1px solid var(--line);
  background: var(--card); color: var(--ink); font: 1rem var(--font-body);
  transition: border-color .2s, box-shadow .2s;
}
.signup input::placeholder { color: var(--ink-faint); }
.signup input:focus { outline: none; border-color: var(--gold); box-shadow: 0 0 0 4px color-mix(in srgb, var(--gold) 18%, transparent); }
.signup .btn { width: 100%; padding: 16px 24px; }
.signup .fine { font-size: .84rem; color: var(--ink-faint); margin: 2px 0 0; }
.signup .form-msg { font-size: .92rem; margin: 0; min-height: 0; }
.signup .form-msg.error { color: var(--clay); }
.signup .form-msg.info { color: var(--ink-soft); }
.signup.is-loading .btn { opacity: .7; pointer-events: none; }
.section-night .signup input { background: rgba(255,255,255,.07); border-color: rgba(255,255,255,.2); color: var(--on-night); }
.section-night .signup input::placeholder { color: var(--on-night-faint); }
.section-night .signup .fine { color: var(--on-night-faint); }
@media (max-width: 520px) { .signup .row { grid-template-columns: 1fr; } }

/* ---------- Scripture block ---------- */
.verse {
  font-family: var(--font-display); font-style: italic; font-weight: 400;
  font-size: clamp(1.35rem, 2.6vw, 1.9rem); line-height: 1.35; margin: 0 0 14px;
}
.verse-ref { font-size: .82rem; letter-spacing: .16em; text-transform: uppercase; color: var(--gold); }
.verse-wrap { max-width: 760px; margin-inline: auto; text-align: center; }
.verse-wrap .divider { margin: 0 auto 28px; }
.divider { width: 44px; height: 44px; color: var(--gold); }

/* ---------- Cards / grids ---------- */
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 22px; }
@media (max-width: 900px) { .grid-3 { grid-template-columns: 1fr 1fr; } }
@media (max-width: 640px) { .grid-3, .grid-2 { grid-template-columns: 1fr; } }

.card {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-lg);
  padding: 28px; transition: transform .2s, box-shadow .2s;
}
a.card { text-decoration: none; display: block; }
a.card:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.card .num { font-family: var(--font-display); font-size: 2.1rem; color: var(--gold); line-height: 1; margin-bottom: 14px; }
.card h3 { margin-bottom: 8px; }
.card p { color: var(--ink-soft); margin: 0; }
.card .meta { font-size: .8rem; letter-spacing: .12em; text-transform: uppercase; color: var(--gold); margin-bottom: 12px; display: block; }
.card .read { display: inline-block; margin-top: 16px; font-weight: 600; font-size: .95rem; color: var(--ink); }

.checklist { list-style: none; padding: 0; margin: 0 0 28px; display: grid; gap: 14px; }
.checklist li { display: grid; grid-template-columns: 26px 1fr; gap: 12px; align-items: start; }
.checklist li::before {
  content: ""; width: 22px; height: 22px; margin-top: 3px; border-radius: 50%;
  background: var(--gold) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='20 6 9 17 4 12'/%3E%3C/svg%3E") center / 13px no-repeat;
}

/* ---------- Split feature ---------- */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 6vw, 80px); align-items: center; }
@media (max-width: 860px) { .split { grid-template-columns: 1fr; } }

/* ---------- Products ---------- */
.product {
  display: grid; grid-template-columns: 300px 1fr; gap: clamp(28px, 5vw, 56px); align-items: center;
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: clamp(24px, 4vw, 44px);
}
.product + .product { margin-top: 24px; }
.product .booklet { max-width: 300px; }
.price { font-family: var(--font-display); font-size: 2rem; margin: 6px 0 20px; }
.price small { font-family: var(--font-body); font-size: .9rem; color: var(--ink-faint); margin-left: 8px; }
.badge {
  display: inline-block; font-size: .74rem; letter-spacing: .12em; text-transform: uppercase;
  background: color-mix(in srgb, var(--gold) 14%, transparent); color: color-mix(in srgb, var(--gold) 75%, var(--ink)); padding: 6px 12px; border-radius: 999px; margin-bottom: 14px;
}
.badge.soon { background: color-mix(in srgb, var(--ink) 8%, transparent); color: var(--ink-soft); }
.product-mini { opacity: .9; }
.product-mini .booklet-cover { background: linear-gradient(180deg, color-mix(in srgb, var(--cover-1) 70%, #888), color-mix(in srgb, var(--cover-2) 80%, #555)); }
.buy-note { font-size: .88rem; color: var(--ink-faint); margin-top: 14px; }
@media (max-width: 760px) {
  .product { grid-template-columns: 1fr; }
  .product .booklet { max-width: 240px; margin: 0 auto; }
}

/* ---------- Article (devotional) ---------- */
.article-head { padding: clamp(48px, 7vw, 88px) 0 24px; text-align: center; }
.article-head .meta { font-size: .82rem; letter-spacing: .14em; text-transform: uppercase; color: var(--gold); margin-bottom: 18px; }
.article-head h1 { font-size: clamp(2.2rem, 5vw, 3.5rem); }
.prose { font-size: 1.14rem; line-height: 1.8; }
.prose p { margin-bottom: 1.3em; }
.prose h2 { font-size: 1.7rem; margin-top: 1.6em; }
.prose blockquote {
  margin: 1.8em 0; padding: 4px 0 4px 24px; border-left: 3px solid var(--gold);
  font-family: var(--font-display); font-style: italic; font-size: 1.32rem; line-height: 1.45; color: var(--ink);
}
.prose blockquote cite { display: block; margin-top: 8px; font-family: var(--font-body); font-style: normal; font-size: .82rem; letter-spacing: .14em; text-transform: uppercase; color: var(--gold); }
.prayer {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-lg);
  padding: 28px 30px; margin: 2em 0;
}
.prayer h3 { font-size: 1rem; font-family: var(--font-body); letter-spacing: .14em; text-transform: uppercase; color: var(--gold); font-weight: 600; margin-bottom: 12px; }
.prayer p { font-family: var(--font-display); font-size: 1.22rem; line-height: 1.6; margin: 0; }
.article-cta {
  margin: 56px 0 0; padding: clamp(28px, 4vw, 40px); border-radius: var(--radius-lg);
  background: var(--night); color: var(--on-night); display: grid; grid-template-columns: 1fr; gap: 6px;
}
.article-cta h3 { font-size: 1.6rem; margin-bottom: 4px; }
.article-cta p { color: var(--on-night-soft); }
.article-cta .signup input { background: rgba(255,255,255,.07); border-color: rgba(255,255,255,.2); color: var(--on-night); }
.article-cta .signup .fine { color: var(--on-night-faint); }

/* ---------- FAQ ---------- */
.faq { max-width: 760px; margin-inline: auto; }
.faq details { border-bottom: 1px solid var(--line); padding: 4px 0; }
.faq summary {
  list-style: none; cursor: pointer; padding: 18px 36px 18px 0; position: relative;
  font-family: var(--font-display); font-size: 1.22rem;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+"; position: absolute; right: 4px; top: 50%; transform: translateY(-50%);
  font-family: var(--font-body); font-size: 1.5rem; color: var(--gold); transition: transform .2s;
}
.faq details[open] summary::after { transform: translateY(-50%) rotate(45deg); }
.faq details p { color: var(--ink-soft); padding-right: 36px; }

/* ---------- Thank-you ---------- */
.steps { counter-reset: s; list-style: none; padding: 0; margin: 32px 0; display: grid; gap: 14px; text-align: left; }
.steps li {
  counter-increment: s; display: grid; grid-template-columns: 40px 1fr; gap: 14px; align-items: start;
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px;
}
.steps li::before {
  content: counter(s); width: 32px; height: 32px; border-radius: 50%; background: var(--ink); color: var(--paper);
  display: grid; place-items: center; font-weight: 600; font-size: .92rem;
}

/* ---------- Footer ---------- */
.site-footer { background: var(--night); color: var(--on-night-soft); padding: 64px 0 32px; font-size: .95rem; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 40px; }
.site-footer .brand-name { color: var(--on-night); }
.site-footer h4 { font-family: var(--font-body); font-size: .78rem; letter-spacing: .16em; text-transform: uppercase; color: var(--gold-soft); font-weight: 600; margin-bottom: 14px; }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.site-footer a { text-decoration: none; color: var(--on-night-soft); }
.site-footer a:hover { color: var(--on-night); }
.footer-bottom { margin-top: 48px; padding-top: 24px; border-top: 1px solid rgba(255,255,255,.1); display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; font-size: .85rem; color: var(--on-night-faint); }
@media (max-width: 760px) { .footer-grid { grid-template-columns: 1fr 1fr; } .footer-grid > :first-child { grid-column: 1 / -1; } }

/* ---------- Misc ---------- */
.yt-link { display: inline-flex; align-items: center; gap: 8px; }
.yt-link svg { width: 20px; height: 20px; color: var(--clay); }
.notice {
  font-size: .85rem; background: var(--notice-bg); border: 1px dashed var(--gold); color: var(--ink);
  padding: 10px 14px; border-radius: 10px; margin-top: 12px;
}
.page-head { padding: clamp(48px, 7vw, 88px) 0 clamp(24px, 4vw, 40px); }
.page-head .lede { max-width: 60ch; }

.reveal { opacity: 0; transform: translateY(14px); transition: opacity .7s ease, transform .7s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
}

:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; border-radius: 6px; }
.product-mini .booklet { max-width: 190px; margin: 0 auto; }
.product-mini { text-align: left; }

.stats { grid-template-columns: repeat(2, 1fr); }
@media (max-width: 640px) { .stats { grid-template-columns: repeat(2, 1fr); gap: 12px; } .stats .card { padding: 20px; } .stats h3 { font-size: 1.1rem; } }
.booklet-cover { container-type: inline-size; }
.booklet-cover .bc-foot { position: relative; z-index: 1; text-shadow: 0 1px 6px color-mix(in srgb, var(--cover-2) 60%, transparent); }
@container (max-width: 220px) {
  .bc-foot { display: none; }
  .bc-sun { margin-bottom: 0 !important; }
  .bc-title { font-size: 1.5rem !important; }
}
.booklet { width: 100%; }

/* ---------- Sample page from the guide ---------- */
.sample-page {
  margin: 0; background: var(--sheet); color: var(--ink);
  border: 1px solid var(--line); border-radius: 4px; box-shadow: var(--shadow-lg);
  padding: clamp(28px, 4vw, 48px); max-width: 460px; justify-self: center;
  transform: rotate(1.2deg);
}
.sample-page .sp-day { font-family: var(--font-display); font-size: 1.05rem; color: var(--gold); margin-bottom: 18px; }
.sample-page .sp-verse { margin: 0 0 8px; font-family: var(--font-display); font-style: italic; font-size: 1.32rem; line-height: 1.45; }
.sample-page .sp-ref { font-size: .9rem; color: var(--ink-faint); margin-bottom: 22px; }
.sample-page .sp-prayer { font-size: 1.02rem; line-height: 1.75; }
.sample-page .sp-carry { margin: 22px 0 0; padding-top: 16px; border-top: 1px solid var(--line); font-size: .95rem; color: var(--ink-soft); }
.sample-page .sp-carry strong { color: var(--ink); }
