/* =====================================================================
   الجهاز — نيوبروتال  |  خط ثمانية
   الحدود سوداء صلبة · الظلال بلا تمويه · ألوان مسطّحة
   ===================================================================== */

/* ── خط ثمانية ───────────────────────────────────────────────────
   نزّل الخط من font.thmanyah.com وضع الملفات في public/fonts/
   الأسماء المتوقعة أدناه — عدّلها لو اختلفت تسمية الملفات عندك.
   قبل رفع الملفات يعمل الموقع على الخط الاحتياطي بدون كسر.        */

@font-face{
  font-family:'Thmanyah';
  src:url('/fonts/thmanyahsans-Light.otf') format('opentype');
  font-weight:300;font-style:normal;font-display:swap;
}
@font-face{
  font-family:'Thmanyah';
  src:url('/fonts/thmanyahsans-Regular.otf') format('opentype');
  font-weight:400;font-style:normal;font-display:swap;
}
@font-face{
  font-family:'Thmanyah';
  src:url('/fonts/thmanyahsans-Medium.otf') format('opentype');
  font-weight:500;font-style:normal;font-display:swap;
}
@font-face{
  font-family:'Thmanyah';
  src:url('/fonts/thmanyahsans-Bold.otf') format('opentype');
  font-weight:700;font-style:normal;font-display:swap;
}
@font-face{
  font-family:'Thmanyah';
  src:url('/fonts/thmanyahsans-Black.otf') format('opentype');
  font-weight:900;font-style:normal;font-display:swap;
}

:root{
  /* الهوية */
  --teal:#0ABFA3;
  --teal-d:#089080;
  --mint:#B8F5E7;

  /* ألوان نيوبروتال مسطّحة — ثابتة في الوضعين */
  --yellow:#FFD84D;
  --coral:#FF7A59;
  --lilac:#C9BCFF;

  /* الأسطح */
  --paper:#FFFDF7;          /* خلفية الصفحة */
  --surface:#FFFFFF;        /* خلفية البطاقات والأزرار */
  --foot-bg:#000000;

  /* الحدود والظلال — تنقلب في الوضع الليلي */
  --edge:#000000;

  /* النصوص */
  --on-surface:#000000;     /* نص على الأسطح البيضاء/الداكنة */
  --on-accent:#000000;      /* نص على الأصفر والنعناعي… يبقى أسود دائماً */
  --ink:#000000;            /* العناوين */
  --body:#2A2A2A;
  --muted:#5F5F5F;

  /* الواجهة */
  --hero-bg:var(--mint);
  --hero-fg:#000000;

  /* ثوابت الأسلوب */
  --bd:3px;
  --bd-thick:4px;
  --sh:-6px 6px 0 var(--edge);
  --sh-sm:-4px 4px 0 var(--edge);
  --sh-lg:-10px 10px 0 var(--edge);

  --s1:.5rem; --s2:1rem; --s3:1.5rem; --s4:2rem;
  --s5:3rem; --s6:4.5rem;
  --wrap:1200px;

  --font:'Thmanyah','IBM Plex Sans Arabic',system-ui,sans-serif;
  --font-display:'Thmanyah','IBM Plex Sans Arabic',system-ui,sans-serif;
}

html[data-theme="dark"]{
  --paper:#12120D;
  --surface:#1E1E18;
  --foot-bg:#080805;

  /* الحد يصير فاتحاً — الأسود يختفي على الداكن */
  --edge:#FFFDF7;

  --on-surface:#FFFDF7;
  --on-accent:#000000;      /* الألوان المسطّحة تبقى فاتحة فالنص يبقى أسود */
  --ink:#FFFDF7;
  --body:#DCDAD0;
  --muted:#A8A69C;

  --hero-bg:#122620;
  --hero-fg:#FFFDF7;
}

*,*::before,*::after{box-sizing:border-box;margin:0;padding:0}
html{scroll-behavior:smooth;-webkit-text-size-adjust:100%}

body{
  font-family:var(--font);
  background:var(--paper);
  color:var(--body);
  font-size:17px;line-height:1.75;font-weight:400;
  -webkit-font-smoothing:antialiased;overflow-x:hidden;
}

h1,h2,h3,h4{color:var(--ink);line-height:1.1;font-weight:900;letter-spacing:-.02em}
h1{font-family:var(--font-display);font-size:clamp(2.7rem,7vw,5.5rem);line-height:1.02}
h2{font-family:var(--font-display);font-size:clamp(2rem,4.4vw,3.4rem)}
h3{font-size:1.3rem;font-weight:700}
p{max-width:68ch}
a{color:var(--teal-d);text-decoration-thickness:2px;text-underline-offset:3px}
img{max-width:100%;display:block}
:focus-visible{outline:3px solid var(--edge);outline-offset:3px}

.wrap{max-width:var(--wrap);margin-inline:auto;padding-inline:clamp(1rem,4vw,2rem)}
.section{padding-block:clamp(3rem,6vw,5rem)}
.lede{font-size:clamp(1.05rem,1.7vw,1.3rem);color:var(--body);font-weight:500}

/* ── الصندوق الأساسي: حد أسود + ظل صلب ────────────────────────── */
.box{
  background:var(--surface);
  border:var(--bd) solid var(--edge);
  box-shadow:var(--sh);
  padding:var(--s3);
}
.box-yellow{background:var(--yellow)}
.box-mint{background:var(--mint)}
.box-coral{background:var(--coral)}
.box-lilac{background:var(--lilac)}
.box-teal{background:var(--teal)}
.box-black{background:#000;color:#fff;border-color:var(--edge)}
.box-black h1,.box-black h2,.box-black h3{color:#fff}

/* شارة مائلة */
.sticker{
  display:inline-block;background:var(--yellow);
  border:var(--bd) solid var(--edge);box-shadow:var(--sh-sm);
  padding:.3rem 1rem;font-weight:700;font-size:.9rem;color:var(--on-accent);
  transform:rotate(-2deg);margin-bottom:var(--s2);
}
.sticker-mint{background:var(--mint)}
.sticker-coral{background:var(--coral)}
.sticker-teal{background:var(--teal)}

.head{margin-bottom:var(--s4);max-width:60ch}
.head h2{margin-bottom:.5rem}

/* ── الشريط العلوي ──────────────────────────────────────────────── */
.topbar{
  position:sticky;top:0;z-index:60;
  background:var(--paper);
  border-bottom:var(--bd-thick) solid var(--edge);
}
.topbar-in{display:flex;align-items:center;gap:var(--s2);min-height:74px}
.brand{display:flex;align-items:center;text-decoration:none;flex-shrink:0}
.brand img{height:40px;width:auto}

.menu{display:flex;gap:.35rem;margin-inline-start:auto}
.menu a{
  text-decoration:none;color:var(--on-surface);
  font-size:1rem;font-weight:700;padding:.45rem .9rem;
  border:var(--bd) solid transparent;transition:none;
}
.menu a:hover{border-color:var(--edge);background:var(--yellow)}
.menu a[aria-current="page"]{background:var(--teal);border-color:var(--edge);box-shadow:var(--sh-sm)}
.menu a.ext::after{content:"↗";font-size:.8em;margin-inline-start:.25rem}

.topbar-actions{display:flex;align-items:center;gap:.5rem}
.icon-btn{
  width:44px;height:44px;display:grid;place-items:center;
  border:var(--bd) solid var(--edge);background:var(--surface);
  color:var(--on-surface);cursor:pointer;font-size:1.05rem;font-family:inherit;
  box-shadow:var(--sh-sm);
}
.icon-btn:hover{background:var(--yellow)}
.icon-btn:active{transform:translate(2px,-2px);box-shadow:-2px 2px 0 var(--edge)}
.burger{display:none}

/* ── الأزرار ───────────────────────────────────────────────────── */
.btn{
  display:inline-flex;align-items:center;justify-content:center;gap:.5rem;
  font-family:inherit;font-size:1.05rem;font-weight:700;text-decoration:none;
  padding:.85rem 1.8rem;cursor:pointer;color:var(--on-surface);
  background:var(--surface);
  border:var(--bd) solid var(--edge);
  box-shadow:var(--sh);
  transition:transform .1s,box-shadow .1s;
}
.btn:hover{transform:translate(3px,-3px);box-shadow:-9px 9px 0 var(--edge)}
.btn:active{transform:translate(0,0);box-shadow:-2px 2px 0 var(--edge)}
.btn-primary{background:var(--teal);color:var(--on-accent)}
.btn-yellow{background:var(--yellow);color:var(--on-accent)}
.btn-coral{background:var(--coral);color:var(--on-accent)}
.btn-white{background:var(--surface);color:var(--on-surface)}
.btn-sm{padding:.45rem 1.1rem;font-size:.92rem;box-shadow:var(--sh-sm)}
.btn-sm:hover{transform:translate(2px,-2px);box-shadow:-6px 6px 0 var(--edge)}

/* ── الواجهة ───────────────────────────────────────────────────── */
.hero{
  background:var(--hero-bg);
  border-bottom:var(--bd-thick) solid var(--edge);
  padding-block:clamp(3rem,8vw,6rem);
  position:relative;overflow:hidden;
}
.hero::before{
  content:"";position:absolute;inset:0;z-index:0;opacity:.5;
  background-image:radial-gradient(var(--hero-fg) 1.4px,transparent 1.5px);
  background-size:22px 22px;
}
.hero > *{position:relative;z-index:1}
.hero{text-align:center}
.hero h1{margin:0 auto var(--s3);max-width:20ch;font-size:clamp(2.8rem,8vw,6.5rem);color:var(--hero-fg)}
.hero .lede{max-width:56ch;margin:0 auto var(--s4);font-size:clamp(1.1rem,2vw,1.45rem);color:var(--hero-fg)}
.hero-cta{display:flex;gap:var(--s2);flex-wrap:wrap;justify-content:center}


/* شريط متحرك أسود */
.ticker{
  background:#000;color:var(--yellow);
  border-bottom:var(--bd-thick) solid var(--edge);
  overflow:hidden;padding-block:.7rem;
}
.ticker-track{display:flex;gap:2.5rem;width:max-content;animation:tick 30s linear infinite;font-weight:700;font-size:1rem;white-space:nowrap}
.ticker-track span::before{content:"◆";margin-inline-end:.7rem;color:var(--teal)}
@keyframes tick{from{transform:translateX(0)}to{transform:translateX(-50%)}}

/* ── الأرقام ───────────────────────────────────────────────────── */
.stats{display:grid;grid-template-columns:repeat(4,1fr);gap:var(--s3)}
.stat{
  background:var(--surface);border:var(--bd) solid var(--edge);box-shadow:var(--sh);
  padding:var(--s3) var(--s2);text-align:center;
}
.stat:nth-child(1){background:var(--yellow)}
.stat:nth-child(2){background:var(--mint)}
.stat:nth-child(3){background:var(--coral)}
.stat:nth-child(4){background:var(--lilac)}
.stat b{
  display:block;font-family:var(--font-display);
  font-size:clamp(2.4rem,5vw,3.8rem);font-weight:900;line-height:1;
  color:var(--on-accent);font-variant-numeric:tabular-nums;
}
.stat span{display:block;margin-top:.5rem;font-size:.98rem;font-weight:700;color:var(--on-accent)}

/* ── شبكة بنتو للمنصات ─────────────────────────────────────────── */
.bento{display:grid;grid-template-columns:repeat(3,1fr);gap:var(--s3)}
.bento .platform:nth-child(1){grid-column:span 2}
.bento .platform:nth-child(6){grid-column:span 2}

.platform{
  background:var(--surface);border:var(--bd) solid var(--edge);box-shadow:var(--sh);
  padding:var(--s3);text-decoration:none;color:var(--on-surface);
  display:flex;flex-direction:column;gap:.5rem;
  transition:transform .1s,box-shadow .1s;
}
.platform:hover{transform:translate(3px,-3px);box-shadow:var(--sh-lg)}
.platform:nth-child(2){background:var(--yellow)}
.platform:nth-child(3){background:var(--mint)}
.platform:nth-child(5){background:var(--lilac)}
.platform h3{font-size:1.5rem;font-weight:900}
.platform .p-sub{
  align-self:flex-start;background:#000;color:var(--yellow);
  font-size:.8rem;font-weight:700;padding:.15rem .7rem;
}
.platform p{color:var(--body);font-size:.98rem;flex:1;font-weight:500}
.platform .p-link{font-size:.9rem;font-weight:700;text-decoration:underline;text-decoration-thickness:2px}

/* ── الخدمات ───────────────────────────────────────────────────── */
.services{display:grid;grid-template-columns:repeat(auto-fit,minmax(280px,1fr));gap:var(--s3)}
.service{
  background:var(--surface);border:var(--bd) solid var(--edge);box-shadow:var(--sh);
  padding:var(--s3);transition:transform .1s,box-shadow .1s;
}
.service:hover{transform:translate(3px,-3px);box-shadow:var(--sh-lg)}
.service-ico{
  width:56px;height:56px;display:grid;place-items:center;margin-bottom:var(--s2);
  background:var(--teal);border:var(--bd) solid var(--edge);
}
.service:nth-child(2n) .service-ico{background:var(--yellow)}
.service:nth-child(3n) .service-ico{background:var(--coral)}
.service-ico svg{width:26px;height:26px;stroke:var(--on-accent);fill:none;stroke-width:2.2;stroke-linecap:round;stroke-linejoin:round}
.service h3{margin-bottom:.35rem;font-size:1.25rem;font-weight:900}
.service p{color:var(--body);font-size:.98rem;font-weight:500}

/* ── العملاء ───────────────────────────────────────────────────── */
.marquee{overflow:hidden;border-block:var(--bd) solid var(--edge);background:var(--surface);padding-block:var(--s3)}
.marquee-track{display:flex;gap:var(--s6);width:max-content;animation:tick 40s linear infinite;align-items:center}
.marquee:hover .marquee-track{animation-play-state:paused}
.client{flex:0 0 auto;height:56px;display:grid;place-items:center;filter:grayscale(1) contrast(1.4)}
.client img{max-height:56px;width:auto;object-fit:contain}
.client:hover{filter:none}

/* ── شريط الدعوة ───────────────────────────────────────────────── */
.cta-band{
  background:var(--teal);border:var(--bd-thick) solid var(--edge);box-shadow:var(--sh-lg);
  padding:clamp(2rem,5vw,3.5rem);text-align:center;
}
.cta-band h2{margin-bottom:.6rem;color:var(--on-accent)}
.cta-band p{color:var(--on-accent);font-weight:600;margin:0 auto var(--s3);max-width:52ch}
.cta-actions{display:flex;gap:var(--s2);justify-content:center;flex-wrap:wrap}

/* ── قوائم ─────────────────────────────────────────────────────── */
.rows{display:grid;grid-template-columns:repeat(2,1fr);gap:var(--s3)}
.row-item{background:var(--surface);border:var(--bd) solid var(--edge);box-shadow:var(--sh-sm);padding:var(--s3)}
.row-item h3{margin-bottom:.3rem;font-weight:900}
.row-item p{color:var(--body);font-size:.97rem;font-weight:500}

/* ── المسيرة ───────────────────────────────────────────────────── */
.track{display:grid;gap:var(--s3)}
.track-item{display:grid;grid-template-columns:120px 1fr;gap:var(--s3);align-items:start}
.track-year{
  background:#000;color:var(--yellow);font-weight:700;font-size:.95rem;
  padding:.3rem .8rem;text-align:center;align-self:start;
}
.track-body{background:var(--surface);border:var(--bd) solid var(--edge);box-shadow:var(--sh-sm);padding:var(--s3)}
.track-body h3{margin-bottom:.2rem;font-weight:900}
.track-sub{
  display:inline-block;background:var(--mint);border:2px solid var(--edge);
  font-size:.85rem;font-weight:700;padding:.1rem .6rem;margin-bottom:.6rem;color:var(--on-accent);
}
.track-body p{color:var(--body);font-size:.97rem;font-weight:500}

/* ── التقنيات ──────────────────────────────────────────────────── */
.tech-group{
  background:var(--surface);border:var(--bd) solid var(--edge);box-shadow:var(--sh-sm);
  padding:var(--s3);margin-bottom:var(--s3);
  display:grid;grid-template-columns:230px 1fr;gap:var(--s3);align-items:center;
}
.chips{display:flex;flex-wrap:wrap;gap:.5rem}
.chip{
  padding:.25rem .85rem;border:2px solid var(--edge);background:var(--yellow);
  font-size:.88rem;font-weight:700;color:var(--on-accent);
}

/* ── المدونة ───────────────────────────────────────────────────── */
.cards{display:grid;grid-template-columns:repeat(auto-fill,minmax(290px,1fr));gap:var(--s3)}
.card{
  display:flex;flex-direction:column;text-decoration:none;color:var(--on-surface);
  background:var(--surface);border:var(--bd) solid var(--edge);box-shadow:var(--sh);
  transition:transform .1s,box-shadow .1s;
}
.card:hover{transform:translate(3px,-3px);box-shadow:var(--sh-lg)}
.card-thumb{aspect-ratio:16/10;overflow:hidden;background:var(--mint);border-bottom:var(--bd) solid var(--edge)}
.card-thumb img{width:100%;height:100%;object-fit:cover}
.card-body{padding:var(--s3);display:flex;flex-direction:column;gap:.55rem;flex:1}
.card h3{font-size:1.15rem;line-height:1.45;font-weight:900}
.card p{font-size:.95rem;color:var(--body);flex:1;font-weight:500}
.card-meta{font-size:.86rem;color:var(--muted);font-weight:600}
.badge{
  align-self:flex-start;font-size:.8rem;font-weight:700;color:var(--on-accent);
  background:var(--yellow);border:2px solid var(--edge);padding:.1rem .7rem;
}

.filters{display:flex;gap:.6rem;flex-wrap:wrap;margin-bottom:var(--s4)}
.filters a{
  text-decoration:none;font-size:.95rem;font-weight:700;color:var(--on-surface);
  padding:.45rem 1.2rem;border:var(--bd) solid var(--edge);background:var(--surface);box-shadow:var(--sh-sm);
}
.filters a:hover{background:var(--yellow)}
.filters a[aria-current]{background:var(--teal)}

/* ── المقال ────────────────────────────────────────────────────── */
.article{max-width:72ch;margin-inline:auto}
.article-cover{
  width:100%;aspect-ratio:16/9;object-fit:cover;
  border:var(--bd) solid var(--edge);box-shadow:var(--sh);margin-block:var(--s3) var(--s4);
}
.prose{font-size:1.08rem;line-height:1.9;font-weight:400}
.prose > * + *{margin-top:1.15em}
.prose h2{font-size:1.7rem;margin-top:1.8em;font-weight:900}
.prose h3{font-size:1.25rem;margin-top:1.5em;font-weight:900}
.prose ul,.prose ol{padding-inline-start:1.4rem}
.prose li + li{margin-top:.4em}
.prose li::marker{color:var(--teal-d);font-weight:900}
.prose blockquote{
  background:var(--mint);border:var(--bd) solid var(--edge);box-shadow:var(--sh-sm);
  padding:var(--s3);font-weight:600;color:var(--on-accent);
}
.prose img{border:var(--bd) solid var(--edge)}
.prose hr{border:0;border-top:var(--bd) solid var(--edge)}
.prose table{width:100%;border-collapse:collapse;font-size:.96rem;border:var(--bd) solid var(--edge)}
.prose th{background:var(--yellow);font-weight:700}
.prose th,.prose td{border:2px solid var(--edge);padding:.6rem .8rem;text-align:start}
.prose .highlight-box{background:var(--yellow);border:var(--bd) solid var(--edge);box-shadow:var(--sh-sm);padding:var(--s3)}
.prose .highlight-box .hb-title{font-weight:900;margin-bottom:.4rem;color:var(--on-accent)}

/* ── النماذج ───────────────────────────────────────────────────── */
.form{max-width:640px}
.field{margin-bottom:var(--s3)}
.field label{display:block;font-size:.95rem;font-weight:700;color:var(--ink);margin-bottom:.4rem}
.field input,.field textarea,.field select{
  width:100%;font-family:inherit;font-size:1rem;font-weight:500;color:var(--ink);
  background:var(--surface);border:var(--bd) solid var(--edge);padding:.8rem 1rem;
}
.field textarea{min-height:160px;resize:vertical;line-height:1.7}
.field input:focus,.field textarea:focus,.field select:focus{
  outline:none;box-shadow:var(--sh-sm);transform:translate(2px,-2px);
}
.field .err{display:block;margin-top:.35rem;font-size:.88rem;font-weight:700;color:#B3261E}
.grid2{display:grid;grid-template-columns:1fr 1fr;gap:var(--s2)}
.hp{position:absolute;inset-inline-start:-9999px;width:0;height:0;opacity:0}

.alert{
  padding:1rem 1.2rem;margin-bottom:var(--s3);font-size:1rem;font-weight:700;
  border:var(--bd) solid var(--edge);box-shadow:var(--sh-sm);color:var(--on-accent);
}
.alert-ok{background:var(--mint)}
.alert-err{background:var(--coral)}

/* ── التذييل ───────────────────────────────────────────────────── */
.foot{background:var(--foot-bg);color:#E8E6DC;margin-top:var(--s6);border-top:var(--bd-thick) solid var(--edge)}
.foot .wrap{padding-block:var(--s5) var(--s3)}
.foot-grid{display:grid;grid-template-columns:1.4fr 1fr 1fr;gap:var(--s4);padding-bottom:var(--s4)}
.foot-logo img{height:44px;width:auto;margin-bottom:var(--s2)}
.foot-about{font-size:.96rem;line-height:1.75;max-width:34ch;color:#C9C7BD;font-weight:500}
.foot h4{color:var(--yellow);font-size:1.05rem;font-weight:900;margin-bottom:var(--s2)}
.foot-list{list-style:none;display:grid;gap:.55rem}
.foot-list a{color:#E8E6DC;text-decoration:none;font-size:.97rem;font-weight:600}
.foot-list a:hover{color:var(--yellow);text-decoration:underline;text-decoration-thickness:2px}
.foot-soc{display:flex;gap:.6rem;margin-top:var(--s3)}
.foot-soc a{
  width:44px;height:44px;display:grid;place-items:center;
  background:#FFFDF7;border:var(--bd) solid #FFFDF7;color:#000;
}
.foot-soc a:hover{background:var(--yellow);border-color:var(--yellow)}
.foot-soc svg{width:18px;height:18px;fill:currentColor}
.foot-bottom{
  border-top:2px solid #3A3A32;padding-top:var(--s3);
  display:flex;justify-content:space-between;gap:var(--s3);flex-wrap:wrap;
  font-size:.9rem;color:#A8A69C;font-weight:500;
}
.foot-bottom a{color:#A8A69C;text-decoration:none}
.foot-bottom a:hover{color:var(--yellow)}

/* ── لوحة التحكم ───────────────────────────────────────────────── */
.admin-bar{background:var(--yellow);border-bottom:var(--bd-thick) solid var(--edge)}
.admin-bar .wrap{display:flex;align-items:center;gap:var(--s2);min-height:64px}
.admin-bar strong{color:var(--on-accent);font-weight:900}
.admin-bar a{color:var(--on-accent);font-weight:700}
.admin-bar .spacer{margin-inline-start:auto}
.table{width:100%;border-collapse:collapse;font-size:.96rem;border:var(--bd) solid var(--edge);background:var(--surface)}
.table th{text-align:start;font-weight:900;color:var(--on-accent);background:var(--mint);font-size:.9rem;padding:.75rem .7rem;border:2px solid var(--edge)}
.table td{padding:.85rem .7rem;border:2px solid var(--edge);color:var(--ink);font-weight:500}
.table .actions{display:flex;gap:.4rem;justify-content:flex-end}
.pill{font-size:.82rem;font-weight:700;padding:.1rem .65rem;background:var(--surface);color:var(--on-surface);border:2px solid var(--edge)}
.pill-live{background:var(--teal)}
.login-box{
  max-width:420px;margin:8vh auto;padding:var(--s4);
  background:var(--surface);border:var(--bd-thick) solid var(--edge);box-shadow:var(--sh-lg);
}

/* ── الحركة والاستجابة ─────────────────────────────────────────── */
.enter{opacity:0;transform:translateY(14px);animation:enter .5s steps(6) forwards}
.enter-2{animation-delay:.1s}.enter-3{animation-delay:.2s}.enter-4{animation-delay:.3s}
@keyframes enter{to{opacity:1;transform:none}}

@media (prefers-reduced-motion:reduce){
  *{animation:none!important;transition:none!important;scroll-behavior:auto!important}
  .enter{opacity:1;transform:none}
}

@media (max-width:960px){
    .bento{grid-template-columns:repeat(2,1fr)}
  .bento .platform:nth-child(1),
  .bento .platform:nth-child(6){grid-column:span 2}
  .foot-grid{grid-template-columns:1fr 1fr}
}

@media (max-width:900px){
  .menu{
    display:none;position:absolute;inset-inline:1rem;top:80px;
    flex-direction:column;gap:.4rem;padding:var(--s2);
    background:var(--paper);border:var(--bd-thick) solid var(--edge);box-shadow:var(--sh-lg);
  }
  .menu.open{display:flex}
  .burger{display:grid}
  .rows,.grid2{grid-template-columns:1fr}
  .stats{grid-template-columns:repeat(2,1fr)}
  .tech-group{grid-template-columns:1fr;gap:.8rem}
  .track-item{grid-template-columns:1fr;gap:.5rem}
  .track-year{justify-self:start}
}

@media (max-width:620px){
  :root{--sh:-4px 4px 0 var(--edge);--sh-lg:-6px 6px 0 var(--edge)}
  .bento,.bento .platform:nth-child(1),.bento .platform:nth-child(6){grid-template-columns:1fr;grid-column:auto}
  .foot-grid{grid-template-columns:1fr}
}

/* ── ترقيم الصفحات ─────────────────────────────────────────────── */
.pager{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:var(--s2);margin-top:var(--s4)}
.pager-links{display:flex;gap:.5rem;flex-wrap:wrap}
.pager-btn{
  display:inline-grid;place-items:center;min-width:44px;padding:.4rem .9rem;
  font-family:inherit;font-size:.95rem;font-weight:700;text-decoration:none;
  color:var(--on-surface);background:var(--surface);
  border:var(--bd) solid var(--edge);box-shadow:var(--sh-sm);
}
a.pager-btn:hover{background:var(--yellow);transform:translate(2px,-2px);box-shadow:-6px 6px 0 var(--edge)}
.pager-btn.is-on{background:var(--teal)}
.pager-btn.is-off{opacity:.4;box-shadow:none}
.pager-count{font-size:.92rem;font-weight:600;color:var(--muted)}

/* ── تصحيح الوضع الليلي: النص فوق الأسطح الملوّنة الثابتة ─────────
   الأصفر والنعناعي والمرجاني والبنفسجي والتركوازي تبقى فاتحة في
   الوضعين، فنصها يبقى أسود بغض النظر عن الوضع.                    */
.box-yellow,.box-mint,.box-coral,.box-lilac,.box-teal,
.box-yellow h1,.box-yellow h2,.box-yellow h3,.box-yellow h4,.box-yellow p,
.box-mint   h1,.box-mint   h2,.box-mint   h3,.box-mint   h4,.box-mint   p,
.box-coral  h1,.box-coral  h2,.box-coral  h3,.box-coral  h4,.box-coral  p,
.box-lilac  h1,.box-lilac  h2,.box-lilac  h3,.box-lilac  h4,.box-lilac  p,
.box-teal   h1,.box-teal   h2,.box-teal   h3,.box-teal   h4,.box-teal   p,
.row-accent,.row-accent h3,.row-accent p,
.prose blockquote,.prose blockquote strong,
.prose .highlight-box,.prose .highlight-box p,
.cta-band h2,.cta-band p{color:var(--on-accent)}

.row-accent{background:var(--yellow)}

/* البطاقات الملوّنة داخل شبكة بنتو */
.platform:nth-child(2),.platform:nth-child(2) h3,.platform:nth-child(2) p,
.platform:nth-child(3),.platform:nth-child(3) h3,.platform:nth-child(3) p,
.platform:nth-child(5),.platform:nth-child(5) h3,.platform:nth-child(5) p{color:var(--on-accent)}

/* الحالات النشطة والتمرير فوق ألوان ثابتة */
.menu a:hover,
.menu a[aria-current="page"],
.icon-btn:hover,
.filters a:hover,
.filters a[aria-current],
a.pager-btn:hover,
.pager-btn.is-on,
.table th{color:var(--on-accent)}

/* ── زر واتساب العائم ──────────────────────────────────────────── */
.wa-fab{
  /* left فيزيائي متعمّد: الموقع RTL فـ inset-inline-start يعني اليمين
     وهناك يجلس ودجت المستشار الذكي */
  position:fixed;bottom:22px;left:22px;z-index:900;
  display:inline-flex;align-items:center;gap:.55rem;
  padding:.7rem 1.1rem;
  background:#25D366;color:#000;text-decoration:none;
  font-family:inherit;font-weight:700;font-size:1rem;
  border:var(--bd) solid #000;box-shadow:-5px 5px 0 #000;
  transition:transform .1s,box-shadow .1s;
}
.wa-fab:hover{transform:translate(3px,-3px);box-shadow:-8px 8px 0 #000}
.wa-fab:active{transform:translate(0,0);box-shadow:-2px 2px 0 #000}
.wa-fab svg{width:26px;height:26px;fill:#000;flex-shrink:0}

/* على الجوال: أيقونة فقط، بلا نص */
@media (max-width:620px){
  .wa-fab{padding:.7rem;bottom:16px;left:16px}
  .wa-label{display:none}
}

@media print{.wa-fab{display:none}}

/* ── مواءمة ودجت المستشار الذكي (Aixra) مع أسلوب الموقع ──────────
   الودجت يُحقن من aixraai.com كـ DOM عادي بلا Shadow DOM، فقواعدنا
   تصله. حلّ موضعي لموقع الجهاز — الحل الدائم إضافة خيارات مظهر
   داخل Aixra نفسها حتى يستفيد بقية التجار.                        */

/* الزر العائم */
.aixra-widget .aixra-fab{
  border:3px solid #000 !important;
  border-radius:0 !important;
  box-shadow:6px 6px 0 #000 !important;
  background:var(--teal) !important;
  width:auto !important;height:auto !important;
  min-width:0 !important;min-height:0 !important;
  padding:.7rem 1.1rem !important;
  font-family:var(--font) !important;font-size:1.5rem !important;line-height:1 !important;
  transition:transform .1s,box-shadow .1s !important;
}
.aixra-widget .aixra-fab:hover{
  transform:translate(-3px,-3px) !important;
  box-shadow:9px 9px 0 #000 !important;
}
.aixra-widget .aixra-fab:active{
  transform:translate(0,0) !important;
  box-shadow:2px 2px 0 #000 !important;
}

/* نافذة المحادثة */
.aixra-widget .aixra-window{
  border:3px solid #000 !important;
  border-radius:0 !important;
  box-shadow:10px 10px 0 #000 !important;
  font-family:var(--font) !important;
}
.aixra-widget .aixra-header{
  background:var(--teal) !important;color:#000 !important;
  border-bottom:3px solid #000 !important;border-radius:0 !important;
}
.aixra-widget .aixra-header-name,
.aixra-widget .aixra-header-status{color:#000 !important;font-weight:700 !important}
.aixra-widget .aixra-avatar,
.aixra-widget .aixra-close{
  border:2px solid #000 !important;border-radius:0 !important;
  background:#FFFDF7 !important;color:#000 !important;
}
.aixra-widget .aixra-input{
  border:2px solid #000 !important;border-radius:0 !important;
  font-family:var(--font) !important;
}
.aixra-widget .aixra-send{
  border:2px solid #000 !important;border-radius:0 !important;
  background:var(--yellow) !important;color:#000 !important;
}
.aixra-widget .aixra-footer{border-top:2px solid #000 !important}
