/* ==================== الألوان والأساسيات ==================== */
:root {
  --navy: #0b2a5b;
  --navy-2: #123a7a;
  --blue: #1d84d6;
  --blue-2: #3aa0ea;
  --sky: #e8f2fc;
  --bg: #f3f7fc;
  --card: #ffffff;
  --text: #13233f;
  --muted: #5d6b82;
  --line: #dfe7f2;
  --radius: 18px;
  --shadow: 0 6px 22px rgba(11, 42, 91, .08);
  --shadow-lg: 0 14px 40px rgba(11, 42, 91, .14);
  --header-h: 84px;
  --bottom-h: 70px;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: 'Tajawal', 'Cairo', system-ui, -apple-system, 'Segoe UI', Tahoma, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.7;
  padding-bottom: calc(var(--bottom-h) + env(safe-area-inset-bottom));
  overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
button { font-family: inherit; cursor: pointer; border: 0; background: none; color: inherit; }
input, textarea, select { font-family: inherit; font-size: 16px; }
.icon.solid { fill: currentColor; stroke: none; }
.icon { width: 1.4em; height: 1.4em; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; }
.container { width: 100%; max-width: 1200px; margin-inline: auto; padding-inline: 16px; }
.app { min-height: 60vh; }
.loader { display: grid; place-items: center; min-height: 60vh; }
.loader span { width: 44px; height: 44px; border-radius: 50%; border: 4px solid var(--sky); border-top-color: var(--blue); animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes fadeUp { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
.page { animation: fadeUp .35s ease both; }

/* ==================== الهيدر ==================== */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, .96);
  backdrop-filter: blur(10px);
  box-shadow: 0 2px 14px rgba(11, 42, 91, .06);
}
.header-inner { display: flex; align-items: center; gap: 12px; min-height: var(--header-h); }
.brand { display: flex; align-items: center; gap: 12px; flex: 1; min-width: 0; }
.brand-logo { width: 66px; height: 66px; border-radius: 50%; object-fit: cover; flex-shrink: 0; box-shadow: 0 2px 10px rgba(11, 42, 91, .2); }
.brand-sep { width: 1px; align-self: stretch; margin-block: 14px; background: var(--line); }
.brand-text { min-width: 0; text-align: center; flex: 1; }
.brand-name { color: var(--navy); font-weight: 800; font-size: clamp(16px, 4.4vw, 22px); line-height: 1.35; }
.brand-slogan { color: var(--blue); font-size: 13px; font-weight: 600; display: flex; align-items: center; justify-content: center; gap: 8px; }
.brand-slogan::before, .brand-slogan::after { content: ''; width: 14px; height: 2px; background: var(--blue); border-radius: 2px; }
.menu-btn { width: 46px; height: 46px; display: grid; place-items: center; color: var(--navy); border-radius: 12px; }
.menu-btn .icon { width: 32px; height: 32px; stroke-width: 2.4; }
.menu-btn:hover { background: var(--sky); }
.top-nav { display: none; }
.bell-btn { position: relative; display: none; }

/* ==================== القائمة الجانبية ==================== */
.drawer-backdrop { position: fixed; inset: 0; background: rgba(5, 20, 45, .45); opacity: 0; pointer-events: none; transition: .25s; z-index: 90; }
.drawer {
  position: fixed; top: 0; bottom: 0; left: 0; width: min(320px, 86vw); z-index: 100;
  background: #fff; transform: translateX(-100%); transition: transform .3s ease;
  display: flex; flex-direction: column; overflow-y: auto;
}
body.drawer-open .drawer { transform: none; }
body.drawer-open .drawer-backdrop { opacity: 1; pointer-events: auto; }
body.drawer-open { overflow: hidden; }
.drawer-head { background: linear-gradient(135deg, var(--navy), var(--blue)); color: #fff; padding: 28px 20px 22px; text-align: center; position: relative; }
.drawer-head img { width: 84px; height: 84px; border-radius: 50%; margin: 0 auto 10px; border: 3px solid rgba(255, 255, 255, .5); }
.drawer-head b { display: block; font-size: 17px; }
.drawer-head small { opacity: .85; }
.drawer-close { position: absolute; top: 12px; left: 12px; color: #fff; width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; background: rgba(255, 255, 255, .15); }
.drawer-links { padding: 12px; display: flex; flex-direction: column; gap: 4px; }
.drawer-links a { display: flex; align-items: center; gap: 14px; padding: 13px 14px; border-radius: 12px; font-weight: 600; color: var(--navy); }
.drawer-links a .icon { color: var(--blue); }
.drawer-links a.active, .drawer-links a:hover { background: var(--sky); }

/* ==================== السلايدر ==================== */
/* التصميم: الصورة على اليسار، ولوحة زرقاء منحنية فيها النص على اليمين */
.hero { position: relative; overflow: hidden; background: linear-gradient(115deg, #2a8ee0 0%, #1258a8 35%, #0d3570 65%, #0b2a5b 100%); }
.hero-track { display: flex; transition: transform .6s cubic-bezier(.65, 0, .35, 1); }
.slide { min-width: 100%; position: relative; height: clamp(205px, 52vw, 540px); display: flex; align-items: center; overflow: hidden; }
.slide-bg {
  position: absolute; top: 0; bottom: 0; left: 0; width: 70%;
  background-size: cover; background-position: left center;
}
.slide-bg.empty { width: 42%; }
.slide-panel { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 1; pointer-events: none; }
.about-leaf { position: absolute; top: 2px; right: 0; width: 7%; max-width: 44px; color: #7fb6ea; opacity: .55; transform: scaleX(-1); z-index: 1; pointer-events: none; }
.slide-bg.empty::after { content: ''; position: absolute; left: 50%; top: 46%; width: min(32vw, 320px); aspect-ratio: 1; transform: translate(-50%, -50%); background: var(--logo) center/cover; border-radius: 50%; box-shadow: 0 16px 50px rgba(0, 0, 0, .35); border: 5px solid rgba(255, 255, 255, .25); }
.slide-overlay { position: absolute; inset: 0; pointer-events: none; background: radial-gradient(ellipse at 90% 10%, rgba(58, 160, 234, .35), transparent 55%); }
.slide-content { position: relative; z-index: 2; color: #fff; padding: 0 4vw 9vw; width: 100%; max-width: 1200px; margin-inline: auto; }
.slide-content .inner { max-width: 62%; }
.slide-sub { font-size: clamp(14px, 4.4vw, 32px); font-weight: 600; opacity: .95; line-height: 1.4; }
.slide-title { font-size: clamp(15px, 4.7vw, 46px); font-weight: 800; line-height: 1.4; margin: 1vw 0 2.6vw; text-shadow: 0 2px 12px rgba(0, 0, 0, .25); }
.slide-badge { display: inline-block; background: var(--blue); padding: .35em 1.2em; border-radius: 999px; font-weight: 700; font-size: clamp(11px, 3.3vw, 18px); box-shadow: 0 6px 18px rgba(29, 132, 214, .45); }
.hero-wave { position: absolute; bottom: -1px; left: 0; right: 0; z-index: 3; line-height: 0; pointer-events: none; }
.hero-wave svg { width: 100%; height: clamp(26px, 9vw, 90px); }
.hero-dots { position: absolute; bottom: 2px; left: 50%; transform: translateX(-50%); display: flex; gap: 6px; z-index: 4; }
.hero-dots button { width: 8px; height: 8px; border-radius: 99px; background: #b9c9de; transition: .3s; }
.hero-dots button.active { width: 8px; background: var(--blue); }

/* ==================== شبكة الروابط السريعة ==================== */
.section { padding-block: 16px; }
.quick-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.quick-item {
  background: var(--card); border-radius: 14px; box-shadow: var(--shadow);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
  padding: 12px 4px 10px; text-align: center; border: 1px solid var(--line); transition: .25s;
  font-weight: 700; color: var(--navy); font-size: clamp(12px, 3.4vw, 16px); line-height: 1.4;
}
.quick-item .icon { width: clamp(30px, 9vw, 46px); height: clamp(30px, 9vw, 46px); color: var(--navy); stroke-width: 1.9; transition: .25s; }
.quick-item:nth-child(1) .icon, .quick-item:nth-child(2) .icon, .quick-item:nth-child(4) .icon { color: var(--navy-2); }
.quick-item:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: var(--blue-2); }
.quick-item:hover .icon { color: var(--blue); }

/* ==================== بطاقة عن المدرسة ==================== */
.about-card {
  background: var(--card); border-radius: 22px; box-shadow: var(--shadow); overflow: hidden;
  display: grid; grid-template-columns: 1.05fr 1fr; align-items: stretch; border: 1px solid var(--line);
  position: relative;
}
.about-card .about-body { padding: 14px 14px 14px 10px; display: flex; flex-direction: column; justify-content: center; position: relative; }
.about-card .about-body::before { content: ''; position: absolute; top: 6px; left: 4px; width: 34px; height: 34px; opacity: .25; background: radial-gradient(circle, var(--blue-2) 30%, transparent 32%) 0 0/10px 10px; }
.about-card .about-img { min-height: 150px; order: 2; padding: 8px; }
.about-img img, .about-img .ph { width: 100%; height: 100%; object-fit: cover; border-radius: 14px 0 0 14px; clip-path: ellipse(100% 125% at 0% 50%); }
.section-title { color: var(--navy); font-weight: 800; font-size: clamp(18px, 5.2vw, 28px); position: relative; display: inline-block; padding-bottom: 4px; margin-bottom: 6px; line-height: 1.5; }
.section-title::after { content: ''; position: absolute; bottom: 0; right: 0; width: 40px; height: 3px; border-radius: 4px; background: var(--blue); }
.about-body p { color: #3e4b62; font-size: clamp(12px, 3.3vw, 15px); line-height: 1.8; }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; background: var(--navy); color: #fff;
  border-radius: 999px; padding: 7px 18px; font-weight: 700; font-size: 13px; transition: .2s; align-self: flex-start; margin-top: 10px; white-space: nowrap;
}
.about-body .btn { font-size: clamp(11px, 3vw, 14px); padding: 6px 14px; }
.btn:hover { background: var(--blue); }
.btn-outline { background: transparent; color: var(--navy); border: 1.5px solid var(--navy); padding: 4px 16px; margin: 0; }
.btn-outline:hover { background: var(--navy); color: #fff; }
.btn .icon { width: 18px; height: 18px; }

/* ==================== الأخبار ==================== */
.section-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 10px; }
.section-head .section-title { margin: 0; }
.news-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.news-card { background: var(--card); border-radius: 12px; overflow: hidden; box-shadow: var(--shadow); border: 1px solid var(--line); transition: .25s; display: flex; flex-direction: column; min-width: 0; }
.news-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.news-card .thumb { aspect-ratio: 16/9; overflow: hidden; background: var(--sky); }
.news-row .news-card .thumb { aspect-ratio: 2.2/1; }
.news-card .thumb img, .news-card .thumb .ph { width: 100%; height: 100%; object-fit: cover; transition: transform .5s; }
.news-card:hover .thumb img { transform: scale(1.06); }
.news-card .nc-body { padding: 10px 12px 12px; display: flex; flex-direction: column; gap: 4px; flex: 1; }
.news-row .nc-body { padding: 6px 8px 8px; gap: 2px; }
.news-card h3 { font-size: 15px; font-weight: 700; color: var(--navy); line-height: 1.5; }
.news-row .news-card h3 { font-size: clamp(11px, 3vw, 17px); line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 2; line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.news-card p { font-size: 13px; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.meta { display: flex; align-items: center; gap: 6px; color: var(--muted); font-size: 13px; margin-top: auto; }
.news-row .meta { font-size: clamp(10px, 2.8vw, 14px); gap: 4px; }
.meta .icon { width: 16px; height: 16px; color: var(--navy); }
.news-row .meta .icon { width: 13px; height: 13px; }
.tag { display: inline-block; font-size: 11px; font-weight: 700; padding: 1px 10px; border-radius: 99px; background: var(--sky); color: var(--blue); align-self: flex-start; }
.tag.event { background: #fff2dd; color: #c27100; }
.news-grid { display: grid; grid-template-columns: 1fr; gap: 16px; }

/* ==================== شريط المميزات ==================== */
.features-bar { background: linear-gradient(135deg, var(--navy), var(--navy-2)); border-radius: 14px; display: grid; grid-template-columns: repeat(4, 1fr); padding: 10px 4px; color: #fff; box-shadow: var(--shadow-lg); }
.feature { display: flex; flex-direction: column; align-items: center; gap: 2px; text-align: center; font-weight: 700; font-size: clamp(10px, 2.9vw, 15px); padding: 4px 2px; white-space: nowrap; }
.feature + .feature { border-right: 1px solid rgba(255, 255, 255, .3); }
.feature .icon { width: clamp(22px, 7vw, 32px); height: clamp(22px, 7vw, 32px); stroke-width: 1.9; }

/* ==================== رأس الصفحات الداخلية ==================== */
.page-hero { background: linear-gradient(135deg, var(--navy), var(--blue)); color: #fff; padding: 34px 0 54px; position: relative; overflow: hidden; }
.page-hero::before { content: ''; position: absolute; width: 340px; height: 340px; border-radius: 50%; background: rgba(255, 255, 255, .06); left: -80px; top: -120px; }
.page-hero h1 { font-size: clamp(24px, 6vw, 38px); font-weight: 800; position: relative; }
.page-hero p { opacity: .9; position: relative; }
.crumbs { font-size: 13px; opacity: .85; margin-bottom: 4px; position: relative; }
.crumbs a:hover { text-decoration: underline; }
.page-body { margin-top: -30px; position: relative; z-index: 2; padding-bottom: 30px; }
.panel { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 22px 18px; border: 1px solid var(--line); }
.panel + .panel { margin-top: 16px; }
.prose p { margin-bottom: 12px; color: #33415c; font-size: 16px; }
.prose p:last-child { margin-bottom: 0; }

.vmv { display: grid; grid-template-columns: 1fr; gap: 14px; margin-top: 16px; }
.vmv .panel { margin: 0; text-align: center; }
.vmv .icon-circle { margin-inline: auto; }
.vmv h3 { color: var(--navy); margin: 8px 0 4px; }
.vmv p { color: var(--muted); }
.icon-circle { width: 64px; height: 64px; border-radius: 50%; display: grid; place-items: center; background: var(--sky); color: var(--blue); }
.icon-circle .icon { width: 30px; height: 30px; }

/* الكادر */
.staff-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; }
.staff-card { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); border: 1px solid var(--line); padding: 18px 12px; text-align: center; transition: .25s; }
.staff-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.staff-card .avatar { width: 96px; height: 96px; border-radius: 50%; margin: 0 auto 10px; overflow: hidden; border: 4px solid var(--sky); background: var(--sky); }
.staff-card .avatar img, .staff-card .avatar .ph { width: 100%; height: 100%; object-fit: cover; }
.staff-card h3 { font-size: 16px; color: var(--navy); }
.staff-card .role { color: var(--blue); font-weight: 700; font-size: 14px; }
.staff-card .subj { color: var(--muted); font-size: 13px; }
.staff-card .bio { color: var(--muted); font-size: 13px; margin-top: 6px; }

/* المنهج */
.curr-grid { display: grid; grid-template-columns: 1fr; gap: 14px; }
.curr-card { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); border: 1px solid var(--line); padding: 18px; display: flex; gap: 14px; align-items: flex-start; }
.curr-card .num { width: 50px; height: 50px; border-radius: 14px; background: linear-gradient(135deg, var(--navy), var(--blue)); color: #fff; display: grid; place-items: center; font-weight: 800; font-size: 20px; flex-shrink: 0; }
.curr-card h3 { color: var(--navy); font-size: 17px; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.chip { background: var(--sky); color: var(--navy); font-size: 13px; font-weight: 600; padding: 3px 12px; border-radius: 99px; }
.curr-card p { color: var(--muted); font-size: 14px; margin-top: 6px; }

/* المعرض */
.filters { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 14px; }
.filters button { padding: 6px 16px; border-radius: 99px; background: #fff; border: 1px solid var(--line); font-weight: 600; color: var(--navy); font-size: 14px; }
.filters button.active { background: var(--navy); color: #fff; border-color: var(--navy); }
.gallery-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.g-item { display: block; width: 100%; padding: 0; position: relative; border-radius: 14px; overflow: hidden; aspect-ratio: 1; background: var(--sky); box-shadow: var(--shadow); }
.g-item img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s; }
.g-item:hover img { transform: scale(1.08); }
.g-item span { position: absolute; inset: auto 0 0 0; padding: 20px 10px 8px; color: #fff; font-size: 13px; font-weight: 600; background: linear-gradient(transparent, rgba(0, 0, 0, .65)); }

/* الخبر المفرد */
.article-img { border-radius: 16px; overflow: hidden; margin-bottom: 18px; aspect-ratio: 16/8; background: var(--sky); }
.article-img img, .article-img .ph { width: 100%; height: 100%; object-fit: cover; }
.article h2 { color: var(--navy); font-size: clamp(20px, 5vw, 30px); line-height: 1.4; margin: 6px 0 8px; }

/* الإشعارات */
.notif { display: flex; gap: 14px; align-items: flex-start; }
.notif .icon-circle { width: 48px; height: 48px; flex-shrink: 0; }
.notif .icon-circle .icon { width: 24px; height: 24px; }
.notif h3 { color: var(--navy); font-size: 16px; }
.notif p { color: var(--muted); font-size: 14px; }
.notif.new .icon-circle { background: var(--blue); color: #fff; }

/* التواصل */
.contact-grid { display: grid; gap: 16px; grid-template-columns: 1fr; }
.info-list { display: flex; flex-direction: column; gap: 14px; }
.info-item { display: flex; gap: 12px; align-items: center; }
.info-item .icon-circle { width: 46px; height: 46px; flex-shrink: 0; }
.info-item .icon-circle .icon { width: 22px; height: 22px; }
.info-item small { color: var(--muted); display: block; font-size: 12px; }
.info-item b { color: var(--navy); font-weight: 700; word-break: break-word; }
.socials { display: flex; gap: 10px; margin-top: 6px; }
.socials a { width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; background: var(--navy); color: #fff; transition: .2s; }
.socials a:hover { background: var(--blue); }
.socials .icon { width: 20px; height: 20px; }
.form { display: flex; flex-direction: column; gap: 12px; }
.form label { font-weight: 700; color: var(--navy); font-size: 14px; display: block; margin-bottom: 4px; }
.form input, .form textarea { width: 100%; padding: 12px 14px; border: 1.5px solid var(--line); border-radius: 12px; background: #fbfdff; outline: none; transition: .2s; }
.form input:focus, .form textarea:focus { border-color: var(--blue); box-shadow: 0 0 0 4px rgba(29, 132, 214, .12); }
.form .btn { align-self: stretch; padding: 12px; font-size: 16px; margin-top: 4px; }
.alert { padding: 10px 14px; border-radius: 12px; font-weight: 600; font-size: 14px; }
.alert.ok { background: #e3f7ec; color: #11743f; }
.alert.err { background: #fde8e8; color: #b42318; }
.map { border-radius: 16px; overflow: hidden; margin-top: 16px; }
.map iframe { width: 100%; height: 320px; border: 0; display: block; }

.empty-state { text-align: center; color: var(--muted); padding: 40px 10px; }
.empty-state .icon { width: 54px; height: 54px; color: #b8c7dc; margin: 0 auto 8px; }

/* صورة بديلة */
.ph { display: grid; place-items: center; background: linear-gradient(135deg, #dbe9f8, #f1f6fc); color: #9db5d3; width: 100%; height: 100%; min-height: 80px; }
.ph .icon { width: 40%; max-width: 64px; height: auto; aspect-ratio: 1; stroke-width: 1.4; }

/* ==================== الفوتر ==================== */
.site-footer { background: var(--navy); color: #cfdcf0; margin-top: 18px; padding: 30px 0 18px; font-size: 14px; }
.footer-grid { display: grid; gap: 22px; grid-template-columns: 1fr; }
.footer-brand { display: flex; gap: 12px; align-items: center; }
.footer-brand img { width: 60px; height: 60px; border-radius: 50%; }
.footer-brand b { color: #fff; font-size: 16px; display: block; }
.site-footer h4 { color: #fff; margin-bottom: 8px; font-size: 16px; }
.footer-links { display: grid; grid-template-columns: 1fr 1fr; gap: 4px 12px; }
.footer-links a:hover, .site-footer .info a:hover { color: #fff; }
.site-footer .info div { display: flex; gap: 8px; align-items: center; margin-bottom: 6px; }
.site-footer .info .icon { width: 18px; height: 18px; color: var(--blue-2); }
.copy { border-top: 1px solid rgba(255, 255, 255, .12); margin-top: 22px; padding-top: 14px; text-align: center; font-size: 13px; opacity: .8; }
.copy a { opacity: .7; }

/* ==================== الشريط السفلي (هاتف) ==================== */
.bottom-nav {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 60;
  background: #fff; box-shadow: 0 -4px 20px rgba(11, 42, 91, .1);
  display: grid; grid-template-columns: repeat(5, 1fr);
  height: calc(var(--bottom-h) + env(safe-area-inset-bottom)); padding-bottom: env(safe-area-inset-bottom);
  border-radius: 20px 20px 0 0;
}
.bottom-nav a { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; font-size: 12px; font-weight: 600; color: var(--navy); position: relative; }
.bottom-nav a .icon { width: 26px; height: 26px; stroke-width: 1.9; }
.bottom-nav a.active { color: var(--blue); }
.bottom-nav a.active::after { content: ''; position: absolute; bottom: 4px; width: 60%; height: 3px; border-radius: 3px; background: var(--blue); }
.badge { position: absolute; top: -6px; left: -8px; background: #e53935; color: #fff; font-size: 11px; font-weight: 800; min-width: 18px; height: 18px; border-radius: 99px; display: grid; place-items: center; padding: 0 5px; border: 2px solid #fff; line-height: 1; }
.nav-ico { position: relative; display: inline-flex; }

/* ==================== Lightbox ==================== */
.lightbox { position: fixed; inset: 0; background: rgba(3, 12, 28, .92); z-index: 200; display: flex; align-items: center; justify-content: center; padding: 50px 10px; }
.lightbox[hidden] { display: none; }
.lightbox img { max-width: 100%; max-height: 100%; border-radius: 10px; object-fit: contain; }
.lightbox button { position: absolute; color: #fff; font-size: 40px; width: 52px; height: 52px; border-radius: 50%; background: rgba(255, 255, 255, .1); display: grid; place-items: center; line-height: 1; }
.lb-close { top: 12px; left: 12px; }
.lb-prev { right: 10px; top: 50%; transform: translateY(-50%); }
.lb-next { left: 10px; top: 50%; transform: translateY(-50%); }
.lb-caption { position: absolute; bottom: 14px; left: 0; right: 0; text-align: center; color: #fff; }

/* ==================== شاشات أكبر ==================== */
@media (min-width: 600px) {
  .staff-grid { grid-template-columns: repeat(3, 1fr); }
  .gallery-grid { grid-template-columns: repeat(3, 1fr); }
  .vmv { grid-template-columns: repeat(3, 1fr); }
  .curr-grid { grid-template-columns: repeat(2, 1fr); }
  .news-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1.4fr 1fr 1fr; }
}

@media (min-width: 992px) {
  :root { --header-h: 92px; }
  body { padding-bottom: 0; }
  .bottom-nav { display: none; }
  .menu-btn { display: none; }
  .brand { flex: 0 0 auto; }
  .brand-text { text-align: right; }
  .brand-slogan { justify-content: flex-start; }
  .brand-slogan::after { display: none; }
  .brand-slogan::before { display: none; }
  .top-nav { display: flex; flex: 1; justify-content: center; gap: 2px; }
  .top-nav a { padding: 8px 12px; border-radius: 10px; font-weight: 700; color: var(--navy); font-size: 15px; white-space: nowrap; transition: .2s; }
  .top-nav a:hover { background: var(--sky); }
  .top-nav a.active { background: var(--navy); color: #fff; }
  .bell-btn { display: grid; place-items: center; width: 46px; height: 46px; flex-shrink: 0; border-radius: 50%; background: var(--sky); color: var(--navy); }
  .bell-btn .icon { width: 24px; height: 24px; }
  .slide { height: clamp(360px, 36vw, 480px); }
  .bell-btn .badge { top: -10px; left: -12px; }

  .section { padding-block: 34px; }
  .quick-grid { grid-template-columns: repeat(6, 1fr); gap: 16px; margin-top: -10px; }
  .quick-item { padding: 26px 10px; }
  .about-card .about-body { padding: 36px 40px; }
  .about-body p { font-size: 17px; }
  .about-card .about-img { min-height: 340px; }
  .news-row { gap: 20px; }
  .news-row .nc-body { padding: 12px 14px 14px; }
  .news-card h3 { font-size: 17px; }
  .slide-content { padding-bottom: 70px; }
  .slide-content .inner { max-width: 52%; }
  .features-bar { padding: 26px 10px; }
  .feature { flex-direction: row; justify-content: center; gap: 12px; font-size: 17px; }
  .feature .icon { width: 38px; height: 38px; }
  .page-hero { padding: 50px 0 80px; }
  .panel { padding: 32px; }
  .staff-grid { grid-template-columns: repeat(4, 1fr); gap: 20px; }
  .gallery-grid { grid-template-columns: repeat(4, 1fr); gap: 14px; }
  .curr-grid { grid-template-columns: repeat(3, 1fr); }
  .news-grid { grid-template-columns: repeat(3, 1fr); gap: 20px; }
  .contact-grid { grid-template-columns: 1fr 1.3fr; }
  .article-wrap { max-width: 860px; margin-inline: auto; }
}

/* ===== الهاتف: مقاسات مأخوذة من التصميم بنسب عرض الشاشة (vw) لتطابقه على أي هاتف ===== */
@media (max-width: 991px) {
  body { padding-bottom: calc(14vw + env(safe-area-inset-bottom)); }
  .container { padding-inline: 2.6vw; }

  /* الهيدر */
  .header-inner { min-height: 17vw; gap: 2vw; padding-block: .6vw; }
  .brand { gap: 2.4vw; }
  .brand-logo { width: 16vw; height: 16vw; }
  .brand-sep { margin-block: 2vw; }
  .brand-name { font-size: 4.25vw; line-height: 1.3; }
  .brand-slogan { font-size: 2.75vw; gap: 1.5vw; margin-top: .6vw; }
  .brand-slogan::before, .brand-slogan::after { width: 3vw; height: 1.5px; }
  .menu-btn { width: 11vw; height: 11vw; }
  .menu-btn .icon { width: 8.5vw; height: 8.5vw; stroke-width: 2.6; }

  /* السلايدر */
  .slide { height: 49.5vw; }
  .slide-content { padding: 0 4.5vw 8vw; }
  .slide-content .inner { max-width: 64%; }
  .slide-sub { font-size: 4.9vw; font-weight: 400; }
  .slide-title { font-size: 5.2vw; margin: 1.2vw 0 2.6vw; line-height: 1.5; }
  .slide-badge { font-size: 2.85vw; padding: .9vw 4.2vw; }
  .hero-wave svg { height: 9vw; }
  .hero-dots { bottom: .6vw; gap: 1.2vw; }
  .hero-dots button { width: 1.9vw; height: 1.9vw; }
  .hero-dots button.active { width: 1.9vw; }

  /* الأقسام */
  .section { padding-block: 2.8vw; }
  .quick-grid { gap: 1.8vw; }
  .quick-item { border-radius: 3vw; padding: 2vw 1vw 1.6vw; gap: .6vw; font-size: 2.85vw; min-height: 15.4vw; }
  .quick-item .icon { width: 7.6vw; height: 7.6vw; }

  /* عن مدرستنا */
  .about-card { grid-template-columns: 1fr 1.05fr; border-radius: 3vw; }
  .about-card .about-body { padding: 3vw 3.4vw 3vw 1.5vw; }
  .about-card .about-body::before { display: none; }
  .about-body .section-title { margin-right: 6vw; }
  .about-leaf { width: 6vw; }
  .about-card .about-img { min-height: 33vw; padding: 1.6vw; }
  .about-card .about-body { padding-block: 2.4vw; }
  .about-img img, .about-img .ph { border-radius: 2.4vw 0 0 2.4vw; }
  .section-title { font-size: 4.4vw; padding-bottom: .8vw; margin-bottom: 1.6vw; }
  .section-title::after { width: 9vw; height: .7vw; }
  .about-body p { font-size: 2.7vw; line-height: 1.7; }
  .about-body .btn { font-size: 2.45vw; padding: 1vw 3.4vw; margin-top: 2vw; gap: 2vw; }
  .about-body .btn .icon { width: 3vw; height: 3vw; }

  /* الأخبار */
  .section-head { margin-bottom: 2.4vw; }
  .btn-outline { font-size: 2.7vw; padding: .8vw 3.6vw; gap: 2vw; }
  .btn-outline .icon { width: 3.4vw; height: 3.4vw; }
  .news-row { gap: 2.4vw; }
  .news-card { border-radius: 2.6vw; }
  .news-row .news-card .thumb { aspect-ratio: 2.35/1; }
  .news-row .nc-body { padding: 1.8vw 2vw 2vw; gap: .6vw; }
  .news-row .news-card h3 { font-size: 2.25vw; display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; letter-spacing: -.1px; }
  .about-leaf { width: 7vw; }
  .news-row .meta { font-size: 2.5vw; gap: 1vw; }
  .news-row .meta .icon { width: 3vw; height: 3vw; }

  /* شريط المميزات */
  .features-bar { border-radius: 2.8vw; padding: 1.6vw .5vw; }
  .feature { font-size: 2.6vw; gap: .2vw; padding: .4vw 1vw; line-height: 1.5; }
  .feature .icon { width: 5vw; height: 5vw; }

  /* الشريط السفلي */
  .bottom-nav { height: calc(13vw + env(safe-area-inset-bottom)); border-radius: 4.5vw 4.5vw 0 0; }
  .bottom-nav a { font-size: 2.75vw; gap: .8vw; }
  .bottom-nav a .icon { width: 5.4vw; height: 5.4vw; }
  .bottom-nav a.active::after { bottom: 0; width: 70%; height: .9vw; }
  .badge { font-size: 2.4vw; min-width: 3.8vw; height: 3.8vw; top: -1.4vw; left: -1.8vw; border-width: 1.5px; padding: 0 .8vw; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
