/* ═══════════════════════════════════════════════════════════════════════════
   WOULD YOU JOIN ME FOR ONE HOUR — STYLESHEET
   Aesthetic: White-and-gold, photographs do the warm work
   ═══════════════════════════════════════════════════════════════════════════ */


/* ─────────────────────────────────────────────────────────────────────────
   1. DESIGN TOKENS
   ───────────────────────────────────────────────────────────────────────── */

:root {
  --white:           #ffffff;
  --white-soft:      #fbfaf6;
  --white-warm:      #f7f3e8;

  /* ── White-based palette with gold live section ── */
  --page-bg:         #ffffff;   /* pure white — page background */
  --page-bg-deep:    #fbf6e9;   /* subtly warm cream for alternating bands */
  --page-bg-soft:    #fdfbf5;   /* nearly white for gentle alternation */
  --card-bg:         #ffffff;   /* white for inset cards/forms */

  --ink:             #25262a;
  --ink-soft:        #50525a;
  --ink-faint:       #8a8d96;
  --ink-ghost:       #d4d6da;

  --gold:            #b8923a;
  --gold-bright:     #d4a83a;
  --gold-light:      #e6c065;
  --gold-deep:       #7a5f1f;
  --gold-faint:      rgba(184, 146, 58, 0.12);
  --gold-glow:       rgba(212, 168, 58, 0.25);

  --tabernacle:      #15110d;
  --tabernacle-soft: #2a221a;

  --font-sans:       "Inter", "Helvetica Neue", "Arial", system-ui, sans-serif;
  --font-serif:      "Cormorant Garamond", "EB Garamond", Georgia, serif;
  --font-display:    "Cormorant Garamond", "EB Garamond", Georgia, serif;

  --space-1: 0.5rem;
  --space-2: 1rem;
  --space-3: 1.75rem;
  --space-4: 3rem;
  --space-5: 5rem;
  --space-6: 8rem;
  --space-7: 12rem;

  --line-fine:  1px solid rgba(184, 146, 58, 0.18);
  --line-gold:  1px solid var(--gold);
  --shadow-soft: 0 1px 3px rgba(37, 38, 42, 0.05);
  --shadow-frame: 0 12px 48px rgba(37, 38, 42, 0.15);
}


/* ─────────────────────────────────────────────────────────────────────────
   2. BASE
   ───────────────────────────────────────────────────────────────────────── */

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 17px;
  line-height: 1.7;
  color: var(--ink);
  background: var(--page-bg);
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }

a {
  color: var(--ink);
  text-decoration: none;
  border-bottom: 1px solid var(--gold);
  transition: color 0.2s, border-color 0.2s;
  padding-bottom: 1px;
}
a:hover { color: var(--gold-deep); border-color: var(--gold-deep); }

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}
.hidden { display: none !important; }


/* ─────────────────────────────────────────────────────────────────────────
   3. TYPOGRAPHY
   ───────────────────────────────────────────────────────────────────────── */

h1, h2, h3, h4 {
  font-family: var(--font-sans);
  font-weight: 500;
  color: var(--ink);
  letter-spacing: -0.01em;
  line-height: 1.2;
  margin: 0 0 var(--space-3);
}

.display-heading {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(2.2rem, 5vw, 3.6rem);
  line-height: 1.1;
  color: var(--ink);
  letter-spacing: -0.015em;
  margin: 0 0 var(--space-3);
}
.display-heading em {
  font-style: italic;
  font-weight: 400;
  color: var(--gold-deep);
}

.display-sub {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 1.15rem;
  color: var(--ink-soft);
  margin: 0 0 var(--space-4);
  max-width: 36em;
  font-weight: 400;
}

.section-eyebrow {
  font-family: var(--font-sans);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--gold-deep);
  margin: 0 0 var(--space-2);
}
p.section-eyebrow { margin: 0 0 var(--space-2); }

.drop-cap-paragraph {
  font-family: var(--font-sans);
  font-size: 1.1rem;
  line-height: 1.75;
  color: var(--ink);
  margin: 0 0 var(--space-3);
}
.drop-cap-paragraph em {
  font-style: italic;
  color: var(--gold-deep);
  font-family: var(--font-serif);
}
.drop-cap {
  font-family: var(--font-display);
  font-style: italic;
  color: var(--gold-deep);
  font-weight: 500;
}


/* ─────────────────────────────────────────────────────────────────────────
   4. ORNAMENTS
   ───────────────────────────────────────────────────────────────────────── */

.ornament-break {
  display: flex;
  justify-content: center;
  align-items: center;
  color: var(--gold);
  margin: var(--space-4) 0;
  opacity: 0.85;
}
.ornament-break.narrow { margin: var(--space-3) 0; opacity: 0.5; }
.ornament-break svg { display: block; }


/* ─────────────────────────────────────────────────────────────────────────
   5. VERSE TICKER
   ───────────────────────────────────────────────────────────────────────── */

.verse-ticker {
  background: var(--tabernacle);
  color: var(--gold-bright);
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 0.88rem;
  letter-spacing: 0.04em;
  padding: 0.6rem 0;
  overflow: hidden;
  position: relative;
  /* GPU compositor layer — keeps the animation off the main thread */
  transform: translateZ(0);
  -webkit-transform: translateZ(0);
}
.verse-track {
  display: inline-block;
  white-space: nowrap;
  animation: verse-scroll 60s linear infinite;
  padding-left: 100%;
  /* These hint the browser to put the animation on the GPU compositor */
  will-change: transform;
  transform: translate3d(0, 0, 0);
  -webkit-transform: translate3d(0, 0, 0);
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
}
@keyframes verse-scroll {
  from { transform: translate3d(0, 0, 0); }
  to   { transform: translate3d(-50%, 0, 0); }
}
/* Respect reduced-motion preferences (iOS accessibility) */
@media (prefers-reduced-motion: reduce) {
  .verse-track {
    animation: none;
    padding-left: 0;
    text-align: center;
    display: block;
  }
}


/* ─────────────────────────────────────────────────────────────────────────
   6. HEADER
   ───────────────────────────────────────────────────────────────────────── */

.header {
  background: var(--white);
  border-bottom: var(--line-fine);
  position: sticky;
  top: 0;
  z-index: 500;
}

/* New stacked, centered header layout — logo prominent on top, then search, then actions */
.header-v2 .header-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: var(--space-3) var(--space-4) var(--space-2);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-2);
}

.header-v2 .header-brand {
  border-bottom: none;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-bottom: 0;
  margin-bottom: 4px;
}
.header-v2 .header-brand:hover { border-bottom: none; }

.header-v2 .site-logo {
  height: 180px;
  width: auto;
  display: block;
  max-width: 90vw;  /* never exceed phone width */
}

/* Search: full-width but capped, centered */
.header-v2 .header-search {
  position: relative;
  width: 100%;
  max-width: 560px;
}
.header-v2 .header-search input {
  width: 100%;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  padding: 0.7rem 1rem 0.7rem 2.4rem;
  background: var(--card-bg);
  border: var(--line-fine);
  border-radius: 0;
  color: var(--ink);
  transition: border-color 0.2s, box-shadow 0.2s;
}
.header-v2 .header-search input::placeholder { color: var(--ink-faint); }
.header-v2 .header-search input:focus {
  outline: none;
  border-color: var(--gold);
  box-shadow: 0 0 0 3px var(--gold-faint);
}

/* Actions: centered horizontally, wrap nicely. Sized to fit 5 buttons in one row on desktop */
.header-v2 .header-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  flex-wrap: wrap;
  max-width: 100%;
}

/* On medium-narrow screens (tablets), allow buttons to wrap to 2 rows cleanly */
@media (max-width: 900px) {
  .header-v2 .header-actions {
    gap: 0.35rem;
  }
  .header-v2 .header-actions .btn {
    font-size: 0.72rem;
    padding: 0.45rem 0.7rem;
  }
}

/* Mobile: logo a bit smaller, tighter spacing */
@media (max-width: 640px) {
  .header-v2 .header-inner {
    padding: var(--space-2) var(--space-3);
    gap: 0.6rem;
  }
  .header-v2 .site-logo {
    height: 140px;
  }
  .header-v2 .header-search input {
    font-size: 0.9rem;
    padding: 0.6rem 0.85rem 0.6rem 2.2rem;
  }
  .header-v2 .header-actions {
    gap: 0.35rem;
  }
}

/* Icon-only button variant (for "Add Chapel" + button in the header) */
.btn-icon-only {
  background: transparent;
  border: 1px solid var(--ink-ghost);
  border-radius: 50%;
  width: 38px;
  height: 38px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--gold-deep);
  transition: all 0.15s;
  flex-shrink: 0;
}
.btn-icon-only:hover {
  border-color: var(--gold);
  background: var(--gold-faint);
  color: var(--ink);
}
.btn-icon-only .btn-icon {
  margin: 0;
}

/* Suggestions dropdown — keep current behavior */
.suggestions {
  position: absolute;
  top: calc(100% + 4px);
  left: 0; right: 0;
  background: var(--card-bg);
  border: var(--line-fine);
  max-height: 320px;
  overflow-y: auto;
  z-index: 1000;
  display: none;
  box-shadow: var(--shadow-soft);
}
.suggestions.visible { display: block; }
.suggestion-item {
  padding: 0.7rem 1rem;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  color: var(--ink);
  cursor: pointer;
  border-bottom: var(--line-fine);
}
.suggestion-item:last-child { border-bottom: none; }
.suggestion-item:hover { background: var(--page-bg-soft); }

.search-icon {
  position: absolute;
  left: 0.85rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--gold-deep);
  display: flex;
}

/* Old header layout (kept for /about and /streams pages which still use it) */
.header-inner {
  max-width: 1400px;
  margin: 0 auto;
  padding: var(--space-2) var(--space-4);
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: var(--space-3);
  align-items: center;
}
.header-brand {
  border-bottom: none;
  display: block;
  padding-bottom: 0;
}
.header-brand:hover { border-bottom: none; }
.site-logo {
  height: 56px;
  width: auto;
}
.header-search {
  position: relative;
  max-width: 460px;
  width: 100%;
  justify-self: center;
}
.header-search input {
  width: 100%;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  padding: 0.7rem 1rem 0.7rem 2.4rem;
  background: var(--card-bg);
  border: var(--line-fine);
  border-radius: 0;
  color: var(--ink);
  transition: border-color 0.2s, box-shadow 0.2s;
}
.header-search input::placeholder { color: var(--ink-faint); }
.header-search input:focus {
  outline: none;
  border-color: var(--gold);
  box-shadow: 0 0 0 3px var(--gold-faint);
}
.header-actions {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}


/* ─────────────────────────────────────────────────────────────────────────
   7. BUTTONS
   ───────────────────────────────────────────────────────────────────────── */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-sans);
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.7rem 1.1rem;
  border: 1px solid transparent;
  background: transparent;
  color: var(--ink);
  cursor: pointer;
  transition: all 0.2s;
  border-radius: 0;
  white-space: nowrap;
}
.btn .btn-icon { color: currentColor; flex-shrink: 0; }

.btn-primary {
  background: var(--gold);
  color: var(--white);
  border-color: var(--gold);
}
.btn-primary:hover {
  background: var(--gold-deep);
  border-color: var(--gold-deep);
}

.btn-ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--ink-ghost);
}
.btn-ghost:hover {
  background: var(--page-bg-soft);
  color: var(--gold-deep);
  border-color: var(--gold);
}

.btn-icon-only {
  padding: 0.6rem;
  color: var(--ink-soft);
  border-color: var(--ink-ghost);
}
.btn-icon-only:hover {
  color: var(--gold-deep);
  border-color: var(--gold);
  background: var(--page-bg-soft);
}

.btn-large { padding: 1rem 2rem; font-size: 0.85rem; }
.btn.full-width { width: 100%; justify-content: center; }


/* ─────────────────────────────────────────────────────────────────────────
   8. HERO with photograph (NEW)
   ───────────────────────────────────────────────────────────────────────── */

.hero {
  position: relative;
  min-height: clamp(540px, 75vh, 760px);
  overflow: hidden;
  background: var(--tabernacle);
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.hero-image-wrap {
  position: absolute;
  inset: 0;
  z-index: 0;
  /* Behind the photo, in case object-fit:contain shows bars or photo fails to load */
  background: linear-gradient(180deg, #1a1208 0%, #3a2a14 30%, #6a4f1f 60%, #8a6824 100%);
}

.hero-image {
  width: 100%;
  height: 100%;
  /* Cover the entire frame at all screen sizes — no empty bars */
  object-fit: cover;
  object-position: center 30%;
  filter: brightness(0.95);
}

/* On wide screens, shift the focal point slightly higher so the monstrance head/host stays prominent */
@media (min-width: 1100px) {
  .hero-image {
    object-position: center 25%;
  }
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(to bottom, rgba(21, 17, 13, 0.35) 0%, rgba(21, 17, 13, 0.15) 40%, rgba(21, 17, 13, 0.55) 100%),
    radial-gradient(ellipse at center, transparent 30%, rgba(21, 17, 13, 0.4) 100%);
}

.hero-content {
  position: relative;
  z-index: 2;
  padding: var(--space-4) var(--space-3);
  max-width: 900px;
  color: var(--white);
}

.hero-title {
  margin: 0;
  font-family: var(--font-display);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.4rem;
}

.hero-eyebrow {
  font-family: var(--font-sans);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--gold-bright);
  margin-bottom: var(--space-3);
  text-shadow: 0 1px 8px rgba(0,0,0,0.5);
}

.hero-line-1 {
  font-size: clamp(2rem, 5vw, 3.4rem);
  font-weight: 400;
  font-style: italic;
  color: var(--white);
  text-shadow: 0 2px 16px rgba(0,0,0,0.6);
  letter-spacing: -0.005em;
  line-height: 1.1;
}

.hero-line-2 {
  font-size: clamp(2.8rem, 7.5vw, 5.2rem);
  font-weight: 500;
  color: var(--gold-light);
  text-shadow: 0 2px 24px rgba(0,0,0,0.7), 0 0 32px var(--gold-glow);
  letter-spacing: -0.01em;
  line-height: 1.05;
}
.hero-line-2 em {
  font-style: italic;
  color: var(--gold-light);
}

.hero-verse {
  margin-top: var(--space-4);
  font-family: var(--font-serif);
  font-style: italic;
  font-size: clamp(1rem, 1.6vw, 1.2rem);
  color: rgba(255, 255, 255, 0.85);
  text-shadow: 0 1px 8px rgba(0,0,0,0.6);
  letter-spacing: 0.01em;
  max-width: 32em;
  margin-left: auto;
  margin-right: auto;
}

/* Subtle attribution at bottom corner of hero */
.hero-attribution {
  position: absolute;
  bottom: 0.8rem;
  right: 1.2rem;
  left: 1.2rem;
  margin: 0;
  font-family: var(--font-sans);
  font-size: 0.65rem;
  line-height: 1.4;
  letter-spacing: 0.06em;
  color: rgba(255, 255, 255, 0.5);
  text-shadow: 0 1px 4px rgba(0,0,0,0.6);
  z-index: 3;
  text-align: right;
  max-width: 100%;
}

@media (max-width: 768px) {
  .hero-attribution {
    font-size: 0.6rem;
    bottom: 0.5rem;
    left: 0.8rem;
    right: 0.8rem;
    text-align: center;
  }
}

/* Graceful fallback if the hero photo is missing: warm gold gradient background */
.hero.no-image,
.hero:has(.hero-image[src=""]) {
  background:
    radial-gradient(ellipse at center, rgba(212, 168, 58, 0.4) 0%, rgba(122, 95, 31, 0.6) 50%, var(--tabernacle) 100%),
    var(--tabernacle);
}
.hero.no-image .hero-overlay {
  background:
    radial-gradient(ellipse at center, transparent 30%, rgba(21, 17, 13, 0.5) 100%);
}
.hero.no-image .hero-attribution { display: none; }


/* ─────────────────────────────────────────────────────────────────────────
   9. MAP
   ───────────────────────────────────────────────────────────────────────── */

.map-section {
  padding: var(--space-5) var(--space-3) var(--space-4);
  max-width: 1500px;
  margin: 0 auto;
}

.map-frame {
  position: relative;
  border: var(--line-fine);
  background: var(--tabernacle);
}

#map {
  height: 560px;
  width: 100%;
  background: var(--tabernacle);
}

.map-caption {
  text-align: center;
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 1.05rem;
  color: var(--ink-soft);
  margin: var(--space-3) auto 0;
  max-width: 48em;
}
.map-caption em { color: var(--ink); }
.caption-cite {
  display: block;
  font-style: normal;
  font-family: var(--font-sans);
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold-deep);
  margin-top: 0.6rem;
  font-weight: 600;
}

/* ─────────────────────────────────────────────────────────────────────────
   9b. MAP MARKERS — classic gold cross
   ───────────────────────────────────────────────────────────────────────── */

.custom-marker {
  background: transparent;
  border: none;
}
.custom-marker svg {
  display: block;
  filter: drop-shadow(0 2px 4px rgba(122, 95, 31, 0.35));
  transition: transform 0.18s ease, filter 0.18s ease;
  transform-origin: 50% 90%;  /* anchor at the bottom of the cross */
}
.custom-marker:hover svg {
  transform: scale(1.18);
  filter: drop-shadow(0 4px 10px rgba(184, 146, 58, 0.6));
}

/* Update legend dot to match new marker style */
.legend-physical {
  background: radial-gradient(circle at 50% 35%, #e6c065 0%, #c89640 40%, #7a5f1f 100%);
  border-radius: 50%;
  box-shadow: 0 0 0 1px rgba(122, 95, 31, 0.4);
}

/* User location marker — soft blue pulsing dot */
.user-location-marker {
  background: transparent;
  border: none;
}
.user-location-marker .user-dot {
  position: absolute;
  top: 4px; left: 4px;
  width: 14px; height: 14px;
  border-radius: 50%;
  background: #3b82f6;
  box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.95),
              0 2px 6px rgba(37, 38, 42, 0.3);
  z-index: 2;
}
.user-location-marker .user-pulse {
  position: absolute;
  top: 4px; left: 4px;
  width: 14px; height: 14px;
  border-radius: 50%;
  background: rgba(59, 130, 246, 0.4);
  animation: user-pulse-ring 2s ease-out infinite;
  z-index: 1;
}
@keyframes user-pulse-ring {
  0%   { transform: scale(1); opacity: 0.7; }
  100% { transform: scale(2.4); opacity: 0; }
}

/* Map legend */
.map-legend {
  background: var(--card-bg);
  border: var(--line-fine);
  padding: 0.6rem 0.9rem;
  box-shadow: var(--shadow-soft);
  font-family: var(--font-sans);
  font-size: 0.78rem;
  color: var(--ink);
  line-height: 1.5;
}
.legend-title {
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  color: var(--gold-deep);
  margin-bottom: 0.4rem;
}
.legend-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.legend-dot {
  display: inline-block;
  width: 12px; height: 12px;
  border-radius: 50%;
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.9);
}
.legend-physical {
  background: radial-gradient(circle at 30% 30%, #e6c065, #b8923a 60%, #7a5f1f);
}
.leaflet-popup-content-wrapper {
  background: var(--card-bg) !important;
  border: var(--line-fine) !important;
  border-radius: 0 !important;
  box-shadow: 0 4px 16px rgba(37, 38, 42, 0.12) !important;
}
.leaflet-popup-tip {
  background: var(--card-bg) !important;
  border: var(--line-fine) !important;
}
.leaflet-popup-content {
  font-family: var(--font-sans) !important;
  font-size: 0.92rem !important;
  margin: 1rem 1.1rem !important;
  line-height: 1.55;
}
.leaflet-popup-content b, .leaflet-popup-content strong {
  font-family: var(--font-display);
  font-size: 1.15rem;
  color: var(--ink);
  font-weight: 500;
}
.popup-perpetual {
  margin-top: 0.5rem;
  padding: 0.25rem 0.55rem;
  background: var(--gold-faint);
  color: var(--gold-deep);
  font-family: var(--font-sans);
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  display: inline-block;
  border: 1px solid var(--gold);
}
.leaflet-popup-content a {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  margin-top: 0.7rem;
  padding: 0.45rem 0.9rem;
  background: var(--gold);
  color: var(--white) !important;
  font-family: var(--font-sans);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 500;
  border-bottom: none !important;
}
.leaflet-popup-content a:hover { background: var(--gold-deep); }

.marker-cluster {
  background: rgba(184, 146, 58, 0.4) !important;
  border: 1px solid var(--gold-bright) !important;
}
.marker-cluster div {
  background: var(--gold) !important;
  color: var(--tabernacle) !important;
  font-family: var(--font-sans) !important;
  font-weight: 600 !important;
}


/* ─────────────────────────────────────────────────────────────────────────
  10. LIVE ADORATION
   ───────────────────────────────────────────────────────────────────────── */

.live-section {
  background: linear-gradient(135deg, #d4a83a 0%, #b8923a 35%, #a07628 65%, #7a5f1f 100%);
  background-attachment: fixed;
  color: var(--white);
  padding: var(--space-6) var(--space-3);
  text-align: center;
  position: relative;
}
.live-section::before {
  /* Soft radial highlight from upper-left, like sunlight catching gilt */
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 30% 20%, rgba(255, 235, 180, 0.35), transparent 50%),
    radial-gradient(ellipse at 70% 80%, rgba(122, 95, 31, 0.4), transparent 60%);
  pointer-events: none;
}
.live-section > * { position: relative; z-index: 1; }

.live-inner { max-width: 1180px; margin: 0 auto; }

.section-marker {
  color: var(--gold);
  display: flex;
  justify-content: center;
  margin-bottom: var(--space-3);
}

.live-section .section-marker {
  color: rgba(255, 248, 225, 0.95);
}
.live-section .display-heading {
  color: var(--white);
  font-size: clamp(2.4rem, 5vw, 3.8rem);
  text-shadow: 0 2px 16px rgba(122, 95, 31, 0.4);
}
.live-section .display-heading em {
  color: #fff8e1;
  font-style: italic;
}
.live-section .display-sub {
  color: rgba(255, 248, 225, 0.85);
  margin-left: auto;
  margin-right: auto;
}

.tabernacle-frame {
  margin: var(--space-4) auto;
  padding: 8px;
  background: linear-gradient(135deg, #2a221a, #15110d, #2a221a);
  max-width: 1100px;
  position: relative;
  box-shadow: 0 16px 48px rgba(122, 95, 31, 0.5), 0 0 0 1px rgba(255, 248, 225, 0.3) inset;
  transition: padding 0.3s ease;
}

/* ─── Floating mini-player chrome (hidden by default) ─── */
.floating-chrome {
  display: none;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 6px 4px 8px;
  cursor: move;
  user-select: none;
}
.floating-title {
  flex: 1;
  font-family: var(--font-sans);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold-bright);
  padding-left: 0.4rem;
  white-space: nowrap;
}
.floating-btn {
  background: transparent;
  border: 1px solid rgba(212, 168, 58, 0.4);
  color: var(--gold-bright);
  width: 26px;
  height: 26px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  border-radius: 0;
  padding: 0;
  transition: all 0.15s;
  flex-shrink: 0;
}
.floating-btn:hover {
  background: var(--gold);
  color: var(--tabernacle);
  border-color: var(--gold);
}

/* ─── FLOATING STATE ─── */
.tabernacle-frame.floating {
  position: fixed;
  bottom: 24px;
  right: 24px;
  margin: 0;
  z-index: 99999;
  width: 360px;
  max-width: calc(100vw - 32px);
  padding: 4px;
  /* Solid dark background — prevents any element behind from showing through during iframe load */
  background: linear-gradient(135deg, #2a221a, #15110d, #2a221a);
  /* Heavy drop shadow so the player reads as clearly floating above content, not blending into it */
  box-shadow:
    0 24px 56px rgba(0, 0, 0, 0.55),
    0 8px 20px rgba(0, 0, 0, 0.4),
    0 0 0 1px rgba(255, 248, 225, 0.35) inset,
    0 0 0 2px rgba(0, 0, 0, 0.6);
  /* Animation: simple fade+slide, no transform conflict */
  animation: floating-in 0.35s cubic-bezier(0.16, 1, 0.3, 1) both;
  /* GPU layer + isolation for bulletproof stacking on iOS Safari */
  isolation: isolate;
  will-change: transform, opacity;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
}

/* Iframe inside the floating frame should also be opaque/black, not transparent */
.tabernacle-frame.floating .live-video-frame {
  background: #000;
}
.tabernacle-frame.floating iframe {
  background: #000;
}

@keyframes floating-in {
  from { transform: translate3d(0, 20px, 0); opacity: 0; }
  to   { transform: translate3d(0, 0, 0); opacity: 1; }
}
.tabernacle-frame.floating::after {
  inset: 2px;
}
.tabernacle-frame.floating .floating-chrome { display: flex; }
.tabernacle-frame.floating.dragging {
  animation: none;
  transition: none;
  cursor: grabbing;
}

/* Placeholder is hidden by default, only shown when video is detached/floating */
.tabernacle-placeholder {
  display: none !important;
}
.live-section.video-detached .tabernacle-placeholder {
  display: flex !important;
  margin: var(--space-4) auto;
  max-width: 1100px;
  aspect-ratio: 16 / 9;
  background: rgba(21, 17, 13, 0.06);
  border: 1px dashed rgba(122, 95, 31, 0.25);
  align-items: center;
  justify-content: center;
  font-family: var(--font-sans);
  font-size: 0.75rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(122, 95, 31, 0.5);
  font-weight: 500;
}

/* Mobile: small picture-in-picture style mini-player anchored bottom-right */
@media (max-width: 640px) {
  .tabernacle-frame.floating {
    /* Genuinely small — like YouTube's PiP, not nearly-full-width */
    width: 240px;
    max-width: 80vw;
    bottom: 16px;
    right: 12px;
    padding: 3px;
    /* Much stronger drop shadow on mobile so it cleanly separates from hero/content behind it */
    box-shadow:
      0 24px 48px rgba(0, 0, 0, 0.7),
      0 8px 16px rgba(0, 0, 0, 0.5),
      0 0 0 1px rgba(255, 248, 225, 0.4) inset,
      0 0 0 2px rgba(0, 0, 0, 0.8);
  }
  /* Smaller chrome bar on mobile */
  .tabernacle-frame.floating .floating-chrome {
    padding: 4px 4px 6px;
  }
  .tabernacle-frame.floating .floating-title {
    font-size: 0.6rem;
    letter-spacing: 0.12em;
  }
  .tabernacle-frame.floating .floating-btn {
    width: 22px;
    height: 22px;
  }
}
.tabernacle-frame::after {
  content: "";
  position: absolute;
  inset: 4px;
  border: 1px solid rgba(212, 168, 58, 0.4);
  pointer-events: none;
}

.live-video-frame {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000;
  overflow: hidden;
}
.live-video-frame iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: none;
}

.live-placeholder {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  background: var(--tabernacle);
  color: var(--gold);
}
.placeholder-monstrance {
  color: var(--gold);
  filter: drop-shadow(0 0 24px rgba(184, 146, 58, 0.4));
  animation: monstrance-glow 4s ease-in-out infinite;
}
@keyframes monstrance-glow {
  0%, 100% { opacity: 0.7; filter: drop-shadow(0 0 16px rgba(184, 146, 58, 0.3)); }
  50%      { opacity: 1;   filter: drop-shadow(0 0 32px rgba(212, 168, 58, 0.5)); }
}
.live-placeholder p {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 1.05rem;
  color: rgba(255, 255, 255, 0.7);
  margin: 0;
}

.live-credit {
  font-family: var(--font-sans);
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(255, 248, 225, 0.85);
  margin: var(--space-3) 0 0;
  font-weight: 500;
}
.live-credit a {
  color: #fff8e1;
  border-color: rgba(255, 248, 225, 0.4);
}
.live-credit a:hover { color: var(--white); border-color: var(--white); }


/* ─────────────────────────────────────────────────────────────────────────
  12. NEARBY PANEL
   ───────────────────────────────────────────────────────────────────────── */

.nearby {
  position: fixed;
  top: 50%;
  right: var(--space-3);
  transform: translateY(-50%);
  width: 320px;
  max-height: 70vh;
  background: var(--card-bg);
  border: var(--line-fine);
  box-shadow: 0 8px 32px rgba(37, 38, 42, 0.12);
  padding: var(--space-3);
  z-index: 900;
  overflow-y: auto;
}
.nearby h3 {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-sans);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ink);
  border-bottom: var(--line-gold);
  padding-bottom: var(--space-2);
  margin: 0 0 var(--space-2);
  padding-right: 2rem;
}

.nearby-close {
  position: absolute;
  top: 0.4rem;
  right: 0.6rem;
  background: transparent;
  border: none;
  font-size: 1.6rem;
  line-height: 1;
  color: var(--ink-faint);
  cursor: pointer;
  padding: 0.3rem 0.6rem;
  transition: color 0.2s;
  z-index: 2;
  font-family: var(--font-display);
}
.nearby-close:hover { color: var(--gold-deep); }
.inline-icon { color: var(--gold-deep); }

.nearby-item {
  padding: 0.85rem 0;
  border-bottom: var(--line-fine);
  cursor: pointer;
  transition: background 0.15s;
}
.nearby-item:last-child { border-bottom: none; }
.nearby-item:hover { background: var(--page-bg-soft); }
.nearby-name {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 500;
  color: var(--ink);
}
.nearby-meta {
  font-family: var(--font-sans);
  font-size: 0.82rem;
  color: var(--ink-faint);
  margin-top: 0.2rem;
}
.nearby-header {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 0.9rem;
  color: var(--ink-soft);
  padding-bottom: var(--space-2);
  border-bottom: var(--line-fine);
  margin-bottom: var(--space-2);
}
.nearby-empty {
  font-family: var(--font-serif);
  font-style: italic;
  color: var(--ink-faint);
  text-align: center;
  padding: var(--space-3) var(--space-2);
}


/* ─────────────────────────────────────────────────────────────────────────
  13. MISSION
   ───────────────────────────────────────────────────────────────────────── */

.mission-section {
  padding: var(--space-6) var(--space-3);
  background: var(--page-bg);
}
.mission-grid {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 5fr 7fr;
  gap: var(--space-6);
  align-items: start;
}

.mission-aside {
  position: sticky;
  top: 100px;
  text-align: center;
  padding: var(--space-4) var(--space-3);
  min-height: 200px;
}

.mission-photo-wrap {
  display: flex;
  justify-content: center;
  margin-bottom: var(--space-3);
  padding: 0 var(--space-2);
}
.mission-photo {
  max-width: 100%;
  width: auto;
  height: auto;
  max-height: 380px;
  display: block;
  /* Subtle gold drop shadow — like light catching gilt */
  filter: drop-shadow(0 8px 24px rgba(184, 146, 58, 0.25))
          drop-shadow(0 2px 6px rgba(37, 38, 42, 0.08));
  transition: transform 0.6s ease;
}
.mission-photo:hover {
  transform: scale(1.02);
}

.aside-quote {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 1.4rem;
  line-height: 1.45;
  color: var(--ink);
  max-width: 18em;
  margin: 0 auto var(--space-2);
  font-weight: 400;
}
.aside-attribution {
  font-family: var(--font-sans);
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold-deep);
  margin: 0;
  font-weight: 600;
}

.mission-body { padding-top: var(--space-3); }
.mission-eyebrow {
  font-family: var(--font-sans);
  font-size: 0.72rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--gold-deep);
  font-weight: 600;
  margin: 0 0 var(--space-2);
}

.mission-coda {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 1.15rem;
  line-height: 1.65;
  color: var(--ink-soft);
  margin: var(--space-3) 0 0;
  max-width: 32em;
}


/* ─────────────────────────────────────────────────────────────────────────
  14. HOW IT WORKS
   ───────────────────────────────────────────────────────────────────────── */

.how-section {
  padding: var(--space-6) var(--space-3);
  background: var(--page-bg);
}
.how-header {
  max-width: 880px;
  margin: 0 auto var(--space-5);
  text-align: center;
}
.how-chapters {
  list-style: none;
  padding: 0;
  margin: 0 auto;
  max-width: 920px;
}

.how-chapter {
  display: grid;
  grid-template-columns: 100px 1fr;
  gap: var(--space-4);
  align-items: start;
  padding: var(--space-4) 0;
  border-bottom: var(--line-fine);
}
.how-chapter:last-of-type { border-bottom: none; }

.chapter-numeral {
  font-family: var(--font-sans);
  font-size: 2rem;
  font-weight: 200;
  color: var(--gold-deep);
  line-height: 1;
  text-align: right;
  letter-spacing: -0.02em;
  padding-top: 0.3rem;
  position: relative;
}
.chapter-numeral::after {
  content: "";
  display: block;
  margin: 1rem 0 0 auto;
  width: 24px;
  height: 1px;
  background: var(--gold);
}

.chapter-text h3 {
  font-family: var(--font-display);
  font-size: 1.7rem;
  font-weight: 500;
  color: var(--ink);
  margin: 0 0 var(--space-2);
}
.chapter-text p {
  font-family: var(--font-sans);
  font-size: 1.05rem;
  line-height: 1.7;
  color: var(--ink-soft);
  margin: 0;
  max-width: 38em;
}


/* ─────────────────────────────────────────────────────────────────────────
  16. PLEDGE + FORMS
   ───────────────────────────────────────────────────────────────────────── */

.pledge-section {
  padding: var(--space-6) var(--space-3);
  background: var(--page-bg-soft);
  text-align: center;
  border-top: var(--line-fine);
  border-bottom: var(--line-fine);
}
.pledge-inner { max-width: 620px; margin: 0 auto; }

.prose-form {
  margin-top: var(--space-3);
  text-align: left;
}
.prose-form .form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-2);
  margin-bottom: var(--space-2);
}
.prose-form input,
.prose-form textarea,
.prose-form select {
  width: 100%;
  padding: 0.9rem 1rem;
  font-family: var(--font-sans);
  font-size: 1rem;
  background: var(--card-bg);
  border: var(--line-fine);
  border-radius: 0;
  color: var(--ink);
  transition: border-color 0.2s, box-shadow 0.2s;
  margin-bottom: var(--space-2);
}
.prose-form input::placeholder,
.prose-form textarea::placeholder { color: var(--ink-faint); }
.prose-form input:focus,
.prose-form textarea:focus,
.prose-form select:focus {
  outline: none;
  border-color: var(--gold);
  box-shadow: 0 0 0 3px var(--gold-faint);
}
.prose-form textarea { resize: vertical; min-height: 110px; }
.prose-form .btn { width: 100%; justify-content: center; margin-top: var(--space-2); }

.checkbox-row {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--font-sans);
  color: var(--ink);
  cursor: pointer;
  padding: var(--space-2) 0;
}
.checkbox-row input { width: auto; margin: 0; padding: 0; }

.thanks-msg {
  margin-top: var(--space-3);
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 1.15rem;
  color: var(--ink);
  padding: var(--space-3);
  border-top: var(--line-gold);
  border-bottom: var(--line-gold);
  background: var(--gold-faint);
}

.form-error, .form-message {
  margin-top: var(--space-2);
  font-family: var(--font-sans);
  font-size: 0.9rem;
  font-style: italic;
  color: var(--ink-soft);
}


/* ─────────────────────────────────────────────────────────────────────────
  17. READING LIST
   ───────────────────────────────────────────────────────────────────────── */

.reading-section {
  padding: var(--space-6) var(--space-3);
  background: var(--page-bg-deep);
  border-top: var(--line-fine);
}
.reading-header {
  max-width: 720px;
  margin: 0 auto var(--space-5);
  text-align: center;
}
.reading-list {
  max-width: 760px;
  margin: 0 auto;
  list-style: none;
  padding: 0;
}

.reading-entry {
  padding: var(--space-3) 0;
  border-bottom: var(--line-fine);
}
.reading-entry:last-child { border-bottom: none; }
.reading-entry a { text-decoration: none; border-bottom: none; }

.reading-title {
  font-family: var(--font-display);
  font-size: 1.45rem;
  font-weight: 500;
  color: var(--ink);
  display: block;
  margin-bottom: 0.4rem;
  transition: color 0.2s;
}
.reading-entry a:hover .reading-title { color: var(--gold-deep); }

.reading-author {
  display: block;
  font-family: var(--font-sans);
  font-size: 0.75rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold-deep);
  margin-bottom: 0.5rem;
  font-weight: 600;
}

.reading-desc {
  display: block;
  font-family: var(--font-sans);
  font-size: 1rem;
  color: var(--ink-soft);
  line-height: 1.6;
}


/* ─────────────────────────────────────────────────────────────────────────
  19. CONTACT
   ───────────────────────────────────────────────────────────────────────── */

.contact-section {
  padding: var(--space-6) var(--space-3);
  background: var(--page-bg-soft);
  text-align: center;
  border-top: var(--line-fine);
}
.contact-inner { max-width: 620px; margin: 0 auto; }
.contact-intro {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 1.15rem;
  color: var(--ink-soft);
  margin: 0 0 var(--space-4);
}


/* ─────────────────────────────────────────────────────────────────────────
  20. FOOTER
   ───────────────────────────────────────────────────────────────────────── */

.footer {
  background: var(--page-bg);
  color: var(--ink);
  padding: var(--space-5) var(--space-3) 0;
  font-family: var(--font-sans);
  border-top: var(--line-fine);
}
.footer-ornament {
  display: flex;
  justify-content: center;
  color: var(--gold);
  margin-bottom: var(--space-4);
  opacity: 0.85;
}
.footer-container {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: var(--space-4);
  padding-bottom: var(--space-5);
}
.footer-col h4 {
  font-family: var(--font-sans);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold-deep);
  margin: 0 0 var(--space-2);
}
.footer-col ul { list-style: none; padding: 0; margin: 0; }
.footer-col li { margin: 0.55rem 0; font-size: 0.95rem; }
.footer-col a {
  color: var(--ink-soft);
  border-bottom: none;
  transition: color 0.2s;
}
.footer-col a:hover { color: var(--gold-deep); }

.footer-col-mission .footer-motto {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.15rem;
  color: var(--gold-deep);
  margin: 0 0 var(--space-2);
  font-weight: 500;
}
.footer-mission-text {
  font-family: var(--font-sans);
  font-size: 0.92rem;
  line-height: 1.65;
  color: var(--ink-soft);
  margin: 0;
  max-width: 30em;
}

.language-select { margin-bottom: var(--space-2); }
.language-select select {
  width: 100%;
  padding: 0.55rem 0.7rem;
  background: var(--card-bg);
  color: var(--ink);
  border: var(--line-fine);
  font-family: var(--font-sans);
  font-size: 0.9rem;
  border-radius: 0;
  cursor: pointer;
}
.language-select select:focus { outline: none; border-color: var(--gold); }

.share-btn {
  width: 100%;
  padding: 0.7rem 1rem;
  background: transparent;
  color: var(--gold-deep);
  border: 1px solid var(--gold);
  font-family: var(--font-sans);
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}
.share-btn:hover {
  background: var(--gold);
  color: var(--white);
  border-color: var(--gold);
}

/* Pope Benedict XVI quote — sits between the four-column footer and the dark colophon */
.footer-quote {
  max-width: 720px;
  margin: var(--space-4) auto 0;
  text-align: center;
  padding: 0 var(--space-3);
}
.footer-quote-text {
  font-family: var(--font-display);
  font-style: italic;
  font-size: clamp(1.1rem, 2vw, 1.4rem);
  line-height: 1.55;
  color: var(--ink);
  margin: 0 0 var(--space-2);
}
.footer-quote-author {
  font-family: var(--font-sans);
  font-size: 0.7rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold-deep);
  font-weight: 600;
  margin: 0 0 var(--space-3);
}

/* Colophon strip — only this stays dark, matching the verse ticker at the top */
.footer-colophon {
  background: var(--tabernacle);
  color: rgba(255, 255, 255, 0.55);
  margin: 0 calc(var(--space-3) * -1);
  padding: var(--space-2) var(--space-3);
  text-align: center;
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 0.82rem;
}
.footer-colophon p { margin: 0; }
.footer-colophon a {
  color: rgba(255, 255, 255, 0.7);
  border-bottom: none;
  font-style: normal;
  letter-spacing: 0.08em;
}
.footer-colophon a:hover { color: var(--gold-bright); }


/* ─────────────────────────────────────────────────────────────────────────
  21. POPUP HELPERS
   ───────────────────────────────────────────────────────────────────────── */

.popup-card { font-family: var(--font-sans); }
.popup-loc {
  font-family: var(--font-sans);
  color: var(--ink-soft);
  font-size: 0.88rem;
  margin-top: 0.3rem;
}
.popup-schedule {
  font-family: var(--font-sans);
  font-size: 0.85rem;
  color: var(--ink-soft);
  margin-top: 0.4rem;
  font-style: italic;
}


/* ─────────────────────────────────────────────────────────────────────────
  22. MODALS
   ───────────────────────────────────────────────────────────────────────── */

.modal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(37, 38, 42, 0.65);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 2000;
  align-items: center;
  justify-content: center;
  padding: var(--space-3);
}
.modal.visible { display: flex; }

.modal-content {
  background: var(--card-bg);
  border: var(--line-fine);
  box-shadow: 0 24px 64px rgba(37, 38, 42, 0.25);
  padding: var(--space-4);
  max-width: 560px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
}

.modal-close {
  position: absolute;
  top: 0.6rem;
  right: 0.8rem;
  background: transparent;
  border: none;
  font-size: 1.8rem;
  color: var(--ink-faint);
  cursor: pointer;
  line-height: 1;
  padding: 0.2rem 0.5rem;
  transition: color 0.2s;
  z-index: 1;
}
.modal-close:hover { color: var(--ink); }

.modal-form h2 {
  font-family: var(--font-display);
  font-size: 1.8rem;
  font-weight: 500;
  color: var(--ink);
  text-align: center;
  margin: 0 0 var(--space-1);
}
.modal-marker {
  text-align: center;
  color: var(--gold-deep);
  margin-bottom: var(--space-2);
  display: flex;
  justify-content: center;
}
.modal-sub {
  text-align: center;
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 0.98rem;
  color: var(--ink-soft);
  margin: 0 0 var(--space-3);
}
.modal-note {
  margin-top: var(--space-2);
  font-family: var(--font-sans);
  font-size: 0.85rem;
  color: var(--ink-faint);
  text-align: center;
}


/* ─────────────────────────────────────────────────────────────────────────
  23. RESPONSIVE
   ───────────────────────────────────────────────────────────────────────── */

@media (max-width: 1100px) {
  .header-inner {
    grid-template-columns: auto 1fr;
    gap: var(--space-3);
  }
  .header-search {
    grid-column: 1 / -1;
    max-width: 100%;
  }
  .header-actions {
    grid-column: 1 / -1;
    justify-content: flex-end;
    flex-wrap: wrap;
  }
  .mission-grid {
    grid-template-columns: 1fr;
    gap: var(--space-4);
  }
  .mission-aside {
    position: static;
    border-bottom: var(--line-fine);
    padding-bottom: var(--space-4);
  }
  .nearby { width: 280px; }
}

@media (max-width: 768px) {
  body { font-size: 16px; }

  .header-inner {
    padding: var(--space-2) var(--space-3);
    gap: var(--space-2);
  }
  .site-logo { height: 44px; }

  /* Show icons + labels, just compact them */
  .header-actions .btn {
    padding: 0.5rem 0.65rem;
    font-size: 0.68rem;
    letter-spacing: 0.06em;
    gap: 0.35rem;
  }
  .header-actions .btn .btn-icon {
    width: 13px;
    height: 13px;
  }
  .header-actions .btn span { display: inline !important; }

  /* Mobile: action buttons sit BELOW the search bar, centered */
  .header-actions {
    flex-wrap: wrap;
    justify-content: center;  /* centered as requested */
    gap: 0.4rem;
    width: 100%;
  }
  /* Hide music button on mobile to make room for the four primary buttons */
  #musicToggle { display: none; }

  .hero { min-height: 480px; }
  .hero-content { padding: var(--space-3) var(--space-2); }

  .map-section { padding: var(--space-3) var(--space-2); }
  #map { height: 400px; }

  .nearby {
    position: fixed;
    top: auto;
    bottom: 0; left: 0; right: 0;
    transform: none;
    width: 100%;
    max-height: 50vh;
    border: none;
    border-top: var(--line-fine);
  }

  .mission-section, .how-section, .pledge-section,
  .reading-section, .contact-section, .live-section {
    padding-left: var(--space-2);
    padding-right: var(--space-2);
  }
  .mission-section, .how-section, .reading-section {
    padding-top: var(--space-5);
    padding-bottom: var(--space-5);
  }

  .how-chapter {
    grid-template-columns: 60px 1fr;
    gap: var(--space-2);
  }
  .chapter-numeral { font-size: 1.5rem; padding-top: 0.4rem; }
  .chapter-numeral::after { width: 16px; margin-top: 0.7rem; }
  .chapter-text h3 { font-size: 1.35rem; }
  .chapter-text p { font-size: 0.98rem; }

  .prose-form .form-row {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .footer-container {
    grid-template-columns: 1fr;
    gap: var(--space-3);
  }
  .footer-col-mission { text-align: center; }
}

@media (max-width: 480px) {
  .header-inner { padding: 0.6rem var(--space-2); }
  .site-logo { height: 38px; }
  .header-actions .btn {
    font-size: 0.62rem;
    padding: 0.4rem 0.55rem;
    letter-spacing: 0.04em;
    gap: 0.3rem;
  }
  .header-actions .btn .btn-icon { width: 12px; height: 12px; }
  .header-actions { gap: 0.3rem; }
  .display-heading { font-size: 1.8rem; }
  .display-sub { font-size: 1rem; }
  .aside-quote { font-size: 1.2rem; }
}


/* ─────────────────────────────────────────────────────────────────────────
  24. ACCESSIBILITY
   ───────────────────────────────────────────────────────────────────────── */

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  .placeholder-monstrance { animation: none; }
  .verse-track { animation: none; padding-left: 0; }
}

:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 2px;
}


/* ═══════════════════════════════════════════════════════════════════════════
   ABOUT PAGE
   ═══════════════════════════════════════════════════════════════════════════ */

/* Page nav (replaces the header-actions on simpler pages) */
.page-nav {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  font-family: var(--font-sans);
}
.page-nav a {
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-soft);
  border-bottom: none;
  padding: 0.5rem 0;
  position: relative;
  transition: color 0.2s;
}
.page-nav a:hover { color: var(--gold-deep); }
.page-nav a.active {
  color: var(--gold-deep);
  border-bottom: 2px solid var(--gold);
}

/* About hero — quiet typographic, no photo */
.about-hero {
  padding: var(--space-7) var(--space-3) var(--space-5);
  background: var(--page-bg);
  text-align: center;
}
.about-hero-inner {
  max-width: 840px;
  margin: 0 auto;
}
.about-hero .display-heading {
  font-size: clamp(2.6rem, 6vw, 4.4rem);
}

/* Essay — longer-form reading */
.essay-section {
  padding: var(--space-5) var(--space-3) var(--space-6);
  background: var(--page-bg);
}
.essay-inner {
  max-width: 680px;
  margin: 0 auto;
  font-family: var(--font-sans);
  font-size: 1.08rem;
  line-height: 1.85;
  color: var(--ink);
}
.essay-lead {
  font-family: var(--font-display);
  font-size: clamp(1.3rem, 2.6vw, 1.7rem);
  line-height: 1.45;
  color: var(--ink);
  font-weight: 400;
  margin: 0 0 var(--space-4);
  font-style: italic;
}
.essay-lead em {
  font-style: italic;
  color: var(--gold-deep);
}
.essay-inner p {
  margin: 0 0 var(--space-3);
}
.essay-inner p em {
  font-family: var(--font-serif);
  font-style: italic;
  color: var(--gold-deep);
}

/* Saints */
.saints-section {
  padding: var(--space-6) var(--space-3);
  background: var(--page-bg-deep);
  border-top: var(--line-fine);
  border-bottom: var(--line-fine);
  text-align: center;
}
.saints-inner {
  max-width: 1100px;
  margin: 0 auto;
}
.saints-section .display-heading {
  margin-bottom: var(--space-5);
}
.saints-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-4);
  margin-top: var(--space-4);
  text-align: center;
}
.saint-block {
  padding: var(--space-3);
  border-top: 1px solid var(--gold);
}
.saint-name {
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 500;
  color: var(--ink);
  margin: 0 0 var(--space-2);
  letter-spacing: -0.005em;
}
.saint-quote {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 1.1rem;
  line-height: 1.55;
  color: var(--gold-deep);
  margin: 0 0 var(--space-2);
}
.saint-context {
  font-family: var(--font-sans);
  font-size: 0.92rem;
  line-height: 1.65;
  color: var(--ink-soft);
  margin: 0;
}

/* CTA */
.cta-section {
  padding: var(--space-6) var(--space-3);
  background: var(--page-bg);
  text-align: center;
}
.cta-inner {
  max-width: 720px;
  margin: 0 auto;
}
.cta-line {
  font-family: var(--font-display);
  font-style: italic;
  font-size: clamp(1.6rem, 3.4vw, 2.6rem);
  line-height: 1.3;
  color: var(--ink);
  margin: 0 0 var(--space-4);
  font-weight: 400;
}
.cta-buttons {
  display: flex;
  justify-content: center;
  gap: var(--space-2);
  flex-wrap: wrap;
}
.cta-buttons .btn {
  text-decoration: none;
  border-bottom: 1px solid transparent;
}

/* Mobile responsive */
@media (max-width: 768px) {
  .about-hero {
    padding: var(--space-5) var(--space-2) var(--space-4);
  }
  .essay-section {
    padding: var(--space-4) var(--space-2) var(--space-5);
  }
  .essay-inner { font-size: 1rem; }
  .saints-section {
    padding: var(--space-5) var(--space-2);
  }
  .saints-grid {
    grid-template-columns: 1fr;
    gap: var(--space-3);
  }
  .cta-section {
    padding: var(--space-5) var(--space-2);
  }
  .page-nav {
    gap: 0.9rem;
    flex-wrap: wrap;
    justify-content: center;
    width: 100%;
  }
  .page-nav a { font-size: 0.7rem; letter-spacing: 0.08em; }
}


/* ═══════════════════════════════════════════════════════════════════════════
   LIVE STREAMS PAGE
   ═══════════════════════════════════════════════════════════════════════════ */

.streams-featured {
  padding: var(--space-5) var(--space-3) var(--space-5);
  background: var(--page-bg);
  text-align: center;
  border-bottom: var(--line-fine);
}
.streams-featured-inner {
  max-width: 1180px;
  margin: 0 auto;
}
.streams-featured .section-marker {
  margin-bottom: var(--space-2);
}
.streams-featured .live-credit {
  font-family: var(--font-sans);
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  margin: var(--space-2) 0 0;
  font-weight: 500;
  color: var(--ink-soft);
}
.streams-featured .live-credit a {
  color: var(--gold-deep);
  border-color: var(--gold);
}

/* List section */
.streams-list-section {
  padding: var(--space-6) var(--space-3);
  background: var(--page-bg);
}
.streams-list-section .reading-header {
  margin-bottom: var(--space-4);
}

.streams-grid {
  max-width: 1100px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: var(--space-3);
}

/* Stream card */
.stream-card {
  display: flex;
  flex-direction: column;
  background: var(--white);
  border: var(--line-fine);
  text-decoration: none;
  border-bottom: var(--line-fine);
  color: inherit;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
  overflow: hidden;
}
a.stream-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 36px rgba(122, 95, 31, 0.18);
  border-color: var(--gold);
}

.stream-card-thumb {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: linear-gradient(135deg, #15110d 0%, #2a221a 50%, #3a2a14 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.stream-thumb-overlay {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 2;
}
.stream-live-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-family: var(--font-sans);
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  color: #ffffff;
  background: #c0392b;
  padding: 0.25rem 0.55rem;
  border-radius: 0;
}
.stream-live-pill::before {
  content: "";
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #ffffff;
  animation: live-blink 1.6s ease-in-out infinite;
}
@keyframes live-blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.3; }
}
.stream-thumb-svg {
  width: 60%;
  height: 80%;
  display: flex;
  align-items: center;
  justify-content: center;
  filter: drop-shadow(0 4px 16px rgba(212, 168, 58, 0.4));
}
.stream-thumb-svg svg {
  width: 100%;
  height: 100%;
}

.stream-card-thumb-empty {
  background: var(--page-bg-soft);
  color: var(--gold-deep);
  opacity: 0.5;
}

.stream-card-body {
  padding: var(--space-3);
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  flex-grow: 1;
}
.stream-card-name {
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 500;
  color: var(--ink);
  margin: 0;
  letter-spacing: -0.005em;
}
.stream-card-source {
  font-family: var(--font-sans);
  font-size: 0.7rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold-deep);
  margin: 0;
  font-weight: 600;
}
.stream-card-desc {
  font-family: var(--font-sans);
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--ink-soft);
  margin: 0;
  flex-grow: 1;
}
.stream-card-link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-family: var(--font-sans);
  font-size: 0.75rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gold-deep);
  font-weight: 600;
  margin-top: var(--space-2);
  border-bottom: none;
  text-decoration: none;
}
.stream-card:hover .stream-card-link {
  color: var(--ink);
}

/* Placeholder "suggest a stream" card */
.stream-card-placeholder {
  background: var(--page-bg-soft);
  border: 1px dashed rgba(184, 146, 58, 0.4);
}
.stream-card-placeholder .stream-card-name {
  color: var(--ink-soft);
  font-size: 1.15rem;
}
.stream-card-placeholder .stream-card-link {
  color: var(--gold-deep);
  cursor: pointer;
}
.stream-card-placeholder .stream-card-link:hover {
  color: var(--ink);
}

/* Mobile */
@media (max-width: 768px) {
  .streams-featured {
    padding: var(--space-4) var(--space-2);
  }
  .streams-list-section {
    padding: var(--space-5) var(--space-2);
  }
  .streams-grid {
    grid-template-columns: 1fr;
    gap: var(--space-2);
  }
  .stream-card-name { font-size: 1.25rem; }
}


/* ═══════════════════════════════════════════════════════════════════════════
   HOUR COMPANION (pledge form destination picker)
   ═══════════════════════════════════════════════════════════════════════════ */

.companion-block {
  margin-top: var(--space-2);
  padding: var(--space-3);
  background: var(--card-bg);
  border: var(--line-fine);
}

.companion-label {
  font-family: var(--font-sans);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold-deep);
  margin: 0 0 var(--space-2);
}
.companion-optional {
  font-weight: 400;
  letter-spacing: 0.06em;
  text-transform: none;
  font-style: italic;
  color: var(--ink-faint);
}

.companion-tabs {
  display: flex;
  gap: 0;
  margin-bottom: var(--space-2);
  border-bottom: var(--line-fine);
  flex-wrap: wrap;
}
.companion-tab {
  flex: 1 1 auto;
  min-width: 0;
  background: transparent;
  border: none;
  border-bottom: 2px solid transparent;
  padding: 0.55rem 0.75rem;
  font-family: var(--font-sans);
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  color: var(--ink-soft);
  cursor: pointer;
  transition: all 0.15s;
  white-space: nowrap;
}
.companion-tab:hover { color: var(--gold-deep); }
.companion-tab.active {
  color: var(--gold-deep);
  border-bottom-color: var(--gold);
  font-weight: 600;
}

.companion-pane {
  margin-top: var(--space-2);
}
.companion-pane-stream {
  /* matches base pane */
}

/* Chapel autocomplete */
.companion-pane-chapel input {
  width: 100%;
  padding: 0.7rem 0.9rem;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  background: var(--white);
  border: var(--line-fine);
  border-radius: 0;
}
.companion-pane-chapel input:focus {
  outline: none;
  border-color: var(--gold);
  box-shadow: 0 0 0 3px var(--gold-faint);
}
.companion-suggestions {
  margin-top: 4px;
  border: var(--line-fine);
  background: var(--white);
  max-height: 220px;
  overflow-y: auto;
  display: none;
}
.companion-suggestions.visible { display: block; }
.companion-suggestion {
  padding: 0.6rem 0.9rem;
  border-bottom: var(--line-fine);
  cursor: pointer;
  font-size: 0.9rem;
}
.companion-suggestion:last-child { border-bottom: none; }
.companion-suggestion:hover { background: var(--page-bg-soft); }
.companion-suggestion strong { font-family: var(--font-display); font-weight: 500; }
.companion-suggestion small {
  display: block;
  color: var(--ink-faint);
  font-style: italic;
  margin-top: 2px;
}

.companion-selected {
  margin: var(--space-2) 0 0;
  padding: 0.6rem 0.9rem;
  background: var(--gold-faint);
  border-left: 3px solid var(--gold);
  font-family: var(--font-sans);
  font-size: 0.9rem;
  color: var(--ink);
}
.companion-selected[hidden] { display: none; }
.companion-clear {
  float: right;
  background: transparent;
  border: none;
  font-size: 1rem;
  color: var(--ink-faint);
  cursor: pointer;
  padding: 0 4px;
  line-height: 1;
}
.companion-clear:hover { color: var(--gold-deep); }

/* Stream picker */
.companion-stream-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 0.5rem;
  padding: 2px; /* room for selected card's thicker border */
}
.companion-stream-btn {
  background: var(--white);
  border: var(--line-fine);
  padding: 0.7rem 0.85rem;
  text-align: left;
  cursor: pointer;
  transition: all 0.15s;
  border-radius: 0;
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  font-family: var(--font-sans);
  min-height: 60px;
}
.companion-stream-btn:hover {
  border-color: var(--gold);
  background: var(--page-bg-soft);
}
.companion-stream-btn.selected {
  background: var(--gold-faint);
  border-color: var(--gold);
  border-width: 2px;
  padding: calc(0.7rem - 1px) calc(0.85rem - 1px);
}
.companion-stream-name {
  font-family: var(--font-display);
  font-size: 0.98rem;
  font-weight: 500;
  color: var(--ink);
  line-height: 1.2;
}
.companion-stream-source {
  font-size: 0.62rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gold-deep);
}
.companion-stream-more {
  display: block;
  margin-top: 0.75rem;
  padding: 0.4rem 0;
  font-family: var(--font-sans);
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  color: var(--gold-deep);
  text-decoration: none;
  text-align: center;
  border-top: var(--line-fine);
  transition: color 0.15s;
}
.companion-stream-more:hover {
  color: var(--ink);
  text-decoration: underline;
}


/* ═══════════════════════════════════════════════════════════════════════════
   OPEN-NOW FILTER (map toggle)
   ═══════════════════════════════════════════════════════════════════════════ */

.map-filter {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 500;
  background: var(--card-bg);
  border: var(--line-fine);
  padding: 0.5rem 0.75rem;
  font-family: var(--font-sans);
  font-size: 0.8rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  box-shadow: var(--shadow-soft);
  cursor: pointer;
  transition: all 0.15s;
  user-select: none;
}
.map-filter:hover { border-color: var(--gold); }
.map-filter input[type="checkbox"] {
  margin: 0;
  width: 14px; height: 14px;
  accent-color: var(--gold);
  cursor: pointer;
}
.map-filter label {
  cursor: pointer;
  color: var(--ink);
  font-weight: 500;
}
.map-filter .filter-count {
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  color: var(--gold-deep);
  font-weight: 600;
}

/* Open Now badge on chapel popups */
.popup-open-now {
  display: inline-block;
  padding: 0.2rem 0.55rem;
  margin-top: 0.5rem;
  margin-right: 0.4rem;
  background: #2d7d46;
  color: white;
  font-family: var(--font-sans);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}
.popup-open-now::before {
  content: "";
  display: inline-block;
  width: 5px; height: 5px;
  border-radius: 50%;
  background: white;
  margin-right: 5px;
  vertical-align: 2px;
  animation: live-blink 1.6s ease-in-out infinite;
}
.popup-open-unknown {
  display: inline-block;
  padding: 0.2rem 0.55rem;
  margin-top: 0.5rem;
  margin-right: 0.4rem;
  background: var(--page-bg-soft);
  color: var(--ink-faint);
  font-family: var(--font-sans);
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  border: 1px dashed var(--ink-ghost);
}

/* Map section needs relative positioning for the absolute filter */
.map-frame { position: relative; }


/* ═══════════════════════════════════════════════════════════════════════════
   STRUCTURED CHAPEL SUBMISSION FORM
   ═══════════════════════════════════════════════════════════════════════════ */

.form-section-title {
  font-family: var(--font-sans);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold-deep);
  margin: var(--space-3) 0 var(--space-2);
  padding-bottom: 0.4rem;
  border-bottom: 1px solid var(--gold-faint);
}
.form-section-title:first-child { margin-top: 0; }

.form-section-hint {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 0.92rem;
  color: var(--ink-soft);
  margin: 0 0 var(--space-2);
}

.btn-small {
  font-size: 0.7rem;
  padding: 0.5rem 0.85rem;
  letter-spacing: 0.08em;
}

/* Address + mini-map */
.address-actions {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  margin: -0.5rem 0 var(--space-2);
  flex-wrap: wrap;
}
.address-status {
  font-family: var(--font-sans);
  font-size: 0.82rem;
  color: var(--ink-soft);
  font-style: italic;
}
.address-status.error { color: #c0392b; font-style: normal; }
.address-status.success { color: #2d7d46; font-style: normal; }

.address-map-wrap {
  margin: 0 0 var(--space-2);
}
.address-map-hint {
  font-family: var(--font-sans);
  font-size: 0.78rem;
  color: var(--ink-soft);
  font-style: italic;
  margin: 0 0 0.5rem;
}
.address-map {
  width: 100%;
  height: 240px;
  border: var(--line-fine);
  background: var(--page-bg-soft);
}

/* Adoration times list */
.adoration-times-list {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  margin: var(--space-2) 0;
}
.time-slot {
  padding: 0.85rem 1rem;
  background: var(--page-bg-soft);
  border-left: 3px solid var(--gold);
  display: grid;
  /* 5 fields (Freq | From | To | Start | End) + remove button */
  grid-template-columns: 1.1fr 1fr 1fr 1fr 1fr auto;
  gap: 0.5rem;
  align-items: end;
}
/* When Daily is selected, From/To fields are hidden via JS — the grid stays the same;
   the empty columns collapse cleanly because display:none on the field removes them from layout */
.time-slot.is-daily {
  grid-template-columns: 1.3fr 1fr 1fr auto;
}
.time-slot.is-daily .ts-from-field,
.time-slot.is-daily .ts-to-field {
  display: none !important;
}
.time-slot.is-various {
  grid-template-columns: 1fr auto;
}
.time-slot-field {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  min-width: 0;
}
.time-slot-label {
  font-family: var(--font-sans);
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  color: var(--gold-deep);
  text-transform: uppercase;
}
.time-slot select {
  width: 100%;
  padding: 0.55rem 0.6rem;
  font-family: var(--font-sans);
  font-size: 0.9rem;
  background: var(--card-bg);
  border: var(--line-fine);
  border-radius: 0;
  color: var(--ink);
  margin: 0;
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='10' height='6'><path d='M0 0 L5 6 L10 0 Z' fill='%237a5f1f'/></svg>");
  background-repeat: no-repeat;
  background-position: right 8px center;
  padding-right: 24px;
}
.time-slot input[type="time"] {
  width: 100%;
  padding: 0.55rem 0.6rem;
  font-family: var(--font-sans);
  font-size: 0.9rem;
  background: var(--card-bg);
  border: var(--line-fine);
  border-radius: 0;
  color: var(--ink);
  margin: 0;
  /* Let native time picker show; just style the container */
}
.time-slot input[type="time"]::-webkit-calendar-picker-indicator {
  filter: invert(50%) sepia(60%) saturate(400%) hue-rotate(15deg) brightness(70%);
  cursor: pointer;
}
.time-slot select:focus,
.time-slot input[type="time"]:focus {
  outline: none;
  border-color: var(--gold);
  box-shadow: 0 0 0 2px var(--gold-faint);
}
.time-slot-checkbox {
  font-family: var(--font-sans);
  font-size: 0.78rem;
  color: var(--ink);
  display: flex;
  align-items: center;
  gap: 0.4rem;
  white-space: nowrap;
}
.time-slot-remove {
  background: transparent;
  border: 1px solid var(--ink-ghost);
  color: var(--ink-faint);
  font-size: 1.1rem;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  padding: 0;
  border-radius: 0;
  transition: all 0.15s;
  align-self: end;
}
.time-slot-remove:hover {
  border-color: #c0392b;
  color: #c0392b;
}

.btn-add-slot {
  align-self: flex-start;
  margin-bottom: var(--space-3);
}

@media (max-width: 640px) {
  .time-slot {
    grid-template-columns: 1fr 1fr;
    gap: 0.6rem;
  }
  .time-slot.is-daily {
    grid-template-columns: 1fr 1fr;
  }
  .time-slot.is-various {
    grid-template-columns: 1fr auto;
  }
  /* Frequency takes full width on mobile; other fields paired */
  .time-slot .ts-freq-field {
    grid-column: 1 / -1;
  }
  .time-slot-remove {
    grid-column: 2;
    justify-self: end;
  }
}


/* ═══════════════════════════════════════════════════════════════════════════
   POPUP additions for structured adoration_times + code-required + closed-now
   ═══════════════════════════════════════════════════════════════════════════ */

.popup-times {
  margin-top: 0.5rem;
  font-family: var(--font-sans);
  font-size: 0.85rem;
  color: var(--ink);
  line-height: 1.5;
}
.popup-times div {
  display: block;
}
.popup-times em {
  font-style: italic;
  color: var(--ink-soft);
}

.popup-open-closed {
  display: inline-block;
  padding: 0.2rem 0.55rem;
  margin-top: 0.5rem;
  margin-right: 0.4rem;
  background: var(--page-bg-soft);
  color: var(--ink-faint);
  font-family: var(--font-sans);
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.popup-code-required {
  margin-top: 0.6rem;
  padding: 0.5rem 0.7rem;
  background: var(--gold-faint);
  border-left: 3px solid var(--gold);
  font-family: var(--font-sans);
  font-size: 0.82rem;
  font-style: italic;
  color: var(--ink);
}

.popup-notes {
  margin-top: 0.5rem;
  padding: 0.5rem 0.7rem;
  background: var(--page-bg-soft);
  border-left: 3px solid var(--ink-ghost);
  font-family: var(--font-sans);
  font-size: 0.85rem;
  color: var(--ink);
  line-height: 1.5;
}
.popup-notes strong {
  font-family: var(--font-sans);
  font-size: 0.62rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold-deep);
  margin-right: 0.4rem;
}


/* ═══════════════════════════════════════════════════════════════════════════
   FLOATING MUSIC BUTTON
   ──────────────────────────────────────────────────────────────────────────
   Positioned bottom-left so it doesn't collide with the live video mini-player
   (which floats bottom-right). Discreet but always reachable.
   ═══════════════════════════════════════════════════════════════════════════ */
.music-floating-btn {
  position: fixed;
  bottom: 24px;
  left: 24px;
  z-index: 99998;  /* just below the mini-player so the video wins if they ever overlap */
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.65rem 1rem 0.65rem 0.8rem;
  font-family: var(--font-sans);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink);
  background: rgba(255, 250, 235, 0.96);
  border: 1px solid rgba(184, 146, 58, 0.5);
  border-radius: 999px;
  box-shadow:
    0 8px 20px rgba(0, 0, 0, 0.18),
    0 2px 6px rgba(0, 0, 0, 0.12);
  cursor: pointer;
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

.music-floating-btn:hover {
  transform: translateY(-1px);
  background: rgba(255, 248, 225, 1);
  box-shadow:
    0 12px 28px rgba(0, 0, 0, 0.22),
    0 4px 8px rgba(0, 0, 0, 0.14);
}

.music-floating-btn:active {
  transform: translateY(0);
}

.music-floating-btn .music-icon {
  display: block;
  color: var(--gold-deep);
  flex-shrink: 0;
}

/* Default (paused): show play icon, hide pause icon */
.music-floating-btn .music-icon-play  { display: block; }
.music-floating-btn .music-icon-pause { display: none; }

/* When playing, flip the icons */
.music-floating-btn.is-playing .music-icon-play  { display: none; }
.music-floating-btn.is-playing .music-icon-pause { display: block; }

/* Subtle pulse animation when actively playing — never harsh, just a heartbeat */
.music-floating-btn.is-playing {
  background: rgba(255, 248, 225, 1);
  border-color: var(--gold);
  box-shadow:
    0 0 0 4px rgba(212, 168, 58, 0.15),
    0 8px 20px rgba(0, 0, 0, 0.18);
}
.music-floating-btn.is-playing .music-icon {
  animation: music-pulse 2.4s ease-in-out infinite;
}
@keyframes music-pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%      { opacity: 0.6; transform: scale(0.9); }
}

/* Mobile: smaller, still left side */
@media (max-width: 640px) {
  .music-floating-btn {
    bottom: 16px;
    left: 12px;
    padding: 0.55rem 0.85rem 0.55rem 0.7rem;
    font-size: 0.7rem;
  }
  .music-floating-btn .music-label {
    /* Keep label visible but smaller */
    letter-spacing: 0.1em;
  }
  .music-floating-btn .music-icon {
    width: 16px;
    height: 16px;
  }
}


/* Reset View button — sits next to the Open Now filter on the map */
.map-reset-btn {
  position: absolute;
  top: 12px;
  /* Position right below the open-now filter on mobile, beside it on desktop */
  left: 12px;
  margin-top: 48px;
  z-index: 500;
  background: var(--card-bg);
  border: var(--line-fine);
  padding: 0.5rem 0.75rem;
  font-family: var(--font-sans);
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--ink);
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  box-shadow: var(--shadow-soft);
  cursor: pointer;
  transition: all 0.15s;
  user-select: none;
  letter-spacing: 0.02em;
}
.map-reset-btn:hover {
  border-color: var(--gold);
  color: var(--gold-deep);
}
.map-reset-btn svg {
  color: var(--gold-deep);
  flex-shrink: 0;
}

@media (max-width: 640px) {
  .map-reset-btn {
    font-size: 0.72rem;
    padding: 0.45rem 0.65rem;
  }
}


/* ═══════════════════════════════════════════════════════════════════════════
   STREAM CARD WRAPPER + REPORT BROKEN LINK
   ──────────────────────────────────────────────────────────────────────────
   Cards now sit inside a wrap so the small "Report broken" link can be a
   sibling rather than nested inside the card's anchor (which would be invalid HTML).
   ═══════════════════════════════════════════════════════════════════════════ */
.stream-card-wrap {
  position: relative;
  display: flex;
  flex-direction: column;
}
.stream-card-wrap .stream-card {
  flex: 1;
}
.stream-card-report {
  display: inline-block;
  margin-top: 0.25rem;
  padding: 0.25rem 0.6rem;
  font-family: var(--font-sans);
  font-size: 0.65rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-faint);
  text-decoration: none;
  text-align: center;
  border: 1px dashed transparent;
  border-radius: 3px;
  transition: color 0.15s, border-color 0.15s, background 0.15s;
  align-self: center;
}
.stream-card-report:hover {
  color: var(--gold-deep);
  border-color: var(--ink-ghost);
  background: var(--page-bg-soft);
}


/* ═══════════════════════════════════════════════════════════════════════════
   MOBILE UX FIX — map controls and legend must NEVER bleed into the header
   ──────────────────────────────────────────────────────────────────────────
   The sticky header needs to win the z-index war over Leaflet's controls,
   especially when scrolling on mobile where everything gets visually
   compressed and the map can be partially visible behind the header.
   ═══════════════════════════════════════════════════════════════════════════ */

/* Header always wins over any map element */
.header-v2 {
  z-index: 1000 !important;
  /* Slightly opaque background so map underneath doesn't bleed through during scroll */
  background: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}

/* Cap all Leaflet controls below the header */
.leaflet-control-container,
.leaflet-top,
.leaflet-bottom,
.leaflet-control-zoom,
.leaflet-control-attribution {
  z-index: 400 !important;
}

/* Our custom map overlays (filter, reset button) — same cap */
.map-filter,
.map-reset-btn {
  z-index: 400 !important;
}

/* The legend ("CHAPELS · Adoration Chapel") was positioned bottom-right by default
   but on mobile it can creep up into the search area during weird scrolls.
   Force it to stay bottom-right within the map. */
.leaflet-control-legend,
.map-legend {
  z-index: 400 !important;
}

/* Make sure the map frame itself doesn't escape its container */
.map-frame {
  position: relative;
  overflow: hidden;
}

/* Mobile: stack the map filter and reset button vertically on the LEFT side,
   away from the top-right where users tap for zoom. Add more top margin
   so they don't sit immediately below the sticky header */
@media (max-width: 640px) {
  .map-filter {
    top: 8px;
    left: 8px;
    font-size: 0.72rem;
    padding: 0.4rem 0.55rem;
  }
  .map-reset-btn {
    top: 8px;
    margin-top: 42px; /* below the filter */
    left: 8px;
    font-size: 0.7rem;
    padding: 0.35rem 0.5rem;
  }
  /* Hide the legend on very small screens — it's noise */
  .leaflet-control-legend,
  .map-legend {
    display: none !important;
  }
}


/* ═══════════════════════════════════════════════════════════════════════════
   HEADER TAGLINE — small italic line under the logo, every page
   Tells first-time visitors what the site is about without preaching.
   ═══════════════════════════════════════════════════════════════════════════ */
.site-tagline {
  display: block;
  margin-top: 0.35rem;
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 0.82rem;
  color: var(--gold-deep);
  letter-spacing: 0.02em;
  text-align: center;
  /* Use small caps spacing for subtle elegance, but keep normal case readable */
}
@media (max-width: 640px) {
  .site-tagline {
    font-size: 0.72rem;
    margin-top: 0.25rem;
  }
}

/* ═══════════════════════════════════════════════════════════════════════════
   HERO EXPLAINER — catechetical sentence between title and verse
   For first-time visitors who don't yet know what Eucharistic Adoration is.
   ═══════════════════════════════════════════════════════════════════════════ */
.hero-explainer {
  max-width: 640px;
  margin: 1.5rem auto 1.25rem;
  font-family: var(--font-sans);
  font-size: 1rem;
  font-weight: 400;
  line-height: 1.6;
  color: var(--cream);
  text-align: center;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.45);
  letter-spacing: 0.01em;
  /* Slightly muted vs the headline so it reads as supporting copy */
  opacity: 0.96;
}

@media (max-width: 640px) {
  .hero-explainer {
    font-size: 0.88rem;
    margin: 1.1rem auto 1rem;
    padding: 0 0.5rem;
    line-height: 1.55;
  }
}
