@font-face{font-family:'Cardo';font-style:italic;font-weight:400;font-display:swap;src:url(../fonts/cardo-400-italic-latin-ext.woff2) format('woff2');unicode-range:U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF}
@font-face{font-family:'Cardo';font-style:italic;font-weight:400;font-display:swap;src:url(../fonts/cardo-400-italic-latin.woff2) format('woff2');unicode-range:U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD}
@font-face{font-family:'Cardo';font-style:normal;font-weight:400;font-display:swap;src:url(../fonts/cardo-400-normal-latin-ext.woff2) format('woff2');unicode-range:U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF}
@font-face{font-family:'Cardo';font-style:normal;font-weight:400;font-display:swap;src:url(../fonts/cardo-400-normal-latin.woff2) format('woff2');unicode-range:U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD}
@font-face{font-family:'Cardo';font-style:normal;font-weight:700;font-display:swap;src:url(../fonts/cardo-700-normal-latin-ext.woff2) format('woff2');unicode-range:U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF}
@font-face{font-family:'Cardo';font-style:normal;font-weight:700;font-display:swap;src:url(../fonts/cardo-700-normal-latin.woff2) format('woff2');unicode-range:U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD}
@font-face{font-family:'Nunito Sans';font-style:italic;font-weight:300 900;font-display:swap;src:url(../fonts/nunitosans-300-900-italic-latin-ext.woff2) format('woff2');unicode-range:U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF}
@font-face{font-family:'Nunito Sans';font-style:italic;font-weight:300 900;font-display:swap;src:url(../fonts/nunitosans-300-900-italic-latin.woff2) format('woff2');unicode-range:U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD}
@font-face{font-family:'Nunito Sans';font-style:normal;font-weight:300 900;font-display:swap;src:url(../fonts/nunitosans-300-900-normal-latin-ext.woff2) format('woff2');unicode-range:U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF}
@font-face{font-family:'Nunito Sans';font-style:normal;font-weight:300 900;font-display:swap;src:url(../fonts/nunitosans-300-900-normal-latin.woff2) format('woff2');unicode-range:U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD}
@font-face{font-family:'Amiri';font-style:italic;font-weight:400;font-display:swap;src:url(../fonts/amiri-400-italic-arabic.woff2) format('woff2');unicode-range:U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC, U+102E0-102FB, U+10E60-10E7E, U+10EC2-10EC4, U+10EFC-10EFF, U+1EE00-1EE03, U+1EE05-1EE1F, U+1EE21-1EE22, U+1EE24, U+1EE27, U+1EE29-1EE32, U+1EE34-1EE37, U+1EE39, U+1EE3B, U+1EE42, U+1EE47, U+1EE49, U+1EE4B, U+1EE4D-1EE4F, U+1EE51-1EE52, U+1EE54, U+1EE57, U+1EE59, U+1EE5B, U+1EE5D, U+1EE5F, U+1EE61-1EE62, U+1EE64, U+1EE67-1EE6A, U+1EE6C-1EE72, U+1EE74-1EE77, U+1EE79-1EE7C, U+1EE7E, U+1EE80-1EE89, U+1EE8B-1EE9B, U+1EEA1-1EEA3, U+1EEA5-1EEA9, U+1EEAB-1EEBB, U+1EEF0-1EEF1}
@font-face{font-family:'Amiri';font-style:normal;font-weight:400;font-display:swap;src:url(../fonts/amiri-400-normal-arabic.woff2) format('woff2');unicode-range:U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC, U+102E0-102FB, U+10E60-10E7E, U+10EC2-10EC4, U+10EFC-10EFF, U+1EE00-1EE03, U+1EE05-1EE1F, U+1EE21-1EE22, U+1EE24, U+1EE27, U+1EE29-1EE32, U+1EE34-1EE37, U+1EE39, U+1EE3B, U+1EE42, U+1EE47, U+1EE49, U+1EE4B, U+1EE4D-1EE4F, U+1EE51-1EE52, U+1EE54, U+1EE57, U+1EE59, U+1EE5B, U+1EE5D, U+1EE5F, U+1EE61-1EE62, U+1EE64, U+1EE67-1EE6A, U+1EE6C-1EE72, U+1EE74-1EE77, U+1EE79-1EE7C, U+1EE7E, U+1EE80-1EE89, U+1EE8B-1EE9B, U+1EEA1-1EEA3, U+1EEA5-1EEA9, U+1EEAB-1EEBB, U+1EEF0-1EEF1}
@font-face{font-family:'Amiri';font-style:normal;font-weight:700;font-display:swap;src:url(../fonts/amiri-700-normal-arabic.woff2) format('woff2');unicode-range:U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC, U+102E0-102FB, U+10E60-10E7E, U+10EC2-10EC4, U+10EFC-10EFF, U+1EE00-1EE03, U+1EE05-1EE1F, U+1EE21-1EE22, U+1EE24, U+1EE27, U+1EE29-1EE32, U+1EE34-1EE37, U+1EE39, U+1EE3B, U+1EE42, U+1EE47, U+1EE49, U+1EE4B, U+1EE4D-1EE4F, U+1EE51-1EE52, U+1EE54, U+1EE57, U+1EE59, U+1EE5B, U+1EE5D, U+1EE5F, U+1EE61-1EE62, U+1EE64, U+1EE67-1EE6A, U+1EE6C-1EE72, U+1EE74-1EE77, U+1EE79-1EE7C, U+1EE7E, U+1EE80-1EE89, U+1EE8B-1EE9B, U+1EEA1-1EEA3, U+1EEA5-1EEA9, U+1EEAB-1EEBB, U+1EEF0-1EEF1}
@font-face{font-family:'Noto Nastaliq Urdu';font-style:normal;font-weight:400 700;font-display:swap;src:url(../fonts/notonastaliqurdu-400-normal-arabic.woff2) format('woff2');unicode-range:U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC, U+102E0-102FB, U+10E60-10E7E, U+10EC2-10EC4, U+10EFC-10EFF, U+1EE00-1EE03, U+1EE05-1EE1F, U+1EE21-1EE22, U+1EE24, U+1EE27, U+1EE29-1EE32, U+1EE34-1EE37, U+1EE39, U+1EE3B, U+1EE42, U+1EE47, U+1EE49, U+1EE4B, U+1EE4D-1EE4F, U+1EE51-1EE52, U+1EE54, U+1EE57, U+1EE59, U+1EE5B, U+1EE5D, U+1EE5F, U+1EE61-1EE62, U+1EE64, U+1EE67-1EE6A, U+1EE6C-1EE72, U+1EE74-1EE77, U+1EE79-1EE7C, U+1EE7E, U+1EE80-1EE89, U+1EE8B-1EE9B, U+1EEA1-1EEA3, U+1EEA5-1EEA9, U+1EEAB-1EEBB, U+1EEF0-1EEF1}

/* ==========================================================================
   msju.in v2 — "Siraj" design system
   Manuscript-inspired identity: warm paper ground, lapis ink, madder rubrics,
   Cardo display type with Nunito Sans text. Amiri (Arabic) and Noto Nastaliq
   Urdu (Urdu) carry the translated pages. All faces are self-hosted.
   ========================================================================== */

:root {
  --paper: #faf7f1;
  --paper-2: #f3eee4;
  --paper-3: #e8e1d2;
  --white: #fffdf9;
  --line: #ddd5c6;
  --line-strong: #bfb39c;
  --ink: #1a1c2c;
  --ink-2: #41445a;
  --ink-3: #6d7087;
  --lapis: #1f3f95;
  --lapis-2: #17307a;
  --lapis-3: #112459;
  --night: #0b1737;
  --lapis-soft: #e6ebf8;
  --lapis-tint: #c4d0ee;
  --lapis-text: #a9b8e3;
  --madder: #a5302b;
  --madder-2: #86241f;
  --madder-light: #e9a8a1;
  --madder-soft: #f7e5e2;
  --serif: 'Cardo', 'Georgia', 'Times New Roman', serif;
  --sans: 'Nunito Sans', system-ui, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  --arabic: 'Amiri', 'Scheherazade New', 'Traditional Arabic', serif;
  --urdu: 'Noto Nastaliq Urdu', 'Jameel Noori Nastaleeq', 'Urdu Typesetting', serif;
  --container: min(1180px, calc(100% - 48px));
  --shadow: 0 30px 60px -28px rgba(17, 36, 89, .35);
  --ease: cubic-bezier(.2, .7, .2, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 400 1.02rem/1.65 var(--sans);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg { max-width: 100%; height: auto; display: block; }
picture { display: contents; }
a { color: var(--lapis); }
h1, h2, h3, h4 { font-family: var(--serif); font-weight: 400; margin: 0; line-height: 1.15; }
p { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }
ul, ol { padding-inline-start: 1.2em; }
strong { font-weight: 700; }
.container { width: var(--container); margin-inline: auto; }
.ltr { direction: ltr; unicode-bidi: isolate; display: inline-block; }
.skip-link {
  position: absolute; inset-inline-start: 16px; top: -60px; z-index: 200;
  padding: 10px 14px; background: var(--madder); color: #fff; text-decoration: none; font-weight: 700;
}
.skip-link:focus { top: 12px; }
:focus-visible { outline: 3px solid var(--madder); outline-offset: 3px; }

/* ---------- Type helpers ---------- */
.rubric {
  display: flex; align-items: center; gap: 12px; margin: 0 0 14px;
  font: 700 .74rem/1.3 var(--sans); letter-spacing: .2em; text-transform: uppercase; color: var(--madder);
}
.rubric::before { content: ""; flex: 0 0 28px; height: 1px; background: currentColor; }
.rubric.center { justify-content: center; }
.rubric.center::after { content: ""; flex: 0 0 28px; height: 1px; background: currentColor; }
.title { font-size: clamp(2rem, 3.8vw, 3.1rem); letter-spacing: -.015em; }
.title em, .hero h1 em, .page-hero h1 em { font-style: italic; }
.lede { font-size: 1.1rem; line-height: 1.65; color: var(--ink-2); }
.small { font-size: .9rem; color: var(--ink-3); }
.prose p { line-height: 1.75; color: var(--ink-2); }
.prose p.first { font-size: 1.15rem; color: var(--ink); }
.prose strong { color: var(--ink); }
.mt { margin-top: 36px; }

/* ---------- Ornaments ---------- */
.ornament {
  display: flex; align-items: center; justify-content: center; gap: 16px;
  margin: 0 auto 44px; color: var(--lapis);
}
.ornament span { flex: 0 0 min(120px, 22vw); height: 1px; background: var(--line-strong); }
.ornament svg { width: 26px; height: 26px; flex: none; }
.ornament svg rect { fill: none; stroke: currentColor; stroke-width: 1.3; }
.ornament svg circle { fill: var(--madder); }
.ornament.light { color: var(--lapis-tint); }
.ornament.light span { background: rgba(196, 208, 238, .35); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  padding: 15px 24px; border: 1px solid transparent; cursor: pointer;
  font: 700 .8rem/1 var(--sans); letter-spacing: .12em; text-transform: uppercase; text-decoration: none;
  transition: background-color .2s, color .2s, border-color .2s, transform .2s;
}
.btn:hover { transform: translateY(-1px); }
.btn-madder { background: var(--madder); color: #fff; }
.btn-madder:hover { background: var(--madder-2); }
.btn-lapis { background: var(--lapis); color: #fff; }
.btn-lapis:hover { background: var(--lapis-2); }
.btn-outline { border-color: rgba(250, 247, 241, .6); color: var(--paper); }
.btn-outline:hover { background: rgba(250, 247, 241, .12); border-color: var(--paper); }
.btn-outline-ink { border-color: var(--lapis); color: var(--lapis); }
.btn-outline-ink:hover { background: var(--lapis-soft); }
.btn-sm { padding: 11px 16px; font-size: .72rem; }
.text-link {
  display: inline-block; font: 700 .8rem/1 var(--sans); letter-spacing: .12em; text-transform: uppercase;
  color: var(--lapis); text-decoration: none; padding-bottom: 5px; border-bottom: 1px solid var(--lapis-tint);
  transition: border-color .2s;
}
.text-link:hover { border-color: var(--lapis); }
.text-link::after { content: " \2192"; }
[dir="rtl"] .text-link::after { content: " \2190"; }
.actions { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 60;
  background: rgba(250, 247, 241, .96); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.rubric-bar { background: var(--lapis-3); color: var(--lapis-tint); font-size: .78rem; }
.rubric-inner { display: flex; align-items: center; justify-content: space-between; gap: 18px; min-height: 36px; }
.rubric-inner p { margin: 0; }
.rubric-inner .links { display: flex; gap: 18px; align-items: center; }
.rubric-bar a { color: #eef2fb; text-decoration: none; }
.rubric-bar a:hover { text-decoration: underline; }
#hijri { color: #eef2fb; }
#hijri::before { content: "\2726"; margin-inline-end: 8px; color: var(--madder-light); }
.nav-shell { display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: 90px; transition: min-height .25s var(--ease); }
.is-compact .nav-shell { min-height: 72px; }
.brand { display: flex; align-items: center; gap: 14px; text-decoration: none; color: var(--ink); }
.brand img { width: 54px; height: auto; transition: width .25s var(--ease); }
.is-compact .brand img { width: 44px; }
.brand strong { display: block; font: 700 1.22rem/1.05 var(--serif); }
.brand small { display: block; margin-top: 5px; font: 700 .66rem/1 var(--sans); letter-spacing: .18em; text-transform: uppercase; color: var(--lapis); }
.main-nav { display: flex; align-items: center; gap: 2px; }
.main-nav > a { position: relative; padding: 12px 12px; font: 600 .92rem/1 var(--sans); color: var(--ink-2); text-decoration: none; white-space: nowrap; }
.main-nav > a::after {
  content: ""; position: absolute; left: 12px; right: 12px; bottom: 5px; height: 2px; background: var(--madder);
  transform: scaleX(0); transform-origin: center; transition: transform .22s var(--ease);
}
.main-nav > a:hover::after, .main-nav > a[aria-current="page"]::after { transform: scaleX(1); }
.main-nav > a[aria-current="page"] { color: var(--ink); }
.main-nav .btn { margin-inline-start: 12px; }
.main-nav > a.btn::after { display: none; }
.main-nav > a.btn-madder { color: #fff; }
details.lang { position: relative; }
details.lang summary {
  list-style: none; cursor: pointer; padding: 12px 12px; display: flex; align-items: center; gap: 8px;
  font: 600 .92rem/1 var(--sans); color: var(--ink-2); white-space: nowrap;
}
details.lang summary::-webkit-details-marker { display: none; }
details.lang summary::after {
  content: ""; width: 6px; height: 6px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor;
  transform: rotate(45deg) translateY(-2px);
}
.lang-list {
  position: absolute; inset-inline-end: 0; top: calc(100% + 8px); min-width: 180px; padding: 8px;
  background: var(--white); border: 1px solid var(--line); box-shadow: var(--shadow); display: grid; z-index: 5;
}
.lang-list a { padding: 10px 12px; text-decoration: none; color: var(--ink); font-size: .96rem; }
.lang-list a:hover { background: var(--lapis-soft); }
.lang-list a[aria-current="page"] { color: var(--madder); font-weight: 700; }
[lang="ur"] { font-family: var(--urdu); }
[lang="ar"] { font-family: var(--arabic); }
.menu-toggle {
  display: none; width: 46px; height: 46px; padding: 0; border: 1px solid var(--line); background: var(--white);
  cursor: pointer; flex-direction: column; align-items: center; justify-content: center; gap: 5px;
}
.menu-toggle span { display: block; width: 20px; height: 2px; background: var(--ink); transition: transform .25s, opacity .25s; }
.nav-open .menu-toggle span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-open .menu-toggle span:nth-child(2) { opacity: 0; }
.nav-open .menu-toggle span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Hero ---------- */
.hero { position: relative; min-height: min(86vh, 840px); display: grid; align-items: end; background: var(--night); color: var(--paper); overflow: hidden; }
.hero-media, .hero-veil { position: absolute; inset: 0; }
.hero-media img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 42%; }
.hero-veil {
  background:
    linear-gradient(100deg, rgba(11, 23, 55, .94) 0%, rgba(11, 23, 55, .74) 40%, rgba(11, 23, 55, .3) 72%, rgba(11, 23, 55, .18) 100%),
    linear-gradient(180deg, rgba(11, 23, 55, .45) 0%, rgba(11, 23, 55, 0) 35%, rgba(11, 23, 55, .6) 100%);
}
[dir="rtl"] .hero-veil { background:
    linear-gradient(-100deg, rgba(11, 23, 55, .94) 0%, rgba(11, 23, 55, .74) 40%, rgba(11, 23, 55, .3) 72%, rgba(11, 23, 55, .18) 100%),
    linear-gradient(180deg, rgba(11, 23, 55, .45) 0%, rgba(11, 23, 55, 0) 35%, rgba(11, 23, 55, .6) 100%); }
.hero .container { position: relative; padding: 140px 0 84px; }
.hero .rubric { color: var(--madder-light); }
.hero h1 { font-size: clamp(2.7rem, 6vw, 5rem); line-height: 1.02; letter-spacing: -.02em; max-width: 12ch; margin: .3em 0 .45em; }
.hero h1 em { color: #f3cfc9; }
.hero .lede { color: #d5ddf2; max-width: 560px; margin-bottom: 34px; }
.hero-arabic {
  position: absolute; right: 3%; left: auto; bottom: 96px; margin: 0; pointer-events: none; user-select: none;
  font: 400 clamp(3.4rem, 10vw, 8.5rem)/1 var(--arabic); color: rgba(250, 247, 241, .13); letter-spacing: 0;
}
.ruler { background: var(--paper); border-top: 4px solid var(--lapis); border-bottom: 1px solid var(--line); }
.stats { display: grid; grid-template-columns: repeat(4, 1fr); list-style: none; margin: 0; padding: 0; }
.stats li { padding: 26px 30px; border-inline-start: 1px solid var(--line); }
.stats li:first-child { border-inline-start: 0; padding-inline-start: 0; }
.stats strong { display: block; font: 400 2.5rem/1 var(--serif); color: var(--lapis); font-variant-numeric: tabular-nums; }
.stats span { display: block; margin-top: 8px; font: 700 .74rem/1.4 var(--sans); letter-spacing: .14em; text-transform: uppercase; color: var(--ink-3); }

/* ---------- Page hero ---------- */
.page-hero { position: relative; min-height: 440px; display: grid; align-items: end; background: var(--night); color: var(--paper); overflow: hidden; }
.page-hero-media { position: absolute; inset: 0; }
.page-hero-media img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 45%; }
.page-hero-media::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(11, 23, 55, .55) 0%, rgba(11, 23, 55, .35) 45%, rgba(11, 23, 55, .9) 100%);
}
.page-hero .container { position: relative; padding: 130px 0 60px; }
.crumbs { margin: 0 0 22px; font: 700 .72rem/1 var(--sans); letter-spacing: .16em; text-transform: uppercase; color: var(--lapis-text); }
.crumbs a { color: inherit; text-decoration: none; }
.crumbs a:hover { color: #fff; }
.crumbs span { margin: 0 8px; color: var(--madder-light); }
.page-hero .rubric { color: var(--madder-light); }
.page-hero h1 { font-size: clamp(2.4rem, 5vw, 4rem); line-height: 1.05; letter-spacing: -.015em; margin: .25em 0 .4em; max-width: 16ch; }
.page-hero .lede { color: #d5ddf2; max-width: 640px; }

/* ---------- Sections ---------- */
.section { padding: 92px 0; }
.section.tight { padding: 60px 0; }
.section.alt { background: var(--paper-2); }
.section-head {
  display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: 24px 64px; align-items: end;
  margin-bottom: 52px; padding-bottom: 26px; position: relative;
}
.section-head::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 5px; border-top: 1px solid var(--line-strong); border-bottom: 1px solid var(--line-strong); }
.section-head.single { grid-template-columns: minmax(0, 760px); }
.section-head .lede { margin: 0; }
.glance {
  display: grid; grid-template-columns: auto 1fr; gap: 22px; align-items: center;
  padding: 26px 30px; background: var(--white); border: 1px solid var(--line); border-inline-start: 4px solid var(--madder);
}
.glance strong { font: 700 1.25rem/1.2 var(--serif); display: block; }
.glance p { margin: 4px 0 0; color: var(--ink-2); }
.glance .seal { width: 64px; height: auto; }

/* ---------- Cards ---------- */
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.cards.two { grid-template-columns: repeat(2, 1fr); }
.cards.four { grid-template-columns: repeat(4, 1fr); }
.card {
  background: var(--white); border: 1px solid var(--line); padding: 30px 28px 32px; position: relative;
  transition: transform .3s var(--ease), border-color .3s, box-shadow .3s;
}
.card:hover { transform: translateY(-4px); border-color: var(--lapis-tint); box-shadow: var(--shadow); }
.card .num { display: block; margin-bottom: 20px; font: italic 400 1.7rem/1 var(--serif); color: var(--madder); }
.card .num::after { content: ""; display: block; width: 36px; height: 1px; background: var(--line-strong); margin-top: 12px; }
.card .kicker { display: block; margin-bottom: 12px; font: 700 .7rem/1.4 var(--sans); letter-spacing: .16em; text-transform: uppercase; color: var(--lapis); }
.card h3 { font: 700 1.3rem/1.2 var(--serif); margin: 0 0 10px; }
.card p { margin: 0; color: var(--ink-2); line-height: 1.6; }
.card .btn, .card .text-link { margin-top: 22px; }
.card.dark { background: var(--lapis-3); border-color: transparent; color: var(--paper); }
.card.dark h3 { color: var(--paper); }
.card.dark p { color: #d5ddf2; }
.card.dark .kicker { color: var(--lapis-text); }
.card.note { background: var(--madder-soft); border-color: #eccdc8; }
.card.note h3 { font-size: 1.1rem; color: var(--madder-2); }
.card.note:hover { transform: none; box-shadow: none; border-color: #eccdc8; }

/* ---------- Split / media ---------- */
.split { display: grid; grid-template-columns: 1.05fr .95fr; gap: 64px; align-items: center; }
.split.flip > .split-media { order: 2; }
.split-media { position: relative; }
.split-media figure { margin: 0; }
.frame { position: relative; }
.frame::before { content: ""; position: absolute; inset: 18px -18px -18px 18px; border: 1px solid var(--lapis-tint); z-index: 0; }
[dir="rtl"] .frame::before { inset: 18px 18px -18px -18px; }
.frame img { position: relative; z-index: 1; width: 100%; }
.frame .second {
  position: absolute; z-index: 2; inset-inline-end: -28px; bottom: -36px; width: 42%;
  border: 6px solid var(--paper); box-shadow: var(--shadow);
}
.frame .second img { width: 100%; }
figcaption { margin-top: 14px; font: italic 400 .98rem/1.4 var(--serif); color: var(--ink-3); }
.stacked figcaption { margin-top: 52px; }
.split-copy .rubric { margin-bottom: 16px; }
.split-copy .title { margin-bottom: 22px; }
.split-copy .text-link, .split-copy .btn { margin-top: 24px; }
.split-copy h3 { font: 700 1.2rem/1.3 var(--serif); margin: 26px 0 4px; }
.checklist { list-style: none; margin: 18px 0 0; padding: 0; display: grid; gap: 12px; }
.checklist li { position: relative; padding-inline-start: 30px; color: var(--ink-2); line-height: 1.55; }
.checklist li::before {
  content: ""; position: absolute; inset-inline-start: 2px; top: .55em; width: 9px; height: 9px;
  background: var(--madder); transform: rotate(45deg);
}

/* ---------- Timeline ---------- */
.timeline { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 36px; position: relative; }
.timeline::before { content: ""; position: absolute; left: 0; right: 0; top: 9px; height: 1px; background: var(--line-strong); }
.timeline li { position: relative; padding-top: 38px; }
.timeline li::before {
  content: ""; position: absolute; top: 2px; inset-inline-start: 2px; width: 15px; height: 15px;
  background: var(--paper-2); border: 1px solid var(--madder); transform: rotate(45deg);
}
.timeline li::after { content: ""; position: absolute; top: 7px; inset-inline-start: 7px; width: 5px; height: 5px; background: var(--madder); transform: rotate(45deg); }
.section:not(.alt) .timeline li::before { background: var(--paper); }
.tl-when { display: block; margin: 0 0 10px; font: italic 400 1.15rem/1.2 var(--serif); color: var(--lapis); }
.timeline h3 { font: 700 1.15rem/1.3 var(--serif); margin: 0 0 10px; }
.timeline p { margin: 0; color: var(--ink-2); line-height: 1.6; font-size: .98rem; }
.quote-head { text-align: center; max-width: 760px; margin: 0 auto 60px; }
.quote-head blockquote { margin: 0; font: italic 400 clamp(1.5rem, 2.8vw, 2.1rem)/1.35 var(--serif); color: var(--ink); }

/* ---------- Photo band ---------- */
.band { position: relative; background: var(--night); color: var(--paper); overflow: hidden; }
.band-media { position: absolute; inset: 0; }
.band-media img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 30%; opacity: .55; }
.band::before { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(11, 23, 55, .55), rgba(11, 23, 55, .82)); }
.band .container { position: relative; padding: 120px 0; max-width: 840px; text-align: center; }
.band .rubric { color: var(--madder-light); }
.band blockquote { margin: 0; font: italic 400 clamp(1.6rem, 3.2vw, 2.5rem)/1.32 var(--serif); }
.band cite { display: block; margin-top: 26px; font: 700 .76rem/1.6 var(--sans); letter-spacing: .16em; text-transform: uppercase; color: var(--lapis-text); font-style: normal; }
.band .actions { justify-content: center; margin-top: 30px; }

/* ---------- Feature (campus) ---------- */
.feature { display: grid; grid-template-columns: 1.45fr .85fr; gap: 20px; }
.feature-photo { position: relative; min-height: 460px; overflow: hidden; background: var(--night); display: block; text-decoration: none; }
.feature-photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform 1.2s var(--ease); }
.feature-photo:hover img { transform: scale(1.03); }
.feature-photo .over {
  position: absolute; inset: auto 0 0 0; padding: 120px 36px 36px; color: var(--paper);
  background: linear-gradient(180deg, rgba(11, 23, 55, 0), rgba(11, 23, 55, .9));
}
.feature-photo .rubric { color: var(--madder-light); }
.feature-photo h3 { font: 400 1.9rem/1.15 var(--serif); margin: 0 0 8px; color: var(--paper); }
.feature-photo p { margin: 0; color: #d5ddf2; max-width: 520px; }
.feature-photo .text-link { color: var(--paper); border-color: rgba(250, 247, 241, .5); margin-top: 18px; }
.facts { background: var(--lapis-3); color: var(--paper); padding: 36px 32px; display: flex; flex-direction: column; }
.facts .rubric { color: var(--madder-light); }
.facts h3 { font: 400 1.7rem/1.15 var(--serif); margin: 0 0 22px; }
.facts dl { margin: 0 0 auto; display: grid; gap: 16px; }
.facts dt { font: 700 .68rem/1 var(--sans); letter-spacing: .16em; text-transform: uppercase; color: var(--lapis-text); }
.facts dd { margin: 5px 0 0; font-size: 1.02rem; }
.facts .btn { margin-top: 30px; align-self: flex-start; }

/* ---------- Steps ---------- */
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.steps li { background: var(--white); border: 1px solid var(--line); padding: 30px 28px; position: relative; }
.steps .step-num { display: block; font: italic 400 2.6rem/1 var(--serif); color: var(--lapis-tint); margin-bottom: 18px; }
.steps h3 { font: 700 1.25rem/1.25 var(--serif); margin: 0 0 10px; }
.steps p { margin: 0; color: var(--ink-2); line-height: 1.6; }

/* ---------- Tables ---------- */
.table-wrap { overflow-x: auto; border: 1px solid var(--line); background: var(--white); }
table.stages { width: 100%; border-collapse: collapse; min-width: 640px; }
.stages th, .stages td { padding: 16px 20px; text-align: start; vertical-align: top; border-bottom: 1px solid var(--line); }
.stages th { font: 700 .72rem/1.4 var(--sans); letter-spacing: .14em; text-transform: uppercase; color: var(--lapis); background: var(--lapis-soft); }
.stages td:first-child { font: 700 1.05rem/1.4 var(--serif); }
.stages tr:last-child td { border-bottom: 0; }

/* ---------- People & panels ---------- */
.people { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.person { background: var(--white); border: 1px solid var(--line); border-top: 3px solid var(--madder); padding: 28px 26px; }
.person .role { display: block; font: 700 .7rem/1.4 var(--sans); letter-spacing: .16em; text-transform: uppercase; color: var(--lapis); margin-bottom: 12px; }
.person h3 { font: 700 1.25rem/1.25 var(--serif); margin: 0 0 14px; }
.person a { color: var(--ink-2); text-decoration: none; font-variant-numeric: tabular-nums; }
.person a:hover { color: var(--madder); }
.panels { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.panel { background: var(--white); border: 1px solid var(--line); padding: 34px 32px; }
.panel.dark { background: var(--lapis-3); color: var(--paper); border-color: transparent; }
.panel.dark .rubric { color: var(--madder-light); }
.panel.dark .rows dt { color: var(--lapis-text); }
.panel.dark .rows div { border-color: rgba(201, 213, 240, .28); }
.panel.dark a { color: #fff; }
.panel.dark .rows dd a { border-color: rgba(201, 213, 240, .4); }
.panel h3 { font: 400 1.75rem/1.15 var(--serif); margin: 0 0 18px; }
.panel .btn, .panel .text-link { margin-top: 22px; }
.panel .btn-outline { color: var(--paper); }
.rows { margin: 0; }
.rows div { display: grid; grid-template-columns: 150px 1fr; gap: 6px 20px; padding: 12px 0; border-bottom: 1px dashed var(--line-strong); }
.rows div:last-child { border-bottom: 0; }
.rows dt { font: 700 .7rem/1.7 var(--sans); letter-spacing: .14em; text-transform: uppercase; color: var(--ink-3); }
.rows dd { margin: 0; line-height: 1.55; }
.rows dd a { text-decoration: none; color: inherit; border-bottom: 1px solid var(--lapis-tint); }
.rows dd a:hover { color: var(--madder); border-color: currentColor; }
.social { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 18px; }
.social a {
  display: inline-flex; align-items: center; gap: 8px; padding: 10px 14px; border: 1px solid var(--line-strong);
  text-decoration: none; color: var(--ink); font: 600 .86rem/1 var(--sans);
}
.social a:hover { border-color: var(--lapis); color: var(--lapis); }
.social svg { width: 16px; height: 16px; fill: currentColor; }

/* ---------- Receipt (donation) ---------- */
.receipt-grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: 40px; align-items: start; }
.receipt { position: relative; background: var(--white); border: 1px solid var(--line-strong); padding: 40px 40px 34px; }
.receipt::before, .receipt::after { content: ""; position: absolute; width: 28px; height: 28px; border: 2px solid var(--madder); }
.receipt::before { top: -1px; inset-inline-start: -1px; border-inline-end: 0; border-bottom: 0; }
.receipt::after { bottom: -1px; inset-inline-end: -1px; border-inline-start: 0; border-top: 0; }
.receipt-head { display: flex; justify-content: space-between; align-items: center; gap: 20px; padding-bottom: 18px; margin-bottom: 8px; border-bottom: 1px solid var(--line-strong); }
.receipt-head .rubric { margin: 0; }
.receipt-head img { width: 46px; }
.receipt .rows div { grid-template-columns: 160px 1fr; }
.receipt .rows dd { font-size: 1.04rem; }
.receipt .value { font: 400 1.45rem/1.2 var(--serif); letter-spacing: .05em; font-variant-numeric: tabular-nums; }
.copy-btn {
  margin-inline-start: 12px; vertical-align: middle; cursor: pointer; padding: 7px 10px;
  border: 1px solid var(--lapis); background: transparent; color: var(--lapis);
  font: 700 .66rem/1 var(--sans); letter-spacing: .12em; text-transform: uppercase; transition: background .2s, color .2s;
}
.copy-btn:hover, .copy-btn.is-done { background: var(--lapis); color: #fff; }
.receipt-foot { margin-top: 20px; padding-top: 18px; border-top: 1px dashed var(--line-strong); font-size: .92rem; color: var(--ink-2); }
.aside-stack { display: grid; gap: 20px; }

/* ---------- Gallery ---------- */
.gallery-group { margin-bottom: 64px; }
.gallery-group:last-of-type { margin-bottom: 0; }
.gallery-group h3 { display: flex; align-items: center; gap: 16px; font: 400 1.6rem/1.2 var(--serif); margin: 0 0 22px; }
.gallery-group h3::after { content: ""; flex: 1; height: 1px; background: var(--line-strong); }
.gallery-group h3 small { font: 700 .7rem/1 var(--sans); letter-spacing: .16em; text-transform: uppercase; color: var(--ink-3); }
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); grid-auto-rows: 210px; grid-auto-flow: dense; gap: 14px; }
.gal-item { position: relative; display: block; height: 100%; overflow: hidden; background: var(--paper-3); }
.gal-item.wide { grid-column: span 2; grid-row: span 2; }
.gal-item img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease); }
.gal-item:hover img, .gal-item:focus-visible img { transform: scale(1.05); }
.gal-item span {
  position: absolute; inset: auto 0 0 0; padding: 40px 14px 12px; color: #fff; font-size: .82rem; line-height: 1.4;
  background: linear-gradient(180deg, rgba(11, 23, 55, 0), rgba(11, 23, 55, .85)); opacity: 0; transition: opacity .3s;
}
.gal-item:hover span, .gal-item:focus-visible span { opacity: 1; }
.lightbox[hidden] { display: none; }
.lightbox { position: fixed; inset: 0; z-index: 100; background: rgba(11, 23, 55, .95); display: grid; place-items: center; padding: 64px 16px 24px; }
.lightbox figure { margin: 0; max-width: min(1400px, 96vw); text-align: center; }
.lightbox img { max-width: 100%; max-height: 76vh; width: auto; height: auto; margin: 0 auto; box-shadow: 0 30px 80px rgba(0, 0, 0, .6); }
.lightbox figcaption { color: var(--lapis-tint); margin-top: 16px; font: italic 400 1.05rem/1.4 var(--serif); }
.lb-count { display: block; margin-top: 6px; font: 700 .7rem/1 var(--sans); letter-spacing: .16em; color: var(--lapis-text); }
.lb-close, .lb-prev, .lb-next {
  position: absolute; width: 48px; height: 48px; border: 1px solid rgba(250, 247, 241, .4); background: rgba(11, 23, 55, .5);
  color: #fff; font: 400 1.5rem/1 var(--serif); cursor: pointer; display: grid; place-items: center; transition: background .2s;
}
.lb-close:hover, .lb-prev:hover, .lb-next:hover { background: var(--madder); border-color: var(--madder); }
.lb-close { top: 14px; inset-inline-end: 14px; }
.lb-prev { left: 14px; top: 50%; transform: translateY(-50%); }
.lb-next { right: 14px; top: 50%; transform: translateY(-50%); }
.lb-open { overflow: hidden; }

/* ---------- CTA ---------- */
.cta { position: relative; background: var(--lapis-3); color: var(--paper); padding: 76px 0; overflow: hidden; }
.cta::before { content: ""; position: absolute; inset: 0; background: radial-gradient(circle at 12% 50%, rgba(31, 63, 149, .7), transparent 55%); }
.cta::after {
  content: ""; position: absolute; inset-inline-end: -60px; top: -60px; width: 320px; height: 320px; opacity: .12;
  background: conic-gradient(from 0deg, var(--paper) 0 45deg, transparent 45deg 90deg, var(--paper) 90deg 135deg, transparent 135deg 180deg, var(--paper) 180deg 225deg, transparent 225deg 270deg, var(--paper) 270deg 315deg, transparent 315deg);
  border-radius: 50%;
}
.cta .container { position: relative; display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 32px; }
.cta .rubric { color: var(--madder-light); }
.cta h2 { font-size: clamp(1.8rem, 3.4vw, 2.6rem); line-height: 1.15; margin: 0 0 12px; }
.cta p { color: #d5ddf2; max-width: 620px; margin: 0; }

/* ---------- Footer ---------- */
.site-footer { background: var(--night); color: var(--lapis-tint); padding: 64px 0 28px; border-top: 4px solid var(--lapis); }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1.25fr; gap: 40px; }
.footer-brand img { width: 62px; background: var(--paper); padding: 6px; }
.footer-brand strong { display: block; margin: 16px 0 8px; font: 700 1.3rem/1.2 var(--serif); color: var(--paper); }
.footer-brand p { margin: 0; color: var(--lapis-text); line-height: 1.6; font-size: .95rem; }
.footer-arabic { margin: 14px 0 0; font: 400 1.55rem/1.5 var(--arabic); color: #8e9bc9; }
.site-footer h4 { margin: 0 0 18px; font: 700 .7rem/1 var(--sans); letter-spacing: .18em; text-transform: uppercase; color: var(--lapis-text); }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.site-footer a { color: #e6ebf8; text-decoration: none; }
.site-footer a:hover { color: #fff; text-decoration: underline; }
.site-footer address { font-style: normal; line-height: 1.7; }
.footer-bottom {
  margin-top: 56px; padding-top: 22px; border-top: 1px solid rgba(201, 213, 240, .2);
  display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; font-size: .8rem; color: #8e9bc9;
}
.footer-bottom p { margin: 0; }
.dev-credit { font-size: .72rem; color: #7f8ab8; letter-spacing: .01em; }
.dev-credit a { color: #a3aed4; border-bottom: 1px dotted currentColor; }
.dev-credit a:hover { color: #fff; text-decoration: none; }

/* ---------- 404 ---------- */
.notfound { min-height: 60vh; display: grid; place-items: center; text-align: center; padding: 80px 0; }
.notfound h1 { font-size: clamp(3rem, 10vw, 7rem); color: var(--lapis); line-height: 1; }
.notfound .actions { justify-content: center; margin-top: 28px; }

/* ---------- Reveal ---------- */
html.js .reveal { opacity: 0; transform: translateY(20px); transition: opacity .8s var(--ease), transform .8s var(--ease); }
html.js .reveal.is-in { opacity: 1; transform: none; }
html.js .reveal.d1 { transition-delay: .1s; }
html.js .reveal.d2 { transition-delay: .2s; }
html.js .reveal.d3 { transition-delay: .3s; }

/* ---------- RTL pages (Urdu / Arabic) ---------- */
html[lang="ur"] body { font-family: var(--urdu); font-size: 1.05rem; line-height: 2.15; }
html[lang="ur"] h1, html[lang="ur"] h2, html[lang="ur"] h3, html[lang="ur"] h4, html[lang="ur"] .brand strong,
html[lang="ur"] .stats strong, html[lang="ur"] .card .num, html[lang="ur"] .tl-when, html[lang="ur"] figcaption { font-family: var(--urdu); line-height: 1.9; letter-spacing: 0; }
html[lang="ar"] body { font-family: var(--arabic); font-size: 1.15rem; line-height: 1.9; }
html[lang="ar"] h1, html[lang="ar"] h2, html[lang="ar"] h3, html[lang="ar"] h4, html[lang="ar"] .brand strong,
html[lang="ar"] .stats strong, html[lang="ar"] .card .num, html[lang="ar"] .tl-when, html[lang="ar"] figcaption { font-family: var(--arabic); letter-spacing: 0; }
html[lang="ur"] .hero h1, html[lang="ar"] .hero h1 { max-width: none; font-size: clamp(2.2rem, 5vw, 4rem); line-height: 1.5; }
html[lang="ur"] .rubric, html[lang="ar"] .rubric, html[lang="ur"] .btn, html[lang="ar"] .btn, html[lang="ur"] .main-nav > a, html[lang="ar"] .main-nav > a,
html[lang="ur"] .stats span, html[lang="ar"] .stats span, html[lang="ur"] .rows dt, html[lang="ar"] .rows dt, html[lang="ur"] .crumbs, html[lang="ar"] .crumbs,
html[lang="ur"] .site-footer h4, html[lang="ar"] .site-footer h4, html[lang="ur"] .brand small, html[lang="ar"] .brand small,
html[lang="ur"] .person .role, html[lang="ar"] .person .role, html[lang="ur"] .facts dt, html[lang="ar"] .facts dt, html[lang="ur"] .text-link, html[lang="ar"] .text-link,
html[lang="ur"] details.lang summary, html[lang="ar"] details.lang summary, html[lang="ur"] .card .kicker, html[lang="ar"] .card .kicker,
html[lang="ur"] .steps h3, html[lang="ar"] .steps h3, html[lang="ur"] .rubric-bar, html[lang="ar"] .rubric-bar, html[lang="ur"] .footer-bottom, html[lang="ar"] .footer-bottom { font-family: inherit; letter-spacing: 0; text-transform: none; }
html[lang="ur"] .rubric, html[lang="ar"] .rubric, html[lang="ur"] .stats span, html[lang="ar"] .stats span, html[lang="ur"] .rows dt, html[lang="ar"] .rows dt,
html[lang="ur"] .site-footer h4, html[lang="ar"] .site-footer h4, html[lang="ur"] .card .kicker, html[lang="ar"] .card .kicker, html[lang="ur"] .person .role, html[lang="ar"] .person .role { font-size: .95em; }
html[lang="ur"] .btn, html[lang="ar"] .btn { padding: 12px 22px; line-height: 1.6; font-size: .95em; }
html[lang="ur"] .main-nav > a, html[lang="ar"] .main-nav > a, html[lang="ur"] details.lang summary, html[lang="ar"] details.lang summary { font-size: 1.02rem; }
html[lang="ur"] .text-link, html[lang="ar"] .text-link { font-size: 1em; }
html[lang="ur"] .rubric-bar, html[lang="ar"] .rubric-bar { font-size: .9rem; }
html[lang="ur"] .lede, html[lang="ar"] .lede { font-size: 1.08em; }
html[lang="ur"] .card h3, html[lang="ar"] .card h3 { line-height: 1.7; }
[dir="rtl"] .main-nav > a::after { left: 12px; right: 12px; }
[dir="rtl"] .lb-prev { left: auto; right: 14px; }
[dir="rtl"] .lb-next { right: auto; left: 14px; }
[dir="rtl"] .brand small { letter-spacing: 0; }
[dir="rtl"] .dev-credit { direction: ltr; }
.hero.rtl-hero .hero-arabic { display: none; }

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
  .people, .cards.four { grid-template-columns: repeat(2, 1fr); }
  .timeline { grid-template-columns: repeat(2, 1fr); gap: 44px 36px; }
  .timeline::before { display: none; }
  .timeline li { padding-top: 0; padding-inline-start: 34px; }
  .timeline li::before { top: 6px; }
  .timeline li::after { top: 11px; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 1280px) {
  .menu-toggle { display: inline-flex; }
  .main-nav {
    display: none; position: absolute; left: 0; right: 0; top: 100%; flex-direction: column; align-items: stretch; gap: 0;
    padding: 10px 24px 22px; background: var(--paper); border-bottom: 1px solid var(--line); box-shadow: var(--shadow); max-height: calc(100vh - 130px); overflow: auto;
  }
  .nav-open .main-nav { display: flex; }
  .main-nav > a { padding: 14px 4px; font-size: 1.05rem; border-bottom: 1px solid var(--line); }
  .main-nav > a::after { display: none; }
  .main-nav > a[aria-current="page"] { color: var(--madder); }
  details.lang summary { padding: 14px 4px; font-size: 1.05rem; border-bottom: 1px solid var(--line); }
  .lang-list { position: static; box-shadow: none; border: 0; background: var(--paper-2); }
  .main-nav .btn { margin: 16px 0 0; }
}
@media (max-width: 980px) {
  .split, .split.flip { grid-template-columns: 1fr; gap: 44px; }
  .split.flip > .split-media { order: 0; }
  .frame .second { inset-inline-end: 0; bottom: -28px; width: 40%; }
  .section-head, .section-head.single { grid-template-columns: 1fr; }
  .cards, .steps { grid-template-columns: repeat(2, 1fr); }
  .feature { grid-template-columns: 1fr; }
  .feature-photo { min-height: 380px; }
  .panels, .receipt-grid { grid-template-columns: 1fr; }
  .cta .container { grid-template-columns: 1fr; }
  .hero .container { padding: 120px 0 70px; }
  .hero-arabic { display: none; }
  .rubric-inner p.addr { display: none; }
}
@media (max-width: 640px) {
  :root { --container: min(1180px, calc(100% - 32px)); }
  .section { padding: 64px 0; }
  .cards, .cards.two, .cards.four, .steps, .people, .timeline, .footer-grid { grid-template-columns: 1fr; }
  .stats { grid-template-columns: 1fr 1fr; }
  .stats li { padding: 18px 16px; border-inline-start: 0; border-top: 1px solid var(--line); }
  .stats li:nth-child(-n+2) { border-top: 0; }
  .stats li:nth-child(even) { border-inline-start: 1px solid var(--line); }
  .stats strong { font-size: 2rem; }
  .rows div, .receipt .rows div { grid-template-columns: 1fr; gap: 2px; }
  .receipt { padding: 28px 22px; }
  .copy-btn { margin: 10px 0 0; display: block; }
  .receipt .value { font-size: 1.3rem; letter-spacing: .03em; }
  .gallery { grid-template-columns: repeat(2, 1fr); grid-auto-rows: 120px; gap: 8px; }
  .hero { min-height: min(78vh, 720px); }
  .hero-media img { object-position: 50% 50%; }
  .hero h1 { max-width: none; }
  .brand strong { font-size: 1.05rem; }
  .brand small { display: none; }
  .rubric-inner { font-size: .74rem; }
  .rubric-inner .links a.mail { display: none; }
  .footer-bottom { flex-direction: column; align-items: flex-start; }
  .lightbox { padding: 70px 8px 16px; }
  .lb-prev, .lb-next { top: auto; bottom: 16px; transform: none; }
  .glance { grid-template-columns: 1fr; }
  .frame::before { inset: 14px -8px -14px 14px; }
  [dir="rtl"] .frame::before { inset: 14px 14px -14px -8px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; }
  html.js .reveal { opacity: 1; transform: none; }
}
@media print {
  .site-header, .site-footer .footer-grid, .cta, .lightbox, .menu-toggle { display: none !important; }
  .hero, .page-hero, .band { min-height: 0; color: var(--ink); background: none; }
  .hero-media, .hero-veil, .page-hero-media, .band-media { display: none; }
  .hero .container, .page-hero .container { padding: 20px 0; }
}

/* Masjid 3D: the model loads only after the visitor opens it. */
.model-teaser { padding: 56px 0; border-block: 1px solid var(--line); background: var(--paper-2); }
.model-teaser-grid { display: grid; grid-template-columns: 1.1fr 1fr; gap: 60px; align-items: center; }
.model-teaser-image { display: block; position: relative; background: #8a9396; border: 1px solid var(--line-strong); }
.model-teaser-image img { width: 100%; height: auto; }
.model-teaser-image span { position: absolute; right: 16px; bottom: 16px; padding: 10px 16px; color: var(--white); background: var(--lapis-3); font-weight: 700; font-size: .875rem; }
.model-teaser .title { margin-bottom: 20px; }
.model-page { padding-block: 44px 64px; }
.model-heading { display: flex; gap: 24px; justify-content: space-between; align-items: end; margin-bottom: 28px; }
.model-heading h1 { font-size: clamp(2.2rem, 4.5vw, 3.7rem); }
.model-frame { position: relative; background: var(--paper-2); border: 1px solid var(--line-strong); box-shadow: var(--shadow); }
.model-stage { position: relative; width: 100%; height: clamp(340px, 55vh, 650px); background: #ede9e1; overflow: hidden; }
.model-poster { width: 100%; height: 100%; object-fit: cover; }
.model-stage canvas { display: block; width: 100%; height: 100%; touch-action: none; }
.model-stage canvas:focus-visible { outline-offset: -4px; }
.model-stage canvas[hidden], .model-frame [hidden] { display: none !important; }
.model-launch { position: absolute; inset: auto 0 0; display: flex; flex-direction: column; align-items: center; text-align: center; gap: 10px; padding: 24px 20px; background: rgba(250,247,241,.96); border-top: 1px solid var(--line); }
.model-launch p { margin: 0; max-width: 600px; }
.model-launch small { color: var(--ink-2); font-size: .8125rem; }
.model-toolbar { display: flex; justify-content: space-between; flex-wrap: wrap; align-items: center; gap: 12px; padding: 12px 16px; background: var(--white); border-top: 1px solid var(--line); }
.model-view-buttons { display: flex; gap: 5px; flex-wrap: wrap; }
.model-toolbar button { min-width: 44px; min-height: 44px; padding: 10px 14px; border: 1px solid transparent; font: 600 .875rem/1.3 var(--sans); color: var(--lapis-3); background: transparent; cursor: pointer; }
.model-toolbar button:hover { background: var(--lapis-soft); }
.model-toolbar button[aria-pressed="true"] { background: var(--lapis-3); color: var(--white); }
.model-toolbar button:disabled { opacity: .45; cursor: default; }
.model-instructions { padding: 0 16px 14px; margin: 0; color: var(--ink-2); font-size: .875rem; background: var(--white); }
.model-footnote { display: flex; justify-content: space-between; align-items: start; gap: 24px; padding-top: 22px; font-size: .875rem; color: var(--ink-2); }
.model-footnote p { max-width: 720px; }
.model-footnote a { white-space: nowrap; }
.model-frame.is-expanded { position: fixed; z-index: 150; inset: 0; display: flex; flex-direction: column; border: 0; padding-top: env(safe-area-inset-top); }
.model-frame.is-expanded .model-stage { flex: 1; min-height: 160px; height: auto; }
.model-frame.is-expanded .model-toolbar { padding-right: 16px; flex: none; }
.model-frame.is-expanded .model-instructions { flex: none; }
#model-collapse { flex: none; align-self: end; margin: 0 16px max(12px, env(safe-area-inset-bottom)); }
body.model-expanded { overflow: hidden; }
@media (max-width: 740px) {
  .model-teaser-grid { grid-template-columns: 1fr; gap: 28px; }
  .model-heading, .model-footnote { flex-direction: column; align-items: start; gap: 16px; }
  .model-page { padding-top: 30px; }
  .model-stage { height: 410px; }
  .model-toolbar { padding: 10px; gap: 6px; }
  .model-toolbar button { padding: 9px 10px; }
  .model-launch { padding: 18px 14px; }
  .model-poster { object-fit: contain; }
  .model-instructions { padding-inline: 12px; }
}
@media (max-height: 550px) and (orientation: landscape) {
  .model-frame.is-expanded .model-instructions { display: none; }
  .model-frame.is-expanded .model-toolbar { padding-block: 2px; }
  #model-collapse { margin-bottom: 6px; padding-block: 10px; }
}
