/* ───────────────────────────────────────────────────────────
   Jesus NYE — Cinematic Scrollytelling
   ─────────────────────────────────────────────────────────── */

:root {
  --bg:           #04060c;
  --ink:          #f5f0e1;
  --ink-dim:      rgba(245,240,225,0.62);
  --gold:         #f6c66a;
  --gold-bright:  #ffd58a;
  --gold-soft:    #b88a3c;
  --royal:        #6da6ff;
  --vapor:        rgba(255,255,255,0.08);
  --serif:        "Cormorant Garamond", "EB Garamond", Georgia, "Times New Roman", serif;
  --sans:         "Inter", ui-sans-serif, system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
  --eyebrow:      0.62rem;
  --pad:          clamp(20px, 4vw, 56px);
}

@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:wght@300;400;500;600&family=Inter:wght@300;400;500;600&display=swap');

* { box-sizing: border-box; }

html, body {
  margin: 0; padding: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overscroll-behavior-y: none;
}

body {
  min-height: 100vh;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }

/* ── WebGL stage ────────────────────────────────────────── */
#stage {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  z-index: 0;
  display: block;
  background:
    radial-gradient(120% 80% at 50% 40%, #0a1124 0%, #04060c 60%, #02030a 100%);
}

/* ── Loader ─────────────────────────────────────────────── */
#loader {
  position: fixed; inset: 0;
  z-index: 100;
  background: #03040a;
  display: grid; place-items: center;
  transition: opacity 1.1s ease 0.2s, visibility 0s linear 1.4s;
}
#loader.done { opacity: 0; visibility: hidden; pointer-events: none; }
.loader-inner { width: min(420px, 76vw); text-align: center; }
.loader-mark {
  font-family: var(--serif);
  font-weight: 500;
  letter-spacing: 0.28em;
  font-size: 1rem;
  color: var(--gold);
  margin-bottom: 22px;
}
.loader-bar {
  height: 1px;
  background: rgba(255,255,255,0.10);
  overflow: hidden;
  position: relative;
}
.loader-fill {
  position: absolute; inset: 0 100% 0 0;
  background: linear-gradient(90deg, transparent, var(--gold-bright), transparent);
  transition: right 0.35s ease;
}
.loader-sub {
  margin-top: 18px;
  font-size: 0.72rem;
  letter-spacing: 0.32em;
  color: var(--ink-dim);
  text-transform: uppercase;
}

/* ── Top bar / nav ──────────────────────────────────────── */
.topbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 30;
  padding: 22px var(--pad);
  display: flex;
  align-items: center;
  justify-content: space-between;
  pointer-events: none;
  mix-blend-mode: screen;
}
.topbar > * { pointer-events: auto; }
.brand {
  font-family: var(--serif);
  font-weight: 500;
  letter-spacing: 0.28em;
  font-size: 0.95rem;
  color: var(--ink);
}
.brand span { color: var(--gold); margin: 0 6px; }
.topnav { display: flex; align-items: center; gap: 26px; }
.topnav a {
  font-size: 0.74rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink-dim);
  transition: color 0.3s ease;
}
.topnav a:hover { color: var(--ink); }
.cta-pill {
  padding: 9px 18px;
  border: 1px solid rgba(246,198,106,0.5);
  border-radius: 999px;
  color: var(--gold-bright) !important;
  transition: background 0.3s ease, border-color 0.3s ease;
}
.cta-pill:hover {
  background: rgba(246,198,106,0.12);
  border-color: var(--gold-bright);
}

/* ── Scroll cue (hero only) ─────────────────────────────── */
.scroll-cue {
  position: fixed;
  bottom: 36px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 25;
  text-align: center;
  color: var(--ink-dim);
  font-size: 0.66rem;
  letter-spacing: 0.34em;
  text-transform: uppercase;
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.scroll-cue.hide { opacity: 0; transform: translateX(-50%) translateY(20px); }
.cue-line {
  width: 1px; height: 42px;
  background: linear-gradient(180deg, rgba(246,198,106,0.6), transparent);
  margin: 12px auto 0;
  animation: cuePulse 2.4s ease-in-out infinite;
}
@keyframes cuePulse {
  0%, 100% { transform: scaleY(0.4); opacity: 0.4; transform-origin: top; }
  50%      { transform: scaleY(1);   opacity: 1;   transform-origin: top; }
}

/* ── Chapters indicator (right rail) ────────────────────── */
.chapters {
  position: fixed;
  top: 50%;
  right: 28px;
  transform: translateY(-50%);
  z-index: 20;
}
.chapters ul {
  list-style: none; margin: 0; padding: 0;
  display: flex; flex-direction: column; gap: 16px;
}
.chapters li {
  display: flex; align-items: center; gap: 14px;
  justify-content: flex-end;
}
.chapters li span {
  width: 22px; height: 1px;
  background: rgba(255,255,255,0.25);
  transition: width 0.5s ease, background 0.5s ease;
}
.chapters li em {
  font-style: normal;
  font-size: 0.66rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink);
  /* fade out fast, fade in slow + delayed → only ever one label visible */
  transition: opacity 0.12s ease;
  opacity: 0;
}
.chapters li.active span {
  width: 42px;
  background: var(--gold-bright);
}
.chapters li.active em {
  opacity: 1;
  transition: opacity 0.32s ease 0.14s;
}
@media (max-width: 760px) { .chapters { display: none; } }

/* ── Scrollytelling sections ────────────────────────────── */
#scroller {
  position: relative;
  z-index: 10;
}
.scene {
  position: relative;
  min-height: 100vh;
  padding: var(--pad);
  display: flex;
  pointer-events: none;
}
.scene-copy {
  pointer-events: auto;
  max-width: 640px;
  opacity: 0;                      /* driven per-frame by main.js */
  transition: opacity 0.18s linear;
  will-change: opacity, transform;
  position: relative;
  padding: 14px 0;
}
/* Soft dark scrim behind scene text so it reads on bright plates
   (Gathering/Communion/King/Overflow) without changing the cinematic look. */
.scene-copy::before {
  content: "";
  position: absolute;
  inset: -22px -32px;
  background: radial-gradient(ellipse at center,
    rgba(4,6,12,0.55) 0%,
    rgba(4,6,12,0.40) 35%,
    rgba(4,6,12,0.00) 75%);
  z-index: -1;
  pointer-events: none;
  border-radius: 24px;
}
/* Letter-level shadow as a second line of defence on very busy backgrounds */
.scene-copy h1,
.scene-copy h2,
.scene-copy .lede {
  text-shadow:
    0 2px 12px rgba(0,0,0,0.65),
    0 0 28px rgba(0,0,0,0.40);
}
.scene-copy .eyebrow {
  text-shadow: 0 1px 6px rgba(0,0,0,0.55);
}

.align-bottom-left   { margin: auto auto 12vh 0; }
.align-bottom-center { margin: auto auto 14vh auto; text-align: center; }
.align-center        { margin: auto; text-align: center; }
.align-top-left      { margin: 14vh auto auto 0; }
.align-top-right     { margin: 14vh 0 auto auto; text-align: right; }

.eyebrow {
  font-family: var(--sans);
  font-size: var(--eyebrow);
  font-weight: 500;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: var(--gold);
  margin: 0 0 18px;
}
.eyebrow.gold { color: var(--gold-bright); }

.scene-copy h1,
.scene-copy h2,
.finale h2 {
  font-family: var(--serif);
  font-weight: 400;
  line-height: 1.05;
  letter-spacing: -0.005em;
  margin: 0 0 22px;
  color: var(--ink);
  text-wrap: balance;
}
.scene-copy h1 { font-size: clamp(2.4rem, 6vw, 5.4rem); }
.scene-copy h2 { font-size: clamp(2rem, 4.6vw, 4rem); }
.scene-copy h1.display { font-size: clamp(2.6rem, 6.4vw, 5.6rem); }
.finale .display { font-size: clamp(2rem, 4.4vw, 3.6rem); line-height: 1.1; }

.lede {
  font-family: var(--serif);
  font-size: clamp(1.05rem, 1.5vw, 1.5rem);
  line-height: 1.45;
  color: var(--ink-dim);
  margin: 0;
  font-weight: 300;
  text-wrap: balance;
}

/* ── Finale / CTA ───────────────────────────────────────── */
.finale {
  position: relative;
  min-height: 100vh;
  padding: 14vh var(--pad) 8vh;
  background:
    radial-gradient(120% 70% at 50% 0%, rgba(246,198,106,0.10) 0%, transparent 60%),
    linear-gradient(180deg, rgba(4,6,12,0) 0%, rgba(4,6,12,0.6) 30%, #04060c 70%);
}
.finale-inner {
  max-width: 1180px;
  margin: 0 auto;
}
.finale .lede { max-width: 720px; }

.cta-grid {
  margin: 64px 0 80px;
  display: grid;
  /* Wide view → 3 across × 2 rows  (3·3) */
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}
/* Medium → 2 across × 3 rows  (2·2·2) */
@media (max-width: 980px) {
  .cta-grid { grid-template-columns: repeat(2, 1fr); }
}
/* Skinny → single column × 6 rows */
@media (max-width: 600px) {
  .cta-grid { grid-template-columns: 1fr; }
}
.cta-card {
  position: relative;
  padding: 28px 26px 26px;
  border: 1px solid rgba(255,255,255,0.10);
  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(255,255,255,0.02), rgba(255,255,255,0.00));
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  transition: transform 0.5s cubic-bezier(.2,.7,.2,1),
              border-color 0.4s ease,
              background 0.4s ease;
  display: flex; flex-direction: column; gap: 8px;
  min-height: 220px;
  overflow: hidden;
}
.cta-card::after {
  content: "";
  position: absolute; inset: -1px;
  border-radius: 18px;
  pointer-events: none;
  background:
    radial-gradient(60% 50% at 80% 0%, rgba(246,198,106,0.18), transparent 60%);
  opacity: 0;
  transition: opacity 0.5s ease;
}
.cta-card:hover {
  transform: translateY(-4px);
  border-color: rgba(246,198,106,0.4);
  background: linear-gradient(180deg, rgba(246,198,106,0.06), rgba(255,255,255,0.00));
}
.cta-card:hover::after { opacity: 1; }
.cta-num {
  font-family: var(--serif);
  font-size: 0.85rem;
  letter-spacing: 0.3em;
  color: var(--gold);
}
.cta-title {
  font-family: var(--serif);
  font-size: 1.75rem;
  letter-spacing: 0.02em;
  color: var(--ink);
}
.cta-sub {
  font-family: var(--serif);
  font-size: 1rem;
  font-weight: 300;
  color: var(--ink-dim);
  line-height: 1.45;
  margin-top: 4px;
  flex: 1;
}
.cta-arrow {
  align-self: flex-end;
  font-size: 1.4rem;
  color: var(--gold);
  transition: transform 0.4s ease;
}
.cta-card:hover .cta-arrow { transform: translateX(6px); }

/* Legacy / Part 1 callout */
.legacy {
  margin: 40px 0 50px;
  padding: 36px;
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 18px;
  background:
    radial-gradient(120% 100% at 0% 0%, rgba(109,166,255,0.10), transparent 50%);
  display: grid;
  gap: 12px;
}
.legacy h3 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(1.6rem, 2.4vw, 2.2rem);
  margin: 0;
}
.ghost-btn {
  align-self: start;
  margin-top: 14px;
  padding: 14px 22px;
  border: 1px solid rgba(255,255,255,0.18);
  border-radius: 999px;
  font-size: 0.78rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink);
  background: transparent;
  cursor: pointer;
  font-family: var(--sans);
  transition: border-color 0.3s ease, background 0.3s ease, color 0.3s ease;
  display: inline-flex; align-items: center; gap: 10px;
}
.ghost-btn:hover { color: var(--gold-bright); }
.ghost-btn:hover {
  border-color: var(--gold-bright);
  background: rgba(246,198,106,0.08);
}
.play-dot {
  display: inline-grid; place-items: center;
  width: 22px; height: 22px;
  border-radius: 50%;
  background: var(--gold-bright);
  color: #0a0e1c;
  font-size: 0.6rem;
}

/* Footer */
.foot {
  margin-top: 60px;
  padding-top: 28px;
  border-top: 1px solid rgba(255,255,255,0.08);
  display: flex; justify-content: space-between;
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink-dim);
  flex-wrap: wrap;
  gap: 10px;
}
.foot-mark { color: var(--gold); letter-spacing: 0.34em; }

/* "An initiative of [Jesus Loves Australia logo]" — landing-page + sub-page footer */
.foot-initiative {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  font-size: 0.62rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--ink-dim);
  transition: opacity 0.3s ease;
  text-decoration: none;
}
.foot-initiative:hover { opacity: 0.85; }
.foot-initiative span { white-space: nowrap; }
.foot-initiative img {
  height: 88px;
  width: auto;
  display: block;
  opacity: 0.96;
}
@media (max-width: 760px) { .foot-initiative img { height: 72px; } }

/* JLA mark sitting at the top of the 2018 Down Payment block */
.legacy-mark {
  height: 180px;
  width: auto;
  display: block;
  margin: 0 0 18px;
  opacity: 1.0;
}
@media (max-width: 760px) { .legacy-mark { height: 130px; } }

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  .cue-line { animation: none; }
  * { transition-duration: 0.2s !important; }
}

/* ─── Mobile menu toggle (hamburger) ───────────────────────── */
.menu-toggle {
  display: none;
  appearance: none;
  -webkit-appearance: none;
  background: rgba(4,6,12,0.6);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 999px;
  width: 44px; height: 44px;
  cursor: pointer;
  padding: 0;
  position: relative;
  transition: background 0.25s ease, border-color 0.25s ease;
}
.menu-toggle:hover { border-color: var(--gold); }
.menu-toggle::before,
.menu-toggle::after,
.menu-toggle span {
  content: "";
  position: absolute;
  left: 12px; right: 12px;
  height: 1.5px;
  background: var(--ink);
  transition: transform 0.3s ease, opacity 0.2s ease;
}
.menu-toggle::before { top: 14px; }
.menu-toggle span    { top: 21px; }
.menu-toggle::after  { top: 28px; }

body.nav-open .menu-toggle::before { transform: translateY(7px) rotate(45deg); }
body.nav-open .menu-toggle span    { opacity: 0; }
body.nav-open .menu-toggle::after  { transform: translateY(-7px) rotate(-45deg); }

/* ─── Mobile: scene text sized down + topbar backdrop ───────── */
@media (max-width: 760px) {
  /* Topbar gets a solid-ish backdrop on mobile so brand text never blends
     with the WebGL underneath while you scroll. */
  .topbar {
    background: linear-gradient(180deg, rgba(4,6,12,0.85) 0%, rgba(4,6,12,0.6) 60%, rgba(4,6,12,0) 100%);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    mix-blend-mode: normal;
    padding: 14px var(--pad);
  }

  /* Show the hamburger; hide the inline nav links (the cta-pill stays visible). */
  .menu-toggle { display: inline-block; }
  .topnav a:not(.cta-pill) { display: none; }

  /* When the menu is open, the inline links re-appear as a stacked panel. */
  body.nav-open .topnav {
    position: fixed;
    top: 70px; right: 16px; left: 16px;
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
    padding: 22px;
    background: rgba(4,6,12,0.94);
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: 18px;
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    z-index: 35;
    box-shadow: 0 24px 60px rgba(0,0,0,0.55);
  }
  body.nav-open .topnav a:not(.cta-pill) {
    display: block;
    padding: 14px 10px;
    text-align: center;
    font-size: 0.85rem;
    border-radius: 12px;
    color: var(--ink);
  }
  body.nav-open .topnav a:not(.cta-pill):hover { background: rgba(246,198,106,0.08); }
  body.nav-open .topnav .cta-pill {
    margin-top: 8px;
    text-align: center;
    padding: 14px 18px;
  }

  /* Scene copy sized down */
  .scene-copy { max-width: 92vw; }
  .scene-copy h1 { font-size: clamp(1.85rem, 9vw, 2.6rem); }
  .scene-copy h2 { font-size: clamp(1.55rem, 7vw, 2.2rem); }
  .scene-copy h1.display { font-size: clamp(2.05rem, 10vw, 3rem); }
  .scene-copy .lede { font-size: 1rem; line-height: 1.45; }
  .scene-copy .eyebrow { font-size: 0.6rem; margin-bottom: 12px; }

  /* On phones, scene-copies are PINNED to viewport centre as a fixed overlay.
     Opacity is still driven by scene weight (main.js), so the text
     crossfades with the WebGL plate behind it — it never scrolls off-screen
     mid-scene the way absolutely-positioned section text would. */
  #scroller > .scene { pointer-events: none; }
  .scene-copy {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: min(86vw, 560px);
    margin: 0 !important;
    text-align: center !important;
    z-index: 15;
  }
  /* Stronger scrim on mobile because bright plates dominate the viewport */
  .scene-copy::before {
    inset: -28px -34px;
    background: radial-gradient(ellipse at center,
      rgba(4,6,12,0.72) 0%,
      rgba(4,6,12,0.55) 35%,
      rgba(4,6,12,0.00) 80%);
  }

  /* Scroll cue: smaller + nudged so it doesn't sit on hero text. */
  .scroll-cue { bottom: 18px; font-size: 0.58rem; }
  .cue-line { height: 28px; }

  /* Finale: tighter padding so the CTA cards never crowd the edges. */
  .finale { padding: 12vh 18px 6vh; }
  .cta-card { padding: 22px 20px; min-height: 0; }
  .cta-title { font-size: 1.55rem; }

  /* Down-Payment legacy block: tighter padding for phones. */
  .legacy { padding: 24px 20px; }

  /* Footer: stack the three pieces cleanly. */
  .foot { flex-direction: column; align-items: flex-start; gap: 18px; }
  .foot-initiative { margin-top: 4px; }

  /* Sub-pages: tighter sub-page padding too. */
  .page-inner { padding: 14vh 20px 6vh; }
  .form-wrap  { padding: 24px 20px; border-radius: 16px; }

  /* Form rows collapse single-column at mobile (already in base, but make
     the radio-group wrap nicer). */
  .radio-group { flex-direction: column; align-items: stretch; }
  .radio-row {
    display: flex;
    width: 100%;
    justify-content: flex-start;
    text-align: left;
  }

  /* Page footer goes single-column too */
  .page-footer { flex-direction: column; align-items: flex-start; gap: 16px; }
}

/* Tiny phones (e.g. iPhone SE 320px) — squeeze a bit further */
@media (max-width: 380px) {
  .scene-copy h1 { font-size: 1.7rem; }
  .scene-copy h2 { font-size: 1.45rem; }
  .scene-copy .lede { font-size: 0.95rem; }
  .topnav .cta-pill { padding: 8px 14px; font-size: 0.7rem; }
  .brand { font-size: 0.85rem; letter-spacing: 0.22em; }
}

/* ─────────────────────────────────────────────────────────────
   Sub-pages (Churches · Partners · Volunteers · Give · Thanks)
   ───────────────────────────────────────────────────────────── */

.page {
  position: relative;
  min-height: 100vh;
  background: var(--bg);
  color: var(--ink);
}
.page::before {
  /* subtle ambient backdrop so pages don't feel flat */
  content: "";
  position: fixed; inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(80% 60% at 80% 0%,   rgba(246,198,106,0.06), transparent 60%),
    radial-gradient(70% 70% at 10% 100%, rgba(109,166,255,0.05), transparent 60%);
}
.page-inner {
  position: relative;
  z-index: 1;
  max-width: 1100px;
  margin: 0 auto;
  padding: 16vh var(--pad) 8vh;
}

/* Back-to-story crumb in the topbar */
.crumb {
  font-size: 0.68rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--ink-dim);
  display: inline-flex; align-items: center; gap: 8px;
  transition: color 0.3s ease;
}
.crumb:hover { color: var(--ink); }
.crumb::before { content: "←"; color: var(--gold); }

/* ── Hero ── */
.page-hero {
  display: grid;
  gap: 22px;
  margin-bottom: 64px;
  max-width: 760px;
}
.page-hero h1 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(2.4rem, 5.4vw, 4.4rem);
  line-height: 1.05;
  letter-spacing: -0.005em;
  margin: 0;
  text-wrap: balance;
}
.page-hero .lede {
  font-family: var(--serif);
  font-size: clamp(1.05rem, 1.5vw, 1.4rem);
  line-height: 1.5;
  color: var(--ink-dim);
  font-weight: 300;
  margin: 0;
  max-width: 640px;
}

/* ── Section blocks ── */
.page-section {
  margin: 64px 0;
}
.page-section h2 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(1.6rem, 3vw, 2.6rem);
  line-height: 1.1;
  margin: 0 0 16px;
}
.page-section p {
  font-family: var(--serif);
  font-size: 1.1rem;
  line-height: 1.55;
  color: var(--ink-dim);
  font-weight: 300;
  margin: 0 0 14px;
  max-width: 720px;
}

/* Three-up bullet grid for "what we do / why / how" sections */
.bullet-grid {
  margin-top: 28px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}
@media (max-width: 880px) { .bullet-grid { grid-template-columns: 1fr; } }
.bullet-card {
  padding: 24px;
  border: 1px solid rgba(255,255,255,0.10);
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(255,255,255,0.02), rgba(255,255,255,0.00));
  display: flex; flex-direction: column; gap: 8px;
  min-height: 180px;
}
.bullet-num {
  font-family: var(--serif);
  color: var(--gold);
  font-size: 0.82rem;
  letter-spacing: 0.28em;
}
.bullet-card h3 {
  font-family: var(--serif);
  font-size: 1.4rem;
  font-weight: 400;
  margin: 0;
}
.bullet-card p {
  font-size: 0.98rem;
  line-height: 1.45;
  color: var(--ink-dim);
  margin: 0;
}

/* ── Form ── */
.form-wrap {
  margin: 40px 0;
  padding: 36px;
  border: 1px solid rgba(255,255,255,0.10);
  border-radius: 20px;
  background:
    linear-gradient(180deg, rgba(255,255,255,0.02), rgba(255,255,255,0.00)),
    radial-gradient(80% 60% at 100% 0%, rgba(246,198,106,0.04), transparent 60%);
}
.form-wrap h2 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(1.6rem, 2.6vw, 2.2rem);
  margin: 0 0 10px;
}
.form-wrap .form-intro {
  font-family: var(--serif);
  color: var(--ink-dim);
  font-size: 1rem;
  line-height: 1.5;
  margin: 0 0 24px;
  max-width: 640px;
}

form.jne-form {
  display: grid;
  gap: 18px;
}
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}
@media (max-width: 640px) { .form-row { grid-template-columns: 1fr; } }
.form-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
/* Only the *direct-child* field label gets the small gold uppercase style.
   Nested labels inside checkbox-grid / level-radio-group keep their own
   typography (serif sentence case). */
.form-field > label {
  font-family: var(--sans);
  font-size: 0.7rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
}
.form-field > label .req { color: rgba(246,198,106,0.5); margin-left: 4px; }
.form-field input,
.form-field select,
.form-field textarea {
  font-family: var(--serif);
  font-size: 1.05rem;
  background: rgba(4,6,12,0.55);
  color: var(--ink);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 12px;
  padding: 14px 16px;
  outline: none;
  transition: border-color 0.25s ease, background 0.25s ease;
  width: 100%;
}
.form-field textarea {
  min-height: 130px;
  resize: vertical;
  line-height: 1.45;
}
.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
  border-color: var(--gold-bright);
  background: rgba(4,6,12,0.78);
}
.form-field select {
  appearance: none;
  background-image:
    linear-gradient(45deg, transparent 50%, var(--gold) 50%),
    linear-gradient(135deg, var(--gold) 50%, transparent 50%);
  background-position: right 22px center, right 16px center;
  background-size: 6px 6px;
  background-repeat: no-repeat;
  padding-right: 38px;
}

.checkbox-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}
@media (max-width: 640px) { .checkbox-grid { grid-template-columns: 1fr; } }
.checkbox-row {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 14px;
  border: 1px solid rgba(255,255,255,0.10);
  border-radius: 12px;
  font-family: var(--serif);
  font-size: 1rem;
  cursor: pointer;
  transition: border-color 0.25s ease, background 0.25s ease;
  /* Reset uppercase + letter-spacing inherited from .form-field label */
  text-transform: none;
  letter-spacing: 0;
  color: var(--ink);
}
.checkbox-row:hover { border-color: rgba(246,198,106,0.45); }
.checkbox-row input {
  appearance: none;
  width: 18px; height: 18px;
  border: 1px solid rgba(255,255,255,0.3);
  border-radius: 4px;
  position: relative;
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease;
  flex: 0 0 18px;
}
.checkbox-row input:checked {
  background: var(--gold);
  border-color: var(--gold);
}
.checkbox-row input:checked::after {
  content: "✓";
  position: absolute;
  inset: 0;
  display: grid; place-items: center;
  color: #0a0e1c;
  font-size: 12px;
  font-weight: 700;
}
.checkbox-row.has-check input:checked + span { color: var(--ink); }

.radio-group {
  display: flex; flex-wrap: wrap; gap: 10px;
}
.radio-row {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 10px 16px;
  border: 1px solid rgba(255,255,255,0.10);
  border-radius: 999px;
  font-family: var(--serif);
  font-size: 0.98rem;
  cursor: pointer;
  transition: border-color 0.25s ease, background 0.25s ease;
  /* Reset uppercase + letter-spacing inherited from .form-field label */
  text-transform: none;
  letter-spacing: 0;
  color: var(--ink);
}
.radio-row input { accent-color: var(--gold); }
.radio-row:hover { border-color: rgba(246,198,106,0.45); }

/* Honeypot — must look like a real field to bots but be invisible */
.honey {
  position: absolute !important;
  left: -9999px !important;
  width: 1px !important; height: 1px !important;
  opacity: 0 !important;
}

.submit-row {
  margin-top: 8px;
  display: flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
}
.btn-primary {
  font-family: var(--sans);
  font-size: 0.82rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  font-weight: 600;
  color: #0a0e1c;
  background: var(--gold-bright);
  border: none;
  border-radius: 999px;
  padding: 16px 32px;
  cursor: pointer;
  transition: background 0.25s ease, transform 0.25s ease;
}
.btn-primary:hover { background: #ffe2a3; transform: translateY(-2px); }
.btn-primary:disabled { opacity: 0.5; cursor: wait; transform: none; }
.submit-note {
  font-family: var(--serif);
  font-size: 0.95rem;
  color: var(--ink-dim);
  max-width: 360px;
}

/* Inline success/error state */
.form-status {
  display: none;
  padding: 18px;
  border-radius: 12px;
  font-family: var(--serif);
  font-size: 1rem;
  line-height: 1.4;
  margin-top: 16px;
}
.form-status.ok    { display: block; background: rgba(246,198,106,0.10); border: 1px solid rgba(246,198,106,0.4); color: var(--gold-bright); }
.form-status.error { display: block; background: rgba(255,90,90,0.10);   border: 1px solid rgba(255,120,120,0.4); color: #ffb4b4; }

/* ─── Five-level commitment cards (Churches page) ───────────── */
.level-grid {
  margin-top: 28px;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 14px;
  counter-reset: lvl;
}
@media (max-width: 1100px) { .level-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 720px)  { .level-grid { grid-template-columns: 1fr; } }
.level-card {
  padding: 22px 20px;
  border: 1px solid rgba(255,255,255,0.10);
  border-radius: 14px;
  background:
    linear-gradient(180deg, rgba(255,255,255,0.02), rgba(255,255,255,0.00)),
    radial-gradient(120% 80% at 0% 0%, rgba(246,198,106,0.05), transparent 60%);
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-height: 200px;
  counter-increment: lvl;
}
.level-card .level-num {
  font-family: var(--serif);
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  color: var(--gold);
}
.level-card h3 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.2rem;
  margin: 0;
  color: var(--ink);
}
.level-card p {
  font-family: var(--serif);
  font-size: 0.94rem;
  line-height: 1.4;
  color: var(--ink-dim);
  margin: 0;
}
.level-card .suit {
  margin-top: auto;
  padding-top: 10px;
  border-top: 1px solid rgba(255,255,255,0.06);
  font-family: var(--sans);
  font-size: 0.66rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(246,198,106,0.7);
}

/* ─── Numbered onboarding steps (Churches page) ─────────────── */
.steps {
  list-style: none;
  margin: 28px 0 0;
  padding: 0;
  display: grid;
  gap: 14px;
}
.steps li {
  display: grid;
  grid-template-columns: 52px 1fr;
  gap: 18px;
  padding: 18px 22px;
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 14px;
  background: linear-gradient(180deg, rgba(255,255,255,0.02), transparent);
}
.steps .step-num {
  font-family: var(--serif);
  font-size: 1.8rem;
  color: var(--gold);
  line-height: 1;
  font-weight: 300;
}
.steps .step-body { display: flex; flex-direction: column; gap: 4px; }
.steps .step-body h4 {
  font-family: var(--serif); font-weight: 400; font-size: 1.1rem; margin: 0; color: var(--ink);
}
.steps .step-body p {
  font-family: var(--serif); font-size: 0.95rem; line-height: 1.45; color: var(--ink-dim); margin: 0;
}

/* ─── Form: level-radio rows (full-width with description) ──── */
.level-radio-group {
  display: grid;
  gap: 10px;
}
.level-radio-row {
  display: grid;
  grid-template-columns: 28px 1fr;
  gap: 14px;
  align-items: flex-start;
  padding: 14px 16px;
  border: 1px solid rgba(255,255,255,0.10);
  border-radius: 12px;
  cursor: pointer;
  transition: border-color 0.25s ease, background 0.25s ease;
  font-family: var(--serif);
}
.level-radio-row:hover { border-color: rgba(246,198,106,0.45); }
.level-radio-row input[type="radio"] {
  margin-top: 4px;
  accent-color: var(--gold);
  width: 18px; height: 18px;
}
.level-radio-row:has(input:checked) {
  border-color: var(--gold-bright);
  background: rgba(246,198,106,0.05);
}
.level-radio-row .level-label-title {
  display: block;
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 4px;
}
.level-radio-row .level-label-body {
  display: block;
  font-size: 1rem;
  color: var(--ink);
  line-height: 1.4;
  /* Reset uppercase + letter-spacing inherited from .form-field label */
  text-transform: none;
  letter-spacing: 0;
  font-family: var(--serif);
}

/* ─── Brochure download CTA (top of form pages) ── */
.brochure-cta {
  margin: 30px 0 56px;
  padding: 26px 28px;
  border: 1px solid rgba(246,198,106,0.28);
  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(246,198,106,0.06), rgba(246,198,106,0.00)),
    radial-gradient(80% 60% at 100% 0%, rgba(246,198,106,0.10), transparent 60%);
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 22px;
}
@media (max-width: 640px) {
  .brochure-cta { grid-template-columns: 1fr; gap: 14px; }
}
.brochure-cta .b-icon {
  width: 52px; height: 52px;
  display: inline-grid; place-items: center;
  border-radius: 14px;
  background: rgba(246,198,106,0.18);
  color: var(--gold-bright);
  font-size: 1.4rem;
}
.brochure-cta .b-body {
  display: flex; flex-direction: column; gap: 6px;
}
.brochure-cta .b-eyebrow {
  font-size: 0.66rem; letter-spacing: 0.28em; text-transform: uppercase;
  color: var(--gold); margin: 0;
}
.brochure-cta .b-title {
  font-family: var(--serif); font-size: 1.4rem; line-height: 1.2; margin: 0; color: var(--ink);
}
.brochure-cta .b-sub {
  font-family: var(--serif); font-size: 0.98rem; color: var(--ink-dim); margin: 0;
}
.brochure-actions {
  display: flex; gap: 12px; flex-wrap: wrap;
  align-items: center;
}

/* ─── Brochure email modal ─────────────────────────────────── */
.brochure-modal {
  position: fixed; inset: 0;
  z-index: 1000;
  display: grid; place-items: center;
  padding: 20px;
}
.brochure-modal[hidden] { display: none; }
.brochure-modal-bg {
  position: absolute; inset: 0;
  background: rgba(4,6,12,0.85);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  cursor: pointer;
}
.brochure-modal-card {
  position: relative;
  width: min(94vw, 560px);
  background: var(--bg);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 20px;
  padding: 36px 30px 30px;
  z-index: 1;
  max-height: 92vh;
  overflow-y: auto;
  box-shadow: 0 30px 80px rgba(0,0,0,0.55);
}
.brochure-modal-close {
  position: absolute; top: 14px; right: 14px;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.10);
  color: var(--ink);
  width: 36px; height: 36px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 1.4rem;
  line-height: 1;
  display: inline-flex; align-items: center; justify-content: center;
  padding: 0;
  transition: border-color 0.25s ease, background 0.25s ease;
}
.brochure-modal-close:hover { border-color: var(--gold); }
.brochure-modal-card .modal-eyebrow {
  font-family: var(--sans);
  font-size: 0.66rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--gold);
  margin: 0 0 10px;
}
.brochure-modal-card h3 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.5rem;
  margin: 0 0 12px;
  line-height: 1.2;
  color: var(--ink);
}
.brochure-modal-card .modal-intro {
  font-family: var(--serif);
  font-size: 1rem;
  color: var(--ink-dim);
  margin: 0 0 22px;
  line-height: 1.5;
}

/* Success state — replaces the form after submission */
.brochure-modal-success { display: none; }
.brochure-modal-card.is-success .brochure-modal-form { display: none; }
.brochure-modal-card.is-success .brochure-modal-success { display: block; }
.brochure-modal-success .check {
  width: 64px; height: 64px;
  margin: 0 auto 18px;
  border-radius: 50%;
  background: rgba(246,198,106,0.16);
  color: var(--gold-bright);
  display: grid; place-items: center;
  font-size: 1.8rem;
}
.brochure-modal-success { text-align: center; }
.brochure-modal-success h3 { text-align: center; }
.brochure-modal-success p { font-family: var(--serif); color: var(--ink-dim); line-height: 1.5; margin: 0 0 14px; font-size: 1rem; }
.brochure-modal-success .submit-row { justify-content: center; margin-top: 18px; }

body.modal-open { overflow: hidden; }

/* ─── Direct deposit panel on Give page ── */
.deposit-panel {
  margin: 36px 0;
  padding: 28px;
  border: 1px solid rgba(255,255,255,0.10);
  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(255,255,255,0.025), rgba(255,255,255,0.00));
}
.deposit-panel h3 {
  font-family: var(--serif); font-weight: 400; font-size: 1.4rem;
  margin: 0 0 6px;
}
.deposit-grid {
  margin-top: 18px;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px 28px;
}
@media (max-width: 640px) { .deposit-grid { grid-template-columns: 1fr; } }
.deposit-row {
  display: flex; flex-direction: column; gap: 4px;
  padding: 10px 0;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}
.deposit-row:last-child { border-bottom: 0; }
.deposit-label {
  font-size: 0.66rem; letter-spacing: 0.22em; text-transform: uppercase;
  color: var(--ink-dim);
}
.deposit-value {
  font-family: var(--serif);
  font-size: 1.1rem;
  color: var(--ink);
  letter-spacing: 0.01em;
  user-select: all;
}
.deposit-value.mono {
  font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  letter-spacing: 0.06em;
}

/* ── Give-tier cards ── */
.tier-grid {
  margin: 40px 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}
@media (max-width: 980px) { .tier-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .tier-grid { grid-template-columns: 1fr; } }
.tier-card {
  padding: 28px 26px;
  border: 1px solid rgba(255,255,255,0.10);
  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(255,255,255,0.02), rgba(255,255,255,0.00));
  display: flex; flex-direction: column; gap: 10px;
}
.tier-amount {
  font-family: var(--serif);
  font-size: clamp(1.6rem, 2.2vw, 2.1rem);
  color: var(--gold-bright);
  letter-spacing: -0.01em;
}
.tier-card h3 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.25rem;
  margin: 0;
  color: var(--ink);
}
.tier-card p {
  font-family: var(--serif);
  font-size: 0.98rem;
  line-height: 1.45;
  color: var(--ink-dim);
  margin: 0;
}

/* ── Sub-page navigation reuse / footer ── */
.page-footer {
  margin-top: 80px;
  padding-top: 28px;
  border-top: 1px solid rgba(255,255,255,0.08);
  display: flex; justify-content: space-between; gap: 14px;
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink-dim);
  flex-wrap: wrap;
}
.page-footer a { color: var(--ink-dim); transition: color 0.3s ease; }
.page-footer a:hover { color: var(--gold-bright); }
.page-footer .foot-mark { color: var(--gold); letter-spacing: 0.34em; }

/* Sub-page topbar: solid background so it reads on non-WebGL pages */
.page .topbar {
  background: linear-gradient(180deg, rgba(4,6,12,0.92), rgba(4,6,12,0));
  mix-blend-mode: normal;
  padding-top: 18px; padding-bottom: 22px;
}

/* ─── Thank-you page: full-viewport centred card "moment" ──── */
body.thanks-body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background:
    radial-gradient(70% 60% at 50% 30%, rgba(246,198,106,0.08), transparent 60%),
    radial-gradient(60% 70% at 50% 100%, rgba(109,166,255,0.06), transparent 60%),
    var(--bg);
}
.thanks-frame {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 100px 20px 40px;       /* top room for the topbar */
  position: relative;
  z-index: 1;
}
.thanks-card {
  max-width: 580px;
  width: 100%;
  text-align: center;
  padding: 52px 38px 44px;
  border: 1px solid rgba(255,255,255,0.10);
  border-radius: 22px;
  background:
    linear-gradient(180deg, rgba(255,255,255,0.04), rgba(255,255,255,0.00)),
    radial-gradient(120% 80% at 50% 0%, rgba(246,198,106,0.10), transparent 60%),
    rgba(4,6,12,0.55);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 30px 80px rgba(0,0,0,0.45);
}
.thanks-check {
  width: 64px; height: 64px;
  margin: 0 auto 22px;
  border-radius: 50%;
  background: rgba(246,198,106,0.16);
  color: var(--gold-bright);
  display: grid; place-items: center;
  font-size: 1.8rem;
  border: 1px solid rgba(246,198,106,0.35);
}
.thanks-card .modal-eyebrow {
  font-family: var(--sans);
  font-size: 0.66rem;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--gold);
  margin: 0 0 14px;
}
.thanks-display {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(2rem, 4.6vw, 3.4rem);
  line-height: 1.05;
  letter-spacing: -0.005em;
  margin: 0 0 14px;
  color: var(--ink);
}
.thanks-card .lede {
  font-family: var(--serif);
  font-size: clamp(1rem, 1.3vw, 1.15rem);
  line-height: 1.5;
  color: var(--ink-dim);
  font-weight: 300;
  margin: 0 0 28px;
}
.thanks-actions {
  display: flex;
  gap: 14px;
  justify-content: center;
  flex-wrap: wrap;
}
.thanks-actions .ghost-btn { margin-top: 0; }

/* Footer on thank-you page sits at the very bottom of the viewport */
.thanks-footer {
  position: relative;
  z-index: 1;
  padding: 0 var(--pad);
  margin: 0 auto;
  max-width: 1100px;
  width: 100%;
  border-top: 0;
}

@media (max-width: 640px) {
  .thanks-card { padding: 40px 24px 36px; }
  .thanks-frame { padding: 90px 16px 28px; }
}
