/* ==========================================================================
   Ashoorkhana Naale Hyder & Masjid e Mehtab Ali Shah — design system
   Palette drawn from the complex itself: night sky over the courtyard,
   the turquoise limewash of the walls, gold zari of the Waqf seal.
   Signature motif: the cusped (scalloped) Deccan arch of the facade.
   ========================================================================== */

:root {
  /* Core palette */
  --night: #0d2b2e;          /* night teal: heroes, footer, bands */
  --night-2: #123a3e;
  --night-3: #184a4e;
  --limewash: #f1f5f2;       /* cool whitewash: page background */
  --limewash-2: #e3ece8;     /* alternate sections */
  --firoza: #1f6f6b;         /* turquoise limewash, deepened for text contrast */
  --firoza-soft: #8fd0c9;    /* turquoise as seen on the walls (on dark) */
  --zari: #c9a24d;           /* gold of the seal */
  --zari-deep: #84661f;      /* gold for text on light */
  --zari-soft: #e8d39a;

  /* Semantic (light) */
  --bg: var(--limewash);
  --bg-alt: var(--limewash-2);
  --surface: #ffffff;
  --ink: #16302f;
  --ink-strong: #0c2224;
  --muted: #4c6462;
  --line: rgba(13, 43, 46, 0.12);
  --line-strong: rgba(13, 43, 46, 0.22);
  --link: var(--firoza);
  --accent-text: var(--zari-deep);
  --shadow: 0 18px 40px -24px rgba(13, 43, 46, 0.35);

  /* On-night colours (constant in both themes) */
  --on-night: #eef4f1;
  --on-night-muted: rgba(238, 244, 241, 0.72);
  --on-night-line: rgba(238, 244, 241, 0.16);

  /* Type */
  --font-display: "Marcellus", "Iowan Old Style", Georgia, serif;
  --font-body: "Figtree", "Segoe UI", system-ui, -apple-system, sans-serif;
  --font-arabic: "Amiri", "Traditional Arabic", serif;

  /* Radii: images 14, panels 18, controls 8 */
  --r-img: 14px;
  --r-panel: 18px;
  --r-ctl: 8px;

  --nav-h: 76px;
  --arch-clip: polygon(6.00% 100.00%, 6.00% 53.23%, 5.57% 52.52%, 5.16% 51.80%, 4.79% 51.08%, 4.46% 50.35%, 4.18% 49.61%, 3.97% 48.87%, 3.82% 48.13%, 3.75% 47.38%, 3.76% 46.65%, 3.85% 45.92%, 4.02% 45.20%, 4.27% 44.49%, 4.60% 43.79%, 5.00% 43.11%, 5.46% 42.45%, 5.99% 41.80%, 6.56% 41.17%, 7.17% 40.56%, 7.82% 39.97%, 8.48% 39.39%, 8.31% 38.61%, 8.17% 37.83%, 8.07% 37.05%, 8.01% 36.28%, 8.00% 35.51%, 8.06% 34.75%, 8.18% 34.00%, 8.37% 33.27%, 8.64% 32.57%, 8.98% 31.89%, 9.40% 31.23%, 9.89% 30.61%, 10.45% 30.02%, 11.07% 29.45%, 11.75% 28.92%, 12.48% 28.42%, 13.25% 27.94%, 14.05% 27.50%, 14.88% 27.07%, 15.72% 26.66%, 15.83% 25.88%, 15.97% 25.10%, 16.14% 24.33%, 16.36% 23.57%, 16.62% 22.83%, 16.94% 22.11%, 17.32% 21.42%, 17.76% 20.77%, 18.27% 20.15%, 18.83% 19.58%, 19.46% 19.04%, 20.15% 18.55%, 20.89% 18.11%, 21.69% 17.71%, 22.53% 17.35%, 23.40% 17.03%, 24.31% 16.75%, 25.24% 16.50%, 26.18% 16.28%, 27.13% 16.07%, 27.51% 15.35%, 27.92% 14.63%, 28.36% 13.93%, 28.83% 13.25%, 29.35% 12.60%, 29.90% 11.98%, 30.51% 11.41%, 31.16% 10.88%, 31.86% 10.40%, 32.61% 9.97%, 33.40% 9.60%, 34.23% 9.29%, 35.10% 9.03%, 36.01% 8.82%, 36.94% 8.67%, 37.89% 8.56%, 38.86% 8.49%, 39.84% 8.46%, 40.82% 8.46%, 41.80% 8.47%, 42.42% 7.87%, 43.07% 7.27%, 43.73% 6.69%, 44.43% 6.15%, 45.15% 5.64%, 45.90% 5.17%, 46.68% 4.76%, 47.49% 4.40%, 48.33% 4.09%, 49.20% 3.85%, 51.67% 4.09%, 52.51% 4.40%, 53.32% 4.76%, 54.10% 5.17%, 54.85% 5.64%, 55.57% 6.15%, 56.27% 6.69%, 56.93% 7.27%, 57.58% 7.87%, 58.20% 8.47%, 59.18% 8.46%, 60.16% 8.46%, 61.14% 8.49%, 62.11% 8.56%, 63.06% 8.67%, 63.99% 8.82%, 64.90% 9.03%, 65.77% 9.29%, 66.60% 9.60%, 67.39% 9.97%, 68.14% 10.40%, 68.84% 10.88%, 69.49% 11.41%, 70.10% 11.98%, 70.65% 12.60%, 71.17% 13.25%, 71.64% 13.93%, 72.08% 14.63%, 72.49% 15.35%, 72.87% 16.07%, 73.82% 16.28%, 74.76% 16.50%, 75.69% 16.75%, 76.60% 17.03%, 77.47% 17.35%, 78.31% 17.71%, 79.11% 18.11%, 79.85% 18.55%, 80.54% 19.04%, 81.17% 19.58%, 81.73% 20.15%, 82.24% 20.77%, 82.68% 21.42%, 83.06% 22.11%, 83.38% 22.83%, 83.64% 23.57%, 83.86% 24.33%, 84.03% 25.10%, 84.17% 25.88%, 84.28% 26.66%, 85.12% 27.07%, 85.95% 27.50%, 86.75% 27.94%, 87.52% 28.42%, 88.25% 28.92%, 88.93% 29.45%, 89.55% 30.02%, 90.11% 30.61%, 90.60% 31.23%, 91.02% 31.89%, 91.36% 32.57%, 91.63% 33.27%, 91.82% 34.00%, 91.94% 34.75%, 92.00% 35.51%, 91.99% 36.28%, 91.93% 37.05%, 91.83% 37.83%, 91.69% 38.61%, 91.52% 39.39%, 92.18% 39.97%, 92.83% 40.56%, 93.44% 41.17%, 94.01% 41.80%, 94.54% 42.45%, 95.00% 43.11%, 95.40% 43.79%, 95.73% 44.49%, 95.98% 45.20%, 96.15% 45.92%, 96.24% 46.65%, 96.25% 47.38%, 96.18% 48.13%, 96.03% 48.87%, 95.82% 49.61%, 95.54% 50.35%, 95.21% 51.08%, 94.84% 51.80%, 94.43% 52.52%, 94.00% 53.23%, 94.00% 100.00%);
  --jaali-gold: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='80' height='80' viewBox='0 0 80 80'%3E%3Cpath fill='none' stroke='%23C9A24D' stroke-width='1' d='M40 12 68 40 40 68 12 40Z M20 20H60V60H20Z M40 0V12M40 68V80M0 40H12M68 40H80M0 0 20 20M80 0 60 20M0 80 20 60M80 80 60 60'/%3E%3C/svg%3E");
  --jaali-firoza: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='80' height='80' viewBox='0 0 80 80'%3E%3Cpath fill='none' stroke='%231F6F6B' stroke-width='1' d='M40 12 68 40 40 68 12 40Z M20 20H60V60H20Z M40 0V12M40 68V80M0 40H12M68 40H80M0 0 20 20M80 0 60 20M0 80 20 60M80 80 60 60'/%3E%3C/svg%3E");

  color-scheme: light;
}

:root[data-theme="dark"] {
  --bg: #0b1517;
  --bg-alt: #101d1f;
  --surface: #14272a;
  --ink: #e3ede9;
  --ink-strong: #f4f8f6;
  --muted: #a3bbb7;
  --line: rgba(227, 237, 233, 0.12);
  --line-strong: rgba(227, 237, 233, 0.24);
  --link: var(--firoza-soft);
  --accent-text: #dcbf72;
  --shadow: 0 18px 40px -24px rgba(0, 0, 0, 0.7);
  --night: #0d2b2e;
  --night-2: #123a3e;
  color-scheme: dark;
}

/* ---------- Base ---------- */
html { scroll-padding-top: calc(var(--nav-h) + 16px); -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }

body {
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--ink);
  background: var(--bg);
  overflow-x: hidden;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, .display {
  font-family: var(--font-display);
  font-weight: 400;
  color: var(--ink-strong);
  line-height: 1.15;
  letter-spacing: 0.005em;
  margin: 0 0 0.6em;
}
h1 { font-size: clamp(2.4rem, 5vw, 4.25rem); }
h2 { font-size: clamp(1.9rem, 3.4vw, 2.85rem); }
h3 { font-size: clamp(1.3rem, 2vw, 1.6rem); }
h4 { font-size: 1.25rem; }
p { margin: 0 0 1em; }
.lede { font-size: 1.1875rem; color: var(--muted); max-width: 38em; }
.muted { color: var(--muted); }
.small-print { font-size: 0.875rem; color: var(--muted); }
strong, b { font-weight: 600; color: var(--ink-strong); }

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

:focus-visible { outline: 3px solid var(--zari); outline-offset: 3px; border-radius: 4px; }

.ar {
  font-family: var(--font-arabic);
  direction: rtl;
  unicode-bidi: isolate;
  line-height: 1.9;
}

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

.skip-link {
  position: absolute; left: 16px; top: -60px; z-index: 2000;
  background: var(--zari); color: var(--night); padding: 10px 16px; border-radius: var(--r-ctl);
  font-weight: 600; text-decoration: none;
}
.skip-link:focus { top: 12px; }

.container { --bs-gutter-x: 2rem; }
@media (max-width: 575.98px) { .container { --bs-gutter-x: 2rem; } }

/* ---------- Buttons ---------- */
.btn-a {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.6em;
  font-family: var(--font-body); font-weight: 600; font-size: 1rem; line-height: 1.2;
  padding: 0.9em 1.5em; border-radius: var(--r-ctl);
  border: 1px solid transparent; text-decoration: none; cursor: pointer;
  transition: background-color .2s ease, color .2s ease, border-color .2s ease, transform .2s ease;
}
.btn-a:active { transform: translateY(1px); }
.btn-a i { font-size: 0.95em; }
.btn-zari { background: var(--zari); color: var(--night); }
.btn-zari:hover { background: var(--zari-soft); color: var(--night); }
.btn-ghost { background: transparent; color: var(--on-night); border-color: var(--on-night-line); }
.btn-ghost:hover { border-color: var(--zari); color: var(--zari-soft); }
.btn-firoza { background: var(--firoza); color: #fff; }
.btn-firoza:hover { background: var(--night-3); color: #fff; }
:root[data-theme="dark"] .btn-firoza { background: var(--firoza-soft); color: var(--night); }
:root[data-theme="dark"] .btn-firoza:hover { background: #b3e1db; color: var(--night); }
.btn-line { background: transparent; color: var(--ink-strong); border-color: var(--line-strong); }
.btn-line:hover { border-color: var(--firoza); color: var(--firoza); }
:root[data-theme="dark"] .btn-line:hover { color: var(--firoza-soft); border-color: var(--firoza-soft); }
.btn-wa { background: #1f8f4e; color: #fff; }
.btn-wa:hover { background: #17733e; color: #fff; }
.btn-block { width: 100%; }
.btn-a[disabled] { opacity: .6; cursor: not-allowed; }

.text-link {
  font-weight: 600; color: var(--link); text-decoration: none;
  border-bottom: 1px solid currentColor; padding-bottom: 1px;
}
.text-link:hover { color: var(--ink-strong); }

/* ---------- Navigation ---------- */
.site-nav {
  position: fixed; inset: 0 0 auto 0; z-index: 1030;
  min-height: var(--nav-h);
  background: rgba(13, 43, 46, 0.55);
  -webkit-backdrop-filter: blur(14px) saturate(1.2);
  backdrop-filter: blur(14px) saturate(1.2);
  border-bottom: 1px solid transparent;
  transition: background-color .3s ease, border-color .3s ease;
}
.site-nav.is-scrolled { background: rgba(10, 33, 35, 0.94); border-bottom-color: var(--on-night-line); }
:root[data-theme="dark"] .site-nav.is-scrolled { background: rgba(6, 20, 22, 0.94); }
.site-nav .navbar { padding: 0; min-height: var(--nav-h); }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--on-night); }
.brand:hover { color: var(--on-night); }
.brand img { width: 48px; height: auto; flex: none; }
.brand-name { font-family: var(--font-display); font-size: 1.15rem; line-height: 1.1; display: block; }
.brand-sub { font-size: 0.78rem; color: var(--on-night-muted); display: block; margin-top: 2px; letter-spacing: .01em; }

.nav-links { gap: 4px; }
.nav-links .nav-link {
  color: var(--on-night-muted); font-weight: 500; font-size: 0.97rem;
  padding: 10px 12px !important; position: relative; border-radius: 6px;
}
.nav-links .nav-link:hover { color: var(--on-night); }
.nav-links .nav-link.active { color: var(--zari-soft); }
.nav-links .nav-link.active::after {
  content: ""; position: absolute; left: 50%; bottom: 2px; width: 6px; height: 6px;
  background: var(--zari); transform: translateX(-50%) rotate(45deg);
}
.nav-tools { display: flex; align-items: center; gap: 10px; }
.icon-btn {
  width: 42px; height: 42px; border-radius: 50%; display: inline-grid; place-items: center; align-items: center; justify-content: center;
  background: transparent; border: 1px solid var(--on-night-line); color: var(--on-night);
  cursor: pointer; transition: border-color .2s ease, color .2s ease;
}
.icon-btn:hover { border-color: var(--zari); color: var(--zari-soft); }
.nav-toggle { display: none; }
.site-nav .btn-a { padding: 0.7em 1.15em; }

@media (max-width: 1199.98px) {
  .nav-toggle { display: inline-grid; }
  .site-nav .navbar-collapse {
    background: rgba(10, 33, 35, 0.98); margin: 0 calc(var(--bs-gutter-x) * -.5);
    padding: 8px calc(var(--bs-gutter-x) * .5) 20px; border-top: 1px solid var(--on-night-line);
  }
  .nav-links .nav-link { padding: 12px 4px !important; font-size: 1.05rem; border-bottom: 1px solid var(--on-night-line); border-radius: 0; }
  .nav-links .nav-link.active::after { left: auto; right: 8px; top: 50%; bottom: auto; transform: translateY(-50%) rotate(45deg); }
  .nav-tools--menu { margin-top: 16px; }
}
@media (max-width: 420px) {
  .brand-sub { display: none; }
  .brand img { width: 42px; }
  .brand-name { font-size: 1.02rem; }
}

/* ---------- Night surfaces & jaali ---------- */
.night {
  position: relative; isolation: isolate;
  background: radial-gradient(120% 90% at 78% 8%, var(--night-3) 0%, var(--night-2) 38%, var(--night) 75%);
  color: var(--on-night);
}
.night h1, .night h2, .night h3, .night h4, .night strong { color: var(--on-night); }
.night p, .night .lede { color: var(--on-night-muted); }
.night a:not(.btn-a) { color: var(--zari-soft); }
.jaali::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background-image: var(--jaali-gold); background-size: 80px 80px; opacity: .11;
  -webkit-mask-image: linear-gradient(180deg, #000 0%, rgba(0,0,0,.5) 60%, transparent 100%);
  mask-image: linear-gradient(180deg, #000 0%, rgba(0,0,0,.5) 60%, transparent 100%);
}

/* Scalloped edge: a row of cusps where a night band meets the page.
   Colour = the neighbouring section (--bg by default, .edge--alt for --bg-alt). */
.edge {
  position: absolute; left: 0; right: 0; height: 16px; z-index: 2; pointer-events: none;
  background: var(--bg);
}
.edge--alt { background: var(--bg-alt); }
.edge--bottom {
  bottom: -1px;
  -webkit-mask: radial-gradient(circle at 50% 100%, #000 15.5px, transparent 16px) 0 0 / 32px 16px repeat-x;
  mask: radial-gradient(circle at 50% 100%, #000 15.5px, transparent 16px) 0 0 / 32px 16px repeat-x;
}
.edge--top {
  top: -1px;
  -webkit-mask: radial-gradient(circle at 50% 0, #000 15.5px, transparent 16px) 0 0 / 32px 16px repeat-x;
  mask: radial-gradient(circle at 50% 0, #000 15.5px, transparent 16px) 0 0 / 32px 16px repeat-x;
}

/* ---------- Cusped arch frame (signature) ---------- */
.arch {
  position: relative; aspect-ratio: 4 / 5; width: 100%;
}
.arch > img, .arch > .arch-fill {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  -webkit-clip-path: var(--arch-clip); clip-path: var(--arch-clip);
}
.arch > svg { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; }
.arch .arch-outer { fill: none; stroke: var(--zari); stroke-width: 1.25; opacity: .9; }
.arch .arch-inner { fill: none; stroke: var(--zari); stroke-width: 1.5; }
.arch-fill {
  background: var(--night-2); display: grid; place-items: center;
}
.arch-fill::before {
  content: ""; position: absolute; inset: 0; background-image: var(--jaali-gold); background-size: 56px 56px; opacity: .22;
}
.arch-fill i { position: relative; font-size: 2.4rem; color: var(--zari); margin-top: 18%; }
.arch--sm { max-width: 260px; }

/* ---------- Home hero ---------- */
.hero {
  min-height: 100svh;
  padding: calc(var(--nav-h) + clamp(32px, 6vw, 72px)) 0 0;
  display: flex; flex-direction: column;
}
.hero-grid { flex: 1; display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: clamp(32px, 6vw, 96px); align-items: center; }
.bismillah {
  font-family: var(--font-arabic); direction: rtl; font-size: clamp(1.6rem, 2.6vw, 2.2rem);
  color: var(--zari); margin: 0 0 18px; line-height: 1.6; text-align: left;
}
.hero h1 { font-size: clamp(2.6rem, 5.6vw, 4.8rem); line-height: 1.06; margin-bottom: 24px; max-width: 12em; }
.hero .lede { color: var(--on-night-muted); font-size: clamp(1.05rem, 1.4vw, 1.2rem); margin-bottom: 32px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.waqf-reg { margin-top: 28px; font-size: .9rem; color: var(--on-night-muted); display: flex; align-items: center; gap: 10px; }
.waqf-reg i { color: var(--zari); }
.hero-art { position: relative; justify-self: center; width: min(100%, 440px); }
.hero-art .arch { filter: drop-shadow(0 30px 60px rgba(0,0,0,.35)); }
.hero-art figcaption { margin-top: 14px; text-align: center; font-size: .85rem; color: var(--on-night-muted); }
.lantern {
  position: absolute; pointer-events: none; width: 10px; height: 10px; border-radius: 50%;
  background: radial-gradient(circle, #ffe7a8 0%, rgba(201,162,77,.6) 45%, transparent 70%);
  box-shadow: 0 0 22px 8px rgba(201,162,77,.25);
}

/* Hero load sequence — the one orchestrated moment */
@media (prefers-reduced-motion: no-preference) {
  .hero .reveal { opacity: 0; transform: translateY(14px); animation: rise .9s cubic-bezier(.2,.7,.2,1) forwards; }
  .hero .reveal:nth-child(2) { animation-delay: .12s; }
  .hero .reveal:nth-child(3) { animation-delay: .24s; }
  .hero .reveal:nth-child(4) { animation-delay: .36s; }
  .hero .reveal:nth-child(5) { animation-delay: .48s; }
  .hero-art .arch > img { animation: unveil 1.6s cubic-bezier(.2,.7,.2,1) .2s both; }
  .hero-art .arch > svg { animation: unveil 1.4s ease .5s both; }
  .lantern { animation: glow 5s ease-in-out infinite; }
  .lantern:nth-of-type(2) { animation-delay: 1.6s; }
  .lantern:nth-of-type(3) { animation-delay: 3.1s; }
}
@keyframes rise { to { opacity: 1; transform: none; } }
@keyframes unveil { from { opacity: 0; transform: scale(1.06); } to { opacity: 1; transform: none; } }
@keyframes glow { 0%, 100% { opacity: .35; transform: translateY(0); } 50% { opacity: 1; transform: translateY(-8px); } }

/* ---------- Prayer times ---------- */
.prayer {
  margin-top: clamp(40px, 6vw, 72px);
  padding: 0 0 46px;
}
.prayer-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 8px 24px; margin-bottom: 18px; }
.prayer-head h2 { font-size: 1.35rem; margin: 0; }
.prayer-meta { display: flex; flex-wrap: wrap; gap: 6px 20px; font-size: .92rem; color: var(--on-night-muted); }
.prayer-meta .hijri { color: var(--zari-soft); }
.prayer-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); border-top: 1px solid var(--on-night-line); }
.prayer-list li { padding: 14px 16px 6px; border-left: 1px solid var(--on-night-line); position: relative; }
.prayer-list li:first-child { border-left: 0; padding-left: 0; }
.prayer-name { display: block; font-size: .92rem; color: var(--on-night-muted); }
.prayer-time { display: block; font-family: var(--font-display); font-size: clamp(1.4rem, 2.2vw, 1.9rem); color: var(--on-night); line-height: 1.25; }
.prayer-list li.is-next .prayer-name, .prayer-list li.is-next .prayer-time { color: var(--zari); }
.prayer-list li.is-next::before {
  content: ""; position: absolute; top: -1px; left: 16px; right: 16px; height: 2px; background: var(--zari);
}
.prayer-list li:first-child.is-next::before { left: 0; }
.prayer-next { font-size: .95rem; color: var(--on-night); }
.prayer-next b { color: var(--zari-soft); font-weight: 600; }
.prayer-note { font-size: .82rem; color: var(--on-night-muted); margin: 10px 0 0; }
@media (max-width: 767.98px) {
  .prayer-list { grid-template-columns: repeat(3, minmax(0, 1fr)); row-gap: 0; border-top: 0; }
  .prayer-list li { border-top: 1px solid var(--on-night-line); }
  .prayer-list li { padding: 12px 12px 6px; }
  .prayer-list li:nth-child(3n+1) { border-left: 0; padding-left: 0; }
  .prayer-list li.is-next::before { top: -1px; left: 12px; right: 12px; }
  .prayer-list li:nth-child(3n+1).is-next::before { left: 0; }
}

/* ---------- Page hero (inner pages) ---------- */
.page-hero { padding: calc(var(--nav-h) + clamp(48px, 8vw, 104px)) 0 clamp(64px, 9vw, 112px); }
.page-hero h1 { max-width: 14em; }
.page-hero .lede { color: var(--on-night-muted); }
.page-hero .hero-actions { margin-top: 28px; }
.crumbs { display: flex; flex-wrap: wrap; gap: 8px; font-size: .9rem; margin-bottom: 18px; color: var(--on-night-muted); list-style: none; padding: 0; }
.crumbs a { color: var(--on-night-muted) !important; text-decoration: none; }
.crumbs a:hover { color: var(--zari-soft) !important; }
.crumbs li + li::before { content: "/"; margin-right: 8px; opacity: .5; }
.crumbs [aria-current] { color: var(--zari-soft); }
.page-hero-grid { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 48px; align-items: end; }
.page-hero-grid .arch { width: 220px; }
@media (max-width: 991.98px) { .page-hero-grid { grid-template-columns: 1fr; } .page-hero-grid .arch { display: none; } }
.article-meta { display: flex; flex-wrap: wrap; gap: 10px 24px; font-size: .95rem; color: var(--on-night-muted); margin-top: 8px; }
.article-meta i { color: var(--zari); margin-right: 6px; }

/* ---------- Sections ---------- */
.section { padding: clamp(64px, 9vw, 120px) 0; position: relative; }
.section--alt { background: var(--bg-alt); }
.section--tight { padding: clamp(48px, 6vw, 80px) 0; }
.section-head { max-width: 44rem; margin-bottom: clamp(32px, 5vw, 56px); }
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }
.section-head p { color: var(--muted); font-size: 1.125rem; margin: 0; }
.night .section-head p { color: var(--on-night-muted); }

.star-rule { display: flex; align-items: center; gap: 14px; color: var(--zari); margin: 0 auto 28px; max-width: 220px; }
.star-rule::before, .star-rule::after { content: ""; flex: 1; height: 1px; background: currentColor; opacity: .5; }
.star-rule svg { width: 18px; height: 18px; flex: none; }

/* ---------- Verse ---------- */
.verse { text-align: center; max-width: 52rem; margin: 0 auto; }
.verse .ar { font-size: clamp(1.8rem, 3.6vw, 2.8rem); color: var(--ink-strong); margin: 0 0 18px; }
.night .verse .ar { color: var(--zari-soft); }
.verse-en { font-family: var(--font-display); font-size: clamp(1.25rem, 2.1vw, 1.65rem); line-height: 1.45; color: var(--ink-strong); margin: 0 auto 14px; max-width: 34em; }
.night .verse-en { color: var(--on-night); }
.verse-ref { font-size: .95rem; color: var(--accent-text); }
.night .verse-ref { color: var(--zari); }
.verse-intro { color: var(--muted); max-width: 36em; margin: 0 auto 26px; }
.verse-title { font-size: clamp(1.4rem, 2.2vw, 1.8rem); margin-bottom: 10px; }
.night .verse-intro { color: var(--on-night-muted); }

.checks { list-style: none; padding: 0; margin: 20px 0 0; display: grid; gap: 10px; }
.checks li { display: flex; gap: 12px; align-items: baseline; color: var(--ink); }
.checks li::before { content: ""; flex: none; width: 8px; height: 8px; background: var(--zari); transform: translateY(-2px) rotate(45deg); }
.night .checks li { color: var(--on-night); }

.news-grid.news-grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 40px 32px; }
@media (max-width: 575.98px) { .news-grid.news-grid--2 { grid-template-columns: 1fr; } }

.map-frame { position: relative; }
.map-frame iframe { display: block; width: 100%; height: 440px; border: 0; }
.map-card { position: absolute; top: 20px; left: 50%; transform: translateX(-50%); width: min(440px, calc(100% - 32px)); display: flex; align-items: center; justify-content: space-between; gap: 16px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-panel); padding: 14px 18px; box-shadow: var(--shadow); }
.map-card strong { display: block; font-family: var(--font-display); font-weight: 400; font-size: 1.15rem; }
.map-card span { color: var(--muted); font-size: .9rem; }
.map-card .btn-a { padding: .65em 1em; font-size: .92rem; }

/* ---------- Media ---------- */
.photo { border-radius: var(--r-img); overflow: hidden; background: var(--bg-alt); margin: 0; }
.photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.photo figcaption, .caption { font-size: .88rem; color: var(--muted); margin-top: 10px; }
.ratio-wide { aspect-ratio: 21 / 9; }
.ratio-photo { aspect-ratio: 4 / 3; }
@media (max-width: 767.98px) { .ratio-wide { aspect-ratio: 4 / 3; } }

/* ---------- Complex legend (places) ---------- */
.legend { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); margin-top: 40px; }
.legend-item { padding: 6px 28px 6px 0; border-right: 1px solid var(--line); margin-right: 28px; }
.legend-item:last-child { border-right: 0; margin-right: 0; }
.legend-item h3 { font-size: 1.35rem; margin: 14px 0 8px; }
.legend-item p { color: var(--muted); font-size: .98rem; margin: 0; }
.motif {
  width: 46px; height: 46px; display: grid; place-items: center; color: var(--firoza);
  background: var(--jaali-firoza) center / 46px 46px; border-radius: 50%;
  box-shadow: inset 0 0 0 1px var(--line-strong);
  position: relative;
}
:root[data-theme="dark"] .motif { color: var(--firoza-soft); background-image: var(--jaali-gold); }
.motif i { background: var(--bg); padding: 6px; border-radius: 50%; font-size: 1rem; }
.section--alt .motif i { background: var(--bg-alt); }
@media (max-width: 991.98px) {
  .legend { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 32px; }
  .legend-item:nth-child(2n) { border-right: 0; margin-right: 0; }
}
@media (max-width: 575.98px) {
  .legend { grid-template-columns: 1fr; row-gap: 24px; }
  .legend-item { border-right: 0; margin-right: 0; padding-right: 0; display: grid; grid-template-columns: 46px 1fr; column-gap: 16px; }
  .legend-item h3 { margin-top: 2px; }
  .legend-item .motif { grid-row: span 2; }
  .legend-item p { grid-column: 2; }
}

/* ---------- Service list ---------- */
.service-list { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0 40px; list-style: none; padding: 0; margin: 0; }
.service-list li { display: grid; grid-template-columns: 40px 1fr; gap: 4px 16px; padding: 26px 0; border-top: 1px solid var(--line); }
.service-list i { color: var(--firoza); font-size: 1.35rem; margin-top: 4px; grid-row: span 2; }
:root[data-theme="dark"] .service-list i { color: var(--firoza-soft); }
.service-list h3 { font-size: 1.25rem; margin: 0; }
.service-list p { margin: 0; color: var(--muted); font-size: .98rem; }
@media (max-width: 991.98px) { .service-list { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 575.98px) { .service-list { grid-template-columns: 1fr; } }

/* ---------- Message from the Mutawalli ---------- */
.steward { display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: clamp(32px, 6vw, 80px); align-items: center; }
.steward blockquote { margin: 0; }
.steward blockquote p {
  font-family: var(--font-display); font-size: clamp(1.35rem, 2.4vw, 1.9rem); line-height: 1.45; color: var(--ink-strong);
}
.pull-quote { margin: 0; }
.pull-quote p { font-family: var(--font-display); font-size: clamp(1.3rem, 2.2vw, 1.75rem); line-height: 1.45; color: var(--ink-strong); margin: 0; }
.steward-name { font-weight: 600; color: var(--ink-strong); display: block; margin-top: 12px; }
.steward-role { color: var(--muted); }
@media (max-width: 767.98px) { .steward { grid-template-columns: 1fr; } .steward .arch { max-width: 220px; } }

/* ---------- Mosaic ---------- */
.mosaic { display: grid; grid-template-columns: 1.3fr 1fr 1fr; grid-template-rows: 260px 260px; gap: 16px; }
.mosaic > a { display: block; position: relative; border-radius: var(--r-img); overflow: hidden; background: var(--bg-alt); color: #fff; text-decoration: none; }
.mosaic > a:first-child { grid-row: span 2; }
.mosaic figure { margin: 0; height: 100%; }
.mosaic img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .6s ease; }
.mosaic a:hover img, .mosaic a:focus-visible img { transform: scale(1.04); }
.mosaic figcaption {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 40px 16px 14px; font-size: .92rem; color: #fff;
  background: linear-gradient(transparent, rgba(8, 26, 28, .82));
}
@media (max-width: 767.98px) {
  .mosaic { grid-template-columns: 1fr 1fr; grid-template-rows: 220px 160px 160px; }
  .mosaic > a:first-child { grid-column: span 2; grid-row: auto; }
}

/* ---------- Voices ---------- */
.voices { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 40px; }
.voice blockquote { margin: 0 0 18px; font-size: 1.02rem; color: var(--ink); }
.voice blockquote::before { content: "\201C"; display: block; font-family: var(--font-display); font-size: 3rem; line-height: .8; color: var(--zari); }
.voice figcaption { display: flex; align-items: center; gap: 12px; font-weight: 600; color: var(--ink-strong); font-size: .97rem; }
.voice img { width: 52px; height: 52px; border-radius: 50%; object-fit: cover; box-shadow: 0 0 0 2px var(--bg), 0 0 0 3px var(--zari); }
@media (max-width: 991.98px) { .voices { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 575.98px) { .voices { grid-template-columns: 1fr; gap: 32px; } }

/* ---------- Donate band ---------- */
.band { padding: clamp(64px, 9vw, 112px) 0; }
.band-grid { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, .8fr); gap: clamp(32px, 6vw, 80px); align-items: center; }
.bank-mini { border: 1px solid var(--on-night-line); border-radius: var(--r-panel); padding: 24px; }
.bank-mini dl { margin: 0 0 20px; display: grid; grid-template-columns: auto 1fr; gap: 8px 20px; font-size: .95rem; }
.bank-mini dt { color: var(--on-night-muted); font-weight: 400; }
.bank-mini dd { margin: 0; color: var(--on-night); font-weight: 600; word-break: break-word; }
@media (max-width: 991.98px) { .band-grid { grid-template-columns: 1fr; } }

/* ---------- Footer ---------- */
.site-footer { padding: clamp(72px, 9vw, 104px) 0 28px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.3fr; gap: 40px; }
.site-footer h2 { font-size: 1.15rem; margin-bottom: 16px; color: var(--on-night); }
.footer-links { list-style: none; margin: 0; padding: 0; }
.footer-links li { margin-bottom: 10px; }
.site-footer a { color: var(--on-night-muted) !important; text-decoration: none; }
.site-footer a:hover { color: var(--zari-soft) !important; }
.footer-about p { color: var(--on-night-muted); font-size: .97rem; max-width: 30em; }
.footer-contact li { display: flex; gap: 12px; margin-bottom: 12px; color: var(--on-night-muted); font-size: .97rem; }
.footer-contact i { color: var(--zari); margin-top: 5px; width: 16px; }
.socials { display: flex; gap: 10px; margin-top: 18px; }
.socials a { width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; border: 1px solid var(--on-night-line); }
.socials a:hover { border-color: var(--zari); }
.footer-base { margin-top: 56px; padding-top: 22px; border-top: 1px solid var(--on-night-line); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px; font-size: .88rem; color: var(--on-night-muted); }
.footer-base p { margin: 0; color: var(--on-night-muted); }
@media (max-width: 991.98px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 575.98px) { .footer-grid { grid-template-columns: 1fr; gap: 32px; } }

/* ---------- Panels, forms ---------- */
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-panel); padding: clamp(24px, 4vw, 40px); box-shadow: var(--shadow); }
.panel h2 { font-size: clamp(1.6rem, 2.6vw, 2.1rem); }
.field { margin-bottom: 18px; }
.field label, .field .label { display: block; font-weight: 600; font-size: .95rem; color: var(--ink-strong); margin-bottom: 6px; }
.field .hint { font-size: .85rem; color: var(--muted); margin-top: 6px; }
.input, .field input, .field select, .field textarea {
  width: 100%; font: inherit; font-size: 1rem; color: var(--ink);
  background: var(--bg); border: 1px solid var(--line-strong); border-radius: var(--r-ctl);
  padding: 12px 14px; transition: border-color .2s ease, box-shadow .2s ease;
}
.field textarea { min-height: 140px; resize: vertical; }
.input:focus, .field input:focus, .field select:focus, .field textarea:focus {
  outline: none; border-color: var(--firoza); box-shadow: 0 0 0 3px rgba(31, 111, 107, .2);
}
:root[data-theme="dark"] .input:focus, :root[data-theme="dark"] .field :is(input, select, textarea):focus { border-color: var(--firoza-soft); box-shadow: 0 0 0 3px rgba(143, 208, 201, .2); }
.field input:user-invalid, .field select:user-invalid, .field textarea:user-invalid { border-color: #b4472f; }
.form-legend { font-family: var(--font-display); font-size: 1.25rem; color: var(--ink-strong); padding-bottom: 10px; margin: 28px 0 18px; border-bottom: 1px solid var(--line); width: 100%; }
.form-legend:first-of-type { margin-top: 8px; }
fieldset { border: 0; padding: 0; margin: 0; min-width: 0; }
.form-note { display: flex; gap: 12px; font-size: .92rem; color: var(--muted); background: var(--bg-alt); border-radius: var(--r-ctl); padding: 14px 16px; margin-top: 16px; }
.form-note i { color: var(--firoza); margin-top: 4px; }
.form-success { text-align: center; padding: 32px 8px; }
.form-success i { font-size: 2.6rem; color: #1f8f4e; margin-bottom: 14px; }

/* Contact methods */
.contact-list { list-style: none; padding: 0; margin: 0; }
.contact-list li { display: grid; grid-template-columns: 48px 1fr; gap: 4px 18px; padding: 22px 0; border-top: 1px solid var(--line); }
.contact-list li:first-child { border-top: 0; padding-top: 0; }
.contact-list .motif { grid-row: span 3; }
.contact-list h3 { font-size: 1.2rem; margin: 0; }
.contact-list p { margin: 0; color: var(--muted); font-size: .97rem; }
.contact-list a.big { font-family: var(--font-display); font-size: 1.4rem; text-decoration: none; }

/* Bank details */
.bank { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 0; }
.bank-details { padding-right: clamp(24px, 4vw, 48px); border-right: 1px solid var(--line); }
.bank-qr { padding-left: clamp(24px, 4vw, 48px); text-align: center; }
.bank-row { padding: 14px 0; border-bottom: 1px solid var(--line); }
.bank-row:last-child { border-bottom: 0; }
.bank-row .k { display: block; font-size: .88rem; color: var(--muted); margin-bottom: 2px; }
.bank-row .v { display: flex; align-items: center; justify-content: space-between; gap: 12px; font-weight: 600; color: var(--ink-strong); font-size: 1.05rem; word-break: break-word; }
.bank-row .v.mono { font-variant-numeric: tabular-nums; letter-spacing: .04em; font-size: 1.2rem; }
.copy-btn { flex: none; display: inline-flex; align-items: center; gap: 6px; font: inherit; font-size: .85rem; font-weight: 600; color: var(--link); background: transparent; border: 1px solid var(--line-strong); border-radius: 6px; padding: 6px 10px; cursor: pointer; }
.copy-btn:hover { border-color: var(--firoza); }
.copy-btn.is-done { color: #1f8f4e; border-color: #1f8f4e; }
.qr-frame { display: inline-block; background: #fff; padding: 14px; border-radius: var(--r-img); border: 1px solid var(--line); }
.qr-frame img { width: 200px; height: 200px; object-fit: contain; display: block; image-rendering: pixelated; }
@media (max-width: 767.98px) {
  .bank { grid-template-columns: 1fr; }
  .bank-details { padding-right: 0; border-right: 0; border-bottom: 1px solid var(--line); padding-bottom: 24px; }
  .bank-qr { padding-left: 0; padding-top: 28px; }
}

/* ---------- Timeline ---------- */
.timeline { list-style: none; margin: 0; padding: 0; position: relative; }
.timeline::before { content: ""; position: absolute; left: 170px; top: 8px; bottom: 8px; width: 1px; background: var(--line-strong); }
.timeline li { display: grid; grid-template-columns: 170px minmax(0, 1fr); gap: 0 48px; padding: 0 0 44px; position: relative; }
.timeline li:last-child { padding-bottom: 0; }
.timeline li::before {
  content: ""; position: absolute; left: 170px; top: 12px; width: 11px; height: 11px; background: var(--zari);
  transform: translateX(-50%) rotate(45deg); box-shadow: 0 0 0 5px var(--bg);
}
.section--alt .timeline li::before { box-shadow: 0 0 0 5px var(--bg-alt); }
.t-date { font-family: var(--font-display); font-size: 1.2rem; color: var(--accent-text); padding-right: 24px; text-align: right; line-height: 1.35; }
.timeline h3 { font-size: 1.45rem; margin-bottom: 6px; }
.timeline .t-sub { font-weight: 600; color: var(--ink-strong); margin-bottom: 6px; }
.timeline p { color: var(--muted); margin: 0; max-width: 36em; }
.timeline .t-portrait { display: flex; gap: 18px; align-items: center; margin-top: 16px; }
.timeline .t-portrait img { width: 76px; height: 96px; object-fit: cover; border-radius: 8px; filter: sepia(.25); }
.timeline .t-portrait span { font-size: .9rem; color: var(--muted); }
@media (max-width: 767.98px) {
  .timeline::before { left: 5px; }
  .timeline li { grid-template-columns: 1fr; padding-left: 32px; }
  .timeline li::before { left: 5px; }
  .t-date { text-align: left; padding: 0 0 4px; font-size: 1.05rem; }
}
.timeline--compact::before { left: 5px; }
.timeline--compact li { grid-template-columns: 1fr; padding-left: 32px; padding-bottom: 30px; }
.timeline--compact li::before { left: 5px; }
.timeline--compact .t-date { text-align: left; padding: 0 0 2px; font-size: 1.05rem; }
.timeline--compact h3 { font-size: 1.2rem; }

/* ---------- Stats ---------- */
.facts { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.fact { padding: 24px 24px 22px; border-left: 1px solid var(--line); }
.fact:first-child { border-left: 0; padding-left: 0; }
.fact .num { font-family: var(--font-display); font-size: clamp(2rem, 3.6vw, 2.9rem); color: var(--ink-strong); line-height: 1.1; display: block; font-variant-numeric: tabular-nums; }
.fact .num small { font-size: .45em; color: var(--muted); font-family: var(--font-body); margin-left: 4px; }
.fact > span:last-child { color: var(--muted); font-size: .95rem; }
@media (max-width: 767.98px) {
  .facts { grid-template-columns: 1fr 1fr; }
  .fact:nth-child(3) { border-left: 0; padding-left: 0; }
  .fact:nth-child(n+3) { border-top: 1px solid var(--line); }
}

.survey { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-top: 24px; }
.survey div { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-panel); padding: 20px 22px; }
.survey h3 { font-size: 1.2rem; margin: 0 0 4px; }
.survey .area { font-family: var(--font-display); font-size: 1.5rem; color: var(--accent-text); display: block; }
.survey p { margin: 4px 0 0; color: var(--muted); font-size: .95rem; }
@media (max-width: 767.98px) { .survey { grid-template-columns: 1fr; } }

.map-btn { display: block; position: relative; border: 0; padding: 0; background: none; width: 100%; border-radius: var(--r-img); overflow: hidden; cursor: zoom-in; }
.map-btn img { width: 100%; max-height: 440px; object-fit: cover; object-position: top; display: block; }
.map-btn span { position: absolute; right: 14px; bottom: 14px; background: rgba(8,26,28,.85); color: #fff; padding: 8px 14px; border-radius: 6px; font-size: .9rem; }

/* ---------- Landmark grid (About) ---------- */
.landmarks { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 32px; }
.landmark .arch { margin-bottom: 18px; }
.landmark h3 { font-size: 1.35rem; margin-bottom: 6px; }
.landmark p { color: var(--muted); font-size: .98rem; margin: 0; }
@media (max-width: 991.98px) { .landmarks { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 575.98px) { .landmarks { grid-template-columns: 1fr 1fr; gap: 24px 16px; } .landmark h3 { font-size: 1.15rem; } .landmark p { font-size: .9rem; } }

/* Stewards */
.stewards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px; }
.stewards figure { margin: 0; }
.stewards .portrait { aspect-ratio: 4 / 5; border-radius: var(--r-img); overflow: hidden; background: var(--bg-alt); margin-bottom: 14px; }
.stewards .portrait img { width: 100%; height: 100%; object-fit: cover; object-position: top; }
.stewards .portrait.sepia img { filter: sepia(.3) contrast(1.05); }
.stewards figcaption strong { display: block; font-family: var(--font-display); font-weight: 400; font-size: 1.25rem; }
.stewards figcaption span { color: var(--muted); font-size: .95rem; }
@media (max-width: 767.98px) { .stewards { grid-template-columns: 1fr 1fr; gap: 20px; } .stewards figure:last-child { grid-column: span 2; max-width: 50%; } }

/* ---------- News ---------- */
.feature-story { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 0; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-panel); overflow: hidden; box-shadow: var(--shadow); }
.feature-story .photo { border-radius: 0; min-height: 320px; }
.feature-story .body { padding: clamp(24px, 4vw, 48px); display: flex; flex-direction: column; justify-content: center; }
.feature-story h3 { font-size: clamp(1.6rem, 2.6vw, 2.2rem); }
@media (max-width: 767.98px) { .feature-story { grid-template-columns: 1fr; } .feature-story .photo { min-height: 220px; aspect-ratio: 16/10; } }
.tag { display: inline-flex; align-items: center; gap: 8px; font-size: .88rem; font-weight: 600; color: var(--accent-text); margin-bottom: 10px; }
.tag::before { content: ""; width: 7px; height: 7px; background: currentColor; transform: rotate(45deg); }
.tag--legal { color: #a1402a; }
:root[data-theme="dark"] .tag--legal { color: #e58b74; }
.tag--community { color: var(--firoza); }
:root[data-theme="dark"] .tag--community { color: var(--firoza-soft); }
.date { font-size: .9rem; color: var(--muted); }

.filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 32px; }
.filter-btn { font: inherit; font-size: .95rem; font-weight: 500; padding: 8px 16px; border-radius: 999px; border: 1px solid var(--line-strong); background: transparent; color: var(--ink); cursor: pointer; }
.filter-btn:hover { border-color: var(--firoza); }
.filter-btn[aria-pressed="true"] { background: var(--night); color: var(--on-night); border-color: var(--night); }
:root[data-theme="dark"] .filter-btn[aria-pressed="true"] { background: var(--firoza-soft); color: var(--night); border-color: var(--firoza-soft); }

.news-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px; }
.news-card { display: flex; flex-direction: column; position: relative; }
.news-card .tag { margin-bottom: 2px; }
.card-link { font: inherit; color: inherit; background: none; border: 0; padding: 0; text-align: left; text-decoration: none; cursor: pointer; }
.card-link::after { content: ""; position: absolute; inset: 0; z-index: 1; border-radius: var(--r-img); }
.card-link:focus-visible { outline: none; }
.card-link:focus-visible::after { outline: 3px solid var(--zari); outline-offset: 6px; }
.news-card:hover h3 { color: var(--link); }
.news-card .photo { aspect-ratio: 16 / 10; margin-bottom: 16px; }
.news-card .photo img { transition: transform .6s ease; }
.news-card:hover .photo img, .news-card:focus-within .photo img { transform: scale(1.04); }
.news-card h3 { font-size: 1.35rem; margin: 2px 0 8px; color: var(--ink-strong); }
.news-card p { color: var(--muted); font-size: .98rem; margin: 0 0 12px; }
.news-card .more { font-weight: 600; color: var(--link); margin-top: auto; }
[data-category][hidden] { display: none; }
@media (max-width: 991.98px) { .news-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 575.98px) { .news-grid { grid-template-columns: 1fr; } }

/* Horizontal timeline gallery */
.strip-wrap { position: relative; }
.strip { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(240px, 300px); gap: 20px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 8px 2px 18px; scrollbar-width: thin; }
.strip a { scroll-snap-align: start; text-decoration: none; color: inherit; display: block; }
.strip .photo { aspect-ratio: 4 / 5; margin-bottom: 12px; }
.strip .photo img { transition: transform .6s ease; }
.strip a:hover .photo img, .strip a:focus-visible .photo img { transform: scale(1.04); }
.strip .when { font-family: var(--font-display); color: var(--accent-text); font-size: 1rem; }
.strip h3 { font-size: 1.15rem; margin: 2px 0 4px; }
.strip p { font-size: .92rem; color: var(--muted); margin: 0; }
.strip-nav { display: flex; gap: 8px; }
.strip-nav button { width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--line-strong); background: var(--surface); color: var(--ink); cursor: pointer; }
.strip-nav button:hover { border-color: var(--firoza); }

/* ---------- Article ---------- */
.prose { max-width: 42rem; margin: 0 auto; font-size: 1.125rem; line-height: 1.75; }
.prose p { margin-bottom: 1.3em; }
.prose blockquote { margin: 2em 0; padding: 0 0 0 24px; border-left: 2px solid var(--zari); }
.prose blockquote p { font-family: var(--font-display); font-size: 1.45rem; line-height: 1.45; color: var(--ink-strong); margin-bottom: .5em; }
.prose blockquote cite { font-style: normal; color: var(--muted); font-size: .95rem; }
.byline { display: flex; align-items: center; gap: 14px; max-width: 42rem; margin: 0 auto 36px; padding-bottom: 24px; border-bottom: 1px solid var(--line); }
.byline img { width: 52px; height: 52px; border-radius: 50%; object-fit: cover; }
.byline strong { display: block; }
.byline span { color: var(--muted); font-size: .92rem; }
.share { max-width: 42rem; margin: 40px auto 0; padding-top: 24px; border-top: 1px solid var(--line); display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; }
.share-links { display: flex; gap: 8px; }
.share-links a, .share-links button { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; border: 1px solid var(--line-strong); color: var(--ink); background: transparent; cursor: pointer; text-decoration: none; }
.share-links a:hover, .share-links button:hover { border-color: var(--firoza); color: var(--firoza); }
.pager { max-width: 42rem; margin: 32px auto 0; display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.pager a { display: block; padding: 18px 20px; border: 1px solid var(--line); border-radius: var(--r-panel); text-decoration: none; color: inherit; }
.pager a:hover { border-color: var(--firoza); }
.pager span { font-size: .88rem; color: var(--muted); display: block; }
.pager strong { font-family: var(--font-display); font-weight: 400; font-size: 1.1rem; }
.pager a:last-child { text-align: right; }
#reading-progress { position: fixed; top: 0; left: 0; height: 3px; width: 0; background: var(--zari); z-index: 1040; }
@media (max-width: 575.98px) { .pager { grid-template-columns: 1fr; } .pager a:last-child { text-align: left; } }

/* Legal / notice callout */
.callout { border-left: 3px solid var(--zari); background: var(--surface); border-radius: 0 var(--r-panel) var(--r-panel) 0; padding: 20px 24px; margin-bottom: 32px; }
.callout h3 { font-size: 1.2rem; margin-bottom: 6px; display: flex; gap: 10px; align-items: center; }
.callout h3 i { color: var(--zari); }
.callout p { margin: 0; color: var(--muted); }
mark.k { background: linear-gradient(transparent 62%, rgba(201,162,77,.35) 0); color: inherit; padding: 0 2px; }

/* Archive viewer */
.archive-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.archive-grid a { text-decoration: none; color: inherit; display: block; }
.archive-grid .photo { aspect-ratio: 3 / 4; margin-bottom: 12px; border: 1px solid var(--line); background: #efe6d2; }
.archive-grid .photo img { filter: sepia(.35); transition: filter .4s ease, transform .6s ease; }
.archive-grid a:hover .photo img, .archive-grid a:focus-visible .photo img { filter: none; transform: scale(1.03); }
.archive-grid h3 { font-size: 1.1rem; margin: 0 0 2px; }
.archive-grid p { font-size: .9rem; color: var(--muted); margin: 0; }
@media (max-width: 575.98px) { .archive-grid { grid-template-columns: 1fr 1fr; gap: 16px; } }
.record { list-style: none; margin: 0 0 24px; padding: 0; }
.record li { padding: 12px 0; border-bottom: 1px solid var(--line); }
.record .k { display: block; font-size: .86rem; color: var(--muted); }
.record .v { font-weight: 600; color: var(--ink-strong); }

/* Highlights row (youth) */
.highlights { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; border-top: 1px solid var(--on-night-line); margin-top: clamp(40px, 6vw, 64px); }
.highlights div { padding: 22px 20px 0; border-left: 1px solid var(--on-night-line); }
.highlights div:first-child { border-left: 0; padding-left: 0; }
.highlights i { color: var(--zari); font-size: 1.2rem; margin-bottom: 10px; display: block; }
.highlights strong { display: block; color: var(--on-night); font-weight: 600; }
.highlights span { color: var(--on-night-muted); font-size: .92rem; }
@media (max-width: 767.98px) {
  .highlights { grid-template-columns: 1fr 1fr; }
  .highlights div:nth-child(3) { border-left: 0; padding-left: 0; }
}

.detail-list { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 0 32px; }
.detail-list li { padding: 20px 0; border-top: 1px solid var(--line); }
.detail-list h3 { font-size: 1.2rem; margin: 0 0 4px; display: flex; gap: 10px; align-items: center; }
.detail-list h3 i { color: var(--firoza); font-size: 1rem; }
:root[data-theme="dark"] .detail-list h3 i { color: var(--firoza-soft); }
.detail-list p { margin: 0; color: var(--muted); font-size: .98rem; }
@media (max-width: 575.98px) { .detail-list { grid-template-columns: 1fr; } }

.people { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 32px; max-width: 860px; }
.person { display: grid; grid-template-columns: 72px 1fr; gap: 4px 18px; }
.monogram { width: 72px; height: 72px; border-radius: 50%; display: grid; place-items: center; font-family: var(--font-display); font-size: 1.5rem; color: var(--zari-soft); background: var(--night-2); grid-row: span 3; }
.person h3 { font-size: 1.3rem; margin: 6px 0 0; }
.person .spec { color: var(--accent-text); font-weight: 600; font-size: .95rem; }
.person p { color: var(--muted); font-size: .97rem; margin: 6px 0 0; }
@media (max-width: 767.98px) { .people { grid-template-columns: 1fr; } }

.quotes-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; }
.quotes-2 figure { margin: 0; }
.quotes-2 blockquote p { font-family: var(--font-display); font-size: clamp(1.25rem, 2vw, 1.5rem); line-height: 1.5; color: var(--ink-strong); }
.quotes-2 figcaption { color: var(--muted); }
.quotes-2 figcaption strong { color: var(--ink-strong); }
@media (max-width: 767.98px) { .quotes-2 { grid-template-columns: 1fr; gap: 32px; } }

/* ---------- Accordion (Bootstrap re-skin) ---------- */
.faq .accordion-item { background: transparent; border: 0; border-top: 1px solid var(--line); border-radius: 0 !important; }
.faq .accordion-item:last-child { border-bottom: 1px solid var(--line); }
.faq .accordion-button {
  background: transparent; color: var(--ink-strong); font-family: var(--font-display); font-size: 1.2rem;
  padding: 20px 0; box-shadow: none !important; gap: 12px;
}
.faq .accordion-button:not(.collapsed) { color: var(--firoza); }
:root[data-theme="dark"] .faq .accordion-button:not(.collapsed) { color: var(--firoza-soft); }
.faq .accordion-button::after { filter: none; }
:root[data-theme="dark"] .faq .accordion-button::after { filter: invert(1) brightness(1.4); }
.faq .accordion-body { padding: 0 0 22px; color: var(--muted); }

/* ---------- Modal re-skin ---------- */
.modal-content { background: var(--surface); color: var(--ink); border: 1px solid var(--line); border-radius: var(--r-panel); }
.modal-header, .modal-footer { border-color: var(--line); }
.modal-title { font-family: var(--font-display); font-weight: 400; color: var(--ink-strong); }
:root[data-theme="dark"] .btn-close { filter: invert(1) grayscale(1) brightness(2); }
.modal-body .photo { margin-bottom: 20px; max-height: 420px; }
.modal-body p { color: var(--ink); }
.wa-preview { background: #e9e2d8; border-radius: 12px; padding: 16px; }
:root[data-theme="dark"] .wa-preview { background: #0b141a; }
.wa-bubble { background: #d9fdd3; color: #111b21; border-radius: 10px 10px 10px 2px; padding: 12px 14px; white-space: pre-wrap; font-size: .95rem; line-height: 1.5; box-shadow: 0 1px 1px rgba(0,0,0,.1); word-break: break-word; }
:root[data-theme="dark"] .wa-bubble { background: #005c4b; color: #e9edef; }

/* ---------- Quick answers helper ---------- */
.helper { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-panel); overflow: hidden; display: flex; flex-direction: column; box-shadow: var(--shadow); }
.helper-head { display: flex; align-items: center; gap: 14px; padding: 18px 20px; background: var(--night); color: var(--on-night); }
.helper-head img { width: 40px; }
.helper-head strong { display: block; color: var(--on-night); }
.helper-head span { font-size: .85rem; color: var(--on-night-muted); }
.helper-log { height: 340px; overflow-y: auto; padding: 20px; display: flex; flex-direction: column; gap: 12px; background: var(--bg); }
.msg { max-width: 88%; padding: 12px 16px; border-radius: 14px; font-size: .97rem; line-height: 1.55; }
.msg p:last-child { margin: 0; }
.msg-bot { align-self: flex-start; background: var(--surface); border: 1px solid var(--line); border-bottom-left-radius: 4px; }
.msg-user { align-self: flex-end; background: var(--firoza); color: #fff; border-bottom-right-radius: 4px; }
:root[data-theme="dark"] .msg-user { background: var(--firoza-soft); color: var(--night); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; padding: 14px 20px 0; }
.chip { font: inherit; font-size: .88rem; padding: 6px 12px; border-radius: 999px; border: 1px solid var(--line-strong); background: transparent; color: var(--ink); cursor: pointer; }
.chip:hover { border-color: var(--firoza); color: var(--firoza); }
.helper-form { display: flex; gap: 10px; padding: 14px 20px 20px; }
.helper-form .input { flex: 1; }
.helper-form button { flex: none; }

/* ---------- Utilities ---------- */
.stack-sm > * + * { margin-top: 12px; }
.gap-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.mt-lg { margin-top: 40px; }
.narrow { max-width: 44rem; }
.visually-hidden-focusable:not(:focus):not(:focus-within) { position: absolute !important; width: 1px !important; height: 1px !important; overflow: hidden !important; clip: rect(0,0,0,0) !important; }

@media (max-width: 991.98px) {
  .hero { min-height: auto; }
  .hero-grid { grid-template-columns: 1fr; }
  .hero-art { width: min(78%, 340px); margin-top: 8px; }
  .lantern { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

@media print {
  .site-nav, .site-footer, .helper, .share { display: none !important; }
  .night { background: none !important; color: #000; }
}
.footer--joined { border-top: 1px solid var(--on-night-line); }
/* Keep wide Bootstrap gutters inside the container padding on small screens */
@media (max-width: 991.98px) { .row.g-5 { --bs-gutter-x: 2rem; } }
