/* ============================================================
   MS MARKETING SOLUTIONS — Design System (Light brand theme)
   Palette: Teal #0097B2 · Cyan #00E5FF · Sand #EBE9DB · White
   ============================================================ */

/* ---------- Tokens ---------- */
:root {
  --teal: #0097B2;
  --teal-deep: #007D94;
  --teal-soft: #E1F4F7;
  --teal-ghost: rgba(0, 151, 178, 0.08);
  --cyan: #00E5FF;
  --teal-bright: #00E5FF;
  --gold: #0097B2;        /* legacy alias — accent on light */
  --gold-light: #00E5FF;  /* legacy alias — accent on teal */
  --sand: #EBE9DB;
  --cream: #F9F8F3;
  --white: #FFFFFF;
  --ink: #093843;
  --ink-soft: rgba(9, 56, 67, 0.72);
  --white-soft: rgba(255, 255, 255, 0.96);
  --white-dim: rgba(255, 255, 255, 0.85);
  --line-light: rgba(9, 56, 67, 0.12);
  --line-dark: rgba(255, 255, 255, 0.28);

  --font-display: 'Playfair Display', 'Amiri', serif;
  --font-body: 'Manrope', 'Tajawal', sans-serif;

  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-luxe: cubic-bezier(0.65, 0, 0.15, 1);
  --dur: 0.9s;

  --container: min(1240px, 92vw);
  --radius: 18px;
  --header-h: 84px;
}

html[lang="ar"] {
  --font-display: 'Amiri', serif;
  --font-body: 'Tajawal', sans-serif;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font-body);
  background: var(--cream);
  color: var(--ink);
  line-height: 1.6;
  overflow-x: hidden;
  min-height: 100vh;
}
img, video, svg, canvas { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }
button, input, select, textarea { font: inherit; color: inherit; }
::selection { background: var(--cyan); color: var(--ink); }

/* Arabic: no letterspacing, slightly larger leading */
html[lang="ar"] body { line-height: 1.85; }
html[lang="ar"] .eyebrow,
html[lang="ar"] .btn,
html[lang="ar"] .nav__link,
html[lang="ar"] .marquee__track span { letter-spacing: 0 !important; }

/* ---------- Typography ---------- */
.h-display {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.08;
  letter-spacing: -0.01em;
}
html[lang="ar"] .h-display { line-height: 1.35; letter-spacing: 0; font-weight: 700; }

.h-hero  { font-size: clamp(2.7rem, 6vw, 5.4rem); }
.h-xl    { font-size: clamp(2.3rem, 5vw, 4.2rem); }
.h-lg    { font-size: clamp(1.9rem, 3.6vw, 3rem); }
.h-md    { font-size: clamp(1.4rem, 2.4vw, 1.9rem); }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--teal);
}
html[lang="ar"] .eyebrow { font-size: 0.95rem; }
.eyebrow::before {
  content: "";
  width: 38px;
  height: 1px;
  background: var(--teal);
}
.lead { font-size: clamp(1.05rem, 1.6vw, 1.25rem); color: var(--ink-soft); max-width: 58ch; }

/* ---------- Layout ---------- */
.container { width: var(--container); margin-inline: auto; }
.section { padding-block: clamp(90px, 12vw, 160px); position: relative; }
.section--tight { padding-block: clamp(60px, 8vw, 100px); }
.section--cream { background: var(--cream); }
.section--sand { background: var(--sand); }

/* Brand bands: the former dark sections are now solid brand teal,
   like the profile cover — white type, cyan accents. */
.section--dark { background: var(--teal); color: var(--white-soft); }
.section--deep { background: var(--teal-deep); color: var(--white-soft); }
.section--dark .lead, .section--deep .lead { color: var(--white-dim); }
.section--dark .eyebrow, .section--deep .eyebrow { color: #fff; }
.section--dark .eyebrow::before, .section--deep .eyebrow::before { background: var(--cyan); }

.section-head { max-width: 760px; margin-bottom: clamp(48px, 6vw, 84px); }
.section-head .h-display { margin-top: 18px; }
.section-head--center { margin-inline: auto; text-align: center; }
.section-head--center .eyebrow::before { display: none; }

.split {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: clamp(40px, 6vw, 96px);
  align-items: center;
}
.split--rev > *:first-child { order: 2; }
.split--rev > *:last-child { order: 1; }
@media (max-width: 860px) {
  .split { grid-template-columns: 1fr; }
  .split--rev > *:first-child { order: 0; }
  .split--rev > *:last-child { order: 0; }
}

/* ---------- Buttons ---------- */
.btn {
  --btn-bg: var(--teal);
  --btn-fg: #fff;
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 17px 34px;
  border-radius: 100px;
  background: var(--btn-bg);
  color: var(--btn-fg);
  font-weight: 700;
  font-size: 0.95rem;
  letter-spacing: 0.04em;
  border: 1px solid transparent;
  cursor: pointer;
  overflow: hidden;
  transition: transform 0.45s var(--ease-out), box-shadow 0.45s var(--ease-out),
    background 0.45s, color 0.45s, border-color 0.45s;
}
.btn .btn__arrow { transition: transform 0.45s var(--ease-out); }
[dir="rtl"] .btn .btn__arrow { transform: scaleX(-1); }
.btn:hover { transform: translateY(-3px); box-shadow: 0 18px 40px -14px rgba(0, 151, 178, 0.55); }
.btn:hover .btn__arrow { transform: translateX(5px); }
[dir="rtl"] .btn:hover .btn__arrow { transform: scaleX(-1) translateX(5px); }
.btn--gold { --btn-bg: var(--cyan); --btn-fg: var(--ink); }
.btn--gold:hover { box-shadow: 0 18px 40px -14px rgba(0, 229, 255, 0.5); }
.btn--ghost {
  --btn-bg: transparent;
  --btn-fg: currentColor;
  border-color: currentColor;
}
.btn--ghost:hover { background: var(--teal); border-color: var(--teal); color: #fff; box-shadow: none; }

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  color: var(--teal);
  border-bottom: 1px solid transparent;
  transition: gap 0.35s var(--ease-out), color 0.3s;
}
.link-arrow:hover { gap: 16px; color: var(--teal-deep); }
[dir="rtl"] .link-arrow svg { transform: scaleX(-1); }

/* ---------- Preloader ---------- */
.preloader {
  position: fixed;
  inset: 0;
  z-index: 2000;
  background: var(--teal);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.7s var(--ease-luxe), visibility 0.7s;
}
.preloader.is-done { opacity: 0; visibility: hidden; }
.preloader__mark {
  font-family: 'Playfair Display', serif;
  font-size: clamp(3.4rem, 9vw, 6rem);
  color: #fff;
  position: relative;
  animation: preloader-pulse 1.6s var(--ease-luxe) infinite alternate;
}
.preloader__mark::after {
  content: "";
  position: absolute;
  inset-inline: 8%;
  bottom: -14px;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--cyan), transparent);
  animation: preloader-line 1.6s var(--ease-luxe) infinite;
}
@keyframes preloader-pulse { from { opacity: 0.55; } to { opacity: 1; } }
@keyframes preloader-line { 0% { transform: scaleX(0); } 55% { transform: scaleX(1); } 100% { transform: scaleX(0); } }

/* Page transition veil */
.page-enter {
  position: fixed;
  inset: 0;
  z-index: 1900;
  background: var(--teal);
  transform-origin: top;
  animation: page-in 0.9s var(--ease-luxe) 0.05s forwards;
  pointer-events: none;
}
@keyframes page-in { to { transform: scaleY(0); } }
/* (exit veil is .pt-veil, built by main.js — styles in mark8.css) */

/* ---------- Header (light) ---------- */
.header {
  position: fixed;
  inset-inline: 0;
  top: 0;
  z-index: 1000;
  height: var(--header-h);
  display: flex;
  align-items: center;
  transition: transform 0.55s var(--ease-out), background 0.45s, box-shadow 0.45s, height 0.45s;
}
.header.is-hidden { transform: translateY(-110%); }
.header.is-solid {
  background: rgba(249, 248, 243, 0.86);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  box-shadow: 0 10px 40px -18px rgba(9, 56, 67, 0.25);
  height: 70px;
}
.header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.logo { display: flex; align-items: center; gap: 12px; line-height: 1; color: var(--ink); z-index: 1101; transition: color 0.4s; }
.logo__img { height: 64px; width: auto; filter: brightness(0); transition: filter 0.4s; }
/* transparent lockup (white): dark on light grounds, white on dark grounds */
.footer .logo__img,
.header.is-open .logo__img,
.page-home .header:not(.is-solid):not(.is-open) .logo__img { filter: none; }
.logo__text { display: none; }   /* hidden: the logo image is the full lockup */
.logo__mark {
  font-family: 'Playfair Display', serif;
  font-weight: 600;
  font-size: 2rem;
  letter-spacing: 0.02em;
}
.logo__word {
  font-family: 'Manrope', sans-serif;
  font-size: 0.55rem;
  font-weight: 700;
  letter-spacing: 0.42em;
  text-transform: uppercase;
  color: var(--teal);
  margin-top: 5px;
  transition: color 0.4s;
}
.header.is-open .logo, .header.is-open .logo .logo__word { color: #fff; }

.nav { display: flex; align-items: center; gap: clamp(20px, 3vw, 40px); }
.nav__link {
  position: relative;
  font-size: 0.92rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--ink-soft);
  padding-block: 6px;
  transition: color 0.3s;
}
html[lang="ar"] .nav__link { font-size: 1.02rem; }
.nav__link::after {
  content: "";
  position: absolute;
  inset-inline-start: 0;
  bottom: 0;
  width: 100%;
  height: 2px;
  background: var(--cyan);
  transform: scaleX(0);
  transform-origin: inline-start;
  transition: transform 0.4s var(--ease-out);
}
.nav__link:hover { color: var(--ink); }
.nav__link:hover::after, .nav__link.is-active::after { transform: scaleX(1); }
.nav__link.is-active { color: var(--teal); }

.header__actions { display: flex; align-items: center; gap: 16px; }
.lang-switch {
  position: relative;
  z-index: 1101;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border: 1px solid var(--line-light);
  border-radius: 100px;
  color: var(--ink);
  font-weight: 700;
  font-size: 0.85rem;
  transition: background 0.35s, border-color 0.35s, color 0.35s, transform 0.35s;
}
.lang-switch:hover { background: var(--cyan); border-color: var(--cyan); color: var(--ink); transform: translateY(-2px); }
.header.is-open .lang-switch { color: #fff; border-color: var(--line-dark); }
.header.is-open .lang-switch:hover { color: var(--ink); }
.header .btn { padding: 13px 26px; font-size: 0.85rem; }
@media (max-width: 1080px) { .header .btn { display: none; } }

/* Burger + mobile nav */
.burger {
  display: none;
  z-index: 1101;
  width: 46px;
  height: 46px;
  border: 1px solid var(--line-light);
  border-radius: 50%;
  background: transparent;
  cursor: pointer;
  position: relative;
}
.burger span {
  position: absolute;
  inset-inline: 13px;
  height: 2px;
  background: var(--ink);
  transition: transform 0.4s var(--ease-out), opacity 0.3s, background 0.3s;
}
.burger span:nth-child(1) { top: 16px; }
.burger span:nth-child(2) { top: 22px; }
.burger span:nth-child(3) { top: 28px; }
.header.is-open .burger { border-color: var(--line-dark); }
.header.is-open .burger span { background: #fff; }
.header.is-open .burger span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.header.is-open .burger span:nth-child(2) { opacity: 0; }
.header.is-open .burger span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

@media (max-width: 860px) {
  .burger { display: block; }
  .nav {
    position: fixed;
    inset: 0;
    z-index: 1100;
    flex-direction: column;
    justify-content: center;
    gap: 10px;
    background: linear-gradient(160deg, var(--teal) 0%, var(--teal-deep) 100%);
    clip-path: circle(0% at calc(100% - 60px) 42px);
    transition: clip-path 0.75s var(--ease-luxe);
    visibility: hidden;
  }
  [dir="rtl"] .nav { clip-path: circle(0% at 60px 42px); }
  .header.is-open .nav { clip-path: circle(140% at 50% 50%); visibility: visible; }
  .nav__link {
    font-family: var(--font-display);
    font-size: clamp(2rem, 8vw, 2.8rem);
    color: #fff !important;
    opacity: 0;
    transform: translateY(26px);
    transition: opacity 0.5s var(--ease-out), transform 0.5s var(--ease-out);
  }
  .header.is-open .nav__link { opacity: 1; transform: none; }
  .header.is-open .nav__link:nth-child(1) { transition-delay: 0.22s; }
  .header.is-open .nav__link:nth-child(2) { transition-delay: 0.3s; }
  .header.is-open .nav__link:nth-child(3) { transition-delay: 0.38s; }
  .header.is-open .nav__link:nth-child(4) { transition-delay: 0.46s; }
  .header.is-open .nav__link:nth-child(5) { transition-delay: 0.54s; }
}

/* ---------- Hero (light, code-driven 3D) ---------- */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: center;
  background:
    radial-gradient(1000px 620px at 82% 18%, rgba(0, 229, 255, 0.12), transparent 62%),
    radial-gradient(820px 520px at 8% 88%, rgba(0, 151, 178, 0.1), transparent 60%),
    linear-gradient(180deg, var(--white) 0%, var(--cream) 100%);
  color: var(--ink);
  overflow: hidden;
}
[dir="rtl"] .hero {
  background:
    radial-gradient(1000px 620px at 18% 18%, rgba(0, 229, 255, 0.12), transparent 62%),
    radial-gradient(820px 520px at 92% 88%, rgba(0, 151, 178, 0.1), transparent 60%),
    linear-gradient(180deg, var(--white) 0%, var(--cream) 100%);
}
.hero__media { position: absolute; inset: 0; pointer-events: none; }
.hero__media canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero__media::after {
  content: "";
  position: absolute;
  inset-inline: 0;
  bottom: 0;
  height: 30%;
  background: linear-gradient(to top, var(--cream), transparent);
}
.hero__content {
  position: relative;
  z-index: 2;
  width: var(--container);
  margin-inline: auto;
  padding-block: calc(var(--header-h) + 40px) 120px;
}
.hero__grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  align-items: center;
  gap: clamp(30px, 5vw, 80px);
}
@media (max-width: 980px) {
  .hero__grid { grid-template-columns: 1fr; }
  .hero__visual { order: -1; margin-top: -10px; }
}
.hero__title { margin-block: 26px 30px; max-width: 15ch; }
.hero__title em {
  font-style: italic;
  color: var(--teal);
}
html[lang="ar"] .hero__title em { font-style: normal; color: var(--teal); }
.hero__sub { max-width: 52ch; color: var(--ink-soft); font-size: clamp(1.02rem, 1.5vw, 1.2rem); margin-bottom: 42px; }
.hero__cta { display: flex; flex-wrap: wrap; gap: 18px; }

.hero__scroll {
  position: absolute;
  bottom: 34px;
  inset-inline-start: 50%;
  transform: translateX(-50%);
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  color: var(--ink-soft);
  font-size: 0.72rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
}
[dir="rtl"] .hero__scroll { transform: translateX(50%); }
.hero__scroll::after {
  content: "";
  width: 1px;
  height: 52px;
  background: linear-gradient(var(--teal), transparent);
  animation: scroll-drip 2.2s var(--ease-luxe) infinite;
}
@keyframes scroll-drip {
  0% { transform: scaleY(0); transform-origin: top; }
  45% { transform: scaleY(1); transform-origin: top; }
  55% { transform: scaleY(1); transform-origin: bottom; }
  100% { transform: scaleY(0); transform-origin: bottom; }
}

/* ---------- 3D marketing carousel (built by ms3d.js) ---------- */
.hero__visual {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: clamp(320px, 40vw, 540px);
}
.ms3d {
  position: relative;
  perspective: 1200px;
  z-index: 2;
  --tile: clamp(180px, 19vw, 250px);
  --orbit-r: calc(var(--tile) * 1.06);
}
.ms3d__float { transform-style: preserve-3d; animation: ms3d-float 9s ease-in-out infinite; }
@keyframes ms3d-float {
  0%, 100% { transform: translateY(0) rotateY(-7deg); }
  50% { transform: translateY(-16px) rotateY(7deg); }
}
.ms3d__assembly {
  position: relative;
  width: var(--tile);
  aspect-ratio: 310 / 430;
  transform-style: preserve-3d;
  transform: rotateX(calc(var(--ry, -8) * 1deg)) rotateY(calc(var(--rx, 10) * 1deg));
  will-change: transform;
}
.ms3d__logo {
  position: absolute;
  inset: 0;
  transform-style: preserve-3d;
}
.ms3d__logo-layer {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  filter: drop-shadow(0 2px 2px rgba(0, 80, 95, 0.12));
}
.ms3d__logo-layer:first-child { filter: drop-shadow(0 30px 40px rgba(0, 125, 148, 0.35)); }
.ms3d__carousel {
  position: absolute;
  inset: 0;
  transform-style: preserve-3d;
  animation: carousel-spin 26s linear infinite;
}
@keyframes carousel-spin {
  from { transform: rotateY(0deg); }
  to { transform: rotateY(360deg); }
}
.ms3d__chip {
  position: absolute;
  top: 50%;
  left: 50%;
  width: clamp(52px, 6vw, 68px);
  height: clamp(52px, 6vw, 68px);
  margin: calc(clamp(52px, 6vw, 68px) / -2) 0 0 calc(clamp(52px, 6vw, 68px) / -2);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid rgba(0, 151, 178, 0.18);
  box-shadow: 0 14px 30px -14px rgba(0, 125, 148, 0.45);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--teal);
}
.ms3d__chip svg { width: 55%; height: 55%; }
.ms3d__shadow {
  position: absolute;
  inset-inline: 14%;
  bottom: -9%;
  height: 34px;
  background: radial-gradient(50% 100% at 50% 50%, rgba(9, 56, 67, 0.3), transparent 72%);
  filter: blur(7px);
  z-index: 1;
  animation: ms3d-shadow 7s ease-in-out infinite;
}
@keyframes ms3d-shadow {
  0%, 100% { transform: scaleX(1); opacity: 0.85; }
  50% { transform: scaleX(0.85); opacity: 0.5; }
}
/* orbit guide rings */
.ms3d-ring {
  position: absolute;
  inset: 0;
  margin: auto;
  width: clamp(320px, 38vw, 560px);
  aspect-ratio: 1;
  border: 1.5px solid rgba(0, 151, 178, 0.35);
  border-radius: 50%;
  transform: rotateX(70deg);
  z-index: 1;
  pointer-events: none;
}
.ms3d-ring--2 {
  width: clamp(390px, 48vw, 680px);
  border-color: rgba(0, 151, 178, 0.18);
  border-style: dashed;
  animation: ring-orbit 30s linear infinite;
}
@keyframes ring-orbit {
  from { transform: rotateX(70deg) rotate(0deg); }
  to { transform: rotateX(70deg) rotate(360deg); }
}
.ms3d-disc {
  position: absolute;
  width: clamp(230px, 28vw, 400px);
  aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, var(--sand) 30%, rgba(235, 233, 219, 0) 75%);
  z-index: 0;
  inset-inline-end: 2%;
  top: 0;
}
.ms3d-dot { display: none; }

/* Inner page hero (light, subtle 3D dots) */
.page-hero {
  position: relative;
  padding-block: calc(var(--header-h) + clamp(70px, 10vw, 130px)) clamp(70px, 9vw, 110px);
  background:
    radial-gradient(900px 460px at 88% 0%, rgba(0, 229, 255, 0.14), transparent 62%),
    radial-gradient(700px 400px at 4% 100%, rgba(0, 151, 178, 0.1), transparent 60%),
    linear-gradient(180deg, var(--white) 0%, var(--cream) 100%);
  color: var(--ink);
  overflow: hidden;
}
[dir="rtl"] .page-hero {
  background:
    radial-gradient(900px 460px at 12% 0%, rgba(0, 229, 255, 0.14), transparent 62%),
    radial-gradient(700px 400px at 96% 100%, rgba(0, 151, 178, 0.1), transparent 60%),
    linear-gradient(180deg, var(--white) 0%, var(--cream) 100%);
}
.page-hero canvas { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.page-hero .container { position: relative; z-index: 2; }
.page-hero .h-display { margin-top: 22px; max-width: 16ch; }
.page-hero__sub { margin-top: 24px; }
.page-hero__word {
  position: absolute;
  inset-inline-end: -2%;
  bottom: -6%;
  font-family: 'Playfair Display', serif;
  font-size: clamp(7rem, 22vw, 19rem);
  font-weight: 700;
  line-height: 1;
  color: transparent;
  -webkit-text-stroke: 1.5px rgba(0, 151, 178, 0.15);
  pointer-events: none;
  user-select: none;
  white-space: nowrap;
  z-index: 1;
}

/* ---------- Marquee ---------- */
.marquee {
  overflow: hidden;
  padding-block: clamp(26px, 4vw, 44px);
  border-block: 1px solid var(--line-light);
  background: var(--white);
  direction: ltr;
}
.marquee--dark { background: var(--teal); border-color: rgba(255, 255, 255, 0.2); }
.marquee__track {
  display: flex;
  gap: 60px;
  width: max-content;
  animation: marquee 30s linear infinite;
}
.marquee:hover .marquee__track { animation-play-state: paused; }
.marquee__track span {
  font-family: var(--font-display);
  font-size: clamp(1.6rem, 3.4vw, 2.8rem);
  white-space: nowrap;
  color: var(--ink);
  display: flex;
  align-items: center;
  gap: 60px;
}
.marquee--dark .marquee__track span { color: #fff; }
.marquee__track span i {
  font-style: normal;
  color: var(--teal);
  font-size: 0.6em;
}
.marquee--dark .marquee__track span i { color: var(--cyan); }
.marquee__track span em {
  font-style: italic;
  color: var(--teal);
}
.marquee--dark .marquee__track span em { color: var(--cyan); }
@keyframes marquee { to { transform: translateX(-50%); } }

/* Clients logo marquee */
.clients-strip {
  overflow: hidden;
  direction: ltr;
  padding-block: 10px;
  background: var(--cream); /* backdrop for mix-blend multiply inside the masked context */
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent);
}
.clients-track { display: flex; align-items: center; gap: clamp(48px, 7vw, 96px); width: max-content; animation: marquee 36s linear infinite; }
.clients-track img { height: 54px; width: auto; object-fit: contain; opacity: 0.8; filter: grayscale(1); mix-blend-mode: multiply; transition: opacity 0.4s, filter 0.4s, transform 0.4s; }
.clients-track img:hover { opacity: 1; filter: none; transform: scale(1.08); }
.clients-track .client-name {
  font-family: var(--font-display);
  font-size: 1.3rem;
  color: var(--ink-soft);
  white-space: nowrap;
  opacity: 0.8;
}

/* Logo wall (about) */
.logo-wall {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  border-top: 1px solid var(--line-light);
  border-inline-start: 1px solid var(--line-light);
}
.logo-wall > div {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(26px, 4vw, 46px);
  border-bottom: 1px solid var(--line-light);
  border-inline-end: 1px solid var(--line-light);
  transition: background 0.4s;
}
.logo-wall > div:hover { background: #fff; }
.logo-wall img { max-height: 64px; width: auto; object-fit: contain; filter: grayscale(1); opacity: 0.85; mix-blend-mode: multiply; transition: filter 0.4s, opacity 0.4s, transform 0.4s; }
.logo-wall > div:hover img { filter: none; opacity: 1; transform: scale(1.06); }
.logo-wall .client-name { font-family: var(--font-display); font-size: 1.15rem; color: var(--ink-soft); text-align: center; }

/* ---------- Media frames ---------- */
.media-frame {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius);
  isolation: isolate;
}
.media-frame img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.1s var(--ease-out); }
.media-frame:hover img { transform: scale(1.06); }
.media-frame--tall { aspect-ratio: 3 / 4; }
.media-frame--wide { aspect-ratio: 16 / 10; }
.media-frame--square { aspect-ratio: 1; }

/* Cyan corner ornament */
.ornament { position: relative; }
.ornament::before {
  content: "";
  position: absolute;
  inset-block-start: -18px;
  inset-inline-start: -18px;
  width: 100px;
  height: 100px;
  border-block-start: 2px solid var(--cyan);
  border-inline-start: 2px solid var(--cyan);
  border-start-start-radius: var(--radius);
  z-index: -1;
}

/* ---------- Stats ---------- */
.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: clamp(28px, 4vw, 56px);
  text-align: center;
}
.stat__num {
  font-family: 'Playfair Display', serif;
  font-size: clamp(3rem, 6.5vw, 5rem);
  font-weight: 600;
  color: #fff;
  line-height: 1;
  display: inline-flex;
  align-items: baseline;
}
.stat__num .plus { color: var(--cyan); font-size: 0.55em; margin-inline-start: 4px; }
.stat__label {
  margin-top: 14px;
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--white-dim);
}
html[lang="ar"] .stat__label { letter-spacing: 0; font-size: 1.05rem; }
.section--cream .stat__num, .section--sand .stat__num { color: var(--ink); }
.section--cream .stat__num .plus, .section--sand .stat__num .plus { color: var(--teal); }
.section--cream .stat__label, .section--sand .stat__label { color: var(--ink-soft); }

/* ---------- Service cards ---------- */
.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 26px;
}
@media (max-width: 1024px) { .services-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .services-grid { grid-template-columns: 1fr; } }
.service-card {
  position: relative;
  padding: clamp(30px, 3.4vw, 44px);
  border-radius: var(--radius);
  background: var(--white);
  border: 1px solid var(--line-light);
  overflow: hidden;
  transition: transform 0.55s var(--ease-out), box-shadow 0.55s var(--ease-out), border-color 0.4s;
}
.service-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(140deg, var(--teal) 0%, #00C2D8 130%);
  opacity: 0;
  transition: opacity 0.55s var(--ease-out);
}
.service-card:hover { transform: translateY(-10px); box-shadow: 0 30px 60px -24px rgba(0, 125, 148, 0.45); border-color: transparent; }
.service-card:hover::before { opacity: 1; }
.service-card > * { position: relative; }
.service-card__num {
  font-family: 'Playfair Display', serif;
  font-style: italic;
  font-size: 1rem;
  color: var(--teal);
  letter-spacing: 0.1em;
  transition: color 0.45s;
}
.service-card__icon { margin-block: 22px 20px; color: var(--teal); transition: color 0.45s, transform 0.55s var(--ease-out); }
.service-card:hover .service-card__icon { color: var(--cyan); transform: translateY(-4px) scale(1.08); }
.service-card:hover .service-card__num { color: var(--cyan); }
.service-card h3 { font-family: var(--font-display); font-size: 1.42rem; font-weight: 600; margin-bottom: 12px; transition: color 0.45s; }
.service-card p { color: var(--ink-soft); font-size: 0.97rem; transition: color 0.45s; }
.service-card:hover h3 { color: #fff; }
.service-card:hover p { color: var(--white-dim); }

/* Numbered service rows (services page) */
.service-row { padding-block: clamp(60px, 8vw, 110px); border-bottom: 1px solid var(--line-light); }
.service-row:last-of-type { border-bottom: 0; }
.service-row__num {
  font-family: 'Playfair Display', serif;
  font-style: italic;
  font-size: clamp(3.4rem, 7vw, 5.6rem);
  line-height: 1;
  color: transparent;
  -webkit-text-stroke: 1.5px var(--teal);
}
html[lang="ar"] .service-row__num { font-family: 'Amiri', serif; font-style: normal; }
.service-row h3 { margin-block: 18px 16px; }
.service-row ul { margin-top: 24px; display: grid; gap: 10px; }
.service-row ul li { display: flex; align-items: center; gap: 12px; color: var(--ink-soft); }
.service-row ul li::before { content: ""; width: 22px; height: 2px; background: var(--cyan); flex: none; }

/* Why-us cards */
.pillars { display: grid; grid-template-columns: repeat(2, 1fr); gap: 26px; }
@media (max-width: 860px) { .pillars { grid-template-columns: 1fr; } }
.pillar {
  padding: clamp(30px, 3.6vw, 48px);
  background: var(--white);
  border-radius: var(--radius);
  border: 1px solid var(--line-light);
  transition: transform 0.55s var(--ease-out), box-shadow 0.55s var(--ease-out);
}
.pillar:hover { transform: translateY(-8px); box-shadow: 0 26px 60px -28px rgba(0, 125, 148, 0.4); }
.pillar__num {
  font-family: 'Playfair Display', serif;
  font-style: italic;
  font-size: 2.2rem;
  color: var(--teal);
  line-height: 1;
}
html[lang="ar"] .pillar__num { font-family: 'Amiri', serif; font-style: normal; }
.pillar h3 { font-family: var(--font-display); font-size: 1.4rem; margin-block: 16px 12px; }
.pillar p { color: var(--ink-soft); }

/* ---------- Process timeline (teal band) ---------- */
.process {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 18px;
  counter-reset: step;
}
@media (max-width: 1024px) { .process { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .process { grid-template-columns: 1fr; } }
.process__step {
  position: relative;
  padding: 30px 24px;
  border: 1px solid var(--line-dark);
  border-radius: var(--radius);
  transition: background 0.45s, transform 0.55s var(--ease-out), border-color 0.45s;
}
.process__step:hover { background: rgba(255, 255, 255, 0.12); transform: translateY(-6px); border-color: var(--cyan); }
.process__step::before {
  counter-increment: step;
  content: "0" counter(step);
  font-family: 'Playfair Display', serif;
  font-style: italic;
  color: var(--cyan);
  font-size: 1.6rem;
}
.process__step h3 { font-family: var(--font-display); font-size: 1.2rem; margin-block: 14px 8px; color: #fff; }
.process__step p { font-size: 0.9rem; color: var(--white-dim); }

/* ---------- Work grid ---------- */
.filter-bar { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: clamp(36px, 5vw, 60px); }
.filter-btn {
  padding: 12px 26px;
  border-radius: 100px;
  border: 1px solid var(--line-light);
  background: transparent;
  font-weight: 700;
  font-size: 0.9rem;
  cursor: pointer;
  color: var(--ink-soft);
  transition: all 0.35s var(--ease-out);
}
.filter-btn:hover { border-color: var(--teal); color: var(--teal); transform: translateY(-2px); }
.filter-btn.is-active { background: var(--teal); border-color: var(--teal); color: #fff; }

.work-grid { columns: 3 300px; column-gap: 24px; }
.work-item {
  position: relative;
  margin-bottom: 24px;
  break-inside: avoid;
  border-radius: var(--radius);
  overflow: hidden;
  cursor: zoom-in;
  transform: translateZ(0);
}
.work-item img { width: 100%; transition: transform 1s var(--ease-out); }
.work-item::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 125, 148, 0.8), transparent 55%);
  opacity: 0;
  transition: opacity 0.5s;
}
.work-item:hover::after { opacity: 1; }
.work-item:hover img { transform: scale(1.07); }
.work-item__tag {
  position: absolute;
  inset-inline-start: 18px;
  bottom: 16px;
  z-index: 2;
  color: #fff;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.45s, transform 0.45s var(--ease-out);
}
html[lang="ar"] .work-item__tag { letter-spacing: 0; font-size: 0.95rem; }
.work-item:hover .work-item__tag { opacity: 1; transform: none; }
.work-item.is-filtered { display: none; }

/* Home featured strip */
.featured-grid { display: grid; grid-template-columns: repeat(12, 1fr); gap: 24px; }
.featured-grid .media-frame:nth-child(1) { grid-column: span 7; aspect-ratio: 16/10; }
.featured-grid .media-frame:nth-child(2) { grid-column: span 5; aspect-ratio: 4/5; }
.featured-grid .media-frame:nth-child(3) { grid-column: span 5; aspect-ratio: 4/5; }
.featured-grid .media-frame:nth-child(4) { grid-column: span 7; aspect-ratio: 16/10; }
@media (max-width: 860px) { .featured-grid .media-frame { grid-column: 1 / -1 !important; aspect-ratio: 16/11 !important; } }
.featured-grid .media-frame figcaption {
  position: absolute;
  inset-inline-start: 22px;
  bottom: 20px;
  z-index: 2;
  color: #fff;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-size: 0.8rem;
  text-shadow: 0 2px 14px rgba(0, 60, 72, 0.7);
}
html[lang="ar"] .featured-grid .media-frame figcaption { letter-spacing: 0; font-size: 1rem; }
.featured-grid .media-frame::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 125, 148, 0.55), transparent 45%);
}

/* ---------- Lightbox ---------- */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 1800;
  background: rgba(0, 74, 88, 0.94);
  backdrop-filter: blur(10px);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.45s, visibility 0.45s;
}
.lightbox.is-open { opacity: 1; visibility: visible; }
.lightbox img {
  max-width: min(1100px, 90vw);
  max-height: 86vh;
  border-radius: 12px;
  box-shadow: 0 40px 120px -30px rgba(0, 30, 36, 0.8);
  transform: scale(0.92);
  transition: transform 0.5s var(--ease-out);
}
.lightbox.is-open img { transform: scale(1); }
.lightbox__close {
  position: absolute;
  top: 26px;
  inset-inline-end: 26px;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  border: 1px solid var(--line-dark);
  background: transparent;
  color: #fff;
  font-size: 1.4rem;
  cursor: pointer;
  transition: background 0.35s, transform 0.35s, color 0.35s;
}
.lightbox__close:hover { background: var(--cyan); color: var(--ink); transform: rotate(90deg); }
.lightbox__nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 56px;
  height: 56px;
  border-radius: 50%;
  border: 1px solid var(--line-dark);
  background: rgba(255, 255, 255, 0.06);
  color: #fff;
  font-size: 1.3rem;
  cursor: pointer;
  transition: background 0.35s;
  z-index: 2;
}
.lightbox__nav:hover { background: var(--teal); }
.lightbox__prev { inset-inline-start: 26px; }
.lightbox__next { inset-inline-end: 26px; }
@media (max-width: 640px) { .lightbox__nav { display: none; } }

/* ---------- Quote (teal band) ---------- */
.quote-mark {
  font-family: 'Playfair Display', serif;
  font-size: clamp(4rem, 8vw, 6.5rem);
  color: var(--cyan);
  line-height: 0.6;
  display: block;
  margin-bottom: 30px;
}
.quote-text {
  font-family: var(--font-display);
  font-size: clamp(1.7rem, 3.6vw, 3rem);
  font-weight: 500;
  line-height: 1.35;
  max-width: 26ch;
  margin-inline: auto;
}
html[lang="ar"] .quote-text { line-height: 1.7; }
.quote-text em { font-style: italic; color: var(--cyan); }
html[lang="ar"] .quote-text em { font-style: normal; }

/* ---------- CTA band (teal) ---------- */
.cta-band {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(1100px 520px at 18% 12%, rgba(0, 229, 255, 0.3), transparent 58%),
    radial-gradient(800px 420px at 88% 95%, rgba(255, 255, 255, 0.16), transparent 58%),
    linear-gradient(150deg, #00A9C6 0%, var(--teal) 45%, var(--teal-deep) 100%);
  color: #fff;
  text-align: center;
  padding-block: clamp(90px, 12vw, 150px);
}
.cta-band canvas { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.cta-band .container { position: relative; z-index: 2; }
.cta-band .eyebrow { color: #fff; }
.cta-band .eyebrow::before { background: var(--cyan); }
.cta-band .h-display { max-width: 18ch; margin-inline: auto; }
.cta-band .h-display em { font-style: italic; color: var(--cyan); }
html[lang="ar"] .cta-band .h-display em { font-style: normal; }
.cta-band .btn { margin-top: 44px; }
.cta-band__ring {
  position: absolute;
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  pointer-events: none;
  animation: ring-spin 26s linear infinite;
}
.cta-band__ring--1 { width: 420px; height: 420px; top: -180px; inset-inline-start: -120px; }
.cta-band__ring--2 { width: 620px; height: 620px; bottom: -300px; inset-inline-end: -180px; border-style: dashed; border-color: rgba(0, 229, 255, 0.4); animation-duration: 40s; }
@keyframes ring-spin { to { transform: rotate(360deg); } }

/* ---------- Contact ---------- */
.contact-layout { display: grid; grid-template-columns: 1fr 1.15fr; gap: clamp(48px, 7vw, 110px); align-items: start; }
@media (max-width: 960px) { .contact-layout { grid-template-columns: 1fr; } }
.contact-info__item { display: flex; gap: 20px; padding-block: 26px; border-bottom: 1px solid var(--line-light); }
.contact-info__item svg { flex: none; color: var(--teal); margin-top: 4px; }
.contact-info__item h3 { font-family: var(--font-display); font-size: 1.15rem; margin-bottom: 6px; }
.contact-info__item p, .contact-info__item a { color: var(--ink-soft); }
.contact-info__item a:hover { color: var(--teal); }

.form { display: grid; gap: 22px; }
.form__row { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
@media (max-width: 640px) { .form__row { grid-template-columns: 1fr; } }
.field { position: relative; }
.field label {
  display: block;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-bottom: 10px;
}
html[lang="ar"] .field label { letter-spacing: 0; font-size: 0.95rem; }
.field input, .field select, .field textarea {
  width: 100%;
  padding: 16px 20px;
  background: var(--white);
  border: 1px solid var(--line-light);
  border-radius: 12px;
  outline: none;
  transition: border-color 0.35s, box-shadow 0.35s;
}
.field input:focus, .field select:focus, .field textarea:focus {
  border-color: var(--teal);
  box-shadow: 0 0 0 4px var(--teal-ghost);
}
.field textarea { min-height: 150px; resize: vertical; }
.form__note { font-size: 0.85rem; color: var(--ink-soft); }

/* Accordion */
.accordion { border-top: 1px solid var(--line-light); }
.accordion__item { border-bottom: 1px solid var(--line-light); }
.accordion__head {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding-block: 26px;
  background: none;
  border: 0;
  cursor: pointer;
  text-align: start;
  font-family: var(--font-display);
  font-size: clamp(1.1rem, 1.8vw, 1.4rem);
  font-weight: 600;
  color: var(--ink);
  transition: color 0.3s;
}
.accordion__head:hover { color: var(--teal); }
.accordion__icon { flex: none; width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--line-light); position: relative; transition: transform 0.45s var(--ease-out), background 0.35s, border-color 0.35s; }
.accordion__icon::before, .accordion__icon::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 12px;
  height: 1.5px;
  background: currentColor;
  transform: translate(-50%, -50%);
}
.accordion__icon::after { transform: translate(-50%, -50%) rotate(90deg); transition: transform 0.45s var(--ease-out); }
.accordion__item.is-open .accordion__icon { background: var(--teal); border-color: var(--teal); transform: rotate(180deg); color: #fff; }
.accordion__item.is-open .accordion__icon::after { transform: translate(-50%, -50%) rotate(0deg); }
.accordion__body { max-height: 0; overflow: hidden; transition: max-height 0.6s var(--ease-luxe); }
.accordion__body p { padding-block: 0 28px; color: var(--ink-soft); max-width: 65ch; }

/* ---------- Footer (brand teal, like the profile cover) ---------- */
.footer {
  position: relative;
  background: linear-gradient(165deg, var(--teal-deep) 0%, #006B80 100%);
  color: var(--white-dim);
  padding-block: clamp(70px, 9vw, 110px) 0;
  overflow: hidden;
}
.footer__grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.1fr;
  gap: clamp(36px, 5vw, 70px);
  padding-bottom: clamp(50px, 7vw, 80px);
  position: relative;
  z-index: 1;
}
@media (max-width: 1024px) { .footer__grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .footer__grid { grid-template-columns: 1fr; } }
.footer .logo { margin-bottom: 22px; color: #fff; }
.footer .logo__word { color: var(--cyan); }
.footer__tagline { max-width: 34ch; font-size: 0.95rem; }
.footer h4 {
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--cyan);
  margin-bottom: 22px;
}
html[lang="ar"] .footer h4 { letter-spacing: 0; font-size: 1rem; }
.footer li { margin-bottom: 12px; }
.footer a { transition: color 0.3s, padding 0.3s; }
.footer a:hover { color: #fff; padding-inline-start: 6px; }
.footer__bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding-block: 28px;
  border-top: 1px solid rgba(255, 255, 255, 0.22);
  font-size: 0.85rem;
  position: relative;
  z-index: 1;
}
.footer__watermark {
  position: absolute;
  inset-inline-end: -1%;
  bottom: -18%;
  font-family: 'Playfair Display', serif;
  font-weight: 700;
  font-size: clamp(10rem, 24vw, 20rem);
  line-height: 1;
  color: transparent;
  -webkit-text-stroke: 1.5px rgba(255, 255, 255, 0.12);
  pointer-events: none;
  user-select: none;
  z-index: 0;
}

/* ---------- Reveal animations ---------- */
[data-reveal] { opacity: 0; transform: translateY(44px); transition: opacity var(--dur) var(--ease-out), transform var(--dur) var(--ease-out); will-change: opacity, transform; }
[data-reveal].is-visible { opacity: 1; transform: none; will-change: auto; }
[data-reveal-delay="1"] { transition-delay: 0.09s; }
[data-reveal-delay="2"] { transition-delay: 0.18s; }
[data-reveal-delay="3"] { transition-delay: 0.27s; }
[data-reveal-delay="4"] { transition-delay: 0.36s; }
[data-reveal-delay="5"] { transition-delay: 0.45s; }
[data-reveal-delay="6"] { transition-delay: 0.54s; }

[data-reveal="clip"] { transform: none; clip-path: inset(0 0 100% 0); transition: clip-path 1.2s var(--ease-luxe), opacity 0.6s; }
[data-reveal="clip"].is-visible { clip-path: inset(0 0 0 0); }

[data-reveal="lines"] { opacity: 1; transform: none; }
[data-reveal="lines"] .line { display: block; overflow: hidden; padding-block: 0.24em; margin-block: -0.24em; padding-inline: 0.1em; margin-inline: -0.1em; }
[data-reveal="lines"] .line > span { display: block; transform: translateY(130%); transition: transform 1s var(--ease-luxe); }
[data-reveal="lines"].is-visible .line > span { transform: none; }
/* Arabic: Amiri's diacritics & swashes overflow any mask — use an
   unclipped fade-rise instead so letter edges are never cut */
html[lang="ar"] [data-reveal="lines"] .line { overflow: visible; padding-block: 0.3em; margin-block: -0.3em; }
html[lang="ar"] [data-reveal="lines"] .line > span { transform: translateY(55%); opacity: 0; transition: transform 1s var(--ease-luxe), opacity 0.8s ease; }
html[lang="ar"] [data-reveal="lines"].is-visible .line > span { transform: none; opacity: 1; }
[data-reveal="lines"].is-visible .line:nth-child(2) > span { transition-delay: 0.12s; }
[data-reveal="lines"].is-visible .line:nth-child(3) > span { transition-delay: 0.24s; }
[data-reveal="lines"].is-visible .line:nth-child(4) > span { transition-delay: 0.36s; }

/* ---------- Custom cursor ---------- */
.cursor-dot, .cursor-ring { position: fixed; top: 0; left: 0; z-index: 3000; pointer-events: none; border-radius: 50%; }
.cursor-dot { width: 8px; height: 8px; background: var(--teal); transform: translate(-50%, -50%); }
.cursor-ring {
  width: 42px;
  height: 42px;
  border: 1.5px solid rgba(0, 151, 178, 0.55);
  transform: translate(-50%, -50%);
  transition: width 0.3s, height 0.3s, background 0.3s, border-color 0.3s;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0;
}
.cursor-ring.is-active { width: 76px; height: 76px; background: rgba(0, 229, 255, 0.14); }
.cursor-ring.is-view { width: 86px; height: 86px; background: var(--cyan); border-color: var(--cyan); font-size: 0.7rem; font-weight: 800; letter-spacing: 0.12em; color: var(--ink); }
@media (hover: none), (max-width: 860px) { .cursor-dot, .cursor-ring { display: none !important; } }

/* ---------- Utilities ---------- */
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(30px, 4vw, 60px); }
@media (max-width: 860px) { .grid-2 { grid-template-columns: 1fr; } }
.mt-lg { margin-top: clamp(40px, 6vw, 70px); }
.text-center { text-align: center; }
.gold { color: var(--teal); }
.section--dark .gold, .section--deep .gold, .cta-band .gold { color: var(--cyan); }

/* Arabic display accents never italicize */
html[lang="ar"] .page-hero .h-display em { font-style: normal; }

/* Scrollbar */
::-webkit-scrollbar { width: 11px; }
::-webkit-scrollbar-track { background: var(--sand); }
::-webkit-scrollbar-thumb { background: var(--teal); border-radius: 10px; border: 2px solid var(--sand); }
::-webkit-scrollbar-thumb:hover { background: var(--teal-deep); }

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  html:not([data-motion="force"]) *,
  html:not([data-motion="force"]) *::before,
  html:not([data-motion="force"]) *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  html:not([data-motion="force"]) { scroll-behavior: auto; }
  html:not([data-motion="force"]) [data-reveal] { opacity: 1 !important; transform: none !important; clip-path: none !important; }
  html:not([data-motion="force"]) [data-reveal="lines"] .line > span { transform: none !important; opacity: 1 !important; }
  html:not([data-motion="force"]) .marquee__track,
  html:not([data-motion="force"]) .clients-track { animation: none !important; }
}

/* ============================================================
   DARK MODE — token remap + component tuning
   Toggled via html[data-theme="dark"] (crescent button in header)
   ============================================================ */
html[data-theme="dark"] {
  color-scheme: dark;
  --cream: #071e26;          /* page background — deep brand ink */
  --white: #0c2c37;          /* cards / panels */
  --sand: #0a2530;           /* alternate band */
  --ink: #eef7f8;            /* headings / body text */
  --ink-soft: rgba(238, 247, 248, 0.72);
  --teal-soft: #0d3743;
  --teal-ghost: rgba(0, 229, 255, 0.1);
  --line-light: rgba(255, 255, 255, 0.14);
}

/* smooth cross-fade while switching (class lives ~0.5s) */
html.theme-switching *,
html.theme-switching *::before,
html.theme-switching *::after {
  transition: background-color 0.45s var(--ease-out), background 0.45s var(--ease-out),
    color 0.45s var(--ease-out), border-color 0.45s var(--ease-out),
    box-shadow 0.45s var(--ease-out) !important;
}

/* accents lift from teal to cyan for contrast on dark */
html[data-theme="dark"] .gold,
html[data-theme="dark"] .hero__title em,
html[data-theme="dark"] .eyebrow,
html[data-theme="dark"] .nav__link.is-active,
html[data-theme="dark"] .link-arrow { color: var(--cyan); }
html[data-theme="dark"] .eyebrow::before { background: var(--cyan); }
html[data-theme="dark"] .link-arrow:hover { color: #7df0ff; }

/* header */
html[data-theme="dark"] .header.is-solid {
  background: rgba(7, 30, 38, 0.88);
  box-shadow: 0 10px 40px -18px rgba(0, 0, 0, 0.6);
}
html[data-theme="dark"] .logo { color: var(--ink); }
html[data-theme="dark"] .burger span { background: var(--ink); }

/* hero + page hero backgrounds */
html[data-theme="dark"] .hero,
html[dir="rtl"][data-theme="dark"] .hero {
  background:
    radial-gradient(1000px 620px at 82% 18%, rgba(0, 229, 255, 0.09), transparent 62%),
    radial-gradient(820px 520px at 8% 88%, rgba(0, 151, 178, 0.14), transparent 60%),
    linear-gradient(180deg, #0a2833 0%, var(--cream) 100%);
}
html[data-theme="dark"] .page-hero,
html[dir="rtl"][data-theme="dark"] .page-hero {
  background:
    radial-gradient(900px 460px at 88% 0%, rgba(0, 229, 255, 0.1), transparent 62%),
    radial-gradient(700px 400px at 4% 100%, rgba(0, 151, 178, 0.12), transparent 60%),
    linear-gradient(180deg, #0a2833 0%, var(--cream) 100%);
}
html[data-theme="dark"] .page-hero__word { -webkit-text-stroke-color: rgba(0, 229, 255, 0.14); }
html[data-theme="dark"] .ms3d__chip {
  background: rgba(12, 44, 55, 0.94);
  border-color: rgba(0, 229, 255, 0.22);
  color: var(--cyan);
}
html[data-theme="dark"] .ms3d-disc {
  background: radial-gradient(circle at 35% 30%, #0d3743 30%, rgba(13, 55, 67, 0) 75%);
}

/* client logos: invert + screen so they read on dark */
html[data-theme="dark"] .clients-track img,
html[data-theme="dark"] .logo-wall img {
  filter: grayscale(1) invert(1) contrast(1.25) brightness(1.75);
  mix-blend-mode: screen;
  opacity: 0.85;
}
html[data-theme="dark"] .clients-track img:hover,
html[data-theme="dark"] .logo-wall > div:hover img {
  filter: invert(1) brightness(1.9);
  opacity: 1;
}
html[data-theme="dark"] .logo-wall > div:hover { background: rgba(255, 255, 255, 0.05); }

/* misc panels */
html[data-theme="dark"] .service-card:hover { box-shadow: 0 30px 60px -24px rgba(0, 0, 0, 0.65); }
html[data-theme="dark"] .pillar:hover { box-shadow: 0 26px 60px -28px rgba(0, 0, 0, 0.6); }
html[data-theme="dark"] .field input:focus,
html[data-theme="dark"] .field select:focus,
html[data-theme="dark"] .field textarea:focus { box-shadow: 0 0 0 4px rgba(0, 229, 255, 0.12); }

/* keep the feed's floating notification cards white in both themes */
html[data-theme="dark"] .st-note { background: #fff; color: #093843; }
html[data-theme="dark"] .st-read { color: #2d5560; }
html[data-theme="dark"] .st-read .on { color: #0097b2; }

/* ---------- crescent / sun toggle ---------- */
.theme-toggle {
  position: relative;
  z-index: 1101;
  width: 46px;
  height: 46px;
  flex: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line-light);
  border-radius: 50%;
  background: transparent;
  color: var(--ink);
  cursor: pointer;
  transition: background 0.35s, border-color 0.35s, color 0.35s, transform 0.35s;
}
.theme-toggle:hover { background: var(--cyan); border-color: var(--cyan); color: #093843; transform: translateY(-2px) rotate(-12deg); }
.theme-toggle svg { display: block; }
.theme-toggle .ico-sun { display: none; }
html[data-theme="dark"] .theme-toggle .ico-moon { display: none; }
html[data-theme="dark"] .theme-toggle .ico-sun { display: block; }
.header.is-open .theme-toggle { color: #fff; border-color: var(--line-dark); }
.header.is-open .theme-toggle:hover { color: #093843; }
