/* Saint Jean Chrysostome · layout and components. Values come from tokens.css only. */

/* ---------- base ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  background: var(--surface);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: var(--step-0);
  line-height: var(--lh-body);
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}
img, picture, video, svg { display: block; max-width: 100%; height: auto; }
h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 400;
  line-height: var(--lh-head);
  letter-spacing: var(--tracking-head);
  text-wrap: balance;
}
h1 { font-size: var(--step-5); }
h2 { font-size: var(--step-3); }
h3 { font-size: var(--step-1); font-weight: 600; }
p, li, dd { text-wrap: pretty; }
p { max-width: var(--width-text); }
a { color: inherit; text-decoration-color: var(--accent); text-underline-offset: 0.2em; }
a:hover { color: var(--accent); }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 3px; }
/* `hidden` must win over component display rules (.btn is inline-flex, .chips is flex) */
html [hidden] { display: none; }
.num, time, .tel { direction: ltr; unicode-bidi: isolate; }
a[href^="mailto:"] { overflow-wrap: break-word; }
/* long Dutch compounds ("parochiebladen") in large titles on a 320 px phone: hyphenate instead of overflowing */
h1, h2, h3 { hyphens: auto; overflow-wrap: break-word; }
.split > * { min-inline-size: 0; }
.vh { position: absolute; inline-size: 1px; block-size: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip-link {
  position: absolute; inset-inline-start: var(--sp-4); inset-block-start: calc(-1 * var(--sp-9));
  background: var(--accent); color: var(--accent-ink); padding: var(--sp-3) var(--sp-5); z-index: 50;
}
.skip-link:focus { inset-block-start: var(--sp-4); }

/* ---------- layout ---------- */
.wrap { inline-size: min(100% - 2 * var(--gutter), var(--width-content)); margin-inline: auto; }
.wrap--wide { inline-size: min(100% - 2 * var(--gutter), var(--width-wide)); }
.section { padding-block: var(--sp-8); }
.section--pivot { padding-block: var(--sp-10); }
.section--raised { background: var(--surface-raised); }
.section--dark { background: var(--surface-inverse); color: var(--ink-inverse); }
.section--dark a:hover { color: var(--gilt-on-dark); }
.section + .section:not(.section--raised, .section--dark) { border-block-start: var(--border); }
.split { display: grid; gap: var(--sp-7); }
@media (min-width: 1024px) {
  .split { grid-template-columns: 7fr 5fr; align-items: start; }
  .split--rev { grid-template-columns: 5fr 7fr; }
}
.stack > * + * { margin-block-start: var(--sp-5); }
.stack-sm > * + * { margin-block-start: var(--sp-3); }
.muted { color: var(--ink-muted); }
.section--dark .muted { color: var(--ink-inverse); opacity: 0.82; }

/* ---------- rubric: the red liturgical cue before every heading ---------- */
.rubric {
  display: flex; align-items: center; gap: var(--sp-2);
  color: var(--accent); font-size: var(--step--1); font-weight: 600;
  font-variant-caps: all-small-caps; letter-spacing: 0.04em;
  margin-block-end: var(--sp-3);
}
:lang(ar) .rubric { font-variant-caps: normal; letter-spacing: 0; }
.section--dark .rubric { color: var(--gilt-on-dark); }
.cross { inline-size: var(--cross); block-size: var(--cross); flex: none; fill: currentColor; }

/* drop cap on the first paragraph of each page (Latin); coloured first word (Arabic) */
.lede { font-size: var(--step-1); line-height: 1.55; }
.lede:not(:lang(ar))::first-letter {
  float: inline-start; font-family: var(--font-display); color: var(--accent);
  font-size: 3.4em; line-height: 0.85; padding-inline-end: var(--sp-2); padding-block-start: var(--sp-1);
}
.lede .initial { color: var(--accent); font-weight: 600; }

/* ---------- header ---------- */
.site-header {
  position: sticky; inset-block-start: 0; z-index: 20;
  background: var(--surface);
  border-block-end: var(--hairline) solid transparent;
  transition: border-color var(--dur-fast) var(--ease);
}
.site-header.is-scrolled { border-block-end-color: var(--line); }
.bar { display: flex; align-items: center; justify-content: space-between; gap: var(--sp-5); min-block-size: 72px; }
.brand { display: flex; align-items: center; gap: var(--sp-3); text-decoration: none; }
.brand .cross { inline-size: 22px; block-size: 22px; color: var(--accent); }
.brand b { display: block; font-family: var(--font-display); font-weight: 600; font-size: var(--step-1); line-height: 1.1; }
.brand small { display: block; font-size: var(--step--1); color: var(--ink-muted); line-height: 1.3; }
.nav ul { list-style: none; padding: 0; display: flex; flex-wrap: wrap; gap: var(--sp-1) var(--sp-5); }
.nav a {
  text-decoration: none; padding-block: var(--sp-2);
  background: linear-gradient(var(--accent), var(--accent)) no-repeat;
  background-size: 0 2px; background-position: bottom 0 left 0;
  transition: background-size var(--dur-fast) var(--ease), color var(--dur-fast) var(--ease);
}
:lang(ar) .nav a { background-position: bottom 0 right 0; }
.nav a:hover, .nav a[aria-current="page"] { background-size: 100% 2px; color: var(--ink); }
.langs { display: flex; gap: var(--sp-3); font-size: var(--step--1); }
.langs a { text-decoration: none; color: var(--ink-muted); padding: var(--sp-2); min-block-size: var(--tap); display: inline-flex; align-items: center; }
.langs a[aria-current="true"] { color: var(--accent); font-weight: 600; }
.menu-btn {
  display: none; min-block-size: var(--tap-mobile); padding-inline: var(--sp-4);
  background: none; border: var(--border); color: var(--ink); font: inherit; cursor: pointer;
}
@media (max-width: 1339px) {
  .menu-btn { display: inline-flex; align-items: center; gap: var(--sp-2); }
  .nav {
    position: fixed; inset: 0; background: var(--surface); z-index: 30;
    padding: var(--sp-9) var(--gutter) var(--sp-7);
    display: none; overflow-y: auto;
  }
  .nav.is-open { display: block; }
  .nav ul { flex-direction: column; gap: 0; }
  .nav li { border-block-end: var(--border); }
  .nav a { display: block; padding-block: var(--sp-4); font-family: var(--font-display); font-size: var(--step-2); background: none; }
  .nav a[aria-current="page"] { color: var(--accent); }
  .nav .langs { margin-block-start: var(--sp-6); }
  .nav-close { position: absolute; inset-block-start: var(--sp-4); inset-inline-end: var(--gutter); }
  .bar > .langs { display: none; }
}
@media (min-width: 1340px) {
  .nav-close, .nav .langs { display: none; }
  .nav ul { gap: var(--sp-1) var(--sp-4); }
  .nav li:first-child { display: none; } /* the brand already links home */
}

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: var(--sp-2);
  min-block-size: var(--tap); padding: var(--sp-3) 22px;
  background: var(--accent); color: var(--accent-ink); border: 0; border-radius: var(--radius);
  font: inherit; font-weight: 600; text-decoration: none; cursor: pointer;
  transition: background-color var(--dur-fast) var(--ease), transform var(--dur-fast) var(--ease);
}
.btn:hover { background: color-mix(in srgb, var(--accent) 85%, black); color: var(--accent-ink); }
.btn:active { transform: translateY(1px); }
.btn--ghost {
  background: none; color: var(--ink); padding-inline: 0;
  background-image: linear-gradient(var(--accent), var(--accent));
  background-repeat: no-repeat; background-size: 36px 2px; background-position: bottom 6px left 0;
  transition: background-size var(--dur-fast) var(--ease), color var(--dur-fast) var(--ease);
}
:lang(ar) .btn--ghost { background-position: bottom 6px right 0; }
.btn--ghost:hover { background-color: transparent; background-size: 100% 2px; color: var(--accent); }
.section--dark .btn--ghost { color: var(--ink-inverse); background-image: linear-gradient(var(--gilt-on-dark), var(--gilt-on-dark)); }
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: var(--sp-4) var(--sp-6); }
@media (max-width: 767px) { .btn { min-block-size: var(--tap-mobile); } }

/* ---------- hero ---------- */
.hero { padding-block: var(--sp-10) var(--sp-8); }
.hero h1 { max-inline-size: 16ch; }
.hero .deck { font-size: var(--step-1); color: var(--ink-muted); margin-block: var(--sp-5) var(--sp-6); }
.trust { font-size: var(--step--1); color: var(--ink-muted); margin-block-start: var(--sp-4); }
.card {
  background: var(--surface-raised); border-block-start: var(--rule-gilt);
  padding: var(--sp-6); border-radius: var(--radius);
}
.card.section--dark { background: var(--surface-inverse); border-block-start-color: var(--gilt-on-dark); }
.next-service .big { font-family: var(--font-display); font-size: var(--step-4); line-height: 1.05; color: var(--accent); }
.next-service dl { display: grid; gap: var(--sp-2); margin-block-start: var(--sp-5); }
.next-service dt { font-weight: 600; }
.next-service dd { color: var(--ink-muted); margin-block-end: var(--sp-2); }
@media (max-width: 767px) { .hero { padding-block: var(--sp-8) var(--sp-7); } }

/* full-bleed photo with an arch-shaped reveal (the royal doors opening) */
.bleed { margin-block: 0; }
@media (max-width: 479px) { .brand small { display: none; } }
.bleed img { inline-size: 100%; aspect-ratio: 16 / 9; max-block-size: 78vh; object-fit: cover; }
.bleed figcaption { font-size: var(--step--1); color: var(--ink-muted); padding-block-start: var(--sp-3); }
/* visible by default; the reveal only plays once JS marks the figure as seen */
[data-reveal="arch"][data-in] img { animation: arch-open var(--dur-slow) var(--ease) both; }
@keyframes arch-open {
  from { clip-path: inset(40% 0 0 0 round 50% 50% 0 0); opacity: 0.4; }
  to { clip-path: inset(0 0 0 0 round 0); opacity: 1; }
}

/* ---------- arch frames for icons and portrait photos ---------- */
.arch { margin: 0; }
.arch picture, .arch > img { border-radius: var(--arch); overflow: hidden; outline: 1px solid var(--gilt); outline-offset: 6px; }
.arch img { inline-size: 100%; aspect-ratio: 3 / 4; object-fit: cover; }
.arch figcaption { font-size: var(--step--1); color: var(--ink-muted); margin-block-start: var(--sp-4); }
.icons-row { display: grid; gap: var(--sp-7); grid-template-columns: repeat(auto-fit, minmax(min(220px, 100%), 1fr)); }

/* ---------- feasts ---------- */
.feasts { list-style: none; padding: 0; display: grid; gap: 0; }
.feast {
  display: grid; grid-template-columns: 7.5rem 1fr; gap: var(--sp-4);
  padding-block: var(--sp-4); border-block-end: var(--border); align-items: baseline;
}
.feast time { color: var(--accent); font-weight: 600; font-variant-numeric: lining-nums; white-space: nowrap; }
:lang(ar) .feast { grid-template-columns: 9.5rem 1fr; }
.feast .tag { display: block; font-size: var(--step--1); color: var(--ink-muted); }
.feast.is-major .name { font-family: var(--font-display); font-size: var(--step-1); }
.feast.is-next { background: var(--accent-soft); padding-inline: var(--sp-3); }
.feast.is-past { display: none; }
.home-feasts .feast.is-hidden { display: none; }
.month { margin-block-start: var(--sp-7); }
.month h3 { font-family: var(--font-display); font-weight: 400; font-size: var(--step-2); border-block-end: var(--rule-gilt); padding-block-end: var(--sp-2); }
@media (max-width: 479px) { .feast { grid-template-columns: 1fr; gap: var(--sp-1); } }

/* ---------- proof strip ---------- */
.proof { display: flex; flex-wrap: wrap; gap: var(--sp-3) var(--sp-6); list-style: none; padding: 0; font-family: var(--font-display); font-size: var(--step-1); }
.proof li + li::before { content: "·"; color: var(--gilt); margin-inline-end: var(--sp-6); }
blockquote { font-family: var(--font-display); font-size: var(--step-2); line-height: 1.3; max-inline-size: 30ch; }
blockquote footer, .quote-src { font-family: var(--font-body); font-size: var(--step--1); color: var(--ink-muted); margin-block-start: var(--sp-3); }

/* ---------- timeline ---------- */
.timeline { list-style: none; padding: 0; border-inline-start: var(--rule-gilt); }
.timeline li { padding-inline-start: var(--sp-6); padding-block-end: var(--sp-6); position: relative; }
.timeline li::before {
  content: ""; position: absolute; inset-inline-start: calc(-1 * var(--sp-2) + -1px); inset-block-start: 0.7em;
  inline-size: var(--sp-3); block-size: var(--sp-3); background: var(--accent); transform: rotate(45deg);
}
.timeline b { display: block; color: var(--accent); font-family: var(--font-display); font-size: var(--step-1); }

/* ---------- lists of teams / schedule ---------- */
.rows { display: grid; gap: 0; }
.row { display: grid; gap: var(--sp-2) var(--sp-6); padding-block: var(--sp-5); border-block-end: var(--border); }
@media (min-width: 768px) { .row { grid-template-columns: 16rem 1fr; } }
.row h3 { font-size: var(--step-1); }
.schedule .when { font-family: var(--font-display); font-size: var(--step-3); color: var(--accent); line-height: 1.1; }

/* ---------- live ---------- */
.player {
  position: relative; aspect-ratio: 16 / 9; background: var(--surface-inverse); color: var(--ink-inverse);
  display: grid; place-items: center; text-align: center; border: 1px solid var(--gilt);
}
.player iframe, .player video { position: absolute; inset: 0; inline-size: 100%; block-size: 100%; border: 0; }
.player .state { padding: var(--sp-6); }
.player .unmute { position: absolute; inset-block-start: var(--sp-4); inset-inline-start: var(--sp-4); z-index: 2; }
.player .tap { position: absolute; inset: 0; margin: auto; inline-size: max-content; block-size: max-content; z-index: 3; }
.player .full { position: absolute; inset-block-start: var(--sp-4); inset-inline-end: var(--sp-4); z-index: 2; background: var(--surface-inverse); color: var(--ink-inverse); padding-inline: var(--sp-4); }
.player video { object-fit: contain; background: var(--surface-inverse); }
/* upright phone video: a tall frame capped to the screen height instead of a small strip in a wide box */
.player.is-portrait { inline-size: min(100%, calc(82vh * 9 / 16)); margin-inline: auto; }
.level meter { inline-size: 100%; block-size: 14px; }
.orient-hint { background: var(--accent-soft); border-inline-start: 4px solid var(--accent); padding: var(--sp-3) var(--sp-4); font-weight: 600; }
.live-dot { display: inline-block; inline-size: 10px; block-size: 10px; border-radius: 999px; background: var(--danger); margin-inline-end: var(--sp-2); }
.is-live .live-dot { animation: pulse 1.6s var(--ease) infinite; }
@keyframes pulse { 50% { opacity: 0.25; } }
.live-badge[hidden] { display: none; }
.live-badge { display: inline-flex; align-items: center; background: var(--accent); color: var(--accent-ink); padding: var(--sp-1) var(--sp-3); font-size: var(--step--1); font-weight: 600; }

/* ---------- gallery ---------- */
.gallery { display: grid; gap: var(--sp-6); grid-template-columns: repeat(auto-fill, minmax(min(280px, 100%), 1fr)); }
.gallery figure { margin: 0; }
.gallery img { inline-size: 100%; aspect-ratio: 4 / 5; object-fit: cover; }
.gallery .wide { grid-column: 1 / -1; }
.gallery .wide img { aspect-ratio: 16 / 9; }
.gallery figcaption { font-size: var(--step--1); color: var(--ink-muted); padding-block-start: var(--sp-2); }

/* ---------- album cards (gallery home) ---------- */
.albums { display: grid; gap: var(--sp-6); grid-template-columns: repeat(auto-fill, minmax(min(300px, 100%), 1fr)); }
.album-card { display: grid; text-decoration: none; color: var(--ink); border: var(--border); background: var(--surface); transition: border-color var(--dur-fast) var(--ease); }
.album-card:hover, .album-card:focus-visible { border-color: var(--accent); }
.album-card img { display: block; inline-size: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.album-empty { display: grid; place-items: center; aspect-ratio: 4 / 3; background: var(--surface-inverse); color: var(--gilt); }
.album-empty .cross { inline-size: 48px; block-size: 48px; }
.album-card-t { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: var(--sp-1) var(--sp-3); padding: var(--sp-4); }
.album-card-t b { font-family: var(--font-display); font-weight: 400; font-size: var(--step-1); }
.album-card-t small { color: var(--ink-muted); white-space: nowrap; }
.gallery a[data-lightbox] { display: block; cursor: zoom-in; }

/* ---------- lightbox ---------- */
.lightbox { margin: 0; padding: 0; border: 0; inline-size: 100vw; block-size: 100dvh; max-inline-size: none; max-block-size: none; background: rgb(12 10 8 / 0.96); color: #f4efe6; }
.lightbox::backdrop { background: rgb(12 10 8 / 0.9); }
.lightbox figure { margin: 0; block-size: 100%; display: grid; grid-template-rows: 1fr auto; place-items: center; padding: 3.5rem var(--sp-4) var(--sp-4); }
.lightbox img { max-inline-size: 100%; max-block-size: calc(100dvh - 8rem); object-fit: contain; }
.lightbox figcaption { text-align: center; padding-block-start: var(--sp-3); max-inline-size: 60ch; }
.lightbox button { position: absolute; inline-size: 48px; block-size: 48px; border: 0; background: rgb(0 0 0 / 0.55); color: #fff; font-size: 2rem; line-height: 1; cursor: pointer; }
.lightbox button:focus-visible { outline: 2px solid var(--gilt); outline-offset: 2px; }
.lb-close { inset-block-start: var(--sp-3); inset-inline-end: var(--sp-3); }
.lb-prev, .lb-next { inset-block-start: 50%; transform: translateY(-50%); }
.lb-prev { inset-inline-start: var(--sp-2); }
.lb-next { inset-inline-end: var(--sp-2); }
[dir="rtl"] .lb-prev, [dir="rtl"] .lb-next { transform: translateY(-50%) scaleX(-1); }
/* counter centred at the top: never under the close button, in either reading direction */
.lb-count { position: absolute; inset-block-start: var(--sp-4); inset-inline: 0; margin: 0; text-align: center; pointer-events: none; }

/* ---------- chips: album links and news filters ---------- */
.chips .chip-page { border-color: var(--accent); color: var(--accent); font-weight: 600; } /* opens another page */
.chips [aria-current="page"] { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.chips { display: flex; flex-wrap: wrap; gap: var(--sp-2); margin-block: var(--sp-5); }
.chips a, .chips button {
  display: inline-flex; align-items: center; gap: var(--sp-1); min-block-size: var(--tap);
  padding-inline: var(--sp-4); border: var(--border); background: var(--surface);
  color: var(--ink); font: inherit; font-size: var(--step--1); text-decoration: none; cursor: pointer;
  transition: border-color var(--dur-fast) var(--ease), color var(--dur-fast) var(--ease);
}
.chips a:hover, .chips button:hover { border-color: var(--accent); color: var(--accent); }
.chips [aria-pressed="true"] { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }

/* ---------- albums ---------- */
.album + .album { border-block-start: var(--border); }
.album-head { display: flex; align-items: baseline; justify-content: space-between; gap: var(--sp-4); margin-block-end: var(--sp-6); border-block-end: var(--rule-gilt); padding-block-end: var(--sp-3); }
.album-head h2 { font-size: var(--step-2); }
.credit { opacity: 0.85; white-space: nowrap; }
.empty { display: flex; align-items: center; gap: var(--sp-4); color: var(--ink-muted); }
.empty .cross { inline-size: 28px; block-size: 28px; color: var(--gilt); }

/* ---------- news ---------- */
.news-list { display: grid; gap: 0; }
.news { display: grid; gap: var(--sp-5); padding-block: var(--sp-6); border-block-end: var(--border); }
@media (min-width: 768px) { .news:has(.news-img) { grid-template-columns: 280px 1fr; } }
.news-img { margin: 0; }
.news-img img { inline-size: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.news-meta { font-size: var(--step--1); color: var(--ink-muted); }
.news-type { color: var(--accent); font-weight: 600; }
.news--funeral .news-type { color: var(--ink); }
.news h3 { font-size: var(--step-2); font-weight: 400; }
.news[hidden] { display: none; }
.news { scroll-margin-block-start: 96px; } /* "read more" lands below the sticky header */
.news:target { background: var(--accent-soft); padding-inline: var(--sp-4); }

/* ---------- liturgical texts (Divine Liturgy, marriage) ---------- */
.lt { max-inline-size: 72ch; }
.lt p { margin-block: var(--sp-3); max-inline-size: none; }
.lt h2 { font-size: var(--step-2); margin-block: var(--sp-8) var(--sp-4); padding-block-end: var(--sp-2); border-block-end: var(--rule-gilt); scroll-margin-block-start: 96px; }
.lt h3 { font-size: var(--step-1); margin-block: var(--sp-7) var(--sp-3); color: var(--accent); scroll-margin-block-start: 96px; }
.lt .lt-title { margin-block-start: 0; }
.lt .role { color: var(--accent); font-weight: 600; font-variant-caps: all-small-caps; letter-spacing: 0.03em; margin-inline-end: var(--sp-1); }
.lt .lt-ar { font-family: "Noto Naskh Arabic", "Amiri", serif; font-size: 1.1em; line-height: 1.9; text-align: start; color: var(--ink); }
.lt .lt-ar .role { font-variant-caps: normal; letter-spacing: 0; }
.toc { margin-block-end: var(--sp-7); }
.toc summary { cursor: pointer; font-family: var(--font-display); font-size: var(--step-1); min-block-size: var(--tap); }
.toc ol { columns: 2 16rem; column-gap: var(--sp-7); padding-inline-start: var(--sp-5); margin-block-start: var(--sp-3); }
.toc li { break-inside: avoid; padding-block: var(--sp-1); font-size: var(--step--1); }

/* ---------- teams ---------- */
.people { display: grid; gap: var(--sp-2); }
.people div { display: grid; gap: 0 var(--sp-4); grid-template-columns: minmax(7rem, auto) 1fr; }
.people dt { font-weight: 600; }
.people dd { color: var(--ink-muted); }
.cal-t { font-size: var(--step-0); margin-block-start: var(--sp-4); }
.dates { list-style: none; padding: 0; display: grid; gap: var(--sp-1); font-size: var(--step--1); }
.dates .is-past { opacity: 0.45; text-decoration: line-through; }
.embed iframe { inline-size: 100%; block-size: 420px; border: var(--border); }

/* ---------- movable feasts table ---------- */
.table-wrap { overflow-x: auto; margin-block-start: var(--sp-6); }
.movable { border-collapse: collapse; inline-size: 100%; min-inline-size: 560px; }
.movable th, .movable td { padding: var(--sp-3) var(--sp-4); border-block-end: var(--border); text-align: start; }
.movable thead th { font-weight: 600; color: var(--accent); font-size: var(--step--1); }
.movable tbody th { font-family: var(--font-display); font-weight: 400; }

/* ---------- broadcaster page ---------- */
.field { display: grid; gap: var(--sp-2); max-inline-size: min(28rem, 100%); grid-template-columns: minmax(0, 1fr); }
.field input, .field select { inline-size: 100%; min-inline-size: 0; }
.field span { font-weight: 600; }
.field input, .field select {
  min-block-size: var(--tap-mobile); padding-inline: var(--sp-4); font: inherit;
  border: 1px solid var(--ink-muted); border-radius: var(--radius); background: var(--surface); color: var(--ink);
}
.field input:focus-visible, .field select:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
.btn--stop { background: var(--ink); }
.btn--stop:hover { background: var(--danger); }
.publish-status { font-weight: 600; min-block-size: 1.7em; }
.publish.is-live .publish-status { color: var(--danger); }
/* show the whole picture exactly as viewers will get it: no cropping that hides an upright phone */
.publish-view video { position: absolute; inset: 0; inline-size: 100%; block-size: 100%; object-fit: contain; }

/* ---------- parish bulletins ---------- */
.bl-year + .bl-year { margin-block-start: var(--sp-8); }
.bl-year > .num { font-size: var(--step-2); border-block-end: var(--rule-gilt); padding-block-end: var(--sp-2); margin-block-end: var(--sp-5); }
.bl-grid { list-style: none; padding: 0; margin: 0; display: grid; gap: var(--sp-4); grid-template-columns: repeat(auto-fill, minmax(min(17rem, 100%), 1fr)); }
.bulletins--mini .bl-grid { grid-template-columns: minmax(0, 1fr); gap: var(--sp-3); }
.bl-card a {
  display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: var(--sp-4);
  min-block-size: 5rem; padding: var(--sp-4); border: var(--border); background: var(--surface);
  color: var(--ink); text-decoration: none; transition: border-color var(--dur-fast) var(--ease);
}
.bl-card a:hover, .bl-card a:focus-visible { border-color: var(--accent); }
.bl-card.is-latest a { border-color: var(--gilt); box-shadow: inset 0 0 0 1px var(--gilt); }
.bl-icon { display: grid; place-items: center; inline-size: 3rem; block-size: 3.6rem; background: var(--accent); color: var(--accent-ink); font-size: var(--step--1); font-weight: 700; letter-spacing: 0.04em; }
.bl-t { display: grid; gap: var(--sp-1); min-inline-size: 0; }
.bl-t b { font-family: var(--font-display); font-weight: 400; font-size: var(--step-1); overflow-wrap: anywhere; }
.bl-t small { color: var(--ink-muted); }
.bl-go { color: var(--accent); font-weight: 600; font-size: var(--step--1); white-space: nowrap; }

/* ---------- articles and monthly activities ---------- */
.art-grid { display: grid; gap: var(--sp-5); grid-template-columns: repeat(auto-fill, minmax(min(21rem, 100%), 1fr)); }
.art-card { display: grid; gap: var(--sp-2); align-content: start; padding: var(--sp-5); border: var(--border); background: var(--surface); }
.art-card h3 { font-size: var(--step-1); margin: 0; }
.art-card p { margin: 0; }
.art-meta { font-size: var(--step--1); color: var(--ink-muted); }
.art-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--sp-2); padding-block-start: var(--sp-2); }
.act-list { list-style: none; padding: 0; margin: 0; display: grid; }
.act-list li { padding-block: var(--sp-2); border-block-end: var(--border); overflow-wrap: anywhere; }
.act-list strong { color: var(--accent); font-weight: 600; }

/* ---------- bulletin reader ---------- */
.pdf-page { scroll-margin-block-start: 90px; } /* a page opened by #p=N is not hidden under the header */
.pdf-viewer { max-inline-size: 60rem; }
.pdf-bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--sp-3); margin-block-end: var(--sp-5); }
.pdf-pages { display: grid; gap: var(--sp-5); }
.pdf-page { display: block; inline-size: 100%; block-size: auto; background: #fff; border: var(--border); box-shadow: 0 2px 14px rgb(0 0 0 / 0.08); }

/* ---------- recordings, documents, admin ---------- */
.rec-list, .doc-list, .admin-list { list-style: none; padding: 0; display: grid; gap: var(--sp-2); }
.rec {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: var(--sp-2) var(--sp-4); inline-size: 100%;
  min-block-size: var(--tap); padding: var(--sp-3) var(--sp-4); border: var(--border); background: var(--surface);
  color: var(--ink); font: inherit; text-align: start; cursor: pointer;
}
.rec:hover, .rec[aria-current] { border-color: var(--accent); color: var(--accent); }
.rec-meta { color: var(--ink-muted); }
.del-at { display: block; flex-basis: 100%; color: var(--danger); font-size: var(--step--1); }
.rec-player { margin-block-end: var(--sp-5); }
.rec-player video { display: block; inline-size: 100%; aspect-ratio: 16 / 9; background: var(--surface-inverse); }
.rec-now { font-weight: 600; margin-block-start: var(--sp-2); }
.doc-list li { overflow-wrap: anywhere; }
.doc-list a { font-weight: 600; }
.admin-list li { display: flex; flex-wrap: wrap; align-items: center; gap: var(--sp-2) var(--sp-3); padding-block: var(--sp-2); border-block-end: var(--border); }
.admin-list .grow { flex: 1 1 16rem; min-inline-size: 0; overflow-wrap: anywhere; }
.btn--sm { min-block-size: 40px; padding-inline: var(--sp-3); font-size: var(--step--1); }
.usage { display: grid; gap: var(--sp-4); grid-template-columns: repeat(auto-fit, minmax(min(16rem, 100%), 1fr)); }
.meter { display: grid; gap: var(--sp-1); }
.meter span { font-weight: 600; }
.meter progress { inline-size: 100%; block-size: 10px; accent-color: var(--accent); }
.confirm { border: 1px solid var(--gilt); background: var(--surface); color: var(--ink); padding: var(--sp-6); inline-size: min(34rem, calc(100vw - 32px)); max-inline-size: none; }
.confirm::backdrop { background: rgb(0 0 0 / 0.55); }
.confirm-name { font-weight: 700; overflow-wrap: anywhere; }
.confirm [data-confirm-msg] p { margin: 0; }
.err { color: var(--danger); font-weight: 600; min-block-size: 1.4em; margin: 0; }

/* ---------- contact ---------- */
.contact-lines { display: grid; gap: var(--sp-4); font-size: var(--step-1); }
.contact-lines a { font-family: var(--font-display); font-size: var(--step-2); text-decoration: none; }
.contact-lines a:hover { color: var(--accent); }
.contact-lines a[href^="mailto:"] { font-size: clamp(1.05rem, 4.6vw, var(--step-2)); }
.contact-lines > div { min-inline-size: 0; }
.addr { font-style: normal; }

/* ---------- audio ---------- */
audio { inline-size: 100%; max-inline-size: 520px; }

/* ---------- footer ---------- */
.site-footer { background: var(--surface-inverse); color: var(--ink-inverse); padding-block: var(--sp-8) var(--sp-9); }
.site-footer a { color: var(--ink-inverse); }
.site-footer a:hover { color: var(--gilt-on-dark); }
.foot { display: grid; gap: var(--sp-7); grid-template-columns: repeat(auto-fit, minmax(min(220px, 100%), 1fr)); }
.foot ul { list-style: none; padding: 0; display: grid; gap: var(--sp-2); }
.foot h2 { font-size: var(--step-1); color: var(--gilt-on-dark); margin-block-end: var(--sp-3); }
/* bottom line: full width, centred, three short lines (name · pastor · address) */
.fine { max-inline-size: none; margin-block-start: var(--sp-7); padding-block-start: var(--sp-5); border-block-start: 1px solid var(--gilt); font-size: var(--step--1); opacity: 0.85; text-align: center; display: grid; gap: var(--sp-1); justify-items: center; }
.fine > span { display: block; }
.nowrap { white-space: nowrap; }

/* ---------- mobile dock ---------- */
.dock { display: none; }
@media (max-width: 767px) {
  .dock {
    position: fixed; inset-inline: 0; inset-block-end: 0; z-index: 15;
    display: flex; align-items: center; justify-content: space-between; gap: var(--sp-4);
    min-block-size: var(--dock-h); padding-inline: var(--gutter);
    background: var(--surface-inverse); color: var(--ink-inverse); font-size: var(--step--1);
    border-block-start: 1px solid var(--gilt);
  }
  .dock a { color: var(--gilt-on-dark); font-weight: 600; min-block-size: var(--tap-mobile); display: inline-flex; align-items: center; }
  body { padding-block-end: var(--dock-h); }
}

/* ---------- 404 ---------- */
.lost { min-block-size: 60vh; display: grid; align-content: center; }

@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;
  }
  .js [data-reveal="arch"]:not([data-in]) img { clip-path: none; }
}

@media print {
  .site-header, .dock, .site-footer, .player { display: none; }
  body { background: none; }
}
