/* ============================================================
   OPTIIIMUM — HOME PAGE
   Bilingual (EN / AR · LTR / RTL) · Light & dark themes
   ============================================================ */

:root {
  /* Brand spectrum */
  --grad-1: #FDD196;
  --grad-2: #FF966D;
  --grad-3: #E555C8;
  --grad-4: #BE6FD2;
  --grad-5: #54B3EC;
  --grad-6: #00FEFF;

  /* Light theme tokens (default) */
  --bg:           #FAFAF7;
  --bg-band:     #F1EFE9;
  --bg-elev:     #FFFFFF;
  --ink:         #0A0A0A;
  --ink-2:       #3D3D3A;
  --ink-3:       #7A7770;
  --line:        #E6E3DB;
  --line-strong: #C9C5BB;
  --cta:         #0A0A0A;
  --cta-ink:     #FAFAF7;
  --accent:      #E555C8;
  --shadow-1:    0 1px 2px rgba(0,0,0,.04), 0 8px 24px rgba(0,0,0,.06);
  --shadow-2:    0 1px 2px rgba(0,0,0,.04), 0 22px 48px rgba(0,0,0,.08);
  --logo-mono:   #1F1F1F;
  --glow:        rgba(229,85,200,.18);

  --r-sm: 8px;
  --r:    14px;
  --r-lg: 22px;
  --r-xl: 32px;

  --maxw: 1280px;
  --pad:  clamp(20px, 4vw, 56px);

  /* Typography system — futuristic premium
     Display:  Space Grotesk 600/700  (futuristic geometric sans)
     Body:     Space Grotesk 400/500
     Accent:   Instrument Serif italic — used ONLY on .alt highlight words
     Mono:     JetBrains Mono — labels, eyebrows, numerics
     Arabic:   IBM Plex Sans Arabic — premium modern Arabic */
  --font-sans: "DM Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  --font-display: "Instrument Serif", Georgia, serif;
  --font-serif: "Instrument Serif", Georgia, serif;
  --font-mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;
  --font-ar: "IBM Plex Sans Arabic", "Tajawal", "Segoe UI", Tahoma, sans-serif;

  --tr-display: -.005em;
  --tr-tight: -.005em;
  --tr-mono: .14em;
}

[data-theme="dark"] {
  --bg:           #0B0B0B;
  --bg-band:     #141413;
  --bg-elev:     #161616;
  /* Text rule: WHITE · GRADIENT · LIGHT GREY only */
  --ink:         #FFFFFF;       /* white */
  --ink-2:       #D4D4D8;       /* light grey */
  --ink-3:       #A1A1AA;       /* light grey (softer) */
  --line:        #2A2A28;
  --line-strong: #3A3A36;
  --cta:         #FFFFFF;
  --cta-ink:     #0B0B0B;
  --accent:      #FF8FE0;
  --shadow-1:    0 1px 2px rgba(0,0,0,.4), 0 12px 32px rgba(0,0,0,.45);
  --shadow-2:    0 1px 2px rgba(0,0,0,.4), 0 28px 60px rgba(0,0,0,.55);
  --logo-mono:   #B8B5AE;
  --glow:        rgba(229,85,200,.28);
}

/* ============================================================
   TEXT COLOR RULE (dark theme)
   All written text must be one of:
     · white         (.text-white / default body)
     · light grey    (.text-mute / --ink-2 / --ink-3)
     · brand gradient (.text-grad / .alt)
   No dark text on light pills allowed.
   ============================================================ */
[data-theme="dark"] .text-grad,
[data-theme="dark"] .grad-text,
[data-theme="dark"] .alt {
  background: linear-gradient(120deg, var(--grad-1), var(--grad-2), var(--grad-3), var(--grad-4), var(--grad-5), var(--grad-6));
  -webkit-background-clip: text; background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
}
[data-theme="dark"] .text-white { color: #FFFFFF !important; }
[data-theme="dark"] .text-mute  { color: var(--ink-2) !important; }

* { box-sizing: border-box; }

html, body {
  margin: 0; padding: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  transition: background-color .25s ease, color .25s ease;
}

html[lang="ar"] { font-family: var(--font-ar); line-height: 1.7; }
html[lang="ar"] body { font-family: var(--font-ar); }

a { color: inherit; text-decoration: none; }

img { display: block; max-width: 100%; }

/* ============= i18n visibility ============= */
html[lang="en"] .i18n-ar { display: none !important; }
html[lang="ar"] .i18n-en { display: none !important; }

/* ============================================================
   LAYOUT PRIMITIVES
   ============================================================ */
.container { max-width: var(--maxw); margin: 0 auto; padding: 0 var(--pad); }

.section { padding: clamp(64px, 9vw, 120px) 0; }
.section + .section { border-top: 1px solid var(--line); }
.section.band { background: var(--bg-band); }

.eyebrow {
  font-family: var(--font-mono);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .14em;
  color: var(--ink-3);
}
html[lang="ar"] .eyebrow { font-family: var(--font-mono); letter-spacing: .08em; }

h1, h2, h3 {
  font-family: var(--font-sans);
  font-weight: 700;
  letter-spacing: -.022em;
  line-height: 1.02;
  margin: 0;
  text-wrap: balance;
}
h1 { font-weight: 700; }
h2 { font-weight: 700; }
h3 { font-weight: 600; letter-spacing: -.015em; line-height: 1.1; }
html[lang="ar"] h1, html[lang="ar"] h2, html[lang="ar"] h3 {
  font-family: var(--font-ar); font-weight: 700; line-height: 1.25; letter-spacing: 0;
}

h1 { font-size: clamp(40px, 7vw, 88px); text-wrap: balance; }
h2 { font-size: clamp(32px, 5vw, 56px); text-wrap: balance; }
h3 { font-size: clamp(22px, 2.4vw, 30px); }

.lede { color: var(--ink-2); font-size: clamp(16px, 1.4vw, 19px); max-width: 62ch; text-wrap: pretty; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 14px 22px; border-radius: 999px;
  font: inherit; font-weight: 500; font-size: 14.5px;
  cursor: pointer; border: 1px solid transparent;
  transition: transform .15s ease, background .15s ease, color .15s ease, border-color .15s ease, box-shadow .15s ease;
  white-space: nowrap;
}
.btn-primary { background: var(--cta); color: var(--cta-ink); }
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 0 0 6px var(--glow); }
/* Dark theme: primary CTA inverts to gradient-on-black so on-button text stays white */
[data-theme="dark"] .btn-primary {
  background:
    linear-gradient(#0B0B0B,#0B0B0B) padding-box,
    linear-gradient(120deg, var(--grad-1), var(--grad-2), var(--grad-3), var(--grad-4), var(--grad-5), var(--grad-6)) border-box;
  border: 1px solid transparent;
  color: #FFFFFF;
}
[data-theme="dark"] .btn-primary:hover {
  background:
    linear-gradient(120deg, var(--grad-1), var(--grad-2), var(--grad-3), var(--grad-4), var(--grad-5), var(--grad-6)) padding-box,
    linear-gradient(120deg, var(--grad-1), var(--grad-2), var(--grad-3), var(--grad-4), var(--grad-5), var(--grad-6)) border-box;
  color: #FFFFFF;
}
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--line-strong); }
.btn-ghost:hover { border-color: var(--ink); }
.btn-sm { padding: 9px 16px; font-size: 13px; }
.btn .arrow { transition: transform .15s ease; }
html[lang="ar"] .btn .arrow { transform: scaleX(-1); }
.btn:hover .arrow { transform: translateX(3px); }
html[lang="ar"] .btn:hover .arrow { transform: translateX(-3px) scaleX(-1); }
.btn .arrow { transition: transform .15s ease; }
html[lang="ar"] .btn .arrow { transform: scaleX(-1); }
.btn:hover .arrow { transform: translateX(3px); }
html[lang="ar"] .btn:hover .arrow { transform: translateX(-3px) scaleX(-1); }

/* Chip */
.chip {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 10px; border-radius: 999px;
  font-size: 11.5px; line-height: 1; font-family: var(--font-mono);
  border: 1px solid var(--line); background: var(--bg-elev); color: var(--ink-2);
}
.chip.ink { background: var(--ink); color: var(--bg); border-color: var(--ink); }
[data-theme="dark"] .chip.ink { background: #1F1F1F; color: #FFFFFF; border-color: #2A2A28; }
.chip.miss { background: rgba(229,85,200,.08); color: var(--accent); border-color: rgba(229,85,200,.3); }

/* ============================================================
   HEADER — floating pill topbar with gradient wordmark + CTA
   ============================================================ */
.topbar {
  position: sticky; top: 16px; z-index: 50;
  background: transparent;
  backdrop-filter: none;
  border: 0;
  padding: 0 var(--pad);
  margin-top: 16px;
}
.topbar > .container { padding: 0; }
.topbar-inner {
  display: flex; align-items: center; gap: 14px;
  padding: 8px 8px 8px 22px;
  background: #0E0E0E;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 999px;
  box-shadow: 0 10px 30px rgba(0,0,0,.45);
}
[data-theme="light"] .topbar-inner {
  background: #FFFFFF;
  border-color: rgba(0,0,0,.08);
  box-shadow: 0 10px 30px rgba(0,0,0,.06);
}

/* Wordmark — official logo (image with CSS mask for color variants) */
.brand-link {
  display: inline-flex; align-items: center; gap: 0;
  border: 0; padding: 4px 0; margin-inline-end: 10px;
  line-height: 1;
}
.brand-mark { display: none; }
.brand-name {
  display: inline-block;
  width: clamp(110px, 9vw, 150px);
  aspect-ratio: 738 / 118;
  background: linear-gradient(95deg,
    #FDD196 0%, #FF966D 16%, #E555C8 36%,
    #BE6FD2 54%, #54B3EC 72%, #00FEFF 92%);
  -webkit-mask: url("assets/logo.png") left center / contain no-repeat;
          mask: url("assets/logo.png") left center / contain no-repeat;
  /* hide any inner text (legacy markup) */
  font-size: 0; color: transparent;
}
.brand-name .dot, .brand-name .tm { display: none; }
.brand-name--white { background: #FFFFFF; }
.brand-name--black { background: #0A0A0A; }
.foot-col .brand-name { width: clamp(140px, 11vw, 180px); }

/* Primary nav inside the pill */
.primary-nav {
  display: flex; align-items: center; gap: 1px;
  margin: 0 auto;
  flex: 0 1 auto;
  overflow: hidden;
}
.primary-nav a {
  padding: 8px 12px;
  border-radius: 999px;
  font-size: 13.5px; font-weight: 500;
  color: rgba(255,255,255,.72);
  border: 0;
  transition: color .15s, background .15s;
  white-space: nowrap;
}
[data-theme="light"] .primary-nav a { color: rgba(0,0,0,.65); }
.primary-nav a:hover { color: #FFFFFF; background: rgba(255,255,255,.06); }
[data-theme="light"] .primary-nav a:hover { color: #0A0A0A; background: rgba(0,0,0,.05); }
.primary-nav a[aria-current="page"] {
  background: linear-gradient(120deg, var(--grad-1), var(--grad-2), var(--grad-3), var(--grad-4), var(--grad-5), var(--grad-6));
  color: #0A0A0A;
  font-weight: 600;
}
[data-theme="light"] .primary-nav a[aria-current="page"] { color: #0A0A0A; }

/* Right-side actions */
.topbar-actions { display: flex; align-items: center; gap: 6px; margin-inline-start: 0; }
.topbar-actions .icon-btn {
  width: 36px; height: 36px;
  background: transparent;
  border-color: rgba(255,255,255,.12);
  color: rgba(255,255,255,.7);
}
[data-theme="light"] .topbar-actions .icon-btn { border-color: rgba(0,0,0,.12); color: rgba(0,0,0,.7); }
.topbar-actions .icon-btn:hover { color: #FFFFFF; border-color: rgba(255,255,255,.35); }
[data-theme="light"] .topbar-actions .icon-btn:hover { color: #0A0A0A; border-color: rgba(0,0,0,.35); }
.topbar-actions .lang-btn { width: auto; padding: 0 12px; font-family: var(--font-mono); font-size: 11px; letter-spacing: .08em; }

/* Nav CTA — gradient pill button */
.nav-cta {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 10px 18px;
  border-radius: 999px;
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 14px;
  letter-spacing: -.005em;
  color: #0A0A0A;
  border: 0;
  background: linear-gradient(120deg, var(--grad-1), var(--grad-2), var(--grad-3), var(--grad-4), var(--grad-5), var(--grad-6));
  background-size: 200% 200%;
  background-position: 0% 50%;
  transition: background-position .5s ease, transform .15s ease, box-shadow .15s ease;
  white-space: nowrap;
}
.nav-cta:hover {
  background-position: 100% 50%;
  transform: translateY(-1px);
  box-shadow: 0 8px 22px rgba(229,85,200,.25);
  color: #0A0A0A;
}
.nav-cta .arrow {
  display: inline-flex; align-items: center; justify-content: center;
  width: 22px; height: 22px; border-radius: 50%;
  background: rgba(0,0,0,.18);
  font-size: 13px; line-height: 1;
}
html[lang="ar"] .nav-cta .arrow { transform: scaleX(-1); }

/* RTL: flip wordmark dot position not needed; lowercase wordmark stays LTR. */
html[lang="ar"] .brand-link { direction: ltr; }

@media (max-width: 1180px) {
  /* keep language button visible on tablet/phone — it's how users switch to Arabic */
  .primary-nav a { padding: 7px 10px; font-size: 13px; }
}
@media (max-width: 1024px) {
  .primary-nav { display: none; }
  .menu-toggle { display: inline-flex !important; }
}
@media (max-width: 880px) {
  .topbar-inner { padding: 8px 8px 8px 16px; gap: 10px; }
  .nav-cta { padding: 9px 14px; font-size: 13px; }
  .nav-cta .arrow { display: none; }
}
@media (max-width: 640px) {
  /* Compact topbar so brand + lang + theme + CTA + hamburger all fit on iPhone widths */
  .topbar { top: 8px; margin-top: 8px; }
  .topbar-inner { gap: 6px; padding: 6px 6px 6px 14px; }
  .brand-link { margin-inline-end: 4px; }
  .brand-name { width: 92px; }
  .topbar-actions { gap: 4px; }
  .topbar-actions .icon-btn { width: 32px; height: 32px; font-size: 13px; }
  .topbar-actions .lang-btn { width: auto; padding: 0 9px; font-size: 10px; letter-spacing: .06em; }
  .nav-cta {
    padding: 0; width: 32px; height: 32px;
    border-radius: 999px;
    display: inline-flex; align-items: center; justify-content: center;
    font-size: 0;
  }
  .nav-cta::after {
    content: "→"; font-size: 15px; line-height: 1; color: inherit;
  }
  html[lang="ar"] .nav-cta::after { content: "←"; }
  .nav-cta span { display: none !important; }
  .nav-cta .arrow { display: none !important; }
}
@media (max-width: 380px) {
  /* Tiny screens — hide CTA entirely to avoid wrapping; user still has it inside mobile menu */
  .topbar-actions .nav-cta { display: none; }
}

@media (max-width: 880px) {
  .primary-nav { display: none; }
  .menu-toggle { display: inline-flex !important; }
}
.menu-toggle { display: none; }

.mobile-menu {
  position: fixed; inset: 0;
  background: var(--bg);
  z-index: 60; padding: 80px var(--pad) 40px;
  display: flex; flex-direction: column; gap: 4px;
  opacity: 0;
  pointer-events: none;
  transform: translateY(-12px);
  transition: opacity .28s ease, transform .28s ease;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}
.mobile-menu.open {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}
.mobile-menu a {
  font-family: var(--font-sans); font-weight: 700; letter-spacing: -.02em; font-size: 32px;
  padding: 8px 0; border-bottom: 1px solid var(--line);
}
html[lang="ar"] .mobile-menu a { font-family: var(--font-ar); font-weight: 600; }
.mobile-close {
  position: fixed; top: 16px; inset-inline-end: 16px; z-index: 70;
}

/* Mobile-menu toolbar (lang, theme, CTA) injected by nav-slider.js */
.mm-tools {
  display: grid;
  grid-template-columns: auto auto 1fr;
  gap: 10px;
  align-items: stretch;
  margin-bottom: 24px;
}
.mm-tool {
  display: inline-flex; align-items: center; justify-content: center;
  gap: 8px;
  height: 44px;
  padding: 0 14px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--bg-elev);
  color: var(--ink);
  font: 500 13px/1 var(--font-mono);
  letter-spacing: .06em;
  text-decoration: none;
  cursor: pointer;
  transition: border-color .2s, background .2s, color .2s;
}
.mm-tool:hover { border-color: var(--ink-2); }
html[lang="ar"] .mm-tool { font-family: var(--font-ar); letter-spacing: 0; }

.mm-tool.mm-lang { padding: 0 16px; font-weight: 600; }
.mm-tool.mm-theme { padding: 0 14px; }
.mm-theme-icon { font-size: 16px; line-height: 1; }
.mm-tool.mm-cta {
  background: linear-gradient(120deg, var(--grad-1), var(--grad-2), var(--grad-3), var(--grad-4), var(--grad-5), var(--grad-6));
  background-size: 200% 200%;
  background-position: 0% 50%;
  border: 0;
  color: #0A0A0A;
  font-weight: 700;
  font-family: var(--font-sans);
  letter-spacing: -.01em;
  font-size: 14px;
  padding: 0 18px;
}
html[lang="ar"] .mm-tool.mm-cta { font-family: var(--font-ar); }
.mm-cta-arrow { font-size: 14px; }
html[lang="ar"] .mm-cta-arrow { transform: scaleX(-1); }

/* ============================================================
   HERO
   ============================================================ */
.hero {
  position: relative; overflow: hidden;
  padding: clamp(80px, 14vw, 160px) 0 clamp(60px, 10vw, 110px);
  isolation: isolate;
}
.hero::before {
  /* Ambient cinematic backdrop */
  content: "";
  position: absolute; inset: -10%;
  z-index: -2;
  background:
    radial-gradient(40% 35% at 18% 28%, rgba(229,85,200,.22), transparent 60%),
    radial-gradient(45% 40% at 82% 72%, rgba(84,179,236,.18), transparent 60%),
    radial-gradient(35% 30% at 50% 50%, rgba(190,111,210,.12), transparent 70%),
    linear-gradient(180deg, #0A0814 0%, #050410 60%, #060410 100%);
  pointer-events: none;
}
[data-theme="light"] .hero::before {
  background:
    radial-gradient(40% 35% at 18% 28%, rgba(229,85,200,.10), transparent 60%),
    radial-gradient(45% 40% at 82% 72%, rgba(84,179,236,.10), transparent 60%),
    linear-gradient(180deg, #FAFAF7 0%, #F2F0EA 100%);
}
.hero::after {
  /* Subtle grid */
  content: "";
  position: absolute; inset: 0;
  z-index: -1;
  background-image:
    linear-gradient(to right, rgba(255,255,255,.04) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255,255,255,.04) 1px, transparent 1px);
  background-size: 64px 64px;
  -webkit-mask: radial-gradient(60% 50% at 50% 40%, #000 0%, transparent 75%);
          mask: radial-gradient(60% 50% at 50% 40%, #000 0%, transparent 75%);
  pointer-events: none;
}
[data-theme="light"] .hero::after {
  background-image:
    linear-gradient(to right, rgba(0,0,0,.05) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(0,0,0,.05) 1px, transparent 1px);
}
.hero-grid {
  display: grid; grid-template-columns: 1.2fr .8fr; gap: clamp(24px, 4vw, 64px);
  align-items: center;
}
@media (max-width: 920px) { .hero-grid { grid-template-columns: 1fr; } }

.hero h1 .alt {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  letter-spacing: -.005em;
  background: linear-gradient(120deg, var(--grad-1), var(--grad-2), var(--grad-3), var(--grad-4), var(--grad-5), var(--grad-6));
  -webkit-background-clip: text; background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
  white-space: nowrap;
}
html[lang="ar"] .hero h1 .alt { font-style: normal; font-weight: 700; }

.hero .lede { margin-top: 24px; }

.hero-ctas { display: flex; gap: 12px; margin-top: 32px; flex-wrap: wrap; }

.hero-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  margin-top: clamp(48px, 6vw, 72px);
  padding-top: clamp(32px, 4vw, 48px);
  border-top: 1px solid rgba(255,255,255,.08);
  position: relative;
}
[data-theme="light"] .hero-stats { border-top-color: rgba(0,0,0,.08); }
.hero-stats::before {
  content: ""; position: absolute;
  top: -1px; left: 25%; right: 25%; height: 1px;
  background: linear-gradient(90deg, transparent, rgba(229,85,200,.6), rgba(84,179,236,.6), transparent);
  opacity: .9;
  filter: blur(.5px);
}
.hero-stats .stat {
  padding: 8px 28px;
  border-inline-start: 1px solid rgba(255,255,255,.06);
  position: relative;
}
.hero-stats .stat:first-child { border-inline-start: 0; padding-inline-start: 0; }
[data-theme="light"] .hero-stats .stat { border-inline-start-color: rgba(0,0,0,.06); }

.hero-stats .stat b {
  display: block;
  font-family: var(--font-sans);
  font-weight: 800;
  font-size: clamp(48px, 6.5vw, 88px);
  line-height: .95;
  letter-spacing: -.035em;
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum";
  color: #FFFFFF;
  margin-bottom: 14px;
  position: relative;
  text-wrap: nowrap;
}
[data-theme="light"] .hero-stats .stat b { color: #0A0A0A; }
html[lang="ar"] .hero-stats .stat b { font-family: var(--font-sans); }

/* Alternating treatment — odd stats stay in solid white/ink, even stats use the
   brand gradient as a tinted text fill for visual rhythm across the row. */
.hero-stats .stat:nth-child(even) b {
  background: linear-gradient(95deg, #FDD196 0%, #FF966D 22%, #E555C8 48%, #BE6FD2 68%, #54B3EC 86%, #00FEFF 100%);
  -webkit-background-clip: text;
          background-clip: text;
  -webkit-text-fill-color: transparent;
          color: transparent;
  filter: drop-shadow(0 6px 28px rgba(229,85,200,.18));
}
[data-theme="light"] .hero-stats .stat:nth-child(even) b {
  -webkit-text-fill-color: transparent;
          color: transparent;
  filter: drop-shadow(0 6px 22px rgba(229,85,200,.22));
}

/* Soft gradient halo behind each number */
.hero-stats .stat b::after {
  content: "";
  position: absolute;
  inset: -20% -10%;
  background: radial-gradient(50% 60% at 50% 60%,
    rgba(229,85,200,.22), rgba(84,179,236,.10) 50%, transparent 75%);
  filter: blur(28px);
  z-index: -1;
  opacity: .8;
  pointer-events: none;
}
[data-theme="light"] .hero-stats .stat b::after { opacity: .35; }

.hero-stats .stat span {
  display: block;
  font-family: var(--font-mono);
  font-size: 11.5px;
  font-weight: 500;
  color: var(--ink-3);
  text-transform: uppercase;
  letter-spacing: .14em;
  line-height: 1.4;
  max-width: 16ch;
}
html[lang="ar"] .hero-stats .stat span {
  font-family: var(--font-ar);
  font-weight: 500;
  letter-spacing: 0;
  text-transform: none;
  font-size: 13.5px;
  color: var(--ink-2);
}

@media (max-width: 880px) {
  .hero-stats {
    grid-template-columns: 1fr 1fr;
    gap: 28px 0;
  }
  .hero-stats .stat { padding: 8px 16px; }
  .hero-stats .stat:nth-child(2n+1) { border-inline-start: 0; padding-inline-start: 0; }
  .hero-stats .stat b { font-size: clamp(44px, 11vw, 64px); }
}
@media (max-width: 480px) {
  .hero-stats .stat b { font-size: clamp(38px, 13vw, 56px); }
  .hero-stats .stat span { font-size: 10.5px; }
  html[lang="ar"] .hero-stats .stat span { font-size: 12.5px; }
}

.hero-visual {
  aspect-ratio: 1/1;
  position: relative;
  display: flex; align-items: center; justify-content: center;
  min-height: 580px;
}
@media (max-width: 920px) { .hero-visual { min-height: 480px; margin-top: 32px; } }
@media (max-width: 560px) { .hero-visual { min-height: 420px; } }

/* Floating particles */
.hero-particles {
  position: absolute; inset: 0; pointer-events: none; z-index: 1;
}
.hero-particles i {
  position: absolute;
  width: 3px; height: 3px; border-radius: 50%;
  background: #fff;
  opacity: 0;
  box-shadow: 0 0 8px rgba(255,255,255,.6);
  animation: particleFloat 12s ease-in-out infinite;
}
.hero-particles i:nth-child(1)  { left: 12%; top: 18%; animation-delay: 0s; --dx: 18px; --dy: -24px; }
.hero-particles i:nth-child(2)  { left: 78%; top: 22%; animation-delay: 1.2s; --dx: -22px; --dy: 14px; }
.hero-particles i:nth-child(3)  { left: 30%; top: 72%; animation-delay: 2.4s; --dx: 16px; --dy: -18px; }
.hero-particles i:nth-child(4)  { left: 85%; top: 58%; animation-delay: 3.6s; --dx: -14px; --dy: -22px; }
.hero-particles i:nth-child(5)  { left: 6%; top: 56%; animation-delay: 4.8s; --dx: 22px; --dy: 16px; }
.hero-particles i:nth-child(6)  { left: 56%; top: 12%; animation-delay: 6s; --dx: -18px; --dy: 18px; }
.hero-particles i:nth-child(7)  { left: 64%; top: 84%; animation-delay: 7.2s; --dx: 20px; --dy: -14px; }
.hero-particles i:nth-child(8)  { left: 22%; top: 38%; animation-delay: 8.4s; --dx: -16px; --dy: 20px; }
.hero-particles i:nth-child(9)  { left: 92%; top: 38%; animation-delay: 9.6s; --dx: -24px; --dy: -14px; }
.hero-particles i:nth-child(10) { left: 42%; top: 88%; animation-delay: 10.8s; --dx: 18px; --dy: 22px; }
.hero-particles i:nth-child(11) { left: 14%; top: 88%; animation-delay: 0.6s; --dx: 14px; --dy: -28px; }
.hero-particles i:nth-child(12) { left: 70%; top: 46%; animation-delay: 5.4s; --dx: -20px; --dy: 12px; }
@keyframes particleFloat {
  0%, 100% { opacity: 0; transform: translate(0,0); }
  20% { opacity: .8; }
  50% { opacity: .9; transform: translate(var(--dx), var(--dy)); }
  80% { opacity: .5; }
}
@media (prefers-reduced-motion: reduce) {
  .hero-particles i { animation: none; opacity: .5; }
}

/* ============================================================
   FLOATING SOCIAL PLATFORM CARDS — live counter dashboard
   ============================================================ */
.social-stack {
  position: absolute; inset: 0;
  z-index: 2;
  pointer-events: none;
}
.sc {
  position: absolute;
  pointer-events: auto;
  background: linear-gradient(160deg, rgba(255,255,255,.07), rgba(255,255,255,.025));
  backdrop-filter: blur(20px) saturate(160%);
  -webkit-backdrop-filter: blur(20px) saturate(160%);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 20px;
  padding: 16px 18px;
  width: 230px;
  box-shadow:
    0 24px 50px -10px rgba(0,0,0,.55),
    0 0 0 1px rgba(255,255,255,.04) inset;
  opacity: 0;
  transform: translateY(20px) scale(.96);
  will-change: transform, opacity;
  animation: scIn 2.4s cubic-bezier(.32, .08, .24, 1) var(--d, 0s) forwards,
             scFloat 22s ease-in-out var(--d, 0s) infinite;
  color: #FFFFFF;
}
[data-theme="light"] .sc {
  background: linear-gradient(160deg, rgba(255,255,255,.95), rgba(255,255,255,.78));
  border-color: rgba(0,0,0,.06);
  box-shadow:
    0 24px 50px -10px rgba(0,0,0,.12),
    0 0 0 1px rgba(0,0,0,.02) inset;
  color: #0A0A0A;
}
@keyframes scIn {
  to { opacity: 1; transform: translateY(0) scale(1); }
}
@keyframes scFloat {
  0%, 100% { translate: 0 0; }
  50%      { translate: 0 -8px; }
}
.sc-mini { width: 200px; padding: 14px 16px; }

/* Layout positions — cascading column so each card stays readable, no overlap on key labels */
.sc-ig  { top:  0%;  left: -6%;   animation-duration: 2.4s, 22s; }
.sc-yt  { top: 16%;  right: -8%;  animation-duration: 2.4s, 24s; animation-delay: var(--d), 1.8s; }
.sc-li  { top: 34%;  left:  6%;   animation-duration: 2.4s, 23s; animation-delay: var(--d), 3.0s; transform: translateY(20px) scale(.96); }
.sc-li  { animation-name: scIn, scFloat; }
.sc-rev { top: 50%;  right: -6%;  animation-duration: 2.4s, 25s; animation-delay: var(--d), 4.2s; }
.sc-tt  { bottom: 16%; left: -4%; animation-duration: 2.4s, 21s; animation-delay: var(--d), 5.4s; }
.sc-fb  { bottom: -2%; right: -6%; animation-duration: 2.4s, 26s; animation-delay: var(--d), 6.6s; }

@media (prefers-reduced-motion: reduce) {
  .sc { animation: scIn 1.4s ease var(--d) forwards; }
  .sc-li { animation: scIn 1.4s ease var(--d) forwards; transform: translate(-50%, -50%); }
}

.sc-head {
  display: flex; align-items: center; gap: 10px;
  margin-bottom: 12px;
}
.sc-icon {
  width: 32px; height: 32px;
  border-radius: 10px;
  display: inline-flex; align-items: center; justify-content: center;
  flex: none;
}
.sc-icon svg { width: 18px; height: 18px; }
.sc-icon-ig { background: linear-gradient(135deg, #FDD196, #FF966D 35%, #E555C8 65%, #BE6FD2); }
.sc-icon-yt { background: #FF0033; }
.sc-icon-tt { background: linear-gradient(135deg, #25F4EE 0%, #000 45%, #FE2C55 90%); }
.sc-icon-fb { background: #1877F2; }
.sc-icon-li { background: #0A66C2; }
.sc-icon-rev { background: linear-gradient(135deg, #34D399, #10B981); }
.sc-meta { display: flex; flex-direction: column; min-width: 0; flex: 1; line-height: 1.25; }
.sc-meta b {
  font-family: var(--font-sans);
  font-weight: 700;
  font-size: 13.5px;
  letter-spacing: -.005em;
  color: inherit;
}
.sc-meta span {
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: .02em;
  opacity: .55;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
html[lang="ar"] .sc-meta b { font-family: var(--font-ar); font-size: 14px; }
html[lang="ar"] .sc-meta span { font-family: var(--font-ar); letter-spacing: 0; font-size: 11.5px; }
.sc-pulse {
  width: 7px; height: 7px; border-radius: 50%;
  background: #34D399;
  flex: none;
  box-shadow: 0 0 0 0 rgba(52,211,153,.6);
  animation: scPulse 2s ease-in-out infinite;
}
@keyframes scPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(52,211,153,.55); }
  50%      { box-shadow: 0 0 0 8px rgba(52,211,153,0); }
}
@media (prefers-reduced-motion: reduce) { .sc-pulse { animation: none; } }

.sc-stat {
  display: flex; flex-direction: column; gap: 2px;
  margin-bottom: 10px;
}
.sc-num {
  font-family: var(--font-sans);
  font-weight: 800;
  font-size: 28px;
  letter-spacing: -.025em;
  line-height: 1;
  font-variant-numeric: tabular-nums;
  background: linear-gradient(110deg, #FDD196 0%, #FF966D 25%, #E555C8 55%, #54B3EC 85%);
  -webkit-background-clip: text; background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
  transition: filter .3s ease;
}
.sc-num.sc-bump {
  /* deliberately empty — number tween itself is the highlight, no extra pulse */
}
@keyframes scBump {
  0%, 100% { filter: none; }
}
.sc-mini .sc-num { font-size: 22px; }
.sc-lbl {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: .14em;
  text-transform: uppercase;
  opacity: .55;
}
html[lang="ar"] .sc-lbl { font-family: var(--font-ar); letter-spacing: 0; text-transform: none; font-size: 12px; }
.sc-foot {
  padding-top: 10px;
  border-top: 1px dashed rgba(255,255,255,.08);
  font-size: 11px;
  opacity: .8;
}
[data-theme="light"] .sc-foot { border-top-color: rgba(0,0,0,.08); }
.sc-foot .trend {
  color: #34D399;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .02em;
}
html[lang="ar"] .sc-foot .trend { font-family: var(--font-ar); font-size: 12.5px; }
.sc-foot .trend .sc-num {
  background: none;
  -webkit-text-fill-color: #34D399;
  color: #34D399;
  font-size: inherit;
  font-weight: 700;
}

@media (max-width: 560px) {
  .sc { width: 190px; padding: 12px 14px; border-radius: 16px; }
  .sc-mini { width: 170px; }
  .sc-num { font-size: 22px; }
  .sc-mini .sc-num { font-size: 18px; }
  .sc-ig { left: -6%; }
  .sc-yt { right: -10%; }
  .sc-fb { right: 2%; }
  .sc-rev, .sc-li { display: none; }
}

/* ============================================================
   ROTATOR — graceful content swap between platforms / people.
   Opacity + light blur only — keeps the underlying float animation
   intact so the card never visually jumps.
   ============================================================ */
.sc.is-swap-out {
  opacity: 0 !important;
  filter: blur(2px);
  transition: opacity 1.6s cubic-bezier(.55,0,.4,1), filter 1.6s ease-out;
}
.sc.is-swap-in {
  animation: scSwapIn 1.8s cubic-bezier(.2,.7,.2,1) forwards !important;
}
.sc.sc-li.is-swap-in,
.sc.sc-person.sc-li.is-swap-in {
  animation: scSwapInCenter 1.8s cubic-bezier(.2,.7,.2,1) forwards !important;
}
@keyframes scSwapIn {
  0%   { opacity: 0; filter: blur(2px); }
  100% { opacity: 1; filter: blur(0); }
}
@keyframes scSwapInCenter {
  0%   { opacity: 0; filter: blur(2px); }
  100% { opacity: 1; filter: blur(0); }
}
/* Image cross-fade inside person photo */
.sc-person-photo {
  transition: opacity 1.4s ease, background-image 0s;
}
.sc-person-photo.is-swap-out { opacity: .15; }

@media (prefers-reduced-motion: reduce) {
  .sc.is-swap-out, .sc.is-swap-in { animation: none !important; transition: none !important; filter: none; }
}

/* ============================================================
   HUMAN PROOF CARDS — real-people glassmorphic cards in hero
   Used at .sc-li and .sc-rev positions instead of LinkedIn/Leads
   ============================================================ */
.sc.sc-person {
  width: 230px;
  padding: 12px;
  display: flex; flex-direction: column; gap: 0;
  overflow: hidden;
}
.sc-person-photo {
  width: 100%;
  aspect-ratio: 16/10;
  background: var(--bg-band) center/cover;
  background-position: center 18%;
  border-radius: 14px;
  position: relative;
  overflow: hidden;
}
.sc-person-photo::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 45%, rgba(0,0,0,.75) 100%);
  border-radius: inherit;
}
.sc-person-body {
  display: flex; align-items: center; gap: 8px;
  padding: 10px 4px 4px;
}
.sc-person-meta {
  flex: 1; min-width: 0;
  display: flex; flex-direction: column; gap: 1px;
  line-height: 1.25;
}
.sc-person-meta b {
  font-family: var(--font-sans);
  font-weight: 700;
  font-size: 14px;
  letter-spacing: -.005em;
  color: inherit;
}
.sc-person-meta span {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: .04em;
  opacity: .65;
  line-height: 1.35;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
html[lang="ar"] .sc-person-meta b { font-family: var(--font-ar); font-size: 14.5px; }
html[lang="ar"] .sc-person-meta span { font-family: var(--font-ar); letter-spacing: 0; font-size: 12px; }

/* Position adjustments for person variants */
.sc.sc-person.sc-li {
  top: 34%; left: 6%;
  transform: translateY(20px) scale(.95);
  animation-name: scIn, scFloat;
}
.sc.sc-person.sc-rev {
  top: 50%; right: -6%;
  width: 220px;
}
@media (max-width: 560px) { .sc-person.sc-li, .sc-person.sc-rev { display: none; } }
/* Hero futuristic gradient orb — abstract, no ring/disc look */
.hero-orb {
  position: absolute; inset: 0;
  border-radius: 50%;
  background:
    radial-gradient(60% 60% at 32% 30%, rgba(229,85,200,.55), transparent 65%),
    radial-gradient(60% 60% at 70% 75%, rgba(84,179,236,.55), transparent 65%),
    radial-gradient(50% 50% at 50% 50%, rgba(255,150,109,.35), transparent 70%);
  filter: blur(40px);
  opacity: .85;
  animation: orbDrift 14s ease-in-out infinite alternate;
}
.hero-orb::before {
  content: ""; position: absolute; inset: 18%;
  border-radius: 50%;
  background:
    conic-gradient(from 210deg,
      rgba(253,209,150,.0), rgba(229,85,200,.25),
      rgba(190,111,210,.18), rgba(84,179,236,.25),
      rgba(0,254,255,.18), rgba(253,209,150,.0));
  filter: blur(20px);
  animation: spin 32s linear infinite;
  opacity: .6;
}
.hero-orb::after {
  content: ""; position: absolute; inset: 30%;
  border-radius: 50%;
  background: radial-gradient(circle at 50% 50%, rgba(255,255,255,.12), transparent 65%);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
@keyframes orbDrift {
  0%   { transform: translate(0, 0) scale(1); }
  50%  { transform: translate(2%, -3%) scale(1.03); }
  100% { transform: translate(-2%, 2%) scale(.98); }
}
@keyframes spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) {
  .hero-orb, .hero-orb::before { animation: none; }
}

.hero-mark {
  display: none;
}

/* ============================================================
   LOGO WALL
   ============================================================ */
.logos-section { padding: clamp(48px, 6vw, 80px) 0; background: var(--bg-band); }
.logos-head { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; margin-bottom: 32px; flex-wrap: wrap; }
.logos-head h2 { font-size: clamp(22px, 2.4vw, 28px); }

.marquee {
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 8%, #000 92%, transparent 100%);
  mask-image: linear-gradient(90deg, transparent 0, #000 8%, #000 92%, transparent 100%);
}
.marquee-track {
  display: flex; gap: 32px;
  animation: marquee 40s linear infinite;
  width: max-content;
}
@keyframes marquee { to { transform: translateX(-50%); } }
html[lang="ar"] .marquee-track { animation-direction: reverse; }
@media (prefers-reduced-motion: reduce) { .marquee-track { animation: none; } }

.marquee img {
  height: 24px; width: auto; flex: none;
  filter: brightness(0) saturate(100%) invert(11%);
  opacity: .7; transition: filter .2s, opacity .2s;
}
[data-theme="dark"] .marquee img { filter: brightness(0) saturate(100%) invert(82%); opacity: .55; }
.marquee img:hover { filter: none; opacity: 1; }

/* ============================================================
   CLIENT-NAMES MARQUEE (personal brands)
   Alternates bold-sans-white and italic-serif-gradient
   ============================================================ */
.clients-names { margin-top: 28px; }
.clients-names .marquee-track {
  animation-duration: 50s;
  gap: 0;
  align-items: baseline;
}
.clients-names .cn {
  font-family: var(--font-sans);
  font-weight: 700;
  font-size: clamp(18px, 1.6vw, 22px);
  letter-spacing: -.02em;
  color: var(--ink);
  white-space: nowrap;
  padding: 0 28px;
  line-height: 1.2;
}
.clients-names .cn-grad {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  letter-spacing: -.005em;
  background: linear-gradient(120deg, var(--grad-1), var(--grad-2), var(--grad-3), var(--grad-4), var(--grad-5), var(--grad-6));
  -webkit-background-clip: text; background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
}
.clients-names .cn-dot {
  font-size: 14px;
  color: var(--ink-3);
  flex: none;
  align-self: center;
}
html[lang="ar"] .clients-names .cn-grad {
  font-family: var(--font-ar);
  font-style: normal;
  font-weight: 700;
}

/* ============================================================
   SERVICES — "WHAT WE DO"
   ============================================================ */
.services-grid {
  display: grid; gap: 14px; margin-top: 48px;
  grid-template-columns: repeat(4, 1fr);
}
@media (max-width: 1080px) { .services-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px)  { .services-grid { grid-template-columns: 1fr; } }

.service-card {
  background: var(--bg-elev);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: 26px;
  display: flex; flex-direction: column; gap: 16px;
  position: relative; overflow: hidden;
  transition: border-color .15s, transform .2s, box-shadow .2s;
}
.service-card:hover { border-color: var(--ink); transform: translateY(-2px); box-shadow: var(--shadow-1); }
.service-card .num {
  font-family: var(--font-mono); font-size: 11px;
  color: var(--ink-3); letter-spacing: .12em;
}
.service-card h3 { font-size: 22px; line-height: 1.15; }
.service-card .row { font-size: 13.5px; color: var(--ink-2); }
.service-card .row b { display: block; color: var(--ink-3); font-size: 10.5px; text-transform: uppercase; letter-spacing: .12em; margin-bottom: 4px; font-family: var(--font-mono); font-weight: 500; }
html[lang="ar"] .service-card .row b { font-family: var(--font-mono); letter-spacing: .06em; }
.service-card .cta {
  margin-top: auto; font-size: 13px; color: var(--ink);
  display: inline-flex; align-items: center; gap: 6px;
  border-bottom: 1px solid var(--line); padding-bottom: 2px;
  align-self: flex-start;
}
.service-card .cta:hover { border-bottom-color: var(--ink); }
html[lang="ar"] .service-card .cta .arrow { transform: scaleX(-1); }

/* ============================================================
   SVC — "Eight services. One operating system." (refined)
   Connected, alive, soft premium boxes with internal motion.
   ============================================================ */
.svc-section {
  position: relative;
  overflow: hidden;
}
.svc-section::before {
  content: "";
  position: absolute; inset: -10%;
  background:
    radial-gradient(40% 30% at 15% 20%, rgba(229,85,200,.10), transparent 60%),
    radial-gradient(35% 25% at 85% 80%, rgba(84,179,236,.10), transparent 60%);
  pointer-events: none;
  z-index: 0;
}
[data-theme="light"] .svc-section::before { opacity: .6; }
.svc-section .container { position: relative; z-index: 1; }

.svc-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin-top: 56px;
  position: relative;
}
@media (max-width: 1080px) { .svc-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px)  { .svc-grid { grid-template-columns: 1fr; } }

/* Connecting hairline across the row — system feel */
.svc-grid::before {
  content: "";
  position: absolute;
  left: 0; right: 0;
  top: 86px;
  height: 1px;
  background: linear-gradient(90deg,
    transparent 4%,
    rgba(229,85,200,.18) 25%,
    rgba(190,111,210,.18) 50%,
    rgba(84,179,236,.18) 75%,
    transparent 96%);
  pointer-events: none;
  z-index: 0;
  opacity: .8;
}
[data-theme="light"] .svc-grid::before {
  background: linear-gradient(90deg,
    transparent 4%, rgba(229,85,200,.22) 50%, transparent 96%);
  opacity: .5;
}
@media (max-width: 1080px) { .svc-grid::before { display: none; } }

.svc-card {
  position: relative;
  padding: 28px 24px 26px;
  border-radius: 24px;
  background:
    linear-gradient(180deg, rgba(255,255,255,.04), rgba(255,255,255,0)),
    rgba(255,255,255,.015);
  border: 1px solid rgba(255,255,255,.07);
  overflow: hidden;
  isolation: isolate;
  backdrop-filter: blur(20px) saturate(140%);
  -webkit-backdrop-filter: blur(20px) saturate(140%);
  transition: transform .35s cubic-bezier(.2,.8,.2,1), border-color .25s, box-shadow .3s;
  display: flex; flex-direction: column; gap: 14px;
  min-height: 280px;
  z-index: 1;
}
[data-theme="light"] .svc-card {
  border-color: rgba(0,0,0,.06);
  background:
    linear-gradient(180deg, rgba(229,85,200,.025), rgba(255,255,255,0)),
    rgba(255,255,255,.7);
}

/* Corner accent node — system feel */
.svc-card::before {
  content: "";
  position: absolute;
  top: 14px; inset-inline-end: 14px;
  width: 4px; height: 4px;
  border-radius: 50%;
  background: linear-gradient(135deg, #FDD196, #E555C8, #54B3EC);
  box-shadow: 0 0 12px rgba(229,85,200,.6);
  opacity: 0;
  transition: opacity .3s ease;
  z-index: 2;
}
.svc-card:hover::before { opacity: 1; }

/* Diagonal light sweep on hover */
.svc-card::after {
  content: "";
  position: absolute;
  inset: -50%;
  background: linear-gradient(115deg, transparent 40%, rgba(255,255,255,.06) 50%, transparent 60%);
  opacity: 0;
  transition: opacity .4s ease, transform .9s cubic-bezier(.2,.8,.2,1);
  transform: translateX(-20%);
  pointer-events: none;
  z-index: 0;
}
[data-theme="light"] .svc-card::after {
  background: linear-gradient(115deg, transparent 40%, rgba(229,85,200,.06) 50%, transparent 60%);
}
.svc-card:hover::after {
  opacity: 1;
  transform: translateX(20%);
}

/* Ambient internal glow */
.svc-glow {
  position: absolute;
  top: -40%; left: -20%;
  width: 140%; height: 140%;
  background:
    radial-gradient(50% 50% at 30% 30%, rgba(229,85,200,.18) 0%, transparent 60%),
    radial-gradient(40% 40% at 80% 80%, rgba(84,179,236,.14) 0%, transparent 60%);
  filter: blur(40px);
  opacity: .6;
  z-index: -1;
  transition: transform .9s cubic-bezier(.2,.8,.2,1), opacity .3s;
  pointer-events: none;
}
[data-theme="light"] .svc-glow { opacity: .4; }

.svc-card:hover {
  transform: translateY(-4px);
  border-color: rgba(229,85,200,.4);
  box-shadow: 0 24px 50px -20px rgba(229,85,200,.25);
}
.svc-card:hover .svc-glow {
  transform: translate(8%, 8%) scale(1.05);
  opacity: .85;
}

.svc-head {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px;
}

/* Layer pill — premium, small, gradient dot */
.svc-layer {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 5px 12px 5px 10px;
  border-radius: 999px;
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(255,255,255,.08);
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ink-2);
}
[data-theme="light"] .svc-layer {
  background: rgba(0,0,0,.03);
  border-color: rgba(0,0,0,.08);
}
html[lang="ar"] .svc-layer {
  font-family: var(--font-ar);
  letter-spacing: 0;
  text-transform: none;
  font-size: 12px;
  font-weight: 500;
}
.svc-layer-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: linear-gradient(135deg, #FDD196, #E555C8 55%, #54B3EC);
  flex: none;
}

.svc-icon {
  width: 38px; height: 38px;
  display: inline-flex; align-items: center; justify-content: center;
  border-radius: 50%;
  background:
    radial-gradient(60% 60% at 50% 50%, rgba(229,85,200,.08), transparent 70%),
    rgba(255,255,255,.04);
  border: 1px solid rgba(255,255,255,.10);
  flex: none;
  transition: transform .35s cubic-bezier(.2,.8,.2,1), box-shadow .3s;
}
[data-theme="light"] .svc-icon {
  background:
    radial-gradient(60% 60% at 50% 50%, rgba(229,85,200,.08), transparent 70%),
    rgba(0,0,0,.03);
  border-color: rgba(0,0,0,.08);
}
.svc-icon svg { width: 20px; height: 20px; }
.svc-card:hover .svc-icon {
  transform: rotate(-8deg) scale(1.08);
  box-shadow: 0 0 0 4px rgba(229,85,200,.10);
}

.svc-title {
  font-size: 20px;
  letter-spacing: -.015em;
  line-height: 1.15;
  margin: 0;
  color: var(--ink);
}
html[lang="ar"] .svc-title { font-size: 22px; line-height: 1.3; }

.svc-desc {
  margin: 0;
  font-size: 13.5px;
  line-height: 1.55;
  color: var(--ink-2);
  text-wrap: pretty;
}
html[lang="ar"] .svc-desc { font-size: 14.5px; line-height: 1.75; }

.svc-tag {
  margin-top: auto;
  padding-top: 14px;
  border-top: 1px dashed rgba(255,255,255,.07);
  display: flex; align-items: center; gap: 10px;
  min-height: 30px;
}
[data-theme="light"] .svc-tag { border-top-color: rgba(0,0,0,.08); }
.svc-tag-dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: linear-gradient(135deg, #E555C8, #54B3EC);
  flex: none;
  animation: svcDotPulse 2.4s ease-in-out infinite;
}
@keyframes svcDotPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(229,85,200,.35); }
  50%      { box-shadow: 0 0 0 6px rgba(229,85,200,0); }
}
.svc-tag-text {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .12em;
  text-transform: uppercase;
  background: linear-gradient(110deg, #FDD196 0%, #FF966D 25%, #E555C8 55%, #54B3EC 90%);
  -webkit-background-clip: text; background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
  font-weight: 600;
  transition: opacity .35s ease, transform .35s ease, filter .35s ease;
  display: inline-block;
}
html[lang="ar"] .svc-tag-text {
  font-family: var(--font-ar);
  letter-spacing: 0;
  text-transform: none;
  font-size: 13px;
  font-weight: 700;
}
.svc-tag-text.fade-out {
  opacity: 0;
  transform: translateY(-4px);
  filter: blur(2px);
}

@media (prefers-reduced-motion: reduce) {
  .svc-tag-text, .svc-tag-text.fade-out {
    transition: none !important; filter: none !important; transform: none !important; opacity: 1 !important;
  }
  .svc-tag-dot { animation: none; }
  .svc-card, .svc-card:hover { transition: none; transform: none; }
  .svc-glow { transition: none; }
}

/* Inline CTA at bottom of section */
.svc-cta {
  margin-top: clamp(40px, 5vw, 60px);
  padding: clamp(28px, 4vw, 44px) clamp(28px, 5vw, 56px);
  border-radius: clamp(20px, 2vw, 28px);
  position: relative;
  overflow: hidden;
  isolation: isolate;
  background:
    radial-gradient(60% 50% at 12% 18%, rgba(255,150,109,.18), transparent 60%),
    radial-gradient(60% 50% at 88% 82%, rgba(84,179,236,.18), transparent 60%),
    linear-gradient(180deg, #0E0E0E, #060606);
  display: flex; align-items: center; justify-content: space-between;
  gap: 24px; flex-wrap: wrap;
}
[data-theme="light"] .svc-cta {
  background:
    radial-gradient(60% 50% at 12% 18%, rgba(255,150,109,.18), transparent 60%),
    radial-gradient(60% 50% at 88% 82%, rgba(84,179,236,.18), transparent 60%),
    linear-gradient(180deg, #FFFFFF, #F6F4EF);
}
.svc-cta::before {
  content: ""; position: absolute; inset: 0;
  padding: 1.5px;
  border-radius: inherit;
  background: linear-gradient(135deg, #FDD196 0%, #FF966D 10%, rgba(229,85,200,.4) 22%, transparent 38%, transparent 62%, rgba(190,111,210,.4) 78%, #54B3EC 90%, #00FEFF 100%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  pointer-events: none;
}
.svc-cta h3 {
  font-size: clamp(20px, 2.2vw, 28px);
  letter-spacing: -.015em;
  line-height: 1.2;
  margin: 0;
  max-width: 32ch;
  text-wrap: balance;
}
@media (max-width: 720px) {
  .svc-cta { flex-direction: column; align-items: flex-start; }
}

/* ============================================================
   CASES
   ============================================================ */
.cases-grid {
  display: grid; gap: 18px; margin-top: 48px;
  grid-template-columns: 1.4fr 1fr 1fr;
  grid-template-rows: auto auto;
}
.cases-grid > :nth-child(1) { grid-row: span 2; }
@media (max-width: 1080px) { .cases-grid { grid-template-columns: 1fr 1fr; } .cases-grid > :nth-child(1) { grid-row: span 1; grid-column: span 2; } }
@media (max-width: 640px)  { .cases-grid { grid-template-columns: 1fr; } .cases-grid > :nth-child(1) { grid-column: span 1; } }

.case-card {
  background: var(--bg-elev);
  border: 1px solid var(--line);
  border-radius: var(--r-xl);
  padding: clamp(24px, 2.4vw, 32px);
  display: flex; flex-direction: column; gap: 18px;
  position: relative; overflow: hidden;
  transition: border-color .2s, transform .25s, box-shadow .25s;
}
.case-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-2); border-color: var(--ink); }
.case-card .industry { font-family: var(--font-mono); font-size: 11px; color: var(--ink-3); text-transform: uppercase; letter-spacing: .12em; }
.case-card h3 { font-size: clamp(24px, 2.4vw, 36px); }
.case-card .visual {
  height: 200px;
  border-radius: var(--r);
  background: var(--bg-band) center/cover;
  position: relative; overflow: hidden;
}
.cases-grid > :nth-child(1) .visual { height: 320px; }
.case-card .visual::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 60%, rgba(0,0,0,.45) 100%);
}
.case-card .stat-pill {
  position: absolute; bottom: 16px; inset-inline-start: 16px;
  background: var(--bg-elev); color: var(--ink);
  padding: 8px 14px; border-radius: 999px;
  font-family: var(--font-sans); font-weight: 600; font-size: 18px;
  letter-spacing: -.01em;
  border: 1px solid var(--line);
  z-index: 2;
}
.case-card .summary { color: var(--ink-2); font-size: 14.5px; }
.case-card .stats {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px;
  padding-top: 14px; border-top: 1px dashed var(--line);
}
.case-card .stats .s b { font-family: var(--font-sans); font-weight: 700; font-size: 22px; line-height: 1; letter-spacing: -.02em; display: block; }
.case-card .stats .s span { font-size: 10.5px; color: var(--ink-3); text-transform: uppercase; letter-spacing: .12em; }
html[lang="ar"] .case-card .stats .s span { text-transform: none; letter-spacing: 0; font-size: 12px; }
.case-card .read {
  font-size: 13px; color: var(--ink);
  display: inline-flex; align-items: center; gap: 6px;
  align-self: flex-start; border-bottom: 1px solid var(--line);
  padding-bottom: 2px; margin-top: auto;
}
.case-card .read:hover { border-bottom-color: var(--ink); }
html[lang="ar"] .case-card .read .arrow { transform: scaleX(-1); }

/* ============================================================
   HOME PAGE — CASE STUDIES CAROUSEL
   ------------------------------------------------------------
   Premium 3-up / 2-up / 1-up slider with elegant outside arrows.
   Uses native horizontal scroll-snap so mobile swipe is free
   and RTL flips automatically with `direction: rtl` on the
   carousel. Arrows live OUTSIDE the scroll viewport so they
   never overlap proof imagery.
   ============================================================ */
.cases-carousel {
  position: relative;
  margin-top: 48px;
  --cc-gap: 22px;
  --cc-per-view: 3;
  --cc-edge: 8px;
}
@media (max-width: 1080px) {
  .cases-carousel { --cc-per-view: 2; }
}
@media (max-width: 640px) {
  .cases-carousel { --cc-per-view: 1; --cc-gap: 14px; }
}

.cases-carousel .cc-viewport {
  overflow: hidden;
  border-radius: var(--r-lg);
  margin: 0 calc(var(--cc-edge) * -1);
}
.cases-carousel .cc-track {
  display: flex;
  flex-wrap: nowrap;
  gap: var(--cc-gap);
  padding: 4px var(--cc-edge) 12px;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  scrollbar-width: none;
  -ms-overflow-style: none;
  overscroll-behavior-inline: contain;
}
.cases-carousel .cc-track::-webkit-scrollbar { display: none; }
@media (prefers-reduced-motion: reduce) {
  .cases-carousel .cc-track { scroll-behavior: auto; }
}

.cc-card {
  flex: 0 0 auto;
  width: calc((100% - (var(--cc-per-view) - 1) * var(--cc-gap)) / var(--cc-per-view));
  scroll-snap-align: start;
  scroll-snap-stop: always;
  display: flex;
  flex-direction: column;
  background: var(--bg-elev);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  position: relative;
  isolation: isolate;
  transition: transform .3s cubic-bezier(.2,.8,.2,1),
              border-color .25s, box-shadow .3s;
}
[data-theme="dark"] .cc-card {
  background: linear-gradient(180deg, rgba(20,20,20,.85), rgba(15,15,15,.85));
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-color: rgba(255,255,255,.08);
}
.cc-card::before {
  /* gradient hairline on hover */
  content: "";
  position: absolute; inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(135deg, #FDD196, #E555C8 50%, #54B3EC);
  -webkit-mask:
    linear-gradient(#000 0 0) content-box,
    linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
          mask-composite: exclude;
  opacity: 0;
  transition: opacity .25s;
  pointer-events: none;
  z-index: 2;
}
.cc-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 22px 50px -24px rgba(229,85,200,.32);
}
.cc-card:hover::before { opacity: 1; }
@media (prefers-reduced-motion: reduce) {
  .cc-card:hover { transform: none; }
}

.cc-image {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 11;
  overflow: hidden;
  background:
    radial-gradient(70% 60% at 30% 25%, rgba(229,85,200,.18), transparent 65%),
    radial-gradient(60% 50% at 75% 80%, rgba(84,179,236,.16), transparent 60%),
    linear-gradient(135deg, #1a1a1a, #0b0b0b);
}
[data-theme="light"] .cc-image {
  background:
    radial-gradient(70% 60% at 30% 25%, rgba(229,85,200,.12), transparent 65%),
    radial-gradient(60% 50% at 75% 80%, rgba(84,179,236,.10), transparent 60%),
    linear-gradient(135deg, #F1EFE9, #E5E0D7);
}
.cc-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 28%;
  display: block;
  transition: transform .6s cubic-bezier(.2,.8,.2,1);
}
.cc-card:hover .cc-image img { transform: scale(1.04); }
.cc-image::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 55%, rgba(0,0,0,.45) 100%);
  pointer-events: none;
}

.cc-body {
  padding: 20px 22px 22px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex: 1;
}
.cc-industry {
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--ink-3);
}
html[lang="ar"] .cc-industry {
  font-family: var(--font-ar);
  font-size: 12.5px;
  letter-spacing: 0;
  text-transform: none;
}
.cc-name {
  font-family: var(--font-sans);
  font-weight: 700;
  font-size: clamp(20px, 1.6vw, 23px);
  line-height: 1.15;
  letter-spacing: -.015em;
  margin: 0;
  color: var(--ink);
}
.cc-challenge {
  font-size: 14px;
  line-height: 1.55;
  color: var(--ink-2);
  margin: 0;
  text-wrap: pretty;
  min-height: 3.1em;
}
html[lang="ar"] .cc-challenge { font-size: 14.5px; line-height: 1.75; }

.cc-result {
  display: flex;
  align-items: baseline;
  gap: 10px;
  padding-top: 14px;
  margin-top: 4px;
  border-top: 1px dashed var(--line);
}
.cc-result b {
  font-family: var(--font-sans);
  font-weight: 700;
  font-size: clamp(26px, 2.6vw, 32px);
  letter-spacing: -.025em;
  line-height: 1;
  color: var(--ink);
  background: linear-gradient(110deg, #FDD196 0%, #FF966D 22%, #E555C8 48%, #BE6FD2 65%, #54B3EC 82%, #00FEFF 100%);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum";
}
.cc-result-label {
  font-size: 12px;
  color: var(--ink-2);
  line-height: 1.35;
  flex: 1;
}
html[lang="ar"] .cc-result-label { font-size: 13px; line-height: 1.55; }

.cc-cta {
  margin-top: auto;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  align-self: flex-start;
  padding-top: 16px;
  font-size: 13px;
  font-weight: 600;
  color: var(--ink);
  letter-spacing: .01em;
  border-bottom: 1px solid var(--line);
  padding-bottom: 4px;
  transition: border-color .2s, gap .2s;
}
html[lang="ar"] .cc-cta { font-size: 14px; }
.cc-card:hover .cc-cta { border-bottom-color: var(--ink); gap: 12px; }
.cc-cta-arrow { transition: transform .2s; }
html[lang="ar"] .cc-cta-arrow { transform: scaleX(-1); }
.cc-card:hover .cc-cta-arrow { transform: translateX(2px); }
html[lang="ar"] .cc-card:hover .cc-cta-arrow { transform: scaleX(-1) translateX(2px); }

/* --- Arrows --- */
.cc-arrow {
  position: absolute;
  top: calc(50% - 60px); /* center on image area, not full card */
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: var(--bg-elev);
  color: var(--ink);
  cursor: pointer;
  z-index: 5;
  box-shadow: 0 12px 28px -14px rgba(0,0,0,.55);
  transition: transform .2s cubic-bezier(.2,.8,.2,1),
              background .2s, color .2s, border-color .2s, opacity .25s;
}
[data-theme="dark"] .cc-arrow {
  background: rgba(20,20,20,.85);
  border-color: rgba(255,255,255,.14);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
.cc-arrow svg { width: 20px; height: 20px; }
.cc-arrow.cc-prev { inset-inline-start: -22px; }
.cc-arrow.cc-next { inset-inline-end: -22px; }
.cc-arrow:hover {
  background: linear-gradient(135deg, #FDD196, #E555C8 50%, #54B3EC);
  color: #fff;
  border-color: transparent;
  transform: translateY(-2px);
}
.cc-arrow:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 3px;
}
.cc-arrow[disabled],
.cc-arrow[aria-disabled="true"] {
  opacity: 0;
  pointer-events: none;
  transform: scale(.9);
}
html[dir="rtl"] .cc-arrow svg { transform: scaleX(-1); }

@media (max-width: 1180px) {
  /* Bring arrows inside the carousel bounds on narrower viewports
     so they don't get clipped by the container edge. */
  .cc-arrow.cc-prev { inset-inline-start: 6px; }
  .cc-arrow.cc-next { inset-inline-end: 6px; }
}
@media (max-width: 640px) {
  .cc-arrow { width: 40px; height: 40px; top: calc(50% - 80px); }
  .cc-arrow svg { width: 17px; height: 17px; }
}

/* --- Dot indicators --- */
.cc-dots {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 22px;
}
.cc-dots button {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  border: none;
  padding: 0;
  background: var(--line);
  cursor: pointer;
  transition: width .25s, background .25s;
}
.cc-dots button[aria-current="true"] {
  width: 28px;
  background: linear-gradient(110deg, #E555C8, #54B3EC);
  border-radius: 999px;
}

/* ============================================================
   PROOF NUMBERS
   ============================================================ */
.proof {
  background: var(--ink); color: var(--bg);
  padding: clamp(64px, 8vw, 120px) 0;
  position: relative; overflow: hidden;
}
[data-theme="dark"] .proof { background: #0E0E0E; color: #FFFFFF; }
[data-theme="dark"] .proof h2 { color: #FFFFFF; }
[data-theme="dark"] .proof .lede { color: var(--ink-2); }
[data-theme="dark"] .proof-stat { border-top-color: rgba(255,255,255,.14); }
[data-theme="dark"] .proof-stat span { color: var(--ink-3); }
.proof::before {
  content: ""; position: absolute; inset: -20% -10% auto auto;
  width: 60vw; height: 60vw; max-width: 720px; max-height: 720px;
  background: conic-gradient(from 220deg at 50% 50%, var(--grad-1), var(--grad-6), var(--grad-5), var(--grad-4), var(--grad-3), var(--grad-2), var(--grad-1));
  filter: blur(80px); opacity: .25; border-radius: 50%;
  pointer-events: none;
}
.proof .container { position: relative; }
.proof h2 { color: var(--bg); }
.proof .lede { color: rgba(245,242,236,.7); }
.proof-grid {
  display: grid; grid-template-columns: repeat(6, 1fr); gap: 20px;
  margin-top: 56px;
}
@media (max-width: 1080px) { .proof-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 560px)  { .proof-grid { grid-template-columns: repeat(2, 1fr); } }
.proof-stat { padding: 18px 0; border-top: 1px solid rgba(245,242,236,.18); }
.proof-stat b { font-family: var(--font-sans); font-weight: 700; font-size: clamp(40px, 5vw, 64px); line-height: 1; letter-spacing: -.025em; display: block; }
.proof-stat span { color: rgba(245,242,236,.62); font-size: 12.5px; margin-top: 8px; display: block; }
html[lang="ar"] .proof-stat span { font-size: 14px; }

/* ============================================================
   AMBASSADORS
   ============================================================ */
.amb-grid {
  display: grid; gap: 16px; margin-top: 48px;
  grid-template-columns: repeat(4, 1fr);
}
@media (max-width: 1080px) { .amb-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px)  { .amb-grid { grid-template-columns: 1fr; } }
.amb {
  background: var(--bg-elev);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  overflow: hidden;
  display: flex; flex-direction: column;
  transition: border-color .15s, transform .2s;
}
.amb:hover { border-color: var(--ink); transform: translateY(-2px); }
.amb .photo {
  aspect-ratio: 4/5;
  background: var(--bg-band) center/cover;
  background-position: center 18%; /* face-safe: bias toward upper third for portraits */
}
.amb .photo img { width: 100%; height: 100%; object-fit: cover; object-position: center 22%; }

/* ============================================================
   FACE-SAFE IMAGE SYSTEM
   Default object-position for portrait/person images so heads
   aren't cropped. Per-image override via inline style.
   ============================================================ */
.intro-card.card-person img { object-position: center 22%; }
.intro-card.card-screen img { object-position: center top; }
.case-card .visual { background-position: center 28%; }
img.face-safe,
.face-safe img { object-fit: cover; object-position: center 22%; }
img.face-center,
.face-center img { object-fit: cover; object-position: center; }
img.contain-safe,
.contain-safe img { object-fit: contain; }
.smart-frame {
  position: relative; overflow: hidden;
  background:
    linear-gradient(135deg, rgba(229,85,200,.08), rgba(84,179,236,.08)),
    var(--bg-band);
}
.smart-frame img { width: 100%; height: 100%; }
.amb .body { padding: 20px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.amb .body b { font-size: 17px; }
.amb .body .field { font-size: 12.5px; color: var(--ink-3); font-family: var(--font-mono); text-transform: uppercase; letter-spacing: .1em; }
html[lang="ar"] .amb .body .field { font-family: var(--font-mono); letter-spacing: .04em; text-transform: none; font-size: 13.5px; }
.amb .body .quote {
  font-family: var(--font-sans); font-weight: 600; font-size: 17px; line-height: 1.3;
  letter-spacing: -.015em;
  color: var(--ink); margin-top: 4px; flex: 1; text-wrap: pretty;
}
html[lang="ar"] .amb .body .quote { font-family: var(--font-ar); font-weight: 500; line-height: 1.55; font-size: 16px; }

/* ============================================================
   COURSES
   ============================================================ */
.courses-grid {
  display: grid; gap: 16px; margin-top: 48px;
  grid-template-columns: repeat(4, 1fr);
}
@media (max-width: 1080px) { .courses-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px)  { .courses-grid { grid-template-columns: 1fr; } }
.course-card {
  background: var(--bg-elev);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  overflow: hidden;
  display: flex; flex-direction: column;
  transition: border-color .15s, transform .2s, box-shadow .2s;
}
.course-card:hover { border-color: var(--ink); transform: translateY(-2px); box-shadow: var(--shadow-1); }
.course-card .thumb {
  aspect-ratio: 16/10;
  background: var(--bg-band) center/cover;
  border-bottom: 1px solid var(--line);
}
.course-card .body { padding: 18px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.course-card .body .cat { font-family: var(--font-mono); font-size: 10.5px; text-transform: uppercase; letter-spacing: .12em; color: var(--ink-3); }
html[lang="ar"] .course-card .body .cat { letter-spacing: .04em; text-transform: none; font-size: 12px; }
.course-card .body h3 { font-size: 19px; line-height: 1.2; }
.course-card .body .desc { color: var(--ink-2); font-size: 13px; }
.course-card .body .enrol {
  margin-top: auto; padding-top: 12px;
  font-size: 12.5px; color: var(--ink);
  display: inline-flex; align-items: center; gap: 6px; align-self: flex-start;
  border-bottom: 1px solid var(--line); padding-bottom: 2px;
}
.course-card .body .enrol:hover { border-bottom-color: var(--ink); }
html[lang="ar"] .course-card .body .enrol .arrow { transform: scaleX(-1); }

/* ------------------------------------------------------------
   Secondary "Enroll Now" pill — injected by courses-enhance.js
   Sits over the card thumb so the user can jump straight to the
   official Teachable / YouTube landing page without going through
   the internal detail page. The card itself still opens the
   internal page on a normal click.
   ------------------------------------------------------------ */
.courses-grid .course-card-wrap {
  position: relative;
  display: flex;
}
.courses-grid .course-card-wrap > .course-card {
  flex: 1;
  width: 100%;
}
.course-card-enroll {
  position: absolute;
  top: 12px;
  inset-inline-end: 12px;
  z-index: 3;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 14px 8px 16px;
  font-family: var(--font-sans);
  font-size: 12px;
  font-weight: 600;
  line-height: 1;
  letter-spacing: .01em;
  color: #0A0A0A;
  background: rgba(255, 255, 255, .92);
  border: 1px solid rgba(255, 255, 255, .55);
  border-radius: 999px;
  text-decoration: none;
  box-shadow: 0 10px 24px -12px rgba(0, 0, 0, .55);
  backdrop-filter: blur(10px) saturate(140%);
  -webkit-backdrop-filter: blur(10px) saturate(140%);
  transition: transform .2s cubic-bezier(.2,.8,.2,1),
              background .2s, color .2s, box-shadow .25s;
}
.course-card-enroll:hover {
  transform: translateY(-2px);
  background: linear-gradient(110deg, #FDD196 0%, #E555C8 50%, #54B3EC 100%);
  color: #fff;
  box-shadow: 0 14px 32px -10px rgba(229, 85, 200, .55);
}
.course-card-enroll-arrow {
  display: inline-block;
  font-weight: 500;
  font-size: 11px;
  transform: translateY(-1px);
}
html[lang="ar"] .course-card-enroll {
  font-family: var(--font-ar);
  font-weight: 700;
  font-size: 13px;
  padding: 7px 14px 7px 14px;
}

/* Coming Soon variant — disabled */
.course-card-enroll.is-soon {
  background: rgba(20, 20, 20, .55);
  color: rgba(255, 255, 255, .82);
  border-color: rgba(255, 255, 255, .14);
  cursor: not-allowed;
  box-shadow: none;
}
.course-card-enroll.is-soon:hover {
  transform: none;
  background: rgba(20, 20, 20, .55);
  color: rgba(255, 255, 255, .82);
  box-shadow: none;
}
.course-card-enroll.is-soon .course-card-enroll-arrow { display: none; }

/* Free YouTube variant — accented cyan */
.course-card-enroll.is-free {
  background: linear-gradient(135deg, #00FEFF, #54B3EC);
  color: #0A0A0A;
  border-color: rgba(0, 254, 255, .35);
}
.course-card-enroll.is-free:hover {
  background: linear-gradient(135deg, #00FEFF, #BE6FD2 80%);
  color: #fff;
}

/* Light theme tuning */
[data-theme="light"] .course-card-enroll {
  background: #0A0A0A;
  color: #FFFFFF;
  border-color: rgba(10, 10, 10, .8);
  box-shadow: 0 10px 24px -14px rgba(10, 10, 10, .5);
}
[data-theme="light"] .course-card-enroll:hover {
  background: linear-gradient(110deg, #FDD196 0%, #E555C8 50%, #54B3EC 100%);
  color: #fff;
}
[data-theme="light"] .course-card-enroll.is-soon {
  background: rgba(241, 239, 233, .9);
  color: #555;
  border-color: rgba(10, 10, 10, .15);
}
[data-theme="light"] .course-card-enroll.is-soon:hover {
  background: rgba(241, 239, 233, .9);
  color: #555;
}

@media (max-width: 560px) {
  .course-card-enroll { font-size: 11.5px; padding: 7px 12px; }
}

/* ============================================================
   INSIDE OPTIIIMUM
   ============================================================ */
.inside-grid {
  display: grid; gap: 14px; margin-top: 48px;
  grid-template-columns: repeat(7, 1fr);
}
@media (max-width: 1080px) { .inside-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 560px)  { .inside-grid { grid-template-columns: repeat(2, 1fr); } }
.dept {
  background: var(--bg-elev);
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 18px;
  min-height: 140px;
  display: flex; flex-direction: column; justify-content: space-between; gap: 12px;
  transition: border-color .15s, transform .2s;
}
.dept:hover { border-color: var(--ink); transform: translateY(-2px); }
.dept .num { font-family: var(--font-mono); font-size: 11px; color: var(--ink-3); }
.dept b { font-size: 15px; line-height: 1.2; }
.dept .count { font-family: var(--font-mono); font-size: 11px; color: var(--ink-3); }

/* ============================================================
   BLOG
   ============================================================ */
.blog-grid {
  display: grid; gap: 18px; margin-top: 48px;
  grid-template-columns: repeat(3, 1fr);
}
@media (max-width: 920px) { .blog-grid { grid-template-columns: 1fr; } }
.blog-card {
  background: var(--bg-elev);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: 28px;
  display: flex; flex-direction: column; gap: 14px;
  transition: border-color .15s, transform .2s;
}
.blog-card:hover { border-color: var(--ink); transform: translateY(-2px); }
.blog-card .date { font-family: var(--font-mono); font-size: 11px; color: var(--ink-3); text-transform: uppercase; letter-spacing: .12em; }
.blog-card h3 { font-size: 24px; line-height: 1.15; }
.blog-card p { color: var(--ink-2); font-size: 14.5px; }
.blog-card .read {
  margin-top: auto; font-size: 13px;
  display: inline-flex; align-items: center; gap: 6px; align-self: flex-start;
  border-bottom: 1px solid var(--line); padding-bottom: 2px;
}
.blog-card .read:hover { border-bottom-color: var(--ink); }
html[lang="ar"] .blog-card .read .arrow { transform: scaleX(-1); }

/* ============================================================
   OPT-BOX — reusable gradient-bordered surface (image 1)
   Use as wrapper on any container to get the signature box look.
   ============================================================ */
.opt-box {
  position: relative;
  border-radius: clamp(20px, 2vw, 32px);
  padding: clamp(48px, 7vw, 96px) clamp(24px, 5vw, 64px);
  isolation: isolate;
  overflow: hidden;
  background:
    radial-gradient(70% 55% at 10% 18%, rgba(255,150,109,.22), transparent 60%),
    radial-gradient(70% 55% at 92% 84%, rgba(84,179,236,.22), transparent 60%),
    linear-gradient(180deg, #0E0E0E, #060606);
}
[data-theme="light"] .opt-box {
  background:
    radial-gradient(70% 55% at 10% 18%, rgba(255,150,109,.22), transparent 60%),
    radial-gradient(70% 55% at 92% 84%, rgba(84,179,236,.22), transparent 60%),
    linear-gradient(180deg, #FFFFFF, #F6F4EF);
}
.opt-box::before {
  /* Gradient hairline border via mask-composite */
  content: "";
  position: absolute; inset: 0;
  padding: 1.5px;
  border-radius: inherit;
  background: linear-gradient(135deg,
    #FDD196 0%, #FF966D 10%, rgba(229,85,200,.4) 22%,
    transparent 38%, transparent 62%,
    rgba(190,111,210,.4) 78%, #54B3EC 90%, #00FEFF 100%);
  -webkit-mask:
    linear-gradient(#000 0 0) content-box,
    linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
          mask-composite: exclude;
  pointer-events: none;
  z-index: 0;
}
.opt-box > * { position: relative; z-index: 1; }

/* ============================================================
   FINAL CTA — now rendered as an opt-box
   ============================================================ */
.final-cta-section {
  padding: clamp(48px, 8vw, 96px) 0 clamp(48px, 8vw, 96px);
}
.final-cta-section .opt-box { text-align: center; }
.final-cta-section .opt-box h2 {
  max-width: 18ch;
  margin: 0 auto;
  font-size: clamp(40px, 6.5vw, 80px);
  line-height: 1.02;
  letter-spacing: -.025em;
}
.final-cta-section .opt-box .lede {
  color: var(--ink-2);
  margin: 18px auto 0;
  max-width: 56ch;
  font-size: clamp(14px, 1.1vw, 16px);
}
.final-cta-section .opt-box .final-cta-btns {
  display: flex; gap: 10px; justify-content: center;
  margin-top: 36px; flex-wrap: wrap;
}
.final-cta-section .opt-box .btn-ghost {
  background: rgba(255,255,255,.04);
  border-color: rgba(255,255,255,.18);
  color: #FFFFFF;
}
.final-cta-section .opt-box .btn-ghost:hover {
  border-color: rgba(255,255,255,.6);
  background: rgba(255,255,255,.08);
}

/* ============================================================
   FOOTER — giant gradient wordmark + 4 columns (image 2)
   ============================================================ */
.foot {
  padding: 64px 0 28px;
  background: var(--bg);
  border-top: 1px solid var(--line);
}
.foot-wordmark {
  display: block;
  width: 100%;
  max-width: 1100px;
  margin: 28px auto 56px;
  aspect-ratio: 738 / 118;
  background: linear-gradient(95deg,
    #FDD196 0%, #FF966D 16%, #E555C8 36%,
    #BE6FD2 54%, #54B3EC 72%, #00FEFF 92%);
  -webkit-mask: url("assets/logo.png") center/contain no-repeat;
          mask: url("assets/logo.png") center/contain no-repeat;
  filter: drop-shadow(0 18px 60px rgba(229,85,200,.18));
}
.foot-top {
  display: grid; gap: clamp(32px, 4vw, 56px);
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
}
@media (max-width: 1024px) {
  .foot-top { grid-template-columns: 1fr 1fr; }
  .foot-top > :nth-child(1) { grid-column: span 2; }
}
@media (max-width: 560px) {
  .foot-top { grid-template-columns: 1fr; }
  .foot-top > :nth-child(1) { grid-column: span 1; }
}
.foot-col h4 {
  font-family: var(--font-mono); font-size: 11px;
  text-transform: uppercase; letter-spacing: .14em;
  color: var(--ink-3); font-weight: 500; margin: 0 0 18px;
}
html[lang="ar"] .foot-col h4 { letter-spacing: .04em; text-transform: none; font-size: 13px; font-family: var(--font-mono); }
.foot-col ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 10px; }
.foot-col a { font-size: 14px; color: var(--ink-2); transition: color .15s; border: 0; }
.foot-col a:hover { color: var(--ink); }
.foot-col .ext::after {
  content: " ↗";
  color: var(--ink-3);
  font-family: var(--font-mono);
  font-size: 12px;
}
.foot-col .blurb {
  font-size: 14px;
  color: var(--ink-2);
  line-height: 1.55;
  margin: 0 0 18px;
  max-width: 28ch;
}
.foot-col .locations {
  font-size: 12.5px;
  color: var(--ink-3);
  margin: 0 0 16px;
  font-family: var(--font-mono);
  letter-spacing: .04em;
}
.foot-col .phone-pills { display: flex; flex-wrap: wrap; gap: 8px; }
.foot-col .phone-pill {
  display: inline-flex; align-items: center;
  padding: 8px 16px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  background: transparent;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: .02em;
  color: var(--ink);
  transition: border-color .15s, background .15s;
  white-space: nowrap;
}
.foot-col .phone-pill:hover { border-color: var(--ink); background: rgba(255,255,255,.04); }
[data-theme="light"] .foot-col .phone-pill:hover { background: rgba(0,0,0,.04); }

.foot-bottom {
  margin-top: 56px; padding-top: 24px;
  border-top: 1px solid var(--line);
  display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  font-size: 12.5px; color: var(--ink-3);
}
.foot-bottom a { color: var(--ink-3); }
.foot-bottom a:hover { color: var(--ink); }

/* ============================================================
   PAGE HERO — used on all dedicated pages
   ============================================================ */
.page-hero {
  padding: clamp(80px, 12vw, 140px) 0 clamp(40px, 6vw, 72px);
  position: relative;
  text-align: left;
}
.page-hero h1 {
  font-size: clamp(40px, 7vw, 84px);
  letter-spacing: -.025em;
  line-height: 1.02;
  margin-top: 12px;
  max-width: 18ch;
  text-wrap: balance;
}
.page-hero .eyebrow { display: block; }

/* ============================================================
   CULTURE STRIP — real-team faces, face-safe cropping (Home)
   ============================================================ */
.culture-strip {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  grid-template-rows: 200px 200px;
  gap: 14px;
  margin: 56px 0 32px;
}
.cs-card {
  position: relative;
  margin: 0;
  border-radius: 20px;
  overflow: hidden;
  background: var(--bg-band);
  border: 1px solid rgba(255,255,255,.06);
  isolation: isolate;
}
[data-theme="light"] .cs-card { border-color: rgba(0,0,0,.06); }
.cs-card img {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: center 22%;
  transition: transform .6s cubic-bezier(.2,.8,.2,1), filter .3s ease;
}
.cs-card:hover img { transform: scale(1.04); filter: saturate(1.08); }
.cs-card figcaption {
  position: absolute; left: 16px; right: 16px; bottom: 14px;
  z-index: 2;
  color: #FFFFFF;
  display: flex; flex-direction: column; gap: 2px;
}
.cs-card::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 45%, rgba(0,0,0,.78) 100%);
  pointer-events: none;
  z-index: 1;
}
.cs-card .cs-name {
  font-family: var(--font-sans);
  font-weight: 700;
  font-size: 16px;
  letter-spacing: -.012em;
}
.cs-card .cs-role {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: rgba(255,255,255,.75);
}
html[lang="ar"] .cs-card .cs-role {
  font-family: var(--font-ar);
  letter-spacing: 0;
  text-transform: none;
  font-size: 12.5px;
}

/* Editorial grid: lg spans 2 rows, tall spans 2 rows */
.cs-card.cs-lg   { grid-row: span 2; }
.cs-card.cs-tall { grid-row: span 2; }

@media (max-width: 920px) {
  .culture-strip {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 220px 220px 220px;
  }
  .cs-card.cs-lg   { grid-row: span 1; grid-column: span 2; }
  .cs-card.cs-tall { grid-row: span 1; }
}
@media (max-width: 560px) {
  .culture-strip {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: repeat(3, 180px);
    gap: 10px;
  }
  .cs-card.cs-lg   { grid-column: span 2; }
}

/* ============================================================
   PRE-FOOTER — PERSONAL BRANDS WE BUILT INTO GROWTH SYSTEMS
   ============================================================ */
.pre-footer {
  padding: clamp(64px, 9vw, 110px) 0;
  position: relative;
  overflow: hidden;
}
.pre-footer::before {
  content: ""; position: absolute; inset: -10%;
  background:
    radial-gradient(45% 35% at 20% 30%, rgba(229,85,200,.12), transparent 60%),
    radial-gradient(40% 30% at 80% 70%, rgba(84,179,236,.10), transparent 60%);
  pointer-events: none;
  z-index: 0;
}
.pre-footer .container { position: relative; z-index: 1; }
.pre-footer-head {
  text-align: center;
  margin-bottom: clamp(40px, 5vw, 60px);
}
.pre-footer-head .eyebrow { display: inline-block; margin-bottom: 12px; }
.pre-footer-head h2 {
  font-size: clamp(36px, 5.5vw, 64px);
  letter-spacing: -.025em;
  line-height: 1.05;
  max-width: 22ch;
  margin: 0 auto;
  text-wrap: balance;
}
.pre-footer-head .lede {
  color: var(--ink-2);
  margin: 18px auto 0;
  max-width: 60ch;
  font-size: clamp(15px, 1.15vw, 17px);
  text-wrap: pretty;
}
.pre-footer-head h2 .pb-soft {
  color: var(--ink-2);
  font-weight: 700;
  letter-spacing: -.025em;
}

/* ============================================================
   PERSONAL-BRANDS MARQUEE — two rows, opposite directions
   ============================================================ */
.pb-marquee {
  display: flex; flex-direction: column; gap: 14px;
  padding: 32px 0;
  -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 6%, #000 94%, transparent 100%);
          mask-image: linear-gradient(90deg, transparent 0, #000 6%, #000 94%, transparent 100%);
}
.pb-marquee-row { overflow: hidden; position: relative; }
.pb-marquee-track {
  display: flex; gap: 14px;
  width: max-content;
  animation: pbMarquee 55s linear infinite;
}
.pb-row-l .pb-marquee-track { animation-direction: normal; }
.pb-row-r .pb-marquee-track { animation-direction: reverse; animation-duration: 68s; }
@keyframes pbMarquee { to { transform: translateX(-50%); } }
html[lang="ar"] .pb-row-l .pb-marquee-track { animation-direction: reverse; }
html[lang="ar"] .pb-row-r .pb-marquee-track { animation-direction: normal; }
.pb-marquee-row:hover .pb-marquee-track { animation-play-state: paused; }
@media (prefers-reduced-motion: reduce) {
  .pb-marquee-track { animation: none; transform: none; flex-wrap: wrap; width: 100%; justify-content: center; }
  .pb-marquee { -webkit-mask-image: none; mask-image: none; }
  .pb-marquee-row { overflow: visible; }
}

.pb-pill {
  flex: none;
  display: inline-flex; align-items: center; gap: 12px;
  padding: 14px 22px;
  border-radius: 999px;
  background: linear-gradient(160deg, rgba(255,255,255,.05), rgba(255,255,255,.015));
  border: 1px solid rgba(255,255,255,.10);
  backdrop-filter: blur(14px) saturate(140%);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
  color: var(--ink);
  text-decoration: none;
  transition: transform .25s, border-color .25s, background .25s;
  position: relative; isolation: isolate;
  white-space: nowrap;
}
[data-theme="light"] .pb-pill {
  background: linear-gradient(160deg, rgba(255,255,255,.9), rgba(255,255,255,.65));
  border-color: rgba(0,0,0,.08);
}
.pb-pill:hover {
  transform: translateY(-2px);
  border-color: rgba(229,85,200,.5);
  background: linear-gradient(160deg, rgba(229,85,200,.08), rgba(84,179,236,.04));
}
[data-theme="light"] .pb-pill:hover {
  background: linear-gradient(160deg, rgba(229,85,200,.06), rgba(255,255,255,.95));
}
.pb-pill-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: linear-gradient(135deg, #FDD196, #E555C8 50%, #54B3EC);
  flex: none;
  box-shadow: 0 0 0 0 rgba(229,85,200,.4);
  animation: pbDotPulse 2.6s ease-in-out infinite;
}
@keyframes pbDotPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(229,85,200,.45); }
  50%      { box-shadow: 0 0 0 8px rgba(229,85,200,0); }
}
@media (prefers-reduced-motion: reduce) { .pb-pill-dot { animation: none; } }
.pb-pill-text { display: flex; flex-direction: column; gap: 1px; line-height: 1.2; }
.pb-pill-name {
  font-family: var(--font-sans);
  font-weight: 700;
  font-size: 15px;
  letter-spacing: -.012em;
  color: var(--ink);
}
.pb-pill-role {
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ink-3);
}
html[lang="ar"] .pb-pill-name { font-family: var(--font-ar); font-size: 16px; }
html[lang="ar"] .pb-pill-role { font-family: var(--font-ar); letter-spacing: 0; text-transform: none; font-size: 12px; }

@media (max-width: 560px) {
  .pb-pill { padding: 12px 16px; gap: 10px; }
  .pb-pill-name { font-size: 14px; }
  .pb-pill-role { font-size: 9.5px; }
  .pb-row-r .pb-marquee-track { animation-duration: 56s; }
}

/* ============================================================
   GLOBAL-BRANDS MARQUEE — same pill chrome, logo inside instead of name
   ============================================================ */
.gb-marquee-section .pre-footer-head { margin-bottom: clamp(32px, 4.5vw, 56px); }

/* ============================================================
   GLOBAL-BRANDS LOGO GRID — clients-page style tiles
   ============================================================ */
.logo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 14px;
}
.logo-cell {
  aspect-ratio: 5/3;
  background: var(--bg-elev);
  border: 1px solid var(--line);
  border-radius: 14px;
  display: flex; align-items: center; justify-content: center;
  padding: 18px;
}
.logo-cell img {
  max-width: 100%; max-height: 100%; object-fit: contain;
  filter: brightness(0) invert(.85);
  opacity: .8;
  transition: filter .15s, opacity .15s;
}
.logo-cell:hover img { filter: none; opacity: 1; }
[data-theme="light"] .logo-cell img { filter: brightness(0) invert(.15); }
[data-theme="light"] .logo-cell:hover img { filter: none; }
.gb-head h2 {
  font-size: clamp(28px, 3.5vw, 44px) !important;
  letter-spacing: -.02em;
  line-height: 1.1;
}
.gb-pill {
  padding: 14px 22px;
  gap: 14px;
}
.gb-pill-logo {
  height: 22px;
  width: auto;
  max-width: 130px;
  object-fit: contain;
  display: block;
  filter: brightness(0) saturate(100%) invert(86%);
  opacity: .75;
  transition: opacity .3s ease, filter .3s ease;
}
[data-theme="light"] .gb-pill-logo {
  filter: brightness(0) saturate(100%);
  opacity: .6;
}
.gb-pill:hover .gb-pill-logo {
  filter: none;
  opacity: 1;
}
@media (max-width: 900px) {
  .gb-pill { padding: 12px 18px; gap: 12px; }
  .gb-pill-logo { height: 19px; max-width: 110px; }
}
@media (max-width: 560px) {
  .gb-pill { padding: 10px 14px; gap: 10px; }
  .gb-pill-logo { height: 16px; max-width: 90px; }
}

.pb-cta {
  text-align: center;
  margin-top: clamp(40px, 5vw, 60px);
}
.pb-cta h3 {
  font-size: clamp(22px, 2.4vw, 30px);
  margin-bottom: 16px;
  letter-spacing: -.015em;
}
.pb-cta-btns {
  display: flex; gap: 10px; justify-content: center; flex-wrap: wrap;
}

/* ============================================================
   BTW — Behind The Work bento (Home)
   ============================================================ */
.btw-section { position: relative; overflow: hidden; }
.btw-section::before {
  content: ""; position: absolute; inset: -10%;
  background:
    radial-gradient(40% 30% at 80% 20%, rgba(229,85,200,.08), transparent 60%),
    radial-gradient(35% 25% at 20% 80%, rgba(84,179,236,.08), transparent 60%);
  pointer-events: none; z-index: 0;
}
.btw-section .container { position: relative; z-index: 1; }
.btw-bento {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr;
  grid-template-rows: 240px 240px;
  gap: 14px;
  margin-top: 48px;
}
.btw-cell {
  position: relative; margin: 0;
  border-radius: 20px;
  overflow: hidden;
  background: var(--bg-band);
  border: 1px solid rgba(255,255,255,.06);
  isolation: isolate;
}
[data-theme="light"] .btw-cell { border-color: rgba(0,0,0,.06); }
.btw-cell img {
  width: 100%; height: 100%;
  object-fit: cover; object-position: center 35%;
  transition: transform .6s cubic-bezier(.2,.8,.2,1), filter .3s;
}
.btw-cell:hover img { transform: scale(1.04); filter: saturate(1.08); }
.btw-cell::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 50%, rgba(0,0,0,.78) 100%);
  pointer-events: none; z-index: 1;
}
.btw-cell figcaption {
  position: absolute; left: 16px; right: 16px; bottom: 14px; z-index: 2;
}
.btw-label {
  display: inline-block;
  padding: 5px 11px;
  border-radius: 999px;
  background: rgba(20,20,20,.6);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255,255,255,.15);
  font-family: var(--font-mono);
  font-size: 10.5px; letter-spacing: .08em; text-transform: uppercase;
  color: #FFFFFF;
}
html[lang="ar"] .btw-label { font-family: var(--font-ar); letter-spacing: 0; text-transform: none; font-size: 12.5px; }
.btw-cell.btw-feature { grid-row: span 2; }
.btw-cell.btw-feature img { object-position: center 30%; }
.btw-cell.btw-wide { grid-column: span 2; }
@media (max-width: 920px) {
  .btw-bento { grid-template-columns: 1fr 1fr; grid-template-rows: repeat(3, 220px); }
  .btw-cell.btw-feature { grid-row: span 1; grid-column: span 2; }
  .btw-cell.btw-wide { grid-column: span 2; }
}
@media (max-width: 560px) {
  .btw-bento { grid-template-columns: 1fr; grid-template-rows: repeat(5, 200px); gap: 10px; }
  .btw-cell.btw-feature, .btw-cell.btw-wide { grid-column: span 1; }
}

/* WhatsApp floater */
.whatsapp {
  position: fixed; bottom: 22px; inset-inline-end: 22px; z-index: 40;
  width: 56px; height: 56px; border-radius: 50%;
  background: #25D366; color: white;
  display: inline-flex; align-items: center; justify-content: center;
  box-shadow: 0 4px 12px rgba(0,0,0,.15), 0 0 0 0 rgba(37,211,102,.4);
  animation: pulse 2.4s ease-in-out infinite;
}
@keyframes pulse { 50% { box-shadow: 0 4px 12px rgba(0,0,0,.15), 0 0 0 14px rgba(37,211,102,0); } }
.whatsapp svg { width: 28px; height: 28px; }
@media (prefers-reduced-motion: reduce) { .whatsapp { animation: none; } }

/* ============================================================
   MOBILE THEME FAB — premium floating switch in bottom-left.
   Visible only on mobile, persists state, syncs with topbar.
   ============================================================ */
.m-theme-fab {
  position: fixed;
  z-index: 41;
  bottom: 88px; /* sits above the bottom-nav (72px tall + 16px gap) */
  inset-inline-start: 16px;
  display: none; /* mobile only — toggled in @media below */
  align-items: center;
  gap: 8px;
  height: 44px;
  padding: 0 14px 0 10px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.14);
  background: rgba(15,15,15,.92);
  color: #FAFAF7;
  box-shadow: 0 12px 30px rgba(0,0,0,.4), 0 0 0 1px rgba(255,255,255,.04) inset;
  backdrop-filter: blur(18px) saturate(160%);
  -webkit-backdrop-filter: blur(18px) saturate(160%);
  font-family: var(--font-mono, "JetBrains Mono", monospace);
  font-size: 11px;
  letter-spacing: .14em;
  text-transform: uppercase;
  cursor: pointer;
  transition: transform .25s cubic-bezier(.2,.8,.2,1), border-color .25s, box-shadow .25s, background .25s;
}
[data-theme="light"] .m-theme-fab {
  background: rgba(255,255,255,.94);
  color: #0B0B0B;
  border-color: rgba(0,0,0,.10);
  box-shadow: 0 12px 30px rgba(0,0,0,.10), 0 0 0 1px rgba(0,0,0,.03) inset;
}
.m-theme-fab:hover { transform: translateY(-1px); }
.m-theme-fab:active { transform: translateY(0) scale(.98); }
html[lang="ar"] .m-theme-fab {
  font-family: var(--font-ar, "Tajawal", sans-serif);
  letter-spacing: 0;
  text-transform: none;
  font-size: 13px;
}
.m-theme-fab-icon {
  width: 26px; height: 26px;
  border-radius: 50%;
  display: grid; place-items: center;
  background: linear-gradient(120deg, #FDD196, #E555C8, #54B3EC);
  color: #0B0B0B;
  position: relative;
  overflow: hidden;
}
.m-theme-fab-icon svg { width: 16px; height: 16px; position: absolute; transition: opacity .3s, transform .35s cubic-bezier(.2,.8,.2,1); }
.m-theme-fab[data-theme="light"] .m-theme-sun  { opacity: 1; transform: rotate(0); }
.m-theme-fab[data-theme="light"] .m-theme-moon { opacity: 0; transform: rotate(45deg) scale(.6); }
.m-theme-fab[data-theme="dark"]  .m-theme-sun  { opacity: 0; transform: rotate(-45deg) scale(.6); }
.m-theme-fab[data-theme="dark"]  .m-theme-moon { opacity: 1; transform: rotate(0); }
.m-theme-fab-lbl { line-height: 1; }

@media (max-width: 880px) {
  .m-theme-fab { display: inline-flex; }
}
@media (max-width: 380px) {
  /* On very narrow screens, drop the label to keep the FAB compact */
  .m-theme-fab-lbl { display: none; }
  .m-theme-fab { padding: 0 10px; }
}
@media (prefers-reduced-motion: reduce) {
  .m-theme-fab, .m-theme-fab-icon svg { transition: none; }
}

/* Section heads */
.section-head {
  display: flex; align-items: end; justify-content: space-between;
  gap: 24px; flex-wrap: wrap; margin-bottom: 8px;
}
.section-head .right { color: var(--ink-3); font-size: 14px; max-width: 36ch; text-wrap: pretty; }

/* Utility */
.eyebrow + h2 { margin-top: 8px; }
h2 + .lede { margin-top: 16px; }


/* ============================================================
   AMBASSADORS — premium testimonial cards (Home + dedicated page)
   ============================================================ */

.amb-page-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-top: 24px;
}
@media (max-width: 920px) { .amb-page-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .amb-page-grid { grid-template-columns: 1fr; } }

.amb-card {
  position: relative;
  padding: 24px;
  border-radius: 22px;
  background:
    linear-gradient(180deg, rgba(255,255,255,.04), rgba(255,255,255,0)),
    rgba(255,255,255,.015);
  border: 1px solid rgba(255,255,255,.08);
  backdrop-filter: blur(16px) saturate(140%);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
  display: flex; flex-direction: column; gap: 14px;
  transition: transform .25s, border-color .25s;
  isolation: isolate;
}
[data-theme="light"] .amb-card { border-color: rgba(0,0,0,.07); background: rgba(255,255,255,.85); }
.amb-card:hover { transform: translateY(-3px); border-color: rgba(229,85,200,.4); }
.amb-card-head { display: flex; align-items: center; gap: 12px; }
.amb-avatar {
  width: 46px; height: 46px;
  border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  font-family: var(--font-sans);
  font-weight: 800;
  font-size: 16px;
  letter-spacing: -.02em;
  color: rgba(0,0,0,.7);
  flex: none;
  box-shadow: 0 0 0 1px rgba(255,255,255,.18) inset;
}
.amb-meta { display: flex; flex-direction: column; gap: 2px; flex: 1; min-width: 0; }
.amb-meta b {
  font-family: var(--font-sans); font-weight: 700; font-size: 15px;
  letter-spacing: -.01em; color: var(--ink);
}
.amb-meta span {
  font-family: var(--font-mono); font-size: 10.5px;
  letter-spacing: .08em; text-transform: uppercase; color: var(--ink-3);
}
html[lang="ar"] .amb-meta b { font-family: var(--font-ar); font-size: 16px; }
html[lang="ar"] .amb-meta span { font-family: var(--font-ar); letter-spacing: 0; text-transform: none; font-size: 13px; }

.amb-quote {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  font-size: 19px;
  line-height: 1.35;
  letter-spacing: -.005em;
  background: linear-gradient(110deg, #FDD196 0%, #FF966D 25%, #E555C8 55%, #54B3EC 90%);
  -webkit-background-clip: text; background-clip: text;
  color: transparent; -webkit-text-fill-color: transparent;
  margin: 0;
  text-wrap: pretty;
}
html[lang="ar"] .amb-quote { font-family: var(--font-ar); font-style: normal; font-weight: 700; font-size: 18px; line-height: 1.7; }

.amb-more {
  margin-top: auto;
}
.amb-more summary {
  cursor: pointer;
  list-style: none;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--ink-2);
  padding: 6px 0;
  display: inline-block;
  border-bottom: 1px solid var(--line);
  transition: color .15s, border-color .15s;
}
.amb-more summary::-webkit-details-marker { display: none; }
html[lang="ar"] .amb-more summary { font-family: var(--font-ar); letter-spacing: 0; text-transform: none; font-size: 13px; }
.amb-more[open] summary { color: var(--ink); border-color: var(--ink); }
.amb-more p { margin: 12px 0 0; font-size: 13.5px; line-height: 1.65; color: var(--ink-2); }
html[lang="ar"] .amb-more p { font-family: var(--font-ar); font-size: 14.5px; line-height: 1.85; }

.amb-cat {
  position: absolute; top: 14px; inset-inline-end: 14px;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(255,255,255,.10);
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ink-3);
}
[data-theme="light"] .amb-cat { background: rgba(0,0,0,.03); border-color: rgba(0,0,0,.08); }
html[lang="ar"] .amb-cat { font-family: var(--font-ar); letter-spacing: 0; text-transform: none; font-size: 11px; }

.amb-filterbar {
  display: flex; flex-wrap: wrap; gap: 8px;
  margin: 32px 0 12px;
}
.amb-filterbar button {
  font: inherit; font-size: 12.5px;
  padding: 6px 14px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--ink-2);
  cursor: pointer;
  transition: border-color .15s, color .15s, background .15s;
  font-family: var(--font-mono);
  letter-spacing: .04em;
}
html[lang="ar"] .amb-filterbar button { font-family: var(--font-ar); letter-spacing: 0; font-size: 13.5px; }
.amb-filterbar button.is-active {
  background: var(--ink); color: var(--bg); border-color: var(--ink);
}
.amb-filterbar button:hover:not(.is-active) { color: var(--ink); border-color: var(--ink); }

.amb-card.hidden { display: none; }



/* ============================================================
   CULTURE STRIP REFINEMENT — compact, face-safe, premium
   Overrides earlier .culture-strip defaults for less wasted
   space + better face framing on every photo.
   ============================================================ */
#team .section-head { gap: 32px; align-items: end; }
#team .section-head > div { max-width: 56ch; }
#team .section-head .right { font-size: 15px; line-height: 1.55; color: var(--ink-2); max-width: 38ch; }

.culture-strip {
  /* Tighter editorial bento — 4 columns, denser rows */
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  grid-template-rows: 180px 180px;
  gap: 12px;
  margin: 40px 0 28px;
}
.cs-card {
  border-radius: 18px;
  transition: transform .35s cubic-bezier(.2,.8,.2,1), border-color .35s, box-shadow .35s;
}
.cs-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 18px 44px -22px rgba(229,85,200,.4), 0 6px 16px -8px rgba(0,0,0,.25);
}
/* Soft brand gradient border on hover — matches ambassadors */
.cs-card::before {
  content: ""; position: absolute; inset: -1px;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(135deg, #FDD196, #FF966D, #E555C8, #BE6FD2, #54B3EC, #00FEFF);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
          mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  opacity: 0;
  transition: opacity .35s ease;
  pointer-events: none;
  z-index: 3;
}
.cs-card:hover::before { opacity: .85; }

/* Face-safe framing — eyes/upper-third visible across every photo */
.cs-card img {
  object-position: 50% 28%;
}
.cs-card.cs-lg img { object-position: 50% 32%; }
.cs-card.cs-tall img { object-position: 50% 22%; }

/* Editorial bento spans on desktop */
.cs-card.cs-lg   { grid-row: span 2; grid-column: span 2; }
.cs-card.cs-tall { grid-row: span 2; }

/* Smaller, less-intrusive figcaption pill */
.cs-card figcaption {
  left: 12px; right: 12px; bottom: 12px;
  padding: 8px 12px;
  border-radius: 12px;
  background: rgba(11,11,11,.55);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255,255,255,.12);
}
.cs-card .cs-name { font-size: 14px; line-height: 1.2; }
.cs-card.cs-lg .cs-name { font-size: 18px; }
.cs-card .cs-role { font-size: 10px; }

/* Inside-grid (departments) — tighten */
.inside-grid { margin-top: 32px; gap: 10px; }
.dept { padding: 14px 16px; }

@media (max-width: 1080px) {
  .culture-strip {
    grid-template-columns: 1fr 1fr 1fr;
    grid-template-rows: 200px 200px;
  }
  .cs-card.cs-lg   { grid-row: span 2; grid-column: span 2; }
  .cs-card.cs-tall { grid-row: span 1; grid-column: span 1; }
  .cs-card:nth-child(6) { display: none; }
}
@media (max-width: 920px) {
  .culture-strip {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 200px 200px 200px;
  }
  .cs-card.cs-lg   { grid-row: span 1; grid-column: span 2; }
  .cs-card.cs-tall { grid-row: span 1; grid-column: span 1; }
  .cs-card:nth-child(6) { display: block; }
}
@media (max-width: 560px) {
  .culture-strip {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: repeat(3, 160px);
    gap: 10px;
  }
  .cs-card.cs-lg { grid-column: span 2; }
  .cs-card .cs-name { font-size: 13px; }
  .cs-card.cs-lg .cs-name { font-size: 16px; }
}

/* ============================================================
   NAV SLIDER + CONTENT CAROUSELS — rail wrapper, arrows
   Activated by slider.js wrapping target elements.
   ============================================================ */

/* Allow the primary nav to scroll horizontally and persist down
   to ~860px instead of being hidden at 1024px. */
.primary-nav {
  overflow-x: auto !important;
  overflow-y: hidden !important;
  scrollbar-width: none;
  -ms-overflow-style: none;
  flex-wrap: nowrap;
  scroll-behavior: smooth;
}
.primary-nav::-webkit-scrollbar { display: none; }

/* Rail wrapper sits in the same flex slot the original element
   occupied, so layout stays intact. */
.rail-wrap {
  position: relative;
  flex: 1 1 auto;
  min-width: 0;
}
.rail-wrap.rail-nav { margin: 0 auto; max-width: 100%; }

.rail-scroller {
  -webkit-overflow-scrolling: touch;
}

/* Edge-fade masks on overflow — keeps cut tabs/cards feeling
   intentional rather than chopped. */
.rail-wrap.has-overflow::before,
.rail-wrap.has-overflow::after {
  content: "";
  position: absolute; top: 0; bottom: 0;
  width: 36px;
  pointer-events: none;
  z-index: 2;
}
.rail-content.has-overflow::before,
.rail-content.has-overflow::after { width: 56px; }
.rail-wrap.has-overflow::before { left: 0;
  background: linear-gradient(90deg, var(--bg) 0%, transparent 100%); }
.rail-wrap.has-overflow::after  { right: 0;
  background: linear-gradient(-90deg, var(--bg) 0%, transparent 100%); }
.section.band .rail-wrap.has-overflow::before { background: linear-gradient(90deg, var(--bg-band) 0%, transparent 100%); }
.section.band .rail-wrap.has-overflow::after  { background: linear-gradient(-90deg, var(--bg-band) 0%, transparent 100%); }
/* Nav rail edge fade should match the pill background, not page bg */
.rail-nav.has-overflow::before,
.rail-nav.has-overflow::after { width: 22px; }
.rail-nav.has-overflow::before { background: linear-gradient(90deg, #0F0F0F 0%, transparent 100%); }
.rail-nav.has-overflow::after  { background: linear-gradient(-90deg, #0F0F0F 0%, transparent 100%); }
[data-theme="light"] .rail-nav.has-overflow::before { background: linear-gradient(90deg, #FFFFFF 0%, transparent 100%); }
[data-theme="light"] .rail-nav.has-overflow::after  { background: linear-gradient(-90deg, #FFFFFF 0%, transparent 100%); }
html[dir="rtl"] .rail-wrap.has-overflow::before,
html[dir="rtl"] .rail-wrap.has-overflow::after {
  background: linear-gradient(90deg, var(--bg) 0%, transparent 100%);
}
html[dir="rtl"] .section.band .rail-wrap.has-overflow::before,
html[dir="rtl"] .section.band .rail-wrap.has-overflow::after {
  background: linear-gradient(90deg, var(--bg-band) 0%, transparent 100%);
}

/* Arrow buttons — small, elegant, premium */
.rail-arrow {
  position: absolute;
  top: 50%;
  width: 36px; height: 36px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: var(--bg-elev);
  border: 1px solid var(--line);
  color: var(--ink);
  cursor: pointer;
  z-index: 6;
  transform: translateY(-50%);
  opacity: 0;
  pointer-events: none;
  transition: opacity .25s, border-color .25s, background .25s, transform .25s ease;
  box-shadow: 0 6px 18px -6px rgba(0,0,0,.25);
}
[data-theme="dark"] .rail-arrow {
  background: rgba(28,28,28,.92);
  border-color: rgba(255,255,255,.12);
  color: #FFFFFF;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
.rail-wrap.has-overflow .rail-arrow { opacity: 1; pointer-events: auto; }
.rail-arrow:hover {
  transform: translateY(-50%) scale(1.08);
  border-color: rgba(229,85,200,.5);
  color: var(--ink);
}
.rail-arrow:focus-visible {
  outline: 2px solid rgba(229,85,200,.55);
  outline-offset: 3px;
}
.rail-arrow.is-disabled { opacity: 0; pointer-events: none; }
.rail-arrow-prev { left: -14px; }
.rail-arrow-next { right: -14px; }
html[dir="rtl"] .rail-arrow-prev { left: auto; right: -14px; }
html[dir="rtl"] .rail-arrow-next { right: auto; left: -14px; }
html[dir="rtl"] .rail-arrow svg { transform: scaleX(-1); }

/* Nav arrow — slightly smaller, sits inside the pill */
.rail-nav .rail-arrow {
  width: 28px; height: 28px;
  box-shadow: none;
  background: rgba(255,255,255,.08);
  border-color: rgba(255,255,255,.14);
  color: rgba(255,255,255,.9);
  backdrop-filter: blur(6px);
}
[data-theme="light"] .rail-nav .rail-arrow {
  background: rgba(0,0,0,.04);
  border-color: rgba(0,0,0,.1);
  color: #0A0A0A;
}
.rail-nav .rail-arrow-prev { left: -6px; }
.rail-nav .rail-arrow-next { right: -6px; }
html[dir="rtl"] .rail-nav .rail-arrow-prev { left: auto; right: -6px; }
html[dir="rtl"] .rail-nav .rail-arrow-next { right: auto; left: -6px; }

/* Content carousels — convert existing grids into flex rails */
.opt-carousel.rail-scroller {
  display: flex !important;
  flex-wrap: nowrap !important;
  gap: 18px;
  overflow-x: auto;
  overflow-y: visible;
  scroll-snap-type: x mandatory;
  scroll-padding-inline: 4px;
  scroll-behavior: smooth;
  scrollbar-width: none;
  -ms-overflow-style: none;
  padding: 6px 4px 16px;
  margin: 0 -4px;
  /* override grid columns */
  grid-template-columns: none !important;
  grid-template-rows: none !important;
}
.opt-carousel.rail-scroller::-webkit-scrollbar { display: none; }
.opt-carousel.rail-scroller > * {
  flex: 0 0 auto;
  scroll-snap-align: start;
  margin: 0;
}

/* Per-section card widths in carousel mode */
.opt-carousel-svc > *      { width: clamp(280px, 30vw, 360px); }
.opt-carousel-cases > *    { width: clamp(300px, 36vw, 440px); }
.opt-carousel-courses > *  { width: clamp(260px, 28vw, 320px); }
.opt-carousel-blog > *     { width: clamp(280px, 32vw, 380px); }
.opt-carousel-amb > *      { width: clamp(280px, 30vw, 340px); }

@media (max-width: 720px) {
  .opt-carousel.rail-scroller { gap: 14px; }
  .opt-carousel > * { width: min(86vw, 360px) !important; }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  .rail-scroller { scroll-behavior: auto; }
  .opt-carousel.rail-scroller { scroll-snap-type: none; }
}

/* On tablet 880-1024 keep nav visible as a scroll rail instead
   of hiding it. (Was display:none ≤1024.) */
@media (min-width: 881px) and (max-width: 1024px) {
  .primary-nav { display: flex !important; }
  .menu-toggle { display: none !important; }
}
@media (max-width: 880px) {
  /* Hide the rail-wrap holding primary-nav when hamburger takes over */
  .rail-wrap.rail-nav { display: none; }
}


/* ============================================================
   BILINGUAL COURSE CARD TITLES — Arabic + English always shown
   ============================================================ */
.course-title-bi {
  font-family: var(--font-sans);
  font-size: 17px;
  line-height: 1.3;
  letter-spacing: -.01em;
  display: block;
  margin: 0;
}
.course-title-bi .cti-ar {
  font-family: var(--font-ar);
  font-weight: 700;
  color: var(--ink);
  font-size: 17.5px;
  background: linear-gradient(110deg, #FDD196 0%, #FF966D 22%, #E555C8 48%, #BE6FD2 65%, #54B3EC 82%, #00FEFF 100%);
  -webkit-background-clip: text; background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
}
.course-title-bi .cti-sep {
  color: var(--ink-3);
  margin: 0 .35em;
  font-weight: 400;
}
.course-title-bi .cti-en {
  font-family: var(--font-sans);
  font-weight: 700;
  color: var(--ink);
}
/* Better wrap behaviour — keep parts together but allow break between halves */
.course-title-bi .cti-ar, .course-title-bi .cti-en { white-space: normal; }

/* In RTL pages, give the Arabic half visual prominence first */
html[dir="rtl"] .course-title-bi { text-align: right; }


/* ============================================================
   AMBIENT OPTIIIMUM GRADIENT MOTION — site-wide, very subtle
   One global drifting blob layer behind everything (fixed),
   plus a faint atmospheric wash inside solid-bg .section.band.
   Performance-safe: pure CSS, no JS, single-layer transforms.
   ============================================================ */
body { position: relative; isolation: isolate; }
body::before {
  content: "";
  position: fixed;
  inset: -12%;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(36% 26% at 18% 22%, rgba(229,85,200,.16), transparent 70%),
    radial-gradient(34% 24% at 78% 28%, rgba(84,179,236,.14), transparent 70%),
    radial-gradient(40% 30% at 28% 78%, rgba(255,150,109,.12), transparent 70%),
    radial-gradient(35% 26% at 80% 82%, rgba(0,254,255,.11), transparent 70%);
  filter: blur(70px);
  opacity: .55;
  animation: optAmbientDrift 28s ease-in-out infinite alternate;
  will-change: transform, opacity;
}
[data-theme="light"] body::before {
  opacity: .35;
  background:
    radial-gradient(36% 26% at 18% 22%, rgba(229,85,200,.13), transparent 70%),
    radial-gradient(34% 24% at 78% 28%, rgba(84,179,236,.11), transparent 70%),
    radial-gradient(40% 30% at 28% 78%, rgba(255,150,109,.10), transparent 70%),
    radial-gradient(35% 26% at 80% 82%, rgba(0,254,255,.09), transparent 70%);
}

/* Ambient wash for .section.band — solid background hides body layer.
   Use ::before so we don't conflict with section's own ::after. */
.section.band { position: relative; isolation: isolate; }
.section.band > .container { position: relative; z-index: 1; }
.section.band::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(40% 30% at 22% 30%, rgba(229,85,200,.10), transparent 70%),
    radial-gradient(36% 28% at 80% 70%, rgba(84,179,236,.08), transparent 70%);
  filter: blur(50px);
  opacity: .8;
  animation: optAmbientDrift 32s ease-in-out infinite alternate-reverse;
}
[data-theme="light"] .section.band::before { opacity: .55; }

@keyframes optAmbientDrift {
  0%   { transform: translate3d(0,0,0) scale(1); }
  50%  { transform: translate3d(2%, -1.5%, 0) scale(1.05); }
  100% { transform: translate3d(-1.5%, 2%, 0) scale(1.02); }
}

@media (prefers-reduced-motion: reduce) {
  body::before, .section.band::before { animation: none !important; }
}

/* Make sure stacking is right — important interactive layers stay above */
.topbar, .hero, .section, .final-cta-section, .foot, .intro { position: relative; }


/* ============================================================
   HOME BLOG PREVIEW — covers + premium card body
   ============================================================ */
.blog-grid .blog-card {
  display: flex;
  flex-direction: column;
  background: var(--bg-elev);
  border: 1px solid var(--line);
  border-radius: 20px;
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  transition: transform .3s cubic-bezier(.2,.8,.2,1), border-color .3s, box-shadow .3s;
}
.blog-grid .blog-card:hover {
  transform: translateY(-3px);
  border-color: rgba(229,85,200,.4);
  box-shadow: 0 18px 44px -22px rgba(229,85,200,.35);
}
.blog-grid .blog-card .thumb {
  aspect-ratio: 16 / 10;
  background-size: cover;
  background-position: center;
  background-color: var(--bg-band);
  transition: transform .5s cubic-bezier(.2,.8,.2,1);
}
.blog-grid .blog-card:hover .thumb { transform: scale(1.04); }
.blog-grid .blog-card .body {
  padding: 22px 22px 24px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  flex: 1;
}
.blog-grid .blog-card .date {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--ink-3);
}
html[lang="ar"] .blog-grid .blog-card .date { font-family: var(--font-ar); letter-spacing: 0; text-transform: none; font-size: 13px; }
.blog-grid .blog-card h3 {
  font-family: var(--font-sans);
  font-size: 19px;
  line-height: 1.25;
  letter-spacing: -.015em;
  color: var(--ink);
  margin: 0;
  text-wrap: balance;
}
.blog-grid .blog-card p {
  color: var(--ink-2);
  font-size: 14.5px;
  line-height: 1.6;
  margin: 0;
}
.blog-grid .blog-card .read {
  margin-top: auto;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--ink);
  display: inline-flex;
  gap: 6px;
  align-items: center;
  width: max-content;
  padding-bottom: 3px;
  border-bottom: 1px solid var(--line);
  transition: border-color .2s;
}
.blog-grid .blog-card:hover .read { border-color: var(--ink); }
html[lang="ar"] .blog-grid .blog-card .read { font-family: var(--font-ar); letter-spacing: 0; text-transform: none; font-size: 13px; }

/* ============================================================
   FACE-SAFE PEOPLE CARDS — site-wide, applies to every people card.
   Rule: no label/badge/tag overlays a person's face, head, or upper
   body. Category chips live ABOVE the photo. Portraits use a
   smarter face-safe object-position. Images never crop heads.
   ============================================================ */

/* -- 1. AMBASSADOR CARDS (Ambassadors.html + Home preview) -- */
/* DOM order is: .amb-portrait, .amb-body, .amb-cat
   We use flex order to reposition the category chip BETWEEN the
   portrait and the body — never on top of the face. */
.amb-card {
  display: flex !important;
  flex-direction: column !important;
}
.amb-card .amb-portrait { order: 0; }
.amb-card .amb-cat      { order: 1; }
.amb-card .amb-body     { order: 2; }

/* Category chip — moved out of the photo, into the card body strip.
   Looks like a clean Optiiimum-style top-of-meta chip. */
.amb-card .amb-cat {
  position: static !important;          /* override prior absolute placement */
  top: auto !important;
  inset-inline-end: auto !important;
  max-width: none !important;
  white-space: normal !important;
  display: inline-flex !important;
  align-items: center;
  gap: 8px;
  margin: 16px 22px 0 !important;       /* sits above the name in the body */
  align-self: flex-start;
  padding: 6px 11px 6px 9px !important;
  border-radius: 999px !important;
  background: transparent !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  border: 1px solid var(--line) !important;
  color: var(--ink-2) !important;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: .12em;
  text-transform: uppercase;
  line-height: 1.2;
  pointer-events: auto;
}
.amb-card .amb-cat::before {
  content: "";
  width: 6px; height: 6px; border-radius: 50%;
  background: linear-gradient(135deg, var(--grad-3, #E555C8), var(--grad-5, #54B3EC));
  flex: none;
  box-shadow: 0 0 0 2px rgba(229,85,200,.12);
}
[data-theme="dark"] .amb-card .amb-cat {
  border-color: rgba(255,255,255,.12) !important;
  color: rgba(255,255,255,.78) !important;
}
html[lang="ar"] .amb-card .amb-cat {
  font-family: var(--font-ar);
  letter-spacing: 0;
  text-transform: none;
  font-size: 12px;
}

/* Body sits below the chip — re-tighten its top padding so the chip
   reads as part of the meta block rather than floating in space. */
.amb-card .amb-body { padding-top: 14px !important; }

/* Portrait — face-safe positioning. Head/eyes always visible. */
.amb-card .amb-portrait {
  aspect-ratio: 4 / 5;
}
.amb-card .amb-portrait img {
  object-fit: cover !important;
  object-position: 50% 12% !important;   /* head/eyes priority */
}

/* Mobile: tighter chip margin, same logic */
@media (max-width: 560px) {
  .amb-card .amb-cat { margin: 14px 18px 0 !important; font-size: 9.5px; }
  .amb-card .amb-body { padding: 12px 18px 18px !important; }
}

/* -- 2. TEAM ROLE CARDS (Team.html + any .amb in grids) -- */
/* The team page uses .amb cards where role label lives inside .body
   (already safe). We just tighten face-safe object-position so heads
   aren't cropped on any of the 25 team portraits. */
.amb .photo {
  aspect-ratio: 4 / 5;
  background-size: cover !important;
  background-position: center 16% !important;  /* head priority */
}
.amb .photo img {
  object-fit: cover;
  object-position: center 16%;
}
/* If a card explicitly sets background-position inline (existing code
   does this), we let it win — but we set 16% as the default fallback. */

/* -- 3. REAL PEOPLE / CULTURE STRIP (Home Inside Optiiimum, Team) -- */
/* Captions stay at bottom inside the dark gradient — already safe.
   We reinforce face-safe object-position and ensure the bottom
   gradient never climbs past the lower 40% of the photo. */
.cs-card::after {
  background: linear-gradient(180deg,
    transparent 0%, transparent 55%,
    rgba(0,0,0,.55) 80%, rgba(0,0,0,.82) 100%
  ) !important;
}
.cs-card figcaption {
  /* Force caption to bottom safe-zone only */
  top: auto !important;
  bottom: 12px !important;
}

/* -- 4. CASE-STUDY PERSON CARDS (.case-card .visual + .stat-pill) -- */
/* When the visual is a person photo, the stat-pill currently sits in
   the bottom-left corner with a dark gradient overlay — that's safe
   for the face. We strengthen face-safety by making sure the visual
   uses face-priority background-position and the bottom gradient
   stays out of the upper half. */
.case-card .visual {
  background-position: center 22% !important;
}
.case-card .visual .stat-pill {
  /* Already bottom-positioned — just reinforce */
  top: auto;
}

/* -- 5. STORY PORTRAIT (About.html Jozeph card) -- */
/* The dark bottom gradient + label is already in a safe zone at the
   bottom. Tighten the gradient so it doesn't climb past 55%, and
   bias the background to keep face visible. */
.story-portrait {
  background-position: center 18% !important;
  background-size: cover !important;
}
.story-portrait::after {
  background: linear-gradient(180deg,
    transparent 0%, transparent 55%,
    rgba(0,0,0,.45) 78%, rgba(0,0,0,.72) 100%
  ) !important;
}

/* -- 6. INTRO PERSON CARDS (Home cinematic intro) -- */
/* The intro person cards have a dark bottom gradient overlay with a
   role tag inside — already in a safe zone. Reinforce object-position
   to ensure the head/face is always visible for any randomized portrait. */
.intro-card.card-person img {
  object-fit: cover;
  object-position: 50% 14%;
}

/* -- 7. UNIVERSAL FALLBACK: any <img> inside a known people container -- */
/* Prevents head-cropping if a new card type is added later. */
.amb-portrait img,
.amb .photo img,
.story-portrait > img {
  object-fit: cover;
  object-position: 50% 16%;
}

/* -- 8. ARABIC RTL: chip alignment -- */
html[dir="rtl"] .amb-card .amb-cat {
  align-self: flex-end;
  margin: 16px 22px 0 !important;
}
@media (max-width: 560px) {
  html[dir="rtl"] .amb-card .amb-cat { margin: 14px 18px 0 !important; }
}

/* ============================================================
   ARABIC HERO TYPOGRAPHY — premium editorial composition
   Two-font system: bold IBM Plex Sans Arabic for main words,
   "GESS Two Light" (with Tajawal Light fallback) for the
   gradient/accent rotator word. Spacing, line-height, and
   letter-spacing are all RTL-aware to prevent overlap.
   ============================================================ */

/* GESS Two Light — try local install first (Saudi-market designers
   often have this licensed), then fall back to a near-identical
   web-safe Light Arabic display face. */
@font-face {
  font-family: "GESS Two Light";
  src: local("GE SS Two Light"),
       local("GESS Two Light"),
       local("GE SS Two-Light"),
       local("GESSTwo-Light"),
       local("GE SS Two Lt"),
       local("GE SS Two"),
       local("Tajawal Light"),
       local("Tajawal-Light");
  font-weight: 300;
  font-style: normal;
  font-display: swap;
}

html {
  /* Bold/main Arabic stack — kept as-is for body text */
  --font-ar: "IBM Plex Sans Arabic", "Tajawal", "Segoe UI", Tahoma, sans-serif;
  /* Light/accent Arabic stack — tries GESS Two Light then degrades
     gracefully through Tajawal Light → Cairo Light → IBM Plex Light. */
  --font-ar-light: "GESS Two Light", "Tajawal", "Cairo", "IBM Plex Sans Arabic", "Segoe UI", Tahoma, sans-serif;
}

/* ---- 1. HERO HEADLINE STATIC TEXT (Arabic) ---- */
/* Generous line-height, no negative tracking, proper RTL flow. */
html[lang="ar"] .hero h1 {
  font-family: var(--font-ar);
  font-weight: 700;
  line-height: 1.55;           /* generous for Arabic ascenders/descenders */
  letter-spacing: 0 !important; /* never compress Arabic glyphs */
  text-align: start;
  word-spacing: .02em;
  max-width: 22ch;             /* gentle measure to keep editorial rhythm */
  text-wrap: balance;
  margin-block-start: 24px;
}
html[lang="ar"] .hero h1 .i18n-ar {
  display: block;
  /* small breathing space above so the descenders of the preceding
     chip never visually crash into ascenders of the headline */
  padding-block-start: 4px;
}

/* ---- 2. ROTATOR (the accent word) — GESS Two Light + gradient ---- */
/* This is the only Arabic word that uses the light accent face. */
html[lang="ar"] .hero-rotator,
html[lang="ar"] .hero-rotator .rw,
html[lang="ar"] .hero-rotator .rw-measure {
  font-family: var(--font-ar-light) !important;
  font-weight: 300 !important;           /* GESS Two Light feel */
  letter-spacing: 0 !important;          /* never overlap Arabic glyphs */
  font-style: normal;
}
/* Spacing around the accent word so it doesn't crash neighbours.
   Logical margin works in both LTR/RTL. */
html[lang="ar"] .hero-rotator {
  margin-inline: .25em;
  padding-block: .12em;          /* vertical breathing room for marks */
  line-height: inherit;          /* match h1 line-height */
  /* The rotator container clips its rolling word — give it enough
     vertical space so Arabic descenders (ج، ع، ق، ي) never get cut. */
  min-height: 1.1em;
}
/* Slightly tighter, intentional translateY for the upward roll so
   Arabic glyphs land on the right baseline — the prior 100% value
   was tuned for Latin caps and clipped Arabic descenders. */
html[lang="ar"] .hero-rotator .rw          { transform: translateY(115%); }
html[lang="ar"] .hero-rotator .rw.in       { transform: translateY(0); }
html[lang="ar"] .hero-rotator .rw.out      { transform: translateY(-115%); }

/* ---- 3. HERO LEDE (Arabic) ---- */
html[lang="ar"] .hero .lede {
  font-family: var(--font-ar);
  font-weight: 400;
  font-size: clamp(15px, 1.35vw, 18px);
  line-height: 1.85;
  letter-spacing: 0;
  max-width: 52ch;
  text-wrap: pretty;
  margin-top: 28px;
}

/* ---- 4. HERO CHIP (Arabic) — small chip above headline ---- */
html[lang="ar"] .hero .chip {
  font-family: var(--font-ar);
  font-weight: 500;
  letter-spacing: 0;
  font-size: 13px;
}

/* ---- 5. CTAs + stats spacing under Arabic hero ---- */
html[lang="ar"] .hero-ctas {
  margin-top: 36px;
  gap: 14px;
}
html[lang="ar"] .hero-stats {
  margin-top: 56px;
}

/* ---- 6. RESPONSIVE ---- */
@media (max-width: 920px) {
  html[lang="ar"] .hero h1 {
    line-height: 1.5;
    max-width: 26ch;
  }
}
@media (max-width: 720px) {
  html[lang="ar"] .hero h1 {
    font-size: clamp(32px, 8.5vw, 52px);
    line-height: 1.45;
    max-width: 100%;
  }
  html[lang="ar"] .hero .lede {
    font-size: 15px;
    line-height: 1.75;
    margin-top: 22px;
  }
  html[lang="ar"] .hero-ctas { margin-top: 28px; }
  html[lang="ar"] .hero-stats { margin-top: 44px; }
}

/* ---- 7. Make sure Arabic gradient text on the rotator renders
        crisply — Arabic glyphs at large sizes can show seams in
        the gradient if anti-aliasing is off. ---- */
html[lang="ar"] .hero-rotator .rw,
html[lang="ar"] .hero-rotator .rw-measure {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ---- 8. ARABIC HERO LINE BREAK ----
   The Arabic rotator sits on its OWN LINE below the main phrase
   because Arabic adjectives follow the noun, not precede it. The
   English version keeps its inline rotator; Arabic gets an
   editorial two-line composition. */
.hero-ar-rotator-line {
  display: block;
  margin-top: .35em;
  /* Slightly larger and more emphatic to anchor the second line. */
  line-height: 1.2;
}
.hero-ar-rotator-line .hero-rotator {
  display: inline-block;
  font-size: 1.05em;                 /* a touch larger than the main line */
  vertical-align: baseline;
  margin-inline: 0;
}
/* Hide the Arabic rotator-line wrapper in non-Arabic mode so the
   English path is unaffected. */
html:not([lang="ar"]) .hero-ar-rotator-line { display: none; }

/* ============================================================
   REAL PEOPLE GRID — uniform editorial grid for the
   "Real people building real growth systems." section.
   1 featured card (top-right of row, 2×2) + 4 same-size cards.
   Replaces the old asymmetric .culture-strip / .cs-card bento.
   ============================================================ */
.real-people-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-template-rows: 1fr 1fr;
  grid-template-areas:
    "c1 c2 f f"
    "c3 c4 f f";
  gap: 14px;
  margin: 40px 0 28px;
  /* Each row at minimum 220px so the featured card stays a generous
     2× of a small card. Auto-rows clamp to viewport on wider screens. */
  grid-auto-rows: minmax(220px, 1fr);
}
.rp-c1       { grid-area: c1; }
.rp-c2       { grid-area: c2; }
.rp-c3       { grid-area: c3; }
.rp-c4       { grid-area: c4; }
.rp-featured { grid-area: f;  }

/* Every card — uniform style, rounded, premium border, hover lift */
.rp-card {
  position: relative;
  margin: 0;
  overflow: hidden;
  border-radius: 18px;
  background: var(--bg-band);
  border: 1px solid var(--line);
  isolation: isolate;
  transition: transform .35s cubic-bezier(.2,.8,.2,1), box-shadow .35s, border-color .35s;
}
.rp-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 18px 44px -22px rgba(229,85,200,.4), 0 6px 16px -8px rgba(0,0,0,.25);
}
[data-theme="light"] .rp-card { border-color: rgba(0,0,0,.06); }

/* Optional gradient border on hover — matches ambassadors/case cards */
.rp-card::before {
  content: ""; position: absolute; inset: -1px;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(135deg, #FDD196, #FF966D, #E555C8, #BE6FD2, #54B3EC, #00FEFF);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
          mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  opacity: 0;
  transition: opacity .35s ease;
  pointer-events: none;
  z-index: 3;
}
.rp-card:hover::before { opacity: .85; }

/* The photo — face-safe object-position, cover, no head cropping */
.rp-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 28%;     /* face-safe: keep heads/eyes in frame */
  transition: transform .6s cubic-bezier(.2,.8,.2,1), filter .3s ease;
  display: block;
}
.rp-card:hover img { transform: scale(1.04); filter: saturate(1.06); }

/* The featured card uses a slightly higher head-priority bias —
   wider crops can swallow heads if 28% is used. */
.rp-card.rp-featured img { object-position: 50% 30%; }

/* Bottom-only dark gradient — caption sits in the safe zone, never
   overlapping the face area. */
.rp-card::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(180deg,
    transparent 0%, transparent 55%,
    rgba(0,0,0,.55) 78%, rgba(0,0,0,.82) 100%);
  pointer-events: none;
  z-index: 1;
}

/* Caption — bottom-pinned pill, premium compact */
.rp-card figcaption {
  position: absolute;
  left: 12px; right: 12px; bottom: 12px;
  z-index: 2;
  padding: 8px 12px;
  border-radius: 10px;
  background: rgba(11,11,11,.65);
  backdrop-filter: blur(8px) saturate(140%);
  -webkit-backdrop-filter: blur(8px) saturate(140%);
  border: 1px solid rgba(255,255,255,.12);
  display: flex; flex-direction: column; gap: 2px;
}
.rp-card .rp-name {
  font-family: var(--font-sans);
  font-weight: 700;
  font-size: 14px;
  line-height: 1.2;
  color: #FFFFFF;
  letter-spacing: -.012em;
}
.rp-card .rp-role {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: rgba(255,255,255,.78);
}
html[lang="ar"] .rp-card .rp-name {
  font-family: var(--font-ar);
  font-weight: 600;
  font-size: 14.5px;
}
html[lang="ar"] .rp-card .rp-role {
  font-family: var(--font-ar);
  letter-spacing: 0;
  text-transform: none;
  font-size: 11.5px;
}

/* Featured card — bigger caption to match larger frame */
.rp-card.rp-featured .rp-name { font-size: 18px; }
.rp-card.rp-featured figcaption {
  left: 16px; right: 16px; bottom: 16px;
  padding: 10px 14px;
}

/* RESPONSIVE — keep face-safe + uniform sizing on every breakpoint.
   On tablet, drop to 3 columns: featured spans 2×2, then 4 small cards
   stack on the side. On phones, single column with featured at top. */
/* Tablet: keep the same 4-col / 2-row layout — featured stays at the
   top-end of the row, four small cards all identical size. We just
   shrink the row height. NO aspect-ratio overrides — equality holds. */
@media (max-width: 1080px) {
  .real-people-grid {
    grid-auto-rows: minmax(170px, 1fr);
    gap: 12px;
  }
}
/* Smaller tablet: stack featured full-width on top, four small cards
   form a uniform 2×2 grid beneath — every small card identical. */
@media (max-width: 820px) {
  .real-people-grid {
    grid-template-columns: 1fr 1fr;
    grid-template-areas:
      "f  f"
      "c1 c2"
      "c3 c4";
    grid-auto-rows: minmax(170px, 1fr);
    gap: 10px;
  }
  .rp-card.rp-featured { aspect-ratio: 16 / 10; }
  .rp-card .rp-name { font-size: 13px; }
  .rp-card.rp-featured .rp-name { font-size: 16px; }
}
@media (max-width: 480px) {
  .real-people-grid {
    grid-template-columns: 1fr;
    grid-template-areas:
      "f"
      "c1"
      "c2"
      "c3"
      "c4";
    grid-auto-rows: minmax(220px, auto);
  }
  .rp-card.rp-featured { aspect-ratio: 16 / 10; }
}

/* Hide the legacy .culture-strip if present elsewhere in the section —
   we use the new .real-people-grid now. */
#team .culture-strip { display: none !important; }


/* ============================================================
   PRIMARY NAV — paged slider (shared across all pages).
   Was inline in Home.html; moved here so every page that links
   home.css gets the same tab look + gradient active state.
   ============================================================ */
.primary-nav-wrap {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 1 1 auto;
  min-width: 0;
  max-width: 980px;
  margin: 0 auto;
  padding: 0 12px;
}
.nav-arrow {
  flex: none;
  width: 36px; height: 36px;
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--bg-elev, transparent);
  border: 1px solid var(--ink-3);
  border-radius: 999px;
  color: var(--ink);
  cursor: pointer; padding: 0;
  position: relative;
  transition: color .18s ease, border-color .18s ease, background .18s ease, transform .15s ease, opacity .18s ease, box-shadow .18s ease;
  box-shadow: 0 1px 2px rgba(0,0,0,.04);
}
.nav-arrow::after {
  /* pulse ring to draw the eye when there's more to scroll */
  content: ""; position: absolute; inset: -3px;
  border-radius: 999px; pointer-events: none;
  border: 1px solid var(--ink-3); opacity: 0;
  animation: navPulse 2.4s ease-out infinite;
}
.nav-arrow[disabled]::after, .nav-arrow.is-disabled::after { display: none; }
@keyframes navPulse {
  0% { transform: scale(.85); opacity: .55; }
  70% { transform: scale(1.35); opacity: 0; }
  100% { transform: scale(1.35); opacity: 0; }
}
.nav-arrow svg { width: 14px; height: 14px; }
.nav-arrow:hover {
  color: var(--ink);
  border-color: var(--ink);
  background: rgba(127,127,127,.06);
}
.nav-arrow:active { transform: scale(.94); }
.nav-arrow:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
.nav-arrow[disabled], .nav-arrow.is-disabled {
  opacity: .28; cursor: default; pointer-events: none;
}
html[dir="rtl"] .nav-arrow svg { transform: scaleX(-1); }

.nav-slider {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  position: relative;
  padding: 0 8px;
  -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 14px, #000 calc(100% - 14px), transparent 100%);
          mask-image: linear-gradient(90deg, transparent 0, #000 14px, #000 calc(100% - 14px), transparent 100%);
}
.nav-track {
  display: flex;
  align-items: stretch;
  direction: ltr;
  transition: transform .42s cubic-bezier(.2,.8,.2,1);
  will-change: transform;
}
.nav-track > a {
  flex: 0 0 25%;
  max-width: 25%;
  min-width: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  font-size: 13.5px;
  font-weight: 500;
  color: var(--ink-2);
  padding: 9px 14px;
  white-space: nowrap;
  text-overflow: ellipsis;
  overflow: hidden;
  border-radius: 999px;
  transition: color .15s ease, background .15s ease;
}
[data-theme="light"] .nav-track > a { color: rgba(0,0,0,.65); }
.nav-track > a:hover {
  color: var(--ink);
  background: rgba(127,127,127,.06);
}
.nav-track > a[aria-current="page"] {
  background: linear-gradient(120deg, var(--grad-1), var(--grad-2), var(--grad-3), var(--grad-4), var(--grad-5), var(--grad-6));
  color: #0A0A0A;
  font-weight: 600;
}
[data-theme="light"] .nav-track > a[aria-current="page"] { color: #0A0A0A; }
html[lang="ar"] .nav-track > a {
  font-family: var(--font-ar);
  font-size: 14px;
  font-weight: 500;
}
html[lang="ar"] .nav-track > a[aria-current="page"] { font-weight: 700; }

@media (max-width: 1180px) {
  .primary-nav-wrap { max-width: 660px; gap: 8px; padding: 0 10px; }
  .nav-track > a { font-size: 13px; padding: 8px 10px; }
}
@media (max-width: 1024px) {
  .primary-nav-wrap { max-width: 520px; }
  .nav-track > a { font-size: 12.5px; padding: 7px 8px; letter-spacing: -.005em; }
}
@media (max-width: 880px) {
  .primary-nav-wrap { display: none; }
}
@media (min-width: 881px) and (max-width: 980px) {
  .nav-track > a { flex: 0 0 33.333%; max-width: 33.333%; }
  .primary-nav-wrap { --nav-per-page: 3; }
}
@media (min-width: 1280px) {
  .nav-track > a { flex: 0 0 20%; max-width: 20%; }
  .primary-nav-wrap { --nav-per-page: 5; }
}
.primary-nav-wrap { --nav-per-page: 4; }


/* ============================================================
   NAV — Creative upgrades
   liquid blob · magnetic hover · hide-on-scroll · scroll-aware
   bg · mega menu · work flyout · animated CTA · جديد badge ·
   logo Easter egg.
   ============================================================ */

/* Hide on scroll down / show on scroll up */
.topbar { transition: transform .35s cubic-bezier(.2,.8,.2,1); }
.topbar.is-hidden { transform: translateY(-160%); }

/* Scroll-aware background */
.topbar-inner {
  transition: background .3s ease, border-color .3s ease,
              box-shadow .3s ease, backdrop-filter .3s ease;
}
.topbar.scrolled .topbar-inner {
  background: rgba(14,14,14,.78);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  box-shadow: 0 12px 36px rgba(0,0,0,.55), 0 0 0 1px rgba(255,255,255,.04) inset;
}
[data-theme="light"] .topbar.scrolled .topbar-inner {
  background: rgba(255,255,255,.82);
  box-shadow: 0 12px 36px rgba(0,0,0,.08), 0 0 0 1px rgba(0,0,0,.04) inset;
}

/* Liquid blob — slides between active/hovered tab */
.nav-track { position: relative; }
.nav-blob {
  position: absolute;
  top: 50%; left: 0;
  height: 32px; width: 0;
  border-radius: 999px;
  background: linear-gradient(120deg, var(--grad-1), var(--grad-2), var(--grad-3), var(--grad-4), var(--grad-5), var(--grad-6));
  transform: translateY(-50%) translateX(0);
  transition: transform .42s cubic-bezier(.3, 1.4, .4, 1),
              width .42s cubic-bezier(.3, 1.4, .4, 1),
              opacity .25s ease;
  pointer-events: none; opacity: 0;
  z-index: 0;
  box-shadow: 0 0 18px rgba(229,85,200,.45), 0 0 36px rgba(0,254,255,.25);
  filter: saturate(1.1);
  will-change: transform, width;
}
.nav-blob.is-active { opacity: 1; }

/* Once the blob is live, hide the static gradient on the active tab */
.nav-track.has-blob > a[aria-current="page"] { background: transparent !important; }

/* Magnetic hover — translate per tab via custom prop */
.nav-track > a {
  position: relative; z-index: 1;
  transition: color .2s ease, transform .25s cubic-bezier(.2,.8,.2,1);
  transform: translate(var(--mx, 0), var(--my, 0));
}
.nav-track.has-blob > a:hover,
.nav-track.has-blob > a[aria-current="page"] { color: #0A0A0A; }
[data-theme="light"] .nav-track.has-blob > a:hover,
[data-theme="light"] .nav-track.has-blob > a[aria-current="page"] { color: #0A0A0A; }

/* جديد badge on Courses */
.nav-new-badge {
  display: inline-flex; align-items: center; gap: 4px;
  font-family: var(--font-mono);
  font-size: 9px; letter-spacing: .04em;
  padding: 2px 7px 2px 6px;
  border-radius: 999px;
  background: linear-gradient(120deg, var(--grad-3), var(--grad-5));
  color: #FFFFFF;
  margin-inline-start: 6px;
  vertical-align: 2px;
  position: relative;
  text-transform: uppercase;
}
.nav-new-badge::before {
  content: ""; width: 5px; height: 5px; border-radius: 50%;
  background: #FFFFFF;
  box-shadow: 0 0 0 0 rgba(255,255,255,.6);
  animation: navBadgePulse 1.6s ease-out infinite;
}
@keyframes navBadgePulse {
  0% { box-shadow: 0 0 0 0 rgba(255,255,255,.6); }
  100% { box-shadow: 0 0 0 8px rgba(255,255,255,0); }
}
html[lang="ar"] .nav-new-badge { font-family: var(--font-ar); text-transform: none; font-size: 10px; }

/* CTA — keep the static brand gradient (no rotating border / shimmer) */
.nav-cta { position: relative; isolation: isolate; }

/* Logo Easter egg — rotate on double-click */
.brand-link.is-spin .brand-name { animation: brandSpin 1.2s cubic-bezier(.4,1.4,.5,1); }
@keyframes brandSpin { to { transform: rotate(360deg); } }
.brand-name { transition: transform .3s; }

/* Mega menu (Services) + Work flyout (Case Studies) */
.nav-flyout, .work-flyout {
  position: absolute;
  top: calc(100% + 14px);
  left: 50%;
  transform: translateX(-50%) translateY(-8px);
  z-index: 70;
  opacity: 0; pointer-events: none;
  transition: opacity .25s ease, transform .3s cubic-bezier(.2,.8,.2,1);
}
.nav-flyout.is-open, .work-flyout.is-open {
  opacity: 1; pointer-events: auto;
  transform: translateX(-50%) translateY(0);
}

.nav-flyout {
  width: clamp(720px, 70vw, 920px);
  padding: 22px;
  border-radius: 22px;
  background: rgba(14,14,14,.92);
  backdrop-filter: blur(24px) saturate(180%);
  -webkit-backdrop-filter: blur(24px) saturate(180%);
  border: 1px solid rgba(255,255,255,.08);
  box-shadow: 0 24px 60px rgba(0,0,0,.55), 0 0 0 1px rgba(255,255,255,.04) inset;
}
[data-theme="light"] .nav-flyout {
  background: rgba(255,255,255,.94);
  border-color: rgba(0,0,0,.06);
  box-shadow: 0 24px 60px rgba(0,0,0,.12), 0 0 0 1px rgba(0,0,0,.04) inset;
}
.nav-flyout-grid {
  display: grid; grid-template-columns: 1.2fr 1fr 1fr;
  gap: 22px; align-items: stretch;
}
.nav-flyout h4 {
  font-family: var(--font-mono); font-size: 10px;
  letter-spacing: .14em; text-transform: uppercase;
  color: var(--ink-3); margin: 0 0 12px;
}
html[lang="ar"] .nav-flyout h4 {
  font-family: var(--font-ar);
  letter-spacing: 0; text-transform: none; font-size: 12px;
}
.nav-services-list { display: grid; gap: 4px; }
.nav-service {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 10px;
  border-radius: 10px;
  color: var(--ink);
  text-decoration: none;
  transition: background .2s;
}
.nav-service:hover { background: rgba(255,255,255,.06); }
[data-theme="light"] .nav-service:hover { background: rgba(0,0,0,.04); }
.nav-service > svg { width: 18px; height: 18px; color: var(--ink-2); flex: none; }
.nav-service .ns-text b {
  display: block; font-weight: 600; font-size: 14px;
  letter-spacing: -.005em;
}
.nav-service .ns-text span { display: block; font-size: 12px; color: var(--ink-3); margin-top: 2px; }
html[lang="ar"] .nav-service .ns-text b { font-family: var(--font-ar); }

.nav-feature {
  position: relative;
  border-radius: 14px; overflow: hidden;
  aspect-ratio: 4/5;
  background-size: cover; background-position: center;
  display: block; text-decoration: none;
  min-height: 220px;
}
.nav-feature::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 40%, rgba(0,0,0,.85));
}
.nav-feature .nav-feature-body {
  position: absolute; left: 14px; right: 14px; bottom: 14px;
  z-index: 2; color: #FFFFFF;
}
.nav-feature .nav-feature-body b { display: block; font-weight: 700; font-size: 16px; }
.nav-feature .nav-feature-body span { display: block; font-size: 11.5px; color: rgba(255,255,255,.75); margin-top: 4px; }

.nav-cta-block {
  display: flex; flex-direction: column; gap: 14px;
  padding: 22px;
  border-radius: 16px;
  background: linear-gradient(135deg, rgba(229,85,200,.14), rgba(0,254,255,.1));
  border: 1px solid rgba(255,255,255,.08);
  justify-content: center;
  text-align: center;
}
[data-theme="light"] .nav-cta-block {
  background: linear-gradient(135deg, rgba(229,85,200,.08), rgba(0,254,255,.05));
  border-color: rgba(0,0,0,.06);
}
.nav-cta-block b {
  font-family: var(--font-sans); font-weight: 700;
  font-size: 17px; line-height: 1.3; letter-spacing: -.01em;
}
html[lang="ar"] .nav-cta-block b { font-family: var(--font-ar); }
.nav-cta-block .nav-cta-mini {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 10px 16px; border-radius: 999px;
  background: linear-gradient(120deg, var(--grad-1), var(--grad-3), var(--grad-5));
  color: #0A0A0A; text-decoration: none; font-weight: 700; font-size: 13px;
  letter-spacing: -.01em;
}
html[lang="ar"] .nav-cta-block .nav-cta-mini { font-family: var(--font-ar); }

/* Work flyout — small visual thumbnail row */
.work-flyout {
  display: flex; gap: 10px;
  padding: 14px;
  border-radius: 18px;
  background: rgba(14,14,14,.92);
  backdrop-filter: blur(24px) saturate(180%);
  -webkit-backdrop-filter: blur(24px) saturate(180%);
  border: 1px solid rgba(255,255,255,.08);
  box-shadow: 0 24px 60px rgba(0,0,0,.55);
}
[data-theme="light"] .work-flyout {
  background: rgba(255,255,255,.94);
  border-color: rgba(0,0,0,.06);
  box-shadow: 0 24px 60px rgba(0,0,0,.12);
}
.work-flyout a {
  position: relative;
  display: block;
  width: 124px; height: 162px;
  border-radius: 12px; overflow: hidden;
  background-size: cover; background-position: center;
  text-decoration: none;
  transition: transform .35s cubic-bezier(.2,.8,.2,1), opacity .35s;
}
.work-flyout a:nth-child(1) { transform: rotate(-2deg); }
.work-flyout a:nth-child(2) { transform: rotate(1deg); }
.work-flyout a:nth-child(3) { transform: rotate(-1deg); }
.work-flyout a:nth-child(4) { transform: rotate(2deg); }
.work-flyout:hover a { opacity: .35; }
.work-flyout a:hover { opacity: 1; transform: scale(1.05) rotate(0); z-index: 1; }
.work-flyout a::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 50%, rgba(0,0,0,.75));
  pointer-events: none;
}
.work-flyout a span {
  position: absolute; left: 10px; right: 10px; bottom: 10px; z-index: 2;
  font-family: var(--font-mono); font-size: 10px; letter-spacing: .08em;
  text-transform: uppercase; color: #FFFFFF;
  text-shadow: 0 1px 4px rgba(0,0,0,.6);
}
html[lang="ar"] .work-flyout a span {
  font-family: var(--font-ar);
  letter-spacing: 0; text-transform: none;
}

@media (max-width: 1023px) {
  .nav-flyout, .work-flyout { display: none !important; }
  .nav-new-badge { font-size: 8px; padding: 1px 5px; }
}

@media (prefers-reduced-motion: reduce) {
  .nav-blob, .nav-cta::before, .nav-cta::after,
  .brand-link.is-spin .brand-name,
  .nav-new-badge::before, .nav-track > a,
  .topbar, .topbar-inner {
    animation: none !important;
    transition: none !important;
  }
}


/* ============================================================
   NAV — Iconic mode
   Icons by default; hovering a tab smoothly expands it and
   slides the label in. Active page gets a permanent gradient
   glow. Mobile gets a floating bottom-nav with 5 quick icons.
   ============================================================ */

/* Disable the paged slider in iconic mode — show all tabs in one row */
.primary-nav-wrap.is-iconic-wrap {
  max-width: none;
  gap: 0;
  padding: 0 4px;
}
.primary-nav-wrap.is-iconic-wrap .nav-slider { overflow: visible; flex: 0 0 auto; }
.primary-nav-wrap.is-iconic-wrap .nav-arrow { display: none !important; }

.nav-track.is-iconic {
  gap: 2px;
  transform: none !important;
}

.nav-track.is-iconic > a {
  flex: 0 0 auto !important;
  max-width: 42px; min-width: 42px;
  height: 38px;
  padding: 0 11px;
  display: inline-flex; align-items: center; justify-content: center;
  gap: 0;
  border-radius: 999px;
  overflow: hidden;
  white-space: nowrap;
  font-size: 13px; letter-spacing: -.005em;
  position: relative; z-index: 1;
  transition:
    max-width .45s cubic-bezier(.32, .08, .24, 1),
    background .3s ease,
    color .3s ease,
    box-shadow .3s ease,
    transform .25s cubic-bezier(.2,.8,.2,1);
}
.nav-track.is-iconic > a:hover {
  max-width: 240px; min-width: auto;
  background: rgba(255,255,255,.06);
}
[data-theme="light"] .nav-track.is-iconic > a:hover { background: rgba(0,0,0,.05); }

.nav-track.is-iconic > a .nav-icon {
  display: inline-flex; align-items: center; justify-content: center;
  width: 18px; height: 18px; flex: none;
  color: currentColor;
}
.nav-track.is-iconic > a .nav-icon svg {
  width: 100%; height: 100%; display: block;
}

.nav-track.is-iconic > a .nav-label {
  display: inline-flex; align-items: center;
  max-width: 0;
  opacity: 0;
  margin-inline-start: 0;
  overflow: hidden;
  white-space: nowrap;
  transform: translateX(-6px);
  transition:
    max-width .45s cubic-bezier(.32, .08, .24, 1),
    margin-inline-start .45s cubic-bezier(.32, .08, .24, 1),
    opacity .3s cubic-bezier(.2,.8,.2,1) .05s,
    transform .45s cubic-bezier(.32, .08, .24, 1);
}
html[dir="rtl"] .nav-track.is-iconic > a .nav-label { transform: translateX(6px); }
.nav-track.is-iconic > a:hover .nav-label {
  max-width: 180px;
  opacity: 1;
  margin-inline-start: 8px;
  transform: translateX(0);
}

/* Hide the liquid blob in iconic mode — active state lives on the tab itself */
.nav-track.is-iconic .nav-blob { display: none !important; }

/* Active page — gradient glow halo on the icon */
.nav-track.is-iconic > a[aria-current="page"] {
  background: linear-gradient(120deg, var(--grad-1), var(--grad-2), var(--grad-3), var(--grad-4), var(--grad-5), var(--grad-6)) !important;
  color: #0A0A0A !important;
  box-shadow: 0 0 18px rgba(229,85,200,.45), 0 0 38px rgba(0,254,255,.22);
}
.nav-track.is-iconic > a[aria-current="page"] .nav-icon { color: #0A0A0A; }

/* جديد badge inside iconic tabs — keep it compact */
.nav-track.is-iconic > a .nav-new-badge {
  margin-inline-start: 6px;
  font-size: 8.5px;
  padding: 1px 5px;
  vertical-align: 0;
}

/* Sliders on narrow desktops where 13 icons would wrap — let them fit one row */
@media (max-width: 1280px) {
  .nav-track.is-iconic > a {
    max-width: 38px; min-width: 38px;
    padding: 0 9px; height: 36px;
  }
  .nav-track.is-iconic > a .nav-icon { width: 17px; height: 17px; }
  .nav-track.is-iconic > a:hover { max-width: 220px; }
}
@media (max-width: 1100px) {
  .nav-track.is-iconic > a {
    max-width: 34px; min-width: 34px;
    padding: 0 8px;
  }
  .nav-track.is-iconic > a .nav-icon { width: 16px; height: 16px; }
}

/* ============================================================
   Mobile bottom-nav — floating pill with 5 quick icons + More
   ============================================================ */
.bottom-nav {
  position: fixed;
  left: 16px; right: 16px;
  bottom: 14px;
  z-index: 55;
  display: none;
  align-items: center;
  justify-content: space-around;
  gap: 4px;
  padding: 8px 10px;
  border-radius: 999px;
  background: rgba(14,14,14,.86);
  backdrop-filter: blur(22px) saturate(180%);
  -webkit-backdrop-filter: blur(22px) saturate(180%);
  border: 1px solid rgba(255,255,255,.08);
  box-shadow: 0 16px 40px rgba(0,0,0,.55), 0 0 0 1px rgba(255,255,255,.04) inset;
  transition: transform .35s cubic-bezier(.2,.8,.2,1), opacity .25s ease;
}
[data-theme="light"] .bottom-nav {
  background: rgba(255,255,255,.92);
  border-color: rgba(0,0,0,.06);
  box-shadow: 0 16px 40px rgba(0,0,0,.1), 0 0 0 1px rgba(0,0,0,.03) inset;
}
.bottom-nav.is-hidden { transform: translateY(140%); opacity: 0; }

.bn-item {
  flex: 1 1 0;
  min-width: 0;
  display: inline-flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 3px;
  padding: 6px 4px;
  border: 0; background: transparent;
  text-decoration: none; cursor: pointer;
  color: rgba(255,255,255,.7);
  transition: color .2s ease, transform .2s ease;
  font-family: var(--font-mono);
  font-size: 9.5px; letter-spacing: .04em;
  text-transform: uppercase;
}
[data-theme="light"] .bn-item { color: rgba(0,0,0,.6); }
html[lang="ar"] .bn-item { font-family: var(--font-ar); letter-spacing: 0; text-transform: none; font-size: 11px; }
.bn-item:hover { color: var(--ink); }
.bn-item:active { transform: scale(.94); }
.bn-icon {
  display: inline-flex; align-items: center; justify-content: center;
  width: 22px; height: 22px;
}
.bn-icon svg { width: 100%; height: 100%; }
.bn-label {
  display: block;
  max-width: 60px;
  overflow: hidden; text-overflow: ellipsis;
  white-space: nowrap;
}
.bn-item[aria-current="page"] {
  color: transparent;
  background: linear-gradient(120deg, var(--grad-1), var(--grad-2), var(--grad-3), var(--grad-4), var(--grad-5), var(--grad-6));
  -webkit-background-clip: text; background-clip: text;
}
.bn-item[aria-current="page"] .bn-icon {
  color: var(--grad-3);
  filter: drop-shadow(0 0 8px rgba(229,85,200,.5));
}

@media (max-width: 880px) {
  .bottom-nav { display: flex; }
  /* push content above the bottom-nav so it doesn't overlap the footer */
  body { padding-bottom: 72px; }
  /* WhatsApp floating button — lift it above the bottom-nav */
  .wa-fab, .whatsapp-fab, [class*="WhatsApp"][class*="fab"] {
    bottom: 88px !important;
  }
}

@media (prefers-reduced-motion: reduce) {
  .nav-track.is-iconic > a, .nav-track.is-iconic > a .nav-label,
  .bottom-nav, .bn-item {
    transition: none !important;
  }
}

/* ============================================================
   HERO EMOJI BACKDROP — soft After-Effects-style floating motifs
   Lives behind the social-stack cards, never in front of text.
   ============================================================ */
.hero-emoji-bg {
  position: absolute;
  inset: -4% -2%;
  pointer-events: none;
  z-index: 1; /* below social-stack (z-index:2) and hero copy */
  overflow: hidden;
}
.hero-emoji-bg .he {
  position: absolute;
  left: var(--ex, 50%);
  bottom: -8%;
  font-size: clamp(22px, 2.4vw, 34px);
  opacity: 0;
  transform: translate3d(0, 0, 0) rotate(0);
  filter: drop-shadow(0 8px 22px rgba(0,0,0,.25));
  will-change: transform, opacity;
  animation: heroEmojiFloat var(--dur, 10s) cubic-bezier(.16, 1, 0.3, 1) var(--d, 0s) infinite;
  user-select: none;
}
@keyframes heroEmojiFloat {
  0%   { opacity: 0;   transform: translate3d(0, 20px, 0) rotate(0) scale(.85); }
  15%  { opacity: .22; }
  50%  { opacity: .28; transform: translate3d(8px, -55vh, 0) rotate(calc(var(--rot, 4deg) * .5)) scale(1); }
  85%  { opacity: .14; }
  100% { opacity: 0;   transform: translate3d(-6px, -110vh, 0) rotate(var(--rot, 4deg)) scale(.9); }
}
[data-theme="light"] .hero-emoji-bg .he {
  filter: drop-shadow(0 6px 16px rgba(0,0,0,.18));
}
@media (prefers-reduced-motion: reduce) {
  .hero-emoji-bg .he { animation: none; opacity: .12; transform: translate3d(0, -40vh, 0); }
}
@media (max-width: 560px) {
  /* Quieter on small screens — keep only every other emoji */
  .hero-emoji-bg .he:nth-child(2n) { display: none; }
  .hero-emoji-bg .he { font-size: 20px; }
}

/* ============================================================
   SOCIAL CARDS — calmer floating motion (replaces aggressive scFloat)
   The synchronized swap cycle is now driven by JS; CSS handles the
   gentle idle drift and ensures fade-out is smooth, not flickery.
   ============================================================ */
.sc {
  animation-name: scIn, scFloatGentle !important;
  animation-iteration-count: 1, infinite !important;
  animation-direction: normal, alternate !important;
  animation-fill-mode: forwards, none !important;
  animation-timing-function: cubic-bezier(.16, 1, 0.3, 1), ease-in-out !important;
}
@keyframes scFloatGentle {
  0%   { transform: translate3d(0, -4px, 0); }
  100% { transform: translate3d(0, 4px, 0); }
}
.sc, .sc-person-photo {
  transition: opacity .85s cubic-bezier(.16, 1, 0.3, 1);
}
.sc.is-swap-out { opacity: 0 !important; }
.sc.is-swap-in  { opacity: 1; }

/* Reduce motion: kill the gentle drift too */
@media (prefers-reduced-motion: reduce) {
  .sc { animation-name: scIn !important; animation-iteration-count: 1 !important; }
}


/* =============================================================
   PRODUCTION FIX (mobile nav, drawer, header layout)
   Force-hides the desktop primary nav on phones, surfaces the
   hamburger, and gives the mobile drawer a polished list with
   visible language/theme controls.
   ============================================================= */

@media (max-width: 880px) {
  /* Always hide the desktop tabbed nav on phones, even in iconic mode */
  .primary-nav-wrap,
  .primary-nav-wrap.is-iconic-wrap,
  .nav-slider,
  .nav-track,
  .nav-arrow { display: none !important; }

  /* Surface the hamburger */
  .menu-toggle { display: inline-flex !important; }

  /* Hide the bottom nav so the drawer is the single source of truth.
     The drawer already covers every page. */
  .bottom-nav { display: none !important; }
  body { padding-bottom: 0; }

  /* Tighten the topbar so the brand + actions fit cleanly */
  .topbar-inner {
    padding-top: 12px; padding-bottom: 12px;
    gap: 8px;
  }
  .topbar-actions {
    margin-inline-start: auto;
    gap: 6px;
    flex-wrap: nowrap;
  }
  /* CTA shrinks to icon on phones to leave room for the lang/theme/menu trio */
  .topbar-actions .nav-cta {
    padding: 0 14px; height: 36px;
    font-size: 12px; letter-spacing: -.005em;
  }
  .topbar-actions .nav-cta .arrow { display: none; }
  /* Lang + theme stay visible on phones */
  .topbar-actions .icon-btn { display: inline-flex !important; }
}

@media (max-width: 480px) {
  /* On very narrow screens, replace the CTA with a compact pill */
  .topbar-actions .nav-cta {
    padding: 0; width: 36px; height: 36px;
    overflow: hidden; text-indent: -999px;
    background-image: linear-gradient(120deg, var(--grad-1, #FDD196), var(--grad-3, #E555C8), var(--grad-5, #54B3EC));
    border-radius: 999px;
  }
  .topbar-actions .nav-cta::after {
    content: "📅"; text-indent: 0;
    position: absolute; inset: 0;
    display: flex; align-items: center; justify-content: center;
    font-size: 16px;
  }
}

/* -------- Mobile drawer polish + lang/theme rail -------- */
.mobile-menu {
  padding: 88px 24px 32px !important;
  gap: 2px !important;
}
.mobile-menu a {
  font-size: clamp(22px, 6vw, 28px) !important;
  padding: 12px 0 !important;
}
.mobile-menu .mm-actions {
  display: flex; flex-wrap: wrap; gap: 10px;
  padding: 24px 0 8px;
  margin-top: 12px;
  border-top: 1px solid var(--line, rgba(255,255,255,.08));
}
.mobile-menu .mm-pill {
  appearance: none;
  border: 1px solid rgba(255,255,255,.18);
  background: rgba(255,255,255,.04);
  color: inherit;
  padding: 10px 16px;
  border-radius: 999px;
  font-family: var(--font-mono, ui-monospace, monospace);
  font-size: 12px;
  letter-spacing: .06em;
  text-transform: uppercase;
  cursor: pointer;
  display: inline-flex; align-items: center; gap: 8px;
  transition: background .15s, border-color .15s, transform .15s;
}
.mobile-menu .mm-pill:active { transform: scale(.96); }
[data-theme="light"] .mobile-menu .mm-pill {
  border-color: rgba(0,0,0,.12);
  background: rgba(0,0,0,.03);
}
.mobile-menu .mm-pill.is-active {
  background: linear-gradient(120deg, var(--grad-1,#FDD196), var(--grad-3,#E555C8), var(--grad-5,#54B3EC));
  color: #fff;
  border-color: transparent;
}
.mobile-menu .mm-pill .mm-dot {
  display: inline-block; width: 10px; height: 10px; border-radius: 999px;
  background: linear-gradient(120deg, var(--grad-1,#FDD196), var(--grad-3,#E555C8), var(--grad-5,#54B3EC));
}
.mobile-menu .mm-group {
  display: flex; align-items: center; gap: 6px;
  padding: 6px; border-radius: 999px;
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.03);
}
[data-theme="light"] .mobile-menu .mm-group {
  border-color: rgba(0,0,0,.08);
  background: rgba(0,0,0,.02);
}
.mobile-menu .mm-group .mm-pill {
  border: 0;
  background: transparent;
  padding: 6px 14px;
}
.mobile-menu .mm-group .mm-pill.is-active {
  background: rgba(255,255,255,.10);
  color: inherit;
}
[data-theme="light"] .mobile-menu .mm-group .mm-pill.is-active {
  background: #fff;
  box-shadow: 0 2px 6px rgba(0,0,0,.08);
}
.mobile-menu .mm-section-label {
  font-family: var(--font-mono, ui-monospace, monospace);
  font-size: 10.5px;
  letter-spacing: .14em;
  text-transform: uppercase;
  opacity: .55;
  margin: 16px 0 8px;
  display: block;
}


/* ============================================================
   GLOBAL BRANDS — paginated slider (replaces auto marquee)
   ============================================================ */
.brands-slider {
  position: relative;
  padding: 6px 56px;
  max-width: 1100px;
  margin: 0 auto;
}
.brands-viewport {
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 4%, #000 96%, transparent 100%);
          mask-image: linear-gradient(90deg, transparent 0, #000 4%, #000 96%, transparent 100%);
}
.brands-track {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: calc((100% - (var(--brands-per-page, 6) - 1) * 36px) / var(--brands-per-page, 6));
  gap: 36px;
  align-items: center;
  transition: transform .55s cubic-bezier(.2,.8,.2,1);
  will-change: transform;
}
.brands-track img {
  width: 100%;
  max-height: 40px;
  height: auto;
  object-fit: contain;
  filter: brightness(0) saturate(100%) invert(11%);
  opacity: .7;
  transition: filter .2s, opacity .2s, transform .2s;
}
[data-theme="dark"] .brands-track img {
  filter: brightness(0) saturate(100%) invert(82%);
  opacity: .55;
}
.brands-track img:hover {
  filter: none;
  opacity: 1;
  transform: translateY(-2px);
}
.brands-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 40px; height: 40px;
  border-radius: 50%;
  border: 1px solid color-mix(in oklab, currentColor 18%, transparent);
  background: color-mix(in oklab, var(--bg, #0b0b0b) 70%, transparent);
  backdrop-filter: blur(6px);
  color: var(--ink, #FAFAF7);
  display: grid; place-items: center;
  cursor: pointer;
  z-index: 3;
  transition: border-color .18s, transform .18s, background .18s;
}
.brands-arrow:hover {
  border-color: color-mix(in oklab, currentColor 40%, transparent);
  transform: translateY(-50%) scale(1.06);
}
.brands-arrow[disabled],
.brands-arrow.is-disabled {
  opacity: .35;
  cursor: not-allowed;
}
.brands-prev { left: 4px; }
.brands-next { right: 4px; }
.brands-arrow svg { width: 18px; height: 18px; }
html[dir="rtl"] .brands-prev svg,
html[dir="rtl"] .brands-next svg { transform: scaleX(-1); }

.brands-dots {
  display: flex; justify-content: center; gap: 8px;
  margin-top: 22px;
}
.brands-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: color-mix(in oklab, currentColor 22%, transparent);
  border: 0; padding: 0; cursor: pointer;
  transition: background .18s, transform .18s, width .18s;
}
.brands-dot.is-active {
  background: linear-gradient(120deg, #FDD196, #E555C8, #54B3EC);
  width: 22px; border-radius: 999px;
}

@media (max-width: 1100px) {
  .brands-slider { padding: 6px 48px; }
}
@media (max-width: 760px) {
  .brands-slider { padding: 6px 44px; }
  .brands-track { gap: 22px; }
  .brands-track img { max-height: 32px; }
  .brands-arrow {
    width: 34px; height: 34px;
  }
  .brands-arrow svg { width: 15px; height: 15px; }
  .brands-prev { left: 2px; }
  .brands-next { right: 2px; }
  .brands-dots {
    display: flex !important;
    margin-top: 16px;
    gap: 6px;
  }
  .brands-dot { width: 6px; height: 6px; }
  .brands-dot.is-active { width: 18px; }
}
@media (max-width: 520px) {
  .brands-slider { padding: 4px 38px; }
  .brands-track img { max-height: 28px; }
}

/* ============================================================
   BRANDS MARQUEE MODE
   Used by .brands-slider[data-mode="marquee"] — converts the
   paginated slider into a compact, continuous auto-scroll strip.
   The viewport stays the same; the track flips from grid to flex
   and is animated by CSS.
   ============================================================ */
.brands-slider[data-mode="marquee"],
.brands-slider--marquee {
  padding: 6px 0;
}
.brands-slider[data-mode="marquee"] .brands-viewport,
.brands-slider--marquee .brands-viewport {
  -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 6%, #000 94%, transparent 100%);
          mask-image: linear-gradient(90deg, transparent 0, #000 6%, #000 94%, transparent 100%);
}
.brands-track.is-marquee {
  display: flex;
  grid-auto-flow: initial;
  grid-auto-columns: initial;
  width: max-content;
  gap: 48px;
  align-items: center;
  animation: brandsMarquee var(--marquee-duration, 55s) linear infinite;
  transform: none !important; /* override any inline transform from JS */
}
.brands-track.is-marquee > * {
  flex: 0 0 auto;
}
.brands-track.is-marquee img {
  max-height: 34px;
  width: auto;
}
html[lang="ar"] .brands-track.is-marquee {
  animation-direction: reverse;
}
@keyframes brandsMarquee {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}
.brands-slider[data-mode="marquee"]:hover .brands-track.is-marquee,
.brands-slider--marquee:hover .brands-track.is-marquee {
  animation-play-state: paused;
}
@media (max-width: 760px) {
  .brands-track.is-marquee {
    gap: 32px;
    animation-duration: 38s;
  }
  .brands-track.is-marquee img { max-height: 26px; }
}
@media (max-width: 480px) {
  .brands-track.is-marquee {
    gap: 24px;
    animation-duration: 30s;
  }
  .brands-track.is-marquee img { max-height: 22px; }
}
@media (prefers-reduced-motion: reduce) {
  .brands-track.is-marquee {
    animation: none;
    transform: translateX(0) !important;
  }
}

/* Cards variant — used on the Work page "Brands we built" slider.
   Each item is a full service card, so we show fewer per page. */
.brands-slider--cards .brands-track {
  --brands-per-page: 4;
  gap: 22px;
  align-items: stretch;
}
.brands-slider--cards .brands-track > * {
  width: 100%;
  height: auto;
  align-self: stretch;
}
.brands-slider--cards .brands-track .service-card { margin: 0; }
@media (max-width: 1100px) {
  .brands-slider--cards .brands-track { --brands-per-page: 3; }
}
@media (max-width: 760px) {
  .brands-slider--cards .brands-track { --brands-per-page: 2; }
}
@media (max-width: 520px) {
  .brands-slider--cards .brands-track { --brands-per-page: 1; }
}


/* ============================================================
   GLOBAL BRANDS — single-line "ticker" treatment (v2 compact)
   Heading sits on the left as a quiet anchor label; logos stream
   past on the right as a slow, continuous, hover-pauseable marquee.
   Inline brand strip — minimal chrome, tiny logos, premium spacing.
   Used on Home + Work pages.
   ============================================================ */
.logos-section { padding: clamp(28px, 3.4vw, 48px) 0 !important; }
.brands-oneline-wrap { padding: clamp(20px, 3vw, 36px) 0; }

.brands-oneline {
  position: relative;
  display: flex;
  align-items: center;
  gap: clamp(14px, 2vw, 28px);
  padding: clamp(8px, 1vw, 14px) clamp(12px, 1.4vw, 20px);
  border-radius: 999px;
  border: 1px solid color-mix(in oklab, currentColor 8%, transparent);
  background: color-mix(in oklab, currentColor 2%, transparent);
  isolation: isolate;
}
[data-theme="dark"] .brands-oneline {
  border-color: color-mix(in oklab, #ffffff 7%, transparent);
  background: color-mix(in oklab, #ffffff 2.5%, transparent);
}
.brands-oneline::before {
  /* faint accent dot before the title */
  content: "";
  position: absolute;
  left: clamp(14px, 1.6vw, 22px); top: 50%;
  width: 5px; height: 5px;
  border-radius: 50%;
  background: linear-gradient(120deg, #FDD196, #E555C8, #54B3EC);
  transform: translate(-10px, -50%);
  box-shadow: 0 0 12px color-mix(in oklab, #E555C8 50%, transparent);
}
html[dir="rtl"] .brands-oneline::before {
  left: auto;
  right: clamp(14px, 1.6vw, 22px);
  transform: translate(10px, -50%);
}
.brands-oneline-title {
  flex: 0 0 auto;
  margin: 0;
  font-size: clamp(10.5px, 0.78vw, 12px);
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  white-space: nowrap;
  color: color-mix(in oklab, var(--ink, #0c0c0c) 62%, transparent);
}
[data-theme="dark"] .brands-oneline-title {
  color: color-mix(in oklab, #ffffff 60%, transparent);
}
.brands-oneline-title .arrow {
  display: inline-block;
  margin-inline-start: 6px;
  opacity: .5;
  transition: transform .25s, opacity .25s;
}
.brands-oneline:hover .brands-oneline-title .arrow {
  transform: translateX(3px);
  opacity: .85;
}
html[dir="rtl"] .brands-oneline-title .arrow { transform: scaleX(-1); }
html[dir="rtl"] .brands-oneline:hover .brands-oneline-title .arrow {
  transform: scaleX(-1) translateX(3px);
}

.brands-oneline-rail {
  position: relative;
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 5%, #000 95%, transparent 100%);
          mask-image: linear-gradient(90deg, transparent 0, #000 5%, #000 95%, transparent 100%);
}
.brands-oneline-track {
  display: flex;
  align-items: center;
  gap: clamp(22px, 2.6vw, 40px);
  width: max-content;
  animation: brandsOnelineScroll var(--brands-oneline-duration, 140s) linear infinite;
  will-change: transform;
}
.brands-oneline:hover .brands-oneline-track {
  animation-play-state: paused;
}
.brands-oneline-track img {
  flex: 0 0 auto;
  height: clamp(13px, 1.05vw, 17px);
  width: auto;
  max-width: none;
  object-fit: contain;
  filter: brightness(0) saturate(100%) invert(14%);
  opacity: .42;
  transition: filter .3s ease, opacity .3s ease, transform .3s ease;
}
[data-theme="dark"] .brands-oneline-track img {
  filter: brightness(0) saturate(100%) invert(86%);
  opacity: .42;
}
.brands-oneline-track img:hover {
  filter: none;
  opacity: 1;
  transform: scale(1.05);
}
html[dir="rtl"] .brands-oneline-track {
  animation-direction: reverse;
}
@keyframes brandsOnelineScroll {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

@media (max-width: 900px) {
  .logos-section { padding: clamp(20px, 4vw, 32px) 0 !important; }
  .brands-oneline {
    gap: 12px;
    padding: 8px 14px;
  }
  .brands-oneline-title { font-size: 10.5px; letter-spacing: 0.06em; }
  .brands-oneline-track {
    gap: 22px;
    animation-duration: 100s;
  }
  .brands-oneline-track img { height: 14px; }
}
@media (max-width: 640px) {
  /* phones: keep one tight line; title remains inline (no stacking) */
  .brands-oneline {
    flex-direction: row;
    align-items: center;
    gap: 10px;
    padding: 7px 12px;
  }
  .brands-oneline::before {
    top: 50%;
    transform: translate(-8px, -50%);
  }
  html[dir="rtl"] .brands-oneline::before {
    transform: translate(8px, -50%);
  }
  .brands-oneline-title {
    font-size: 9.5px;
    letter-spacing: 0.05em;
    white-space: nowrap;
  }
  /* hide the arrow on phones to save horizontal room */
  .brands-oneline-title .arrow { display: none; }
  .brands-oneline-rail { width: auto; min-width: 0; flex: 1 1 auto; }
  .brands-oneline-track {
    gap: 18px;
    animation-duration: 75s;
  }
  .brands-oneline-track img { height: 13px; }
}
@media (max-width: 380px) {
  /* very small phones: hide the title entirely, just the strip */
  .brands-oneline-title { display: none; }
  .brands-oneline::before { left: 12px; transform: translate(-6px, -50%); }
  html[dir="rtl"] .brands-oneline::before { right: 12px; transform: translate(6px, -50%); }
}
@media (prefers-reduced-motion: reduce) {
  .brands-oneline-track {
    animation: none;
    transform: translateX(0);
  }
}


/* ============================================================
   GLOBAL RESPONSIVE SAFETY NET — applied to all pages
   Prevents horizontal scroll, ensures touch targets, fluid images.
   Added: production hardening pass.
   ============================================================ */
html, body {
  max-width: 100%;
  overflow-x: hidden;
}
img, video, iframe, svg {
  max-width: 100%;
  height: auto;
}
.container, .wrap, section, header, footer, main, article {
  max-width: 100%;
}
*, *::before, *::after { box-sizing: border-box; }

/* Touch target safety on phones */
@media (max-width: 768px) {
  button, .btn, a.btn, a.nav-cta, .icon-btn {
    min-height: 44px;
  }
  /* Prevent any text from breaking layout */
  h1, h2, h3, h4, h5, h6, p, li, span {
    overflow-wrap: anywhere;
    word-break: break-word;
  }
  /* Prevent fixed widths from overflowing */
  table { display: block; overflow-x: auto; }
}

/* iPad portrait safety */
@media (min-width: 769px) and (max-width: 1024px) {
  .container { padding-left: 24px; padding-right: 24px; }
}

/* Print: clean layout */
@media print {
  .topbar, .foot-controls, .m-theme-fab, .whatsapp, .mobile-nav { display: none !important; }
  body { background: #fff !important; color: #000 !important; }
}
