/* =========================================================================
   PREMIUM LAYER  (loaded last, after calm-theme.css)
   - bigger, easier-to-read text on phones
   - animated dark hero with Islamic geometry
   - cards with colour, pattern and "sticker" icons
   - scroll, hover and touch animations (all switched off for reduced-motion)
   ========================================================================= */

@property --ang { syntax: "<angle>"; initial-value: 0deg; inherits: false; }

:root {
  --pm-ink: #2A0F1A;
  --pm-burg: #3B1A27;
  --pm-burg-2: #5A2037;
  --pm-crim: #B43B60;
  --pm-crim-d: #922848;
  --pm-gold: #CFB047;
  --pm-gold-l: #F3E3A0;
  --pm-gold-d: #8E6B2A;
  --pm-teal: #8E6B2A;
  --pm-plum: #5A2037;
  --pm-cream: #FFFCF8;
  --pm-rose: #F9EEF2;
  --pm-ease: cubic-bezier(.2, .7, .2, 1);
}

/* ---------- 1. TEXT SIZE ------------------------------------------------ */
/* brand-theme.css sets the body at 16px in a font with a small x-height, which reads small.
   On phones everything that is sized in rem (almost all of the site) grows by 12.5%. */
body { font-size: 17.5px; }
@media (max-width: 991.98px) { html { font-size: 106.25%; } }
@media (max-width: 767.98px) {
  html { font-size: 112.5%; }
  body { font-size: 1rem; line-height: 1.7; }

  /* things that were tiny labels: keep them clearly readable */
  .home-page .home-eyebrow { font-size: .8rem; }
  .home-page .hero-kicker { font-size: .78rem; }
  .home-page .fact-value { font-size: 1rem; }
  .home-page .fact-label { font-size: .86rem; line-height: 1.45; }
  .home-page .programme-label { font-size: .8rem; }
  .home-page .pt-name { font-size: 1rem; }
  .home-page .pt-ar { font-size: 1.1rem; }
  .home-page .pt-class { font-size: .8rem; }
  .home-page .programme-card-text .programme-copy p,
  .home-page .purpose-card p,
  .home-page .admission-step p,
  .home-page .leader-card p,
  .home-page .feature-card p,
  .home-page .news-item p { font-size: 1rem; line-height: 1.7; }
  .home-page .home-description { font-size: 1.04rem; line-height: 1.7; }
  .home-page .intro-points li { font-size: 1.04rem; }
  .home-page .leader-role { font-size: .95rem; }
  .home-page .placement-box { font-size: 1rem; line-height: 1.7; }
  .home-page .level-pills a { font-size: .95rem; min-width: 96px; padding: .8rem .9rem; }
  .home-page .home-btn { font-size: 1rem; min-height: 54px; }
  .home-page .contact-link strong { font-size: 1rem; }
  .home-page .contact-link span { font-size: 1rem; }
  .home-page .home-notice-text { font-size: .95rem; }
  .public-page p, .public-page li { font-size: 1.02rem; }

  /* the top bar keeps its own fixed sizes so logo + language + menu always fit on one row */
  .public-nav { min-height: 72px; gap: .5rem; padding: .5rem 12px; flex-wrap: nowrap; }
  .public-nav.menu-open { flex-wrap: wrap; }
  .public-nav .brand-link { flex: 1 1 auto; }
  .public-menu-toggle, .lang-toggle { flex: none; }
  .public-nav .brand-link { min-width: 0; max-width: calc(100% - 178px); gap: .55rem; }
  .public-nav .brand-link img { width: 46px; height: 46px; padding: 4px; }
  .public-nav .brand-name { font-size: 16px; }
  .public-nav .brand-name small { font-size: 10px; margin-top: .15rem; letter-spacing: .03em; }
  .public-menu-toggle { font-size: 15px; padding: .5rem .7rem; }
  .lang-toggle { font-size: 16px; padding: .35rem .75rem; }
  .public-nav .public-nav-links a { font-size: 18px; padding: .75rem .3rem; }
  .home-page .hero-kicker { letter-spacing: .06em; }
}

/* Touch feedback: cards and buttons answer a tap, so it feels alive on a phone */
@media (hover: none) {
  .home-page .home-btn:active,
  .home-page .programme-card:active,
  .home-page .feature-card:active,
  .home-page .admission-step:active,
  .home-page .leader-card:active,
  .home-page .purpose-card:active,
  .home-page .news-item:active,
  .home-page .level-pills a:active,
  .public-card:active { transform: scale(.975); transition-duration: .1s; }
  .home-page a { -webkit-tap-highlight-color: rgba(207, 176, 71, .25); }
}

/* ---------- 2. SCROLL PROGRESS BAR ------------------------------------- */
.scroll-progress {
  position: fixed; top: 0; left: 0; z-index: 2500; width: 100%; height: 4px;
  transform: scaleX(0); transform-origin: 0 50%;
  background: linear-gradient(90deg, var(--pm-gold), var(--pm-crim), var(--pm-gold));
  box-shadow: 0 0 12px rgba(207, 176, 71, .7);
  pointer-events: none;
}

/* ---------- 3. HERO ----------------------------------------------------- */
.home-page .home-notices { margin-top: 0; }
.home-page .home-hero {
  position: relative; isolation: isolate; overflow: hidden; color: #fff;
  min-height: min(92vh, 800px);
  padding: clamp(64px, 9vw, 120px) 0 clamp(120px, 14vw, 170px);
  background:
    radial-gradient(60% 70% at 88% 8%, rgba(207, 176, 71, .30), transparent 62%),
    radial-gradient(55% 65% at 0% 100%, rgba(180, 59, 96, .50), transparent 62%),
    linear-gradient(135deg, #240C16 0%, #4B1D30 48%, #7D2842 100%) !important;
}
.home-page.has-notice .home-hero { padding-top: 48px; }
.home-page .home-hero .container { position: relative; z-index: 2; }
.home-page .hero-content { max-width: 760px; }

/* background effects */
.hero-fx { position: absolute; inset: 0; z-index: 0; overflow: hidden; pointer-events: none; }
.fx-pattern {
  position: absolute; inset: -120px; opacity: .9;
  background: url(/images/islamic-pattern.svg) 0 0 / 120px 120px;
  -webkit-mask-image: linear-gradient(100deg, transparent 5%, #000 55%, #000);
          mask-image: linear-gradient(100deg, transparent 5%, #000 55%, #000);
}
.fx-orb { position: absolute; border-radius: 50%; filter: blur(60px); }
.fx-orb-1 { width: 420px; height: 420px; right: -80px; top: -120px; background: rgba(207, 176, 71, .35); }
.fx-orb-2 { width: 360px; height: 360px; left: -100px; bottom: -80px; background: rgba(180, 59, 96, .55); }
.fx-orb-3 { width: 260px; height: 260px; left: 42%; top: 38%; background: rgba(21, 135, 173, .22); }
.fx-star { position: absolute; color: var(--pm-gold); opacity: .38; }
.fx-star-1 { width: 220px; height: 220px; right: 4%; top: 8%; }
.fx-star-2 { width: 120px; height: 120px; left: 3%; bottom: 20%; opacity: .25; }
.fx-star-3 { width: 70px; height: 70px; left: 46%; top: 12%; opacity: .3; }
.fx-spark {
  position: absolute; bottom: -20px; left: var(--x); width: var(--s, 6px); height: var(--s, 6px);
  background: var(--pm-gold-l); border-radius: 50%; opacity: 0;
  box-shadow: 0 0 10px 2px rgba(243, 227, 160, .8);
}
.hero-curve { position: absolute; left: 0; right: 0; bottom: -1px; z-index: 1; width: 100%; height: clamp(50px, 8vw, 110px); display: block; }
.hero-curve path { fill: var(--pm-cream); }

/* headline + text */
.home-page .hero-kicker {
  background: rgba(255, 255, 255, .1) !important; border: 1px solid rgba(207, 176, 71, .55) !important;
  color: var(--pm-gold-l) !important; -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
  border-radius: 999px; padding: .6rem 1.1rem;
}
.home-page .hero-kicker i { color: var(--pm-gold) !important; }
.home-page .home-hero h1 {
  color: #fff !important; margin: 1.3rem 0 1.2rem;
  font-weight: 700; letter-spacing: -.01em; line-height: 1.04;
  font-size: clamp(2.6rem, 5.6vw, 4.6rem);
  text-shadow: 0 4px 30px rgba(0, 0, 0, .25);
}
.home-page .home-hero h1 span {
  color: transparent !important;
  background: linear-gradient(100deg, #CFB047 18%, #FFF4C8 40%, #CFB047 62%) 0 0 / 220% 100%;
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; text-shadow: none;
}
.home-page .hero-description { color: rgba(255, 255, 255, .9) !important; font-size: clamp(1.05rem, 1.5vw, 1.22rem); line-height: 1.7; }
.home-page .hero-assurance { gap: .6rem; color: #fff !important; font-size: .95rem; }
.home-page .hero-assurance span {
  padding: .5rem .95rem; border-radius: 999px;
  background: rgba(255, 255, 255, .1); border: 1px solid rgba(255, 255, 255, .22);
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
}
.home-page .hero-assurance i { color: var(--pm-gold) !important; }
@media (max-width: 767.98px) {
  .home-page .hero-assurance { flex-direction: row; flex-wrap: wrap; font-size: .95rem; }
  .home-page .home-hero h1 { font-size: clamp(2.5rem, 12vw, 3.2rem); }
  .home-page .hero-actions { max-width: none; }
}

/* buttons */
.home-page .home-btn {
  position: relative; overflow: hidden; border-radius: 14px !important; font-weight: 800;
  background: linear-gradient(135deg, #C8466D, #922848) !important; border-color: transparent !important;
  box-shadow: 0 10px 28px rgba(146, 40, 72, .38) !important;
}
.home-page .home-btn:hover { background: linear-gradient(135deg, #D35079, #A02F51) !important; transform: translateY(-3px) scale(1.02); }
.home-page .home-btn::after {
  content: ""; position: absolute; top: 0; bottom: 0; left: -80%; width: 50%;
  background: linear-gradient(100deg, transparent, rgba(255, 255, 255, .45), transparent);
  transform: skewX(-20deg); pointer-events: none;
}
.home-page .home-btn:hover::after { left: 130%; transition: left .7s var(--pm-ease); }
.home-page .home-btn-gold {
  background: linear-gradient(135deg, #E8CC6A, #CFB047) !important; color: var(--pm-burg) !important;
  box-shadow: 0 10px 28px rgba(207, 176, 71, .4) !important;
}
.home-page .home-btn-gold:hover { background: linear-gradient(135deg, #F3DC85, #D9BC55) !important; }
.home-page .home-hero .home-btn-outline {
  background: rgba(255, 255, 255, .1) !important; border: 1.5px solid rgba(255, 255, 255, .55) !important;
  color: #fff !important; box-shadow: none !important; -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
}
.home-page .home-hero .home-btn-outline:hover { background: #fff !important; color: var(--pm-burg) !important; }
.home-page .home-btn.is-closed { background: rgba(255, 255, 255, .15) !important; box-shadow: none !important; }

/* right-hand hero art (laptop and tablet only) */
.hero-visual { display: none; }
@media (min-width: 992px) {
  .home-page .home-hero .container {
    display: grid; grid-template-columns: minmax(0, 1.18fr) minmax(0, .82fr); align-items: center; gap: 2rem;
  }
  .hero-visual { display: block; position: relative; width: 100%; max-width: 470px; aspect-ratio: 1; justify-self: center; }
  .hv-glow { position: absolute; inset: 8%; border-radius: 50%; background: radial-gradient(circle, rgba(207, 176, 71, .5), transparent 68%); filter: blur(26px); }
  .hv-star { position: absolute; color: var(--pm-gold); }
  .hv-star-a { inset: 0; width: 100%; height: 100%; opacity: .85; }
  .hv-star-b { inset: 13%; width: 74%; height: 74%; opacity: .5; color: #fff; }
  .hv-orbit { position: absolute; inset: 4%; border: 1px dashed rgba(243, 227, 160, .5); border-radius: 50%; }
  .hv-dot { position: absolute; top: -7px; left: 50%; width: 14px; height: 14px; margin-left: -7px; border-radius: 50%; background: var(--pm-gold-l); box-shadow: 0 0 18px 5px rgba(243, 227, 160, .8); }
  .hv-emblem {
    position: absolute; left: 50%; top: 50%; width: 38%; aspect-ratio: .8; transform: translate(-50%, -50%);
    display: grid; place-items: center; padding: 8%;
    background: #fff; border-radius: 30px; border: 3px solid var(--pm-gold);
    box-shadow: 0 0 0 10px rgba(255, 255, 255, .1), 0 30px 70px rgba(0, 0, 0, .45);
  }
  .hv-emblem img { width: 100%; height: 100%; object-fit: contain; }
  .hv-chip {
    position: absolute; display: flex; align-items: center; gap: .6rem; padding: .7rem 1rem; white-space: nowrap;
    border-radius: 16px; background: rgba(255, 255, 255, .13); border: 1px solid rgba(255, 255, 255, .3);
    -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
    color: #fff; font-weight: 700; font-size: .95rem; box-shadow: 0 14px 34px rgba(0, 0, 0, .3);
  }
  .hv-chip i { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 10px; background: linear-gradient(135deg, #E8CC6A, #CFB047); color: var(--pm-burg); font-size: .85rem; }
  .hv-chip-1 { left: -6%; top: 12%; }
  .hv-chip-2 { right: -10%; top: 75%; }
  .hv-chip-3 { left: 2%; bottom: 8%; }
}

/* ---------- 4. FACT STRIP (floating card that overlaps the hero) -------- */
.home-page .home-facts {
  background: var(--pm-cream) !important; border: 0 !important; margin-top: clamp(-90px, -7vw, -56px);
  padding: 0 0 1.5rem; z-index: 3;
}
.home-page .home-facts .row {
  position: relative; background: #fff; border-radius: 24px; overflow: hidden;
  border: 1px solid rgba(207, 176, 71, .45);
  box-shadow: 0 28px 70px -18px rgba(42, 15, 26, .35);
}
.home-page .home-facts .row::before {
  content: ""; position: absolute; top: 0; left: 0; right: 0; height: 4px;
  background: linear-gradient(90deg, var(--pm-gold), var(--pm-crim), var(--pm-gold));
  background-size: 200% 100%;
}
.home-page .home-facts [class*="col-"] + [class*="col-"] .fact-item { border-left: 1px solid #F1E9EC; }
.home-page .fact-item { padding: 1.5rem 1.4rem; transition: background .25s; }
.home-page .fact-item:hover { background: #FFFAF0; }
.home-page .fact-icon {
  width: 54px; height: 54px; flex-basis: 54px; border: 0 !important; border-radius: 16px;
  background: linear-gradient(135deg, #B43B60, #7D2842) !important; color: #fff !important; font-size: 1.3rem;
  box-shadow: 0 8px 18px rgba(146, 40, 72, .3); transform: rotate(-6deg); transition: transform .3s var(--pm-ease);
}
.home-page .fact-item:hover .fact-icon { transform: rotate(6deg) scale(1.1); }
.home-page .col-6:nth-child(2) .fact-icon { background: linear-gradient(135deg, #E8CC6A, #A9831A) !important; }
.home-page .col-6:nth-child(3) .fact-icon { background: linear-gradient(135deg, #B43B60, #7D2842) !important; }
.home-page .col-6:nth-child(4) .fact-icon { background: linear-gradient(135deg, #E8CC6A, #A9831A) !important; }
.home-page .fact-value { font-family: var(--font-display); font-size: 1.3rem; font-weight: 700; color: var(--pm-burg) !important; line-height: 1.15; }
.home-page .fact-label { color: #6B6368 !important; font-size: .9rem; }
@media (max-width: 991.98px) {
  .home-page .home-facts [class*="col-"]:nth-child(3) .fact-item,
  .home-page .home-facts [class*="col-"]:nth-child(4) .fact-item { border-top: 1px solid #F1E9EC; }
  .home-page .home-facts [class*="col-"]:nth-child(3) .fact-item { border-left: 0; }
}
@media (max-width: 767.98px) {
  .home-page .fact-item { padding: 1rem .8rem; gap: .7rem; align-items: center; min-height: 0; }
  .home-page .fact-icon { width: 44px; height: 44px; flex-basis: 44px; border-radius: 13px; font-size: 1.05rem; }
  .home-page .fact-value { font-size: 1.05rem; }
}

/* ---------- 5. SCROLLING RIBBON ---------------------------------------- */
.ribbon {
  position: relative; overflow: hidden; padding: 1.1rem 0; margin-top: 1rem;
  background: linear-gradient(90deg, #240C16, #4B1D30, #240C16);
  border-top: 2px solid var(--pm-gold); border-bottom: 2px solid var(--pm-gold);
}
.ribbon::before, .ribbon::after { content: ""; position: absolute; top: 0; bottom: 0; width: 70px; z-index: 2; pointer-events: none; }
.ribbon::before { left: 0; background: linear-gradient(90deg, #240C16, transparent); }
.ribbon::after { right: 0; background: linear-gradient(-90deg, #240C16, transparent); }
.ribbon-track { display: flex; width: max-content; }
.ribbon-set { display: flex; flex: none; align-items: center; }
.ribbon-set span {
  display: inline-flex; align-items: center; gap: 1.4rem; padding-right: 1.4rem; white-space: nowrap;
  color: var(--pm-gold-l); font-size: 1.25rem; font-weight: 600; letter-spacing: .02em;
}
.ribbon-set span::after { content: ""; width: 9px; height: 9px; background: var(--pm-gold); transform: rotate(45deg); box-shadow: 0 0 10px rgba(207, 176, 71, .8); }
.ribbon-set .ar { font-family: var(--font-arabic); font-size: 1.5rem; color: #fff; }

/* ---------- 6. SECTIONS ------------------------------------------------- */
.home-page .home-section { position: relative; }
.home-page .home-section-heading.text-center .home-eyebrow::after { width: 27px; height: 2px; background: var(--pm-gold); content: ""; }
.home-page .home-heading { font-family: var(--font-display); font-weight: 700; letter-spacing: -.01em; line-height: 1.12; font-size: clamp(2rem, 3.6vw, 3rem); color: var(--pm-burg); }
@media (max-width: 767.98px) { .home-page .home-heading { font-size: clamp(2.05rem, 9vw, 2.6rem); } }
.home-page .home-eyebrow { color: var(--pm-crim-d); font-weight: 800; }

.home-page .home-intro,
.home-page .home-admissions,
.home-page .home-contact { background: var(--pm-cream) url(/images/pattern-gold.svg) 0 0 / 120px 120px; }
.home-page .home-purpose { background: linear-gradient(180deg, #fff, var(--pm-rose)) !important; }
.home-page .home-programmes {
  background: linear-gradient(180deg, var(--pm-rose) 0%, var(--pm-cream) 100%) !important;
}
.home-page .home-programmes::before, .home-page .home-leadership::before {
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .8;
  background: url(/images/pattern-gold.svg) 0 0 / 120px 120px;
  -webkit-mask-image: linear-gradient(180deg, #000, transparent 70%); mask-image: linear-gradient(180deg, #000, transparent 70%);
}
.home-page .home-programmes > .container, .home-page .home-leadership > .container { position: relative; }
.home-page .home-leadership { background: #fff !important; }

/* intro photo: gold offset frame */
.home-page .intro-visual { overflow: visible; border: 0; border-radius: 22px; box-shadow: 16px 16px 0 var(--pm-gold), 0 30px 60px -20px rgba(42, 15, 26, .45); background: transparent; }
.home-page .intro-visual .intro-photo { border-radius: 22px 22px 0 0; }
.home-page .intro-visual .intro-image-caption { border-radius: 0 0 22px 22px; background: linear-gradient(135deg, var(--pm-ink), var(--pm-burg-2)); }
.home-page .intro-points i { background: linear-gradient(135deg, var(--pm-gold), #A9831A); color: #fff; box-shadow: 0 4px 10px rgba(169, 131, 26, .4); }
@media (max-width: 767.98px) { .home-page .intro-visual { box-shadow: 9px 9px 0 var(--pm-gold), 0 24px 44px -18px rgba(42, 15, 26, .45); margin-right: 9px; } }

/* ---------- 7. CARDS ---------------------------------------------------- */
/* spotlight that follows the finger / pointer (set by premium.js) */
.spot { position: relative; }
.spot::before {
  content: ""; position: absolute; inset: 0; z-index: 0; border-radius: inherit; pointer-events: none; opacity: 0;
  background: radial-gradient(340px circle at var(--mx, 50%) var(--my, 50%), rgba(207, 176, 71, .26), transparent 60%);
  transition: opacity .3s;
}
.spot:hover::before, .spot.is-touched::before { opacity: 1; }
.spot > * { position: relative; z-index: 1; }

/* feature cards (editable by the administrator) */
.home-page .feature-card {
  position: relative; overflow: hidden; border: 0 !important; border-radius: 22px !important; padding: 1.8rem !important;
  background: linear-gradient(160deg, #fff 40%, var(--pm-rose)) !important;
  box-shadow: 0 16px 44px -14px rgba(42, 15, 26, .22) !important;
}
.home-page .feature-card::after {
  content: ""; position: absolute; right: -40px; bottom: -40px; width: 150px; height: 150px; z-index: 0;
  background: url(/images/pattern-gold.svg) center / 90px; border-radius: 50%; opacity: .9;
}
.home-page .feature-card .fi {
  width: 62px; height: 62px; border-radius: 18px; font-size: 1.5rem; transform: rotate(-7deg);
  box-shadow: 0 12px 24px rgba(125, 40, 66, .35), 0 0 0 4px #fff, 0 0 0 5px rgba(207, 176, 71, .6);
  transition: transform .35s var(--pm-ease);
}
.home-page .feature-card:hover .fi { transform: rotate(5deg) scale(1.12); }
.home-page .feature-card h3 { font-family: var(--font-display); font-size: 1.45rem; font-weight: 700; }

/* news items */
.home-page .news-item { border-radius: 18px; border-left-width: 6px; box-shadow: 0 10px 28px -10px rgba(42, 15, 26, .18); }

/* purpose cards: one dark, one gold */
.home-page .purpose-card {
  border: 0 !important; border-radius: 26px !important; padding: clamp(2rem, 4vw, 3rem) !important;
  background: linear-gradient(145deg, #2A0F1A, #6E2440) !important; color: #fff;
  box-shadow: 0 30px 60px -22px rgba(42, 15, 26, .6) !important;
}
.home-page .purpose-card.vision-card { background: linear-gradient(145deg, #A9831A, #E8CC6A) !important; color: var(--pm-ink); box-shadow: 0 30px 60px -22px rgba(142, 107, 42, .6) !important; }
.home-page .purpose-card::after { display: none; }
.home-page .purpose-card::before { /* huge faded sticker */
  content: ""; position: absolute; inset: 0; opacity: .9; z-index: 0; pointer-events: none;
  background: url(/images/islamic-pattern.svg) right -30px bottom -30px / 200px no-repeat;
}
.home-page .purpose-card .purpose-icon {
  width: 68px; height: 68px; border-radius: 20px; font-size: 1.6rem; transform: rotate(-8deg);
  background: #fff !important; color: var(--pm-crim) !important; box-shadow: 0 14px 30px rgba(0, 0, 0, .35);
}
.home-page .vision-card .purpose-icon { color: #8E6B2A !important; }
.home-page .purpose-card h3 { color: #fff; font-family: var(--font-display); font-size: 2rem; font-weight: 700; }
.home-page .purpose-card p { color: rgba(255, 255, 255, .9); font-size: 1.08rem; line-height: 1.75; }
.home-page .vision-card h3 { color: var(--pm-ink); }
.home-page .vision-card p { color: #2A0F1A; }
.home-page .purpose-card.spot::before { background: radial-gradient(380px circle at var(--mx, 50%) var(--my, 50%), rgba(255, 255, 255, .2), transparent 60%); }

/* programme cards: crimson and gold only */
.home-page .programme-card-text {
  --acc: #B43B60; --acc2: #6E2440; --acc-soft: #FBEAF0;
  position: relative; border: 0 !important; border-radius: 24px !important; background: #fff;
  box-shadow: 0 22px 54px -18px rgba(42, 15, 26, .32) !important; overflow: hidden;
  transition: transform .35s var(--pm-ease), box-shadow .35s;
}
.home-page .col-md-6:nth-child(2) .programme-card-text { --acc: #A9831A; --acc2: #6B4E0E; --acc-soft: #FBF4DB; }
.home-page .col-md-6:nth-child(3) .programme-card-text { --acc: #B43B60; --acc2: #6E2440; --acc-soft: #FBEAF0; }
.home-page .col-md-6:nth-child(4) .programme-card-text { --acc: #A9831A; --acc2: #6B4E0E; --acc-soft: #FBF4DB; }
.home-page .programme-card-text:hover { box-shadow: 0 34px 70px -18px rgba(42, 15, 26, .45) !important; }
.home-page .programme-card-text .pc-head {
  position: relative; overflow: hidden; padding: 1.5rem 1.5rem 1.4rem !important; min-height: 120px;
  background: linear-gradient(135deg, var(--acc2), var(--acc));
}
.home-page .programme-card-text .pc-head::before {
  content: ""; position: absolute; inset: -40px; z-index: 0; opacity: .85;
  background: url(/images/islamic-pattern.svg) 0 0 / 100px 100px;
}
.home-page .programme-card-text .pc-head::after {
  content: ""; position: absolute; right: -50px; top: -60px; width: 170px; height: 170px; border-radius: 50%; z-index: 0;
  background: radial-gradient(circle, rgba(255, 255, 255, .35), transparent 70%);
}
.home-page .programme-card-text .pc-head > * { position: relative; z-index: 1; }
.home-page .programme-card-text .pc-icon {
  width: 64px; height: 64px; border-radius: 20px; background: #fff !important; border: 0;
  transform: rotate(-9deg); box-shadow: 0 14px 28px rgba(0, 0, 0, .35), 0 0 0 4px rgba(255, 255, 255, .28);
  transition: transform .4s var(--pm-ease);
}
.home-page .programme-card-text:hover .pc-icon { transform: rotate(6deg) scale(1.12); }
.home-page .programme-card-text .pc-icon i { color: var(--acc) !important; font-size: 1.7rem; }
.home-page .programme-card-text .pc-ar { color: #fff !important; font-size: 1.7rem; font-weight: 700; text-shadow: 0 2px 10px rgba(0, 0, 0, .3); }
.home-page .programme-card-text .programme-copy { padding: 1.4rem 1.6rem 1.7rem; }
.home-page .programme-card-text .programme-label { color: var(--acc2); font-weight: 800; background: var(--acc-soft); padding: .3rem .75rem; border-radius: 999px; }
.home-page .programme-card-text .programme-copy h3 { font-family: var(--font-display); font-size: 1.55rem; font-weight: 700; line-height: 1.2; color: var(--pm-burg); }
.home-page .pc-texts li { border-bottom: 1px dashed #E7DDE0; }
.home-page .pt-name { color: var(--pm-burg); }
.home-page .pt-ar { color: var(--acc); }
.home-page .pt-class { background: var(--acc-soft); color: var(--acc2); font-weight: 700; }

.home-page .pc-actions { display: flex; flex-wrap: wrap; gap: .6rem; margin-top: auto; padding-top: 1.2rem; }
.home-page .pc-link {
  display: inline-flex; align-items: center; gap: .5rem; padding: .7rem 1.1rem; border-radius: 12px; min-height: 46px;
  background: linear-gradient(135deg, var(--acc), var(--acc2)); color: #fff !important; font-weight: 800; font-size: .95rem; text-decoration: none;
  box-shadow: 0 8px 18px -6px var(--acc);
}
.home-page .pc-link:hover { transform: translateY(-2px); gap: .8rem; }
.home-page .pc-link-apply { background: var(--acc-soft); color: var(--acc2) !important; box-shadow: none; border: 1.5px solid var(--acc); }

/* levels (dark band) */
.home-page .home-levels {
  background:
    radial-gradient(50% 60% at 100% 0%, rgba(180, 59, 96, .45), transparent 60%),
    radial-gradient(45% 60% at 0% 100%, rgba(207, 176, 71, .22), transparent 60%),
    linear-gradient(135deg, #240C16, #3B1A27) !important;
}
.home-page .home-levels::before { content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .8; background: url(/images/islamic-pattern.svg) 0 0 / 120px 120px; }
.home-page .home-levels > .container { position: relative; }
.home-page .level-pills a { border-radius: 14px; background: rgba(255, 255, 255, .08); border: 1px solid rgba(255, 255, 255, .25); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.home-page .level-pills a:hover { background: linear-gradient(135deg, #E8CC6A, #CFB047); border-color: transparent; color: var(--pm-ink); transform: translateY(-4px) scale(1.04); box-shadow: 0 12px 26px rgba(207, 176, 71, .4); }
.home-page .placement-box { border-radius: 18px; border: 1px solid rgba(207, 176, 71, .4); background: rgba(255, 255, 255, .07); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); }

/* admission steps */
.home-page .admission-step {
  border: 0 !important; border-radius: 22px !important; padding: 1.9rem 1.5rem !important;
  background: linear-gradient(170deg, #fff 50%, #FBF4E4) !important; box-shadow: 0 18px 44px -16px rgba(42, 15, 26, .25) !important;
  transition: transform .35s var(--pm-ease), box-shadow .35s;
}
.home-page .admission-step:hover { transform: translateY(-8px); box-shadow: 0 30px 60px -16px rgba(42, 15, 26, .35) !important; }
.home-page .step-number {
  width: 62px; height: 62px; border-radius: 50%; font-size: 1.25rem; font-family: var(--font-display); font-weight: 700;
  background: linear-gradient(135deg, #C8466D, #5A2037); color: #fff;
  box-shadow: 0 0 0 6px rgba(180, 59, 96, .12), 0 12px 24px rgba(146, 40, 72, .35);
}
.home-page .admission-step h3 { font-family: var(--font-display); font-size: 1.4rem; font-weight: 700; }
@media (min-width: 992px) {
  .home-page .col-lg-3:not(:last-child) > .admission-step::after {
    content: ""; position: absolute; top: 3.6rem; right: -1.55rem; width: 1.55rem; z-index: 2;
    border-top: 2px dashed var(--pm-gold);
  }
}

/* leadership */
.home-page .leader-card {
  position: relative; border: 0 !important; border-radius: 24px !important; padding: 2.2rem 1.6rem !important;
  background: linear-gradient(180deg, #fff, var(--pm-rose)) !important; box-shadow: 0 18px 44px -16px rgba(42, 15, 26, .25);
  transition: transform .35s var(--pm-ease), box-shadow .35s;
}
.home-page .leader-card:hover { transform: translateY(-8px); box-shadow: 0 30px 60px -16px rgba(42, 15, 26, .35); }
.home-page .leader-symbol {
  width: 92px; height: 92px; border-radius: 50%; font-size: 2rem; border: 4px solid transparent;
  background: linear-gradient(#fff, #fff) padding-box, conic-gradient(from var(--ang), #CFB047, #B43B60, #3B1A27, #CFB047) border-box;
  color: var(--pm-crim); box-shadow: 0 14px 30px rgba(146, 40, 72, .25);
}
.home-page .leader-card h3 { font-family: var(--font-display); font-size: 1.5rem; font-weight: 700; }
.home-page .leader-role { display: inline-block; padding: .25rem .8rem; border-radius: 999px; background: #FBF4DB; color: var(--pm-gold-d); }

/* motto */
.home-page .home-motto-section { background: #fff !important; padding-top: 1rem; }
.home-page .home-motto {
  border: 1px solid rgba(207, 176, 71, .7); border-radius: 28px;
  background:
    radial-gradient(50% 80% at 100% 0%, rgba(207, 176, 71, .25), transparent 60%),
    linear-gradient(135deg, #240C16, #5A2037) !important; color: #fff;
  box-shadow: 0 34px 70px -24px rgba(42, 15, 26, .7);
}
.home-page .home-motto::before { color: rgba(207, 176, 71, .25) !important; font-family: var(--font-display) !important; }
.home-page .home-motto::after { content: ""; position: absolute; inset: 0; pointer-events: none; background: url(/images/islamic-pattern.svg) 0 0 / 120px; opacity: .7; }
.home-page .home-motto .motto-label { color: var(--pm-gold) !important; z-index: 1; }
.home-page .home-motto blockquote { color: #fff !important; font-family: var(--font-display) !important; font-weight: 600; z-index: 1; font-size: clamp(1.7rem, 3.4vw, 2.7rem); }
.home-page .home-motto .motto-attribution { color: var(--pm-gold-l) !important; z-index: 1; }

/* contact */
.home-page .contact-panel { border: 0; border-radius: 26px; box-shadow: 0 30px 64px -20px rgba(42, 15, 26, .3); background: linear-gradient(180deg, #fff, #FFF9EF); }
.home-page .contact-panel h3 { font-family: var(--font-display); font-size: 1.7rem; font-weight: 700; }
.home-page .contact-link { padding: .7rem .8rem; margin: .6rem -.8rem 0; border-radius: 16px; transition: background .25s, transform .25s var(--pm-ease); }
.home-page .contact-link:hover { background: #fff; transform: translateX(6px); box-shadow: 0 8px 22px rgba(42, 15, 26, .1); }
.home-page .contact-icon { width: 48px; height: 48px; flex-basis: 48px; border-radius: 15px; background: linear-gradient(135deg, #B43B60, #7D2842); color: #fff; box-shadow: 0 8px 18px rgba(146, 40, 72, .3); transform: rotate(-6deg); }

/* final call to action */
.home-page .home-cta-section { background: #fff; }
.home-page .home-cta {
  border-radius: 30px; position: relative; overflow: hidden;
  background:
    radial-gradient(50% 90% at 100% 0%, rgba(207, 176, 71, .35), transparent 60%),
    linear-gradient(120deg, #240C16, #5A2037 55%, #7D2842) !important;
  box-shadow: 0 34px 70px -24px rgba(42, 15, 26, .7);
}
.home-page .home-cta::before { content: ""; position: absolute; inset: 0; pointer-events: none; background: url(/images/islamic-pattern.svg) 0 0 / 120px; opacity: .8; }
.home-page .home-cta > * { position: relative; }
.home-page .home-cta h2 { font-family: var(--font-display); color: #fff; font-weight: 700; font-size: clamp(2rem, 3.8vw, 3.1rem); line-height: 1.1; }

/* ---------- 8. INNER PAGES (about, programmes, admissions...) ----------- */
.public-hero { isolation: isolate; }
.public-hero::before {
  content: ""; position: absolute; inset: -120px; z-index: -1; pointer-events: none; opacity: .9;
  background: url(/images/islamic-pattern.svg) 0 0 / 120px 120px;
}
.public-hero h1 { font-family: var(--font-display); font-weight: 700; }
.public-card { position: relative; overflow: hidden; border: 0 !important; border-radius: 22px !important; box-shadow: 0 16px 44px -16px rgba(42, 15, 26, .25) !important; }
.public-card::before { content: ""; position: absolute; top: 0; left: 0; right: 0; height: 4px; background: linear-gradient(90deg, var(--pm-gold), var(--pm-crim)); }
.public-card:hover { transform: translateY(-5px); box-shadow: 0 28px 56px -16px rgba(42, 15, 26, .35) !important; }

/* ---------- 9. ANIMATION (only for visitors who have not asked for less motion) */
@media (prefers-reduced-motion: no-preference) {
  /* hero entrance */
  .home-page .hero-content > * { animation: pm-rise .95s var(--pm-ease) both; }
  .home-page .hero-content > *:nth-child(1) { animation-delay: .05s; }
  .home-page .hero-content > *:nth-child(2) { animation-delay: .2s; }
  .home-page .hero-content > *:nth-child(3) { animation-delay: .35s; }
  .home-page .hero-content > *:nth-child(4) { animation-delay: .5s; }
  .home-page .hero-content > *:nth-child(5) { animation-delay: .65s; }
  @keyframes pm-rise { from { opacity: 0; transform: translateY(34px); filter: blur(8px); } to { opacity: 1; transform: none; filter: none; } }
  .hero-visual { animation: pm-zoom 1.2s .3s var(--pm-ease) both; }
  @keyframes pm-zoom { from { opacity: 0; transform: scale(.82) rotate(-8deg); } to { opacity: 1; transform: none; } }

  /* gold shimmer on the headline */
  .home-page .home-hero h1 span { animation: pm-shimmer 5s linear infinite; }
  @keyframes pm-shimmer { to { background-position: -220% 0; } }

  /* hero background life */
  .fx-pattern { animation: pm-drift 60s linear infinite; }
  @keyframes pm-drift { to { transform: translate(120px, 120px); } }
  .fx-orb { animation: pm-float 14s ease-in-out infinite; }
  .fx-orb-2 { animation-duration: 18s; animation-delay: -4s; }
  .fx-orb-3 { animation-duration: 22s; animation-delay: -9s; }
  @keyframes pm-float { 0%, 100% { transform: translate(0, 0) scale(1); } 33% { transform: translate(40px, 30px) scale(1.12); } 66% { transform: translate(-30px, 50px) scale(.94); } }
  .fx-star, .hv-star-a { animation: pm-spin 70s linear infinite; }
  .fx-star-2, .hv-star-b { animation: pm-spin-rev 55s linear infinite; }
  .fx-star-3 { animation: pm-spin 30s linear infinite; }
  @keyframes pm-spin { to { transform: rotate(360deg); } }
  @keyframes pm-spin-rev { to { transform: rotate(-360deg); } }
  .fx-spark { animation: pm-rise-spark var(--d, 9s) linear var(--dl, 0s) infinite; }
  @keyframes pm-rise-spark { 0% { transform: translateY(0) scale(.6); opacity: 0; } 15% { opacity: .95; } 100% { transform: translateY(-110vh) translateX(30px) scale(1.1); opacity: 0; } }
  .fx-orb-1, .fx-star-1, .fx-pattern, .fx-orb-2 { translate: 0 calc(var(--sy, 0) * .12px); }
  .fx-star-2, .fx-star-3, .hv-chip { translate: 0 calc(var(--sy, 0) * -.08px); }

  /* hero art */
  .hv-orbit { animation: pm-spin 24s linear infinite; }
  .hv-emblem { animation: pm-bob 6s ease-in-out infinite; }
  @keyframes pm-bob { 0%, 100% { transform: translate(-50%, -50%); } 50% { transform: translate(-50%, calc(-50% - 14px)); } }
  .hv-chip { animation: pm-chip 7s ease-in-out infinite; }
  .hv-chip-2 { animation-delay: -2.5s; }
  .hv-chip-3 { animation-delay: -5s; }
  @keyframes pm-chip { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-12px); } }
  .hv-glow { animation: pm-breathe 5s ease-in-out infinite; }
  @keyframes pm-breathe { 0%, 100% { opacity: .75; transform: scale(1); } 50% { opacity: 1; transform: scale(1.1); } }

  /* the main button pulses gently and shines now and then */
  .home-page .hero-actions .home-btn:first-child { animation: pm-pulse 2.8s ease-in-out infinite; }
  @keyframes pm-pulse { 0%, 100% { box-shadow: 0 10px 28px rgba(146, 40, 72, .38), 0 0 0 0 rgba(207, 176, 71, .55); } 50% { box-shadow: 0 10px 28px rgba(146, 40, 72, .38), 0 0 0 12px rgba(207, 176, 71, 0); } }
  .home-page .hero-actions .home-btn:first-child::after { animation: pm-shine 4.5s ease-in-out 1.6s infinite; }
  @keyframes pm-shine { 0%, 55% { left: -80%; } 85%, 100% { left: 130%; } }

  /* moving top edge of the fact strip, ribbon, ring around leader avatars */
  .home-page .home-facts .row::before { animation: pm-slide 4s linear infinite; }
  @keyframes pm-slide { to { background-position: -200% 0; } }
  .ribbon-track { animation: pm-marquee 38s linear infinite; }
  @keyframes pm-marquee { to { transform: translateX(-50%); } }
  .home-page .leader-symbol { animation: pm-ang 6s linear infinite; }
  @keyframes pm-ang { to { --ang: 360deg; } }

  /* sticker icons wiggle once the card has come into view */
  .home-page .programme-card-text .pc-icon, .home-page .feature-card .fi, .home-page .purpose-icon { animation: pm-wiggle 5s ease-in-out infinite; }
  .home-page .programme-card-text:nth-child(n) .pc-icon { animation-delay: .3s; }
  @keyframes pm-wiggle { 0%, 88%, 100% { rotate: 0deg; } 91% { rotate: -9deg; } 94% { rotate: 7deg; } 97% { rotate: -4deg; } }
  .home-page .step-number { animation: pm-ring 3s ease-in-out infinite; }
  @keyframes pm-ring { 0%, 100% { box-shadow: 0 0 0 6px rgba(180, 59, 96, .12), 0 12px 24px rgba(146, 40, 72, .35); } 50% { box-shadow: 0 0 0 13px rgba(180, 59, 96, 0), 0 12px 24px rgba(146, 40, 72, .35); } }

  /* scroll reveals: bigger, softer, and cards come in one after another */
  .js-motion .reveal { opacity: 0; transform: translateY(40px); transition: opacity .8s ease, transform .9s var(--pm-ease); }
  .js-motion .reveal.in { opacity: 1; transform: none; }
  .js-motion .reveal-stagger > * { opacity: 0; transform: translateY(46px) scale(.94); transition: opacity .7s ease, transform .85s var(--pm-ease); }
  .js-motion .reveal-stagger.in > * { opacity: 1; transform: none; }
  .js-motion .reveal-stagger.in > *:nth-child(2) { transition-delay: .12s; }
  .js-motion .reveal-stagger.in > *:nth-child(3) { transition-delay: .24s; }
  .js-motion .reveal-stagger.in > *:nth-child(4) { transition-delay: .36s; }
  .js-motion .reveal-stagger.in > *:nth-child(5) { transition-delay: .48s; }
  .js-motion .reveal-stagger.in > *:nth-child(6) { transition-delay: .6s; }
  .js-motion .reveal-stagger.in > *:nth-child(n+7) { transition-delay: .7s; }
  .js-motion .level-pills.reveal-stagger > * { transform: scale(.7); }
  .js-motion .level-pills.reveal-stagger.in > * { transform: none; }
  .js-motion .level-pills.reveal-stagger.in > *:nth-child(n) { transition-delay: calc(var(--i, 0) * .07s); }
}

/* ---------- 10. REDUCED MOTION: everything still, nothing hidden -------- */
@media (prefers-reduced-motion: reduce) {
  .fx-spark, .scroll-progress { display: none; }
  .ribbon-track { overflow-x: auto; }
  .home-page .home-btn::after { display: none; }
}


/* ---------- 11. FOOTER: compact, professional ---------------------------- */
.site-footer {
  position: relative; padding: 1.75rem 0 1rem; border-top: 3px solid var(--pm-gold);
  background: var(--pm-burg); color: #F3ECEE;
}
.site-footer::before, .site-footer::after { content: none; }
.site-footer .container { position: relative; z-index: 1; }
.sf-main { display: flex; align-items: center; justify-content: space-between; gap: 1.25rem 2rem; flex-wrap: wrap; }
.sf-main .sf-logo { display: flex; align-items: center; gap: .85rem; min-width: 0; flex: 1 1 340px; text-align: left; }
.sf-main .sf-logo img {
  width: 56px; height: 56px; flex: 0 0 56px; padding: 4px; border-radius: 12px; border: 0;
  background: #fff; box-shadow: none; animation: none;
}
.sf-name { display: block; min-width: 0; }
.sf-name b { display: block; font-family: var(--font-display); font-size: 1.12rem; font-weight: 700; line-height: 1.25; color: #fff; }
.sf-name small { display: block; margin-top: .25rem; font-size: .8rem; font-weight: 500; letter-spacing: .02em; line-height: 1.4; text-transform: none; color: var(--pm-gold-l); }
.sf-main .sf-social { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: .5rem; }
.sf-main .sf-social a {
  width: 40px; height: 40px; font-size: 1.05rem; background: rgba(255, 255, 255, .08);
  border: 1px solid rgba(255, 255, 255, .22); transition: background .2s, color .2s, border-color .2s;
}
.sf-main .sf-social a:hover, .sf-main .sf-social a:focus-visible {
  transform: none; background: var(--pm-gold); border-color: var(--pm-gold); color: var(--pm-burg); box-shadow: none;
}
.site-footer .sf-bottom {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: .4rem 1.1rem;
  margin-top: 1.25rem; padding-top: .85rem; border-top: 1px solid rgba(255, 255, 255, .14);
  font-size: .85rem; color: rgba(255, 255, 255, .72); text-align: center;
}
.site-footer .sf-bottom a { color: var(--pm-gold-l); text-decoration: none; }
.site-footer .sf-bottom a:hover { text-decoration: underline; }
.sf-bottom .sf-lang { margin: 0; padding: .2rem .8rem; font-size: .85rem; }
@media (max-width: 767.98px) {
  .site-footer { padding: 1.4rem 0 .9rem; }
  .sf-main { flex-direction: column; align-items: center; gap: 1rem; }
  .sf-main .sf-logo { flex: 0 0 auto; flex-direction: column; text-align: center; gap: .6rem; }
  .sf-main .sf-logo img { width: 48px; height: 48px; flex-basis: 48px; }
  .sf-name b { font-size: 1rem; }
  .sf-name small { font-size: .76rem; }
  .sf-main .sf-social { justify-content: center; gap: .45rem; }
  .sf-main .sf-social a { width: 38px; height: 38px; font-size: 1rem; }
  .site-footer .sf-bottom { margin-top: 1rem; padding-top: .7rem; font-size: .8rem; gap: .3rem .9rem; }
}
html.lang-ar .sf-main .sf-logo { text-align: right; }

/* ---------- 12. COURSE CARDS: the book list opens on tap ---------------- */
.home-page .pc-more { margin-top: .4rem; border-top: 1px solid #EFE6E9; }
.home-page .pc-more > summary {
  display: flex; align-items: center; gap: .6rem; padding: 1rem 0; cursor: pointer; list-style: none;
  color: var(--acc2); font-weight: 800; font-size: 1rem; min-height: 52px;
}
.home-page .pc-more > summary::-webkit-details-marker { display: none; }
.home-page .pc-more > summary span { flex: 1; }
.home-page .pc-count { display: grid; place-items: center; min-width: 28px; height: 28px; padding: 0 .4rem; border-radius: 999px; background: var(--acc); color: #fff; font-size: .85rem; }
.home-page .pc-more > summary i { transition: transform .3s var(--pm-ease); color: var(--acc); }
.home-page .pc-more[open] > summary i { transform: rotate(180deg); }
.home-page .pc-more[open] .pc-texts { animation: pm-open .4s var(--pm-ease) both; }
@keyframes pm-open { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: none; } }
.home-page .pc-more .pc-texts { border-top: 0; padding-top: 0; margin-top: 0; }

/* footer: registration details under the registered name */
.sf-name .sf-reg { display: flex; flex-wrap: wrap; gap: .1rem .9rem; margin-top: .4rem; font-size: .78rem; line-height: 1.5; color: rgba(255, 255, 255, .78); }
.sf-name .sf-reg > span { white-space: nowrap; }
.sf-name .sf-reg bdi { color: #fff; font-weight: 600; letter-spacing: .03em; }
@media (max-width: 767.98px) { .sf-name .sf-reg { justify-content: center; font-size: .74rem; gap: .05rem .7rem; } }
