/* ============================================================
   Caring in His Love (OHPN) — Design System
   Warm, dignified, faith-grounded. Need → Hope → How-you-help.
   ============================================================ */

/* ---------- Tokens ---------- */
:root {
  /* Palette — warm teal anchor + amber hope + cream ground */
  --ink:        #112e34;   /* deep teal-navy, primary text on light */
  --ink-2:      #2c4750;   /* secondary text */
  --teal:       #1f6f7a;   /* brand teal */
  --teal-deep:  #143f47;   /* deep panels */
  --teal-700:   #18555e;
  --amber:      #d99a3e;   /* hope / accent / CTA */
  --amber-deep: #b97d27;
  --rose:       #b75d52;   /* sparing "love" warmth */
  --cream:      #faf6ee;   /* page ground */
  --cream-2:    #f3ebdc;   /* warm panel */
  --sand:       #e9dec9;   /* borders / soft fill */
  --white:      #ffffff;
  --on-dark:    #f6efe2;   /* text on dark photos/panels */
  --on-dark-mut:#cdd9d8;

  /* Type */
  --display: "Fraunces", Georgia, "Times New Roman", serif;
  --body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;

  /* Fluid type scale */
  --fs-hero: clamp(2.6rem, 1.4rem + 5.2vw, 5.2rem);
  --fs-h1:   clamp(2.1rem, 1.4rem + 3vw, 3.6rem);
  --fs-h2:   clamp(1.7rem, 1.2rem + 2.1vw, 2.7rem);
  --fs-h3:   clamp(1.2rem, 1.0rem + 0.8vw, 1.5rem);
  --fs-lead: clamp(1.06rem, 0.98rem + 0.5vw, 1.3rem);
  --fs-body: 1.02rem;
  --fs-sm:   0.88rem;

  /* Spacing / layout */
  --container: 1180px;
  --container-narrow: 760px;
  --gutter: clamp(1.1rem, 4vw, 2.5rem);
  --section-y: clamp(3.6rem, 6vw, 7rem);
  --radius: 16px;
  --radius-lg: 26px;
  --radius-sm: 10px;
  --shadow-sm: 0 2px 10px rgba(17,46,52,.08);
  --shadow:    0 16px 40px -18px rgba(17,46,52,.35);
  --shadow-lg: 0 30px 70px -28px rgba(17,46,52,.5);
  --ring: 0 0 0 1px var(--sand);
}

/* ---------- Reset / base ---------- */
*,*::before,*::after { box-sizing: border-box; }
* { margin: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--body);
  font-size: var(--fs-body);
  line-height: 1.7;
  color: var(--ink);
  background: var(--cream);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
img, picture, svg, video { display: block; max-width: 100%; }
img { height: auto; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; padding: 0; }
button { font: inherit; cursor: pointer; }

h1,h2,h3,h4 { font-family: var(--display); font-weight: 600; line-height: 1.08; color: var(--ink); letter-spacing: -0.01em; }
h1 { font-size: var(--fs-h1); }
h2 { font-size: var(--fs-h2); }
h3 { font-size: var(--fs-h3); font-weight: 600; }
p { color: var(--ink-2); }
strong { color: var(--ink); font-weight: 600; }

/* ---------- Layout helpers ---------- */
.container { width: 100%; max-width: var(--container); margin-inline: auto; padding-inline: var(--gutter); }
.narrow { max-width: var(--container-narrow); }
.section { padding-block: var(--section-y); }
.section--cream2 { background: var(--cream-2); }
.section--sand { background: linear-gradient(180deg, var(--cream), var(--cream-2)); }
.center { text-align: center; }
.stack > * + * { margin-top: 1.1rem; }

/* Eyebrow / scripture-style label */
.eyebrow {
  display: inline-flex; align-items: center; gap: .6ch;
  font-family: var(--body); font-weight: 600; font-size: .78rem;
  letter-spacing: .18em; text-transform: uppercase;
  color: var(--amber-deep);
}
.eyebrow::before { content:""; width: 26px; height: 2px; background: var(--amber); display:inline-block; }
.eyebrow--center { justify-content: center; }
.on-dark .eyebrow { color: #f0c27a; }

.section-head { max-width: 720px; }
.section-head.center { margin-inline: auto; }
.section-head p { font-size: var(--fs-lead); margin-top: .7rem; color: var(--ink-2); }
.section-head--light h2, .section-head--light p { color: var(--on-dark); }

/* ---------- Buttons ---------- */
.btn {
  --bg: var(--amber); --fg: #2a1c06;
  display: inline-flex; align-items: center; justify-content: center; gap: .6ch;
  background: var(--bg); color: var(--fg);
  font-weight: 600; font-size: .98rem; letter-spacing: .01em;
  padding: .9em 1.6em; border-radius: 999px; border: 1px solid transparent;
  transition: transform .15s ease, box-shadow .2s ease, background .2s ease;
  box-shadow: 0 10px 24px -10px rgba(185,125,39,.7);
}
.btn:hover { transform: translateY(-2px); box-shadow: 0 16px 30px -12px rgba(185,125,39,.8); }
.btn:active { transform: translateY(0); }
.btn--lg { padding: 1.05em 2em; font-size: 1.05rem; }
.btn--teal { --bg: var(--teal); --fg: #fff; box-shadow: 0 10px 24px -10px rgba(31,111,122,.7); }
.btn--ghost { --bg: transparent; --fg: var(--ink); border-color: var(--sand); box-shadow: none; }
.btn--ghost:hover { background: var(--cream-2); }
.btn--on-dark { --bg: transparent; --fg: var(--on-dark); border-color: rgba(246,239,226,.4); box-shadow: none; }
.btn--on-dark:hover { background: rgba(246,239,226,.12); }
.btn-row { display: flex; flex-wrap: wrap; gap: .8rem; }
.btn-row.center { justify-content: center; }

/* ---------- Header / nav ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(250,246,238,.86);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--sand);
}
.nav { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 72px; }
.brand { display: flex; align-items: center; gap: .7rem; }
.brand img { width: 40px; height: 40px; object-fit: contain; }
.brand-name { font-family: var(--display); font-weight: 600; font-size: 1.12rem; color: var(--ink); line-height: 1.05; }
.brand-name small { display:block; font-family: var(--body); font-weight: 500; font-size: .64rem; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-2); }
.nav-links { display: flex; align-items: center; gap: .35rem; }
.nav-links a { padding: .5em .9em; border-radius: 999px; font-weight: 500; font-size: .96rem; color: var(--ink-2); transition: color .15s, background .15s; }
.nav-links a:hover { color: var(--ink); background: var(--cream-2); }
.nav-links a.active { color: var(--teal); }
.nav-links .btn { display: none; } /* inline Donate is for the mobile dropdown only; desktop uses .nav-cta */
.nav-cta { display: flex; align-items: center; gap: .6rem; }
.nav-toggle { display: none; background: none; border: 0; padding: .4rem; color: var(--ink); }
.nav-toggle svg { width: 28px; height: 28px; }

/* ---------- Hero ---------- */
.hero { position: relative; min-height: min(88vh, 760px); display: flex; align-items: flex-end; color: var(--on-dark); isolation: isolate; }
.hero__media { position: absolute; inset: 0; z-index: -2; }
.hero__media img { width: 100%; height: 100%; object-fit: cover; }
.hero__scrim {
  position: absolute; inset: 0; z-index: -1;
  background:
    linear-gradient(180deg, rgba(11,30,34,.34) 0%, rgba(11,30,34,.05) 30%, rgba(11,30,34,.55) 78%, rgba(11,30,34,.86) 100%),
    radial-gradient(120% 80% at 20% 110%, rgba(20,63,71,.6), transparent 60%);
}
.hero__inner { padding-block: clamp(2.5rem, 6vw, 5rem); max-width: 880px; }
.hero h1 { color: #fff; font-size: var(--fs-hero); font-weight: 600; text-wrap: balance; text-shadow: 0 2px 30px rgba(0,0,0,.35); }
.hero h1 em { font-style: italic; color: #f3c884; }
.hero__lead { font-size: var(--fs-lead); color: var(--on-dark); max-width: 560px; margin-top: 1.1rem; text-shadow: 0 1px 16px rgba(0,0,0,.4); }
.hero .btn-row { margin-top: 1.8rem; }
.hero__verse { margin-top: 1.6rem; font-family: var(--display); font-style: italic; font-size: 1.05rem; color: #f0e3c9; opacity: .95; }

/* floating trust chips on hero */
.hero__chips { position: absolute; right: var(--gutter); top: clamp(1.5rem,5vw,3rem); display: grid; gap: .6rem; z-index: 1; }
.chip {
  display: inline-flex; align-items: center; gap: .55ch;
  background: rgba(250,246,238,.92); color: var(--ink);
  padding: .5em .9em; border-radius: 999px; font-size: .82rem; font-weight: 600;
  box-shadow: var(--shadow-sm);
}
.chip svg { width: 16px; height: 16px; color: var(--teal); }

/* ---------- Need band (scripture) ---------- */
.verse-band { background: var(--teal-deep); color: var(--on-dark); position: relative; overflow: hidden; }
.verse-band::after { content:""; position:absolute; inset:0; background: radial-gradient(80% 120% at 90% -10%, rgba(217,154,62,.18), transparent 55%); pointer-events:none; }
.verse-band .container { position: relative; }
.verse-band blockquote { font-family: var(--display); font-size: clamp(1.5rem, 1rem + 2.4vw, 2.5rem); line-height: 1.25; font-weight: 500; color: #fff; max-width: 18ch; }
.verse-band .ref { display:block; margin-top: 1.1rem; font-family: var(--body); font-size: .9rem; letter-spacing: .14em; text-transform: uppercase; color: #f0c27a; }
.verse-grid { display: grid; grid-template-columns: 1.1fr 1fr; gap: clamp(2rem,5vw,5rem); align-items: center; }
.verse-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 1.4rem 1.2rem; }
.stat { background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.12); border-radius: var(--radius); padding: 1.2rem 1.3rem; }
.stat b { font-family: var(--display); font-size: clamp(1.8rem,1rem+2.4vw,2.6rem); color: #f3c884; display:block; line-height: 1; }
.stat span { font-size: .92rem; color: var(--on-dark-mut); margin-top: .5rem; display:block; }

/* ---------- Pillars (programs) ---------- */
.pillars { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.4rem; }
.pillar {
  position: relative; border-radius: var(--radius-lg); overflow: hidden; min-height: 420px;
  display: flex; flex-direction: column; justify-content: flex-end; color: var(--on-dark);
  box-shadow: var(--shadow); isolation: isolate;
}
.pillar img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; transition: transform .6s ease; }
.pillar::after { content:""; position:absolute; inset:0; z-index:-1; background: linear-gradient(180deg, rgba(11,30,34,.05) 30%, rgba(11,30,34,.55) 62%, rgba(11,30,34,.9) 100%); }
.pillar:hover img { transform: scale(1.05); }
.pillar__body { padding: 1.6rem; }
.pillar h3 { color: #fff; font-size: 1.4rem; }
.pillar p { color: var(--on-dark-mut); font-size: .96rem; margin-top: .5rem; }
.pillar__link { margin-top: 1rem; display: inline-flex; align-items: center; gap: .5ch; font-weight: 600; color: #f3c884; font-size: .92rem; }
.pillar__link svg { width: 16px; height: 16px; transition: transform .2s; }
.pillar:hover .pillar__link svg { transform: translateX(4px); }

/* ---------- Story split ---------- */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(2rem,5vw,4.5rem); align-items: center; }
.split--reverse .split__media { order: 2; }
.split__media { position: relative; }
.split__media img { width: 100%; border-radius: var(--radius-lg); box-shadow: var(--shadow); aspect-ratio: 4/5; object-fit: cover; }
.split__media .badge {
  position: absolute; left: -18px; bottom: 22px; background: var(--white);
  border-radius: var(--radius); padding: 1rem 1.2rem; box-shadow: var(--shadow);
  max-width: 220px; border: 1px solid var(--sand);
}
.split__media .badge b { font-family: var(--display); color: var(--teal); font-size: 1.6rem; display:block; line-height:1; }
.split__media .badge span { font-size: .82rem; color: var(--ink-2); }
.split__body h2 + p { margin-top: 1rem; }
.split__body p + p { margin-top: 1rem; }

/* ---------- Gallery ---------- */
.gallery { display: grid; grid-template-columns: repeat(4, 1fr); gap: .8rem; }
.gallery a { display:block; border-radius: var(--radius-sm); overflow: hidden; aspect-ratio: 1; background: var(--sand); }
.gallery img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease, filter .3s; }
.gallery a:hover img { transform: scale(1.08); filter: saturate(1.1); }
.gallery--tall a:nth-child(6n+1) { grid-row: span 2; aspect-ratio: 1/2; }

/* mosaic strip for home */
.mosaic { display: grid; grid-template-columns: repeat(6,1fr); grid-auto-rows: 130px; gap: .7rem; }
.mosaic a { overflow:hidden; border-radius: var(--radius-sm); }
.mosaic img { width:100%; height:100%; object-fit:cover; transition: transform .5s; }
.mosaic a:hover img { transform: scale(1.07); }
.mosaic a:nth-child(1){ grid-column: span 2; grid-row: span 2; }
.mosaic a:nth-child(4){ grid-column: span 2; }
.mosaic a:nth-child(7){ grid-row: span 2; }

/* ---------- CTA band ---------- */
.cta-band { position: relative; overflow: hidden; color: var(--on-dark); isolation:isolate; }
.cta-band img { position:absolute; inset:0; width:100%; height:100%; object-fit:cover; z-index:-2; }
.cta-band::after { content:""; position:absolute; inset:0; z-index:-1; background: linear-gradient(100deg, rgba(20,63,71,.94), rgba(20,63,71,.7) 55%, rgba(20,63,71,.4)); }
.cta-band .container { display: grid; grid-template-columns: 1.3fr auto; gap: 2rem; align-items: center; }
.cta-band h2 { color: #fff; }
.cta-band p { color: var(--on-dark); font-size: var(--fs-lead); margin-top: .7rem; max-width: 46ch; }

/* ---------- Cards (give / generic) ---------- */
.cards { display: grid; grid-template-columns: repeat(3,1fr); gap: 1.2rem; }
.card { background: var(--white); border: 1px solid var(--sand); border-radius: var(--radius); padding: 1.6rem; box-shadow: var(--shadow-sm); }
.card .ic { width: 46px; height: 46px; border-radius: 12px; display:grid; place-items:center; background: var(--cream-2); color: var(--teal); margin-bottom: 1rem; }
.card .ic svg { width: 24px; height: 24px; }
.card h3 { font-size: 1.15rem; }
.card p { margin-top: .5rem; font-size: .96rem; }

/* give amounts */
.give-amounts { display:grid; grid-template-columns: repeat(3,1fr); gap: .8rem; }
.give-amounts .amt { text-align:center; border:1px solid var(--sand); background:var(--white); border-radius: var(--radius); padding: 1.2rem .6rem; }
.give-amounts .amt b { font-family:var(--display); font-size:1.5rem; color:var(--teal); display:block; }
.give-amounts .amt span { font-size:.84rem; color:var(--ink-2); }

/* ---------- Timeline ---------- */
.timeline { position: relative; display: grid; gap: 1.6rem; padding-left: 1.6rem; }
.timeline::before { content:""; position:absolute; left: 5px; top: 6px; bottom: 6px; width: 2px; background: linear-gradient(var(--amber), var(--sand)); }
.timeline li { position: relative; }
.timeline li::before { content:""; position:absolute; left: -1.6rem; top: .35rem; width: 12px; height: 12px; border-radius: 50%; background: var(--amber); box-shadow: 0 0 0 4px var(--cream); transform: translateX(-1px); }
.timeline .yr { font-family: var(--display); color: var(--teal); font-weight: 600; font-size: 1.1rem; }
.timeline p { margin-top: .2rem; }

/* ---------- Page hero (interior) ---------- */
.page-hero { position: relative; color: var(--on-dark); isolation:isolate; padding-block: clamp(4rem,10vw,8rem) clamp(3rem,7vw,5rem); }
.page-hero img { position:absolute; inset:0; width:100%; height:100%; object-fit:cover; z-index:-2; }
.page-hero::after { content:""; position:absolute; inset:0; z-index:-1; background: linear-gradient(180deg, rgba(11,30,34,.45), rgba(11,30,34,.75)); }
.page-hero h1 { color:#fff; font-size: var(--fs-h1); max-width: 16ch; }
.page-hero p { color: var(--on-dark); font-size: var(--fs-lead); max-width: 52ch; margin-top: .9rem; }
.breadcrumb { font-size:.82rem; letter-spacing:.06em; color: var(--on-dark-mut); margin-bottom: 1rem; }
.breadcrumb a:hover { color:#fff; }

/* prose */
.prose p { margin-top: 1.1rem; font-size: 1.05rem; }
.prose h2 { margin-top: 2.2rem; }
.prose h3 { margin-top: 1.6rem; }

/* ---------- Footer ---------- */
.site-footer { background: var(--ink); color: var(--on-dark-mut); padding-block: clamp(3rem,5vw,4.5rem) 2rem; }
.footer-grid { display:grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 2rem; }
.site-footer .brand-name { color: #fff; }
.site-footer .brand-name small { color: var(--on-dark-mut); }
.site-footer p { color: var(--on-dark-mut); margin-top: 1rem; max-width: 38ch; font-size: .95rem; }
.footer-col h4 { font-family: var(--body); font-size: .8rem; letter-spacing:.14em; text-transform:uppercase; color:#fff; margin-bottom: 1rem; }
.footer-col a { display:block; padding: .3rem 0; color: var(--on-dark-mut); font-size:.95rem; }
.footer-col a:hover { color:#fff; }
.footer-verse { font-family: var(--display); font-style: italic; color: #f0c27a; font-size: 1.05rem; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.1); margin-top: 2.5rem; padding-top: 1.5rem; display:flex; justify-content:space-between; flex-wrap:wrap; gap:.6rem; font-size:.84rem; color: rgba(255,255,255,.55); }

/* ---------- Lightbox ---------- */
.lightbox { position: fixed; inset: 0; z-index: 100; background: rgba(11,30,34,.92); display:none; align-items:center; justify-content:center; padding: 4vw; }
.lightbox.open { display:flex; }
.lightbox img { max-width: 92vw; max-height: 88vh; border-radius: 8px; box-shadow: var(--shadow-lg); }
.lightbox button { position:absolute; top: 4vw; right: 4vw; background: rgba(255,255,255,.12); color:#fff; border:0; width:46px; height:46px; border-radius:50%; font-size:1.4rem; }

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

/* ---------- Responsive ---------- */
@media (max-width: 940px) {
  .verse-grid { grid-template-columns: 1fr; gap: 2rem; }
  .pillars { grid-template-columns: 1fr 1fr; }
  .cards { grid-template-columns: 1fr 1fr; }
  .split { grid-template-columns: 1fr; gap: 2rem; }
  .split--reverse .split__media { order: 0; }
  .split__media img { aspect-ratio: 16/11; }
  .split__media .badge { left: 14px; }
  .cta-band .container { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .gallery { grid-template-columns: repeat(3,1fr); }
}
@media (max-width: 720px) {
  .nav-links, .nav-cta .btn { display: none; }
  .nav-toggle { display: inline-flex; }
  .site-header.open .nav-links {
    display: flex; position: absolute; top: 72px; left:0; right:0;
    flex-direction: column; align-items: stretch; gap: 0;
    background: var(--cream); border-bottom: 1px solid var(--sand); padding: .6rem var(--gutter) 1.2rem;
    box-shadow: var(--shadow);
  }
  .site-header.open .nav-links a { padding: .85em .6em; border-bottom: 1px solid var(--sand); border-radius:0; }
  .site-header.open .nav-links .btn { display:inline-flex; margin-top: .8rem; border-bottom:0; }
  .pillars { grid-template-columns: 1fr; }
  .cards { grid-template-columns: 1fr; }
  .give-amounts { grid-template-columns: 1fr 1fr; }
  .verse-stats { grid-template-columns: 1fr 1fr; }
  .gallery { grid-template-columns: repeat(2,1fr); gap:.6rem; }
  .mosaic { grid-auto-rows: 110px; }
  .hero__chips { display:none; }
  .footer-grid { grid-template-columns: 1fr; }
  .hero { min-height: 90vh; }
}
@media (max-width: 420px) {
  .give-amounts { grid-template-columns: 1fr; }
}
