/* =========================================================================
   Church of Our Lady of Sorrows — Ká-Hó, Coloane (Macau)
   Production stylesheet. Faithful to the design prototype tokens.
   ========================================================================= */

:root {
  --burgundy: #6b1f2a;
  --burgundy-deep: #3d0f16;
  --burgundy-mid: #4c141c;
  --gold: #c2a14d;
  --gold-light: #e3cf94;
  --cream-bg: #faf6ef;
  --cream-alt: #f7f1e7;
  --panel: #f1ece3;
  --panel-alt: #f3ecdf;
  --border: #e4dccd;
  --text: #2b2b2b;

  --display: 'Cormorant Garamond', 'Noto Serif SC', serif;
  --body: 'EB Garamond', 'Noto Serif SC', Georgia, serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
[hidden] { display: none !important; }

/* ---------- Background music control ---------- */
.music-toggle {
  position: fixed; right: 18px; bottom: 18px; z-index: 90;
  width: 52px; height: 52px; border-radius: 50%; border: none; cursor: pointer;
  background: var(--burgundy); color: var(--gold-light);
  box-shadow: 0 4px 16px rgba(0,0,0,.28);
  display: flex; align-items: center; justify-content: center;
  transition: transform .15s, background .15s;
}
.music-toggle:hover { transform: scale(1.06); background: var(--burgundy-mid); }
.music-toggle:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }
.music-toggle__icon { font-size: 22px; line-height: 1; }
.music-toggle.is-playing .music-toggle__icon { display: none; }
.music-toggle__bars { display: none; gap: 3px; align-items: flex-end; height: 20px; }
.music-toggle.is-playing .music-toggle__bars { display: flex; }
.music-toggle__bars i {
  width: 3px; background: var(--gold-light); border-radius: 2px;
  transform-origin: bottom; animation: eq .9s ease-in-out infinite;
}
.music-toggle__bars i:nth-child(1) { height: 9px;  animation-delay: 0s; }
.music-toggle__bars i:nth-child(2) { height: 18px; animation-delay: .2s; }
.music-toggle__bars i:nth-child(3) { height: 13px; animation-delay: .4s; }
@keyframes eq { 0%, 100% { transform: scaleY(.4); } 50% { transform: scaleY(1); } }

/* ---------- Under-construction screen (Chinese) ---------- */
.uc {
  min-height: calc(100vh - 40px);
  display: flex; align-items: center; justify-content: center;
  text-align: center; color: #fff; padding: 60px 24px;
  background-image:
    linear-gradient(rgba(61,15,22,.86), rgba(76,20,28,.8) 45%, rgba(61,15,22,.92)),
    url('../images/book-cover.jpg');
  background-size: cover; background-position: center 38%;
}
.uc__inner { max-width: 640px; }
.uc__cross { font-size: 40px; color: var(--gold-light); margin-bottom: 18px; line-height: 1; }
.uc__place {
  letter-spacing: 5px; text-transform: uppercase; font-size: 12px;
  color: var(--gold-light); margin-bottom: 18px;
}
.uc__title {
  font-family: var(--display); font-weight: 500; font-size: 46px; line-height: 1.15;
  text-shadow: 0 2px 14px rgba(0,0,0,.45);
}
.uc__rule { width: 64px; height: 2px; background: var(--gold); margin: 26px auto; }
.uc__heading {
  font-family: var(--display); font-style: italic; font-size: 26px;
  color: #f0e3c2; margin-bottom: 16px;
}
.uc__text { font-size: 17px; line-height: 1.85; color: #efe6d2; }
.uc__langs { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; margin-top: 28px; }
.uc__btn {
  font-family: var(--body); font-size: 17px; font-weight: 600; cursor: pointer;
  padding: 12px 26px; min-height: 48px; border-radius: 999px;
  background: var(--gold-light); color: var(--burgundy-deep); border: 1px solid var(--gold-light);
  transition: background .15s, color .15s;
}
.uc__btn--alt { background: transparent; color: var(--gold-light); }
.uc__btn:hover { background: #fff; border-color: #fff; color: var(--burgundy-deep); }
html { scroll-behavior: smooth; }
body {
  background: var(--cream-bg);
  color: var(--text);
  font-family: var(--body);
  line-height: 1.75;
  font-size: 18px;
  overflow-wrap: break-word;   /* long words/URLs never force sideways scroll */
}
::selection { background: var(--gold); color: #fff; }

img { max-width: 100%; }
a { color: inherit; }

/* Accessible focus styles (prototype had none) */
a:focus-visible,
button:focus-visible,
[tabindex]:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 2px;
  border-radius: 3px;
}

/* Visually hidden, still read by screen readers */
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* ---------- Language switch (sticky menu) ---------- */
.globe { flex: none; }
.lang-switch { display: flex; gap: 6px; }
.lang-switch button {
  font-family: var(--body); cursor: pointer; white-space: nowrap;
  background: transparent; color: var(--gold-light);
  border: 1px solid rgba(227,207,148,.55); border-radius: 999px;
  transition: background .15s, color .15s, border-color .15s;
}
.lang-switch button:hover { border-color: #fff; color: #fff; }
.lang-switch button[aria-pressed="true"] {
  background: var(--gold-light); border-color: var(--gold-light);
  color: var(--burgundy-deep); font-weight: 700;
}
.lang-switch--compact { gap: 4px; }
.lang-switch--compact button {
  font-size: 12px; letter-spacing: .6px; padding: 4px 9px; min-height: 30px; min-width: 38px;
}

/* ---------- Header / hero ---------- */
.hero {
  position: relative;
  color: #fff;
  text-align: center;
  padding: clamp(64px, 12vw, 120px) clamp(18px, 5vw, 24px) clamp(52px, 10vw, 100px);
  background-image:
    linear-gradient(rgba(61,15,22,.72), rgba(76,20,28,.64) 45%, rgba(61,15,22,.86)),
    url('../images/hero.jpg');
  background-size: cover;
  background-position: center 38%;
  overflow: hidden;
}
.hero__cross { font-size: 34px; color: var(--gold-light); margin-bottom: 20px; line-height: 1; }
.hero__place {
  letter-spacing: 5px; text-transform: uppercase;
  font-size: 12px; color: var(--gold-light); margin-bottom: 18px;
}
.hero__title {
  font-family: var(--display); font-weight: 500;
  font-size: clamp(30px, 7vw, 58px); line-height: 1.12; letter-spacing: .5px;
  max-width: 820px; margin: 0 auto;
  text-shadow: 0 2px 14px rgba(0,0,0,.45);
}
.hero__rule { width: 64px; height: 2px; background: var(--gold); margin: 28px auto; }
.hero__quote {
  font-family: var(--display); font-style: italic; font-size: clamp(18px, 4.2vw, 24px);
  color: #f0e3c2; text-shadow: 0 2px 10px rgba(0,0,0,.4);
}
.hero__years { font-size: 15px; color: #e7d6ad; margin-top: 8px; letter-spacing: 1px; }

/* ---------- Nav (sticky) ---------- */
/* Computers: the whole menu on one line, with PT · EN · 中文 on the right.
   Phones & tablets (below 1024 px): a "☰ Menu" drop-down and a "🌐 English ▾"
   language drop-down (see the max-width: 1023px block below). */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: var(--burgundy);
  box-shadow: 0 2px 10px rgba(0,0,0,.2);
}
/* menu links land just below the sticky bar, not hidden under it */
section[id], header[id] { scroll-margin-top: 58px; }
/* [ menu (scrolls sideways if needed) ][ PT · EN · 中文 (always visible) ] */
.nav__inner { display: flex; align-items: center; position: relative; }
.nav__toggle, .nav__langtoggle { display: none; }
.lang-switch .l-full { display: none; }
.nav__scroll {
  flex: 1 1 auto; min-width: 0;
  overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch;
}
.nav__scroll::-webkit-scrollbar { display: none; }
/* soft fade on the right edge hints that the menu scrolls when it doesn't fit */
.nav__scroll {
  -webkit-mask-image: linear-gradient(to right, #000 calc(100% - 22px), transparent);
          mask-image: linear-gradient(to right, #000 calc(100% - 22px), transparent);
}
.nav__lang {
  flex: none; display: flex; align-items: center; gap: 6px;
  padding: 0 12px 0 10px; color: var(--gold-light);
  border-left: 1px solid rgba(255,255,255,.14);
}
.nav ul {
  list-style: none; display: flex; flex-wrap: nowrap;
  width: max-content; margin: 0 auto;   /* centred when it fits */
}
.nav a {
  display: block; color: #f6ecd8; white-space: nowrap;
  padding: 15px clamp(8px, 0.95vw, 16px); font-size: 13px;
  text-transform: uppercase; letter-spacing: clamp(.4px, .08vw, 1.2px);
  text-decoration: none; transition: background .15s;
}
.nav a:hover { background: var(--burgundy-mid); color: #fff; }
/* Mid-size screens: tighter menu so it still fits on one line next to the language switch */
@media (max-width: 1320px) {
  .nav a { font-size: 12.5px; letter-spacing: .3px; padding-left: 7px; padding-right: 7px; }
  .nav__lang > .globe { display: none; }
}
@media (max-width: 1100px) {
  .nav a { padding-left: 6px; padding-right: 6px; letter-spacing: .2px; }
}

/* Phones & tablets: two drop-downs, big rows that are easy to tap */
@media (max-width: 1023px) {
  .nav__inner { justify-content: space-between; }
  .nav__toggle, .nav__langtoggle {
    display: inline-flex; align-items: center; gap: 10px; min-height: 52px; padding: 0 18px;
    background: none; border: 0; cursor: pointer; color: #f6ecd8;
    font-family: var(--body); font-size: 14px; font-weight: 600; letter-spacing: 1.2px; text-transform: uppercase;
  }
  .nav__langtoggle { gap: 8px; padding: 0 16px; font-size: 15px; letter-spacing: .3px; text-transform: none; }
  .nav__toggle:hover, .nav__langtoggle:hover,
  .nav.is-open .nav__toggle, .nav__lang.is-open .nav__langtoggle { background: var(--burgundy-mid); }
  /* ☰ that turns into ✕ when open */
  .nav__burger { position: relative; width: 20px; height: 14px; flex: none; }
  .nav__burger span {
    position: absolute; left: 0; right: 0; height: 2px; border-radius: 2px; background: currentColor;
    transition: transform .2s, opacity .2s, top .2s;
  }
  .nav__burger span:nth-child(1) { top: 0; }
  .nav__burger span:nth-child(2) { top: 6px; }
  .nav__burger span:nth-child(3) { top: 12px; }
  .nav.is-open .nav__burger span:nth-child(1) { top: 6px; transform: rotate(45deg); }
  .nav.is-open .nav__burger span:nth-child(2) { opacity: 0; }
  .nav.is-open .nav__burger span:nth-child(3) { top: 6px; transform: rotate(-45deg); }
  .nav__caret {
    width: 7px; height: 7px; margin-left: 2px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor;
    transform: translateY(-2px) rotate(45deg); transition: transform .2s;
  }
  .nav__lang.is-open .nav__caret { transform: translateY(2px) rotate(-135deg); }

  /* the sections */
  .nav__scroll {
    display: none; position: absolute; top: 100%; left: 0; right: 0;
    -webkit-mask-image: none; mask-image: none;
    max-height: calc(100vh - 52px); max-height: calc(100dvh - 52px); overflow-y: auto; overscroll-behavior: contain;
    background: var(--burgundy-deep); border-top: 1px solid rgba(255,255,255,.12);
    box-shadow: 0 16px 30px rgba(0,0,0,.35);
  }
  .nav.is-open .nav__scroll { display: block; }
  .nav ul { display: grid; grid-template-columns: 1fr; width: auto; padding: 6px 0 10px; }
  .nav a { padding: 15px 24px; font-size: 14px; letter-spacing: 1.2px; border-bottom: 1px solid rgba(255,255,255,.07); }

  /* the languages */
  .nav__lang { border-left: 0; padding: 0; }
  .nav__lang > .globe { display: none; }
  .nav__lang .lang-switch {
    display: none; position: absolute; top: calc(100% + 6px); right: 8px; z-index: 2; min-width: 210px;
    flex-direction: column; gap: 2px; padding: 6px;
    background: #fff; border-radius: 10px; box-shadow: 0 16px 34px rgba(0,0,0,.32);
  }
  .nav__lang.is-open .lang-switch { display: flex; }
  .nav__lang .lang-switch button {
    display: flex; align-items: center; justify-content: space-between; min-height: 48px; padding: 0 14px;
    border: 0; border-radius: 7px; background: none; color: var(--burgundy-deep);
    font-size: 17px; letter-spacing: .2px; text-align: left;
  }
  .nav__lang .lang-switch button:hover { background: var(--cream-alt); color: var(--burgundy-deep); }
  .nav__lang .lang-switch button[aria-pressed="true"] { background: var(--panel-alt); color: var(--burgundy); }
  .nav__lang .lang-switch button[aria-pressed="true"]::after { content: '✓'; color: var(--gold); font-weight: 700; }
  .lang-switch .l-short { display: none; }
  .lang-switch .l-full { display: inline; }
}
/* tablets: the sections in two columns */
@media (min-width: 600px) and (max-width: 1023px) {
  .nav ul { grid-template-columns: 1fr 1fr; column-gap: 12px; padding: 8px 14px 14px; }
}

/* ---------- Section scaffolding ---------- */
section { border-bottom: 1px solid var(--border); }
.section-inner { margin: 0 auto; padding: clamp(52px, 8vw, 80px) clamp(18px, 5vw, 24px); }
.w-760 { max-width: 760px; }
.w-820 { max-width: 820px; }
.w-920 { max-width: 920px; }
.w-1040 { max-width: 1040px; }
.bg-alt { background: var(--cream-alt); }

.sec-head { text-align: center; margin-bottom: 36px; }
.sec-head h2 {
  font-family: var(--display); font-weight: 500;
  font-size: clamp(28px, 5vw, 40px); color: var(--burgundy);
}
.sec-head .rule,
.rule-c { width: 64px; height: 3px; background: var(--gold); margin: 14px auto 0; }

/* ---------- Introdução ---------- */
.intro__welcome {
  font-family: var(--display); font-style: italic; font-size: 26px;
  text-align: center; color: var(--burgundy-mid); margin-bottom: 32px;
}
.intro p.para { margin-bottom: 20px; text-align: justify; }
.intro__thanks {
  text-align: center; font-family: var(--display); font-style: italic;
  font-size: 24px; color: var(--burgundy); margin-top: 8px;
}
strong { color: var(--burgundy); }

/* ---------- História: book + QR ---------- */
.book-card {
  display: flex; flex-wrap: wrap; gap: 36px; align-items: center;
  background: var(--panel); border: 1px solid var(--border);
  border-radius: 10px; padding: 36px; margin-bottom: 48px;
}
.book-card__qr { flex: 0 0 190px; text-align: center; margin: 0 auto; }
.book-card__qr img {
  width: 170px; height: 170px; display: block;
  border: 8px solid #fff; box-shadow: 0 4px 16px rgba(0,0,0,.12); margin: 0 auto;
}
.book-card__qr small { display: block; margin-top: 12px; font-size: 13px; color: #777; }
.book-card__qr .sel {
  margin-top: 4px; font-family: var(--display); font-size: 18px; color: var(--burgundy);
}
.book-card__body { flex: 1; min-width: min(280px, 100%); }
.book-card__body h3 {
  font-family: var(--display); font-weight: 600; color: var(--burgundy);
  font-size: 28px; line-height: 1.2; margin-bottom: 14px;
}
.book-card__body .desc { margin-bottom: 18px; }
.book-card__body .avail { font-size: 14px; color: #8a7d68; margin-bottom: 12px; }
.book-pills, .gal-tabs { display: flex; flex-wrap: wrap; gap: 10px; }
.book-pills button, .gal-tabs button {
  font-family: var(--body);
  background: #fff; border: 1px solid #d8c483; color: var(--burgundy-mid);
  font-size: 14px; padding: 8px 16px; border-radius: 20px;
  cursor: pointer; font-weight: 400; transition: all .15s;
  min-height: 40px;
}
.book-pills button:hover, .gal-tabs button:hover { border-color: var(--burgundy); }
.book-pills button[aria-pressed="true"], .gal-tabs button[aria-pressed="true"] {
  background: var(--burgundy); border-color: var(--burgundy);
  color: #fff; font-weight: 600;
}
.book-more { font-size: 13px; color: #9a8e78; margin-top: 14px; }
/* Direct "open the book" link (a QR code can't be scanned on the same phone) */
.book-open {
  display: inline-block; margin-top: 16px; padding: 10px 20px; min-height: 44px;
  background: var(--burgundy); color: #fff; border-radius: 22px;
  font-size: 15px; font-weight: 500; text-decoration: none; letter-spacing: .3px;
  transition: background .15s;
}
.book-open:hover { background: var(--burgundy-mid); }

/* ---------- Bíblia: PowerPoint slide viewer ---------- */
.deck { position: relative; max-width: 880px; margin: 0 auto; outline: none; }
.deck:focus-visible .deck__stage { outline: 3px solid var(--gold); outline-offset: 3px; }
.deck__stage {
  position: relative; aspect-ratio: 16 / 9; background: #13203a;
  border-radius: 10px; overflow: hidden; box-shadow: 0 6px 22px rgba(75,20,28,.16);
  /* the page can still scroll up/down over the slide; pinching zooms the slide, and
     sideways swipes do nothing (only the arrows change slides) */
  touch-action: pan-y; user-select: none; -webkit-user-select: none;
}
.deck__stage.is-zoomed { touch-action: none; cursor: grab; }
.deck__stage.is-dragging { cursor: grabbing; }
.deck__img {
  width: 100%; height: 100%; object-fit: contain; display: block;
  transform-origin: 0 0; transition: transform .18s ease-out; -webkit-user-drag: none;
}
.deck__stage.is-touching .deck__img { transition: none; }   /* follow fingers / mouse exactly */
.deck__nav, .deck__close {
  position: absolute; z-index: 2; width: 44px; height: 44px; border-radius: 50%;
  border: none; cursor: pointer; background: rgba(255,255,255,.88); color: var(--burgundy);
  font-size: 28px; line-height: 1; box-shadow: 0 2px 10px rgba(0,0,0,.3);
  display: flex; align-items: center; justify-content: center; padding-bottom: 4px;
}
.deck__nav { top: 50%; transform: translateY(-50%); }
.deck__nav--prev { left: 10px; }
.deck__nav--next { right: 10px; }
.deck__nav:disabled { opacity: .25; cursor: default; }
.deck__close { display: none; top: 12px; right: 12px; font-size: 18px; padding-bottom: 0; }
.deck__bar { display: flex; align-items: center; gap: 14px; margin-top: 12px; }
.deck__count {
  min-width: 64px; text-align: left; font-size: 14px; font-weight: 600;
  color: var(--burgundy); font-variant-numeric: tabular-nums;
}
/* drag to move through the slides quickly */
.deck__range { flex: 1; min-width: 0; height: 32px; margin: 0; accent-color: var(--burgundy); cursor: pointer; }
.deck__zoom { display: flex; justify-content: center; align-items: center; gap: 6px; }
.deck__zbtn, .deck__zlevel {
  font-family: var(--body); min-height: 38px; border-radius: 19px; border: 1px solid #d8c483;
  background: #fff; color: var(--burgundy-mid); cursor: pointer;
}
.deck__zbtn { width: 42px; font-size: 22px; line-height: 1; padding: 0 0 2px; }
.deck__zlevel { min-width: 64px; padding: 0 10px; font-size: 14px; font-variant-numeric: tabular-nums; }
.deck__zbtn:disabled { opacity: .4; cursor: default; }
.deck__zbtn:hover:not(:disabled), .deck__zlevel:hover { border-color: var(--burgundy); }
.deck__full {
  font-family: var(--body); font-size: 14px; padding: 6px 16px; min-height: 38px;
  border-radius: 19px; border: 1px solid #d8c483; background: #fff;
  color: var(--burgundy-mid); cursor: pointer; white-space: nowrap;
}
.deck__full:hover { border-color: var(--burgundy); }
/* Full screen as an overlay (the browser Fullscreen API doesn't work on iPhone) */
.deck.is-full {
  position: fixed; inset: 0; z-index: 200; max-width: none; margin: 0;
  background: #000; display: flex; flex-direction: column; padding: 10px 10px 14px;
}
.deck.is-full .deck__stage {
  flex: 1; min-height: 0; aspect-ratio: auto; border-radius: 0; box-shadow: none; background: #000;
}
.deck.is-full .deck__close { display: flex; }
.deck.is-full .deck__count { color: #fff; }

/* ---------- Timeline ---------- */
.cron-title {
  font-family: var(--display); font-weight: 500; font-size: 26px;
  color: var(--burgundy); text-align: center; margin-bottom: 28px;
}
.timeline { border-left: 3px solid var(--gold); margin-left: 8px; }
.timeline__item { position: relative; padding: 0 0 28px 28px; }
.timeline__dot {
  position: absolute; left: -9px; top: 4px; width: 15px; height: 15px;
  border-radius: 50%; background: var(--burgundy);
  border: 3px solid var(--cream-bg); box-shadow: 0 0 0 2px var(--gold);
}
.timeline__year {
  font-family: var(--display); font-weight: 600; color: var(--burgundy);
  font-size: 22px; line-height: 1; margin-bottom: 6px;
}
.timeline__text { color: #3a3a3a; }

/* ---------- Missas ---------- */
.mass-card {
  display: inline-flex; flex-direction: column; align-items: center;
  background: #fff; border: 1px solid var(--border); border-radius: 10px;
  padding: 32px 48px; box-shadow: 0 3px 12px rgba(75,20,28,.06);
}
.mass-card__day { font-family: var(--display); font-size: 30px; color: var(--burgundy); }
.mass-card__time {
  font-family: var(--display); font-size: 52px; font-weight: 600;
  color: var(--burgundy-mid); line-height: 1.1; margin: 4px 0;
}
.mass-card__lang {
  font-size: 15px; letter-spacing: 1px; text-transform: uppercase; color: #9a7f3c;
}
.mass-note { margin-top: 26px; color: #4a443a; }

/* ---------- Oração a Nossa Senhora das Dores ---------- */
/* A burgundy devotional band holding a cream "holy card". */
.prayer {
  background-image:
    repeating-linear-gradient(45deg, rgba(255,255,255,.035) 0 12px, transparent 12px 24px),
    linear-gradient(150deg, var(--burgundy) 0%, var(--burgundy-deep) 100%);
  border-bottom: none;
}
.prayer .sec-head { margin-bottom: 32px; }
.prayer .sec-head h2 { color: #fff; text-shadow: 0 2px 12px rgba(0,0,0,.3); }
.prayer__cross { font-size: 30px; line-height: 1; color: var(--gold-light); margin-bottom: 14px; }
.prayer-card {
  background: var(--cream-bg); border-radius: 10px;
  padding: 48px 52px 44px;
  /* double gold frame, like a devotional prayer card */
  border: 1px solid var(--gold);
  box-shadow: inset 0 0 0 7px var(--cream-bg), inset 0 0 0 8px rgba(194,161,77,.55),
              0 12px 36px rgba(0,0,0,.28);
}
.prayer-card__para {
  font-size: 19px; line-height: 1.85; color: #3a2a2c;
  text-align: justify; margin-bottom: 20px;
}
.prayer-card__amen {
  font-family: var(--display); font-style: italic; font-size: 24px;
  color: var(--burgundy); text-align: center;
}
.prayer-card__rule { width: 48px; height: 2px; background: var(--gold); margin: 26px auto; }
.prayer-card__rubric {
  text-align: center; font-style: italic; font-size: 16px;
  letter-spacing: .5px; color: #83682b; margin-bottom: 12px;
}
.prayer-card__vocal {
  list-style: none; text-align: center; margin-bottom: 26px;
  font-family: var(--display); font-style: italic; font-weight: 600;
  font-size: 22px; line-height: 1.6; color: var(--burgundy-mid);
}
.prayer-card__invocation {
  text-align: center; font-family: var(--display); font-weight: 600;
  font-size: clamp(22px, 4.4vw, 28px); line-height: 1.3; color: var(--burgundy);
}

/* ---------- Coro (video placeholder) ---------- */
.choir-para { max-width: 680px; margin: 0 auto 32px; text-align: center; }
/* Choir video not available yet: an elegant "Video coming soon" label between
   two fading gold lines (double gold edge as on the prayer card) */
.choir-soon {
  display: flex; align-items: center; justify-content: center; gap: 18px;
  max-width: 600px; margin: 0 auto;
}
.choir-soon__line { flex: 1; min-width: 0; height: 1px; background: linear-gradient(to right, transparent, var(--gold)); }
.choir-soon__line:last-child { background: linear-gradient(to left, transparent, var(--gold)); }
.choir-soon__badge {
  display: inline-flex; align-items: center; gap: 12px; flex: none; margin: 0;
  padding: 10px 26px 10px 11px; border: 1px solid var(--gold); border-radius: 999px;
  background: #fff; color: var(--burgundy);
  font-family: var(--display); font-style: italic; font-weight: 500; font-size: 23px;
  letter-spacing: .3px; white-space: nowrap;
  box-shadow: inset 0 0 0 3px #fff, inset 0 0 0 4px rgba(194,161,77,.4), 0 6px 18px rgba(75,20,28,.10);
}
.choir-soon__icon {
  width: 36px; height: 36px; border-radius: 50%; flex: none;
  display: grid; place-items: center; padding-left: 2px;
  background: var(--burgundy); color: var(--gold-light);
}
@media (max-width: 400px) {
  .choir-soon { gap: 10px; }
  .choir-soon__badge { font-size: 19px; padding-right: 20px; }
}
.mono { font-family: ui-monospace, monospace; font-size: 12px; letter-spacing: 1.5px; }

/* ---------- Stub note cards ---------- */
.note-card {
  display: inline-block; background: #fff; border: 1px dashed var(--gold);
  border-radius: 10px; padding: 28px 40px; color: #9a7f3c; font-style: italic;
}

/* ---------- Notícias ---------- */
.news-sub {
  text-align: center; font-size: 14px; color: #8a7d68;
  letter-spacing: .5px; margin-bottom: 40px;
}
.news-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 24px; }
.news-card {
  background: #fff; border: 1px solid var(--border); border-radius: 10px;
  overflow: hidden; box-shadow: 0 3px 12px rgba(75,20,28,.06);
  /* Column layout so every card's "read more" line can sit on the baseline,
     however tall the headline above it runs. */
  display: flex; flex-direction: column;
}
.news-card__photo {
  height: 148px; flex: none; background-color: var(--burgundy);
  background-image: repeating-linear-gradient(45deg, rgba(255,255,255,.05) 0 10px, transparent 10px 20px);
  display: flex; align-items: center; justify-content: center;
  color: var(--gold-light); font-family: ui-monospace, monospace;
  font-size: 12px; letter-spacing: 1px;
}
.news-card__body { padding: 18px 20px 22px; flex: 1; display: flex; flex-direction: column; }
.news-card__body h3 {
  font-family: var(--display); font-weight: 600; color: var(--burgundy);
  font-size: 21px; line-height: 1.25; margin-bottom: 10px;
}
.news-card__src { font-size: 13px; color: #888; line-height: 1.45; }

/* ---------- Galeria ---------- */
/* "Passado / Presente" tabs above the slideshow (pill look shared with .book-pills) */
.gal-tabs { justify-content: center; margin-bottom: 24px; }
.gal-tabs button { font-size: 16px; padding: 8px 26px; min-height: 44px; letter-spacing: .5px; }
.gal-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 12px; }
.gal-item {
  aspect-ratio: 1;
  background-color: var(--panel);
  background-image: repeating-linear-gradient(45deg, rgba(194,161,77,.10) 0 9px, transparent 9px 18px);
  border: 1.5px dashed var(--gold);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 6px; color: #9a7f3c; font-family: ui-monospace, monospace;
  font-size: 12px; text-align: center; padding: 8px;
}
.gal-item__kind { font-size: 18px; }
/* Real-photo gallery tiles */
.gal-item--img {
  background-size: cover; background-position: center;
  border: 1px solid var(--border); border-style: solid;
  padding: 0; gap: 0; justify-content: flex-end; color: #fff;
}
.gal-item__label {
  width: 100%; padding: 14px 8px 7px;
  background: linear-gradient(transparent, rgba(60,15,22,.85));
  font-family: ui-monospace, monospace; font-size: 11px; letter-spacing: 1px;
}
.gal-note { text-align: center; font-size: 14px; color: #8a7d68; margin-top: 24px; }

/* ---------- Gallery slideshow ---------- */
.slideshow {
  position: relative; max-width: 900px; margin: 0 auto;
  aspect-ratio: 16 / 10; border-radius: 12px; overflow: hidden;
  border: 1px solid var(--border); background: var(--panel);
  box-shadow: 0 6px 22px rgba(75,20,28,.12);
}
.slideshow__track { position: absolute; inset: 0; }
.slideshow__slide {
  position: absolute; inset: 0;
  background-size: cover; background-position: center;
  display: flex; align-items: flex-end;
  opacity: 0; transition: opacity .6s ease; pointer-events: none;
}
.slideshow__slide.is-active { opacity: 1; pointer-events: auto; }
/* Small originals: the photo at the size its original supports (--size), mounted
   on a plain cream mat, over a dark blurred fill of itself */
.slideshow__slide--small { overflow: hidden; }
.slideshow__slide--small::before {
  content: ''; position: absolute; inset: -40px;
  background: var(--img) center / cover no-repeat;
  filter: blur(24px) brightness(.5) saturate(1.1);
}
.slideshow__stage {
  position: absolute; inset: 0 0 64px; z-index: 2;   /* above the caption's dark fade */
  container-type: size; display: grid; place-items: center;
}
.slideshow__frame {
  --mat: clamp(10px, 5.5cqh, 28px);
  display: block; padding: var(--mat); border-radius: 3px;
  background: radial-gradient(ellipse at 30% 15%, #fffdf8, var(--cream-bg) 70%);
  box-shadow: 0 16px 38px rgba(0,0,0,.55), 0 2px 6px rgba(0,0,0,.3);
}
.slideshow__frame img {
  display: block; width: auto;
  height: min(var(--size, 300px), calc(92cqh - 2 * var(--mat)));
  box-shadow: 0 1px 4px rgba(0,0,0,.25);
}
.slideshow__slide--small .slideshow__label { position: relative; z-index: 1; }
.slideshow__label {
  width: 100%; padding: 48px 22px 34px; color: #fff;
  background: linear-gradient(transparent, rgba(60,15,22,.88));
  font-size: 16px; line-height: 1.4; text-shadow: 0 1px 4px rgba(0,0,0,.4);
}
.slideshow__btn {
  position: absolute; top: 50%; transform: translateY(-50%); z-index: 3;
  width: 46px; height: 46px; border-radius: 50%; border: none; cursor: pointer;
  background: rgba(255,255,255,.85); color: var(--burgundy);
  font-size: 28px; line-height: 1; padding-bottom: 4px;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 2px 10px rgba(0,0,0,.28); transition: background .15s;
}
.slideshow__btn:hover { background: #fff; }
.slideshow__btn--prev { left: 12px; }
.slideshow__btn--next { right: 12px; }
.slideshow__dots {
  position: absolute; left: 0; right: 0; bottom: 12px; z-index: 3;
  display: flex; gap: 8px; justify-content: center;
}
.slideshow__dot {
  width: 9px; height: 9px; border-radius: 50%; border: none; padding: 0;
  cursor: pointer; background: rgba(255,255,255,.55);
  box-shadow: 0 0 3px rgba(0,0,0,.4); transition: background .15s;
}
.slideshow__dot.is-active { background: #fff; }
@media (prefers-reduced-motion: reduce) {
  .slideshow__slide { transition: none; }
}
@media (max-width: 640px) {
  .slideshow { aspect-ratio: 4 / 3; }
  .slideshow__btn { width: 40px; height: 40px; font-size: 24px; }
  .slideshow__label { font-size: 14px; padding: 40px 16px 30px; }
  .deck__nav { width: 42px; height: 42px; font-size: 26px; }
  .deck__nav--prev { left: 6px; }
  .deck__nav--next { right: 6px; }
  /* the slider gets its own full-width row; count · zoom · full screen below it */
  .deck__bar { gap: 6px 8px; flex-wrap: wrap; }
  .deck__range { order: -1; flex-basis: 100%; height: 36px; }
  .deck__zoom { margin: 0 auto; }
  .deck__count { min-width: 0; }
  .deck__zbtn { width: 38px; }
  .deck__zlevel { min-width: 54px; padding: 0 6px; }
  .deck__full { padding: 6px 11px; font-size: 13px; }
}

/* ---------- Informações ---------- */
.info-notes { font-style: italic; color: #6a6356; margin-bottom: 40px; text-align: center; }
.sub-head {
  font-family: var(--display); font-weight: 600; font-size: 26px;
  color: var(--burgundy-mid); border-bottom: 2px solid var(--gold);
  padding-bottom: 8px; margin-bottom: 8px;
}
.sub-intro { font-size: 15px; color: #6a6356; margin-bottom: 24px; }

.solemn-list { display: flex; flex-direction: column; gap: 2px; margin-bottom: 48px; }
.solemn-row {
  display: flex; gap: 18px; align-items: baseline;
  padding: 12px 14px; border-radius: 6px;
}
.solemn-row:nth-child(odd) { background: var(--cream-bg); }
.solemn-row:nth-child(even) { background: var(--panel-alt); }
.solemn-row__date {
  flex: 0 0 110px; font-size: 14px; font-weight: 600;
  color: var(--burgundy); text-align: right;
}
.solemn-row__name { font-family: var(--display); font-weight: 600; font-size: 19px; color: #3a2326; }
.solemn-row__desc { color: #5a5346; }

/* ---------- Accordions ---------- */
.accordion {
  border: 1px solid var(--border); border-radius: 10px;
  overflow: hidden; margin-bottom: 14px; background: #fff;
}
.accordion__head {
  width: 100%; text-align: left; cursor: pointer;
  padding: 18px 22px; font-family: var(--display); font-weight: 600;
  font-size: 22px; display: flex; align-items: center; gap: 12px;
  background: var(--panel); color: var(--burgundy);
  border: none; transition: background .15s;
}
.accordion--c .accordion__head { padding: 16px 22px; font-size: 21px; }
.accordion__head[aria-expanded="false"]:hover { background: #e8e0d2; }
.accordion__mark { color: var(--gold); font-size: 18px; }
.accordion--c .accordion__mark { font-size: 17px; }
.accordion__head[aria-expanded="true"] { background: var(--burgundy); color: #fff; }
.accordion__head[aria-expanded="true"] .accordion__mark { color: var(--gold-light); }
.accordion__body { padding: 22px 24px; border-top: 1px solid #f0e8d8; }
.accordion--c .accordion__body { padding: 20px 24px; }
.accordion__body ul { margin: 0 0 0 20px; display: flex; flex-direction: column; gap: 8px; }
.accordion__body p { margin-bottom: 14px; }
.accordion__body p:last-child { margin-bottom: 0; }

/* ---------- Contacto ---------- */
.contact-para { margin-bottom: 28px; }
.contact-card {
  display: inline-block; background: var(--panel);
  border: 1px solid var(--border); border-radius: 10px; padding: 32px 44px;
}
.contact-card .email { font-family: var(--display); font-size: 24px; margin-bottom: 8px; overflow-wrap: anywhere; }
.contact-card .email a { color: var(--burgundy); text-decoration: underline; overflow-wrap: anywhere; }
.contact-card .loc { font-size: 14px; color: #888; }

/* ---------- Footer ---------- */
.footer {
  background: var(--burgundy-deep); color: #d8c79a;
  text-align: center; padding: 40px 24px; font-size: 15px;
  border-bottom: none;
}
.footer__cross { color: var(--gold-light); font-size: 22px; margin-bottom: 10px; }
.footer p { margin-bottom: 4px; }
.footer p.dim { opacity: .7; }
.footer p.footer__visitors {
  margin-top: 14px; font-size: 13px; letter-spacing: .04em; opacity: .7;
  font-variant-numeric: tabular-nums;
}

/* ---------- News: real photos + clickable cards ---------- */
.news-card__photo--img {
  background-size: cover; background-position: center;
  background-repeat: no-repeat; background-image: none; /* overridden inline */
}
.news-construction { display: flex; justify-content: center; text-align: center; }
.news-card--link { cursor: pointer; transition: box-shadow .15s, transform .15s; }
.news-card--link:hover {
  box-shadow: 0 8px 24px rgba(75,20,28,.16); transform: translateY(-3px);
}
.news-card--link:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }
.news-card__more {
  margin-top: auto; padding-top: 12px; font-size: 13px; font-weight: 600;
  letter-spacing: .3px; color: var(--burgundy);
}

/* Photoless articles: a reverent burgundy crest band in place of the photo,
   so the card keeps the same silhouette as its neighbours in the grid. */
.news-card__photo--crest {
  position: relative; flex-direction: column; gap: 12px;
  background-color: transparent;
  background-image:
    repeating-linear-gradient(45deg, rgba(255,255,255,.045) 0 12px, transparent 12px 24px),
    linear-gradient(150deg, var(--burgundy) 0%, var(--burgundy-deep) 100%);
}
.news-card__crest-mark {
  font-size: 34px; line-height: 1; color: var(--gold-light);
  text-shadow: 0 2px 10px rgba(0,0,0,.28);
}
.news-card__crest-rule { width: 46px; height: 2px; background: var(--gold); opacity: .85; }

/* ---------- Article reader modal ---------- */
.article-modal { position: fixed; inset: 0; z-index: 100; display: none; }
.article-modal.is-open { display: block; }
.article-modal__backdrop {
  position: absolute; inset: 0; background: rgba(30,10,14,.72);
  backdrop-filter: blur(2px);
}
.article-modal__panel {
  position: relative; z-index: 1;
  max-width: min(760px, calc(100% - 40px)); margin: 40px auto; max-height: calc(100vh - 80px);
  background: var(--cream-bg); border-radius: 12px; overflow: hidden;
  box-shadow: 0 20px 60px rgba(0,0,0,.4);
  display: flex; flex-direction: column;
}
.article-modal__close {
  position: absolute; top: 14px; right: 14px; z-index: 2;
  width: 40px; height: 40px; border-radius: 50%; border: none; cursor: pointer;
  background: rgba(255,255,255,.9); color: var(--burgundy);
  font-size: 18px; line-height: 1; box-shadow: 0 2px 8px rgba(0,0,0,.25);
}
.article-modal__close:hover { background: #fff; }
.article-modal__content { overflow-y: auto; -webkit-overflow-scrolling: touch; }
.article__lead {
  height: 300px; background-size: cover; background-position: center;
  background-color: var(--panel);
}
.article__meta {
  padding: 22px 40px 0; font-size: 13px; color: #8a7d68; letter-spacing: .3px;
}
/* When an article has no lead image, clear the floating close button. */
.article-modal__content > .article__meta:first-child { padding-top: 52px; }
.article__headline {
  padding: 6px 40px 0; font-family: var(--display); font-weight: 600;
  color: var(--burgundy); font-size: 30px; line-height: 1.2;
}
.article__flag {
  margin: 14px 40px 0; padding: 8px 14px; font-size: 12.5px; font-style: italic;
  color: #7a6a45; background: var(--panel-alt); border-left: 3px solid var(--gold);
  border-radius: 4px;
}
.article__body { padding: 18px 40px 8px; }
.article__body p { margin-bottom: 16px; }
.article__ask { font-weight: 700; color: var(--burgundy); margin-bottom: 6px; }
.article__ask + p { margin-top: 0; }
.article__sub {
  font-family: var(--display); font-weight: 600; font-size: 22px;
  color: var(--burgundy-mid); margin: 26px 0 10px;
}
.article__quote {
  margin: 20px 0; padding: 6px 0 6px 20px; border-left: 3px solid var(--gold);
  font-family: var(--display); font-style: italic; font-size: 21px;
  color: var(--burgundy-mid);
}
/* Designed header for photoless articles */
.article__titlecard {
  position: relative; text-align: center; color: #fff;
  padding: 48px 40px 40px;
  background: linear-gradient(150deg, var(--burgundy) 0%, var(--burgundy-deep) 100%);
}
.article__titlecard::after {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background-image: repeating-linear-gradient(45deg, rgba(255,255,255,.045) 0 12px, transparent 12px 24px);
}
.article__titlecard > * { position: relative; }
.article__titlecard-cross { font-size: 28px; color: var(--gold-light); line-height: 1; margin-bottom: 14px; }
.article__titlecard-src {
  font-size: 12.5px; letter-spacing: .5px; color: var(--gold-light);
  opacity: .9; margin-bottom: 12px;
}
.article__titlecard-headline {
  font-family: var(--display); font-weight: 600; line-height: 1.15;
  font-size: clamp(26px, 4.4vw, 34px); text-shadow: 0 2px 12px rgba(0,0,0,.3);
}
.article__titlecard-sub {
  font-family: var(--display); font-style: italic; font-size: 20px;
  color: var(--gold-light); margin-top: 16px;
}
.article__titlecard-sub::before { content: '“'; }
.article__titlecard-sub::after { content: '”'; }

/* Key-facts strip */
.article__facts {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 12px; padding: 24px 40px 4px;
}
.article__fact {
  background: var(--panel); border-left: 3px solid var(--gold); border-radius: 6px;
  padding: 12px 15px; display: flex; flex-direction: column; gap: 3px;
}
.article__fact-label {
  font-size: 11px; text-transform: uppercase; letter-spacing: 1px;
  font-weight: 600; color: var(--burgundy);
}
.article__fact-value { font-size: 14px; line-height: 1.4; color: #4a443a; }

/* Editorial drop cap (photoless articles) */
.article__body--cap > p:first-of-type::first-letter {
  float: left; font-family: var(--display); font-weight: 600; color: var(--burgundy);
  font-size: 60px; line-height: .78; padding: 6px 10px 0 0;
}

.article__figure {
  margin: 26px 0 6px;
}
.article__figure img {
  width: 100%; height: auto; display: block; border-radius: 8px;
  border: 1px solid var(--border);
}
.article__figure figcaption {
  margin-top: 8px; font-size: 13px; color: #8a7d68; font-style: italic;
}
.article__gallery {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
  gap: 8px; padding: 8px 40px 40px;
}
.article__gallery img {
  width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 6px;
  border: 1px solid var(--border);
}

/* ---------- Tablets & large phones ---------- */
@media (max-width: 768px) {
  .book-card { padding: 24px; gap: 24px; }
  .mass-card { padding: 26px 30px; }
  .mass-card__time { font-size: 46px; }
  .contact-card { padding: 26px 26px; }
  .intro__welcome, .intro__thanks { font-size: 22px; }
  .accordion__head { font-size: 20px; }
  .accordion--c .accordion__head { font-size: 19px; }
}

/* ---------- Phones ---------- */
@media (max-width: 640px) {
  body { font-size: 17px; }
  .book-card { padding: 20px; gap: 20px; }
  .book-card__qr { flex-basis: auto; }
  .mass-card { padding: 24px 22px; }
  .mass-card__time { font-size: 42px; }
  .prayer-card { padding: 32px 22px 30px; }
  .prayer-card__para { font-size: 17.5px; line-height: 1.8; hyphens: auto; }
  .prayer-card__vocal { font-size: 20px; }
  .solemn-row { gap: 12px; padding: 12px 10px; }
  .solemn-row__date { flex-basis: 86px; }
  .contact-card { padding: 24px 20px; }
  .contact-card .email { font-size: 20px; }
  /* Article reader goes full-screen on phones */
  .article-modal__panel { margin: 0; max-width: 100%; max-height: 100vh; border-radius: 0; }
  .article__lead { height: 200px; }
  .article__meta, .article__headline, .article__body, .article__gallery, .article__facts { padding-left: 22px; padding-right: 22px; }
  .article__titlecard { padding: 34px 22px 28px; }
  .article__titlecard-sub { font-size: 18px; }
  .article__body--cap > p:first-of-type::first-letter { font-size: 48px; }
  .article__flag { margin-left: 22px; margin-right: 22px; }
  .article__headline { font-size: 24px; }
  .article__gallery { grid-template-columns: repeat(auto-fill, minmax(88px, 1fr)); }
}

/* ---------- Small phones ---------- */
@media (max-width: 400px) {
  .nav__toggle { padding: 0 14px; }
  .nav__langtoggle { padding: 0 12px; }
  .section-inner { padding-left: 16px; padding-right: 16px; }
  .book-card { padding: 16px; }
  .note-card { padding: 22px 24px; }
}
