/* ==========================================================
   Lost in the Dark — Advent Devotional
   Colors live here so the whole look can be tuned in one spot.
   ========================================================== */
:root {
  --night: #0b1220;
  --night-2: #111a2e;
  --night-3: #18233b;
  --gold: #d9b66a;
  --gold-bright: #f1d48c;
  --gold-deep: #a9823a;
  --ember: #f4a640;
  --parchment: #f3e8d2;
  --parchment-2: #e9dbbd;
  --ink: #2b2118;
  --ink-soft: #5c4a38;
  --berry: #9c2b23;
  --text: #ece4d4;
  --text-dim: #b8ad98;
  --line: rgba(217, 182, 106, 0.35);

  --font-display: "Cinzel", "Trajan Pro", Georgia, serif;
  --font-body: "EB Garamond", Garamond, Georgia, serif;

  --radius: 10px;
  --maxw: 1100px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  background: var(--night);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 19px;
  line-height: 1.6;
  overflow-x: hidden;
}
a { color: var(--gold-bright); }
img { max-width: 100%; display: block; }
button { font: inherit; cursor: pointer; }
:focus-visible { outline: 2px solid var(--gold-bright); outline-offset: 3px; }

/* ---------- Starry background ---------- */
.sky {
  position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(ellipse at 50% 120%, rgba(244,166,64,.16), transparent 55%),
    radial-gradient(ellipse at 50% -20%, #1b2a4a 0%, transparent 60%),
    var(--night);
}
.sky::before, .sky::after {
  content: ""; position: absolute; inset: 0;
  background-image:
    radial-gradient(1px 1px at 10% 20%, #fff8, transparent),
    radial-gradient(1px 1px at 30% 70%, #fff6, transparent),
    radial-gradient(1.5px 1.5px at 55% 15%, #fffa, transparent),
    radial-gradient(1px 1px at 75% 40%, #fff7, transparent),
    radial-gradient(1px 1px at 90% 80%, #fff5, transparent),
    radial-gradient(1.5px 1.5px at 20% 90%, #fff6, transparent),
    radial-gradient(1px 1px at 65% 60%, #fff5, transparent),
    radial-gradient(1px 1px at 45% 35%, #fff6, transparent);
  background-size: 320px 320px;
  opacity: .8;
}
.sky::after { background-size: 470px 470px; background-position: 120px 60px; opacity: .5; animation: twinkle 6s ease-in-out infinite alternate; }
@keyframes twinkle { from { opacity: .25; } to { opacity: .6; } }

/* ---------- Top bar ---------- */
.topbar {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 14px max(16px, calc((100vw - var(--maxw)) / 2));
  padding-top: calc(14px + env(safe-area-inset-top));
  background: rgba(11, 18, 32, .85);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(217,182,106,.15);
}
.brand { display: flex; align-items: center; gap: 14px; text-decoration: none; color: var(--text); }
.brand-mark {
  font-family: var(--font-display); font-weight: 600; font-size: 18px; letter-spacing: .04em;
  border: 1.5px solid var(--text); padding: 2px 8px;
}
.brand-logo {
  /* the logo file is used as a stencil, so it takes the same off-white as the header text */
  display: block; height: 40px; aspect-ratio: 640 / 208; background: var(--text);
  -webkit-mask: url("../assets/logo.png") center / contain no-repeat; mask: url("../assets/logo.png") center / contain no-repeat;
}
.brand-divider { width: 1px; height: 26px; background: var(--line); }
.brand-title { font-family: var(--font-display); letter-spacing: .32em; font-size: 14px; text-transform: uppercase; }
.topnav { display: flex; gap: 26px; }
.topnav a { color: var(--text); text-decoration: none; font-size: 16px; padding: 4px 0; border-bottom: 1px solid transparent; }
.topnav a:hover, .topnav a.active { color: var(--gold-bright); border-bottom-color: var(--gold); }

main { max-width: var(--maxw); margin: 0 auto; padding: 0 16px 60px; outline: none; }
.loading { text-align: center; padding: 30vh 0; color: var(--text-dim); font-style: italic; }

/* ---------- Shared type ---------- */
.eyebrow {
  font-family: var(--font-display); letter-spacing: .35em; text-transform: uppercase;
  font-size: 13px; color: var(--gold);
  display: flex; align-items: center; justify-content: center; gap: 14px;
}
.eyebrow::before, .eyebrow::after { content: ""; height: 1px; width: 40px; background: var(--line); }
.eyebrow.left { justify-content: flex-start; }
.eyebrow.left::before { display: none; }
h1, h2, h3 { font-family: var(--font-display); font-weight: 600; line-height: 1.15; margin: 0; }
.gold-text {
  background: linear-gradient(180deg, var(--gold-bright) 0%, var(--gold) 55%, var(--gold-deep) 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.star-rule { display: flex; align-items: center; justify-content: center; gap: 10px; color: var(--gold); margin: 14px 0; }
.star-rule::before, .star-rule::after { content: ""; height: 1px; width: 60px; background: var(--line); }

.btn {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--font-display); letter-spacing: .12em; text-transform: uppercase; font-size: 14px; font-weight: 600;
  padding: 12px 22px; border-radius: 6px; text-decoration: none;
  background: linear-gradient(180deg, var(--gold-bright), var(--gold));
  color: #1a1206; border: 1px solid var(--gold-bright);
  box-shadow: 0 0 24px rgba(241, 212, 140, .25);
  transition: transform .15s ease, box-shadow .15s ease;
}
.btn:hover { transform: translateY(-1px); box-shadow: 0 0 34px rgba(241, 212, 140, .4); }
.btn.ghost { background: transparent; color: var(--gold-bright); box-shadow: none; border-color: var(--line); }
.btn.small { padding: 8px 14px; font-size: 12px; }
.linklike { background: none; border: 0; color: var(--gold-bright); text-decoration: underline; padding: 0; }

/* ---------- Home hero ---------- */
.hero {
  position: relative; text-align: center;
  margin: 0 -16px; padding: 56px 16px 40px;
  background-size: cover; background-position: center;
}
.hero.has-image::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(180deg, rgba(11,18,32,.55), rgba(11,18,32,.25) 40%, rgba(11,18,32,.9));
}
.hero-title { margin: 18px 0 6px; }
.hero-title .big { display: block; font-size: clamp(64px, 14vw, 132px); line-height: .9; font-weight: 700; letter-spacing: .02em; }
.hero-title .small { display: flex; align-items: center; justify-content: center; gap: 14px; font-size: clamp(16px, 3vw, 24px); letter-spacing: .4em; color: var(--gold); margin: 6px 0; font-weight: 400; }
.hero-title .small::before, .hero-title .small::after { content: ""; height: 1px; width: 70px; background: var(--line); }
.hero-sub { font-family: var(--font-display); letter-spacing: .28em; text-transform: uppercase; font-size: clamp(12px, 2vw, 16px); color: var(--text); margin: 14px 0 0; }
.hero-cta { margin-top: 30px; display: flex; flex-direction: column; align-items: center; gap: 12px; }
.hero-note { color: var(--text-dim); font-style: italic; font-size: 17px; }

/* ---------- Artwork hero (home page) ---------- */
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.art-hero { width: 100vw; margin-left: calc(50% - 50vw); text-align: center; }
.art-crop { overflow: hidden; position: relative; }
.art-frame {
  position: relative; aspect-ratio: 1672 / 941;
  width: 100%; max-width: 1600px; margin: 0 auto;
}
.art-frame img { width: 100%; height: 100%; object-fit: cover; }
/* soften the edges into the night sky */
.art-frame::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background:
    linear-gradient(180deg, transparent 93%, var(--night) 100%),
    linear-gradient(90deg, var(--night) 0, transparent 3%, transparent 97%, var(--night) 100%);
}
@media (max-width: 1600px) { .art-frame::after { background: linear-gradient(180deg, transparent 93%, var(--night) 100%); } }

.art-lantern { position: absolute; transform: translate(-50%, -50%); z-index: 1; display: block; border-radius: 45% 45% 40% 40%; }
.art-lantern > span { position: absolute; pointer-events: none; transition: opacity 1.2s ease; }
/* Unlit: the glass is dimmed so it reads as cold and dark */
.art-lantern .dim {
  inset: -4%; border-radius: inherit;
  background: radial-gradient(closest-side, rgba(8,12,22,.7), rgba(8,12,22,.45) 70%, transparent);
  mix-blend-mode: multiply;
}
/* Lit: every layer of light is centered on the flame (about 66% down the glass)
   and fades outward, so the light reads as coming from the flame itself. */
.art-lantern { --fy: 66%; }
/* Warm cast on the metal frame and nearby trees (overlay tints without washing out) */
.art-lantern .cast {
  inset: -55% -85%;
  background: radial-gradient(closest-side at 50% 58%, rgba(255,160,60,.75), rgba(255,140,50,.35) 45%, transparent 85%);
  mix-blend-mode: overlay; opacity: 0;
}
/* Soft halo of light around the lantern */
.art-lantern .glow {
  inset: -105% -160%;
  background: radial-gradient(closest-side at 50% 54%, rgba(255,190,90,.55), rgba(255,150,50,.22) 35%, rgba(255,130,40,.07) 60%, transparent 78%);
  mix-blend-mode: screen; opacity: 0;
}
/* Light inside the glass: brightest at the flame, dimmer toward the top and edges */
.art-lantern .core {
  inset: 6% 10% 4%; border-radius: 46% 46% 40% 40%;
  background: radial-gradient(ellipse 55% 60% at 50% var(--fy), rgba(255,240,200,.9), rgba(255,200,110,.55) 30%, rgba(255,160,60,.18) 65%, transparent 100%);
  mix-blend-mode: screen; opacity: 0;
}
/* Light pooling on the snow beneath */
.art-lantern .spill {
  left: -70%; right: -70%; top: 118%; height: 55%;
  background: radial-gradient(closest-side, rgba(255,190,110,.42), rgba(255,160,70,.15) 55%, transparent);
  mix-blend-mode: screen; opacity: 0;
}
.art-lantern .flame {
  left: 50%; top: 53%; width: 15%; height: 26%; transform: translateX(-50%);
  border-radius: 50% 50% 45% 45% / 65% 65% 35% 35%;
  background: radial-gradient(ellipse at 50% 72%, #fff 0 22%, #ffe49a 45%, rgba(255,170,60,.5) 62%, rgba(255,170,60,0) 76%);
  mix-blend-mode: screen; opacity: 0; filter: blur(.4px);
}
.art-lantern.lit .dim { opacity: 0; }
/* Uneven flicker: each layer uses a different length so they never fall into a visible loop */
.art-lantern.lit .cast  { opacity: 1; animation: flick 4.3s linear infinite; animation-delay: var(--delay); }
.art-lantern.lit .glow  { opacity: 1; animation: flick 3.1s linear infinite; animation-delay: var(--delay); }
.art-lantern.lit .core  { opacity: 1; animation: flick 2.3s linear infinite; animation-delay: var(--delay); }
.art-lantern.lit .spill { opacity: 1; animation: flick 3.7s linear infinite; animation-delay: var(--delay); }
.art-lantern.lit .flame { opacity: 1; animation: artFlame 1.9s ease-in-out infinite; animation-delay: var(--delay); transform-origin: 50% 90%; }
.art-lantern.current .glow { inset: -120% -185%; }
@keyframes flick {
  0%, 100% { opacity: 1; }   9% { opacity: .9; }   14% { opacity: .97; } 23% { opacity: .84; }
  31% { opacity: .95; }      40% { opacity: .9; }  52% { opacity: 1; }   58% { opacity: .82; }
  66% { opacity: .93; }      78% { opacity: .88; } 87% { opacity: .98; } 93% { opacity: .9; }
}
@keyframes artFlame {
  0%, 100% { transform: translateX(-50%) scale(1, 1); }
  18% { transform: translateX(-52%) scale(1.04, .95) skewX(-2deg); }
  37% { transform: translateX(-49%) scale(.95, 1.07) skewX(1.5deg); }
  55% { transform: translateX(-51%) scale(1.03, .97); }
  74% { transform: translateX(-48%) scale(.97, 1.05) skewX(2deg); }
}

/* Lantern name tags: always visible, sitting on the stone ledge (--label-top is set per lantern in app.js) */
.art-lantern > .art-label {
  left: 50%; top: var(--label-top, 165%);
  transform: translate(-50%, -50%);
  pointer-events: auto; white-space: nowrap;
  font-family: var(--font-display); font-weight: 600; text-transform: uppercase;
  font-size: clamp(10px, 1.05vw, 15px); letter-spacing: .2em; line-height: 1;
  padding: .55em .8em .5em 1em; border-radius: 999px;
  color: var(--text);
  background: rgba(11, 18, 32, .78);
  border: 1px solid rgba(217, 182, 106, .45);
  box-shadow: 0 2px 10px rgba(0,0,0,.5);
  backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px);
  transition: transform .25s ease, box-shadow .25s ease, background .25s ease, color .25s ease, border-color .25s ease;
}
.art-lantern.lit > .art-label { color: var(--gold-bright); border-color: rgba(241, 212, 140, .7); }
.art-lantern:hover > .art-label, .art-lantern:focus-visible > .art-label {
  transform: translate(-50%, -50%) scale(1.22);
  color: #1a1206;
  background: linear-gradient(180deg, var(--gold-bright), var(--gold));
  border-color: var(--gold-bright);
  box-shadow: 0 0 14px rgba(255, 210, 120, .85), 0 0 36px rgba(255, 170, 60, .55);
}
.art-hero .hero-cta { margin-top: 6px; padding: 0 16px; }

@media (max-width: 760px) {
  /* crop the sides on phones so the lanterns and title stay large */
  .art-frame { width: 124%; max-width: none; margin-left: -12%; }
  .art-lantern > .art-label { font-size: 9px; letter-spacing: .06em; padding: .5em .6em .45em .65em; }
  .art-hero .hero-cta { margin-top: 14px; }
}

/* Lantern row */
.lantern-row { display: flex; justify-content: center; align-items: flex-end; gap: clamp(8px, 3vw, 34px); margin: 30px auto 0; max-width: 720px; }
.lantern { width: clamp(46px, 11vw, 96px); position: relative; text-decoration: none; color: inherit; text-align: center; }
.lantern svg { width: 100%; height: auto; overflow: visible; }
.lantern .glass { fill: rgba(255,255,255,.04); }
.lantern .flame { opacity: 0; transition: opacity .6s; }
.lantern .halo { opacity: 0; transition: opacity .6s; }
.lantern.lit .flame { opacity: 1; animation: flicker 2.8s infinite ease-in-out; transform-origin: 50% 70%; }
.lantern.lit .halo { opacity: 1; }
.lantern.lit .glass { fill: rgba(244,166,64,.22); }
.lantern.current .halo { animation: pulse 2.6s infinite ease-in-out; }
.lantern-label { font-family: var(--font-display); letter-spacing: .2em; text-transform: uppercase; font-size: clamp(9px, 1.6vw, 12px); color: var(--text-dim); margin-top: 8px; display: block; }
.lantern.lit .lantern-label { color: var(--gold-bright); }
.lantern:nth-child(odd) { transform: translateY(-6px); }
@keyframes flicker { 0%,100% { transform: scale(1); } 30% { transform: scale(1.06, .96); } 60% { transform: scale(.96, 1.05); } }
@keyframes pulse { 0%,100% { opacity: .7; } 50% { opacity: 1; } }

.ledge { height: 18px; margin: 0 auto; max-width: 760px; border-radius: 4px;
  background: linear-gradient(180deg, #e9eef5 0 4px, #57524b 4px, #3b3630); opacity: .8; box-shadow: 0 10px 30px #0008; }

/* ---------- Cards / sections ---------- */
.section { margin: 56px 0; }
.section-head { text-align: center; margin-bottom: 26px; }
.section-head h2 { font-size: clamp(26px, 4vw, 36px); margin-top: 10px; }
.cards { display: grid; gap: 18px; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.card {
  background: linear-gradient(180deg, rgba(24,35,59,.9), rgba(17,26,46,.9));
  border: 1px solid rgba(217,182,106,.22); border-radius: var(--radius);
  padding: 22px; color: var(--text); text-decoration: none; display: block;
  transition: border-color .2s, transform .2s;
}
a.card:hover { border-color: var(--gold); transform: translateY(-2px); }
.card h3 { font-size: 20px; color: var(--gold-bright); margin: 6px 0 8px; }
.card p { margin: 0; color: var(--text-dim); }
.card .meta { font-family: var(--font-display); font-size: 12px; letter-spacing: .25em; text-transform: uppercase; color: var(--gold); }

.today-card { display: grid; grid-template-columns: 1fr auto; gap: 18px; align-items: center; }
.today-card .verse { font-style: italic; color: var(--text); margin-top: 6px; }

/* Parchment panels */
.parchment {
  background:
    radial-gradient(ellipse at 20% 10%, rgba(255,255,255,.5), transparent 50%),
    radial-gradient(ellipse at 80% 90%, rgba(150,110,60,.18), transparent 60%),
    linear-gradient(180deg, var(--parchment), var(--parchment-2));
  color: var(--ink); border-radius: 6px;
  box-shadow: 0 20px 50px rgba(0,0,0,.5), inset 0 0 60px rgba(120,80,30,.18);
}

/* ---------- Reading page ---------- */
.reader-nav { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin: 26px 0 18px; }
.reader-nav .center { text-align: center; flex: 1; }
.reader-nav .date { color: var(--text-dim); font-style: italic; font-size: 16px; }
.reader-nav .btn { min-width: 0; }

.book {
  display: grid; grid-template-columns: 1fr 1fr; gap: 0;
  border-radius: 6px; overflow: hidden;
}
.page { padding: clamp(24px, 4vw, 48px); position: relative; }
.page + .page { border-left: 1px solid rgba(90,60,30,.25); box-shadow: inset 16px 0 30px -20px rgba(80,50,20,.35); }
.day-badge {
  display: inline-block; font-family: var(--font-display); letter-spacing: .3em; font-size: 13px;
  background: #2d2a26; color: #f3e8d2; padding: 4px 14px; border-radius: 3px;
}
.page h1 { font-size: clamp(28px, 4vw, 38px); color: var(--ink); letter-spacing: .06em; margin: 16px 0 4px; text-transform: uppercase; }
.page .week-label { font-family: var(--font-display); letter-spacing: .3em; font-size: 12px; color: var(--ink-soft); text-transform: uppercase; }
.page .star-rule { color: var(--ink-soft); }
.page .star-rule::before, .page .star-rule::after { background: rgba(60,40,20,.3); }
.scripture { text-align: center; color: var(--berry); font-style: italic; font-size: 21px; margin: 18px 0 6px; }
.scripture-ref { text-align: center; color: var(--berry); font-size: 17px; margin-bottom: 18px; }
.scripture-ref .ver { font-size: 14px; }
.body-text p { margin: 0 0 1em; color: var(--ink); }
.body-text p:first-child::first-letter {
  font-family: var(--font-display); float: left; font-size: 3.2em; line-height: .9; padding: 4px 8px 0 0; color: var(--gold-deep);
}
.side-heading { font-family: var(--font-display); letter-spacing: .32em; text-transform: uppercase; color: var(--ink); font-size: 15px; text-align: center; margin: 0 0 14px; }
.reflect-list { padding-left: 1.1em; margin: 0 0 26px; color: var(--ink); }
.reflect-list li { margin-bottom: 10px; }
.prayer { font-style: italic; color: var(--ink-soft); border-left: 3px solid var(--gold-deep); padding-left: 14px; margin: 0 0 26px; }
.journal-box label { display: block; font-family: var(--font-display); letter-spacing: .2em; font-size: 12px; text-transform: uppercase; color: var(--ink-soft); margin-bottom: 6px; }
.journal-box textarea {
  width: 100%; min-height: 150px; resize: vertical;
  font: inherit; font-size: 18px; color: var(--ink); line-height: 1.7;
  background: repeating-linear-gradient(180deg, transparent 0 29px, rgba(90,60,30,.18) 29px 30px), rgba(255,255,255,.35);
  border: 1px solid rgba(90,60,30,.25); border-radius: 4px; padding: 6px 10px;
}
.saved-note { font-size: 14px; color: var(--ink-soft); font-style: italic; min-height: 1.4em; }
.mark-read { display: flex; align-items: center; gap: 10px; margin-top: 16px; color: var(--ink); font-size: 17px; cursor: pointer; }
.mark-read input { width: 20px; height: 20px; accent-color: var(--gold-deep); }
.video-wrap { position: relative; padding-top: 56.25%; margin-bottom: 24px; border-radius: 4px; overflow: hidden; background: #000; }
.video-wrap iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.trees { position: absolute; left: 0; right: 0; bottom: 0; height: 60px; opacity: .25; pointer-events: none;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 60'%3E%3Cpath fill='%233b2a18' d='M10 60l10-30 10 30zM30 60l14-44 14 44zM150 60l12-36 12 36zM170 60l14-50 14 50z'/%3E%3C/svg%3E") bottom right / 260px 60px no-repeat; }
.placeholder-flag {
  margin: 0 0 18px; padding: 8px 12px; border: 1px dashed var(--gold-deep); border-radius: 4px;
  font-size: 14px; color: var(--ink-soft); background: rgba(255,255,255,.3);
}

/* Book sections on the reading page */
a.eyebrow { text-decoration: none; display: inline-block; }
a.eyebrow:hover { color: var(--gold-bright); }
.scripture-box { text-align: center; margin: 14px 0 26px; padding: 14px 16px 12px; border-top: 1px solid rgba(90,60,30,.25); border-bottom: 1px solid rgba(90,60,30,.25); }
.scripture-box .label, .wi-anchor span { font-family: var(--font-display); letter-spacing: .3em; font-size: 12px; text-transform: uppercase; color: var(--ink-soft); }
.scripture-box .scripture-ref { margin: 6px 0 4px; font-size: 20px; }
.scripture-ref a, .wi-anchor a { color: var(--berry); text-decoration: underline; text-decoration-color: rgba(122,40,40,.35); text-underline-offset: 3px; }
.scripture-ref a:hover, .wi-anchor a:hover { text-decoration-color: currentColor; }
.scripture-ref .sep { color: var(--ink-soft); }
.read-first { font-size: 14px; font-style: italic; color: var(--ink-soft); margin: 0; }
.note-heading { font-family: var(--font-display); letter-spacing: .22em; text-transform: uppercase; color: var(--gold-deep); font-size: 13px; font-weight: 600; margin: 0 0 8px; }
.note-text { color: var(--ink); margin: 0 0 24px; font-size: 17.5px; line-height: 1.65; }
.respond { color: var(--ink); font-weight: 500; font-size: 19px; line-height: 1.5; margin: 0 0 26px; text-align: center; padding: 0 6px; }
.page .body-text { margin-bottom: 18px; }

/* Week introduction */
.week-intro { padding: clamp(22px, 4vw, 40px) clamp(20px, 5vw, 52px); margin: 0 0 24px; }
.wi-head { text-align: center; margin-bottom: 20px; }
.week-intro .eyebrow { color: var(--ink-soft); }
.wi-name { font-family: var(--font-display); letter-spacing: .28em; text-transform: uppercase; color: var(--gold-deep); font-size: 13px; margin-top: 10px; }
.week-intro h2 { color: var(--ink); font-size: clamp(26px, 4vw, 36px); letter-spacing: .04em; margin: 4px 0 10px; }
.wi-anchor { margin: 0; color: var(--ink); }
.wi-anchor span { margin-right: 8px; }
.wi-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.wi-box { background: rgba(255,255,255,.32); border: 1px solid rgba(90,60,30,.18); border-radius: 6px; padding: 16px 18px 4px; }
.wi-question { font-size: 21px; font-style: italic; color: var(--berry); margin: 0 0 14px; line-height: 1.4; }
.wi-more { text-align: center; margin: 18px 0 0; }
.wi-more a, .welcome a { color: var(--berry); }

/* Welcome + closing */
.welcome, .beyond { padding: clamp(26px, 5vw, 52px) clamp(20px, 6vw, 64px); max-width: 860px; margin: 0 auto; }
.welcome { text-align: center; }
.welcome .eyebrow { color: var(--ink-soft); }
.welcome h2, .beyond h1 { color: var(--ink); font-size: clamp(26px, 4vw, 36px); letter-spacing: .05em; margin: 6px 0 2px; text-align: center; }
.welcome .star-rule, .beyond .star-rule { color: var(--ink-soft); }
.welcome .star-rule::before, .welcome .star-rule::after, .beyond .star-rule::before, .beyond .star-rule::after { background: rgba(60,40,20,.3); }
.welcome > p { color: var(--ink); font-size: 19px; }
.howto { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 24px; text-align: left; }
.howto p { margin: 0; color: var(--ink-soft); font-size: 16.5px; }
.beyond .body-text p:first-child::first-letter { font-family: var(--font-display); float: left; font-size: 3.2em; line-height: .9; padding: 4px 8px 0 0; color: var(--gold-deep); }
.beyond .wi-grid { margin: 8px 0 26px; }
.beyond .respond { text-align: left; font-size: 18px; padding: 0; margin-bottom: 14px; }
.closing-verse { margin: 30px auto 0; text-align: center; font-style: italic; font-size: 22px; color: var(--berry); max-width: 560px; }
.closing-verse cite { display: block; font-style: normal; font-size: 14px; letter-spacing: .2em; text-transform: uppercase; color: var(--ink-soft); margin-top: 8px; font-family: var(--font-display); }
@media (max-width: 760px) {
  .wi-grid, .howto { grid-template-columns: 1fr; }
}

.locked {
  text-align: center; padding: 60px 20px; max-width: 560px; margin: 40px auto;
}
.locked svg { width: 90px; height: auto; display: block; margin: 0 auto; overflow: visible; }
.locked .flame, .locked .halo { opacity: 0; }
.locked .glass { fill: rgba(255,255,255,.04); }
.locked h1 { font-size: 30px; margin: 18px 0 10px; }
.locked p { color: var(--text-dim); }

/* ---------- All days calendar ---------- */
.week-block { margin: 30px 0; }
.week-block h2 { font-size: 22px; display: flex; align-items: baseline; gap: 14px; flex-wrap: wrap; margin-bottom: 4px; }
.week-block h2 small { font-family: var(--font-body); font-style: italic; font-weight: 400; color: var(--text-dim); font-size: 17px; letter-spacing: 0; }
.week-block .theme { color: var(--text-dim); margin: 0 0 14px; }
.day-grid { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
.day-tile {
  position: relative; display: block; text-decoration: none; color: var(--text);
  padding: 14px; border-radius: 8px; min-height: 108px;
  background: rgba(24,35,59,.85); border: 1px solid rgba(217,182,106,.2);
  transition: border-color .2s, transform .2s;
}
.day-tile:hover { border-color: var(--gold); transform: translateY(-2px); }
.day-tile .num { font-family: var(--font-display); color: var(--gold); font-size: 13px; letter-spacing: .2em; }
.day-tile .t { display: block; font-size: 17px; line-height: 1.3; margin: 6px 0 4px; }
.day-tile .d { font-size: 14px; color: var(--text-dim); font-style: italic; }
.day-tile.today { border-color: var(--gold-bright); box-shadow: 0 0 0 1px var(--gold-bright), 0 0 26px rgba(241,212,140,.25); }
.day-tile.today::after { content: "Today"; position: absolute; top: 12px; right: 12px; font-family: var(--font-display); font-size: 10px; letter-spacing: .2em; text-transform: uppercase; background: var(--gold); color: #1a1206; padding: 2px 7px; border-radius: 3px; }
.day-tile.read .num::after { content: " ✓"; color: var(--gold-bright); }
.day-tile.is-locked { opacity: .45; pointer-events: none; }
.day-tile.is-locked .t::before { content: "🔒 "; font-size: 13px; }

.progress { display: flex; align-items: center; gap: 14px; justify-content: center; color: var(--text-dim); margin-top: 10px; }
.progress-bar { width: 220px; height: 6px; border-radius: 3px; background: rgba(255,255,255,.1); overflow: hidden; }
.progress-bar span { display: block; height: 100%; background: linear-gradient(90deg, var(--gold-deep), var(--gold-bright)); }

/* ---------- Journal ---------- */
.journal-list { display: grid; gap: 16px; max-width: 780px; margin: 0 auto; }
.journal-entry { padding: 22px 26px; }
.journal-entry .meta { font-family: var(--font-display); font-size: 12px; letter-spacing: .25em; text-transform: uppercase; color: var(--ink-soft); }
.journal-entry h3 { color: var(--ink); font-size: 20px; margin: 4px 0 10px; }
.journal-entry p { white-space: pre-wrap; margin: 0; color: var(--ink); }
.journal-entry a { color: var(--gold-deep); font-size: 15px; }
.empty { text-align: center; color: var(--text-dim); font-style: italic; padding: 40px 0; }
.toolbar { display: flex; justify-content: center; gap: 12px; flex-wrap: wrap; margin: 20px 0 30px; }

/* ---------- Footer ---------- */
.footer { text-align: center; color: var(--text-dim); font-size: 15px; padding: 30px 16px 40px; border-top: 1px solid rgba(217,182,106,.12); }
.footer p { margin: 0 0 8px; }

/* ---------- Phone menu (hamburger) ---------- */
.menu-btn {
  display: none; position: relative; width: 44px; height: 44px; margin-right: -8px;
  background: none; border: 0; padding: 0; color: var(--text);
}
.menu-btn span {
  position: absolute; left: 10px; right: 10px; height: 2px; border-radius: 2px; background: currentColor;
  transition: transform .25s ease, opacity .2s ease, top .25s ease;
}
.menu-btn span:nth-child(1) { top: 14px; }
.menu-btn span:nth-child(2) { top: 21px; }
.menu-btn span:nth-child(3) { top: 28px; }
.menu-btn[aria-expanded="true"] span:nth-child(1) { top: 21px; transform: rotate(45deg); }
.menu-btn[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.menu-btn[aria-expanded="true"] span:nth-child(3) { top: 21px; transform: rotate(-45deg); }

.mobile-menu {
  position: fixed; left: 0; right: 0; bottom: 0; top: var(--topbar-h, 61px); z-index: 19;
  display: flex; flex-direction: column; gap: 12px;
  padding: 24px 20px calc(24px + env(safe-area-inset-bottom));
  background: rgba(11, 18, 32, .97);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  overflow-y: auto;
  animation: menuIn .45s cubic-bezier(.2,.7,.2,1);
}
.mobile-menu[hidden] { display: none; }
@keyframes menuIn { from { opacity: 0; transform: translateY(-14px); } to { opacity: 1; transform: none; } }
.mobile-menu a { animation: menuItemIn .45s cubic-bezier(.2,.7,.2,1) both; }
.mobile-menu a:nth-child(2) { animation-delay: .04s; } .mobile-menu a:nth-child(3) { animation-delay: .08s; }
.mobile-menu a:nth-child(4) { animation-delay: .12s; } .mobile-menu a:nth-child(5) { animation-delay: .16s; }
@keyframes menuItemIn { from { opacity: 0; transform: translateY(-10px); } to { opacity: 1; transform: none; } }
.mobile-menu a {
  display: flex; align-items: center; gap: 16px;
  padding: 16px 18px; border-radius: 10px; text-decoration: none;
  font-family: var(--font-display); font-size: 18px; letter-spacing: .06em; color: var(--text);
  border: 1px solid rgba(217,182,106,.25); background: rgba(24,35,59,.6);
}
.mobile-menu a.active { color: var(--gold-bright); border-color: var(--gold); }
.mobile-menu svg, .m-action svg { width: 26px; height: 26px; flex: none; fill: none; stroke: var(--gold); stroke-width: 1.6; stroke-linejoin: round; stroke-linecap: round; }
body.menu-open { overflow: hidden; }

/* ---------- Phone home screen buttons (hidden on larger screens) ---------- */
.m-actions { display: none; }

@media (max-width: 760px) {
  body { font-size: 18px; }
  .topnav { display: none; }
  .menu-btn { display: block; }
  .brand-logo { height: 32px; }

  /* One-screen home: artwork on top, three big buttons filling the rest */
  body.route-home .footer,
  body.route-home .home-extra,
  body.route-home .art-hero .hero-cta { display: none; }
  body.route-home main { padding-bottom: 0; }
  body.route-home .art-hero {
    min-height: calc(100dvh - var(--topbar-h, 61px));
    display: flex; flex-direction: column;
  }
  .m-actions {
    display: flex; flex-direction: column; justify-content: center; gap: 10px;
    flex: 1; padding: 10px 20px calc(18px + env(safe-area-inset-bottom));
  }
  .m-action {
    display: grid; grid-template-columns: 30px 1fr 30px; align-items: center;
    min-height: clamp(52px, 7.6dvh, 68px); padding: 8px 16px; border-radius: 10px; text-decoration: none;
    color: var(--text); font-family: var(--font-display); font-size: 18px; letter-spacing: .06em;
    background: linear-gradient(180deg, rgba(24,35,59,.75), rgba(11,18,32,.75));
    border: 1px solid rgba(217,182,106,.55);
    box-shadow: inset 0 0 0 1px rgba(0,0,0,.4), 0 4px 16px rgba(0,0,0,.35);
    transition: border-color .2s, box-shadow .2s, transform .1s;
  }
  .m-action:active { transform: scale(.98); border-color: var(--gold-bright); box-shadow: 0 0 18px rgba(241,212,140,.35); }
  .m-action .m-label { text-align: center; line-height: 1.2; }
  .m-action small { display: block; font-family: var(--font-body); font-style: italic; letter-spacing: 0; font-size: 14px; color: var(--text-dim); }
  .book { grid-template-columns: 1fr; }
  .page + .page { border-left: 0; border-top: 1px solid rgba(90,60,30,.25); box-shadow: inset 0 16px 30px -24px rgba(80,50,20,.35); }
  .reader-nav .btn span.lbl { display: none; }
  .today-card { grid-template-columns: 1fr; }
  .day-grid { grid-template-columns: repeat(2, 1fr); }
  .hero { padding-top: 36px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

@media print {
  .topbar, .mobile-menu, .footer, .reader-nav, .journal-box, .sky { display: none !important; }
  body { background: #fff; }
  .book { grid-template-columns: 1fr; }
}

/* Phone home: small "where we are" line above the buttons */
.m-eyebrow { font-size: 12px; margin-bottom: 4px; }

/* Resource card with several downloads (Gather Group Guides) */
.card-files { grid-column: 1 / -1; }
.file-list { list-style: none; margin: 16px 0 0; padding: 0; display: grid; gap: 8px; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
.file-list a {
  display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 8px;
  color: var(--text); text-decoration: none; background: rgba(255,255,255,.04);
  border: 1px solid rgba(217,182,106,.22); transition: border-color .2s, background .2s;
}
.file-list a:hover, .file-list a:focus-visible { border-color: var(--gold); background: rgba(217,182,106,.08); }
.file-list svg { width: 20px; height: 20px; flex: none; fill: none; stroke: var(--gold); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.file-list span { flex: 1; line-height: 1.3; }
.file-list small { font-family: var(--font-display); font-size: 11px; letter-spacing: .18em; color: var(--text-dim); }
