/* Layout: a cross-section of ground. Dark soil band carries the logo and the Word; quiet light ground for everything else. */
:root {
  --sky: #EEF2EA;
  --surface: #FFFFFF;
  --ink: #1F2A1E;
  --muted: #56624F;
  --leaf: #3F6B3A;
  --soil: #2B211A;
  --soil-ink: #EFE6D8;
  --gold: #C8962E;
  --line: #D3DCCB;
  --display: "Libre Caslon Display", "Iowan Old Style", Georgia, serif;
  --body: "Karla", "Segoe UI", system-ui, sans-serif;
}
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) {
  --sky: #141A13; --surface: #1C241B; --ink: #E7ECE2; --muted: #A3AF9C; --leaf: #8DBF7F;
  --soil: #0D0A07; --soil-ink: #E9DFCF; --gold: #E0B252; --line: #2E3A2C; color-scheme: dark } }
:root[data-theme="dark"] {
  --sky: #141A13; --surface: #1C241B; --ink: #E7ECE2; --muted: #A3AF9C; --leaf: #8DBF7F;
  --soil: #0D0A07; --soil-ink: #E9DFCF; --gold: #E0B252; --line: #2E3A2C; color-scheme: dark }

* { box-sizing: border-box }
[hidden] { display: none !important }
body { margin: 0; background: var(--sky); color: var(--ink); font: 17px/1.65 var(--body) }
.wrap { max-width: 1000px; margin: 0 auto;
  padding-left: max(20px, env(safe-area-inset-left, 0px)); padding-right: max(20px, env(safe-area-inset-right, 0px)) }
h1, h2, h3 { font-family: var(--display); font-weight: 400; line-height: 1.1; text-wrap: balance; margin: 0 }
h2 { font-size: clamp(1.9rem, 4.5vw, 2.7rem) }
h3 { font-size: 1.35rem }
p { margin: 0; max-width: 60ch }
a { color: var(--leaf) }
.eyebrow { font-size: .76rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--leaf) }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px }
.stack { display: grid; gap: 14px; align-content: start }

.mark { display: inline-block; background: currentColor; aspect-ratio: 664 / 900;
  -webkit-mask: url("logo.png") center / contain no-repeat; mask: url("logo.png") center / contain no-repeat }

/* header */
body::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); z-index: 10; background: var(--sky) }
header.top { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 20; background: color-mix(in srgb, var(--sky) 92%, transparent); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line) }
.nav { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding-block: 12px }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); font-family: var(--display); font-size: 1.2rem; white-space: nowrap }
.brand .mark { height: 32px; color: var(--ink) }
.nav ul { display: flex; align-items: center; gap: 18px; list-style: none; margin: 0; padding: 0 }
.nav ul a { color: var(--ink); text-decoration: none; font-weight: 500 }
.nav ul a[aria-current="page"] { color: var(--leaf); text-decoration: underline; text-underline-offset: 6px }
@media (max-width: 480px) { .brand span.word { display: none } }

.btn { display: inline-block; background: var(--leaf); color: var(--sky); padding: 12px 22px; border-radius: 999px; text-decoration: none; border: 0; font: 700 1rem var(--body); cursor: pointer }
.btn:hover { filter: brightness(1.08) }
.btn.ghost { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1.5px currentColor }
.btn.small { padding: 7px 16px; font-size: .9rem }
.nav .btn { color: var(--sky) }

/* soil band */
.soil { background: var(--soil); color: var(--soil-ink) }
.soil .eyebrow { color: var(--gold) }
.soil .btn { background: var(--soil-ink); color: var(--soil) }
.soil .btn.ghost { background: transparent; color: var(--soil-ink) }
.soil + .rootline, .rootline { height: 5px; background: var(--leaf) }

.hero { padding-block: clamp(44px, 8vw, 88px) }
.hero-grid { display: grid; grid-template-columns: 1.2fr .8fr; gap: 36px; align-items: center }
.hero h1 { font-size: clamp(2.6rem, 7vw, 4.8rem) }
.hero h1 em { font-style: italic; color: var(--gold) }
.hero .lede { font-size: 1.15rem; opacity: .85 }
.hero .mark { width: 100%; max-width: 320px; justify-self: center; color: var(--soil-ink) }
.ctas { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 8px }
@media (max-width: 720px) { .hero-grid { grid-template-columns: 1fr } .hero .mark { max-width: 190px; order: -1 } }

section.block { padding-block: clamp(56px, 8vw, 92px) }
.split { display: grid; grid-template-columns: .9fr 1.1fr; gap: 44px }
@media (max-width: 720px) { .split { grid-template-columns: 1fr; gap: 18px } }
.split > * { min-width: 0 }
.lead { font-size: 1.12rem }
.muted { color: var(--muted) }

/* daily verse: set for reading, not display */
.daily { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: clamp(24px, 5vw, 48px); display: grid; gap: 18px; justify-items: center; text-align: center }
.daily-head { display: grid; gap: 4px; justify-items: center }
.daily-date { font-variant-numeric: tabular-nums; color: var(--muted); font-size: .92rem }
.daily .daily-subject { font-family: var(--body); font-weight: 700; font-size: clamp(1.3rem, 3vw, 1.55rem); line-height: 1.25; color: var(--ink) }
.passages { display: grid; gap: 26px; justify-items: center; width: 100%; max-width: 38rem }
.passage { display: grid; gap: 10px; justify-items: center }
.passage + .passage { padding-top: 26px; border-top: 1px solid var(--line); width: 100% }
.daily blockquote { margin: 0; font-family: "Lora", Georgia, "Iowan Old Style", serif; font-weight: 400; font-size: clamp(1.08rem, 2.4vw, 1.22rem); line-height: 1.8; color: var(--ink); text-wrap: pretty; max-width: 36rem }
.daily cite { font: 700 .78rem/1 var(--body); font-style: normal; letter-spacing: .12em; text-transform: uppercase; color: var(--leaf); padding: 7px 12px; border-radius: 999px; background: color-mix(in srgb, var(--leaf) 12%, transparent) }
.daily .row { justify-content: center }
.example { display: inline-block; font: 700 .68rem var(--body); letter-spacing: .1em; text-transform: uppercase; padding: 2px 8px; border-radius: 999px; border: 1px dashed currentColor; opacity: .75; vertical-align: middle }
.row { display: flex; gap: 10px; flex-wrap: wrap; align-items: center }
.toast { font-size: .9rem; color: var(--leaf); font-weight: 500 }

/* reach out */
.ways { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; border-top: 1px solid var(--line); margin-top: 28px }
.ways > div { padding: 22px 22px 6px 0; display: grid; gap: 8px; align-content: start; min-width: 0 }
.ways > div + div { border-left: 1px solid var(--line); padding-left: 22px }
@media (max-width: 720px) { .ways { grid-template-columns: 1fr } .ways > div + div { border-left: 0; border-top: 1px solid var(--line); padding-left: 0 } }
.contact-line { font-variant-numeric: tabular-nums; font-weight: 700; user-select: all }

form { display: grid; gap: 14px; margin-top: 28px; max-width: 640px }
label { font-weight: 700; font-size: .9rem; display: grid; gap: 6px }
input, textarea, select { font: inherit; color: var(--ink); background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; width: 100% }
textarea { min-height: 120px; resize: vertical }
.row2 { display: grid; grid-template-columns: 1fr; gap: 14px }
.sent { background: var(--surface); border: 1px solid var(--leaf); border-radius: 10px; padding: 14px 16px; color: var(--leaf); font-weight: 500 }

/* apps */
.apps { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 24px }
.apps a { display: grid; gap: 4px; padding: 20px 22px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); text-decoration: none; color: var(--ink) }
.apps a:hover { border-color: var(--leaf) }
.apps .soon { font-size: .82rem; color: var(--muted) }
@media (max-width: 560px) { .apps { grid-template-columns: 1fr } }

/* photos */
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 20px; margin-top: 32px }
.photo { margin: 0; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; overflow: hidden; display: grid }
.photo img { display: block; width: 100%; height: auto; aspect-ratio: 1; object-fit: cover; max-width: 100% }
.photo cite { font-style: normal; font-weight: 700; color: var(--leaf); min-width: 0 }
.photo-toast { padding: 0 14px 12px }
.photo .img-old { aspect-ratio: 4 / 5; max-width: 100%; display: grid; place-items: end start; padding: 22px; color: #F6F1E7; font-family: var(--display); font-size: 1.35rem; line-height: 1.25; background-size: cover; background-position: center }
.photo figcaption { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 12px 14px }
.tag { font-size: .72rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted) }

/* give */
.give-amounts { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-top: 8px }
.give-amounts button { font: 700 1.1rem var(--body); font-variant-numeric: tabular-nums; padding: 14px 0; border-radius: 12px; border: 1.5px solid var(--line); background: var(--surface); color: var(--ink); cursor: pointer }
.give-amounts button[aria-pressed="true"] { border-color: var(--leaf); background: var(--leaf); color: var(--sky) }
@media (max-width: 420px) { .give-amounts { grid-template-columns: repeat(2, 1fr) } }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: clamp(22px, 4vw, 36px); display: grid; gap: 16px; align-content: start }

footer { background: var(--soil); color: var(--soil-ink); padding-block: 40px }
.foot { display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; font-size: .92rem; align-items: center }
.foot .brand { color: var(--soil-ink) }
.foot .brand .mark { color: var(--soil-ink); height: 38px }
.foot a { color: var(--soil-ink) }
.foot nav { display: flex; gap: 18px }

.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0 }

/* photos: floating slideshow + contact sheet */
.float { background: var(--surface); border: 1px solid var(--line); border-radius: 20px; box-shadow: var(--float-shadow) }
:root { --float-shadow: 0 1px 2px rgba(31,42,30,.06), 0 14px 36px -10px rgba(31,42,30,.22), 0 34px 70px -30px rgba(31,42,30,.28); --frame: #1B1712; --frame-ink: #E9DFCF }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --float-shadow: 0 1px 2px rgba(0,0,0,.4), 0 16px 40px -10px rgba(0,0,0,.6), 0 36px 80px -30px rgba(0,0,0,.7); --frame: #0B0907 } }
:root[data-theme="dark"] { --float-shadow: 0 1px 2px rgba(0,0,0,.4), 0 16px 40px -10px rgba(0,0,0,.6), 0 36px 80px -30px rgba(0,0,0,.7); --frame: #0B0907 }

.viewer { width: 100%; max-width: 600px; margin: 36px auto 8px; padding: clamp(12px, 2.5vw, 20px); display: grid; gap: 14px; transform: translateY(-2px) }
.stage { position: relative; touch-action: pan-y; border-radius: 12px; overflow: hidden; background: var(--sky) }
.stage .slide { display: none; margin: 0 }
.stage .slide.is-active { display: block; animation: fade-in .25s ease }
.stage .slide img { display: block; width: 100%; height: auto; aspect-ratio: 1; object-fit: cover; max-width: 100% }
@keyframes fade-in { from { opacity: .35 } to { opacity: 1 } }
.nav-arrow { position: absolute; top: 50%; z-index: 2; translate: 0 -50%; width: 42px; height: 42px; border-radius: 50%; border: 0; cursor: pointer;
  background: color-mix(in srgb, var(--surface) 82%, transparent); color: var(--ink); font: 400 1.8rem/1 var(--body); box-shadow: 0 4px 14px rgba(0,0,0,.18); display: grid; place-items: center; padding-bottom: 4px }
.nav-arrow.prev { left: 10px } .nav-arrow.next { right: 10px }
.nav-arrow:hover { background: var(--surface) }

.strip { display: grid; grid-template-columns: repeat(9, minmax(0, 1fr)); gap: clamp(4px, 1vw, 8px); align-items: center; padding: 6px 2px }
.strip-cell { padding: 0; border: 0; background: none; cursor: pointer; border-radius: 7px; opacity: .55; transition: opacity .15s ease, transform .15s ease }
.strip-cell img { display: block; width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 7px; max-width: 100% }
.strip-cell:hover { opacity: .9 }
.strip-cell.is-current { opacity: 1; transform: scale(1.14); box-shadow: 0 0 0 2.5px var(--surface), 0 0 0 5px var(--leaf), 0 6px 14px rgba(0,0,0,.2); z-index: 1 }

.viewer-bar, .loupe-bar { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap }
.frame-no { font: 700 .82rem/1 ui-monospace, Menlo, Consolas, monospace; font-variant-numeric: tabular-nums; letter-spacing: .06em; color: var(--muted) }
.viewer-toast { margin: 0; text-align: center }

.sheet-backdrop { position: fixed; inset: 0; z-index: 50; display: grid; place-items: center; background: rgba(20,16,12,.45); backdrop-filter: blur(5px);
  padding: max(16px, env(safe-area-inset-top, 0px)) max(16px, env(safe-area-inset-right, 0px)) max(16px, env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px)) }
.sheet { position: relative; width: min(980px, 100%); max-height: 100%; display: grid; grid-template-rows: auto auto minmax(0, 1fr); overflow: hidden; animation: rise .22s ease }
@keyframes rise { from { opacity: 0; transform: translateY(12px) } to { opacity: 1; transform: none } }
.sheet-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 16px 18px 6px }
.sheet-head h2 { font-size: 1.6rem }
.close-x { width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--line); background: var(--surface); color: var(--ink); font: 400 1.6rem/1 var(--body); cursor: pointer; display: grid; place-items: center; padding-bottom: 3px; flex: none }
.close-x:hover { border-color: var(--leaf); color: var(--leaf) }
.sheet-tabs { display: flex; gap: 6px; padding: 8px 18px 12px; overflow-x: auto; border-bottom: 1px solid var(--line) }
.sheet-tab { display: grid; gap: 2px; text-align: left; padding: 8px 14px; border-radius: 10px; border: 1px solid var(--line); background: var(--sky); color: var(--ink); cursor: pointer; font: 700 .9rem var(--body); flex: none }
.sheet-tab small { font: 500 .72rem ui-monospace, Menlo, monospace; color: var(--muted); font-variant-numeric: tabular-nums }
.sheet-tab[aria-selected="true"] { background: var(--leaf); border-color: var(--leaf); color: var(--sky) }
.sheet-tab[aria-selected="true"] small { color: var(--sky); opacity: .85 }
.sheet-grid { overflow-y: auto; background: var(--frame); padding: 16px; display: grid; grid-template-columns: repeat(auto-fill, minmax(104px, 1fr)); gap: 14px 10px; align-content: start }
.frame { display: grid; gap: 6px; padding: 5px 5px 6px; border: 0; border-radius: 3px; background: #F4EFE6; cursor: pointer; transition: transform .12s ease }
.frame img { display: block; width: 100%; aspect-ratio: 1; object-fit: cover; max-width: 100% }
.frame .frame-no { color: #5A4E40; font-size: .7rem; text-align: left }
.frame:hover { transform: translateY(-2px) scale(1.03) }
@media (max-width: 520px) { .sheet-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px 8px; padding: 10px } .sheet-head h2 { font-size: 1.3rem } }

.loupe { position: absolute; inset: 0; z-index: 3; background: var(--surface); display: grid; grid-template-rows: auto auto auto; align-content: center; gap: 14px; padding: 64px 18px 18px; justify-items: center; overflow-y: auto }
.loupe img { width: min(560px, 100%); max-height: calc(100vh - 220px); aspect-ratio: 1; object-fit: contain; border-radius: 10px; box-shadow: var(--float-shadow); min-height: 0 }
.loupe .close-x { position: absolute; top: 12px; right: 14px }
.loupe-bar { width: min(560px, 100%) }

@media (prefers-reduced-motion: reduce) { .stage .slide.is-active, .sheet { animation: none } .strip-cell, .frame { transition: none } }

.verse-ref { display: inline-block; margin-top: 6px; font-weight: 700; font-size: .85rem; letter-spacing: .08em; text-transform: uppercase; color: var(--leaf) }

/* round 5 */
.nav ul a:not(.btn) { display: inline-block; padding-block: 12px; margin-block: -12px }
.brand { padding-block: 6px; margin-block: -6px }
.btn { position: relative }
.btn.small::after { content: ""; position: absolute; inset: -7px -4px }
.strip-cell { position: relative }
.strip-cell::after { content: ""; position: absolute; inset: -8px -2px }

.day-nav { display: flex; gap: 6px; justify-content: center; flex-wrap: wrap }
.day-nav button { font: 600 .85rem var(--body); color: var(--muted); background: none; border: 1px solid var(--line); border-radius: 999px; padding: 8px 14px; min-height: 38px; cursor: pointer }
.day-nav button:hover:not(:disabled) { color: var(--leaf); border-color: var(--leaf) }
.day-nav button:disabled { opacity: .45; cursor: default }
.daily-note { font-size: .85rem }
.daily[aria-busy="true"] .passages { opacity: .5; transition: opacity .2s }

.form-private { margin: 0; font-size: .95rem; opacity: .85 }
.opt { font-weight: 400; opacity: .7 }
.form-error { margin: 0; color: var(--gold); font-weight: 600 }
.cf-turnstile:empty { display: none }
.thanks { margin-top: 28px; max-width: 640px; display: grid; gap: 12px; padding: clamp(20px, 4vw, 30px); border-radius: 16px; border: 1px solid color-mix(in srgb, var(--soil-ink) 25%, transparent); background: color-mix(in srgb, var(--soil-ink) 6%, transparent) }
.thanks:focus { outline: none }
.thanks h3 { font-size: 1.6rem }
.thanks p { opacity: .85 }
.thanks .thanks-preview { font-size: .85rem; opacity: .65 }
.thanks .btn { justify-self: start }

.give-more { display: grid; gap: 28px; margin-top: clamp(40px, 6vw, 64px) }
.by-mail { display: grid; gap: 10px; padding-top: 28px; border-top: 1px solid var(--line) }
.by-mail h2 { font-size: 1.6rem }
address { font-style: normal; line-height: 1.6 }
.disclosure { max-width: none; font-size: .72rem; line-height: 1.6; letter-spacing: .02em; color: var(--muted) }
.disclosure a { color: inherit }

.scripture-note { max-width: 70ch; margin: 28px auto 0; font-size: .74rem; line-height: 1.6; color: var(--muted); text-align: center }

.prose { max-width: 720px; display: grid; gap: 14px }
.prose h1 { font-size: clamp(2.2rem, 5vw, 3.2rem) }
.prose h2 { font-size: 1.45rem; margin-top: 18px }
.prose p { max-width: 68ch }

.notfound { display: grid; gap: 16px; justify-items: center; text-align: center; padding-block: 20px }
.notfound .mark { height: 120px; color: var(--ink) }
.notfound h1 { font-size: clamp(2rem, 5vw, 3rem) }
.notfound p { margin-inline: auto }
.notfound .ctas { justify-content: center }

.foot { align-items: flex-start }
.foot-id { display: grid; gap: 10px }
.foot address { opacity: .75; font-size: .9rem; padding-left: 38px }
.foot-nav { flex-wrap: wrap; gap: 6px 18px }
.foot-nav a { display: inline-block; padding-block: 10px; margin-block: -10px }
.foot-legal { opacity: .6; font-size: .85rem; flex-basis: 100% }
.nav ul a.btn[aria-current="page"] { color: var(--sky); text-decoration: none; box-shadow: 0 0 0 2px var(--sky), 0 0 0 4px var(--leaf) }

/* social */
.social { display: flex; flex-wrap: nowrap; gap: clamp(4px, 1.6vw, 8px); list-style: none; margin: 0; padding: 0; flex-basis: 100%; min-width: 0 }
.social li { flex: 0 1 auto; min-width: 0 }
.social a { display: grid; place-items: center; width: clamp(30px, 10vw, 40px); height: clamp(30px, 10vw, 40px); border-radius: 50%; color: var(--soil-ink);
  border: 1px solid color-mix(in srgb, var(--soil-ink) 30%, transparent); transition: color .15s ease, border-color .15s ease, background .15s ease }
.social a:hover, .social a:focus-visible { color: var(--soil); background: var(--soil-ink); border-color: var(--soil-ink) }
.social svg { width: 45%; height: 45%; fill: currentColor }
@media (prefers-reduced-motion: reduce) { .social a { transition: none } }
.photo-page { max-width: 640px }
.photo-single { display: block; width: 100%; height: auto; border-radius: 12px; max-width: 100% }
.photo-page .viewer-bar { justify-content: space-between }
.photo-back { text-align: center; margin: 18px auto 0 }
.photo-back a { font-weight: 700; color: var(--leaf) }
a.contact-line { color: inherit; text-decoration: underline; text-underline-offset: 3px }
.social a[aria-disabled="true"] { cursor: default }

/* give: Stripe checkout picker */
.give-card { gap: 14px }
.freq { display: grid; grid-template-columns: 1fr 1fr; padding: 4px; border-radius: 999px; background: var(--sky); border: 1px solid var(--line) }
.freq button { font: 700 .95rem var(--body); padding: 10px 0; border: 0; border-radius: 999px; background: none; color: var(--muted); cursor: pointer }
.freq button[aria-checked="true"] { background: var(--surface); color: var(--ink); box-shadow: 0 1px 3px rgba(0,0,0,.12) }
.give-amounts button[aria-checked="true"] { border: 2px solid var(--leaf); background: color-mix(in srgb, var(--leaf) 12%, var(--surface)); color: var(--leaf) }
.give-amounts .amt-other { grid-column: 1 / -1; font-size: 1rem }
.give-go { text-align: center; font-size: 1.05rem; padding-block: 14px }
.give-note { margin: 0; font-size: .85rem; color: var(--muted) }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden }
/* keep "Prayer:" and its address on one line; the column sizes the text to fit */
.ways > div:has(.contact-row) { container-type: inline-size }
.contact-row { white-space: nowrap; font-size: min(1rem, 5.6cqi) }
