/* ==========================================================================
   St. Mary Coptic Orthodox Church — Design Mockup
   Design system: "Modern Iconography"
   One shared stylesheet for every page. Mobile-first.
   ========================================================================== */

/* ---------- 1. Design tokens ---------- */
:root {
  /* Palette */
  --lapis: #0F2A4A;
  --night: #0A1C33;
  --gold: #C9A24B;
  --gold-soft: #E6D3A3;
  --parchment: #F7F1E5;
  --ivory: #FFFDF8;
  --red: #8E2A2A;
  --ink: #1D1D1F;

  /* Supporting tones (derived, AA-checked against their backgrounds) */
  --muted: #55504A;              /* body copy on parchment/ivory */
  --on-dark: #F4EEE2;            /* body copy on lapis */
  --on-dark-muted: #C9C2B4;      /* secondary copy on lapis */
  --gold-text: #7A5E1E;          /* gold-toned text that passes AA on light */
  --hairline: rgba(201, 162, 75, 0.55);
  --hairline-soft: rgba(201, 162, 75, 0.28);

  /* Type */
  --font-display: "Cormorant Garamond", "Cormorant", Georgia, "Times New Roman", serif;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-arabic: "Amiri", "Traditional Arabic", "Geeza Pro", serif;
  --font-coptic: "Noto Sans Coptic", var(--font-body);

  /* Type scale (fluid) */
  --fs-xs: 0.75rem;
  --fs-sm: 0.875rem;
  --fs-base: 1rem;
  --fs-md: 1.125rem;
  --fs-lg: clamp(1.25rem, 1.1rem + 0.6vw, 1.5rem);
  --fs-xl: clamp(1.6rem, 1.3rem + 1.2vw, 2.25rem);
  --fs-2xl: clamp(2rem, 1.5rem + 2vw, 3rem);
  --fs-hero: clamp(2.5rem, 1.6rem + 4.2vw, 5rem);

  /* Spacing */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.5rem;
  --space-6: 2rem;
  --space-7: 3rem;
  --space-8: 4rem;
  --section-y: clamp(3.5rem, 2.5rem + 4vw, 6.5rem);
  --gutter: 1rem;

  /* Shape & depth */
  --radius: 6px;
  --radius-lg: 14px;
  --shadow-sm: 0 1px 2px rgba(10, 28, 51, 0.06), 0 2px 8px rgba(10, 28, 51, 0.05);
  --shadow-md: 0 10px 30px -12px rgba(10, 28, 51, 0.25);

  /* Layout */
  --container: 1180px;
  --ribbon-h: 0px; /* mockup ribbon removed; was 28px */
  --header-h: 68px;

  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
}

@media (min-width: 768px) {
  :root { --gutter: 2rem; --header-h: 76px; }
}

/* ---------- 2. Base ---------- */
*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--ribbon-h) + var(--header-h) + 1rem);
}

body {
  margin: 0;
  padding-top: var(--ribbon-h);
  font-family: var(--font-body);
  font-size: var(--fs-base);
  line-height: 1.65;
  color: var(--ink);
  background: var(--ivory);
  overflow-x: hidden;
}

body.nav-locked { overflow: hidden; }

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

a { color: var(--lapis); text-underline-offset: 0.2em; text-decoration-thickness: 1px; }
a:hover { color: var(--red); }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.12;
  letter-spacing: -0.005em;
  margin: 0 0 var(--space-4);
  color: var(--lapis);
}
h1 { font-size: var(--fs-hero); }
h2 { font-size: var(--fs-2xl); }
h3 { font-size: var(--fs-lg); }
h4 { font-size: var(--fs-md); }

p { margin: 0 0 var(--space-4); }

/* Visible focus for keyboard users everywhere */
:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 3px;
  border-radius: 3px;
}
.section--lapis :focus-visible,
.hero :focus-visible,
.site-footer :focus-visible { outline-color: var(--gold-soft); }

.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;
}

.skip-link {
  position: absolute;
  left: var(--space-4);
  top: calc(var(--ribbon-h) + var(--space-2));
  z-index: 1000;
  padding: var(--space-2) var(--space-4);
  background: var(--gold);
  color: var(--night);
  font-weight: 600;
  border-radius: var(--radius);
  transform: translateY(-200%);
}
.skip-link:focus { transform: none; }

/* Arabic text anywhere */
[lang="ar"] {
  font-family: var(--font-arabic);
  line-height: 1.9;
}

/* ---------- 3. Layout helpers ---------- */
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.container--narrow { max-width: 780px; }

.section { padding-block: var(--section-y); position: relative; }

.section--ivory { background: var(--ivory); }

/* Parchment: warm base + faint paper grain + faint cross pattern */
.section--parchment {
  background-color: var(--parchment);
  background-image:
    radial-gradient(ellipse at 20% 0%, rgba(230, 211, 163, 0.35), transparent 55%),
    radial-gradient(ellipse at 100% 100%, rgba(201, 162, 75, 0.10), transparent 50%),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120' viewBox='0 0 120 120'%3E%3Cg fill='%23C9A24B' fill-opacity='0.07' transform='translate(40 40) scale(0.4)'%3E%3Cpath d='M46 50 43 24h14l-3 26zM50 54l3 26H47l3-26z'/%3E%3Cpath d='M50 46 76 43v14l-26-3zM50 54 24 57V43l26 3z'/%3E%3Ccircle cx='50' cy='13' r='6.5'/%3E%3Ccircle cx='50' cy='87' r='6.5'/%3E%3Ccircle cx='13' cy='50' r='6.5'/%3E%3Ccircle cx='87' cy='50' r='6.5'/%3E%3C/g%3E%3C/svg%3E");
}

/* Lapis: deep blue + faint gold cross pattern */
.section--lapis {
  color: var(--on-dark);
  background-color: var(--lapis);
  background-image:
    radial-gradient(ellipse at 50% -10%, rgba(230, 211, 163, 0.12), transparent 60%),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120' viewBox='0 0 120 120'%3E%3Cg fill='%23C9A24B' fill-opacity='0.06' transform='translate(40 40) scale(0.4)'%3E%3Cpath d='M46 50 43 24h14l-3 26zM50 54l3 26H47l3-26z'/%3E%3Cpath d='M50 46 76 43v14l-26-3zM50 54 24 57V43l26 3z'/%3E%3Ccircle cx='50' cy='13' r='6.5'/%3E%3Ccircle cx='50' cy='87' r='6.5'/%3E%3Ccircle cx='13' cy='50' r='6.5'/%3E%3Ccircle cx='87' cy='50' r='6.5'/%3E%3C/g%3E%3C/svg%3E"),
    linear-gradient(180deg, var(--lapis), var(--night));
}
.section--lapis h2,
.section--lapis h3,
.section--lapis h4 { color: var(--ivory); }
.section--lapis a:not(.btn) { color: var(--gold-soft); }
.section--lapis a:not(.btn):hover { color: var(--ivory); }

/* Section heading block */
.section-head {
  text-align: center;
  max-width: 680px;
  margin: 0 auto var(--space-7);
}
.section-head p { color: var(--muted); font-size: var(--fs-md); }
.section--lapis .section-head p { color: var(--on-dark-muted); }

.eyebrow {
  display: inline-block;
  font-family: var(--font-body);
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold-text);
  margin-bottom: var(--space-3);
}
.section--lapis .eyebrow,
.hero .eyebrow { color: var(--gold); }

.lede { font-size: var(--fs-md); color: var(--muted); }

/* Grids */
.grid { display: grid; gap: var(--space-5); }
@media (min-width: 640px) {
  .grid--2 { grid-template-columns: repeat(2, 1fr); }
  .grid--3 { grid-template-columns: repeat(2, 1fr); }
  .grid--4 { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 1000px) {
  .grid--3 { grid-template-columns: repeat(3, 1fr); }
  .grid--4 { grid-template-columns: repeat(4, 1fr); }
}

.split { display: grid; gap: var(--space-7); align-items: center; }
@media (min-width: 900px) {
  .split { grid-template-columns: 5fr 6fr; gap: var(--space-8); }
  .split--reverse > :first-child { order: 2; }
}

/* ---------- 4. The Coptic cross motif ---------- */
.cross { width: 1em; height: 1em; fill: currentColor; flex: none; }

/* Divider: hairline — cross — hairline */
.divider {
  display: flex;
  align-items: center;
  gap: var(--space-4);
  color: var(--gold);
  max-width: 320px;
  margin: 0 auto var(--space-5);
}
.divider::before,
.divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--hairline));
}
.divider::after { background: linear-gradient(90deg, var(--hairline), transparent); }
.divider .cross { width: 22px; height: 22px; }

/* ---------- 5. Mockup ribbon & TBD tags ---------- */
.mockup-ribbon {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 200;
  height: var(--ribbon-h);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-3);
  background: repeating-linear-gradient(-45deg, var(--red), var(--red) 12px, #7d2424 12px, #7d2424 24px);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  white-space: nowrap;
  overflow: hidden;
}
.mockup-ribbon span { opacity: 0.85; font-weight: 500; letter-spacing: 0.08em; }
@media (max-width: 767px) { .mockup-ribbon span { display: none; } }

.tbd {
  display: inline-block;
  vertical-align: middle;
  margin-inline-start: 0.4em;
  padding: 0.05em 0.45em;
  border: 1px dashed currentColor;
  border-radius: 3px;
  font-family: var(--font-body);
  font-size: 0.65rem;
  font-weight: 600;
  font-style: normal;
  letter-spacing: 0.08em;
  line-height: 1.5;
  text-transform: uppercase;
  color: var(--red);
  background: rgba(142, 42, 42, 0.05);
  white-space: nowrap;
}
.section--lapis .tbd,
.hero .tbd,
.site-footer .tbd,
.tbd--light {
  color: var(--gold-soft);
  background: rgba(230, 211, 163, 0.08);
}

/* ---------- 6. Buttons ---------- */
.btn {
  --btn-bg: var(--lapis);
  --btn-fg: var(--ivory);
  --btn-bd: var(--lapis);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5em;
  min-height: 44px;
  padding: 0.7em 1.4em;
  border: 1px solid var(--btn-bd);
  border-radius: 999px;
  background: var(--btn-bg);
  color: var(--btn-fg);
  font-family: var(--font-body);
  font-size: var(--fs-sm);
  font-weight: 600;
  letter-spacing: 0.02em;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color 0.2s var(--ease), color 0.2s var(--ease), border-color 0.2s var(--ease), transform 0.2s var(--ease);
}
.btn:hover { color: var(--btn-fg); transform: translateY(-1px); }
.btn:active { transform: none; }

.btn--primary:hover { --btn-bg: var(--night); --btn-bd: var(--night); }

.btn--gold {
  --btn-bg: var(--gold);
  --btn-fg: var(--night);
  --btn-bd: var(--gold);
}
.btn--gold:hover { --btn-bg: var(--gold-soft); --btn-bd: var(--gold-soft); }

.btn--ghost {
  --btn-bg: transparent;
  --btn-fg: var(--lapis);
  --btn-bd: var(--hairline);
}
.btn--ghost:hover { --btn-bg: var(--lapis); --btn-fg: var(--ivory); --btn-bd: var(--lapis); }

.btn--ghost-light {
  --btn-bg: transparent;
  --btn-fg: var(--ivory);
  --btn-bd: rgba(230, 211, 163, 0.6);
}
.btn--ghost-light:hover { --btn-bg: rgba(230, 211, 163, 0.12); --btn-fg: var(--ivory); --btn-bd: var(--gold-soft); }

.btn--sm { min-height: 38px; padding: 0.45em 1.1em; font-size: var(--fs-xs); }

.btn .icon { width: 1.1em; height: 1.1em; fill: currentColor; }

.btn-row { display: flex; flex-wrap: wrap; gap: var(--space-3); }

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 0.4em;
  font-weight: 600;
  font-size: var(--fs-sm);
  text-decoration: none;
}
.link-arrow::after { content: "→"; transition: transform 0.2s var(--ease); }
.link-arrow:hover::after { transform: translateX(3px); }

/* ---------- 7. Cards ---------- */
.card {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: var(--space-6);
  background: var(--ivory);
  border: 1px solid var(--hairline-soft);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}
.card h3 { margin-bottom: var(--space-2); }
.card p { color: var(--muted); }
.card > :last-child { margin-bottom: 0; }
.card .card-foot { margin-top: auto; padding-top: var(--space-4); }

/* Inner gold hairline, like a gilded manuscript frame */
.card--framed::before {
  content: "";
  position: absolute;
  inset: 7px;
  border: 1px solid var(--hairline-soft);
  border-radius: calc(var(--radius-lg) - 5px);
  pointer-events: none;
}

.card--dark {
  background: rgba(255, 253, 248, 0.04);
  border-color: rgba(201, 162, 75, 0.35);
  box-shadow: none;
  color: var(--on-dark);
}
.card--dark p { color: var(--on-dark-muted); }

.card-icon {
  display: grid;
  place-items: center;
  width: 48px; height: 48px;
  margin-bottom: var(--space-4);
  border: 1px solid var(--hairline);
  border-radius: 50%;
  color: var(--gold);
}
.card-icon .cross { width: 22px; height: 22px; }

/* ---------- 8. Photo placeholders & arched frames ---------- */
.photo {
  position: relative;
  margin: 0;
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: linear-gradient(160deg, var(--lapis), var(--night));
  aspect-ratio: 4 / 3;
}
.photo img { width: 100%; height: 100%; object-fit: cover; }

/* Caption appears only while the placeholder image is showing */
.photo figcaption {
  position: absolute;
  inset: auto 0 0 0;
  padding: var(--space-3) var(--space-4);
  font-size: var(--fs-xs);
  font-weight: 500;
  letter-spacing: 0.04em;
  color: var(--ivory);
  background: linear-gradient(0deg, rgba(10, 28, 51, 0.85), transparent);
  text-align: center;
}
.photo:not(.is-placeholder) figcaption { display: none; }
.photo--parchment.is-placeholder figcaption {
  color: var(--lapis);
  background: linear-gradient(0deg, rgba(247, 241, 229, 0.95), transparent);
}

/* Arched church-window frame (4:5 so the arch is a true semicircle) */
.photo--arch {
  aspect-ratio: 4 / 5;
  border-radius: 50% 50% var(--radius) var(--radius) / 40% 40% var(--radius) var(--radius);
  box-shadow: var(--shadow-md);
}
.photo--arch::after {
  content: "";
  position: absolute;
  inset: 10px;
  border: 1px solid rgba(230, 211, 163, 0.6);
  border-radius: 50% 50% 3px 3px / 40% 40% 3px 3px;
  pointer-events: none;
}
.photo--arch figcaption { padding-bottom: var(--space-5); }

.photo--wide { aspect-ratio: 16 / 9; }

/* ---------- 9. Header ---------- */
.site-header {
  position: sticky;
  top: var(--ribbon-h);
  z-index: 100;
  border-bottom: 1px solid var(--hairline-soft);
}
/* Frosted background lives on a pseudo-element: a backdrop-filter on the
   header itself would trap the fixed-position mobile drawer inside it. */
.site-header::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: rgba(255, 253, 248, 0.94);
  backdrop-filter: saturate(1.2) blur(10px);
  -webkit-backdrop-filter: saturate(1.2) blur(10px);
}
.header-inner {
  display: flex;
  align-items: center;
  gap: var(--space-4);
  height: var(--header-h);
}

.brand {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  margin-inline-end: auto;
  color: var(--lapis);
  text-decoration: none;
  min-width: 0;
}
.brand:hover { color: var(--lapis); }
/* Church seal (images/logo.jpg), cropped to a circle with a gold ring */
.brand-mark {
  display: block;
  width: 48px; height: 48px;
  flex: none;
  padding: 2px;
  overflow: hidden;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: var(--shadow-sm);
}
.brand-mark img {
  width: 100%; height: 100%;
  border-radius: 50%;
  object-fit: cover;
  transform: scale(1.03); /* hides the white corners of the square JPG */
  background: var(--ivory);
}
.site-footer .brand-mark { width: 64px; height: 64px; }
.brand-text { display: flex; flex-direction: column; line-height: 1.1; min-width: 0; }
.brand-name {
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 700;
  white-space: nowrap;
}
.brand-sub {
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.header-actions { display: flex; align-items: center; gap: var(--space-2); }

/* EN | عربي toggle */
.lang-toggle {
  display: inline-flex;
  padding: 3px;
  border: 1px solid var(--hairline);
  border-radius: 999px;
}
.lang-toggle button {
  min-height: 32px;
  min-width: 40px;
  padding: 0 0.7em;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--lapis);
  font: 600 0.75rem/1 var(--font-body);
  cursor: pointer;
}
.lang-toggle button[lang="ar"] { font-family: var(--font-arabic); font-size: 0.95rem; }
.lang-toggle button[aria-pressed="true"] { background: var(--lapis); color: var(--ivory); }

/* Menu button (mobile) */
.menu-btn {
  display: inline-grid;
  place-items: center;
  width: 44px; height: 44px;
  padding: 0;
  border: 1px solid var(--hairline);
  border-radius: 50%;
  background: transparent;
  color: var(--lapis);
  cursor: pointer;
}
.menu-btn svg { width: 20px; height: 20px; stroke: currentColor; }

/* Nav — mobile: slide-in drawer */
.site-nav {
  position: fixed;
  top: var(--ribbon-h);
  bottom: 0;
  right: 0;
  z-index: 150;
  width: min(86vw, 360px);
  padding: var(--space-6) var(--space-5);
  display: flex;
  flex-direction: column;
  gap: var(--space-5);
  overflow-y: auto;
  background: var(--lapis);
  background-image: linear-gradient(180deg, var(--lapis), var(--night));
  color: var(--on-dark);
  transform: translateX(100%);
  visibility: hidden;
  transition: transform 0.35s var(--ease), visibility 0s linear 0.35s;
}
.nav-open .site-nav {
  transform: none;
  visibility: visible;
  transition: transform 0.35s var(--ease);
}
.nav-close {
  flex: none;
  align-self: flex-end;
  width: 44px; height: 44px;
  display: grid; place-items: center;
  border: 1px solid rgba(230, 211, 163, 0.4);
  border-radius: 50%;
  background: transparent;
  color: var(--ivory);
  cursor: pointer;
}
.nav-close svg { width: 18px; height: 18px; stroke: currentColor; }

.nav-list { list-style: none; margin: 0; padding: 0; }
.nav-list a {
  display: block;
  padding: var(--space-3) 0;
  border-bottom: 1px solid rgba(201, 162, 75, 0.2);
  font-family: var(--font-display);
  font-size: 1.45rem;
  font-weight: 600;
  color: var(--ivory);
  text-decoration: none;
}
.nav-list a:hover,
.nav-list a[aria-current="page"] { color: var(--gold); }
.site-nav .lang-toggle { align-self: flex-start; border-color: rgba(230, 211, 163, 0.45); }
.site-nav .lang-toggle button { color: var(--ivory); }
.site-nav .lang-toggle button[aria-pressed="true"] { background: var(--gold); color: var(--night); }
.nav-extra { display: grid; gap: var(--space-3); margin-top: auto; }
.nav-extra a { color: var(--gold-soft); font-size: var(--fs-sm); }

.nav-scrim {
  position: fixed;
  inset: 0;
  z-index: 140;
  background: rgba(10, 28, 51, 0.5);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s var(--ease), visibility 0s linear 0.3s;
}
.nav-open .nav-scrim { opacity: 1; visibility: visible; transition: opacity 0.3s var(--ease); }

.header-lang { display: none; }

@media (max-width: 379px) {
  .brand-sub { display: none; }
  .header-actions .btn--gold { padding-inline: 0.9em; }
}

/* Nav — desktop: inline */
@media (min-width: 1100px) {
  .menu-btn, .nav-close, .nav-scrim, .site-nav .lang-toggle, .nav-extra { display: none; }
  .header-lang { display: inline-flex; }
  .site-nav {
    position: static;
    width: auto;
    padding: 0;
    flex-direction: row;
    overflow: visible;
    background: none;
    color: inherit;
    transform: none;
    visibility: visible;
    transition: none;
  }
  .nav-list { display: flex; gap: var(--space-1); }
  .nav-list a {
    position: relative;
    padding: var(--space-2) var(--space-3);
    border: 0;
    font-family: var(--font-body);
    font-size: var(--fs-sm);
    font-weight: 500;
    color: var(--ink);
  }
  .nav-list a::after {
    content: "";
    position: absolute;
    left: var(--space-3); right: var(--space-3); bottom: 2px;
    height: 1px;
    background: var(--gold);
    transform: scaleX(0);
    transition: transform 0.25s var(--ease);
  }
  .nav-list a:hover { color: var(--lapis); }
  .nav-list a:hover::after,
  .nav-list a[aria-current="page"]::after { transform: scaleX(1); }
  .nav-list a[aria-current="page"] { color: var(--lapis); }
}

/* ---------- 10. Fasting banner ---------- */
.fast-banner {
  background: var(--parchment);
  border-bottom: 1px solid var(--hairline-soft);
  font-size: var(--fs-sm);
  color: var(--ink);
}
.fast-banner .container {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: var(--space-2) var(--space-3);
  padding-block: var(--space-2);
  text-align: center;
}
.fast-banner strong { font-family: var(--font-display); font-size: 1.1rem; color: var(--red); }
.fast-banner .cross { color: var(--red); width: 14px; height: 14px; }

/* ---------- 11. Hero ---------- */
.hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  color: var(--on-dark);
  text-align: center;
  padding-block: clamp(4rem, 3rem + 6vw, 8.5rem) clamp(4rem, 3rem + 5vw, 7rem);
  background: linear-gradient(180deg, var(--lapis) 0%, var(--night) 100%);
}
/* faint cross lattice */
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -2;
  opacity: 0.9;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='96' height='96' viewBox='0 0 120 120'%3E%3Cg fill='%23C9A24B' fill-opacity='0.055' transform='translate(40 40) scale(0.4)'%3E%3Cpath d='M46 50 43 24h14l-3 26zM50 54l3 26H47l3-26z'/%3E%3Cpath d='M50 46 76 43v14l-26-3zM50 54 24 57V43l26 3z'/%3E%3Ccircle cx='50' cy='13' r='6.5'/%3E%3Ccircle cx='50' cy='87' r='6.5'/%3E%3Ccircle cx='13' cy='50' r='6.5'/%3E%3Ccircle cx='87' cy='50' r='6.5'/%3E%3C/g%3E%3C/svg%3E");
  mask-image: radial-gradient(ellipse at center, #000 30%, transparent 80%);
  -webkit-mask-image: radial-gradient(ellipse at center, #000 30%, transparent 80%);
}
/* candlelight glow */
.hero-glow {
  position: absolute;
  z-index: -1;
  left: 50%;
  top: 38%;
  width: min(1100px, 150vw);
  aspect-ratio: 1.6;
  transform: translate(-50%, -50%);
  background:
    radial-gradient(ellipse at center, rgba(255, 214, 140, 0.26) 0%, rgba(230, 180, 90, 0.10) 35%, transparent 65%);
  pointer-events: none;
}

.hero-inner { max-width: 900px; margin-inline: auto; }

.hero-coptic {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: var(--space-2);
  margin-bottom: var(--space-4);
  font-family: var(--font-coptic);
  font-size: var(--fs-md);
  letter-spacing: 0.12em;
  color: var(--gold);
}

.hero h1 {
  color: var(--ivory);
  font-weight: 500;
  margin-bottom: var(--space-3);
}
.hero h1 .h1-line2 {
  display: block;
  font-size: 0.42em;
  font-weight: 500;
  font-style: italic;
  letter-spacing: 0.02em;
  color: var(--gold-soft);
  margin-top: var(--space-3);
}

.hero .divider { margin-block: var(--space-6); }

.verse { margin: 0 auto var(--space-7); max-width: 720px; }
.verse blockquote { margin: 0; }
.verse-en {
  font-family: var(--font-display);
  font-size: var(--fs-lg);
  font-style: italic;
  line-height: 1.5;
  color: var(--ivory);
  margin-bottom: var(--space-4);
}
.verse-ar {
  font-size: var(--fs-md);
  color: var(--gold-soft);
  margin-bottom: var(--space-3);
}
.verse cite {
  display: block;
  font-style: normal;
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold);
}

.hero .btn-row { justify-content: center; }

/* Live / next-service status pill */
.status-pill {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5em;
  margin-bottom: var(--space-6);
  padding: 0.4em 1em;
  border: 1px solid rgba(230, 211, 163, 0.4);
  border-radius: 999px;
  background: rgba(10, 28, 51, 0.45);
  font-size: var(--fs-xs);
  font-weight: 500;
  letter-spacing: 0.04em;
  color: var(--on-dark);
  text-decoration: none;
}
.status-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 0 3px rgba(201, 162, 75, 0.25);
}
.status-pill.is-live .status-dot { background: #E0605A; box-shadow: 0 0 0 3px rgba(224, 96, 90, 0.3); }

/* ---------- 12. Home-specific blocks ---------- */

/* Values list */
.values {
  list-style: none;
  margin: var(--space-5) 0 var(--space-6);
  padding: 0;
  display: grid;
  gap: var(--space-3);
}
@media (min-width: 560px) { .values { grid-template-columns: 1fr 1fr; } }
.values li {
  display: flex;
  gap: var(--space-3);
  align-items: flex-start;
  font-weight: 500;
}
.values .cross { color: var(--gold); width: 18px; height: 18px; margin-top: 0.2em; }

/* Today in the Coptic Church */
.today {
  display: grid;
  gap: 0;
  overflow: hidden;
  padding: 0;
}
@media (min-width: 900px) { .today { grid-template-columns: 1fr 1.4fr; } }
.today-date {
  padding: var(--space-6);
  background: linear-gradient(160deg, var(--lapis), var(--night));
  color: var(--on-dark);
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}
.today-date .eyebrow { color: var(--gold); margin-bottom: 0; }
.today-date .today-greg {
  font-family: var(--font-display);
  font-size: var(--fs-xl);
  line-height: 1.15;
  color: var(--ivory);
}
.today-date .today-coptic {
  font-family: var(--font-display);
  font-size: var(--fs-lg);
  font-style: italic;
  color: var(--gold-soft);
}
.today-date .today-season {
  margin-top: auto;
  padding-top: var(--space-4);
  border-top: 1px solid rgba(201, 162, 75, 0.3);
  font-size: var(--fs-sm);
}
.today-season strong { display: block; color: var(--ivory); font-family: var(--font-display); font-size: 1.25rem; font-weight: 600; }
.today-body {
  padding: var(--space-6);
  display: grid;
  gap: var(--space-5);
}
.today-item h3 {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-size: 1.3rem;
  margin-bottom: var(--space-1);
}
.today-item h3 .cross { color: var(--gold); width: 16px; height: 16px; }
.today-item p { margin: 0; color: var(--muted); font-size: var(--fs-sm); }
.today-item ul { margin: 0; padding: 0; list-style: none; font-size: var(--fs-sm); color: var(--muted); }
.today-item li { padding: 2px 0; }
.today-item li span { display: inline-block; min-width: 9.5em; font-weight: 600; color: var(--ink); }
.sample-note {
  font-size: var(--fs-xs);
  color: var(--muted);
  border-top: 1px dashed var(--hairline);
  padding-top: var(--space-3);
}

/* Service times */
.service {
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}
.service-day {
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gold);
}
.service h3 { margin: 0; font-size: 1.5rem; }
.service .service-time {
  font-family: var(--font-display);
  font-size: var(--fs-lg);
  color: var(--gold-soft);
}

/* First visit steps */
.steps { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--space-5); counter-reset: step; }
.steps li { position: relative; padding-inline-start: 3.5rem; }
.steps li::before {
  counter-increment: step;
  content: counter(step, upper-roman);
  position: absolute;
  inset-inline-start: 0;
  top: 0;
  width: 2.5rem; height: 2.5rem;
  display: grid; place-items: center;
  border: 1px solid var(--hairline);
  border-radius: 50%;
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--gold-text);
}
.steps h3 { font-size: 1.3rem; margin-bottom: var(--space-1); }
.steps p { margin: 0; color: var(--muted); }

/* Video / sermon cards */
.video-card { padding: 0; overflow: hidden; }
.video-card .photo { border-radius: 0; aspect-ratio: 16 / 9; }
.video-card .play {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  pointer-events: none;
}
.video-card .play span {
  display: grid; place-items: center;
  width: 56px; height: 56px;
  border-radius: 50%;
  background: rgba(10, 28, 51, 0.6);
  border: 1px solid var(--gold-soft);
  color: var(--ivory);
}
.video-card .play svg { width: 20px; height: 20px; fill: currentColor; margin-inline-start: 3px; }
.video-body { padding: var(--space-5); display: flex; flex-direction: column; flex: 1; }
.video-body h3 { font-size: 1.3rem; }
.video-body h3 a { color: inherit; text-decoration: none; }
.video-body h3 a::after { content: ""; position: absolute; inset: 0; } /* whole card clickable */
.video-meta { font-size: var(--fs-xs); color: var(--muted); margin: 0; }
.tag {
  display: inline-block;
  margin-bottom: var(--space-2);
  padding: 0.1em 0.6em;
  border-radius: 999px;
  background: var(--parchment);
  border: 1px solid var(--hairline-soft);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--gold-text);
  align-self: flex-start;
}

/* Events list */
.events { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--space-3); }
.event {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: var(--space-4);
  align-items: center;
  padding: var(--space-4);
  background: var(--ivory);
  border: 1px solid var(--hairline-soft);
  border-radius: var(--radius-lg);
}
@media (min-width: 768px) { .event { grid-template-columns: auto 1fr auto; padding: var(--space-4) var(--space-5); } }
.event-date {
  display: grid;
  place-items: center;
  width: 64px;
  padding: var(--space-2) 0;
  border-radius: var(--radius);
  background: var(--lapis);
  color: var(--ivory);
  line-height: 1;
  text-align: center;
}
.event-date .m { font-size: 0.65rem; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; color: var(--gold); }
.event-date .d { font-family: var(--font-display); font-size: 1.9rem; font-weight: 600; margin-top: 2px; }
.event h3 { font-size: 1.25rem; margin: 0 0 2px; }
.event p { margin: 0; font-size: var(--fs-sm); color: var(--muted); }
.event .btn { grid-column: 1 / -1; justify-self: start; }
@media (min-width: 768px) { .event .btn { grid-column: auto; } }

.ccb-note {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  margin-top: var(--space-5);
  font-size: var(--fs-sm);
  color: var(--muted);
}

/* Faith in Action strip */
.action-strip {
  display: grid;
  gap: var(--space-4);
}
@media (min-width: 640px) { .action-strip { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1000px) { .action-strip { grid-template-columns: repeat(4, 1fr); } }
.action-item {
  padding: var(--space-5);
  border-top: 1px solid var(--gold);
}
.action-item h3 { font-size: 1.35rem; margin-bottom: var(--space-2); }
.action-item p { color: var(--on-dark-muted); font-size: var(--fs-sm); margin: 0; }

/* Priest feature */
.priest-facts {
  list-style: none;
  margin: var(--space-5) 0 var(--space-6);
  padding: 0;
  display: grid;
  gap: var(--space-2);
  font-size: var(--fs-sm);
}
.priest-facts li { display: flex; gap: var(--space-3); padding-bottom: var(--space-2); border-bottom: 1px solid var(--hairline-soft); }
.priest-facts li span:first-child { min-width: 8em; font-weight: 600; color: var(--lapis); }

/* Give CTA */
.give-cta {
  text-align: center;
  padding: clamp(2.5rem, 2rem + 3vw, 4.5rem) var(--space-5);
  border-radius: var(--radius-lg);
  border: 1px solid var(--hairline);
  background:
    radial-gradient(ellipse at 50% 0%, rgba(230, 211, 163, 0.35), transparent 70%),
    var(--ivory);
}
.give-cta h2 { margin-bottom: var(--space-3); }
.give-cta p { max-width: 560px; margin-inline: auto; color: var(--muted); }
.give-cta .btn-row { justify-content: center; margin-top: var(--space-5); }

/* ---------- 13. Forms ---------- */
.field { display: grid; gap: var(--space-1); }
.field label { font-size: var(--fs-sm); font-weight: 600; }
.input {
  width: 100%;
  min-height: 44px;
  padding: 0.6em 0.9em;
  border: 1px solid #B8AE9C;
  border-radius: var(--radius);
  background: var(--ivory);
  color: var(--ink);
  font: inherit;
}
.input:focus-visible { outline: 2px solid var(--gold); outline-offset: 1px; border-color: var(--lapis); }
.form-note { font-size: var(--fs-xs); margin: var(--space-2) 0 0; min-height: 1.2em; }

/* ---------- 14. Footer ---------- */
.site-footer {
  color: var(--on-dark-muted);
  background: var(--night);
  border-top: 3px double var(--gold);
  font-size: var(--fs-sm);
}
.site-footer a { color: var(--gold-soft); }
.site-footer a:hover { color: var(--ivory); }
.footer-grid {
  display: grid;
  gap: var(--space-6);
  padding-block: var(--space-8) var(--space-6);
}
@media (min-width: 768px) { .footer-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1100px) { .footer-grid { grid-template-columns: 1.4fr 1fr 1fr 1.4fr; } }
.site-footer h2 {
  font-family: var(--font-body);
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: var(--space-4);
}
.site-footer .brand { color: var(--ivory); margin-bottom: var(--space-4); }
.site-footer .brand-sub { color: var(--on-dark-muted); }
.site-footer address { font-style: normal; line-height: 1.8; }
.footer-list { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--space-2); }
.social { display: flex; gap: var(--space-2); margin-top: var(--space-4); }
.social a {
  display: grid; place-items: center;
  width: 40px; height: 40px;
  border: 1px solid rgba(201, 162, 75, 0.45);
  border-radius: 50%;
}
.social svg { width: 18px; height: 18px; fill: currentColor; }
.newsletter { display: grid; gap: var(--space-2); }
.newsletter-row { display: flex; gap: var(--space-2); }
.newsletter .input { background: rgba(255, 253, 248, 0.06); border-color: rgba(201, 162, 75, 0.45); color: var(--ivory); }
.newsletter .input::placeholder { color: #A9A294; }
.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: var(--space-3);
  padding-block: var(--space-5);
  border-top: 1px solid rgba(201, 162, 75, 0.2);
  font-size: var(--fs-xs);
}

/* ---------- 15. Motion (only when the visitor allows it) ---------- */
@media (prefers-reduced-motion: no-preference) {
  /* Fade-up on scroll: JS adds .js to <html> and .is-visible to elements */
  .js .reveal {
    opacity: 0;
    transform: translateY(18px);
    transition: opacity 0.9s var(--ease), transform 0.9s var(--ease);
  }
  .js .reveal.is-visible { opacity: 1; transform: none; }
  .js .reveal-delay-1 { transition-delay: 0.1s; }
  .js .reveal-delay-2 { transition-delay: 0.2s; }
  .js .reveal-delay-3 { transition-delay: 0.3s; }

  /* Slow gold-leaf shimmer */
  .shimmer {
    background: linear-gradient(100deg, var(--gold) 0%, var(--gold) 40%, #F3E3B5 50%, var(--gold) 60%, var(--gold) 100%);
    background-size: 250% 100%;
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    animation: shimmer 7s linear infinite;
  }
  .divider .cross, .brand-mark .cross { animation: glint 7s ease-in-out infinite; }

  /* Candle-like breathing of the hero glow */
  .hero-glow { animation: candle 6s ease-in-out infinite alternate; }

  .status-pill.is-live .status-dot { animation: pulse 1.8s ease-in-out infinite; }
}

@keyframes shimmer { from { background-position: 150% 0; } to { background-position: -100% 0; } }
@keyframes glint { 0%, 80%, 100% { filter: none; } 90% { filter: brightness(1.35) drop-shadow(0 0 3px rgba(230, 211, 163, 0.6)); } }
@keyframes candle { from { opacity: 0.8; transform: translate(-50%, -50%) scale(1); } to { opacity: 1; transform: translate(-50%, -51%) scale(1.04); } }
@keyframes pulse { 50% { box-shadow: 0 0 0 6px rgba(224, 96, 90, 0); } }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* ==========================================================================
   PHASE 2 — Inner-page components
   ========================================================================== */

/* ---------- 16. Page hero (inner pages) ---------- */
.page-hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  padding-block: clamp(3rem, 2.4rem + 3vw, 5.5rem);
  color: var(--on-dark);
  text-align: center;
  background: linear-gradient(180deg, var(--lapis), var(--night));
}
.page-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(ellipse at 50% 0%, rgba(255, 214, 140, 0.20), transparent 60%),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='96' height='96' viewBox='0 0 120 120'%3E%3Cg fill='%23C9A24B' fill-opacity='0.06' transform='translate(40 40) scale(0.4)'%3E%3Cpath d='M46 50 43 24h14l-3 26zM50 54l3 26H47l3-26z'/%3E%3Cpath d='M50 46 76 43v14l-26-3zM50 54 24 57V43l26 3z'/%3E%3Ccircle cx='50' cy='13' r='6.5'/%3E%3Ccircle cx='50' cy='87' r='6.5'/%3E%3Ccircle cx='13' cy='50' r='6.5'/%3E%3Ccircle cx='87' cy='50' r='6.5'/%3E%3C/g%3E%3C/svg%3E");
}
.page-hero h1 { color: var(--ivory); font-size: var(--fs-2xl); font-weight: 500; margin-bottom: var(--space-3); }
.page-hero .lede { color: var(--on-dark-muted); max-width: 640px; margin: 0 auto; }
.page-hero .divider { margin-bottom: var(--space-4); }

/* In-page section links; sticks under the header while scrolling */
.subnav {
  position: sticky;
  top: calc(var(--ribbon-h) + var(--header-h));
  z-index: 50;
  background: rgba(247, 241, 229, 0.96);
  border-bottom: 1px solid var(--hairline-soft);
}
.subnav ul {
  display: flex;
  gap: var(--space-1);
  margin: 0 auto;
  padding: var(--space-2) var(--gutter);
  max-width: var(--container);
  list-style: none;
  overflow-x: auto;
  scrollbar-width: none;
}
.subnav ul::-webkit-scrollbar { display: none; }
.subnav a {
  display: block;
  padding: 0.4em 0.9em;
  border-radius: 999px;
  font-size: var(--fs-sm);
  font-weight: 500;
  color: var(--lapis);
  text-decoration: none;
  white-space: nowrap;
}
.subnav a:hover { background: rgba(201, 162, 75, 0.15); color: var(--lapis); }

/* ---------- 17. Prose & info blocks ---------- */
.prose { max-width: 68ch; }
.prose h3 { margin-top: var(--space-6); }
.prose ul, .prose ol { padding-inline-start: 1.25em; margin: 0 0 var(--space-4); }
.prose li { margin-bottom: var(--space-2); }
.prose li::marker { color: var(--gold-text); }

.callout {
  padding: var(--space-5) var(--space-6);
  border-inline-start: 3px solid var(--gold);
  background: rgba(230, 211, 163, 0.25);
  border-radius: 0 var(--radius) var(--radius) 0;
}
.callout > :last-child { margin-bottom: 0; }

.scripture {
  margin: 0;
  font-family: var(--font-display);
  font-size: var(--fs-lg);
  font-style: italic;
  line-height: 1.5;
  color: var(--lapis);
  text-align: center;
}
.scripture cite {
  display: block;
  margin-top: var(--space-3);
  font-family: var(--font-body);
  font-size: var(--fs-xs);
  font-style: normal;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold-text);
}
.section--lapis .scripture { color: var(--ivory); }
.section--lapis .scripture cite { color: var(--gold); }

.meta-list { margin: 0; display: grid; gap: var(--space-2); font-size: var(--fs-sm); }
.meta-list div { display: flex; gap: var(--space-3); }
.meta-list dt { min-width: 4.5em; font-weight: 600; color: var(--lapis); }
.meta-list dd { margin: 0; color: var(--muted); }

.stack > * + * { margin-top: var(--space-5); }

/* ---------- 18. Schedule table ---------- */
.schedule { width: 100%; border-collapse: collapse; font-size: var(--fs-sm); }
.schedule caption { text-align: start; padding-bottom: var(--space-3); color: var(--muted); }
.schedule th, .schedule td { padding: var(--space-4); text-align: start; vertical-align: top; }
.schedule thead th {
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold-text);
  border-bottom: 1px solid var(--hairline);
}
.schedule tbody tr { border-bottom: 1px solid var(--hairline-soft); }
.schedule tbody th { font-family: var(--font-display); font-size: 1.2rem; font-weight: 600; color: var(--lapis); }
.schedule .when { font-weight: 600; white-space: nowrap; }
@media (max-width: 699px) {
  .schedule thead { display: none; }
  .schedule tr { display: grid; padding: var(--space-3) 0; }
  .schedule th, .schedule td { padding: var(--space-1) 0; }
  .schedule td[data-label]::before {
    content: attr(data-label) ": ";
    font-weight: 600;
    color: var(--gold-text);
  }
}

/* ---------- 19. FAQ (details/summary) ---------- */
.faq { border-top: 1px solid var(--hairline); }
.faq details { border-bottom: 1px solid var(--hairline); }
.faq summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--space-4);
  padding: var(--space-4) 0;
  font-family: var(--font-display);
  font-size: 1.3rem;
  font-weight: 600;
  color: var(--lapis);
  cursor: pointer;
  list-style: none;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+";
  flex: none;
  display: grid; place-items: center;
  width: 30px; height: 30px;
  border: 1px solid var(--hairline);
  border-radius: 50%;
  font-family: var(--font-body);
  font-size: 1.1rem;
  font-weight: 400;
  color: var(--gold-text);
  transition: transform 0.25s var(--ease);
}
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details > div { padding-bottom: var(--space-5); color: var(--muted); }
.faq details > div > :last-child { margin-bottom: 0; }

/* ---------- 20. Filter chips ---------- */
.chips {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-2);
  margin-bottom: var(--space-6);
}
.chip {
  min-height: 40px;
  padding: 0 1.1em;
  border: 1px solid var(--hairline);
  border-radius: 999px;
  background: var(--ivory);
  color: var(--lapis);
  font: 500 var(--fs-sm) / 1 var(--font-body);
  cursor: pointer;
}
.chip:hover { border-color: var(--gold); }
.chip[aria-pressed="true"] { background: var(--lapis); border-color: var(--lapis); color: var(--ivory); }

/* ---------- 21. Live stream box ---------- */
.stream {
  position: relative;
  display: grid;
  place-items: center;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(201, 162, 75, 0.45);
  background: url("../images/placeholder-lapis.svg") center / cover, var(--night);
  text-align: center;
  color: var(--ivory);
  text-decoration: none;
}
.stream-inner { display: grid; justify-items: center; gap: var(--space-3); padding: var(--space-5); }
.stream .play-btn {
  display: grid; place-items: center;
  width: 72px; height: 72px;
  border-radius: 50%;
  background: rgba(10, 28, 51, 0.65);
  border: 1px solid var(--gold-soft);
}
.stream .play-btn svg { width: 26px; height: 26px; fill: currentColor; margin-inline-start: 4px; }
.stream:hover { color: var(--ivory); }
.stream:hover .play-btn { background: var(--gold); color: var(--night); }
.stream-label { font-family: var(--font-display); font-size: var(--fs-lg); }

/* ---------- 22. Calendar ---------- */
.cal-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  margin-bottom: var(--space-5);
}
.cal-toolbar h3 { margin: 0; font-size: var(--fs-xl); }
.cal-nav { display: flex; align-items: center; gap: var(--space-2); }
.view-toggle { display: none; }
@media (min-width: 760px) { .view-toggle { display: inline-flex; } }

.cal-grid { display: none; }
.cal-list { display: grid; gap: var(--space-3); list-style: none; margin: 0; padding: 0; }

@media (min-width: 760px) {
  .cal[data-view="month"] .cal-grid { display: grid; }
  .cal[data-view="month"] .cal-list { display: none; }
}

.cal-grid {
  grid-template-columns: repeat(7, 1fr);
  border-top: 1px solid var(--hairline-soft);
  border-inline-start: 1px solid var(--hairline-soft);
  background: var(--ivory);
  border-radius: var(--radius);
  overflow: hidden;
}
.cal-head, .cal-day {
  border-bottom: 1px solid var(--hairline-soft);
  border-inline-end: 1px solid var(--hairline-soft);
}
.cal-head {
  padding: var(--space-2);
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-align: center;
  color: var(--gold-text);
  background: var(--parchment);
}
.cal-day { min-height: 112px; padding: var(--space-2); font-size: 0.72rem; }
.cal-day.is-empty { background: rgba(247, 241, 229, 0.5); }
.cal-day.is-today { box-shadow: inset 0 0 0 2px var(--gold); }
.cal-num { display: block; margin-bottom: var(--space-1); font-weight: 600; color: var(--lapis); }
.cal-ev {
  display: block;
  margin-bottom: 3px;
  padding: 2px 6px;
  border-radius: 4px;
  background: rgba(15, 42, 74, 0.08);
  color: var(--lapis);
  line-height: 1.35;
}
.cal-ev--special { background: var(--lapis); color: var(--ivory); }
.cal-ev--feast { background: rgba(142, 42, 42, 0.12); color: var(--red); font-weight: 600; }

.cal-list .event { background: var(--ivory); }
.cal-legend { display: flex; flex-wrap: wrap; gap: var(--space-4); margin-top: var(--space-4); font-size: var(--fs-xs); color: var(--muted); }
.cal-legend .cal-ev { display: inline-block; margin: 0 var(--space-1) 0 0; }

/* ---------- 23. Timeline (Our Roots) ---------- */
.timeline {
  position: relative;
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(250px, 300px);
  gap: var(--space-5);
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-padding-inline: var(--gutter);
  padding: var(--space-6) var(--gutter) var(--space-5);
  margin: 0 calc(-1 * var(--gutter));
  list-style: none;
  scrollbar-color: var(--gold) transparent;
}
.tl-item { position: relative; scroll-snap-align: start; padding-top: var(--space-6); }
/* Each item draws its own stretch of the line, so it runs the full scroll width */
.tl-item::after {
  content: "";
  position: absolute;
  top: 11px;
  inset-inline-start: 0;
  width: calc(100% + var(--space-5));
  height: 1px;
  background: var(--hairline);
}
.tl-item:last-child::after { width: 100%; background: linear-gradient(90deg, var(--hairline), transparent); }
.tl-item::before {
  content: "";
  position: absolute;
  z-index: 1;
  top: 5px;
  inset-inline-start: 0;
  width: 13px; height: 13px;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 0 4px var(--lapis), 0 0 0 5px var(--hairline);
}
.tl-year {
  display: block;
  font-family: var(--font-display);
  font-size: var(--fs-xl);
  font-weight: 600;
  color: var(--gold);
  line-height: 1;
  margin-bottom: var(--space-2);
}
.tl-item h3 { font-size: 1.3rem; margin-bottom: var(--space-2); }
.tl-item p { color: var(--on-dark-muted); font-size: var(--fs-sm); margin: 0; }
.tl-item--now .tl-year { color: var(--ivory); }
.tl-item--now::before { background: var(--ivory); }
.tl-hint { font-size: var(--fs-xs); color: var(--on-dark-muted); text-align: center; margin-top: var(--space-3); }

/* ---------- 24. Ministries ---------- */
.ministry .card-icon { margin-bottom: var(--space-3); }
.ministry .meta-list { margin: var(--space-3) 0 var(--space-4); }
.ministry h3 { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-2); }

/* ---------- 25. Numbered cards (sacraments etc.) ---------- */
.numbered { counter-reset: num; }
.numbered .card { padding-top: var(--space-7); }
.numbered .card::after {
  counter-increment: num;
  content: counter(num, upper-roman);
  position: absolute;
  top: var(--space-5);
  inset-inline-start: var(--space-6);
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--gold-text);
  letter-spacing: 0.1em;
}

/* Coptic months table */
.months { width: 100%; border-collapse: collapse; font-size: var(--fs-sm); }
.months th, .months td { padding: var(--space-2) var(--space-3); border-bottom: 1px solid var(--hairline-soft); text-align: start; }
.months thead th { font-size: var(--fs-xs); letter-spacing: 0.14em; text-transform: uppercase; color: var(--gold-text); border-bottom-color: var(--hairline); }
.months td:first-child { font-family: var(--font-display); font-size: 1.1rem; font-weight: 600; color: var(--lapis); width: 2.5em; }
.months td:nth-child(3) { font-family: var(--font-coptic); color: var(--gold-text); }

/* Agpeya hours */
.hours { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--space-3); }
@media (min-width: 700px) { .hours { grid-template-columns: repeat(2, 1fr); } }
.hours li {
  display: grid;
  grid-template-columns: 4.5rem 1fr;
  gap: var(--space-3);
  padding: var(--space-4);
  border: 1px solid rgba(201, 162, 75, 0.3);
  border-radius: var(--radius);
}
.hours .hour-time { font-family: var(--font-display); font-size: 1.1rem; color: var(--gold); line-height: 1.2; }
.hours h3 { font-size: 1.2rem; margin-bottom: 2px; }
.hours p { margin: 0; font-size: var(--fs-sm); color: var(--on-dark-muted); }

/* ---------- 26. Giving ---------- */
.give-hero-panel {
  display: grid;
  gap: var(--space-6);
  padding: clamp(1.5rem, 1rem + 3vw, 3.5rem);
  border: 1px solid var(--hairline);
  border-radius: var(--radius-lg);
  background: radial-gradient(ellipse at 50% 0%, rgba(230, 211, 163, 0.35), transparent 70%), var(--ivory);
  text-align: center;
}
.give-hero-panel .btn { justify-self: center; }
.btn--lg { min-height: 56px; padding-inline: 2.2em; font-size: var(--fs-base); }

.fund { text-align: center; align-items: center; }
.fund .card-icon { margin-inline: auto; }
.fund-amounts { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--space-2); margin-bottom: var(--space-4); }
.fund-amounts span {
  padding: 0.25em 0.8em;
  border: 1px solid var(--hairline-soft);
  border-radius: 999px;
  font-size: var(--fs-xs);
  color: var(--muted);
}

.ways { display: grid; gap: var(--space-5); }
@media (min-width: 900px) { .ways { grid-template-columns: repeat(3, 1fr); } }
.qr { width: 160px; height: 160px; margin: 0 auto var(--space-4); border-radius: var(--radius); }
.big-number {
  font-family: var(--font-display);
  font-size: var(--fs-xl);
  font-weight: 600;
  color: var(--lapis);
  line-height: 1.2;
  margin-bottom: var(--space-2);
}

/* ---------- 27. Forms (contact, prayer, appointment) ---------- */
.form-card { padding: clamp(1.25rem, 1rem + 2vw, 2.5rem); }
.form-grid { display: grid; gap: var(--space-4); }
@media (min-width: 640px) {
  .form-grid { grid-template-columns: 1fr 1fr; }
  .field--full { grid-column: 1 / -1; }
}
textarea.input { min-height: 130px; resize: vertical; }
select.input { appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--lapis) 50%), linear-gradient(135deg, var(--lapis) 50%, transparent 50%); background-position: calc(100% - 18px) 55%, calc(100% - 13px) 55%; background-size: 5px 5px; background-repeat: no-repeat; padding-inline-end: 2.2em; }
.check { display: flex; gap: var(--space-2); align-items: flex-start; font-size: var(--fs-sm); }
.check input { width: 18px; height: 18px; margin-top: 0.2em; accent-color: var(--lapis); flex: none; }
.req { color: var(--red); }
.form-actions { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-3); }
.form-card .form-note { color: var(--red); font-weight: 500; }

/* ---------- 28. Map placeholder & contact details ---------- */
.map {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 320px;
  height: 100%;
  overflow: hidden;
  border-radius: var(--radius-lg);
  border: 1px solid var(--hairline);
  background-color: #EFE6D2;
  background-image:
    linear-gradient(rgba(15, 42, 74, 0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(15, 42, 74, 0.06) 1px, transparent 1px),
    linear-gradient(115deg, transparent 46%, rgba(255, 253, 248, 0.9) 46%, rgba(255, 253, 248, 0.9) 50%, transparent 50%),
    linear-gradient(15deg, transparent 60%, rgba(255, 253, 248, 0.9) 60%, rgba(255, 253, 248, 0.9) 62.5%, transparent 62.5%);
  background-size: 32px 32px, 32px 32px, 100% 100%, 100% 100%;
  text-align: center;
}
.map-pin { display: grid; justify-items: center; gap: var(--space-2); padding: var(--space-5); }
.map-pin svg { width: 44px; height: 44px; fill: var(--red); filter: drop-shadow(0 4px 6px rgba(10, 28, 51, 0.25)); }
.map-pin strong { font-family: var(--font-display); font-size: var(--fs-lg); color: var(--lapis); }

.contact-list { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--space-4); }
.contact-list li { display: grid; grid-template-columns: 44px 1fr; gap: var(--space-3); align-items: start; }
.contact-list .card-icon { width: 44px; height: 44px; margin: 0; }
.contact-list .card-icon svg { width: 18px; height: 18px; fill: var(--gold-text); }
.contact-list strong { display: block; color: var(--lapis); }

/* Light cards placed on lapis sections keep dark, readable text */
.card { color: var(--ink); }
.card--dark { color: var(--on-dark); }
.section--lapis .card:not(.card--dark) h2,
.section--lapis .card:not(.card--dark) h3 { color: var(--lapis); }
.section--lapis .card:not(.card--dark) .tbd { color: var(--red); background: rgba(142, 42, 42, 0.05); }
.section--lapis .card:not(.card--dark) a:not(.btn) { color: var(--lapis); }

/* Drawer: the Give button keeps its button colors */
.nav-extra .btn { justify-self: start; }
.nav-extra a.btn { color: var(--night); }

/* ---------- 29. Mockup toast (explains placeholder buttons) ---------- */
.toast {
  position: fixed;
  left: 50%;
  bottom: var(--space-5);
  z-index: 300;
  width: min(92vw, 460px);
  padding: var(--space-4) var(--space-5);
  border: 1px solid var(--gold);
  border-radius: var(--radius-lg);
  background: var(--night);
  color: var(--ivory);
  font-size: var(--fs-sm);
  box-shadow: var(--shadow-md);
  transform: translate(-50%, 150%);
  opacity: 0;
  transition: transform 0.35s var(--ease), opacity 0.35s var(--ease);
}
.toast.is-shown { transform: translate(-50%, 0); opacity: 1; }
.toast strong { color: var(--gold); letter-spacing: 0.08em; text-transform: uppercase; font-size: var(--fs-xs); display: block; margin-bottom: 2px; }
.card--dark .meta-list dt { color: var(--gold-soft); }
.card--dark .meta-list dd { color: var(--on-dark-muted); }

/* ==========================================================================
   PHASE 3 — Interactive features
   ========================================================================== */

/* Fasting banner is hidden by JS when no fast is active */
.fast-banner[hidden] { display: none; }

/* Sermon filter */
.filter-status { text-align: center; font-size: var(--fs-sm); color: var(--muted); margin: calc(-1 * var(--space-4)) 0 var(--space-5); min-height: 1.5em; }
[data-filter-items] > [hidden] { display: none; }

/* Timeline controls */
.tl-controls {
  display: flex;
  align-items: center;
  gap: var(--space-4);
  max-width: 520px;
  margin: 0 auto;
}
.tl-btn {
  flex: none;
  width: 44px; height: 44px;
  display: grid; place-items: center;
  border: 1px solid rgba(230, 211, 163, 0.5);
  border-radius: 50%;
  background: transparent;
  color: var(--ivory);
  font-size: 1.1rem;
  cursor: pointer;
}
.tl-btn:hover:not(:disabled) { background: var(--gold); border-color: var(--gold); color: var(--night); }
.tl-btn:disabled { opacity: 0.35; cursor: default; }
.tl-progress { flex: 1; height: 2px; background: rgba(201, 162, 75, 0.25); border-radius: 2px; overflow: hidden; }
.tl-progress span { display: block; height: 100%; width: 10%; background: var(--gold); transition: width 0.3s var(--ease); }
.js .tl-item { opacity: 0.55; transition: opacity 0.35s var(--ease); }
.tl-item.is-active { opacity: 1; }
.tl-item.is-active::before { background: var(--ivory); box-shadow: 0 0 0 4px var(--lapis), 0 0 0 6px var(--gold); }
.timeline:focus-visible { outline-offset: -2px; }

/* ---------- Arabic / right-to-left ---------- */
html[lang="ar"] body,
html[lang="ar"] .btn,
html[lang="ar"] .input,
html[lang="ar"] .chip,
html[lang="ar"] .lang-toggle button { font-family: var(--font-arabic); }
html[lang="ar"] h1, html[lang="ar"] h2, html[lang="ar"] h3, html[lang="ar"] h4,
html[lang="ar"] .brand-name, html[lang="ar"] .scripture,
html[lang="ar"] .today-greg, html[lang="ar"] .today-coptic, html[lang="ar"] .tl-year,
html[lang="ar"] .service-time, html[lang="ar"] .nav-list a { font-family: var(--font-arabic); font-style: normal; }
html[lang="ar"] body { line-height: 1.85; }
html[lang="ar"] .eyebrow,
html[lang="ar"] .brand-sub,
html[lang="ar"] .service-day,
html[lang="ar"] .tag,
html[lang="ar"] .site-footer h2,
html[lang="ar"] .schedule thead th,
html[lang="ar"] .cal-head,
html[lang="ar"] .mockup-ribbon { letter-spacing: 0; text-transform: none; }
html[lang="ar"] .eyebrow { font-size: var(--fs-sm); }


/* Mirror direction-dependent pieces */
[dir="rtl"] .site-nav { right: auto; left: 0; transform: translateX(-100%); }
[dir="rtl"] .nav-open .site-nav { transform: none; }
@media (min-width: 1100px) { [dir="rtl"] .site-nav { transform: none; } }
[dir="rtl"] .link-arrow::after { content: "←"; }
[dir="rtl"] .link-arrow:hover::after { transform: translateX(-3px); }
[dir="rtl"] .tl-btn { transform: scaleX(-1); }
[dir="rtl"] .skip-link { left: auto; right: var(--space-4); }
[dir="rtl"] .callout { border-radius: var(--radius) 0 0 var(--radius); }
[dir="rtl"] select.input { background-position: 13px 55%, 18px 55%; }
[dir="rtl"] .tl-item:last-child::after { background: linear-gradient(270deg, var(--hairline), transparent); }
[dir="rtl"] .cal-ev, [dir="rtl"] .event-date { direction: rtl; }
/* Phone numbers, emails and codes stay left-to-right inside Arabic text */
[dir="rtl"] a[href^="tel:"], [dir="rtl"] .big-number, [dir="rtl"] input[type="email"], [dir="rtl"] input[type="tel"] { direction: ltr; unicode-bidi: isolate; }

/* Notice shown while Arabic is on */
.ar-notice {
  background: var(--gold-soft);
  color: var(--night);
  font-size: var(--fs-sm);
  text-align: center;
  padding: var(--space-2) var(--gutter);
}
.ar-notice span { font-family: var(--font-body); font-size: var(--fs-xs); opacity: 0.8; }
html[lang="ar"] .verse-en { display: none; }  /* the Arabic verse is already shown */

/* Portrait on a white background (Fr. Domadious): shrink it slightly so the
   whole figure sits inside the arch, anchored to the bottom edge */
.photo--cutout { background: #fff; }
.photo--cutout img {
  object-fit: contain;
  object-position: center bottom;
  padding: 9% 7% 0;
}
.photo--cutout.is-placeholder { background: linear-gradient(160deg, var(--lapis), var(--night)); }
.photo--cutout.is-placeholder img { padding: 0; object-fit: cover; }

/* Real YouTube thumbnails carry their own title text: keep the play button
   small and in the corner so it doesn't cover it */
.video-card .play { place-items: end start; padding: var(--space-3); }
.video-card .play span { width: 44px; height: 44px; }
.video-card .play svg { width: 16px; height: 16px; }

/* Calendar with the real weekly schedule */
.cal-ev b { font-weight: 700; }
.cal-list .event { align-items: start; }
.cal-list .event h3 { margin-bottom: var(--space-1); }
.cal-line { margin: 0 0 2px; font-size: var(--fs-sm); color: var(--muted); }
.cal-line strong { color: var(--ink); font-weight: 600; }
.cal-line span { white-space: nowrap; }
.cal-line span::before { content: "· "; }
.cal-list .event.is-today { border-color: var(--gold); box-shadow: inset 0 0 0 1px var(--gold); }
.cal-nav h3 { min-width: 9.5em; text-align: center; }

/* Today in the Coptic Church: live saints & readings */
.today-item ul.saints { list-style: none; margin: 0 0 var(--space-2); padding: 0; }
.today-item ul.saints li { padding: 2px 0; font-size: var(--fs-md); }
.today-item ul.saints a { color: var(--lapis); font-family: var(--font-display); font-size: 1.15rem; font-weight: 600; text-decoration-color: var(--hairline); }
.today-item ul.saints a:hover { color: var(--red); }
.today-item li em { font-style: normal; color: var(--ink); }
.today-link { margin-top: var(--space-3); }

/* Real giving QR code (not perfectly square): keep its shape, readable size */
.qr { width: 200px; height: auto; border-radius: var(--radius); }

/* Footer: "Join Our Community" button (replaces the newsletter sign-up) */
.footer-join { align-self: start; }
@media (min-width: 1100px) { .footer-join { margin-top: 2.1rem; } }
