/* ==========================================================================
   أكاديمية المعرفة | Al-Maarifa Academy — Design System
   Static site: HTML + Alpine.js — Arabic RTL
   Fonts are loaded via <link> in each page <head> for faster rendering.
   ========================================================================== */

:root {
  /* Brand palette */
  --navy-900: #081a33;
  --navy-800: #0b2545;
  --navy-700: #0f2d53;
  --navy-600: #163d6e;
  --navy-500: #1d4e89;
  --navy-400: #3877bb;

  --gold-700: #86691f;
  --gold-600: #a8862f;
  --gold-500: #c9a227;
  --gold-400: #d8b94e;
  --gold-300: #e7cd77;

  --teal-700: #0b5b5a;
  --teal-600: #0e7c7b;
  --teal-500: #14a3a1;

  --sand: #faf7f0;
  --sand-200: #f2ece0;
  --cream: #fffdf8;
  --ink: #1f2937;
  --ink-soft: #4b5563;
  --line: #e8e0d2;

  --shadow-sm: 0 2px 8px rgba(11, 37, 69, .06);
  --shadow-md: 0 12px 30px -8px rgba(11, 37, 69, .14);
  --shadow-lg: 0 28px 60px -16px rgba(11, 37, 69, .28);
  --shadow-gold: 0 14px 30px -10px rgba(201, 162, 39, .55);

  --radius: 18px;
  --radius-lg: 26px;
  --maxw: 1200px;
}

/* ------------------------------ Base ------------------------------ */
* { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 175px; }

body {
  margin: 0;
  font-family: 'Tajawal', system-ui, sans-serif;
  background: var(--sand);
  color: var(--ink);
  line-height: 1.85;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

h1, h2, h3, h4, h5, .font-display { font-family: 'Cairo', 'Tajawal', sans-serif; }
.font-brand { font-family: 'El Messiri', 'Cairo', serif; }

a { text-decoration: none; color: inherit; }
img { max-width: 100%; display: block; }
::selection { background: var(--gold-300); color: var(--navy-900); }

/* Scrollbar */
::-webkit-scrollbar { width: 12px; height: 12px; }
::-webkit-scrollbar-track { background: var(--sand-200); }
::-webkit-scrollbar-thumb { background: var(--navy-500); border-radius: 20px; border: 3px solid var(--sand-200); }
::-webkit-scrollbar-thumb:hover { background: var(--navy-700); }

/* ------------------------------ Layout ------------------------------ */
.container { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: 22px; }
.section { padding-block: clamp(56px, 8vw, 110px); position: relative; }
.section-sm { padding-block: clamp(40px, 5vw, 64px); }

.bg-sand { background: var(--sand); }
.bg-cream { background: var(--cream); }
.bg-navy { background: var(--navy-800); color: #eaf1fb; }

/* Decorative geometric pattern (8-point star) — subtle overlay */
.pattern-stars {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='60' height='60' viewBox='0 0 60 60'%3E%3Cpath d='M30 4l6 14 14 6-14 6-6 14-6-14-14-6 14-6z' fill='none' stroke='%23c9a227' stroke-width='1' opacity='0.5'/%3E%3C/svg%3E");
  background-size: 60px 60px;
}
.pattern-grid {
  background-image:
    linear-gradient(rgba(11,37,69,.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(11,37,69,.04) 1px, transparent 1px);
  background-size: 28px 28px;
}

/* Soft decorative blobs */
.blob { position: absolute; border-radius: 50%; filter: blur(60px); opacity: .5; pointer-events: none; z-index: 0; }
.blob-gold { background: radial-gradient(circle, rgba(216,185,78,.7), transparent 70%); }
.blob-teal { background: radial-gradient(circle, rgba(20,163,161,.5), transparent 70%); }
.blob-navy { background: radial-gradient(circle, rgba(56,119,187,.5), transparent 70%); }

/* ------------------------------ Typography helpers ------------------------------ */
.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: 'Cairo', sans-serif; font-weight: 700; font-size: .82rem;
  letter-spacing: .12em; color: var(--gold-600); text-transform: uppercase;
  margin-bottom: 16px;
}
.eyebrow::before { content: ""; width: 30px; height: 2px; background: var(--gold-500); display: inline-block; border-radius: 2px; }
.eyebrow.center { justify-content: center; }
.eyebrow.light { color: var(--gold-300); }
.eyebrow.light::before { background: var(--gold-400); }

.section-title {
  font-size: clamp(1.7rem, 3.6vw, 2.7rem); font-weight: 800; line-height: 1.3;
  color: var(--navy-800); margin: 0 0 14px;
}
.section-title .accent { color: var(--gold-600); }
.bg-navy .section-title { color: #fff; }

.lead { font-size: clamp(1rem, 1.6vw, 1.18rem); color: var(--ink-soft); max-width: 640px; }
.center .lead, .text-center .lead { margin-inline: auto; }
.bg-navy .lead { color: #c7d6ea; }

.text-gradient {
  background: linear-gradient(100deg, var(--gold-500), var(--gold-300));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}

/* ------------------------------ Buttons ------------------------------ */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  font-family: 'Cairo', sans-serif; font-weight: 700; font-size: 1rem;
  padding: 14px 28px; border-radius: 999px; cursor: pointer; border: 2px solid transparent;
  transition: transform .25s ease, box-shadow .25s ease, background .25s ease, color .25s ease;
  white-space: nowrap; line-height: 1;
}
.btn svg { width: 20px; height: 20px; }
.btn:hover { transform: translateY(-3px); }
.btn:active { transform: translateY(-1px); }

.btn-primary { background: linear-gradient(135deg, var(--gold-500), var(--gold-400)); color: var(--navy-900); box-shadow: var(--shadow-gold); }
.btn-primary:hover { box-shadow: 0 20px 40px -10px rgba(201,162,39,.7); }

.btn-navy { background: var(--navy-800); color: #fff; box-shadow: var(--shadow-md); }
.btn-navy:hover { background: var(--navy-700); }

.btn-outline { background: transparent; color: var(--navy-800); border-color: var(--navy-200, #c7d6ea); border-color: rgba(11,37,69,.22); }
.btn-outline:hover { border-color: var(--navy-800); background: var(--navy-800); color: #fff; }

.btn-light { background: rgba(255,255,255,.12); color: #fff; border-color: rgba(255,255,255,.4); backdrop-filter: blur(4px); }
.btn-light:hover { background: #fff; color: var(--navy-800); }

.btn-ghost { background: transparent; color: var(--navy-700); padding-inline: 8px; }
.btn-ghost:hover { color: var(--gold-600); transform: none; }

.btn-lg { padding: 17px 36px; font-size: 1.08rem; }
.btn-sm { padding: 10px 20px; font-size: .9rem; }

/* ------------------------------ Header / Nav ------------------------------ */
.site-header { position: sticky; top: 0; z-index: 60; }

.topbar {
  background: var(--navy-900); color: #dfe8f5; font-size: .86rem;
  font-family: 'Cairo', sans-serif; font-weight: 500;
}
.topbar .container { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding-block: 9px; flex-wrap: wrap; }
.topbar a { color: var(--gold-300); font-weight: 700; }
.topbar a:hover { color: #fff; }
.topbar .pulse { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--gold-400); box-shadow: 0 0 0 0 rgba(216,185,78,.7); animation: pulse 2s infinite; }
.topbar .meta { display: flex; align-items: center; gap: 18px; }
.topbar .meta span { display: inline-flex; align-items: center; gap: 7px; }

@keyframes pulse { 0%{box-shadow:0 0 0 0 rgba(216,185,78,.7)} 70%{box-shadow:0 0 0 9px rgba(216,185,78,0)} 100%{box-shadow:0 0 0 0 rgba(216,185,78,0)} }

.navbar {
  display: flex; align-items: center; justify-content: space-between; gap: 18px;
  padding-block: 14px; background: rgba(255,253,248,.86); backdrop-filter: blur(12px);
  border-bottom: 1px solid transparent; transition: padding .3s, box-shadow .3s, background .3s;
}
.navwrap { background: rgba(255,253,248,.86); transition: box-shadow .3s, background .3s; }
.is-scrolled .navwrap { box-shadow: var(--shadow-sm); background: rgba(255,253,248,.96); }
.is-scrolled .navbar { padding-block: 9px; }

.brand { display: flex; align-items: center; gap: 13px; }
.brand .crest { height: 96px; width: auto; flex: none; transition: transform .4s; object-fit: contain; }
.brand:hover .crest { transform: scale(1.05); }
.brand .name { display: flex; flex-direction: column; line-height: 1.15; }
.brand .name b { font-family: 'El Messiri', serif; font-weight: 700; font-size: 1.32rem; color: var(--navy-800); }
.brand .name small { font-size: .68rem; letter-spacing: .16em; color: var(--gold-600); font-family: 'Cairo', sans-serif; font-weight: 600; }

.main-nav { display: flex; align-items: center; gap: 4px; }
.nav-link {
  position: relative; font-family: 'Cairo', sans-serif; font-weight: 600; font-size: .98rem;
  color: var(--navy-700); padding: 10px 14px; border-radius: 12px; transition: color .2s, background .2s;
}
.nav-link::after {
  content: ""; position: absolute; bottom: 4px; right: 14px; left: 14px; height: 2px;
  background: var(--gold-500); border-radius: 2px; transform: scaleX(0); transform-origin: right; transition: transform .28s ease;
}
.nav-link:hover { color: var(--navy-900); }
.nav-link:hover::after { transform: scaleX(1); }
.nav-link.active { color: var(--navy-900); }
.nav-link.active::after { transform: scaleX(1); }

.nav-actions { display: flex; align-items: center; gap: 12px; }

/* Dropdown */
.dropdown { position: relative; }
.dropdown-menu {
  position: absolute; top: calc(100% + 10px); right: 0; min-width: 230px; background: #fff;
  border-radius: 16px; box-shadow: var(--shadow-lg); border: 1px solid var(--line); padding: 10px; z-index: 70;
}
.dropdown-menu a {
  display: flex; align-items: center; gap: 12px; padding: 11px 14px; border-radius: 12px;
  font-family: 'Cairo', sans-serif; font-weight: 600; color: var(--navy-700); font-size: .95rem; transition: background .18s, color .18s;
}
.dropdown-menu a:hover { background: var(--sand); color: var(--gold-700); }
.dropdown-menu a svg { width: 20px; height: 20px; color: var(--gold-600); flex: none; }
.dropdown .nav-link { display: inline-flex; align-items: center; gap: 4px; white-space: nowrap; }
.caret { width: 16px; height: 16px; transition: transform .25s; }

/* Hamburger */
.hamburger { display: none; width: 46px; height: 46px; border: 1px solid var(--line); border-radius: 12px; background: #fff; align-items: center; justify-content: center; cursor: pointer; color: var(--navy-800); }
.hamburger svg { width: 24px; height: 24px; }

/* Mobile drawer */
.drawer-backdrop { position: fixed; inset: 0; background: rgba(8,26,51,.55); backdrop-filter: blur(3px); z-index: 80; }
.drawer {
  position: fixed; top: 0; right: 0; bottom: 0; width: min(86vw, 360px); background: var(--cream);
  z-index: 90; box-shadow: var(--shadow-lg); display: flex; flex-direction: column; padding: 22px;
}
.drawer .brand { margin-bottom: 8px; }
.drawer-links { display: flex; flex-direction: column; gap: 4px; margin-top: 18px; }
.drawer-links a {
  font-family: 'Cairo', sans-serif; font-weight: 600; font-size: 1.06rem; color: var(--navy-800);
  padding: 13px 14px; border-radius: 12px; display: flex; align-items: center; gap: 12px;
}
.drawer-links a:hover, .drawer-links a.active { background: var(--sand); color: var(--gold-700); }
.drawer-links a svg { width: 20px; height: 20px; color: var(--gold-600); }
.drawer-sub { padding-inline-start: 18px; }

/* ------------------------------ Hero ------------------------------ */
.hero { position: relative; overflow: hidden; background: var(--navy-900); color: #fff; }
.hero-bg {
  position: absolute; inset: 0; z-index: 0;
  background:
    radial-gradient(1100px 600px at 85% -10%, rgba(56,119,187,.55), transparent 60%),
    radial-gradient(900px 700px at 10% 110%, rgba(20,163,161,.4), transparent 60%),
    linear-gradient(160deg, #081a33 0%, #0b2545 45%, #0f2d53 100%);
}
.hero-pattern { position: absolute; inset: 0; opacity: .18; z-index: 0; }
.hero .container { position: relative; z-index: 2; }

.page-hero { position: relative; overflow: hidden; background: var(--navy-900); color: #fff; padding-block: clamp(70px, 11vw, 130px) clamp(48px, 7vw, 80px); }
.breadcrumb { display: flex; align-items: center; gap: 9px; font-family: 'Cairo', sans-serif; font-size: .86rem; color: #a9c0e0; margin-bottom: 16px; }
.breadcrumb a:hover { color: var(--gold-300); }
.breadcrumb svg { width: 15px; height: 15px; opacity: .7; }

/* ------------------------------ Cards ------------------------------ */
.card {
  background: #fff; border-radius: var(--radius); border: 1px solid var(--line);
  box-shadow: var(--shadow-sm); transition: transform .3s ease, box-shadow .3s ease, border-color .3s;
  position: relative; overflow: hidden;
}
.card.pad { padding: 30px; }
.card.lift:hover { transform: translateY(-8px); box-shadow: var(--shadow-md); border-color: var(--gold-300); }

.card-icon {
  width: 60px; height: 60px; border-radius: 16px; display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, var(--navy-700), var(--navy-500)); color: var(--gold-300); margin-bottom: 18px;
  box-shadow: var(--shadow-sm);
}
.card-icon svg { width: 30px; height: 30px; }
.card-icon.gold { background: linear-gradient(135deg, var(--gold-500), var(--gold-400)); color: var(--navy-900); }
.card-icon.teal { background: linear-gradient(135deg, var(--teal-600), var(--teal-500)); color: #fff; }

.card h3 { font-size: 1.22rem; color: var(--navy-800); margin: 0 0 10px; font-weight: 700; }
.card p { margin: 0; color: var(--ink-soft); }

/* top accent bar that grows on hover */
.card .topbar-accent { position: absolute; top: 0; right: 0; left: 0; height: 4px; background: linear-gradient(90deg, var(--gold-500), var(--gold-300)); transform: scaleX(0); transform-origin: right; transition: transform .35s; }
.card.lift:hover .topbar-accent { transform: scaleX(1); }

/* ------------------------------ Value chips ------------------------------ */
.value-card { text-align: center; padding: 26px 18px; background:#fff; border-radius: var(--radius); border: 1px solid var(--line); transition: transform .3s, box-shadow .3s, background .3s; }
.value-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); background: linear-gradient(180deg,#fff, var(--sand)); }
.value-card .ring { width: 64px; height: 64px; margin: 0 auto 14px; border-radius: 50%; display: flex; align-items: center; justify-content: center; background: var(--sand); border: 2px dashed var(--gold-400); color: var(--gold-600); transition: transform .4s; }
.value-card:hover .ring { transform: rotate(8deg) scale(1.05); }
.value-card .ring svg { width: 30px; height: 30px; }
.value-card b { font-family: 'Cairo', sans-serif; color: var(--navy-800); font-size: 1.1rem; }
.value-card p { margin: 6px 0 0; font-size: .85rem; color: var(--ink-soft); line-height: 1.6; }

/* ------------------------------ Stats ------------------------------ */
.stat { text-align: center; }
.stat .num { font-family: 'Cairo', sans-serif; font-weight: 900; font-size: clamp(2rem, 4vw, 3rem); line-height: 1; color: var(--gold-500); }
.bg-navy .stat .num { color: var(--gold-400); }
.stat .label { font-family: 'Cairo', sans-serif; font-weight: 600; color: var(--ink-soft); margin-top: 8px; font-size: .98rem; }
.bg-navy .stat .label { color: #b9cae3; }

/* ------------------------------ Pills / badges ------------------------------ */
.pill { display: inline-flex; align-items: center; gap: 8px; padding: 7px 16px; border-radius: 999px; font-family: 'Cairo', sans-serif; font-weight: 600; font-size: .85rem; background: rgba(201,162,39,.14); color: var(--gold-700); border: 1px solid rgba(201,162,39,.3); }
.pill.light { background: rgba(255,255,255,.12); color: #fff; border-color: rgba(255,255,255,.3); }
.pill.teal { background: rgba(20,163,161,.14); color: var(--teal-700); border-color: rgba(20,163,161,.3); }

.chip { display: inline-flex; align-items: center; gap: 8px; padding: 9px 16px; border-radius: 12px; background: #fff; border: 1px solid var(--line); font-family: 'Cairo', sans-serif; font-weight: 600; color: var(--navy-700); font-size: .92rem; transition: transform .2s, box-shadow .2s, border-color .2s; }
.chip:hover { transform: translateY(-3px); box-shadow: var(--shadow-sm); border-color: var(--gold-300); }
.chip svg { width: 18px; height: 18px; color: var(--gold-600); }

/* ------------------------------ List checks ------------------------------ */
.check-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 13px; }
.check-list li { display: flex; align-items: flex-start; gap: 12px; color: var(--ink); }
.check-list li .ic { flex: none; width: 26px; height: 26px; border-radius: 8px; background: rgba(20,163,161,.14); color: var(--teal-600); display: flex; align-items: center; justify-content: center; margin-top: 3px; }
.check-list li .ic svg { width: 16px; height: 16px; }
.bg-navy .check-list li { color: #dce7f5; }

/* ------------------------------ Stage cards ------------------------------ */
.stage-card { position: relative; border-radius: var(--radius-lg); overflow: hidden; color: #fff; min-height: 340px; display: flex; flex-direction: column; justify-content: flex-end; padding: 30px; box-shadow: var(--shadow-md); transition: transform .35s; }
.stage-card:hover { transform: translateY(-8px); }
.stage-card .veil { position: absolute; inset: 0; z-index: 0; }
.stage-card .kg { background: linear-gradient(160deg, #14a3a1, #0b5b5a); }
.stage-card .c1 { background: linear-gradient(160deg, #3877bb, #0f2d53); }
.stage-card .c2 { background: linear-gradient(160deg, #a8862f, #634d17); }
.stage-card .content { position: relative; z-index: 2; }
.stage-card .badge-num { position: absolute; top: 24px; left: 24px; font-family: 'El Messiri', serif; font-weight: 700; font-size: 3.4rem; opacity: .25; line-height: 1; }
.stage-card h3 { color: #fff; font-size: 1.5rem; margin: 0 0 6px; }
.stage-card p { color: rgba(255,255,255,.86); margin: 0 0 16px; }
.stage-card .arrow { display: inline-flex; align-items: center; gap: 8px; font-family: 'Cairo', sans-serif; font-weight: 700; color: #fff; }
.stage-card .arrow svg { width: 18px; height: 18px; transition: transform .3s; }
.stage-card:hover .arrow svg { transform: translateX(-6px); }

/* ------------------------------ Journey timeline ------------------------------ */
.journey { display: flex; align-items: flex-start; justify-content: center; flex-wrap: nowrap; }
.journey-step { flex: 0 1 240px; display: flex; flex-direction: column; align-items: center; text-align: center; padding: 10px 8px; transition: transform .3s; }
.journey-step:hover { transform: translateY(-8px); }
.journey-dot { width: 80px; height: 80px; border-radius: 50%; display: flex; align-items: center; justify-content: center; box-shadow: var(--shadow-md); margin-bottom: 18px; border: 4px solid #fff; outline: 1px solid var(--line); }
.journey-dot svg { width: 34px; height: 34px; }
.journey-tag { font-family: 'Cairo', sans-serif; font-weight: 700; font-size: .74rem; letter-spacing: .08em; color: var(--gold-600); margin-bottom: 5px; }
.journey-step b { font-family: 'Cairo', sans-serif; font-size: 1.24rem; color: var(--navy-800); display: block; line-height: 1.3; }
.journey-step small { color: var(--ink-soft); font-size: .94rem; font-weight: 600; }
.journey-line { flex: 0 1 96px; min-width: 28px; height: 3px; margin-top: 39px; background: repeating-linear-gradient(90deg, var(--gold-400) 0 9px, transparent 9px 18px); }

/* ------------------------------ Stage detail panels ------------------------------ */
.stage-panel { position: relative; overflow: hidden; border-radius: var(--radius-lg); padding: clamp(32px, 4vw, 46px); color: #fff; box-shadow: var(--shadow-lg); min-height: 350px; display: flex; align-items: center; }
.stage-panel-kg { background: linear-gradient(155deg, #9c7a28, #574213); }
.stage-panel-c1 { background: linear-gradient(155deg, #1d4e89, #0b2545); }
.stage-panel-c2 { background: linear-gradient(155deg, #0e7c7b, #0b3b3a); }
.stage-panel .pattern { position: absolute; inset: 0; opacity: .16; }
.stage-panel-num { position: absolute; top: 24px; left: 30px; font-family: 'El Messiri', serif; font-weight: 700; font-size: 4.4rem; line-height: 1; opacity: .22; }
.stage-panel-icon { width: 74px; height: 74px; border-radius: 20px; background: rgba(255,255,255,.16); border: 1px solid rgba(255,255,255,.3); display: flex; align-items: center; justify-content: center; margin-bottom: 20px; }
.stage-panel-icon svg { width: 38px; height: 38px; color: #fff; }
.stage-panel h3 { font-size: clamp(1.6rem, 2.6vw, 2rem); color: #fff; margin: 0 0 6px; }
.stage-panel > div > p { color: rgba(255,255,255,.9); margin: 0 0 22px; font-size: 1.05rem; font-weight: 600; }
.stage-panel-meta { display: flex; flex-direction: column; gap: 10px; align-items: flex-start; }
.stage-panel-meta span { display: inline-flex; align-items: center; gap: 10px; font-family: 'Cairo', sans-serif; font-weight: 600; font-size: .92rem; color: #fff; background: rgba(255,255,255,.13); border: 1px solid rgba(255,255,255,.18); padding: 9px 15px; border-radius: 11px; }
.stage-panel-meta svg { width: 18px; height: 18px; flex: none; }

/* Flip a 2-col row on desktop (panel-first DOM, content shown first) */
@media (min-width: 761px) { .row-flip > :first-child { order: 2; } .row-flip > :last-child { order: 1; } }

/* ------------------------------ Steps ------------------------------ */
.step { position: relative; padding: 28px; background: #fff; border-radius: var(--radius); border: 1px solid var(--line); box-shadow: var(--shadow-sm); transition: transform .3s, box-shadow .3s; }
.step:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); }
.step .n { width: 52px; height: 52px; border-radius: 14px; background: linear-gradient(135deg, var(--navy-700), var(--navy-500)); color: var(--gold-300); display: flex; align-items: center; justify-content: center; font-family: 'Cairo', sans-serif; font-weight: 800; font-size: 1.3rem; margin-bottom: 16px; }
.step h3 { margin: 0 0 8px; color: var(--navy-800); font-size: 1.12rem; }
.step p { margin: 0; color: var(--ink-soft); font-size: .96rem; }

/* ------------------------------ Subject grid ------------------------------ */
.subject { display: flex; align-items: center; gap: 14px; padding: 16px 18px; background: #fff; border: 1px solid var(--line); border-radius: 14px; transition: transform .25s, box-shadow .25s, border-color .25s; }
.subject:hover { transform: translateY(-4px); box-shadow: var(--shadow-sm); border-color: var(--gold-300); }
.subject .ic { width: 44px; height: 44px; border-radius: 12px; flex: none; display: flex; align-items: center; justify-content: center; background: var(--sand); color: var(--navy-600); }
.subject .ic svg { width: 24px; height: 24px; }
.subject b { font-family: 'Cairo', sans-serif; color: var(--navy-800); font-size: 1rem; display: block; }
.subject span { font-size: .85rem; color: var(--ink-soft); }

/* compact subject pills (icon + label inline) */
.subject-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.subject-grid .subject { gap: 12px; font-family: 'Cairo', sans-serif; font-weight: 600; color: var(--navy-800); font-size: .95rem; }
.subject-grid .subject > svg { width: 24px; height: 24px; color: var(--gold-600); flex: none; }

/* spec / key-value list */
.spec-list { list-style: none; padding: 0; margin: 0; }
.spec-list li { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 12px 2px; border-bottom: 1px dashed var(--line); }
.spec-list li:last-child { border-bottom: 0; }
.spec-list li span { color: var(--ink-soft); font-size: .92rem; font-family: 'Cairo', sans-serif; }
.spec-list li b { color: var(--navy-800); font-family: 'Cairo', sans-serif; font-weight: 700; font-size: .97rem; text-align: left; }

/* ------------------------------ Accordion (FAQ) ------------------------------ */
.faq-item { background: #fff; border: 1px solid var(--line); border-radius: 16px; margin-bottom: 14px; overflow: hidden; transition: box-shadow .3s, border-color .3s; }
.faq-item.open { box-shadow: var(--shadow-md); border-color: var(--gold-300); }
.faq-q { width: 100%; text-align: right; display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 22px 24px; background: none; border: none; cursor: pointer; font-family: 'Cairo', sans-serif; font-weight: 700; font-size: 1.06rem; color: var(--navy-800); }
.faq-q .qmark { display: flex; align-items: center; gap: 14px; }
.faq-q .qmark .num { width: 34px; height: 34px; border-radius: 10px; background: var(--sand); color: var(--gold-600); display: flex; align-items: center; justify-content: center; font-weight: 800; flex: none; }
.faq-toggle { width: 34px; height: 34px; border-radius: 50%; background: var(--sand); display: flex; align-items: center; justify-content: center; flex: none; transition: transform .3s, background .3s; }
.faq-item.open .faq-toggle { transform: rotate(45deg); background: var(--gold-500); color: #fff; }
.faq-toggle svg { width: 18px; height: 18px; }
.faq-a { padding: 0 24px; color: var(--ink-soft); }
.faq-a-inner { padding-bottom: 22px; padding-inline-start: 48px; }

/* ------------------------------ Forms ------------------------------ */
.field { margin-bottom: 18px; }
.field label { display: block; font-family: 'Cairo', sans-serif; font-weight: 600; color: var(--navy-800); margin-bottom: 8px; font-size: .95rem; }
.field label .req { color: #d14343; }
.input, .select, .textarea {
  width: 100%; padding: 13px 16px; border: 1.5px solid var(--line); border-radius: 12px; background: #fff;
  font-family: 'Tajawal', sans-serif; font-size: 1rem; color: var(--ink); transition: border-color .2s, box-shadow .2s;
}
.input:focus, .select:focus, .textarea:focus { outline: none; border-color: var(--gold-500); box-shadow: 0 0 0 4px rgba(201,162,39,.16); }
.textarea { min-height: 130px; resize: vertical; }
.form-card { background: #fff; border-radius: var(--radius-lg); box-shadow: var(--shadow-md); border: 1px solid var(--line); padding: clamp(24px, 4vw, 44px); }
.form-note { display: flex; gap: 10px; align-items: flex-start; font-size: .88rem; color: var(--ink-soft); }
.alert-success { display: none; align-items: center; gap: 12px; background: rgba(20,163,161,.12); border: 1px solid rgba(20,163,161,.35); color: var(--teal-700); padding: 16px 18px; border-radius: 14px; font-family: 'Cairo', sans-serif; font-weight: 600; margin-bottom: 18px; }
.alert-success.show { display: flex; }
.alert-error { background: rgba(209,67,67,.1); border: 1px solid rgba(209,67,67,.35); color: #b91c1c; padding: 14px 18px; border-radius: 14px; font-family: 'Cairo', sans-serif; font-weight: 600; margin-bottom: 18px; font-size: .95rem; }
.btn:disabled { opacity: .65; cursor: not-allowed; transform: none; }
.alert-success svg { width: 24px; height: 24px; flex: none; }
.input.invalid, .select.invalid, .textarea.invalid { border-color: #d14343; box-shadow: 0 0 0 4px rgba(209,67,67,.12); }
.err-msg { color: #d14343; font-size: .82rem; margin: 6px 2px 0; font-family: 'Cairo', sans-serif; font-weight: 600; }

/* notice / callout */
.notice { display: flex; gap: 18px; align-items: flex-start; background: linear-gradient(120deg, rgba(201,162,39,.13), rgba(201,162,39,.03)); border: 1px solid rgba(201,162,39,.32); border-right: 5px solid var(--gold-500); border-radius: 16px; padding: 22px 24px; }
.notice-icon { width: 52px; height: 52px; border-radius: 14px; background: linear-gradient(135deg, var(--gold-500), var(--gold-400)); color: var(--navy-900); display: flex; align-items: center; justify-content: center; flex: none; box-shadow: var(--shadow-sm); }
.notice-icon svg { width: 26px; height: 26px; }
.notice b { font-family: 'Cairo', sans-serif; color: var(--navy-800); font-size: 1.1rem; display: block; margin-bottom: 5px; }
.notice p { margin: 0; color: var(--ink-soft); font-size: .96rem; }

/* ------------------------------ Contact page ------------------------------ */
.contact-panel { background: linear-gradient(160deg, var(--navy-700), var(--navy-900)); border-radius: var(--radius-lg); padding: clamp(28px, 4vw, 42px); color: #fff; box-shadow: var(--shadow-lg); position: relative; overflow: hidden; }
.contact-row { display: flex; gap: 16px; align-items: flex-start; padding: 16px 0; border-bottom: 1px solid rgba(255,255,255,.1); position: relative; z-index: 2; }
.contact-row:last-of-type { border-bottom: 0; }
.contact-row .ic-box { width: 48px; height: 48px; border-radius: 13px; background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.18); color: var(--gold-400); display: flex; align-items: center; justify-content: center; flex: none; }
.contact-row .ic-box svg { width: 22px; height: 22px; }
.contact-row .lbl { font-family: 'Cairo', sans-serif; font-size: .79rem; color: var(--gold-400); font-weight: 700; display: block; margin-bottom: 3px; }
.contact-row b { font-family: 'Cairo', sans-serif; color: #fff; font-size: 1.03rem; font-weight: 700; display: block; }
.contact-row a { color: #fff; }
.contact-row a:hover { color: var(--gold-300); }
.contact-row p { margin: 0; color: #bcd0ec; font-size: .93rem; }
.map-placeholder { position: relative; overflow: hidden; border-radius: var(--radius-lg); min-height: 320px; background: linear-gradient(150deg, var(--navy-700), var(--navy-900)); display: flex; align-items: center; justify-content: center; box-shadow: var(--shadow-lg); }
.map-placeholder .pattern-grid { position: absolute; inset: 0; opacity: .4; }
.map-pin { position: relative; z-index: 2; display: flex; flex-direction: column; align-items: center; color: #fff; text-align: center; }
.map-pin .dot { position: relative; width: 64px; height: 64px; margin-bottom: 16px; }
.map-pin .dot svg { width: 64px; height: 64px; color: var(--gold-400); position: relative; z-index: 2; filter: drop-shadow(0 6px 10px rgba(0,0,0,.4)); }
.map-pin .ping { position: absolute; left: 50%; top: 54%; width: 24px; height: 24px; transform: translate(-50%,-50%); border-radius: 50%; background: rgba(201,162,39,.5); animation: ping 1.8s cubic-bezier(0,0,.2,1) infinite; }
@keyframes ping { 0%{ transform: translate(-50%,-50%) scale(.6); opacity: .8 } 80%,100%{ transform: translate(-50%,-50%) scale(3.2); opacity: 0 } }
.map-pin b { font-family: 'El Messiri', serif; font-size: 1.5rem; color: #fff; }
.map-pin span { color: #bcd0ec; font-size: .96rem; margin-top: 4px; display: block; }

/* ------------------------------ CTA band ------------------------------ */
.cta-band { position: relative; overflow: hidden; border-radius: var(--radius-lg); padding: clamp(36px, 6vw, 64px); background: linear-gradient(135deg, var(--navy-800), var(--navy-600)); color: #fff; box-shadow: var(--shadow-lg); }
.cta-band .pattern { position: absolute; inset: 0; opacity: .14; }

/* ------------------------------ Footer ------------------------------ */
.site-footer { background: var(--navy-900); color: #b9cae3; position: relative; overflow: hidden; }
.site-footer .pattern { position: absolute; inset: 0; opacity: .05; }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1.4fr; gap: 40px; position: relative; z-index: 2; }
.site-footer h4 { color: #fff; font-size: 1.05rem; margin: 0 0 18px; font-family: 'Cairo', sans-serif; }
.footer-links { list-style: none; padding: 0; margin: 0; display: grid; gap: 11px; }
.footer-links a { color: #b9cae3; transition: color .2s, padding .2s; display: inline-flex; align-items: center; gap: 8px; font-size: .96rem; }
.footer-links a:hover { color: var(--gold-300); padding-inline-start: 5px; }
.footer-contact li { display: flex; align-items: flex-start; gap: 12px; margin-bottom: 14px; font-size: .96rem; }
.footer-contact svg { width: 20px; height: 20px; color: var(--gold-400); flex: none; margin-top: 3px; }
.footer-brand .name b { font-family: 'El Messiri', serif; font-size: 1.5rem; color: #fff; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.1); margin-top: 48px; padding-top: 26px; display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; position: relative; z-index: 2; font-size: .88rem; }
.social { display: flex; gap: 10px; }
.social a { width: 42px; height: 42px; border-radius: 12px; background: rgba(255,255,255,.08); display: flex; align-items: center; justify-content: center; color: #cdd; transition: background .25s, transform .25s, color .25s; }
.social a:hover { background: var(--gold-500); color: var(--navy-900); transform: translateY(-4px); }
.social a svg { width: 20px; height: 20px; }

/* ------------------------------ Reveal animation ------------------------------ */
.reveal { opacity: 0; transform: translateY(34px); transition: opacity .7s cubic-bezier(.2,.7,.2,1), transform .7s cubic-bezier(.2,.7,.2,1); }
.reveal.in { opacity: 1; transform: none; }
.reveal.d1 { transition-delay: .08s; }
.reveal.d2 { transition-delay: .16s; }
.reveal.d3 { transition-delay: .24s; }
.reveal.d4 { transition-delay: .32s; }
.reveal.d5 { transition-delay: .40s; }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1 !important; transform: none !important; } html { scroll-behavior: auto; } }

/* float animation for hero crest */
@keyframes float { 0%,100%{transform:translateY(0)} 50%{transform:translateY(-14px)} }
.floaty { animation: float 6s ease-in-out infinite; }

/* marquee for partners/values strip */
.marquee { overflow: hidden; }
.marquee-track { display: flex; gap: 50px; width: max-content; animation: marquee 28s linear infinite; }
.marquee:hover .marquee-track { animation-play-state: paused; }
@keyframes marquee { from { transform: translateX(0); } to { transform: translateX(50%); } }

/* divider with diamond */
.divider { display: flex; align-items: center; gap: 16px; color: var(--gold-500); }
.divider::before, .divider::after { content: ""; height: 1px; flex: 1; background: linear-gradient(90deg, transparent, var(--gold-400), transparent); }
.divider svg { width: 22px; height: 22px; }

/* ------------------------------ Utilities ------------------------------ */
.grid { display: grid; gap: 26px; }
.g-2 { grid-template-columns: repeat(2, 1fr); }
.g-3 { grid-template-columns: repeat(3, 1fr); }
.g-4 { grid-template-columns: repeat(4, 1fr); }
.items-center { align-items: center; }
.items-start { align-items: flex-start; }
.text-center { text-align: center; }
.mt-s { margin-top: 18px; } .mt-m { margin-top: 30px; } .mt-l { margin-top: 48px; }
.maxw-narrow { max-width: 760px; }
.relative { position: relative; }
.flex-actions { display: flex; gap: 14px; flex-wrap: wrap; }
.center .flex-actions, .text-center .flex-actions { justify-content: center; }

/* ------------------------------ Responsive ------------------------------ */
@media (max-width: 1024px) {
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 32px; }
  .g-4 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 880px) {
  .main-nav, .nav-actions .btn { display: none; }
  .hamburger { display: flex; }
  .topbar .meta span.hide-sm { display: none; }
}
@media (max-width: 760px) {
  .g-2, .g-3, .g-4 { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; text-align: center; }
  .section { padding-block: clamp(46px, 9vw, 70px); }
  .subject-grid { grid-template-columns: repeat(2, 1fr); }
  .journey { flex-direction: column; align-items: center; gap: 4px; }
  .journey-line { width: 3px; height: 38px; min-width: 0; margin: 0; background: repeating-linear-gradient(180deg, var(--gold-400) 0 9px, transparent 9px 18px); }
}

/* ===== Language toggle button ===== */
.lang-btn {
  display: inline-flex; align-items: center; gap: 6px;
  font-family: 'Cairo', sans-serif; font-weight: 700; font-size: .8rem;
  color: var(--gold-300); border: 1px solid rgba(255,255,255,.28);
  padding: 3px 12px; border-radius: 999px; cursor: pointer;
  background: transparent; transition: background .2s, color .2s, border-color .2s;
  line-height: 1.7;
}
.lang-btn:hover { background: rgba(255,255,255,.12); color: #fff; border-color: rgba(255,255,255,.5); }
.lang-btn-drawer {
  width: 100%; justify-content: center; margin-top: 10px;
  color: var(--navy-800); border-color: var(--navy-200, rgba(11,37,69,.25));
  font-size: .95rem; padding: 10px;
}
.lang-btn-drawer:hover { background: var(--sand); color: var(--gold-700); }
