/* =========================================================
   Wajiz Company — public site
   ثيم فاتح: خلفيات أوف-وايت ومحايدة دافئة، بطاقات بيضاء وزجاجية، ولمسات البرونزي والذهبي من الشعار.
   كل الألوان والخطوط والمسافات متغيرات في :root — لا ألوان ثابتة داخل المكونات.
   كل الاتجاهات بخصائص منطقية (inline-start/end) لتعمل RTL و LTR.
   ========================================================= */

:root {
  /* الخلفيات */
  --bg: #FBF8F4;            /* خلفية الصفحة: أوف-وايت دافئ */
  --bg-alt: #F4EEE6;        /* أقسام متناوبة: محايد ناعم */
  --bg-deep: #EDE4D8;       /* التذييل والعناصر الأعمق */
  --surface: #FFFFFF;       /* البطاقات */
  --glass: rgba(255, 255, 255, .72);
  --glass-strong: rgba(255, 255, 255, .86);

  /* النص */
  --text: #1C1814;          /* العناوين */
  --text-2: #4A423A;        /* النص الأساسي — 9.6:1 على --bg */
  --text-3: #6E655C;        /* الثانوي — 5.6:1 على --bg */
  --line: #E6DCCF;
  --line-strong: #D8CBBA;

  /* هوية الشعار */
  --bronze: #be8451;
  --gold: #B8860B;
  --bronze-ink: #8A5A2B;    /* نص برونزي صغير بتباين كافٍ — 5.9:1 على --bg */
  --bronze-soft: rgba(190, 132, 81, .12);
  --bronze-line: rgba(190, 132, 81, .38);
  --accent-gradient: linear-gradient(90deg, var(--bronze), var(--gold));

  --success-ink: #2F6B1F;

  /* قيم RGB للشفافيات (تتبدل مع الثيم) */
  --bg-rgb: 251, 248, 244;
  --ink-rgb: 28, 24, 20;
  --accent-rgb: 190, 132, 81;
  --gold-rgb: 184, 134, 11;
  --on-accent: #1C1814;     /* النص فوق اللون الأساسي (الأزرار) */
  --accent-hover: var(--gold);
  --glass-border: rgba(255, 255, 255, .9);
  --quote-bg: linear-gradient(150deg, #E9CFAF, #D6AF7E);
  --success-soft: rgba(90, 150, 70, .14);
  --alert-bg: #EEF5EA;
  --alert-border: #C7DDBB;
  --alert-text: #2F4A22;
  --danger: #A8321F;

  /* الرسوم التوضيحية والخريطة (تُستخدم داخل SVG عبر var()) */
  --il-ground: #F1E8DC;
  --il-line: #E2D5C3;
  --il-detail: #C9B79F;
  --il-accent: var(--bronze);
  --il-muted: #9A9086;
  --il-leaf: #6E8B4A;
  --map-dots: #D8CBBA;
  --map-outline: #C9B79F;
  --map-hq: var(--bronze);
  --map-big: #8A5A2B;
  --map-small: #E2B98A;
  --map-on-hq: #1C1814;
  --map-on-big: #FFFFFF;
  --map-on-small: #1C1814;

  /* الطباعة: عائلة واحدة بأوزان مختلفة، وسلم أحجام موحد */
  --font: 'IBM Plex Sans Arabic', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --fs-xs: 13px;
  --fs-sm: 14px;
  --fs-base: 16px;
  --fs-md: 17px;
  --fs-lead: clamp(17px, 1.35vw, 19px);
  --fs-h3: clamp(20px, 1.8vw, 24px);
  --fs-h2: clamp(28px, 3.4vw, 44px);
  --fs-h1: clamp(32px, 4.4vw, 56px);
  --fs-display: clamp(34px, 5vw, 68px);
  --lh-tight: 1.3;          /* العربية تحتاج ارتفاع سطر أكبر من اللاتينية في العناوين */
  --lh-body: 1.8;

  /* الشكل */
  --radius-lg: 32px;
  --radius-md: 24px;
  --radius-sm: 18px;
  --shadow-sm: 0 1px 2px rgba(28, 24, 20, .04), 0 4px 14px -6px rgba(28, 24, 20, .08);
  --shadow-md: 0 2px 4px rgba(28, 24, 20, .04), 0 24px 48px -24px rgba(28, 24, 20, .18);
  --shadow-lg: 0 40px 80px -40px rgba(28, 24, 20, .28);
  --blur: saturate(160%) blur(20px);

  --container: 1240px;
  --gutter: 24px;
  --section: clamp(72px, 9vw, 120px);
  --header-h: 72px;
  --ease: cubic-bezier(.2, .7, .2, 1);

  /* لون القسم الذي يلي الواجهة (من نحن = --bg-alt)؛ تُحسب هنا فتبقى قيمة الصفحة داخل الأقسام الداكنة */
  --hx-fade-to: var(--bg-alt);
}

/* =========================================================
   الثيمات: data-theme على <html> — يُختار من لوحة التحكم فقط (نصوص وإعدادات الموقع ← المظهر).
   الفاتح هو :root أعلاه؛ هنا القيم التي تختلف فقط.
   ========================================================= */

/* داكن: الصفحة تبقى فاتحة، وأقسام وبطاقات مختارة فقط تتحول لفحمي دافئ (ليس أسود)
   بنفس لمسات البرونزي. المتغيرات تُعاد تعريفها على القسم نفسه فتسري عليه وعلى ما بداخله.
   .tone-dark متاحة أيضاً لأي عنصر يُراد تغميقه في كل الثيمات. */
.tone-dark,
:root[data-theme="dark"] :is(
  .site-header,
  .hx,
  .statement,
  #services,
  .section--teaser,
  #quality,
  .careers,
  .site-footer,
  .page-hero,
  .section--map,
  .vm__card--dark,
  .profile-cta,
  .map-card,
  .cta-band
) {
  color-scheme: dark;
  color: var(--text-2);
  --logo-on-light: none;   /* يُظهر نسخة الشعار المخصصة للخلفيات الغامقة (x-brand) */
  --logo-on-dark: block;
  --bg: #1F1C18;
  --bg-alt: #26221D;
  --bg-deep: #191714;
  --surface: #2C2823;
  --glass: rgba(44, 40, 35, .72);
  --glass-strong: rgba(44, 40, 35, .88);
  --glass-border: rgba(255, 255, 255, .08);

  --text: #F4EFE8;
  --text-2: #D6CDC2;        /* 11:1 على --bg */
  --text-3: #A99F94;        /* 6.6:1 على --bg */
  --line: #3A342D;
  --line-strong: #4C453C;

  --gold: #CFA03A;
  /* المتغيرات المركّبة تُحسب حيث عُرّفت، فتُعاد هنا لتأخذ الذهبي الأفتح */
  --accent-gradient: linear-gradient(90deg, var(--bronze), #CFA03A);
  --accent-hover: #CFA03A;
  --bronze-ink: #DDAE7C;    /* نص برونزي صغير: 7.9:1 على --bg */
  --bronze-soft: rgba(190, 132, 81, .16);
  --bronze-line: rgba(190, 132, 81, .42);
  --gold-rgb: 207, 160, 58;
  --success-ink: #9BD37E;

  --bg-rgb: 31, 28, 24;
  --ink-rgb: 244, 239, 232; /* خطوط الشبكة ومسارات المؤشرات تصبح فاتحة */
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, .3), 0 6px 16px -8px rgba(0, 0, 0, .5);
  --shadow-md: 0 2px 4px rgba(0, 0, 0, .3), 0 24px 48px -24px rgba(0, 0, 0, .6);
  --shadow-lg: 0 40px 80px -40px rgba(0, 0, 0, .75);

  --quote-bg: linear-gradient(150deg, #4A3828, #33281E);
  --success-soft: rgba(130, 190, 100, .16);
  --alert-bg: #22301C;
  --alert-border: #3B5330;
  --alert-text: #CDE8BF;
  --danger: #F0907B;

  --il-ground: #2F2A24;
  --il-line: #3F3830;
  --il-detail: #6E6152;
  --il-muted: #8C8277;
  --il-leaf: #7FA05A;
  --map-dots: #4A423A;
  --map-outline: #6E6152;
}

/* اليوم الوطني: أخضر العلم السعودي (#006C35) مع ذهبي الهوية، على خلفية فاتحة مخضرّة */
:root[data-theme="green"] {
  --bg: #F3F8F4;
  --bg-alt: #E6F0E8;
  --bg-deep: #D7E7DB;
  --glass: rgba(255, 255, 255, .74);
  --glass-strong: rgba(255, 255, 255, .88);

  --text: #0F2419;
  --text-2: #33473B;        /* 9.4:1 على --bg */
  --text-3: #56685C;        /* 5.7:1 على --bg */
  --line: #D2E2D6;
  --line-strong: #B9D0BF;

  --bronze: #006C35;        /* اللون الأساسي يصبح الأخضر الوطني */
  --gold: #B8860B;
  --bronze-ink: #005A2C;    /* 7.6:1 على --bg */
  --bronze-soft: rgba(0, 108, 53, .1);
  --bronze-line: rgba(0, 108, 53, .3);
  --accent-gradient: linear-gradient(90deg, #006C35, #B8860B);
  --on-accent: #FFFFFF;     /* أبيض على الأخضر: 6.9:1 */
  --accent-hover: #00552A;
  --success-ink: #006C35;

  --bg-rgb: 243, 248, 244;
  --ink-rgb: 15, 36, 25;
  --accent-rgb: 0, 108, 53;
  --shadow-sm: 0 1px 2px rgba(15, 36, 25, .05), 0 4px 14px -6px rgba(15, 36, 25, .1);
  --shadow-md: 0 2px 4px rgba(15, 36, 25, .05), 0 24px 48px -24px rgba(15, 36, 25, .2);
  --shadow-lg: 0 40px 80px -40px rgba(15, 36, 25, .3);

  --quote-bg: linear-gradient(150deg, #D3E8D9, #A9CFB5);

  --il-ground: #E8F2EA;
  --il-line: #CFE1D4;
  --il-detail: #9DBBA6;
  --il-muted: #7C9283;
  --map-dots: #C3D8C9;
  --map-outline: #9DBBA6;
  --map-big: #00552A;
  --map-small: #93C7A6;
  --map-on-hq: #FFFFFF;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text-2);
  font-family: var(--font);
  font-size: var(--fs-base);
  line-height: var(--lh-body);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { display: block; max-width: 100%; }
a { color: var(--bronze-ink); }
a:hover { color: var(--text); }
h1, h2, h3, p, figure, ul, ol, dl { margin: 0; }
h1, h2, h3 { color: var(--text); font-weight: 700; line-height: var(--lh-tight); text-wrap: balance; }
ul, ol { padding: 0; list-style: none; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--bronze); outline-offset: 3px; border-radius: 6px; }
.num { direction: ltr; unicode-bidi: isolate; }
.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: 16px; top: -60px; z-index: 100; background: var(--text); color: var(--bg); padding: 10px 18px; border-radius: 999px; font-weight: 700; transition: top .2s; }
.skip-link:focus { top: 16px; color: var(--bg); }

/* ---------- Layout ---------- */
.container { width: 100%; max-width: var(--container); margin-inline: auto; padding-inline: var(--gutter); }
.section { padding-block: var(--section); }
.section--base { background: var(--bg); }
.section--alt { background: var(--bg-alt); }
.section--flush-bottom { padding-bottom: 0; }
.section--tight-top { padding-top: clamp(48px, 6vw, 72px); }

/* ---------- Typography ---------- */
.eyebrow { display: inline-flex; align-items: center; gap: 10px; font-size: var(--fs-sm); font-weight: 600; letter-spacing: .02em; color: var(--bronze-ink); }
.eyebrow::before { content: ""; width: 18px; height: 2px; border-radius: 1px; background: var(--accent-gradient); }
.display { font-weight: 700; line-height: var(--lh-tight); }
.h1 { font-size: var(--fs-h1); }
.h2 { font-size: var(--fs-h2); }
.h3 { font-size: var(--fs-h3); }
.lead { font-size: var(--fs-lead); color: var(--text-2); }
.muted { color: var(--text-3); }
.text-gold { background: var(--accent-gradient); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; color: var(--gold); }
[dir="ltr"] .display, [dir="ltr"] h1, [dir="ltr"] h2 { letter-spacing: -.015em; }

.section-head { display: flex; flex-direction: column; gap: 14px; margin-bottom: clamp(36px, 5vw, 56px); }
.section-head p { font-size: var(--fs-lead); }
.section-head--center { align-items: center; text-align: center; }
.section-head--center p { max-width: 640px; }
.section-head--split { flex-direction: row; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 20px 40px; }
.section-head--split > div { display: flex; flex-direction: column; gap: 14px; max-width: 720px; }
.section-head--split > p { max-width: 440px; }
.section-actions { margin-top: 40px; display: flex; justify-content: center; }

/* ---------- Buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 52px; padding-inline: 26px; border-radius: 999px; text-decoration: none; font-weight: 600; font-size: var(--fs-base); border: 1px solid transparent; cursor: pointer; transition: transform .3s var(--ease), background-color .3s, color .3s, box-shadow .3s, border-color .3s; white-space: nowrap; }
.btn:hover { transform: translateY(-2px); }
.btn--gold, .btn--gold:hover { color: var(--on-accent); }
.btn--gold { background: var(--bronze); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .3), 0 14px 28px -14px rgba(var(--accent-rgb), .8); }
.btn--gold:hover { background: var(--accent-hover); }
.btn--ghost, .btn--ghost:hover { color: var(--text); }
.btn--ghost { background: var(--glass); border-color: var(--line-strong); -webkit-backdrop-filter: var(--blur); backdrop-filter: var(--blur); }
.btn--ghost:hover { border-color: var(--bronze); background: var(--surface); }
.btn--dark, .btn--dark:hover { color: var(--bg); }
.btn--dark { background: var(--text); }
.btn--dark:hover { background: var(--text-2); }
.btn--sm { min-height: 44px; padding-inline: 18px; font-size: var(--fs-sm); }
.btn .arrow { display: inline-block; transition: transform .3s var(--ease); }
[dir="rtl"] .btn:hover .arrow { transform: translateX(-4px); }
[dir="ltr"] .btn:hover .arrow { transform: translateX(4px); }

.chip { display: inline-flex; align-items: center; gap: 8px; border-radius: 999px; padding: 5px 14px; font-size: var(--fs-xs); font-weight: 500; color: var(--bronze-ink); background: var(--bronze-soft); border: 1px solid var(--bronze-line); }
.chip--soft { color: var(--text-2); background: var(--bg-alt); border-color: transparent; }
.chip--outline-light { color: var(--text); background: var(--surface); border-color: var(--line); font-size: var(--fs-base); padding: 10px 22px; }
.badge-pill { align-self: flex-start; display: inline-flex; align-items: center; gap: 10px; padding: 7px 16px; border-radius: 999px; font-size: var(--fs-sm); font-weight: 500; color: var(--text); background: var(--glass); border: 1px solid var(--bronze-line); -webkit-backdrop-filter: var(--blur); backdrop-filter: var(--blur); }
.badge-pill::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 0 4px rgba(var(--gold-rgb), .18); }

/* ---------- Header: زجاج فاتح ---------- */
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(var(--bg-rgb), .72); -webkit-backdrop-filter: var(--blur); backdrop-filter: var(--blur); border-bottom: 1px solid var(--line); transition: background-color .3s, box-shadow .3s; }
.site-header.is-scrolled { background: rgba(var(--bg-rgb), .9); box-shadow: var(--shadow-sm); }
.site-header__inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: var(--header-h); }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--text); flex: none; }
.brand:hover { color: var(--text); }
.brand__logo { display: block; height: var(--logo-h, 40px); width: auto; max-width: min(240px, 52vw); object-fit: contain; }
.brand__logo--on-light { display: var(--logo-on-light, block); }
.brand__logo--on-dark { display: var(--logo-on-dark, none); }
.brand__text { display: flex; flex-direction: column; line-height: 1.2; }
.brand__name { font-size: 18px; font-weight: 700; color: var(--text); }
.brand__sub { font-size: 11px; color: var(--text-3); letter-spacing: .02em; }
.site-nav { display: flex; gap: 0 26px; font-size: var(--fs-sm); font-weight: 500; }
.site-nav a { color: var(--text-2); text-decoration: none; min-height: 44px; display: flex; align-items: center; position: relative; }
.site-nav a::after { content: ""; position: absolute; inset-inline: 0; bottom: 8px; height: 2px; border-radius: 1px; background: var(--accent-gradient); transform: scaleX(0); transition: transform .35s var(--ease); }
.site-nav a:hover, .site-nav a[aria-current="page"] { color: var(--text); }
.site-nav a:hover::after, .site-nav a[aria-current="page"]::after { transform: scaleX(1); }
.header-actions { display: flex; align-items: center; gap: 10px; }
.lang-switch { min-height: 44px; padding-inline: 16px; border: 1px solid var(--line-strong); background: var(--glass); border-radius: 999px; font-size: var(--fs-xs); font-weight: 500; color: var(--text); display: inline-flex; align-items: center; gap: 8px; text-decoration: none; }
.lang-switch:hover { border-color: var(--bronze); color: var(--text); }
.menu-toggle { display: none; width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--line-strong); background: var(--glass); color: var(--text); align-items: center; justify-content: center; cursor: pointer; }


/* 1200px: ثمانية روابط في القائمة لا تتسع بجانب الشعار والأزرار تحت هذا العرض */
@media (max-width: 1200px) {
  .menu-toggle { display: inline-flex; }
  .header-actions .btn--sm { display: none; }
  .site-nav { position: absolute; inset: 100% 0 auto 0; flex-direction: column; gap: 0; padding: 8px var(--gutter) 24px; background: rgba(var(--bg-rgb), .98); border-bottom: 1px solid var(--line); box-shadow: var(--shadow-md); transform: translateY(-12px); opacity: 0; pointer-events: none; transition: opacity .3s, transform .3s var(--ease); font-size: var(--fs-md); }
  .site-nav a { min-height: 54px; border-bottom: 1px solid var(--line); }
  .site-nav a::after { display: none; }
  .nav-open .site-nav { opacity: 1; transform: none; pointer-events: auto; }
}

/* ---------- خلفيات الصور مع غشاء فاتح (الواجهة وصفحات المشاريع والأخبار) ---------- */
/* غشاء أوف-وايت من جهة النص (بداية السطر) يجعل النص الداكن مقروءاً، ويُبقي الصورة حاضرة في الجهة الأخرى،
   مع تلاشٍ سفلي إلى لون الصفحة. */
.veil { --veil-side: to left; background:
  linear-gradient(var(--veil-side), rgba(var(--bg-rgb), .96) 0%, rgba(var(--bg-rgb), .86) 34%, rgba(var(--bg-rgb), .35) 62%, rgba(var(--bg-rgb), 0) 80%),
  linear-gradient(180deg, rgba(var(--bg-rgb), .5) 0%, rgba(var(--bg-rgb), 0) 22%, rgba(var(--bg-rgb), 0) 70%, var(--bg) 100%); }
[dir="ltr"] .veil { --veil-side: to right; }
@media (max-width: 1024px) {
  /* النص بعرض الشاشة: غشاء متساوٍ أقوى */
  .veil { background: linear-gradient(rgba(var(--bg-rgb), .8), rgba(var(--bg-rgb), .8)), linear-gradient(180deg, rgba(var(--bg-rgb), 0) 60%, var(--bg) 100%); }
}

.hero__bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center 55%; }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); border-top: 1px solid var(--line); }
.stat { padding: 24px 8px 0; display: flex; flex-direction: column; gap: 2px; }
.stat__value { font-size: clamp(30px, 3vw, 40px); font-weight: 700; color: var(--text); line-height: 1.15; direction: ltr; text-align: start; }
.stat__label { font-size: var(--fs-sm); color: var(--text-3); }

/* =========================================================
   Hero (resources/views/components/hero.blade.php)
   ثلاثة أنماط بخلفية بعرض الشاشة: hx--image · hx--video · hx--slider
   ========================================================= */
.hx { --hx-bronze: var(--bronze); --hx-gold: var(--gold); position: relative; overflow: hidden; isolation: isolate; background: var(--bg-alt); }

.hx__copy { position: relative; z-index: 1; min-width: 0; display: flex; flex-direction: column; gap: 20px; }
.hx__copy--overlay { max-width: 720px; }
.hx__title { font-weight: 700; color: var(--text); font-size: var(--fs-h1); line-height: var(--lh-tight); }
.hx__title--xl { font-size: var(--fs-display); line-height: 1.22; }
[dir="ltr"] .hx__title { letter-spacing: -.02em; line-height: 1.12; }
.hx__accent { display: block; color: var(--gold); background: var(--accent-gradient); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.hx__lead { max-width: 580px; font-size: var(--fs-lead); line-height: var(--lh-body); color: var(--text-2); }
.hx__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 6px; }

.hx-badge { align-self: flex-start; display: inline-flex; align-items: center; gap: 10px; padding: 7px 16px; border-radius: 999px; font-size: var(--fs-sm); font-weight: 500; color: var(--text); background: var(--glass); border: 1px solid var(--bronze-line); -webkit-backdrop-filter: var(--blur); backdrop-filter: var(--blur); }
.hx-badge::before { content: ""; flex: none; width: 7px; height: 7px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 0 4px rgba(var(--gold-rgb), .18); }

.hx-btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 52px; padding-inline: 26px; border-radius: 999px; font-size: var(--fs-base); font-weight: 600; text-decoration: none; white-space: nowrap; border: 1px solid transparent; transition: transform .35s var(--ease), box-shadow .35s, background-color .35s, border-color .35s; }
.hx-btn--primary, .hx-btn--primary:hover { color: var(--on-accent); }
.hx-btn--primary { background: var(--bronze); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .3), 0 16px 32px -16px rgba(var(--accent-rgb), .85); }
.hx-btn--primary:hover { background: var(--accent-hover); transform: translateY(-2px); }
.hx-btn--glass, .hx-btn--glass:hover { color: var(--text); }
.hx-btn--glass { background: var(--glass); border-color: var(--line-strong); -webkit-backdrop-filter: var(--blur); backdrop-filter: var(--blur); }
.hx-btn--glass:hover { background: var(--surface); border-color: var(--bronze); transform: translateY(-2px); }
.hx-btn .arrow { display: inline-block; transition: transform .35s var(--ease); }
[dir="rtl"] .hx-btn:hover .arrow { transform: translateX(-4px); }
[dir="ltr"] .hx-btn:hover .arrow { transform: translateX(4px); }

.hx-control { width: 44px; height: 44px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-size: 16px; color: var(--text); background: var(--glass); border: 1px solid var(--line-strong); -webkit-backdrop-filter: var(--blur); backdrop-filter: var(--blur); cursor: pointer; transition: border-color .3s, background-color .3s; }
.hx-control:hover { border-color: var(--bronze); background: var(--surface); }
[x-cloak] { display: none !important; }

.hx--image, .hx--video, .hx--slider { margin-top: calc(-1 * var(--header-h) - 1px); min-height: max(640px, min(100svh, 940px)); display: flex; flex-direction: column; justify-content: flex-end; }
.hx .hx__bg, .hx__video, .hx-slide__img { position: absolute; inset: 0; z-index: -1; width: 100%; height: 100%; object-fit: cover; }
.hx__scrim { position: absolute; inset: 0; z-index: -1; }
.hx__stage { position: relative; z-index: 1; padding-top: calc(var(--header-h) + 72px); padding-bottom: 28px; }
.hx__stage--cols { display: grid; grid-template-columns: minmax(0, 1fr) minmax(280px, 340px); align-items: end; gap: clamp(32px, 5vw, 72px); }

.hx-glass { display: flex; flex-direction: column; gap: 6px; padding: 22px; border-radius: var(--radius-md); color: var(--text); background: var(--glass); border: 1px solid var(--glass-border); -webkit-backdrop-filter: var(--blur); backdrop-filter: var(--blur); box-shadow: var(--shadow-md); transition: transform .5s var(--ease), border-color .5s; }
.hx-glass:hover { transform: translateY(-4px); border-color: var(--bronze-line); }
.hx-glass__top { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 8px; }
.hx-glass__icon { width: 44px; height: 44px; border-radius: 14px; background: var(--surface); box-shadow: var(--shadow-sm); display: flex; align-items: center; justify-content: center; }
.hx-glass__badge { font-size: 11px; font-weight: 500; padding: 4px 10px; border-radius: 999px; color: var(--bronze-ink); background: var(--bronze-soft); border: 1px solid var(--bronze-line); direction: ltr; }
.hx-glass strong { font-size: var(--fs-h3); font-weight: 700; color: var(--text); line-height: var(--lh-tight); }
.hx-glass__text { font-size: var(--fs-sm); color: var(--text-2); }

.hx-control--corner { position: absolute; inset-inline-end: var(--gutter); bottom: 28px; }
.hx-icon-play, .hx--video.is-paused .hx-icon-pause { display: none; }
.hx--video.is-paused .hx-icon-play { display: block; }

.hx__slides { display: grid; }
.hx-slide { grid-area: 1 / 1; opacity: 0; visibility: hidden; transition: opacity .9s var(--ease), visibility 0s linear .9s; }
.hx-slide.is-active, .hx--slider:not(.is-ready) .hx-slide:first-child { opacity: 1; visibility: visible; transition: opacity .9s var(--ease), visibility 0s; }
.hx-slide__img { transform: scale(1.08); transition: transform 7s linear; }
.hx-slide.is-active .hx-slide__img { transform: scale(1); }
.hx-slide__copy { transform: translateY(18px); opacity: 0; transition: transform .9s var(--ease) .25s, opacity .9s var(--ease) .25s; }
.hx-slide.is-active .hx-slide__copy, .hx--slider:not(.is-ready) .hx-slide:first-child .hx-slide__copy { transform: none; opacity: 1; }

.hx__nav { position: relative; z-index: 2; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-bottom: 8px; }
.hx--slider:not(.is-ready) .hx__nav { display: none; }
.hx-nav__buttons { display: flex; gap: 8px; }
.hx-dots { display: flex; gap: 8px; }
.hx-dot { width: 40px; height: 44px; padding: 0; border: 0; background: none; cursor: pointer; display: flex; align-items: center; }
.hx-dot__fill { position: relative; display: block; width: 100%; height: 4px; border-radius: 2px; overflow: hidden; background: rgba(var(--ink-rgb), .14); }
.hx-dot__fill::after { content: ""; position: absolute; inset: 0; border-radius: inherit; background: var(--accent-gradient); transform: scaleX(0); }
[dir="rtl"] .hx-dot__fill::after { transform-origin: right; }
[dir="ltr"] .hx-dot__fill::after { transform-origin: left; }
.hx-dot[aria-current="true"] .hx-dot__fill::after { animation: hx-progress var(--hx-interval, 6500ms) linear forwards; }
/* شريط التقدم يتوقف مع التبديل نفسه (is-held من hero.js)، لا عند مجرد وجود المؤشر فوق الواجهة */
.hx--slider.is-paused .hx-dot[aria-current="true"] .hx-dot__fill::after,
.hx--slider.is-held .hx-dot[aria-current="true"] .hx-dot__fill::after { animation: none; transform: scaleX(1); }
.hx-dot:hover .hx-dot__fill { background: rgba(var(--ink-rgb), .24); }
@keyframes hx-progress { to { transform: scaleX(1); } }

/* الأرقام (Bento): عدد الأعمدة يحسبه components/hero/stats.blade.php ليبقى كل صف مكتملاً */
.hx-bento { position: relative; z-index: 2; display: grid; grid-template-columns: repeat(var(--hx-cols-lg, 4), minmax(0, 1fr)); gap: 10px; margin-top: clamp(40px, 5vw, 56px); }
.hx-bento--overlay { margin-top: 12px; padding-bottom: 40px; }
.hx-bento__tile { display: flex; flex-direction: column; gap: 2px; padding: 18px 20px; border-radius: var(--radius-sm); background: var(--glass-strong); border: 1px solid var(--glass-border); -webkit-backdrop-filter: var(--blur); backdrop-filter: var(--blur); box-shadow: var(--shadow-sm); transition: transform .4s var(--ease), border-color .4s, box-shadow .4s; }
.hx-bento__tile:hover { transform: translateY(-3px); border-color: var(--bronze-line); box-shadow: var(--shadow-md); }
.hx-bento__tile:first-child { background: linear-gradient(140deg, rgba(var(--accent-rgb), .22), rgba(var(--gold-rgb), .08)), var(--glass-strong); border-color: var(--bronze-line); }
.hx-bento__value { font-size: clamp(24px, 2.4vw, 34px); font-weight: 700; line-height: 1.15; color: var(--text); direction: ltr; text-align: start; }
.hx-bento__label { font-size: var(--fs-xs); color: var(--text-3); }

@media (max-width: 1024px) {
  .hx__stage--cols { grid-template-columns: 1fr; gap: 24px; }
  .hx-glass { max-width: 420px; }
  .hx-bento { grid-template-columns: repeat(var(--hx-cols-md, 3), minmax(0, 1fr)); }
}
@media (max-width: 720px) {
  .hx__stage { padding-top: calc(var(--header-h) + 40px); }
  .hx-btn { min-height: 50px; padding-inline: 20px; font-size: 15px; }
  .hx__actions .hx-btn { flex: 1 1 auto; }
  .hx-glass { display: none; }
  .hx-control--corner { bottom: 20px; }
  .hx-dot { width: 28px; }
  .hx-bento { grid-template-columns: repeat(var(--hx-cols-sm, 2), minmax(0, 1fr)); gap: 8px; }
  .hx-bento__tile { padding: 14px 12px; border-radius: 16px; }
  .hx-bento__value { font-size: 22px; }
  .hx-bento__label { font-size: 12px; line-height: 1.5; }
}

/* ---------- شريط الأرقام فوق الخلفية: شريط زجاجي واحد بدل بطاقات منفصلة ---------- */
/* تدرج أسفل صورة الواجهة يدخل في لون القسم التالي (يُقرأ من :root لأن .hx يعيد تعريف --bg-alt في الثيم الداكن).
   القسم التالي فاتح، فالتدرج محصور في المسافة تحت الشريط (40px) حتى لا يفتّح الزجاج ويضعف تباين نصوصه */
/* .hx--image::after, .hx--video::after, .hx--slider::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 56px;
  background: linear-gradient(to bottom, transparent, color-mix(in srgb, var(--hx-fade-to) 55%, transparent) 60%, var(--hx-fade-to));
  pointer-events: none;
  z-index: 1;
} */
.hx-bento.hx-bento--overlay {
  display: grid;
  grid-template-columns: repeat(var(--hx-cols-lg, 6), 1fr); /* 6 أعمدة لست أرقام؛ العدد من لوحة التحكم */
  gap: 0;
  position: relative;
  z-index: 2;
  /* الشريط نفسه بعرض المحتوى (بدون حشوة .container داخل الزجاج) */
  width: calc(100% - 2 * var(--gutter));
  max-width: calc(var(--container) - 2 * var(--gutter));
  margin: 12px auto 40px;
  padding: 0;
  background: rgba(40, 33, 27, .28);
  backdrop-filter: blur(16px) saturate(130%);
  -webkit-backdrop-filter: blur(16px) saturate(130%);
  border: 1px solid rgba(255, 255, 255, .09);
  border-radius: 22px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, .35);
  overflow: hidden;
}
.hx-bento--overlay::before {
  content: ""; position: absolute; top: 0; left: 8%; right: 8%; height: 1px;
  background: linear-gradient(90deg, transparent, #C99D66, transparent);
  pointer-events: none;
}
.hx-bento--overlay .hx-bento__tile,
.hx-bento--overlay .hx-bento__tile:first-child {
  position: relative;
  gap: 0;
  padding: 30px 28px;
  background: transparent;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
  transform: none;
  transition: background .3s ease;
}
.hx-bento--overlay .hx-bento__tile:hover { background: rgba(177, 128, 72, .12); transform: none; box-shadow: none; }
.hx-bento--overlay .hx-bento__tile + .hx-bento__tile::before {
  content: ""; position: absolute; top: 26px; bottom: 26px; inset-inline-start: 0; width: 1px;
  background: linear-gradient(to bottom, transparent, rgba(255, 255, 255, .18), transparent);
}
.hx-bento--overlay .hx-bento__value { font-size: 40px; font-weight: 700; color: #C99D66; margin-bottom: 6px; }
.hx-bento--overlay .hx-bento__label { font-size: 14px; color: rgba(255, 255, 255, .68); }

@media (max-width: 900px) {
  .hx-bento.hx-bento--overlay { grid-template-columns: repeat(3, 1fr); }
  .hx-bento--overlay .hx-bento__tile:nth-child(3n + 1)::before { content: none; }
  .hx-bento--overlay .hx-bento__tile:nth-child(n + 4) { border-top: 1px solid rgba(255, 255, 255, .08); }
}
@media (max-width: 767px) {
  .hx-bento.hx-bento--overlay { grid-template-columns: repeat(2, 1fr); }
  .hx-bento--overlay .hx-bento__tile { padding: 22px 18px; }
  .hx-bento--overlay .hx-bento__tile:nth-child(3n + 1)::before { content: ""; } /* يلغي قاعدة الثلاثة أعمدة */
  .hx-bento--overlay .hx-bento__tile:nth-child(2n + 1)::before { content: none; }
  .hx-bento--overlay .hx-bento__tile:nth-child(n + 4) { border-top: 0; }
  .hx-bento--overlay .hx-bento__tile:nth-child(n + 3) { border-top: 1px solid rgba(255, 255, 255, .08); }
  .hx-bento--overlay .hx-bento__value { font-size: 26px; }
}

/* ---------- الواجهة على الجوال (< 768px) ----------
   ارتفاع الصورة --hx-h: الشاشة كاملة (100svh لا 100vh بسبب شريط المتصفح)، أو 88svh مع شريط الأرقام
   ليظهر صفه الأول في أول شاشة. الأرقام تأتي تحت الصورة كشريط مستقل لا فوقها،
   وأدوات السلايدر في أسفل الصورة على الجهة العكسية لزر الشات العائم. */
@media (max-width: 767px) {
  .hx { --hx-h: 100svh; --hx-fab: 54px; }
  .hx:has(> .hx-bento) { --hx-h: 88svh; }
  .hx--image, .hx--video, .hx--slider { min-height: 0; display: block; }
  .hx .hx__bg, .hx__video, .hx-slide__img, .hx .hx__scrim { bottom: auto; height: var(--hx-h); }
  .hx .hx__bg, .hx__video, .hx-slide__img { object-position: 60% center; }
  .hx .hx__scrim { background: linear-gradient(to top, rgba(var(--bg-rgb), .92) 0%, rgba(var(--bg-rgb), .6) 45%, rgba(var(--bg-rgb), .15) 100%); }
  :root[data-theme="dark"] .hx .hx__scrim { background: linear-gradient(to top, rgba(20, 17, 14, .92) 0%, rgba(20, 17, 14, .6) 45%, rgba(20, 17, 14, .15) 100%); }

  /* المحتوى ملتصق بأسفل الصورة، مع مسافة تحته تفصل الأزرار عن أدوات السلايدر */
  .hx__slides { min-height: var(--hx-h); }
  .hx-slide { display: flex; flex-direction: column; justify-content: flex-end; }
  .hx .hx__stage { min-height: var(--hx-h); display: flex; flex-direction: column; justify-content: flex-end; padding-top: calc(var(--header-h) + 24px); padding-bottom: 96px; }

  .hx .hx__copy { gap: 0; }
  .hx .hx-badge { margin-bottom: 16px; padding: 6px 12px; font-size: 12px; }
  .hx .hx__title--xl { font-size: clamp(30px, 8.5vw, 38px); line-height: 1.15; }
  .hx .hx__lead { margin-top: 14px; font-size: 15px; line-height: 1.7; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
  .hx .hx__actions { margin-top: 22px; flex-direction: column; width: 100%; gap: 10px; }
  .hx .hx__actions .hx-btn { width: 100%; min-height: 50px; flex: none; }

  /* أدوات السلايدر: 36px في أسفل الصورة، تبدأ بعد مساحة زر الشات فلا تتقاطع معه */
  .hx .hx-control { width: 36px; height: 36px; font-size: 14px; }
  .hx__nav { position: absolute; inset-inline: 0; top: calc(var(--hx-h) - 56px); justify-content: flex-end; gap: 12px; padding-bottom: 0; padding-inline-start: calc(16px + var(--hx-fab) + 12px); }
  .hx-dots { gap: 6px; min-width: 0; }
  .hx-dot { width: 22px; height: 36px; }
  .hx-control--corner { bottom: auto; top: calc(var(--hx-h) - 56px); }

  /* شريط الأرقام تحت الصورة مباشرة: خلفية مصمتة بلون نهاية التدرج، بعرض الشاشة */
  .hx-bento.hx-bento--overlay { width: 100%; max-width: none; margin: 0; border: 0; border-radius: 0; box-shadow: none; background: #14110E; -webkit-backdrop-filter: none; backdrop-filter: none; }

}

/* ---------- About ---------- */
.about { display: flex; flex-wrap: wrap; align-items: center; gap: clamp(40px, 6vw, 72px); }
.about__media { flex: 1 1 440px; position: relative; min-height: 640px; }
.about__img-main { position: absolute; inset-inline-start: 0; top: 0; width: 72%; height: 560px; border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-md); }
.about__img-sub { position: absolute; inset-inline-end: 0; bottom: 0; width: 56%; height: 290px; border-radius: var(--radius-md); overflow: hidden; border: 8px solid var(--bg-alt); box-shadow: var(--shadow-md); }
.about__img-main img, .about__img-sub img { width: 100%; height: 100%; object-fit: cover; }
.about__img-main img { object-position: center 30%; }
.about__since { position: absolute; inset-inline-end: 6%; top: 40px; background: var(--glass-strong); -webkit-backdrop-filter: var(--blur); backdrop-filter: var(--blur); border: 1px solid var(--glass-border); box-shadow: var(--shadow-md); border-radius: var(--radius-md); padding: 20px 24px; display: flex; flex-direction: column; }
.about__since strong { font-size: 42px; font-weight: 700; line-height: 1.1; background: var(--accent-gradient); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; color: var(--gold); }
.about__since span { font-size: var(--fs-sm); color: var(--text-3); }
.about__copy { flex: 999 1 480px; min-width: 0; display: flex; flex-direction: column; gap: 20px; }
.about__copy > p { font-size: var(--fs-lead); }
.pillars { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 12px; margin-top: 8px; }
.pillar { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 20px; display: flex; gap: 14px; align-items: flex-start; box-shadow: var(--shadow-sm); }
.pillar__icon { flex: none; width: 38px; height: 38px; border-radius: 50%; background: var(--bronze-soft); color: var(--bronze-ink); display: flex; align-items: center; justify-content: center; }
.pillar strong { display: block; font-weight: 600; font-size: var(--fs-md); color: var(--text); }
.pillar span { font-size: var(--fs-sm); color: var(--text-3); }
.vm { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(340px, 100%), 1fr)); gap: 16px; margin-top: clamp(48px, 6vw, 72px); }
.vm__card { border-radius: var(--radius-lg); padding: clamp(32px, 4vw, 52px); display: flex; flex-direction: column; gap: 14px; border: 1px solid var(--line); box-shadow: var(--shadow-sm); }
.vm__card--dark { background: linear-gradient(150deg, rgba(var(--accent-rgb), .16), rgba(var(--gold-rgb), .05) 60%), var(--surface); border-color: var(--bronze-line); }
.vm__card--light { background: var(--surface); }
.vm__card p { font-size: clamp(20px, 2vw, 26px); line-height: 1.55; font-weight: 500; color: var(--text); }
.values { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 16px; }

/* ---------- Statement ---------- */
.statement { padding-block: clamp(96px, 12vw, 160px); text-align: center; background-color: var(--bg); background-image: linear-gradient(rgba(var(--ink-rgb), .045) 1px, transparent 1px), linear-gradient(90deg, rgba(var(--ink-rgb), .045) 1px, transparent 1px); background-size: 96px 96px; }
.statement p { max-width: 980px; margin-inline: auto; font-size: var(--fs-display); line-height: 1.4; font-weight: 700; color: var(--text); text-wrap: balance; }
.statement__line { display: block; width: 96px; height: 3px; border-radius: 2px; background: var(--accent-gradient); margin: 32px auto 0; }

/* ---------- Services ---------- */
.services { display: flex; flex-direction: column; gap: 20px; }
.service-feature { display: flex; flex-wrap: wrap; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-md); }
.service-feature__media { flex: 1 1 460px; min-height: 480px; overflow: hidden; }
.service-feature__media img { width: 100%; height: 100%; object-fit: cover; }
.service-feature__body { flex: 999 1 420px; min-width: 0; padding: clamp(32px, 5vw, 60px) clamp(24px, 4vw, 52px); display: flex; flex-direction: column; justify-content: center; gap: 16px; }
.service-no { font-weight: 300; line-height: 1; direction: ltr; text-align: start; color: var(--bronze); }
.service-feature .service-no { font-size: 64px; }
.service-feature h3 { font-size: var(--fs-h2); }
.service-feature p, .service-card p { color: var(--text-2); }
.tags { display: flex; flex-wrap: wrap; gap: 8px; }
.service-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(320px, 100%), 1fr)); gap: 20px; }
.service-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); overflow: hidden; display: flex; flex-direction: column; box-shadow: var(--shadow-sm); }
.service-card__media { height: 260px; background: var(--bg-alt); display: flex; align-items: center; justify-content: center; overflow: hidden; }
.service-card__media img { width: 100%; height: 100%; object-fit: cover; }
.service-card__media svg { width: 100%; height: 100%; }
.service-card__body { padding: 32px 32px 36px; display: flex; flex-direction: column; gap: 12px; }
.service-card .service-no { font-size: 36px; }
.service-card h3 { font-size: var(--fs-h3); }
.extra-scope { border: 1px dashed var(--bronze-line); background: var(--glass); border-radius: var(--radius-md); padding: 24px 28px; display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 10px 28px; }
.extra-scope strong { font-size: var(--fs-base); color: var(--bronze-ink); }
.extra-scope span { font-size: var(--fs-base); color: var(--text-2); }

/* ---------- Field highlights ---------- */
.field-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(260px, 100%), 1fr)); gap: 16px; }
/* فوتر مندمج مع أسفل الصورة: تدرج غامق + blur يتلاشى لأعلى + النص فوقهما */
@property --fc-shade { syntax: "<number>"; inherits: true; initial-value: 1; }
.field-card { --fc-shade: 1; position: relative; isolation: isolate; height: 520px; border-radius: 28px; overflow: hidden; background: var(--bg-deep); box-shadow: var(--shadow-md); transition: --fc-shade .6s var(--ease); }
.field-card img { display: block; width: 100%; height: 100%; object-fit: cover; }
.field-card.zoom img { transition: transform .6s var(--ease); }
.field-card.zoom:hover img { transform: none; }
.field-card::before { content: ""; position: absolute; inset: auto 0 0 0; height: 40%; z-index: 1; pointer-events: none; -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); -webkit-mask-image: linear-gradient(to bottom, transparent 0, #000 55%); mask-image: linear-gradient(to bottom, transparent 0, #000 55%); }
.field-card::after { content: ""; position: absolute; inset: auto 0 0 0; height: 48%; z-index: 1; pointer-events: none; background: linear-gradient(to bottom, rgba(20, 17, 14, 0) 0%, rgba(20, 17, 14, calc(.55 * var(--fc-shade))) 45%, rgba(20, 17, 14, min(1, calc(.88 * var(--fc-shade)))) 100%); }
.field-card figcaption { position: absolute; inset: auto 0 0 0; z-index: 2; padding: 0 26px 28px; display: flex; flex-direction: column; gap: 6px; }
.field-card figcaption::before { content: ""; width: 34px; height: 2px; background: #C99D66; margin-bottom: 8px; }
.field-card figcaption strong { font-size: 21px; font-weight: 700; line-height: 1.35; color: #fff; }
.field-card figcaption span { font-size: 14px; line-height: 1.6; color: rgba(255, 255, 255, .75); display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 3; overflow: hidden; transition: transform .6s var(--ease); }
@media (hover: hover) and (pointer: fine) {
  .field-card:hover { --fc-shade: 1.12; }
  .field-card.zoom:hover img { transform: scale(1.05); }
  .field-card:hover figcaption span { transform: translateY(-4px); }
}

/* ---------- Quote band ---------- */
.quote-band { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(320px, 100%), 1fr)); background: var(--bg-alt); }
.quote-band figure { height: 600px; overflow: hidden; }
.quote-band figure img { width: 100%; height: 100%; object-fit: cover; }
.quote-band__text { background: var(--quote-bg); color: var(--text); padding: 64px clamp(28px, 4vw, 56px); display: flex; flex-direction: column; justify-content: center; gap: 20px; }
.quote-band__text svg path { fill: var(--text); }
.quote-band__text p { font-size: clamp(22px, 2.4vw, 32px); line-height: 1.55; font-weight: 600; color: var(--text); }
.quote-band__text span { font-size: var(--fs-sm); font-weight: 600; color: var(--text-2); }

/* ---------- Projects teaser ---------- */
.teaser { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 40px; }
.teaser__copy { flex: 999 1 500px; min-width: 0; display: flex; flex-direction: column; gap: 16px; }
.teaser__copy > p { font-size: var(--fs-lead); max-width: 560px; }
.teaser__copy .btn { align-self: flex-start; margin-top: 8px; }
.teaser__stats { flex: 1 1 420px; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.mini-stat { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-md); padding: 24px 18px; display: flex; flex-direction: column; gap: 4px; box-shadow: var(--shadow-sm); }
.mini-stat strong { font-size: clamp(32px, 3.4vw, 44px); font-weight: 700; color: var(--text); line-height: 1.1; direction: ltr; text-align: start; }
.mini-stat:first-child { background: linear-gradient(140deg, rgba(var(--accent-rgb), .18), rgba(var(--gold-rgb), .05)), var(--surface); border-color: var(--bronze-line); }
.mini-stat span { font-size: var(--fs-sm); color: var(--text-3); }

/* ---------- Clients marquee ---------- */
.clients { overflow: hidden; }
.marquee { overflow: hidden; direction: ltr; -webkit-mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent); mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent); }
.marquee__track { display: flex; width: max-content; animation: marquee 45s linear infinite; }
.marquee:hover .marquee__track { animation-play-state: paused; }
@keyframes marquee { to { transform: translateX(-50%); } }
.logo-tile { flex: none; width: 220px; height: 120px; margin: 0 8px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-md); padding: 22px 26px; display: flex; align-items: center; justify-content: center; }
.logo-tile img { max-width: 100%; max-height: 100%; object-fit: contain; filter: grayscale(1); opacity: .6; transition: filter .5s, opacity .5s; }
.logo-tile:hover img { filter: none; opacity: 1; }
.logo-tile--text { font-weight: 600; color: var(--text-3); text-align: center; font-size: var(--fs-base); }
.clients__count { margin-top: 36px; text-align: center; font-size: var(--fs-sm); color: var(--text-3); }

/* ---------- Quality ---------- */
.iso-grid { max-width: 1080px; margin-inline: auto; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(260px, 100%), 1fr)); gap: 20px; }
.iso-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 36px 24px; display: flex; flex-direction: column; align-items: center; gap: 16px; text-align: center; text-decoration: none; box-shadow: var(--shadow-sm); }
.iso-card strong { font-size: var(--fs-h3); font-weight: 700; color: var(--text); }
.iso-card span { font-size: var(--fs-sm); color: var(--text-3); direction: ltr; }
.iso-note { margin-top: 28px; text-align: center; font-size: var(--fs-base); color: var(--text-3); }

/* ---------- Careers: صورة بغشاء فاتح ---------- */
.careers { position: relative; overflow: hidden; isolation: isolate; padding-block: clamp(96px, 12vw, 150px); background: var(--bg-alt); }
.careers__bg { position: absolute; inset: -10% 0 0 0; z-index: -2; width: 100%; height: 120%; object-fit: cover; object-position: center 30%; }
.careers__scrim { position: absolute; inset: 0; z-index: -1; }
.careers__inner { position: relative; display: flex; flex-wrap: wrap; align-items: center; gap: 40px; }
.careers__copy { flex: 999 1 500px; min-width: 0; display: flex; flex-direction: column; gap: 20px; }
.careers__copy h2 { font-size: var(--fs-h1); }
.careers__copy .lead { max-width: 580px; }
.perks { display: flex; flex-wrap: wrap; gap: 10px; }
.perk { border: 1px solid var(--line-strong); border-radius: 999px; padding: 9px 18px; font-size: var(--fs-sm); font-weight: 500; color: var(--text); background: var(--glass); -webkit-backdrop-filter: var(--blur); backdrop-filter: var(--blur); }
.careers__copy .btn { align-self: flex-start; margin-top: 8px; }
.careers__card { flex: 1 1 320px; background: var(--glass-strong); border: 1px solid var(--glass-border); -webkit-backdrop-filter: var(--blur); backdrop-filter: var(--blur); border-radius: var(--radius-lg); padding: 36px; display: flex; flex-direction: column; gap: 16px; box-shadow: var(--shadow-md); }
.careers__card h3 { font-size: var(--fs-h3); }
.careers__card p { font-size: var(--fs-base); color: var(--text-2); }
.careers__card-stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; border-top: 1px solid var(--line); padding-top: 16px; }
.careers__card-stats strong { display: block; font-size: 30px; font-weight: 700; color: var(--text); direction: ltr; text-align: start; }
.careers__card-stats div:last-child strong { color: var(--bronze-ink); }
.careers__card-stats span { font-size: var(--fs-xs); color: var(--text-3); }

/* ---------- Profile download ---------- */
.profile-cta { position: relative; overflow: hidden; background: linear-gradient(135deg, rgba(var(--accent-rgb), .16), rgba(var(--gold-rgb), .04) 55%), var(--surface); border: 1px solid var(--bronze-line); border-radius: var(--radius-lg); padding: clamp(28px, 4.5vw, 52px); display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 28px; box-shadow: var(--shadow-md); }
.profile-cta__mark { position: absolute; inset-inline-end: -40px; top: -60px; opacity: .08; pointer-events: none; }
.profile-cta__body { position: relative; display: flex; align-items: center; gap: 22px; flex: 999 1 460px; min-width: 0; }
.profile-cta__body > div { display: flex; flex-direction: column; gap: 6px; }
.profile-cta__icon { flex: none; width: 72px; height: 72px; border-radius: 20px; background: var(--surface); border: 1px solid var(--bronze-line); color: var(--bronze-ink); display: flex; align-items: center; justify-content: center; box-shadow: var(--shadow-sm); }
.profile-cta h2 { font-size: var(--fs-h3); }
.profile-cta .btn { position: relative; }

/* ---------- FAQ (details/summary: يعمل بدون JavaScript ومقروء لمحركات البحث) ---------- */
.faq__list { max-width: 860px; margin-inline: auto; display: flex; flex-direction: column; gap: 10px; }
.faq__item { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-sm); box-shadow: var(--shadow-sm); transition: border-color .3s; }
.faq__item[open] { border-color: var(--bronze-line); }
.faq__item summary { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 20px 22px; cursor: pointer; list-style: none; }
.faq__item summary::-webkit-details-marker { display: none; }
.faq__item summary h3 { font-size: var(--fs-md); font-weight: 600; line-height: 1.6; }
.faq__icon { flex: none; position: relative; width: 28px; height: 28px; border-radius: 50%; background: var(--bronze-soft); }
.faq__icon::before, .faq__icon::after { content: ""; position: absolute; inset-inline-start: 8px; top: 13px; width: 12px; height: 2px; border-radius: 1px; background: var(--bronze-ink); transition: transform .3s var(--ease); }
.faq__icon::after { transform: rotate(90deg); }
.faq__item[open] .faq__icon::after { transform: rotate(0); }
.faq__item p { padding: 0 22px 22px; color: var(--text-2); white-space: pre-line; }

/* ---------- Contact ---------- */
.contact { display: flex; flex-wrap: wrap; gap: 20px; }
.contact__cards { flex: 1 1 340px; display: flex; flex-direction: column; gap: 12px; }
.contact-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 18px 20px; display: flex; align-items: center; gap: 16px; text-decoration: none; color: var(--text); box-shadow: var(--shadow-sm); }
.contact-card:hover { color: var(--text); border-color: var(--bronze-line); }
.contact-card__icon { flex: none; width: 50px; height: 50px; border-radius: 15px; background: var(--bronze-soft); color: var(--bronze-ink); display: flex; align-items: center; justify-content: center; }
.contact-card__text { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.contact-card__text small { font-size: var(--fs-xs); color: var(--text-3); }
.contact-card__text strong { font-weight: 600; font-size: var(--fs-md); overflow-wrap: anywhere; }
.contact-card__arrow { color: var(--bronze-ink); }
.map-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 20px; display: flex; flex-direction: column; gap: 14px; text-decoration: none; color: var(--text); box-shadow: var(--shadow-sm); }
.map-card:hover { color: var(--text); border-color: var(--bronze-line); }
.map-card svg { border-radius: 12px; background: var(--bg-alt); }
.map-card__text { display: flex; flex-direction: column; }
.map-card__text strong { font-weight: 600; }
.map-card small { font-size: var(--fs-xs); color: var(--text-3); }
.contact-form { flex: 999 1 520px; min-width: 0; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: clamp(22px, 4vw, 40px); display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; align-content: start; box-shadow: var(--shadow-md); }
.field { display: flex; flex-direction: column; gap: 6px; }
.field--full { grid-column: 1 / -1; }
.field label { font-size: var(--fs-sm); font-weight: 600; color: var(--text); }
.field input, .field select, .field textarea { min-height: 52px; border: 1px solid var(--line); border-radius: 14px; padding: 0 16px; font-size: var(--fs-base); background: var(--bg); color: var(--text); transition: border-color .2s, box-shadow .2s, background-color .2s; width: 100%; }
.field textarea { padding-block: 14px; resize: vertical; min-height: 140px; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--bronze); background: var(--surface); box-shadow: 0 0 0 4px rgba(var(--accent-rgb), .16); }
.field .error { font-size: var(--fs-xs); color: var(--danger); }
.field--invalid input, .field--invalid textarea { border-color: var(--danger); }
.hp { position: absolute; inset-inline-start: -9999px; width: 1px; height: 1px; overflow: hidden; }
.contact-form .btn { grid-column: 1 / -1; min-height: 56px; }
.alert-success { grid-column: 1 / -1; display: flex; gap: 14px; align-items: flex-start; background: var(--alert-bg); border: 1px solid var(--alert-border); color: var(--alert-text); border-radius: var(--radius-sm); padding: 16px 18px; }
.alert-success strong { display: block; }

/* ---------- Footer ---------- */
.site-footer { background: var(--bg-deep); color: var(--text-2); padding: clamp(64px, 8vw, 88px) 0 28px; border-top: 1px solid var(--line); }
.site-footer__top { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 40px; }
.site-footer__about { flex: 1 1 300px; max-width: 420px; display: flex; flex-direction: column; gap: 16px; font-size: var(--fs-base); }
.site-footer .brand__name { font-size: 22px; }
.site-footer .brand__sub { font-size: var(--fs-xs); }
.site-footer__cols { display: flex; flex-wrap: wrap; gap: 40px 72px; font-size: var(--fs-base); }
.site-footer__col { display: flex; flex-direction: column; gap: 2px; }
.site-footer__col strong { color: var(--text); font-weight: 700; margin-bottom: 8px; }
.site-footer__col a, .site-footer__col span { color: var(--text-2); text-decoration: none; min-height: 36px; display: flex; align-items: center; }
.site-footer__col a:hover { color: var(--bronze-ink); }
/* أيقونات التواصل: القيم المطلوبة للتذييل الغامق، ومقابلها بالحبر الداكن حين يكون التذييل فاتحاً */
.socials { --social-line: rgba(var(--ink-rgb), .15); --social-ink: rgba(var(--ink-rgb), .75); display: flex; flex-wrap: wrap; gap: 10px; }
:root[data-theme="dark"] .site-footer .socials, .tone-dark .socials { --social-line: rgba(255, 255, 255, .15); --social-ink: rgba(255, 255, 255, .75); }
.socials a { width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--social-line); display: inline-flex; align-items: center; justify-content: center; color: var(--social-ink); transition: background-color .2s, border-color .2s, color .2s, transform .2s; }
.socials a:hover { background: #B18048; border-color: #B18048; color: #fff; transform: translateY(-2px); }
.socials a:focus-visible { outline: 2px solid #C99D66; outline-offset: 3px; }
.socials svg { width: 18px; height: 18px; }
.site-footer__col .contact-line { gap: 10px; }
.site-footer__col .contact-line > span { min-height: 0; display: inline; color: inherit; }
.contact-line__icon { width: 18px; height: 18px; flex: none; color: var(--bronze-ink); }
.site-footer__bottom { margin-top: 48px; border-top: 1px solid var(--line-strong); padding-top: 22px; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; font-size: var(--fs-xs); color: var(--text-3); }
.site-footer__legal { display: flex; flex-wrap: wrap; gap: 4px 16px; }
.site-footer__bottom-links { display: flex; flex-wrap: wrap; gap: 4px 20px; }
.site-footer__bottom-links a { color: var(--text-3); text-decoration: none; }
.site-footer__bottom-links a:hover { color: var(--bronze-ink); }
.developer-credit { display: inline-flex; align-items: center; gap: 8px; }
.developer-credit__dot { width: 5px; height: 5px; border-radius: 50%; background: currentColor; opacity: .6; }
.developer-credit a { color: inherit; text-decoration: none; font-weight: 600; }
.developer-credit a:hover { color: var(--bronze-ink); }

.wa-float { position: fixed; bottom: 24px; inset-inline-start: 24px; z-index: 40; width: 60px; height: 60px; border-radius: 50%; background: var(--bronze); color: var(--on-accent); display: flex; align-items: center; justify-content: center; box-shadow: 0 14px 30px -10px rgba(var(--accent-rgb), .75); transition: transform .3s var(--ease), background-color .3s; }
.wa-float:hover { transform: scale(1.06); background: var(--accent-hover); color: var(--on-accent); }
/* نبض: حلقتان تتسعان وتتلاشيان بالتناوب، ويتوقف عند المرور (ومع تقليل الحركة) */
.wa-float::before,
.wa-float::after { content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit; background: var(--bronze); animation: wa-pulse 2.4s var(--ease) infinite; pointer-events: none; }
.wa-float::after { animation-delay: 1.2s; }
.wa-float:hover::before,
.wa-float:hover::after { animation-play-state: paused; opacity: 0; }
@keyframes wa-pulse { 0% { opacity: .5; transform: scale(1); } 80%, 100% { opacity: 0; transform: scale(1.8); } }

/* ---------- Page hero (المشاريع والأخبار) ---------- */
.page-hero { position: relative; isolation: isolate; margin-top: calc(-1 * var(--header-h) - 1px); height: 560px; overflow: hidden; display: flex; align-items: flex-end; background: var(--bg-alt); }
.page-hero .hero__bg { z-index: -2; }
.page-hero .hero__scrim { position: absolute; inset: 0; z-index: -1; }
.page-hero--project { height: 520px; }
.page-hero__content { position: relative; width: 100%; padding-bottom: 56px; display: flex; flex-direction: column; gap: 16px; }
.page-hero__content h1 { font-size: var(--fs-h1); max-width: 900px; }
.page-hero__content .lead { max-width: 680px; }
.page-hero__status { align-self: flex-start; }
.crumbs { display: flex; flex-wrap: wrap; gap: 8px; font-size: var(--fs-sm); color: var(--text-3); }
.crumbs a { color: var(--text-2); text-decoration: none; }
.crumbs a:hover { color: var(--bronze-ink); }
.crumbs [aria-current] { color: var(--bronze-ink); font-weight: 500; }

/* ---------- Projects page ---------- */
.stats-wrap { padding-bottom: 32px; }
.stats--bar { border-bottom: 1px solid var(--line); }
.stats--bar .stat { padding-block: 24px; }
.map-wrap { display: flex; flex-wrap: wrap; gap: 48px; align-items: center; }
.map-wrap__copy { flex: 1 1 340px; display: flex; flex-direction: column; gap: 16px; }
.map-wrap__copy h2 { font-size: var(--fs-h2); }
.map-wrap__copy > p { font-size: var(--fs-lead); }
.bars { display: flex; flex-direction: column; gap: 12px; margin-top: 8px; }
.bar__row { display: flex; justify-content: space-between; font-size: var(--fs-base); color: var(--text-2); }
.bar__row b { color: var(--bronze-ink); font-weight: 700; }
.bar__track { height: 6px; border-radius: 3px; background: var(--line); overflow: hidden; margin-top: 6px; }
.bar__fill { height: 100%; border-radius: 3px; background: var(--accent-gradient); }
[dir="rtl"] .bar__fill { transform-origin: right; }
[dir="ltr"] .bar__fill { transform-origin: left; }
.map-card-lg { flex: 999 1 540px; min-width: 0; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 24px; position: relative; box-shadow: var(--shadow-md); }
.map-card-lg__note { position: absolute; top: 26px; inset-inline-start: 30px; font-size: var(--fs-xs); color: var(--text-3); }
.map-svg { display: block; width: 100%; height: auto; }
.map-svg .label { font-family: var(--font); font-size: 14px; font-weight: 600; fill: var(--text-2); }
.map-svg .label--hq { font-size: 16px; font-weight: 700; fill: var(--text); }
.map-svg .count { font-family: var(--font); font-weight: 700; }
.toolbar { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 20px; margin-bottom: 24px; }
.toolbar__title { display: flex; flex-direction: column; gap: 12px; }
.toolbar h2 { font-size: var(--fs-h2); }
.segmented { display: flex; background: var(--surface); border: 1px solid var(--line); border-radius: 999px; padding: 4px; gap: 4px; box-shadow: var(--shadow-sm); }
.segmented a { min-height: 44px; padding-inline: 22px; border-radius: 999px; font-size: var(--fs-base); display: inline-flex; align-items: center; gap: 8px; text-decoration: none; color: var(--text-2); font-weight: 500; }
.segmented a small { opacity: .7; }
.segmented a[aria-current="true"] { background: var(--text); color: var(--bg); font-weight: 600; }
.filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 28px; }
.filter { min-height: 42px; padding-inline: 16px; border: 1px solid var(--line-strong); background: var(--surface); border-radius: 999px; font-size: var(--fs-sm); display: inline-flex; align-items: center; gap: 6px; text-decoration: none; color: var(--text-2); }
.filter:hover { border-color: var(--bronze); color: var(--text); }
.filter[aria-current="true"] { background: var(--bronze); border-color: var(--bronze); color: var(--on-accent); font-weight: 600; }
.filter small { opacity: .75; font-size: var(--fs-xs); direction: ltr; }
.project-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(340px, 100%), 1fr)); gap: 16px; }
.project-card { height: 100%; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-md); display: flex; flex-direction: column; overflow: hidden; text-decoration: none; color: inherit; box-shadow: var(--shadow-sm); transition: transform .5s var(--ease), box-shadow .5s, border-color .5s; }
.project-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); border-color: var(--bronze-line); color: inherit; }
.project-card__media { height: 200px; overflow: hidden; }
.project-card__media img { width: 100%; height: 100%; object-fit: cover; }
.project-card__body { padding: 24px; display: flex; flex-direction: column; gap: 14px; flex: 1; }
.project-card__top { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.project-card__icon { width: 46px; height: 46px; border-radius: 14px; background: var(--bronze-soft); color: var(--bronze-ink); display: flex; align-items: center; justify-content: center; }
.status { font-size: 12px; font-weight: 600; padding: 4px 12px; border-radius: 999px; }
.status--active { background: var(--success-soft); color: var(--success-ink); }
.status--completed { background: var(--bg-alt); color: var(--text-2); }
.project-card__title { flex: 1; font-size: var(--fs-md); line-height: 1.6; font-weight: 600; color: var(--text); }
.project-card__meta { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; padding-top: 14px; border-top: 1px solid var(--line); font-size: var(--fs-xs); color: var(--text-3); }
.project-card__meta span:first-child { display: flex; align-items: center; gap: 6px; }
.project-card__meta .chip { padding: 2px 12px; }
.empty-state { text-align: center; padding: 40px; color: var(--text-3); }

.cta-section { padding-block: clamp(72px, 9vw, 112px); background: var(--bg); }
.cta-band { display: flex; flex-wrap: wrap; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-md); }
.cta-band__body { flex: 999 1 460px; min-width: 0; padding: clamp(32px, 5vw, 60px) clamp(24px, 4vw, 52px); display: flex; flex-direction: column; gap: 16px; justify-content: center; }
.cta-band__body h2 { font-size: var(--fs-h2); }
.cta-band__body p { font-size: var(--fs-lead); color: var(--text-3); }
.cta-band__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 6px; }
.cta-band__media { flex: 1 1 340px; min-height: 340px; }
.cta-band__media img { width: 100%; height: 100%; object-fit: cover; object-position: center 25%; }
.cta-band--simple .cta-band__body { align-items: center; text-align: center; }

/* سطر السرية في صفحة المشاريع */
.confidential-note { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 16px 24px; max-width: 880px; margin-inline: auto; padding: clamp(24px, 4vw, 36px); border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--surface); box-shadow: var(--shadow-sm); text-align: center; }
.confidential-note__icon { display: grid; place-items: center; width: 48px; height: 48px; border-radius: 50%; background: var(--bronze-soft); color: var(--bronze-ink); flex: none; }
.confidential-note p { flex: 1 1 360px; margin: 0; color: var(--text-2); font-size: var(--fs-md); line-height: var(--lh-body); text-align: start; }

/* ============ فريق العمل ============ */
.team-count { align-self: flex-start; display: inline-flex; align-items: center; gap: 8px; margin-top: 8px; padding: 6px 14px; border-radius: 999px; background: var(--glass); border: 1px solid var(--glass-border); color: var(--text); font-size: var(--fs-sm); font-weight: 600; -webkit-backdrop-filter: var(--blur); backdrop-filter: var(--blur); }
.team-count::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--bronze); }

/* الصورة: إطار رأسي 4:5 موحّد، بديل بالحروف الأولى، وتكبير هادئ عند المرور */
.team-photo { position: relative; display: block; width: 100%; aspect-ratio: 4 / 5; padding: 0; border: 0; overflow: hidden; background: linear-gradient(160deg, var(--bg-alt), var(--bg-deep)); border-radius: var(--radius-md); font: inherit; color: inherit; }
button.team-photo { cursor: pointer; }
.team-photo img { width: 100%; height: 100%; object-fit: cover; object-position: center 20%; transition: transform .9s var(--ease), filter .6s; }
.team-photo::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(var(--ink-rgb), .42), transparent 45%); opacity: 0; transition: opacity .5s; pointer-events: none; }
button.team-photo:hover img, button.team-photo:focus-visible img { transform: scale(1.045); }
button.team-photo:hover::after, button.team-photo:focus-visible::after { opacity: 1; }
.team-photo__hint { position: absolute; inset-block-end: 16px; inset-inline-end: 16px; z-index: 1; display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: var(--surface); color: var(--text); font-size: 22px; line-height: 1; box-shadow: var(--shadow-sm); transform: scale(.85); opacity: 0; transition: transform .4s var(--ease), opacity .4s; }
button.team-photo:hover .team-photo__hint, button.team-photo:focus-visible .team-photo__hint { transform: none; opacity: 1; }
.avatar-initials { position: absolute; inset: 0; display: grid; place-items: center; font-size: clamp(36px, 5vw, 64px); font-weight: 700; letter-spacing: .04em; color: var(--bronze-ink); opacity: .55; }

/* القيادة: بطاقات كبيرة */
.leaders { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(20px, 3vw, 40px); }
.leaders--1 { grid-template-columns: minmax(0, 420px); justify-content: center; }
.leaders--2 { grid-template-columns: repeat(2, minmax(0, 440px)); justify-content: center; }
.leader { display: flex; flex-direction: column; gap: 22px; }
.leader__photo { border-radius: var(--radius-lg); box-shadow: var(--shadow-md); }
.leader__body { display: flex; flex-direction: column; gap: 8px; padding-inline: 4px; }
.leader__position { color: var(--bronze-ink); font-size: var(--fs-sm); font-weight: 600; letter-spacing: .01em; }
.leader__name { font-size: var(--fs-h3); line-height: var(--lh-tight); color: var(--text); margin: 0; }
.leader__bio { color: var(--text-3); font-size: var(--fs-base); margin: 4px 0 0; }
.leader__actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin-top: 8px; padding-top: 14px; border-top: 1px solid var(--line); }
.link-arrow { display: inline-flex; align-items: center; gap: 8px; padding: 0; border: 0; background: none; color: var(--text); font: inherit; font-weight: 600; cursor: pointer; }
.link-arrow .arrow { transition: transform .35s var(--ease); }
.link-arrow:hover { color: var(--bronze-ink); }
.link-arrow:hover .arrow { transform: translateX(-4px); }
[dir="ltr"] .link-arrow:hover .arrow { transform: translateX(4px); }

/* بقية الفريق حسب القسم */
.team-group + .team-group { margin-top: clamp(48px, 6vw, 72px); }
.team-group__title { display: flex; align-items: center; gap: 14px; margin: 0 0 28px; font-size: var(--fs-h3); color: var(--text); }
.team-group__title::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.team-group__title small { order: 1; min-width: 30px; padding: 2px 10px; border-radius: 999px; background: var(--bronze-soft); color: var(--bronze-ink); font-size: var(--fs-xs); font-weight: 700; text-align: center; }
.people { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(16px, 2.4vw, 32px) clamp(16px, 2vw, 28px); }
.person { display: flex; flex-direction: column; gap: 14px; }
.person__body { display: flex; flex-direction: column; gap: 4px; padding-inline: 2px; }
.person__name { margin: 0; font-size: var(--fs-md); line-height: var(--lh-tight); color: var(--text); }
.person__name button { padding: 0; border: 0; background: none; font: inherit; color: inherit; text-align: start; cursor: pointer; }
.person__name button:hover { color: var(--bronze-ink); }
.person__position { color: var(--text-3); font-size: var(--fs-sm); }
.person .member-links { margin-top: 6px; }

.member-links { display: flex; flex-wrap: wrap; gap: 8px; }
.member-links a { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-width: 34px; height: 34px; padding: 0 9px; border: 1px solid var(--line); border-radius: 999px; color: var(--text-2); text-decoration: none; transition: color .3s, border-color .3s, background-color .3s; }
.member-links a:hover { color: var(--bronze-ink); border-color: var(--bronze-line); background: var(--bronze-soft); }
.member-links--labels a { padding: 0 14px; font-size: var(--fs-sm); }

/* النبذة الكاملة: <dialog> أصلي */
.bio-dialog { width: min(960px, calc(100vw - 32px)); max-height: calc(100dvh - 48px); padding: 0; border: 0; border-radius: var(--radius-lg); background: var(--surface); color: var(--text-2); box-shadow: var(--shadow-lg); overflow: hidden; }
.bio-dialog::backdrop { background: rgba(var(--ink-rgb), .55); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.bio-dialog[open] { animation: bio-in .45s var(--ease); }
@keyframes bio-in { from { opacity: 0; transform: translateY(16px) scale(.98); } }
.bio-dialog__inner { position: relative; display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); max-height: inherit; }
.bio-dialog__media { position: relative; min-height: 100%; background: linear-gradient(160deg, var(--bg-alt), var(--bg-deep)); }
.bio-dialog__media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center 20%; }
.bio-dialog__body { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; padding: clamp(28px, 4vw, 52px); overflow-y: auto; max-height: calc(100dvh - 48px); }
.bio-dialog__name { margin: 0; font-size: var(--fs-h2); line-height: var(--lh-tight); color: var(--text); }
.bio-dialog__text { margin: 10px 0 6px; font-size: var(--fs-md); line-height: var(--lh-body); }
.bio-dialog__text p + p { margin-top: 12px; }
.bio-dialog__close { position: absolute; inset-block-start: 16px; inset-inline-end: 16px; z-index: 2; display: grid; place-items: center; width: 42px; height: 42px; border: 1px solid var(--line); border-radius: 50%; background: var(--glass-strong); color: var(--text); cursor: pointer; -webkit-backdrop-filter: var(--blur); backdrop-filter: var(--blur); transition: transform .3s var(--ease); }
.bio-dialog__close:hover { transform: rotate(90deg); }
html.has-dialog { overflow: hidden; }

@media (max-width: 1024px) {
  .leaders { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .leaders--1 { grid-template-columns: minmax(0, 420px); }
  .people { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 720px) {
  .leaders, .leaders--2 { grid-template-columns: minmax(0, 1fr); }
  .people { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .bio-dialog__inner { grid-template-columns: 1fr; overflow-y: auto; }
  .bio-dialog__media { aspect-ratio: 4 / 3; min-height: 0; }
  .bio-dialog__body { max-height: none; overflow: visible; }
}
.promo-band .cta-band__media img { width: 100%; height: 100%; object-fit: cover; }

/* Project detail */
.detail { display: flex; flex-wrap: wrap; gap: 40px; align-items: flex-start; }
.detail__main { flex: 999 1 540px; min-width: 0; display: flex; flex-direction: column; gap: 24px; }
.detail__main > p { font-size: var(--fs-md); color: var(--text-2); white-space: pre-line; }
.detail__scope { display: flex; flex-direction: column; gap: 14px; }
.detail__aside { flex: 1 1 300px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-md); padding: 28px; display: flex; flex-direction: column; gap: 18px; position: sticky; top: calc(var(--header-h) + 24px); box-shadow: var(--shadow-sm); }
.detail__aside dl { display: grid; gap: 14px; }
.detail__aside dt { font-size: var(--fs-xs); color: var(--text-3); }
.detail__aside dd { margin: 2px 0 0; font-size: var(--fs-base); color: var(--text); font-weight: 600; }
.detail__aside .btn { align-self: flex-start; }
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(200px, 100%), 1fr)); gap: 12px; }
.gallery a { border-radius: var(--radius-sm); overflow: hidden; aspect-ratio: 4 / 3; display: block; }
.gallery img { width: 100%; height: 100%; object-fit: cover; }

/* ---------- Announcement bar ---------- */
.announce { position: relative; z-index: 51; background: var(--accent-gradient); color: var(--on-accent); font-size: var(--fs-sm); }
.announce__inner { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 6px 14px; min-height: 42px; padding-block: 8px; text-align: center; }
.announce__dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; opacity: .6; }
.announce__text { font-weight: 600; }
.announce__link, .announce__link:hover { color: inherit; }
.announce__link { font-weight: 700; text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }
.announce__link:hover { text-decoration-thickness: 2px; }

/* ---------- News ---------- */
.page-hero--compact { height: 480px; }
.news-list { padding-top: clamp(48px, 6vw, 72px); }
.news-list__banner { margin-bottom: 48px; }
.post-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(320px, 100%), 1fr)); gap: 16px; }
.post-grid:not(:first-child) { margin-top: 16px; }

.post-card { height: 100%; display: flex; flex-direction: column; overflow: hidden; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-md); text-decoration: none; color: inherit; box-shadow: var(--shadow-sm); transition: transform .5s var(--ease), box-shadow .5s, border-color .5s; }
.post-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); border-color: var(--bronze-line); color: inherit; }
.post-card__media { aspect-ratio: 16 / 10; background: var(--bg-alt); display: flex; align-items: center; justify-content: center; }
.post-card__media img { width: 100%; height: 100%; object-fit: cover; }
.post-card__placeholder { opacity: .4; }
.post-card__body { flex: 1; padding: 24px 24px 26px; display: flex; flex-direction: column; gap: 12px; }
.post-card__title { font-size: var(--fs-h3); line-height: 1.45; font-weight: 700; color: var(--text); }
.post-card__excerpt { font-size: var(--fs-base); color: var(--text-2); display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.post-card__more { margin-top: auto; padding-top: 6px; font-size: var(--fs-sm); font-weight: 600; color: var(--bronze-ink); display: inline-flex; align-items: center; gap: 8px; }
.post-card__more .arrow { transition: transform .3s var(--ease); }
[dir="rtl"] .post-card:hover .post-card__more .arrow { transform: translateX(-4px); }
[dir="ltr"] .post-card:hover .post-card__more .arrow { transform: translateX(4px); }

.post-card--lead { flex-direction: row; flex-wrap: wrap; border-radius: var(--radius-lg); }
.post-card--lead .post-card__media { flex: 1 1 500px; aspect-ratio: auto; min-height: 400px; }
.post-card--lead .post-card__body { flex: 1 1 360px; justify-content: center; padding: clamp(26px, 4vw, 52px); gap: 16px; }
.post-card--lead .post-card__title { font-size: var(--fs-h2); line-height: var(--lh-tight); }
.post-card--lead .post-card__excerpt { font-size: var(--fs-md); -webkit-line-clamp: 4; }

.post-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; font-size: var(--fs-xs); color: var(--text-3); }
.post-meta .chip { padding: 3px 12px; font-size: 12px; }
.post-meta--hero { font-size: var(--fs-base); color: var(--text-2); }

.article-hero { height: 540px; }
.article-section { padding-top: clamp(40px, 5vw, 64px); }
.article { max-width: 740px; margin-inline: auto; display: flex; flex-direction: column; gap: 36px; }
.article__lead { font-size: clamp(19px, 1.8vw, 23px); line-height: 1.75; font-weight: 500; color: var(--text); padding-inline-start: 20px; border-inline-start: 3px solid var(--bronze); }
.article__gallery { display: flex; flex-direction: column; gap: 16px; }
.article__footer { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; padding-top: 26px; border-top: 1px solid var(--line); }
.article__share-label { font-size: var(--fs-sm); color: var(--text-3); }
.article__footer .btn { margin-inline-start: auto; }
.share { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.share a, .share__copy { min-width: 44px; height: 44px; border-radius: 999px; border: 1px solid var(--line-strong); display: inline-flex; align-items: center; justify-content: center; color: var(--text-2); background: var(--surface); text-decoration: none; transition: border-color .3s, color .3s; }
.share__copy { padding-inline: 16px; font-size: var(--fs-xs); cursor: pointer; }
.share a:hover, .share__copy:hover { border-color: var(--bronze); color: var(--bronze-ink); }
.share__copy.is-done { border-color: var(--bronze); color: var(--bronze-ink); }

/* المحتوى المنسّق القادم من المحرر */
.prose { font-size: var(--fs-md); line-height: 1.95; color: var(--text-2); overflow-wrap: break-word; }
.prose > * + * { margin-top: 1.1em; }
.prose h2, .prose h3 { color: var(--text); line-height: var(--lh-tight); margin-top: 1.8em; }
.prose h2 { font-size: var(--fs-h3); font-weight: 700; }
.prose h3 { font-size: clamp(18px, 1.6vw, 21px); font-weight: 700; }
.prose a { color: var(--bronze-ink); text-underline-offset: 3px; }
.prose strong { color: var(--text); font-weight: 600; }
.prose ul, .prose ol { padding-inline-start: 1.4em; }
.prose ul { list-style: disc; }
.prose ol { list-style: decimal; }
.prose li + li { margin-top: .4em; }
.prose li::marker { color: var(--bronze); }
.prose blockquote { margin: 1.6em 0; padding: 4px 0; padding-inline-start: 20px; border-inline-start: 3px solid var(--bronze); font-size: 1.12em; color: var(--text); }
.prose img { width: 100%; height: auto; border-radius: var(--radius-sm); margin-block: 1.4em; }
.prose figure { margin: 1.6em 0; }
.prose table { width: 100%; border-collapse: collapse; font-size: var(--fs-sm); display: block; overflow-x: auto; }
.prose th, .prose td { padding: 12px 14px; border-bottom: 1px solid var(--line); text-align: start; }
.prose th { color: var(--text); font-weight: 600; background: var(--bg-alt); }
.prose hr { border: 0; height: 1px; background: var(--line); margin-block: 2.4em; }

/* التنقل بين الصفحات */
.pager { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 10px; margin-top: 48px; }
.pager__pages { display: flex; gap: 6px; }
.pager__page, .pager__step, .pager__gap { min-width: 44px; min-height: 44px; padding-inline: 14px; border-radius: 999px; display: inline-flex; align-items: center; justify-content: center; font-size: var(--fs-sm); text-decoration: none; color: var(--text-2); }
.pager__page, .pager__step { border: 1px solid var(--line-strong); background: var(--surface); }
a.pager__page:hover, a.pager__step:hover { border-color: var(--bronze); color: var(--text); }
.pager__page[aria-current="page"] { background: var(--text); border-color: var(--text); color: var(--bg); font-weight: 700; }
.pager__step[aria-disabled="true"] { opacity: .4; }

/* ---------- Interaction helpers ---------- */
.zoom { overflow: hidden; }
.zoom img { transition: transform 1.2s var(--ease); }
.zoom:hover img { transform: scale(1.05); }
.lift { transition: transform .5s var(--ease), box-shadow .5s, border-color .5s; }
.lift:hover { transform: translateY(-5px); box-shadow: var(--shadow-lg); }
.pulse { transform-origin: center; transform-box: fill-box; animation: pulse 2.6s ease-out infinite; }
@keyframes pulse { 0% { opacity: .55; transform: scale(1); } 100% { opacity: 0; transform: scale(2.6); } }
.dash { stroke-dasharray: 4 6; animation: dash 1.6s linear infinite; }
@keyframes dash { to { stroke-dashoffset: -20; } }

/* ---------- Scroll reveal ---------- */
/* يعمل عبر IntersectionObserver في site.js؛ بدون JavaScript يظهر كل شيء طبيعياً */
.js [data-reveal] { opacity: 0; transition: opacity .9s var(--ease), transform .9s var(--ease), clip-path 1.2s var(--ease); will-change: opacity, transform; }
.js [data-reveal="up"] { transform: translateY(40px); }
.js [data-reveal="scale"] { transform: scale(.95); }
.js [data-reveal="image"] { opacity: 1; clip-path: inset(12% 8% 12% 8% round 32px); }
.js [data-reveal="image"] img { transform: scale(1.1); transition: transform 1.4s var(--ease); }
.js [data-reveal].is-visible { opacity: 1; transform: none; clip-path: inset(0 0 0 0 round 0); }
.js [data-reveal="image"].is-visible img { transform: none; }
.js [data-reveal-delay="1"] { transition-delay: .08s; }
.js [data-reveal-delay="2"] { transition-delay: .16s; }
.js [data-reveal-delay="3"] { transition-delay: .24s; }
.js .bar__fill { transform: scaleX(0); transition: transform 1.2s var(--ease); }
.js .is-visible .bar__fill, .js .bars.is-visible .bar__fill { transform: scaleX(1); }

@supports (animation-timeline: scroll()) {
  .parallax { animation: parallax linear both; animation-timeline: scroll(); animation-range: 0 900px; }
  @keyframes parallax { to { transform: translateY(160px) scale(1.06); } }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .js [data-reveal] { opacity: 1 !important; transform: none !important; clip-path: none !important; }
  .js [data-reveal] img { transform: none !important; }
  .js .bar__fill { transform: none !important; }
}

/* ---------- Tablet ---------- */
@media (max-width: 1024px) {
  .about__media { min-height: 560px; }
  .about__img-main { height: 480px; }
  .service-feature__media { min-height: 360px; flex-basis: 100%; }
  .quote-band figure { height: 440px; }
  .detail__aside { position: static; }
}

/* ---------- Mobile ---------- */
@media (max-width: 720px) {
  :root { --gutter: 18px; --header-h: 64px; }
  .site-header__inner { gap: 12px; }
  .brand__name { font-size: 16px; }
  .btn { min-height: 50px; padding-inline: 22px; }
  .about__media { min-height: 460px; }
  .about__img-main { height: 380px; width: 82%; }
  .about__img-sub { height: 200px; width: 58%; border-width: 6px; }
  .about__since { padding: 14px 18px; }
  .about__since strong { font-size: 32px; }
  .teaser__stats { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
  .mini-stat { padding: 18px 12px; }
  .mini-stat strong { font-size: 28px; }
  .field-card { height: 420px; }
  .quote-band figure { height: 320px; }
  .service-feature .service-no { font-size: 48px; }
  .service-card__body { padding: 24px 22px 28px; }
  .page-hero { height: 460px; }
  .page-hero--compact { height: 420px; }
  .article-hero { height: 460px; }
  .page-hero__content { padding-bottom: 40px; }
  .segmented { width: 100%; }
  .segmented a { flex: 1; justify-content: center; padding-inline: 12px; }
  .post-card--lead .post-card__media { min-height: 240px; flex-basis: 100%; }
  .article__footer .btn { margin-inline-start: 0; }
  .pager__pages { order: -1; width: 100%; justify-content: center; }
  .profile-cta__body { flex-direction: column; align-items: flex-start; }
  .contact-form { grid-template-columns: 1fr; }
}
/* زر الشات العائم على الجوال: مساحته (16 + 54px) محجوزة لأدوات السلايدر في .hx__nav */
@media (max-width: 767px) {
  .wa-float { width: 54px; height: 54px; bottom: 20px; inset-inline-start: 16px; }
}
