/* SABEEL
   Everything a visitor needs, without the ceremony.

   Nav behaviour: a plain static bar, present from the first pixel and never
   moving. For a room run by volunteers, the site should behave the way a door
   behaves.

   One family, Bricolage Grotesque, worked across its optical-size and weight
   axes so the display and the body are visibly related. That single-family
   discipline is where the premium read comes from here, since there is no
   cinematic hero to lean on. Deep forest as the only colour, which is neither
   Meridian's teal nor Ablaq's rust, and deliberately not the bright green the
   whole masjid-template category defaults to. */

:root {
  --paper: #FCFCFA;
  --tint: #F3F3EF;
  --ink: #14171A;      /* 16.9 on paper */
  --body: #3D4448;     /* 9.2 */
  --muted: #6B7276;    /* 4.9 */
  --line: #E2E2DC;
  --green: #1F4D3D;    /* 8.6 on paper */
  --green-dk: #163A2D;
  --green-lt: #E9F0ED;

  --sh-sm: 0 1px 2px rgba(20,23,26,.05);
  --sh-md: 0 12px 32px -14px rgba(20,23,26,.18);
  --sh-lg: 0 28px 64px -26px rgba(20,23,26,.30);
  --ease: cubic-bezier(.22,1,.36,1);
  --wrap: 1160px;
  --navh: 72px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--navh) + 20px); }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body { margin: 0; background: var(--paper); color: var(--body); font-family: 'Bricolage Grotesque', ui-sans-serif, system-ui, sans-serif; font-size: 17px; line-height: 1.65; -webkit-font-smoothing: antialiased; }

h1, h2, h3 { color: var(--ink); margin: 0; font-weight: 600; text-wrap: balance; }
h1 { font-size: clamp(38px, 4.6vw, 66px); line-height: 1.04; letter-spacing: -.03em; }
h2 { font-size: clamp(28px, 3.2vw, 44px); line-height: 1.1; letter-spacing: -.025em; }
h3 { font-size: 19px; line-height: 1.35; letter-spacing: -.01em; }
p { margin: 0; }
a { color: var(--green); }
img { display: block; max-width: 100%; }
:focus-visible { outline: 2px solid var(--green); outline-offset: 3px; border-radius: 3px; }
.sec--ink :focus-visible { outline-color: var(--paper); }

.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 16px; z-index: 300; background: var(--ink); color: #fff; padding: 12px 18px; border-radius: 999px; }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 clamp(20px, 4vw, 40px); }
.num { font-variant-numeric: tabular-nums; }
.eyebrow { display: inline-block; font-size: 12px; font-weight: 600; letter-spacing: .13em; text-transform: uppercase; color: var(--green); margin-bottom: 14px; }
.eyebrow--light { color: #8FCBB4; }
.tag { display: inline-block; font-size: 12.5px; font-weight: 600; letter-spacing: .04em; color: var(--green); background: var(--green-lt); padding: 7px 14px; border-radius: 999px; margin-bottom: 26px; }

.preview-flag { position: fixed; bottom: 14px; right: 14px; z-index: 200; background: rgba(20,23,26,.9); color: #fff; backdrop-filter: blur(8px); font-size: 11.5px; padding: 7px 13px; border-radius: 999px; }

/* ---------------- Static nav ---------------- */

.nav { position: sticky; top: 0; z-index: 100; background: rgba(252,252,250,.92); backdrop-filter: blur(14px); border-bottom: 1px solid var(--line); }
.nav-in { height: var(--navh); display: flex; align-items: center; gap: 30px; }
.wordmark { font-size: 20px; font-weight: 700; letter-spacing: -.02em; color: var(--ink); text-decoration: none; }
.nav-links { display: flex; gap: 26px; margin-left: 10px; }
.nav-links a { color: var(--body); text-decoration: none; font-size: 15px; font-weight: 500; }
.nav-links a:hover { color: var(--green); }
.nav-right { margin-left: auto; display: flex; align-items: center; gap: 16px; }
.nav-next { font-size: 14px; color: var(--muted); font-variant-numeric: tabular-nums; }
.nav-next b { color: var(--green); font-weight: 600; }

.btn { display: inline-flex; align-items: center; justify-content: center; height: 44px; padding: 0 22px; border-radius: 999px; font-size: 15px; font-weight: 600; text-decoration: none; border: 0; cursor: pointer; font-family: inherit; transition: background .2s, color .2s, transform .18s var(--ease), border-color .2s; }
.btn:hover { transform: translateY(-1px); }
.btn--lg { height: 52px; padding: 0 28px; font-size: 16px; }
.btn--fill { background: var(--green); color: #fff; }
.btn--fill:hover { background: var(--green-dk); }
.btn--line { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--line); }
.btn--line:hover { box-shadow: inset 0 0 0 1.5px var(--ink); }

.burger { display: none; width: 44px; height: 44px; border: 0; background: transparent; cursor: pointer; flex-direction: column; justify-content: center; gap: 6px; padding: 0 10px; }
.burger span { height: 2px; background: var(--ink); border-radius: 2px; }
.drawer { position: fixed; inset: var(--navh) 0 0 0; z-index: 99; background: var(--paper); padding: 26px clamp(20px,4vw,40px); display: flex; flex-direction: column; gap: 2px; }
.drawer[hidden] { display: none; }
@media (min-width: 861px) { .drawer { display: none !important; } }
.drawer a { font-size: 26px; font-weight: 600; color: var(--ink); text-decoration: none; padding: 13px 0; border-bottom: 1px solid var(--line); letter-spacing: -.02em; }
.drawer .btn { margin-top: 22px; align-self: flex-start; border-bottom: 0; font-size: 15px; color: #fff; }

/* ---------------- Centered hero over a faint lattice ---------------- */

.hero { background-color: var(--paper); background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='64' height='64'%3E%3Cg fill='none' stroke='%231F4D3D' stroke-opacity='.055'%3E%3Cpath d='M32 4 L60 32 L32 60 L4 32 Z'/%3E%3Crect x='12' y='12' width='40' height='40'/%3E%3C/g%3E%3C/svg%3E"); padding: clamp(56px, 8vh, 96px) 0 0; }
.hero-in { text-align: center; display: flex; flex-direction: column; align-items: center; }
.hero h1 { font-size: clamp(44px, 6vw, 84px); }
.hero-sub { margin-top: 22px; font-size: 18.5px; max-width: 52ch; }
.hero-cta { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; margin-top: 32px; }

.hero-stage { position: relative; margin-top: clamp(40px, 6vh, 72px); padding-bottom: 90px; }
.hero-photo { width: 100%; aspect-ratio: 21/9; object-fit: cover; border-radius: 16px; }
.today-card {
  position: absolute; left: 50%; bottom: 0; transform: translateX(-50%);
  width: min(920px, calc(100% - 32px));
  background: var(--paper); border: 1px solid var(--line); border-radius: 16px;
  box-shadow: var(--sh-lg); padding: 20px 24px 16px;
}
.tc-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px 24px; flex-wrap: wrap; padding-bottom: 14px; border-bottom: 1px solid var(--line); }
.tc-loc { font-size: 13.5px; color: var(--muted); }
.tc-next { display: flex; align-items: baseline; gap: 9px; font-size: 15px; }
.tc-next em { font-style: normal; font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.tc-next b { color: var(--green); font-weight: 700; }
.tc-next span { font-weight: 700; color: var(--ink); }
.tc-next i { font-style: normal; font-size: 13px; color: var(--muted); }
.tc-times { display: grid; grid-template-columns: repeat(5, minmax(0,1fr)); }
.tc-cell { text-align: center; padding: 14px 6px 10px; border-radius: 10px; }
.tc-cell.is-next { background: var(--green-lt); }
.tc-name { display: block; font-size: 12px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.tc-cell.is-next .tc-name { color: var(--green); }
.tc-time { display: block; margin-top: 4px; font-size: 19px; font-weight: 700; color: var(--ink); }
.tc-cell.is-next .tc-time { color: var(--green); }

/* ---------------- Sections ---------------- */

.sec { padding: clamp(76px, 9vw, 132px) 0; }
.sec--tint { background: var(--tint); }
.sec--ink { background: var(--ink); color: rgba(255,255,255,.76); }
.sec--ink h2 { color: #fff; }
.sec-head { max-width: 620px; margin-bottom: 48px; }
.sec-head--row { max-width: none; display: flex; align-items: end; justify-content: space-between; gap: 24px; flex-wrap: wrap; }
.sec-sub { margin-top: 16px; font-size: 18px; max-width: 56ch; }
.link-arrow { font-size: 15px; font-weight: 600; text-decoration: none; white-space: nowrap; }
.link-arrow::after { content: ' →'; }

[data-reveal] { opacity: 0; transform: translateY(16px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
[data-reveal].is-in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { [data-reveal] { opacity: 1; transform: none; transition: none; } }

/* Times */
.times-head { display: flex; align-items: end; justify-content: space-between; gap: 24px; flex-wrap: wrap; margin-bottom: 36px; }
.times-meta { display: flex; gap: 22px; font-size: 14.5px; color: var(--muted); font-variant-numeric: tabular-nums; }
.times-panel { border-top: 2px solid var(--ink); }
.pt-table { width: 100%; border-collapse: collapse; }
.pt-table thead { display: none; }
.pt-table tbody th { text-align: left; font-weight: 600; padding: 24px 0; border-bottom: 1px solid var(--line); }
.pt-table tbody td { text-align: right; padding: 24px 0 24px 28px; border-bottom: 1px solid var(--line); font-size: 19px; color: var(--muted); font-variant-numeric: tabular-nums; }
.pt-table tbody td:last-child { color: var(--ink); font-weight: 600; font-size: 23px; }
.pt-name { font-size: 27px; font-weight: 600; color: var(--ink); letter-spacing: -.025em; }
.pt-ar { display: inline-block; font-family: 'Noto Naskh Arabic', serif; font-size: 15px; color: var(--muted); margin-left: 12px; }
.pt-table tr.is-next th, .pt-table tr.is-next td { background: var(--green-lt); }
.pt-table tr.is-next .pt-name, .pt-table tr.is-next td:last-child { color: var(--green); }
.times-jumuah { display: flex; align-items: center; gap: 32px; flex-wrap: wrap; padding-top: 26px; }
.tj { display: flex; align-items: baseline; gap: 10px; font-size: 15px; color: var(--muted); }
.tj b { font-size: 18px; color: var(--ink); }
.times-jumuah .link-arrow { margin-left: auto; }

/* About */
.notes { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 32px; }
.note { padding-top: 22px; border-top: 2px solid var(--ink); }
.note p { margin-top: 8px; font-size: 15.5px; color: var(--muted); }
.wide-photo { margin: 56px 0 0; }
.wide-photo img { width: 100%; aspect-ratio: 21/9; object-fit: cover; border-radius: 6px; }
.wide-photo figcaption { margin-top: 14px; font-size: 14.5px; color: var(--muted); }

/* Events */
.ev-grid { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 22px; }
.ev-card { background: var(--paper); border: 1px solid var(--line); border-radius: 8px; overflow: hidden; display: flex; flex-direction: column; transition: border-color .25s, transform .3s var(--ease); }
.ev-card:hover { border-color: var(--ink); transform: translateY(-3px); }
.ev-media { position: relative; aspect-ratio: 3/2; overflow: hidden; }
.ev-media img { width: 100%; height: 100%; object-fit: cover; }
.ev-date { position: absolute; left: 12px; top: 12px; background: var(--paper); border-radius: 6px; padding: 7px 11px; text-align: center; line-height: 1; }
.ev-date b { display: block; font-size: 19px; font-weight: 700; color: var(--ink); }
.ev-date i { font-style: normal; font-size: 10px; letter-spacing: .09em; color: var(--muted); }
.ev-body { padding: 18px 18px 20px; display: flex; flex-direction: column; flex: 1; }
.ev-tag { font-size: 11px; font-weight: 600; letter-spacing: .11em; text-transform: uppercase; color: var(--green); }
.ev-title { margin: 7px 0 5px; font-size: 17.5px; }
.ev-meta { font-size: 14px; color: var(--muted); }
.ev-foot { margin-top: auto; padding-top: 16px; display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.ev-price { font-size: 14.5px; font-weight: 600; color: var(--ink); }
.ev-btn { height: 38px; padding: 0 16px; border-radius: 999px; border: 1px solid var(--line); background: var(--paper); color: var(--ink); font: inherit; font-size: 14px; font-weight: 600; cursor: pointer; transition: background .2s, color .2s, border-color .2s; }
.ev-btn:hover { background: var(--green); color: #fff; border-color: var(--green); }
.ev-btn.is-done { background: var(--green-lt); color: var(--green); border-color: transparent; cursor: default; }

/* Give */
.give-grid { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,430px); gap: 60px; align-items: center; }
.give-copy p { margin-top: 18px; max-width: 46ch; font-size: 17.5px; }
.give-points { list-style: none; margin: 24px 0 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.give-points li { position: relative; padding-left: 24px; font-size: 15.5px; }
.give-points li::before { content: ''; position: absolute; left: 0; top: 10px; width: 8px; height: 8px; border-radius: 50%; background: #8FCBB4; }

.give-card { background: var(--paper); border-radius: 14px; padding: 28px; color: var(--body); box-shadow: var(--sh-lg); }
.dn-progress { margin-bottom: 22px; }
.dn-bar { height: 6px; border-radius: 999px; background: var(--line); overflow: hidden; }
.dn-bar i { display: block; height: 100%; border-radius: 999px; background: var(--green); transition: width 1.1s var(--ease); }
.dn-figures { display: flex; align-items: baseline; gap: 8px; margin-top: 11px; }
.dn-raised { font-size: 26px; font-weight: 700; color: var(--ink); letter-spacing: -.02em; }
.dn-goal { font-size: 14px; color: var(--muted); }
.dn-form { display: flex; flex-direction: column; gap: 13px; }
.dn-freq { display: grid; grid-template-columns: 1fr 1fr; gap: 5px; padding: 4px; background: var(--tint); border-radius: 999px; }
.dn-freq button { height: 38px; border: 0; border-radius: 999px; background: transparent; font: inherit; font-size: 14.5px; font-weight: 600; color: var(--muted); cursor: pointer; }
.dn-freq button.is-on { background: var(--paper); color: var(--ink); box-shadow: var(--sh-sm); }
.dn-amounts { display: grid; grid-template-columns: repeat(4, 1fr); gap: 7px; }
.dn-amounts button { height: 46px; border-radius: 9px; border: 1.5px solid var(--line); background: var(--paper); font: inherit; font-size: 15px; font-weight: 600; color: var(--ink); cursor: pointer; transition: border-color .2s, background .2s, color .2s; }
.dn-amounts button:hover { border-color: var(--green); }
.dn-amounts button.is-on { border-color: var(--green); background: var(--green-lt); color: var(--green); }
.dn-other { grid-column: 1 / -1; }
.dn-other input { width: 100%; height: 46px; border-radius: 9px; border: 1.5px solid var(--line); padding: 0 15px; font: inherit; font-size: 15px; color: var(--ink); background: var(--paper); }
.dn-other input:focus { outline: none; border-color: var(--green); }
.dn-fund { display: flex; flex-direction: column; gap: 6px; font-size: 13px; font-weight: 600; color: var(--muted); }
.dn-fund select { height: 46px; border-radius: 9px; border: 1.5px solid var(--line); padding: 0 13px; font: inherit; font-size: 15px; color: var(--ink); background: var(--paper); }
.dn-fund select:focus { outline: none; border-color: var(--green); }
.dn-submit { height: 52px; border-radius: 999px; border: 0; background: var(--green); color: #fff; font: inherit; font-size: 16px; font-weight: 600; cursor: pointer; transition: background .2s; }
.dn-submit:hover { background: var(--green-dk); }
.dn-fine { font-size: 12.5px; color: var(--muted); text-align: center; }

/* Programs widget */
.pg-grid { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 22px; }
.pg-card { background: var(--paper); border: 1px solid var(--line); border-radius: 12px; padding: 24px; display: flex; flex-direction: column; transition: border-color .25s, transform .3s var(--ease); }
.pg-card:hover { border-color: var(--ink); transform: translateY(-3px); }
.pg-status { display: inline-flex; padding: 4px 11px; border-radius: 999px; font-size: 11px; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; }
.pg-status--open { background: var(--green-lt); color: var(--green); }
.pg-status--waitlist { background: #F5EEDA; color: #7A5F14; }
.pg-title { font-size: 19px; font-weight: 700; letter-spacing: -.015em; color: var(--ink); margin-top: 13px; }
.pg-desc { margin-top: 6px; font-size: 15px; color: var(--muted); flex: 1; }
.pg-meta { margin: 16px 0 0; display: grid; gap: 7px; }
.pg-meta div { display: flex; gap: 10px; font-size: 13.5px; border-top: 1px solid var(--line); padding-top: 7px; }
.pg-meta dt { color: var(--muted); width: 40px; flex-shrink: 0; }
.pg-meta dd { margin: 0; color: var(--ink); }
.pg-btn { margin-top: 16px; display: inline-flex; align-items: center; justify-content: center; height: 42px; border-radius: 999px; background: var(--green); color: #fff; font-size: 14px; font-weight: 600; text-decoration: none; transition: background .2s; }
.pg-btn:hover { background: var(--green-dk); }

/* Visit */
.visit-grid { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1fr); gap: 60px; align-items: start; }
.dl { margin: 32px 0 0; }
.dl > div { display: grid; grid-template-columns: 130px minmax(0,1fr); gap: 20px; padding: 14px 0; border-top: 1px solid var(--line); }
.dl dt { color: var(--muted); font-size: 14.5px; }
.dl dd { margin: 0; color: var(--ink); font-size: 16px; }
.arabic { font-family: 'Noto Naskh Arabic', serif; font-size: 22px; color: var(--muted); margin-top: 32px; }
.visit-media img { width: 100%; aspect-ratio: 4/5; object-fit: cover; border-radius: 6px; }

/* Footer */
.foot { background: var(--tint); border-top: 1px solid var(--line); padding: 64px 0 30px; }
.foot-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 36px; padding-bottom: 40px; border-bottom: 1px solid var(--line); }
.foot-name { font-size: 20px; font-weight: 700; color: var(--ink); letter-spacing: -.02em; }
.foot-ar { font-family: 'Noto Naskh Arabic', serif; font-size: 16px; color: var(--muted); margin-top: 5px; }
.foot h4 { font-size: 11.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); font-weight: 600; margin: 0 0 12px; }
.foot p, .foot-grid a { font-size: 15px; color: var(--body); text-decoration: none; display: block; margin-bottom: 6px; }
.foot-grid a:hover { color: var(--green); }
.foot-base { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 14px; padding-top: 24px; font-size: 13.5px; color: var(--muted); }
.credit a { color: var(--body); text-decoration: underline; text-underline-offset: 3px; }
.credit a:hover { color: var(--green); }

.uw-toast { position: fixed; left: 50%; bottom: 26px; transform: translate(-50%, 20px); z-index: 250; max-width: min(520px, calc(100vw - 32px)); background: var(--ink); color: #fff; padding: 15px 22px; border-radius: 12px; font-size: 14.5px; line-height: 1.5; box-shadow: var(--sh-lg); opacity: 0; pointer-events: none; transition: opacity .3s var(--ease), transform .3s var(--ease); }
.uw-toast.is-on { opacity: 1; transform: translate(-50%, 0); }

/* Monthly page */
.page-head { padding: 80px 0 50px; border-bottom: 1px solid var(--line); }
.page-head h1 { font-size: clamp(34px, 4.2vw, 56px); }
.page-head p { margin-top: 16px; max-width: 56ch; font-size: 17.5px; }
.month { width: 100%; border-collapse: collapse; }
.month th { text-align: right; font-size: 11.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); font-weight: 600; padding: 0 12px 14px; }
.month th:first-child { text-align: left; }
.month td { padding: 18px 12px; text-align: right; border-top: 1px solid var(--line); font-size: 17px; font-variant-numeric: tabular-nums; }
.month td:first-child { text-align: left; color: var(--ink); font-weight: 600; font-size: 19px; }
.month tr.is-next td { background: var(--green-lt); }

@media (max-width: 1024px) {
  .notes, .pg-grid { grid-template-columns: minmax(0,1fr); gap: 26px; }
  .pg-grid { grid-template-columns: repeat(2, minmax(0,1fr)); gap: 20px; }
  .ev-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .give-grid, .visit-grid { grid-template-columns: minmax(0,1fr); gap: 40px; }
  .foot-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
}
@media (max-width: 860px) {
  .nav-links, .nav-next { display: none; }
  .burger { display: flex; }
}
@media (max-width: 640px) {
  body { font-size: 16px; }
  .ev-grid, .pg-grid, .foot-grid { grid-template-columns: minmax(0,1fr); }
  .hero-photo { aspect-ratio: 4/3; }
  .hero-stage { padding-bottom: 150px; }
  .tc-times { grid-template-columns: repeat(5, minmax(0,1fr)); }
  .tc-time { font-size: 15px; }
  .tc-name { font-size: 10px; }
  .dn-amounts { grid-template-columns: repeat(2, 1fr); }
  .dl > div { grid-template-columns: minmax(0,1fr); gap: 3px; }
  .pt-name { font-size: 21px; }
  .pt-table tbody td { font-size: 15px; padding-left: 12px; }
  .pt-table tbody td:last-child { font-size: 19px; }
  .times-jumuah .link-arrow { margin-left: 0; }
  .wide-photo img { aspect-ratio: 4/3; }
}
