/* ==========================================================
   مدارس علو الأهلية — تصميم عصري
   Design Tokens: مستوحاة من ألوان الشعار
   ========================================================== */
:root {
  --navy-900: #0f1340;
  --navy:     #1b2056;   /* كحلي الشعار */
  --navy-700: #262c74;
  --blue:     #0898c0;   /* أزرق الشعار */
  --blue-600: #0a86ab;
  --green:    #20b090;   /* أخضر الشعار */
  --green-600:#1a9a7d;

  --ink:      #1d2236;
  --ink-2:    #4a5068;
  --muted:    #7a8099;
  --line:     #e5e8f0;
  --bg:       #ffffff;
  --bg-alt:   #f5f7fb;
  --white:    #ffffff;

  --font: 'Cairo', 'Segoe UI', Tahoma, Arial, sans-serif;
  --container: 1200px;
  --radius: 18px;
  --radius-sm: 12px;
  --shadow-sm: 0 1px 2px rgba(15,19,64,.06), 0 2px 8px rgba(15,19,64,.05);
  --shadow:    0 10px 30px -12px rgba(15,19,64,.18), 0 2px 6px rgba(15,19,64,.05);
  --shadow-lg: 0 30px 60px -20px rgba(15,19,64,.35);
  --grad: linear-gradient(135deg, var(--navy) 0%, var(--navy-700) 55%, var(--blue) 130%);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 90px; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.75;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4 { line-height: 1.35; margin: 0 0 .5em; color: var(--navy); font-weight: 700; }
p { margin: 0 0 1em; }
ul, ol { margin: 0; padding: 0; list-style: none; }
:focus-visible { outline: 3px solid var(--blue); outline-offset: 3px; border-radius: 6px; }

.container { width: min(100% - 40px, var(--container)); margin-inline: auto; }
.icon { display: inline-block; vertical-align: middle; flex-shrink: 0; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 12px 24px; border-radius: 0; font: inherit; font-weight: 600;
  font-size: 15px; line-height: 1; border: 1.5px solid transparent; cursor: pointer;
  transition: transform .2s ease, box-shadow .2s ease, background .2s ease, color .2s ease, border-color .2s ease;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-2px); }
.btn-lg { padding: 16px 30px; font-size: 16px; }
.btn-sm { padding: 9px 16px; font-size: 14px; }
.btn-primary { background: var(--blue); color: #fff; box-shadow: 0 10px 24px -8px rgba(8,152,192,.6); }
.btn-primary:hover { background: var(--blue-600); }
.btn-light { background: #fff; color: var(--navy); }
.btn-light:hover { box-shadow: var(--shadow); }
.btn-outline { border-color: var(--navy); color: var(--navy); background: transparent; }
.btn-outline:hover { background: var(--navy); color: #fff; }
.btn-outline-light { border-color: rgba(255,255,255,.75); color: #fff; background: rgba(255,255,255,.08); backdrop-filter: blur(4px); cursor: pointer; }
.btn-outline-light:hover { background: #fff; color: var(--navy); }
.btn-ghost { color: #fff; border-color: rgba(255,255,255,.35); background: rgba(255,255,255,.08); }
.btn-ghost:hover { background: rgba(255,255,255,.16); }
.btn-ghost .icon { color: var(--green); }

/* ---------- Eyebrow & section heads ---------- */
.eyebrow {
  display: inline-block; font-size: 13px; font-weight: 600; letter-spacing: .02em;
  color: var(--blue); background: rgba(8,152,192,.09);
  padding: 6px 14px; border-radius: 999px; margin-bottom: 14px;
}
.eyebrow-light { color: #bff1e4; background: rgba(255,255,255,.12); }
.section { padding: 96px 0; }
.section-alt { background: var(--bg-alt); }
.section-head { margin-bottom: 48px; }
.section-head.center { text-align: center; max-width: 720px; margin-inline: auto; }
.section-head-row { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; flex-wrap: wrap; max-width: none; text-align: start; }
.section-title { font-size: clamp(28px, 3.4vw, 40px); letter-spacing: -.01em; margin-bottom: .3em; }
.section-sub { color: var(--muted); font-size: 17px; margin: 0; }
.lead { font-size: 19px; color: var(--navy); font-weight: 500; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,.86);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid var(--line);
}
.nav-wrap { display: flex; align-items: center; gap: 20px; min-height: 80px; width: min(100% - 40px, 1340px); }
.brand { display: flex; align-items: center; gap: 12px; flex-shrink: 0; }
.brand img { width: 52px; height: auto; }
.brand-text { display: flex; flex-direction: column; line-height: 1.2; }
.brand-text strong { color: var(--navy); font-size: 17px; }
.brand-text small { color: var(--muted); font-size: 11px; letter-spacing: .08em; margin-top: 2px; }
.main-nav { display: flex; align-items: center; gap: 6px; margin-inline-start: auto; flex-wrap: nowrap; }
.main-nav > a, .main-nav > .nav-lang {
  display: inline-flex; align-items: center; justify-content: center; white-space: nowrap;
  min-height: 42px; padding: 8px 14px; border: 1px solid var(--line); border-radius: 0; background: #fff;
  font-size: 14px; font-weight: 600; color: var(--ink-2); line-height: 1; transition: color .2s, background .2s, border-color .2s;
}
.main-nav > a:hover, .main-nav > .nav-lang:hover { color: #fff; background: var(--navy); border-color: var(--navy); }
.main-nav > .nav-lang:hover { color: #fff !important; background: var(--navy) !important; }
.nav-lang {
  gap: 8px; color: var(--navy) !important; border: 1.5px solid var(--navy) !important;
  background: transparent !important; font-weight: 700 !important; letter-spacing: .01em;
}
.nav-lang .icon { color: var(--blue); transition: color .2s; }
.nav-lang:hover .icon { color: #7ef0d2; }
.nav-lang span { direction: ltr; }
.header-actions { display: flex; align-items: center; gap: 10px; }
.header-actions .btn-ghost { color: var(--navy); border-color: var(--line); background: #fff; }
.header-actions .btn-icon { width: 44px; height: 44px; padding: 0; }
.header-actions .btn-ghost:hover { background: var(--bg-alt); }
.header-actions .btn-ghost .icon { color: var(--blue); }
.menu-btn {
  display: none; width: 44px; height: 44px; border-radius: 0; border: 1px solid var(--line);
  background: #fff; cursor: pointer; padding: 0; position: relative;
}
.menu-btn span {
  position: absolute; left: 12px; right: 12px; height: 2px; background: var(--navy); border-radius: 2px;
  transition: transform .25s, opacity .25s;
}
.menu-btn span:nth-child(1) { top: 14px; }
.menu-btn span:nth-child(2) { top: 21px; }
.menu-btn span:nth-child(3) { top: 28px; }
.menu-btn[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.menu-btn[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.menu-btn[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Hero ---------- */
.hero {
  position: relative; overflow: hidden; color: #fff;
  background: var(--navy);
  padding: 80px 0 0;
}
/* سلايدر صور المرافق الحقيقية */
.hero-slides { position: absolute; inset: 0; z-index: 0; overflow: hidden; }
.hero-slides span {
  position: absolute; inset: -2%; background-size: cover; background-position: center;
  opacity: 0; transform: scale(1.06); filter: saturate(1.05) contrast(1.03);
  animation: slide 24s ease-in-out infinite;
}
.hero-slides span:nth-child(1) { animation-delay: 0s; }
.hero-slides span:nth-child(2) { animation-delay: -6s; }
.hero-slides span:nth-child(3) { animation-delay: -12s; }
.hero-slides span:nth-child(4) { animation-delay: -18s; }
@keyframes slide {
  0%   { opacity: 0; transform: scale(1.06); }
  6%   { opacity: 1; }
  27%  { opacity: 1; transform: scale(1.01); }
  33%  { opacity: 0; transform: scale(1); }
  100% { opacity: 0; transform: scale(1.06); }
}
.hero-slides::after {
  content: ""; position: absolute; inset: 0;
  /* الطبقة أخف وأغمق جهة النص فقط ليبقى مقروءاً، وتظهر الصورة واضحة في الجهة الأخرى */
  background: linear-gradient(90deg, rgba(20,24,72,.80) 0%, rgba(27,32,86,.55) 45%, rgba(23,97,154,.22) 100%);
}
html[dir="rtl"] .hero-slides::after {
  background: linear-gradient(270deg, rgba(20,24,72,.80) 0%, rgba(27,32,86,.55) 45%, rgba(23,97,154,.22) 100%);
}
.hero-copy { text-shadow: 0 2px 18px rgba(10,12,40,.45); }
.hero-copy .btn { text-shadow: none; }
.hero > .container { position: relative; z-index: 1; }
@media (prefers-reduced-motion: reduce) { .hero-slides span { animation: none; opacity: 0; } .hero-slides span:first-child { opacity: 1; } }
.hero-grid { position: relative; display: grid; grid-template-columns: 1.1fr .9fr; gap: 48px; align-items: center; }
.hero-title { color: #fff; font-size: clamp(44px, 6.4vw, 78px); line-height: 1.12; font-weight: 800; letter-spacing: -.02em; margin-bottom: .35em; }
.hero-title span { display: block; }
.hero-title .accent { background: linear-gradient(90deg, #7ef0d2, #5cd3ef); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero-title .accent { text-shadow: none; } /* الظل يُعتّم النص المتدرّج الشفاف */
.hero-lead { font-size: 19px; color: rgba(255,255,255,.85); max-width: 560px; margin-bottom: 36px; }
.hero-cta { display: flex; gap: 14px; flex-wrap: wrap; }
.hero-cta .btn-primary { background: var(--green); box-shadow: 0 12px 28px -10px rgba(32,176,144,.8); }
.hero-cta .btn-primary:hover { background: var(--green-600); }
.hero-media { position: relative; }
.hero-cutout { position: relative; }
.hero-cutout img { position: relative; width: 100%; height: auto; }
.stats {
  position: relative; display: grid; grid-template-columns: repeat(4, 1fr); gap: 0;
  margin-top: 72px; background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.14); border-radius: var(--radius) var(--radius) 0 0;
  backdrop-filter: blur(6px);
}
.stats li { padding: 26px 28px; border-inline-start: 1px solid rgba(255,255,255,.12); }
.stats li:first-child { border-inline-start: 0; }
.stats strong { display: block; font-size: 20px; color: #fff; font-weight: 700; }
.stats span { font-size: 14px; color: rgba(255,255,255,.7); }

/* ---------- About ---------- */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: center; margin-bottom: 72px; }
.split-media { position: relative; }
.split-media img { border-radius: 24px; box-shadow: var(--shadow); width: 100%; aspect-ratio: 6/5; object-fit: cover; }
.split-media::after {
  content: ""; position: absolute; inset: -14px 14px 14px -14px; border-radius: 28px;
  background: linear-gradient(135deg, var(--green), var(--blue)); z-index: -1; opacity: .18;
}
.split-text p { color: var(--ink-2); }

/* ---------- الرؤية والرسالة والقيم ---------- */
.mvv { display: grid; grid-template-columns: 1.3fr 1fr; gap: 20px; margin-bottom: 96px; }
.mvv-card { position: relative; overflow: hidden; border-radius: 24px; padding: 40px; }
.mvv-head { display: flex; align-items: center; gap: 14px; margin-bottom: 22px; }
.mvv-head h3 { margin: 0; font-size: 18px; }
.mvv-icon {
  width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center; flex-shrink: 0;
}
.mvv-statement { margin: 0; text-wrap: balance; }

/* الرؤية: البطاقة الأبرز */
.mvv-vision {
  background: radial-gradient(120% 140% at 100% 0%, var(--navy-700) 0%, var(--navy) 45%, var(--navy-900) 100%);
  color: #fff; display: flex; flex-direction: column; justify-content: center; min-height: 300px;
  box-shadow: var(--shadow-lg);
}
.mvv-vision::after {
  content: ""; position: absolute; inset-inline-start: -90px; bottom: -110px; width: 320px; height: 320px;
  border-radius: 50%; background: radial-gradient(circle, rgba(8,152,192,.38), transparent 68%); pointer-events: none;
}
.mvv-vision .mvv-head { position: relative; z-index: 1; }
.mvv-vision .mvv-head h3 { color: #7ef0d2; }
.mvv-vision .mvv-icon { background: rgba(255,255,255,.1); color: #7ef0d2; border: 1px solid rgba(255,255,255,.16); }
.mvv-vision .mvv-statement {
  position: relative; z-index: 1; color: #fff; font-size: clamp(26px, 3vw, 36px);
  font-weight: 700; line-height: 1.6; max-width: 20em;
}
.mvv-mark {
  position: absolute; inset-inline-end: -50px; top: -40px; color: #fff; opacity: .05; pointer-events: none; line-height: 0;
}
.mvv-mark .icon { width: 280px; height: 280px; }

/* الرسالة */
.mvv-mission {
  background: linear-gradient(160deg, rgba(8,152,192,.08), rgba(32,176,144,.06) 60%, #fff);
  border: 1px solid var(--line); display: flex; flex-direction: column; justify-content: center;
}
.mvv-mission::before {
  content: ""; position: absolute; inset-block: 28px; inset-inline-start: 0; width: 4px;
  border-radius: 0 4px 4px 0; background: linear-gradient(180deg, var(--blue), var(--green));
}
[dir="rtl"] .mvv-mission::before { border-radius: 4px 0 0 4px; }
.mvv-mission .mvv-icon { background: #fff; color: var(--blue); box-shadow: var(--shadow-sm); }
.mvv-mission .mvv-statement { color: var(--navy); font-size: 21px; font-weight: 600; line-height: 1.85; }

/* القيم */
.mvv-values {
  grid-column: 1 / -1; background: #fff; border: 1px solid var(--line); box-shadow: var(--shadow-sm);
  display: grid; grid-template-columns: 220px 1fr; align-items: center; gap: 32px; padding: 32px 40px;
}
.mvv-values .mvv-head { margin: 0; }
.mvv-values .mvv-icon { background: linear-gradient(135deg, rgba(8,152,192,.14), rgba(32,176,144,.18)); color: var(--blue); }
.values-list { display: grid; grid-template-columns: repeat(5, 1fr); }
.values-list li {
  display: flex; flex-direction: column; align-items: flex-start; gap: 12px;
  padding-inline: 22px; border-inline-start: 1px solid var(--line);
}
.value-ico {
  width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center;
  background: var(--bg-alt); color: var(--blue);
}
.value-name { font-size: 16px; font-weight: 700; color: var(--navy); line-height: 1.5; }

/* ---------- مخرجاتنا: مسار ملف الخريج ---------- */
.section-head-wide { max-width: 880px; }
.section-title { text-wrap: balance; }
.profile-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.profile-card { display: flex; flex-direction: column; gap: 22px; }
.profile-top { display: flex; align-items: center; }
.profile-node {
  width: 56px; height: 56px; border-radius: 50%; flex-shrink: 0; display: grid; place-items: center; color: #fff;
  background: linear-gradient(135deg, var(--blue), var(--green));
  box-shadow: 0 0 0 5px rgba(8,152,192,.1), 0 10px 22px -8px rgba(8,152,192,.55);
}
.profile-line {
  flex: 1; height: 2px; margin-inline: 14px -12px; border-radius: 2px;
  background: repeating-linear-gradient(90deg, rgba(8,152,192,.38) 0 7px, transparent 7px 14px);
}
.profile-card:last-child .profile-line {
  -webkit-mask-image: linear-gradient(to right, #000, transparent); mask-image: linear-gradient(to right, #000, transparent);
}
[dir="rtl"] .profile-card:last-child .profile-line {
  -webkit-mask-image: linear-gradient(to left, #000, transparent); mask-image: linear-gradient(to left, #000, transparent);
}
.profile-body {
  position: relative; overflow: hidden; flex: 1; padding: 30px 26px 32px; border-radius: var(--radius);
  background: #fff; border: 1px solid var(--line); box-shadow: var(--shadow-sm);
}
.profile-num {
  position: absolute; bottom: -10px; inset-inline-end: 16px; font-size: 68px; font-weight: 800; line-height: 1;
  letter-spacing: -.02em; color: rgba(20,24,90,.055); user-select: none;
}
.profile-body h3 { position: relative; font-size: 20px; margin: 0 0 10px; }
.profile-body p { position: relative; color: var(--ink-2); font-size: 15px; line-height: 1.9; margin: 0; }

/* ---------- Stages ---------- */
.stage-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; margin-bottom: 56px; }
.stage-card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 32px 28px; box-shadow: var(--shadow-sm); position: relative; overflow: hidden;
  transition: transform .25s, box-shadow .25s;
}
.stage-card::before {
  content: ""; position: absolute; top: 0; inset-inline: 0; height: 4px;
  background: linear-gradient(90deg, var(--blue), var(--green));
}
.stage-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.stage-icon {
  width: 60px; height: 60px; border-radius: 18px; display: grid; place-items: center;
  background: var(--navy); color: #fff; margin-bottom: 18px;
}
.stage-card { display: flex; flex-direction: column; align-items: flex-start; }
.stage-card h3 { font-size: 22px; margin-bottom: 14px; }
.stage-note {
  display: inline-flex; align-items: center; gap: 8px; margin: 0 0 28px; padding: 6px 14px; border-radius: 999px;
  background: var(--bg-alt); color: var(--ink-2); font-size: 14px; font-weight: 600;
}
.stage-note .icon { color: var(--blue); }
.stage-link {
  margin-top: auto; display: inline-flex; align-items: center; gap: 8px; font-weight: 700; font-size: 15px; color: var(--blue);
  padding-top: 18px; border-top: 1px solid var(--line); align-self: stretch; transition: color .2s;
}
.stage-link:hover { color: var(--navy); }
.stage-link .arrow { display: inline-flex; transition: transform .25s var(--ease-out); }
.stage-link:hover .arrow { transform: translateX(-4px); }
[dir="ltr"] .stage-link .arrow { transform: scaleX(-1); }
[dir="ltr"] .stage-link:hover .arrow { transform: translateX(4px) scaleX(-1); }

.bilingual {
  display: grid; grid-template-columns: 1.2fr 1fr; gap: 48px; align-items: center;
  background: var(--grad); color: #fff; border-radius: 28px; padding: 56px; box-shadow: var(--shadow-lg);
  position: relative; overflow: hidden;
}
.bilingual::after {
  content: ""; position: absolute; width: 380px; height: 380px; border-radius: 50%;
  background: radial-gradient(circle, rgba(32,176,144,.35), transparent 70%); inset-inline-end: -120px; bottom: -160px;
}
.bilingual-text { position: relative; z-index: 1; }
.bilingual h3 { color: #fff; font-size: 30px; }
.bilingual p { color: rgba(255,255,255,.85); }
.bilingual-skills { position: relative; z-index: 1; display: grid; gap: 12px; }
.bilingual-skills li {
  display: flex; align-items: center; gap: 12px; padding: 16px 18px; border-radius: 14px;
  background: rgba(255,255,255,.09); border: 1px solid rgba(255,255,255,.14);
}
.bilingual-skills .icon { color: #7ef0d2; }
.bilingual-skills span { font-weight: 500; }

/* ---------- Fees ---------- */
.fees-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; margin-bottom: 48px; }
.card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 30px; box-shadow: var(--shadow-sm);
}
.card-title { font-size: 19px; padding-bottom: 14px; margin-bottom: 18px; border-bottom: 1px solid var(--line); }
.card-dark { background: var(--navy); border-color: var(--navy); }
.card-dark .card-title { color: #fff; border-color: rgba(255,255,255,.14); }
.card-dark .policy li { color: rgba(255,255,255,.86); }
.card-dark .policy li::before { background: var(--green); }
.note { font-size: 13px; color: var(--muted); margin: 14px 0 0; }

.table-wrap { overflow-x: auto; border-radius: var(--radius-sm); border: 1px solid var(--line); }
table { width: 100%; border-collapse: collapse; font-size: 15px; }
th, td { padding: 13px 16px; text-align: start; border-bottom: 1px solid var(--line); }
thead th { background: var(--bg-alt); color: var(--navy); font-weight: 600; font-size: 14px; }
tbody tr:last-child td { border-bottom: 0; }
tbody tr:hover td { background: #fafbfe; }
td.num { font-weight: 700; color: var(--navy); white-space: nowrap; direction: ltr; text-align: start; }

.discounts { display: grid; gap: 12px; }
.discounts li {
  display: flex; align-items: center; gap: 16px; padding: 14px 16px; border-radius: 14px; background: var(--bg-alt);
}
.discounts .pct {
  flex-shrink: 0; min-width: 62px; text-align: center; padding: 8px 10px; border-radius: 10px;
  background: var(--green); color: #fff; font-weight: 800; font-size: 16px;
}
.discounts span:last-child { font-size: 15px; color: var(--ink-2); }

.policy { counter-reset: p; display: grid; gap: 12px; }
.policy li { position: relative; padding-inline-start: 34px; font-size: 15px; color: var(--ink-2); }
.policy li::before {
  counter-increment: p; content: counter(p); position: absolute; inset-inline-start: 0; top: 2px;
  width: 22px; height: 22px; border-radius: 50%; background: var(--blue); color: #fff;
  font-size: 12px; font-weight: 700; display: grid; place-items: center;
}

.cta-band {
  display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap;
  padding: 36px 40px; border-radius: var(--radius); background: #fff; border: 1px solid var(--line); box-shadow: var(--shadow);
}
.cta-band h3 { font-size: 24px; margin: 0 0 4px; }
.cta-band p { margin: 0; color: var(--muted); }
.cta-actions { display: flex; gap: 12px; flex-wrap: wrap; }

/* ---------- News ---------- */
.news-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; margin-bottom: 56px; }
.news-card {
  background: #fff; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line);
  box-shadow: var(--shadow-sm); transition: transform .25s, box-shadow .25s; display: flex; flex-direction: column;
}
.news-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.news-card.news-featured { grid-column: span 2; }
.news-card.news-featured .news-thumb { aspect-ratio: auto; height: 100%; }
.news-thumb { aspect-ratio: 4 / 3; overflow: hidden; background: var(--bg-alt); }
.news-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s; }
.news-card:hover .news-thumb img { transform: scale(1.05); }
.news-body { padding: 22px 24px 26px; }
.news-body time { font-size: 13px; color: var(--green); font-weight: 600; }
.news-body h3 { font-size: 18px; margin: 6px 0 0; }
.news-excerpt { color: var(--ink-2); font-size: 14px; margin: 8px 0 0; }
.news-card.news-featured { flex-direction: row; }
.news-card.news-featured .news-thumb { width: 55%; aspect-ratio: auto; }
.news-card.news-featured .news-body { display: flex; flex-direction: column; justify-content: center; padding: 36px; }
.news-card.news-featured .news-body h3 { font-size: 26px; }

.partners { margin-top: 56px; padding-top: 36px; border-top: 1px solid var(--line); text-align: center; }
.partners-label {
  display: inline-block; margin: 0 0 24px; font-size: 22px; font-weight: 800; color: var(--navy);
}
.partners-list {
  display: flex; flex-wrap: wrap; justify-content: center; gap: 16px;
  margin: 0; padding: 0; list-style: none;
}
.partners-list li { flex: 0 0 auto; width: 220px; margin: 0; padding: 0; list-style: none; }
/* صندوق ثابت الحجم: أي شعار يُعرض كاملاً داخله بدون قص أو تمدد */
.partner-card {
  display: flex; align-items: center; justify-content: center; width: 100%; height: 100px; padding: 14px 20px;
  overflow: hidden; background: #fff; border: 1px solid var(--line); border-radius: var(--radius-sm); color: var(--navy);
  font-size: 15px; font-weight: 700; line-height: 1.4; text-align: center;
}
.partner-card img {
  display: block; width: 100%; height: 100%; max-width: 100%; max-height: 100%; object-fit: contain;
}
.partner-name { display: block; text-wrap: balance; }

/* ---------- Gallery ---------- */
.filters { display: flex; gap: 8px; flex-wrap: wrap; }
.filter {
  font: inherit; font-size: 14px; font-weight: 600; cursor: pointer; padding: 9px 18px; border-radius: 0;
  background: #fff; color: var(--ink-2); border: 1px solid var(--line); transition: .2s;
}
.filter:hover { color: var(--navy); border-color: var(--navy); }
.filter.is-active { background: var(--navy); color: #fff; border-color: var(--navy); }
.gallery-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.gallery-item { margin: 0; border-radius: var(--radius); overflow: hidden; position: relative; background: var(--bg-alt); box-shadow: var(--shadow-sm); }
.gallery-item[hidden] { display: none; }
.gallery-item a { display: block; position: relative; }
.gallery-item img { width: 100%; aspect-ratio: 4/3; object-fit: cover; transition: transform .5s; }
.gallery-item:hover img { transform: scale(1.06); }
.gallery-item figcaption {
  position: absolute; inset-inline: 0; bottom: 0; padding: 40px 18px 14px;
  background: linear-gradient(transparent, rgba(15,19,64,.8)); color: #fff; font-weight: 600; font-size: 15px;
  opacity: 0; transform: translateY(8px); transition: .3s;
}
.gallery-item:hover figcaption { opacity: 1; transform: none; }
.gallery-more { text-align: center; margin-top: 40px; }
.gallery-more[hidden], #galleryMore[hidden] { display: none; }

/* ---------- Lightbox ---------- */
.lightbox { position: fixed; inset: 0; z-index: 100; background: rgba(10,12,35,.92); display: grid; place-items: center; padding: 24px; }
.lightbox[hidden] { display: none; }
.lightbox img { max-width: min(1100px, 100%); max-height: 86vh; border-radius: 14px; box-shadow: var(--shadow-lg); }
.lightbox-close {
  position: absolute; top: 18px; inset-inline-end: 18px; width: 48px; height: 48px; border-radius: 0;
  border: 0; background: rgba(255,255,255,.14); color: #fff; font-size: 30px; line-height: 1; cursor: pointer;
}
.lightbox-close:hover { background: rgba(255,255,255,.26); }

/* ---------- Footer ---------- */
.site-footer { background: var(--navy-900); color: rgba(255,255,255,.78); padding-top: 72px; font-size: 15px; }
.footer-grid { display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 48px; padding-bottom: 56px; }
.footer-brand img { width: 84px; height: auto; margin-bottom: 18px; }
.footer-brand p { color: rgba(255,255,255,.65); max-width: 380px; }
.site-footer h4 { color: #fff; font-size: 17px; margin-bottom: 18px; }
.contact-list li, .footer-links li { display: flex; align-items: flex-start; gap: 12px; margin-bottom: 14px; }
.contact-list .icon { color: var(--green); margin-top: 4px; }
.contact-list a, .footer-links a { transition: color .2s; }
.contact-list a:hover, .footer-links a:hover { color: #fff; }
.footer-links li::before { content: "←"; color: var(--green); }
.footer-social { display: flex; gap: 10px; margin-top: 24px; flex-wrap: wrap; }
.footer-social a {
  width: 42px; height: 42px; border-radius: 0; display: grid; place-items: center;
  background: rgba(255,255,255,.08); color: #fff; transition: .2s;
}
.footer-social a:hover { background: var(--green); transform: translateY(-2px); }
.footer-bar { border-top: 1px solid rgba(255,255,255,.1); padding: 22px 0; font-size: 14px; color: rgba(255,255,255,.55); }
.footer-bar-inner { display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap; }
.footer-bar a { color: rgba(255,255,255,.7); }
.footer-bar a:hover { color: #fff; }
.to-top {
  width: 40px; height: 40px; border-radius: 0; display: grid; place-items: center;
  background: rgba(255,255,255,.1); color: #fff !important;
}

/* ---------- English (LTR) ---------- */
[dir="ltr"] .arrow { display: inline-flex; transform: scaleX(-1); }
[dir="ltr"] .footer-links li::before { content: "→"; }
[dir="ltr"] .policy li { padding-inline-start: 34px; }
[dir="ltr"] .brand { flex-direction: row; }

/* ---------- Responsive ---------- */
@media (max-width: 1180px) {
  .menu-btn { display: block; margin-inline-start: auto; }
  .header-actions { display: none; }
  .main-nav {
    position: fixed; inset: 80px 0 auto 0; flex-direction: column; align-items: stretch; gap: 0;
    background: #fff; padding: 12px 20px 24px; border-bottom: 1px solid var(--line); box-shadow: var(--shadow);
    transform: translateY(-120%); opacity: 0; pointer-events: none; transition: .3s ease; margin: 0; z-index: 49;
  }
  .main-nav.is-open { transform: none; opacity: 1; pointer-events: auto; max-height: calc(100vh - 80px); max-height: calc(100dvh - 80px); overflow-y: auto; }
  .main-nav > a, .main-nav > .nav-lang { padding: 14px 16px; margin-bottom: 8px; min-height: 0; font-size: 15px; }
  .nav-lang { margin: 12px 0 0; }
  .hero-grid { grid-template-columns: 1fr; }
  .hero-media { max-width: 520px; margin-inline: auto; width: 100%; }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .stats li:nth-child(3) { border-inline-start: 0; }
  .stats li:nth-child(n+3) { border-top: 1px solid rgba(255,255,255,.12); }
  .profile-grid, .stage-grid { grid-template-columns: repeat(2, 1fr); }
  .mvv { grid-template-columns: 1fr; }
  .mvv-vision { min-height: 0; }
  .mvv-values { grid-template-columns: 1fr; gap: 22px; }
  .values-list { grid-template-columns: repeat(3, 1fr); gap: 12px; }
  .values-list li {
    flex-direction: row; align-items: center; gap: 12px; padding: 12px 14px;
    border: 0; background: var(--bg-alt); border-radius: 14px;
  }
  .value-ico { background: #fff; width: 40px; height: 40px; }
  .split { grid-template-columns: 1fr; gap: 40px; }
  .bilingual { grid-template-columns: 1fr; padding: 40px; }
  .fees-grid { grid-template-columns: 1fr; }
  .news-grid { grid-template-columns: repeat(2, 1fr); }
  .news-card.news-featured { grid-column: span 2; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 640px) {
  body { font-size: 15px; }
  .container { width: min(100% - 28px, var(--container)); }
  .nav-wrap { min-height: 72px; }
  .main-nav { inset: 72px 0 auto 0; }
  .brand-text small { display: none; }
  .hero { padding-top: 48px; }
  .hero-lead { font-size: 17px; }
  .hero-cta .btn { flex: 1 1 100%; }
  .stats { margin-top: 48px; }
  .stats li { padding: 18px; }
  .section { padding: 64px 0; }
  .section-head { margin-bottom: 32px; }
  .profile-grid, .stage-grid, .news-grid, .gallery-grid { grid-template-columns: 1fr; }
  .mvv { margin-bottom: 64px; }
  .mvv-card { padding: 28px 24px; border-radius: 20px; }
  .mvv-values { padding: 26px 20px; }
  .values-list { grid-template-columns: 1fr; }
  .mvv-mission .mvv-statement { font-size: 18px; }
  .news-card.news-featured { grid-column: auto; flex-direction: column; }
  .news-card.news-featured .news-thumb { width: 100%; aspect-ratio: 4/3; }
  .bilingual { padding: 28px; border-radius: 22px; }
  .cta-band { padding: 26px; }
  .cta-actions .btn { flex: 1 1 100%; }
  .footer-grid { grid-template-columns: 1fr; gap: 32px; }
  .footer-bar-inner { justify-content: center; text-align: center; }
  .gallery-item figcaption { opacity: 1; transform: none; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

/* ==========================================================
   الحركة — نظام واحد متناسق
   1) تتابع دخول الهيرو عند التحميل
   2) ظهور تدريجي للعناصر عند التمرير (يضيفه app.js)
   3) تفاعلات صغيرة عند التحويم
   كل الحركة تعتمد على transform/opacity فقط، وتُعطَّل عند prefers-reduced-motion
   ========================================================== */
:root { --sx: -1; --ease-out: cubic-bezier(.2, .7, .2, 1); }
[dir="rtl"] { --sx: 1; }          /* اتجاه "البداية": يمين في العربية، يسار في الإنجليزية */

/* ---------- شريط تقدّم التمرير + ظل الهيدر ---------- */
.scroll-progress {
  position: fixed; top: 0; inset-inline: 0; height: 3px; z-index: 60; pointer-events: none;
  background: linear-gradient(90deg, var(--blue), var(--green));
  transform: scaleX(var(--p, 0)); transform-origin: right center;
}
[dir="ltr"] .scroll-progress { transform-origin: left center; }
.site-header { transition: box-shadow .3s ease, background .3s ease; }
.site-header.is-scrolled { box-shadow: 0 8px 28px -14px rgba(15,19,64,.28); background: rgba(255,255,255,.94); }

/* ---------- 1) الهيرو عند التحميل ---------- */
@keyframes rise { from { opacity: 0; transform: translateY(26px); } }
@keyframes hero-in { from { opacity: 0; transform: translateX(calc(var(--sx) * -60px)) scale(.95); } }
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-12px); } }

.hero-copy > .eyebrow { animation: rise .7s var(--ease-out) .05s backwards; }
.hero-title span:nth-child(1) { animation: rise .9s var(--ease-out) .15s backwards; }
.hero-title span:nth-child(2) { animation: rise .9s var(--ease-out) .3s backwards; }
.hero-lead { animation: rise .9s var(--ease-out) .45s backwards; }
.hero-cta { animation: rise .9s var(--ease-out) .6s backwards; }
.hero-media { animation: hero-in 1.1s var(--ease-out) .35s backwards; }
.hero-cutout { animation: float 7s ease-in-out 1.6s infinite; }
.stats li { animation: rise .8s var(--ease-out) backwards; }
.stats li:nth-child(1) { animation-delay: .85s; }
.stats li:nth-child(2) { animation-delay: .95s; }
.stats li:nth-child(3) { animation-delay: 1.05s; }
.stats li:nth-child(4) { animation-delay: 1.15s; }

/* ---------- 2) الظهور عند التمرير ---------- */
@keyframes reveal-up    { from { opacity: 0; transform: translateY(30px); } }
@keyframes reveal-row   { from { opacity: 0; transform: translateY(10px); } }
@keyframes reveal-start { from { opacity: 0; transform: translateX(calc(var(--sx) * 48px)); } }
@keyframes reveal-end   { from { opacity: 0; transform: translateX(calc(var(--sx) * -48px)); } }
@keyframes reveal-scale { from { opacity: 0; transform: scale(.93); } }
@keyframes pop  { from { opacity: 0; transform: scale(.5); } 60% { transform: scale(1.12); } }
@keyframes grow-x { from { transform: scaleX(0); } }
@keyframes grow-y { from { transform: scaleY(0); } }
@keyframes settle { from { transform: scale(1.14); } }

/* العنصر مخفي فقط عندما يعمل JavaScript، وإلا يبقى المحتوى ظاهرًا */
.js [data-reveal]:not(.is-in) { opacity: 0; }
.js [data-reveal].is-in { animation: var(--rv, reveal-up) .85s var(--ease-out) var(--d, 0ms) backwards; }
[data-reveal="up"]    { --rv: reveal-up; }
[data-reveal="row"]   { --rv: reveal-row; }
[data-reveal="start"] { --rv: reveal-start; }
[data-reveal="end"]   { --rv: reveal-end; }
[data-reveal="scale"] { --rv: reveal-scale; }
.js [data-reveal="row"].is-in { animation-duration: .5s; }

/* لمسات داخل البطاقات بعد ظهورها */
.value-ico { transform-origin: center; }
.values-list li.is-in .value-ico { animation: pop .7s cubic-bezier(.34,1.56,.64,1) calc(var(--d, 0ms) + 250ms) backwards; }
.stage-card::before { transform-origin: right center; }
[dir="ltr"] .stage-card::before { transform-origin: left center; }
.stage-card.is-in::before { animation: grow-x .9s var(--ease-out) calc(var(--d, 0ms) + 300ms) backwards; }
.stage-card.is-in .stage-icon { animation: pop .7s cubic-bezier(.34,1.56,.64,1) calc(var(--d, 0ms) + 200ms) backwards; }
.mvv-mission::before { transform-origin: top center; }
.mvv-mission.is-in::before { animation: grow-y 1s var(--ease-out) .5s backwards; }
.bilingual-skills li.is-in .icon { animation: pop .6s cubic-bezier(.34,1.56,.64,1) calc(var(--d, 0ms) + 250ms) backwards; }
.news-card.is-in .news-thumb img { animation: settle 1.4s var(--ease-out) var(--d, 0ms) backwards; }
.discounts li.is-in .pct { animation: pop .6s cubic-bezier(.34,1.56,.64,1) calc(var(--d, 0ms) + 200ms) backwards; }

/* حركة هادئة مستمرة في بطاقة الرؤية */
@keyframes breathe { 0%, 100% { opacity: .65; transform: scale(1); } 50% { opacity: 1; transform: scale(1.18); } }
@keyframes drift { 0%, 100% { transform: translate(0, 0) rotate(0); } 50% { transform: translate(calc(var(--sx) * -14px), 10px) rotate(-3deg); } }
.mvv-vision::after { animation: breathe 7s ease-in-out infinite; }
.mvv-mark { animation: drift 16s ease-in-out infinite; }

/* ---------- 3) التحويم ---------- */
.btn .arrow { transition: transform .25s var(--ease-out); }
.btn:hover .arrow { transform: translateX(-5px); }
[dir="ltr"] .btn:hover .arrow { transform: translateX(5px) scaleX(-1); }
.btn-primary:hover, .btn-light:hover { box-shadow: 0 14px 30px -10px rgba(8,152,192,.55); }
.stage-icon { transition: transform .35s var(--ease-out), background .25s; }
.stage-card:hover .stage-icon { transform: rotate(-8deg) scale(1.08); background: var(--blue); }
.value-ico { transition: background .25s, color .25s, transform .3s var(--ease-out); }
.values-list li:hover .value-ico { background: var(--blue); color: #fff; transform: translateY(-3px); }
.discounts li { transition: transform .25s var(--ease-out), background .25s; }
.discounts li:hover { transform: translateX(calc(var(--sx) * -6px)); background: #eef3fa; }
.partner-card { transition: transform .25s var(--ease-out), border-color .25s, box-shadow .25s; }
.partner-card:hover { transform: translateY(-3px); border-color: var(--blue); box-shadow: var(--shadow-sm); }
a.partner-card:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
.profile-body { transition: transform .3s var(--ease-out), border-color .25s, box-shadow .25s; }
.profile-card:hover .profile-body { transform: translateY(-5px); border-color: rgba(8,152,192,.35); box-shadow: var(--shadow); }
.profile-node { transition: transform .35s var(--ease-out); }
.profile-card:hover .profile-node { transform: scale(1.1) rotate(-6deg); }
.profile-line { transform-origin: right center; }
[dir="ltr"] .profile-line { transform-origin: left center; }
.profile-card.is-in .profile-node { animation: pop .7s cubic-bezier(.34,1.56,.64,1) calc(var(--d, 0ms) + 150ms) backwards; }
.profile-card.is-in .profile-line { animation: grow-x .9s var(--ease-out) calc(var(--d, 0ms) + 450ms) backwards; }
.filter { transition: background .2s, color .2s, border-color .2s, transform .2s; }
.filter:active, .btn:active { transform: scale(.97); }

/* ---------- تقليل الحركة: كل شيء ظاهر وثابت ---------- */
@media (prefers-reduced-motion: reduce) {
  .js [data-reveal] { opacity: 1 !important; transform: none !important; }
  .scroll-progress { display: none; }
}

/* مخرجاتنا — الاستجابة */
@media (max-width: 1180px) {
  .profile-card:nth-child(2n) .profile-line { opacity: 0; }
}
@media (max-width: 640px) {
  .profile-grid { gap: 18px; }
  .profile-card { display: grid; grid-template-columns: 56px 1fr; gap: 16px; position: relative; }
  .profile-card:nth-child(2n) .profile-line { opacity: 1; }
  .profile-line { display: none; }
  .profile-card::before {
    content: ""; position: absolute; inset-inline-start: 27px; top: 64px; bottom: -16px; width: 2px;
    background: repeating-linear-gradient(180deg, rgba(8,152,192,.38) 0 7px, transparent 7px 14px);
  }
  .profile-card:last-child::before { display: none; }
  .profile-body { padding: 24px 22px 26px; }
}

/* ==========================================================
   صفحة المراحل الدراسية + المقطع التعريفي في الرئيسية
   ========================================================== */
.main-nav > a[aria-current="page"] { color: #fff; background: var(--navy); border-color: var(--navy); }

/* رأس الصفحة الداخلية */
.page-hero {
  position: relative; overflow: hidden; color: #fff; padding: 72px 0 128px;
  background: radial-gradient(120% 140% at 100% 0%, var(--navy-700) 0%, var(--navy) 45%, var(--navy-900) 100%);
}
.page-hero::after {
  content: ""; position: absolute; inset-inline-start: -110px; bottom: -150px; width: 420px; height: 420px;
  border-radius: 50%; background: radial-gradient(circle, rgba(8,152,192,.4), transparent 68%); pointer-events: none;
  animation: breathe 7s ease-in-out infinite;
}
.page-hero-mark { position: absolute; inset-inline-end: -40px; top: -30px; color: #fff; opacity: .05; line-height: 0; pointer-events: none; animation: drift 16s ease-in-out infinite; }
.page-hero-mark .icon { width: 320px; height: 320px; }
.page-hero > .container { position: relative; z-index: 1; }
.breadcrumb ol { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; padding: 0; margin: 0 0 26px; list-style: none; font-size: 14px; font-weight: 600; color: rgba(255,255,255,.7); }
.breadcrumb li + li::before { content: "/"; margin-inline-end: 10px; opacity: .45; }
.breadcrumb a { transition: color .2s; }
.breadcrumb a:hover { color: #fff; }
.breadcrumb [aria-current] { color: #7ef0d2; }
.page-hero h1 { color: #fff; font-size: clamp(34px, 4.8vw, 58px); line-height: 1.2; font-weight: 800; letter-spacing: -.02em; margin: 0 0 .35em; text-wrap: balance; }
.page-hero p { margin: 0; max-width: 36em; font-size: 18px; color: rgba(255,255,255,.82); }
.breadcrumb { animation: rise .7s var(--ease-out) .05s backwards; }
.page-hero h1 { animation: rise .9s var(--ease-out) .15s backwards; }
.page-hero p { animation: rise .9s var(--ease-out) .3s backwards; }

/* بطاقات المراحل تتداخل مع أسفل رأس الصفحة */
.stages-section { padding-top: 0; }
.stages-section .stage-grid { position: relative; z-index: 2; margin-top: -64px; }
.stages-section .stage-card { box-shadow: var(--shadow); }
.stage-card { scroll-margin-top: 110px; }
.fees-section { padding-top: 0; }
.fees-section .fees-grid { position: relative; z-index: 2; margin-top: -64px; }

@media (max-width: 640px) {
  .page-hero { padding: 48px 0 96px; }
  .page-hero p { font-size: 16px; }
  .stages-section .stage-grid { margin-top: -44px; }
  .fees-section .fees-grid { margin-top: -44px; }
}

@media (max-width: 640px) {
  .partners { margin-top: 40px; padding-top: 28px; }
  .partners-list { gap: 12px; }
  .partners-list li { width: calc(50% - 6px); }
  .partner-card { height: 84px; padding: 10px 14px; font-size: 14px; }
}

/* ---------- Popup announcement ---------- */
.popup { position: fixed; inset: 0; z-index: 120; display: grid; place-items: center; padding: 20px; }
.popup[hidden] { display: none; }
.popup-backdrop { position: absolute; inset: 0; background: rgba(10,12,35,.72); animation: popupFade .3s ease both; }
.popup-dialog {
  position: relative; width: min(100%, 520px); max-height: calc(100vh - 40px); max-height: calc(100dvh - 40px); overflow: auto;
  background: #fff; border-radius: var(--radius); box-shadow: var(--shadow-lg); animation: popupIn .4s var(--ease-out, ease) both;
}
.popup-dialog:focus { outline: none; }
.popup-close {
  position: absolute; top: 8px; inset-inline-end: 12px; z-index: 2; width: auto; height: auto; padding: 2px 8px;
  border: 0; border-radius: 6px; background: none; box-shadow: none; cursor: pointer;
  font: inherit; font-size: 36px; font-weight: 400; line-height: 1; color: var(--navy);
  text-shadow: 0 0 3px #fff, 0 0 8px #fff, 0 0 14px #fff; transition: transform .2s;
}
.popup-close:hover { transform: scale(1.15); }
.popup-close:focus { outline: none; }
.popup-close:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
.popup-media { display: block; line-height: 0; background: none; }
.popup-media.is-link { cursor: pointer; }
.popup-media img { display: block; width: 100%; height: auto; max-width: none; max-height: none; object-fit: fill; }
.popup-body { padding: 26px 28px 30px; text-align: start; }
.popup-title { font-size: 24px; color: var(--navy); margin: 0 0 10px; line-height: 1.4; }
.popup-text { color: var(--ink-2); margin: 0 0 20px; }
.popup-body > :last-child { margin-bottom: 0; }
html.popup-open { overflow: hidden; }
@keyframes popupFade { from { opacity: 0; } to { opacity: 1; } }
@keyframes popupIn { from { opacity: 0; transform: translateY(18px) scale(.97); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .popup-backdrop, .popup-dialog { animation: none; } }
@media (max-width: 640px) { .popup-body { padding: 22px 20px 24px; } .popup-title { font-size: 21px; } }

/* ---------- Parents' guide modal (PDF) ---------- */
.guide { position: fixed; inset: 0; z-index: 125; display: grid; place-items: center; padding: 20px; }
.guide[hidden] { display: none; }
.guide-backdrop { position: absolute; inset: 0; background: rgba(10,12,35,.78); animation: popupFade .3s ease both; }
.guide-dialog {
  position: relative; display: flex; flex-direction: column; width: min(100%, 1000px);
  height: min(calc(100vh - 40px), 860px); height: min(calc(100dvh - 40px), 860px);
  background: #fff; border-radius: var(--radius); box-shadow: var(--shadow-lg); overflow: hidden; animation: popupIn .4s var(--ease-out, ease) both;
}
.guide-dialog:focus { outline: none; }
.guide-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px 20px; border-bottom: 1px solid var(--line); background: #fff; }
.guide-title { margin: 0; font-size: 18px; color: var(--navy); line-height: 1.4; }
.guide-actions { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }
.guide-close {
  border: 0; background: none; box-shadow: none; cursor: pointer; padding: 0 8px; border-radius: 6px;
  font: inherit; font-size: 34px; line-height: 1; color: var(--navy); transition: transform .2s;
}
.guide-close:hover { transform: scale(1.15); }
.guide-close:focus { outline: none; }
.guide-close:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
.guide-body { position: relative; flex: 1 1 auto; min-height: 0; background: var(--bg-alt); }
.guide-frame { display: block; width: 100%; height: 100%; border: 0; background: #fff; }
.guide-fallback { display: none; position: absolute; inset: 0; flex-direction: column; align-items: center; justify-content: center; gap: 18px; padding: 24px; text-align: center; color: var(--ink-2); }
.guide-fallback p { margin: 0; }
.guide.guide-nopdf .guide-frame { display: none; }
.guide.guide-nopdf .guide-fallback { display: flex; }
@media (max-width: 640px) {
  .guide { padding: 0; }
  .guide-dialog { width: 100%; height: 100%; max-height: none; border-radius: 0; }
  .guide-head { flex-wrap: wrap; padding: 10px 14px; }
  .guide-title { font-size: 16px; flex: 1 1 100%; order: 2; }
  .guide-actions { order: 1; width: 100%; }
  .guide-actions .btn { padding: 8px 12px; font-size: 13px; }
  .guide-close { margin-inline-start: auto; }
}
@media (prefers-reduced-motion: reduce) { .guide-backdrop, .guide-dialog { animation: none; } }

/* ---------- Contact page ---------- */
.contacts-stack { display: grid; gap: 28px; }
.contact-table td { vertical-align: middle; }
/* الصف الأول (عناوين الأعمدة) بخلفية كحلية ونص أبيض */
.contact-table thead th { background: var(--navy); color: #fff; font-weight: 700; font-size: 14px; border-bottom: 0; white-space: nowrap; }
.contact-table thead th.cell-action, .contact-table td.cell-action { text-align: center; }
.contact-link { display: inline-block; color: var(--navy); font-weight: 600; word-break: break-all; }
.contact-link:hover { color: var(--blue); text-decoration: underline; }
.contact-btn {
  display: inline-block; padding: 9px 20px; border-radius: 0; background: var(--green); color: #fff;
  min-width: 120px; font-size: 14px; font-weight: 700; line-height: 1.4; white-space: nowrap; text-align: center; transition: background .2s, transform .2s;
}
.contact-btn:hover { background: var(--green-600); transform: translateY(-1px); }
.contact-btn.is-disabled { background: #cfd5e3; color: #fff; cursor: not-allowed; pointer-events: none; }
@media (max-width: 760px) {
  .contacts-section { padding: 36px 0 56px; }
  .contacts-stack { gap: 20px; }
  .contacts-section .card { padding: 18px 14px 8px; }
  .contacts-section .card-title { font-size: 18px; margin-bottom: 14px; padding-bottom: 12px; }
  .contacts-section .table-wrap { border: 0; overflow: visible; border-radius: 0; }

  .contact-table, .contact-table tbody, .contact-table tr, .contact-table td { display: block; width: 100%; }
  .contact-table thead { display: none; }

  /* كل صف بطاقة مستقلة */
  .contact-table tr {
    margin-bottom: 12px; padding: 14px 16px; background: #fff;
    border: 1px solid var(--line); border-inline-start: 3px solid var(--blue); border-radius: 0;
  }
  .contact-table tbody tr:hover td { background: transparent; }
  .contact-table td { padding: 0; border: 0; text-align: start; min-width: 0; }
  .contact-table tr td:empty { display: none !important; }

  /* الخلية الأولى عنوان البطاقة */
  .contact-table td:first-child { font-weight: 700; font-size: 16px; line-height: 1.5; color: var(--navy); padding-bottom: 10px; margin-bottom: 8px; border-bottom: 1px dashed var(--line); }
  .contact-table td:first-child::before { display: none; }

  /* باقي الخلايا: اسم الحقل صغير ثم القيمة */
  .contact-table td:not(:first-child) { display: flex; align-items: baseline; justify-content: space-between; gap: 14px; padding: 5px 0; font-size: 15px; overflow-wrap: anywhere; }
  .contact-table td:not(:first-child)::before { content: attr(data-label); flex: 0 0 auto; max-width: 42%; font-size: 12.5px; font-weight: 600; color: var(--muted); }
  .contact-table td:not(:first-child) > * { text-align: end; }

  /* الجداول ذات العمودين: القيمة (جوال/بريد) تحت العنوان بدون اسم الحقل */
  .contact-table.cols-2 td:not(:first-child) { display: block; padding: 0; }
  .contact-table.cols-2 td:not(:first-child)::before { display: none; }
  .contact-table.cols-2 td:not(:first-child) > * { text-align: start; }
  .contact-table.cols-2 .contact-link { font-size: 16px; }

  /* زر الإجراء بعرض البطاقة */
  .contact-table td.cell-action { display: block; padding: 12px 0 2px; }
  .contact-table td.cell-action::before { display: none; }
  .contact-table td.cell-action .contact-btn { display: block; width: 100%; padding: 12px 16px; }
}

/* ---------- Nav dropdown (من نحن) ---------- */
.nav-dd { position: relative; display: flex; }
.nav-dd-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; white-space: nowrap; cursor: pointer;
  min-height: 42px; padding: 8px 14px; border: 1px solid var(--line); border-radius: 0; background: #fff;
  font: inherit; font-size: 14px; font-weight: 600; color: var(--ink-2); line-height: 1; transition: color .2s, background .2s, border-color .2s;
}
.nav-dd-btn:hover, .nav-dd.is-open .nav-dd-btn, .nav-dd.is-current .nav-dd-btn { color: #fff; background: var(--navy); border-color: var(--navy); }
.nav-dd-chev { transition: transform .2s; }
.nav-dd.is-open .nav-dd-chev { transform: rotate(180deg); }
.nav-dd-menu {
  display: none; position: absolute; top: 100%; inset-inline-start: 0; min-width: 210px; z-index: 60;
  background: #fff; border: 1px solid var(--line); border-top: 3px solid var(--blue); box-shadow: var(--shadow);
}
.nav-dd.is-open .nav-dd-menu { display: block; }
.nav-dd-menu a { display: block; padding: 12px 18px; font-size: 14px; font-weight: 600; color: var(--ink-2); border-bottom: 1px solid var(--line); white-space: nowrap; transition: background .2s, color .2s; }
.nav-dd-menu a:last-child { border-bottom: 0; }
.nav-dd-menu a:hover, .nav-dd-menu a[aria-current="page"] { background: var(--bg-alt); color: var(--navy); }
.nav-dd-menu a[aria-current="page"] { box-shadow: inset 3px 0 0 var(--blue); }
[dir="rtl"] .nav-dd-menu a[aria-current="page"] { box-shadow: inset -3px 0 0 var(--blue); }
@media (hover: hover) and (min-width: 1181px) {
  .nav-dd:hover .nav-dd-menu { display: block; }
  .nav-dd:hover .nav-dd-chev { transform: rotate(180deg); }
  .nav-dd:hover .nav-dd-btn { color: #fff; background: var(--navy); border-color: var(--navy); }
}
@media (max-width: 1180px) {
  .nav-dd { display: block; margin-bottom: 8px; }
  .nav-dd-btn { width: 100%; justify-content: space-between; padding: 14px 16px; min-height: 0; font-size: 15px; }
  .nav-dd-menu { position: static; min-width: 0; box-shadow: none; border: 0; border-top: 0; background: transparent; }
  .nav-dd-menu a { padding: 14px 24px; font-size: 15px; border-bottom: 0; white-space: normal; }
}

/* ---------- About pages ---------- */
.ab-heading { text-align: center; font-size: clamp(26px, 3.2vw, 38px); margin: 0 0 .6em; text-wrap: balance; }
.ab-intro { max-width: 900px; margin: 0 auto 44px; text-align: center; font-size: 17px; line-height: 2; color: var(--ink-2); }
.ab-cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
.ab-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 44px 32px; text-align: center; box-shadow: var(--shadow-sm); }
.ab-card h3 { font-size: 28px; margin: 0 0 14px; }
.ab-card p { margin: 0; font-size: 18px; line-height: 1.9; color: var(--ink-2); }

.ab-article { display: grid; grid-template-columns: minmax(0, 1fr); gap: 48px; align-items: start; }
.ab-article.has-media { grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); }
.ab-article.has-media.media-start .ab-media { order: -1; }
.ab-label { display: inline-block; margin-bottom: 10px; font-size: 13px; font-weight: 700; color: var(--blue); letter-spacing: .02em; }
.ab-title { font-size: clamp(26px, 3.2vw, 38px); margin: 0 0 .6em; }
.ab-text p { margin: 0 0 1.3em; font-size: 16.5px; line-height: 2.05; color: var(--ink-2); text-align: justify; }
.ab-text p:last-child { margin-bottom: 0; }
.ab-text strong { color: var(--navy); font-weight: 700; }
.ab-media { margin: 0; position: sticky; top: 110px; }
.ab-media img { display: block; width: 100%; height: auto; box-shadow: var(--shadow); }
.ab-media-art img { box-shadow: none; max-width: 420px; margin-inline: auto; }
.ab-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }

.ab-steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 44px 32px; }
.ab-steps li { text-align: center; }
.ab-num {
  display: inline-grid; place-items: center; width: 62px; height: 62px; margin-bottom: 18px; border-radius: 50%;
  font-size: 22px; font-weight: 800; color: var(--navy); background: #bfeae6;
}
.ab-steps-grey .ab-num { background: #ececec; width: 70px; height: 70px; font-size: 24px; }
.ab-steps p { margin: 0 auto; max-width: 330px; font-size: 16.5px; line-height: 1.9; color: var(--ink-2); }

@media (max-width: 960px) {
  .ab-article.has-media { grid-template-columns: minmax(0, 1fr); gap: 32px; }
  .ab-article.has-media.media-start .ab-media { order: 0; }
  .ab-media { position: static; }
  .ab-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .ab-cards { grid-template-columns: minmax(0, 1fr); gap: 16px; }
  .ab-card { padding: 30px 20px; }
  .ab-card h3 { font-size: 24px; }
  .ab-steps { grid-template-columns: minmax(0, 1fr); gap: 32px; }
  .ab-text p { text-align: start; font-size: 16px; }
}

/* ---------- قوائم فرعية داخل «المدارس» ---------- */
.nav-sub { position: relative; border-bottom: 1px solid var(--line); }
.nav-sub-btn { display: flex; width: 100%; align-items: center; justify-content: space-between; gap: 14px; padding: 12px 18px; font: inherit; font-size: 14px; font-weight: 600; color: var(--ink-2); background: transparent; border: 0; cursor: pointer; white-space: nowrap; text-align: start; }
.nav-sub-btn:hover, .nav-sub.is-open .nav-sub-btn, .nav-sub.is-current .nav-sub-btn { background: var(--bg-alt); color: var(--navy); }
.nav-sub-chev { transform: rotate(90deg); transition: transform .2s; }
[dir="rtl"] .nav-sub-chev { transform: rotate(-90deg); }
.nav-sub-menu { display: none; position: absolute; top: 0; inset-inline-start: 100%; min-width: 220px; background: var(--white, #fff); border: 1px solid var(--line); box-shadow: 0 10px 28px rgba(0,0,0,.12); z-index: 5; }
.nav-sub.is-open .nav-sub-menu { display: block; }
@media (hover: hover) and (min-width: 901px) { .nav-sub:hover .nav-sub-menu { display: block; } }
@media (max-width: 900px) {
  .nav-sub { border-bottom: 0; }
  .nav-sub-btn { padding: 14px 24px; font-size: 15px; }
  .nav-sub-chev, [dir="rtl"] .nav-sub-chev { transform: none; }
  .nav-sub.is-open .nav-sub-chev { transform: rotate(180deg); }
  .nav-sub-menu { position: static; min-width: 0; border: 0; box-shadow: none; background: transparent; }
  .nav-sub-menu a { padding: 12px 40px; }
}
.page-empty { text-align: center; color: var(--ink-2); padding: 56px 16px; border: 2px dashed var(--line); border-radius: 14px; max-width: 640px; margin: 0 auto; }

/* ---------- القبول والتسجيل: مستعرض الإنترنت المضمّن والجداول ---------- */
.ab-browser { background: #fff; border: 1px solid var(--line); border-radius: var(--radius-sm); overflow: hidden; box-shadow: var(--shadow-sm); }
.ab-browser-bar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 10px 14px; background: var(--bg-alt); border-bottom: 1px solid var(--line); }
.ab-browser-url { flex: 1 1 220px; min-width: 0; direction: ltr; text-align: left; font-size: 14px; color: var(--ink-2); background: #fff; border: 1px solid var(--line); border-radius: 999px; padding: 6px 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ab-browser-btn { appearance: none; border: 1px solid var(--line); background: #fff; color: var(--navy); border-radius: 999px; padding: 6px 14px; font: inherit; font-size: 14px; font-weight: 600; cursor: pointer; text-decoration: none; white-space: nowrap; }
.ab-browser-btn:hover { border-color: var(--blue); color: var(--blue-600); }
.ab-browser-frame { display: block; width: 100%; min-height: 300px; border: 0; background: #fff; }
.ab-browser + .note { text-align: center; }
@media (max-width: 640px) {
  .ab-browser-url { order: 3; flex-basis: 100%; }
  .ab-browser-bar { justify-content: space-between; }
}

/* ---------- توسيط نصوص قائمة الجوال (الأزرار والقوائم المنسدلة) ---------- */
@media (max-width: 1180px) {
  .nav-dd-btn { position: relative; justify-content: center; text-align: center; padding-inline: 44px; }
  .nav-dd-chev { position: absolute; inset-inline-end: 16px; top: 50%; margin-top: -6px; }
  .nav-dd-menu a { text-align: center; padding-inline: 16px; }
}
@media (max-width: 900px) {
  .nav-sub-btn { position: relative; justify-content: center; text-align: center; padding-inline: 44px; }
  .nav-sub-chev { position: absolute; inset-inline-end: 16px; top: 50%; margin-top: -5px; }
  .nav-sub-menu a { text-align: center; padding-inline: 16px; }
}

/* ---------- مجتمع علو: عناصر قابلة للطي وصورة القسم ---------- */
.ab-narrow { max-width: 980px; }
.ab-acc { display: grid; gap: 22px; }
.ab-acc-item { background: #fff; border-bottom: 3px solid var(--blue); box-shadow: var(--shadow); }
.ab-acc-item summary {
  list-style: none; cursor: pointer; display: flex; align-items: center; gap: 14px;
  padding: 24px 28px; font-size: 20px; font-weight: 600; color: var(--green-600); line-height: 1.6;
}
.ab-acc-item summary::-webkit-details-marker { display: none; }
.ab-acc-item summary::before {
  content: ""; flex: 0 0 16px; height: 3px; background: var(--blue); border-radius: 2px;
}
.ab-acc-item:not([open]) summary::before {
  height: 16px; background:
    linear-gradient(var(--blue), var(--blue)) center / 100% 3px no-repeat,
    linear-gradient(var(--blue), var(--blue)) center / 3px 100% no-repeat;
}
.ab-acc-item summary:focus-visible { outline: 2px solid var(--blue); outline-offset: -2px; }
.ab-acc-body { padding: 0 28px 28px; color: var(--ink-2); font-size: 17px; line-height: 2; }
.ab-acc-body p { margin: 0 0 .7em; }
.ab-acc-body ul { margin: 0 0 .7em; padding-inline-start: 1.4em; }
.ab-acc-body li { margin-bottom: .45em; }
.ab-acc-body li::marker { color: var(--ink-2); }
.ab-acc-body > :last-child { margin-bottom: 0; }
.ab-section-tight { padding-block: 0 24px; }
.ab-figure { margin: 0 auto; max-width: 820px; text-align: center; }
.ab-figure img { display: block; width: 100%; height: auto; box-shadow: var(--shadow); }
.ab-figure figcaption { margin-top: 12px; font-size: 14px; color: var(--muted); }
@media (max-width: 640px) {
  .ab-acc-item summary { padding: 18px 18px; font-size: 17px; }
  .ab-acc-body { padding: 0 18px 20px; font-size: 16px; }
}

/* ---------- نموذج «اتصل بنا» والأسئلة الشائعة ---------- */
.cf-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 56px; align-items: start; }
.cf-h { margin: 0 0 28px; font-size: clamp(24px, 2.6vw, 34px); font-weight: 500; line-height: 1.5; color: var(--ink); }
.cf-form { display: grid; gap: 18px; }
.cf-field { display: grid; gap: 8px; font-weight: 700; color: var(--ink); }
.cf-req { color: #d4202e; }
.cf-field input, .cf-field textarea {
  width: 100%; padding: 14px 18px; font: inherit; font-weight: 400; color: var(--ink);
  background: #fff; border: 1px solid var(--line); border-radius: 14px; transition: border-color .2s, box-shadow .2s;
}
.cf-field textarea { resize: vertical; min-height: 150px; }
.cf-field input:focus, .cf-field textarea:focus { outline: 0; border-color: var(--blue); box-shadow: 0 0 0 3px rgba(8,152,192,.15); }
.cf-form .btn { justify-self: start; min-width: 140px; }
.pdf-viewer { display: grid; gap: 14px; }
.pdf-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.pdf-frame { display: block; width: 100%; height: min(85vh, 1100px); min-height: 480px; border: 1px solid var(--line, #dde3ea); background: #fff; box-shadow: var(--shadow-sm); }
.pdf-note { margin: 0; }
.cf-wide { max-width: 980px; margin-inline: auto; }
.cf-kinds { border: 0; padding: 0; margin: 0; min-width: 0; }
.cf-kinds legend { padding: 0; margin-bottom: 8px; font-weight: 700; }
.cf-checks { display: flex; flex-wrap: wrap; gap: 12px 32px; }
.cf-check { display: inline-flex; align-items: center; gap: 8px; font-weight: 400; cursor: pointer; }
.cf-check input { width: 18px; height: 18px; accent-color: var(--blue); }
.cf-hp { position: absolute; inset-inline-start: -9999px; width: 1px; height: 1px; overflow: hidden; }
.cf-alert { margin: 0 0 20px; padding: 14px 18px; border-radius: 12px; font-weight: 600; line-height: 1.8; }
.cf-ok { background: #e7f7f1; color: #0e6b52; border: 1px solid #b7e6d6; }
.cf-err { background: #fdecea; color: #8a1f15; border: 1px solid #f3b9b2; }
.cf-faq-list { display: grid; gap: 14px; }
.cf-faq-item { background: #fff; box-shadow: var(--shadow-sm); }
.cf-faq-item summary {
  list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: space-between; gap: 14px;
  padding: 22px 26px; font-weight: 700; color: var(--navy); line-height: 1.7;
}
.cf-faq-item summary::-webkit-details-marker { display: none; }
.cf-faq-item summary::after {
  content: ""; flex: 0 0 9px; height: 9px; border-inline-end: 2px solid var(--muted); border-bottom: 2px solid var(--muted);
  transform: rotate(45deg); transition: transform .2s; margin-top: -4px;
}
.cf-faq-item[open] summary::after { transform: rotate(-135deg); margin-top: 4px; }
.cf-faq-item summary:focus-visible { outline: 2px solid var(--blue); outline-offset: -2px; }
.cf-faq-a { padding: 0 26px 24px; color: var(--ink-2); line-height: 2; }
@media (max-width: 900px) {
  .cf-grid { grid-template-columns: minmax(0, 1fr); gap: 40px; }
  .cf-form .btn { justify-self: stretch; }
}
