/* 24-7Angels — mobile-first, light-filled palette */
:root {
  --cream: #FFF9F2;
  --cream-deep: #F7EDE0;
  --gold: #E8C97A;
  --gold-deep: #D4A84B;
  --rose: #F0C4C8;
  --sky: #B8D4E8;
  --sage: #C5D9B8;
  --ink: #3D342C;
  --ink-soft: #6B5E52;
  --white: #FFFFFF;
  --shadow: 0 8px 24px rgba(61, 52, 44, 0.08);
  --radius: 16px;
  --font: "Segoe UI", system-ui, -apple-system, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  height: 100%;
  font-family: var(--font);
  color: var(--ink);
  background: var(--cream);
}

body {
  display: flex;
  flex-direction: column;
  min-height: 100dvh;
}

/* ----- Header ----- */
.app-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  background: linear-gradient(135deg, #FFF9F2 0%, #FFEFD8 50%, #F5E6F0 100%);
  border-bottom: 1px solid rgba(212, 168, 75, 0.25);
  position: sticky;
  top: 0;
  z-index: 1000;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  text-decoration: none;
  color: inherit;
}

.brand-mark {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 30%, #FFF6E8, var(--gold));
  display: grid;
  place-items: center;
  font-size: 1.1rem;
  box-shadow: var(--shadow);
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}

.brand-text strong {
  font-size: 1.05rem;
  letter-spacing: 0.02em;
}

.brand-text span {
  font-size: 0.72rem;
  color: var(--ink-soft);
}

.header-actions {
  display: flex;
  gap: 0.4rem;
}

.btn {
  appearance: none;
  border: none;
  border-radius: 999px;
  padding: 0.55rem 1rem;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.btn:active { transform: scale(0.97); }

.btn-primary {
  background: linear-gradient(135deg, var(--gold), var(--gold-deep));
  color: #3D2E10;
  box-shadow: var(--shadow);
}

.btn-ghost {
  background: rgba(255, 255, 255, 0.7);
  color: var(--ink);
  border: 1px solid rgba(61, 52, 44, 0.12);
}

/* ----- Layout ----- */
.app-main {
  flex: 1;
  display: flex;
  flex-direction: column;
  position: relative;
  min-height: 0;
}

.map-wrap {
  flex: 1;
  position: relative;
  min-height: 55vh;
}

#map {
  width: 100%;
  height: 100%;
  min-height: 55vh;
  background: var(--sky);
}

/* Floating controls over map */
.map-controls {
  position: absolute;
  left: 0.75rem;
  right: 0.75rem;
  top: 0.75rem;
  z-index: 500;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  pointer-events: none;
}

.map-controls > * { pointer-events: auto; }

.chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  background: rgba(255, 249, 242, 0.92);
  backdrop-filter: blur(8px);
  padding: 0.4rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.chip {
  appearance: none;
  border: 1px solid transparent;
  background: transparent;
  border-radius: 999px;
  padding: 0.4rem 0.75rem;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--ink-soft);
  cursor: pointer;
}

.chip[aria-pressed="true"] {
  background: var(--white);
  color: var(--ink);
  border-color: var(--gold);
  box-shadow: 0 2px 8px rgba(212, 168, 75, 0.25);
}

/* ----- Bottom sheet / panels ----- */
.panel {
  background: var(--white);
  border-radius: var(--radius) var(--radius) 0 0;
  box-shadow: 0 -4px 24px rgba(61, 52, 44, 0.08);
  padding: 1rem 1rem 1.25rem;
  max-height: 42vh;
  overflow: auto;
}

.panel h2 {
  margin: 0 0 0.35rem;
  font-size: 1.1rem;
}

.panel .lede {
  margin: 0 0 1rem;
  color: var(--ink-soft);
  font-size: 0.9rem;
}

.post-card {
  background: var(--cream);
  border-radius: 12px;
  padding: 0.85rem 1rem;
  margin-bottom: 0.65rem;
  border: 1px solid rgba(212, 168, 75, 0.15);
}

.post-card header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.4rem;
}

.post-card .marker-thumb {
  width: 28px;
  height: 28px;
}

.post-card .meta {
  font-size: 0.75rem;
  color: var(--ink-soft);
}

.post-card p {
  margin: 0 0 0.6rem;
  font-size: 0.95rem;
  line-height: 1.45;
}

.emoji-row {
  display: flex;
  gap: 0.4rem;
}

.emoji-btn {
  appearance: none;
  border: 1px solid rgba(61, 52, 44, 0.1);
  background: var(--white);
  border-radius: 999px;
  padding: 0.3rem 0.65rem;
  font-size: 0.85rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
}

.emoji-btn[aria-pressed="true"] {
  border-color: var(--gold-deep);
  background: #FFF6E0;
}

/* ----- Compose / journal (hidden panels toggled in JS) ----- */
.screen {
  display: none;
  flex: 1;
  flex-direction: column;
  padding: 1rem;
  overflow: auto;
  background: var(--cream);
}

.screen.is-active { display: flex; }

.form-group {
  margin-bottom: 1rem;
}

.form-group label {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  margin-bottom: 0.35rem;
  color: var(--ink-soft);
}

.form-group textarea,
.form-group select,
.form-group input {
  width: 100%;
  padding: 0.75rem 0.9rem;
  border-radius: 12px;
  border: 1px solid rgba(61, 52, 44, 0.15);
  font: inherit;
  background: var(--white);
}

.form-group textarea { min-height: 100px; resize: vertical; }

.marker-picker {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.5rem;
}

.marker-option {
  appearance: none;
  border: 2px solid transparent;
  background: var(--white);
  border-radius: 12px;
  padding: 0.5rem;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
  font-size: 0.7rem;
  color: var(--ink-soft);
}

.marker-option img { width: 48px; height: 48px; }

.marker-option[aria-pressed="true"] {
  border-color: var(--gold-deep);
  background: #FFF8EC;
}

.privacy-note {
  font-size: 0.8rem;
  background: #EAF3FA;
  border-radius: 12px;
  padding: 0.75rem 0.9rem;
  color: var(--ink-soft);
  margin-bottom: 1rem;
}

/* ----- Nav tabs (mobile) ----- */
.app-nav {
  display: flex;
  justify-content: space-around;
  padding: 0.45rem 0.5rem calc(0.45rem + env(safe-area-inset-bottom));
  background: var(--white);
  border-top: 1px solid rgba(61, 52, 44, 0.08);
  position: sticky;
  bottom: 0;
  z-index: 1000;
}

.nav-btn {
  appearance: none;
  border: none;
  background: transparent;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.15rem;
  font-size: 0.68rem;
  color: var(--ink-soft);
  padding: 0.35rem 0.75rem;
  border-radius: 10px;
  cursor: pointer;
}

.nav-btn[aria-current="page"] {
  color: var(--ink);
  background: var(--cream-deep);
  font-weight: 700;
}

.nav-btn .ico { font-size: 1.2rem; }

/* ----- Leaflet popup tweak ----- */
.leaflet-popup-content-wrapper {
  border-radius: 14px;
  box-shadow: var(--shadow);
}

.leaflet-popup-content {
  margin: 0.75rem 0.9rem;
  font-size: 0.9rem;
}

/* ----- Desktop ----- */
@media (min-width: 840px) {
  .app-main {
    flex-direction: row;
    height: calc(100dvh - 64px - 0px);
  }

  .map-wrap {
    flex: 1.4;
    min-height: auto;
  }

  #map { min-height: 100%; height: 100%; }

  .panel {
    flex: 0 0 360px;
    max-height: none;
    border-radius: 0;
    overflow: auto;
  }

  .app-nav {
    position: fixed;
    top: 0.85rem;
    right: 1rem;
    bottom: auto;
    border: none;
    background: transparent;
    padding: 0;
    gap: 0.35rem;
    z-index: 1100;
  }

  .nav-btn {
    flex-direction: row;
    background: rgba(255, 249, 242, 0.95);
    box-shadow: var(--shadow);
    font-size: 0.8rem;
    padding: 0.45rem 0.85rem;
  }

  .header-actions { display: none; } /* desktop uses top nav */
}

/* ----- Feathers / filters (v2) ----- */
.select-wrap { align-items: center; padding: 0.3rem 0.6rem; font-size: 0.85rem; }
.select-wrap select { border: none; background: transparent; font: inherit; font-size: 0.8rem; max-width: 60vw; color: var(--ink); }
.marker-option[aria-pressed="true"] { border-color: var(--mood, var(--gold-deep)); background: color-mix(in srgb, var(--mood, #FFF8EC) 25%, white); }
.marker-option img { width: 36px; height: 48px; }
.post-card .marker-thumb { width: 22px; height: 30px; }
.feather-popup p { margin: 0.45rem 0; line-height: 1.4; }
.feather-popup .meta { font-size: 0.75rem; color: var(--ink-soft); margin-bottom: 0.3rem; }
.mood-pill { display: inline-block; padding: 0.15rem 0.6rem; border-radius: 999px; font-size: 0.72rem; font-weight: 700; color: var(--ink); }
.leaflet-marker-icon { filter: drop-shadow(0 2px 3px rgba(61,52,44,.2)); }

/* ----- v3: seamless tiles + circular map ----- */
.leaflet-container img.leaflet-tile { max-width: none !important; max-height: none !important; border: 0 !important; padding: 0; margin: 0; }
.leaflet-container, .leaflet-container * { box-sizing: content-box; }
.leaflet-popup-content-wrapper *, .leaflet-popup-content * { box-sizing: border-box; }

.map-wrap {
  display: flex; flex-direction: column; align-items: center; gap: 0.75rem;
  padding: 0.75rem 0.75rem 1rem;
  background: radial-gradient(circle at 50% 45%, #FFFDF6 0%, #FFF3DC 45%, #F8E8F0 100%);
  min-height: auto;
}
.map-controls { position: static; display: flex; flex-wrap: wrap; justify-content: center; gap: 0.5rem; width: 100%; }
.map-circle-glow {
  width: min(92vw, 68vh, 640px);
  aspect-ratio: 1 / 1;
  border-radius: 50%;
  padding: 6px;
  background: conic-gradient(from 0deg, #F6D365, #FFC9A3, #F7C6D3, #D9C8F0, #BFE0F5, #CDE8C0, #F6D365);
  box-shadow: 0 0 0 8px rgba(255, 249, 235, 0.9), 0 0 45px 12px rgba(246, 211, 101, 0.45), 0 0 90px 30px rgba(255, 220, 240, 0.35);
}
#map {
  width: 100%; height: 100% !important; min-height: 0 !important;
  border-radius: 50%; overflow: hidden;
  -webkit-mask-image: -webkit-radial-gradient(white, black); /* Safari clip fix */
  background: #EAF3FA;
}
/* keep zoom buttons inside the circle */
#map .leaflet-bottom.leaflet-right { bottom: 14%; right: 14%; }
#map .leaflet-control-attribution { font-size: 9px; background: rgba(255,255,255,.75); border-radius: 6px; margin: 0 auto 6px; }
.emoji-btn[aria-pressed="true"] { border-color: var(--gold-deep); background: #FFF3D6; box-shadow: 0 0 0 2px rgba(232,201,122,.35); }

/* My gifts */
.gifts-summary { background: linear-gradient(135deg, #FFF8E6, #FCEAF1); border-radius: var(--radius); padding: 1rem; margin-bottom: 1rem; box-shadow: var(--shadow); }
.gifts-summary h2 { margin: 0 0 0.3rem; }
.gift-row { display: flex; flex-wrap: wrap; gap: 0.4rem; align-items: center; }
.gift-chip { background: #fff; border-radius: 999px; padding: 0.25rem 0.7rem; font-size: 0.9rem; border: 1px solid rgba(232,201,122,.5); }
.gift-label { font-size: 0.78rem; color: var(--ink-soft); margin-right: 0.2rem; }

@media (min-width: 840px) {
  .map-circle-glow { width: min(62vw, 78vh, 720px); }
  .map-wrap { justify-content: center; }
}
@media print { .gifts-summary { box-shadow: none; border: 1pt solid #E8C97A; } .gift-chip { border: 0.5pt solid #ccc; } }
/* v3 layout fix: let the circle size itself, never overlap controls/panel */
.map-wrap { flex: 0 0 auto; }
.map-circle-glow { flex: 0 0 auto; margin: 10px auto 18px; }
@media (min-width: 840px) { .map-wrap { flex: 1 1 auto; } }

/* ----- v4: map as a soft background behind Share / Journal / Sign in ----- */
body:not([data-screen="map"]) #map-home {
  position: fixed; inset: 0; z-index: 0;
  pointer-events: none;               /* nothing behind can catch taps */
  filter: blur(4px) saturate(0.9);
  opacity: 0.55;
  justify-content: center;
}
body:not([data-screen="map"]) #map-home .panel,
body:not([data-screen="map"]) #map-home .map-controls,
body:not([data-screen="map"]) .leaflet-control-container,
body:not([data-screen="map"]) .leaflet-marker-pane,
body:not([data-screen="map"]) .leaflet-shadow-pane,
body:not([data-screen="map"]) .leaflet-popup-pane { display: none !important; }
body:not([data-screen="map"])::before {     /* light-filled veil */
  content: ""; position: fixed; inset: 0; z-index: 1; pointer-events: none;
  background: radial-gradient(circle at 50% 40%, rgba(255,253,246,.55), rgba(255,246,236,.8));
}
body:not([data-screen="map"]) #map-home .map-wrap { background: transparent; }
.screen { position: relative; z-index: 1500; }
.screen.is-active {
  width: min(100%, 760px); margin: 0.75rem auto calc(5rem + env(safe-area-inset-bottom));
  background: rgba(255, 251, 245, 0.97);
  border-radius: var(--radius);
  box-shadow: 0 10px 40px rgba(212,168,75,.18), 0 0 0 1px rgba(232,201,122,.25);
  padding: 1.25rem 1.1rem;
  overflow: visible;
}
body:not([data-screen="map"]) { overflow-y: auto; }
.app-header, .app-nav { z-index: 2000; }
@media (min-width: 840px) { .screen.is-active { margin-top: 1.5rem; padding: 1.75rem 2rem; } }
@media print { body::before { display: none !important; } #map-home { display: none !important; } .screen.is-active { box-shadow: none; margin: 0; } }
body:not([data-screen="map"]) #map-home { opacity: 0.8; filter: blur(2.5px) saturate(0.95); }
body:not([data-screen="map"])::before { background: radial-gradient(circle at 50% 40%, rgba(255,253,246,.25), rgba(255,246,236,.6)); }
.screen.is-active { flex: 0 0 auto; }
@media (max-width: 839px) { body:not([data-screen="map"]) .app-nav { position: fixed; left: 0; right: 0; bottom: 0; } }

/* ----- v5: moments of Grace ----- */
.screen > h1:first-child, .screen > h2:first-child { margin-top: 0; margin-bottom: 0.4rem; line-height: 1.2; }
.screen > .lede { margin-top: 0; }
.screen.is-active { display: block; }
.welcome { text-align: center; max-width: 560px; padding: 0.25rem 0.5rem 0; }
.welcome h1 { font-size: 1.25rem; margin: 0.2rem 0 0.3rem; }
.welcome p { margin: 0; font-size: 0.88rem; color: var(--ink-soft); line-height: 1.45; }
.grace-counter { margin: 0; font-size: 0.9rem; color: var(--ink-soft); display: flex; align-items: center; gap: 0.5rem; }
.grace-counter b { color: var(--gold-deep); font-size: 1.05rem; }
.pulse { width: 10px; height: 10px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 0 0 rgba(232,201,122,.7); animation: pulse 2.2s infinite; }
@keyframes pulse { 70% { box-shadow: 0 0 0 10px rgba(232,201,122,0); } 100% { box-shadow: 0 0 0 0 rgba(232,201,122,0); } }
.empty-state { text-align: center; color: var(--ink-soft); padding: 1.5rem 0.5rem; font-style: italic; }
.story-box { min-height: 16rem !important; font-size: 1.02rem; line-height: 1.6; }
@media (min-width: 840px) { .story-box { min-height: 22rem !important; } }
.char-count, .hint { font-size: 0.75rem; color: var(--ink-soft); margin: 0.3rem 0 0; }
.char-count { text-align: right; }
.photo-preview img { display: block; max-width: 100%; max-height: 260px; border-radius: 12px; margin: 0.6rem 0 0.4rem; box-shadow: var(--shadow); }
.vis-group { border: 0; padding: 0; margin: 0 0 1rem; }
.vis-group legend { font-size: 0.8rem; font-weight: 600; color: var(--ink-soft); margin-bottom: 0.4rem; }
.vis-option { display: flex; gap: 0.7rem; align-items: flex-start; background: var(--white); border: 2px solid rgba(61,52,44,.1); border-radius: 14px; padding: 0.75rem 0.9rem; margin-bottom: 0.5rem; cursor: pointer; }
.vis-option input { margin-top: 0.25rem; accent-color: var(--gold-deep); width: 1.1rem; height: 1.1rem; }
.vis-option span { display: flex; flex-direction: column; gap: 0.15rem; }
.vis-option small { color: var(--ink-soft); font-size: 0.78rem; }
.vis-option:has(input:checked) { border-color: var(--gold-deep); background: #FFF8EA; }
.btn-big { width: 100%; padding: 0.85rem 1rem; font-size: 1rem; }

/* Responses: Touched my heart first and larger */
.response-row { display: flex; flex-wrap: wrap; gap: 0.4rem; align-items: center; }
.resp-btn { appearance: none; display: inline-flex; align-items: center; gap: 0.3rem; border: 1px solid rgba(61,52,44,.12); background: #fff; border-radius: 999px; padding: 0.3rem 0.65rem; font-size: 0.85rem; cursor: pointer; color: var(--ink); }
.resp-primary { padding: 0.35rem 0.9rem 0.35rem 0.45rem; font-weight: 700; background: linear-gradient(135deg, #FFF1F4, #FFF7E6); border-color: #F3B5C4; }
.resp-icon { width: 30px; height: 30px; }
.resp-label { font-size: 0.82rem; }
.resp-count { font-variant-numeric: tabular-nums; color: var(--ink-soft); }
.resp-btn[aria-pressed="true"] { border-color: var(--gold-deep); background: #FFF3D6; box-shadow: 0 0 0 2px rgba(232,201,122,.35); }
.resp-primary[aria-pressed="true"] { border-color: #E86F8E; background: #FFE4EB; box-shadow: 0 0 0 3px rgba(232,111,142,.25); }
.feather-popup h3 { margin: 0.4rem 0 0; font-size: 1rem; }
.popup-photo { width: 100%; max-height: 140px; object-fit: cover; border-radius: 10px; margin-top: 0.4rem; }

/* Book of Blessings */
.gifts-hero { display: flex; gap: 0.8rem; align-items: center; }
.gifts-heart { width: 64px; height: 64px; flex: none; }
.gifts-hero h2 { margin: 0 0 0.2rem; font-size: 1.3rem; color: #B9506E; }
.gifts-hero p { margin: 0 0 0.6rem; font-size: 0.9rem; line-height: 1.45; }
.gift-chip { display: inline-flex; align-items: center; gap: 0.3rem; }
.gift-chip .resp-icon { width: 22px; height: 22px; }
.gift-primary { background: #FFF0F4; border-color: #F3B5C4; font-weight: 700; }
.journal-entry { background: #fff; border: 1px solid rgba(232,201,122,.35); border-radius: 14px; padding: 1rem; margin-bottom: 0.9rem; }
.journal-entry h3 { margin: 0.5rem 0 0.15rem; font-size: 1.1rem; }
.journal-entry time { font-size: 0.78rem; color: var(--ink-soft); }
.entry-top { display: flex; flex-wrap: wrap; gap: 0.4rem; align-items: center; }
.entry-body { white-space: pre-wrap; line-height: 1.6; margin: 0.6rem 0; }
.journal-photo { display: block; max-width: 100%; max-height: 320px; border-radius: 12px; margin-top: 0.6rem; }
.vis-badge { font-size: 0.72rem; font-weight: 700; border-radius: 999px; padding: 0.15rem 0.6rem; background: #EEF5FB; }
.vis-private { background: #F1ECF8; } .vis-loved_ones { background: #FDEFF3; }
.about p { line-height: 1.65; font-size: 1rem; }
.about-note { background: #FFF6E6; border-radius: 12px; padding: 0.8rem 1rem; }
.toast { position: fixed; left: 50%; bottom: 5.5rem; transform: translateX(-50%) translateY(20px); opacity: 0; transition: .3s; z-index: 3000; background: #3D342C; color: #fff; padding: 0.7rem 1rem; border-radius: 14px; font-size: 0.88rem; max-width: 90vw; pointer-events: none; }
.toast.show { opacity: 0.95; transform: translateX(-50%); }
.nav-btn { padding: 0.35rem 0.4rem; }
.header-actions .btn { white-space: nowrap; padding: 0.5rem 0.8rem; font-size: 0.8rem; }

/* v7: make feathers pop on the map */
.leaflet-marker-icon { filter: drop-shadow(0 0 2px #fff) drop-shadow(0 0 3px rgba(255,255,255,.95)) drop-shadow(0 2px 3px rgba(40,30,20,.45)); }


/* v8: real Touched my heart art */
.resp-icon { width: 34px; height: 34px; object-fit: contain; }
.gift-chip .resp-icon { width: 26px; height: 26px; }
.gifts-heart { width: 76px; height: 76px; object-fit: contain; }
.hands-pref { margin-top: 1.5rem; }
.hands-pref h3 { margin: 0 0 .25rem; }
.hands-picker { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: .6rem; }
.hand-opt { display: flex; flex-direction: column; align-items: center; gap: .2rem; width: 4.6rem; padding: .45rem .3rem; background: #fff; border: 2px solid rgba(61,52,44,.1); border-radius: 14px; font-size: .75rem; text-align: center; cursor: pointer; }
.hand-opt input { position: absolute; opacity: 0; }
.hand-opt img { width: 44px; height: 44px; }
.hand-opt small { display: block; color: var(--ink-soft); font-size: .65rem; }
.hand-opt.soon { opacity: .5; cursor: default; }
.hand-opt:has(input:checked) { border-color: var(--gold-deep); background: #FFF8EA; }
.feather-popup { max-height: 300px; overflow-y: auto; }
.leaflet-marker-icon { filter: drop-shadow(0 0 1.5px #fff) drop-shadow(0 0 4px rgba(255,255,255,1)) drop-shadow(0 0 7px rgba(255,248,225,.9)) drop-shadow(0 2px 3px rgba(40,30,20,.4)); }
.marker-option img { width: 26px; height: 58px; object-fit: contain; filter: drop-shadow(0 0 3px rgba(255,248,225,.9)); }
.marker-thumb { width: 18px; height: 40px; object-fit: contain; }

/* ===== v11 brand: Dancing Script (vendored, OFL), gold feather mark, heavenly light background ===== */
@font-face { font-family: "Dancing Script"; src: url("../vendor/fonts/DancingScript-600.woff2") format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Dancing Script"; src: url("../vendor/fonts/DancingScript-700.woff2") format("woff2"); font-weight: 700; font-display: swap; }
:root {
  --brown: #5C3C2B;        /* sampled from the logo script */
  --brown-soft: #7A5540;
  --gold: #E6C36A;
  --gold-deep: #C9973A;
  --ink: #4A3226;
  --ink-soft: #6E5546;
  --script: "Dancing Script", "Segoe Script", cursive;
}
html { background: #FBF3E4; }
body { background: transparent; }
/* The light-rays image sits on a fixed layer sized to the screen, so it stays put while the page scrolls
   (works on phones too, unlike background-attachment: fixed). */
html::before { content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background: linear-gradient(rgba(255,251,243,.05), rgba(255,251,243,.25)), var(--brand-bg, url("../assets/brand/background.jpg")) center top / cover no-repeat; }
#map-home .map-wrap { background: radial-gradient(circle at 50% 45%, rgba(255,253,246,.55) 0%, rgba(255,243,220,.25) 50%, transparent 75%); }
.brand-name { white-space: nowrap; }
.app-header { background: rgba(255,250,240,.82); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); border-bottom: 1px solid rgba(201,151,58,.25); }
.brand-mark { width: 60px; height: auto; border-radius: 0; background: none; box-shadow: none; filter: drop-shadow(0 1px 2px rgba(92,60,43,.25)); }
.brand-text strong.brand-name { font-family: var(--script); font-weight: 700; font-size: 1.75rem; color: var(--brown); letter-spacing: 0; line-height: 1; }
.brand-text span { color: var(--brown-soft); }
h1, h2, h3, .panel h2, .welcome h1 { color: var(--brown); }
.btn-primary { background: linear-gradient(180deg, #F0D27E, var(--gold-deep)); color: #3F2618; border: 1px solid rgba(150,105,30,.35); box-shadow: 0 3px 10px rgba(201,151,58,.3); }
.btn-ghost { color: var(--brown); border-color: rgba(201,151,58,.45); }
a { color: var(--brown-soft); }

/* v12: nothing sits under the header. --header-h is measured live by app.js. */
@media (min-width: 840px) {
  body[data-screen="map"] .app-main { height: calc(100dvh - var(--header-h, 64px)); }
  body[data-screen="map"] .map-wrap { justify-content: flex-start; overflow-y: auto; overflow-x: hidden; }
  body[data-screen="map"] .panel { overflow-y: auto; }
}
html { scroll-padding-top: calc(var(--header-h, 64px) + 8px); }

/* Swoosh markers: white edge is baked into the PNGs; no soft/cream glow so nearby feathers stay crisp */
.leaflet-marker-icon.swoosh-marker { filter: none; }
body[data-marker="swoosh"] .marker-option img { width: 22px; height: 48px; filter: none; }
body[data-marker="swoosh"] .marker-thumb { width: 15px; height: 32px; filter: none; }

/* Feather meanings: picker, story meta, legend */
.marker-option .mo-text { display:flex; flex-direction:column; align-items:flex-start; text-align:left; line-height:1.2; }
.marker-option .mo-text b { font-size:.95rem; }
.marker-option .mo-text small { font-size:.75rem; opacity:.7; }
body[data-marker="swoosh"] .marker-option { display:flex; align-items:center; gap:10px; }
.meta-meaning { font-weight:700; }
.feather-legend { margin:10px auto 0; max-width:640px; background:rgba(255,253,248,.92); border-radius:14px; padding:8px 14px; font-size:.85rem; position:relative; z-index:500; }
.feather-legend summary { cursor:pointer; font-weight:700; }
.feather-legend ul { list-style:none; margin:8px 0 0; padding:0; display:grid; grid-template-columns:repeat(auto-fill,minmax(190px,1fr)); gap:6px 12px; }
.feather-legend li { display:flex; align-items:center; gap:8px; }
.feather-legend img { width:14px; height:30px; object-fit:contain; }
.feather-legend li span { display:flex; flex-direction:column; line-height:1.15; }
.feather-legend small { opacity:.65; font-size:.72rem; }

/* Globe look: ocean blue, spherical shading, atmospheric halo */
#map { background: #0B3D7A; }
.map-circle-glow { position: relative; padding: 4px;
  background: radial-gradient(circle, #9fd4ff 0%, #5aa9f0 100%);
  box-shadow: 0 0 0 3px rgba(190,228,255,.9), 0 0 28px 8px rgba(110,180,255,.55), 0 0 70px 26px rgba(80,150,240,.30), 0 0 130px 50px rgba(160,210,255,.18); }
.map-circle-glow::after { content:""; position:absolute; inset:4px; border-radius:50%; pointer-events:none; z-index:450;
  background: radial-gradient(circle at 35% 30%, rgba(255,255,255,.16) 0%, rgba(255,255,255,0) 38%),
              radial-gradient(circle at 50% 50%, rgba(0,0,0,0) 62%, rgba(6,30,70,.28) 86%, rgba(4,20,50,.55) 100%);
  box-shadow: inset 0 0 18px 4px rgba(170,215,255,.35); }
.ocean-labels { opacity: .85; }
.leaflet-overlay-pane .ocean-labels { pointer-events:none; }

/* CSS-only ocean deepening (no canvas): light land stays light, blue water -> deep sapphire */

.ocean-ref { opacity:.9; }

/* Perfect circle at every viewport: one size used for BOTH width and height */
#map-home .map-wrap { container-type: inline-size; }
.map-circle-glow {
  --globe: min(calc(100vw - 32px), 68vh, 640px);
  width: var(--globe) !important; height: var(--globe) !important;
  min-width: var(--globe); min-height: var(--globe); max-width: none; max-height: none;
  aspect-ratio: 1 / 1; flex: 0 0 auto !important; align-self: center; box-sizing: border-box;
  border-radius: 50%;
}
@supports (width: 1cqi) { .map-circle-glow { --globe: min(calc(100cqi - 32px), 68vh, 640px); } }
@media (min-width: 840px) {
  .map-circle-glow { --globe: min(calc(100vw - 420px), calc(100vh - 260px), 720px); }
  @supports (width: 1cqi) { .map-circle-glow { --globe: min(calc(100cqi - 40px), calc(100vh - 260px), 720px); } }
}
.map-circle-glow > #map { width: 100% !important; height: 100% !important; aspect-ratio: 1 / 1; border-radius: 50%; overflow: hidden; }
@media (max-width: 839px){ .feather-legend { z-index: 1; } }

/* Turquoise brand ocean (#5DAED6, sampled from Kellee's reference map) */
#map { background: #5DAED6; }
.map-circle-glow { background: radial-gradient(circle, #BFE9F0 0%, #6CC3D6 100%) !important;
  box-shadow: 0 0 0 3px rgba(200,240,245,.95), 0 0 28px 8px rgba(64,190,200,.50), 0 0 70px 26px rgba(64,190,200,.26), 0 0 130px 50px rgba(246,211,101,.18) !important; }
.map-circle-glow::after { background: radial-gradient(circle at 35% 30%, rgba(255,255,255,.18) 0%, rgba(255,255,255,0) 38%),
  radial-gradient(circle at 50% 50%, rgba(0,0,0,0) 66%, rgba(10,70,90,.16) 88%, rgba(8,55,75,.32) 100%) !important;
  box-shadow: inset 0 0 18px 4px rgba(200,240,245,.35) !important; }

/* Globe edge: no haze. Default = sparkling pure-white rim; html.ring-none = clean edge only */
.map-circle-glow { background: #fff !important; padding: 3px !important;
  box-shadow: 0 0 0 1px rgba(255,255,255,1), 0 0 3px 1px rgba(255,255,255,.95) !important; }
.map-circle-glow::after { background: none !important; box-shadow: none !important; }
.map-circle-glow::before { content:""; position:absolute; inset:-7px; border-radius:50%; pointer-events:none; z-index:451;
  background:
    radial-gradient(circle at 50% 0.6%, #fff 0 3.4px, transparent 4.6px),
    radial-gradient(circle at 85.4% 14.6%, #fff 0 2.6px, transparent 3.6px),
    radial-gradient(circle at 99.4% 50%, #fff 0 3.8px, transparent 5px),
    radial-gradient(circle at 85.4% 85.4%, #fff 0 2.6px, transparent 3.6px),
    radial-gradient(circle at 50% 99.4%, #fff 0 3.4px, transparent 4.6px),
    radial-gradient(circle at 14.6% 85.4%, #fff 0 2.6px, transparent 3.6px),
    radial-gradient(circle at 0.6% 50%, #fff 0 3.8px, transparent 5px),
    radial-gradient(circle at 14.6% 14.6%, #fff 0 2.6px, transparent 3.6px),
    radial-gradient(circle at 69% 3.8%, #fff 0 2px, transparent 3px),
    radial-gradient(circle at 96.2% 31%, #fff 0 2px, transparent 3px),
    radial-gradient(circle at 31% 96.2%, #fff 0 2px, transparent 3px),
    radial-gradient(circle at 3.8% 69%, #fff 0 2px, transparent 3px);
  filter: drop-shadow(0 0 2px #fff) drop-shadow(0 0 4px rgba(255,255,255,.9)); animation: ring-twinkle 3.2s ease-in-out infinite; }
@keyframes ring-twinkle { 0%,100% { opacity:1; } 50% { opacity:.45; } }
@media (prefers-reduced-motion: reduce) { .map-circle-glow::before { animation:none; } }
html.ring-none .map-circle-glow::before { display:none; }
html.ring-none .map-circle-glow { padding: 0 !important; background: transparent !important; box-shadow: none !important; }

.sea-name { font-family: Georgia, serif; font-style: italic; letter-spacing: .18em; text-transform: uppercase; font-size: 10px; line-height: 1.5; color: #1F5F86; text-align: center; background: none; border: 0; pointer-events: none; }
#scope-chips { display: none !important; }
/* Background lifted so the grey cloud corner sits above the screen */
html::before { inset: -16vh 0 0 0 !important; }
/* Thin turquoise rim (same as the water) so the globe edge stays crisp when zoomed in on land */
html.ring-none .map-circle-glow { box-shadow: 0 0 0 3px #5DAED6 !important; }
.panel-filter { display:flex; width:100%; margin: 0 0 .75rem; box-sizing:border-box; } .panel-filter select { flex:1; min-width:0; }
/* Bigger globe: the map is the main place people come to be inspired */
.map-circle-glow { --globe: min(calc(100vw - 16px), 80vh, 900px); }
@supports (width: 1cqi) { .map-circle-glow { --globe: min(calc(100cqi - 16px), 80vh, 900px); } }
@media (min-width: 840px) {
  .map-circle-glow { --globe: min(calc(100vw - 400px), calc(100vh - 170px), 900px); }
  @supports (width: 1cqi) { .map-circle-glow { --globe: min(calc(100cqi - 24px), calc(100vh - 170px), 900px); } }
}
/* Counter sits just under the globe, clearly visible */
.grace-counter { justify-content: center; margin: 14px auto 4px !important; position: relative; z-index: 2;
  background: rgba(255,253,248,.92); border-radius: 999px; padding: 6px 16px; width: fit-content; box-shadow: 0 2px 10px rgba(201,151,58,.18); }
.feather-legend { width: min(640px, 100%); box-sizing: border-box; }

/* v14: centered globe; filter pill under headline; counter + legend below globe */

#map-home .map-wrap > .feather-legend { margin: 6px auto 0; }
.map-circle-glow { margin: 6px auto 4px; }
@media (max-width: 839px) {
  .map-circle-glow { --globe: max(260px, min(calc(100vw - 16px), calc(100vh - 300px), 900px)); }
  @supports (width: 1cqi) { .map-circle-glow { --globe: max(260px, min(calc(100cqi - 16px), calc(100svh - 300px), 900px)); } }
}
@media (min-width: 840px) {
  .map-circle-glow { --globe: min(calc(100vw - 400px), calc(100dvh - var(--header-h, 64px) - 210px), 900px); }
  @supports (width: 1cqi) { .map-circle-glow { --globe: min(calc(100cqi - 24px), calc(100dvh - var(--header-h, 64px) - 210px), 900px); } }
}
@media (max-width: 839px) {
  #map-home .map-wrap > .feather-legend { padding: 6px 10px; font-size: .72rem; }
  .feather-legend ul { grid-template-columns: repeat(3, minmax(0,1fr)); gap: 4px 8px; margin-top: 6px; }
  .feather-legend img { width: 9px; height: 20px; flex: 0 0 auto; }
  .feather-legend small { display: none; }
}

/* v15: larger globe restored; small right-aligned counter; two filter pills; soft modals */
.map-circle-glow { --globe: min(calc(100vw - 16px), 80vh, 900px); }
@supports (width: 1cqi) { .map-circle-glow { --globe: min(calc(100cqi - 16px), 80vh, 900px); } }
@media (min-width: 840px) {
  .map-circle-glow { --globe: min(calc(100vw - 400px), calc(100vh - 170px), 900px); }
  @supports (width: 1cqi) { .map-circle-glow { --globe: min(calc(100cqi - 24px), calc(100vh - 170px), 900px); } }
}
#map-home .map-wrap > .grace-counter { align-self: flex-start; margin: 0 auto 0 4px !important; padding: 2px 10px; font-size: .7rem; gap: .3rem; box-shadow: 0 1px 6px rgba(201,151,58,.15); }
#map-home .map-wrap > .grace-counter b { font-size: .8rem; }
#map-home .map-wrap > .grace-counter .pulse { width: 7px; height: 7px; }
.filter-pair { display: flex; gap: 6px; margin: 0 0 .75rem; }
.filter-pill { flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; gap: 1px; background: #FFF8E6; border: 1px solid rgba(201,151,58,.45); border-radius: 12px; padding: 3px 8px; }
.fp-label { font-size: .64rem; font-weight: 700; color: var(--brown); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.filter-pill select { border: none; background: transparent; font: inherit; font-size: .76rem; color: var(--ink); width: 100%; padding: 0; cursor: pointer; }
.filter-pill:focus-within { border-color: #5DAED6; box-shadow: 0 0 0 2px rgba(93,174,214,.3); }
.soft-modal { border: none; border-radius: 18px; padding: 1.1rem 1.2rem; width: min(360px, 92vw); background: #FFFDF8; box-shadow: 0 10px 40px rgba(120,80,20,.25); border-top: 4px solid #5DAED6; }
.soft-modal::backdrop { background: rgba(90,60,20,.3); }
.soft-modal h3 { margin: 0 0 .6rem; color: var(--brown); font-size: 1.1rem; }
.soft-modal label { display: flex; flex-direction: column; gap: 3px; font-size: .8rem; font-weight: 600; color: var(--brown); margin-bottom: .55rem; }
.soft-modal input, .soft-modal select { font: inherit; font-size: .9rem; font-weight: 400; padding: .45rem .6rem; border: 1px solid rgba(201,151,58,.45); border-radius: 10px; background: #fff; }
.soft-modal .hint { font-size: .75rem; margin: .2rem 0 .7rem; }
.modal-actions { display: flex; justify-content: flex-end; gap: .5rem; }
/* v17: biggest globe - nearly full height under the header */
.map-circle-glow { --globe: min(calc(100vw - 16px), 1000px); }
@supports (width: 1cqi) { .map-circle-glow { --globe: min(calc(100cqi - 16px), 1000px); } }
@media (min-width: 840px) {
  .map-circle-glow { --globe: min(calc(100vw - 376px), calc(100vh - 110px), 1000px); }
  @supports (width: 1cqi) { .map-circle-glow { --globe: min(calc(100cqi - 16px), calc(100vh - 110px), 1000px); } }
}
/* v19: vivid turquoise header bar with pop */
.app-header { background: linear-gradient(135deg, #3FA9D8 0%, #5DAED6 50%, #6CC6E0 100%) !important;
  border-bottom: 1px solid rgba(255,255,255,.35); box-shadow: 0 3px 14px rgba(20,90,130,.28), 0 1px 0 rgba(255,255,255,.25) inset;
  backdrop-filter: none; -webkit-backdrop-filter: none; }
.app-header .brand-text strong.brand-name { color: #fff; text-shadow: 0 1px 3px rgba(10,60,95,.45); }
.app-header .brand-text span { color: #F2FBFF; text-shadow: 0 1px 2px rgba(10,60,95,.4); }
.app-header .brand-mark { filter: drop-shadow(0 1px 3px rgba(10,60,95,.45)); }
.header-actions .btn-ghost { background: transparent; color: #fff; border: 1.5px solid rgba(255,255,255,.85); text-shadow: 0 1px 2px rgba(10,60,95,.35); }
.header-actions .btn-primary { background: #fff; color: #1E6E96; border: 1.5px solid #fff; box-shadow: 0 2px 8px rgba(10,60,95,.25); }
@media (min-width: 840px) {
  .app-nav .nav-btn { background: rgba(255,255,255,.14); color: #fff; border: 1.5px solid rgba(255,255,255,.7); box-shadow: none; text-shadow: 0 1px 2px rgba(10,60,95,.35); }
  .app-nav .nav-btn[aria-current="page"] { background: #fff; color: #1E6E96; text-shadow: none; border-color: #fff; }
}
/* phone: keep both header buttons on-screen */
@media (max-width: 839px) {
  .app-header { gap: .4rem; padding: .6rem .6rem; }
  .app-header .brand { min-width: 0; flex: 1 1 auto; }
  .app-header .brand-mark { width: 42px; }
  .app-header .brand-text { min-width: 0; }
  .app-header .brand-text strong.brand-name { font-size: 1.4rem; }
  .app-header .brand-text span { font-size: .68rem; }
  .header-actions { flex: 0 0 auto; gap: .3rem; }
  .header-actions .btn { padding: .4rem .6rem; font-size: .74rem; }
}
/* v20: bright luminous gold logo with soft glow + gentle twinkle */
.app-header .brand { position: relative; }
.app-header .brand-mark { filter: brightness(1.35) saturate(1.9) sepia(.2) drop-shadow(0 0 4px rgba(255,240,180,.95)) drop-shadow(0 0 9px rgba(255,214,90,.75)) !important; }
.app-header .brand::before, .app-header .brand::after { content: "✦"; position: absolute; color: #fff; pointer-events: none; line-height: 1;
  text-shadow: 0 0 4px rgba(255,250,210,1), 0 0 8px rgba(255,220,120,.9); animation: brand-twinkle 2.6s ease-in-out infinite; }
.app-header .brand::before { font-size: 10px; left: 2px; top: -4px; }
.app-header .brand::after { font-size: 7px; left: 52px; top: 22px; animation-delay: 1.3s; }
@keyframes brand-twinkle { 0%,100% { opacity: .25; transform: scale(.6) rotate(0deg); } 50% { opacity: 1; transform: scale(1.15) rotate(20deg); } }
@media (max-width: 839px) { .app-header .brand::after { left: 36px; top: 20px; } }
@media (prefers-reduced-motion: reduce) { .app-header .brand::before, .app-header .brand::after { animation: none; opacity: .85; } }
/* v21: Kellee's jeweled feather + script wordmark images */
.app-header .brand-mark { width: auto !important; height: 40px; filter: drop-shadow(0 0 4px rgba(255,240,180,.9)) drop-shadow(0 0 8px rgba(255,214,90,.55)) !important; }
.app-header .brand-text { display: flex; flex-direction: column; align-items: flex-start; gap: 1px; }
.app-header .brand-wordmark { display: block; height: 30px; width: auto; filter: drop-shadow(0 0 3px rgba(255,250,235,.95)) drop-shadow(0 0 7px rgba(255,250,235,.8)); }
.app-header .brand::after { left: 92px; top: 26px; }
@media (max-width: 839px) {
  .app-header .brand-mark { height: 28px; }
  .app-header .brand-wordmark { height: 22px; }
  .app-header .brand::after { left: 60px; top: 18px; }
}
/* v22: optional WHITE header - enable with <html class="header-white"> (turquoise stays default) */
html.header-white .app-header { background: #fff !important; border-bottom: 3px solid #5DAED6; box-shadow: 0 2px 12px rgba(30,110,150,.14); }
html.header-white .app-header .brand-wordmark { filter: none; }
html.header-white .app-header .brand-text span { color: #1E6E96; text-shadow: none; }
html.header-white .app-header .brand-mark { filter: drop-shadow(0 0 3px rgba(255,214,90,.55)) drop-shadow(0 0 7px rgba(255,200,80,.35)) !important; }
html.header-white .app-header .brand::before, html.header-white .app-header .brand::after { color: #E2B33C; text-shadow: 0 0 4px rgba(255,214,90,.9); }
html.header-white .header-actions .btn-ghost { color: #1E6E96; border-color: #5DAED6; text-shadow: none; }
html.header-white .header-actions .btn-primary { background: #3FA9D8; color: #fff; border-color: #3FA9D8; box-shadow: 0 2px 8px rgba(30,110,150,.25); }
@media (min-width: 840px) {
  html.header-white .app-nav .nav-btn { background: #fff; color: #1E6E96; border: 1.5px solid #5DAED6; text-shadow: none; }
  html.header-white .app-nav .nav-btn[aria-current="page"] { background: #3FA9D8; color: #fff; border-color: #3FA9D8; }
}
/* v24: page background options behind the globe - add ONE class to <html>: bg-ivory | bg-skycream | bg-palegold (none = light-rays image) */
html.bg-ivory::before { background: radial-gradient(ellipse 75% 70% at 50% 55%, #FFFDF6 0%, #FBF6EA 55%, #F6EEDC 100%) !important; }
html.bg-skycream::before { background: linear-gradient(180deg, #EAF6FB 0%, #F3F8F3 45%, #FFF8EA 100%) !important; }
html.bg-palegold::before { background: radial-gradient(circle at 50% 56%, #FFF4D6 0%, #FFF6E2 30%, #FBF7EE 65%, #FBF7EE 100%) !important; }
/* v25: theme-earth - white & brown page chrome (map water stays turquoise). Use with header-white. */
html.theme-earth { --sky: #E9DCC6; }
html.theme-earth::before { background: linear-gradient(180deg, #FFFFFF 0%, #FFFDF8 40%, #FAF4EA 100%) !important; }
html.theme-earth #map-home .map-wrap { background: transparent; }
html.theme-earth .map-circle-glow { box-shadow: 0 0 0 3px #8B5E3C, 0 0 22px 6px rgba(201,151,58,.28), 0 0 60px 20px rgba(246,211,101,.16) !important; }
html.theme-earth.ring-none .map-circle-glow { box-shadow: 0 0 0 3px #8B5E3C !important; }
html.theme-earth .map-circle-glow::before { display: none; }
html.header-white.theme-earth .app-header { border-bottom: 2px solid #C9A46A; box-shadow: 0 2px 12px rgba(107,66,38,.10); }
html.header-white.theme-earth .app-header .brand-text span { color: #6B4226; }
html.header-white.theme-earth .header-actions .btn-ghost,
html.header-white.theme-earth .app-nav .nav-btn { background: #fff; color: #6B4226; border: 1.5px solid #8B5E3C; text-shadow: none; box-shadow: none; }
html.header-white.theme-earth .header-actions .btn-primary,
html.header-white.theme-earth .app-nav .nav-btn[aria-current="page"] { background: #6B4226; color: #fff; border: 1.5px solid #6B4226; box-shadow: 0 2px 8px rgba(107,66,38,.25); }
html.theme-earth .filter-pill:focus-within { border-color: #C9973A; box-shadow: 0 0 0 2px rgba(201,151,58,.3); }
html.theme-earth .soft-modal { border-top-color: #8B5E3C; }
html.theme-earth :focus-visible { outline-color: #C9973A; }
html.theme-earth a:not(.btn):not(.brand) { color: #8B5E3C; }
@media (max-width: 839px) {
  html.header-white.theme-earth .app-nav .nav-btn { background: transparent; border: 0; box-shadow: none; }
  html.header-white.theme-earth .app-nav .nav-btn[aria-current="page"] { background: #F3E7D6; color: #6B4226; border: 0; box-shadow: none; }
}
/* v26: light-rays background options for theme-earth */
html.bg-rays-original::before { background: linear-gradient(rgba(255,251,243,.05), rgba(255,251,243,.25)), var(--brand-bg, url("../assets/brand/background.jpg")) center top / cover no-repeat !important; }
html.bg-rays-original #map-home .map-wrap { background: radial-gradient(circle at 50% 45%, rgba(255,253,246,.55) 0%, rgba(255,243,220,.25) 50%, transparent 75%); }
html.bg-rays-warm::before { background: linear-gradient(rgba(255,253,248,.10), rgba(250,244,234,.35)), url("../assets/brand/background-warm.webp") center top / cover no-repeat !important; }
@supports not (background-image: url("x.webp")) { html.bg-rays-warm::before { background-image: url("../assets/brand/background-warm.jpg") !important; } }
/* v27: crisp, larger logo (no haze); twinkling gold stars kept */
html.header-white .app-header .brand-mark { height: 56px !important; width: auto !important; filter: none !important; }
html.header-white .app-header .brand-wordmark { height: 42px; filter: none !important; }
html.header-white .app-header .brand { gap: .6rem; }
html.header-white .app-header .brand::before { left: 0; top: -2px; }
html.header-white .app-header .brand::after { left: 112px; top: 38px; }
@media (max-width: 839px) {
  html.header-white .app-header .brand-mark { height: 34px !important; }
  html.header-white .app-header .brand-wordmark { height: 26px; }
  html.header-white .app-header .brand { gap: .35rem; }
  html.header-white .app-header .brand::after { left: 68px; top: 24px; }
}
@media (max-width: 379px) {
  html.header-white .app-header .brand-mark { height: 30px !important; }
  html.header-white .app-header .brand-wordmark { height: 23px; }
  html.header-white .app-header .brand::after { left: 60px; top: 21px; }
  html.header-white .header-actions .btn { padding: .38rem .5rem; font-size: .7rem; }
}
/* v28: quick zoom strip beside the +/- control (earth styling) */
#map .leaflet-control-zoom { position: relative; overflow: visible; }
.zoom-strip { position: absolute; right: calc(100% + 6px); bottom: 0; display: flex; flex-direction: column; gap: 3px; }
.zoom-strip button { font: 600 10.5px/1 system-ui, sans-serif; color: #6B4226; background: rgba(255,253,248,.92); border: 1px solid rgba(139,94,60,.45);
  border-radius: 999px; padding: 4px 8px; cursor: pointer; box-shadow: 0 1px 3px rgba(61,40,20,.18); text-align: center; }
.zoom-strip button:hover { background: #fff; border-color: #8B5E3C; }
.zoom-strip button[aria-pressed="true"] { background: #E2B33C; border-color: #C9973A; color: #3D2614; }
.zoom-strip button:focus-visible { outline: 2px solid #C9973A; outline-offset: 1px; }
@media (max-width: 839px) { .zoom-strip { gap: 2px; right: calc(100% + 4px); } .zoom-strip button { font-size: 9px; padding: 3px 6px; } }
/* v29: calm map - credits "i", compact level picker, feather tap boxes, clusters */
.feather-hit { background: none; border: 0; display: flex; justify-content: center; align-items: flex-end; }
.feather-hit img { display: block; pointer-events: none; }
.leaflet-marker-pane { z-index: 620; }
.feather-cluster { background: none; border: 0; }
.feather-cluster span { display: flex; align-items: center; justify-content: center; width: 46px; height: 46px; border-radius: 50%;
  background: radial-gradient(circle at 50% 40%, #FFFDF6 0%, #FFF1CF 70%, #F4DC9E 100%); border: 2px solid #C9973A; color: #6B4226;
  font: 700 15px/1 system-ui, sans-serif; box-shadow: 0 0 0 4px rgba(255,248,225,.7), 0 0 14px 4px rgba(246,211,101,.55); }
.feather-cluster span::before { content: "✦"; position: absolute; transform: translate(14px,-14px); font-size: 10px; color: #E2B33C; }
/* credits */
#map .leaflet-bottom.leaflet-left { bottom: 6%; left: 50%; transform: translateX(-50%); }
.map-credits { margin: 0 !important; display: flex; flex-direction: column-reverse; align-items: center; gap: 4px; }
.mc-btn { width: 20px; height: 20px; border-radius: 50%; border: 1px solid rgba(139,94,60,.45); background: rgba(255,253,248,.75); color: #6B4226;
  font: italic 700 12px/1 Georgia, serif; cursor: pointer; padding: 0; opacity: .75; }
.mc-btn:hover, .mc-btn[aria-expanded="true"] { opacity: 1; background: #fff; }
.mc-text { font-size: 10px; line-height: 1.35; background: rgba(255,253,248,.95); color: #5a4030; border-radius: 8px; padding: 5px 8px; max-width: 230px; text-align: center; box-shadow: 0 2px 8px rgba(61,40,20,.2); }
.mc-text a { color: #8B5E3C; }
/* compact level picker (replaces the v28 strip) */
.zoom-level { position: absolute; right: calc(100% + 5px); bottom: 0; display: flex; flex-direction: column-reverse; align-items: flex-end; gap: 3px; opacity: .72; transition: opacity .2s; }
.zoom-level:hover, .zoom-level.is-open, .zoom-level:focus-within { opacity: 1; }
.zoom-level button { font: 600 11px/1 system-ui, sans-serif; color: #6B4226; background: rgba(255,253,248,.95); border: 1px solid rgba(139,94,60,.45);
  border-radius: 999px; padding: 5px 9px; cursor: pointer; white-space: nowrap; box-shadow: 0 1px 3px rgba(61,40,20,.18); }
.zoom-level .zl-menu { display: flex; flex-direction: column; gap: 3px; align-items: stretch; }
.zoom-level .zl-menu[hidden] { display: none; }
.zoom-level .zl-menu button[aria-checked="true"] { background: #E2B33C; border-color: #C9973A; color: #3D2614; }
.zoom-level button:focus-visible { outline: 2px solid #C9973A; outline-offset: 1px; }
#map .leaflet-control-zoom { opacity: .85; } #map .leaflet-control-zoom:hover { opacity: 1; }
@media (max-width: 839px) { .zoom-level button { font-size: 10px; padding: 4px 7px; } }
/* v29: warm the light-gray base map toward the cream/earth palette (labels pane untouched for crisp text) */
#map .calm-base { filter: sepia(.35) saturate(1.1) brightness(.98); }

/* v30: pure white header + white-and-gold light (no pink/beige) */
html.bg-rays-gold::before { background: url("../assets/brand/background-gold.webp") center top / cover no-repeat !important; }
@supports not (background-image: url("x.webp")) { html.bg-rays-gold::before { background-image: url("../assets/brand/background-gold.jpg") !important; } }
html.header-white.theme-earth .app-header { background: #FFFFFF !important; backdrop-filter: none !important; -webkit-backdrop-filter: none !important; border-bottom: 2px solid #D4AF37; box-shadow: 0 2px 10px rgba(212,175,55,.14); }
html.header-white.theme-earth .app-nav .nav-btn[aria-current="page"] { background: #FFF8E1; }

/* v31: name leads, feather is a smaller sparkling stamp */
html.header-white .app-header .brand-mark { height: 44px !important; }
html.header-white .app-header .brand-wordmark { height: 48px; }
html.header-white .app-header .brand::after { left: 88px; top: 30px; }
@media (max-width: 839px) {
  html.header-white .app-header .brand-mark { height: 28px !important; }
  html.header-white .app-header .brand-wordmark { height: 30px; }
  html.header-white .app-header .brand::after { left: 56px; top: 20px; }
}
@media (max-width: 379px) {
  html.header-white .app-header .brand-mark { height: 24px !important; }
  html.header-white .app-header .brand-wordmark { height: 26px; }
  html.header-white .app-header .brand::after { left: 48px; top: 17px; }
}

/* v32: bright white light twinkle (soft golden halo so it shows on the white header) */
html.header-white .app-header .brand::before, html.header-white .app-header .brand::after { color: #FFFFFF !important; text-shadow: 0 0 2px #fff, 0 0 5px rgba(255,236,170,.95), 0 0 10px rgba(212,175,55,.75) !important; }

/* v33: small photo button */
.visually-hidden-file { position:absolute; width:1px; height:1px; opacity:0; overflow:hidden; }
.photo-btn { display:inline-flex; align-items:center; gap:.35rem; padding:.4rem .8rem; border:1.5px solid #8B5E3C; border-radius:999px; color:#6B4226; background:#fff; font-size:.9rem; cursor:pointer; margin:0 .5rem 0 0; }
.photo-btn:hover { background:#FFF8E1; }
.visually-hidden-file:focus-visible + .photo-hint, .visually-hidden-file:focus + .photo-hint { outline: none; }
.photo-hint { font-size:.78rem; }

/* v34: desktop 3-column compose - feathers left, journal middle, sharing right */
@media (min-width: 1000px) {
  #compose-screen { max-width: 1240px !important; }
  .compose-grid { display:grid; grid-template-columns: 230px minmax(0,1fr) 320px; grid-template-areas: "left main right"; gap: 1.5rem; align-items: start; }
  .compose-grid .cmp-left { grid-area:left; margin:0; }
  .compose-grid .cmp-main { grid-area:main; }
  .compose-grid .cmp-right { grid-area:right; }
  .compose-grid .cmp-left .marker-picker { display:grid !important; grid-template-columns: 1fr; gap:.4rem; }
  .compose-grid .cmp-main .story-box { min-height: 420px; }
}
@media (min-width: 1000px) {
  #compose-screen { width: min(1240px, 94vw) !important; max-width: none !important; }
  .compose-grid { grid-template-columns: 210px minmax(0,1fr) 300px; }
  .compose-grid .cmp-left .marker-option { flex-direction: row !important; justify-content:flex-start; gap:8px; padding:.3rem .5rem; text-align:left; }
  .compose-grid .cmp-left .marker-option img { width: 18px !important; height: 34px !important; }
}
@media (min-width: 1000px) { #compose-screen { width: min(1240px, 92vw) !important; } }
.photo-btn { width: auto !important; display: inline-flex !important; }

/* v35: narrower side columns on the compose form */
@media (min-width: 1000px) {
  .compose-grid { grid-template-columns: 180px minmax(0,1fr) 260px !important; gap: 1.25rem; }
  .compose-grid .cmp-left .marker-option .mo-text b { font-size: .85rem; }
  .compose-grid .cmp-right .vis-option small { font-size: .74rem; }
}

/* v36: sacred journal space */
.story-box { background: linear-gradient(180deg, #FFFFFF 0%, #FFFDF7 100%) !important; border: 1.5px solid #E6D3A3 !important; border-radius: 16px !important;
  padding: 1.25rem 1.4rem !important; font-family: Georgia, "Iowan Old Style", "Palatino Linotype", serif !important; font-size: 1.12rem !important; line-height: 1.8 !important; color: #4A3020 !important;
  box-shadow: inset 0 1px 6px rgba(201,151,58,.08), 0 4px 18px rgba(201,151,58,.10) !important; transition: box-shadow .4s ease, border-color .4s ease; }
.story-box::placeholder { color: #A88B6A; font-style: italic; }
.story-box:focus { outline: none !important; border-color: #D4AF37 !important; box-shadow: inset 0 1px 6px rgba(201,151,58,.08), 0 0 0 3px rgba(212,175,55,.18), 0 6px 28px rgba(212,175,55,.28) !important; }
html, body { overflow-x: hidden; }
.compose-grid .cmp-left .marker-option[aria-pressed="true"] { background: #FFF8E1 !important; border-color: #D4AF37 !important; }

/* v37: each feather choice tinted with its own color */
.marker-option { background: color-mix(in srgb, var(--mood, #fff) 16%, white) !important; border: 2px solid color-mix(in srgb, var(--mood, #ddd) 35%, white) !important; }
.marker-option[aria-pressed="true"], .compose-grid .cmp-left .marker-option[aria-pressed="true"] { background: color-mix(in srgb, var(--mood, #fff) 34%, white) !important; border-color: var(--mood, #D4AF37) !important; box-shadow: 0 2px 10px color-mix(in srgb, var(--mood, #D4AF37) 35%, transparent); }

/* v38: outline-only feather choices, larger feathers, livelier labels */
.marker-option { background: #fff !important; border: 2px solid var(--mood, #ddd) !important; }
.marker-option[aria-pressed="true"], .compose-grid .cmp-left .marker-option[aria-pressed="true"] { background: #fff !important; border: 3px solid var(--mood, #D4AF37) !important; box-shadow: 0 2px 10px color-mix(in srgb, var(--mood, #D4AF37) 40%, transparent) !important; }
.compose-grid .cmp-left .marker-option img { width: 26px !important; height: 52px !important; }
.marker-option .mo-text b, .compose-grid .cmp-left .marker-option .mo-text b { font-family: "Avenir Next", "Segoe UI", "Helvetica Neue", Arial, sans-serif !important; font-weight: 700 !important; font-size: .92rem !important; color: #3A2616 !important; letter-spacing: .01em; }
.feather-legend b { font-family: "Avenir Next", "Segoe UI", "Helvetica Neue", Arial, sans-serif; font-weight: 700; color: #3A2616; }

/* v39: back to soft color wash (v37), medium feathers, compact rows so all 9 fit without scrolling */
.marker-option { background: color-mix(in srgb, var(--mood, #fff) 16%, white) !important; border: 2px solid color-mix(in srgb, var(--mood, #ddd) 35%, white) !important; }
.marker-option[aria-pressed="true"], .compose-grid .cmp-left .marker-option[aria-pressed="true"] { background: color-mix(in srgb, var(--mood, #fff) 34%, white) !important; border: 2px solid var(--mood, #D4AF37) !important; box-shadow: 0 2px 10px color-mix(in srgb, var(--mood, #D4AF37) 35%, transparent) !important; }
.compose-grid .cmp-left .marker-option img { width: 22px !important; height: 43px !important; }
.compose-grid .cmp-left .marker-option { padding: .2rem .5rem !important; min-height: 0; }
.compose-grid .cmp-left .marker-picker { gap: .3rem !important; }

/* v40: plain white choices, gold only when chosen, original feather size */
.marker-option { background: #fff !important; border: 2px solid transparent !important; box-shadow: none !important; }
.marker-option[aria-pressed="true"], .compose-grid .cmp-left .marker-option[aria-pressed="true"] { background: #FFF8E1 !important; border: 2px solid #D4AF37 !important; box-shadow: none !important; }
.compose-grid .cmp-left .marker-option img { width: 18px !important; height: 34px !important; }

/* v41: softer original label font, thin color line on each choice */
.marker-option .mo-text b, .compose-grid .cmp-left .marker-option .mo-text b { font-family: inherit !important; font-weight: 600 !important; font-size: .85rem !important; color: var(--ink-soft, #6B4F3A) !important; letter-spacing: 0; }
.feather-legend b { font-family: inherit; font-weight: 600; color: inherit; }
.marker-option, .compose-grid .cmp-left .marker-option { border-left: 4px solid var(--mood, #ddd) !important; }
.marker-option[aria-pressed="true"], .compose-grid .cmp-left .marker-option[aria-pressed="true"] { border-left: 4px solid var(--mood, #D4AF37) !important; }

/* v42: chosen feather = soft fill of its own color (no gold) */
.marker-option[aria-pressed="true"], .compose-grid .cmp-left .marker-option[aria-pressed="true"] { background: color-mix(in srgb, var(--mood, #fff) 22%, white) !important; border: 2px solid transparent !important; border-left: 4px solid var(--mood, #ccc) !important; box-shadow: none !important; }
.swoosh-marker { filter: drop-shadow(0 1px 2px rgba(60,40,20,.35)); }

/* v43: feather key pinned at top of side panel (desktop), always visible */
.feather-legend.legend-in-panel { margin: 0 0 10px; max-width: none; padding: 8px 10px; background: #fff; border: 1px solid #EBDDC2; border-radius: 12px; font-size: .74rem; position: sticky; top: 0; z-index: 5; }
.feather-legend.legend-in-panel summary { font-weight: 600; color: #6B4226; cursor: pointer; }
.feather-legend.legend-in-panel ul { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 4px 6px; margin: 6px 0 0; padding: 0; list-style: none; }
.feather-legend.legend-in-panel li { display: flex; align-items: center; gap: 4px; line-height: 1.15; }
.feather-legend.legend-in-panel img { width: 10px; height: 22px; flex: 0 0 auto; }

/* ===== v44: Touched my heart hands dropdown; white + gold response boxes (no pink) ===== */
.resp-primary, .resp-btn.resp-primary { background: #FFFFFF; border: 1px solid #E6D3A3; }
.resp-primary[aria-pressed="true"], .resp-btn.resp-primary[aria-pressed="true"] { background: linear-gradient(180deg, #FFFFFF, #FFF8E3); border-color: #C9A24A; box-shadow: 0 0 0 1px rgba(201,162,74,.25); }
.resp-primary .resp-label { color: #6B4A2B; }
.gift-primary, .gift-chip.gift-primary { background: #FFFFFF; border-color: #E6D3A3; }
.gifts-hero h2 { color: #8A6A2E; }
.resp-icon, .gifts-heart, .hands-img { object-fit: contain; background: transparent; }
.hands-picker { display: block; }
.hands-dd { position: relative; max-width: 320px; }
.hands-dd-btn { display: flex; align-items: center; gap: 12px; width: 100%; padding: 8px 14px; background: #FFFFFF; border: 1px solid #E6D3A3; border-radius: 14px; color: #5A3E24; font: inherit; cursor: pointer; }
.hands-dd-btn .hands-img { width: 56px; height: 56px; }
.hands-dd-btn .caret { margin-left: auto; color: #B8913E; }
.hands-dd .hands-menu { display: none; position: absolute; z-index: 1200; left: 0; right: 0; top: calc(100% + 6px); }
.hands-dd.open .hands-menu { display: block; }
.hands-menu { list-style: none; margin: 0; padding: 8px; background: #FFFFFF; border: 1px solid #EADDBB; border-radius: 16px; box-shadow: 0 10px 28px rgba(90,62,36,.12); }
.hands-item { display: flex; align-items: center; gap: 14px; padding: 6px 10px; margin: 2px 0; background: #FFFFFF; border: 1px solid transparent; border-radius: 12px; cursor: pointer; color: #5A3E24; }
.hands-item .hands-img { width: 72px; height: 72px; }
.hands-item:hover, .hands-item:focus { background: #FFFCF2; border-color: #EEDFB8; outline: none; }
.hands-item.selected { background: #FFF8E3; border-color: #C9A24A; }
.hands-pop { margin: 8px 0 4px; padding: 10px; background: #FFFFFF; border: 1px solid #E6D3A3; border-radius: 16px; box-shadow: 0 8px 22px rgba(90,62,36,.10); }
.hands-pop .hands-menu { border: 0; box-shadow: none; padding: 0; display: flex; gap: 6px; flex-wrap: wrap; }
.hands-pop .hands-item { flex-direction: column; gap: 2px; font-size: 13px; padding: 6px; }
.hands-pop .hands-item .hands-img { width: 64px; height: 64px; }
.hands-pop-h { margin: 0 0 6px; color: #6B4A2B; font-weight: 600; font-size: 14px; }
.hands-pop-note { margin: 6px 0 0; font-size: 12px; color: #8A7356; }
.hands-pop .hands-menu { flex-wrap: nowrap; justify-content: space-between; } .hands-pop .hands-item { flex: 1 1 0; min-width: 0; text-align: center; }

/* ===== v45: Touched my heart hand-color gathering (everyone sees the mix) ===== */
.hands-cluster {
  display: inline-flex;
  align-items: center;
  flex: none;
  height: 24px;
  margin-right: 2px;
}
.hands-cluster .hands-stack-img {
  width: 22px;
  height: 22px;
  object-fit: contain;
  background: #FFFFFF;
  border-radius: 50%;
  box-shadow: 0 0 0 1.5px #FFFFFF, 0 0 0 2px rgba(201, 162, 74, 0.4);
  margin-left: -10px;
  position: relative;
}
.hands-cluster .hands-stack-img:first-child { margin-left: 0; }
.resp-primary {
  max-width: 100%;
  flex-wrap: nowrap;
  gap: 0.35rem;
  justify-content: flex-start;
  align-items: center;
}
.resp-primary .hands-cluster { flex: 0 1 auto; min-width: 0; }
.resp-primary .resp-label {
  white-space: nowrap;
  color: #6B4A2B;
  flex: 0 0 auto;
}
.resp-primary .resp-count { flex: 0 0 auto; margin-left: 0.1rem; }
.feather-popup .hands-cluster { height: 22px; }
.feather-popup .hands-cluster .hands-stack-img {
  width: 20px;
  height: 20px;
  margin-left: -9px;
  box-shadow: 0 0 0 1px #FFFFFF, 0 0 0 1.5px rgba(201, 162, 74, 0.35);
}
.feather-popup .resp-primary { padding: 0.3rem 0.55rem 0.3rem 0.35rem; }
.feather-popup .resp-primary .resp-label { font-size: 0.78rem; }
.gifts-hero .hands-cluster {
  height: 56px;
  flex: none;
}
.gifts-hero .hands-cluster .hands-stack-img,
.gifts-hero .gifts-stack-img {
  width: 52px;
  height: 52px;
  margin-left: -18px;
  box-shadow: 0 0 0 2px #FFFFFF, 0 0 0 3px rgba(201, 162, 74, 0.4);
}
.gifts-hero .hands-cluster .hands-stack-img:first-child { margin-left: 0; }
.gift-chip .hands-cluster {
  height: 22px;
  vertical-align: middle;
}
.gift-chip .hands-cluster .hands-stack-img {
  width: 20px;
  height: 20px;
  margin-left: -8px;
  box-shadow: 0 0 0 1px #FFFFFF, 0 0 0 1.5px rgba(201, 162, 74, 0.35);
}
@media (max-width: 520px) {
  .post-card .hands-cluster { height: 24px; }
  .post-card .hands-cluster .hands-stack-img {
    width: 22px;
    height: 22px;
    margin-left: -10px;
  }
}

.gifts-summary { background: #FFFFFF; border: 1px solid #E6D3A3; }

/* ===== v46: seven hand choices, grouped and comfortably sized on phones ===== */
.hands-dd.open .hands-menu, .hands-pop .hands-menu {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px;
}
.hands-menu-heading {
  grid-column: 1 / -1; padding: 5px 8px 2px;
  color: #8A7356; font-size: 12px; font-weight: 600; letter-spacing: .02em;
}
.hands-menu .hands-item {
  flex-direction: row; gap: 8px; padding: 5px 6px; margin: 0;
  min-width: 0; text-align: left; font-size: 13px;
}
.hands-menu .hands-item .hands-img { width: 40px; height: 40px; flex: 0 0 40px; }
.hands-menu .hands-item:focus-visible { outline: 2px solid #C9A24A; outline-offset: -2px; }
.hands-pop { max-height: 380px; overflow-y: auto; }

/* ===== v47: one clear Blessings gathering, sized for a phone ===== */
#journal-screen, .gifts-hero, .gifts-hero > div { min-width: 0; }
@media (max-width: 520px) {
  .gifts-hero { flex-direction: column; align-items: flex-start; gap: .65rem; }
  .gifts-hero .hands-cluster { height: 36px; }
  .gifts-hero .hands-cluster .hands-stack-img {
    width: 32px; height: 32px; margin-left: -14px;
    box-shadow: 0 0 0 1.5px #FFFFFF, 0 0 0 2px rgba(201,162,74,.4);
  }
  .gifts-hero .hands-cluster .hands-stack-img:first-child { margin-left: 0; }
}

/* ===== v49: switchable gold-glitter video trial, behind the map area only ===== */
/* v93: html.bg-gold-glitter rules below are kept as a backup. The map now stays
   sunlit at all hours (see ANGELS_CONFIG.background.forceSunlit). The gold-glitter
   look now powers the Prayer view (.prayer-gold-background). */
.map-gold-background { display: none; }
html.bg-gold-glitter body[data-screen="map"] #map-home .map-wrap {
  position: relative; isolation: isolate; background: #1B1006;
}
html.bg-gold-glitter body[data-screen="map"] .map-gold-background {
  display: block; position: absolute; inset: 0 0 auto; height: 100%; min-height: 100%; z-index: -1; overflow: hidden;
  pointer-events: none;
  background: #1B1006 url("../assets/bg/gold-glitter-poster.jpg") center / cover no-repeat;
}
.map-gold-video {
  position: absolute; inset: -2px; width: calc(100% + 4px); height: calc(100% + 4px);
  object-fit: cover; object-position: center; filter: blur(1.3px);
}
html.bg-gold-glitter body[data-screen="map"] .welcome h1 { color: #FFF1C7; }
html.bg-gold-glitter body[data-screen="map"] .welcome p { color: #FFF5DF; }
html.bg-gold-glitter body[data-screen="map"] .welcome { text-shadow: 0 1px 4px #1B1006; }
html.bg-gold-glitter body[data-screen="map"] .map-circle-glow {
  box-shadow: 0 0 0 3px #8B5E3C, 0 0 0 4px rgba(224,186,93,.65),
    0 8px 28px rgba(0,0,0,.45), 0 0 22px rgba(255,220,133,.22) !important;
}
html.bg-gold-glitter body[data-screen="map"] .mc-btn,
html.bg-gold-glitter body[data-screen="map"] .zoom-level button {
  background: #FFFDF8; opacity: 1;
}
@media (prefers-reduced-motion: reduce) {
  .map-gold-video, .prayer-gold-video { display: none; }
}

/* ===== v50: sunlit sky, feathered blessing rays and drifting illuminated dust ===== */
.map-sun-background { display: none; }
html.bg-sunlit body[data-screen="map"] #map-home .map-wrap {
  position: relative; isolation: isolate; background: #97BDEA;
}
html.bg-sunlit body[data-screen="map"] .map-sun-background {
  display: block; position: absolute; inset: 0 0 auto; min-height: 100%; height: 100%;
  z-index: -1; overflow: hidden; pointer-events: none;
  background:
    radial-gradient(ellipse at 88% 78%, rgba(255,255,255,.22), transparent 32%),
    radial-gradient(ellipse at 10% 72%, rgba(255,255,255,.15), transparent 27%),
    radial-gradient(ellipse at 0% 0%, #FFFDF1 0%, #FFF4C9 12%, rgba(255,249,222,.76) 28%, transparent 67%),
    linear-gradient(135deg, #E9F4FC 0%, #BDDDF5 45%, #6699E0 100%);
}
.map-sun-background::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: url("../assets/bg/sunbeams.svg") left top / 100% 100% no-repeat;
  animation: blessing-rays 14s ease-in-out infinite;
}
.sun-dust { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
@keyframes blessing-rays { 0%,100% { opacity: .76; } 50% { opacity: 1; } }
html.bg-sunlit body[data-screen="map"] .map-circle-glow {
  box-shadow: 0 0 0 3px #8B5E3C, 0 0 0 4px rgba(255,228,160,.65),
    0 10px 30px rgba(103,72,30,.28), 0 0 22px rgba(255,238,183,.28) !important;
}
html.bg-sunlit body[data-screen="map"] .welcome {
  color: #573B23; background: rgba(255,253,239,.4); border-radius: 14px;
  text-shadow: 0 1px 2px rgba(255,255,255,.8);
}
html.bg-sunlit body[data-screen="map"] .welcome h1,
html.bg-sunlit body[data-screen="map"] .welcome p { color: #573B23; }
html.bg-sunlit body[data-screen="map"] .mc-btn,
html.bg-sunlit body[data-screen="map"] .zoom-level button { background: #FFFDF8; opacity: 1; }
@media (prefers-reduced-motion: reduce) { .map-sun-background::before { animation: none; opacity: .9; } }

.map-sun-background.sun-paused::before { animation-play-state: paused; }

/* ===== v51: automatic local day/night, gentle cross-fade and readable night copy ===== */
/* Keep BOTH layers painted during a transition; inactive media remains paused. */
body[data-screen="map"] .map-gold-background,
body[data-screen="map"] .map-sun-background {
  position: absolute; inset: 0 0 auto; height: 100%; min-height: 100%;
  z-index: -1; overflow: hidden; pointer-events: none;
  opacity: 0; transition: opacity 2s ease;
}
body[data-screen="map"] .map-gold-background {
  background: #1B1006 url("../assets/bg/gold-glitter-poster.jpg") center / cover no-repeat;
}
body[data-screen="map"] .map-sun-background {
  background:
    radial-gradient(ellipse at 88% 78%, rgba(255,255,255,.22), transparent 32%),
    radial-gradient(ellipse at 10% 72%, rgba(255,255,255,.15), transparent 27%),
    radial-gradient(ellipse at 0% 0%, #FFFDF1 0%, #FFF4C9 12%, rgba(255,249,222,.76) 28%, transparent 67%),
    linear-gradient(135deg, #E9F4FC 0%, #BDDDF5 45%, #6699E0 100%);
}
html:is(.bg-sunlit,.bg-gold-glitter) body[data-screen="map"] .map-gold-background,
html:is(.bg-sunlit,.bg-gold-glitter) body[data-screen="map"] .map-sun-background { display: block; }
html.bg-sunlit body[data-screen="map"] .map-sun-background,
html.bg-gold-glitter body[data-screen="map"] .map-gold-background { opacity: 1; }
.welcome, .grace-counter { transition: background-color 2s ease, border-color 2s ease, color 2s ease; }
.welcome h1, .welcome p { transition: color 2s ease; }
html.bg-gold-glitter body[data-screen="map"] .welcome {
  width: min(560px, calc(100% - 12px)); padding: 12px 16px;
  background: rgba(30,18,10,.67); border: 1px solid rgba(232,201,122,.48);
  border-radius: 16px; backdrop-filter: blur(7px); -webkit-backdrop-filter: blur(7px);
  box-shadow: 0 3px 16px rgba(0,0,0,.2); overflow-wrap: anywhere;
  text-shadow: 0 1px 3px rgba(12,6,2,.8);
}
html.bg-gold-glitter body[data-screen="map"] .welcome h1 { color: #FFF0C9; }
html.bg-gold-glitter body[data-screen="map"] .welcome p { color: #FFF6E1; }
html.bg-gold-glitter body[data-screen="map"] .grace-counter {
  max-width: calc(100% - 24px); flex-wrap: wrap; line-height: 1.5;
  color: #FFF5DD; background: rgba(30,18,10,.8); border: 1px solid rgba(232,201,122,.5);
  backdrop-filter: blur(7px); -webkit-backdrop-filter: blur(7px);
  text-shadow: 0 1px 2px #1B1006; box-shadow: 0 2px 12px rgba(0,0,0,.22);
}
html.bg-gold-glitter body[data-screen="map"] .grace-counter b { color: #FFDB7B; }
@media (prefers-reduced-motion: reduce) {
  .map-gold-background, .map-sun-background, .welcome, .welcome h1, .welcome p, .grace-counter { transition: none !important; }
}

html:not(.bg-transition-ready) .map-gold-background,
html:not(.bg-transition-ready) .map-sun-background,
html:not(.bg-transition-ready) .welcome,
html:not(.bg-transition-ready) .welcome h1,
html:not(.bg-transition-ready) .welcome p,
html:not(.bg-transition-ready) .grace-counter { transition: none !important; }
html:not(.bg-sunlit) .map-sun-background::before { animation-play-state: paused; }

/* ===== v52: fit the round map above the fold; compact hero; photo popups that stay readable ===== */
/* v52: stop the browser from scrolling the page to the map on load */
#map, .map-circle-glow, #map-home .map-wrap { overflow-anchor: none; }

/* Live budgets set by app.js (--map-hero-h, --map-bottom-h). Fallbacks keep first paint sane. */
:root {
  --map-hero-h: 110px;
  --map-bottom-h: 8px;
}

body[data-screen="map"] #map-home .map-wrap {
  padding: 4px 8px 8px;
  gap: 0.4rem;
  justify-content: flex-start;
  overflow-x: hidden;
  overflow-y: auto; /* fallback for very short windows */
}

@media (min-width: 840px) {
  body[data-screen="map"] #map-home .map-wrap {
    /* Prefer no scroll: globe sizes to remaining height */
    overflow-y: hidden;
  }
}

/* Compact hero: counter tucked beside the headline on laptop, under copy on phone */
.welcome.map-hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
  width: min(640px, calc(100% - 8px));
  max-width: min(640px, calc(100% - 8px));
  margin: 0 auto;
  padding: 0.35rem 0.65rem;
  box-sizing: border-box;
  text-align: center;
}
.welcome.map-hero .welcome-copy { min-width: 0; }
.welcome.map-hero h1 { font-size: 1.15rem; margin: 0 0 0.15rem; line-height: 1.25; }
.welcome.map-hero p { margin: 0; font-size: 0.82rem; line-height: 1.35; }
.welcome.map-hero .grace-counter {
  margin: 0 !important;
  align-self: center;
  padding: 3px 12px;
  font-size: 0.72rem;
  gap: 0.35rem;
  width: fit-content;
  max-width: 100%;
  box-shadow: 0 1px 6px rgba(201,151,58,.15);
}
.welcome.map-hero .grace-counter b { font-size: 0.82rem; }
.welcome.map-hero .grace-counter .pulse { width: 7px; height: 7px; }

@media (min-width: 840px) {
  .welcome.map-hero {
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 0.45rem 0.9rem;
    text-align: left;
    padding: 0.4rem 0.85rem;
  }
  .welcome.map-hero .welcome-copy { flex: 1 1 280px; min-width: 0; }
  .welcome.map-hero .grace-counter {
    flex: 0 1 auto;
    align-self: center;
    margin: 0 !important;
  }
  .welcome.map-hero h1 { font-size: 1.2rem; }
  .welcome.map-hero p { font-size: 0.84rem; }
}

/* Hide the old loose counter rules that assumed it sat under the hero as a sibling */
#map-home .map-wrap > .grace-counter { display: none; }

/* Globe fills the remaining viewport under header + hero (+ phone legend/nav) */
.map-circle-glow {
  --globe: min(
    calc(100vw - 20px),
    calc(100dvh - var(--header-h, 64px) - var(--map-hero-h, 110px) - var(--map-bottom-h, 8px)),
    900px
  );
  margin: 2px auto 0 !important;
}
@supports (width: 1cqi) {
  .map-circle-glow {
    --globe: min(
      calc(100cqi - 16px),
      calc(100dvh - var(--header-h, 64px) - var(--map-hero-h, 110px) - var(--map-bottom-h, 8px)),
      900px
    );
  }
}
@supports (height: 100svh) {
  .map-circle-glow {
    --globe: min(
      calc(100vw - 20px),
      calc(100svh - var(--header-h, 64px) - var(--map-hero-h, 110px) - var(--map-bottom-h, 8px)),
      900px
    );
  }
  @supports (width: 1cqi) {
    .map-circle-glow {
      --globe: min(
        calc(100cqi - 16px),
        calc(100svh - var(--header-h, 64px) - var(--map-hero-h, 110px) - var(--map-bottom-h, 8px)),
        900px
      );
    }
  }
}
@media (max-width: 839px) {
  /* Let the page scroll to the feed; first screen keeps hero + globe + feather key above the nav. */
  body[data-screen="map"] {
    min-height: 100svh;
    overflow-y: auto;
  }
  body[data-screen="map"] #map-home.app-main {
    display: flex;
    flex-direction: column;
    height: auto;
    min-height: 0;
    overflow: visible;
  }
  body[data-screen="map"] #map-home .map-wrap {
    flex: 0 0 auto;
    min-height: 0;
    overflow: visible;
    padding-bottom: 6px;
  }
  body[data-screen="map"] #map-home > .panel {
    flex: 0 0 auto;
    max-height: none;
    margin-bottom: calc(4.25rem + env(safe-area-inset-bottom, 0px));
  }
  body[data-screen="map"] .app-nav {
    position: fixed;
    left: 0; right: 0; bottom: 0;
  }
  .welcome.map-hero { padding: 0.3rem 0.55rem; gap: 0.28rem; }
  .welcome.map-hero h1 { font-size: 1.05rem; }
  .welcome.map-hero p { font-size: 0.78rem; line-height: 1.3; }
  .map-circle-glow {
    --globe: max(
      200px,
      min(
        calc(100vw - 20px),
        calc(100svh - var(--header-h, 64px) - var(--map-hero-h, 110px) - var(--map-bottom-h, 200px)),
        900px
      )
    );
  }
}
@media (min-width: 840px) {
  .map-circle-glow {
    --globe: min(
      calc(100vw - 400px),
      calc(100dvh - var(--header-h, 64px) - var(--map-hero-h, 110px) - 20px),
      900px
    );
  }
  @supports (width: 1cqi) {
    .map-circle-glow {
      --globe: min(
        calc(100cqi - 16px),
        calc(100dvh - var(--header-h, 64px) - var(--map-hero-h, 110px) - 20px),
        900px
      );
    }
  }
}

/* Phone feather key stays glanceable under the smaller globe */
@media (max-width: 839px) {
  #map-home .map-wrap > .feather-legend {
    margin: 4px auto 0;
    padding: 5px 8px;
    font-size: .7rem;
  }
  .feather-legend ul { gap: 3px 6px; margin-top: 4px; }
}

/* Keep night headline panel readable with the tucked counter */
html.bg-gold-glitter body[data-screen="map"] .welcome.map-hero {
  width: min(720px, calc(100% - 12px));
  padding: 10px 14px;
}
html.bg-gold-glitter body[data-screen="map"] .welcome.map-hero .grace-counter {
  color: #FFF5DD;
  background: rgba(30,18,10,.55);
  border: 1px solid rgba(232,201,122,.45);
  text-shadow: 0 1px 2px #1B1006;
  box-shadow: none;
}
html.bg-gold-glitter body[data-screen="map"] .welcome.map-hero .grace-counter b { color: #FFDB7B; }
html.bg-sunlit body[data-screen="map"] .welcome.map-hero {
  background: rgba(255,253,239,.4);
  border-radius: 14px;
}

/* ----- Miracle popups with photos: fit the visible map, no layout jump ----- */
.leaflet-popup.grace-popup {
  margin-bottom: 12px;
}
.leaflet-popup.grace-popup .leaflet-popup-content-wrapper {
  background: #FFFFFF;
  border: 1px solid #E6D3A3;
  border-radius: 14px;
  box-shadow: 0 8px 28px rgba(90,62,36,.18);
  padding: 0;
  overflow: hidden;
}
.leaflet-popup.grace-popup .leaflet-popup-content {
  margin: 0.65rem 0.8rem 0.7rem;
  max-width: min(280px, 78vw);
}
.leaflet-popup.grace-popup .leaflet-popup-tip {
  background: #FFFFFF;
  border: 1px solid #E6D3A3;
  box-shadow: none;
}
.feather-popup {
  max-height: min(42dvh, 340px);
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}
.feather-popup .popup-photo {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 10;
  height: auto;
  max-height: 110px;
  object-fit: cover;
  border-radius: 10px;
  margin: 0.35rem 0 0.15rem;
  background: #F7EEDC;
}
@media (max-width: 839px) {
  .feather-popup { max-height: min(38dvh, 300px); }
  .feather-popup .popup-photo { max-height: 96px; }
  /* Bottom sheet lives on document.body (Leaflet panes are transformed, so position:fixed fails there) */
  .grace-sheet {
    position: fixed;
    left: 8px;
    right: 8px;
    bottom: calc(68px + env(safe-area-inset-bottom, 0px));
    z-index: 2600;
    max-height: min(48dvh, 380px);
    display: flex;
    flex-direction: column;
    background: #FFFFFF;
    border: 1px solid #E6D3A3;
    border-radius: 16px;
    box-shadow: 0 10px 36px rgba(90,62,36,.28);
    overflow: hidden;
  }
  .grace-sheet[hidden] { display: none !important; }
  .grace-sheet-card {
    padding: 0.7rem 0.85rem 0.85rem;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    max-height: min(48dvh, 380px);
  }
  .grace-sheet-card .popup-photo {
    max-height: 120px;
  }
  .grace-sheet-close {
    position: absolute;
    top: 6px;
    right: 8px;
    width: 32px;
    height: 32px;
    border: 0;
    border-radius: 999px;
    background: rgba(255,253,248,.92);
    color: #6B4226;
    font: 700 18px/1 system-ui, sans-serif;
    cursor: pointer;
  }
  /* Hide the in-map popup while the sheet is open */
  body.grace-sheet-open .leaflet-popup-pane { visibility: hidden; }
}

/* ===== v54: feather key starts closed; clear tappable pill summary ===== */
.feather-legend {
  background: transparent;
  border: 0;
  box-shadow: none;
  padding: 0;
  width: fit-content;
  max-width: min(640px, calc(100% - 16px));
  margin-left: auto;
  margin-right: auto;
}
.feather-legend summary {
  list-style: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  cursor: pointer;
  user-select: none;
  font: 600 0.84rem/1.2 system-ui, "Segoe UI", sans-serif;
  color: #6B4226;
  background: #FFFFFF;
  border: 1.5px solid #C9A24A;
  border-radius: 999px;
  padding: 0.48rem 0.95rem 0.48rem 1.05rem;
  box-shadow: 0 2px 8px rgba(90, 62, 36, 0.10);
}
.feather-legend summary::-webkit-details-marker { display: none; }
.feather-legend summary::marker { content: ""; }
.feather-legend summary::after {
  content: "▾";
  font-size: 0.78rem;
  color: #B8913E;
  line-height: 1;
  transform: translateY(-0.5px);
}
.feather-legend[open] summary::after { content: "▴"; }
.feather-legend summary:hover {
  background: #FFFCF2;
  border-color: #B8913E;
}
.feather-legend summary:focus-visible {
  outline: 2px solid #C9A24A;
  outline-offset: 2px;
}

/* Expanded card — only when open */
.feather-legend[open] {
  width: min(640px, calc(100% - 16px));
  background: #FFFFFF;
  border: 1px solid #EBDDC2;
  border-radius: 14px;
  padding: 8px 12px 10px;
  box-shadow: 0 4px 16px rgba(90, 62, 36, 0.08);
}
.feather-legend[open] summary {
  width: 100%;
  justify-content: space-between;
  box-sizing: border-box;
  background: #FFFCF5;
  margin-bottom: 2px;
}

/* Desktop: same closed pill in the side panel */
.feather-legend.legend-in-panel {
  background: transparent;
  border: 0;
  padding: 0;
  margin: 0 0 10px;
  max-width: none;
  width: fit-content;
  position: sticky;
  top: 0;
  z-index: 5;
}
.feather-legend.legend-in-panel[open] {
  width: 100%;
  background: #FFFFFF;
  border: 1px solid #EBDDC2;
  border-radius: 12px;
  padding: 8px 10px;
}
.feather-legend.legend-in-panel summary {
  font-size: 0.78rem;
  padding: 0.42rem 0.85rem 0.42rem 0.95rem;
}

@media (max-width: 839px) {
  #map-home .map-wrap > .feather-legend {
    margin: 6px auto 0;
    padding: 0;
    font-size: inherit;
  }
  #map-home .map-wrap > .feather-legend[open] {
    padding: 6px 10px 8px;
  }
  .feather-legend summary {
    font-size: 0.8rem;
    padding: 0.44rem 0.85rem 0.44rem 0.95rem;
  }
}

/* ===== v56: front-page copy — journal invitation and quiet dedication ===== */
.map-dedication {
  margin: 2px auto 0;
  padding: 0 8px;
  max-width: min(420px, calc(100% - 16px));
  text-align: center;
  font: italic 0.72rem/1.35 Georgia, "Times New Roman", serif;
  color: #8A7356;
  letter-spacing: 0.01em;
}
.journal-invite {
  display: block;
  text-decoration: none;
  color: #6B4226;
  background: #FFFFFF;
  border: 1.5px solid #C9A24A;
  border-radius: 14px;
  padding: 0.65rem 0.85rem;
  box-shadow: 0 2px 10px rgba(90, 62, 36, 0.10);
  box-sizing: border-box;
  cursor: pointer;
}
.journal-invite-text {
  display: block;
  font: 500 0.84rem/1.4 var(--font);
  color: #6B4226;
  text-align: left;
}
.journal-invite:hover {
  background: #FFFCF2;
  border-color: #B8913E;
}
.journal-invite:focus-visible {
  outline: 2px solid #C9A24A;
  outline-offset: 2px;
}

/* Desktop hero: a little wider so the new sentence stays two lines and the globe stays ~416px */
@media (min-width: 840px) {
  .welcome.map-hero {
    width: min(720px, calc(100% - 16px));
    max-width: min(720px, calc(100% - 16px));
  }
  .welcome.map-hero .welcome-copy { flex: 1 1 340px; }
  .welcome.map-hero p { font-size: 0.8rem; line-height: 1.32; }
  /* Keep the v55 globe size and low placement even though the new copy is a little shorter */
  .welcome.map-hero { margin-bottom: 28px; }
}

/* Laptop: invitation lives in the side panel (moved there in JS), so the globe stays the same size */
@media (min-width: 840px) {
  aside.panel > .journal-invite {
    margin: 0 0 12px;
    width: 100%;
  }
  aside.panel > .journal-invite .journal-invite-text { font-size: 0.82rem; }
  /* Dedication tucked in the lower sky of the map column, not in the globe's layout flow */
  body[data-screen="map"] #map-home .map-wrap { position: relative; }
  body[data-screen="map"] #map-home .map-wrap > .journal-invite { display: none; } /* safety if JS has not moved it yet */
  body[data-screen="map"] #map-home .map-dedication {
    position: absolute;
    left: 10px;
    right: auto;
    bottom: 8px;
    max-width: min(240px, calc((100% - var(--globe, 416px)) / 2 - 16px));
    margin: 0;
    padding: 0;
    text-align: left;
    font-size: 0.7rem;
    line-height: 1.35;
    z-index: 4;
    pointer-events: none;
  }
}

/* Phone: compact card under the map, above the closed feather key; dedication just under the globe */
@media (max-width: 839px) {
  body[data-screen="map"] #map-home .map-dedication {
    margin: 4px auto 2px;
    font-size: 0.7rem;
  }
  body[data-screen="map"] #map-home .journal-invite {
    width: min(100%, 420px);
    margin: 4px auto 2px;
    padding: 0.55rem 0.75rem;
  }
  body[data-screen="map"] #map-home .journal-invite-text {
    font-size: 0.8rem;
    line-height: 1.35;
  }
}

/* Night: dedication stays quiet and readable on the gold sky; journal card stays white-with-gold */
html.bg-gold-glitter body[data-screen="map"] .map-dedication {
  color: #E6D4A4;
  text-shadow: 0 1px 3px rgba(12, 6, 2, 0.7);
}
html.bg-gold-glitter body[data-screen="map"] #map-home .journal-invite {
  background: rgba(255, 253, 248, 0.94);
  border-color: #C9A24A;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.28);
}

/* ===== v57: comfortable miracle reading card, photo-or-clip, optional ?bigmap=1 ===== */
/* Every story opens in a white-and-gold reading card: centered over the map column on laptop,
   a tall scrollable bottom sheet on phone. The small in-map popup becomes an invisible carrier. */
body.grace-sheet-open .leaflet-popup-pane { visibility: hidden; }
.grace-sheet {
  position: fixed;
  z-index: 2600;
  display: flex;
  flex-direction: column;
  background: #FFFFFF;
  border: 1.5px solid #C9A24A;
  border-radius: 18px;
  box-shadow: 0 14px 44px rgba(90, 62, 36, 0.28), 0 0 0 6px rgba(255, 246, 220, 0.55);
  overflow: hidden;
}
.grace-sheet::before { /* thin gold ribbon along the top */
  content: "";
  display: block;
  flex: 0 0 4px;
  background: linear-gradient(90deg, #E8C97A, #C9A24A 50%, #E8C97A);
}
.grace-sheet[hidden] { display: none !important; }
.grace-sheet-card {
  padding: 1rem 1.25rem 1.1rem;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  max-height: none;
  flex: 1 1 auto;
}
.grace-sheet .feather-popup.story-read { max-height: none; overflow: visible; }
.grace-sheet-close {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 2;
  width: 36px;
  height: 36px;
  border: 1.5px solid #C9A24A;
  border-radius: 999px;
  background: #FFFFFF;
  color: #6B4226;
  font: 700 20px/1 system-ui, sans-serif;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(90, 62, 36, 0.15);
}
.grace-sheet-close:hover { background: #FFF8E1; }
.grace-sheet-close:focus-visible { outline: 2px solid #C9A24A; outline-offset: 2px; }

/* Reading type */
.story-read .mood-pill {
  font-size: 0.9rem;
  padding: 0.3rem 0.85rem;
  margin-right: 2.6rem; /* clear the close button */
  border: 1px solid rgba(201, 162, 74, 0.45);
}
.story-read p.story-text {
  font-size: 18px;
  line-height: 1.62;
  color: #3D342C;
  margin: 0.8rem 0 0.75rem;
  white-space: pre-line;
  overflow-wrap: anywhere;
}
.story-read .meta {
  font-size: 0.92rem;
  line-height: 1.4;
  color: #6B5E52;
  margin-bottom: 0.35rem;
}
.story-read .response-row { margin-top: 0.75rem; }
.story-read .resp-primary .resp-label { font-size: 0.9rem; }
.story-read .resp-count { font-size: 0.95rem; }

/* v61: Share this Grace sits with the response buttons without crowding them */
.story-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem 0.5rem;
}
.story-read .story-actions { margin-top: 0.75rem; }
.story-actions .response-row,
.story-read .story-actions .response-row { margin-top: 0; }
.share-grace-btn {
  appearance: none;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  border: 1px solid #E6D3A3;
  background: linear-gradient(180deg, #FFFDF7, #FFF6E4);
  border-radius: 999px;
  padding: 0.32rem 0.75rem 0.32rem 0.5rem;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  color: #6B4A2B;
  line-height: 1.2;
}
.share-grace-btn:hover,
.share-grace-btn:focus-visible {
  border-color: #C9A24A;
  background: #FFF8E1;
}
.share-grace-btn:focus-visible {
  outline: 2px solid #C9A24A;
  outline-offset: 2px;
}
.share-grace-icon {
  width: 16px;
  height: 16px;
  color: #C9973A;
  flex: none;
}
.share-grace-label {
  white-space: nowrap;
  color: #6B4A2B;
}
.story-read .share-grace-btn { font-size: 0.86rem; padding: 0.38rem 0.8rem 0.38rem 0.55rem; }
.story-read .share-grace-icon { width: 18px; height: 18px; }

/* Photo and clip */
.popup-photo-btn {
  display: block;
  width: 100%;
  padding: 0;
  margin: 0.7rem 0 0.2rem;
  border: 0;
  background: none;
  cursor: zoom-in;
  position: relative;
}
.popup-photo-btn .popup-photo { margin: 0; }
.story-read .popup-photo {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: auto;
  max-height: 260px;
  object-fit: cover;
  border-radius: 12px;
  border: 1px solid #EBDDB8;
  background: #F7EEDC;
}
.story-read .popup-photo-btn::after {
  content: "Tap to enlarge";
  position: absolute;
  right: 8px;
  bottom: 8px;
  padding: 2px 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.9);
  color: #6B4226;
  font: 600 0.72rem/1.5 var(--font);
  border: 1px solid #E6D3A3;
}
.popup-video,
.clip-preview,
.journal-video {
  display: block;
  width: 100%;
  max-height: 260px;
  border-radius: 12px;
  border: 1px solid #EBDDB8;
  background: #F7EEDC;
  object-fit: contain;
}
.story-read .popup-video { margin: 0.7rem 0 0.2rem; max-height: 280px; }
.feather-popup:not(.story-read) .popup-video { max-height: 110px; }
.clip-preview { max-width: 420px; margin: 0.6rem 0 0.3rem; }
.clip-len { display: block; font-size: 0.8rem; margin-bottom: 0.3rem; }

/* Tap-to-enlarge photo view */
.grace-lightbox {
  position: fixed;
  inset: 0;
  z-index: 2700;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(40, 28, 16, 0.78);
  cursor: zoom-out;
}
.grace-lightbox[hidden] { display: none !important; }
.grace-lightbox img {
  max-width: min(100%, 1100px);
  max-height: 100%;
  object-fit: contain;
  border-radius: 14px;
  border: 2px solid #E8C97A;
  background: #FFFFFF;
}
.grace-lightbox .grace-sheet-close { top: 16px; right: 16px; }

/* Laptop: a roomy card centered over the map column (side panel stays readable) */
@media (min-width: 840px) {
  .grace-sheet {
    top: calc(var(--header-h, 64px) + 14px);
    left: calc((100vw - 360px) / 2);
    right: auto;
    bottom: auto;
    transform: translateX(-50%);
    width: min(460px, calc(100vw - 360px - 40px));
    max-height: calc(100dvh - var(--header-h, 64px) - 28px);
  }
}

/* Phone: keep the white-with-gold bottom sheet, just taller and easier to read */
@media (max-width: 839px) {
  .grace-sheet {
    left: 8px;
    right: 8px;
    top: auto;
    transform: none;
    width: auto;
    bottom: calc(68px + env(safe-area-inset-bottom, 0px));
    max-height: min(72dvh, 620px);
  }
  .grace-sheet-card { padding: 0.85rem 1rem 1rem; max-height: none; }
  .story-read p.story-text { font-size: 17px; line-height: 1.6; }
  .story-read .meta { font-size: 0.88rem; }
  .story-read .popup-photo { max-height: 200px; }
  .story-read .popup-video { max-height: 220px; }
}

/* OPTIONAL preview (?bigmap=1 only): a modestly larger laptop globe. Sky, rays, colors and phone are untouched. */
@media (min-width: 840px) {
  html.bigmap .welcome.map-hero { margin-bottom: 4px; }
  html.bigmap .map-circle-glow {
    --globe: min(calc(100vw - 400px), calc(100dvh - var(--header-h, 64px) - var(--map-hero-h, 110px) + 10px), 900px);
  }
  @supports (width: 1cqi) {
    html.bigmap .map-circle-glow {
      --globe: min(calc(100cqi - 16px), calc(100dvh - var(--header-h, 64px) - var(--map-hero-h, 110px) + 10px), 900px);
    }
  }
}
/* v57: short laptop screens keep the photo modest so the loving responses stay in view */
@media (min-width: 840px) and (max-height: 760px) {
  .story-read .popup-photo { max-height: 180px; }
  .story-read .popup-video { max-height: 200px; }
  .story-read p.story-text { margin: 0.65rem 0 0.6rem; }
}

/* ===== v58: no feather/color label above public stories ===== */
/* Story card: content starts below the close button (the label pill used to sit beside it). */
.grace-sheet-card { padding-top: 3.1rem; }
.story-read > .popup-photo-btn:first-of-type,
.story-read > .popup-video:first-of-type { margin-top: 0; }
.story-read > p.story-text:first-of-type { margin-top: 0; }
@media (max-width: 839px) { .grace-sheet-card { padding-top: 2.95rem; } }
/* Side-panel list: the story opens the card; a small feather + place/date line follows */
.post-card p.post-story { margin: 0 0 0.45rem; }
.post-card .post-meta { display: flex; align-items: center; gap: 0.35rem; margin-bottom: 0.4rem; }
.post-card .post-meta .marker-thumb { width: 16px; height: 22px; flex: 0 0 auto; object-fit: contain; }

/* ===== v59: second-version front page copy, Blest Journal nav fit ===== */
@media (max-width: 839px) {
  .app-nav { padding-left: 0.2rem; padding-right: 0.2rem; }
  .nav-btn { padding: 0.35rem 0.35rem; font-size: 0.66rem; white-space: nowrap; }
}
@media (min-width: 840px) {
  .welcome.map-hero,
  html.bg-gold-glitter body[data-screen="map"] .welcome.map-hero {
    width: min(920px, calc(100% - 16px));
    max-width: min(920px, calc(100% - 16px));
    margin-bottom: 12px;
  }
  .welcome.map-hero .welcome-copy { flex: 1 1 500px; }
  .welcome.map-hero h1 { font-size: 1.12rem; margin-bottom: 0.15rem; }
  .welcome.map-hero p { font-size: 0.8rem; line-height: 1.32; }
}

/* ===== v65 preview: in-button squeeze (no full-screen overlay) ===== */
.resp-primary {
  position: relative;
  overflow: visible;
  padding-top: 0.28rem;
  padding-bottom: 0.28rem;
}
.response-row,
.story-actions {
  overflow: visible;
}
.touch-icon {
  position: relative;
  display: inline-block;
  width: 36px;
  height: 36px;
  flex: 0 0 auto;
  overflow: visible;
  z-index: 1;
  pointer-events: none;
}
.story-read .touch-icon,
.grace-sheet .touch-icon {
  width: 42px;
  height: 42px;
}
.touch-icon-aura {
  position: absolute;
  left: 18%;
  top: 14%;
  width: 64%;
  height: 52%;
  border-radius: 50%;
  background: radial-gradient(ellipse at 50% 55%, rgba(255, 220, 120, 0.9) 0%, rgba(255, 230, 160, 0.45) 42%, rgba(255, 244, 210, 0) 72%);
  opacity: 0;
  transform: scale(0.86);
  will-change: transform, opacity;
  z-index: 0;
}
.touch-icon-rays {
  position: absolute;
  left: 50%;
  top: 42%;
  width: 230%;
  height: 230%;
  background: url("../assets/responses/burst/rays.webp?v=109") center / contain no-repeat;
  opacity: 0;
  transform: translate(-50%, -42%) scale(0.72);
  transform-origin: 50% 42%;
  will-change: transform, opacity;
  z-index: 1;
  pointer-events: none;
}
.touch-icon-heart,
.touch-icon-hands {
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  pointer-events: none;
  will-change: transform;
}
.touch-icon-heart { transform-origin: 49.8% 30.5%; z-index: 2; }
.touch-icon-hands { transform-origin: 50% 88.4%; z-index: 3; }

/* A little room so rays can shimmer out around the icon without feeling like a jump */
.story-read .story-actions,
.grace-sheet .story-actions,
.post-card .response-row {
  padding-top: 0.35rem;
  padding-bottom: 0.45rem;
}

.touch-icon.is-playing { z-index: 4; }
.touch-icon.is-playing .touch-icon-hands {
  animation: ti-hands 2.5s linear both;
}
.touch-icon.is-playing .touch-icon-heart {
  animation: ti-heart 2.5s linear both;
}
.touch-icon.is-playing .touch-icon-aura {
  animation: ti-aura 2.5s linear both;
}
.touch-icon.is-playing .touch-icon-rays {
  animation: ti-rays 2.5s linear both;
}

@keyframes ti-hands {
  0%, 6% { transform: scaleX(1); }
  18% { transform: scaleX(0.990); }
  28% { transform: scaleX(0.953); }
  40% { transform: scaleX(0.857); }
  50% { transform: scaleX(0.774); }
  60% { transform: scaleX(0.74); }
  72% { transform: scaleX(0.813); }
  84% { transform: scaleX(0.927); }
  92% { transform: scaleX(0.984); }
  97%, 100% { transform: scaleX(1); }
}
@keyframes ti-heart {
  0%, 18% { transform: scale(1, 1); }
  40% { transform: scale(0.984, 1.009); }
  55% { transform: scale(0.965, 1.020); }
  62% { transform: scale(0.981, 1.011); }
  66% { transform: scale(1.045, 1.025); }
  76% { transform: scale(1.009, 1.005); }
  88%, 100% { transform: scale(1, 1); }
}
@keyframes ti-aura {
  0%, 6% { opacity: 0; transform: scale(0.86); }
  18% { opacity: 0.75; transform: scale(1); }
  28%, 62% { opacity: 1; transform: scale(1.12); }
  84% { opacity: 0.45; transform: scale(1.02); }
  93% { opacity: 0.08; transform: scale(0.96); }
  100% { opacity: 0; transform: scale(0.9); }
}
@keyframes ti-rays {
  0%, 10% { opacity: 0; transform: translate(-50%, -42%) scale(0.72) rotate(0deg); }
  20% { opacity: 0.12; transform: translate(-50%, -42%) scale(0.80) rotate(0.2deg); }
  32% { opacity: 0.38; transform: translate(-50%, -42%) scale(0.90) rotate(-0.3deg); }
  40% { opacity: 0.62; transform: translate(-50%, -42%) scale(0.96) rotate(0.4deg); }
  50% { opacity: 1; transform: translate(-50%, -42%) scale(1) rotate(-0.2deg); }
  54% { opacity: 0.92; transform: translate(-50%, -42%) scale(1.04) rotate(0.5deg); }
  60% { opacity: 0.82; transform: translate(-50%, -42%) scale(1.02) rotate(-0.3deg); }
  72% { opacity: 0.48; transform: translate(-50%, -42%) scale(0.96) rotate(0.4deg); }
  84% { opacity: 0.20; transform: translate(-50%, -42%) scale(0.88) rotate(-0.2deg); }
  93% { opacity: 0.04; transform: translate(-50%, -42%) scale(0.80) rotate(0deg); }
  100% { opacity: 0; transform: translate(-50%, -42%) scale(0.76) rotate(0deg); }
}

@media (prefers-reduced-motion: reduce) {
  .touch-icon.is-playing .touch-icon-hands,
  .touch-icon.is-playing .touch-icon-heart,
  .touch-icon.is-playing .touch-icon-rays {
    animation: none !important;
  }
  .touch-icon.is-playing .touch-icon-hands,
  .touch-icon.is-playing .touch-icon-heart { transform: none; }
  .touch-icon.is-playing .touch-icon-rays { opacity: 0 !important; }
  .touch-icon.is-playing .touch-icon-aura {
    animation: ti-glow-soft 1.2s ease-in-out both;
  }
}
@keyframes ti-glow-soft {
  0% { opacity: 0; transform: scale(0.9); }
  35% { opacity: 0.95; transform: scale(1.16); }
  70% { opacity: 0.7; transform: scale(1.08); }
  100% { opacity: 0; transform: scale(1); }
}

/* v65: keep the phone toast above the open story sheet so it doesn't cover Touched */
@media (max-width: 839px) {
  body.grace-sheet-open .toast {
    bottom: auto;
    top: calc(var(--header-h, 64px) + 10px);
    transform: translateX(-50%) translateY(-12px);
  }
  body.grace-sheet-open .toast.show {
    transform: translateX(-50%);
  }
  /* Longer journal line stays compact under the globe */
  body[data-screen="map"] #map-home .journal-invite {
    padding: 0.45rem 0.7rem;
  }
  body[data-screen="map"] #map-home .journal-invite-text {
    font-size: 0.76rem;
    line-height: 1.32;
  }
}
.welcome-copy .welcome-tap{margin-top:2px;opacity:.9;font-size:.95em}
/* v65: counter pill a subtle bump for readability */
.welcome.map-hero .grace-counter { padding: 4px 14px; font-size: 0.82rem; gap: 0.4rem; }
.welcome.map-hero .grace-counter b { font-size: 0.95rem; }
.welcome.map-hero .grace-counter .pulse { width: 8px; height: 8px; }
html.bg-gold-glitter body[data-screen="map"] .welcome.map-hero .grace-counter {
  background: rgba(30,18,10,.72); border-color: rgba(232,201,122,.7); color: #FFF8E8;
}
html body .welcome.map-hero .grace-counter { flex-wrap: nowrap !important; white-space: nowrap; }
@media (max-width: 400px) { .welcome.map-hero .grace-counter { font-size: 0.78rem; padding: 4px 12px; } .welcome.map-hero .grace-counter b { font-size: 0.9rem; } }
@media (max-width: 380px) { .welcome.map-hero .grace-counter { font-size: 0.72rem; padding: 4px 10px; gap: .3rem; } .welcome.map-hero .grace-counter b { font-size: 0.84rem; } }
@media (min-width: 840px) { .welcome.map-hero .welcome-copy { flex: 1 1 200px; } .welcome.map-hero { flex-wrap: nowrap; } .welcome.map-hero .grace-counter { flex: 0 0 auto; } }
/* v65: quieter counter */
.welcome.map-hero .grace-counter { font-size: 0.74rem !important; padding: 3px 12px; }
.welcome.map-hero .grace-counter b { font-size: 0.74rem !important; font-weight: 700; }
.welcome.map-hero .grace-counter .pulse { width: 6px; height: 6px; }
html.bg-gold-glitter body[data-screen="map"] .welcome.map-hero .grace-counter { background: rgba(30,18,10,.35); border: 1px solid rgba(232,201,122,.4); color: #F6EBD3; }
/* v65: two-word legend fits on one line */
.feather-legend li span b { white-space: nowrap; }
@media (max-width: 839px) { .feather-legend ul { grid-template-columns: repeat(2, minmax(0,1fr)) !important; } .feather-legend li span b { font-size: .95rem; } }
.legend-in-panel ul { grid-template-columns: repeat(2, minmax(0,1fr)) !important; }
/* v65: more notice for the dedication line */
body[data-screen="map"] #map-home .map-dedication { font-size: 0.95rem !important; color: #6B4A26; font-weight: 600; text-shadow: 0 1px 2px rgba(255,250,235,.85); }
@media (min-width: 840px) { body[data-screen="map"] #map-home .map-dedication { max-width: min(260px, calc((100% - var(--globe, 416px)) / 2 - 12px)); bottom: 14px; left: 14px; } }
@media (max-width: 839px) { body[data-screen="map"] #map-home .map-dedication { margin: 8px auto 6px; font-size: 0.92rem !important; } }
html.bg-gold-glitter body[data-screen="map"] #map-home .map-dedication { color: #FFE9B3; text-shadow: 0 1px 4px rgba(12,6,2,.9); }
/* intro subtitle */
h1 .h1-sub{font-size:.62em;font-weight:500;white-space:nowrap;opacity:.85}
/* bigger Moments of Grace subtitle */
h1 .h1-sub{font-size:.85em !important;font-weight:600 !important;opacity:1 !important}
/* touch cue: script line above the globe on phones */
.touch-cue{display:none}
@media (max-width: 839px){
  body[data-screen="map"] #map-home .welcome-tap{display:none !important}
  body[data-screen="map"] #map-home .touch-cue{display:block;margin:.35rem auto -.1rem;text-align:center;font-family:var(--script),"Dancing Script",cursive;font-weight:600;font-size:1.3rem;color:#A87A2A;text-shadow:0 1px 2px rgba(255,250,235,.9);line-height:1.2}
  html.bg-gold-glitter body[data-screen="map"] #map-home .touch-cue{color:#FFE9B3;text-shadow:0 1px 3px rgba(40,20,5,.6)}
}
/* laptop: balanced intro line break */
@media (max-width: 839px){ .lap-br{display:none} }


/* ===== v68 Option C: restore the older flowing intro (no stacked lines, no box over the globe) ===== */
/* Italic cue stays inline at the end of the single paragraph on laptops */
.welcome-copy .welcome-tap,
.welcome.map-hero .welcome-tap {
  display: inline;
  margin: 0;
  font-size: inherit;
  font-style: italic;
  opacity: 0.95;
}
@media (min-width: 840px) {
  .welcome.map-hero,
  html.bg-sunlit body[data-screen="map"] .welcome.map-hero,
  html.bg-gold-glitter body[data-screen="map"] .welcome.map-hero {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: center;
    justify-content: flex-start;
    text-align: left;
    width: min(920px, calc(100% - 16px));
    max-width: min(920px, calc(100% - 16px));
    margin: 0 auto 12px;
    padding: 0.4rem 0.9rem;
    gap: 0.5rem 1rem;
    box-sizing: border-box;
    overflow-wrap: normal;
    word-break: normal;
  }
  .welcome.map-hero .welcome-copy {
    flex: 1 1 auto;
    min-width: 0;
  }
  .welcome.map-hero h1 {
    font-size: 1.12rem;
    margin: 0 0 0.18rem;
    line-height: 1.25;
  }
  .welcome.map-hero p {
    font-size: 0.8rem;
    line-height: 1.4;
    margin: 0;
  }
  /* Keep the italic cue with the end of the sentence so it never becomes its own leftover line */
  .welcome.map-hero .welcome-tap { white-space: nowrap; }
  .welcome.map-hero .grace-counter {
    flex: 0 0 auto;
    align-self: center;
    margin: 0 !important;
  }
}
/* Phone: hide the inline italic so it does not duplicate the gold script touch-cue */
@media (max-width: 839px) {
  body[data-screen="map"] #map-home .welcome-tap { display: none !important; }
}


/* ===== v69 Option D: italic cue on its own tight line under the paragraph (laptop only) ===== */
@media (min-width: 840px) {
  .welcome-copy .welcome-tap,
  .welcome.map-hero .welcome-tap,
  body[data-screen="map"] #map-home .welcome-tap {
    display: block;
    margin: 0.12rem 0 0;
    padding: 0;
    font-size: 0.8rem;
    line-height: 1.35;
    font-style: italic;
    opacity: 0.95;
    white-space: nowrap;
    background: none;
    border: 0;
    box-shadow: none;
  }
}
@media (max-width: 839px) {
  body[data-screen="map"] #map-home .welcome-tap { display: none !important; }
}


/* ===== v70 Option E: gold script cue on laptop, softer dedication, sidebar invitation ===== */
@media (min-width: 840px) {
  .welcome-copy .welcome-tap,
  .welcome.map-hero .welcome-tap,
  body[data-screen="map"] #map-home .welcome-tap {
    display: block;
    margin: 0.18rem 0 0;
    padding: 0;
    font-family: var(--script), "Dancing Script", cursive;
    font-weight: 600;
    font-style: normal;
    font-size: 1.35rem;
    line-height: 1.2;
    color: #A87A2A;
    text-shadow: 0 1px 2px rgba(255, 250, 235, 0.9);
    opacity: 1;
    white-space: nowrap;
    background: none;
    border: 0;
    box-shadow: none;
  }
  .welcome.map-hero .welcome-tap em {
    font-family: inherit;
    font-style: normal;
    font-weight: inherit;
    color: inherit;
  }
  html.bg-gold-glitter body[data-screen="map"] #map-home .welcome-tap {
    color: #FFE9B3;
    text-shadow: 0 1px 3px rgba(40, 20, 5, 0.6);
  }
}
@media (max-width: 839px) {
  body[data-screen="map"] #map-home .welcome-tap { display: none !important; }
}

/* Dedication: keep the larger size, restore the earlier soft golden-brown (#8A7356, v56) */
body[data-screen="map"] #map-home .map-dedication {
  color: #8A7356;
  text-shadow: 0 1px 2px rgba(255, 250, 235, 0.85);
}
html.bg-gold-glitter body[data-screen="map"] #map-home .map-dedication {
  color: #E6D4A4;
  text-shadow: 0 1px 3px rgba(12, 6, 2, 0.7);
}

/* Invitation card: cream with gold border, sits at the top of the sidebar on laptops */
.join-invite {
  display: block;
  text-decoration: none;
  color: #6B4226;
  background: #FFF9F2;
  border: 1.5px solid #C9A24A;
  border-radius: 14px;
  padding: 0.7rem 0.85rem 0.75rem;
  box-shadow: 0 2px 10px rgba(90, 62, 36, 0.10);
  box-sizing: border-box;
  cursor: default;
}
.join-invite:hover {
  background: #FFF9F2;
  border-color: #C9A24A;
}
.join-invite-title {
  margin: 0 0 0.3rem;
  font-family: var(--script), "Dancing Script", cursive;
  font-weight: 600;
  font-size: 1.42rem;
  line-height: 1.2;
  color: #A87A2A;
  text-align: left;
  letter-spacing: 0;
}
.join-invite-text {
  margin: 0;
  font: 500 0.82rem/1.4 var(--font);
  color: #6B4226;
  text-align: left;
}
.join-invite-btn {
  display: block;
  width: 100%;
  margin: 0.55rem 0 0.4rem;
  text-align: center;
  box-sizing: border-box;
  cursor: pointer;
}
.join-invite-note {
  margin: 0;
  font: 500 0.72rem/1.35 var(--font);
  color: #8A7356;
  text-align: left;
}
.join-invite-journal {
  margin: 0.22rem 0 0;
  font: 500 0.72rem/1.35 var(--font);
  color: #8A7356;
  text-align: left;
}
.join-invite-journal a {
  color: #6B4226;
  font-weight: 700;
  text-decoration: underline;
  text-decoration-color: rgba(201, 162, 74, 0.7);
  text-underline-offset: 2px;
}
.join-invite-journal a:hover { color: #8B5E3C; }

@media (min-width: 840px) {
  aside.panel > .join-invite {
    margin: 0 0 12px;
    width: 100%;
  }
}
@media (max-width: 839px) {
  body[data-screen="map"] #map-home .join-invite {
    width: min(100%, 420px);
    margin: 6px auto 8px;
    padding: 0.65rem 0.8rem 0.7rem;
    scroll-margin-top: calc(var(--header-h, 64px) + 12px);
    scroll-margin-bottom: calc(4.75rem + env(safe-area-inset-bottom, 0px));
  }
}

html.bg-gold-glitter body[data-screen="map"] #map-home .join-invite,
html.bg-gold-glitter aside.panel > .join-invite {
  background: rgba(255, 253, 248, 0.94);
  border-color: #C9A24A;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.28);
}


/* ===== v71 Option F: centered intro; counter mirrors the dedication at the bottom of the map pane ===== */
@media (min-width: 840px) {
  .welcome.map-hero,
  html.bg-sunlit body[data-screen="map"] .welcome.map-hero,
  html.bg-gold-glitter body[data-screen="map"] .welcome.map-hero {
    display: flex;
    flex-direction: column;
    flex-wrap: nowrap;
    align-items: center;
    justify-content: flex-start;
    text-align: center;
    width: min(700px, calc(100% - 24px));
    max-width: min(700px, calc(100% - 24px));
    margin: 2px auto 10px;
    padding: 0.45rem 1.1rem 0.5rem;
    gap: 0;
    box-sizing: border-box;
  }
  .welcome.map-hero .welcome-copy {
    flex: 0 1 auto;
    width: 100%;
    max-width: 100%;
  }
  .welcome.map-hero h1 {
    font-size: 1.12rem;
    margin: 0 0 0.18rem;
    line-height: 1.25;
  }
  .welcome.map-hero p {
    font-size: 0.8rem;
    line-height: 1.4;
    margin: 0;
    text-align: center;
  }
  .welcome-copy .welcome-tap,
  .welcome.map-hero .welcome-tap,
  body[data-screen="map"] #map-home .welcome-tap {
    text-align: center;
  }
}

/* Show the counter as a sibling of the globe again */
#map-home .map-wrap > .grace-counter {
  display: flex !important;
  align-items: center;
  gap: 0.35rem;
  width: fit-content;
  max-width: 100%;
  margin: 0;
  padding: 3px 12px;
  font-size: 0.74rem;
  font-weight: 500;
  white-space: nowrap;
  box-sizing: border-box;
  box-shadow: 0 1px 6px rgba(201, 151, 58, 0.15);
}
#map-home .map-wrap > .grace-counter b {
  font-size: 0.74rem;
  font-weight: 700;
}
#map-home .map-wrap > .grace-counter .pulse { width: 6px; height: 6px; }

@media (min-width: 840px) {
  body[data-screen="map"] #map-home .map-wrap > .grace-counter {
    position: absolute;
    right: 14px;
    bottom: 14px;
    left: auto;
    z-index: 4;
    margin: 0 !important;
    align-self: auto !important;
    text-align: right;
    justify-content: flex-end;
    line-height: 1.3;
    /* Wide laptops: one quiet line in the right-hand sky */
    white-space: nowrap;
    max-width: none;
  }
}
/* Narrow laptops: a tidy two-line pill in the lower-right corner, outside the globe */
@media (min-width: 840px) and (max-width: 1199px) {
  body[data-screen="map"] #map-home .map-wrap > .grace-counter {
    display: block !important;
    white-space: normal;
    max-width: 148px;
    text-align: right;
    line-height: 1.3;
  }
  body[data-screen="map"] #map-home .map-wrap > .grace-counter .pulse {
    display: inline-block;
    vertical-align: middle;
    margin-right: 0.3rem;
  }
}

@media (max-width: 839px) {
  body[data-screen="map"] #map-home .map-wrap > .grace-counter {
    position: static;
    align-self: center !important;
    margin: 4px auto 8px !important;
    justify-content: center;
    white-space: nowrap;
  }
}
@media (max-width: 400px) {
  #map-home .map-wrap > .grace-counter { font-size: 0.7rem; padding: 3px 10px; }
  #map-home .map-wrap > .grace-counter b { font-size: 0.7rem; }
}

html.bg-gold-glitter body[data-screen="map"] #map-home .map-wrap > .grace-counter {
  color: #F6EBD3;
  background: rgba(30, 18, 10, 0.35);
  border: 1px solid rgba(232, 201, 122, 0.4);
  text-shadow: 0 1px 2px #1B1006;
}


/* ===== v72 Option G: even-weight headline; shorter warmer intro ===== */
.ph-br { display: none; }
@media (max-width: 839px) {
  .ph-br { display: block; }
}
.welcome.map-hero h1,
.welcome.map-hero h1 .h1-sub {
  font-size: inherit;
  font-weight: 700;
  opacity: 1;
  white-space: normal;
}
@media (min-width: 840px) {
  .welcome.map-hero h1 {
    font-size: 1.12rem;
    font-weight: 700;
    letter-spacing: 0;
    white-space: nowrap;
  }
}
@media (max-width: 839px) {
  .welcome.map-hero h1 {
    font-size: 1.12rem;
    font-weight: 700;
    line-height: 1.25;
    white-space: normal;
  }
}

/* ===== v77 Option L: winged-cross welcome moment, and a gentle flip into Prayer ===== */

/* First-visit welcome: a soft white veil over the whole site, no box on the map */
html.welcome-pending,
html.welcome-pending body,
body.welcome-open {
  overflow: hidden;
}
.welcome-moment {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 4000;
  align-items: center;
  justify-content: center;
  background: #FFFFFF;
  opacity: 1;
  /* v112: soft 1.4s melt — ease-in-out fade, slight bloom, scene shows through */
  transition: opacity 1.4s ease-in-out, filter 1.4s ease-in-out, background-color 1.4s ease-in-out;
  filter: blur(0) brightness(1);
}
html.welcome-pending .welcome-moment,
.welcome-moment.is-open {
  display: flex;
}
.welcome-moment.is-leaving {
  opacity: 0;
  pointer-events: none;
  background-color: rgba(255, 255, 255, 0);
  filter: blur(8px) brightness(1.18);
}
.welcome-moment-stage {
  position: relative;
  width: min(92vw, 46vh);
  height: min(92vw, 46vh);
  max-width: 560px;
  max-height: 560px;
}
.welcome-moment-still,
.welcome-moment-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  background: transparent;
  pointer-events: none;
}
.welcome-moment-video {
  z-index: 1;
}
button.welcome-skip {
  position: absolute;
  top: max(14px, env(safe-area-inset-top, 0px));
  right: max(16px, env(safe-area-inset-right, 0px));
  appearance: none;
  -webkit-appearance: none;
  background: transparent;
  border: 0;
  box-shadow: none;
  margin: 0;
  padding: 8px 10px;
  font: 500 0.92rem/1 var(--font);
  color: #8A7356;
  letter-spacing: 0.02em;
  cursor: pointer;
  opacity: 0.88;
  z-index: 2;
  border-radius: 0;
}
button.welcome-skip:hover {
  opacity: 1;
  text-decoration: underline;
  text-underline-offset: 3px;
}
button.welcome-skip:focus-visible {
  outline: none;
  text-decoration: underline;
  text-underline-offset: 3px;
  opacity: 1;
}

/* v80: Turn to Prayer is a clear Prayer-side pill in the sky at the globe's upper right */
@keyframes prayer-shimmer {
  0% { background-position: 120% 0; }
  100% { background-position: -20% 0; }
}
button.prayer-turn {
  appearance: none;
  -webkit-appearance: none;
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  margin: 0 auto;
  padding: 0.42rem 1.15rem 0.48rem 0.8rem;
  border: 1.5px solid #C9A24B;
  border-radius: 999px;
  background: linear-gradient(180deg, #4A2E1C 0%, #3A2418 46%, #2A1A10 100%);
  box-shadow:
    0 2px 10px rgba(42, 26, 16, 0.3),
    0 0 0 1px rgba(201, 162, 75, 0.18);
  color: #E8C97A;
  font-family: var(--script), "Dancing Script", cursive;
  font-weight: 600;
  font-size: 1.28rem;
  line-height: 1.15;
  white-space: nowrap;
  cursor: pointer;
  z-index: 6;
  overflow: hidden;
}
button.prayer-turn > * { position: relative; z-index: 1; }
button.prayer-turn .prayer-turn-glyph {
  display: block;
  width: 1.35rem;
  height: 1.35rem;
  object-fit: contain;
  filter: drop-shadow(0 0 3px rgba(232, 201, 122, 0.55));
  flex: 0 0 auto;
}
button.prayer-turn::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(110deg, transparent 35%, rgba(255, 232, 170, 0.28) 50%, transparent 65%);
  background-size: 220% 100%;
  animation: prayer-shimmer 4.8s ease-in-out infinite;
  pointer-events: none;
  z-index: 0;
}
button.prayer-turn:hover {
  color: #FFE9B3;
  border-color: #E2B33C;
  box-shadow:
    0 0 16px rgba(232, 201, 122, 0.55),
    0 0 28px rgba(201, 162, 75, 0.32),
    0 2px 10px rgba(42, 26, 16, 0.3);
}
button.prayer-turn:focus-visible {
  outline: none;
  color: #FFE9B3;
  border-color: #F0D78A;
  box-shadow:
    0 0 0 2px rgba(255, 249, 242, 0.9),
    0 0 16px rgba(232, 201, 122, 0.55);
}
@media (prefers-reduced-motion: reduce) {
  button.prayer-turn::after { animation: none; background: none; }
}

@media (min-width: 840px) {
  /* Open sky at the top right of the globe, just below the intro box. Out of the globe's flow. */
  body[data-screen="map"] #map-home .prayer-turn {
    position: absolute;
    top: 130px;
    left: 50%;
    right: auto;
    bottom: auto;
    transform: translateX(140px);
    margin: 0;
    font-size: 1.32rem;
    padding: 0.44rem 1.2rem 0.5rem 0.85rem;
  }
}
/* Narrow laptops: tuck the pill at the globe's upper right, inside the map column */
@media (min-width: 840px) and (max-width: 1199px) {
  body[data-screen="map"] #map-home .prayer-turn {
    left: auto;
    right: 14px;
    transform: none;
    font-size: 1.18rem;
    padding: 0.38rem 1rem 0.42rem 0.72rem;
  }
  body[data-screen="map"] #map-home .prayer-turn .prayer-turn-glyph {
    width: 1.2rem;
    height: 1.2rem;
  }
}
@media (max-width: 839px) {
  /* Centered just under the globe; first thing below it, still on the first screen */
  body[data-screen="map"] #map-home .prayer-turn {
    order: 2;
    position: static;
    transform: none;
    margin: 8px auto 6px;
    font-size: 1.22rem;
  }
  body[data-screen="map"] #map-home .map-circle-glow { order: 1; }
  body[data-screen="map"] #map-home .map-dedication { order: 3; }
  body[data-screen="map"] #map-home .map-wrap > .grace-counter { order: 4; }
  body[data-screen="map"] #map-home .join-invite,
  body[data-screen="map"] #map-home .journal-invite { order: 5; }
  body[data-screen="map"] #map-home .feather-legend { order: 7; }
}

/* Full-screen Prayer: a warm brown bloom from the tap, then the Prayer view */
.prayer-flip {
  --bloom-x: 50%;
  --bloom-y: 50%;
  position: fixed;
  inset: 0;
  z-index: 3500;
  pointer-events: none;
  opacity: 1;
  background: transparent;
}
.prayer-flip.is-open {
  display: block;
  pointer-events: auto;
}
.prayer-stage {
  position: absolute;
  inset: 0;
  clip-path: circle(0px at var(--bloom-x) var(--bloom-y));
  transition: clip-path 0.8s ease-in-out;
  background: transparent;
}
.prayer-flip.is-bloomed .prayer-stage {
  clip-path: circle(160vmax at var(--bloom-x) var(--bloom-y));
}
.prayer-bloom {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background: radial-gradient(circle at var(--bloom-x) var(--bloom-y),
    #8A5E3B 0%, #5C3A22 48%, #4A2E1C 100%);
}
/* The old cream glow is folded into the halo/cross on brown — hide it to avoid a white flash. */
.prayer-glow {
  display: none;
}
.prayer-view {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  padding: 2rem 1.5rem 3rem;
  text-align: center;
  box-sizing: border-box;
  /* Bloom supplies the opaque brown; glitter fades in later at the edges. */
  background: transparent;
  overflow: hidden;
  opacity: 1;
  z-index: 1;
  isolation: isolate;
}
.prayer-gold-background {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
  background: #1B1006 url("../assets/bg/gold-glitter-poster.jpg") center / cover no-repeat;
  opacity: 0;
  transition: opacity 0.4s ease 0s;
}
.prayer-flip.is-revealed .prayer-gold-background {
  opacity: 1;
  transition: opacity 0.7s ease 0.75s;
}
.prayer-gold-video {
  position: absolute;
  inset: -4px;
  width: calc(100% + 8px);
  height: calc(100% + 8px);
  object-fit: cover;
  object-position: center;
  filter: blur(2.2px);
  opacity: 0.8;
}
/* Warm brown veil: solid and calm where the content sits, fading so glitter
   remains visible around the outer area. Colors match the header nav browns. */
.prayer-brown-veil {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background:
    radial-gradient(ellipse 58% 62% at 50% 46%,
      rgba(74, 46, 28, 0.96) 0%,
      rgba(92, 58, 34, 0.92) 32%,
      rgba(138, 94, 59, 0.62) 54%,
      rgba(92, 58, 34, 0.28) 74%,
      rgba(74, 46, 28, 0.08) 100%);
}
.prayer-view > *:not(.prayer-gold-background):not(.prayer-brown-veil):not(.prayer-light-cross):not(.prayer-page):not(.prayer-entry):not(.prayer-rays) {
  position: relative;
  z-index: 3;
}
#prayer-map,
.map-circle-glow > #prayer-map {
  width: 100% !important;
  height: 100% !important;
  aspect-ratio: 1 / 1;
  border-radius: 50%;
  overflow: hidden;
}
.prayer-emblem-wrap {
  position: relative;
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 0 0.35rem;
  isolation: isolate;
}
.prayer-rays {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 220vmin;
  height: 220vmin;
  transform: translate(-50%, -50%) scale(0.6) rotate(-12deg);
  opacity: 0;
  pointer-events: none;
  z-index: 0;
  transition: opacity 0.4s ease 0.08s, transform 0.45s ease 0.08s;
}
.prayer-flip.is-revealed .prayer-rays {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1) rotate(0deg);
  transition: opacity 0.65s ease 0s, transform 0.7s ease 0s;
}
.prayer-rays-spin {
  position: absolute;
  inset: 0;
  background: repeating-conic-gradient(
    from 0.25turn at 50% 50%,
    rgba(232, 201, 122, 0) 0deg,
    rgba(201, 162, 75, 0.07) 4deg,
    rgba(232, 201, 122, 0.22) 6.5deg,
    rgba(201, 162, 75, 0.08) 9deg,
    rgba(232, 201, 122, 0) 15deg
  );
  -webkit-mask-image: radial-gradient(circle at 50% 50%,
    rgba(0, 0, 0, 0.7) 0%,
    rgba(0, 0, 0, 0.4) 22%,
    rgba(0, 0, 0, 0.12) 48%,
    rgba(0, 0, 0, 0) 66%);
  mask-image: radial-gradient(circle at 50% 50%,
    rgba(0, 0, 0, 0.7) 0%,
    rgba(0, 0, 0, 0.4) 22%,
    rgba(0, 0, 0, 0.12) 48%,
    rgba(0, 0, 0, 0) 66%);
}
.prayer-flip.is-revealed .prayer-rays-spin {
  animation: prayer-rays-spin 120s linear infinite;
}
@keyframes prayer-rays-spin {
  to { transform: rotate(360deg); }
}
.prayer-halo {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 42vh;
  height: 42vh;
  max-width: 70vw;
  max-height: 70vw;
  transform: translate(-50%, -50%) scale(0.7);
  opacity: 0;
  pointer-events: none;
  z-index: 1;
  background: radial-gradient(circle,
    rgba(255, 246, 212, 0.62) 0%,
    rgba(232, 201, 122, 0.4) 28%,
    rgba(201, 162, 75, 0.16) 52%,
    rgba(201, 162, 75, 0) 72%);
  transition: opacity 0.35s ease 0.05s, transform 0.35s ease 0.05s;
}
.prayer-flip.is-revealed .prayer-halo {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
  transition: opacity 0.5s ease 0.2s, transform 0.55s ease 0.2s;
}
.prayer-emblem {
  position: relative;
  z-index: 2;
  display: block;
  height: 18vh;
  width: auto;
  max-width: 46vw;
  opacity: 0;
  transform: scale(0.92);
  filter:
    drop-shadow(0 0 14px rgba(255, 236, 170, 0.7))
    drop-shadow(0 2px 8px rgba(20, 10, 4, 0.65));
  transition: opacity 0.35s ease 0.05s, transform 0.35s ease 0.05s;
}
.prayer-flip.is-revealed .prayer-emblem {
  opacity: 1;
  transform: scale(1);
  transition: opacity 0.5s ease 0.3s, transform 0.55s ease 0.3s;
}
.prayer-title {
  margin: 0;
  font-family: "Cormorant Garamond", "Palatino Linotype", Palatino, Georgia, serif;
  font-weight: 600;
  font-style: italic;
  font-size: clamp(2.4rem, 7vw, 4rem);
  letter-spacing: 0.045em;
  line-height: 1.1;
  color: #FFF6D4;
  text-shadow: 0 1px 2px rgba(20, 10, 4, 0.9), 0 2px 10px rgba(12, 6, 2, 0.55);
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.3s ease 0.04s, transform 0.3s ease 0.04s;
}
.prayer-flip.is-revealed .prayer-title {
  opacity: 1;
  transform: none;
  transition: opacity 0.5s ease 0.45s, transform 0.5s ease 0.45s;
}
.prayer-placeholder {
  margin: 0.2rem auto 1.15rem;
  max-width: 30rem;
  font: 500 1.2rem/1.6 var(--font);
  color: #FFF8E8;
  text-transform: none;
  text-shadow: 0 1px 2px rgba(20, 10, 4, 0.85), 0 2px 8px rgba(12, 6, 2, 0.45);
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 0.3s ease 0.04s, transform 0.3s ease 0.04s;
}
.prayer-flip.is-revealed .prayer-placeholder {
  opacity: 1;
  transform: none;
  transition: opacity 0.5s ease 0.58s, transform 0.5s ease 0.58s;
}
.prayer-ph-tag {
  font-weight: 700;
  letter-spacing: 0.02em;
  color: #F0D78A;
}
button.prayer-back {
  appearance: none;
  -webkit-appearance: none;
  background: transparent;
  border: 0;
  box-shadow: none;
  padding: 0.35rem 0.65rem;
  font-family: var(--script), "Dancing Script", cursive;
  font-weight: 600;
  font-size: 1.5rem;
  color: #F3DE9A;
  cursor: pointer;
  text-shadow: 0 1px 2px rgba(20, 10, 4, 0.9), 0 2px 8px rgba(12, 6, 2, 0.45);
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 0.3s ease 0.04s, transform 0.3s ease 0.04s, color 0.2s ease;
}
.prayer-flip.is-revealed button.prayer-back {
  opacity: 1;
  transform: none;
  transition: opacity 0.45s ease 0.7s, transform 0.45s ease 0.7s, color 0.2s ease;
}
button.prayer-back:hover { color: #FFF1C7; }
button.prayer-back:focus-visible {
  outline: none;
  text-decoration: underline;
  text-underline-offset: 4px;
  color: #FFF1C7;
}

@media (prefers-reduced-motion: reduce) {
  .welcome-moment,
  .welcome-moment.is-leaving {
    transition: opacity 0.45s ease !important;
    filter: none !important;
  }
  .prayer-flip {
    opacity: 0;
    transition: opacity 0.45s ease;
  }
  .prayer-flip.is-open { opacity: 1; }
  .prayer-stage,
  .prayer-flip.is-bloomed .prayer-stage {
    clip-path: none !important;
    transition: none !important;
  }
  .prayer-gold-background,
  .prayer-rays,
  .prayer-halo,
  .prayer-emblem,
  .prayer-title,
  .prayer-placeholder,
  button.prayer-back {
    transition: opacity 0.45s ease !important;
    transform: none !important;
  }
  .prayer-rays-spin { animation: none !important; }
}

@font-face { font-family: "Cormorant Garamond"; src: url("../vendor/fonts/CormorantGaramond-400.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Cormorant Garamond"; src: url("../vendor/fonts/CormorantGaramond-400-italic.woff2") format("woff2"); font-weight: 400; font-style: italic; font-display: swap; }
@font-face { font-family: "Cormorant Garamond"; src: url("../vendor/fonts/CormorantGaramond-400.woff2") format("woff2"); font-weight: 500; font-style: normal; font-display: swap; }
@font-face { font-family: "Cormorant Garamond"; src: url("../vendor/fonts/CormorantGaramond-400-italic.woff2") format("woff2"); font-weight: 500; font-style: italic; font-display: swap; }
@font-face { font-family: "Cormorant Garamond"; src: url("../vendor/fonts/CormorantGaramond-600.woff2") format("woff2"); font-weight: 600; font-style: normal; font-display: swap; }
@font-face { font-family: "Cormorant Garamond"; src: url("../vendor/fonts/CormorantGaramond-600-italic.woff2") format("woff2"); font-weight: 600; font-style: italic; font-display: swap; }
@font-face { font-family: "Cormorant Garamond"; src: url("../vendor/fonts/CormorantGaramond-700.woff2") format("woff2"); font-weight: 700; font-style: normal; font-display: swap; }
@font-face { font-family: "Cormorant Garamond"; src: url("../vendor/fonts/CormorantGaramond-700-italic.woff2") format("woff2"); font-weight: 700; font-style: italic; font-display: swap; }

/* ===== v81 N1: lighter, graceful Cormorant Garamond headline ===== */
/* ===== v82: raise the headline to 600 so its stroke sits closer to the body text ===== */
/* Line-box is locked to the v80 height so the globe does not shrink or move. */
.welcome.map-hero h1,
.welcome.map-hero h1 .h1-grace,
.welcome.map-hero h1 .h1-sub {
  font-family: "Cormorant Garamond", "Palatino Linotype", Palatino, Georgia, serif;
  font-weight: 600;
  font-style: normal;
  letter-spacing: 0.04em;
}
.welcome.map-hero h1 .h1-grace {
  font-style: italic;
  font-weight: 600;
  letter-spacing: 0.045em;
  opacity: 1;
}
@media (min-width: 840px) {
  .welcome.map-hero h1 {
    font-size: 1.36rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    line-height: 1.4rem;
    white-space: nowrap;
    margin: 0 0 0.18rem;
  }
}
@media (max-width: 839px) {
  .welcome.map-hero h1 {
    font-size: 1.22rem;
    font-weight: 600;
    letter-spacing: 0.03em;
    line-height: 1.4rem;
    white-space: normal;
  }
}


/* ===== v81: Turn to Prayer is grounded low, centered beneath the globe like soil under the sunlight ===== */
/* Absolutely placed so the globe keeps its current size and position. */
@media (min-width: 840px) {
  body[data-screen="map"] #map-home .prayer-turn {
    position: absolute;
    top: auto;
    left: 50%;
    right: auto;
    bottom: 12px;
    transform: translateX(-50%);
    margin: 0;
    font-size: 1.32rem;
    padding: 0.44rem 1.2rem 0.5rem 0.85rem;
  }
}
@media (min-width: 840px) and (max-width: 1199px) {
  body[data-screen="map"] #map-home .prayer-turn {
    left: 50%;
    right: auto;
    transform: translateX(-50%);
    font-size: 1.18rem;
    padding: 0.38rem 1rem 0.42rem 0.72rem;
  }
  body[data-screen="map"] #map-home .prayer-turn .prayer-turn-glyph {
    width: 1.2rem;
    height: 1.2rem;
  }
}
@media (max-width: 839px) {
  /* Stay centered just under the globe, a little more planted */
  body[data-screen="map"] #map-home .prayer-turn {
    margin: 6px auto 8px;
  }
}


/* ===== v81 N3: Turn to Prayer as a small brown-and-gold companion world ===== */
button.prayer-turn.prayer-turn-orb {
  appearance: none;
  -webkit-appearance: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.12rem;
  padding: 0;
  margin: 0;
  border: 0;
  border-radius: 0;
  background: none;
  box-shadow: none;
  overflow: visible;
  color: #E8C97A;
  font-family: var(--script), "Dancing Script", cursive;
  font-weight: 600;
  font-size: 1.05rem;
  line-height: 1.1;
  white-space: nowrap;
  cursor: pointer;
  z-index: 6;
}
button.prayer-turn.prayer-turn-orb::after {
  content: none;
  display: none;
  animation: none;
  background: none;
}
button.prayer-turn.prayer-turn-orb:hover,
button.prayer-turn.prayer-turn-orb:focus-visible {
  color: #FFE9B3;
  border: 0;
  box-shadow: none;
}
.prayer-orb {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background:
    radial-gradient(circle at 32% 28%, #7A4A2C 0%, #5A3420 32%, #3A2418 68%, #1C110A 100%);
  border: 1.5px solid #E2B33C;
  box-shadow:
    0 0 0 1px rgba(201, 162, 75, 0.35),
    0 0 14px 2px rgba(232, 201, 122, 0.48),
    0 0 26px rgba(201, 162, 75, 0.3),
    0 8px 16px rgba(26, 12, 6, 0.45),
    inset 0 -10px 16px rgba(10, 6, 2, 0.5),
    inset 0 7px 12px rgba(255, 232, 170, 0.2);
  flex: 0 0 auto;
}
.prayer-orb::before {
  content: "";
  position: absolute;
  inset: 7%;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 26%, rgba(255, 236, 190, 0.42) 0%, rgba(255, 220, 150, 0.1) 34%, transparent 60%);
  pointer-events: none;
  z-index: 0;
}
button.prayer-turn.prayer-turn-orb .prayer-turn-glyph {
  position: relative;
  z-index: 1;
  width: 2.35rem;
  height: 2.35rem;
  filter: drop-shadow(0 0 5px rgba(232, 201, 122, 0.85));
}
.prayer-turn-label {
  position: relative;
  z-index: 1;
  font-family: inherit;
  font-weight: 600;
  font-size: 1.08rem;
  line-height: 1.1;
  color: #A87A2A;
  text-shadow: 0 1px 2px rgba(255, 250, 235, 0.9);
  letter-spacing: 0.01em;
}
html.bg-gold-glitter body[data-screen="map"] .prayer-turn-label {
  color: #FFE9B3;
  text-shadow: 0 1px 3px rgba(12, 6, 2, 0.7);
}
button.prayer-turn.prayer-turn-orb:hover .prayer-orb,
button.prayer-turn.prayer-turn-orb:focus-visible .prayer-orb {
  border-color: #F0D78A;
  box-shadow:
    0 0 0 1.5px rgba(240, 215, 138, 0.7),
    0 0 18px 3px rgba(232, 201, 122, 0.7),
    0 0 32px rgba(201, 162, 75, 0.42),
    0 8px 16px rgba(26, 12, 6, 0.45),
    inset 0 -10px 16px rgba(10, 6, 2, 0.45),
    inset 0 7px 12px rgba(255, 232, 170, 0.28);
}
button.prayer-turn.prayer-turn-orb:hover .prayer-turn-label,
button.prayer-turn.prayer-turn-orb:focus-visible .prayer-turn-label {
  color: #8B5E3C;
}
html.bg-gold-glitter body[data-screen="map"] button.prayer-turn.prayer-turn-orb:hover .prayer-turn-label,
html.bg-gold-glitter body[data-screen="map"] button.prayer-turn.prayer-turn-orb:focus-visible .prayer-turn-label {
  color: #FFE9B3;
}
button.prayer-turn.prayer-turn-orb:focus-visible {
  outline: none;
}
button.prayer-turn.prayer-turn-orb:focus-visible .prayer-orb {
  box-shadow:
    0 0 0 2px rgba(255, 249, 242, 0.92),
    0 0 0 4px rgba(232, 201, 122, 0.7),
    0 0 18px 3px rgba(232, 201, 122, 0.7),
    0 8px 16px rgba(26, 12, 6, 0.45);
}

/* Laptop: companion moon in the globe's lower-right pocket, label above so it stays off the counter */
@media (min-width: 840px) {
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb {
    position: absolute;
    top: auto;
    left: 50%;
    right: auto;
    bottom: 52px;
    transform: translateX(175px);
    margin: 0;
    font-size: 1.08rem;
    padding: 0;
    flex-direction: column-reverse;
    gap: 0.2rem;
  }
}
@media (min-width: 1200px) {
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb {
    bottom: 48px;
    transform: translateX(230px);
  }
}
@media (min-width: 1400px) {
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb {
    bottom: 50px;
    transform: translateX(280px);
  }
}
@media (min-width: 840px) and (max-width: 1199px) {
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb {
    bottom: 56px;
    transform: translateX(175px);
    font-size: 1rem;
    padding: 0;
  }
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-orb {
    width: 72px;
    height: 72px;
  }
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-turn-glyph {
    width: 2.1rem;
    height: 2.1rem;
  }
}

/* Phone: centered under the globe; tuck the caption and tighten following margins so the counter stays above the nav */
@media (max-width: 839px) {
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb {
    position: static;
    transform: none;
    flex-direction: column;
    margin: 0 auto;
    gap: 0;
  }
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-orb {
    width: 64px;
    height: 64px;
  }
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-turn-glyph {
    width: 1.9rem;
    height: 1.9rem;
  }
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-turn-label {
    font-size: 1.05rem;
    margin-top: -14px;
  }
  body[data-screen="map"] #map-home:has(.prayer-turn-orb) .map-dedication {
    margin: 0 auto 0 !important;
  }
  body[data-screen="map"] #map-home:has(.prayer-turn-orb) .map-wrap > .grace-counter {
    margin: 2px auto 4px !important;
  }
}


/* ===== v84: candle companion-moon with curved Ask for Prayer / Pray a prayer ===== */
body[data-screen="map"] #map-home .map-circle-glow {
  overflow: visible;
}
.prayer-orb-cluster {
  position: relative;
  display: block;
  width: 180px;
  height: 180px;
  pointer-events: none;
}
.prayer-orb-cluster .prayer-orb,
.prayer-orb-cluster .prayer-captions {
  pointer-events: none;
}
button.prayer-turn.prayer-turn-orb {
  appearance: none;
  -webkit-appearance: none;
  display: block;
  width: 180px;
  height: 180px;
  padding: 0;
  margin: 0;
  border: 0;
  border-radius: 0;
  background: none;
  box-shadow: none;
  overflow: visible;
  cursor: pointer;
  z-index: 8;
  pointer-events: auto;
  font-family: "Cormorant Garamond", "Palatino Linotype", Palatino, Georgia, serif;
}
button.prayer-turn.prayer-turn-orb::after {
  content: none;
  display: none;
  animation: none;
}
.prayer-captions {
  position: absolute;
  inset: 0;
  width: 180px;
  height: 180px;
  overflow: visible;
  z-index: 2;
}
.prayer-caption {
  font-family: "Cormorant Garamond", "Palatino Linotype", Palatino, Georgia, serif;
  font-weight: 700;
  font-size: 17px;
  letter-spacing: 0.4px;
  fill: #4A2C16;
  stroke: rgba(255, 249, 242, 0.88);
  stroke-width: 2.2px;
  stroke-linejoin: round;
  stroke-linecap: round;
  paint-order: stroke fill;
  filter:
    drop-shadow(0 0 1.5px rgba(255, 250, 240, 0.95))
    drop-shadow(0 0 3px rgba(255, 249, 242, 0.75))
    drop-shadow(0 1px 1px rgba(255, 255, 255, 0.85));
}
html.bg-gold-glitter body[data-screen="map"] .prayer-caption {
  fill: #FFE9B3;
  stroke: rgba(26, 12, 6, 0.55);
  stroke-width: 2.4px;
  filter:
    drop-shadow(0 0 1.5px rgba(12, 6, 2, 0.7))
    drop-shadow(0 1px 2px rgba(12, 6, 2, 0.55));
}
button.prayer-turn.prayer-turn-orb:hover .prayer-caption,
button.prayer-turn.prayer-turn-orb:focus-visible .prayer-caption {
  fill: #3A2010;
}
html.bg-gold-glitter body[data-screen="map"] button.prayer-turn.prayer-turn-orb:hover .prayer-caption,
html.bg-gold-glitter body[data-screen="map"] button.prayer-turn.prayer-turn-orb:focus-visible .prayer-caption {
  fill: #FFF4C8;
}

/* Sphere: Prayer-page evening browns, soft gold rim */
button.prayer-turn.prayer-turn-orb .prayer-orb {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 96px;
  height: 96px;
  margin: 0;
  transform: translate(-50%, -50%);
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background:
    radial-gradient(circle at 32% 26%, #5C3A24 0%, #4A2E1C 40%, #2A1A10 78%, #1A1008 100%);
  border: 1.6px solid #E2B33C;
  box-shadow:
    0 0 0 1px rgba(201, 162, 75, 0.4),
    0 0 16px 3px rgba(232, 201, 122, 0.5),
    0 0 28px rgba(201, 162, 75, 0.32),
    0 8px 16px rgba(26, 12, 6, 0.45),
    inset 0 -12px 16px rgba(10, 6, 2, 0.5),
    inset 0 8px 12px rgba(255, 232, 170, 0.16);
  z-index: 1;
}
button.prayer-turn.prayer-turn-orb .prayer-orb::before {
  content: "";
  position: absolute;
  inset: 8%;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 24%, rgba(255, 236, 190, 0.28) 0%, rgba(255, 220, 150, 0.08) 34%, transparent 62%);
  pointer-events: none;
  z-index: 0;
}
.prayer-candle {
  position: relative;
  z-index: 1;
  width: 62px;
  height: 62px;
  display: block;
  overflow: visible;
  filter: drop-shadow(0 0 5px rgba(232, 201, 122, 0.55));
}
.prayer-candle .candle-halo {
  transform-origin: 40px 34px;
  animation: prayer-halo 2.4s ease-in-out infinite;
}
.prayer-candle .candle-flame,
.prayer-candle .candle-flame-core {
  transform-origin: 40px 38px;
  animation: prayer-flicker 1.7s ease-in-out infinite;
}
.prayer-candle .candle-flame-core {
  animation-duration: 1.35s;
  animation-delay: -0.4s;
}
@keyframes prayer-flicker {
  0%, 100% { transform: scale(1) rotate(0deg); }
  18% { transform: scale(1.06, 0.94) rotate(-2.2deg); }
  42% { transform: scale(0.95, 1.07) rotate(1.8deg); }
  66% { transform: scale(1.05, 0.96) rotate(-1.2deg); }
  84% { transform: scale(0.98, 1.03) rotate(1deg); }
}
@keyframes prayer-halo {
  0%, 100% { opacity: 0.82; transform: scale(1); }
  50% { opacity: 1; transform: scale(1.08); }
}
@media (prefers-reduced-motion: reduce) {
  .prayer-candle .candle-halo,
  .prayer-candle .candle-flame,
  .prayer-candle .candle-flame-core { animation: none; }
}

button.prayer-turn.prayer-turn-orb:hover .prayer-orb,
button.prayer-turn.prayer-turn-orb:focus-visible .prayer-orb {
  border-color: #F0D78A;
  box-shadow:
    0 0 0 1.5px rgba(240, 215, 138, 0.75),
    0 0 20px 4px rgba(232, 201, 122, 0.75),
    0 0 36px rgba(201, 162, 75, 0.45),
    0 8px 16px rgba(26, 12, 6, 0.45),
    inset 0 -12px 16px rgba(10, 6, 2, 0.4),
    inset 0 8px 12px rgba(255, 232, 170, 0.28);
}
button.prayer-turn.prayer-turn-orb:hover .prayer-candle,
button.prayer-turn.prayer-turn-orb:focus-visible .prayer-candle {
  filter: drop-shadow(0 0 8px rgba(255, 232, 170, 0.85));
}
button.prayer-turn.prayer-turn-orb:focus-visible {
  outline: none;
}
button.prayer-turn.prayer-turn-orb:focus-visible .prayer-orb {
  box-shadow:
    0 0 0 2px rgba(255, 249, 242, 0.95),
    0 0 0 4px rgba(232, 201, 122, 0.75),
    0 0 20px 4px rgba(232, 201, 122, 0.7),
    0 8px 16px rgba(26, 12, 6, 0.45);
}

/* Laptop: companion moon in the globe square's lower-right pocket */
@media (min-width: 840px) {
  body[data-screen="map"] #map-home .map-circle-glow > .prayer-turn.prayer-turn-orb {
    position: absolute;
    top: auto;
    left: auto;
    right: -18px;
    bottom: 28px;
    transform: none;
    margin: 0;
    padding: 0;
    flex-direction: row;
  }
}
@media (min-width: 840px) and (max-width: 1199px) {
  body[data-screen="map"] #map-home .map-circle-glow > .prayer-turn.prayer-turn-orb {
    right: -8px;
    bottom: 46px;
  }
  .prayer-orb-cluster,
  .prayer-captions,
  button.prayer-turn.prayer-turn-orb {
    width: 168px;
    height: 168px;
  }
  button.prayer-turn.prayer-turn-orb .prayer-orb {
    width: 88px;
    height: 88px;
  }
  .prayer-candle { width: 56px; height: 56px; }
  .prayer-caption { font-size: 16px; }
}
@media (min-width: 1400px) {
  body[data-screen="map"] #map-home .map-circle-glow > .prayer-turn.prayer-turn-orb {
    right: -12px;
    bottom: 32px;
  }
}

/* Phone: sit in the globe's lower-right pocket so dedic and counter stay clear */
@media (max-width: 839px) {
  body[data-screen="map"] #map-home .map-circle-glow > .prayer-turn.prayer-turn-orb {
    position: absolute;
    top: auto;
    left: auto;
    right: -10px;
    bottom: 2px;
    transform: none;
    margin: 0;
    flex-direction: row;
  }
  .prayer-orb-cluster,
  .prayer-captions,
  button.prayer-turn.prayer-turn-orb {
    width: 150px;
    height: 150px;
  }
  button.prayer-turn.prayer-turn-orb .prayer-orb {
    width: 80px;
    height: 80px;
  }
  .prayer-candle { width: 52px; height: 52px; }
  .prayer-caption { font-size: 15px; stroke-width: 3.5px; }
}


/* v84 placement/size overrides — win over earlier N3 rules */
@media (min-width: 840px) {
  body[data-screen="map"] #map-home .map-circle-glow > .prayer-turn.prayer-turn-orb {
    right: -52px;
    bottom: 42px;
  }
  body[data-screen="map"] #map-home .map-circle-glow > .prayer-turn.prayer-turn-orb,
  body[data-screen="map"] #map-home .map-circle-glow > .prayer-turn.prayer-turn-orb .prayer-orb-cluster,
  body[data-screen="map"] #map-home .map-circle-glow > .prayer-turn.prayer-turn-orb .prayer-captions {
    width: 180px;
    height: 180px;
  }
  body[data-screen="map"] #map-home .map-circle-glow > .prayer-turn.prayer-turn-orb .prayer-orb {
    width: 96px;
    height: 96px;
  }
  body[data-screen="map"] #map-home .map-circle-glow > .prayer-turn.prayer-turn-orb .prayer-candle {
    width: 62px;
    height: 62px;
  }
  body[data-screen="map"] #map-home .map-circle-glow > .prayer-turn.prayer-turn-orb .prayer-caption {
    font-size: 17.5px;
  }
}
@media (min-width: 840px) and (max-width: 1199px) {
  body[data-screen="map"] #map-home .map-circle-glow > .prayer-turn.prayer-turn-orb {
    right: -58px;
    bottom: 58px;
  }
  body[data-screen="map"] #map-home .map-circle-glow > .prayer-turn.prayer-turn-orb,
  body[data-screen="map"] #map-home .map-circle-glow > .prayer-turn.prayer-turn-orb .prayer-orb-cluster,
  body[data-screen="map"] #map-home .map-circle-glow > .prayer-turn.prayer-turn-orb .prayer-captions {
    width: 168px;
    height: 168px;
  }
  body[data-screen="map"] #map-home .map-circle-glow > .prayer-turn.prayer-turn-orb .prayer-orb {
    width: 88px;
    height: 88px;
  }
  body[data-screen="map"] #map-home .map-circle-glow > .prayer-turn.prayer-turn-orb .prayer-candle {
    width: 56px;
    height: 56px;
  }
  body[data-screen="map"] #map-home .map-circle-glow > .prayer-turn.prayer-turn-orb .prayer-caption {
    font-size: 16px;
  }
}
@media (min-width: 1400px) {
  body[data-screen="map"] #map-home .map-circle-glow > .prayer-turn.prayer-turn-orb {
    right: -44px;
    bottom: 44px;
  }
}

/* Phone: companion moon in the lower-right pocket (right of the credits "i", below zoom).
   Hang only as far as needed so Honey's line and the counter stay visible above the nav. */
@media (max-width: 839px) {
  body[data-screen="map"] #map-home .map-circle-glow {
    /* Reserve hang space under the globe; margin does not change --globe size. */
    margin-bottom: 66px !important;
  }
  body[data-screen="map"] #map-home .map-circle-glow > .prayer-turn.prayer-turn-orb {
    position: absolute;
    left: auto;
    right: 0;
    top: auto;
    bottom: -82px;
    transform: none;
    margin: 0;
  }
  body[data-screen="map"] #map-home .map-circle-glow > .prayer-turn.prayer-turn-orb,
  body[data-screen="map"] #map-home .map-circle-glow > .prayer-turn.prayer-turn-orb .prayer-orb-cluster,
  body[data-screen="map"] #map-home .map-circle-glow > .prayer-turn.prayer-turn-orb .prayer-captions {
    width: 140px;
    height: 140px;
  }
  body[data-screen="map"] #map-home .map-circle-glow > .prayer-turn.prayer-turn-orb .prayer-orb {
    width: 80px;
    height: 80px;
  }
  body[data-screen="map"] #map-home .map-circle-glow > .prayer-turn.prayer-turn-orb .prayer-candle {
    width: 52px;
    height: 52px;
  }
  body[data-screen="map"] #map-home .map-circle-glow > .prayer-turn.prayer-turn-orb .prayer-caption {
    font-size: 15px;
    stroke-width: 3.6px;
  }
  body[data-screen="map"] #map-home:has(.prayer-turn-orb) .map-dedication {
    margin: 4px auto 1px !important;
  }
  body[data-screen="map"] #map-home:has(.prayer-turn-orb) .map-wrap > .grace-counter {
    margin: 1px auto 2px !important;
  }
}



/* ===== v85: orb in the open sky; mirrored prayer arc; slightly larger intro body ===== */

/* The stack is transparent on laptops (display:contents) so the button
   positions against the map column. On the phone it becomes a real
   positioning context so the orb can sit just below the globe. */
.map-globe-stack { display: contents; }

/* Intro body: +12.5% size, one weight step, stronger contrast.
   Padding is tuned so --map-hero-h (and the globe) stay exactly where they were. */
@media (min-width: 840px) {
  .welcome.map-hero,
  html.bg-sunlit body[data-screen="map"] .welcome.map-hero,
  html.bg-gold-glitter body[data-screen="map"] .welcome.map-hero {
    width: min(760px, calc(100% - 24px));
    max-width: min(760px, calc(100% - 24px));
    padding: 0.44rem 1.15rem 0.5rem;
    margin: 2px auto 10px;
  }
  .welcome.map-hero .welcome-copy > p:not(.welcome-tap) {
    font-size: 0.9rem;
    font-weight: 600;
    line-height: 1.28;
    color: #4A2C16;
  }
  html.bg-gold-glitter body[data-screen="map"] .welcome.map-hero .welcome-copy > p:not(.welcome-tap) {
    color: #FFF6E1;
  }
  .welcome-copy .welcome-tap,
  .welcome.map-hero .welcome-tap,
  body[data-screen="map"] #map-home .welcome-tap {
    font-weight: 700;
    font-size: 1.38rem;
    margin: 0.12rem 0 0;
    line-height: 1.15;
  }
}
/* Narrow laptops: keep the three body lines from wrapping, hold the hero height
   so the globe stays 519px at y=242. Size is +7.5% (0.86rem) and weight 600. */
@media (min-width: 840px) and (max-width: 1199px) {
  .welcome.map-hero,
  html.bg-sunlit body[data-screen="map"] .welcome.map-hero,
  html.bg-gold-glitter body[data-screen="map"] .welcome.map-hero {
    width: 100%;
    max-width: 100%;
    padding: 0.66rem 6px 0.66rem;
  }
  .welcome.map-hero .welcome-copy > p:not(.welcome-tap) {
    font-size: 0.86rem;
    line-height: 1.25;
    letter-spacing: -0.015em;
  }
  .welcome-copy .welcome-tap,
  .welcome.map-hero .welcome-tap,
  body[data-screen="map"] #map-home .welcome-tap {
    font-size: 1.28rem;
    margin: 0.08rem 0 0;
  }
}
@media (max-width: 839px) {
  /* Weight 600 and a modest size bump. A full 10–15% size increase
     wraps to a fifth line and would push the globe (must stay at y=253). */
  body[data-screen="map"] #map-home .welcome.map-hero {
    padding: 0.38rem 0.4rem 0.32rem;
    gap: 0.12rem;
  }
  body[data-screen="map"] #map-home .welcome.map-hero h1 {
    margin: 0 0 0.08rem;
  }
  body[data-screen="map"] #map-home .welcome.map-hero .welcome-copy > p:not(.welcome-tap) {
    font-size: 0.8rem;
    font-weight: 600;
    line-height: 1.22;
    color: #4A2C16;
  }
  html.bg-gold-glitter body[data-screen="map"] #map-home .welcome.map-hero .welcome-copy > p:not(.welcome-tap) {
    color: #FFF6E1;
  }
  body[data-screen="map"] #map-home .touch-cue {
    font-weight: 700;
    font-size: 1.32rem;
    margin: 0.35rem auto -0.1rem;
  }
}

/* Desktop: sit the cluster in the open sky to the right of the globe square,
   inside the map column, above the grace counter. */
@media (min-width: 840px) {
  body[data-screen="map"] #map-home .map-wrap {
    position: relative;
  }
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb {
    position: absolute;
    left: auto;
    right: 8px;
    top: auto;
    bottom: 52px;
    transform: none;
    margin: 0;
    z-index: 8;
    width: 164px;
    height: 164px;
  }
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-orb-cluster,
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-captions {
    width: 164px;
    height: 164px;
  }
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-orb {
    width: 88px;
    height: 88px;
  }
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-candle {
    width: 56px;
    height: 56px;
  }
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-caption {
    font-size: 17px;
    font-weight: 700;
    letter-spacing: 0.4px;
    stroke-width: 2.2px;
  }
}

/* Wide laptop: a little more breathing room in the sky */
@media (min-width: 1400px) {
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb {
    right: 12px;
    bottom: 52px;
    width: 180px;
    height: 180px;
  }
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-orb-cluster,
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-captions {
    width: 180px;
    height: 180px;
  }
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-orb {
    width: 96px;
    height: 96px;
  }
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-candle {
    width: 62px;
    height: 62px;
  }
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-caption {
    font-size: 17px;
    font-weight: 700;
    letter-spacing: 0.4px;
    stroke-width: 2.2px;
  }
}

/* 1024-class laptops: the right-hand sky is tight. Scale the cluster down and
   sit it in the lower-right corner pocket, above the counter, clear of the rim. */
@media (min-width: 840px) and (max-width: 1199px) {
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb {
    right: 4px;
    bottom: 60px;
    width: 96px;
    height: 96px;
  }
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-orb-cluster,
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-captions {
    width: 96px;
    height: 96px;
  }
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-orb {
    width: 54px;
    height: 54px;
  }
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-candle {
    width: 36px;
    height: 36px;
  }
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-caption {
    font-size: 12.5px;
    font-weight: 700;
    letter-spacing: 0.25px;
    stroke-width: 1.8px;
  }
}

/* Phone: orb sits just below the globe, on the right, clear of the map.
   Honey's line and the counter share the same band on the left. */
@media (max-width: 839px) {
  body[data-screen="map"] #map-home .map-wrap {
    position: relative;
  }
  body[data-screen="map"] #map-home .map-globe-stack {
    display: block;
    position: relative;
    width: fit-content;
    max-width: 100%;
    margin: 2px auto 148px;
  }
  body[data-screen="map"] #map-home .map-circle-glow {
    margin-bottom: 0 !important;
  }
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb {
    position: absolute;
    left: auto;
    right: 0;
    top: 100%;
    bottom: auto;
    transform: none;
    margin: 14px 0 0 0;
    z-index: 8;
    width: 124px;
    height: 124px;
  }
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-orb-cluster,
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-captions {
    width: 124px;
    height: 124px;
  }
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-orb {
    width: 68px;
    height: 68px;
  }
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-candle {
    width: 44px;
    height: 44px;
  }
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-caption {
    font-size: 14.5px;
    font-weight: 700;
    letter-spacing: 0.3px;
    stroke-width: 2px;
  }
  body[data-screen="map"] #map-home:has(.prayer-turn-orb) .map-dedication {
    position: relative;
    z-index: 3;
    align-self: flex-start;
    max-width: calc(100% - 150px);
    width: calc(100% - 150px);
    margin: -140px 0 0 10px !important;
    padding: 6px 0 0;
    text-align: left;
  }
  body[data-screen="map"] #map-home:has(.prayer-turn-orb) .map-wrap > .grace-counter {
    position: relative;
    z-index: 3;
    align-self: flex-start !important;
    margin: 6px 0 72px 10px !important;
    justify-content: flex-start;
    max-width: calc(100% - 150px);
  }
}


/* ===== v87: orb reads as a button; Prayer in the header/phone nav ===== */

/* Slow, gentle gold pulse on the orb rim. ::after is free: the button's own
   ::after is disabled, and the orb's ::before is the inner highlight. */
button.prayer-turn.prayer-turn-orb .prayer-orb::after {
  content: "";
  position: absolute;
  inset: -5px;
  border-radius: 50%;
  box-shadow:
    0 0 0 1.5px rgba(226, 179, 60, 0.5),
    0 0 12px 3px rgba(232, 201, 122, 0.42),
    0 0 22px 6px rgba(201, 162, 75, 0.22);
  animation: prayer-orb-pulse 3s ease-in-out infinite;
  pointer-events: none;
  z-index: -1;
}
@keyframes prayer-orb-pulse {
  0%, 100% { opacity: 0.42; }
  50% { opacity: 1; }
}

/* Lift the whole candle+labels slightly; do not touch the button's
   positioning transform. */
button.prayer-turn.prayer-turn-orb .prayer-orb-cluster {
  transform-origin: 50% 50%;
  transition: transform 0.4s ease;
}
button.prayer-turn.prayer-turn-orb:hover .prayer-orb-cluster,
button.prayer-turn.prayer-turn-orb:focus-visible .prayer-orb-cluster {
  transform: scale(1.04);
}

/* Warmer, brighter rim + a brighter flame on hover and keyboard focus. */
button.prayer-turn.prayer-turn-orb:hover .prayer-orb,
button.prayer-turn.prayer-turn-orb:focus-visible .prayer-orb {
  border-color: #F6DE98;
  box-shadow:
    0 0 0 1.5px rgba(246, 222, 152, 0.85),
    0 0 22px 5px rgba(240, 196, 90, 0.8),
    0 0 40px rgba(226, 179, 60, 0.5),
    0 8px 16px rgba(26, 12, 6, 0.45),
    inset 0 -12px 16px rgba(10, 6, 2, 0.38),
    inset 0 8px 12px rgba(255, 236, 190, 0.34);
}
button.prayer-turn.prayer-turn-orb:hover .prayer-orb::after,
button.prayer-turn.prayer-turn-orb:focus-visible .prayer-orb::after {
  animation: none;
  opacity: 1;
  box-shadow:
    0 0 0 2px rgba(246, 222, 152, 0.75),
    0 0 16px 4px rgba(240, 196, 90, 0.7),
    0 0 28px 8px rgba(226, 179, 60, 0.4);
}
button.prayer-turn.prayer-turn-orb:hover .prayer-candle,
button.prayer-turn.prayer-turn-orb:focus-visible .prayer-candle {
  filter: drop-shadow(0 0 10px rgba(255, 236, 190, 0.95)) brightness(1.12);
}
button.prayer-turn.prayer-turn-orb:hover .prayer-candle .candle-flame,
button.prayer-turn.prayer-turn-orb:hover .prayer-candle .candle-flame-core,
button.prayer-turn.prayer-turn-orb:focus-visible .prayer-candle .candle-flame,
button.prayer-turn.prayer-turn-orb:focus-visible .prayer-candle .candle-flame-core {
  filter: brightness(1.18) saturate(1.08);
}
button.prayer-turn.prayer-turn-orb:hover .prayer-candle .candle-halo,
button.prayer-turn.prayer-turn-orb:focus-visible .prayer-candle .candle-halo {
  opacity: 1;
  filter: brightness(1.2);
}

/* Visible keyboard focus ring on the orb itself. */
button.prayer-turn.prayer-turn-orb:focus-visible {
  outline: none;
}
button.prayer-turn.prayer-turn-orb:focus-visible .prayer-orb {
  outline: none;
  box-shadow:
    0 0 0 2px rgba(255, 249, 242, 0.98),
    0 0 0 5px rgba(232, 201, 122, 0.9),
    0 0 22px 5px rgba(240, 196, 90, 0.75),
    0 8px 16px rgba(26, 12, 6, 0.45),
    inset 0 -12px 16px rgba(10, 6, 2, 0.38),
    inset 0 8px 12px rgba(255, 236, 190, 0.34);
}

@media (prefers-reduced-motion: reduce) {
  button.prayer-turn.prayer-turn-orb .prayer-orb::after {
    animation: none;
    opacity: 0.7;
  }
  button.prayer-turn.prayer-turn-orb .prayer-orb-cluster {
    transition: none;
  }
  button.prayer-turn.prayer-turn-orb:hover .prayer-orb-cluster,
  button.prayer-turn.prayer-turn-orb:focus-visible .prayer-orb-cluster {
    transform: none;
  }
}

/* Nav Prayer button: same gold candle as the orb, sized like the other icons. */
.nav-btn .nav-prayer-ico {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.2rem;
  height: 1.2rem;
  flex: 0 0 auto;
  line-height: 0;
}
.nav-btn .nav-prayer-ico svg {
  width: 100%;
  height: 100%;
  display: block;
  overflow: visible;
}

/* Six nav items: keep the header on one row at 1024–1440, and the phone bar unwrapped. */
@media (min-width: 840px) and (max-width: 1199px) {
  .app-nav {
    gap: 0.2rem;
    right: 0.55rem;
  }
  .nav-btn {
    font-size: 0.72rem;
    padding: 0.4rem 0.52rem;
  }
}
@media (min-width: 1200px) and (max-width: 1365px) {
  .app-nav { gap: 0.28rem; }
  .nav-btn { padding: 0.42rem 0.68rem; }
}
@media (max-width: 839px) {
  .app-nav {
    padding-left: 0.08rem;
    padding-right: 0.08rem;
    gap: 0;
  }
  .nav-btn {
    flex: 1 1 0;
    min-width: 0;
    padding: 0.28rem 0.1rem;
    font-size: 0.58rem;
    gap: 0.08rem;
  }
  .nav-btn .ico,
  .nav-btn .nav-prayer-ico {
    font-size: 1.05rem;
    width: 1.05rem;
    height: 1.05rem;
  }
}


/* ===== v89: two-line intro body; warmer Cormorant; About "How do we know" ===== */

/* Phone: hide forced laptop breaks and let the body wrap naturally. */
@media (max-width: 839px) {
  .lap-br-narrow { display: none; }
}

/* 1024-class: keep three balanced body lines (the combined first line will not fit). */
@media (min-width: 840px) and (max-width: 1199px) {
  .lap-br-narrow { display: unset; }
}

/* 1280 and 1440: one break only, so the body is two lines. */
@media (min-width: 1200px) {
  .lap-br-narrow { display: none; }
}

@media (min-width: 840px) {
  .welcome.map-hero .welcome-copy > p:not(.welcome-tap) {
    font-family: "Cormorant Garamond", "Palatino Linotype", Palatino, Georgia, serif;
    font-weight: 600;
    font-size: 1.08rem;
    line-height: 1.32;
    letter-spacing: 0.01em;
    color: #6B4A2E;
  }
  html.bg-gold-glitter body[data-screen="map"] .welcome.map-hero .welcome-copy > p:not(.welcome-tap) {
    color: #F6E6C4;
  }
}

/* Wide laptops: widen the card so the two body lines fit and look balanced.
   Extra vertical padding replaces the dropped third body line so --map-hero-h
   (and the globe) stay exactly where they were. */
@media (min-width: 1200px) {
  .welcome.map-hero,
  html.bg-sunlit body[data-screen="map"] .welcome.map-hero,
  html.bg-gold-glitter body[data-screen="map"] .welcome.map-hero {
    width: min(900px, calc(100% - 16px));
    max-width: min(900px, calc(100% - 16px));
    padding: 0.75rem 1.2rem 0.80rem;
    margin: 2px auto 10px;
  }
}

@media (min-width: 1400px) {
  .welcome.map-hero,
  html.bg-sunlit body[data-screen="map"] .welcome.map-hero,
  html.bg-gold-glitter body[data-screen="map"] .welcome.map-hero {
    width: min(960px, calc(100% - 20px));
    max-width: min(960px, calc(100% - 20px));
  }
}

/* 1024-class: three body lines at a slightly smaller Cormorant size so the
   long third line still fits; padding holds the hero (and globe) at y=242. */
@media (min-width: 840px) and (max-width: 1199px) {
  .welcome.map-hero,
  html.bg-sunlit body[data-screen="map"] .welcome.map-hero,
  html.bg-gold-glitter body[data-screen="map"] .welcome.map-hero {
    width: 100%;
    max-width: 100%;
    padding: 0.35rem 6px 0.34rem;
  }
  .welcome.map-hero .welcome-copy > p:not(.welcome-tap) {
    font-size: 1rem;
    line-height: 1.28;
    letter-spacing: 0;
  }
}

/* Phone: same warmer Cormorant, modest size so the copy wraps naturally
   without pushing the globe off y=253. */
@media (max-width: 839px) {
  body[data-screen="map"] #map-home .welcome.map-hero .welcome-copy > p:not(.welcome-tap) {
    font-family: "Cormorant Garamond", "Palatino Linotype", Palatino, Georgia, serif;
    font-weight: 600;
    font-size: 0.84rem;
    line-height: 1.22;
    letter-spacing: 0.01em;
    color: #6B4A2E;
  }
  html.bg-gold-glitter body[data-screen="map"] #map-home .welcome.map-hero .welcome-copy > p:not(.welcome-tap) {
    color: #F6E6C4;
  }
}

/* About: a gentle heading in the same family as the front-page headline. */
.about h3 {
  font-family: "Cormorant Garamond", "Palatino Linotype", Palatino, Georgia, serif;
  font-weight: 600;
  font-size: 1.35rem;
  line-height: 1.3;
  color: var(--brown, #6B4226);
  margin: 1.35rem 0 0.45rem;
  letter-spacing: 0.01em;
}
.about h3:first-child {
  margin-top: 0.35rem;
}

@media (max-width: 839px) {
  body[data-screen="map"] #map-home .welcome.map-hero {
    padding: 0.28rem 0.4rem 0.22rem;
  }
}
@media (min-width: 1200px) {
  html.bg-gold-glitter body[data-screen="map"] .welcome.map-hero {
    padding: 0.68rem 1.2rem 0.72rem;
  }
}


/* ===== v91: lining, slightly larger 24/7 in the intro body ===== */
.welcome.map-hero .welcome-copy > p:not(.welcome-tap) .intro-247 {
  font-family: "Cormorant Garamond", "Palatino Linotype", Palatino, Georgia, serif;
  font-style: italic;
  font-variant-numeric: lining-nums;
  font-feature-settings: "lnum";
  font-size: 1.12em;
  font-weight: 700;
  color: inherit;
  letter-spacing: 0.01em;
  line-height: 1;
  vertical-align: baseline;
}


/* ===== v92: brown-and-gold nav buttons; gold line icons; gold Share feather ===== */
html.header-white.theme-earth .app-nav .nav-btn {
  background: linear-gradient(180deg, #8A5E3B 0%, #5C3A22 100%);
  color: #FBF3E2;
  border: 1px solid #C9A24B;
  box-shadow: 0 1px 3px rgba(60, 30, 10, 0.28);
  text-shadow: none;
  transition: background 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}
html.header-white.theme-earth .app-nav .nav-btn .ico,
html.header-white.theme-earth .app-nav .nav-btn .nav-prayer-ico {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.15rem;
  height: 1.15rem;
  flex: 0 0 auto;
  line-height: 0;
  color: #E8C97A;
  font-size: 1.15rem;
}
html.header-white.theme-earth .app-nav .nav-btn .ico svg,
html.header-white.theme-earth .app-nav .nav-btn .nav-prayer-ico svg {
  width: 100%;
  height: 100%;
  display: block;
  overflow: visible;
}
html.header-white.theme-earth .app-nav .nav-btn:hover,
html.header-white.theme-earth .app-nav .nav-btn:focus-visible {
  background: linear-gradient(180deg, #9A6A44 0%, #6A4428 100%);
  color: #FFF8E8;
  border-color: #E2B33C;
  box-shadow:
    0 0 0 1px rgba(226, 179, 60, 0.4),
    0 0 10px rgba(232, 201, 122, 0.48);
}
html.header-white.theme-earth .app-nav .nav-btn:focus-visible {
  outline: 2px solid #E8C97A;
  outline-offset: 2px;
}
html.header-white.theme-earth .app-nav .nav-btn[aria-current="page"] {
  background: linear-gradient(180deg, #5A3820 0%, #4A2E1C 100%);
  color: #E8C97A;
  border: 1px solid #C9A24B;
  box-shadow:
    0 0 0 1px rgba(232, 201, 122, 0.55),
    0 0 12px rgba(232, 201, 122, 0.55);
  font-weight: 700;
}
html.header-white.theme-earth .app-nav .nav-btn[aria-current="page"] .ico,
html.header-white.theme-earth .app-nav .nav-btn:hover .ico,
html.header-white.theme-earth .app-nav .nav-btn:focus-visible .ico {
  color: #F6DE98;
}

@media (max-width: 839px) {
  html.header-white.theme-earth .app-nav .nav-btn,
  html.header-white.theme-earth .app-nav .nav-btn[aria-current="page"] {
    border-width: 1px;
  }
  html.header-white.theme-earth .app-nav .nav-btn .ico,
  html.header-white.theme-earth .app-nav .nav-btn .nav-prayer-ico {
    width: 1.05rem;
    height: 1.05rem;
    font-size: 1.05rem;
  }
}
@media (prefers-reduced-motion: reduce) {
  html.header-white.theme-earth .app-nav .nav-btn {
    transition: none;
  }
}

/* ===== v93: Prayer view uses the gold-glitter night background; map stays sunlit ===== */

/* ===== v94: Prayer view — brown vignette, gold rays, calmer glitter ===== */

/* ===== v95: Prayer bloom from the tap, gold rays, staggered reveal ===== */

/* ===== v96–v97: Prayer planet map, tea-light responses, notifications, request form, My Prayers, light-cross ===== */
.prayer-view > .prayer-rays {
  left: 50%;
  top: 46%;
}
.prayer-entry {
  position: absolute;
  inset: 0;
  z-index: 5;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  padding: 2rem 1.5rem 3rem;
  text-align: center;
  pointer-events: none;
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.prayer-flip.is-page .prayer-entry {
  opacity: 0;
  transform: scale(0.94);
}

.prayer-page {
  position: absolute;
  inset: 0;
  z-index: 4;
  display: flex;
  flex-direction: column;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.65s ease 0.05s;
}
.prayer-flip.is-page .prayer-page {
  opacity: 1;
  pointer-events: auto;
}

.prayer-page-bar {
  height: var(--header-h, 64px);
  flex: 0 0 var(--header-h, 64px);
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.6rem 1rem;
  padding: 0 1rem;
  box-sizing: border-box;
  position: relative;
  z-index: 6;
}
.prayer-page-hero {
  height: var(--map-hero-h, 110px);
  flex: 0 0 var(--map-hero-h, 110px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  box-sizing: border-box;
  padding: 0 1rem;
  z-index: 5;
}
.prayer-page-title {
  margin: 0;
  font-family: "Cormorant Garamond", "Palatino Linotype", Palatino, Georgia, serif;
  font-weight: 600;
  font-style: italic;
  font-size: clamp(2rem, 5vw, 3.2rem);
  letter-spacing: 0.045em;
  line-height: 1.05;
  color: #FFF6D4;
  text-shadow: 0 1px 2px rgba(20, 10, 4, 0.9), 0 2px 10px rgba(12, 6, 2, 0.55);
}
.prayer-page-lede {
  margin: 0.15rem 0 0;
  font: 500 1.15rem/1.35 var(--font);
  color: #FFF8E8;
  text-transform: none;
  text-shadow: 0 1px 2px rgba(20, 10, 4, 0.85);
}
.prayer-page-lede .prayer-lede-em,
.prayer-placeholder .prayer-lede-em {
  font-weight: 700;
  color: #F0D78A;
  text-transform: none;
}
.prayer-lede-phrase { white-space: nowrap; }
.prayer-page-body {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  position: relative;
  z-index: 5;
}
.prayer-map-col {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 11px 8px 8px;
  box-sizing: border-box;
}
.prayer-page .map-circle-glow,
.prayer-page .prayer-globe {
  margin: 6px auto 4px;
}
.prayer-panel {
  flex: 0 0 auto;
  box-sizing: border-box;
  padding: 0.85rem 1rem 1.25rem;
  color: #FFF8E8;
  background: rgba(40, 24, 14, 0.55);
  border-top: 1px solid rgba(232, 201, 122, 0.35);
  overflow: auto;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.prayer-panel h3 {
  margin: 0 0 0.35rem;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-weight: 600;
  font-size: 1.25rem;
  color: #FFF6D4;
  display: flex;
  align-items: center;
  gap: 0.45rem;
}
.sample-badge {
  display: inline-block;
  font-family: var(--font);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #4A2E1C;
  background: linear-gradient(180deg, #F6E4A8, #E8C97A);
  border-radius: 999px;
  padding: 0.12rem 0.45rem;
  vertical-align: middle;
}
.prayer-request-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}
.prayer-request-open {
  appearance: none;
  width: 100%;
  display: flex;
  gap: 0.6rem;
  text-align: left;
  background: rgba(255, 248, 232, 0.08);
  border: 1px solid rgba(232, 201, 122, 0.28);
  border-radius: 12px;
  padding: 0.55rem 0.65rem;
  color: #FFF8E8;
  cursor: pointer;
}
.prayer-request-open:hover,
.prayer-request-open:focus-visible {
  background: rgba(255, 248, 232, 0.16);
  border-color: rgba(232, 201, 122, 0.55);
  outline: none;
}
.prayer-request-thumb {
  flex: none;
  width: 22px;
  height: 42px;
  object-fit: contain;
  filter: drop-shadow(0 0 4px rgba(255, 220, 120, 0.55));
}
.prayer-request-open b { display: block; font-size: 0.88rem; color: #FFF6D4; }
.prayer-request-area,
.prayer-request-meta { display: block; font-size: 0.72rem; color: #F0D78A; }
.prayer-request-snip {
  display: block;
  font-size: 0.8rem;
  line-height: 1.35;
  color: #F6EBD3;
  max-height: 2.7em;
  overflow: hidden;
}

@media (min-width: 840px) {
  .prayer-page-body { flex-direction: row; align-items: stretch; }
  .prayer-map-col { flex: 1.4; }
  .prayer-panel {
    flex: 0 0 360px;
    max-width: 360px;
    border-top: 0;
    border-left: 1px solid rgba(232, 201, 122, 0.35);
  }
}

.prayer-page button.prayer-back,
.prayer-flip.is-page .prayer-page button.prayer-back {
  opacity: 1;
  transform: none;
  position: relative;
  z-index: 2;
  transition: color 0.2s ease;
}

.prayer-notify-btn {
  appearance: none;
  position: relative;
  background: transparent;
  border: 0;
  padding: 0.2rem 0.35rem;
  cursor: pointer;
  filter: drop-shadow(0 0 6px rgba(255, 220, 120, 0.55));
}
.prayer-notify-btn img {
  display: block;
  width: 22px;
  height: 42px;
  object-fit: contain;
}
.prayer-nav-badge {
  position: absolute;
  top: -4px;
  right: -6px;
  min-width: 1.15rem;
  height: 1.15rem;
  padding: 0 0.28rem;
  border-radius: 999px;
  background: linear-gradient(180deg, #E8C97A, #C9A24B);
  color: #3D2A14;
  font: 700 0.68rem/1.15rem var(--font);
  text-align: center;
  box-shadow: 0 0 0 2px #4A2E1C;
}
.nav-btn-prayer { position: relative; }
.nav-btn-prayer .prayer-nav-badge {
  top: 2px;
  right: 2px;
}

/* Gentle prayer card */
.prayer-card {
  position: absolute;
  z-index: 8;
  left: 50%;
  top: 52%;
  transform: translate(-50%, -50%);
  width: min(28rem, calc(100% - 2rem));
  max-height: min(78vh, 640px);
  overflow: auto;
  box-sizing: border-box;
  padding: 1.15rem 1.2rem 1.2rem;
  background: linear-gradient(180deg, #FFFDF7 0%, #FBF3E2 100%);
  border: 1px solid #C9A24B;
  border-radius: 18px;
  box-shadow: 0 16px 40px rgba(20, 10, 4, 0.4);
  color: #4A2E1C;
}
.prayer-card-close {
  appearance: none;
  position: absolute;
  top: 0.4rem;
  right: 0.5rem;
  width: 2rem;
  height: 2rem;
  border: 0;
  background: transparent;
  color: #6B4A2B;
  font-size: 1.4rem;
  line-height: 1;
  cursor: pointer;
}
.prayer-card-kicker { margin: 0 0 0.35rem; font-size: 0.78rem; color: #8A5E3B; }
.prayer-card-title {
  margin: 0 0 0.4rem;
  padding-right: 1.6rem;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-weight: 600;
  font-size: 1.35rem;
  color: #4A2E1C;
}
.prayer-card-mine { margin: 0 0 0.4rem; font-size: 0.78rem; font-weight: 700; color: #8A5E3B; }
.prayer-card-body-text { margin: 0 0 0.85rem; font-size: 1rem; line-height: 1.5; color: #4A2E1C; }
.prayer-card-lit {
  margin: -0.35rem 0 0.7rem;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 0.95rem;
  font-weight: 600;
  font-style: italic;
  color: #8A5E3B;
}


.prayer-choices {
  display: flex;
  flex-direction: column;
  gap: 0.38rem;
  margin: 0 0 0.85rem;
}
.resp-tealight {
  appearance: none;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  width: 100%;
  text-align: left;
  background: linear-gradient(180deg, #FFFDF7, #FFF6E4);
  border: 1px solid #E6D3A3;
  border-radius: 999px;
  padding: 0.28rem 0.85rem 0.28rem 0.32rem;
  font-weight: 700;
  color: #6B4A2B;
  cursor: pointer;
}
.resp-tealight:hover,
.resp-tealight:focus-visible {
  border-color: #C9A24A;
  outline: none;
}
.resp-tealight[aria-pressed="true"] {
  background: linear-gradient(180deg, #FFF8E1, #F6E4A8);
  border-color: #C9A24A;
  box-shadow: 0 0 0 1px rgba(201, 162, 74, 0.25);
}
.resp-tealight .tealight-icon {
  width: 28px;
  height: 36px;
  flex: none;
  display: block;
  object-fit: contain;
}
.resp-tealight .resp-label {
  font-size: 0.86rem;
  line-height: 1.25;
  color: #6B4A2B;
}

.prayer-gathering { margin: 0.2rem 0 0; }
.prayer-gather-row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 0.12rem 0.15rem;
  min-height: 28px;
}
.gather-tealight {
  width: 22px;
  height: 28px;
  object-fit: contain;
  filter: drop-shadow(0 1px 1px rgba(90, 62, 36, 0.25));
}
.gather-more, .gather-empty { font-size: 0.78rem; color: #8A5E3B; font-weight: 700; align-self: center; padding-left: 0.25rem; }
.prayer-gather-count {
  margin: 0.35rem 0 0;
  font-size: 0.92rem;
  font-weight: 700;
  color: #4A2E1C;
}

/* Map markers */
.prayer-candle-marker {
  background: none !important;
  border: 0 !important;
}
.leaflet-marker-icon.prayer-candle-marker {
  animation: prayer-candle-flicker 1.8s ease-in-out infinite;
}
@keyframes prayer-candle-flicker {
  0%, 100% { filter: drop-shadow(0 0 4px rgba(255, 220, 120, 0.55)) drop-shadow(0 0 10px rgba(255, 200, 80, 0.35)); }
  45% { filter: drop-shadow(0 0 8px rgba(255, 236, 170, 0.9)) drop-shadow(0 0 16px rgba(255, 210, 80, 0.55)); }
}
.prayer-cluster { background: none !important; border: 0 !important; }
.prayer-cluster span {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  width: 48px;
  height: 62px;
  color: #5C3C2B;
}
.prayer-cluster img {
  width: 22px;
  height: 42px;
  display: block;
  object-fit: contain;
  filter: drop-shadow(0 0 5px rgba(255, 220, 120, 0.55));
}
.prayer-cluster em {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 20px;
  height: 18px;
  margin-top: -8px;
  padding: 0 5px;
  border-radius: 999px;
  background: linear-gradient(180deg, #FFF8E1, #E8C97A);
  font: 700 0.72rem/1 var(--font);
  color: #4A2E1C;
  box-shadow: 0 1px 2px rgba(20, 10, 4, 0.25);
}

/* Notifications panel */
.prayer-notify-panel {
  position: absolute;
  z-index: 9;
  top: calc(var(--header-h, 64px) + 6px);
  right: 1rem;
  width: min(24rem, calc(100% - 2rem));
  max-height: min(70vh, 520px);
  overflow: auto;
  background: linear-gradient(180deg, #FFFDF7, #FBF3E2);
  border: 1px solid #C9A24B;
  border-radius: 16px;
  box-shadow: 0 14px 36px rgba(20, 10, 4, 0.35);
  color: #4A2E1C;
  padding: 0.7rem 0.85rem 0.85rem;
  box-sizing: border-box;
}
.prayer-notify-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin: 0 0 0.4rem;
}
.prayer-notify-head h3 {
  margin: 0;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 1.25rem;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}
.prayer-notify-list { list-style: none; margin: 0; padding: 0; }
.prayer-note {
  margin: 0 0 0.55rem;
  padding: 0.55rem 0.6rem;
  background: rgba(138, 94, 59, 0.08);
  border-radius: 12px;
  cursor: pointer;
}
.prayer-note.is-unread { box-shadow: inset 3px 0 0 #C9A24B; }
.prayer-note p { margin: 0 0 0.35rem; font-size: 0.88rem; line-height: 1.4; }
.prayer-note-lights {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  font-size: 0.78rem;
  font-weight: 700;
  color: #6B4A2B;
}
.prayer-note-lights span { display: inline-flex; align-items: center; gap: 0.15rem; }
.prayer-notify-foot {
  margin: 0.4rem 0 0;
  font-size: 0.72rem;
  color: #8A5E3B;
  line-height: 1.35;
}

@media (max-width: 839px) {
  .prayer-page-lede { font-size: 0.95rem; padding: 0 0.75rem; }
  .prayer-page-title { font-size: 1.85rem; }
  .prayer-map-col { padding-top: 46px; }
  .prayer-panel { margin-bottom: calc(4.25rem + env(safe-area-inset-bottom, 0px)); }
  .prayer-card { top: 48%; }
}

@media (prefers-reduced-motion: reduce) {
  .prayer-entry,
  .prayer-page { transition: opacity 0.45s ease !important; transform: none !important; }
  .leaflet-marker-icon.prayer-candle-marker { animation: none !important; }
}



/* ===== v97: light-cross overlay, request form, list breakdown, My Prayers ===== */
.prayer-light-cross {
  position: absolute;
  left: 10.23%;
  top: 16.75%;
  width: 168px;
  height: 236px;
  transform: translate(-50%, -32.14%);
  z-index: 2;
  pointer-events: none;
}
.prayer-light-cross-veil {
  position: absolute;
  left: 50%;
  top: 32.14%;
  width: 150px;
  height: 150px;
  transform: translate(-50%, -50%);
  background: radial-gradient(circle, rgba(74, 46, 28, 0.7) 0%, rgba(92, 58, 34, 0.42) 38%, rgba(74, 46, 28, 0.12) 62%, transparent 74%);
}
.prayer-light-cross-svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: visible;
  filter: drop-shadow(0 0 10px rgba(255, 232, 170, 0.55)) drop-shadow(0 0 22px rgba(232, 201, 122, 0.4));
  animation: prayer-cross-twinkle 4.8s ease-in-out infinite;
}
@keyframes prayer-cross-twinkle {
  0%, 100% { opacity: 0.84; filter: drop-shadow(0 0 8px rgba(255, 232, 170, 0.45)) drop-shadow(0 0 18px rgba(232, 201, 122, 0.3)); }
  42% { opacity: 1; filter: drop-shadow(0 0 14px rgba(255, 246, 220, 0.85)) drop-shadow(0 0 28px rgba(232, 201, 122, 0.55)); }
  68% { opacity: 0.9; filter: drop-shadow(0 0 10px rgba(255, 232, 170, 0.6)) drop-shadow(0 0 20px rgba(232, 201, 122, 0.4)); }
}

.prayer-myp-link {
  appearance: none;
  background: transparent;
  border: 0;
  padding: 0.3rem 0.45rem;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-weight: 600;
  font-size: 1.15rem;
  color: #F3DE9A;
  cursor: pointer;
  text-shadow: 0 1px 2px rgba(20, 10, 4, 0.9);
}
.prayer-myp-link:hover,
.prayer-myp-link:focus-visible {
  color: #FFF1C7;
  outline: none;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.prayer-myp-link-panel {
  margin-left: auto;
  font-size: 1rem;
  color: #8A5E3B;
  text-shadow: none;
}
.prayer-myp-link-panel:hover,
.prayer-myp-link-panel:focus-visible { color: #4A2E1C; }

.prayer-request-cta {
  appearance: none;
  display: block;
  width: 100%;
  margin: 0 0 0.7rem;
  padding: 0.55rem 0.9rem;
  border-radius: 999px;
  border: 1px solid #C9A24B;
  background: linear-gradient(180deg, #F6E4A8, #C9A24B);
  color: #4A2E1C;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-weight: 700;
  font-size: 1.15rem;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(20, 10, 4, 0.25);
}
.prayer-request-cta:hover,
.prayer-request-cta:focus-visible {
  background: linear-gradient(180deg, #FFF1C7, #E8C97A);
  outline: none;
  box-shadow: 0 0 0 2px rgba(255, 246, 212, 0.45), 0 2px 10px rgba(20, 10, 4, 0.3);
}

.prayer-request-form-wrap {
  position: absolute;
  z-index: 9;
  top: calc(var(--header-h, 64px) + 8px);
  right: 1rem;
  width: min(24.75rem, calc(100% - 2rem));
  max-height: min(88vh, 720px);
  overflow: auto;
  background: linear-gradient(180deg, #FFFDF7, #FBF3E2);
  color: #4A2E1C;
  border: 1px solid #C9A24B;
  border-radius: 16px;
  padding: 0.75rem 0.9rem 0.9rem;
  margin: 0;
  box-shadow: 0 14px 36px rgba(20, 10, 4, 0.35);
  box-sizing: border-box;
}
.prayer-request-form-wrap h4 {
  position: sticky;
  top: 0;
  margin: 0 0 0.3rem;
  padding: 0.1rem 0 0.25rem;
  background: linear-gradient(180deg, #FFFDF7, #FBF3E2);
  font-family: "Cormorant Garamond", Georgia, serif;
  font-weight: 700;
  font-size: 1.25rem;
  color: #4A2E1C;
  z-index: 1;
}
.prayer-form-note,
.prayer-field-hint {
  margin: 0 0 0.45rem;
  font-size: 0.82rem;
  line-height: 1.4;
  color: #6B4A2B;
}
.prayer-field-hint { margin: 0.1rem 0 0.5rem; font-size: 0.78rem; }
.prayer-request-form-wrap label,
.prayer-notify-pref legend {
  display: block;
  margin: 0 0 0.2rem;
  font-size: 0.92rem;
  font-weight: 700;
  color: #4A2E1C;
}
.prayer-opt { font-weight: 500; color: #8A5E3B; }
.prayer-request-form-wrap input[type="text"],
.prayer-request-form-wrap textarea,
.prayer-request-form-wrap select {
  width: 100%;
  box-sizing: border-box;
  margin: 0 0 0.4rem;
  padding: 0.42rem 0.6rem;
  font: 500 1rem/1.4 var(--font);
  color: #4A2E1C;
  background: #FFFDF7;
  border: 1px solid #E6D3A3;
  border-radius: 10px;
}
.prayer-request-form-wrap textarea { min-height: 3.6rem; resize: vertical; }
.prayer-request-form-wrap input:focus-visible,
.prayer-request-form-wrap textarea:focus-visible,
.prayer-request-form-wrap select:focus-visible {
  outline: none;
  border-color: #C9A24B;
  box-shadow: 0 0 0 2px rgba(201, 162, 75, 0.35);
}
.prayer-anon-row { margin: 0 0 0.4rem; }
.prayer-anon-toggle {
  display: flex !important;
  align-items: center;
  gap: 0.4rem;
  font-weight: 600 !important;
  margin: 0.15rem 0 0 !important;
  cursor: pointer;
}
.prayer-notify-pref {
  margin: 0 0 0.55rem;
  padding: 0.45rem 0.6rem 0.35rem;
  border: 1px solid #E6D3A3;
  border-radius: 10px;
}
.prayer-notify-pref legend { padding: 0 0.25rem; }
.prayer-notify-pref label {
  display: flex !important;
  align-items: center;
  gap: 0.4rem;
  font-weight: 600 !important;
  margin: 0.2rem 0 !important;
  cursor: pointer;
}
.prayer-form-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
}
.prayer-form-submit {
  appearance: none;
  border: 1px solid #C9A24B;
  border-radius: 999px;
  padding: 0.5rem 1.05rem;
  background: linear-gradient(180deg, #F6E4A8, #C9A24B);
  color: #4A2E1C;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-weight: 700;
  font-size: 1.08rem;
  cursor: pointer;
}
.prayer-form-submit:hover,
.prayer-form-submit:focus-visible {
  background: linear-gradient(180deg, #FFF1C7, #E8C97A);
  outline: none;
}
.prayer-form-cancel {
  appearance: none;
  background: transparent;
  border: 0;
  color: #6B4A2B;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  padding: 0.4rem 0.3rem;
}
.prayer-form-cancel:hover,
.prayer-form-cancel:focus-visible { color: #4A2E1C; text-decoration: underline; outline: none; }

.prayer-request-confirm {
  background: linear-gradient(180deg, #FFFDF7, #FBF3E2);
  border: 1px solid #C9A24B;
  border-left: 4px solid #C9A24B;
  border-radius: 12px;
  color: #4A2E1C;
  padding: 0.7rem 0.8rem;
  margin: 0 0 0.75rem;
  font-size: 0.95rem;
  line-height: 1.45;
}
.prayer-request-confirm strong { color: #4A2E1C; }
.prayer-request-confirm .prayer-form-note { margin: 0.35rem 0 0; }

.prayer-yours-badge {
  display: inline-block;
  margin-left: 0.3rem;
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #4A2E1C;
  background: linear-gradient(180deg, #F6E4A8, #E8C97A);
  border-radius: 999px;
  padding: 0.1rem 0.4rem;
  vertical-align: middle;
}
.prayer-answered-badge {
  display: inline-block;
  margin-left: 0.3rem;
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: #FFF8E8;
  background: #5C3A22;
  border: 1px solid #C9A24B;
  border-radius: 999px;
  padding: 0.1rem 0.4rem;
  vertical-align: middle;
}
.prayer-request-item.is-answered .prayer-request-open { opacity: 0.86; }
.prayer-breakdown {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem 0.7rem;
  margin-top: 0.3rem;
  font-size: 0.8rem;
  font-weight: 600;
  color: #F0D78A;
}
.prayer-breakdown strong {
  font-weight: 700;
  color: #F6E4A8;
}
.prayer-breakdown-color {
  display: inline-flex;
  align-items: center;
  gap: 0.18rem;
  color: #FFF8E8;
}
.prayer-breakdown-color img {
  width: 16px;
  height: 21px;
  object-fit: contain;
}
.prayer-list-flag { color: #F0D78A; font-size: 0.72rem; }

.prayer-dash {
  position: absolute;
  z-index: 9;
  top: calc(var(--header-h, 64px) + 6px);
  right: 1rem;
  width: min(24.75rem, calc(100% - 2rem));
  max-height: min(78vh, 640px);
  overflow: auto;
  background: linear-gradient(180deg, #FFFDF7, #FBF3E2);
  border: 1px solid #C9A24B;
  border-radius: 16px;
  box-shadow: 0 14px 36px rgba(20, 10, 4, 0.35);
  color: #4A2E1C;
  padding: 0.75rem 0.9rem 0.9rem;
  box-sizing: border-box;
}
.prayer-dash-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin: 0 0 0.5rem;
}
.prayer-dash-head h3 {
  margin: 0;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 1.4rem;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}
.prayer-dash-body { display: flex; flex-direction: column; gap: 0.75rem; }
.prayer-dash-empty {
  margin: 0.4rem 0;
  font-size: 1rem;
  line-height: 1.45;
}
.prayer-dash-item {
  background: rgba(138, 94, 59, 0.08);
  border: 1px solid rgba(201, 162, 75, 0.35);
  border-radius: 14px;
  padding: 0.7rem 0.75rem 0.8rem;
}
.prayer-dash-item.is-answered { background: rgba(138, 94, 59, 0.05); }
.prayer-dash-item h4 {
  margin: 0 0 0.2rem;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-weight: 700;
  font-size: 1.2rem;
  color: #4A2E1C;
}
.prayer-dash-date {
  margin: 0 0 0.4rem;
  font-size: 0.8rem;
  color: #8A5E3B;
}
.prayer-dash-item p.prayer-dash-body-text {
  margin: 0 0 0.5rem;
  font-size: 1rem;
  line-height: 1.5;
}
.prayer-dash-meanings {
  list-style: none;
  margin: 0 0 0.45rem;
  padding: 0;
  font-size: 0.88rem;
  line-height: 1.4;
}
.prayer-dash-meanings li {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  margin: 0 0 0.15rem;
}
.prayer-dash-meanings img {
  width: 22px;
  height: 28px;
  object-fit: contain;
  flex: none;
}
.prayer-dash-notices { margin: 0.35rem 0 0.5rem; }
.prayer-dash-notices h5 {
  margin: 0 0 0.25rem;
  font-size: 0.82rem;
  font-weight: 700;
  color: #6B4A2B;
  letter-spacing: 0.02em;
}
.prayer-dash-notices p {
  margin: 0 0 0.25rem;
  font-size: 0.86rem;
  line-height: 1.4;
  color: #4A2E1C;
}
.prayer-dash-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-top: 0.35rem;
}
.prayer-dash-actions button {
  appearance: none;
  border-radius: 999px;
  padding: 0.4rem 0.8rem;
  font-size: 0.88rem;
  font-weight: 700;
  cursor: pointer;
}
.prayer-mark-answered {
  border: 1px solid #C9A24B;
  background: #FFF8E1;
  color: #4A2E1C;
}
.prayer-mark-answered[aria-pressed="true"] {
  background: #5C3A22;
  color: #F6E4A8;
  border-color: #5C3A22;
}
.prayer-dash-share {
  border: 1px solid #C9A24B;
  background: linear-gradient(180deg, #F6E4A8, #C9A24B);
  color: #4A2E1C;
}
.prayer-dash-actions button:hover,
.prayer-dash-actions button:focus-visible {
  box-shadow: 0 0 0 2px rgba(201, 162, 75, 0.35);
  outline: none;
}
.prayer-dash-foot {
  margin: 0.65rem 0 0;
  font-size: 0.78rem;
  color: #8A5E3B;
  line-height: 1.35;
}

.prayer-notify-head { flex-wrap: wrap; }

@media (max-width: 839px) {
  .prayer-light-cross {
    left: 13%;
    top: 8.8%;
    width: 112px;
    height: 158px;
    opacity: 0.9;
  }
  .prayer-myp-link { font-size: 1rem; padding: 0.25rem 0.3rem; }
  .prayer-request-form-wrap,
  .prayer-dash {
    left: 0.6rem;
    right: 0.6rem;
    width: auto;
    top: calc(var(--header-h, 64px) + 4px);
    max-height: min(72vh, 620px);
    margin-bottom: calc(4.25rem + env(safe-area-inset-bottom, 0px));
  }
}

@media (prefers-reduced-motion: reduce) {
  .prayer-light-cross-svg { animation: none !important; opacity: 0.95; }
}

/* ===== v99: prayer title placement, readable top controls, softer corner cross ===== */
/* Keep the hero's reserved height so the Prayer globe does not move.
   Sit the title higher in that space, centered over the globe on desktop. */
.prayer-page-hero {
  justify-content: flex-start;
  padding-top: 0.4rem;
}
@media (min-width: 840px) {
  .prayer-page-hero {
    width: calc(100% - 360px);
    padding-left: 1rem;
    padding-right: 1rem;
    box-sizing: border-box;
  }
}

/* Brown-gold pills so the top-right Prayer controls stay readable on glitter.
   Scoped to the page bar so in-panel "My Prayers" links are unchanged. */
.prayer-page-bar .prayer-myp-link,
.prayer-page-bar button.prayer-back,
.prayer-page button.prayer-back,
.prayer-flip.is-page .prayer-page-bar button.prayer-back {
  background: rgba(60, 36, 20, 0.75);
  border: 1px solid #C9A24B;
  border-radius: 999px;
  color: #FFF6D4;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-weight: 700;
  font-size: 1.05rem;
  line-height: 1.2;
  text-shadow: none;
  padding: 0.35rem 0.85rem;
  box-shadow: 0 1px 4px rgba(20, 10, 4, 0.35);
}
/* v109q: Grace Map uses the upright gold map feather, sized like the candle */
.prayer-page-bar button.prayer-back,
.prayer-flip.is-page .prayer-page-bar button.prayer-back {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.3rem 0.85rem 0.3rem 0.55rem;
  white-space: nowrap;
  flex-shrink: 0;
}
.prayer-page-bar button.prayer-back img,
.prayer-flip.is-page .prayer-page-bar button.prayer-back img {
  display: block;
  width: 16px;
  height: 30px;
  object-fit: contain;
  flex: 0 0 auto;
  filter: drop-shadow(0 0 3px rgba(255, 220, 120, 0.45));
}
.prayer-flip:not(.is-page) button.prayer-back img {
  display: none;
}
.prayer-page-bar .prayer-myp-link:hover,
.prayer-page-bar .prayer-myp-link:focus-visible,
.prayer-page-bar button.prayer-back:hover,
.prayer-page-bar button.prayer-back:focus-visible,
.prayer-page button.prayer-back:hover,
.prayer-page button.prayer-back:focus-visible {
  color: #FFF6D4;
  background: rgba(74, 46, 28, 0.92);
  border-color: #E8C97A;
  text-decoration: none;
  outline: none;
}
.prayer-page-bar .prayer-notify-btn {
  background: rgba(60, 36, 20, 0.75);
  border: 1px solid #C9A24B;
  border-radius: 50%;
  width: 48px;
  height: 48px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  filter: none;
  box-shadow: 0 1px 4px rgba(20, 10, 4, 0.35);
  box-sizing: border-box;
}
.prayer-page-bar .prayer-notify-btn:hover,
.prayer-page-bar .prayer-notify-btn:focus-visible {
  background: rgba(74, 46, 28, 0.92);
  border-color: #E8C97A;
  outline: none;
}
.prayer-page-bar .prayer-notify-btn img {
  width: 18px;
  height: 34px;
}
@media (max-width: 839px) {
  /* Keep the frosted bar only behind the pills so the light-cross at the
     top-left stays fully visible. */
  .prayer-page-bar,
  .prayer-flip.is-page .prayer-page-bar {
    gap: 0.5rem;
    padding: 0 0.5rem;
    width: max-content;
    max-width: 100%;
    margin-left: auto;
    align-self: flex-end;
  }
  .prayer-page-bar .prayer-myp-link,
  .prayer-page-bar .prayer-myp-btn,
  .prayer-page-bar button.prayer-back,
  .prayer-flip.is-page .prayer-page-bar button.prayer-back,
  .prayer-flip.is-page .prayer-page-bar .prayer-myp-btn {
    font-size: 0.95rem;
    white-space: nowrap;
    flex-shrink: 0;
  }
  .prayer-page-bar .prayer-myp-btn,
  .prayer-flip.is-page .prayer-page-bar .prayer-myp-btn {
    padding: 0.24rem 0.55rem 0.24rem 0.36rem;
    gap: 0.32rem;
  }
  .prayer-page-bar button.prayer-back,
  .prayer-flip.is-page .prayer-page-bar button.prayer-back {
    padding: 0.24rem 0.55rem 0.24rem 0.36rem;
    gap: 0.32rem;
  }
  .prayer-page-bar button.prayer-back img,
  .prayer-flip.is-page .prayer-page-bar button.prayer-back img {
    width: 16px;
    height: 30px;
  }
}

/* Slightly softer corner light-cross — still present, a little less bright. */
.prayer-light-cross-svg {
  filter: drop-shadow(0 0 8px rgba(255, 232, 170, 0.4)) drop-shadow(0 0 16px rgba(232, 201, 122, 0.28));
  opacity: 0.72;
}
@keyframes prayer-cross-twinkle {
  0%, 100% { opacity: 0.66; filter: drop-shadow(0 0 6px rgba(255, 232, 170, 0.32)) drop-shadow(0 0 14px rgba(232, 201, 122, 0.22)); }
  42% { opacity: 0.82; filter: drop-shadow(0 0 10px rgba(255, 246, 220, 0.55)) drop-shadow(0 0 20px rgba(232, 201, 122, 0.38)); }
  68% { opacity: 0.72; filter: drop-shadow(0 0 8px rgba(255, 232, 170, 0.42)) drop-shadow(0 0 16px rgba(232, 201, 122, 0.28)); }
}

/* v99: Request a Prayer form lives in the brown side column */
.prayer-panel .prayer-request-form-wrap[hidden] { display: none !important; }
.prayer-panel .prayer-request-form-wrap {
  position: relative;
  left: auto;
  right: auto;
  top: auto;
  z-index: auto;
  display: block;
  width: 100%;
  max-height: none;
  overflow: visible;
  background: rgba(255, 248, 232, 0.08);
  color: #FFF8E8;
  border: 1px solid rgba(232, 201, 122, 0.35);
  border-radius: 12px;
  padding: 0.55rem 0.65rem 0.65rem;
  margin: 0 0 0.55rem;
  box-shadow: none;
  box-sizing: border-box;
}
.prayer-panel .prayer-request-form-wrap h4 {
  position: static;
  margin: 0 0 0.3rem;
  padding: 0;
  background: transparent;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-weight: 700;
  font-size: 1.25rem;
  color: #FFF6D4;
  text-shadow: none;
  z-index: auto;
}
.prayer-panel .prayer-form-note,
.prayer-panel .prayer-field-hint {
  color: #F0D9B0;
  font-size: 0.82rem;
  line-height: 1.4;
}
.prayer-panel .prayer-field-hint { font-size: 0.78rem; }
.prayer-panel .prayer-request-form-wrap label,
.prayer-panel .prayer-notify-pref legend {
  color: #FFF6D4;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-weight: 700;
  font-size: 1.05rem;
}
.prayer-panel .prayer-opt { font-weight: 600; color: #F0D78A; }
.prayer-panel .prayer-request-form-wrap input[type="text"],
.prayer-panel .prayer-request-form-wrap textarea,
.prayer-panel .prayer-request-form-wrap select {
  width: 100%;
  box-sizing: border-box;
  margin: 0 0 0.3rem;
  padding: 0.4rem 0.55rem;
  font: 500 1rem/1.4 var(--font);
  color: #FFF8E8;
  background: rgba(20, 12, 6, 0.4);
  border: 1px solid rgba(232, 201, 122, 0.45);
  border-radius: 10px;
  caret-color: #FFF6D4;
}
.prayer-panel .prayer-request-form-wrap textarea { min-height: 2.8rem; resize: vertical; }
.prayer-panel .prayer-request-form-wrap option { color: #4A2E1C; background: #FBF3E2; }
.prayer-panel .prayer-request-form-wrap input::placeholder,
.prayer-panel .prayer-request-form-wrap textarea::placeholder {
  color: #E8D3A8;
  opacity: 0.8;
}
.prayer-panel .prayer-request-form-wrap input:focus-visible,
.prayer-panel .prayer-request-form-wrap textarea:focus-visible,
.prayer-panel .prayer-request-form-wrap select:focus-visible {
  outline: none;
  border-color: #E8C97A;
  box-shadow: 0 0 0 2px rgba(232, 201, 122, 0.35);
}
.prayer-panel .prayer-notify-pref {
  margin: 0 0 0.55rem;
  padding: 0.45rem 0.6rem 0.35rem;
  border: 1px solid rgba(232, 201, 122, 0.35);
  border-radius: 10px;
  background: rgba(20, 12, 6, 0.22);
}
.prayer-panel .prayer-notify-pref legend { padding: 0 0.25rem; color: #FFF6D4; }
.prayer-panel .prayer-notify-pref label,
.prayer-panel .prayer-anon-toggle {
  color: #FFF8E8 !important;
  font-weight: 600 !important;
}
.prayer-panel .prayer-form-cancel {
  color: #F0D9B0;
  font-size: 1rem;
  font-weight: 600;
}
.prayer-panel .prayer-form-cancel:hover,
.prayer-panel .prayer-form-cancel:focus-visible {
  color: #FFF6D4;
  text-decoration: underline;
  outline: none;
}
.prayer-panel .prayer-request-confirm {
  background: rgba(255, 248, 232, 0.08);
  border: 1px solid rgba(232, 201, 122, 0.35);
  border-left: 4px solid #C9A24B;
  border-radius: 12px;
  color: #FFF8E8;
}
.prayer-panel .prayer-request-confirm strong { color: #FFF6D4; }
.prayer-panel .prayer-request-confirm .prayer-form-note { color: #F0D9B0; }

/* ===== v100: lifted Prayer column, My Prayer Request pill, globe controls ===== */

/* Desktop: column starts just under the top-right buttons and runs to the bottom. */
@media (min-width: 840px) {
  .prayer-page-body {
    position: static;
  }
  .prayer-page .prayer-panel {
    position: absolute;
    top: var(--header-h, 64px);
    right: 0;
    bottom: 0;
    width: 360px;
    max-width: 360px;
    flex: none;
    height: auto;
    z-index: 5;
    border-top: 0;
    border-left: 1px solid rgba(232, 201, 122, 0.35);
  }
  .prayer-page .prayer-map-col {
    width: 100%;
    flex: 1 1 auto;
    padding: 11px 360px 8px 0;
    box-sizing: border-box;
  }
}

/* Combined candle + label pill. Replaces the unlabeled candle and the separate My Prayers link. */
.prayer-page-bar .prayer-myp-btn {
  appearance: none;
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  background: rgba(60, 36, 20, 0.75);
  border: 1px solid #C9A24B;
  border-radius: 999px;
  color: #FFF6D4;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-weight: 700;
  font-size: 1.05rem;
  line-height: 1.2;
  padding: 0.3rem 0.9rem 0.3rem 0.55rem;
  cursor: pointer;
  text-shadow: none;
  box-shadow: 0 1px 4px rgba(20, 10, 4, 0.35);
}
.prayer-page-bar .prayer-myp-btn img {
  display: block;
  width: 16px;
  height: 30px;
  object-fit: contain;
  filter: drop-shadow(0 0 3px rgba(255, 220, 120, 0.45));
}
.prayer-page-bar .prayer-myp-btn:hover,
.prayer-page-bar .prayer-myp-btn:focus-visible {
  color: #FFF6D4;
  background: rgba(74, 46, 28, 0.92);
  border-color: #E8C97A;
  outline: none;
}
.prayer-page-bar .prayer-myp-btn .prayer-nav-badge {
  top: -6px;
  right: -6px;
}
.prayer-myp-label-short { display: none; }
@media (max-width: 839px) {
  .prayer-myp-label-full { display: none; }
  .prayer-myp-label-short { display: inline; }
  .prayer-page-bar .prayer-myp-btn { font-size: 1rem; padding: 0.28rem 0.7rem 0.28rem 0.45rem; }
}

/* Location is never a street address. */
.prayer-panel .prayer-loc-note {
  margin: 0 0 0.55rem;
  font-size: 0.82rem;
  line-height: 1.4;
  color: #F0D9B0;
}
.prayer-panel .prayer-loc-note.is-fallback { color: #F6E4A8; }

/* Same zoom placement and look as the main map globe. */
#prayer-map .leaflet-bottom.leaflet-right { bottom: 14%; right: 14%; }
#prayer-map .leaflet-control-zoom {
  position: relative;
  overflow: visible;
  opacity: 0.85;
}
#prayer-map .leaflet-control-zoom:hover { opacity: 1; }
#prayer-map .leaflet-bottom.leaflet-left {
  bottom: 6%;
  left: 50%;
  transform: translateX(-50%);
}
#prayer-map .calm-base { filter: sepia(0.35) saturate(1.1) brightness(0.98); }

/* ===== v102: Prayer title is Cormorant Garamond italic 600, slightly tracked ===== */

/* ===== v103: Prayer subtitle wording only ===== */

/* ===== v104: larger Prayer title and subtitle fill the sky; globe size and y stay put ===== */
/* Hero height (--map-hero-h) and map-col padding are unchanged so the globe does not move.
   The title block is packed toward the globe and may overflow the hero into the existing
   empty padding, leaving a comfortable gap above the globe. */
@media (min-width: 840px) {
  .prayer-page-hero {
    justify-content: flex-end;
    padding-top: 0;
    padding-bottom: 27px;
  }
  .prayer-page-title { font-size: 3.7rem; }
  .prayer-page-lede { font-size: 1.2rem; }
}
@media (max-width: 839px) {
  .prayer-page-hero {
    justify-content: flex-end;
    padding-top: 0;
  }
  .prayer-page-title { font-size: 2.5rem; }
  .prayer-page-lede {
    font-size: 1.1rem;
    padding: 0 0.75rem;
    margin-bottom: -13px;
  }
}

/* ===== v105: five tea-light types; keep breakdown counts on one row ===== */
.prayer-breakdown {
  gap: 0.2rem 0.38rem;
}
.prayer-dash {
  max-height: min(84vh, 700px);
}


/* ===== v108c preview: phone intro readable (~17px body, two-line headline); tight cream box ===== */
@media (max-width: 839px) {
  /* One-line headline at this width had to drop below ~19px, so restore two lines at a larger size. */
  .ph-br { display: block; }
  body[data-screen="map"] #map-home .welcome.map-hero h1,
  .welcome.map-hero h1 {
    font-size: 22px;
    letter-spacing: 0.02em;
    line-height: 1.14;
    white-space: normal;
    margin: 0;
  }
  /* Drop the v108b one-line spacer and shrink leftover cream padding. */
  body[data-screen="map"] #map-home .welcome.map-hero {
    padding: 0.08rem 0.4rem 0.06rem;
    gap: 0.04rem;
  }
  body[data-screen="map"] #map-home .welcome.map-hero .welcome-copy > p:not(.welcome-tap) {
    font-family: "Cormorant Garamond", "Palatino Linotype", Palatino, Georgia, serif;
    font-weight: 600;
    font-size: 17px;
    line-height: 1.14;
    letter-spacing: 0.01em;
    color: #4A2C16;
    text-align: center;
  }
  html.bg-gold-glitter body[data-screen="map"] #map-home .welcome.map-hero .welcome-copy > p:not(.welcome-tap) {
    color: #F6E6C4;
  }
  /* A little less air under the script cue so the globe stays closer to y=237. */
  body[data-screen="map"] #map-home .touch-cue {
    margin: 0.16rem auto -0.18rem;
  }
}


/* ===== v108e preview: phone short-Safari — orb on the globe, compact footer =====
   At real iPhone Safari heights the prayer planet sat below the globe and under
   the nav. Keep intro type from v108c. Laptop is unchanged. */
@media (max-width: 839px) {
  /* Close a little air between the intro, the script cue, and the globe. */
  body[data-screen="map"] #map-home .touch-cue {
    margin: 0.04rem auto 0;
  }
  body[data-screen="map"] #map-home .map-controls {
    margin: 0;
    min-height: 0;
    height: 0;
    overflow: hidden;
    position: absolute;
  }

  /* Orb no longer needs a 148px band under the globe. */
  body[data-screen="map"] #map-home .map-globe-stack {
    display: block;
    position: relative;
    width: fit-content;
    max-width: 100%;
    margin: 0 auto;
    overflow: visible;
  }

  /* Sit the Ask for Prayer planet on the lower-right rim of the globe. */
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb {
    position: absolute;
    left: auto;
    right: -16px;
    top: auto;
    bottom: 10px;
    transform: none;
    margin: 0;
    z-index: 9;
    width: 116px;
    height: 116px;
  }
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-orb-cluster,
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-captions {
    width: 116px;
    height: 116px;
  }
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-orb {
    width: 62px;
    height: 62px;
  }
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-candle {
    width: 40px;
    height: 40px;
  }
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-caption {
    font-size: 13.5px;
    font-weight: 700;
    letter-spacing: 0.3px;
    stroke-width: 2px;
  }

  /* Dedication + counter: one compact centered row below the first screen
     (they had been pulled into the 148px band, which sat under the nav). */
  body[data-screen="map"] #map-home:has(.prayer-turn-orb) .map-dedication,
  body[data-screen="map"] #map-home .map-dedication {
    position: static;
    z-index: auto;
    align-self: center;
    width: auto;
    max-width: min(100%, 360px);
    margin: 10px 12px 0 !important;
    padding: 0;
    text-align: center;
    font-size: 0.78rem !important;
    line-height: 1.25;
    font-weight: 600;
  }
  body[data-screen="map"] #map-home:has(.prayer-turn-orb) .map-wrap > .grace-counter,
  body[data-screen="map"] #map-home .map-wrap > .grace-counter {
    position: static;
    z-index: auto;
    align-self: center !important;
    justify-content: center;
    width: fit-content;
    max-width: calc(100% - 16px);
    margin: 4px auto 12px !important;
  }

  /* Size the globe to the leftover height under intro + cue, above the nav.
     min(vw, available height) — shrink only when the short Safari window requires it. */
  body[data-screen="map"] #map-home .map-circle-glow {
    --globe: min(
      calc(100vw - 20px),
      calc(100svh - var(--header-h, 64px) - var(--map-hero-h, 110px) - 96px)
    ) !important;
    margin: 0 auto !important;
  }

  /* Keep +/- and World clear of the prayer planet on the right rim. */
  /* Sit zoom just above the prayer planet, still on the right, inside the rim. */
  body[data-screen="map"] #map-home .leaflet-bottom.leaflet-right {
    right: 14px;
    left: auto;
    bottom: 126px;
  }
}


/* ===== v108 wrap: phone intro — no single-word last line =====
   text-wrap: pretty first (fallback), then balance. Laptop is unchanged.
   Last four words are also joined with &nbsp; for Safari without balance. */
@media (max-width: 839px) {
  body[data-screen="map"] #map-home .welcome.map-hero .welcome-copy > p:not(.welcome-tap),
  .welcome.map-hero .welcome-copy > p:not(.welcome-tap) {
    text-wrap: pretty;
    text-wrap: balance;
  }
}

/* ===== v108-H preview: phone headline — drop 'bring'; taper on Moments of Grace =====
   Laptop keeps “Feathers from Heaven bring Moments of Grace” on one line. */
.h1-comma { display: none; }
@media (max-width: 839px) {
  .h1-comma { display: inline; }
  .h1-bring { display: none; }
  .ph-br { display: block; }
  body[data-screen="map"] #map-home .welcome.map-hero h1,
  .welcome.map-hero h1 {
    font-size: 22px;
    letter-spacing: 0.02em;
    line-height: 1.14;
    white-space: normal;
    text-align: center;
    margin: 0;
  }
}


/* ===== v108: phone Prayer globe matches the main map globe (size and y) =====
   v108e sized #map-home's globe to leftover height and the taller intro sits
   it lower. Prayer still used the older --map-bottom-h formula and the 46px
   map-col offset, so the flip landed 13px low and 9px small on short Safari.
   Laptop is unchanged. */
@media (max-width: 839px) {
  .prayer-page .map-circle-glow,
  .prayer-page .prayer-globe {
    --globe: min(
      calc(100vw - 20px),
      calc(100svh - var(--header-h, 64px) - var(--map-hero-h, 110px) - 96px)
    ) !important;
  }
  .prayer-page .prayer-map-col {
    padding-top: 33px;
  }
}

/* ===== v109 preview: phone tap-to-expand globe =====
   Resting size is 320px (not 300). Feathers stay at their normal 34×76
   size and clusters at 46px; they are not scaled with the globe. At 300px
   the 3 / 12 count bubbles and clusters sat tight on the Gulf; 320px keeps
   them clearly readable while still leaving more page than v108 (352–370).
   Expanded size matches v108's cap: min(100vw - 20px, height under the
   header and above the nav). Laptop is unchanged. */
@media (max-width: 839px) {
  body[data-screen="map"] #map-home .map-circle-glow {
    --globe-rest: 200px;
    --globe: min(var(--globe-rest), calc(100vw - 20px)) !important;
    transition: width 0.4s cubic-bezier(0.22, 1, 0.36, 1),
                height 0.4s cubic-bezier(0.22, 1, 0.36, 1),
                min-width 0.4s cubic-bezier(0.22, 1, 0.36, 1),
                min-height 0.4s cubic-bezier(0.22, 1, 0.36, 1);
  }
  body[data-screen="map"] #map-home .map-circle-glow.globe-noanim {
    transition: none;
  }
  body.globe-expanded[data-screen="map"] #map-home .map-circle-glow {
    --globe: min(
      var(--globe-expand, calc(100vw - 20px)),
      calc(100vw - 20px),
      calc(100svh - var(--header-h, 64px) - var(--nav-h, 54px) - 16px)
    ) !important;
  }

  /* Room to scroll the resting globe fully above the nav, including the orb. */
  body[data-screen="map"] #map-home .map-globe-stack {
    margin-bottom: calc(var(--nav-h, 54px) + 36px);
  }

  /* Resting: let vertical swipes scroll the page instead of dragging the map. */
  body[data-screen="map"]:not(.globe-expanded) #map-home #map {
    touch-action: pan-y;
  }
  body.globe-expanded[data-screen="map"] #map-home #map {
    touch-action: none;
  }

  /* Hide zoom / World while resting (gestures are off). */
  body[data-screen="map"]:not(.globe-expanded) #map-home .leaflet-bottom.leaflet-right {
    opacity: 0;
    pointer-events: none;
  }
  body.globe-expanded[data-screen="map"] #map-home .leaflet-bottom.leaflet-right {
    opacity: 1;
    pointer-events: auto;
  }

  .globe-expand-hit {
    position: absolute;
    inset: 0;
    border: 0;
    padding: 0;
    margin: 0;
    border-radius: 50%;
    background: transparent;
    cursor: pointer;
    z-index: 8;
    -webkit-tap-highlight-color: transparent;
  }
  body.globe-expanded .globe-expand-hit,
  .globe-expand-hit[hidden] { display: none; }

  .globe-explore-hint {
    position: absolute;
    left: 50%;
    bottom: 18%;
    transform: translateX(-50%);
    margin: 0;
    padding: 0.22rem 0.7rem;
    border-radius: 999px;
    border: 1px solid #C9A24B;
    background: rgba(245, 236, 220, 0.94);
    color: #4A2C16;
    font-family: "Cormorant Garamond", Georgia, serif;
    font-weight: 600;
    font-size: 13px;
    letter-spacing: 0.02em;
    line-height: 1.2;
    white-space: nowrap;
    box-shadow: 0 1px 4px rgba(74, 44, 22, 0.18);
    pointer-events: none;
    z-index: 8;
  }
  .globe-explore-hint.is-fading { opacity: 0; transition: opacity 0.4s ease; }
  .globe-explore-hint[hidden] { display: none; }

  .globe-close {
    position: absolute;
    top: -8px;
    right: -8px;
    width: 32px;
    height: 32px;
    padding: 0;
    border-radius: 50%;
    border: 1.5px solid #C9A24B;
    background: #FFF8E8;
    color: #4A2C16;
    font-size: 16px;
    line-height: 1;
    display: none;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 12;
    box-shadow: 0 1px 4px rgba(74, 44, 22, 0.25);
  }
  body.globe-expanded .globe-close:not([hidden]) { display: inline-flex; }
  .globe-close span { display: block; transform: translateY(-0.5px); }
  .globe-close:focus-visible { outline: 2px solid #C9A24B; outline-offset: 2px; }

  .globe-backdrop {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(40, 24, 14, 0.18);
    z-index: 6;
    border: 0;
  }
  body.globe-expanded .globe-backdrop:not([hidden]) { display: block; }

  /* Keep the prayer orb and the expanded globe above the backdrop. */
  body.globe-expanded[data-screen="map"] #map-home .map-globe-stack {
    position: relative;
    z-index: 7;
  }

  /* Prayer flip lands on the resting globe. */
  .prayer-page .map-circle-glow,
  .prayer-page .prayer-globe {
    --globe: min(200px, calc(100vw - 20px)) !important;
  }
}

@media (min-width: 840px) {
  .globe-expand-hit,
  .globe-explore-hint,
  .globe-close,
  .globe-backdrop { display: none !important; }
}

/* ===== v109c preview: phone — v109 orb on the rim; raise stories + invite =====
   The Ask for Prayer planet is back on the resting globe's lower-right rim at
   the v109 size, with the original curved captions. No under-row, no pills.
   Phone hides the Moments of Grace counter and the "In this moment" line
   (laptop keeps both). The stories column and the join invite follow the
   globe after a small gap — the large stack margin from v109 is dropped.
   Resting globe stays 320px with tap-to-expand. Map recenter ([38, -78])
   stays so the "3" bubble is fully visible at rest. */
@media (max-width: 839px) {
  body[data-screen="map"] #map-home .map-dedication {
    display: none !important;
  }
  body[data-screen="map"] #map-home .grace-counter,
  body[data-screen="map"] #map-home .map-wrap > .grace-counter {
    display: none !important;
  }

  /* Small gap under the globe (orb sits on the rim, not in this band). */
  body[data-screen="map"] #map-home .map-globe-stack {
    margin-bottom: 12px !important;
  }

  body[data-screen="map"] #map-home .join-invite,
  body[data-screen="map"] #map-home .journal-invite {
    margin-top: 0 !important;
    margin-bottom: 10px !important;
  }

  body[data-screen="map"] #map-home > .panel {
    margin-top: 0;
    padding-top: 4px;
  }
  /* Join invite is moved after the first story card; keep a compact card there. */
  body[data-screen="map"] #feed-list .join-invite,
  body[data-screen="map"] #feed-list .journal-invite {
    margin: 12px auto 14px !important;
    width: 100%;
  }
  body[data-screen="map"] aside.panel > .feather-legend {
    margin: 12px auto 8px;
  }

  /* Prayer flip still lands on the 320 resting globe (v108 33px offset). */
  .prayer-page .prayer-map-col {
    padding-top: 33px;
  }
}

/* ===== v109c-small preview: 200px resting globe so stories peek on the first screen =====
   Same as v109c (orb on the rim, curved captions, no phone counter / dedication,
   stories + invite follow the globe). Resting globe is 200px so that at 390×664
   the filters, "Moments of Grace" heading, and the top of the first story card
   sit above the nav without scrolling. Feathers stay full size. The rim cluster
   is scaled to 92px (planet 50px) so it doesn't crowd the smaller globe; caption
   type stays 13px. Laptop is unchanged (these rules are phone-only). */
@media (max-width: 839px) {
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb,
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-orb-cluster,
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-captions {
    width: 92px !important;
    height: 92px !important;
  }
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-orb {
    width: 50px !important;
    height: 50px !important;
  }
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-candle {
    width: 32px !important;
    height: 32px !important;
  }
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-caption {
    font-size: 13px !important;
    stroke-width: 2px;
  }
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb {
    right: -12px !important;
    bottom: 6px !important;
  }
}

/* ===== v109d-orb preview: phone — prayer planet in the right-corner sky =====
   Resting globe stays 200px. The Ask for Prayer planet leaves the rim and sits
   in the open sky to the right of the globe, level with the globe's lower half.
   It is position:absolute, so it does not push the stories stream down.
   Cluster width is capped to the side slot so 375 / 390 / 430 do not clip.
   Planet aims for 56–62px when the slot allows (still larger than the 50px rim
   version). Curved captions stay ≥13px. No visible box around the orb.
   Expanded 370px globe leaves no side slot, so the corner orb is hidden.
   Laptop is unchanged (phone-only rules). */
@media (max-width: 839px) {
  body[data-screen="map"] #map-home .map-globe-stack {
    overflow: visible !important;
  }
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb {
    position: absolute !important;
    left: 100% !important;
    right: auto !important;
    top: auto !important;
    /* Sit in the lower-right sky, level with the globe's lower half. */
    bottom: 2px !important;
    margin: 0 0 0 6px !important;
    transform: none !important;
    z-index: 9;
    /* Slot = space to the right of the 200px globe, minus a screen margin. */
    --orb-slot: calc((100vw - var(--globe-rest, 200px)) / 2 - 10px);
    width: min(110px, max(78px, var(--orb-slot))) !important;
    height: min(110px, max(78px, var(--orb-slot))) !important;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: none !important;
    box-shadow: none !important;
    overflow: visible !important;
  }
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-orb-cluster,
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-captions {
    width: 100% !important;
    height: 100% !important;
    overflow: visible !important;
  }
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-orb {
    /* 56–62px when the cluster is large enough; shrink only in a tight slot. */
    width: min(62px, 66%) !important;
    height: min(62px, 66%) !important;
  }
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-candle {
    width: min(40px, 64%) !important;
    height: min(40px, 64%) !important;
  }
  body[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb .prayer-caption {
    font-size: 13px !important;
    font-weight: 700;
    letter-spacing: 0.2px;
    stroke-width: 2.4px;
  }

  /* 370px expanded globe fills the width — hide the corner orb so it cannot cover the map. */
  body.globe-expanded[data-screen="map"] #map-home .prayer-turn.prayer-turn-orb {
    display: none !important;
  }
}

/* ===== v109f preview: phone — delicate sparkle glimpse of the Moments count =====
   Same left-sky slot as v109e, level with the prayer orb's center, no box.
   Much smaller type and a tiny gold star glint instead of the round pulse dot.
   Laptop and everything else unchanged. */
.sky-grace { display: none; }

@keyframes sky-twinkle {
  0%, 100% { opacity: 0.4; transform: scale(0.82); }
  45% { opacity: 1; transform: scale(1.12); }
  60% { opacity: 0.7; transform: scale(0.95); }
}

@media (max-width: 839px) {
  body[data-screen="map"] #map-home .sky-grace {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0;
    position: absolute;
    right: 100%;
    left: auto;
    top: auto;
    bottom: 2px;
    margin: 0 6px 0 0;
    --orb-slot: calc((100vw - var(--globe-rest, 200px)) / 2 - 10px);
    width: min(110px, max(78px, var(--orb-slot)));
    height: min(110px, max(78px, var(--orb-slot)));
    padding: 0;
    border: 0;
    background: none;
    box-shadow: none;
    border-radius: 0;
    text-align: center;
    z-index: 9;
    pointer-events: none;
    overflow: visible;
  }
  body[data-screen="map"] #map-home .sky-grace-sparkle {
    display: block;
    width: 9px;
    height: 9px;
    margin: 0 0 3px;
    line-height: 0;
  }
  body[data-screen="map"] #map-home .sky-grace-sparkle svg {
    display: block;
    width: 9px;
    height: 9px;
    overflow: visible;
    filter: drop-shadow(0 0 2px rgba(232, 201, 122, 0.95))
            drop-shadow(0 0 5px rgba(226, 179, 60, 0.55));
    animation: sky-twinkle 2.8s ease-in-out infinite;
    transform-origin: 50% 50%;
  }
  body[data-screen="map"] #map-home .sky-grace-num {
    display: block;
    margin: 0;
    padding: 0;
    border: 0;
    background: none;
    font-family: "Cormorant Garamond", Georgia, serif;
    font-weight: 600;
    font-style: normal;
    font-size: 15px;
    font-variant-numeric: lining-nums;
    font-feature-settings: "lnum";
    line-height: 1;
    letter-spacing: 0.02em;
    color: #8A5A28;
    text-shadow:
      0 0 6px rgba(255, 250, 236, 0.95),
      0 0 12px rgba(232, 201, 122, 0.35);
  }
  body[data-screen="map"] #map-home .sky-grace-word {
    display: block;
    margin: 2px 0 0;
    font-family: "Cormorant Garamond", Georgia, serif;
    font-weight: 600;
    font-style: italic;
    font-size: 11px;
    line-height: 1.15;
    letter-spacing: 0.05em;
    color: #8A6A42;
    text-shadow: 0 0 6px rgba(255, 250, 236, 0.9);
  }
  body.globe-expanded[data-screen="map"] #map-home .sky-grace {
    display: none !important;
  }
}

@media (max-width: 379px) {
  body[data-screen="map"] #map-home .sky-grace-num {
    font-size: 14px;
  }
}

@media (min-width: 840px) {
  .sky-grace { display: none !important; }
}


/* v109j: phone and laptop My Request share the short notice and a closed-by-default
   "See how people prayed" toggle. The phone intro stays phone-only. */
.prayer-dash-intro { display: none; }
.prayer-dash-lit,
.prayer-dash-notices-phone,
.prayer-dash-how { display: none; }

.prayer-dash-lit {
  margin: 0.15rem 0 0.55rem;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 1.15rem;
  font-weight: 600;
  color: #6B4A2B;
}
.prayer-dash-how {
  margin: 0 0 0.7rem;
}
.prayer-dash-how summary {
  display: inline-flex;
  align-items: center;
  gap: 0.2rem;
  list-style: none;
  cursor: pointer;
  width: auto;
  padding: 0;
  border: 0;
  background: none;
  box-shadow: none;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 0.92rem;
  font-style: italic;
  font-weight: 600;
  color: #8A5E3B;
  line-height: 1.3;
}
.prayer-dash-how summary::-webkit-details-marker,
.prayer-dash-how summary::marker { display: none; content: none; }
.prayer-dash-how summary:hover,
.prayer-dash-how summary:focus-visible {
  color: #6B4A2B;
  text-decoration: underline;
  text-underline-offset: 2px;
  outline: none;
}
.prayer-dash-how .dash-how-caret {
  display: inline-block;
  font-style: normal;
  font-size: 0.75rem;
  line-height: 1;
  transform: translateY(1px);
  transition: transform 0.2s ease;
}
.prayer-dash-how[open] .dash-how-caret { transform: translateY(1px) rotate(180deg); }
.prayer-dash-how .prayer-dash-meanings {
  display: block;
  margin: 0.45rem 0 0;
  padding: 0;
  font-size: 0.88rem;
  color: #6B4A2B;
}
.prayer-dash-how .prayer-dash-meanings li {
  margin: 0 0 0.1rem;
  gap: 0.3rem;
}
.prayer-dash-how .prayer-dash-meanings img {
  width: 16px;
  height: 21px;
}

/* ===== v109g preview: phone Prayer — scroll, rest/expand globe, calmer cards =====
   Laptop is unchanged. The Prayer globe still rests at the same 200px landing
   as the home globe. The overlay itself scrolls so every request can be reached. */
@media (max-width: 839px) {
  body.prayer-open,
  body.prayer-open html {
    overflow: hidden !important;
    overscroll-behavior: none;
  }
  html:has(body.prayer-open) {
    overflow: hidden !important;
    overscroll-behavior: none;
  }

  #prayer-page,
  .prayer-flip.is-page .prayer-page {
    overflow-x: hidden;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
    touch-action: pan-y;
  }

  /* Keep Back / Grace Map in view while the list scrolls. The bar itself is
     see-through so the light-cross and glitter stay visible; the pills keep
     their own backgrounds. */
  .prayer-page-bar {
    position: sticky;
    top: 0;
    background: none;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }

  /* List cards: drop the colored tea-light count row; keep "N candles lit". */
  .prayer-page .prayer-breakdown-color { display: none !important; }
  .prayer-page .prayer-breakdown { gap: 0; margin-top: 0.35rem; }

  /* Full request text at a readable size (no mid-sentence clip). */
  .prayer-page .prayer-request-snip {
    font-size: 14px;
    line-height: 1.4;
    max-height: none;
    overflow: visible;
  }

  /* My Request + lighting card: hide the busy candle stream. Types picker stays.
     Laptop meanings / gathering / detailed notices stay hidden on phone. */
  .prayer-dash .prayer-gathering,
  .prayer-dash .prayer-dash-meanings-laptop,
  .prayer-dash .prayer-dash-notices-laptop,
  .prayer-card .prayer-gathering { display: none !important; }
  .prayer-dash-intro,
  .prayer-dash-lit,
  .prayer-dash-notices-phone { display: block; }
  .prayer-dash-how { display: block; }

  /* Quiet, closed-by-default type breakdown. */
  .prayer-dash-how {
    margin: 0 0 0.7rem;
  }
  .prayer-dash-how summary {
    display: inline-flex;
    align-items: center;
    gap: 0.2rem;
    list-style: none;
    cursor: pointer;
    width: auto;
    padding: 0;
    border: 0;
    background: none;
    box-shadow: none;
    font-family: "Cormorant Garamond", Georgia, serif;
    font-size: 0.92rem;
    font-style: italic;
    font-weight: 600;
    color: #8A5E3B;
    line-height: 1.3;
  }
  .prayer-dash-how summary::-webkit-details-marker,
  .prayer-dash-how summary::marker { display: none; content: none; }
  .prayer-dash-how summary:hover,
  .prayer-dash-how summary:focus-visible {
    color: #6B4A2B;
    text-decoration: underline;
    text-underline-offset: 2px;
    outline: none;
  }
  .prayer-dash-how .dash-how-caret {
    display: inline-block;
    font-style: normal;
    font-size: 0.75rem;
    line-height: 1;
    transform: translateY(1px);
    transition: transform 0.2s ease;
  }
  .prayer-dash-how[open] .dash-how-caret { transform: translateY(1px) rotate(180deg); }
  .prayer-dash-how .prayer-dash-meanings {
    display: block;
    margin: 0.45rem 0 0;
    padding: 0;
    font-size: 0.88rem;
    color: #6B4A2B;
  }

  .prayer-dash-intro {
    display: block;
    margin: 0 0 0.45rem;
    font-family: "Cormorant Garamond", Georgia, serif;
    font-size: 0.95rem;
    font-style: italic;
    line-height: 1.35;
    color: #6B4A2B;
  }
  .prayer-dash-lit {
    display: block;
    margin: 0.15rem 0 0.55rem;
    font-family: "Cormorant Garamond", Georgia, serif;
    font-size: 1.15rem;
    font-weight: 600;
    color: #6B4A2B;
  }

  /* Room at the end of the list; the overlay covers the bottom nav. */
  .prayer-page .prayer-panel {
    margin-bottom: 1.5rem;
  }

  /* Prayer globe: same rest/expand behavior as the home globe. */
  .prayer-page .map-circle-glow.prayer-globe {
    transition: width 0.4s cubic-bezier(0.22, 1, 0.36, 1),
                height 0.4s cubic-bezier(0.22, 1, 0.36, 1),
                min-width 0.4s cubic-bezier(0.22, 1, 0.36, 1),
                min-height 0.4s cubic-bezier(0.22, 1, 0.36, 1);
  }
  .prayer-page .map-circle-glow.prayer-globe.globe-noanim {
    transition: none;
  }
  body.prayer-globe-expanded .prayer-page .map-circle-glow.prayer-globe {
    --globe: min(
      var(--prayer-globe-expand, calc(100vw - 20px)),
      calc(100vw - 20px),
      calc(100svh - var(--header-h, 64px) - 16px)
    ) !important;
  }
  body.prayer-open:not(.prayer-globe-expanded) #prayer-map {
    touch-action: pan-y;
  }
  body.prayer-globe-expanded #prayer-map {
    touch-action: none;
  }
  body.prayer-open:not(.prayer-globe-expanded) #prayer-map .leaflet-bottom.leaflet-right {
    opacity: 0;
    pointer-events: none;
  }
  body.prayer-globe-expanded #prayer-map .leaflet-bottom.leaflet-right {
    opacity: 1;
    pointer-events: auto;
  }
  /* Keep the pray popup and My Request panel in the viewport while the page scrolls. */
  .prayer-flip.is-page .prayer-card {
    position: fixed;
    top: 50%;
    left: 50%;
    z-index: 40;
  }
  .prayer-flip.is-page .prayer-dash {
    position: fixed;
    z-index: 40;
    max-height: calc(100dvh - var(--header-h, 64px) - 12px);
    margin-bottom: 0;
  }
  .prayer-dash-how .prayer-dash-meanings li {
    margin: 0 0 0.1rem;
    gap: 0.3rem;
  }
  .prayer-dash-how .prayer-dash-meanings img {
    width: 16px;
    height: 21px;
  }

  .prayer-page .globe-expand-hit {
    touch-action: pan-y;
    z-index: 700;
  }
  .prayer-page .globe-explore-hint { z-index: 701; }
  .prayer-page .globe-close { z-index: 702; }

  /* Resting: the map shouldn't steal the expand tap or the page scroll. */
  body.prayer-open:not(.prayer-globe-expanded) #prayer-map {
    pointer-events: none;
  }
  body.prayer-globe-expanded .prayer-page .globe-expand-hit,
  .prayer-page .globe-expand-hit[hidden] { display: none; }
  body.prayer-globe-expanded .prayer-page .globe-close:not([hidden]) { display: inline-flex; }
  body.prayer-globe-expanded .prayer-page .map-globe-stack {
    position: relative;
    z-index: 7;
    overflow: visible;
  }
  .prayer-page .prayer-map-col,
  .prayer-page .map-globe-stack {
    overflow: visible;
  }
}

/* v109q: phone only — slightly smaller Prayer title, tighter hero, map sits
   higher. Resting globe stays 200px and still expands. Laptop unchanged. */
@media (max-width: 839px) {
  .prayer-page-bar .prayer-myp-btn,
  .prayer-page-bar button.prayer-back,
  .prayer-flip.is-page .prayer-page-bar .prayer-myp-btn,
  .prayer-flip.is-page .prayer-page-bar button.prayer-back {
    box-shadow: 0 1px 4px rgba(20, 10, 4, 0.4), 0 2px 8px rgba(12, 6, 2, 0.28);
  }
  .prayer-page .prayer-page-hero {
    height: 120px;
    flex: 0 0 120px;
  }
  .prayer-page .prayer-page-title {
    font-size: 2.2rem;
  }
  .prayer-page .prayer-page-lede {
    font-size: 1rem;
    margin-bottom: -8px;
    padding: 0 0.7rem;
  }
  .prayer-page .prayer-map-col {
    padding-top: 28px;
  }
}

/* v109q: phone only — Prayer globe lands on the home globe, then eases up
   into its higher rest as the flip finishes. Laptop is unchanged. */
@media (max-width: 839px) {
  .prayer-page .map-circle-glow.prayer-globe {
    transform: translateY(var(--prayer-globe-drift, 0px));
  }
  .prayer-flip.is-drifting .prayer-page .map-circle-glow.prayer-globe:not(.globe-noanim) {
    transition: width 0.4s cubic-bezier(0.22, 1, 0.36, 1),
                height 0.4s cubic-bezier(0.22, 1, 0.36, 1),
                min-width 0.4s cubic-bezier(0.22, 1, 0.36, 1),
                min-height 0.4s cubic-bezier(0.22, 1, 0.36, 1),
                transform 0.55s cubic-bezier(0.215, 0.61, 0.355, 1);
  }
}
@media (max-width: 839px) and (prefers-reduced-motion: reduce) {
  .prayer-page .map-circle-glow.prayer-globe {
    transform: none;
  }
}

/* Short Safari viewports: keep the gold Request button fully on the first
   screen without moving the 200px Prayer globe off the home landing. */
@media (max-width: 839px) and (max-height: 600px) {
  .prayer-page .prayer-panel {
    padding-top: 6px;
    padding-bottom: 16px;
  }
  .prayer-page .prayer-panel h3 {
    margin-bottom: 0.25rem;
  }
  .prayer-page .prayer-request-cta {
    margin-bottom: 0.45rem;
    padding-top: 0.45rem;
    padding-bottom: 0.45rem;
  }
  .prayer-page .prayer-map-col {
    padding-bottom: 4px;
  }
  /* v109o: make room for the blessing line so Place/Cancel stay on screen */
  .prayer-page .prayer-bless-note {
    margin: 0.08rem 0 0.22rem;
  }
  .prayer-page .prayer-panel .prayer-request-form-wrap textarea {
    min-height: 2.5rem;
    height: 5rem;
    max-height: 5rem;
  }
  .prayer-page .prayer-panel .prayer-loc-note {
    margin-bottom: 0.32rem;
  }
}

@media (min-width: 840px) {
  .prayer-dash-intro,
  .prayer-dash .prayer-dash-meanings-laptop,
  .prayer-dash .prayer-gathering,
  .prayer-dash .prayer-dash-notices-laptop { display: none !important; }
  .prayer-dash-lit,
  .prayer-dash-notices-phone { display: block !important; }
  .prayer-dash-how { display: block !important; }
  #prayer-globe-expand-hit,
  #prayer-globe-explore-hint,
  #prayer-globe-close { display: none !important; }
}

/* ===== v109l preview (mid): lighter candlelit My Prayer Request (phone and laptop) =====
   Inner card stays a light warm honey cream for reading. Candle warmth lives
   mostly in the outer panel edges and a soft amber/gold glow. Layout unchanged. */
.prayer-dash,
.prayer-flip.is-page .prayer-dash {
  background:
    radial-gradient(ellipse 85% 80% at 50% 28%,
      #F7E6C2 0%,
      #F3D9A4 58%,
      #E8C483 100%);
  border: 1px solid #C9A24B;
  box-shadow:
    inset 0 1px 0 rgba(255, 248, 232, 0.9),
    inset 0 0 0 1px rgba(201, 162, 75, 0.28),
    inset 0 0 18px rgba(243, 217, 164, 0.45),
    0 0 14px rgba(232, 196, 131, 0.55),
    0 0 28px rgba(201, 162, 75, 0.38),
    0 16px 40px rgba(20, 10, 4, 0.45);
  color: #4A2E1C;
}
.prayer-dash-item,
.prayer-dash-item.is-answered {
  background: linear-gradient(180deg, #FBEFD6, #F6E3BC);
  border: 1px solid rgba(201, 162, 75, 0.45);
  box-shadow: inset 0 1px 0 rgba(255, 252, 244, 0.85);
}
.prayer-dash-item h4,
.prayer-dash-item p.prayer-dash-body-text,
.prayer-dash-notices p,
.prayer-dash-notices h5,
.prayer-dash-head h3,
.prayer-dash-lit,
.prayer-dash-date,
.prayer-dash-intro,
.prayer-dash-foot,
.prayer-dash-how summary {
  color: #4A2E1C;
}
.prayer-dash-how summary:hover,
.prayer-dash-how summary:focus-visible {
  color: #3A2414;
}
.prayer-dash .prayer-mark-answered {
  background: linear-gradient(180deg, #F3D9A4, #E8C483);
  border-color: #B8893A;
  color: #3A2414;
}
.prayer-dash .prayer-mark-answered[aria-pressed="true"] {
  background: #5C3A22;
  color: #F6E4A8;
  border-color: #5C3A22;
}
.prayer-dash .prayer-dash-share {
  background: linear-gradient(180deg, #F3D9A4, #C9A24B);
  border-color: #B8893A;
  color: #3A2414;
}


/* ===== v109n: small title on Grace and Prayer submissions ===== */
.form-group-title { margin-bottom: 0.7rem; }
.form-group-title input {
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 1.05rem;
  font-weight: 600;
  color: #4A2E1C;
  background: #FFF9F0;
  border: 1px solid rgba(139, 94, 59, 0.28);
  padding: 0.42rem 0.75rem;
  min-height: 0;
}
.form-group-title input::placeholder {
  color: #8A5E3B;
  font-weight: 400;
  font-style: italic;
  opacity: 0.85;
}
.form-group-title input:focus-visible {
  outline: none;
  border-color: #C9A24B;
  box-shadow: 0 0 0 2px rgba(201, 162, 75, 0.35);
}
.prayer-request-form-wrap #prayer-req-title {
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 1.05rem;
  font-weight: 600;
  color: #4A2E1C;
  background: #FFF9F0;
  padding: 0.38rem 0.65rem;
  margin-bottom: 0.55rem;
}
.prayer-request-form-wrap #prayer-req-title::placeholder {
  color: #8A5E3B;
  font-weight: 400;
  font-style: italic;
  opacity: 0.85;
}
.story-title,
.post-card .story-title,
.journal-entry .story-title,
.feather-popup .story-title,
.prayer-card .prayer-card-title.has-user-title,
.prayer-dash-item h4 .story-title {
  margin: 0 0 0.28rem;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-weight: 600;
  font-size: 1.08rem;
  line-height: 1.28;
  color: #5C3A22;
}
.feather-popup .story-title,
.story-read .story-title {
  margin: 0.15rem 0 0.4rem;
  padding-right: 2.6rem; /* keep longer titles clear of the close button */
  font-size: 1.2rem;
  color: #4A2E1C;
}
.prayer-card .prayer-card-title.has-user-title {
  margin: 0 0 0.4rem;
  font-size: 1.2rem;
  color: #4A2E1C;
}
.prayer-request-open b.prayer-request-heading {
  display: block;
  margin: 0 0 0.12rem;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-weight: 600;
  font-size: 1.08rem;
  line-height: 1.28;
  color: #FFF6D4; /* warm gold so titles stay readable on the dark prayer list */
}
.prayer-dash-item h4 .story-title {
  display: inline;
  margin: 0 0.25rem 0 0;
  font-size: 1.2rem;
  color: #4A2E1C;
}


/* ===== v109o: gentle blessing line under the request question ===== */
.prayer-bless-note {
  margin: 0.12rem 0 0.4rem;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-style: italic;
  font-weight: 400;
  font-size: 0.92rem;
  line-height: 1.35;
  color: #6B4A2B;
}
.prayer-bless-keep { white-space: nowrap; }
.prayer-panel .prayer-bless-note {
  color: #F0D9B0;
}


/* ===== v109p-midform preview only: Request a Prayer form in middle honey/amber
   (same palette as the My Request panel). v109p main is unchanged. */
.prayer-panel .prayer-request-form-wrap,
.prayer-request-form-wrap {
  background:
    radial-gradient(ellipse 85% 80% at 50% 28%,
      #F7E6C2 0%,
      #F3D9A4 58%,
      #E8C483 100%);
  color: #4A2E1C;
  border: 1px solid #C9A24B;
  box-shadow:
    inset 0 1px 0 rgba(255, 248, 232, 0.9),
    inset 0 0 0 1px rgba(201, 162, 75, 0.28),
    0 0 14px rgba(232, 196, 131, 0.45),
    0 8px 24px rgba(20, 10, 4, 0.28);
}
.prayer-panel .prayer-request-form-wrap h4,
.prayer-request-form-wrap h4 {
  background: transparent;
  color: #4A2E1C;
  text-shadow: none;
}
.prayer-panel .prayer-request-form-wrap label,
.prayer-panel .prayer-notify-pref legend,
.prayer-request-form-wrap label {
  color: #4A2E1C;
}
.prayer-panel .prayer-request-form-wrap .prayer-form-note,
.prayer-panel .prayer-request-form-wrap .prayer-field-hint,
.prayer-panel .prayer-request-form-wrap .prayer-loc-note,
.prayer-panel .prayer-request-form-wrap .prayer-bless-note,
.prayer-panel .prayer-loc-note,
.prayer-panel .prayer-bless-note,
.prayer-panel .prayer-form-note {
  color: #6B4423;
  font-style: italic;
}
.prayer-panel .prayer-loc-note.is-fallback { color: #6B4423; }
.prayer-panel .prayer-request-form-wrap input[type="text"],
.prayer-panel .prayer-request-form-wrap textarea,
.prayer-panel .prayer-request-form-wrap select,
.prayer-request-form-wrap input[type="text"],
.prayer-request-form-wrap textarea,
.prayer-request-form-wrap select {
  color: #4A2E1C;
  background: linear-gradient(180deg, #FBEFD6, #F6E3BC);
  border: 1px solid rgba(201, 162, 75, 0.55);
  caret-color: #4A2E1C;
}
.prayer-panel .prayer-request-form-wrap input::placeholder,
.prayer-panel .prayer-request-form-wrap textarea::placeholder,
.prayer-request-form-wrap input::placeholder,
.prayer-request-form-wrap textarea::placeholder {
  color: #8A5E3B;
  opacity: 0.85;
  font-style: italic;
}
.prayer-panel .prayer-request-form-wrap input:focus-visible,
.prayer-panel .prayer-request-form-wrap textarea:focus-visible,
.prayer-panel .prayer-request-form-wrap select:focus-visible {
  outline: none;
  border-color: #C9A24B;
  box-shadow: 0 0 0 2px rgba(201, 162, 75, 0.35);
}
.prayer-panel .prayer-request-form-wrap .prayer-form-cancel,
.prayer-panel .prayer-form-cancel {
  color: #4A2E1C;
}
.prayer-panel .prayer-request-form-wrap .prayer-form-cancel:hover,
.prayer-panel .prayer-request-form-wrap .prayer-form-cancel:focus-visible,
.prayer-panel .prayer-form-cancel:hover,
.prayer-panel .prayer-form-cancel:focus-visible {
  color: #3A2414;
  text-decoration: underline;
}
.prayer-panel .prayer-request-form-wrap .prayer-form-submit,
.prayer-form-submit {
  color: #4A2E1C;
  border-color: #B8893A;
  background: linear-gradient(180deg, #F3D9A4, #C9A24B);
}


/* ===== v109r: phone only — expanded map controls + no pill/lede collision =====
   Resting Prayer page is unchanged. When the page is scrolled or the map is
   expanded, the title and lede fade so the sticky see-through pills never sit
   on the words. No frosted bar is added, so the light-cross stays clear at rest.
   Zoom +/- and the World picker grow to 44px earth-toned targets on the expanded
   home and Prayer globes, kept in the lower-right ocean so they do not cover
   candles. Laptop is unchanged. */
@media (max-width: 839px) {
  .prayer-page .prayer-page-title,
  .prayer-page .prayer-page-lede {
    transition: opacity 0.28s ease;
  }
  body.prayer-globe-expanded .prayer-page .prayer-page-title,
  body.prayer-globe-expanded .prayer-page .prayer-page-lede,
  .prayer-page.prayer-hero-tucked .prayer-page-title,
  .prayer-page.prayer-hero-tucked .prayer-page-lede {
    opacity: 0;
    pointer-events: none;
  }

  body.prayer-globe-expanded #prayer-map .leaflet-bottom.leaflet-right,
  body.globe-expanded[data-screen="map"] #map-home .leaflet-bottom.leaflet-right {
    bottom: 14%;
    right: 12%;
    left: auto;
    margin: 0;
    opacity: 1;
    pointer-events: auto;
  }
  body.prayer-globe-expanded #prayer-map .leaflet-control-zoom,
  body.globe-expanded[data-screen="map"] #map-home .leaflet-control-zoom {
    position: relative;
    overflow: visible;
    opacity: 1;
    border: 0;
    background: none;
    box-shadow: none;
  }
  body.prayer-globe-expanded #prayer-map .leaflet-bar,
  body.globe-expanded[data-screen="map"] #map-home .leaflet-bar,
  body.prayer-globe-expanded #prayer-map .leaflet-touch .leaflet-bar,
  body.globe-expanded[data-screen="map"] #map-home .leaflet-touch .leaflet-bar {
    border: 0;
    box-shadow: none;
    background: none;
  }
  body.prayer-globe-expanded #prayer-map .leaflet-control-zoom a,
  body.globe-expanded[data-screen="map"] #map-home .leaflet-control-zoom a,
  body.prayer-globe-expanded #prayer-map .leaflet-touch .leaflet-bar a,
  body.globe-expanded[data-screen="map"] #map-home .leaflet-touch .leaflet-bar a {
    width: 44px;
    height: 44px;
    line-height: 42px;
    font-size: 26px;
    font-weight: 600;
    color: #4A2E1C;
    background: rgba(255, 248, 232, 0.96);
    border: 1.5px solid #C9A24B;
    box-shadow: 0 1px 4px rgba(20, 10, 4, 0.28);
    box-sizing: border-box;
  }
  body.prayer-globe-expanded #prayer-map .leaflet-control-zoom a:first-child,
  body.globe-expanded[data-screen="map"] #map-home .leaflet-control-zoom a:first-child,
  body.prayer-globe-expanded #prayer-map .leaflet-touch .leaflet-bar a:first-child,
  body.globe-expanded[data-screen="map"] #map-home .leaflet-touch .leaflet-bar a:first-child {
    border-top-left-radius: 10px;
    border-top-right-radius: 10px;
    border-bottom-left-radius: 0;
    border-bottom-right-radius: 0;
  }
  body.prayer-globe-expanded #prayer-map .leaflet-control-zoom a:last-child,
  body.globe-expanded[data-screen="map"] #map-home .leaflet-control-zoom a:last-child,
  body.prayer-globe-expanded #prayer-map .leaflet-touch .leaflet-bar a:last-child,
  body.globe-expanded[data-screen="map"] #map-home .leaflet-touch .leaflet-bar a:last-child {
    border-top-left-radius: 0;
    border-top-right-radius: 0;
    border-bottom-left-radius: 10px;
    border-bottom-right-radius: 10px;
    margin-top: -1px;
  }
  body.prayer-globe-expanded #prayer-map .leaflet-control-zoom a:hover,
  body.globe-expanded[data-screen="map"] #map-home .leaflet-control-zoom a:hover,
  body.prayer-globe-expanded #prayer-map .leaflet-control-zoom a:focus-visible,
  body.globe-expanded[data-screen="map"] #map-home .leaflet-control-zoom a:focus-visible {
    background: #FFF6D4;
    color: #3A2414;
  }
  /* World sits low on the round map (bottom-center, inside the clip) so it
     does not cover mid-Atlantic candle hunting. Menu opens upward in-flow.
     +/- stay in the lower-right ocean. */
  body:not(.globe-expanded) #map .zoom-level,
  body.prayer-open:not(.prayer-globe-expanded) #prayer-map .zoom-level,
  body:not(.prayer-open) #prayer-map .zoom-level {
    opacity: 0;
    pointer-events: none;
  }
  body.prayer-globe-expanded #prayer-map .zoom-level,
  body.globe-expanded[data-screen="map"] #map-home .zoom-level,
  body.globe-expanded #map .zoom-level {
    position: absolute;
    /* Slightly right of center and a little up from the rim, so the pill
       sits in the South Atlantic instead of on Brazil's eastern tip. */
    left: 60%;
    right: auto;
    top: auto;
    bottom: 22px;
    transform: translateX(-50%);
    z-index: 800;
    opacity: 1;
    pointer-events: auto;
    gap: 6px;
    align-items: center;
  }
  body.prayer-globe-expanded #prayer-map .zoom-level button,
  body.globe-expanded[data-screen="map"] #map-home .zoom-level button {
    min-height: 44px;
    min-width: 44px;
    padding: 0 14px;
    font: 600 15px/1.15 system-ui, -apple-system, "Segoe UI", sans-serif;
    color: #4A2E1C;
    background: rgba(255, 248, 232, 0.96);
    border: 1.5px solid #C9A24B;
    border-radius: 999px;
    box-shadow: 0 1px 4px rgba(20, 10, 4, 0.28);
  }
  body.prayer-globe-expanded #prayer-map .zoom-level .zl-menu,
  body.globe-expanded[data-screen="map"] #map-home .zoom-level .zl-menu,
  body.globe-expanded #map .zoom-level .zl-menu {
    position: static;
    right: auto;
    top: auto;
    bottom: auto;
    transform: none;
    gap: 4px;
  }
  body.prayer-globe-expanded #prayer-map .zoom-level .zl-menu button,
  body.globe-expanded[data-screen="map"] #map-home .zoom-level .zl-menu button {
    min-height: 44px;
    min-width: 88px;
    text-align: center;
  }
  body.prayer-globe-expanded #prayer-map .zoom-level .zl-menu button[aria-checked="true"],
  body.globe-expanded[data-screen="map"] #map-home .zoom-level .zl-menu button[aria-checked="true"] {
    background: #E2B33C;
    border-color: #C9973A;
    color: #3D2614;
  }
}
@media (max-width: 839px) and (prefers-reduced-motion: reduce) {
  .prayer-page .prayer-page-title,
  .prayer-page .prayer-page-lede { transition: none; }
}


/* ===== v110 / v109r: phone only — sturdier display serif + cream input boxes =====
   Cormorant 700 is already loaded; light-background titles go ink #4A2E1C.
   Input boxes use a soft cream tint (not white) so they read as a place to type
   on the honey form panel, with a warm brown border and a gold focus ring.
   Laptop typography, inputs, globe, cross, and flip landing are unchanged. */
@media (max-width: 839px) {
  :root {
    --input-cream: #FDF6E6; /* option A: light warm cream, default */
  }

  /* Display serif titles: keep Cormorant, use the heavier cut */
  .prayer-card-title,
  .prayer-card .prayer-card-title.has-user-title,
  .story-title,
  .post-card .story-title,
  .journal-entry .story-title,
  .feather-popup .story-title,
  .story-read .story-title,
  .prayer-dash-item h4,
  .prayer-dash-item h4 .story-title,
  .prayer-dash-head h3,
  .prayer-request-form-wrap h4,
  .prayer-panel .prayer-request-form-wrap h4,
  #compose-screen h2,
  .prayer-card-lit,
  .prayer-dash-lit {
    font-weight: 700;
  }
  .prayer-card-title,
  .prayer-card .prayer-card-title.has-user-title,
  .story-title,
  .post-card .story-title,
  .journal-entry .story-title,
  .feather-popup .story-title,
  .story-read .story-title,
  .prayer-dash-item h4,
  .prayer-dash-item h4 .story-title {
    color: #4A2E1C;
  }
  .prayer-card-lit,
  .prayer-dash-lit {
    font-style: italic;
    color: #4A2E1C;
  }
  .prayer-request-open b.prayer-request-heading {
    font-weight: 700;
    color: #FFF6D4; /* stays cream on the dark list cards */
  }
  .prayer-page-bar .prayer-myp-btn,
  .prayer-page-bar button.prayer-back,
  .prayer-flip.is-page .prayer-page-bar .prayer-myp-btn,
  .prayer-flip.is-page .prayer-page-bar button.prayer-back {
    font-weight: 700;
  }

  /* Clear cream typing boxes — Prayer form + matching Grace compose fields */
  .prayer-panel .prayer-request-form-wrap input[type="text"],
  .prayer-panel .prayer-request-form-wrap textarea,
  .prayer-panel .prayer-request-form-wrap select,
  .prayer-request-form-wrap input[type="text"],
  .prayer-request-form-wrap textarea,
  .prayer-request-form-wrap select,
  .prayer-request-form-wrap #prayer-req-title,
  .prayer-panel .prayer-request-form-wrap #prayer-req-title,
  .form-group input,
  .form-group textarea,
  .form-group select,
  .form-group-title input,
  .story-box {
    background: var(--input-cream, #FDF6E6) !important;
    background-image: none !important;
    border: 1.5px solid #B08A5A !important;
    border-width: 1.5px !important;
    border-radius: 12px;
    color: #4A2E1C;
    font-size: 16px;
    line-height: 1.45;
    box-shadow: none !important;
  }
  .prayer-panel .prayer-request-form-wrap input[type="text"],
  .prayer-panel .prayer-request-form-wrap textarea,
  .prayer-panel .prayer-request-form-wrap select,
  .prayer-request-form-wrap input[type="text"],
  .prayer-request-form-wrap textarea,
  .prayer-request-form-wrap select,
  .prayer-request-form-wrap #prayer-req-title,
  .form-group-title input {
    padding: 0.55rem 0.75rem;
  }
  .prayer-request-form-wrap #prayer-req-title,
  .form-group-title input {
    font-family: "Cormorant Garamond", Georgia, serif;
    font-weight: 700;
    font-size: 17px;
  }
  .prayer-panel .prayer-request-form-wrap input::placeholder,
  .prayer-panel .prayer-request-form-wrap textarea::placeholder,
  .prayer-request-form-wrap input::placeholder,
  .prayer-request-form-wrap textarea::placeholder,
  .prayer-request-form-wrap #prayer-req-title::placeholder,
  .form-group-title input::placeholder,
  .form-group input::placeholder,
  .form-group textarea::placeholder,
  .story-box::placeholder {
    color: #6B4A2B !important;
    opacity: 0.92;
    font-style: italic;
    font-weight: 400;
  }
  .prayer-panel .prayer-request-form-wrap input:focus,
  .prayer-panel .prayer-request-form-wrap input:focus-visible,
  .prayer-panel .prayer-request-form-wrap textarea:focus,
  .prayer-panel .prayer-request-form-wrap textarea:focus-visible,
  .prayer-panel .prayer-request-form-wrap select:focus,
  .prayer-panel .prayer-request-form-wrap select:focus-visible,
  .prayer-request-form-wrap input:focus,
  .prayer-request-form-wrap input:focus-visible,
  .prayer-request-form-wrap textarea:focus,
  .prayer-request-form-wrap textarea:focus-visible,
  .prayer-request-form-wrap select:focus,
  .prayer-request-form-wrap select:focus-visible,
  .form-group input:focus,
  .form-group input:focus-visible,
  .form-group textarea:focus,
  .form-group textarea:focus-visible,
  .form-group select:focus,
  .form-group-title input:focus,
  .form-group-title input:focus-visible,
  .story-box:focus,
  .story-box:focus-visible {
    outline: none !important;
    border-color: #C9A24B !important;
    box-shadow: 0 0 0 3px rgba(201, 162, 75, 0.42) !important;
  }
}


/* ===== v109t: prayer-ask panel boxes only the request body + candle count.
   Badge, place, and title stay on the popup cream beside the close X.
   The honey panel is centered and matches the candle-button width. */
.prayer-card {
  --prayer-ask-bg: #F6E6C4;
  --prayer-ask-border: #C9A24B;
}
.prayer-card .prayer-card-title,
.prayer-card .prayer-card-title.has-user-title {
  font-size: 1.42rem;
  line-height: 1.22;
  margin: 0 0 0.45rem;
  padding-right: 1.6rem; /* clear the close X, as before */
}
.prayer-card-ask {
  background: var(--prayer-ask-bg, #F6E6C4);
  border: 1px solid var(--prayer-ask-border, #C9A24B);
  border-radius: 14px;
  padding: 0.7rem 0.85rem 0.65rem;
  margin: 0 0 0.85rem; /* equal left/right, same edges as the candle buttons */
  box-shadow:
    inset 0 1px 2px rgba(255, 248, 232, 0.9),
    inset 0 -1px 4px rgba(139, 94, 59, 0.08);
}
.prayer-card-ask .prayer-card-body-text { margin: 0 0 0.45rem; }
.prayer-card-ask .prayer-card-lit { margin: 0; }
.prayer-card-choices-label {
  margin: 0 0 0.4rem;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-style: italic;
  font-weight: 700;
  font-size: 1.02rem;
  line-height: 1.25;
  color: #4A2E1C;
}
.prayer-card .prayer-choices {
  margin: 0 0 0.15rem;
}
.prayer-card .resp-tealight {
  border-color: #E8D9B6;
}

@media (max-width: 839px) {
  .prayer-card,
  .prayer-flip.is-page .prayer-card {
    max-height: calc(100dvh - 16px);
  }
  .prayer-card .prayer-card-title,
  .prayer-card .prayer-card-title.has-user-title {
    font-size: 1.32rem;
  }
}
@media (max-width: 839px) and (max-height: 600px) {
  .prayer-card {
    padding: 0.8rem 0.85rem 0.75rem;
  }
  .prayer-card-ask {
    padding: 0.55rem 0.7rem 0.5rem;
    margin: 0 0 0.6rem;
  }
  .prayer-card-ask .prayer-card-body-text { margin-bottom: 0.35rem; }
  .prayer-card-choices-label {
    margin-bottom: 0.28rem;
    font-size: 0.98rem;
  }
  .prayer-card .prayer-choices { gap: 0.26rem; }
  .prayer-card .resp-tealight { padding-top: 0.2rem; padding-bottom: 0.2rem; }
}


/* ===== v111: Grace Map pill feather — cleaned asset (no baked white stroke),
   soft gold glow, and a gentle slow shimmer. Map swoosh PNGs are unchanged.
   Also restyle My Prayer Requests (and the Share form, which used the same
   tan panel) to the popup cream, with the prayer body + candle count in the
   honey ask box (tint A). Answered button is left as-is. */
.prayer-page-bar button.prayer-back img.prayer-grace-feather,
.prayer-flip.is-page .prayer-page-bar button.prayer-back img.prayer-grace-feather {
  width: 16px;
  height: 30px;
  object-fit: contain;
  filter: drop-shadow(0 0 3px rgba(255, 214, 120, 0.55));
  animation: prayer-feather-shimmer 4.2s ease-in-out infinite;
}
@keyframes prayer-feather-shimmer {
  0%, 100% {
    filter:
      drop-shadow(0 0 3px rgba(255, 214, 120, 0.55))
      drop-shadow(0 0 6px rgba(255, 200, 90, 0.2));
  }
  45% {
    filter:
      drop-shadow(0 0 6px rgba(255, 236, 190, 0.95))
      drop-shadow(0 0 12px rgba(255, 214, 120, 0.6));
  }
}
@media (prefers-reduced-motion: reduce) {
  .prayer-page-bar button.prayer-back img.prayer-grace-feather,
  .prayer-flip.is-page .prayer-page-bar button.prayer-back img.prayer-grace-feather {
    animation: none;
    filter: drop-shadow(0 0 3px rgba(255, 214, 120, 0.55));
  }
}

.prayer-dash,
.prayer-flip.is-page .prayer-dash {
  --prayer-ask-bg: #F6E6C4;
  --prayer-ask-border: #C9A24B;
  /* v111b: restore the honey/tan outer frame so it blends into the brown
     background; keep the cream inner card and honey ask box from After. */
  background:
    radial-gradient(ellipse 85% 80% at 50% 28%,
      #F7E6C2 0%,
      #F3D9A4 58%,
      #E8C483 100%);
  border: 1px solid #C9A24B;
  box-shadow:
    inset 0 1px 0 rgba(255, 248, 232, 0.9),
    inset 0 0 0 1px rgba(201, 162, 75, 0.28),
    inset 0 0 18px rgba(243, 217, 164, 0.45),
    0 0 14px rgba(232, 196, 131, 0.55),
    0 0 28px rgba(201, 162, 75, 0.38),
    0 16px 40px rgba(20, 10, 4, 0.45);
  color: #4A2E1C;
}
.prayer-dash-item,
.prayer-dash-item.is-answered {
  background: linear-gradient(180deg, #FFFDF8 0%, #FFF8EC 100%);
  border: 1px solid rgba(201, 162, 75, 0.35);
  box-shadow: inset 0 1px 0 rgba(255, 252, 244, 0.9);
}
.prayer-dash-ask {
  background: var(--prayer-ask-bg, #F6E6C4);
  border: 1px solid var(--prayer-ask-border, #C9A24B);
  border-radius: 14px;
  padding: 0.7rem 0.85rem 0.65rem;
  margin: 0 0 0.75rem;
  box-shadow:
    inset 0 1px 2px rgba(255, 248, 232, 0.9),
    inset 0 -1px 4px rgba(139, 94, 59, 0.08);
}
.prayer-dash-ask .prayer-dash-body-text { margin: 0 0 0.45rem; }
.prayer-dash-ask .prayer-dash-lit { margin: 0; }

/* Share Your Prayer Request has no inner card (fields sit directly in the
   wrap), so it is not given a honey-frame + cream-inner split. The wrap is
   left cream for now; the preview shows this and the earlier honey wrap. */
.prayer-panel .prayer-request-form-wrap,
.prayer-request-form-wrap {
  background: linear-gradient(180deg, #FFFDF8 0%, #FFF8EC 100%);
  color: #4A2E1C;
  border: 1px solid #C9A24B;
  box-shadow: 0 8px 24px rgba(20, 10, 4, 0.28);
}
.prayer-panel .prayer-request-form-wrap input[type="text"],
.prayer-panel .prayer-request-form-wrap textarea,
.prayer-panel .prayer-request-form-wrap select,
.prayer-request-form-wrap input[type="text"],
.prayer-request-form-wrap textarea,
.prayer-request-form-wrap select,
.prayer-request-form-wrap #prayer-req-title {
  background: #FDF6E6 !important;
  background-image: none !important;
  border: 1.5px solid #B08A5A !important;
  color: #4A2E1C;
}
.prayer-panel .prayer-request-form-wrap input:focus-visible,
.prayer-panel .prayer-request-form-wrap textarea:focus-visible,
.prayer-panel .prayer-request-form-wrap select:focus-visible,
.prayer-request-form-wrap input:focus-visible,
.prayer-request-form-wrap textarea:focus-visible,
.prayer-request-form-wrap select:focus-visible,
.prayer-request-form-wrap #prayer-req-title:focus-visible {
  outline: none;
  border-color: #C9A24B !important;
  box-shadow: 0 0 0 3px rgba(201, 162, 75, 0.42) !important;
}

@media (max-width: 839px) and (max-height: 600px) {
  .prayer-dash-ask {
    padding: 0.55rem 0.7rem 0.5rem;
    margin: 0 0 0.55rem;
  }
  .prayer-dash-ask .prayer-dash-body-text { margin-bottom: 0.35rem; }
}


/* ===== v112: readable My Prayer Requests intro line (phone).
   Same body sans as the Posted line, slightly larger, not italic, no orphan. */
.prayer-dash-intro,
.prayer-page .prayer-dash-intro {
  font-family: var(--font);
  font-style: normal;
  font-weight: 400;
  font-size: 1rem;
  line-height: 1.45;
  color: #4A2E1C;
  text-wrap: balance;
}
@media (max-width: 839px) {
  .prayer-dash-intro,
  .prayer-page .prayer-dash-intro {
    font-family: var(--font);
    font-style: normal;
    font-weight: 400;
    font-size: 1rem;
    line-height: 1.45;
    color: #4A2E1C;
    text-wrap: balance;
  }
}


/* ===== v112: brown Prayer bloom — 2.0s readable hold, then a 1.4s soft melt =====
   The entry beat (winged cross, “Prayer”, and the lede) stays fully readable
   after its staggered fade-in. Then it eases out with a slight bloom while
   the Prayer page fades up underneath. The Grace Map return keeps the
   shorter existing close fade. Landing + 300ms hold + ~24px phone drift
   are unchanged and still start when is-page is added. */
.prayer-entry {
  filter: blur(0) brightness(1);
  transition: opacity 0.6s ease, transform 0.6s ease, filter 0.6s ease;
}
.prayer-flip.is-page .prayer-entry {
  opacity: 0;
  transform: none;
  filter: blur(7px) brightness(1.18);
  transition: opacity 1.4s ease-in-out, transform 1.4s ease-in-out, filter 1.4s ease-in-out;
}
.prayer-page {
  transition: opacity 0.65s ease 0.05s;
}
.prayer-flip.is-page .prayer-page {
  opacity: 1;
  pointer-events: auto;
  transition: opacity 1.4s ease-in-out;
}

@media (prefers-reduced-motion: reduce) {
  .prayer-entry,
  .prayer-page,
  .prayer-flip.is-page .prayer-entry,
  .prayer-flip.is-page .prayer-page {
    transition: opacity 0.45s ease !important;
    transform: none !important;
    filter: none !important;
  }
}
