/* ==========================================================================
   NUBD Elhandasa — main stylesheet
   --------------------------------------------------------------------------
   Design system via CSS variables · BEM-like naming · logical properties
   everywhere (margin-inline, inset-inline-start…) so RTL ⇄ LTR switching
   works without duplicate rules. Motion is enhanced by JS (GSAP); without
   JS/GSAP or with prefers-reduced-motion, everything stays visible.
   ========================================================================== */

/* ---------- 1. Tokens ---------- */
:root {
  --navy-950: #08112a;
  --navy-900: #0b1430;
  --navy-800: #0f1b3d;
  --navy-700: #1a2a57;
  --navy-600: #2a3b6b;
  --navy-400: #5b6b93;
  --navy-200: #c5cbdb;
  --navy-100: #e7eaf2;

  --gold-700: #7a5620;
  --gold-600: #8a6326;   /* gold text on light backgrounds (AA) */
  --gold-500: #b8893d;   /* brand gold */
  --gold-400: #cfa25a;
  --gold-300: #ddb977;   /* gold text on navy (AA) */
  --glow: #f2c879;
  --green: #4c8c3a;

  --paper: #fafaf7;
  --paper-2: #f3f1ea;
  --white: #ffffff;

  --ink: var(--navy-800);
  --muted: #4a5470;
  --muted-light: #b9c1d6;
  --line: rgba(15, 27, 61, 0.12);
  --line-strong: rgba(15, 27, 61, 0.22);
  --line-light: rgba(255, 255, 255, 0.14);

  --font-ar: 'Cairo', 'Segoe UI', Tahoma, system-ui, sans-serif;
  --font-en: 'Sora', 'Cairo', 'Segoe UI', system-ui, sans-serif;
  --font: var(--font-ar);
  --font-display: var(--font-ar);

  --fs-hero: clamp(2.5rem, 1.4rem + 5.4vw, 6.2rem);
  --fs-h2: clamp(2rem, 1.2rem + 3.2vw, 3.6rem);
  --fs-h3: clamp(1.15rem, 1rem + 0.6vw, 1.5rem);
  --fs-lead: clamp(1.05rem, 0.98rem + 0.35vw, 1.3rem);
  --fs-body: 1rem;
  --fs-small: 0.875rem;

  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-expo: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-io: cubic-bezier(0.76, 0, 0.24, 1);

  --radius: 20px;
  --radius-sm: 12px;
  --radius-xs: 8px;
  --container: 1280px;
  --gutter: clamp(16px, 4vw, 48px);
  --header-h: 76px;
  --section-pad: clamp(72px, 11vw, 150px);
  --shadow: 0 30px 60px -30px rgba(15, 27, 61, 0.35);
  --shadow-soft: 0 12px 32px -16px rgba(15, 27, 61, 0.28);
  --focus: 0 0 0 3px var(--paper), 0 0 0 5px var(--gold-500);
}

html[lang='en'] {
  --font: var(--font-en);
  --font-display: var(--font-en);
}

/* ---------- 2. Reset / base ---------- */
*,
*::before,
*::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
  overflow-x: clip;
}

html.lenis,
html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-stopped { overflow: hidden; }

html.is-loading,
html.is-locked { overflow: hidden; }

body {
  margin: 0;
  font-family: var(--font);
  font-size: var(--fs-body);
  line-height: 1.75;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
}

img,
svg,
picture { display: block; max-width: 100%; }
img { height: auto; }

a { color: inherit; text-decoration: none; }
button,
input,
textarea,
select { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: 0; padding: 0; }
ul,
ol { list-style: none; margin: 0; padding: 0; }
h1, h2, h3, h4, p, figure, dl, dd { margin: 0; }
[hidden] { display: none !important; }

:focus { outline: none; }
:focus-visible {
  outline: 2px solid var(--gold-500);
  outline-offset: 3px;
  border-radius: 4px;
}

::selection { background: var(--glow); color: var(--navy-900); }

.visually-hidden {
  position: absolute !important;
  inline-size: 1px; block-size: 1px;
  overflow: hidden; clip: rect(0 0 0 0);
  white-space: nowrap; margin: -1px; padding: 0; border: 0;
}

.skip-link {
  position: fixed;
  inset-block-start: 12px;
  inset-inline-start: 12px;
  z-index: 10000;
  padding: 10px 18px;
  border-radius: 999px;
  background: var(--navy-800);
  color: var(--paper);
  transform: translateY(-160%);
  transition: transform 0.3s var(--ease-out);
}
.skip-link:focus-visible { transform: none; }

.container {
  inline-size: 100%;
  max-inline-size: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* Latin/numeric fragments inside Arabic text keep a clean rhythm */
[dir='ltr'],
.ltr { direction: ltr; unicode-bidi: isolate; }

/* ---------- 3. Typography helpers ---------- */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-size: var(--fs-small);
  font-weight: 700;
  color: var(--gold-600);
  margin-block-end: 14px;
}
.eyebrow::before {
  content: '';
  inline-size: 36px;
  block-size: 1px;
  background: currentColor;
}
.eyebrow--light { color: var(--gold-300); }
html[lang='en'] .eyebrow { letter-spacing: 0.18em; text-transform: uppercase; font-size: 0.75rem; }

.section__title {
  font-family: var(--font-display);
  font-size: var(--fs-h2);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.01em;
  max-inline-size: 18ch;
}
html[lang='ar'] .section__title { letter-spacing: 0; line-height: 1.3; }

.section__intro {
  font-size: var(--fs-lead);
  color: var(--muted);
  max-inline-size: 46ch;
  margin-block-start: 18px;
}

/* Split-text masks (built by animations.js). One mask per word keeps
   Arabic letter-joining intact and wraps naturally in both directions. */
.split-line {
  display: inline-block;
  overflow: hidden;
  vertical-align: top;
  padding-block: 0.1em 0.14em;
  margin-block: -0.1em -0.14em;
}
.split-line--open { padding-block-end: 0.42em; margin-block-end: -0.42em; }
.split-word { display: inline-block; }
html.js:not(.no-motion) .is-split .split-word { transform: translateY(115%); }
html.js .is-split.is-in .split-word {
  transform: none;
  transition: transform 1.1s var(--ease-expo);
  transition-delay: calc(var(--i, 0) * 70ms);
}

/* Hero content stays hidden until the intro starts (failsafe after 5s) */
html.js .hero__inner,
html.js .hero__scene { visibility: hidden; animation: failsafe 0s 5s forwards; }
html.hero-ready .hero__inner,
html.hero-ready .hero__scene { visibility: visible; animation: none; }
@keyframes failsafe { to { visibility: visible; } }

/* ---------- 4. Buttons ---------- */
.btn {
  --btn-bg: transparent;
  --btn-fg: var(--ink);
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-block-size: 52px;
  padding: 0 28px;
  border-radius: 999px;
  background: var(--btn-bg);
  color: var(--btn-fg);
  font-weight: 700;
  font-size: 0.98rem;
  line-height: 1;
  white-space: nowrap;
  overflow: hidden;
  isolation: isolate;
  transition: color 0.45s var(--ease-out), box-shadow 0.45s var(--ease-out), border-color 0.45s var(--ease-out);
}
.btn::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: inherit;
  background: var(--navy-800);
  transform: translateY(101%);
  transition: transform 0.55s var(--ease-expo);
}
.btn:hover::before,
.btn:focus-visible::before { transform: translateY(0); }
.btn > span { position: relative; display: inline-block; }

.btn--gold { --btn-bg: var(--gold-500); --btn-fg: var(--navy-900); box-shadow: 0 14px 30px -14px rgba(184, 137, 61, 0.7); }
.btn--gold:hover,
.btn--gold:focus-visible { --btn-fg: var(--paper); }

.btn--ghost { --btn-fg: var(--paper); border: 1px solid rgba(255, 255, 255, 0.35); }
.btn--ghost::before { background: var(--paper); }
.btn--ghost:hover,
.btn--ghost:focus-visible { --btn-fg: var(--navy-900); border-color: var(--paper); }

.btn--dark { --btn-bg: var(--navy-800); --btn-fg: var(--paper); }
.btn--dark::before { background: var(--gold-500); }
.btn--dark:hover { --btn-fg: var(--navy-900); }

.btn--sm { min-block-size: 42px; padding: 0 20px; font-size: 0.9rem; }

.magnetic { will-change: transform; }

/* ---------- 5. Preloader ---------- */
.preloader {
  position: fixed;
  inset: 0;
  z-index: 9000;
  display: grid;
  place-items: center;
}
.preloader__curtain {
  position: absolute;
  inset-inline: 0;
  block-size: 50.5%;
  background: #fefefe;
  will-change: transform;
}
.preloader__curtain--top { inset-block-start: 0; }
.preloader__curtain--bottom { inset-block-end: 0; }
.preloader__stage {
  position: relative;
  display: grid;
  place-items: center;
  inline-size: min(78vw, 560px);
  aspect-ratio: 600 / 240;
}
.preloader__svg {
  position: absolute;
  inset: 0;
  inline-size: 100%;
  block-size: 100%;
  overflow: visible;
}
.preloader__pulse {
  fill: none;
  stroke: url(#plStroke);
  stroke-width: 4;
  stroke-linejoin: round;
  stroke-linecap: round;
  stroke-dasharray: 1;
  stroke-dashoffset: 1;
}
.preloader__beat { transform-box: view-box; transform-origin: 0 168px; }
.preloader__horizon { stroke: var(--navy-800); stroke-width: 4; stroke-linecap: round; opacity: 0; }
.preloader__spark { opacity: 0; mix-blend-mode: multiply; }
.pl-bld { transform: translateY(110%); transform-box: fill-box; }
.pl-bld rect:first-child { fill: #d9dce4; }
.pl-bld .pl-win { fill: #1a2a57; }
.pl-arc { fill: none; stroke: var(--gold-500); stroke-width: 1.5; stroke-dasharray: 1; stroke-dashoffset: 1; }
.preloader__logo {
  position: relative;
  inline-size: min(56vw, 260px);
  opacity: 0;
}
.preloader__logo img { inline-size: 100%; block-size: auto; }
.preloader__skip {
  position: absolute;
  inset-block-end: max(24px, env(safe-area-inset-bottom));
  inset-inline-end: 24px;
  padding: 8px 18px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  font-size: var(--fs-small);
  color: var(--muted);
  transition: background 0.3s, color 0.3s;
}
.preloader__skip:hover { background: var(--navy-800); color: var(--paper); }
.preloader.is-exiting .preloader__skip { opacity: 0; }
.preloader.is-reduced .preloader__logo { opacity: 1; }

/* ---------- 6. Custom cursor ---------- */
.cursor { display: none; }
html.has-cursor .cursor {
  display: block;
  position: fixed;
  left: 0;
  top: 0;
  z-index: 9500;
  pointer-events: none;
}
.cursor__dot,
.cursor__ring {
  position: fixed;
  left: 0;
  top: 0;
  border-radius: 50%;
  pointer-events: none;
  will-change: transform;
}
.cursor__dot {
  inline-size: 6px;
  block-size: 6px;
  margin: -3px 0 0 -3px;
  background: var(--gold-500);
}
.cursor__ring {
  inline-size: 38px;
  block-size: 38px;
  margin: -19px 0 0 -19px;
  border: 1px solid rgba(184, 137, 61, 0.7);
  display: grid;
  place-items: center;
  transition: width 0.45s var(--ease-expo), height 0.45s var(--ease-expo), margin 0.45s var(--ease-expo),
    background 0.35s, border-color 0.35s;
}
.cursor__label {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--navy-900);
  opacity: 0;
  transform: scale(0.6);
  transition: opacity 0.3s, transform 0.4s var(--ease-expo);
}
.cursor.is-link .cursor__ring { inline-size: 56px; block-size: 56px; margin: -28px 0 0 -28px; background: rgba(184, 137, 61, 0.12); }
.cursor.is-view .cursor__ring { inline-size: 88px; block-size: 88px; margin: -44px 0 0 -44px; background: var(--glow); border-color: var(--glow); }
.cursor.is-view .cursor__label { opacity: 1; transform: none; }
.cursor.is-view .cursor__dot { opacity: 0; }
.cursor.is-hidden { opacity: 0; }

/* ---------- 7. Scroll progress pulse ---------- */
.pulse-progress {
  position: fixed;
  inset-block: 50% auto;
  inset-inline-end: 22px;
  z-index: 800;
  block-size: min(46vh, 420px);
  inline-size: 24px;
  transform: translateY(-50%);
  display: none;
}
.pulse-progress__track {
  position: absolute;
  inset-block: 0;
  inset-inline-start: 50%;
  inline-size: 1px;
  background: var(--line-strong);
}
.pulse-progress__fill {
  position: absolute;
  inset: 0;
  background: var(--gold-500);
  transform-origin: top;
  transform: scaleY(0);
}
.pulse-progress__beat {
  position: absolute;
  inset-inline-start: calc(50% - 20px);
  inline-size: 40px;
  block-size: 24px;
  margin-block-start: -12px;
  fill: none;
  stroke: var(--gold-500);
  stroke-width: 2;
  stroke-linejoin: round;
  stroke-linecap: round;
  pointer-events: none;
  opacity: 0;
  transform: scaleX(0.4);
}
.pulse-progress__beat.is-beating { animation: beat 0.9s var(--ease-out); }
@keyframes beat {
  0% { opacity: 0; transform: scaleX(0.3) scaleY(0.4); }
  25% { opacity: 1; transform: scaleX(1) scaleY(1.2); }
  60% { opacity: 1; transform: scaleX(1) scaleY(1); }
  100% { opacity: 0; transform: scaleX(0.6) scaleY(0.2); }
}
.pulse-progress__dots {
  position: absolute;
  inset: 0;
}
.pulse-progress__dot {
  position: absolute;
  inset-inline-start: 50%;
  inline-size: 18px;
  block-size: 18px;
  margin-inline-start: -9px;
  margin-block-start: -9px;
  display: grid;
  place-items: center;
}
.pulse-progress__dot::before {
  content: '';
  inline-size: 7px;
  block-size: 7px;
  border-radius: 50%;
  background: var(--paper);
  border: 1px solid var(--line-strong);
  transition: transform 0.4s var(--ease-expo), background 0.3s;
}
.pulse-progress__dot.is-active::before { background: var(--gold-500); border-color: var(--gold-500); transform: scale(1.4); }
.pulse-progress__dot:hover::before { transform: scale(1.5); }
.pulse-progress__tip {
  position: absolute;
  inset-inline-end: 24px;
  white-space: nowrap;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--navy-800);
  color: var(--paper);
  font-size: 0.75rem;
  opacity: 0;
  transform: translateX(6px);
  pointer-events: none;
  transition: opacity 0.3s, transform 0.4s var(--ease-expo);
}
[dir='rtl'] .pulse-progress__tip { transform: translateX(-6px); }
.pulse-progress__dot:hover .pulse-progress__tip,
.pulse-progress__dot:focus-visible .pulse-progress__tip { opacity: 1; transform: none; }
.pulse-progress.is-on-dark .pulse-progress__track { background: var(--line-light); }

@media (min-width: 1024px) {
  .pulse-progress { display: block; }
}

/* ---------- 8. Page curtain (language switch transition) ---------- */
.page-curtain {
  position: fixed;
  inset: 0;
  z-index: 8500;
  display: grid;
  place-items: center;
  background: var(--navy-800);
  clip-path: inset(0 0 100% 0);
  pointer-events: none;
}
.page-curtain svg { inline-size: min(60vw, 420px); block-size: 60px; }
.page-curtain path {
  fill: none;
  stroke: var(--gold-500);
  stroke-width: 2.5;
  stroke-linejoin: round;
  stroke-dasharray: 600;
  stroke-dashoffset: 600;
}
.page-curtain.is-active { pointer-events: all; }

/* ---------- 9. Header ---------- */
.header {
  position: fixed;
  inset-block-start: 0;
  inset-inline: 0;
  z-index: 900;
  block-size: var(--header-h);
  color: var(--paper);
  transition: background 0.5s var(--ease-out), color 0.5s var(--ease-out), transform 0.6s var(--ease-expo),
    box-shadow 0.5s var(--ease-out);
}
.header::after {
  content: '';
  position: absolute;
  inset-inline: 0;
  inset-block-end: 0;
  block-size: 1px;
  background: linear-gradient(90deg, transparent, var(--gold-500), transparent);
  opacity: 0;
  transition: opacity 0.5s;
}
.header.is-scrolled {
  background: rgba(250, 250, 247, 0.84);
  -webkit-backdrop-filter: saturate(1.4) blur(14px);
  backdrop-filter: saturate(1.4) blur(14px);
  color: var(--ink);
  box-shadow: 0 10px 30px -24px rgba(15, 27, 61, 0.5);
}
.header.is-scrolled::after { opacity: 0.6; }
.header.is-hidden { transform: translateY(-100%); }
html.menu-open .header { background: transparent; color: var(--paper); box-shadow: none; transform: none; -webkit-backdrop-filter: none; backdrop-filter: none; }
html.menu-open .header::after { opacity: 0; }

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  block-size: 100%;
}

.brand { display: inline-flex; align-items: center; gap: 12px; flex: none; }
.brand__tile {
  inline-size: 48px;
  block-size: 48px;
  border-radius: 12px;
  overflow: hidden;
  background: var(--white);
  box-shadow: 0 6px 18px -8px rgba(0, 0, 0, 0.45);
  flex: none;
}
.brand__tile img { inline-size: 100%; block-size: 100%; object-fit: cover; }
.brand__word { display: flex; flex-direction: column; line-height: 1; direction: ltr; }
.brand__nubd {
  font-family: var(--font-en);
  font-weight: 700;
  font-size: 1.35rem;
  letter-spacing: 0.04em;
}
.brand__nubd em { font-style: normal; color: var(--gold-500); }
.brand__sub {
  font-family: var(--font-en);
  font-size: 0.56rem;
  letter-spacing: 0.42em;
  margin-block-start: 5px;
  opacity: 0.8;
}

.nav { display: none; }
.nav__list { display: flex; gap: clamp(14px, 2vw, 30px); }
.nav__link {
  position: relative;
  display: inline-block;
  padding-block: 6px;
  font-weight: 600;
  font-size: 0.95rem;
  opacity: 0.86;
  transition: opacity 0.3s;
}
.nav__link::after {
  content: '';
  position: absolute;
  inset-inline: 0;
  inset-block-end: 0;
  block-size: 1.5px;
  background: var(--gold-500);
  transform: scaleX(0);
  transform-origin: var(--origin-end, right);
  transition: transform 0.5s var(--ease-expo);
}
[dir='ltr'] .nav__link::after { --origin-end: right; }
[dir='rtl'] .nav__link::after { --origin-end: left; }
.nav__link:hover,
.nav__link.is-active { opacity: 1; }
.nav__link:hover::after,
.nav__link.is-active::after { transform: scaleX(1); transform-origin: var(--origin-start, left); }
[dir='rtl'] .nav__link:hover::after,
[dir='rtl'] .nav__link.is-active::after { --origin-start: right; }

.header__actions { display: flex; align-items: center; gap: 10px; }
.header__cta { display: none; }

.lang-toggle {
  min-block-size: 40px;
  padding: 0 14px;
  border-radius: 999px;
  border: 1px solid currentColor;
  font-weight: 700;
  font-size: 0.85rem;
  opacity: 0.9;
  transition: background 0.3s, color 0.3s, opacity 0.3s;
}
.lang-toggle:hover { background: var(--gold-500); border-color: var(--gold-500); color: var(--navy-900); opacity: 1; }
.lang-toggle span[data-i18n='header.lang'] { font-family: var(--font-ar); }
html[lang='ar'] .lang-toggle span { font-family: var(--font-en); }

.burger {
  position: relative;
  inline-size: 44px;
  block-size: 44px;
  border-radius: 50%;
  display: grid;
  place-content: center;
  gap: 7px;
}
.burger__line {
  display: block;
  inline-size: 24px;
  block-size: 1.5px;
  background: currentColor;
  transition: transform 0.5s var(--ease-expo);
}
.burger[aria-expanded='true'] .burger__line:first-child { transform: translateY(4.25px) rotate(45deg); }
.burger[aria-expanded='true'] .burger__line:last-child { transform: translateY(-4.25px) rotate(-45deg); }

@media (min-width: 1100px) {
  .nav { display: block; }
  .burger { display: none; }
  .header__cta { display: inline-flex; }
}

/* ---------- 10. Mobile menu ---------- */
.mobile-menu {
  position: fixed;
  inset: 0;
  z-index: 850;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: calc(var(--header-h) + 20px) var(--gutter) max(28px, env(safe-area-inset-bottom));
  color: var(--paper);
}
.mobile-menu__bg {
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(circle at 80% 90%, rgba(242, 200, 121, 0.16), transparent 50%),
    var(--navy-900);
  clip-path: circle(0% at var(--menu-x, 92%) 38px);
  transition: clip-path 0.8s var(--ease-io);
}
[dir='rtl'] .mobile-menu__bg { --menu-x: 8%; }
.mobile-menu.is-open .mobile-menu__bg { clip-path: circle(150% at var(--menu-x, 92%) 38px); }
.mobile-menu__list { display: grid; gap: 4px; }
.mobile-menu__link {
  display: flex;
  align-items: baseline;
  gap: 16px;
  padding-block: 6px;
  font-size: clamp(1.8rem, 8vw, 3rem);
  font-weight: 800;
  line-height: 1.25;
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.5s, transform 0.7s var(--ease-expo), color 0.3s;
}
.mobile-menu__link:hover { color: var(--glow); }
.mobile-menu__num { font-family: var(--font-en); font-size: 0.8rem; font-weight: 400; color: var(--gold-300); }
.mobile-menu.is-open .mobile-menu__link { opacity: 1; transform: none; }
.mobile-menu.is-open li:nth-child(1) .mobile-menu__link { transition-delay: 0.18s; }
.mobile-menu.is-open li:nth-child(2) .mobile-menu__link { transition-delay: 0.23s; }
.mobile-menu.is-open li:nth-child(3) .mobile-menu__link { transition-delay: 0.28s; }
.mobile-menu.is-open li:nth-child(4) .mobile-menu__link { transition-delay: 0.33s; }
.mobile-menu.is-open li:nth-child(5) .mobile-menu__link { transition-delay: 0.38s; }
.mobile-menu.is-open li:nth-child(6) .mobile-menu__link { transition-delay: 0.43s; }
.mobile-menu.is-open li:nth-child(7) .mobile-menu__link { transition-delay: 0.48s; }
.mobile-menu__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-block-start: 40px;
  padding-block-start: 20px;
  border-block-start: 1px solid var(--line-light);
  opacity: 0;
  transition: opacity 0.6s 0.5s;
}
.mobile-menu.is-open .mobile-menu__footer { opacity: 1; }
.mobile-menu__tagline { color: var(--gold-300); font-size: var(--fs-small); }
.lang-toggle--light { color: var(--paper); }

/* ---------- 11. Hero ---------- */
.hero {
  position: relative;
  min-block-size: 100vh;
  min-block-size: 100svh;
  display: flex;
  flex-direction: column;
  padding-block-start: calc(var(--header-h) + clamp(28px, 7vh, 90px));
  color: var(--paper);
  background:
    radial-gradient(ellipse 60% 50% at 70% 85%, rgba(242, 200, 121, 0.2), transparent 70%),
    linear-gradient(180deg, var(--navy-950) 0%, var(--navy-800) 55%, #17264f 100%);
  overflow: hidden;
  isolation: isolate;
}
[dir='rtl'] .hero { background:
    radial-gradient(ellipse 60% 50% at 30% 85%, rgba(242, 200, 121, 0.2), transparent 70%),
    linear-gradient(180deg, var(--navy-950) 0%, var(--navy-800) 55%, #17264f 100%); }

.hero__grid {
  position: absolute;
  inset: -60px;
  z-index: -2;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.055) 1px, transparent 1px),
    linear-gradient(rgba(255, 255, 255, 0.022) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.022) 1px, transparent 1px);
  background-size: 120px 120px, 120px 120px, 24px 24px, 24px 24px;
  -webkit-mask-image: radial-gradient(ellipse 80% 70% at 50% 35%, #000 25%, transparent 85%);
  mask-image: radial-gradient(ellipse 80% 70% at 50% 35%, #000 25%, transparent 85%);
  will-change: transform;
}
.hero__wire {
  position: absolute;
  inset: 0;
  z-index: -1;
  inline-size: 100%;
  block-size: 100%;
  pointer-events: none;
}
[dir='rtl'] .hero__wire { transform: scaleX(-1); }
[dir='rtl'] .wire__label { display: none; }
.wire__line,
.wire__tower { fill: none; stroke-dasharray: 1; stroke-dashoffset: 0; vector-effect: non-scaling-stroke; }
.wire__line { stroke: rgba(242, 200, 121, 0.32); stroke-width: 1; }
.wire__line--faint { stroke: rgba(255, 255, 255, 0.08); }
.wire__tower { stroke: rgba(255, 255, 255, 0.16); stroke-width: 1; }
.wire__label { fill: rgba(242, 200, 121, 0.55); font-family: var(--font-en); font-size: 12px; letter-spacing: 0.12em; }

.hero__inner { position: relative; z-index: 2; }
.hero__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 6px 14px 6px 6px;
  border: 1px solid var(--line-light);
  border-radius: 999px;
  font-size: var(--fs-small);
  color: var(--gold-300);
  background: rgba(255, 255, 255, 0.04);
  margin-block-end: clamp(18px, 3vh, 30px);
}
[dir='rtl'] .hero__eyebrow { padding: 6px 6px 6px 14px; }
.hero__eyebrow::before {
  content: '';
  inline-size: 22px;
  block-size: 22px;
  border-radius: 50%;
  background:
    radial-gradient(circle, var(--glow) 0 3px, transparent 4px),
    rgba(242, 200, 121, 0.16);
  animation: heartbeat 1.6s var(--ease-out) infinite;
}
@keyframes heartbeat {
  0%, 100% { transform: scale(1); }
  12% { transform: scale(1.25); }
  24% { transform: scale(1); }
  36% { transform: scale(1.15); }
  48% { transform: scale(1); }
}
.hero__title {
  font-family: var(--font-display);
  font-size: var(--fs-hero);
  font-weight: 800;
  line-height: 1.08;
  letter-spacing: -0.025em;
  max-inline-size: 13ch;
}
html[lang='ar'] .hero__title { line-height: 1.25; letter-spacing: 0; }
.hero__title .underline-word { position: relative; display: inline-block; color: var(--glow); }
.hero__underline {
  position: absolute;
  inset-inline: -2%;
  inset-block-end: -0.12em;
  inline-size: 104%;
  block-size: 0.32em;
  overflow: visible;
  pointer-events: none;
}
.hero__underline path {
  fill: none;
  stroke: var(--gold-500);
  stroke-width: 5;
  stroke-linecap: round;
  stroke-dasharray: 1;
  stroke-dashoffset: 0;
}
.hero__subtitle {
  max-inline-size: 54ch;
  margin-block-start: clamp(16px, 2.6vh, 28px);
  font-size: var(--fs-lead);
  color: rgba(250, 250, 247, 0.78);
}
.hero__ctas { display: flex; flex-wrap: wrap; gap: 12px; margin-block-start: clamp(22px, 4vh, 40px); }

.hero__scene {
  position: relative;
  z-index: 1;
  margin-block-start: auto;
  inline-size: 100%;
  pointer-events: none;
}
.skyline {
  inline-size: 100%;
  block-size: clamp(190px, 34vh, 320px);
  overflow: visible;
}
@media (min-width: 900px) {
  /* Desktop: the skyline is a background layer anchored to the bottom so
     the hero always fits the viewport; text sits on the opposite side. */
  .hero { padding-block-end: clamp(160px, 30vh, 300px); }
  .hero__scene { position: absolute; inset-inline: 0; inset-block-end: 0; }
  .skyline { block-size: clamp(260px, 50vh, 560px); }
}
[dir='rtl'] .skyline { transform: scaleX(-1); }
.skyline .sk-layer { will-change: transform; }
.skyline .sk-body { fill: #d9dce4; }
.skyline .sk-body--b { fill: #c7ccd7; }
.skyline .sk-body--c { fill: #e8e9ed; }
.skyline .sk-shade { fill: var(--navy-800); opacity: 0.22; }
.skyline .sk-outline { fill: none; stroke: rgba(242, 200, 121, 0.75); stroke-width: 1.2; stroke-dasharray: 1; vector-effect: non-scaling-stroke; }
.skyline .sk-win { fill: #24345f; transition: fill 0.6s; }
.skyline .sk-win.is-lit { fill: var(--glow); }
.skyline .sk-ground { fill: #0b1430; }
.skyline .sk-lawn { fill: #29452a; }
.skyline .sk-line { fill: none; stroke: var(--gold-500); stroke-width: 3; stroke-linejoin: round; stroke-linecap: round; stroke-dasharray: 1; }
.skyline .sk-line--base { stroke: var(--paper); stroke-width: 2.5; }
.skyline .sk-arc { fill: none; stroke: var(--gold-500); stroke-width: 1.5; stroke-dasharray: 1; opacity: 0.8; }
.skyline .sk-trunk { fill: #4a3826; }
.skyline .sk-crown { fill: var(--green); }
.skyline .sk-crown--b { fill: #3f7a31; }
.skyline .sk-person { fill: #0b1430; }
.skyline .sk-glow { fill: url(#skGlow); }
.skyline .sk-bird { fill: none; stroke: rgba(250, 250, 247, 0.55); stroke-width: 1.5; stroke-linecap: round; }

.hero__scroll {
  position: absolute;
  inset-block-end: 14px;
  inset-inline-start: var(--gutter);
  z-index: 3;
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 0.72rem;
  color: var(--paper);
  opacity: 0.8;
}
html[lang='en'] .hero__scroll { letter-spacing: 0.2em; text-transform: uppercase; }
.hero__scroll-line {
  position: relative;
  inline-size: 56px;
  block-size: 1px;
  background: rgba(255, 255, 255, 0.2);
  overflow: hidden;
}
.hero__scroll-line::after {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--glow);
  transform: translateX(-100%);
  animation: scrollcue 2s var(--ease-io) infinite;
}
[dir='rtl'] .hero__scroll-line::after { animation-name: scrollcue-rtl; }
@keyframes scrollcue {
  0% { transform: translateX(-100%); }
  55% { transform: translateX(0); }
  100% { transform: translateX(100%); }
}
@keyframes scrollcue-rtl {
  0% { transform: translateX(100%); }
  55% { transform: translateX(0); }
  100% { transform: translateX(-100%); }
}

/* ---------- 12. Marquee ---------- */
.marquee {
  position: relative;
  overflow: hidden;
  padding-block: clamp(18px, 3vw, 30px);
  background: var(--paper);
  border-block-end: 1px solid var(--line);
}
.marquee__track {
  display: flex;
  inline-size: max-content;
  animation: marquee 48s linear infinite;
}
[dir='rtl'] .marquee__track { animation-name: marquee-rtl; }
.marquee:hover .marquee__track,
html.is-tab-hidden .marquee__track { animation-play-state: paused; }
.marquee__group { display: flex; align-items: center; flex: none; }
.marquee__item {
  display: inline-flex;
  align-items: center;
  gap: clamp(18px, 3vw, 40px);
  padding-inline-end: clamp(18px, 3vw, 40px);
  font-family: var(--font-display);
  font-size: clamp(1.4rem, 1rem + 2.4vw, 3rem);
  font-weight: 800;
  white-space: nowrap;
  color: transparent;
  -webkit-text-stroke: 1px var(--navy-600);
}
.marquee__item:nth-child(even) { color: var(--navy-800); -webkit-text-stroke: 0; }
.marquee__item svg { inline-size: 2.2em; block-size: 1em; flex: none; stroke: var(--gold-500); }
@keyframes marquee { to { transform: translateX(-50%); } }
@keyframes marquee-rtl { to { transform: translateX(50%); } }

/* ---------- 13. Sections ---------- */
.section {
  position: relative;
  padding-block: var(--section-pad);
}
.section--navy {
  background: var(--navy-800);
  color: var(--paper);
}
.section--navy .section__intro { color: var(--muted-light); }
.section--paper2 { background: var(--paper-2); }
.section__head { margin-block-end: clamp(36px, 6vw, 72px); }
.section__head--split {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px 48px;
}

.empty-state {
  padding: 48px 24px;
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius);
  text-align: center;
  color: var(--muted);
}

/* Pulse dividers (SVG injected by animations.js) */
.pulse-divider {
  position: relative;
  block-size: 64px;
  margin-block: -32px;
  z-index: 2;
  pointer-events: none;
}
.pulse-divider svg { position: absolute; inset: 0; inline-size: 100%; block-size: 100%; overflow: visible; }
.pulse-divider path {
  fill: none;
  stroke: var(--gold-500);
  stroke-width: 1.5;
  stroke-linejoin: round;
  stroke-linecap: round;
  stroke-dasharray: 1;
  stroke-dashoffset: 0;
  vector-effect: non-scaling-stroke;
}
.pulse-divider path.pulse-divider__base { stroke: var(--line-strong); }
[dir='rtl'] .pulse-divider svg { transform: scaleX(-1); }
.pulse-divider--light path.pulse-divider__base { stroke: var(--line-light); }
.footer .pulse-divider { margin-block: 0 24px; }

/* Generic reveal helpers (JS adds .is-in; GSAP handles if present) */
html.js [data-reveal] { opacity: 0; transform: translateY(28px); }
html.js [data-reveal].is-in,
html.no-motion [data-reveal] {
  opacity: 1;
  transform: none;
  transition: opacity 0.9s var(--ease-out), transform 1s var(--ease-expo);
}

/* The mask lives on the child: a fully clipped target never "intersects"
   for IntersectionObserver, so the figure itself stays observable. */
.reveal-img { overflow: hidden; border-radius: var(--radius); }
html.js .reveal-img > * { clip-path: inset(0 0 100% 0); }
html.js .reveal-img.is-in > *,
html.no-motion .reveal-img > * { clip-path: inset(0 0 0 0); transition: clip-path 1.3s var(--ease-io); }

/* ---------- 14. About ---------- */
.about__grid {
  display: grid;
  gap: clamp(32px, 6vw, 80px);
  align-items: start;
}
.about__label {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--gold-600);
  margin-block-end: 10px;
}
html[lang='en'] .about__label { letter-spacing: 0.12em; text-transform: uppercase; font-size: 0.75rem; }
.about__story { font-size: var(--fs-lead); line-height: 1.9; color: var(--ink); max-inline-size: 58ch; }
.about__cards { display: grid; gap: 16px; margin-block-start: 36px; }
.about__card {
  position: relative;
  padding: 24px 26px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  transition: transform 0.6s var(--ease-expo), box-shadow 0.6s var(--ease-expo), border-color 0.4s;
}
.about__card::before {
  content: '';
  position: absolute;
  inset-block-start: -1px;
  inset-inline-start: 26px;
  inline-size: 48px;
  block-size: 2px;
  background: var(--gold-500);
}
.about__card:hover { transform: translateY(-4px); box-shadow: var(--shadow-soft); border-color: transparent; }
.about__card p { color: var(--muted); }
.about__media { position: relative; aspect-ratio: 4 / 5; background: var(--navy-100); }
.about__media-inner { position: absolute; inset: -8% 0; }
.about__media img { inline-size: 100%; block-size: 100%; object-fit: cover; }

@media (min-width: 900px) {
  .about__grid { grid-template-columns: 1.15fr 0.85fr; }
  .about__cards { grid-template-columns: 1fr 1fr; }
}

.counters {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  margin-block-start: clamp(48px, 8vw, 100px);
  border-block: 1px solid var(--line);
}
.counter {
  padding: clamp(22px, 3vw, 40px) clamp(12px, 2vw, 28px);
  border-inline-end: 1px solid var(--line);
}
.counter:nth-child(2n) { border-inline-end: 0; }
.counter:nth-child(n + 3) { border-block-start: 1px solid var(--line); }
.counter__value {
  display: flex;
  align-items: baseline;
  gap: 2px;
  font-family: var(--font-en);
  font-size: clamp(2.4rem, 1.6rem + 3.4vw, 4.6rem);
  font-weight: 700;
  line-height: 1;
  color: var(--navy-800);
  direction: ltr;
  justify-content: flex-end;
}
[dir='ltr'] .counter__value { justify-content: flex-start; }
.counter__suffix { color: var(--gold-500); }
.counter__label { margin-block-start: 10px; color: var(--muted); font-weight: 600; }
@media (min-width: 900px) {
  .counters { grid-template-columns: repeat(4, 1fr); }
  .counter:nth-child(2n) { border-inline-end: 1px solid var(--line); }
  .counter:last-child { border-inline-end: 0; }
  .counter:nth-child(n + 3) { border-block-start: 0; }
}

.values { margin-block-start: clamp(48px, 8vw, 96px); }
.values__title { font-size: var(--fs-h3); font-weight: 800; margin-block-end: 24px; }
.values__list { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 230px), 1fr)); }
.value {
  position: relative;
  padding: 22px 22px 24px;
  border-radius: var(--radius-sm);
  background: var(--paper-2);
  overflow: hidden;
}
.value__num { font-family: var(--font-en); font-size: 0.8rem; color: var(--gold-600); }
.value__title { margin-block: 6px 6px; font-size: 1.15rem; font-weight: 800; }
.value__text { color: var(--muted); font-size: 0.95rem; }
.value::after {
  content: '';
  position: absolute;
  inset-inline: 0;
  inset-block-end: 0;
  block-size: 2px;
  background: var(--gold-500);
  transform: scaleX(0);
  transform-origin: var(--o, left);
  transition: transform 0.7s var(--ease-expo);
}
[dir='rtl'] .value::after { --o: right; }
.value:hover::after { transform: scaleX(1); }

/* ---------- 15. Services ---------- */
.services {
  overflow: hidden;
  background:
    radial-gradient(ellipse 50% 40% at 100% 0%, rgba(242, 200, 121, 0.09), transparent 70%),
    var(--navy-800);
}
.services__grid {
  display: grid;
  gap: 1px;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 290px), 1fr));
  background: var(--line-light);
  border: 1px solid var(--line-light);
  border-radius: var(--radius);
  overflow: hidden;
}
.service {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-block-size: 280px;
  padding: clamp(26px, 3vw, 38px);
  background: var(--navy-800);
  overflow: hidden;
  isolation: isolate;
  transition: background 0.6s var(--ease-out);
}
.service::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background: radial-gradient(circle at var(--mx, 50%) var(--my, 0%), rgba(242, 200, 121, 0.16), transparent 60%);
  opacity: 0;
  transition: opacity 0.5s;
}
.service:hover::before { opacity: 1; }
.service:hover { background: var(--navy-700); }
.service__top { display: flex; align-items: flex-start; justify-content: space-between; }
.service__num { font-family: var(--font-en); font-size: 0.8rem; color: var(--gold-300); }
.service__icon { inline-size: 56px; block-size: 56px; color: var(--glow); }
.service__icon path { stroke-dasharray: 1; stroke-dashoffset: 0; }
.service:hover .service__icon path,
.service:focus-within .service__icon path { animation: draw 1.1s var(--ease-io) both; }
.service:hover .service__icon path:nth-child(2) { animation-delay: 0.08s; }
.service:hover .service__icon path:nth-child(3) { animation-delay: 0.16s; }
.service:hover .service__icon path:nth-child(4) { animation-delay: 0.24s; }
.service:hover .service__icon path:nth-child(5) { animation-delay: 0.32s; }
@keyframes draw { from { stroke-dashoffset: 1; } to { stroke-dashoffset: 0; } }
.service__title { margin-block-start: 28px; font-size: var(--fs-h3); font-weight: 800; line-height: 1.35; }
.service__text { color: var(--muted-light); font-size: 0.95rem; }
.service__line {
  margin-block-start: auto;
  block-size: 1px;
  background: linear-gradient(90deg, var(--gold-500), transparent);
  transform: scaleX(0.25);
  transform-origin: var(--o, left);
  transition: transform 0.8s var(--ease-expo);
}
[dir='rtl'] .service__line { --o: right; background: linear-gradient(-90deg, var(--gold-500), transparent); }
.service:hover .service__line { transform: scaleX(1); }

/* ---------- 16. Featured horizontal showcase ---------- */
.featured {
  position: relative;
  background: var(--paper);
  overflow: hidden;
}
.featured__pin {
  min-block-size: 100vh;
  min-block-size: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: clamp(24px, 4vh, 48px);
  padding-block: calc(var(--header-h) + 16px) 40px;
}
.featured__head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px 40px;
}
.featured__hint { display: inline-flex; align-items: center; gap: 14px; color: var(--muted); font-size: var(--fs-small); }
.featured__hint-line { inline-size: 64px; block-size: 1px; background: var(--gold-500); position: relative; overflow: hidden; }
.featured__hint-line::after { content: ''; position: absolute; inset: 0; background: var(--navy-800); animation: hint 2.2s var(--ease-io) infinite; }
@keyframes hint { 0% { transform: translateX(-100%); } 100% { transform: translateX(100%); } }
[dir='rtl'] .featured__hint-line::after { animation-direction: reverse; }

.featured__viewport {
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}
.featured__viewport::-webkit-scrollbar { display: none; }
.featured__track {
  display: flex;
  gap: clamp(16px, 2vw, 32px);
  inline-size: max-content;
  padding-inline: var(--gutter);
  will-change: transform;
}
.featured__card {
  position: relative;
  flex: none;
  inline-size: min(84vw, 660px);
  scroll-snap-align: center;
}
.featured__link { display: block; border-radius: var(--radius); }
.featured__media {
  position: relative;
  aspect-ratio: 16 / 11;
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--navy-100);
}
.featured__media img {
  inline-size: 100%;
  block-size: 100%;
  object-fit: cover;
  transform: scale(1.08);
  transition: transform 1.2s var(--ease-expo);
}
.featured__link:hover .featured__media img { transform: scale(1.02); }
.featured__media::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 45%, rgba(8, 17, 42, 0.78));
}
.featured__caption {
  position: absolute;
  inset-inline: clamp(18px, 3vw, 32px);
  inset-block-end: clamp(18px, 3vw, 28px);
  z-index: 2;
  color: var(--paper);
}
.featured__index { font-family: var(--font-en); font-size: 0.8rem; color: var(--glow); }
.featured__title { font-size: clamp(1.3rem, 1rem + 1.4vw, 2.1rem); font-weight: 800; line-height: 1.25; }
.featured__meta { font-size: var(--fs-small); color: rgba(250, 250, 247, 0.8); }
.featured__bar {
  position: relative;
  margin-inline: var(--gutter);
  block-size: 1px;
  background: var(--line);
  display: none;
}
.featured__bar-fill { position: absolute; inset: 0; background: var(--gold-500); transform-origin: var(--o, left); transform: scaleX(0); }
[dir='rtl'] .featured__bar-fill { --o: right; }

html.has-hscroll .featured__viewport { overflow: visible; scroll-snap-type: none; }
html.has-hscroll .featured__bar { display: block; }

/* ---------- 17. Projects ---------- */
.filters { display: flex; flex-wrap: wrap; gap: 8px; }
.filter {
  position: relative;
  min-block-size: 42px;
  padding: 0 18px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  font-weight: 600;
  font-size: 0.92rem;
  color: var(--muted);
  transition: color 0.3s, border-color 0.3s, background 0.3s;
}
.filter:hover { color: var(--ink); border-color: var(--navy-800); }
.filter[aria-pressed='true'] { background: var(--navy-800); border-color: var(--navy-800); color: var(--paper); }
.filter__count { font-family: var(--font-en); font-size: 0.72rem; opacity: 0.6; margin-inline-start: 6px; }

.projects__grid {
  display: grid;
  gap: clamp(18px, 2.4vw, 32px);
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 330px), 1fr));
}
.project-card { perspective: 900px; }
.project-card.is-hidden { display: none; }
.project-card__link {
  display: block;
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: 0 1px 0 var(--line);
  transform-style: preserve-3d;
  will-change: transform;
  transition: box-shadow 0.6s var(--ease-expo);
}
.project-card__link:hover { box-shadow: var(--shadow); }
.project-card__media {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border-radius: var(--radius) var(--radius) 0 0;
  background: var(--navy-100);
}
.project-card__media img {
  inline-size: 100%;
  block-size: 100%;
  object-fit: cover;
  transition: transform 1s var(--ease-expo);
}
.project-card__link:hover .project-card__media img { transform: scale(1.06); }
.project-card__badge {
  position: absolute;
  inset-block-start: 14px;
  inset-inline-start: 14px;
  padding: 4px 12px;
  border-radius: 999px;
  background: rgba(250, 250, 247, 0.92);
  color: var(--navy-800);
  font-size: 0.78rem;
  font-weight: 700;
}
.project-card__body { padding: 20px 22px 24px; transform: translateZ(30px); }
.project-card__title { font-size: 1.2rem; font-weight: 800; line-height: 1.35; }
.project-card__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 14px;
  margin-block-start: 6px;
  color: var(--muted);
  font-size: 0.88rem;
}
.project-card__meta span + span::before { content: '·'; margin-inline-end: 14px; color: var(--gold-500); }
.project-card__more {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-block-start: 14px;
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--gold-600);
}
.project-card__more .icon { inline-size: 16px; block-size: 16px; transition: transform 0.5s var(--ease-expo); }
[dir='rtl'] .project-card__more .icon { transform: scaleX(-1); }
.project-card__link:hover .project-card__more .icon { transform: translate(4px, -4px); }
[dir='rtl'] .project-card__link:hover .project-card__more .icon { transform: scaleX(-1) translate(4px, -4px); }

/* ---------- 18. Gallery (masonry) ---------- */
.masonry { columns: 3 260px; column-gap: clamp(12px, 1.6vw, 22px); }
.masonry__item { break-inside: avoid; margin-block-end: clamp(12px, 1.6vw, 22px); }
.masonry__btn {
  position: relative;
  display: block;
  inline-size: 100%;
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: var(--navy-100);
  text-align: start;
}
.masonry__btn img { inline-size: 100%; transition: transform 1s var(--ease-expo), filter 0.6s; }
.masonry__btn:hover img { transform: scale(1.05); }
.masonry__cap {
  position: absolute;
  inset-inline: 0;
  inset-block-end: 0;
  padding: 28px 16px 14px;
  background: linear-gradient(180deg, transparent, rgba(8, 17, 42, 0.8));
  color: var(--paper);
  font-size: 0.9rem;
  font-weight: 600;
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.5s, transform 0.6s var(--ease-expo);
}
.masonry__btn:hover .masonry__cap,
.masonry__btn:focus-visible .masonry__cap { opacity: 1; transform: none; }
@media (hover: none) { .masonry__cap { opacity: 1; transform: none; } }

/* ---------- 19. Team ---------- */
.team__grid { display: grid; gap: clamp(16px, 2vw, 28px); grid-template-columns: repeat(auto-fill, minmax(min(100%, 250px), 1fr)); }
.member { position: relative; }
.member__media {
  position: relative;
  aspect-ratio: 4 / 5;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--navy-100);
}
.member__media img {
  inline-size: 100%;
  block-size: 100%;
  object-fit: cover;
  filter: grayscale(0.35) contrast(1.02);
  transition: transform 1.1s var(--ease-expo), filter 0.8s;
}
.member:hover .member__media img { transform: scale(1.06); filter: none; }
.member__overlay {
  position: absolute;
  inset: auto 0 0 0;
  padding: 60px 20px 20px;
  background: linear-gradient(180deg, transparent, rgba(8, 17, 42, 0.86));
  color: var(--paper);
  transform: translateY(32%);
  transition: transform 0.7s var(--ease-expo);
}
.member:hover .member__overlay,
.member:focus-within .member__overlay { transform: none; }
.member__name { font-size: 1.15rem; font-weight: 800; line-height: 1.3; }
.member__role { color: var(--gold-300); font-size: 0.9rem; }
.member__link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-block-start: 12px;
  font-size: 0.85rem;
  font-weight: 700;
  opacity: 0;
  transition: opacity 0.5s 0.1s, color 0.3s;
}
.member__link .icon { inline-size: 16px; block-size: 16px; }
.member:hover .member__link,
.member:focus-within .member__link { opacity: 1; }
.member__link:hover { color: var(--glow); }
@media (hover: none) {
  .member__overlay { transform: none; }
  .member__link { opacity: 1; }
}

/* ---------- 20. Contact ---------- */
.contact {
  background:
    radial-gradient(ellipse 40% 50% at 0% 100%, rgba(242, 200, 121, 0.08), transparent 70%),
    var(--navy-800);
}
.contact__grid { display: grid; gap: clamp(28px, 5vw, 64px); }
@media (min-width: 960px) { .contact__grid { grid-template-columns: 1fr 1fr; } }
.contact__cards { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 240px), 1fr)); }
.contact-card {
  display: flex;
  gap: 14px;
  padding: 18px;
  border: 1px solid var(--line-light);
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.03);
  transition: border-color 0.4s, background 0.4s, transform 0.5s var(--ease-expo);
}
.contact-card:hover { border-color: rgba(242, 200, 121, 0.5); background: rgba(255, 255, 255, 0.06); }
.contact-card--wide { grid-column: 1 / -1; }
.contact-card__icon {
  flex: none;
  inline-size: 42px;
  block-size: 42px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(242, 200, 121, 0.12);
  color: var(--glow);
}
.contact-card__icon .icon { inline-size: 20px; block-size: 20px; }
.contact-card__label { font-size: 0.8rem; color: var(--muted-light); }
.contact-card__value { font-weight: 700; line-height: 1.5; word-break: break-word; }
.contact-card__value a { transition: color 0.3s; }
.contact-card__value a:hover { color: var(--glow); }
.contact-card__value a + a { display: block; }
.btn--whatsapp { --btn-bg: #1f9d55; --btn-fg: #fff; margin-block-start: 8px; min-block-size: 44px; padding: 0 18px; font-size: 0.9rem; }
.btn--whatsapp::before { background: var(--paper); }
.btn--whatsapp:hover { --btn-fg: var(--navy-900); }
.btn--whatsapp .icon { inline-size: 18px; block-size: 18px; }

.office-links { margin-block-start: 32px; }
.office-links__title { font-size: 1.05rem; font-weight: 800; margin-block-end: 10px; color: var(--gold-300); }
.office-links__list { border-block-start: 1px solid var(--line-light); }
.office-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-block: 16px;
  border-block-end: 1px solid var(--line-light);
  font-size: 1.08rem;
  font-weight: 700;
  transition: color 0.3s, padding 0.6s var(--ease-expo);
}
.office-link .icon {
  inline-size: 20px;
  block-size: 20px;
  color: var(--gold-300);
  transition: transform 0.6s var(--ease-expo);
}
[dir='rtl'] .office-link .icon { transform: scaleX(-1); }
.office-link:hover { color: var(--glow); padding-inline-start: 10px; }
.office-link:hover .icon { transform: translate(3px, -3px) rotate(0deg); }
[dir='rtl'] .office-link:hover .icon { transform: scaleX(-1) translate(3px, -3px); }
.office-links__empty { padding-block: 16px; color: var(--muted-light); }

.contact-form {
  padding: clamp(22px, 3vw, 40px);
  border-radius: var(--radius);
  background: var(--paper);
  color: var(--ink);
  box-shadow: 0 40px 80px -40px rgba(0, 0, 0, 0.55);
}
.contact-form__title { font-size: var(--fs-h3); font-weight: 800; margin-block-end: 18px; }
.field { display: grid; gap: 6px; margin-block-end: 16px; }
.field__label { font-weight: 700; font-size: 0.9rem; }
.field__input {
  inline-size: 100%;
  min-block-size: 50px;
  padding: 12px 16px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  background: var(--white);
  transition: border-color 0.3s, box-shadow 0.3s;
}
.field__input:focus-visible { outline: none; border-color: var(--gold-500); box-shadow: 0 0 0 3px rgba(184, 137, 61, 0.25); }
.field__input--area { resize: vertical; min-block-size: 130px; }
.field__input[aria-invalid='true'] { border-color: #b3261e; }
[dir='rtl'] input[type='tel'] { text-align: end; }
.contact-form__status { min-block-size: 1.5em; font-size: 0.9rem; color: var(--gold-700); margin-block-end: 8px; }
.contact-form__status.is-error { color: #b3261e; }
.contact-form__actions { display: flex; flex-wrap: wrap; gap: 10px; }
.contact-form .btn--ghost { --btn-fg: var(--navy-800); border-color: var(--line-strong); }
.contact-form .btn--ghost::before { background: var(--navy-800); }
.contact-form .btn--ghost:hover { --btn-fg: var(--paper); }

/* ---------- 21. Footer ---------- */
.footer {
  position: relative;
  padding-block: 0 28px;
  background: var(--navy-950);
  color: var(--muted-light);
}
.footer__grid {
  display: grid;
  gap: 36px;
  padding-block: clamp(36px, 6vw, 72px);
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr));
}
.footer__brand { display: grid; gap: 16px; align-content: start; }
.footer__logo {
  inline-size: 120px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: var(--white);
}
.footer__tagline { color: var(--paper); font-weight: 700; }
.footer__title { font-size: 0.95rem; font-weight: 800; color: var(--paper); margin-block-end: 14px; }
.footer__list { display: grid; gap: 8px; }
.footer__list a { transition: color 0.3s; }
.footer__list a:hover { color: var(--glow); }
.footer__list .icon { display: inline-block; vertical-align: middle; inline-size: 14px; block-size: 14px; margin-inline-start: 6px; color: var(--gold-300); }
[dir='rtl'] .footer__list .icon { transform: scaleX(-1); }
.footer__bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-block-start: 22px;
  border-block-start: 1px solid var(--line-light);
  font-size: 0.85rem;
}
.footer__bottom-links { display: flex; gap: 20px; }
.footer__credit { font-family: var(--font-en); font-size: 0.8rem; letter-spacing: 0.02em; }

/* Mobile: two link columns side by side, brand + contact full width */
@media (max-width: 760px) {
  .footer__grid { grid-template-columns: 1fr 1fr; gap: 32px 20px; }
  .footer__brand,
  .footer__col:last-child { grid-column: 1 / -1; }
}

/* Mobile: stacked, centred bottom bar with a hairline before the credit */
@media (max-width: 760px) {
  .footer__bottom {
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 14px;
    padding-block: 22px 8px;
  }
  .footer__bottom > p:first-child { order: 1; }
  .footer__bottom-links { order: 2; }
  .footer__credit {
    order: 3;
    inline-size: 100%;
    padding-block-start: 14px;
    border-block-start: 1px solid var(--line-light);
  }
  .footer__bottom-links a {
    display: inline-flex;
    align-items: center;
    min-block-size: 40px;
    padding-inline: 18px;
    border: 1px solid var(--line-light);
    border-radius: 999px;
  }
}
.footer__credit-link {
  position: relative;
  font-weight: 700;
  color: var(--gold-300);
  transition: color 0.3s;
}
.footer__credit-link::after {
  content: '';
  position: absolute;
  inset-inline: 0;
  inset-block-end: -2px;
  block-size: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.5s var(--ease-expo);
}
.footer__credit-link:hover { color: var(--glow); }
.footer__credit-link:hover::after { transform: scaleX(1); }
.footer__bottom-links a:hover { color: var(--glow); }

.socials { display: flex; flex-wrap: wrap; gap: 8px; }
.social {
  inline-size: 40px;
  block-size: 40px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  border: 1px solid var(--line-light);
  color: var(--paper);
  transition: background 0.3s, color 0.3s, border-color 0.3s, transform 0.5s var(--ease-expo);
}
.social .icon { inline-size: 18px; block-size: 18px; }
.social:hover { background: var(--gold-500); border-color: var(--gold-500); color: var(--navy-900); transform: translateY(-3px); }

/* ---------- 22. Lightbox ---------- */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 9200;
  display: grid;
  color: var(--paper);
}
.lightbox__backdrop { position: absolute; inset: 0; background: var(--navy-950); }
.lightbox__panel {
  position: relative;
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  block-size: 100%;
  max-block-size: 100vh;
  max-block-size: 100dvh;
}
.lightbox__media {
  position: relative;
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  min-block-size: 0;
}
.lightbox__stage {
  position: relative;
  overflow: hidden;
  touch-action: none;
  user-select: none;
  cursor: grab;
}
.lightbox__stage:active { cursor: grabbing; }
.lightbox__slide {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  padding: clamp(56px, 7vw, 80px) clamp(12px, 5vw, 80px) 12px;
}
.lightbox__slide img {
  max-inline-size: 100%;
  max-block-size: 100%;
  object-fit: contain;
  border-radius: var(--radius-xs);
  transition: transform 0.5s var(--ease-expo);
  transform-origin: center;
  will-change: transform;
}
.lightbox__slide.is-zoomed img { transition: none; cursor: move; }
.lightbox__nav {
  position: absolute;
  inset-block-start: 50%;
  z-index: 3;
  inline-size: 52px;
  block-size: 52px;
  margin-block-start: -26px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--line-light);
  transition: background 0.3s, color 0.3s;
}
.lightbox__nav:hover { background: var(--gold-500); color: var(--navy-900); }
.lightbox__nav .icon { inline-size: 22px; block-size: 22px; }
.lightbox__nav--prev { inset-inline-start: clamp(8px, 2vw, 24px); }
.lightbox__nav--next { inset-inline-end: clamp(8px, 2vw, 24px); }
[dir='rtl'] .lightbox__nav .icon { transform: scaleX(-1); }
.lightbox__toolbar {
  position: absolute;
  inset-block-start: 12px;
  inset-inline: 12px;
  z-index: 4;
  display: flex;
  align-items: center;
  gap: 8px;
}
.lightbox__counter { margin-inline-end: auto; font-family: var(--font-en); font-size: 0.85rem; color: var(--muted-light); padding-inline: 8px; }
.lightbox__tool {
  inline-size: 44px;
  block-size: 44px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  transition: background 0.3s, color 0.3s;
}
.lightbox__tool:hover,
.lightbox__tool[aria-pressed='true'] { background: var(--gold-500); color: var(--navy-900); }
.lightbox__tool .icon { inline-size: 20px; block-size: 20px; }
.lightbox__thumbs {
  display: flex;
  gap: 8px;
  padding: 10px clamp(12px, 3vw, 24px) 14px;
  overflow-x: auto;
  scrollbar-width: thin;
  justify-content: safe center;
}
.lightbox__thumb {
  flex: none;
  inline-size: 72px;
  block-size: 52px;
  border-radius: 6px;
  overflow: hidden;
  opacity: 0.5;
  border: 2px solid transparent;
  transition: opacity 0.3s, border-color 0.3s;
}
.lightbox__thumb img { inline-size: 100%; block-size: 100%; object-fit: cover; }
.lightbox__thumb[aria-current='true'] { opacity: 1; border-color: var(--gold-500); }
.lightbox__thumb:hover { opacity: 0.9; }
.lightbox__info {
  max-block-size: 38vh;
  overflow-y: auto;
  padding: 18px clamp(16px, 4vw, 32px) max(22px, env(safe-area-inset-bottom));
  border-block-start: 1px solid var(--line-light);
  background: var(--navy-900);
}
.lightbox__title { font-size: clamp(1.3rem, 1rem + 1.4vw, 2rem); font-weight: 800; line-height: 1.3; }
.lightbox__meta {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: 12px;
  margin-block: 16px;
  padding-block: 14px;
  border-block: 1px solid var(--line-light);
}
.lightbox__meta dt { font-size: 0.75rem; color: var(--muted-light); }
.lightbox__meta dd { font-weight: 700; }
.lightbox__desc { color: rgba(250, 250, 247, 0.82); line-height: 1.9; }
.lightbox.is-simple .lightbox__meta,
.lightbox.is-simple #lb-cat,
.lightbox.is-simple .lightbox__desc:empty { display: none; }

@media (min-width: 1000px) {
  .lightbox__panel { grid-template-rows: none; grid-template-columns: minmax(0, 1fr) 380px; }
  .lightbox__info {
    max-block-size: none;
    border-block-start: 0;
    border-inline-start: 1px solid var(--line-light);
    padding: 90px 32px 32px;
  }
  .lightbox.is-simple .lightbox__panel { grid-template-columns: minmax(0, 1fr) 320px; }
}

/* ---------- 23. Preview badge ---------- */
.preview-badge {
  position: fixed;
  inset-block-end: 16px;
  inset-inline-start: 16px;
  z-index: 950;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  max-inline-size: calc(100vw - 32px);
  padding: 8px 8px 8px 16px;
  border-radius: 999px;
  background: var(--navy-800);
  color: var(--paper);
  font-size: 0.82rem;
  box-shadow: var(--shadow-soft);
}
[dir='rtl'] .preview-badge { padding: 8px 16px 8px 8px; }
.preview-badge__dot { inline-size: 8px; block-size: 8px; border-radius: 50%; background: var(--glow); animation: heartbeat 1.6s infinite; }
.preview-badge__btn { padding: 6px 12px; border-radius: 999px; background: var(--gold-500); color: var(--navy-900); font-weight: 700; }

/* ---------- 24. Utilities / responsive ---------- */
@media (max-width: 599px) {
  .hero__ctas .btn { flex: 1 1 auto; }
  .hero__scroll { display: none; }
  .contact-form__actions .btn { flex: 1 1 100%; }
}

/* Reduced motion: no transforms, simple fades only */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.2s !important;
  }
  html.js [data-reveal] { transform: none; }
  .marquee__track { animation: none; }
  .hero__eyebrow::before,
  .preview-badge__dot { animation: none; }
}

/* ---------- 25. Print ---------- */
@media print {
  .preloader, .cursor, .pulse-progress, .page-curtain, .header, .mobile-menu,
  .hero__scene, .hero__wire, .hero__grid, .hero__scroll, .marquee, .featured,
  .pulse-divider, .contact-form, .lightbox, .preview-badge, .filters { display: none !important; }
  body { background: #fff; color: #000; }
  .hero, .section--navy, .footer { background: #fff !important; color: #000 !important; min-block-size: 0; }
  .hero { padding-block: 24px; }
  html.js [data-reveal], html.js .reveal-img > * { opacity: 1 !important; transform: none !important; clip-path: none !important; }
  .project-card { break-inside: avoid; }
  a[href^='http']::after { content: ' (' attr(href) ')'; font-size: 0.8em; }
}
