/* =========================================================================
   PAKISTAN ISLAMIC CENTRE — DESIGN SYSTEM
   A UK Pakistani-community visual identity: deep navy (from the mihrab-arch
   mark), brushed-gold metalwork accents, warm stone/sand neutrals, and an
   8-point geometric star motif carried through as the signature texture.
   ========================================================================= */

/* ---- Custom brand font: Pala (Palatino Linotype) ----
   Path is relative to this CSS file — adjust ../fonts/pala.ttf
   if your folder structure is different. */
@font-face {
  font-family: 'Pala';
  src: url('../fonts/pala.ttf') format('truetype');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

:root {
  /* ---- Color tokens ---- */
  --ink: #1A2530;
  --forest: #1C3A57;        /* primary navy (matches the logo arch) */
  --forest-dark: #122A40;   /* deep navy */
  --forest-tint: #E7ECF1;
  --sand: #F6F1E7;
  --sand-deep: #EDE4D0;
  --sand-line: #DED0AE;
  --brass: #C9A24D;         /* primary gold (matches the logo star/crescent) */
  --brass-light: #E0C179;
  --brass-tint: #F5ECD8;
  --white: #FFFFFF;
  --success: #3E7A56;
  --danger: #B5502F;

  /* ---- Type ---- */
  --font-display: 'Pala', Georgia, serif;
  --font-body: 'Pala', 'Segoe UI', sans-serif;
  --font-accent: 'Pala', sans-serif;
  --font-data: 'Pala', monospace;

  /* ---- Shape / motion ---- */
  --radius-sm: 8px;
  --radius-md: 16px;
  --radius-lg: 28px;
  --radius-pill: 999px;
  --shadow-soft: 0 20px 50px -25px rgba(9, 50, 38, 0.35);
  --shadow-card: 0 12px 30px -18px rgba(27, 36, 32, 0.25);
  --ease: cubic-bezier(.22,.61,.36,1);
}

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

/* =========================================================================
   BASE
   ========================================================================= */

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--sand);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* Belt-and-braces: no raw <img> should ever be able to push a mobile
   layout wider than its container. Elements with their own sizing
   rules (illus-card, hero-skyline, navbar logo, etc.) are more
   specific and override this safely. */
img { max-width: 100%; height: auto; }

h1, h2, h3, h4, .font-display {
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--forest-dark);
  letter-spacing: -0.01em;
}

h1 { font-weight: 500; }

a { color: var(--forest); text-decoration: none; }
a:hover { color: var(--brass); }

::selection { background: var(--brass-tint); color: var(--forest-dark); }

:focus-visible {
  outline: 2.5px solid var(--brass);
  outline-offset: 3px;
}

.font-accent { font-family: var(--font-accent); }
.font-data { font-family: var(--font-data); }

.text-forest { color: var(--forest) !important; }
.text-brass { color: var(--brass) !important; }
.bg-forest { background-color: var(--forest) !important; }
.bg-forest-dark { background-color: var(--forest-dark) !important; }
.bg-sand-deep { background-color: var(--sand-deep) !important; }
.bg-brass { background-color: var(--brass) !important; }

/* Eyebrow label — small kufic-style tag used above section titles */
.eyebrow {
  font-family: var(--font-accent);
  font-size: 0.8rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--brass);
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  margin-bottom: 0.9rem;
}
.eyebrow::before {
  content: "";
  width: 26px; height: 1px;
  background: var(--brass);
  display: inline-block;
}

.section-title { margin-bottom: 0.5rem; }
.section-lede { color: #52605A; max-width: 640px; }

.section { padding: 5.5rem 0; }
.section-sm { padding: 3.25rem 0; }

@media (max-width: 767.98px) {
  .section { padding: 3.5rem 0; }
  .section-sm { padding: 2.25rem 0; }
}

/* Repeating geometric star texture — the signature motif */
.pattern-strip {
  background-image: url('../images/pattern-star.svg');
  background-repeat: repeat;
  background-size: 64px 64px;
}
.pattern-strip-light {
  background-image: url('../images/pattern-star-light.svg');
  background-repeat: repeat;
  background-size: 64px 64px;
}

.divider-pattern {
  height: 30px;
  background-image: url('../images/pattern-star.svg');
  background-repeat: repeat-x;
  background-size: 30px 30px;
  background-position: center;
  opacity: 0.9;
}

/* =========================================================================
   UTILITY BAR — date / hijri / iqama ticker (fixed above navbar)
   ========================================================================= */

.utility-bar {
  background: var(--forest-dark);
  color: var(--sand);
  font-family: var(--font-data);
  font-size: 0.82rem;
  border-bottom: 1px solid rgba(246,241,231,0.08);
}
.utility-bar .container-fluid,
.utility-bar .container { padding-top: 0.5rem; padding-bottom: 0.5rem; }

.utility-bar .u-date {
  color: rgba(246,241,231,0.75);
  letter-spacing: 0.02em;
}

.utility-bar .u-jumua {
  color: var(--brass-light);
  font-weight: 600;
}

.utility-bar .u-links a {
  color: rgba(246,241,231,0.85);
  margin-left: 1.1rem;
  font-size: 0.78rem;
}
.utility-bar .u-links a:hover { color: var(--brass-light); }

.lang-switch {
  display: inline-flex;
  border: 1px solid rgba(246,241,231,0.25);
  border-radius: var(--radius-pill);
  overflow: hidden;
}
.lang-switch button {
  background: transparent;
  border: none;
  color: rgba(246,241,231,0.8);
  font-family: var(--font-data);
  font-size: 0.72rem;
  padding: 0.2rem 0.65rem;
  cursor: pointer;
}
.lang-switch button.active { background: var(--brass); color: var(--forest-dark); font-weight: 700; }

/* =========================================================================
   NAVBAR
   ========================================================================= */

.navbar-mosque {
  background: var(--sand);
  padding: 0.9rem 0;
  border-bottom: 1px solid var(--sand-line);
}

.navbar-brand-mosque {
  display: flex;
  align-items: center;
  gap: 0.7rem;
}
.navbar-brand-mosque img { width: 50px; height: auto; }
.navbar-brand-mosque .brand-text { line-height: 1.15; }
.navbar-brand-mosque .brand-text .brand-name {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.05rem;
  line-height: 1.15;
  color: var(--forest-dark);
  display: block;
  white-space: nowrap;
}
@media (max-width: 400px) {
  .navbar-brand-mosque .brand-text .brand-name { font-size: 0.92rem; }
}
.navbar-brand-mosque .brand-text .brand-sub {
  font-family: var(--font-accent);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  color: var(--brass);
  text-transform: uppercase;
}

.navbar-mosque .nav-link {
  font-weight: 600;
  font-size: 0.92rem;
  color: var(--ink);
  padding: 0.5rem 0.9rem !important;
  position: relative;
}
.navbar-mosque .nav-link:hover,
.navbar-mosque .nav-link.active { color: var(--forest); }
.navbar-mosque .nav-link.active::after {
  content: "";
  position: absolute;
  left: 0.9rem; right: 0.9rem; bottom: 0.15rem;
  height: 2px;
  background: var(--brass);
  border-radius: 2px;
}

.btn-donate-nav {
  background: var(--brass);
  color: var(--white) !important;
  border-radius: var(--radius-pill);
  padding: 0.55rem 1.4rem !important;
  font-weight: 700 !important;
  transition: background 0.2s var(--ease), transform 0.2s var(--ease);
}
.btn-donate-nav:hover { background: var(--forest); transform: translateY(-1px); }

/* =========================================================================
   BUTTONS
   ========================================================================= */

.btn-brass {
  background: var(--brass);
  border: 1px solid var(--brass);
  color: var(--white);
  border-radius: var(--radius-pill);
  padding: 0.75rem 1.85rem;
  font-weight: 700;
  font-size: 0.95rem;
  transition: all 0.22s var(--ease);
}
.btn-brass:hover { background: var(--brass-light); border-color: var(--brass-light); color: var(--forest-dark); transform: translateY(-2px); }

.btn-forest {
  background: var(--forest);
  border: 1px solid var(--forest);
  color: var(--white);
  border-radius: var(--radius-pill);
  padding: 0.75rem 1.85rem;
  font-weight: 700;
  font-size: 0.95rem;
  transition: all 0.22s var(--ease);
}
.btn-forest:hover { background: var(--forest-dark); color: var(--white); transform: translateY(-2px); }

.btn-outline-cream {
  background: transparent;
  border: 1.5px solid rgba(246,241,231,0.55);
  color: var(--sand);
  border-radius: var(--radius-pill);
  padding: 0.7rem 1.8rem;
  font-weight: 700;
  font-size: 0.95rem;
  transition: all 0.22s var(--ease);
}
.btn-outline-cream:hover { background: var(--sand); color: var(--forest-dark); border-color: var(--sand); }

.btn-outline-forest {
  background: transparent;
  border: 1.5px solid var(--forest);
  color: var(--forest);
  border-radius: var(--radius-pill);
  padding: 0.7rem 1.8rem;
  font-weight: 700;
  font-size: 0.95rem;
  transition: all 0.22s var(--ease);
}
.btn-outline-forest:hover { background: var(--forest); color: var(--white); }

/* Selected state for radio "pill" buttons (donation type etc.). Bootstrap's .btn-check only colours
   its own .btn-outline-* variants, so our custom button needs its own checked / focus styles. */
.btn-check:checked + .btn-outline-forest,
.btn-check:active + .btn-outline-forest,
.btn-outline-forest.active {
  background: var(--forest);
  border-color: var(--forest);
  color: var(--white);
  box-shadow: 0 0 0 3px rgba(28, 58, 87, 0.18);
}
.btn-check:focus-visible + .btn-outline-forest { box-shadow: 0 0 0 3px rgba(181, 144, 60, 0.45); }
.btn-check:checked + .btn-outline-forest::before { content: "\2713\00a0"; }

.btn-sm-pill { padding: 0.45rem 1.15rem; font-size: 0.82rem; border-radius: var(--radius-pill); font-weight: 700; }

/* =========================================================================
   HERO
   ========================================================================= */

.hero {
  position: relative;
  background: radial-gradient(ellipse 120% 90% at 20% -10%, #135A48 0%, var(--forest) 45%, var(--forest-dark) 100%);
  color: var(--sand);
  overflow: hidden;
  padding-top: 4.5rem;
}

.hero .rosette-decor {
  position: absolute;
  top: -60px; right: -60px;
  width: 420px; height: 420px;
  opacity: 0.9;
  pointer-events: none;
}

.hero .hero-skyline {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  width: 100%; height: 140px;
  object-fit: cover;
  object-position: bottom;
  pointer-events: none;
}

.hero-eyebrow {
  font-family: var(--font-accent);
  color: var(--brass-light);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  font-size: 0.85rem;
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
}
.hero-eyebrow::before { content: ""; width: 30px; height: 1px; background: var(--brass-light); }

.hero h1 {
  color: var(--white);
  font-size: clamp(2.4rem, 5vw, 3.75rem);
  line-height: 1.08;
}

.hero .lede {
  color: rgba(246,241,231,0.82);
  font-size: 1.1rem;
  max-width: 560px;
}

/* Floating "next prayer" card on the hero */
.next-prayer-card {
  background: rgba(246,241,231,0.97);
  border-radius: var(--radius-lg);
  padding: 1.6rem 1.7rem;
  box-shadow: var(--shadow-soft);
  color: var(--ink);
  position: relative;
  overflow: hidden;
}
.next-prayer-card::before {
  content: "";
  position: absolute; inset: 0;
  background-image: url('../images/pattern-star.svg');
  background-size: 90px 90px;
  opacity: 0.35;
  pointer-events: none;
}
.next-prayer-card .np-label {
  font-family: var(--font-accent);
  font-size: 0.78rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--brass);
}
.next-prayer-card .np-name {
  font-family: var(--font-display);
  font-size: 2rem;
  color: var(--forest-dark);
  font-weight: 600;
}
.next-prayer-card .np-countdown {
  font-family: var(--font-data);
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--forest);
  letter-spacing: 0.02em;
}
.next-prayer-card .np-meta { font-size: 0.85rem; color: #5B6960; }

/* =========================================================================
   PRAYER TIMES
   ========================================================================= */

.prayer-strip {
  background: var(--white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  overflow: hidden;
}

.prayer-row {
  display: grid;
  grid-template-columns: 1.4fr repeat(2, 1fr);
  align-items: center;
  padding: 1rem 1.5rem;
  border-bottom: 1px solid var(--sand-line);
  transition: background 0.2s var(--ease);
}
.prayer-row:last-child { border-bottom: none; }
.prayer-row.header {
  background: var(--forest-tint);
  font-family: var(--font-accent);
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--forest);
}
.prayer-row.current { background: var(--brass-tint); }
.prayer-row .p-name {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.05rem;
  color: var(--forest-dark);
  display: flex;
  align-items: center;
  gap: 0.6rem;
}
.prayer-row.current .p-name::before {
  content: "";
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--brass);
  display: inline-block;
}
.prayer-row .p-time {
  font-family: var(--font-data);
  font-size: 1.05rem;
  text-align: center;
  color: var(--ink);
}
.prayer-row .p-sub { font-size: 0.72rem; color: #7A8880; text-align:center; }

/* =========================================================================
   CARDS
   ========================================================================= */

.card-mosque {
  background: var(--white);
  border: none;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-card);
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease);
}
.card-mosque:hover { transform: translateY(-6px); box-shadow: 0 24px 48px -20px rgba(27,36,32,0.28); }
/* Equal-height cards are opt-in via Bootstrap's .h-100 (added on cards that
   sit side-by-side in a row, e.g. news/campaign/event/stat cards). Without
   this, .card-mosque used to default to height:100% — harmless when a card
   is the sole occupant of its column, but inside a Bootstrap row (which
   stretches columns to match the tallest one) every OTHER stacked card in a
   sidebar column would also inflate to fill the whole column height,
   producing large blank card-coloured gaps beneath normal-sized content
   (seen on the prayer-times sidebar, dashboard, donate and contact pages). */

.feature-tile {
  background: var(--white);
  border-radius: var(--radius-md);
  padding: 2rem 1.75rem;
  height: 100%;
  box-shadow: var(--shadow-card);
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease);
  border-top: 3px solid transparent;
}
.feature-tile:hover { transform: translateY(-6px); border-top-color: var(--brass); }
.feature-tile img { margin-bottom: 1.1rem; }
.feature-tile h3 { font-size: 1.2rem; margin-bottom: 0.5rem; }
.feature-tile p { color: #5B6960; font-size: 0.92rem; margin-bottom: 0; }

.illus-card {
  border-radius: var(--radius-md);
  overflow: hidden;
  position: relative;
  box-shadow: var(--shadow-card);
}
.illus-card img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform 0.5s var(--ease); }
.illus-card:hover img { transform: scale(1.06); }
.illus-card .illus-caption {
  position: absolute; left: 0; right: 0; bottom: 0;
  padding: 1.1rem 1.2rem;
  background: linear-gradient(0deg, rgba(9,50,38,0.88), transparent);
  color: var(--sand);
}
.illus-card .illus-caption .cap-eyebrow { font-family: var(--font-accent); font-size: 0.7rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--brass-light); }
.illus-card .illus-caption h4 { color: var(--white); font-size: 1.05rem; margin-bottom: 0; }

.badge-mosque {
  font-family: var(--font-accent);
  font-size: 0.7rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  background: var(--brass-tint);
  color: var(--brass);
  border-radius: var(--radius-pill);
  padding: 0.32rem 0.85rem;
  display: inline-block;
}
.badge-mosque.on-dark { background: rgba(246,241,231,0.15); color: var(--brass-light); }

/* Event card */
.event-card { display: flex; gap: 1.1rem; padding: 1.2rem; }
.event-date-block {
  flex: 0 0 68px;
  background: var(--forest);
  color: var(--sand);
  border-radius: var(--radius-sm);
  text-align: center;
  padding: 0.6rem 0.4rem;
  height: fit-content;
}
.event-date-block .ed-day { font-family: var(--font-display); font-size: 1.5rem; font-weight: 600; line-height: 1; }
.event-date-block .ed-month { font-family: var(--font-accent); font-size: 0.68rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--brass-light); }

/* News card */
.news-card .news-meta { font-size: 0.78rem; color: #7A8880; font-family: var(--font-data); }
.news-card h3 { font-size: 1.15rem; }

/* Campaign / donation progress card */
.campaign-card { padding: 1.6rem; }
.progress-mosque {
  height: 10px; border-radius: var(--radius-pill); background: var(--sand-deep); overflow: hidden;
}
.progress-mosque .bar { height: 100%; background: linear-gradient(90deg, var(--brass), var(--brass-light)); border-radius: var(--radius-pill); }

/* Testimonial */
.testimonial-card { padding: 2rem; }
.testimonial-card p { font-family: var(--font-display); font-size: 1.15rem; font-style: italic; color: var(--forest-dark); }

/* =========================================================================
   AMOUNT SELECTOR (donations)
   ========================================================================= */

.amount-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.75rem; }
.amount-option {
  border: 1.5px solid var(--sand-line);
  background: var(--white);
  border-radius: var(--radius-md);
  padding: 0.9rem 0.5rem;
  text-align: center;
  font-family: var(--font-data);
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--forest-dark);
  cursor: pointer;
  transition: all 0.18s var(--ease);
}
.amount-option:hover { border-color: var(--brass); }
.amount-option.selected { background: var(--forest); border-color: var(--forest); color: var(--sand); }
.amount-option:focus-visible { outline: 3px solid rgba(181, 144, 60, 0.55); outline-offset: 2px; }

/* Donate page: "One-off donation" / "Chanda" switch */
.give-switch { display: flex; gap: 0.5rem; background: var(--sand-deep); border-radius: var(--radius-pill); padding: 0.35rem; }
.give-switch .btn-check + label {
  flex: 1; text-align: center; border-radius: var(--radius-pill); padding: 0.7rem 1rem; margin: 0;
  font-weight: 700; font-size: 0.92rem; color: #5B6960; cursor: pointer; transition: all 0.2s var(--ease);
}
.give-switch .btn-check:checked + label { background: var(--forest); color: var(--sand); box-shadow: 0 2px 8px rgba(0,0,0,.15); }
.give-switch .btn-check:focus-visible + label { outline: 3px solid rgba(181, 144, 60, 0.55); }

.freq-toggle { display: inline-flex; background: var(--sand-deep); border-radius: var(--radius-pill); padding: 0.3rem; }
.freq-toggle button {
  border: none; background: transparent; padding: 0.55rem 1.4rem; border-radius: var(--radius-pill);
  font-weight: 700; font-size: 0.88rem; color: #5B6960; cursor: pointer; transition: all 0.2s var(--ease);
}
.freq-toggle button.active { background: var(--forest); color: var(--sand); }

/* =========================================================================
   FORMS
   ========================================================================= */

.form-mosque label { font-weight: 600; font-size: 0.88rem; color: var(--forest-dark); margin-bottom: 0.35rem; }
.form-mosque .form-control, .form-mosque .form-select {
  border: 1.5px solid var(--sand-line);
  border-radius: var(--radius-sm);
  padding: 0.7rem 0.95rem;
  background: var(--white);
  font-size: 0.95rem;
}
.form-mosque .form-control:focus, .form-mosque .form-select:focus {
  border-color: var(--brass);
  box-shadow: 0 0 0 3px rgba(184,134,59,0.16);
}
.form-mosque .input-group-text { background: var(--sand-deep); border: 1.5px solid var(--sand-line); color: var(--forest); font-weight: 700; }

.auth-panel {
  background: var(--white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-soft);
  overflow: hidden;
}
.auth-side {
  background: linear-gradient(160deg, var(--forest) 0%, var(--forest-dark) 100%);
  color: var(--sand);
  position: relative;
  padding: 3rem 2.5rem;
}

/* =========================================================================
   FOOTER
   ========================================================================= */

.footer-mosque {
  background: var(--forest-dark);
  color: rgba(246,241,231,0.75);
  position: relative;
}
.footer-mosque h5 { color: var(--sand); font-family: var(--font-display); font-size: 1.05rem; margin-bottom: 1.1rem; }
.footer-mosque a { color: rgba(246,241,231,0.72); }
.footer-mosque a:hover { color: var(--brass-light); }
.footer-mosque .foot-links li { margin-bottom: 0.55rem; font-size: 0.92rem; }
.footer-mosque .foot-links li.d-flex { align-items: flex-start; }
.footer-mosque .foot-links li.d-flex img { margin-top: 0.2rem; }
.footer-bottom { border-top: 1px solid rgba(246,241,231,0.1); font-size: 0.82rem; color: rgba(246,241,231,0.5); }
.social-circle {
  width: 38px; height: 38px;
  border-radius: 50%;
  border: 1px solid rgba(246,241,231,0.25);
  display: inline-flex; align-items: center; justify-content: center;
  color: var(--sand);
  transition: all 0.2s var(--ease);
}
.social-circle:hover { background: var(--brass); border-color: var(--brass); color: var(--forest-dark); }

.newsletter-strip {
  background: var(--brass);
  color: var(--forest-dark);
}
.newsletter-strip input.form-control {
  border-radius: var(--radius-pill);
  border: none;
  padding: 0.8rem 1.3rem;
}
.newsletter-strip .btn-forest { padding: 0.8rem 1.7rem; }

/* =========================================================================
   MISC UTILITIES
   ========================================================================= */

.reveal { opacity: 0; transform: translateY(18px); transition: opacity 0.7s var(--ease), transform 0.7s var(--ease); }
.reveal.in-view { opacity: 1; transform: translateY(0); }

.stat-num { font-family: var(--font-display); font-size: 2.6rem; font-weight: 600; color: var(--forest-dark); }
.stat-label { font-family: var(--font-accent); font-size: 0.78rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--brass); }


/* Hero stat counters — force 3-across, never wrap to a new line */
.hero-stats-row {
  display: flex;
  flex-wrap: nowrap;
  gap: 1.25rem;
}
.hero-stats-row > div {
  flex: 1 1 0;
  min-width: 0; /* allows text to shrink instead of overflowing the card */
}
.hero-stats-row .stat-num {
  font-size: clamp(1.4rem, 4.5vw, 2.6rem);
  white-space: nowrap;
}
.hero-stats-row .stat-label {
  display: block;
  white-space: normal;
  line-height: 1.25;
}

@media (max-width: 575.98px) {
  .hero-stats-row { gap: 0.75rem; }
  .hero-stats-row .stat-num { font-size: 1.5rem; }
  .hero-stats-row .stat-label { font-size: 0.68rem; }
}


.avatar-ring {
  width: 46px; height: 46px; border-radius: 50%;
  background: var(--forest-tint); color: var(--forest);
  display: inline-flex; align-items: center; justify-content: center;
  font-family: var(--font-display); font-weight: 600;
}

.dashboard-side-link {
  display: flex; align-items: center; gap: 0.7rem;
  padding: 0.75rem 1rem; border-radius: var(--radius-sm);
  color: var(--ink); font-weight: 600; font-size: 0.92rem;
}
.dashboard-side-link.active, .dashboard-side-link:hover { background: var(--forest-tint); color: var(--forest); }

.table-mosque th { font-family: var(--font-accent); font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--brass); border-bottom: 2px solid var(--sand-line); }
.table-mosque td { vertical-align: middle; font-size: 0.92rem; border-bottom: 1px solid var(--sand-line); }

/* Only translated chrome elements switch to the Arabic-capable accent font —
   the whole body must NOT switch font, since most body copy stays English
   until it's translated too, and Reem Kufi has no Latin glyphs. */
.rtl { direction: rtl; text-align: right; }
.rtl [data-i18n] { font-family: var(--font-accent); }
.rtl .navbar-nav, .rtl .u-links { direction: rtl; }

/* Category filter pills — Events / News / Gallery */
.filter-pills { display: flex; flex-wrap: wrap; gap: 0.6rem; }
.filter-pills button {
  border: 1.5px solid var(--sand-line);
  background: var(--white);
  color: var(--ink);
  border-radius: var(--radius-pill);
  padding: 0.5rem 1.2rem;
  font-weight: 600;
  font-size: 0.86rem;
  cursor: pointer;
  transition: all 0.2s var(--ease);
}
.filter-pills button:hover { border-color: var(--brass); }
.filter-pills button.active { background: var(--forest); border-color: var(--forest); color: var(--sand); }

.skip-link {
  position: absolute; left: -999px; top: 0; background: var(--forest); color: var(--white);
  padding: 0.6rem 1rem; z-index: 2000; border-radius: 0 0 8px 0;
}
.skip-link:focus { left: 0; }

/* Language attribution note styling for gallery placeholder pieces */
.art-note { font-size: 0.72rem; color: #8A968F; }

@media (max-width: 575.98px) {
  .amount-grid { grid-template-columns: repeat(2, 1fr); }
  .event-card { flex-direction: column; }
  .stat-num { font-size: 2rem; }
  .next-prayer-card { padding: 1.3rem 1.25rem; }
  .next-prayer-card .np-name { font-size: 1.6rem; }
  .next-prayer-card .np-countdown { font-size: 1.3rem; }
}

/* =========================================================================
   RESPONSIVE FIXES — small phones (prayer strip / utility bar / navbar)
   ========================================================================= */
@media (max-width: 430px) {
  .prayer-row {
    grid-template-columns: 1.25fr 1fr 1fr;
    padding: 0.8rem 0.85rem;
    column-gap: 0.35rem;
  }
  .prayer-row .p-name { font-size: 0.86rem; gap: 0.4rem; }
  .prayer-row .p-name img { width: 13px; flex-shrink: 0; }
  .prayer-row .p-time { font-size: 0.86rem; }
  .prayer-row .p-sub { font-size: 0.64rem; }
  .prayer-row.header { font-size: 0.68rem; letter-spacing: 0.04em; }

  .btn-donate-nav { padding: 0.5rem 1.1rem !important; font-size: 0.88rem; }
  .navbar-brand-mosque img { width: 42px; }
}

@media (max-width: 380px) {
  .utility-bar { font-size: 0.74rem; }
  .lang-switch button { padding: 0.18rem 0.5rem; font-size: 0.68rem; }
}