/* ==========================================================================
   قرطاج الحديثة — نظام التصميم الكامل (RTL)
   ملف CSS3 مكتوب بالكامل ولا يعتمد على أي إطار خارجي، ليبقى الموقع سليماً
   بصرياً وكامل الوظائف حتى لو تعذّر تحميل أي مورد خارجي.
   ========================================================================== */

/* ------------------------------- المتغيّرات -------------------------------- */
:root {
  --blue: #0284c7;
  --blue-deep: #0369a1;
  --blue-ink: #075985;
  --navy: #0b3b63;
  --navy-2: #082c4b;
  --green: #10b981;
  --green-deep: #059669;
  --gold: #c9a227;
  --gold-soft: #f0d982;
  --rose: #e4485e;
  --slate-50: #f8fafc;
  --slate-100: #f1f5f9;
  --slate-200: #e2e8f0;
  --slate-300: #cbd5e1;
  --slate-400: #94a3b8;
  --slate-500: #64748b;
  --slate-600: #475569;
  --slate-700: #334155;
  --slate-800: #1e293b;
  --white: #ffffff;

  --ink: #14293d;
  --body: #40566b;
  --muted: #6b8296;
  --line: #e2ecf4;
  --line-strong: #cfe0ee;
  --bg: #ffffff;
  --bg-alt: #f8fafc;
  --bg-sky: #eef7fd;

  --radius-sm: 10px;
  --radius: 16px;
  --radius-lg: 24px;
  --radius-xl: 32px;
  --shadow-xs: 0 1px 2px rgba(11, 59, 99, 0.06);
  --shadow-sm: 0 4px 14px rgba(11, 59, 99, 0.07);
  --shadow: 0 12px 30px rgba(11, 59, 99, 0.09);
  --shadow-lg: 0 26px 60px rgba(11, 59, 99, 0.14);
  --ring: 0 0 0 4px rgba(2, 132, 199, 0.18);
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --header-h: 74px;
  --font-head: 'Cairo', system-ui, 'Segoe UI', Tahoma, sans-serif;
  --font-body: 'Tajawal', system-ui, 'Segoe UI', Tahoma, sans-serif;
}

/* --------------------------------- تهيئة ---------------------------------- */
*,
*::before,
*::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 20px);
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.03rem;
  line-height: 1.85;
  color: var(--body);
  background: var(--bg);
  direction: rtl;
  text-align: right;
  overflow-x: hidden;
}

h1, h2, h3, h4, h5 {
  font-family: var(--font-head);
  color: var(--ink);
  line-height: 1.35;
  margin: 0 0 0.6em;
  font-weight: 800;
  letter-spacing: -0.01em;
}

h1 { font-size: clamp(1.9rem, 4.2vw, 3.1rem); font-weight: 900; }
h2 { font-size: clamp(1.5rem, 3vw, 2.2rem); font-weight: 900; }
h3 { font-size: clamp(1.15rem, 2vw, 1.45rem); }
h4 { font-size: 1.1rem; }

p { margin: 0 0 1em; }
a { color: var(--blue-deep); text-decoration: none; transition: color 0.2s var(--ease); }
a:hover { color: var(--blue); }
img, svg { max-width: 100%; }
ul, ol { margin: 0 0 1em; padding-inline-start: 1.2em; }
li { margin-bottom: 0.35em; }
button { font: inherit; }
:focus-visible { outline: 3px solid var(--blue); outline-offset: 2px; border-radius: 6px; }

.wrap { width: 100%; max-width: 1220px; margin: 0 auto; padding: 0 20px; }
.wrap-wide { max-width: 1400px; }

.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;
}

.skip-link {
  position: absolute; inset-inline-start: 12px; top: -60px; z-index: 999;
  background: var(--navy); color: #fff; padding: 10px 18px; border-radius: 0 0 12px 12px;
  transition: top 0.2s var(--ease);
}
.skip-link:focus { top: 0; color: #fff; }

/* -------------------------------- الأيقونات -------------------------------- */
.ico { width: 20px; height: 20px; flex: 0 0 auto; display: block; }
.ico-sm { width: 16px; height: 16px; }
.ico-lg { width: 26px; height: 26px; }
.ico-xl { width: 34px; height: 34px; }
.cat-ico { width: 30px; height: 30px; }

/* --------------------------------- الأزرار --------------------------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  font-family: var(--font-head); font-weight: 700; font-size: 0.97rem;
  padding: 13px 24px; border-radius: 999px; border: 2px solid transparent;
  cursor: pointer; text-align: center; line-height: 1.2; white-space: nowrap;
  transition: transform 0.2s var(--ease), box-shadow 0.25s var(--ease),
    background-color 0.25s var(--ease), color 0.25s var(--ease), border-color 0.25s var(--ease);
  background: var(--slate-100); color: var(--ink);
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }
.btn-primary { background: linear-gradient(135deg, var(--blue) 0%, var(--blue-deep) 100%); color: #fff; box-shadow: 0 10px 24px rgba(2, 132, 199, 0.3); }
.btn-primary:hover { color: #fff; box-shadow: 0 16px 34px rgba(2, 132, 199, 0.38); }
.btn-navy { background: var(--navy); color: #fff; box-shadow: var(--shadow-sm); }
.btn-navy:hover { color: #fff; background: var(--navy-2); }
.btn-green { background: linear-gradient(135deg, #10b981 0%, #059669 100%); color: #fff; box-shadow: 0 10px 24px rgba(16, 185, 129, 0.28); }
.btn-green:hover { color: #fff; }
.btn-gold { background: linear-gradient(135deg, #d9b13a 0%, #b98d16 100%); color: #2b2205; box-shadow: 0 10px 24px rgba(201, 162, 39, 0.3); }
.btn-gold:hover { color: #2b2205; }
.btn-outline { background: transparent; border-color: var(--line-strong); color: var(--ink); }
.btn-outline:hover { border-color: var(--blue); color: var(--blue-deep); background: var(--bg-sky); }
.btn-ghost { background: rgba(255, 255, 255, 0.12); color: #fff; border-color: rgba(255, 255, 255, 0.35); backdrop-filter: blur(6px); }
.btn-ghost:hover { color: #fff; background: rgba(255, 255, 255, 0.22); }
.btn-sm { padding: 9px 16px; font-size: 0.88rem; }
.btn-lg { padding: 16px 32px; font-size: 1.06rem; }
.btn-block { width: 100%; }
.btn-icon { padding: 11px; border-radius: 50%; }

.btn-row { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }

/* -------------------------------- شارات ----------------------------------- */
.badge {
  display: inline-flex; align-items: center; gap: 6px;
  font-family: var(--font-head); font-weight: 700; font-size: 0.76rem;
  padding: 5px 12px; border-radius: 999px; line-height: 1.5;
  background: var(--bg-sky); color: var(--blue-ink); border: 1px solid var(--line-strong);
}
.badge-gold { background: #fdf6e0; color: #8a6d10; border-color: #f0d982; }
.badge-green { background: #e8f9f2; color: #06654a; border-color: #b6ebd6; }
.badge-rose { background: #fdeef1; color: #a3203a; border-color: #f7ccd5; }
.badge-navy { background: #e7eef5; color: var(--navy); border-color: #cfdeeb; }
.badge-solid { background: var(--blue-deep); color: #fff; border-color: transparent; }

/* ------------------------------- الهيدر ----------------------------------- */
.topbar {
  background: var(--navy); color: #cfe3f3; font-size: 0.86rem; padding: 8px 0;
}
.topbar .wrap { display: flex; flex-wrap: wrap; gap: 10px 22px; align-items: center; justify-content: space-between; }
.topbar a { color: #cfe3f3; }
.topbar a:hover { color: #fff; }
.topbar-list { display: flex; flex-wrap: wrap; gap: 10px 20px; align-items: center; margin: 0; padding: 0; list-style: none; }
.topbar-list li { display: flex; align-items: center; gap: 7px; margin: 0; }
.topbar .ico { width: 15px; height: 15px; color: var(--gold-soft); }
.topbar-domain { display: inline-flex; align-items: center; gap: 7px; font-weight: 700; color: #fff; }
.topbar-domain .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.25); }

.site-header {
  position: sticky; top: 0; z-index: 120; background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(12px); border-bottom: 1px solid var(--line);
  transition: box-shadow 0.3s var(--ease);
}
.site-header.is-stuck { box-shadow: 0 8px 26px rgba(11, 59, 99, 0.09); }
.header-inner { display: flex; align-items: center; gap: 20px; min-height: var(--header-h); }

.brand { display: flex; align-items: center; gap: 12px; flex: 0 0 auto; }
.brand img { height: 52px; width: auto; border-radius: 10px; background: #fff; box-shadow: var(--shadow-xs); }
.brand-text { display: flex; flex-direction: column; line-height: 1.25; }
.brand-name { font-family: var(--font-head); font-weight: 900; font-size: 1.16rem; color: var(--navy); }
.brand-name .accent { color: var(--gold); }
.brand-sub { font-size: 0.72rem; color: var(--muted); font-weight: 500; }

.nav { margin-inline-start: auto; }
.nav-list { display: flex; align-items: center; gap: 4px; list-style: none; margin: 0; padding: 0; }
.nav-list li { margin: 0; }
.nav-link {
  display: block; padding: 10px 15px; border-radius: 999px; font-family: var(--font-head);
  font-weight: 700; font-size: 0.95rem; color: var(--slate-700); position: relative;
}
.nav-link:hover { background: var(--bg-sky); color: var(--blue-deep); }
.nav-link.is-active { color: var(--blue-deep); background: var(--bg-sky); }
.nav-link.is-active::after {
  content: ''; position: absolute; inset-inline: 22%; bottom: 3px; height: 3px;
  border-radius: 3px; background: var(--gold);
}
.header-actions { display: flex; align-items: center; gap: 10px; }
.burger {
  display: none; width: 46px; height: 46px; border-radius: 14px; border: 1px solid var(--line-strong);
  background: #fff; color: var(--navy); align-items: center; justify-content: center; cursor: pointer;
}

/* القائمة على الجوال */
.mobile-nav {
  position: fixed; inset: 0; z-index: 200; background: rgba(11, 59, 99, 0.5);
  opacity: 0; visibility: hidden; transition: opacity 0.3s var(--ease), visibility 0.3s;
}
.mobile-nav.is-open { opacity: 1; visibility: visible; }
.mobile-panel {
  position: absolute; inset-block: 0; inset-inline-end: 0; width: min(340px, 88vw);
  background: #fff; padding: 22px; overflow-y: auto; transform: translateX(-100%);
  transition: transform 0.35s var(--ease); display: flex; flex-direction: column; gap: 6px;
}
[dir='rtl'] .mobile-panel { transform: translateX(100%); }
.mobile-nav.is-open .mobile-panel { transform: translateX(0); }
.mobile-panel .nav-link { padding: 14px 16px; border-radius: 14px; font-size: 1.05rem; }
.mobile-panel .close-row { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; }
.mobile-contact { margin-top: auto; padding-top: 18px; border-top: 1px solid var(--line); display: grid; gap: 10px; font-size: 0.9rem; }

/* ------------------------------- الأقسام ---------------------------------- */
.section { padding: clamp(52px, 7vw, 92px) 0; }
.section-alt { background: var(--bg-alt); }
.section-sky { background: linear-gradient(180deg, #f4faff 0%, #eaf4fc 100%); }
.section-navy { background: linear-gradient(140deg, var(--navy) 0%, #061f37 100%); color: #cfe3f3; }
.section-navy h2, .section-navy h3 { color: #fff; }

.sec-head { max-width: 760px; margin-bottom: 42px; }
.sec-head.center { margin-inline: auto; text-align: center; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px; font-family: var(--font-head);
  font-weight: 800; font-size: 0.8rem; letter-spacing: 0.06em; color: var(--blue-deep);
  background: var(--bg-sky); border: 1px solid var(--line-strong); padding: 6px 14px;
  border-radius: 999px; margin-bottom: 16px;
}
.section-navy .eyebrow { background: rgba(255, 255, 255, 0.1); color: #fff; border-color: rgba(255, 255, 255, 0.22); }
.sec-title { margin-bottom: 14px; }
.sec-sub { font-size: 1.06rem; color: var(--muted); margin: 0; }
.section-navy .sec-sub { color: #a8c8e2; }

/* فاصل خط النبض */
.ecg-divider { height: 60px; display: block; width: 100%; overflow: hidden; }
.ecg-divider svg { width: 200%; height: 100%; }
.ecg-divider path {
  fill: none; stroke: var(--blue); stroke-width: 3; stroke-linejoin: round; stroke-linecap: round;
  stroke-dasharray: 1800; stroke-dashoffset: 1800;
  animation: ecg-draw 5s linear infinite;
}
.ecg-divider.is-soft path { stroke: var(--line-strong); }
@keyframes ecg-draw {
  0% { stroke-dashoffset: 1800; }
  70%, 100% { stroke-dashoffset: -1800; }
}

/* --------------------------------- الهيرو --------------------------------- */
.hero { position: relative; background: linear-gradient(150deg, var(--navy) 0%, #0a4a7a 55%, #0b6ea8 100%); color: #e6f2fb; overflow: hidden; }
.hero::before {
  content: ''; position: absolute; inset: 0;
  background-image: radial-gradient(circle at 82% 18%, rgba(255, 255, 255, 0.13) 0, transparent 42%),
    radial-gradient(circle at 8% 88%, rgba(16, 185, 129, 0.16) 0, transparent 38%);
  pointer-events: none;
}
.hero-grid { position: relative; display: grid; grid-template-columns: 1.08fr 0.92fr; gap: 44px; align-items: center; padding: clamp(40px, 6vw, 84px) 0; }
.hero-copy h1 { color: #fff; margin-bottom: 18px; }
.hero-copy h1 .hl { color: var(--gold-soft); display: block; }
.hero-lead { font-size: 1.12rem; color: #b9d8ef; max-width: 60ch; margin-bottom: 26px; }
.hero-badges { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 28px; }
.hero-badges .badge { background: rgba(255, 255, 255, 0.1); color: #e6f2fb; border-color: rgba(255, 255, 255, 0.24); }
.hero-note { display: flex; flex-wrap: wrap; gap: 8px 24px; margin-top: 26px; font-size: 0.9rem; color: #9dc4e0; }
.hero-note span { display: inline-flex; align-items: center; gap: 8px; }
.hero-note .ico { color: var(--gold-soft); width: 17px; height: 17px; }

/* السلايدر */
.slider { position: relative; background: rgba(255, 255, 255, 0.07); border: 1px solid rgba(255, 255, 255, 0.16); border-radius: var(--radius-lg); padding: 16px; backdrop-filter: blur(8px); }
.slides { position: relative; min-height: 396px; }
.slide {
  position: absolute; inset: 0; opacity: 0; visibility: hidden; transform: translateY(14px);
  transition: opacity 0.6s var(--ease), transform 0.6s var(--ease), visibility 0.6s;
  display: flex; flex-direction: column;
}
.slide.is-active { opacity: 1; visibility: visible; transform: none; position: relative; }
.slide-media { background: #fff; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.slide-media svg { display: block; width: 100%; height: auto; }
.slide-body { padding: 18px 6px 0; }
.slide-body h3 { color: #fff; font-size: 1.32rem; margin-bottom: 8px; }
.slide-body p { color: #b9d8ef; font-size: 0.98rem; margin-bottom: 12px; }
.slide-body .badge { background: rgba(255, 255, 255, 0.12); color: #fff; border-color: rgba(255, 255, 255, 0.24); }
.slider-bar { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-top: 16px; }
.dots { display: flex; gap: 8px; }
.dot { width: 11px; height: 11px; border-radius: 50%; border: 0; padding: 0; cursor: pointer; background: rgba(255, 255, 255, 0.32); transition: all 0.25s var(--ease); }
.dot.is-active { background: var(--gold-soft); width: 30px; border-radius: 999px; }
.slider-arrows { display: flex; gap: 8px; }
.slider-arrows button {
  width: 42px; height: 42px; border-radius: 50%; border: 1px solid rgba(255, 255, 255, 0.3);
  background: rgba(255, 255, 255, 0.1); color: #fff; cursor: pointer; display: grid; place-items: center;
  transition: all 0.2s var(--ease);
}
.slider-arrows button:hover { background: rgba(255, 255, 255, 0.24); }

/* شريط الثقة */
.trust-strip { background: #fff; border-bottom: 1px solid var(--line); }
.trust-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; }
.trust-card { padding: 30px 26px; border-inline-start: 1px solid var(--line); display: flex; gap: 14px; }
.trust-card:first-child { border-inline-start: 0; }
.trust-ico {
  width: 50px; height: 50px; border-radius: 16px; display: grid; place-items: center; flex: 0 0 auto;
  background: var(--bg-sky); color: var(--blue-deep);
}
.trust-card h4 { margin-bottom: 4px; font-size: 1rem; }
.trust-card p { margin: 0; font-size: 0.88rem; color: var(--muted); line-height: 1.7; }

/* الإحصائيات */
.stats-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.stat {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 24px 20px;
  text-align: center; box-shadow: var(--shadow-xs);
}
.stat b { display: block; font-family: var(--font-head); font-size: 2.1rem; font-weight: 900; color: var(--blue-deep); line-height: 1.2; }
.stat span { font-size: 0.9rem; color: var(--muted); }

/* --------------------------------- شبكات ---------------------------------- */
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 26px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; }

/* عن الشركة */
.about-grid { display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 48px; align-items: start; }
.about-media { position: relative; }
.about-frame {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 26px;
  box-shadow: var(--shadow); text-align: center;
}
.about-frame img { height: 130px; width: auto; margin-inline: auto; }
.about-frame .motto { font-family: var(--font-head); font-weight: 800; color: var(--navy); margin-top: 12px; }
.about-frame .en { font-size: 0.82rem; color: var(--muted); letter-spacing: 0.02em; }
.about-float {
  margin-top: -34px; margin-inline-start: 24px; background: var(--navy); color: #dbeaf6;
  border-radius: var(--radius); padding: 18px 20px; box-shadow: var(--shadow-lg); max-width: 320px;
}
.about-float b { color: #fff; display: block; font-family: var(--font-head); }

.check-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; }
.check-list li { display: flex; gap: 12px; align-items: flex-start; margin: 0; font-size: 0.98rem; }
.check-list .tick {
  width: 24px; height: 24px; border-radius: 50%; background: #e8f9f2; color: var(--green-deep);
  display: grid; place-items: center; flex: 0 0 auto; margin-top: 5px;
}
.check-list .tick .ico { width: 14px; height: 14px; stroke-width: 2.4; }

.legal-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-top: 34px; }
.legal-card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 20px;
  box-shadow: var(--shadow-xs); border-top: 4px solid var(--gold);
}
.legal-card .lc-top { display: flex; align-items: center; gap: 10px; color: var(--blue-deep); margin-bottom: 10px; }
.legal-card .lc-label { font-size: 0.82rem; color: var(--muted); font-family: var(--font-head); font-weight: 700; }
.legal-card .lc-value { font-family: var(--font-head); font-weight: 900; font-size: 1.06rem; color: var(--ink); direction: ltr; text-align: right; word-break: break-word; }
.legal-card .lc-note { font-size: 0.78rem; color: var(--muted); margin-top: 6px; line-height: 1.6; }

/* -------------------------- شبكة الأقسام الطبية ---------------------------- */
.cats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.cat-card {
  position: relative; background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 24px 22px 22px; overflow: hidden; box-shadow: var(--shadow-xs);
  transition: transform 0.28s var(--ease), box-shadow 0.28s var(--ease), border-color 0.28s var(--ease);
  display: flex; flex-direction: column; gap: 10px; min-height: 210px;
}
.cat-card::before {
  content: ''; position: absolute; inset-inline: 0; top: 0; height: 5px;
  background: var(--accent, var(--blue)); transform: scaleX(0.35); transform-origin: right;
  transition: transform 0.35s var(--ease);
}
.cat-card:hover { transform: translateY(-6px); box-shadow: var(--shadow); border-color: var(--line-strong); }
.cat-card:hover::before { transform: scaleX(1); }
.cat-card .cat-ico-wrap {
  width: 56px; height: 56px; border-radius: 18px; display: grid; place-items: center;
  background: color-mix(in srgb, var(--accent, var(--blue)) 12%, #fff);
  color: var(--accent, var(--blue));
}
.cat-card h3 { margin: 0; font-size: 1.1rem; }
.cat-card .cat-en { font-size: 0.76rem; color: var(--muted); letter-spacing: 0.02em; direction: ltr; text-align: right; margin-top: -6px; }
.cat-card p { font-size: 0.9rem; color: var(--muted); margin: 0; flex: 1; }
.cat-card .cat-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding-top: 12px; border-top: 1px dashed var(--line-strong); }
.cat-card .cat-count { font-family: var(--font-head); font-weight: 800; font-size: 0.84rem; color: var(--blue-deep); }
.cat-card .cat-more { display: inline-flex; align-items: center; gap: 6px; font-family: var(--font-head); font-weight: 700; font-size: 0.85rem; color: var(--slate-600); }
.cat-card:hover .cat-more { color: var(--blue-deep); }

/* شبكة غير متمركزة على الشاشات الكبيرة */
@media (min-width: 1024px) {
  .cats-grid { grid-template-columns: repeat(6, 1fr); }
  .cat-card { grid-column: span 2; }
  .cat-card:nth-child(1) { grid-column: span 3; }
  .cat-card:nth-child(2) { grid-column: span 3; }
  .cat-card:nth-child(7) { grid-column: span 6; }
  .cat-card:nth-child(7) { flex-direction: row; align-items: center; gap: 22px; min-height: 0; }
  .cat-card:nth-child(7) p { flex: 1; }
  .cat-card:nth-child(7) .cat-foot { border: 0; padding: 0; flex: 0 0 auto; }
}

/* ------------------------------- الفلاتر ---------------------------------- */
.filter-bar {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 18px; box-shadow: var(--shadow-xs); display: grid; gap: 16px;
}
.filter-row { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.filter-row .search-wrap { position: relative; flex: 1 1 260px; min-width: 220px; }
.filter-row .search-wrap .ico { position: absolute; inset-inline-start: 14px; top: 50%; transform: translateY(-50%); color: var(--slate-400); pointer-events: none; }
.filter-row .search-wrap input { padding-inline-start: 44px; }
.filter-row .select-wrap { flex: 0 1 210px; min-width: 165px; }

.chips { display: flex; flex-wrap: wrap; gap: 9px; }
.chip {
  font-family: var(--font-head); font-weight: 700; font-size: 0.86rem; padding: 9px 16px;
  border-radius: 999px; border: 1px solid var(--line-strong); background: #fff; color: var(--slate-600);
  cursor: pointer; transition: all 0.22s var(--ease); display: inline-flex; align-items: center; gap: 7px;
}
.chip:hover { border-color: var(--blue); color: var(--blue-deep); }
.chip.is-active { background: var(--blue-deep); border-color: var(--blue-deep); color: #fff; box-shadow: 0 6px 16px rgba(3, 105, 161, 0.26); }
.chip .count { background: rgba(255, 255, 255, 0.24); border-radius: 999px; padding: 0 7px; font-size: 0.76rem; }
.chip:not(.is-active) .count { background: var(--slate-100); color: var(--muted); }

.results-bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin: 22px 0 18px; }
.results-count { font-family: var(--font-head); font-weight: 800; color: var(--ink); }
.results-count b { color: var(--blue-deep); }
.link-btn { background: none; border: 0; color: var(--blue-deep); font-family: var(--font-head); font-weight: 700; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; padding: 6px; }
.link-btn:hover { color: var(--blue); text-decoration: underline; }

/* ------------------------------ بطاقة المنتج ------------------------------- */
.products-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; }
.p-card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden;
  display: flex; flex-direction: column; box-shadow: var(--shadow-xs);
  transition: transform 0.28s var(--ease), box-shadow 0.28s var(--ease);
}
.p-card:hover { transform: translateY(-6px); box-shadow: var(--shadow); }
.p-media { position: relative; background: #eef6fc; border-bottom: 1px solid var(--line); }
.p-media svg { display: block; width: 100%; height: auto; }
.p-media .p-badge { position: absolute; top: 12px; inset-inline-start: 12px; }
.p-media .p-cat {
  position: absolute; top: 12px; inset-inline-end: 12px; background: rgba(255, 255, 255, 0.94);
  border: 1px solid var(--line-strong); border-radius: 999px; padding: 4px 11px;
  font-size: 0.74rem; font-family: var(--font-head); font-weight: 700; color: var(--blue-deep);
}
.p-body { padding: 18px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.p-model { font-size: 0.76rem; color: var(--muted); direction: ltr; text-align: right; letter-spacing: 0.03em; }
.p-title { font-family: var(--font-head); font-weight: 800; font-size: 1.04rem; color: var(--ink); margin: 0; line-height: 1.5; }
.p-desc { font-size: 0.88rem; color: var(--muted); margin: 0; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.p-meta { display: flex; flex-wrap: wrap; gap: 8px; }
.p-meta .badge { font-size: 0.72rem; padding: 4px 10px; }
.p-foot { margin-top: auto; padding-top: 14px; border-top: 1px dashed var(--line-strong); display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.p-price { font-family: var(--font-head); font-weight: 900; color: var(--blue-deep); font-size: 1rem; }
.p-price small { display: block; font-size: 0.68rem; color: var(--muted); font-weight: 500; }
.p-actions { display: flex; gap: 8px; }

/* حالة عدم وجود نتائج */
.empty {
  text-align: center; padding: 64px 24px; background: #fff; border: 1px dashed var(--line-strong);
  border-radius: var(--radius-lg); color: var(--muted);
}
.empty .empty-ico { width: 74px; height: 74px; margin: 0 auto 16px; border-radius: 50%; display: grid; place-items: center; background: var(--bg-sky); color: var(--blue-deep); }
.empty h3 { color: var(--ink); }
.empty p { max-width: 46ch; margin-inline: auto; }

/* -------------------------------- النماذج --------------------------------- */
.form-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; }
.form-grid .span-2 { grid-column: 1 / -1; }
.field { display: flex; flex-direction: column; gap: 7px; }
.field > label { font-family: var(--font-head); font-weight: 700; font-size: 0.9rem; color: var(--ink); }
.field .hint { font-size: 0.78rem; color: var(--muted); }
.req { color: var(--rose); }

.input, .select, .textarea {
  width: 100%; font-family: var(--font-body); font-size: 0.98rem; color: var(--ink);
  background: #fff; border: 1.5px solid var(--line-strong); border-radius: var(--radius-sm);
  padding: 12px 15px; transition: border-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
  appearance: none;
}
.textarea { min-height: 120px; resize: vertical; line-height: 1.7; }
.select {
  background-image: linear-gradient(45deg, transparent 50%, var(--slate-500) 50%), linear-gradient(135deg, var(--slate-500) 50%, transparent 50%);
  background-position: calc(18px) calc(50% + 2px), calc(23px) calc(50% + 2px);
  background-size: 5px 5px, 5px 5px; background-repeat: no-repeat;
  padding-inline-end: 42px;
}
.input:focus, .select:focus, .textarea:focus { outline: 0; border-color: var(--blue); box-shadow: var(--ring); }
.input::placeholder, .textarea::placeholder { color: var(--slate-400); }
.input[readonly] { background: var(--slate-100); color: var(--slate-600); }
.field-error { color: var(--rose); font-size: 0.8rem; min-height: 0; }
.input.has-error, .textarea.has-error, .select.has-error { border-color: var(--rose); box-shadow: 0 0 0 4px rgba(228, 72, 94, 0.12); }

.check-row { display: flex; align-items: flex-start; gap: 10px; font-size: 0.92rem; }
.check-row input { width: 19px; height: 19px; accent-color: var(--blue); margin-top: 4px; flex: 0 0 auto; }

/* ---------------------------------- البطاقات ------------------------------- */
.card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow-xs); }
.card-soft { background: var(--bg-alt); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }

/* --------------------------------- الجدول --------------------------------- */
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
table.data { width: 100%; border-collapse: collapse; min-width: 480px; }
table.data th, table.data td { padding: 14px 18px; text-align: right; border-bottom: 1px solid var(--line); font-size: 0.94rem; }
table.data th {
  background: var(--bg-alt); font-family: var(--font-head); font-weight: 800; color: var(--ink);
  font-size: 0.88rem; position: sticky; top: 0;
}
table.data tbody tr:last-child td { border-bottom: 0; }
table.data tbody tr:nth-child(even) { background: #fbfdff; }
table.data td:first-child { font-family: var(--font-head); font-weight: 700; color: var(--ink); }

/* ------------------------------- عنوان الصفحة ------------------------------ */
.page-head { position: relative; background: linear-gradient(135deg, var(--navy) 0%, #0a4a7a 100%); color: #d8ecfa; padding: clamp(38px, 5vw, 64px) 0; overflow: hidden; }
.page-head::after {
  content: ''; position: absolute; inset-inline-start: -60px; top: -60px; width: 320px; height: 320px;
  border-radius: 50%; background: rgba(255, 255, 255, 0.05);
}
.page-head h1 { color: #fff; margin-bottom: 10px; }
.page-head p { color: #a9cbe6; max-width: 68ch; margin: 0; }
.breadcrumb { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; font-size: 0.86rem; color: #9dc4e0; margin-bottom: 14px; padding: 0; list-style: none; }
.breadcrumb li { margin: 0; }
.breadcrumb a { color: #cfe3f3; }
.breadcrumb a:hover { color: #fff; }
.breadcrumb .sep { opacity: 0.6; }

/* --------------------------------- المودال -------------------------------- */
.modal {
  position: fixed; inset: 0; z-index: 300; display: flex; align-items: flex-start; justify-content: center;
  padding: 24px 16px; background: rgba(9, 42, 71, 0.62); backdrop-filter: blur(4px);
  opacity: 0; visibility: hidden; transition: opacity 0.28s var(--ease), visibility 0.28s; overflow-y: auto;
}
.modal.is-open { opacity: 1; visibility: visible; }
.modal-card {
  background: #fff; border-radius: var(--radius-lg); width: min(980px, 100%); margin: auto;
  box-shadow: var(--shadow-lg); transform: translateY(20px) scale(0.98);
  transition: transform 0.32s var(--ease); overflow: hidden;
}
.modal.is-open .modal-card { transform: none; }
.modal-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; padding: 22px 26px; border-bottom: 1px solid var(--line); }
.modal-head h3 { margin: 0; }
.modal-close { border: 1px solid var(--line-strong); background: #fff; width: 42px; height: 42px; border-radius: 50%; cursor: pointer; display: grid; place-items: center; color: var(--slate-600); flex: 0 0 auto; }
.modal-close:hover { background: var(--slate-100); color: var(--ink); }
.modal-body { padding: 26px; }
.modal-foot { padding: 20px 26px; border-top: 1px solid var(--line); background: var(--bg-alt); display: flex; flex-wrap: wrap; gap: 12px; justify-content: flex-end; }
body.no-scroll { overflow: hidden; }

/* تفاصيل المنتج */
.pd-grid { display: grid; grid-template-columns: 1fr 1.15fr; gap: 28px; align-items: start; }
.pd-media { background: #eef6fc; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.pd-media svg { display: block; width: 100%; height: auto; }
.pd-thumbs { display: flex; gap: 10px; margin-top: 12px; }
.pd-info h2 { margin-bottom: 6px; }
.pd-en { color: var(--muted); font-size: 0.92rem; direction: ltr; text-align: right; margin-bottom: 14px; }
.pd-meta { display: flex; flex-wrap: wrap; gap: 9px; margin-bottom: 18px; }
.pd-price-box { background: var(--bg-alt); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; margin-bottom: 18px; }
.pd-price-box .val { font-family: var(--font-head); font-weight: 900; font-size: 1.5rem; color: var(--blue-deep); }
.pd-price-box .note { font-size: 0.8rem; color: var(--muted); }
.pd-block { margin-top: 26px; }
.pd-block h4 { display: flex; align-items: center; gap: 9px; margin-bottom: 12px; }
.pd-block h4 .ico { color: var(--blue-deep); }

/* ------------------------------ طلب عرض السعر ------------------------------ */
.quote-grid { display: grid; grid-template-columns: 1.15fr 0.85fr; gap: 30px; align-items: start; }
.quote-summary { position: sticky; top: calc(var(--header-h) + 18px); }
.q-items { display: grid; gap: 10px; max-height: 340px; overflow-y: auto; padding-inline-end: 4px; }
.q-row {
  display: grid; grid-template-columns: 1fr auto auto; gap: 10px; align-items: center;
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 12px 14px;
}
.q-row .q-name { font-family: var(--font-head); font-weight: 700; font-size: 0.92rem; color: var(--ink); }
.q-row .q-name small { display: block; font-weight: 500; color: var(--muted); font-size: 0.76rem; direction: ltr; text-align: right; }
.qty { display: inline-flex; align-items: center; gap: 6px; }
.qty button { width: 30px; height: 30px; border-radius: 8px; border: 1px solid var(--line-strong); background: #fff; cursor: pointer; display: grid; place-items: center; color: var(--slate-600); }
.qty button:hover { border-color: var(--blue); color: var(--blue-deep); }
.qty input { width: 52px; text-align: center; padding: 6px; border: 1.5px solid var(--line-strong); border-radius: 8px; font-family: var(--font-head); font-weight: 700; }
.q-remove { background: none; border: 0; color: var(--slate-400); cursor: pointer; padding: 6px; }
.q-remove:hover { color: var(--rose); }
.q-total { display: flex; align-items: center; justify-content: space-between; padding: 16px 0 0; margin-top: 14px; border-top: 1px solid var(--line); }
.q-total b { font-family: var(--font-head); font-size: 1.2rem; color: var(--blue-deep); }
.q-empty { text-align: center; color: var(--muted); padding: 26px 10px; font-size: 0.92rem; }
.q-actions { display: grid; gap: 10px; margin-top: 18px; }
.q-note { font-size: 0.82rem; color: var(--muted); background: var(--bg-sky); border: 1px solid var(--line-strong); border-radius: var(--radius-sm); padding: 12px 14px; margin-top: 16px; }
.preview-box {
  background: #0f2b3d; color: #cfe9f8; border-radius: var(--radius); padding: 18px; font-size: 0.86rem;
  white-space: pre-wrap; line-height: 1.9; max-height: 300px; overflow: auto; font-family: var(--font-body);
}

/* --------------------------------- الفوتر --------------------------------- */
.site-footer { background: linear-gradient(160deg, var(--navy) 0%, #061f37 100%); color: #a9cbe6; padding: 58px 0 0; margin-top: 0; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: 34px; }
.site-footer h4 { color: #fff; font-size: 1.02rem; margin-bottom: 16px; }
.site-footer a { color: #a9cbe6; }
.site-footer a:hover { color: #fff; }
.footer-brand { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
.footer-brand img { height: 54px; width: auto; border-radius: 10px; background: #fff; padding: 3px; }
.footer-brand .fn { font-family: var(--font-head); font-weight: 900; color: #fff; font-size: 1.1rem; }
.footer-brand .fs { font-size: 0.72rem; color: #7fa8c8; }
.footer-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 9px; font-size: 0.9rem; }
.footer-list li { margin: 0; display: flex; gap: 9px; align-items: flex-start; }
.footer-list .ico { color: var(--gold-soft); width: 17px; height: 17px; margin-top: 5px; }
.footer-bottom {
  margin-top: 42px; border-top: 1px solid rgba(255, 255, 255, 0.12); padding: 20px 0;
  display: flex; flex-wrap: wrap; gap: 12px; align-items: center; justify-content: space-between; font-size: 0.84rem;
}
.footer-bottom .legal-ids { display: flex; flex-wrap: wrap; gap: 8px 18px; direction: ltr; }

/* --------------------------- الأزرار العائمة للجوال ------------------------ */
.fab {
  position: fixed; inset-inline-start: 16px; bottom: 18px; z-index: 150; display: flex; flex-direction: column; gap: 10px;
}
.fab a {
  width: 54px; height: 54px; border-radius: 50%; display: grid; place-items: center; color: #fff;
  box-shadow: var(--shadow-lg); transition: transform 0.25s var(--ease);
}
.fab a:hover { transform: scale(1.08); color: #fff; }
.fab .fab-wa { background: #25d366; }
.fab .fab-tel { background: var(--blue-deep); }
.fab .fab-top { background: var(--navy); opacity: 0; visibility: hidden; }
.fab .fab-top.is-visible { opacity: 1; visibility: visible; }
.fab .ico { width: 25px; height: 25px; }

/* --------------------------------- التنبيهات ------------------------------- */
.toast-wrap { position: fixed; inset-inline: 0; bottom: 24px; z-index: 400; display: flex; flex-direction: column; align-items: center; gap: 10px; pointer-events: none; }
.toast {
  background: var(--navy); color: #fff; border-radius: 999px; padding: 13px 24px; font-family: var(--font-head);
  font-weight: 700; font-size: 0.92rem; box-shadow: var(--shadow-lg); display: flex; align-items: center; gap: 10px;
  animation: toast-in 0.35s var(--ease);
}
.toast.is-ok { background: var(--green-deep); }
.toast.is-warn { background: #b45309; }
.toast.is-err { background: #b91c1c; }
@keyframes toast-in { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }

/* --------------------------------- الحركات -------------------------------- */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity 0.7s var(--ease), transform 0.7s var(--ease); }
.reveal.is-in { opacity: 1; transform: none; }
.reveal[data-delay='1'] { transition-delay: 0.08s; }
.reveal[data-delay='2'] { transition-delay: 0.16s; }
.reveal[data-delay='3'] { transition-delay: 0.24s; }
.reveal[data-delay='4'] { transition-delay: 0.32s; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; }
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; }
}

/* ------------------------------- الاستجابة -------------------------------- */
@media (max-width: 1100px) {
  .hero-grid { grid-template-columns: 1fr; gap: 34px; }
  .products-grid { grid-template-columns: repeat(3, 1fr); }
  .cats-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: repeat(2, 1fr); }
  .about-grid, .quote-grid, .pd-grid { grid-template-columns: 1fr; }
  .quote-summary { position: static; }
  .trust-grid { grid-template-columns: repeat(2, 1fr); }
  .trust-card:nth-child(3) { border-inline-start: 0; }
  .trust-card { border-top: 1px solid var(--line); }
  .trust-card:nth-child(-n + 2) { border-top: 0; }
}

@media (max-width: 980px) {
  .nav { display: none; }
  .burger { display: inline-flex; }
  .legal-grid { grid-template-columns: repeat(2, 1fr); }
  .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 720px) {
  :root { --header-h: 66px; }
  body { font-size: 1rem; line-height: 1.8; }
  .brand img { height: 44px; }
  .brand-sub { display: none; }
  .products-grid { grid-template-columns: repeat(2, 1fr); gap: 14px; }
  .p-body { padding: 14px; }
  .p-title { font-size: 0.95rem; }
  .p-desc { display: none; }
  .cats-grid { grid-template-columns: 1fr; }
  .stats-row { grid-template-columns: repeat(2, 1fr); }
  .form-grid { grid-template-columns: 1fr; }
  .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .topbar-list.topbar-hide-sm { display: none; }
  .topbar .wrap { justify-content: center; }
  .slider { padding: 12px; }
  .slides { min-height: 320px; }
  .modal-body, .modal-head, .modal-foot { padding: 18px; }
  .table-wrap { border-radius: var(--radius-sm); }
  table.data thead { display: none; }
  table.data, table.data tbody, table.data tr, table.data td { display: block; width: 100%; }
  table.data tr { border-bottom: 1px solid var(--line); padding: 10px 0; }
  table.data td { border: 0; padding: 7px 16px; display: flex; justify-content: space-between; gap: 14px; }
  table.data td::before { content: attr(data-label); font-family: var(--font-head); font-weight: 700; color: var(--muted); font-size: 0.82rem; }
  table.data td:first-child { font-size: 1rem; }
  .q-row { grid-template-columns: 1fr; gap: 8px; }
  .q-row .qty { justify-self: start; }
  .fab { inset-inline-start: 12px; bottom: 12px; }
  .fab a { width: 50px; height: 50px; }
}

@media (max-width: 420px) {
  .products-grid { grid-template-columns: 1fr; }
  .btn { padding: 12px 20px; font-size: 0.92rem; }
  .hero-copy h1 { font-size: 1.75rem; }
}

/* --------------------------------- الطباعة -------------------------------- */
@media print {
  .site-header, .topbar, .site-footer, .fab, .mobile-nav, .toast-wrap, .no-print,
  .slider-arrows, .dots, .filter-bar { display: none !important; }
  body { background: #fff; color: #000; font-size: 11pt; }
  .section { padding: 12px 0; }
  .card, .p-card, .modal-card { box-shadow: none; border-color: #cbd5e1; }
  a { color: #000; text-decoration: none; }
  .print-only { display: block !important; }
}
.print-only { display: none; }

/* ==========================================================================
   ملحقات: صفحات الأقسام، أوراق الطباعة، وكتالوج PDF
   ========================================================================== */

.cats-detail { display: grid; gap: 28px; }
.cat-detail-head { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; margin-bottom: 18px; }
.cat-detail-head .cat-ico-wrap {
  width: 62px; height: 62px; border-radius: 20px; display: grid; place-items: center; flex: 0 0 auto;
  background: color-mix(in srgb, var(--accent, var(--blue)) 12%, #fff);
  color: var(--accent, var(--blue));
}
.cat-detail-head .cat-en { font-size: 0.8rem; color: var(--muted); letter-spacing: 0.02em; }

.products-grid-sm { grid-template-columns: repeat(2, 1fr); gap: 16px; }
.products-grid-sm .p-media { border-bottom: 1px solid var(--line); }
.products-grid-sm .p-desc { display: none; }

/* ملخّص مصغّر للمنتج داخل صفحة الأقسام */
@media (max-width: 720px) {
  .products-grid-sm { grid-template-columns: 1fr; }
}

/* ------------------------------- أوراق الطباعة ---------------------------- */

.print-sheet { display: none; }
.print-head {
  display: flex; align-items: center; gap: 18px; flex-wrap: wrap;
  border-bottom: 3px solid var(--navy); padding-bottom: 14px; margin-bottom: 20px;
}
.print-head img { height: 78px; width: auto; }
.print-head-info h1 { font-size: 1.05rem; margin: 0 0 4px; color: var(--navy); }
.print-head-info p { margin: 0; font-size: 0.82rem; color: var(--slate-600); }
.print-stamp {
  margin-inline-start: auto; text-align: center; border: 1.5px dashed var(--line-strong);
  border-radius: 12px; padding: 10px 16px; min-width: 150px;
}
.print-stamp strong { display: block; font-family: var(--font-head); color: var(--blue-deep); font-size: 0.9rem; }
.print-stamp span { font-size: 0.78rem; color: var(--muted); }
.print-title { text-align: center; font-size: 1.4rem; margin: 18px 0; }
.print-body {
  white-space: pre-wrap; font-family: var(--font-body); font-size: 0.92rem; line-height: 1.9;
  border: 1px solid var(--line); border-radius: 12px; padding: 18px; background: #fff;
}
.print-legal { margin-top: 16px; font-size: 0.78rem; color: var(--muted); text-align: center; }

.sheet {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 26px; margin-bottom: 26px; box-shadow: var(--shadow-xs); page-break-after: always;
}
.sheet:last-child { page-break-after: auto; }
.sheet-grid { display: grid; grid-template-columns: 0.85fr 1.15fr; gap: 24px; align-items: start; margin-bottom: 18px; }
.sheet-media { background: #eef6fc; border: 1px solid var(--line); border-radius: var(--radius-sm); overflow: hidden; }
.sheet-media svg { display: block; width: 100%; height: auto; }
.sheet h2 { margin-bottom: 4px; }
.sheet h3 {
  font-size: 1.02rem; margin: 22px 0 10px; padding-inline-start: 12px;
  border-inline-start: 4px solid var(--blue); color: var(--navy);
}
.sheet-en { color: var(--muted); font-size: 0.86rem; direction: ltr; text-align: right; margin-bottom: 10px; }
table.sheet-facts, table.sheet-specs { width: 100%; border-collapse: collapse; font-size: 0.88rem; }
table.sheet-facts th, table.sheet-specs th {
  text-align: right; background: var(--bg-alt); font-family: var(--font-head); font-weight: 700;
  color: var(--ink); width: 38%; border: 1px solid var(--line); padding: 9px 12px;
}
table.sheet-facts td, table.sheet-specs td { border: 1px solid var(--line); padding: 9px 12px; color: var(--body); }
.sheet-list { margin: 0; padding-inline-start: 1.2em; font-size: 0.9rem; }
.sheet-foot {
  display: flex; flex-wrap: wrap; gap: 10px; justify-content: space-between; margin-top: 20px;
  padding-top: 12px; border-top: 1px dashed var(--line-strong); font-size: 0.76rem; color: var(--muted);
}

@media print {
  body.printing > *:not(#printSheet) { display: none !important; }
  body.printing #printSheet { display: block !important; }
  #printRoot { margin: 0 !important; }
  .sheet { border: 0; box-shadow: none; padding: 0 0 18px; margin-bottom: 0; }
  .print-head { border-bottom-color: #000; }
  .print-body { border-color: #cbd5e1; }
  .sheet h3 { border-inline-start-color: #000; }
  table.sheet-facts th, table.sheet-specs th { background: #f1f5f9; }
  table.sheet-facts th, table.sheet-specs th,
  table.sheet-facts td, table.sheet-specs td { border-color: #cbd5e1; }
}

@media (max-width: 820px) {
  .sheet-grid { grid-template-columns: 1fr; }
}

/* ------------------------- خريطة الموقع التوضيحية -------------------------- */
.map-wrap { position: relative; }
.map-card {
  position: absolute; background: #fff; border: 1px solid var(--line-strong);
  border-radius: 14px; padding: 10px 14px; box-shadow: var(--shadow-sm); max-width: 62%;
}
.map-card strong { display: block; font-family: var(--font-head); color: var(--navy); font-size: 0.98rem; }
.map-card span { font-size: 0.8rem; color: var(--muted); }
.map-card-title { top: 12%; inset-inline-end: 4%; }
.map-card-domain { bottom: 8%; inset-inline-start: 4%; }
.map-card-domain span { display: block; }
.map-card-domain .map-card-label { font-family: var(--font-head); font-weight: 700; color: var(--navy); font-size: 0.82rem; }
.map-card-domain span[dir='ltr'] { color: var(--blue-deep); font-weight: 700; }

@media (max-width: 520px) {
  .map-card { max-width: 74%; padding: 8px 11px; }
  .map-card-title { top: 8%; }
}
/* ----------------------- صور المنتجات الحقيقية (محلية) ---------------------- */
.media-box { display: block; position: relative; }
.media-box img.media-photo {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  background: #eef6fc;
}
.media-box-hero img.media-photo { aspect-ratio: 16 / 9; }
.media-box .media-fallback { display: none; }
.media-box img.media-photo.is-missing { display: none; }
.media-box img.media-photo.is-missing + .media-fallback { display: block; }
.media-box img.media-photo.is-missing + .media-fallback svg { display: block; width: 100%; height: auto; }

@media print {
  .media-box img.media-photo { aspect-ratio: auto; max-height: 62mm; object-fit: contain; }
}