/* =====================================================================
   المعمل الافتراضي للعلوم — ورقة الأنماط الرئيسية
   هوية: طابع هيئة تعليمية سعودية × إخراج سينمائي
   ===================================================================== */

/* ---------- المتغيرات ---------- */
:root {
  --saudi: #006c35;
  --saudi-deep: #0b2b1e;
  --saudi-ink: #123a29;
  --saudi-soft: #e3f0e7;
  --gold: #c9a24b;
  --gold-deep: #a97f2e;
  --gold-soft: #ead9ac;
  --gold-faint: #f6eeda;

  --paper: #ffffff;
  --bg: #f6f8f4;
  --ink: #1c2f25;
  --muted: #5b6b62;
  --line: #e2e8e1;

  --phy: #2563a8;
  --chem: #c2671f;
  --bio: #2f8f5b;
  --earth: #5b6b62;

  --font-head: 'Tajawal', 'Segoe UI', system-ui, sans-serif;
  --font-body: 'IBM Plex Sans Arabic', 'Segoe UI', system-ui, sans-serif;
  --font-mono: 'IBM Plex Mono', 'Courier New', monospace;

  --radius: 16px;
  --radius-lg: 22px;
  --shadow-1: 0 1px 2px rgba(11, 43, 30, .06), 0 6px 18px rgba(11, 43, 30, .07);
  --shadow-2: 0 10px 34px rgba(11, 43, 30, .16);
  --ease: cubic-bezier(.22, .68, .28, 1);
  --maxw: 1220px;
  --header-h: 78px;
}

/* ---------- الأساس ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); }

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.85;
  color: var(--ink);
  background: var(--bg);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
ul { margin: 0; padding: 0; list-style: none; }
h1, h2, h3, h4, h5 { font-family: var(--font-head); font-weight: 800; line-height: 1.35; margin: 0; color: var(--ink); }
p { margin: 0; }

.container { width: min(var(--maxw), 100% - 48px); margin-inline: auto; }

.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

::selection { background: var(--gold-soft); color: var(--saudi-deep); }

/* ---------- أدوات عامة ---------- */
.mono { font-family: var(--font-mono); font-weight: 500; }

.kicker {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--font-mono); font-size: 12px; letter-spacing: .04em;
  color: var(--gold-deep); text-transform: uppercase;
}
.kicker::before { content: ''; width: 34px; height: 1px; background: var(--gold); }
.kicker.center::after { content: ''; width: 34px; height: 1px; background: var(--gold); }

.section-title { font-size: clamp(26px, 3.4vw, 38px); font-weight: 800; }
.section-sub { color: var(--muted); max-width: 620px; }

/* ختم / شعار مكاني */
.emblem {
  width: 46px; height: 46px; border-radius: 50%; flex: none;
  background: radial-gradient(circle at 32% 28%, var(--gold-soft), var(--gold) 58%, var(--gold-deep));
  display: grid; place-items: center;
  box-shadow: inset 0 0 0 2px rgba(255, 255, 255, .55), 0 3px 8px rgba(11, 43, 30, .25);
  color: #fff;
}
.emblem svg { width: 26px; height: 26px; }

/* ---------- الشريط العلوي ---------- */
.top-strip {
  background: var(--saudi-deep);
  color: rgba(255, 255, 255, .82);
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: .03em;
  padding: 7px 0;
}
.top-strip .container { display: flex; justify-content: space-between; gap: 16px; }
.top-strip .sep { opacity: .4; margin-inline: 8px; }

.site-header {
  position: sticky; top: 0; z-index: 60;
  background: rgba(255, 255, 255, .86);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
  transition: box-shadow .3s var(--ease), background .3s;
}
.site-header.scrolled { box-shadow: 0 10px 30px rgba(11, 43, 30, .12); }
.header-inner { display: flex; align-items: center; gap: 20px; height: var(--header-h); }
.brand { display: flex; align-items: center; gap: 12px; min-width: 0; }
.brand-txt { display: flex; flex-direction: column; line-height: 1.25; }
.brand-txt b { font-family: var(--font-head); font-weight: 900; font-size: 17px; color: var(--saudi-deep); white-space: nowrap; }
.brand-txt span { font-size: 11px; color: var(--muted); font-family: var(--font-mono); letter-spacing: .05em; white-space: nowrap; }

.main-nav { margin-inline-start: auto; display: flex; align-items: center; gap: 6px; }
.main-nav a {
  font-size: 14.5px; font-weight: 600; color: var(--ink);
  padding: 9px 14px; border-radius: 10px; transition: background .2s, color .2s;
}
.main-nav a:hover { background: var(--saudi-soft); color: var(--saudi-deep); }
.main-nav a.active { color: var(--saudi); }
.header-cta {
  font-family: var(--font-head); font-weight: 800; font-size: 14px;
  background: var(--saudi); color: #fff !important;
  padding: 10px 20px; border-radius: 12px;
  box-shadow: 0 4px 14px rgba(0, 108, 53, .32);
}
.header-cta:hover { background: #005a2c !important; }

.menu-toggle {
  display: none; margin-inline-start: auto;
  background: none; border: 1px solid var(--line); border-radius: 10px;
  width: 42px; height: 42px; font-size: 18px; color: var(--saudi-deep);
}

/* ---------- الهيرو (سینمایی) ---------- */
.hero { position: relative; color: #fff; overflow: hidden; background: var(--saudi-deep); }
.hero-bg { position: absolute; inset: -4%; z-index: 0; overflow: hidden; }
.hero-bg img { width: 100%; height: 100%; object-fit: cover; filter: saturate(.82) contrast(1.02); }
.hero-bg.kenburns img { animation: kenburns 26s var(--ease) forwards; }
@keyframes kenburns { from { transform: scale(1) translate(0, 0); } to { transform: scale(1.14) translate(1.5%, -1.5%); } }
.hero-shade {
  position: absolute; inset: 0; z-index: 1;
  background:
    radial-gradient(120% 90% at 85% 20%, rgba(0, 0, 0, .18), transparent 55%),
    radial-gradient(140% 120% at 12% 100%, rgba(11, 43, 30, .9), transparent 60%),
    linear-gradient(105deg, rgba(11, 43, 30, .88) 30%, rgba(11, 43, 30, .35) 68%, rgba(11, 43, 30, .62));
}
.hero::after { /* vignette */
  content: ''; position: absolute; inset: 0; z-index: 2; pointer-events: none;
  background: radial-gradient(115% 95% at 50% 40%, transparent 58%, rgba(6, 22, 15, .55));
}
.hero-inner { position: relative; z-index: 3; padding: clamp(84px, 11vh, 128px) 0 clamp(66px, 9vh, 100px); }
.hero-badge {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--font-mono); font-size: 12px; letter-spacing: .05em;
  color: var(--gold-soft);
  border: 1px solid rgba(201, 162, 75, .55);
  background: rgba(11, 43, 30, .35);
  padding: 8px 16px; border-radius: 999px;
  margin-bottom: 26px; backdrop-filter: blur(6px);
}
.hero-badge .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 0 4px rgba(201, 162, 75, .2); }
.hero h1 {
  font-size: clamp(32px, 5.4vw, 60px); font-weight: 900;
  color: #fff; max-width: 760px; letter-spacing: -.01em;
}
.hero h1 em { font-style: normal; color: var(--gold-soft); }
.hero-lead { margin-top: 20px; font-size: clamp(15px, 1.6vw, 18px); color: rgba(255, 255, 255, .86); max-width: 640px; }
.hero-actions { margin-top: 34px; display: flex; flex-wrap: wrap; gap: 14px; align-items: center; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  font-family: var(--font-head); font-weight: 800; font-size: 15.5px;
  padding: 14px 28px; border-radius: 13px; border: 1.5px solid transparent;
  transition: transform .2s var(--ease), box-shadow .25s, background .2s, border-color .2s;
}
.btn:active { transform: scale(.98); }

.btn-gold {
  background: linear-gradient(180deg, #d9b45f, #c9a24b 55%, #b8903c);
  color: var(--saudi-deep);
  box-shadow: 0 8px 22px rgba(201, 162, 75, .4), inset 0 1px 0 rgba(255, 255, 255, .5);
}
.btn-gold:hover { transform: translateY(-2px); box-shadow: 0 12px 30px rgba(201, 162, 75, .5); }

.btn-ghost {
  background: rgba(255, 255, 255, .08); border-color: rgba(255, 255, 255, .35);
  color: #fff; backdrop-filter: blur(6px);
}
.btn-ghost:hover { background: rgba(255, 255, 255, .16); border-color: rgba(255, 255, 255, .6); }

.btn-green { background: var(--saudi); color: #fff; box-shadow: 0 8px 22px rgba(0, 108, 53, .35); }
.btn-green:hover { background: #005a2c; transform: translateY(-2px); }

.hero-trust {
  margin-top: 52px; display: flex; flex-wrap: wrap; gap: 0;
  border: 1px solid rgba(255, 255, 255, .16);
  border-radius: 18px; background: rgba(255, 255, 255, .05); backdrop-filter: blur(8px);
  overflow: hidden; width: fit-content; max-width: 100%;
}
.trust-item { display: flex; align-items: center; gap: 12px; padding: 16px 26px; }
.trust-item + .trust-item { border-inline-start: 1px solid rgba(255, 255, 255, .14); }
.trust-num { font-family: var(--font-mono); font-size: 22px; font-weight: 600; color: var(--gold-soft); }
.trust-txt { font-size: 12.5px; color: rgba(255, 255, 255, .78); line-height: 1.5; }

/* ---------- قسم الرأس الموحد ---------- */
.section { padding: clamp(56px, 8vw, 96px) 0; }
.section-head { margin-bottom: 40px; }
.section-head.row { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; flex-wrap: wrap; }

/* ---------- بطاقات المراحل ---------- */
.stages-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.stage-card {
  position: relative; border-radius: var(--radius-lg); overflow: hidden;
  min-height: 380px; display: flex; flex-direction: column; justify-content: flex-end;
  color: #fff; box-shadow: var(--shadow-1);
  transition: transform .35s var(--ease), box-shadow .35s;
  isolation: isolate;
}
.stage-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-2); }
.stage-card img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; transition: transform .8s var(--ease); }
.stage-card:hover img { transform: scale(1.07); }
.stage-card::after {
  content: ''; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(200deg, rgba(11, 43, 30, .1) 10%, rgba(11, 43, 30, .55) 48%, rgba(6, 22, 15, .92) 92%);
}
.stage-card .body { padding: 26px; }
.stage-tag { font-family: var(--font-mono); font-size: 12px; color: var(--gold-soft); letter-spacing: .05em; }
.stage-card h3 { color: #fff; font-size: 24px; font-weight: 900; margin: 8px 0 6px; }
.stage-card .range { font-size: 13px; color: rgba(255, 255, 255, .75); }
.stage-card p { font-size: 13.5px; color: rgba(255, 255, 255, .7); margin-top: 10px; }
.stage-link {
  margin-top: 16px; display: inline-flex; align-items: center; gap: 8px;
  font-size: 13.5px; font-weight: 700; color: var(--gold-soft);
}
.stage-link .arr { transition: transform .3s var(--ease); }
.stage-card:hover .stage-link .arr { transform: translateX(-5px); }

/* ---------- شريط التصفية ---------- */
.filters-panel {
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-lg);
  box-shadow: var(--shadow-1); padding: 22px; margin-bottom: 30px;
}
.filter-chips { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 16px; }
.chip {
  font-family: var(--font-head); font-weight: 700; font-size: 13.5px;
  color: var(--muted); background: var(--bg); border: 1px solid var(--line);
  padding: 9px 18px; border-radius: 999px; transition: all .2s var(--ease);
}
.chip:hover { border-color: var(--saudi); color: var(--saudi); }
.chip.on { background: var(--saudi-deep); color: var(--gold-soft); border-color: var(--saudi-deep); }

.filter-row { display: grid; grid-template-columns: repeat(3, 1fr) auto; gap: 14px; align-items: end; }
.field { display: flex; flex-direction: column; gap: 7px; }
.field label { font-size: 12.5px; font-weight: 700; color: var(--muted); font-family: var(--font-mono); letter-spacing: .03em; }
.field select, .field input {
  appearance: none; width: 100%;
  font-family: var(--font-body); font-size: 14.5px; font-weight: 600; color: var(--ink);
  background: var(--bg) url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'><path d='M1 1l5 5 5-5' stroke='%230b2b1e' stroke-width='1.8' fill='none' stroke-linecap='round'/></svg>") no-repeat left 16px center;
  border: 1.5px solid var(--line); border-radius: 12px;
  padding: 12px 16px; transition: border-color .2s;
}
.field select { padding-inline-end: 44px; cursor: pointer; }
.field input { background-image: none; }
.field select:focus, .field input:focus { outline: none; border-color: var(--saudi); box-shadow: 0 0 0 3px rgba(0, 108, 53, .12); }

.filter-reset {
  font-size: 13px; font-weight: 700; color: var(--gold-deep);
  background: var(--gold-faint); border: 1px solid var(--gold-soft);
  padding: 12px 18px; border-radius: 12px; white-space: nowrap;
}
.filter-reset:hover { background: var(--gold-soft); }

.result-line {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  margin: 4px 2px 18px; color: var(--muted); font-size: 13.5px;
}
.result-line .count { font-family: var(--font-mono); color: var(--saudi); font-weight: 600; }

/* ---------- بطاقات التجارب ---------- */
.grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.exp-card {
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-lg);
  overflow: hidden; display: flex; flex-direction: column;
  box-shadow: var(--shadow-1); position: relative;
  transition: transform .3s var(--ease), box-shadow .3s, border-color .3s;
}
.exp-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-2); border-color: rgba(201, 162, 75, .6); }

.exp-media { position: relative; aspect-ratio: 16 / 9.4; overflow: hidden; background: var(--saudi-deep); }
.exp-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease); }
.exp-card:hover .exp-media img { transform: scale(1.08); }
.exp-media::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(11, 43, 30, .05) 30%, rgba(11, 43, 30, .75) 100%);
}
.exp-badge {
  position: absolute; top: 14px; inset-inline-end: 14px; z-index: 2;
  font-family: var(--font-mono); font-size: 11px; letter-spacing: .04em;
  padding: 6px 12px; border-radius: 999px; display: inline-flex; align-items: center; gap: 6px;
  backdrop-filter: blur(6px);
}
.exp-badge::before { content: ''; width: 6px; height: 6px; border-radius: 50%; }
.exp-badge.pending { background: rgba(11, 43, 30, .72); color: var(--gold-soft); border: 1px solid rgba(201, 162, 75, .5); }
.exp-badge.pending::before { background: var(--gold); }
.exp-badge.ready { background: rgba(0, 108, 53, .85); color: #fff; border: 1px solid rgba(255, 255, 255, .35); }
.exp-badge.ready::before { background: #b8e6c9; box-shadow: 0 0 0 3px rgba(184, 230, 201, .25); }

.exp-grade {
  position: absolute; bottom: 14px; inset-inline-start: 16px; z-index: 2;
  color: #fff; font-size: 12.5px; font-weight: 700; font-family: var(--font-head);
  background: rgba(11, 43, 30, .5); padding: 5px 12px; border-radius: 8px; backdrop-filter: blur(4px);
}

.exp-body { padding: 20px 22px 22px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.exp-meta { font-family: var(--font-mono); font-size: 11px; color: var(--gold-deep); letter-spacing: .02em; }
.exp-title { font-size: 19px; font-weight: 800; line-height: 1.45; }
.exp-unit { font-size: 13px; color: var(--muted); }
.exp-foot { margin-top: auto; padding-top: 14px; border-top: 1px dashed var(--line); display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.exp-code { font-family: var(--font-mono); font-size: 11px; color: var(--muted); letter-spacing: .05em; }
.exp-link { font-size: 13.5px; font-weight: 800; color: var(--saudi); display: inline-flex; align-items: center; gap: 7px; }
.exp-link .arr { transition: transform .3s var(--ease); }
.exp-card:hover .exp-link .arr { transform: translateX(-5px); }

/* حالة عدم وجود نتائج */
.empty {
  grid-column: 1 / -1; text-align: center; padding: 70px 20px; color: var(--muted);
  border: 1.5px dashed var(--line); border-radius: var(--radius-lg); background: var(--paper);
}
.empty b { display: block; font-size: 18px; color: var(--ink); margin-bottom: 6px; font-family: var(--font-head); }

/* ---------- كيف يعمل ---------- */
.how-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; counter-reset: step; }
.step {
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-lg);
  padding: 30px 28px; position: relative; box-shadow: var(--shadow-1);
  transition: transform .3s var(--ease), box-shadow .3s;
}
.step:hover { transform: translateY(-5px); box-shadow: var(--shadow-2); }
.step-num {
  font-family: var(--font-mono); font-size: 30px; font-weight: 600; color: var(--gold);
  line-height: 1;
}
.step::after {
  content: ''; position: absolute; top: 30px; inset-inline-start: 28px;
  width: 46px; height: 3px; border-radius: 3px;
  background: linear-gradient(90deg, var(--gold), var(--saudi));
  opacity: .85;
}
.step h3 { font-size: 18.5px; margin: 22px 0 8px; }
.step p { font-size: 14px; color: var(--muted); }

/* ---------- السلامة المخبرية ---------- */
.safety {
  background: var(--saudi-deep); color: #fff; border-radius: var(--radius-lg);
  padding: clamp(28px, 4vw, 46px); position: relative; overflow: hidden;
}
.safety::after {
  content: ''; position: absolute; inset-inline-end: -80px; top: -80px; width: 320px; height: 320px;
  background: radial-gradient(circle, rgba(201, 162, 75, .22), transparent 65%); pointer-events: none;
}
.safety-grid { display: grid; grid-template-columns: 1.1fr 1.4fr; gap: 30px; position: relative; z-index: 1; }
.safety h3 { color: var(--gold-soft); font-size: 24px; margin-bottom: 10px; }
.safety p { color: rgba(255, 255, 255, .78); font-size: 14px; }
.safety-rules { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.safety-rules li {
  display: flex; align-items: flex-start; gap: 10px; font-size: 13.5px;
  background: rgba(255, 255, 255, .06); border: 1px solid rgba(255, 255, 255, .1);
  padding: 12px 14px; border-radius: 12px; color: rgba(255, 255, 255, .88);
}
.safety-rules li::before { content: '✓'; color: var(--gold-soft); font-weight: 700; flex: none; }

/* ---------- بانر الدعوة ---------- */
.cta-banner { position: relative; border-radius: var(--radius-lg); overflow: hidden; color: #fff; }
.cta-banner img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: 0; }
.cta-banner::after { content: ''; position: absolute; inset: 0; background: linear-gradient(100deg, rgba(6, 22, 15, .94), rgba(11, 43, 30, .55)); z-index: 1; }
.cta-inner { position: relative; z-index: 2; padding: clamp(44px, 6vw, 72px); display: flex; align-items: center; justify-content: space-between; gap: 30px; flex-wrap: wrap; }
.cta-inner h3 { color: #fff; font-size: clamp(22px, 3vw, 32px); font-weight: 900; max-width: 520px; }
.cta-inner p { color: rgba(255, 255, 255, .8); margin-top: 10px; font-size: 14.5px; max-width: 480px; }

/* ---------- الفوتر ---------- */
.site-footer { background: var(--saudi-deep); color: rgba(255, 255, 255, .8); margin-top: clamp(40px, 6vw, 80px); }
.footer-top { padding: 60px 0 40px; display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 40px; }
.footer-brand .emblem { margin-bottom: 16px; }
.footer-brand b { font-family: var(--font-head); font-size: 19px; color: #fff; }
.footer-brand p { font-size: 13.5px; color: rgba(255, 255, 255, .6); margin-top: 10px; max-width: 320px; }
.footer-col h4 { color: var(--gold-soft); font-size: 14px; letter-spacing: .03em; margin-bottom: 16px; }
.footer-col li { margin-bottom: 10px; }
.footer-col a { font-size: 13.5px; color: rgba(255, 255, 255, .72); transition: color .2s; }
.footer-col a:hover { color: var(--gold-soft); }
.footer-contact li { font-size: 13.5px; color: rgba(255, 255, 255, .65); display: flex; align-items: center; gap: 10px; }
.footer-contact .mono { font-size: 12px; }

.compliance {
  border: 1px solid rgba(201, 162, 75, .35); background: rgba(201, 162, 75, .08);
  border-radius: 14px; padding: 18px 22px; margin-bottom: 34px;
  display: flex; align-items: center; gap: 16px;
}
.compliance .seal { flex: none; width: 40px; height: 40px; }
.compliance p { font-size: 13px; color: rgba(255, 255, 255, .82); line-height: 1.8; }
.compliance b { color: var(--gold-soft); }

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, .12); padding: 20px 0;
  display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap;
  font-size: 12.5px; color: rgba(255, 255, 255, .55);
}

/* =====================================================================
   صفحة التجربة
   ===================================================================== */
.breadcrumb {
  font-family: var(--font-mono); font-size: 12px; color: var(--muted);
  display: flex; align-items: center; flex-wrap: wrap; gap: 8px; padding: 20px 0 0;
}
.breadcrumb a { color: var(--saudi); font-weight: 600; }
.breadcrumb a:hover { text-decoration: underline; }
.breadcrumb .sep { color: var(--gold); }

.exp-hero {
  position: relative; color: #fff; overflow: hidden; border-radius: var(--radius-lg);
  min-height: clamp(260px, 34vh, 380px); display: flex; align-items: flex-end;
  margin-top: 18px; isolation: isolate;
}
.exp-hero img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; }
.exp-hero.kenburns img { animation: kenburns 22s var(--ease) forwards; }
.exp-hero::after {
  content: ''; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(200deg, rgba(11, 43, 30, .35) 20%, rgba(6, 22, 15, .85) 90%);
}
.exp-hero::before {
  content: ''; position: absolute; inset: 0; z-index: -1;
  background: radial-gradient(120% 100% at 80% 10%, transparent 50%, rgba(6, 22, 15, .6));
}
.exp-hero .inner { padding: clamp(30px, 5vw, 54px); width: 100%; }
.tagline {
  display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 18px;
}
.tagline span {
  font-family: var(--font-mono); font-size: 11.5px; letter-spacing: .04em;
  background: rgba(255, 255, 255, .12); border: 1px solid rgba(255, 255, 255, .28);
  padding: 6px 13px; border-radius: 999px; backdrop-filter: blur(5px);
  color: rgba(255, 255, 255, .95);
}
.tagline span.gold { background: rgba(201, 162, 75, .22); border-color: rgba(201, 162, 75, .6); color: var(--gold-soft); }
.exp-hero h1 { color: #fff; font-size: clamp(26px, 4vw, 42px); font-weight: 900; max-width: 820px; }
.exp-hero .lesson-line { margin-top: 10px; font-size: 14.5px; color: rgba(255, 255, 255, .8); }
.exp-hero .lesson-line b { color: var(--gold-soft); font-weight: 700; }

/* تخطيط الصفحة */
.exp-layout { display: grid; grid-template-columns: 1.55fr 1fr; gap: 28px; margin-top: 30px; align-items: start; }
.panel {
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-lg);
  padding: clamp(20px, 3vw, 30px); box-shadow: var(--shadow-1);
}
.panel-title {
  font-size: 17px; font-weight: 800; margin-bottom: 6px;
  display: flex; align-items: center; gap: 10px;
}
.panel-title .ix {
  font-family: var(--font-mono); font-size: 12px; color: var(--gold-deep);
  background: var(--gold-faint); border: 1px solid var(--gold-soft);
  padding: 3px 10px; border-radius: 7px;
}
.panel-sub { font-size: 13px; color: var(--muted); margin-bottom: 20px; }

/* حاوية المعاينة / التشغيل */
.player {
  border: 1.5px dashed rgba(201, 162, 75, .7);
  border-radius: var(--radius-lg);
  background:
    radial-gradient(90% 120% at 85% 0%, rgba(201, 162, 75, .14), transparent 55%),
    radial-gradient(110% 130% at 10% 100%, rgba(0, 108, 53, .22), transparent 60%),
    linear-gradient(160deg, #0e3a28, #0b2b1e 60%);
  min-height: 480px;
  padding: 18px;
  position: relative;
}
.player::before {
  content: ''; position: absolute; inset: 0; pointer-events: none; border-radius: inherit;
  background: repeating-linear-gradient(45deg, transparent 0 14px, rgba(255, 255, 255, .018) 14px 28px);
}
.player::after { /* vignette خفيفة */
  content: ''; position: absolute; inset: 0; pointer-events: none; border-radius: inherit;
  background: radial-gradient(120% 100% at 50% 40%, transparent 60%, rgba(6, 22, 15, .3));
}
.sim-root { position: relative; z-index: 1; width: 100%; }

/* ---------- الإطار العام للمحاكاة ---------- */
.sim-wrap { display: flex; flex-direction: column; gap: 14px; }
.sim-stage {
  position: relative; border-radius: 14px; overflow: hidden;
  background: rgba(255, 255, 255, .04);
  border: 1px solid rgba(255, 255, 255, .09);
  min-height: 300px; display: flex; flex-direction: column; align-items: center;
  justify-content: center; padding: 14px; text-align: center;
}
.sim-stage svg { max-width: 100%; }
.sim-ctl {
  display: flex; flex-wrap: wrap; gap: 10px; align-items: center;
  justify-content: center;
}
.sim-ctl-row { display: flex; align-items: center; gap: 10px; width: 100%; }
.sim-ctl-row.full { margin: 2px 0; }
.sim-ctl-row input[type=range] { flex: 1; min-width: 80px; }
.sim-lab { font-size: 12.5px; color: rgba(255, 255, 255, .78); white-space: nowrap; }
.sim-val { font-size: 12px; color: var(--gold-soft); min-width: 64px; text-align: end; }

.btn-sim {
  font-family: var(--font-head); font-weight: 700; font-size: 13px;
  color: #eaf3ec; background: rgba(255, 255, 255, .09);
  border: 1px solid rgba(255, 255, 255, .22); border-radius: 10px;
  padding: 9px 16px; transition: background .2s, transform .15s, box-shadow .2s;
}
.btn-sim:hover { background: rgba(255, 255, 255, .18); }
.btn-sim:active { transform: scale(.97); }
.btn-sim:disabled { opacity: .45; cursor: not-allowed; }
.btn-sim.gold {
  background: linear-gradient(180deg, #d9b45f, #c9a24b 55%, #b8903c);
  color: var(--saudi-deep); border-color: transparent;
  box-shadow: 0 4px 14px rgba(201, 162, 75, .35);
}
.btn-sim.gold:hover { filter: brightness(1.05); }
.btn-sim.on { background: var(--saudi); border-color: rgba(184, 230, 201, .5); color: #fff; }

.readout {
  font-family: var(--font-mono); font-size: 12.5px; line-height: 1.9;
  color: rgba(255, 255, 255, .82); margin-top: 10px; max-width: 560px;
}

/* عناصر مشتركة في المشاهد */
.orbit-l { fill: none; stroke: rgba(255, 255, 255, .18); stroke-width: 1; }
.sun-core { fill: #f0c95c; }
.battery { fill: #1f4d37; stroke: rgba(255, 255, 255, .35); stroke-width: 1.5; }
.wire { fill: none; stroke: rgba(255, 255, 255, .55); stroke-width: 3; }
.tlabel, .m-tag, .q-tag, .r-tag, .a-tag, .sun-t, .nuc-t, .p-name, .cl-t, .h-tag, .pend-read { font-family: var(--font-mono); font-size: 12px; fill: rgba(255, 255, 255, .85); }

/* ================= 1) إنبات البذرة ================= */
.grow-plot { background: linear-gradient(180deg, #123a29, #0b2b1e); }
.grow-plot svg { max-height: 190px; }
.grow-stage { font-size: 13px; color: var(--gold-soft); margin-top: 6px; }
.grow-note { font-size: 12.5px; color: rgba(255, 255, 255, .7); margin-top: 6px; }

/* ================= 2) الذوبان ================= */
.dissolve-beaker { position: relative; width: 100%; max-width: 320px; height: 260px; }
.dissolve-beaker .water {
  position: absolute; left: 14%; right: 14%; bottom: 8%; top: 18%;
  background: linear-gradient(180deg, #bcd8ee, #cfe6f5);
  border-radius: 8px 8px 4px 4px; opacity: 1; transition: opacity .6s;
}
.dissolve-beaker .water.dissolved { background: linear-gradient(180deg, #d7eaf7, #eef6fc); }
.dissolve-beaker .beaker-glass {
  position: absolute; inset: 6% 10% 4%; border: 3px solid rgba(255, 255, 255, .35);
  border-top-width: 2px; border-radius: 0 0 12px 12px;
}
.dissolve-beaker .spoon { position: absolute; right: 12%; top: 20%; width: 6px; height: 40px; background: #d9c9a5; border-radius: 3px; transform-origin: top center; transition: transform .2s; }
.dissolve-beaker .spoon.stirring { animation: stir .5s ease-in-out infinite; }
@keyframes stir { 0%,100% { transform: rotate(-25deg); } 50% { transform: rotate(25deg); } }

/* ================= 3) النبض ================= */
.pulse-stage { min-height: 260px; }
.heart {
  width: 54px; height: 54px; position: relative; margin: 10px auto;
}
.heart::before, .heart::after {
  content: ''; position: absolute; width: 30px; height: 46px; background: var(--chem);
  border-radius: 30px 30px 0 0; top: 0;
}
.heart::before { left: 12px; transform: rotate(-45deg); transform-origin: 100% 100%; }
.heart::after { right: 12px; transform: rotate(45deg); transform-origin: 0 100%; }
.heart.beat { animation: hb .5s ease-in-out; }
@keyframes hb { 0%,100% { transform: scale(1); } 30% { transform: scale(1.28); } 60% { transform: scale(.95); } }
.pulse-bpm { font-size: 18px; color: var(--gold-soft); }
.pulse-hint { font-size: 13px; color: rgba(255, 255, 255, .7); max-width: 400px; margin-top: 8px; }

/* ================= 4) الدائرة ================= */
.circuit-stage svg { max-height: 240px; }
.circuit-svg .switch rect { transition: fill .3s; }
.circuit-svg .switch.closed rect { fill: #1f4d37; }
.sw-body { fill: #2a3a30; stroke: rgba(255, 255, 255, .4); stroke-width: 1.5; }
.sw-txt { font-size: 11px; fill: rgba(255, 255, 255, .8); font-family: var(--font-body); }
.sw-wire { stroke: #c9a24b; stroke-width: 5; stroke-linecap: round; }
.bulb { fill: #e8eef0; stroke: #8a969c; stroke-width: 2; transition: fill .2s; }
.bulb.on { fill: #ffe08a; stroke: #f2c94c; filter: drop-shadow(0 0 14px #ffd75e); }
.filament { fill: #9a7b2f; }
.bulb-rays { opacity: 0; transition: opacity .3s; }
.bulb-rays.show { opacity: 1; }
.bulb-rays line { stroke: #ffd75e; stroke-width: 3; stroke-linecap: round; }

/* ================= 5) الظل ================= */
.shadow-stage { padding: 0; }
.shadow-stage .sky { position: relative; width: 100%; max-width: 460px; height: 280px; overflow: hidden; }
.shadow-stage .sun { position: absolute; width: 44px; height: 44px; border-radius: 50%; background: radial-gradient(circle at 35% 35%, #ffe9a8, #f2c94c); box-shadow: 0 0 34px rgba(242, 201, 76, .7); transition: left .3s, top .3s; }
.shadow-stage .ground { position: absolute; bottom: 0; left: 0; right: 0; height: 34%; background: linear-gradient(180deg, #2c5a3c, #1f452f); }
.shadow-stage .stick { position: absolute; bottom: 34%; left: 50%; width: 6px; height: 70px; background: #c98d4b; transform: translateX(-50%); }
.shadow-ellipse { position: absolute; bottom: 34%; height: 14px; background: rgba(0, 0, 0, .4); border-radius: 50%; transform-origin: center; transition: width .3s, left .3s; }
.sh-label { position: absolute; bottom: 12px; right: 0; left: 0; text-align: center; font-size: 12px; color: rgba(255, 255, 255, .85); }

/* ================= 6) المجهر ================= */
.micro-stage { flex-direction: row; gap: 14px; flex-wrap: wrap; }
.micro-stage .eyepiece { width: 70px; display: grid; place-items: center; }
.micro-stage .lens-dot { width: 44px; height: 44px; border-radius: 50%; border: 6px solid rgba(255, 255, 255, .3); border-top-color: var(--gold); animation: spin 6s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.micro-stage .field { position: relative; width: min(300px, 100%); aspect-ratio: 1; border-radius: 50%; overflow: hidden; background: radial-gradient(circle, #dff1e6, #bcd8c9 60%, #9fc2ac); transition: filter .15s; }
.micro-stage .field svg { width: 100%; height: 100%; transition: transform .4s; }
.cell-wall { fill: rgba(22, 74, 48, .25); stroke: #1f5a3c; stroke-width: 4; }
.cell-membrane { fill: rgba(120, 200, 150, .35); stroke: #2f8f5b; stroke-width: 2; }
.nucleus { fill: rgba(60, 110, 160, .5); stroke: #3a6fa5; stroke-width: 2.5; }
.nucleolus { fill: rgba(30, 60, 90, .6); }
.micro-stage .label { position: absolute; font-size: 11px; color: #123a29; font-weight: 700; background: rgba(255, 255, 255, .8); padding: 2px 8px; border-radius: 6px; }
.micro-stage .label.l1 { top: 10%; right: 12%; }
.micro-stage .label.l2 { top: 70%; right: 14%; }
.micro-stage .label.l3 { top: 44%; left: 8%; }
.micro-stage .field.no-labels .label { display: none; }

/* ================= 7) التفاعل ================= */
.react-stage { min-height: 300px; }
.react-stage .flask { position: relative; width: 150px; height: 180px; }
.flask-liquid {
  position: absolute; left: 0; right: 0; bottom: 0; height: 62%;
  background: linear-gradient(180deg, #e8d9ac, #d9b45f);
  border-radius: 0 0 40px 40px; clip-path: polygon(24% 0, 76% 0, 76% 100%, 24% 100%);
}
.react-stage .bubbles { position: absolute; inset: 0; }
.react-stage .bubbles .b { position: absolute; bottom: 20%; width: 8px; height: 8px; border-radius: 50%; background: rgba(255, 255, 255, .75); animation: rise 1.6s linear forwards; }
@keyframes rise { to { transform: translateY(-120px); opacity: 0; } }
.react-stage .balloon { position: absolute; top: 0; left: 50%; transform: translateX(-50%); }
.balloon-ball { width: 120px; height: 140px; border-radius: 50% 50% 48% 52%; background: radial-gradient(circle at 35% 30%, #f5b8b8, #e0655f 70%); transform: scale(0.2); transform-origin: bottom center; transition: transform .3s; }
.balloon-neck { width: 26px; height: 40px; margin: -14px auto 0; background: #e0655f; border-radius: 0 0 8px 8px; }

/* ================= 8) ماء الجير ================= */
.lime-stage { min-height: 280px; position: relative; }
.lime-stage .glass { width: 130px; height: 150px; border: 3px solid rgba(255, 255, 255, .35); border-radius: 4px 4px 14px 14px; position: relative; overflow: hidden; }
.lime-stage .lime { position: absolute; left: 0; right: 0; bottom: 0; height: 70%; background: rgba(228, 235, 240, 1); transition: background .4s; }
.lime-stage .straw { position: absolute; bottom: 42%; width: 10px; height: 110px; background: #d9b45f; border-radius: 4px; transform: rotate(8deg); }
.blow-bubbles .b { position: absolute; bottom: 30%; width: 6px; height: 6px; border-radius: 50%; background: rgba(255, 255, 255, .8); animation: rise 1.2s linear forwards; }

/* ================= 9) الحمل الحراري ================= */
.conv-stage { min-height: 320px; }
.conv-stage .beaker-c { position: relative; width: 200px; height: 220px; }
.water-c { position: absolute; left: 10%; right: 10%; bottom: 12%; top: 6%; background: linear-gradient(180deg, #cfe6f5, #bcd8ee); border-radius: 4px; overflow: hidden; border: 2px solid rgba(255, 255, 255, .3); }
.water-c .dye { position: absolute; width: 6px; height: 6px; border-radius: 50%; background: #5a2e9e; opacity: .85; transition: bottom .5s linear, left .5s; }
.conv-stage .burner { position: absolute; bottom: 0; left: 40%; width: 40px; height: 22px; background: #2a3a30; border-radius: 6px 6px 0 0; }
.conv-stage .burner.lit { background: #7a4a22; box-shadow: 0 0 18px rgba(242, 150, 60, .8); }

/* ================= 10) المخبار ================= */
.cyl-stage { min-height: 320px; }
.cyl-stage .cylinder { position: relative; width: 130px; height: 260px; border: 3px solid rgba(255, 255, 255, .4); border-radius: 6px 6px 12px 12px; background: rgba(255, 255, 255, .05); }
.cyl-water { position: absolute; left: 6%; right: 6%; bottom: 4%; width: 88%; height: 0%; background: linear-gradient(180deg, #9fd0f0, #6fb1e0); border-radius: 2px; transition: height .3s; }
.meniscus { position: absolute; left: 6%; width: 88%; height: 6px; border-top: 3px solid rgba(0, 40, 70, .6); border-radius: 50%; transition: bottom .3s; }
.cyl-scale { position: absolute; right: -34px; top: 6px; display: flex; flex-direction: column-reverse; gap: 18px; }
.cyl-scale i { font-style: normal; font-family: var(--font-mono); font-size: 10px; color: rgba(255, 255, 255, .7); }

/* ================= 11) الكثافة ================= */
.dens-stage { min-height: 300px; }
.dens-stage .tank { position: relative; width: min(360px, 100%); height: 220px; border: 3px solid rgba(255, 255, 255, .35); border-radius: 8px; background: rgba(255, 255, 255, .04); }
.tank-water { position: absolute; left: 0; right: 0; bottom: 0; height: 60%; background: linear-gradient(180deg, rgba(120, 190, 235, .5), rgba(60, 140, 210, .6)); }
.drop-zone { position: absolute; inset: 0; display: grid; place-items: end center; padding-bottom: 8%; color: rgba(255, 255, 255, .5); font-size: 12.5px; }
.drop-zone .obj { width: 46px; height: 46px; border-radius: 8px; border: 2px solid rgba(255, 255, 255, .6); color: #fff; font-size: 11px; display: grid; place-items: center; transition: transform 1.4s ease-in, top 1.4s; }
.drop-zone .obj.floats { transform: translateY(-52px); }
.drop-zone .obj.sinks { transform: translateY(20px); opacity: .85; }

/* ================= 12) الفصول ================= */
.seasons-stage { min-height: 340px; }
.seasons-svg .earth { fill: #3f7ae8; stroke: #bfe0ff; stroke-width: 2; }
.seasons-svg .axis { stroke: #ffd75e; stroke-width: 2; }

/* ================= 13) الضغط الجوي ================= */
.press-stage { min-height: 300px; }
.cup-scene { position: relative; width: 220px; height: 240px; }
.cup-scene .cup { position: absolute; bottom: 10px; left: 50%; transform: translateX(-50%); width: 150px; height: 150px; border: 4px solid rgba(255, 255, 255, .45); border-radius: 6px 6px 22px 22px; transition: transform .5s; }
.cup-scene .cup.flipped { transform: translateX(-50%) scaleY(-1); }
.cup-water { position: absolute; left: 4px; right: 4px; bottom: 4px; height: 0; background: #6fb1e0; border-radius: 0 0 16px 16px; transition: height .4s; }
.cup-water.full { height: calc(100% - 8px); }
.cup-scene .card { position: absolute; bottom: 158px; left: 50%; transform: translateX(-50%); width: 170px; height: 10px; background: #e8dcc8; border-radius: 3px; }
.cup-scene .card.holding { box-shadow: 0 0 0 2px rgba(201, 162, 75, .6); }
.cup-scene .arrows { position: absolute; inset: 0; opacity: 0; transition: opacity .4s; }
.cup-scene .arrows.show { opacity: 1; }
.cup-scene .arrows i { position: absolute; color: var(--gold-soft); font-style: normal; font-weight: 700; }
.cup-scene .a-l { left: 14%; top: 45%; }
.cup-scene .a-r { right: 14%; top: 45%; }
.cup-scene .a-t { bottom: 4%; left: 50%; }

/* ================= 14) البلورات ================= */
.crystal-stage { min-height: 320px; }
.crystal-stage .jar { position: relative; width: 150px; height: 230px; border: 3px solid rgba(255, 255, 255, .35); border-radius: 8px; overflow: hidden; background: rgba(255, 255, 255, .04); }
.jar-liquid { position: absolute; left: 0; right: 0; bottom: 0; height: 55%; background: linear-gradient(180deg, #cfe6f5, #bcd8ee); transition: height .5s; }
.crystal-stage .string { position: absolute; top: 0; left: 50%; width: 3px; height: 80%; background: #e8dcc8; transform: translateX(-50%); }
.crystals .cr { position: absolute; width: 10px; height: 10px; background: #f4f4f4; border: 1px solid rgba(120, 120, 130, .4); transform: rotate(45deg); }

/* ================= 15) البندول ================= */
.pend-stage { min-height: 320px; }
.pend-svg .string { stroke: #e8dcc8; stroke-width: 2.5; }
.pend-svg .bob { fill: #c9a24b; stroke: #e7cf92; stroke-width: 2; }
.pend-svg .mount, .pend-svg .bar { stroke: rgba(255, 255, 255, .5); stroke-width: 3; }

/* ================= 16) الأحماض والقواعد ================= */
.ph-stage { min-height: 300px; }
.ph-row { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; }
.ph-cup { width: 92px; border: 2px solid rgba(255, 255, 255, .25); border-radius: 12px; background: rgba(255, 255, 255, .05); padding: 8px; color: #fff; transition: border-color .2s, transform .2s; }
.ph-cup:hover { transform: translateY(-3px); }
.ph-cup.sel { border-color: var(--gold); box-shadow: 0 0 0 3px rgba(201, 162, 75, .25); }
.ph-label { display: block; font-size: 12px; margin-bottom: 8px; }
.ph-liquid { display: block; height: 54px; border-radius: 8px; background: #eee; transition: background .5s; }
.ph-scale { display: flex; align-items: center; gap: 12px; margin-top: 18px; color: rgba(255, 255, 255, .75); font-size: 12px; width: min(420px, 100%); }
.ph-scale .bar { position: relative; flex: 1; height: 8px; border-radius: 6px; background: linear-gradient(90deg, #e8442e, #f5a623, #6fb1e0, #3a7ae8); }
.ph-scale .bar i { position: absolute; top: -3px; font-style: normal; font-family: var(--font-mono); font-size: 11px; color: #fff; }

/* ================= 17) المغناطيس ================= */
.magnet-stage { min-height: 300px; }
.magnet-svg .magnet-bar { fill: #8a1f2d; stroke: #e8dcc8; stroke-width: 2; }
.magnet-svg .pole { font-size: 16px; font-weight: 800; fill: #fff; }
.magnet-svg .field-line { fill: none; stroke: var(--gold-soft); stroke-width: 2; stroke-dasharray: 5 4; animation: dash 1.2s linear infinite; }
@keyframes dash { to { stroke-dashoffset: -18; } }

/* ================= 18) كولوم ================= */
.coul-stage { min-height: 320px; }
.coul-svg .axis-l { stroke: rgba(255, 255, 255, .25); stroke-width: 1.5; }
.coul-svg .charge { stroke: #fff; stroke-width: 2; }
.coul-svg .q-pos { fill: #3fae6a; }
.coul-svg .q-neg { fill: #e0655f; }
.coul-svg .f-arrow { stroke: #ffd75e; stroke-width: 4; }

/* ================= 19) أوم ================= */
.ohm-stage { min-height: 280px; }
.ohm-svg .resistor { fill: #2a3a30; stroke: rgba(255, 255, 255, .5); stroke-width: 2; }
.ohm-svg .amp { fill: #123a29; stroke: rgba(255, 255, 255, .5); stroke-width: 2; }
.ohm-svg .volt { fill: #1f2d3a; stroke: rgba(255, 255, 255, .5); stroke-width: 2; }

/* ================= 20) السقوط الحر ================= */
.fall-stage { min-height: 320px; }
.fall-svg .ruler { fill: #e8dcc8; }
.fall-svg .ball { fill: #c9a24b; stroke: #e7cf92; stroke-width: 2; }
.fall-svg .floor { fill: rgba(255, 255, 255, .4); }

/* ================= 21) الانكسار ================= */
.refract-stage { min-height: 320px; }
.refract-svg .interface { stroke: rgba(255, 255, 255, .6); stroke-width: 2.5; }
.refract-svg .normal { stroke: rgba(255, 255, 255, .25); stroke-width: 1.5; stroke-dasharray: 4 4; }
.refract-svg .ray-inc { stroke: #ffd75e; stroke-width: 3; }
.refract-svg .ray-ref { stroke: #6fb1e0; stroke-width: 3; }

/* ================= 22) الذرة ================= */
.atom-stage { min-height: 320px; }
.atom-svg .nucleus { fill: #c9a24b; stroke: #e7cf92; stroke-width: 2; }
.atom-svg .electron { fill: #6fb1e0; }
.atom-sel { font-family: var(--font-mono); font-size: 13px; color: var(--gold-soft); padding: 8px 14px; }

/* ================= 23) المولارية ================= */
.molar-stage { min-height: 300px; }
.molar-stage .vol-flask { position: relative; width: 140px; height: 200px; }
.flask-mark { position: absolute; top: 26%; left: 0; right: 0; height: 3px; background: rgba(255, 255, 255, .8); }
.molar-stage .flask-liquid { height: 10%; transition: height .3s; border-radius: 40px 40px 40px 40px; }

/* ================= 24) الخلايا ================= */
.cells-stage { flex-direction: row; gap: 16px; flex-wrap: wrap; }
.cell-panel { width: min(240px, 100%); background: rgba(255, 255, 255, .05); border: 1px solid rgba(255, 255, 255, .12); border-radius: 14px; padding: 14px; }
.cell-panel h4 { color: var(--gold-soft); font-size: 14px; margin-bottom: 8px; }
.cell-panel svg { width: 100%; }
.cell-panel .cw { fill: rgba(47, 143, 91, .35); stroke: #2f8f5b; stroke-width: 3; }
.cell-panel .cm { fill: rgba(120, 200, 150, .25); stroke: rgba(255, 255, 255, .4); stroke-width: 1.5; }
.cell-panel .cm.rnd { fill: rgba(120, 200, 150, .25); stroke: rgba(255, 255, 255, .4); }
.cell-panel .nu { fill: rgba(60, 110, 160, .5); stroke: #3a6fa5; stroke-width: 2; }
.cell-panel .ch { fill: rgba(60, 160, 110, .6); }
.cell-panel .vac { fill: rgba(255, 255, 255, .35); stroke: rgba(255, 255, 255, .5); stroke-width: 1.5; }
.cell-panel .cl-t { font-size: 10px; fill: rgba(255, 255, 255, .7); }
.cells-stage.no-labels .cl-t { display: none; }

/* ================= 25) مربع بانيت ================= */
.punnett-stage { min-height: 300px; }
.pun-grid { display: grid; grid-template-columns: repeat(3, 62px); gap: 6px; }
.pc { width: 62px; height: 42px; border: 1.5px solid rgba(255, 255, 255, .3); border-radius: 8px; display: grid; place-items: center; font-family: var(--font-mono); font-size: 16px; font-weight: 600; }
.pc.head { background: rgba(201, 162, 75, .25); color: var(--gold-soft); }
.pc.kid { background: rgba(255, 255, 255, .08); color: #fff; }
.pc.empty { border: none; }

/* ================= 26) المفتاح التصنيفي ================= */
.tax-stage { min-height: 280px; }
.tax-question { font-size: 15px; color: var(--gold-soft); margin-bottom: 14px; }
.tax-pool { display: flex; gap: 10px; flex-wrap: wrap; justify-content: center; margin-bottom: 8px; }
.tax-chip { background: rgba(255, 255, 255, .1); border: 1px solid rgba(255, 255, 255, .25); padding: 8px 16px; border-radius: 999px; font-size: 13px; }

/* ================= 27) الزلازل ================= */
.seismic-stage { min-height: 300px; position: relative; }
.ground-row { position: absolute; right: 0; left: 0; height: 12px; border-radius: 4px; transition: transform .08s; }
#grow1 { bottom: 18%; background: rgba(47, 143, 91, .5); }
#grow2 { bottom: 11%; background: rgba(47, 143, 91, .65); }
#grow3 { bottom: 4%; background: rgba(35, 110, 70, .8); }
.buildings { position: absolute; bottom: 30%; right: 8%; left: 8%; display: flex; justify-content: space-between; align-items: flex-end; }
.buildings i { display: block; width: 34px; background: rgba(255, 255, 255, .35); border-radius: 4px 4px 0 0; }
.b1 { height: 70px; } .b2 { height: 46px; } .b3 { height: 92px; } .b4 { height: 58px; }
.buildings.shake-1 { animation: sh1 .3s infinite; }
.buildings.shake-2 { animation: sh2 .25s infinite; }
.buildings.shake-3 { animation: sh3 .2s infinite; }
.buildings.shake-4, .buildings.shake-5 { animation: sh4 .16s infinite; }
@keyframes sh1 { 0%,100% { transform: translateX(0); } 50% { transform: translateX(3px); } }
@keyframes sh2 { 0%,100% { transform: translateX(0); } 50% { transform: translateX(6px); } }
@keyframes sh3 { 0%,100% { transform: translateX(0); } 50% { transform: translateX(9px); } }
@keyframes sh4 { 0%,100% { transform: translate(0,0); } 33% { transform: translate(12px,-3px); } 66% { transform: translate(-10px,2px); } }

/* ================= 28) الكواكب ================= */
.planets-stage { min-height: 360px; }
.planets-svg .p-ball { stroke: rgba(255, 255, 255, .5); stroke-width: 1; }
.planets-svg .p-name { font-size: 10px; fill: rgba(255, 255, 255, .75); }

/* ---------- شريط تمرير عناصر التحكم ---------- */
input[type=range] {
  -webkit-appearance: none; appearance: none; height: 5px; border-radius: 4px;
  background: rgba(255, 255, 255, .2); outline: none;
}
input[type=range]::-webkit-slider-thumb {
  -webkit-appearance: none; width: 16px; height: 16px; border-radius: 50%;
  background: var(--gold); border: 2px solid #fff; cursor: pointer;
}
input[type=range]::-moz-range-thumb {
  width: 16px; height: 16px; border-radius: 50%; background: var(--gold); border: 2px solid #fff; cursor: pointer;
}

/* =====================================================================
   الوضع الإرشادي التفاعلي (للتجارب دون محاكاة مخصصة)
   ===================================================================== */
.guided { text-align: right; width: 100%; }
.guided-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 6px; }
.guided-title { font-family: var(--font-head); font-weight: 800; font-size: 15px; color: var(--gold-soft); }
.guided-progress { font-family: var(--font-mono); font-size: 11.5px; color: rgba(255, 255, 255, .55); }
.gstep { display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; border-radius: 12px; background: rgba(255, 255, 255, .05); border: 1px solid rgba(255, 255, 255, .1); margin-top: 10px; }
.gstep.done { background: rgba(0, 108, 53, .22); border-color: rgba(120, 200, 150, .4); }
.gnum {
  flex: none; width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center;
  font-family: var(--font-mono); font-size: 12px; background: rgba(201, 162, 75, .2); color: var(--gold-soft); border: 1px solid rgba(201, 162, 75, .5);
}
.gstep.done .gnum { background: var(--saudi); border-color: var(--saudi); color: #fff; }
.gbody { flex: 1; }
.gstep .gt { font-size: 13.5px; color: rgba(255, 255, 255, .92); }
.gstep .gd { font-size: 12.5px; color: rgba(255, 255, 255, .62); margin-top: 2px; }
.gstep .gdo {
  font-size: 12px; font-weight: 700; color: var(--saudi-deep); background: var(--gold);
  border: none; border-radius: 8px; padding: 7px 14px; margin-top: 8px;
}
.gstep .gdo:disabled { opacity: .4; }
.gstep.done .gdo { display: none; }
.g-conclusion {
  margin-top: 14px; padding: 14px 16px; border-radius: 12px;
  background: rgba(201, 162, 75, .12); border: 1px solid rgba(201, 162, 75, .4);
  font-size: 13.5px; line-height: 1.9; color: rgba(255, 255, 255, .9);
}
.g-conclusion b { color: var(--gold-soft); }

/* أهداف التعلم */
.objectives li {
  display: flex; gap: 12px; align-items: flex-start; padding: 11px 0;
  border-bottom: 1px dashed var(--line); font-size: 14.5px; line-height: 1.9;
}
.objectives li:last-child { border-bottom: 0; }
.objectives .check {
  flex: none; width: 22px; height: 22px; margin-top: 4px; border-radius: 50%;
  background: var(--saudi-soft); color: var(--saudi);
  display: grid; place-items: center; font-size: 12px; border: 1px solid rgba(0, 108, 53, .3);
}

/* الشريط الجانبي */
.side-stack { display: flex; flex-direction: column; gap: 22px; }
.info-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 11px 0; border-bottom: 1px dashed var(--line); font-size: 13.5px; }
.info-row:last-child { border-bottom: 0; }
.info-row .k { color: var(--muted); display: flex; align-items: center; gap: 8px; }
.info-row .v { font-family: var(--font-mono); font-size: 12.5px; font-weight: 600; color: var(--saudi-deep); text-align: end; }

.tools li {
  display: flex; align-items: center; gap: 11px; padding: 8.5px 0;
  font-size: 14px; border-bottom: 1px dashed var(--line);
}
.tools li:last-child { border-bottom: 0; }
.tools .t-dot { width: 8px; height: 8px; border-radius: 2px; background: var(--gold); flex: none; }

.start-box { text-align: center; }
.start-box .btn { width: 100%; }
.start-note { margin-top: 12px; font-size: 12.5px; color: var(--muted); line-height: 1.8; }
.start-note .mono { font-size: 11.5px; }

.compat-note {
  display: flex; gap: 12px; background: var(--saudi-soft); border: 1px solid rgba(0, 108, 53, .25);
  border-radius: 14px; padding: 15px 18px; font-size: 13px; line-height: 1.85; color: var(--saudi-ink);
}
.compat-note svg { flex: none; width: 20px; height: 20px; margin-top: 3px; color: var(--saudi); }

.related { margin-top: 46px; }

/* ---------- ظهور العناصر عند التمرير ---------- */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.reveal.in { opacity: 1; transform: none; }

/* =====================================================================
   الاستجابة
   ===================================================================== */
@media (max-width: 1020px) {
  .stages-grid, .grid, .how-grid { grid-template-columns: repeat(2, 1fr); }
  .filter-row { grid-template-columns: repeat(3, 1fr); }
  .exp-layout { grid-template-columns: 1fr; }
  .footer-top { grid-template-columns: 1fr 1fr; }
  .safety-grid { grid-template-columns: 1fr; }
}

@media (max-width: 760px) {
  :root { --header-h: 68px; }
  .main-nav {
    position: fixed; inset: var(--header-h) 0 auto 0; flex-direction: column; gap: 4px;
    background: rgba(255, 255, 255, .98); backdrop-filter: blur(14px);
    padding: 18px 22px 26px; border-bottom: 1px solid var(--line);
    box-shadow: 0 24px 40px rgba(11, 43, 30, .18);
    transform: translateY(-140%); transition: transform .4s var(--ease);
  }
  .main-nav.open { transform: translateY(0); }
  .main-nav a { width: 100%; padding: 13px 16px; }
  .menu-toggle { display: grid; place-items: center; }
  .stages-grid, .grid, .how-grid { grid-template-columns: 1fr; }
  .filter-row { grid-template-columns: 1fr; }
  .trust-item { flex-direction: column; align-items: flex-start; gap: 4px; }
  .hero-trust { flex-direction: column; width: 100%; }
  .trust-item + .trust-item { border-inline-start: 0; border-top: 1px solid rgba(255, 255, 255, .14); }
  .safety-rules { grid-template-columns: 1fr; }
  .footer-top { grid-template-columns: 1fr; gap: 28px; }
  .cta-inner { flex-direction: column; align-items: flex-start; }
  .compliance { flex-direction: column; align-items: flex-start; }
  .brand-txt span { display: none; }
}

/* =====================================================================
   تقليل الحركة
   ===================================================================== */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .reveal { opacity: 1; transform: none; }
  .hero-bg.kenburns img, .exp-hero.kenburns img { transform: none; }
}
