/* ==========================================================================
   Shine Development Foundation — site styles
   Layout language inspired by a serif + pill-button nonprofit template,
   re-colored to the SDF logo: red #EE1F26 and charcoal #231F20.
   ========================================================================== */

:root {
  --primary: #EE1F26;
  --primary-dark: #C9141B;
  --dark: #211C1D;
  --dark-2: #2E2728;
  --heading: #141112;
  --text: #5C5657;
  --soft: #FFF2F0;
  --soft-2: #F4F4F4;
  --line: #F0E2DF;
  --white: #FFFFFF;

  --font-head: "Merriweather", Georgia, serif;
  --font-body: "DM Sans", "Segoe UI", Arial, sans-serif;

  --radius: 20px;
  --radius-sm: 12px;
  --container: 1240px;
  --gutter: clamp(16px, 4vw, 36px);
  --section-y: clamp(72px, 9vw, 110px);
  --shadow: 0 10px 40px rgba(33, 28, 29, .08);
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.7;
  color: var(--text);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; height: auto; }
svg { display: block; }
a { color: var(--primary); text-decoration: none; transition: color .2s; }
a:hover { color: var(--primary-dark); }
h1, h2, h3, h4 {
  font-family: var(--font-head);
  font-weight: 400;
  color: var(--heading);
  line-height: 1.25;
  margin: 0 0 .5em;
}
h1 { font-size: clamp(2.3rem, 4.6vw, 3.6rem); }
h2 { font-size: clamp(1.9rem, 3.6vw, 2.9rem); }
h3 { font-size: 1.35rem; }
p { margin: 0 0 1em; }
ul, ol { margin: 0; padding: 0; }
strong { color: var(--heading); font-weight: 700; }
:focus-visible { outline: 3px solid var(--primary); outline-offset: 3px; border-radius: 6px; }

.container { width: 100%; max-width: var(--container); margin-inline: auto; padding-inline: var(--gutter); }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: 12px; top: -60px; z-index: 200; background: var(--dark); color: #fff; padding: 10px 16px; border-radius: 8px; }
.skip-link:focus { top: 12px; color: #fff; }
.center { text-align: center; }

/* Inline icons */
.i { width: 1em; height: 1em; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex: none; }

/* ---------- Tag pill (section eyebrow) ---------- */
.tag {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 5px 16px 5px 5px; border-radius: 999px;
  background: var(--soft); color: var(--heading);
  font-size: .92rem; font-weight: 500; margin-bottom: 18px;
}
.tag-icon {
  display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%;
  background: var(--primary); color: #fff;
}
.tag-icon svg { width: 14px; height: 14px; fill: currentColor; }
.tag-light { background: #fff; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 12px;
  min-height: 52px; padding: 8px 10px 8px 22px;
  border-radius: 999px; border: 1.5px solid transparent;
  font: 500 1.02rem/1.2 var(--font-body); cursor: pointer;
  transition: background-color .25s, color .25s, border-color .25s;
}
.btn-arrow {
  display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%;
  background: #fff; color: var(--primary); transition: transform .25s, background-color .25s, color .25s;
}
.btn-arrow svg { width: 15px; height: 15px; }
.btn:hover .btn-arrow { transform: rotate(45deg); }
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--dark); color: #fff; }
.btn-outline { border-color: currentColor; color: #fff; padding-right: 22px; }
.btn-outline .btn-arrow { width: auto; height: auto; background: none; color: inherit; }
.btn-outline:hover { background: #fff; color: var(--dark); border-color: #fff; }
.btn-dark-outline { border-color: var(--heading); color: var(--heading); padding-right: 22px; }
.btn-dark-outline .btn-arrow { width: auto; height: auto; background: none; color: inherit; }
.btn-dark-outline:hover { background: var(--heading); color: #fff; }
.btn-white { background: #fff; color: var(--heading); }
.btn-white .btn-arrow { background: var(--primary); color: #fff; }
.btn-white:hover { background: var(--primary); color: #fff; }
.btn-white:hover .btn-arrow { background: #fff; color: var(--primary); }

.more-link { display: inline-flex; align-items: center; gap: 10px; font-weight: 700; color: var(--heading); }
.more-link .dot-arrow {
  display: grid; place-items: center; width: 26px; height: 26px; border-radius: 50%;
  background: var(--heading); color: #fff; transition: transform .25s, background-color .25s;
}
.more-link .dot-arrow svg { width: 13px; height: 13px; }
.more-link:hover { color: var(--primary); }
.more-link:hover .dot-arrow { transform: translateX(3px); background: var(--primary); }

/* ==========================================================================
   Header
   ========================================================================== */
.site-header { position: sticky; top: 0; z-index: 100; background: var(--soft); transition: box-shadow .3s; }
.site-header.is-scrolled { box-shadow: 0 8px 30px rgba(33, 28, 29, .08); }
.header-wrap { position: relative; }

.brand-tab {
  position: absolute; left: var(--gutter); top: 0; z-index: 2;
  filter: drop-shadow(0 10px 18px rgba(33, 28, 29, .14));
}
.brand {
  display: flex; align-items: center; justify-content: center;
  width: 176px; height: calc(var(--header-h, 124px) + 22px);
  padding: 6px 14px 30px;
  background: linear-gradient(var(--primary) 0 5px, #fff 5px);
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 22px), 50% 100%, 0 calc(100% - 22px));
  transition: height .3s;
}
.brand img { width: 148px; height: auto; }

.header-rows { padding-left: calc(176px + 32px); }
.topbar {
  display: flex; align-items: center; justify-content: space-between; gap: 20px;
  min-height: 48px; border-bottom: 1px solid var(--line);
  font-size: .95rem; color: var(--heading);
  overflow: hidden; max-height: 60px; transition: max-height .3s, opacity .3s, min-height .3s;
}
.topbar ul { list-style: none; display: flex; align-items: center; gap: 26px; flex-wrap: wrap; }
.topbar li { display: inline-flex; align-items: center; gap: 8px; }
.topbar .i { color: var(--primary); font-size: 1.05rem; }
.topbar a { color: var(--heading); }
.topbar a:hover { color: var(--primary); }
.topbar .reg { color: var(--text); }

.navbar { display: flex; align-items: center; justify-content: space-between; gap: 20px; min-height: 76px; }
.site-nav ul { list-style: none; display: flex; gap: 6px; }
.site-nav ul a {
  position: relative; display: block; padding: 8px 14px;
  color: var(--heading); font-weight: 500; font-size: 1.05rem;
}
.site-nav ul a::after {
  content: ""; position: absolute; left: 14px; right: 14px; bottom: 2px; height: 2px;
  background: var(--primary); transform: scaleX(0); transform-origin: left; transition: transform .25s;
}
.site-nav ul a:hover { color: var(--primary); }
.site-nav ul a:hover::after, .site-nav ul a[aria-current="page"]::after { transform: scaleX(1); }
.site-nav ul a[aria-current="page"] { color: var(--primary); }
.nav-actions { display: flex; align-items: center; gap: 12px; margin-left: auto; }

.nav-toggle {
  display: none; width: 50px; height: 50px; border-radius: 50%;
  border: 1.5px solid var(--primary); background: #fff; cursor: pointer; position: relative;
}
.nav-toggle span, .nav-toggle span::before, .nav-toggle span::after {
  position: absolute; left: 50%; width: 20px; height: 2px; margin-left: -10px;
  background: var(--heading); border-radius: 2px; content: ""; transition: transform .25s, background-color .2s;
}
.nav-toggle span { top: 50%; margin-top: -1px; }
.nav-toggle span::before { top: -6px; left: 0; margin: 0; }
.nav-toggle span::after { top: 6px; left: 0; margin: 0; }
.nav-toggle[aria-expanded="true"] span { background: transparent; }
.nav-toggle[aria-expanded="true"] span::before { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span::after { transform: translateY(-6px) rotate(-45deg); }

/* Collapsed header on scroll (desktop) */
.site-header.is-scrolled .topbar { max-height: 0; min-height: 0; opacity: 0; border-bottom-color: transparent; }
.site-header.is-scrolled { --header-h: 76px; }

/* ==========================================================================
   Shared section styles
   ========================================================================== */
.section { padding-block: var(--section-y); position: relative; }
.bg-soft { background: var(--soft); }
.bg-dark { background: var(--dark); color: #CFC7C7; }
.bg-dark h2, .bg-dark h3 { color: #fff; }

.section-head { margin-bottom: clamp(40px, 5vw, 60px); }
.section-head.center { max-width: 760px; margin-inline: auto; text-align: center; }
.section-head .intro { font-size: 1.1rem; max-width: 42em; }
.section-head.center .intro { margin-inline: auto; }
.head-split { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: end; }
.head-split .intro { margin: 0 0 .6em; }

.head-icon {
  display: grid; place-items: center; width: 70px; height: 70px; border-radius: 50%;
  background: var(--soft); color: var(--primary); margin: 0 auto 18px;
}
.head-icon svg { width: 30px; height: 30px; fill: currentColor; }

/* Wave dividers */
.wave { position: absolute; left: 0; right: 0; bottom: -1px; width: 100%; height: clamp(40px, 6vw, 90px); pointer-events: none; z-index: 2; }
.wave path { fill: var(--wave-fill, #fff); }
.wave-top { top: -1px; bottom: auto; transform: scaleY(-1); }

/* ==========================================================================
   Home hero
   ========================================================================== */
.hero { position: relative; display: grid; grid-template-columns: minmax(0, 41%) 1fr; min-height: 760px; background: var(--dark); }
.hero-panel {
  display: flex; flex-direction: column; justify-content: center;
  padding: 110px clamp(24px, 4vw, 56px) 150px max(var(--gutter), calc((100vw - var(--container)) / 2 + var(--gutter)));
  color: #E4DCDC;
}
.hero-panel { position: relative; overflow: hidden; }
/* Faint copy of the current slide photo behind the dark panel (dark layer at 90%) */
.hero-panel-bg { position: absolute; inset: 0; z-index: 0; pointer-events: none; }
.hero-panel-bg img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity 1s ease; }
.hero-panel-bg img.is-active { opacity: 1; }
.hero-panel-bg::after { content: ""; position: absolute; inset: 0; background: rgba(33, 28, 29, .9); }
.hero-panel > :not(.hero-panel-bg) { position: relative; z-index: 1; }
.hero-panel h1 { color: #fff; margin-bottom: .5em; }
.hero-panel h1 em { font-style: italic; color: #FF6B70; }
.hero-panel p { font-size: 1.1rem; max-width: 32em; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 16px; margin: 20px 0 44px; }
.hero-meta { display: flex; align-items: center; gap: 18px; color: #fff; line-height: 1.5; font-size: calc(1.0625rem - 1pt); }
.hero-meta .stack { display: flex; }
.hero-meta .stack span {
  display: grid; place-items: center; width: 46px; height: 46px; border-radius: 50%;
  background: #fff; color: var(--primary); border: 2px solid var(--dark); margin-left: -12px;
}
.hero-meta .stack span:first-child { margin-left: 0; }
.hero-meta .stack span:last-child { background: var(--primary); color: #fff; }
.hero-meta .stack svg { width: 20px; height: 20px; }

.hero-media { position: relative; overflow: hidden; }
/* Soft shading: blends the photo into the dark panel and grounds the caption card */
.hero-media::after {
  content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background:
    linear-gradient(90deg, rgba(33, 28, 29, .55) 0%, rgba(33, 28, 29, 0) 24%),
    linear-gradient(0deg, rgba(20, 16, 17, .5) 0%, rgba(20, 16, 17, 0) 42%),
    linear-gradient(180deg, rgba(20, 16, 17, .18) 0%, rgba(20, 16, 17, 0) 18%);
}
.hero-card { z-index: 2; }
.hero-img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  object-position: var(--focus, center);
  opacity: 0; transform: scale(1.06);
  transition: opacity 1s ease, transform 7s ease;
}
.hero-img.is-active { opacity: 1; transform: scale(1); }
.hero-dots { display: flex; gap: 4px; margin-top: 16px; margin-left: -7px; }
.hero-dot {
  display: grid; place-items: center; width: 24px; height: 24px; padding: 0;
  border: 0; background: none; cursor: pointer; transition: width .3s;
}
.hero-dot::before {
  content: ""; width: 10px; height: 10px; border-radius: 999px;
  background: rgba(20, 17, 18, .28); transition: width .3s, background-color .3s;
}
.hero-dot:hover::before { background: rgba(20, 17, 18, .5); }
.hero-dot.is-active { width: 40px; }
.hero-dot.is-active::before { width: 30px; background: var(--primary); }
.hero-card {
  position: absolute; right: clamp(20px, 3vw, 44px); bottom: clamp(90px, 10vw, 130px);
  width: min(540px, calc(100% - 40px));
  display: grid; grid-template-columns: 1fr auto; gap: 18px; align-items: center;
  padding: 26px 26px 26px 30px; border-radius: var(--radius);
  background: rgba(255, 255, 255, .42);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, .6);
}
.hero-slide { display: none; }
.hero-slide.is-active { display: block; animation: fadeUp .5s ease; }
.hero-slide .kicker { font-size: .85rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--primary); margin-bottom: 6px; }
.hero-slide h2 { font-size: clamp(1.25rem, 2vw, 1.6rem); margin-bottom: 14px; }
.hero-arrows { display: grid; gap: 12px; }
.round-btn {
  display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%;
  border: 1.5px solid var(--primary); background: transparent; color: var(--primary); cursor: pointer;
  transition: background-color .2s, color .2s;
}
.round-btn:hover { background: var(--primary); color: #fff; }
.round-btn svg { width: 18px; height: 18px; }
@keyframes fadeUp { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

/* ==========================================================================
   Arched thematic cards
   ========================================================================== */
.arch-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.arch-card {
  --arch: 150px;
  display: flex; flex-direction: column; align-items: center; text-align: center;
  padding: 40px 26px 32px; border-radius: var(--arch) var(--arch) 16px 16px;
  background: var(--soft); color: var(--text);
  transition: background-color .35s, color .35s, transform .35s;
}
.arch-card .arch-icon {
  display: grid; place-items: center; width: 78px; height: 78px; border-radius: 50%;
  background: var(--primary); color: #fff; margin-bottom: 26px; transition: background-color .35s, color .35s;
}
.arch-card .arch-icon svg { width: 36px; height: 36px; }
.arch-card h3 { font-size: 1.25rem; transition: color .35s; }
.arch-card p { font-size: 1rem; flex: 1; }
.arch-card:hover, .arch-card:focus-visible { background: var(--primary); color: #FFE9EA; transform: translateY(-6px); }
.arch-card:hover h3, .arch-card:focus-visible h3, .arch-card:hover .more-link, .arch-card:focus-visible .more-link { color: #fff; }
.arch-card:hover .arch-icon, .arch-card:focus-visible .arch-icon { background: #fff; color: var(--primary); }
.arch-card:hover .dot-arrow, .arch-card:focus-visible .dot-arrow { background: #fff; color: var(--primary); }
.grid-note { text-align: center; margin: 48px auto 0; max-width: 40em; }

/* ==========================================================================
   About intro (home + about)
   ========================================================================== */
.about-grid { display: grid; grid-template-columns: 1fr 1.05fr; gap: clamp(36px, 6vw, 80px); align-items: center; }
.check-list { list-style: none; display: grid; gap: 12px; margin: 24px 0 32px; }
.check-list li { position: relative; padding-left: 34px; line-height: 1.5; color: var(--heading); }
.check-list li::before {
  content: ""; position: absolute; left: 0; top: 1px; width: 22px; height: 22px; border-radius: 50%;
  background: var(--primary) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5.5 10.5l3 3 6-6.5' fill='none' stroke='%23fff' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/100% no-repeat;
}
.check-list.cols-2 { grid-template-columns: 1fr 1fr; gap: 14px 30px; }

.media-frame { position: relative; }
.media-frame > img { width: 100%; border-radius: var(--radius); aspect-ratio: 9 / 7; object-fit: cover; }
.est-badge {
  position: absolute; left: -46px; top: 36px;
  display: grid; place-items: center; text-align: center;
  width: 150px; height: 150px; border-radius: 50%;
  background: var(--dark); color: #fff; border: 8px solid #fff; line-height: 1.2;
}
.est-badge small { display: block; font-size: .9rem; color: #D8CFCF; }
.est-badge strong { display: block; font: 400 2.1rem/1.1 var(--font-head); color: #fff; margin-top: 4px; }

/* ==========================================================================
   Counters
   ========================================================================== */
.counters { display: grid; grid-template-columns: repeat(4, 1fr); gap: 30px; padding-top: 50px; border-top: 1px solid var(--line); }
.counter .c-icon {
  display: grid; place-items: center; width: 92px; height: 92px; border-radius: 50%;
  background: var(--soft); color: var(--heading); margin-bottom: 22px;
}
.counter .c-icon svg { width: 38px; height: 38px; stroke-width: 1.6; }
.counter .c-label { font-size: 1.02rem; margin-bottom: 4px; }
.counter .c-num { display: block; font: 400 clamp(2.4rem, 4vw, 3rem)/1.15 var(--font-head); color: var(--heading); margin-bottom: 10px; }
.counter p { margin: 0; font-size: 1rem; }

/* ==========================================================================
   Vision / mission
   ========================================================================== */
.vm-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.vm-card { position: relative; overflow: hidden; padding: clamp(32px, 4vw, 48px); border-radius: var(--radius); background: #fff; }
.vm-card .vm-icon {
  display: grid; place-items: center; width: 64px; height: 64px; border-radius: 50%;
  background: var(--soft); color: var(--primary); margin-bottom: 24px;
}
.vm-card .vm-icon svg { width: 28px; height: 28px; }
.vm-card h3 { font-size: 1.6rem; }
.vm-card p { font-size: 1.12rem; margin: 0; }
.vm-card.is-red { background: var(--primary); color: #FFE7E8; }
.vm-card.is-red h3 { color: #fff; }
.vm-card.is-red .vm-icon { background: #fff; }

/* ==========================================================================
   Values
   ========================================================================== */
.values { list-style: none; display: grid; grid-template-columns: repeat(5, 1fr); gap: 20px; counter-reset: v; }
.values li {
  counter-increment: v; position: relative;
  padding: 34px 24px 28px; border-radius: var(--radius-sm);
  background: var(--dark-2); transition: background-color .3s, transform .3s;
}
.values li::before { content: counter(v, decimal-leading-zero); display: block; font: 400 1rem/1 var(--font-head); color: #FF7A7E; margin-bottom: 22px; }
.values li:hover { background: var(--primary); transform: translateY(-4px); }
.values li:hover::before { color: #fff; }
.values h3 { font-size: 1.3rem; margin-bottom: .4em; }
.values p { margin: 0; font-size: 1rem; color: #D6CDCD; }
.values li:hover p { color: #FFE7E8; }

/* ==========================================================================
   CTA band
   ========================================================================== */
.cta { position: relative; overflow: hidden; background: var(--dark); color: #E8E0E0; }
.cta-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.cta::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(20,16,17,.92) 0%, rgba(20,16,17,.7) 55%, rgba(20,16,17,.35) 100%); }
.cta .container { position: relative; z-index: 1; display: grid; grid-template-columns: 1.4fr 1fr; gap: 40px; align-items: center; }
.cta h2 { color: #fff; }
.cta p { font-size: 1.1rem; max-width: 36em; }
.cta-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 28px; }

/* ==========================================================================
   FAQ
   ========================================================================== */
.faq-grid { display: grid; grid-template-columns: .9fr 1.1fr; gap: clamp(36px, 5vw, 72px); align-items: start; }
.ask-card { margin-top: 36px; padding: 32px; border-radius: var(--radius); background: var(--soft); }
.ask-card h3 { font-size: 1.6rem; }
.faq { display: grid; gap: 18px; }
.faq details { border-radius: var(--radius-sm); background: var(--soft); overflow: hidden; transition: background-color .25s; }
.faq summary {
  list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 16px;
  padding: 18px 22px; font: 400 1.08rem/1.4 var(--font-head); color: var(--heading);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font: 400 1.7rem/1 var(--font-body); flex: none; transition: transform .25s; }
.faq details[open] { background: var(--primary); }
.faq details[open] summary { color: #fff; border-bottom: 1px solid rgba(255,255,255,.25); }
.faq details[open] summary::after { content: "−"; }
.faq .answer { padding: 16px 22px 22px; color: #fff; }
.faq .answer p { margin: 0; }

/* ==========================================================================
   Page banner (inner pages)
   ========================================================================== */
.page-banner { position: relative; overflow: hidden; background: var(--dark); text-align: center; padding: clamp(80px, 10vw, 120px) 0 clamp(110px, 12vw, 160px); }
.page-banner > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.page-banner::before { content: ""; position: absolute; inset: 0; background: rgba(20, 16, 17, .45); }
.page-banner .container { position: relative; z-index: 1; }
.page-banner h1 { color: #fff; margin-bottom: .35em; }
.breadcrumb { list-style: none; display: inline-flex; align-items: center; gap: 10px; color: #fff; font-weight: 500; }
.breadcrumb a { color: #fff; }
.breadcrumb a:hover { color: #FF9EA1; }
.breadcrumb li + li::before { content: "›"; margin-right: 10px; font-size: 1.3rem; line-height: 1; }

/* ==========================================================================
   Team / board
   ========================================================================== */
.team-layout { display: grid; grid-template-columns: .8fr 1.2fr; gap: clamp(36px, 5vw, 64px); align-items: start; }
.team-intro { position: sticky; top: 130px; }
.team-list { list-style: none; display: grid; gap: 24px; }
.member {
  display: grid; grid-template-columns: 200px 1fr; overflow: hidden;
  border-radius: var(--radius); background: var(--soft); border: 1px solid var(--line);
}
.member-photo {
  display: grid; place-items: center; min-height: 200px;
  background: linear-gradient(135deg, var(--primary), #8E0E14); color: #fff;
  font: 400 3rem/1 var(--font-head);
}
.member:nth-child(2) .member-photo { background: linear-gradient(135deg, #3A2F30, #161213); }
.member:nth-child(3) .member-photo { background: linear-gradient(135deg, #C8141B, #5E0A0E); }
.member-body { padding: 28px 30px; align-self: center; }
.member-body h3 { font-size: 1.55rem; margin-bottom: 2px; }
.member-role { color: var(--primary); font-weight: 700; margin-bottom: 10px; }
.member-body p:last-child { margin: 0; }

/* Structure */
.structure { display: grid; justify-items: center; gap: 0; }
.structure .node {
  padding: 18px 30px; border-radius: var(--radius-sm); text-align: center; min-width: 250px;
  background: #fff; border: 1px solid var(--line); box-shadow: var(--shadow);
  font: 400 1.1rem/1.3 var(--font-head); color: var(--heading);
}
.structure .node small { display: block; margin-top: 4px; font: 400 .95rem/1.4 var(--font-body); color: var(--text); }
.structure .node-top { background: var(--primary); border-color: var(--primary); color: #fff; }
.structure .node-top small { color: #FFE1E2; }
.structure .link { width: 2px; height: 34px; background: var(--primary); opacity: .35; }
.structure .row { display: flex; flex-wrap: wrap; justify-content: center; gap: 20px; position: relative; padding-top: 34px; }
.structure .row::before { content: ""; position: absolute; top: 0; left: 25%; right: 25%; height: 2px; background: var(--primary); opacity: .35; }
.structure .row .node { position: relative; }
.structure .row .node::before { content: ""; position: absolute; top: -34px; left: 50%; width: 2px; height: 34px; background: var(--primary); opacity: .35; }

.gov-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 24px; margin-top: 60px; }
.gov-card { padding: clamp(28px, 4vw, 40px); border-radius: var(--radius); background: #fff; }
.gov-card h3 { font-size: 1.5rem; }
.gov-card p:last-child { margin: 0; }
.reg-card { background: var(--dark); color: #D6CDCD; display: flex; flex-direction: column; justify-content: center; }
.reg-card .reg-label { font-size: .85rem; letter-spacing: .14em; text-transform: uppercase; }
.reg-card .reg-num { font: 400 2.6rem/1.2 var(--font-head); color: #fff; margin: 6px 0; letter-spacing: .03em; }

/* ==========================================================================
   Thematic areas page
   ========================================================================== */
.area-nav { position: sticky; top: 76px; z-index: 20; background: #fff; border-bottom: 1px solid var(--line); }
.area-nav ul { list-style: none; display: flex; justify-content: center; gap: 10px; padding-block: 14px; overflow-x: auto; scrollbar-width: none; }
.area-nav ul::-webkit-scrollbar { display: none; }
.area-nav a {
  display: inline-flex; align-items: center; gap: 8px; white-space: nowrap;
  padding: 9px 18px; border-radius: 999px; background: var(--soft); color: var(--heading); font-weight: 500;
}
.area-nav a svg { width: 18px; height: 18px; color: var(--primary); }
.area-nav a:hover, .area-nav a.is-active { background: var(--primary); color: #fff; }
.area-nav a:hover svg, .area-nav a.is-active svg { color: #fff; }

.area-block { scroll-margin-top: 170px; }
.area-row { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(36px, 5vw, 72px); align-items: center; }
.area-block:nth-of-type(even) .area-media { order: 2; }
.area-media { position: relative; }
.area-media img { width: 100%; border-radius: var(--radius); aspect-ratio: 18 / 13; object-fit: cover; }
.area-media .area-num {
  position: absolute; right: -18px; bottom: -18px;
  display: grid; place-items: center; width: 96px; height: 96px; border-radius: 50%;
  background: var(--primary); color: #fff; border: 6px solid #fff; font: 400 1.7rem/1 var(--font-head);
}
.area-block:nth-of-type(even) .area-media .area-num { right: auto; left: -18px; }
.bg-soft .area-media .area-num { border-color: var(--soft); }
.area-copy h2 { font-size: clamp(1.7rem, 3vw, 2.4rem); }
.focus-box { margin-top: clamp(36px, 5vw, 56px); padding: clamp(26px, 4vw, 40px); border-radius: var(--radius); background: #fff; border: 1px solid var(--line); }
.bg-soft .focus-box { border-color: #fff; }
.focus-box h3 { display: flex; align-items: center; gap: 12px; font-size: 1.35rem; margin-bottom: 22px; }
.focus-box h3 svg { width: 26px; height: 26px; color: var(--primary); }
.focus-box .check-list { margin: 0; }
.focus-box .check-list li { color: var(--text); }

/* ==========================================================================
   Contact page
   ========================================================================== */
.contact-grid { display: grid; grid-template-columns: 1fr 1.1fr; gap: clamp(36px, 5vw, 72px); align-items: start; }
.info-grid { list-style: none; display: grid; grid-template-columns: 1fr 1fr; gap: 34px 28px; margin-top: 34px; }
.info-grid .ic {
  display: grid; place-items: center; width: 54px; height: 54px; border-radius: 50%;
  background: var(--soft); color: var(--primary); margin-bottom: 14px;
}
.info-grid .ic svg { width: 22px; height: 22px; }
.info-grid .lbl { display: block; font-size: .95rem; margin-bottom: 4px; }
.info-grid .val, .info-grid address { font: 400 1.05rem/1.5 var(--font-head); font-style: normal; color: var(--heading); word-break: break-word; }
.info-grid a.val:hover { color: var(--primary); }

.form-card { padding: clamp(26px, 4vw, 40px); border-radius: var(--radius); border: 1px solid var(--line); background: #fff; box-shadow: var(--shadow); }
.form-card h2 { font-size: clamp(1.8rem, 3vw, 2.4rem); }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px 22px; margin-top: 26px; }
.field { display: grid; gap: 8px; }
.field.full { grid-column: 1 / -1; }
.field label { font-size: .95rem; font-weight: 500; color: var(--heading); }
.field input, .field select, .field textarea {
  width: 100%; font: inherit; font-size: 1rem; color: var(--heading);
  padding: 14px 20px; border: 1.5px solid transparent; border-radius: 999px; background: var(--soft-2);
  transition: border-color .2s, background-color .2s;
}
.field textarea { border-radius: 22px; min-height: 150px; resize: vertical; }
.field select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5 7.5l5 5 5-5' fill='none' stroke='%23141112' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 18px center; background-size: 18px; padding-right: 48px; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--primary); background-color: #fff; }
.form-foot { grid-column: 1 / -1; display: flex; align-items: center; flex-wrap: wrap; gap: 16px; margin-top: 6px; }
.form-note { margin: 0; font-size: .92rem; }
.form-error { grid-column: 1 / -1; margin: 0; color: var(--primary-dark); font-weight: 700; }


/* ==========================================================================
   Footer
   ========================================================================== */
.site-footer { position: relative; overflow: hidden; background: #171314; color: #BDB3B3; font-size: 1rem; }
.site-footer .container { position: relative; }
.footer-top { display: grid; grid-template-columns: 1.5fr 1fr 1.1fr 1.3fr; gap: 44px; padding-block: clamp(60px, 8vw, 90px) 50px; }
.footer-logo { display: inline-block; background: #fff; border-radius: var(--radius-sm); padding: 8px 14px; margin-bottom: 22px; }
.footer-logo img { width: 150px; }
.site-footer h2 { font-size: 1.25rem; color: #fff; margin-bottom: 26px; position: relative; padding-bottom: 14px; }
.site-footer h2::after { content: ""; position: absolute; left: 0; bottom: 0; width: 30px; height: 2px; background: var(--primary); }
.site-footer ul { list-style: none; display: grid; gap: 10px; }
.site-footer a { color: #E8E0E0; }
.site-footer a:hover { color: #FF8B8F; }
.footer-cta p { margin-bottom: 20px; }
.footer-contacts {
  display: grid; grid-template-columns: repeat(3, 1fr) auto; gap: 24px; align-items: center;
  padding-block: 30px; border-top: 1px solid rgba(255,255,255,.1);
}
.footer-contacts small { display: block; font-size: .85rem; margin-bottom: 2px; }
.footer-contacts .val { font: 400 1.05rem/1.4 var(--font-head); color: #fff; }
.footer-contacts address { font-style: normal; }
.social { display: flex; gap: 10px; }
.social a {
  display: grid; place-items: center; width: 42px; height: 42px; border-radius: 50%;
  background: var(--primary); color: #fff; transition: background-color .2s, color .2s;
}
.social a:hover { background: #fff; color: var(--primary); }
.social svg { width: 19px; height: 19px; }
.footer-bottom { padding-block: 22px; border-top: 1px solid rgba(255,255,255,.1); text-align: center; font-size: .95rem; }
.footer-bottom p { margin: 0; }

.to-top {
  position: fixed; right: 22px; bottom: 22px; z-index: 90;
  display: grid; place-items: center; width: 46px; height: 46px; border-radius: 10px;
  background: var(--primary); color: #fff; border: 0; cursor: pointer;
  opacity: 0; visibility: hidden; transform: translateY(10px); transition: opacity .3s, transform .3s, visibility .3s, background-color .2s;
}
.to-top.is-visible { opacity: 1; visibility: visible; transform: none; }
.to-top:hover { background: var(--dark); }
.to-top svg { width: 20px; height: 20px; }

/* ---------- Reveal on scroll ---------- */
.js .reveal { opacity: 0; transform: translateY(24px); transition: opacity .7s ease, transform .7s ease; }
.js .reveal.is-visible { opacity: 1; transform: none; }

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 1199px) {
  .site-nav ul a { padding: 8px 10px; font-size: 1rem; }
  .site-nav ul a::after { left: 10px; right: 10px; }
  .topbar .reg { display: none; }
  .values { grid-template-columns: repeat(3, 1fr); }
  .footer-top { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 991px) {
  .site-header { --header-h: 76px; }
  .topbar { display: none; }
  .brand { width: 136px; padding: 5px 12px 26px; }
  .brand img { width: 112px; }
  .header-rows { padding-left: calc(136px + 16px); }
  .nav-toggle { display: block; }
  .nav-actions .btn { display: none; }
  .site-nav {
    position: absolute; left: 0; right: 0; top: 100%;
    background: #fff; border-top: 1px solid var(--line); box-shadow: 0 20px 40px rgba(33,28,29,.12);
    padding: 12px var(--gutter) 22px; z-index: 5;
    opacity: 0; visibility: hidden; transform: translateY(-8px); transition: opacity .2s, transform .2s, visibility .2s;
  }
  .site-nav.is-open { opacity: 1; visibility: visible; transform: none; }
  .site-nav ul { flex-direction: column; gap: 0; }
  .site-nav ul a { padding: 14px 4px; font-size: 1.08rem; border-bottom: 1px solid var(--line); }
  .site-nav ul a::after { display: none; }
  .site-nav .btn { display: inline-flex; margin-top: 18px; }


  .hero { grid-template-columns: 1fr; }
  .hero-panel { padding: 70px var(--gutter) 60px; }
  .hero-media { min-height: 460px; }
  .hero-card { bottom: 80px; }

  .arch-grid { grid-template-columns: repeat(2, 1fr); }
  .about-grid, .faq-grid, .team-layout, .contact-grid, .area-row, .cta .container, .head-split { grid-template-columns: 1fr; }
  .area-block:nth-of-type(even) .area-media { order: 0; }
  .team-intro { position: static; }
  .est-badge { left: 16px; top: 16px; width: 124px; height: 124px; border-width: 6px; }
  .est-badge strong { font-size: 1.7rem; }
  .counters { grid-template-columns: repeat(2, 1fr); }
  .gov-grid { grid-template-columns: 1fr; }
  .area-nav { top: 76px; }
  .area-nav ul { justify-content: flex-start; }
  .area-media .area-num { right: 16px; bottom: -24px; }
  .area-block:nth-of-type(even) .area-media .area-num { left: auto; right: 16px; }
  .footer-contacts { grid-template-columns: 1fr 1fr; }
}

@media (min-width: 992px) { .site-nav .nav-extra { display: none; } }

@media (max-width: 767px) {
  .vm-grid, .check-list.cols-2, .form-grid, .info-grid { grid-template-columns: 1fr; }
  .values { grid-template-columns: 1fr 1fr; }
  .member { grid-template-columns: 1fr; }
  .member-photo { min-height: 150px; }
  .hero-card { position: relative; right: auto; bottom: auto; margin: -80px 16px 70px; width: auto; }
  .hero-media { min-height: 0; display: flex; flex-direction: column; justify-content: flex-end; padding-top: 420px; }
  .hero-img { object-position: var(--focus-sm, var(--focus, center)); }
  .structure .row { flex-direction: column; align-items: center; padding-top: 0; }
  .structure .row::before, .structure .row .node::before { display: none; }
  .structure .row .node + .node { margin-top: 16px; }
  .structure .row { margin-top: 34px; }
  .structure .row::after { content: none; }
}

@media (max-width: 575px) {
  .arch-grid, .counters, .values, .footer-top, .footer-contacts { grid-template-columns: 1fr; }
  .arch-card { --arch: 180px; }
  .hero-actions .btn, .cta-actions .btn { width: 100%; justify-content: space-between; }
  .hero-meta { flex-wrap: wrap; }
  .brand { width: 118px; }
  .brand img { width: 96px; }
  .header-rows { padding-left: calc(118px + 12px); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
  .js .reveal { opacity: 1; transform: none; }
}

/* ==========================================================================
   Language switch (EN | اردو)
   ========================================================================== */
.lang-switch {
  display: inline-flex; align-items: center; padding: 2px; gap: 1px;
  border: 1px solid var(--primary); border-radius: 999px; background: #fff;
}
.lang-switch a {
  display: grid; place-items: center; min-width: 26px; height: 22px; padding: 0 7px;
  border-radius: 999px; color: var(--heading); font-weight: 700; font-size: .55rem; line-height: 1;
  transition: background-color .2s, color .2s;
}
.lang-switch a[lang="ur"] { font-family: "Noto Nastaliq Urdu", "Segoe UI", Tahoma, sans-serif; font-weight: 500; font-size: .6rem; padding-bottom: 2px; }
.lang-switch a:hover { color: var(--primary); }
.lang-switch a[aria-current="true"] { background: var(--primary); color: #fff; }

/* ==========================================================================
   Urdu (right-to-left)
   ========================================================================== */
html[dir="rtl"] {
  --font-head: "Noto Nastaliq Urdu", "Merriweather", Georgia, serif;
  --font-body: "Noto Nastaliq Urdu", "DM Sans", "Segoe UI", Tahoma, sans-serif;
}
[dir="rtl"] body { font-size: calc(1.1rem - 2pt); line-height: 2.2; }
[dir="rtl"] h1, [dir="rtl"] h2, [dir="rtl"] h3, [dir="rtl"] h4 { line-height: 1.9; letter-spacing: 0; }
[dir="rtl"] h1 { font-size: calc(clamp(2rem, 3.8vw, 3rem) - 3pt); }
[dir="rtl"] h2 { font-size: calc(clamp(1.6rem, 3vw, 2.35rem) - 3pt); }
[dir="rtl"] em { font-style: normal; }
[dir="rtl"] .hero-slide .kicker, [dir="rtl"] .reg-label, [dir="rtl"] .site-footer h2 { letter-spacing: 0; text-transform: none; }
[dir="rtl"] .btn { line-height: 2; padding: 6px 22px 6px 10px; }
[dir="rtl"] .btn-outline, [dir="rtl"] .btn-dark-outline { padding-left: 22px; }
[dir="rtl"] .faq summary, [dir="rtl"] .structure .node, [dir="rtl"] .info-grid .val,
[dir="rtl"] .info-grid address, [dir="rtl"] .footer-contacts .val { line-height: 2; }
[dir="rtl"] .structure .node small { line-height: 1.9; }

/* Mirror direction-dependent icons and motion */
[dir="rtl"] .btn-arrow svg, [dir="rtl"] .dot-arrow svg, [dir="rtl"] .round-btn svg { transform: scaleX(-1); }
[dir="rtl"] .btn:hover .btn-arrow { transform: rotate(-45deg); }
[dir="rtl"] .more-link:hover .dot-arrow { transform: translateX(-3px); }
[dir="rtl"] .breadcrumb li + li::before { margin-right: 0; margin-left: 10px; font-family: "DM Sans", sans-serif; }

/* Mirror positions */
[dir="rtl"] .skip-link { left: auto; right: 12px; }
[dir="rtl"] .tag { padding: 5px 5px 5px 16px; }
[dir="rtl"] .brand-tab { left: auto; right: var(--gutter); }
[dir="rtl"] .header-rows { padding-left: 0; padding-right: calc(176px + 32px); }
[dir="rtl"] .site-nav ul a::after { transform-origin: right; }
[dir="rtl"] .nav-actions { margin-left: 0; margin-right: auto; }
[dir="rtl"] .hero-panel { padding: 110px max(var(--gutter), calc((100vw - var(--container)) / 2 + var(--gutter))) 150px clamp(24px, 4vw, 56px); }
[dir="rtl"] .hero-meta .stack span { margin-left: 0; margin-right: -12px; }
[dir="rtl"] .hero-meta .stack span:first-child { margin-right: 0; }
[dir="rtl"] .hero-media::after {
  background:
    linear-gradient(270deg, rgba(33, 28, 29, .55) 0%, rgba(33, 28, 29, 0) 24%),
    linear-gradient(0deg, rgba(20, 16, 17, .5) 0%, rgba(20, 16, 17, 0) 42%),
    linear-gradient(180deg, rgba(20, 16, 17, .18) 0%, rgba(20, 16, 17, 0) 18%);
}
[dir="rtl"] .hero-card { right: auto; left: clamp(20px, 3vw, 44px); }
[dir="rtl"] .hero-dots { margin-left: 0; margin-right: -7px; }
[dir="rtl"] .check-list li { padding-left: 0; padding-right: 34px; line-height: 2.1; }
[dir="rtl"] .check-list li::before { left: auto; right: 0; top: 8px; }
[dir="rtl"] .est-badge { left: auto; right: -46px; }
[dir="rtl"] .cta::after { background: linear-gradient(270deg, rgba(20,16,17,.92) 0%, rgba(20,16,17,.7) 55%, rgba(20,16,17,.35) 100%); }
[dir="rtl"] .area-media .area-num { right: auto; left: -18px; }
[dir="rtl"] .area-block:nth-of-type(even) .area-media .area-num { left: auto; right: -18px; }
[dir="rtl"] .field select { background-position: left 18px center; padding-right: 20px; padding-left: 48px; }
[dir="rtl"] .site-footer h2::after { left: auto; right: 0; }
[dir="rtl"] .to-top { right: auto; left: 22px; }

@media (max-width: 1199px) {
  [dir="rtl"] .site-nav ul a { padding: 8px 10px; }
}
@media (max-width: 991px) {
  [dir="rtl"] .header-rows { padding-right: calc(136px + 16px); }
  [dir="rtl"] .hero-panel { padding: 70px var(--gutter) 60px; }
  [dir="rtl"] .est-badge { right: 16px; }
  [dir="rtl"] .area-media .area-num,
  [dir="rtl"] .area-block:nth-of-type(even) .area-media .area-num { left: 16px; right: auto; }
}
@media (max-width: 767px) {
  [dir="rtl"] .hero-card { left: auto; }
}
@media (max-width: 575px) {
  [dir="rtl"] .header-rows { padding-right: calc(118px + 12px); }
  .lang-switch a { min-width: 23px; height: 20px; padding: 0 5px; }
}

/* Hero meta: keep each sentence on one line whenever the panel has room */
.hero-panel { container-type: inline-size; }
@container (min-width: 280px) {
  .hero-meta { flex-wrap: wrap; row-gap: 8px; }
  .hero-meta > div:last-child { white-space: nowrap; }
}
@container (min-width: 380px) {
  .hero-meta { flex-wrap: nowrap; }
}
@container (min-width: 340px) {
  [dir="rtl"] .hero-meta { flex-wrap: nowrap; }
}

/* Large screens: give the hero text panel a fixed-width text column so it never gets cramped */
@media (min-width: 1600px) {
  .hero { grid-template-columns: minmax(0, calc((100vw - var(--container)) / 2 + 540px)) 1fr; }
}
/* Safety net: shrink the English hero title if its column is ever too narrow for "Communities" */
@container (max-width: 420px) {
  html:not([dir="rtl"]) .hero-panel h1 { font-size: min(clamp(2.3rem, 4.6vw, 3.6rem), 15cqi); }
}
/* "Established" badge sits inside the photo on tablets/small laptops so it is never cut off */
@media (max-width: 1199px) {
  .est-badge { left: 16px; top: 16px; }
  [dir="rtl"] .est-badge { left: auto; right: 16px; }
}

/* ==========================================================================
   Donation campaigns: horizontal carousel + "Donate Now" popup
   ========================================================================== */
.dn-carousel { position: relative; }
.dn-track {
  list-style: none; margin: 0; padding: 6px 2px 26px;
  display: grid; grid-auto-flow: column; gap: 26px;
  grid-auto-columns: calc((100% - 2 * 26px) / 3);
  overflow-x: auto; overscroll-behavior-x: contain;
  scroll-snap-type: x mandatory; scroll-behavior: smooth;
  scrollbar-width: none; -webkit-overflow-scrolling: touch;
}
.dn-track::-webkit-scrollbar { display: none; }
.dn-track:focus-visible { outline: 3px solid var(--primary); outline-offset: 4px; border-radius: var(--radius); }

/* Round arrows sitting on the left / right edge of the cards */
.dn-arrow {
  position: absolute; top: 42%; z-index: 3; transform: translateY(-50%);
  display: grid; place-items: center; width: 52px; height: 52px; border-radius: 50%;
  border: 1px solid var(--line); background: #fff; color: var(--heading); cursor: pointer;
  box-shadow: 0 6px 20px rgba(33, 28, 29, .14);
  transition: background-color .2s, color .2s, opacity .2s, transform .2s;
}
.dn-arrow svg { width: 20px; height: 20px; }
.dn-arrow:hover { background: var(--primary); color: #fff; border-color: var(--primary); }
.dn-arrow:disabled { opacity: 0; pointer-events: none; }
.dn-arrow-prev { left: -26px; }
.dn-arrow-next { right: -26px; }

.dn-card {
  scroll-snap-align: start;
  display: flex; flex-direction: column;
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; transition: transform .35s ease, box-shadow .35s ease;
}
.dn-card:hover { transform: translateY(-6px); box-shadow: var(--shadow); }
.dn-media { aspect-ratio: 16 / 10; overflow: hidden; background: var(--soft); border-radius: var(--radius) var(--radius) 0 0; }
.dn-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s ease; }
.dn-card:hover .dn-media img { transform: scale(1.06); }
.dn-body { display: flex; flex-direction: column; flex: 1; padding: 24px 24px 26px; }
.dn-body h3 {
  font-family: var(--font-body); font-weight: 700; font-size: 1.5rem; line-height: 1.3;
  color: var(--heading); margin-bottom: .6em; letter-spacing: -.01em;
}
.dn-body p {
  flex: 1; margin-bottom: 24px; font-size: 1rem; line-height: 1.6;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.dn-more { color: var(--primary); text-decoration: underline; text-underline-offset: 3px; font-weight: 500; }
.dn-open {
  width: 100%; min-height: 50px; padding: 12px 20px; border: 0; border-radius: 999px; cursor: pointer;
  background: var(--primary); color: #fff; font: 700 1.05rem/1.2 var(--font-body);
  transition: background-color .25s, transform .25s;
}
.dn-open:hover { background: var(--dark); transform: translateY(-1px); }

/* Donate page: all campaigns as a grid of boxes */
.dn-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.dn-all { margin: 34px 0 0; }
@media (max-width: 991px) { .dn-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 575px) { .dn-grid { grid-template-columns: 1fr; gap: 20px; } }

/* ---------- Popup ---------- */
.dn-modal {
  width: min(480px, calc(100% - 32px)); max-height: calc(100% - 32px);
  padding: 0; border: 0; border-radius: var(--radius);
  background: #fff; color: var(--text); box-shadow: 0 30px 80px rgba(20, 16, 17, .35);
  overflow: auto;
}
.dn-modal::backdrop { background: rgba(20, 16, 17, .6); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); }
.dn-modal[open] { animation: dnIn .3s ease; }
.dn-modal[open]::backdrop { animation: dnFade .3s ease; }
@keyframes dnIn { from { opacity: 0; transform: translateY(16px) scale(.98); } to { opacity: 1; transform: none; } }
@keyframes dnFade { from { opacity: 0; } to { opacity: 1; } }
.dn-modal-inner { position: relative; padding: 32px 30px 30px; border-top: 5px solid var(--primary); }
.dn-close {
  position: absolute; top: 14px; right: 14px;
  width: 38px; height: 38px; border-radius: 50%; border: 0; cursor: pointer;
  background: var(--soft); color: var(--heading); font-size: 1.5rem; line-height: 1;
  transition: background-color .2s, color .2s;
}
.dn-close:hover { background: var(--primary); color: #fff; }
.dn-modal h2 { font-size: 1.55rem; margin-bottom: .4em; padding-right: 36px; }
.dn-modal h2 small { display: block; font-family: var(--font-body); font-size: .9rem; color: var(--text); margin-bottom: 4px; }
.dn-note { font-size: .98rem; }
.dn-form { display: grid; gap: 16px; margin-top: 8px; }
.dn-form .btn { justify-self: start; }
.dn-form .btn[disabled] { opacity: .7; cursor: wait; }
.dn-hp { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
.dn-view-done { text-align: center; padding: 10px 6px 4px; }
.dn-done-icon {
  display: grid; place-items: center; width: 76px; height: 76px; margin: 0 auto 18px;
  border-radius: 50%; background: #e8f6ee; color: #1b8a4a;
}
.dn-done-icon svg { width: 38px; height: 38px; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.dn-view-done h2 { padding: 0; }
.dn-view-done p { font-size: 1.05rem; margin-bottom: 24px; }
body.dn-lock { overflow: hidden; }

/* ---------- Urdu (right to left) ---------- */
[dir="rtl"] .dn-arrow svg { transform: scaleX(-1); }
[dir="rtl"] .dn-arrow-prev { left: auto; right: -26px; }
[dir="rtl"] .dn-arrow-next { right: auto; left: -26px; }
[dir="rtl"] .dn-body h3 { font-family: var(--font-head); font-weight: 400; line-height: 1.9; }
[dir="rtl"] .dn-body p { line-height: 2.1; }
[dir="rtl"] .dn-close { right: auto; left: 14px; }
[dir="rtl"] .dn-modal h2 { padding-right: 0; padding-left: 36px; }
[dir="rtl"] .dn-view-done h2 { padding: 0; }

/* ---------- Responsive ---------- */
@media (max-width: 991px) {
  .dn-track { grid-auto-columns: calc((100% - 26px) / 2); }
  .dn-arrow-prev { left: -10px; } .dn-arrow-next { right: -10px; }
  [dir="rtl"] .dn-arrow-prev { right: -10px; } [dir="rtl"] .dn-arrow-next { left: -10px; }
}
@media (max-width: 575px) {
  .dn-track { grid-auto-columns: 86%; gap: 16px; }
  .dn-arrow { width: 44px; height: 44px; }
  .dn-arrow-prev { left: -6px; } .dn-arrow-next { right: -6px; }
  [dir="rtl"] .dn-arrow-prev { right: -6px; } [dir="rtl"] .dn-arrow-next { left: -6px; }
  .dn-body h3 { font-size: 1.3rem; }
  .dn-modal-inner { padding: 28px 20px 22px; }
  .dn-form .btn { justify-self: stretch; justify-content: space-between; }
}
@media (prefers-reduced-motion: reduce) {
  .dn-track { scroll-behavior: auto; }
}

/* ---- Urdu text sizes (generated: text minus 2pt, titles minus 3pt) ---- */
[dir="rtl"] h3 { font-size: calc(1.35rem - 3pt); }
[dir="rtl"] .tag { font-size: calc(.92rem - 2pt); }
[dir="rtl"] .btn { font-size: calc(1.02rem - 2pt); }
[dir="rtl"] .topbar { font-size: calc(.95rem - 2pt); }
[dir="rtl"] .topbar .i { font-size: calc(1.05rem - 2pt); }
[dir="rtl"] .site-nav ul a { font-size: calc(1.05rem - 2pt); }
[dir="rtl"] .section-head .intro { font-size: calc(1.1rem - 2pt); }
[dir="rtl"] .hero-panel p { font-size: calc(1.1rem - 2pt); }
[dir="rtl"] .hero-meta { font-size: calc(calc(1.0625rem - 1pt) - 2pt); }
[dir="rtl"] .hero-slide .kicker { font-size: calc(.85rem - 2pt); }
[dir="rtl"] .hero-slide h2 { font-size: calc(clamp(1.25rem, 2vw, 1.6rem) - 3pt); }
[dir="rtl"] .arch-card h3 { font-size: calc(1.25rem - 3pt); }
[dir="rtl"] .arch-card p { font-size: calc(1rem - 2pt); }
[dir="rtl"] .est-badge small { font-size: calc(.9rem - 2pt); }
[dir="rtl"] .est-badge strong { font-size: calc(2.1rem - 2pt); }
[dir="rtl"] .counter .c-label { font-size: calc(1.02rem - 2pt); }
[dir="rtl"] .counter .c-num { font-size: calc(clamp(2.4rem, 4vw, 3rem) - 2pt); }
[dir="rtl"] .counter p { font-size: calc(1rem - 2pt); }
[dir="rtl"] .vm-card h3 { font-size: calc(1.6rem - 3pt); }
[dir="rtl"] .vm-card p { font-size: calc(1.12rem - 2pt); }
[dir="rtl"] .values li::before { font-size: calc(1rem - 2pt); }
[dir="rtl"] .values h3 { font-size: calc(1.3rem - 3pt); }
[dir="rtl"] .values p { font-size: calc(1rem - 2pt); }
[dir="rtl"] .cta p { font-size: calc(1.1rem - 2pt); }
[dir="rtl"] .ask-card h3 { font-size: calc(1.6rem - 3pt); }
[dir="rtl"] .faq summary { font-size: calc(1.08rem - 2pt); }
[dir="rtl"] .faq summary::after { font-size: calc(1.7rem - 2pt); }
[dir="rtl"] .breadcrumb li + li::before { font-size: calc(1.3rem - 2pt); }
[dir="rtl"] .member-photo { font-size: calc(3rem - 2pt); }
[dir="rtl"] .member-body h3 { font-size: calc(1.55rem - 3pt); }
[dir="rtl"] .structure .node { font-size: calc(1.1rem - 2pt); }
[dir="rtl"] .structure .node small { font-size: calc(.95rem - 2pt); }
[dir="rtl"] .gov-card h3 { font-size: calc(1.5rem - 3pt); }
[dir="rtl"] .reg-card .reg-label { font-size: calc(.85rem - 2pt); }
[dir="rtl"] .reg-card .reg-num { font-size: calc(2.6rem - 2pt); }
[dir="rtl"] .area-media .area-num { font-size: calc(1.7rem - 2pt); }
[dir="rtl"] .area-copy h2 { font-size: calc(clamp(1.7rem, 3vw, 2.4rem) - 3pt); }
[dir="rtl"] .focus-box h3 { font-size: calc(1.35rem - 3pt); }
[dir="rtl"] .info-grid .lbl { font-size: calc(.95rem - 2pt); }
[dir="rtl"] .info-grid .val, [dir="rtl"] .info-grid address { font-size: calc(1.05rem - 2pt); }
[dir="rtl"] .form-card h2 { font-size: calc(clamp(1.8rem, 3vw, 2.4rem) - 3pt); }
[dir="rtl"] .field label { font-size: calc(.95rem - 2pt); }
[dir="rtl"] .field input, [dir="rtl"] .field select, [dir="rtl"] .field textarea { font-size: calc(1rem - 2pt); }
[dir="rtl"] .form-note { font-size: calc(.92rem - 2pt); }
[dir="rtl"] .site-footer { font-size: calc(1rem - 2pt); }
[dir="rtl"] .site-footer h2 { font-size: calc(1.25rem - 3pt); }
[dir="rtl"] .footer-contacts small { font-size: calc(.85rem - 2pt); }
[dir="rtl"] .footer-contacts .val { font-size: calc(1.05rem - 2pt); }
[dir="rtl"] .footer-bottom { font-size: calc(.95rem - 2pt); }
@media (max-width: 1199px) {
  [dir="rtl"] .site-nav ul a { font-size: calc(1rem - 2pt); }
}
@media (max-width: 991px) {
  [dir="rtl"] .site-nav ul a { font-size: calc(1.08rem - 2pt); }
  [dir="rtl"] .est-badge strong { font-size: calc(1.7rem - 2pt); }
}
[dir="rtl"] .dn-body h3 { font-size: calc(1.5rem - 3pt); }
[dir="rtl"] .dn-body p { font-size: calc(1rem - 2pt); }
[dir="rtl"] .dn-open { font-size: calc(1.05rem - 2pt); }
[dir="rtl"] .dn-close { font-size: calc(1.5rem - 2pt); }
[dir="rtl"] .dn-modal h2 { font-size: calc(1.55rem - 3pt); }
[dir="rtl"] .dn-modal h2 small { font-size: calc(.9rem - 2pt); }
[dir="rtl"] .dn-note { font-size: calc(.98rem - 2pt); }
[dir="rtl"] .dn-view-done p { font-size: calc(1.05rem - 2pt); }
@media (max-width: 575px) {
  [dir="rtl"] .dn-body h3 { font-size: calc(1.3rem - 3pt); }
}
/* ---- end Urdu text sizes ---- */
