/*
 * File: styles.css
 * Task: Site styling and layout task.
 * Author: WXHLab
 * Authored: November 2026
 */

/* ==========================================================================
   TABLE OF CONTENTS
   1.  Design tokens (:root CSS variables)
   2.  Base / reset / typography / layout helpers (.wrap = 90% content width)
   3.  Demo ribbon, top bar, header and navigation (.hdr, .nav, .dd, .burger)
   4.  Buttons
   5.  Hero, sections, cards, quick actions, stats, ornaments, pills
   6.  Thumbs & tones, events, page header, leadership, chapters, gallery, FAQ
   7.  Forms (.f), multi-step indicator, alerts
   8.  Tables
   9.  Portal / admin console shell (.shell, .side, .kpis, .bars, .tabs)
   10. Membership card, receipt, modal, toast, progress, footer, prose
   11. Scroll-reveal (.fade) and responsive breakpoints (980 / 820 / 620px) + print
   12. Prayer-times widget (.pt state classes) and Jumu'ah strip
   13. Event share bar, search, language selector, RTL overrides
   14. Low-data mode (.lowdata)
   15. Menu badges, RSVP row, signed-in chip, member photos
   16. Traffic map and analytics charts (SVG maps, bars, donut, legends)
   17. Link accessibility and reduced-motion handling
   Accessibility is spread through the file: .sr / .skip / :focus-visible (section 2),
   prefers-reduced-motion blocks (after .fade, after the map, after the prayer animation).
   ========================================================================== */
/* UIMGA — professional theme: deep green + gold, geometric Islamic motifs */
/* 1. DESIGN TOKENS (CSS custom properties, usable anywhere as var(--name)).
   --g9..--g6  deep-green brand ramp, darkest to lightest; --g1 is the pale green tint used for hover/active fills.
   --gold / --gold-l / --gold-d  accent gold: base, light (on dark backgrounds), dark (text on light backgrounds).
   --navy, --teal  secondary hues used by .tone-navy / .tone-teal thumbnails (and --navy by .pill.navy).
   --ink (body text), --muted (secondary text), --line (borders/dividers), --cream (page background), --white.
   --danger / --warn / --ok  status colours (errors and destructive buttons / caution / success).
   --r  standard card corner radius; --sh  standard soft card shadow.
   --pattern  inline SVG data-URI of the geometric Islamic motif (square + rotated square + circle in translucent gold);
   overlaid by ::before layers on hero, dark sections, page header, thumbs, membership card and footer; set to none by .lowdata. */
:root {
  --g9: #06291f;
  --g8: #0a3d2e;
  --g7: #0f5640;
  --g6: #177a5a;
  --g1: #e3f1ea;
  --gold: #c9a227;
  --gold-l: #e6c65a;
  --gold-d: #7a600c;
  --navy: #16324f;
  --teal: #0f766e;
  --ink: #16241f;
  --muted: #5a6b64;
  --line: #e3e8e5;
  --cream: #faf8f2;
  --white: #fff;
  --danger: #b3261e;
  --warn: #a15c00;
  --ok: #177a5a;
  --r: 14px;
  --sh: 0 1px 2px rgba(6, 41, 31, 0.06), 0 8px 24px rgba(6, 41, 31, 0.08);
  --pattern: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='64' height='64' viewBox='0 0 64 64'%3E%3Cg fill='none' stroke='%23e6c65a' stroke-opacity='.22' stroke-width='1'%3E%3Crect x='16' y='16' width='32' height='32'/%3E%3Crect x='16' y='16' width='32' height='32' transform='rotate(45 32 32)'/%3E%3Ccircle cx='32' cy='32' r='5'/%3E%3C/g%3E%3C/svg%3E");
}
/* 2. BASE: universal reset (border-box, zero margins), smooth scrolling, body typography (system sans stack, 16px/1.65),
   serif headings (Georgia) and default link colour. */
* {
  box-sizing: border-box;
  margin: 0;
}
html {
  scroll-behavior: smooth;
}
body {
  font:
    16px/1.65 "Segoe UI",
    system-ui,
    -apple-system,
    Roboto,
    Arial,
    sans-serif;
  color: var(--ink);
  background: var(--cream);
  -webkit-font-smoothing: antialiased;
}
h1,
h2,
h3,
h4 {
  font-family: Georgia, "Times New Roman", serif;
  line-height: 1.2;
  color: var(--g8);
  letter-spacing: -0.01em;
}
a {
  color: var(--g6);
  text-decoration: none;
}
a:hover {
  text-decoration: underline;
}
img,
svg {
  max-width: 100%;
}
/* .ar = Arabic text: Naskh-style font stack and right-to-left direction regardless of page direction. */
.ar {
  font-family:
    "Amiri", "Scheherazade New", "Traditional Arabic", "Segoe UI", serif;
  direction: rtl;
}
/* .wrap = main content container. THE 90% RULE: width is max(90%, 100% - 192px), i.e. content uses 90% of the viewport,
   but once 10% would exceed 96px per side the side margins stop growing and the content keeps widening. Centred via margin-inline. */
.wrap {
  width: max(90%, calc(100% - 192px));
  margin-inline: auto;
} /* 90% of the screen; on very wide screens the side margins stop growing (96px each) */
/* Accessibility: .sr is visually hidden off-screen text; .skip (a skip-to-content link) is revealed on keyboard focus;
   :focus-visible gives every keyboard-focused control a gold 3px outline; .ico is the shared inline SVG icon (stroke icons, 1.25em). */
.sr {
  position: absolute;
  left: -9999px;
}
.skip:focus {
  left: 8px;
  top: 8px;
  z-index: 200;
  background: #fff;
  padding: 8px 12px;
  border-radius: 8px;
}
:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 2px;
}
.ico {
  width: 1.25em;
  height: 1.25em;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  vertical-align: -0.2em;
  flex: none;
}

/* 3. DEMO RIBBON + TOP BAR + HEADER/NAV. .ribbon is the gold 'demo' banner; .topbar is the thin dark utility bar above the header. */
/* demo ribbon + topbar */
.ribbon {
  background: var(--gold);
  color: var(--g9);
  font-size: 0.82rem;
  text-align: center;
  padding: 5px 10px;
  font-weight: 600;
}
.topbar {
  background: var(--g9);
  color: #cfe3da;
  font-size: 0.85rem;
}
.topbar .wrap {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 7px 0;
  flex-wrap: wrap;
}
.topbar a {
  color: #cfe3da;
  margin-left: 18px;
}
.topbar a:hover {
  color: var(--gold-l);
  text-decoration: none;
}
.topbar .ar {
  font-size: 1.15rem;
  color: var(--gold-l);
}

/* Header: sticky translucent bar (74px tall). .nav is the horizontal menu; .dd is a hover/focus-within dropdown whose .menu is
   absolutely positioned; .burger (hidden on desktop) is shown at <=820px (see responsive section), where .nav.open reveals the menu. */
/* header */
.hdr {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.hdr .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 74px;
  gap: 16px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--g8);
}
.brand:hover {
  text-decoration: none;
}
.brand svg {
  width: 46px;
  height: 46px;
}
.brand b {
  font:
    700 1.25rem Georgia,
    serif;
  display: block;
  line-height: 1;
}
.brand small {
  font-size: 0.68rem;
  color: var(--muted);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  display: block;
  max-width: 230px;
  line-height: 1.25;
  margin-top: 3px;
}
/* header brand: larger wordmark, full name on a single line */
.hdr .brand svg {
  width: 58px;
  height: 58px;
}
.hdr .brand b {
  font-size: 2rem;
  letter-spacing: 0.01em;
}
.hdr .brand small {
  font-size: 0.8rem;
  max-width: none;
  white-space: nowrap;
  margin-top: 5px;
}
@media (max-width: 1440px) {
  .hdr .brand small {
    font-size: 0.64rem;
  }
  .hdr .brand b {
    font-size: 1.6rem;
  }
  .hdr .brand svg {
    width: 48px;
    height: 48px;
  }
}
@media (max-width: 1180px) {
  .hdr .brand small {
    white-space: normal;
    max-width: 200px;
  }
}
@media (max-width: 620px) {
  .hdr .brand small {
    display: none;
  }
}
.nav {
  display: flex;
  align-items: center;
  gap: 2px;
}
.nav > a,
.nav > .dd > button {
  padding: 9px 12px;
  border-radius: 9px;
  color: var(--ink);
  font: 600 0.92rem inherit;
  font-family: inherit;
  background: none;
  border: 0;
  cursor: pointer;
}
.nav > .dd > button {
  font-size: inherit;
}
.nav > a:hover,
.nav > .dd > button:hover,
.nav a.on {
  background: var(--g1);
  color: var(--g8);
  text-decoration: none;
}
.dd {
  position: relative;
}
.dd .menu {
  display: none;
  position: absolute;
  right: 0;
  top: 100%;
  min-width: 200px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: var(--sh);
  padding: 6px;
}
.dd:hover .menu,
.dd:focus-within .menu {
  display: block;
}
.menu a {
  display: block;
  padding: 8px 12px;
  border-radius: 8px;
  color: var(--ink);
  font-size: 0.92rem;
}
.menu a:hover {
  background: var(--g1);
  text-decoration: none;
}
.burger {
  display: none;
  background: none;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 8px 10px;
  cursor: pointer;
}

/* 4. BUTTONS. .btn base is a pill; variants: .btn-p primary green, .btn-g gold, .btn-o outline, .btn-w white outline (on dark),
   .btn-d danger, .btn-sm small. Disabled state is dimmed with no hover lift. */
/* buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 20px;
  border-radius: 999px;
  border: 2px solid transparent;
  font: 700 0.95rem inherit;
  font-family: inherit;
  cursor: pointer;
  transition: 0.18s;
  text-decoration: none !important;
  line-height: 1.2;
}
.btn-p {
  background: var(--g7);
  color: #fff;
}
.btn-p:hover {
  background: var(--g8);
  transform: translateY(-1px);
}
.btn-g {
  background: var(--gold);
  color: var(--g9);
}
.btn-g:hover {
  background: var(--gold-l);
  transform: translateY(-1px);
}
.btn-o {
  border-color: var(--g7);
  color: var(--g7);
  background: transparent;
}
.btn-o:hover {
  background: var(--g1);
}
.btn-w {
  border-color: rgba(255, 255, 255, 0.55);
  color: #fff;
}
.btn-w:hover {
  background: rgba(255, 255, 255, 0.12);
}
.btn-sm {
  padding: 7px 14px;
  font-size: 0.85rem;
}
.btn-d {
  background: var(--danger);
  color: #fff;
}
.btn[disabled] {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

/* 5. HERO. Two-column grid (text 1.15fr / card .85fr); ::before overlays the pattern; .sky is a decorative SVG skyline anchored
   to the bottom edge; .hero-card is a frosted-glass panel; .moon is a faint decorative crescent. */
/* hero */
.hero {
  position: relative;
  color: #fff;
  background:
    radial-gradient(
      1200px 500px at 85% -10%,
      rgba(230, 198, 90, 0.28),
      transparent 60%
    ),
    linear-gradient(135deg, var(--g9), var(--g7));
  overflow: hidden;
}
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--pattern);
  opacity: 0.9;
}
.hero .wrap {
  position: relative;
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 48px;
  align-items: center;
  padding: 72px 0 130px;
}
.hero h1 {
  color: #fff;
  font-size: clamp(2.1rem, 4.6vw, 3.5rem);
}
.hero h1 em {
  font-style: normal;
  color: var(--gold-l);
}
.hero .bism {
  font-size: 1.9rem;
  color: var(--gold-l);
  margin-bottom: 10px;
  display: block;
  text-align: left;
  direction: rtl;
}
.hero p.lead {
  font-size: 1.15rem;
  color: #d3e6dd;
  margin: 18px 0 28px;
  max-width: 56ch;
}
.cta-row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}
.hero .sky {
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  width: 100%;
  height: 130px;
  display: block;
}
.hero-card {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 22px;
  padding: 26px;
  backdrop-filter: blur(6px);
}
.hero-card h3 {
  color: #fff;
  font-size: 1.1rem;
  margin-bottom: 14px;
}
.hero-card .row {
  display: flex;
  gap: 12px;
  align-items: center;
  padding: 12px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  color: #e5f2ec;
}
.hero-card .row:first-of-type {
  border-top: 0;
}
.hero-card .badge-i {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: var(--gold);
  color: var(--g9);
  display: grid;
  place-items: center;
  flex: none;
}
.moon {
  position: absolute;
  right: 6%;
  top: 20px;
  width: 130px;
  opacity: 0.14;
}

/* SECTIONS & CARDS. .sec is a 72px-padded band (.alt white, .dark green gradient with pattern). .eyebrow is the small uppercase kicker;
   .sh is a section heading block. .grid with .g2/.g3/.g4 sets 2/3/4 equal columns (collapsed in responsive blocks).
   .card is the standard white panel (.hv adds hover lift); .ic / .ic.gold is the rounded icon tile. */
/* sections */
.sec {
  padding: 72px 0;
}
.sec.alt {
  background: #fff;
}
.sec.dark {
  background: linear-gradient(135deg, var(--g9), var(--g8));
  color: #d3e6dd;
  position: relative;
  overflow: hidden;
}
.sec.dark::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--pattern);
}
.sec.dark .wrap {
  position: relative;
}
.sec.dark h2 {
  color: #fff;
}
.eyebrow {
  display: inline-flex;
  gap: 8px;
  align-items: center;
  font: 700 0.78rem system-ui;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold-d);
  margin-bottom: 10px;
}
.eyebrow::before {
  content: "";
  width: 28px;
  height: 2px;
  background: var(--gold);
}
.sec.dark .eyebrow {
  color: var(--gold-l);
}
.sh {
  max-width: 680px;
  margin-bottom: 38px;
}
.sh h2 {
  font-size: clamp(1.7rem, 3vw, 2.35rem);
}
.sh p {
  color: var(--muted);
  margin-top: 10px;
}
.sec.dark .sh p {
  color: #b8d2c7;
}
.grid {
  display: grid;
  gap: 22px;
}
.g2 {
  grid-template-columns: repeat(2, 1fr);
}
.g3 {
  grid-template-columns: repeat(3, 1fr);
}
.g4 {
  grid-template-columns: repeat(4, 1fr);
}
.card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 24px;
  box-shadow: var(--sh);
  transition: 0.2s;
}
.card.hv:hover {
  transform: translateY(-4px);
  box-shadow: 0 14px 34px rgba(6, 41, 31, 0.14);
}
.card h3 {
  font-size: 1.15rem;
  margin-bottom: 8px;
}
.card p {
  color: var(--muted);
  font-size: 0.95rem;
}
.ic {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--g1), #fff);
  border: 1px solid #cfe5da;
  display: grid;
  place-items: center;
  color: var(--g7);
  margin-bottom: 14px;
  font-size: 1.4rem;
}
.ic.gold {
  background: linear-gradient(135deg, #f8efc9, #fff);
  border-color: #ecdb9c;
  color: var(--gold-d);
}

/* QUICK ACTIONS: card strip pulled up (-44px) to overlap the hero; .feat is the highlighted green variant. */
/* quick actions */
.quick {
  margin-top: -44px;
  position: relative;
  z-index: 5;
}
.quick .card {
  display: flex;
  flex-direction: column;
  gap: 6px;
  color: var(--ink);
  text-decoration: none;
}
.quick .card:hover {
  text-decoration: none;
}
.quick .card b {
  font:
    700 1.1rem Georgia,
    serif;
  color: var(--g8);
}
.quick .card span.go {
  margin-top: auto;
  color: var(--g6);
  font-weight: 700;
  font-size: 0.9rem;
}
.quick .card.feat {
  background: linear-gradient(135deg, var(--g7), var(--g8));
  color: #d3e6dd;
  border: 0;
}
.quick .card.feat b,
.quick .card.feat span.go {
  color: #fff;
}
.quick .card.feat .ic {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.25);
  color: var(--gold-l);
}

/* STATS: 4-column counter row on dark sections. */
/* stats */
.stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  text-align: center;
}
.stat b {
  display: block;
  font:
    700 clamp(2rem, 4vw, 3rem) Georgia,
    serif;
  color: var(--gold-l);
}
.stat span {
  color: #b8d2c7;
  font-size: 0.92rem;
}

/* SPLIT layout (two columns), .orn ornament box and .pill status chips (.gold .red .amber .grey .navy colour variants). */
/* split ornament */
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: center;
}
.orn {
  aspect-ratio: 1;
  max-width: 420px;
  margin: auto;
  width: 100%;
  position: relative;
}
.orn svg {
  width: 100%;
  height: 100%;
}
.pill {
  display: inline-block;
  padding: 3px 12px;
  border-radius: 999px;
  background: var(--g1);
  color: var(--g7);
  font-size: 0.78rem;
  font-weight: 700;
}
.pill.gold {
  background: #f8efc9;
  color: var(--gold-d);
}
.pill.red {
  background: #fde8e6;
  color: var(--danger);
}
.pill.amber {
  background: #fff1d6;
  color: var(--warn);
}
.pill.grey {
  background: #eceff0;
  color: #4b5a60;
}
.pill.navy {
  background: #e1ebf5;
  color: var(--navy);
}

/* 6. THUMBS & TONES: .tone-* are gradient backgrounds for thumbnails; .thumb is a 150px image-less banner with pattern overlay; .meta is a small metadata row. */
/* thumbs & tones */
.tone-green {
  background: linear-gradient(135deg, var(--g7), var(--g9));
}
.tone-gold {
  background: linear-gradient(135deg, var(--gold), var(--gold-d));
}
.tone-navy {
  background: linear-gradient(135deg, #27507a, var(--navy));
}
.tone-teal {
  background: linear-gradient(135deg, #14a094, var(--teal));
}
.thumb {
  height: 150px;
  border-radius: 12px;
  margin: -8px -8px 16px;
  position: relative;
  overflow: hidden;
  display: grid;
  place-items: center;
  color: rgba(255, 255, 255, 0.9);
  font-size: 2.4rem;
}
.thumb::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--pattern);
  opacity: 0.9;
}
.thumb .ico {
  width: 56px;
  height: 56px;
  position: relative;
}
.meta {
  font-size: 0.82rem;
  color: var(--muted);
  display: flex;
  gap: 10px;
  align-items: center;
  margin-bottom: 6px;
  flex-wrap: wrap;
}

/* EVENTS: .ev row with .date calendar tile (month / day / weekday). */
/* events */
.ev {
  display: flex;
  gap: 18px;
  align-items: flex-start;
}
.date {
  flex: none;
  width: 68px;
  border-radius: 14px;
  overflow: hidden;
  text-align: center;
  border: 1px solid var(--line);
  background: #fff;
}
.date i {
  display: block;
  background: var(--g7);
  color: #fff;
  font: 700 0.72rem system-ui;
  font-style: normal;
  letter-spacing: 0.1em;
  padding: 3px 0;
  text-transform: uppercase;
}
.date b {
  display: block;
  font:
    700 1.7rem Georgia,
    serif;
  color: var(--g8);
  padding: 4px 0 0;
  line-height: 1.1;
}
.date small {
  display: block;
  color: var(--muted);
  font-size: 0.72rem;
  padding-bottom: 6px;
}

/* PAGE HEADER (.ph): green banner at the top of inner pages with breadcrumb (.crumb). */
/* page header */
.ph {
  position: relative;
  color: #fff;
  background: linear-gradient(135deg, var(--g9), var(--g7));
  padding: 54px 0 46px;
  overflow: hidden;
}
.ph::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--pattern);
}
.ph .wrap {
  position: relative;
}
.ph h1 {
  color: #fff;
  font-size: clamp(1.9rem, 3.6vw, 2.7rem);
}
.ph p {
  color: #cfe3da;
  margin-top: 8px;
  max-width: 64ch;
}
.crumb {
  font-size: 0.85rem;
  color: #a9c9bb;
  margin-bottom: 8px;
}
.crumb a {
  color: #d9ece3;
}

/* LEADERSHIP: .person card with circular initials avatar and gold role label. */
/* leadership */
.person {
  text-align: center;
}
.avatar {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  margin: 0 auto 14px;
  display: grid;
  place-items: center;
  font:
    700 1.7rem Georgia,
    serif;
  color: #fff;
  background: linear-gradient(135deg, var(--g6), var(--g8));
  border: 4px solid #fff;
  box-shadow: 0 0 0 2px var(--gold);
}
.person .role {
  color: var(--gold-d);
  font-weight: 700;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

/* CHAPTERS: .tools is the search/filter toolbar; shared input styling for .tools and .f form controls; focus ring on any input/select/textarea;
   .chap lists chapter branches as small chips. */
/* chapters */
.tools {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 22px;
}
.tools input,
.tools select,
.f input,
.f select,
.f textarea {
  font: inherit;
  padding: 11px 14px;
  border: 1.5px solid #cfd8d3;
  border-radius: 10px;
  background: #fff;
  color: var(--ink);
  width: 100%;
}
.tools input {
  flex: 1;
  min-width: 220px;
  width: auto;
}
.tools select {
  width: auto;
}
input:focus,
select:focus,
textarea:focus {
  border-color: var(--g6);
  outline: 3px solid rgba(23, 122, 90, 0.18);
}
.chap h3 {
  font-size: 1.05rem;
}
.chap small {
  color: var(--muted);
}
.chap ul {
  list-style: none;
  padding: 0;
  margin: 10px 0 0;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.chap li {
  background: var(--g1);
  color: var(--g7);
  padding: 2px 10px;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 600;
}

/* GALLERY: 4-column square tiles (.gal); .lb is the full-screen lightbox overlay shown when .on is set; .box shows the active tile; .cap its caption. */
/* gallery */
.gal {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}
.gal button {
  aspect-ratio: 1;
  border: 0;
  border-radius: 16px;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  color: #fff;
  display: grid;
  place-items: center;
  padding: 0;
}
.gal button::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--pattern);
}
.gal button .ico {
  width: 52px;
  height: 52px;
  position: relative;
}
.gal button span {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 26px 12px 10px;
  background: linear-gradient(transparent, rgba(0, 0, 0, 0.6));
  font-size: 0.82rem;
  text-align: left;
}
.gal button:hover {
  transform: scale(1.02);
}
.lb {
  position: fixed;
  inset: 0;
  background: rgba(6, 41, 31, 0.88);
  display: none;
  place-items: center;
  z-index: 120;
  padding: 20px;
}
.lb.on {
  display: grid;
}
.lb .box {
  width: min(640px, 100%);
  aspect-ratio: 4/3;
  border-radius: 20px;
  display: grid;
  place-items: center;
  color: #fff;
  position: relative;
  overflow: hidden;
}
.lb .box::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--pattern);
}
.lb .box .ico {
  width: 96px;
  height: 96px;
  position: relative;
}
.lb .cap {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 20px;
  background: rgba(0, 0, 0, 0.45);
  text-align: center;
}

/* FAQ: native <details class="faq"> accordion; '+' / '-' marker is generated via ::after depending on [open]. */
/* faq */
details.faq {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0 20px;
  margin-bottom: 10px;
}
details.faq summary {
  cursor: pointer;
  padding: 16px 0;
  font-weight: 700;
  color: var(--g8);
  list-style: none;
  display: flex;
  justify-content: space-between;
  gap: 12px;
}
details.faq summary::after {
  content: "+";
  color: var(--gold-d);
  font-size: 1.4rem;
  line-height: 1;
}
details.faq[open] summary::after {
  content: "–";
}
details.faq p {
  padding-bottom: 16px;
  color: var(--muted);
}

/* 7. FORMS (.f): grid with 16px gaps; .row2/.row3 = 2/3 column rows (single column <=620px); .req red asterisk; .hint helper text; .chk checkbox row;
   .err inline validation message; .hp is a HONEYPOT field kept off-screen (bots fill it, humans never see it); .steps is the multi-step
   wizard indicator (.on current, .done completed); .drop is a dashed file-drop zone; .alert has .info/.ok/.warn/.bad colour variants. */
/* forms */
.f {
  display: grid;
  gap: 16px;
}
.f .row2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.f .row3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}
.f label {
  display: block;
  font-weight: 600;
  font-size: 0.88rem;
  margin-bottom: 5px;
  color: var(--g8);
}
.f label .req {
  color: var(--danger);
}
.f .hint {
  font-size: 0.8rem;
  color: var(--muted);
  margin-top: 4px;
}
.f .chk {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  font-weight: 400;
}
.f .chk input {
  width: auto;
  margin-top: 5px;
}
.err {
  color: var(--danger);
  font-size: 0.82rem;
  margin-top: 4px;
}
.hp {
  position: absolute;
  left: -9999px;
}
.steps {
  display: flex;
  gap: 6px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}
.steps div {
  flex: 1;
  min-width: 110px;
  padding: 10px 12px;
  border-radius: 10px;
  background: #eef2f0;
  color: var(--muted);
  font-weight: 700;
  font-size: 0.82rem;
  display: flex;
  gap: 8px;
  align-items: center;
}
.steps div b {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: #cfd8d3;
  color: #fff;
  display: grid;
  place-items: center;
  font-size: 0.78rem;
}
.steps div.on {
  background: var(--g1);
  color: var(--g8);
}
.steps div.on b {
  background: var(--g7);
}
.steps div.done b {
  background: var(--gold);
}
.drop {
  border: 2px dashed #b9c9c1;
  border-radius: 12px;
  padding: 18px;
  text-align: center;
  background: #fbfdfc;
  color: var(--muted);
}
.alert {
  padding: 14px 16px;
  border-radius: 12px;
  border: 1px solid;
  display: flex;
  gap: 12px;
  font-size: 0.92rem;
}
.alert[hidden] {
  display: none;
}
.alert.info {
  background: #eaf4fb;
  border-color: #bcd9ee;
  color: #134a73;
}
.alert.ok {
  background: #e6f4ec;
  border-color: #b6dcc6;
  color: #0f5c3c;
}
.alert.warn {
  background: #fff6e3;
  border-color: #f0d9a0;
  color: #7a4b00;
}
.alert.bad {
  background: #fdecea;
  border-color: #f3c0bb;
  color: #8c1d16;
}

/* 8. TABLES: .tw is a scrollable bordered wrapper; header cells are small uppercase; .num cells are right-aligned tabular figures. */
/* tables */
.tw {
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
}
table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}
th {
  background: #f1f5f3;
  text-align: left;
  padding: 11px 14px;
  font-size: 0.76rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--g8);
  white-space: nowrap;
}
td {
  padding: 11px 14px;
  border-top: 1px solid var(--line);
  vertical-align: middle;
}
tr:hover td {
  background: #fafcfb;
}
td.num,
th.num {
  text-align: right;
  font-variant-numeric: tabular-nums;
}

/* 9. PORTAL / ADMIN CONSOLE SHELL. .shell = 250px sidebar + content; .side is the sticky nav (becomes a horizontal scroller <=980px),
   .who is the signed-in user block, buttons use .on for the active view. .panel is the content pane. .kpis/.kpi are summary tiles
   (.warnk turns the figure red); .bars are horizontal progress bars (label / track / value); .tabs are pill tabs (.on active). */
/* portal / admin shell */
.shell {
  display: grid;
  grid-template-columns: 250px 1fr;
  gap: 26px;
  padding: 34px 0 70px;
  align-items: start;
}
.side {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 12px;
  position: sticky;
  top: 96px;
  box-shadow: var(--sh);
}
.side .who {
  padding: 14px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--g8), var(--g7));
  color: #fff;
  margin-bottom: 10px;
}
.side .who b {
  display: block;
  font-family: Georgia, serif;
}
.side .who small {
  color: #bcd9cc;
}
.side button {
  display: flex;
  gap: 10px;
  align-items: center;
  width: 100%;
  text-align: left;
  padding: 10px 12px;
  border: 0;
  background: none;
  border-radius: 10px;
  font: 600 0.92rem inherit;
  font-family: inherit;
  color: var(--ink);
  cursor: pointer;
}
.side button:hover {
  background: var(--g1);
}
.side button.on {
  background: var(--g1);
  color: var(--g8);
  box-shadow: inset 3px 0 0 var(--gold);
}
.panel h2 {
  font-size: 1.5rem;
  margin-bottom: 4px;
}
.panel > p.sub {
  color: var(--muted);
  margin-bottom: 20px;
}
.kpis {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 22px;
}
.kpi {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 18px;
  box-shadow: var(--sh);
  position: relative;
  overflow: hidden;
}
.kpi::after {
  content: "";
  position: absolute;
  right: -18px;
  top: -18px;
  width: 70px;
  height: 70px;
  border-radius: 50%;
  background: var(--g1);
}
.kpi small {
  color: var(--muted);
  font-weight: 600;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  position: relative;
}
.kpi b {
  display: block;
  font:
    700 1.7rem Georgia,
    serif;
  color: var(--g8);
  position: relative;
}
.kpi.warnk b {
  color: var(--danger);
}
.bars .b {
  display: grid;
  grid-template-columns: 130px 1fr 110px;
  gap: 12px;
  align-items: center;
  margin: 8px 0;
  font-size: 0.86rem;
}
.bars .t {
  height: 12px;
  background: #e9efec;
  border-radius: 99px;
  overflow: hidden;
  position: relative;
}
.bars .t i {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, var(--g6), var(--gold));
  border-radius: 99px;
}
.bars .t i.exp {
  position: absolute;
  inset: 0;
  background: transparent;
  border-right: 2px dashed var(--gold-d);
  opacity: 0;
}
.tabs {
  display: flex;
  gap: 6px;
  margin-bottom: 18px;
  flex-wrap: wrap;
}
.tabs button {
  padding: 8px 16px;
  border-radius: 99px;
  border: 1px solid var(--line);
  background: #fff;
  font: 600 0.88rem inherit;
  font-family: inherit;
  cursor: pointer;
}
.tabs button.on {
  background: var(--g7);
  color: #fff;
  border-color: var(--g7);
}

/* 10. MEMBERSHIP CARD (.mcard, ID-card style with pattern and QR slot) and printable RECEIPT (.receipt, striped top edge, dl grid, QR floated right). */
/* card + receipt */
.mcard {
  width: min(420px, 100%);
  border-radius: 20px;
  color: #fff;
  padding: 22px;
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, var(--g9), var(--g6));
  box-shadow: 0 18px 40px rgba(6, 41, 31, 0.3);
}
.mcard::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--pattern);
}
.mcard > * {
  position: relative;
}
.mcard .top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold-l);
  font-weight: 700;
}
.mcard .nm {
  font:
    700 1.35rem Georgia,
    serif;
  margin: 20px 0 2px;
}
.mcard .no {
  font-family: Consolas, monospace;
  letter-spacing: 0.06em;
  color: var(--gold-l);
}
.mcard .bt {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin-top: 18px;
}
.mcard .qr {
  background: #fff;
  border-radius: 10px;
  padding: 6px;
  width: 92px;
  height: 92px;
}
.receipt {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 28px;
  max-width: 560px;
  margin: auto;
  position: relative;
  box-shadow: var(--sh);
}
.receipt::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 8px;
  background: repeating-linear-gradient(
    90deg,
    var(--g7) 0 14px,
    var(--gold) 14px 28px
  );
  border-radius: 14px 14px 0 0;
}
.receipt h3 {
  margin: 8px 0 16px;
}
.receipt dl {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 6px 14px;
  font-size: 0.92rem;
  margin: 14px 0;
}
.receipt dt {
  color: var(--muted);
}
.receipt .tot {
  font:
    700 1.6rem Georgia,
    serif;
  color: var(--g8);
}
.receipt .qr {
  width: 96px;
  height: 96px;
  float: right;
  margin-left: 16px;
}

/* MODAL / TOAST / PROGRESS. .modal overlay is hidden until .on (display:grid); .mbox is the dialog; .chan is a 2-column payment/notification channel
   picker whose label highlights via :has(input:checked). .toasts stacks .toast notices bottom-right (slide-in animation 'in'); .prog is a thin progress bar. */
/* modal / toast */
.modal {
  position: fixed;
  inset: 0;
  background: rgba(6, 41, 31, 0.6);
  display: none;
  place-items: center;
  z-index: 150;
  padding: 16px;
  overflow: auto;
}
.modal.on {
  display: grid;
}
.mbox {
  background: #fff;
  border-radius: 18px;
  width: min(520px, 100%);
  padding: 26px;
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.35);
  max-height: 94vh;
  overflow: auto;
}
.mbox h3 {
  margin-bottom: 6px;
}
.chan {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin: 14px 0;
}
.chan label {
  border: 1.5px solid #cfd8d3;
  border-radius: 12px;
  padding: 12px;
  cursor: pointer;
  display: flex;
  gap: 10px;
  align-items: center;
  font-weight: 600;
  font-size: 0.88rem;
}
.chan input {
  accent-color: var(--g7);
}
.chan label:has(input:checked) {
  border-color: var(--g7);
  background: var(--g1);
}
.toasts {
  position: fixed;
  right: 16px;
  bottom: 16px;
  z-index: 200;
  display: grid;
  gap: 10px;
}
.toast {
  background: var(--g9);
  color: #fff;
  padding: 12px 16px;
  border-radius: 12px;
  box-shadow: var(--sh);
  border-left: 4px solid var(--gold);
  max-width: 340px;
  animation: in 0.25s;
}
@keyframes in {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
}
.prog {
  height: 10px;
  background: #e5ece8;
  border-radius: 99px;
  overflow: hidden;
  margin: 10px 0 6px;
}
.prog i {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, var(--g6), var(--gold));
}

/* FOOTER (.ftr): dark, patterned, 4-column link grid (1.4fr 1fr 1fr 1.2fr), newsletter input (.sub) and legal row. .prose is long-form text (max 760px). */
/* footer */
.ftr {
  background: var(--g9);
  color: #a9c9bb;
  position: relative;
  overflow: hidden;
}
.ftr::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--pattern);
  opacity: 0.6;
}
.ftr .wrap {
  position: relative;
  padding: 56px 0 24px;
}
.ftr .cols {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.2fr;
  gap: 36px;
}
.ftr h4 {
  color: #fff;
  font-size: 1rem;
  margin-bottom: 12px;
  font-family: Georgia, serif;
}
.ftr a {
  display: block;
  color: #a9c9bb;
  padding: 3px 0;
  font-size: 0.92rem;
}
.ftr a:hover {
  color: var(--gold-l);
  text-decoration: none;
}
.ftr .sub {
  display: flex;
  gap: 8px;
  margin-top: 8px;
}
.ftr .sub input {
  flex: 1;
  padding: 10px 12px;
  border-radius: 10px;
  border: 0;
  font: inherit;
  min-width: 0;
}
.ftr .legal {
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  margin-top: 34px;
  padding-top: 18px;
  font-size: 0.82rem;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}
.prose {
  max-width: 760px;
}
.prose h2 {
  font-size: 1.4rem;
  margin: 30px 0 8px;
}
.prose p,
.prose li {
  color: #33443d;
  margin-bottom: 10px;
}
.prose ul {
  padding-left: 22px;
}

.about-section {
  padding-bottom: 60px;
}
.about-intro-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-items: stretch;
  gap: 20px;
}
.about-panel {
  min-width: 0;
  padding: 26px;
  border: 1px solid var(--line);
  border-radius: var(--r);
  background: #fff;
  box-shadow: var(--sh);
}
.about-panel h2 {
  margin: 0 0 12px;
  font-size: 1.45rem;
}
.about-panel p {
  margin-bottom: 12px;
  color: #33443d;
}
.about-panel .about-motto {
  margin: 10px 0;
  color: var(--g7);
  font-size: 1.5rem;
  text-align: right;
}
.about-panel .about-note {
  margin-bottom: 0;
  color: var(--muted);
  font-size: 0.84rem;
}
.about-aims-heading {
  margin: 40px 0 20px;
}
.about-aims-heading h2 {
  font-size: 1.65rem;
}
.about-aims {
  gap: 18px;
}
.about-aims .card {
  height: 100%;
  padding: 22px;
}
.about-aims .card p {
  max-width: 42ch;
}

.history-section {
  background:
    radial-gradient(
      ellipse at 9% 12%,
      rgba(201, 162, 39, 0.07),
      transparent 32%
    ),
    #f5f6f1;
}
.history-heading {
  max-width: 720px;
  margin-bottom: 36px;
}
.history-heading .eyebrow,
.history-card .eyebrow,
.history-property .eyebrow {
  margin-bottom: 10px;
}
.history-heading h2 {
  margin-bottom: 12px;
  font-size: clamp(2rem, 4vw, 2.8rem);
}
.history-heading > p,
.history-origin p,
.history-milestone p,
.history-card p,
.history-property p {
  color: var(--muted);
}
.history-origin {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  gap: 28px;
  align-items: start;
  padding: 28px;
  border: 1px solid rgba(15, 86, 64, 0.1);
  border-radius: 18px;
  background: #fff;
  box-shadow: var(--sh);
}
.history-year {
  display: grid;
  min-height: 122px;
  align-content: center;
  justify-items: center;
  gap: 5px;
  border-radius: 13px;
  color: #f7f4e8;
  background: linear-gradient(145deg, var(--g8), var(--g9));
}
.history-year span,
.history-date {
  color: var(--gold-d);
  font-size: 0.72rem;
  font-weight: 750;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.history-year span {
  color: var(--gold-l);
}
.history-year strong {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 2.4rem;
  line-height: 1;
}
.history-origin h3,
.history-milestone h3,
.history-card h3,
.history-property h3 {
  margin-bottom: 9px;
  color: var(--g8);
  font-size: 1.25rem;
}
.history-origin p + p,
.history-milestone p + p,
.history-card p + p {
  margin-top: 11px;
}
.history-timeline {
  position: relative;
  display: grid;
  gap: 0;
  max-width: 900px;
  margin: 35px auto 40px;
}
.history-timeline::before {
  position: absolute;
  top: 10px;
  bottom: 10px;
  left: 114px;
  width: 1px;
  background: linear-gradient(
    to bottom,
    rgba(201, 162, 39, 0.15),
    rgba(15, 86, 64, 0.35),
    rgba(201, 162, 39, 0.15)
  );
  content: "";
}
.history-milestone {
  position: relative;
  display: grid;
  grid-template-columns: 90px minmax(0, 1fr);
  gap: 48px;
  padding: 18px 0 23px;
}
.history-date {
  padding-top: 3px;
  text-align: right;
  letter-spacing: 0.06em;
}
.history-marker {
  position: absolute;
  top: 23px;
  left: 108px;
  width: 13px;
  height: 13px;
  border: 3px solid #f5f6f1;
  border-radius: 50%;
  background: var(--g6);
  box-shadow: 0 0 0 1px rgba(15, 86, 64, 0.35);
}
.history-milestone h3 {
  font-size: 1.15rem;
}
.history-bottom-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}
.history-card {
  padding: 25px;
  border: 1px solid rgba(15, 86, 64, 0.1);
  border-radius: 16px;
  background: #fff;
  box-shadow: var(--sh);
}
.history-card h3 {
  margin-bottom: 17px;
}
.history-card h4 {
  margin: 18px 0 7px;
  color: var(--g7);
  font-size: 0.95rem;
}
.history-card ul {
  display: grid;
  gap: 6px;
  padding-left: 1.2rem;
  color: var(--muted);
}
.history-property {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  gap: 16px;
  align-items: start;
  margin-top: 18px;
  padding: 24px;
  border: 1px solid rgba(201, 162, 39, 0.23);
  border-radius: 16px;
  background: linear-gradient(120deg, #fffdf6, #fff);
}
.history-property-icon {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border-radius: 12px;
  color: var(--gold-d);
  background: rgba(201, 162, 39, 0.13);
  font-size: 1.35rem;
}
.history-property h3 {
  margin-bottom: 6px;
}
@media (max-width: 620px) {
  .history-origin {
    grid-template-columns: 1fr;
    gap: 18px;
    padding: 20px;
  }
  .history-year {
    min-height: 86px;
  }
  .history-timeline {
    margin: 26px 0 30px;
  }
  .history-timeline::before {
    left: 7px;
  }
  .history-milestone {
    grid-template-columns: 1fr;
    gap: 4px;
    padding: 14px 0 20px 30px;
  }
  .history-date {
    text-align: left;
  }
  .history-marker {
    top: 19px;
    left: 1px;
  }
  .history-bottom-grid {
    grid-template-columns: 1fr;
  }
  .history-card,
  .history-property {
    padding: 20px;
  }
}

/* 11. SCROLL REVEAL: .fade starts hidden/shifted; JS adds .in when it enters the viewport. Reduced-motion users get no motion (accessibility). */
.fade {
  opacity: 0;
  transform: translateY(18px);
  transition: 0.6s;
}
.fade.in {
  opacity: 1;
  transform: none;
}
@media (prefers-reduced-motion: reduce) {
  .fade {
    opacity: 1;
    transform: none;
    transition: none;
  }
  html {
    scroll-behavior: auto;
  }
}

/* RESPONSIVE BREAKPOINTS (desktop-first, max-width):
   <=980px  tablet: hero/split to 1 column, 4-col grids to 2, 3-col to 2, portal sidebar becomes horizontal scroller, footer 2 cols, gallery 2 cols.
   <=820px  mobile nav: burger shown, .nav becomes a full-width dropdown (.open), dropdown menus expand inline, topbar right-hand links hidden.
   <=620px  phone: all grids and form rows to 1 column (stats stay 2), tighter hero padding, narrower bar labels, receipt dl stacked. */
@media (max-width: 980px) {
  .hero .wrap,
  .split {
    grid-template-columns: 1fr;
  }
  .g4,
  .kpis,
  .stats {
    grid-template-columns: repeat(2, 1fr);
  }
  .g3 {
    grid-template-columns: 1fr 1fr;
  }
  .shell {
    grid-template-columns: 1fr;
  }
  .side {
    position: static;
    display: flex;
    overflow: auto;
    gap: 4px;
    padding: 8px;
  }
  .side .who {
    display: none;
  }
  .side button {
    white-space: nowrap;
    width: auto;
  }
  .ftr .cols {
    grid-template-columns: 1fr 1fr;
  }
  .gal {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (max-width: 1100px) {
  .topbar .wrap > div:last-child {
    display: flex;
    flex-wrap: wrap;
  }
  .burger {
    display: block;
  }
  .nav {
    display: none;
    position: absolute;
    left: 0;
    right: 0;
    top: 74px;
    background: #fff;
    border-bottom: 1px solid var(--line);
    flex-direction: column;
    align-items: stretch;
    padding: 10px 4%;
    max-height: 75vh;
    overflow: auto;
  }
  .nav.open {
    display: flex;
  }
  .dd .menu {
    display: block;
    position: static;
    border: 0;
    box-shadow: none;
    padding: 0 0 0 12px;
  }
}
@media (max-width: 820px) {
  .about-intro-grid {
    grid-template-columns: 1fr;
  }
  .topbar .wrap > div:last-child {
    display: none;
  }
}
@media (max-width: 620px) {
  .g2,
  .g3,
  .g4,
  .kpis,
  .f .row2,
  .f .row3,
  .ftr .cols,
  .chan {
    grid-template-columns: 1fr;
  }
  .stats {
    grid-template-columns: 1fr 1fr;
  }
  .hero .wrap {
    padding: 48px 0 120px;
  }
  .bars .b {
    grid-template-columns: 90px 1fr 80px;
  }
  .receipt dl {
    grid-template-columns: 1fr;
  }
}
/* PRINT: hides chrome (ribbon, topbar, header, footer, sidebar, buttons, tabs, toasts) and shows the shell as a plain block on white. */
@media print {
  .ribbon,
  .topbar,
  .hdr,
  .ftr,
  .side,
  .btn,
  .tabs,
  .toasts {
    display: none !important;
  }
  body {
    background: #fff;
  }
  .shell {
    display: block;
  }
}

/* 12. PRAYER WIDGET (.prayer). .ph-top header row with .pnext (next-prayer summary); .pgrid is a 6-tile grid (3 columns <=700px); .pt is a prayer-time tile.
   STATE CLASSES on .pt (toggled by JS):
     .pt.next = the upcoming prayer, ORANGE (#f59e0b) with dark text;
     .pt.cur  = the current prayer, solid GREEN with white text and a FLASHING glow (keyframes 'pnow', defined at the end of the file);
     .pt.done = prayers already passed today, RED tint with red text;
     .pt.sun  = sunrise tile: not dimmed, grey label. */
/* prayer widget */
.prayer .ph-top {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  align-items: start;
  margin-bottom: 14px;
}
.pnext {
  text-align: right;
  background: var(--g1);
  padding: 8px 14px;
  border-radius: 12px;
}
.pnext b {
  display: block;
  font:
    700 1.15rem Georgia,
    serif;
  color: var(--g8);
}
.pgrid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 10px;
}
.pt {
  background: #f6f9f7;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 10px;
  text-align: center;
}
.pt small {
  display: block;
  color: var(--muted);
  font-weight: 600;
  font-size: 0.76rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.pt b {
  font:
    700 1.2rem Georgia,
    serif;
  color: var(--g8);
}
.pt.next {
  background: #f59e0b;
  border-color: #d97706;
}
.pt.next small,
.pt.next b {
  color: #3b2300;
}
.pt.done {
  background: #fdecea;
  border-color: #e9a8a1;
}
.pt.done small,
.pt.done b {
  color: #a1261c;
}
.pt.cur {
  background: #166534;
  border-color: #14532d;
  animation: pnow 2.4s ease-in-out infinite;
}
.pt.cur small,
.pt.cur b {
  color: #fff;
}
.pt.sun {
  opacity: 1;
}
.pt.sun small {
  color: #5b6a65;
}
/* .jum is the Jumu'ah (Friday prayer) strip, gold-highlighted when .today. In the timetable, tr.today highlights today's row and tr.fri marks Fridays (gold first cell). */
.jum {
  margin-top: 14px;
  padding: 10px 14px;
  border-radius: 12px;
  background: #fbf6e2;
  border: 1px solid #ecdb9c;
  font-size: 0.92rem;
}
.jum.today {
  background: #f8efc9;
  border-color: var(--gold);
}
tr.today td {
  background: #e8f2ed !important;
  font-weight: 700;
}
tr.fri td:first-child {
  color: var(--gold-d);
  font-weight: 700;
}
/* Prayer grid: 3 columns on narrow screens. */
@media (max-width: 700px) {
  .pgrid {
    grid-template-columns: repeat(3, 1fr);
  }
}
/* event share bar, search, language */
/* 13. SHARE BAR + 'add to calendar' dropdown (details.cal / .calmenu), nav search icon button, language selector, <mark> search highlight. */
.share {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-top: 10px;
  align-items: center;
}
details.cal {
  position: relative;
}
details.cal summary {
  list-style: none;
  cursor: pointer;
}
details.cal summary::-webkit-details-marker {
  display: none;
}
.calmenu {
  position: absolute;
  z-index: 6;
  top: 100%;
  left: 0;
  margin-top: 4px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: var(--sh);
  padding: 6px;
  min-width: 210px;
}
.calmenu a {
  display: block;
  padding: 8px 12px;
  border-radius: 8px;
  color: var(--ink);
  font-size: 0.9rem;
}
.calmenu a:hover {
  background: var(--g1);
  text-decoration: none;
}
.navsearch {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  color: var(--g8);
  border: 1px solid var(--line);
}
.navsearch:hover {
  background: var(--g1);
}
.langsel {
  margin-left: 14px;
  background: transparent;
  color: #cfe3da;
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 8px;
  padding: 2px 6px;
  font: inherit;
  font-size: 0.82rem;
}
.langsel option {
  color: #16241f;
}
mark {
  background: #f8efc9;
  padding: 0 2px;
  border-radius: 3px;
}
/* RTL OVERRIDES: when the document is dir=rtl (e.g. Arabic) mirror the horizontal offsets: top-bar link and language margins flip sides,
   next-prayer text aligns left, and the calendar dropdown anchors to the right edge. body.rtl switches to an Arabic-friendly font stack. */
[dir="rtl"] .topbar a {
  margin-left: 0;
  margin-right: 18px;
}
[dir="rtl"] .langsel {
  margin-left: 0;
  margin-right: 14px;
}
[dir="rtl"] .pnext {
  text-align: left;
}
[dir="rtl"] .calmenu {
  left: auto;
  right: 0;
}
body.rtl {
  font-family: "Amiri", "Segoe UI", Tahoma, sans-serif;
}
/* 14. LOW-DATA MODE: body.lowdata is added by js/app.js when the user opted in or the browser reports Save-Data. It removes the pattern token, hides decorative layers, kills all animations/transitions and flattens hero/header backgrounds. */
/* low-data mode: no decorative patterns, animations or heavy backgrounds */
.lowdata {
  --pattern: none;
}
.lowdata .hero::before,
.lowdata .ph::before,
.lowdata .sec.dark::before,
.lowdata .ftr::before,
.lowdata .thumb::before,
.lowdata .mcard::before,
.lowdata .hero .sky,
.lowdata .moon {
  display: none;
}
.lowdata *,
.lowdata *::before,
.lowdata *::after {
  animation: none !important;
  transition: none !important;
  scroll-behavior: auto !important;
}
.lowdata .hero,
.lowdata .ph {
  background: var(--g8);
}
.lowdata .hdr {
  backdrop-filter: none;
}
/* 15. MENU COUNT BADGES (.nbadge) and EVENT RSVP row (.rsvp-row; .btn-d inside repeats danger colours). */
/* menu counts + RSVP */
.nbadge {
  display: inline-grid;
  place-items: center;
  min-width: 19px;
  height: 19px;
  padding: 0 6px;
  margin-left: 6px;
  border-radius: 99px;
  background: var(--gold);
  color: var(--g9);
  font: 700 0.7rem system-ui;
  vertical-align: 1px;
}
.rsvp-row {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
  margin-top: 12px;
}
.rsvp-n {
  color: var(--muted);
  font-size: 0.84rem;
}
.rsvp-row .btn-d {
  background: var(--danger);
  color: #fff;
}
/* SIGNED-IN CHIP: .authbox in the header holds .who-chip (avatar .wc-pic + name/role .wc-t); .tb-pic/.tb-who are the compact top-bar version. Role text hides <=1100px, then reappears inline <=820px. */
/* signed-in chip in the header */
.authbox {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: 8px;
}
.who-chip {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 4px 12px 4px 4px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--g1);
  color: var(--ink);
  text-decoration: none !important;
  max-width: 260px;
}
.who-chip:hover {
  background: #d4eadf;
}
.wc-pic,
.tb-pic {
  border-radius: 50%;
  background: linear-gradient(135deg, var(--g6), var(--g9));
  color: #fff;
  display: grid;
  place-items: center;
  font:
    700 0.8rem Georgia,
    serif;
  overflow: hidden;
  flex: none;
  border: 2px solid var(--gold-l);
}
.wc-pic {
  width: 36px;
  height: 36px;
}
.tb-pic {
  width: 24px;
  height: 24px;
  font-size: 0.62rem;
  border-width: 1.5px;
}
.wc-pic img,
.tb-pic img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.wc-t {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
  min-width: 0;
}
.wc-t b {
  font-size: 0.84rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.wc-t small {
  font-size: 0.7rem;
  color: var(--muted);
  white-space: nowrap;
}
.topbar .tb-who {
  color: #e9f4ee;
}
.topbar .tb-who b {
  color: var(--gold-l);
}
@media (max-width: 1100px) {
  .wc-t small {
    display: none;
  }
  .who-chip {
    max-width: 190px;
  }
}
@media (max-width: 820px) {
  .authbox {
    flex-wrap: wrap;
    margin: 6px 0;
  }
  .wc-t small {
    display: inline;
  }
}
/* MEMBER PHOTO: .pic circular avatar (initials fallback or image; .big variant), small .cp photo on the membership card, centred .who block in the sidebar. */
/* member photo */
.side .who {
  text-align: center;
}
.pic {
  width: 76px;
  height: 76px;
  border-radius: 50%;
  margin: 0 auto 10px;
  background: linear-gradient(135deg, var(--g6), var(--g9));
  color: #fff;
  display: grid;
  place-items: center;
  font:
    700 1.5rem Georgia,
    serif;
  border: 3px solid var(--gold-l);
  overflow: hidden;
}
.pic img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.pic.big {
  width: 96px;
  height: 96px;
  margin: 0;
  border-color: #fff;
  box-shadow: 0 0 0 2px var(--gold);
}
.mcard .cp {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--gold-l);
  margin-top: 14px;
  display: block;
}
.mcard .cp + .nm {
  margin-top: 8px;
}
/* 16. TRAFFIC MAP: .mapgrid = map + top-list columns (1 column <=980px). .wmap holds the SVG world map; .bub are sized bubbles (pop-in animation, .sel = selected),
   .ring is a pulsing ping, .tip the hover tooltip, .mleg the size legend, .tl a ranked list row (rank / name / bar / share / count), .perbar the period switcher. */
/* traffic map */
.mapgrid {
  display: grid;
  grid-template-columns: minmax(0, 2.4fr) minmax(260px, 1fr);
  gap: 18px;
  align-items: start;
}
.wmap {
  position: relative;
  background: linear-gradient(180deg, #f3f8f5, #e8f1ec);
  border-radius: 12px;
  overflow: hidden;
}
.wmap svg {
  width: 100%;
  height: auto;
  display: block;
}
.wmap path {
  fill: #bcd2c5;
  stroke: #fff;
  stroke-width: 0.5;
  transition: fill 0.3s;
}
.wmap .bg {
  cursor: pointer;
  outline: none;
}
.wmap .bub {
  fill: rgba(201, 162, 39, 0.55);
  stroke: #9a7b12;
  stroke-width: 1.2;
  transform-box: fill-box;
  transform-origin: center;
  animation: pop 0.9s cubic-bezier(0.2, 1.3, 0.4, 1) both;
  transition: fill 0.2s;
}
.wmap .bg:hover .bub,
.wmap .bg:focus .bub {
  fill: rgba(201, 162, 39, 0.8);
}
.wmap .bub.sel {
  fill: rgba(23, 122, 90, 0.7);
  stroke: #0a3d2e;
}
.wmap .ring {
  fill: none;
  stroke: #c9a227;
  stroke-width: 1.2;
  transform-box: fill-box;
  transform-origin: center;
  animation: ping 2.8s ease-out infinite;
  pointer-events: none;
}
@keyframes pop {
  from {
    transform: scale(0);
  }
  to {
    transform: scale(1);
  }
}
@keyframes ping {
  0% {
    transform: scale(1);
    opacity: 0.7;
  }
  100% {
    transform: scale(1.8);
    opacity: 0;
  }
}
.wmap .tip {
  position: absolute;
  pointer-events: none;
  background: #06291f;
  color: #fff;
  font-size: 0.82rem;
  padding: 8px 11px;
  border-radius: 9px;
  box-shadow: var(--sh);
  z-index: 3;
  white-space: nowrap;
}
.mleg {
  position: absolute;
  left: 12px;
  bottom: 10px;
  display: flex;
  gap: 14px;
  align-items: flex-end;
  font-size: 0.74rem;
  color: #3d5148;
  background: rgba(255, 255, 255, 0.75);
  padding: 6px 10px;
  border-radius: 9px;
}
.mleg span {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
}
.mleg i {
  display: block;
  border-radius: 50%;
  background: rgba(201, 162, 39, 0.55);
  border: 1px solid #9a7b12;
}
.toplist {
  display: grid;
  gap: 6px;
}
.tl {
  display: grid;
  grid-template-columns: 22px 1fr 70px 52px 38px;
  gap: 8px;
  align-items: center;
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  font: inherit;
  cursor: pointer;
  text-align: left;
}
.tl:hover,
.tl.on {
  background: var(--g1);
  border-color: var(--g6);
}
.tl .rk {
  color: var(--muted);
  font-size: 0.78rem;
}
.tl .nm {
  font-weight: 600;
  font-size: 0.88rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.tl .bar {
  height: 7px;
  background: #e5ece8;
  border-radius: 9px;
  overflow: hidden;
}
.tl .bar i {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, var(--g6), var(--gold));
}
.tl small {
  color: var(--muted);
  text-align: right;
}
.tl b {
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.perbar {
  display: flex;
  gap: 6px;
}
.perbar button {
  padding: 7px 14px;
  border-radius: 99px;
  border: 1px solid var(--line);
  background: #fff;
  font: 600 0.85rem inherit;
  font-family: inherit;
  cursor: pointer;
}
.perbar button.on {
  background: var(--g7);
  color: #fff;
  border-color: var(--g7);
}
@media (max-width: 980px) {
  .mapgrid {
    grid-template-columns: 1fr;
  }
}
@media (prefers-reduced-motion: reduce) {
  .wmap .bub,
  .wmap .ring {
    animation: none;
  }
}
/* ANALYTICS CHARTS: .fbar filter bar; .agrid 2-column chart grid (1 column <=820px), .card.ac.wide spans both columns; .ax axis text; .lg/.dl legends;
   .dn donut chart with .dc centre text and .ds sub-text; details.tbl is a collapsible data-table alternative to a chart (text equivalent);
   .live is the pulsing 'live' indicator (keyframes 'pulse'). */
/* analytics */
.fbar {
  display: flex;
  gap: 14px;
  align-items: center;
  flex-wrap: wrap;
  margin-bottom: 20px;
}
.fbar select {
  font: inherit;
  padding: 10px 14px;
  border: 1.5px solid #cfd8d3;
  border-radius: 10px;
  background: #fff;
  max-width: 100%;
}
.fbar small {
  color: var(--muted);
}
.agrid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 22px;
}
body[data-page="downloads"] .agrid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.card.ac {
  min-width: 0;
}
.card.ac.wide {
  grid-column: 1/-1;
}
.sub2 {
  color: var(--muted);
  font-size: 0.88rem;
  margin: -2px 0 14px;
}
.card.ac svg {
  width: 100%;
  height: auto;
  display: block;
}
.ax {
  font: 11px system-ui;
  fill: #5a6b64;
}
.lg {
  display: flex;
  gap: 16px;
  margin-bottom: 8px;
  font-size: 0.84rem;
  flex-wrap: wrap;
}
.lg i,
.dl i {
  display: inline-block;
  width: 11px;
  height: 11px;
  border-radius: 3px;
  margin-right: 6px;
}
.dn {
  display: grid;
  grid-template-columns: minmax(150px, 210px) 1fr;
  gap: 18px;
  align-items: center;
}
.dn svg {
  max-width: 210px;
}
.dc {
  font:
    700 5px Georgia,
    serif;
  fill: #0a3d2e;
}
.ds {
  font: 2.6px system-ui;
  fill: #5a6b64;
}
.dl {
  list-style: none;
  padding: 0;
  display: grid;
  gap: 8px;
  font-size: 0.88rem;
}
.dl li {
  display: grid;
  grid-template-columns: auto 1fr auto 42px;
  align-items: center;
  gap: 4px;
}
.dl small {
  color: var(--muted);
  text-align: right;
}
details.tbl {
  margin-top: 12px;
}
details.tbl summary {
  cursor: pointer;
  color: var(--g6);
  font-weight: 600;
  font-size: 0.84rem;
}
details.tbl .tw {
  margin-top: 8px;
  max-height: 220px;
}
.live {
  display: inline-flex;
  gap: 6px;
  align-items: center;
  color: var(--g6);
  font-weight: 600;
  font-size: 0.82rem;
}
.live::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--g6);
  animation: pulse 2s infinite;
}
@keyframes pulse {
  50% {
    opacity: 0.3;
  }
}
@media (max-width: 820px) {
  .agrid {
    grid-template-columns: 1fr;
  }
  body[data-page="downloads"] .agrid {
    grid-template-columns: 1fr;
  }
  .dn {
    grid-template-columns: 1fr;
  }
  .dn svg {
    margin: auto;
  }
}

/* 17. LINK ACCESSIBILITY: inline links inside paragraphs/alerts/cards are underlined so they are distinguishable without colour. Friday rows get a gold first cell. */
p > a:not(.btn),
.alert a,
.card p a {
  text-decoration: underline;
}
.fri td:first-child {
  color: var(--gold-d);
}

/* Flashing-green animation for .pt.cur (current prayer): background and glow ring pulse every 2.4s; disabled just below for reduced-motion users. */
@keyframes pnow {
  0%,
  100% {
    background: #166534;
    box-shadow: 0 0 0 0 rgba(34, 139, 84, 0);
  }
  50% {
    background: #1f8a4c;
    box-shadow: 0 0 0 6px rgba(34, 139, 84, 0.22);
  }
}
@media (prefers-reduced-motion: reduce) {
  .pt.cur {
    animation: none;
  }
}

/* ---- interactive traffic map: zoom / pan / drill-down controls ---- */
.wmap svg {
  touch-action: none;
  cursor: grab;
}
.wmap.grab svg {
  cursor: grabbing;
}
.wmap path {
  vector-effect: non-scaling-stroke;
}
.wmap .bub,
.wmap .ring {
  vector-effect: non-scaling-stroke;
}
.wmap .bg.still .bub,
.wmap .bg.still .ring {
  animation: none;
}
.wmap .bub {
  transform-box: fill-box;
}
.mctl {
  position: absolute;
  right: 12px;
  top: 12px;
  display: grid;
  gap: 6px;
  z-index: 2;
}
.mctl button {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: #fff;
  font: 700 1.15rem system-ui;
  color: var(--g8);
  cursor: pointer;
  box-shadow: var(--sh);
}
.mctl button:hover {
  background: var(--g1);
}
.mcrumb {
  position: absolute;
  left: 12px;
  top: 12px;
  right: 64px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  z-index: 2;
  font-size: 0.8rem;
}
.mcrumb button {
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.92);
  border-radius: 9px;
  padding: 6px 10px;
  font: inherit;
  color: #3d5148;
  cursor: pointer;
  text-align: left;
}
.mcrumb button b {
  color: var(--g8);
  margin-right: 4px;
}
.mcrumb button.cur {
  background: var(--g8);
  border-color: var(--g8);
  color: #d3e6dd;
}
.mcrumb button.cur b {
  color: #fff;
}
.mcrumb span {
  color: var(--muted);
}
.mhint {
  position: absolute;
  right: 12px;
  bottom: 10px;
  font-size: 0.7rem;
  color: #3d5148;
  background: rgba(255, 255, 255, 0.75);
  padding: 4px 8px;
  border-radius: 8px;
  max-width: 46%;
  text-align: right;
}
@media (max-width: 620px) {
  .mhint {
    display: none;
  }
}
