/* =====================================================================
   Jusoor Group — Design System
   ===================================================================== */

:root {
  /* Brand palette */
  --navy: #0B2545;
  --navy-2: #13315C;
  --steel: #8DA9C4;
  --cream: #EEF4ED;
  --paper: #FAF7F2;
  --gold: #B8945A;
  --gold-2: #8E6E3F;
  --gold-soft: #D4B996;
  --gold-bright: #D4A24A;
  --ink: #1A1F2E;
  --muted: #5C6473;
  --line: #DCD7CC;
  --line-2: #2A3E5C;

  /* Type */
  --serif: 'Playfair Display', 'Cormorant Garamond', Georgia, serif;
  --sans: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, 'SF Mono', Menlo, monospace;
  --arabic: 'Noto Naskh Arabic', 'Amiri', serif;

  /* Spacing scale */
  --s-1: 4px;
  --s-2: 8px;
  --s-3: 12px;
  --s-4: 16px;
  --s-5: 24px;
  --s-6: 32px;
  --s-7: 48px;
  --s-8: 64px;
  --s-9: 96px;
  --s-10: 128px;

  /* Layout */
  --max: 1280px;
  --gutter: 32px;
}

/* Reset-ish */
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; overflow-x: hidden; }
body {
  font-family: var(--sans);
  color: var(--ink);
  background: var(--paper);
  line-height: 1.55;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
button { font: inherit; cursor: pointer; }
hr { border: 0; border-top: 1px solid var(--line); margin: var(--s-7) 0; }

/* ---------- Typography ---------- */
.h-display {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(44px, 5.4vw, 76px);
  line-height: 1.05;
  letter-spacing: -0.025em;
  color: var(--navy);
}
.h-1 {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(36px, 4.4vw, 60px);
  line-height: 1.1;
  letter-spacing: -0.015em;
  color: var(--navy);
  text-wrap: balance;
}
.h-2 {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(28px, 3vw, 40px);
  line-height: 1.15;
  letter-spacing: -0.01em;
  color: var(--navy);
  text-wrap: balance;
}
.h-3 {
  font-family: var(--serif);
  font-weight: 500;
  font-size: 24px;
  line-height: 1.25;
  color: var(--navy);
  margin: 0;
}
.eyebrow {
  font-family: var(--sans);
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-size: 12px;
  font-weight: 600;
  color: var(--gold-2);
  display: inline-flex;
  align-items: center;
  gap: 12px;
}
.eyebrow::before {
  content: '';
  display: inline-block;
  width: 24px;
  height: 1px;
  background: var(--gold);
}
.eyebrow.no-rule::before { display: none; }
.lead {
  font-size: 19px;
  line-height: 1.6;
  color: var(--muted);
  max-width: 60ch;
  text-wrap: pretty;
}
.body { color: var(--muted); }
.body p { margin: 0 0 1em; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 24px;
  font-weight: 500;
  font-size: 15px;
  border: 1px solid transparent;
  transition: all .2s ease;
  letter-spacing: 0.01em;
  cursor: pointer;
  background: none;
  color: inherit;
}
.btn-primary {
  background: var(--navy);
  color: var(--cream);
}
.btn-primary:hover { background: var(--navy-2); }
.btn-gold {
  background: var(--gold);
  color: #fff;
}
.btn-gold:hover { background: var(--gold-2); }
.btn-ghost {
  border-color: var(--navy);
  color: var(--navy);
}
.btn-ghost:hover { background: var(--navy); color: var(--cream); }
.btn-ghost-light {
  border-color: rgba(255,255,255,0.4);
  color: var(--cream);
}
.btn-ghost-light:hover { background: var(--cream); color: var(--navy); }
.btn .arrow {
  display: inline-block;
  transition: transform .2s ease;
}
.btn:hover .arrow { transform: translateX(4px); }

/* ---------- Layout ---------- */
.container {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--gutter);
}
.section { padding: var(--s-9) 0; }
.section-sm { padding: var(--s-8) 0; }
.section-lg { padding: var(--s-10) 0; }

.section-navy { background: var(--navy); color: var(--cream); }
.section-navy .h-1, .section-navy .h-2, .section-navy .h-3, .section-navy .h-display { color: var(--cream); }
.section-navy .body, .section-navy .lead { color: var(--steel); }
.section-navy .eyebrow { color: var(--gold-soft); }
.section-navy .eyebrow::before { background: var(--gold); }

.section-cream { background: var(--cream); }
.section-paper { background: var(--paper); }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(250, 247, 242, 0.92);
  backdrop-filter: saturate(140%) blur(8px);
  border-bottom: 1px solid var(--line);
}
.site-header__top {
  background: var(--navy);
  color: var(--steel);
  font-size: 13px;
}
.site-header__top .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 10px;
  padding-bottom: 10px;
}
.site-header__top a { color: var(--cream); }
.site-header__top a:hover { color: var(--gold-soft); }
.site-header__top .top-meta { display: flex; gap: 24px; align-items: center; }
.site-header__top .top-actions { display: flex; gap: 16px; align-items: center; }
.lang-toggle {
  display: inline-flex;
  background: rgba(255,255,255,0.06);
  border-radius: 999px;
  padding: 2px;
  font-size: 12px;
}
.lang-toggle button {
  border: 0;
  background: transparent;
  color: var(--steel);
  padding: 4px 12px;
  border-radius: 999px;
  cursor: pointer;
  letter-spacing: 0.04em;
}
.lang-toggle button.active {
  background: var(--gold);
  color: #fff;
}

.site-header__main {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 0;
  gap: 24px;
}
.site-header__main .header-right {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-left: auto;
}
.site-header__logo img { height: 56px; width: auto; }
.site-header__nav-row { display: none; }
.site-nav { display: flex !important; gap: 2px; align-items: center; flex-wrap: nowrap; }
.site-nav a {
  padding: 8px 12px;
  font-size: 14px;
  color: var(--ink);
  position: relative;
  border-radius: 2px;
  transition: color .15s ease;
}
.site-nav a:hover, .site-nav a.active { color: var(--navy); }
.site-nav a.active::after,
.site-nav a:hover::after {
  content: '';
  position: absolute;
  left: 16px;
  right: 16px;
  bottom: 4px;
  height: 1px;
  background: var(--gold);
}
.site-nav .has-sub { position: relative; }
.site-nav .has-sub > a::after { content: ''; }
.site-nav .has-sub::before {
  content: '';
  position: absolute;
  inset: auto 0 -10px 0;
  height: 10px;
}
.site-nav .has-sub:hover .submenu { display: block; }
.submenu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  margin-top: 8px;
  min-width: 320px;
  background: var(--paper);
  border: 1px solid var(--line);
  padding: 12px;
  box-shadow: 0 30px 60px -20px rgba(11, 37, 69, 0.18);
}
.submenu a {
  display: block;
  padding: 12px 14px;
  font-size: 14px;
  border-radius: 0;
}
.submenu a small {
  display: block;
  color: var(--muted);
  font-size: 12px;
  margin-top: 4px;
}
.submenu a:hover { background: var(--cream); }
.submenu a:hover::after { display: none; }

.header-cta { display: flex; gap: 12px; align-items: center; }

/* ---------- Footer ---------- */
.site-footer {
  background: var(--navy);
  color: var(--steel);
  padding-top: var(--s-9);
}
.site-footer a { color: var(--cream); }
.site-footer a:hover { color: var(--gold-soft); }
.site-footer__top {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr 1.2fr;
  gap: 48px;
  padding-bottom: var(--s-8);
  border-bottom: 1px solid var(--line-2);
}
.site-footer h5 {
  font-family: var(--sans);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--gold-soft);
  font-weight: 600;
  margin: 0 0 20px;
}
.footer-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; font-size: 14px; }
.footer-brand p { font-size: 14px; color: var(--steel); max-width: 32ch; }
.footer-brand img { height: 48px; margin-bottom: 20px; filter: brightness(1.1); }
.newsletter input {
  width: 100%;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--line-2);
  color: var(--cream);
  padding: 12px 14px;
  font: inherit;
  font-size: 14px;
}
.newsletter input::placeholder { color: rgba(141,169,196,0.6); }
.newsletter input:focus { outline: 1px solid var(--gold); border-color: var(--gold); }
.newsletter button {
  width: 100%;
  margin-top: 10px;
  padding: 12px;
  background: var(--gold);
  color: #fff;
  border: 0;
  font-weight: 500;
  letter-spacing: 0.02em;
  font-size: 14px;
}
.newsletter button:hover { background: var(--gold-2); }
.social {
  display: flex;
  gap: 10px;
  margin-top: 20px;
}
.social a {
  width: 38px;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line-2);
  border-radius: 50%;
  transition: all .2s ease;
}
.social a:hover { background: var(--gold); border-color: var(--gold); color: #fff; }
.social svg { width: 16px; height: 16px; }

.site-footer__bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 24px 0;
  font-size: 13px;
  color: rgba(141,169,196,0.7);
  flex-wrap: wrap;
  gap: 16px;
}
.site-footer__bottom .legal { display: flex; gap: 24px; flex-wrap: wrap; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  padding: var(--s-9) 0 var(--s-10);
  overflow: hidden;
}

/* Hero visual wrapper — gives us a hook for variant restyling */
.hero-grid > div:nth-child(2) {
  position: relative;
}
.hero-grid > div:nth-child(2)::after {
  /* warm gold accent corner — desktop subtle */
  content: '';
  position: absolute;
  bottom: -12px;
  right: -12px;
  width: 64px;
  height: 64px;
  border-right: 2px solid var(--gold);
  border-bottom: 2px solid var(--gold);
  pointer-events: none;
  opacity: 0;
  transition: opacity .4s ease .2s;
}
.is-revealed .hero-grid > div:nth-child(2)::after { opacity: 1; }
html[dir="rtl"] .hero-grid > div:nth-child(2)::after {
  right: auto;
  left: -12px;
  border-right: 0;
  border-left: 2px solid var(--gold);
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 72px;
  align-items: center;
}
.hero-meta {
  margin-top: 32px;
  display: flex;
  gap: 32px;
  flex-wrap: wrap;
  padding-top: 32px;
  border-top: 1px solid var(--line);
}
.hero-meta .stat .num {
  font-family: var(--serif);
  font-size: 42px;
  color: var(--navy);
  font-weight: 500;
  line-height: 1;
}
.hero-meta .stat .label {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--muted);
  margin-top: 6px;
}
.hero-actions { display: flex; gap: 12px; margin-top: 36px; flex-wrap: wrap; }

/* ---------- Striped SVG placeholders ---------- */
.placeholder {
  position: relative;
  background-color: var(--cream);
  background-image: repeating-linear-gradient(
    135deg,
    rgba(11, 37, 69, 0.06) 0,
    rgba(11, 37, 69, 0.06) 1px,
    transparent 1px,
    transparent 12px
  );
  border: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--navy);
  font-family: var(--mono);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  text-align: center;
  padding: 16px;
  overflow: hidden;
}
.placeholder.dark {
  background-color: var(--navy-2);
  background-image: repeating-linear-gradient(
    135deg,
    rgba(255,255,255,0.04) 0,
    rgba(255,255,255,0.04) 1px,
    transparent 1px,
    transparent 12px
  );
  color: var(--gold-soft);
  border-color: var(--line-2);
}
.placeholder.gold {
  background-color: rgba(184, 148, 90, 0.12);
  background-image: repeating-linear-gradient(
    135deg,
    rgba(184, 148, 90, 0.18) 0,
    rgba(184, 148, 90, 0.18) 1px,
    transparent 1px,
    transparent 10px
  );
  color: var(--gold-2);
  border-color: rgba(184,148,90,0.3);
}
.placeholder span { background: var(--paper); padding: 4px 10px; }
.placeholder.dark span { background: var(--navy); }

/* ---------- Cards ---------- */
.card {
  background: var(--paper);
  border: 1px solid var(--line);
  padding: 32px;
  transition: all .25s ease;
  display: flex;
  flex-direction: column;
}
.card:hover {
  border-color: var(--gold);
  transform: translateY(-2px);
}
.card .num-marker {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--gold-2);
  letter-spacing: 0.15em;
  margin-bottom: 24px;
}
.card .h-3 { margin-bottom: 12px; }
.card .body { font-size: 15px; flex: 1; }
.card .more {
  margin-top: 24px;
  font-size: 14px;
  color: var(--navy);
  font-weight: 500;
  display: inline-flex;
  gap: 8px;
  align-items: center;
}
.card .more .arrow { transition: transform .2s ease; }
.card:hover .more .arrow { transform: translateX(4px); }

/* ---------- Service-specific ---------- */
.svc-icon {
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(184, 148, 90, 0.12);
  color: var(--gold-2);
  margin-bottom: 24px;
}
.svc-icon svg { width: 28px; height: 28px; }

/* ---------- Grid utilities ---------- */
.grid { display: grid; gap: 32px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

@media (max-width: 980px) {
  .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .hero-grid { grid-template-columns: 1fr; gap: 48px; }
  .site-footer__top { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 600px) {
  .site-nav { font-size: 13px; gap: 0; }
  .site-nav a { padding: 8px 10px; }
}
@media (max-width: 600px) {
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .site-footer__top { grid-template-columns: 1fr; }
  :root { --gutter: 20px; }
  .section { padding: 64px 0; }
}

/* =====================================================================
   Mobile overflow — collapse inline multi-column grids
   Inline styles beat class-based media queries; !important is required.
   Excludes tiny icon grids (24px wide) which are already mobile-safe.
   ===================================================================== */
@media (max-width: 900px) {
  [style*="grid-template-columns"]:not([style*="24px"]) {
    grid-template-columns: 1fr !important;
    gap: 40px !important;
  }
  /* 80px icon+label rows (pricing tables) — keep as auto+1fr, just tighten gap */
  [style*="grid-template-columns:80px 1fr"],
  [style*="grid-template-columns: 80px 1fr"] {
    grid-template-columns: auto 1fr !important;
    gap: 16px !important;
  }
  /* Services list rows — stack content and remove horizontal padding */
  [style*="200px 1fr 200px 80px"] {
    padding: 32px 0 !important;
  }
  /* Reduce large section gaps on mobile */
  .section { padding: 56px 0 !important; }
  .section-lg { padding: 72px 0 !important; }
  /* Sticky sidebars shouldn't be sticky on mobile */
  aside[style*="sticky"] { position: static !important; }
  [style*="position:sticky"],
  [style*="position: sticky"] { position: static !important; }
}


.menu-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  background: none;
  border: none;
  padding: 8px;
  cursor: pointer;
  flex-shrink: 0;
  margin-left: 8px;
}
.menu-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--navy);
  border-radius: 2px;
  transition: all .25s ease;
}
html[dir="rtl"] .menu-toggle { margin-left: 0; margin-right: 8px; }

.mobile-nav {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 300;
}
.mobile-nav.open { display: flex; }

.mobile-nav__overlay {
  position: absolute;
  inset: 0;
  background: rgba(11, 37, 69, 0.55);
  backdrop-filter: blur(2px);
  animation: fade-in .25s ease;
}
@keyframes fade-in { from { opacity: 0; } to { opacity: 1; } }

.mobile-nav__panel {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(320px, 88vw);
  background: var(--paper);
  padding: 20px 24px 32px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform .3s cubic-bezier(0.16, 1, 0.3, 1);
}
.mobile-nav.open .mobile-nav__panel { transform: translateX(0); }
html[dir="rtl"] .mobile-nav__panel {
  right: auto;
  left: 0;
  transform: translateX(-100%);
}
html[dir="rtl"] .mobile-nav.open .mobile-nav__panel { transform: translateX(0); }

.mobile-nav__close {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 16px;
}
html[dir="rtl"] .mobile-nav__close { justify-content: flex-start; }
.mobile-nav__close button {
  background: none;
  border: none;
  font-size: 32px;
  font-weight: 300;
  color: var(--navy);
  padding: 0 4px;
  cursor: pointer;
  line-height: 1;
}

.mobile-nav__links {
  display: flex;
  flex-direction: column;
  flex: 1;
}
.mobile-nav__links > a {
  display: block;
  padding: 15px 0;
  border-bottom: 1px solid var(--line);
  font-family: var(--serif);
  font-size: 18px;
  color: var(--navy);
  font-weight: 500;
}
.mobile-nav__links > a.active { color: var(--gold-2); }

.mobile-nav__sub {
  display: flex;
  flex-direction: column;
  background: var(--cream);
  margin: 0 -24px;
  padding: 4px 24px 4px 36px;
}
html[dir="rtl"] .mobile-nav__sub { padding: 4px 36px 4px 24px; }
.mobile-nav__sub-link {
  display: block;
  padding: 10px 0;
  font-size: 14px;
  color: var(--muted);
  border-bottom: 1px solid rgba(220,215,204,0.5);
}
.mobile-nav__sub-link:last-child { border-bottom: none; }

.mobile-nav__cta {
  margin-top: 28px;
}
.mobile-nav__cta .btn {
  width: 100%;
  justify-content: center;
}

.mobile-nav__contact {
  margin-top: 20px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 13px;
}
.mobile-nav__contact a { color: var(--navy); }

/* Responsive header — hide desktop nav, show hamburger */
@media (max-width: 960px) {
  .site-nav, .header-cta { display: none !important; }
  .menu-toggle { display: flex; }
}

/* Top bar — hide heavy content on mobile */
@media (max-width: 640px) {
  .top-address, .top-sep { display: none; }
  .top-email { display: none; }
  .site-header__top .top-meta a[href^="tel"] { font-size: 12px; }
}

/* ---------- WhatsApp Floater ---------- */
.wa-floater {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 80;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: #25D366;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 12px 30px -8px rgba(37, 211, 102, 0.5);
  transition: transform .2s ease;
}
.wa-floater:hover { transform: scale(1.08); }
.wa-floater svg { width: 28px; height: 28px; fill: #fff; }
.wa-floater .pulse {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 2px solid #25D366;
  animation: wa-pulse 1.8s ease-out infinite;
}
@keyframes wa-pulse {
  0% { transform: scale(1); opacity: .8; }
  100% { transform: scale(1.5); opacity: 0; }
}

/* ---------- Decorative bits ---------- */
.gold-rule {
  width: 56px;
  height: 1px;
  background: var(--gold);
  margin: 0 0 24px;
}
.dot-rule {
  height: 1px;
  background-image: linear-gradient(to right, var(--line) 50%, transparent 0%);
  background-size: 8px 1px;
  background-repeat: repeat-x;
}

/* ---------- Forms ---------- */
.form-row { display: grid; gap: 8px; margin-bottom: 20px; }
.form-row label {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--muted);
  font-weight: 600;
}
.form-row input,
.form-row textarea,
.form-row select {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid var(--line);
  background: #fff;
  font: inherit;
  font-size: 15px;
  color: var(--ink);
  border-radius: 0;
}
.form-row input:focus,
.form-row textarea:focus,
.form-row select:focus {
  outline: none;
  border-color: var(--gold);
}
.form-row textarea { min-height: 140px; resize: vertical; }
.form-grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 600px) { .form-grid-2 { grid-template-columns: 1fr; } }

/* ---------- Page hero (interior) ---------- */
.page-hero {
  background: var(--navy);
  color: var(--cream);
  padding: var(--s-8) 0 var(--s-9);
  position: relative;
  overflow: hidden;
}
.page-hero .breadcrumb {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--gold-soft);
  margin-bottom: 32px;
  display: flex;
  gap: 8px;
}
.page-hero .breadcrumb a:hover { color: var(--gold); }
.page-hero .breadcrumb .sep { opacity: 0.4; }
.page-hero h1 {
  color: var(--cream);
  font-family: var(--serif);
  font-size: clamp(40px, 5vw, 72px);
  font-weight: 500;
  line-height: 1.05;
  letter-spacing: -0.015em;
  margin: 0 0 24px;
  max-width: 22ch;
  text-wrap: balance;
}
.page-hero p { color: var(--steel); max-width: 60ch; font-size: 18px; }

/* ---------- RTL ---------- */
[dir="rtl"] body { font-family: var(--arabic); }
[dir="rtl"] .eyebrow::before { display: none; }
[dir="rtl"] .eyebrow::after {
  content: '';
  display: inline-block;
  width: 24px;
  height: 1px;
  background: var(--gold);
}

/* ---------- Misc ---------- */
.split-stat {
  border-top: 1px solid var(--line);
  padding-top: 24px;
}
.split-stat .num {
  font-family: var(--serif);
  font-size: 56px;
  color: var(--navy);
  font-weight: 500;
  line-height: 1;
  letter-spacing: -0.02em;
}
.split-stat .label {
  font-size: 13px;
  color: var(--muted);
  margin-top: 8px;
  max-width: 26ch;
}

.testimonial {
  background: var(--paper);
  border: 1px solid var(--line);
  padding: 40px;
}
.testimonial .quote {
  font-family: var(--serif);
  font-size: 22px;
  line-height: 1.5;
  color: var(--navy);
  margin: 0 0 24px;
  font-style: italic;
}
.testimonial .who {
  display: flex;
  gap: 12px;
  align-items: center;
  font-size: 14px;
}
.testimonial .who .avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--cream);
  background-image: repeating-linear-gradient(135deg, rgba(11, 37, 69, 0.1) 0, rgba(11, 37, 69, 0.1) 1px, transparent 1px, transparent 6px);
}
.testimonial .who strong { color: var(--navy); display: block; }
.testimonial .who span { color: var(--muted); font-size: 13px; }

/* logo strip */
.logo-strip {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 24px;
  align-items: center;
}
.logo-strip .placeholder { height: 56px; padding: 0; }
@media (max-width: 800px) { .logo-strip { grid-template-columns: repeat(3, 1fr); } }

/* article cards (blog) */
.article-card { display: flex; flex-direction: column; gap: 16px; }
.article-card .thumb { aspect-ratio: 4/3; }
.article-card .cat { font-size: 12px; text-transform: uppercase; letter-spacing: 0.15em; color: var(--gold-2); font-weight: 600; }
.article-card .date { font-family: var(--mono); font-size: 12px; color: var(--muted); }
.article-card .title { font-family: var(--serif); font-size: 22px; color: var(--navy); line-height: 1.25; margin: 4px 0 8px; font-weight: 500; }
.article-card.featured .thumb { aspect-ratio: 16/10; }
.article-card.featured .title { font-size: 36px; line-height: 1.1; }
.article-card.compact { flex-direction: row; gap: 20px; align-items: flex-start; padding-bottom: 24px; border-bottom: 1px solid var(--line); }
.article-card.compact .thumb { width: 140px; flex-shrink: 0; aspect-ratio: 1; }
.article-card.compact .title { font-size: 18px; margin: 4px 0; }

/* prose pages */
.prose { max-width: 72ch; margin: 0 auto; }
.prose h2 {
  font-family: var(--serif);
  color: var(--navy);
  font-size: 28px;
  margin: 56px 0 16px;
  font-weight: 500;
}
.prose h3 {
  font-family: var(--sans);
  font-size: 18px;
  margin: 32px 0 12px;
  color: var(--navy);
}
.prose p { color: var(--ink); margin: 0 0 16px; line-height: 1.7; }
.prose ul, .prose ol { color: var(--ink); line-height: 1.7; padding-left: 20px; }
.prose li { margin-bottom: 8px; }
.prose .meta {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--muted);
  margin-bottom: 16px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

/* faq */
.faq-item {
  border-bottom: 1px solid var(--line);
  padding: 24px 0;
}
.faq-item summary {
  font-family: var(--serif);
  font-size: 20px;
  color: var(--navy);
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  font-weight: 500;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: '+';
  font-family: var(--sans);
  font-size: 28px;
  color: var(--gold);
  transition: transform .2s ease;
  font-weight: 300;
}
.faq-item[open] summary::after { transform: rotate(45deg); }
.faq-item p { margin: 16px 0 0; color: var(--muted); line-height: 1.7; }


/* =====================================================================
   RTL / Arabic mode
   Activated when <html dir="rtl" lang="ar"> (set by i18n engine)
   ===================================================================== */
html[dir="rtl"] body,
html[dir="rtl"] .lang-ar {
  font-family: var(--arabic), var(--sans);
  letter-spacing: 0;
}
html[dir="rtl"] h1, html[dir="rtl"] h2, html[dir="rtl"] h3,
html[dir="rtl"] h4, html[dir="rtl"] h5, html[dir="rtl"] h6,
html[dir="rtl"] .display, html[dir="rtl"] .h1, html[dir="rtl"] .h2, html[dir="rtl"] .h3 {
  font-family: var(--arabic), var(--serif);
  letter-spacing: 0;
  line-height: 1.4;
  font-weight: 600;
}
html[dir="rtl"] .eyebrow,
html[dir="rtl"] .meta,
html[dir="rtl"] .mono {
  font-family: var(--arabic), var(--sans);
  letter-spacing: 0.05em;
}
/* eyebrow rule line moves to the right */
html[dir="rtl"] .eyebrow::before {
  left: auto;
  right: 0;
}
html[dir="rtl"] .eyebrow:not(.no-rule) {
  padding-left: 0;
  padding-right: 56px;
}
/* lists: flip padding */
html[dir="rtl"] ul, html[dir="rtl"] ol,
html[dir="rtl"] .prose ul, html[dir="rtl"] .prose ol {
  padding-left: 0;
  padding-right: 20px;
}
/* nav active underline */
html[dir="rtl"] .site-nav a.active::after,
html[dir="rtl"] .site-nav a:hover::after {
  left: 16px;
  right: 16px;
}
/* arrow glyphs flip direction */
html[dir="rtl"] .arrow {
  display: inline-block;
  transform: scaleX(-1);
}
/* header: logo on right, menu on left, but flexbox row-reverse handles it via dir */
html[dir="rtl"] .header-right {
  margin-left: 0;
  margin-right: auto;
}
/* footer text alignment */
html[dir="rtl"] .site-footer__top,
html[dir="rtl"] .footer-list,
html[dir="rtl"] .footer-brand p {
  text-align: right;
}
html[dir="rtl"] .site-footer__bottom .legal {
  flex-direction: row-reverse;
}
/* whatsapp floater */
html[dir="rtl"] .wa-floater {
  right: auto;
  left: 28px;
}
/* tweaks panel still pinned right */
/* faq plus icon stays right */
html[dir="rtl"] .faq-item summary {
  flex-direction: row-reverse;
}
/* form labels */
html[dir="rtl"] .form-field label,
html[dir="rtl"] form label {
  text-align: right;
}
/* hero stats: align right */
html[dir="rtl"] .hero-stats,
html[dir="rtl"] .stat,
html[dir="rtl"] .stat-block {
  text-align: right;
}
/* buttons: arrow position naturally swaps via inline-flex; ensure spacing OK */
html[dir="rtl"] .btn .arrow {
  margin-left: 0;
  margin-right: 6px;
}
/* Slightly larger Arabic body for readability */
html[dir="rtl"] body { font-size: 17px; line-height: 1.7; }
/* preserve numbers in latin where used as data (we chose Western digits, this is fine by default) */
html[dir="rtl"] .stat .num,
html[dir="rtl"] .stat-num { font-family: var(--serif); }

/* hero grid often has 2 cols with text left, visual right -- keep visual on text-end side */
html[dir="rtl"] .hero-grid { direction: rtl; }
html[dir="rtl"] .grid { direction: rtl; }

/* legal & nav: small text alignment in top bar */
html[dir="rtl"] .site-header__top .top-meta,
html[dir="rtl"] .site-header__top .top-actions { gap: 24px; }

/* lang toggle: keep EN-Arabic order natural; flexbox handles reversal */

/* =====================================================================
   MOBILE PHONE-VIEW REDESIGN (≤640px)
   Hero variants + warm gold/sand refinements + reveals + press states
   Driven by body[data-hero-variant="split|editorial|overlay"]
   ===================================================================== */

/* ---- Press state (touch feedback) for buttons & cards on mobile ---- */
@media (hover: none) and (pointer: coarse) {
  .btn:active { transform: scale(0.97); transition: transform .08s ease; }
  .card:active, .article-card:active { transform: scale(0.99); }
}

/* ---- Scroll reveal primitive (used on mobile only to avoid desktop regressions) ---- */
@media (max-width: 900px) {
  .reveal {
    opacity: 0;
    transform: translateY(18px);
    transition: opacity .7s cubic-bezier(0.16, 1, 0.3, 1), transform .7s cubic-bezier(0.16, 1, 0.3, 1);
    will-change: opacity, transform;
  }
  .reveal.is-in {
    opacity: 1;
    transform: none;
  }
  /* Stagger children */
  .reveal-stagger > * {
    opacity: 0;
    transform: translateY(14px);
    transition: opacity .55s ease, transform .55s ease;
  }
  .reveal-stagger.is-in > * { opacity: 1; transform: none; }
  .reveal-stagger.is-in > *:nth-child(1) { transition-delay: .05s; }
  .reveal-stagger.is-in > *:nth-child(2) { transition-delay: .15s; }
  .reveal-stagger.is-in > *:nth-child(3) { transition-delay: .25s; }
  .reveal-stagger.is-in > *:nth-child(4) { transition-delay: .35s; }
  .reveal-stagger.is-in > *:nth-child(5) { transition-delay: .45s; }
  @media (prefers-reduced-motion: reduce) {
    .reveal, .reveal-stagger > * { opacity: 1 !important; transform: none !important; transition: none !important; }
  }
}

/* ---- Mobile-only hero treatments ---- */
@media (max-width: 640px) {

  /* Warm-up paper background only on mobile to give a sand/desert feel */
  body { background: #FBF6EE; }

  /* Tighten section rhythm */
  .hero { padding: 32px 0 56px; }

  /* Larger CTA hit targets */
  .hero-actions .btn {
    min-height: 52px;
    padding: 16px 22px;
    font-size: 15px;
  }
  .hero-actions { gap: 10px; margin-top: 28px; }
  .hero-actions .btn { width: 100%; justify-content: center; }

  /* Stats: tighter, 2-col grid, smaller numerals */
  .hero-meta {
    margin-top: 28px;
    padding-top: 24px;
    display: grid !important;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
  }
  .hero-meta .stat .num {
    font-size: 32px;
  }
  .hero-meta .stat .label {
    font-size: 11px;
    letter-spacing: 0.12em;
  }

  /* Eyebrow on mobile: a little airier */
  .hero .eyebrow { font-size: 11px; }

  /* ============================================
     VARIANT A — SPLIT (default, refined)
     Image first, then headline. Warm corner accent.
     ============================================ */
  body[data-hero-variant="split"] .hero-grid {
    grid-template-columns: 1fr !important;
    gap: 28px !important;
  }
  body[data-hero-variant="split"] .hero-grid > div:nth-child(2) {
    order: -1;
    margin: 0 -20px;  /* full-bleed within gutter */
  }
  body[data-hero-variant="split"] .hero-grid > div:nth-child(2) > div {
    aspect-ratio: 4/3 !important;
    position: relative;
  }
  body[data-hero-variant="split"] .hero-grid > div:nth-child(2)::after {
    /* hide desktop corner accent; replace with subtle warm overlay */
    display: none;
  }
  body[data-hero-variant="split"] .h-display {
    font-size: 40px !important;
    line-height: 1.08;
    margin: 16px 0 18px !important;
  }
  body[data-hero-variant="split"] .lead { font-size: 16px; }

  /* ============================================
     VARIANT B — EDITORIAL (bold)
     Massive serif headline first, no image, stats inline as a
     warm ribbon. CTAs prominent.
     ============================================ */
  body[data-hero-variant="editorial"] .hero {
    padding: 24px 0 48px;
    background:
      radial-gradient(circle at 0% 0%, rgba(212, 185, 150, 0.35), transparent 60%),
      radial-gradient(circle at 100% 100%, rgba(184, 148, 90, 0.18), transparent 55%),
      #FBF6EE;
  }
  body[data-hero-variant="editorial"] .hero-grid {
    grid-template-columns: 1fr !important;
    gap: 0 !important;
  }
  /* Hide the image entirely in editorial mode */
  body[data-hero-variant="editorial"] .hero-grid > div:nth-child(2) {
    display: none;
  }
  body[data-hero-variant="editorial"] .h-display {
    font-size: 52px !important;
    line-height: 1.0;
    margin: 18px 0 24px !important;
    letter-spacing: -0.025em;
  }
  body[data-hero-variant="editorial"] .h-display::after {
    /* warm gold underline punctuation */
    content: '';
    display: block;
    width: 48px;
    height: 3px;
    background: var(--gold);
    margin-top: 20px;
  }
  body[data-hero-variant="editorial"] .lead {
    font-size: 17px;
    line-height: 1.55;
  }
  body[data-hero-variant="editorial"] .hero-meta {
    margin-top: 32px;
    padding-top: 24px;
    border-top: 1px solid rgba(184, 148, 90, 0.35);
    grid-template-columns: 1fr 1fr;
  }
  body[data-hero-variant="editorial"] .hero-meta .stat .num {
    color: var(--gold-2);
  }

  /* ============================================
     VARIANT C — OVERLAY (cinematic)
     Full-bleed photo, dark scrim, headline + CTA over image.
     Stats below as compact horizontal pill row.
     ============================================ */
  body[data-hero-variant="overlay"] .hero {
    padding: 0 0 40px;
    background: var(--paper);
  }
  body[data-hero-variant="overlay"] .hero > .container {
    padding: 0;
    max-width: 100%;
  }
  body[data-hero-variant="overlay"] .hero-grid {
    grid-template-columns: 1fr !important;
    gap: 0 !important;
    position: relative;
  }
  /* Image becomes the background of the text block */
  body[data-hero-variant="overlay"] .hero-grid > div:nth-child(2) {
    position: absolute;
    inset: 0;
    z-index: 0;
    margin: 0;
    height: 100%;
  }
  body[data-hero-variant="overlay"] .hero-grid > div:nth-child(2) > div {
    aspect-ratio: auto !important;
    height: 100% !important;
    width: 100%;
    overflow: hidden;
  }
  body[data-hero-variant="overlay"] .hero-grid > div:nth-child(2) img {
    height: 100% !important;
    width: 100%;
    object-fit: cover;
  }
  body[data-hero-variant="overlay"] .hero-grid > div:nth-child(2)::before {
    /* dark warm scrim for text legibility */
    content: '';
    position: absolute;
    inset: 0;
    z-index: 1;
    background:
      linear-gradient(180deg,
        rgba(11, 37, 69, 0.15) 0%,
        rgba(11, 37, 69, 0.55) 55%,
        rgba(11, 37, 69, 0.92) 100%);
  }
  body[data-hero-variant="overlay"] .hero-grid > div:nth-child(2)::after { display: none; }
  body[data-hero-variant="overlay"] .hero-grid > div:first-child {
    position: relative;
    z-index: 2;
    padding: 28px 20px 32px;
    min-height: 92vh;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    color: var(--cream);
  }
  body[data-hero-variant="overlay"] .hero .eyebrow {
    color: var(--gold-soft);
  }
  body[data-hero-variant="overlay"] .hero .eyebrow::before {
    background: var(--gold-soft);
  }
  body[data-hero-variant="overlay"] .hero .h-display {
    color: var(--cream) !important;
    font-size: 44px !important;
    line-height: 1.05;
    margin: 14px 0 18px !important;
  }
  body[data-hero-variant="overlay"] .hero .lead {
    color: rgba(238, 244, 237, 0.85) !important;
    font-size: 15px;
  }
  body[data-hero-variant="overlay"] .hero-actions {
    margin-top: 22px;
  }
  body[data-hero-variant="overlay"] .hero .btn-primary {
    background: var(--gold);
    color: #fff;
    border-color: var(--gold);
  }
  body[data-hero-variant="overlay"] .hero .btn-primary:hover,
  body[data-hero-variant="overlay"] .hero .btn-primary:active {
    background: var(--gold-2);
    border-color: var(--gold-2);
  }
  body[data-hero-variant="overlay"] .hero .btn-ghost {
    border-color: rgba(255,255,255,0.4);
    color: var(--cream);
  }
  body[data-hero-variant="overlay"] .hero .btn-ghost:hover,
  body[data-hero-variant="overlay"] .hero .btn-ghost:active {
    background: rgba(255,255,255,0.1);
    color: var(--cream);
  }
  body[data-hero-variant="overlay"] .hero-meta {
    margin-top: 24px;
    padding-top: 20px;
    border-top: 1px solid rgba(255,255,255,0.18);
    grid-template-columns: 1fr 1fr;
    gap: 16px;
  }
  body[data-hero-variant="overlay"] .hero-meta .stat .num {
    color: var(--gold-soft);
    font-size: 28px;
  }
  body[data-hero-variant="overlay"] .hero-meta .stat .label {
    color: rgba(238, 244, 237, 0.7);
  }

  /* Hide stats globally if tweak is off */
  body[data-show-stats="false"] .hero-meta { display: none !important; }

  /* ----- Card list (services) — mobile rhythm ----- */
  .grid.grid-2 .card {
    padding: 32px 24px !important;
  }
  .svc-icon {
    width: 48px;
    height: 48px;
    margin-bottom: 18px;
  }

  /* ----- Section headers more compact on mobile ----- */
  .section { padding: 56px 0 !important; }

  /* ----- Industries: tighter spacing ----- */
  .section-paper .grid.grid-2 > div { padding: 18px 0 !important; }

  /* ----- Bottom CTA: stack with warmer feel ----- */
  .section-navy .btn-gold { width: 100%; justify-content: center; }
  .section-navy .btn-ghost-light { width: 100%; justify-content: center; }
}

/* ===== Small phones: keep editorial headline from blowing past viewport ===== */
@media (max-width: 380px) {
  body[data-hero-variant="editorial"] .h-display { font-size: 44px !important; }
  body[data-hero-variant="overlay"] .hero .h-display { font-size: 38px !important; }
  body[data-hero-variant="split"] .h-display { font-size: 34px !important; }
  .hero-meta .stat .num { font-size: 26px !important; }
}

/* ===== RTL fixes for new variants ===== */
@media (max-width: 640px) {
  html[dir="rtl"] body[data-hero-variant="editorial"] .h-display::after {
    margin-left: 0;
    margin-right: 0;
  }
  html[dir="rtl"] body[data-hero-variant="overlay"] .hero-grid > div:first-child {
    text-align: right;
  }
}

/* =====================================================================
   OVERLAY HERO — TITLE PLACEMENT VARIANTS
   Driven by body[data-title-variant="bottom-left|top-left|centered|center-xl|stacked"]
   Only applies when overlay hero is active.
   ===================================================================== */

/* ---- Title line wrappers (.t-l1 / .t-l2) — block-level, full width ---- */
.h-display .t-l1,
.h-display .t-l2 {
  display: block;
}
/* Desktop+: keep each title line on a single line — never break "international" from "ambition" */
@media (min-width: 641px) {
  .h-display .t-l1,
  .h-display .t-l2 {
    white-space: nowrap;
  }
}
.h-display .t-with {
  /* Always stylized: cream/white, italic, slightly smaller */
  color: var(--cream);
  font-style: italic;
  font-weight: 300;
  font-size: 0.78em;
  letter-spacing: 0.01em;
  opacity: 0.95;
}

/* Gold words ("Bridging", "Malaysian") in overlay hero — match desktop on every viewport */
body[data-hero-variant="overlay"] .hero .h-display span[style*="gold"] {
  color: #ECC47A !important;
}

/* ====== Title break style — body[data-title-break="..."] ======
   On desktop/tablet (≥641px), title is ALWAYS clean two-line.
   Alternate break styles only apply on mobile. */

/* Default: clean two-line break */
body[data-title-break="two-line"] .h-display .t-l2 { display: block; }

@media (max-width: 640px) {
  /* "with" floats — pulled onto its own indented line, then rest of line 2 */
  body[data-title-break="with-floats"] .h-display .t-with {
    display: block;
    font-size: 0.5em;
    font-style: italic;
    font-weight: 400;
    color: var(--gold-soft);
    letter-spacing: 0.06em;
    margin: 0.35em 0 0.05em 0.6em;
    line-height: 1;
  }
  html[dir="rtl"] body[data-title-break="with-floats"] .h-display .t-with {
    margin: 0.35em 0.6em 0.05em 0;
  }

  /* Right-shifted — second line pushed right (asymmetric editorial) */
  body[data-title-break="right-shifted"] .h-display .t-l2 {
    padding-left: 8%;
  }
  html[dir="rtl"] body[data-title-break="right-shifted"] .h-display .t-l2 {
    padding-left: 0;
    padding-right: 8%;
  }

  /* Smaller subline — line 2 at ~70% scale, lighter weight, sand color */
  body[data-title-break="smaller-subline"] .h-display .t-l2 {
    font-size: 0.66em;
    font-weight: 300;
    letter-spacing: -0.005em;
    margin-top: 0.35em;
    color: rgba(238, 244, 237, 0.9);
  }

  /* Italic counterpoint — line 2 in italic serif, slightly smaller */
  body[data-title-break="italic-counter"] .h-display .t-l2 {
    font-style: italic;
    font-weight: 400;
    font-size: 0.85em;
    margin-top: 0.05em;
  }

  /* Stacked-with — "with" alone on its own line, l2 phrase on a third line */
  body[data-title-break="stacked-with"] .h-display .t-with {
    display: block;
    font-size: 0.55em;
    font-weight: 300;
    font-style: italic;
    color: var(--gold-soft);
    margin-top: 0.3em;
    line-height: 1;
  }
}

@media (min-width: 641px) {
  /* === DEFAULT: bottom-left (already handled above by flex justify-content: flex-end via padding) === */
  body[data-hero-variant="overlay"][data-title-variant="bottom-left"] .hero-grid > div:first-child {
    padding: 96px 0 80px;
    justify-content: flex-end;
    display: flex;
    flex-direction: column;
  }

  /* === TOP-LEFT: title at the top, eyebrow leads === */
  body[data-hero-variant="overlay"][data-title-variant="top-left"] .hero-grid {
    min-height: min(78vh, 720px);
  }
  body[data-hero-variant="overlay"][data-title-variant="top-left"] .hero-grid > div:first-child {
    padding: 80px 0 40px;
    justify-content: flex-start;
    display: flex;
    flex-direction: column;
    max-width: 900px;
  }
  body[data-hero-variant="overlay"][data-title-variant="top-left"] .hero .h-display {
    font-size: clamp(48px, 5.6vw, 76px) !important;
  }

  /* === CENTERED: huge headline, dead center, single column, dramatic === */
  body[data-hero-variant="overlay"][data-title-variant="centered"] .hero-grid {
    min-height: min(88vh, 820px);
  }
  body[data-hero-variant="overlay"][data-title-variant="centered"] .hero-grid > div:first-child {
    padding: 80px 24px;
    max-width: 1100px;
    margin: 0 auto;
    text-align: center;
    align-items: center;
    justify-content: center;
    display: flex;
    flex-direction: column;
  }
  body[data-hero-variant="overlay"][data-title-variant="centered"] .hero-grid > div:nth-child(2)::before {
    /* symmetric dark scrim, top-and-bottom weighted */
    background:
      linear-gradient(180deg,
        rgba(11, 37, 69, 0.55) 0%,
        rgba(11, 37, 69, 0.35) 50%,
        rgba(11, 37, 69, 0.75) 100%) !important;
  }
  body[data-hero-variant="overlay"][data-title-variant="centered"] .hero .h-display {
    font-size: clamp(56px, 7vw, 96px) !important;
    line-height: 1.0 !important;
    text-align: center;
    max-width: 18ch;
    margin: 18px auto 24px !important;
  }
  body[data-hero-variant="overlay"][data-title-variant="centered"] .lead {
    text-align: center;
    margin: 0 auto;
    max-width: 56ch;
  }
  body[data-hero-variant="overlay"][data-title-variant="centered"] .hero-actions {
    justify-content: center;
  }
  body[data-hero-variant="overlay"][data-title-variant="centered"] .hero-meta {
    justify-content: center;
    width: 100%;
    max-width: 720px;
  }

  /* === CENTER-XL: vertically centered, left-aligned, even bigger headline, tight === */
  body[data-hero-variant="overlay"][data-title-variant="center-xl"] .hero-grid {
    min-height: min(86vh, 800px);
  }
  body[data-hero-variant="overlay"][data-title-variant="center-xl"] .hero-grid > div:first-child {
    padding: 80px 0;
    justify-content: center;
    display: flex;
    flex-direction: column;
    max-width: 880px;
  }
  body[data-hero-variant="overlay"][data-title-variant="center-xl"] .hero .h-display {
    font-size: clamp(64px, 8vw, 108px) !important;
    line-height: 0.96 !important;
    letter-spacing: -0.03em !important;
    margin: 24px 0 32px !important;
  }
  body[data-hero-variant="overlay"][data-title-variant="center-xl"] .lead {
    font-size: 20px;
    max-width: 52ch;
  }

  /* === STACKED: each line broken — gold words emphasized on their own lines === */
  body[data-hero-variant="overlay"][data-title-variant="stacked"] .hero-grid > div:first-child {
    padding: 96px 0 80px;
    justify-content: flex-end;
    display: flex;
    flex-direction: column;
    max-width: 900px;
  }
  body[data-hero-variant="overlay"][data-title-variant="stacked"] .hero .h-display {
    font-size: clamp(56px, 7vw, 96px) !important;
    line-height: 1.0 !important;
    letter-spacing: -0.025em !important;
  }
  body[data-hero-variant="overlay"][data-title-variant="stacked"] .hero .h-display span[style*="gold"] {
    display: block;
    font-style: italic;
    font-weight: 400;
  }
}

/* Mobile: keep title variants present but constrained */
@media (max-width: 640px) {
  body[data-hero-variant="overlay"][data-title-variant="centered"] .hero-grid > div:first-child {
    text-align: center;
    align-items: center;
    justify-content: center;
  }
  body[data-hero-variant="overlay"][data-title-variant="centered"] .hero .h-display {
    text-align: center;
    margin-left: auto !important;
    margin-right: auto !important;
  }
  body[data-hero-variant="overlay"][data-title-variant="centered"] .hero-actions {
    justify-content: center;
  }
  body[data-hero-variant="overlay"][data-title-variant="top-left"] .hero-grid > div:first-child {
    justify-content: flex-start;
    padding-top: 28px;
  }
  body[data-hero-variant="overlay"][data-title-variant="center-xl"] .hero-grid > div:first-child {
    justify-content: center;
  }
  body[data-hero-variant="overlay"][data-title-variant="stacked"] .hero .h-display span[style*="gold"] {
    display: block;
    font-style: italic;
    font-weight: 400;
  }
  body[data-hero-variant="overlay"][data-title-variant="center-xl"] .hero .h-display {
    font-size: 48px !important;
    line-height: 0.98 !important;
  }
}
@media (min-width: 641px) {
  body[data-hero-variant="overlay"] .hero {
    padding: 0;
    background: var(--paper);
    overflow: hidden;
  }
  body[data-hero-variant="overlay"] .hero > .container {
    padding: 0;
    max-width: 100%;
    position: relative;
  }
  body[data-hero-variant="overlay"] .hero-grid {
    grid-template-columns: 1fr !important;
    gap: 0 !important;
    position: relative;
    min-height: min(78vh, 720px);
  }
  /* Image becomes full-bleed background */
  body[data-hero-variant="overlay"] .hero-grid > div:nth-child(2) {
    position: absolute;
    inset: 0;
    z-index: 0;
    margin: 0;
  }
  body[data-hero-variant="overlay"] .hero-grid > div:nth-child(2) > div {
    aspect-ratio: auto !important;
    height: 100% !important;
    width: 100%;
    overflow: hidden;
  }
  body[data-hero-variant="overlay"] .hero-grid > div:nth-child(2) img {
    height: 100% !important;
    width: 100% !important;
    object-fit: cover;
    transform: scale(1.02);
  }
  /* Warm-to-navy scrim, side-weighted on desktop so text reads against it */
  body[data-hero-variant="overlay"] .hero-grid > div:nth-child(2)::before {
    content: '';
    position: absolute;
    inset: 0;
    z-index: 1;
    background:
      linear-gradient(90deg,
        rgba(11, 37, 69, 0.85) 0%,
        rgba(11, 37, 69, 0.55) 45%,
        rgba(11, 37, 69, 0.20) 75%,
        rgba(11, 37, 69, 0.10) 100%),
      linear-gradient(180deg,
        rgba(11, 37, 69, 0.0) 0%,
        rgba(11, 37, 69, 0.25) 100%);
  }
  body[data-hero-variant="overlay"] .hero-grid > div:nth-child(2)::after { display: none; }

  /* Text column sits over the image */
  body[data-hero-variant="overlay"] .hero-grid > div:first-child {
    position: relative;
    z-index: 2;
    padding: 96px 0 80px;
    max-width: 900px;
    color: var(--cream);
  }
  body[data-hero-variant="overlay"] .hero .container {
    /* keep inner padding so text doesn't hug edge */
  }
  /* Honor desktop max-width inside the now-fluid container */
  body[data-hero-variant="overlay"] .hero-grid > div:first-child::before {
    content: '';
    display: block;
    /* spacer not needed; padding handles it */
  }

  body[data-hero-variant="overlay"] .hero .eyebrow {
    color: var(--gold-soft);
  }
  body[data-hero-variant="overlay"] .hero .eyebrow::before {
    background: var(--gold-soft);
  }
  body[data-hero-variant="overlay"] .hero .h-display {
    color: var(--cream) !important;
    text-shadow: 0 2px 30px rgba(0, 0, 0, 0.25);
  }
  body[data-hero-variant="overlay"] .hero .h-display span[style*="gold"] {
    color: #ECC47A !important;
  }
  body[data-hero-variant="overlay"] .hero .lead {
    color: rgba(238, 244, 237, 0.9) !important;
  }
  body[data-hero-variant="overlay"] .hero .lead strong {
    color: var(--cream);
  }
  body[data-hero-variant="overlay"] .hero .btn-primary {
    background: var(--gold);
    color: #fff;
    border-color: var(--gold);
  }
  body[data-hero-variant="overlay"] .hero .btn-primary:hover {
    background: var(--gold-2);
    border-color: var(--gold-2);
  }
  body[data-hero-variant="overlay"] .hero .btn-ghost {
    border-color: rgba(255,255,255,0.5);
    color: var(--cream);
  }
  body[data-hero-variant="overlay"] .hero .btn-ghost:hover {
    background: var(--cream);
    color: var(--navy);
  }
  body[data-hero-variant="overlay"] .hero-meta {
    border-top-color: rgba(255,255,255,0.2) !important;
  }
  body[data-hero-variant="overlay"] .hero-meta .stat .num {
    color: var(--gold-soft);
  }
  body[data-hero-variant="overlay"] .hero-meta .stat .label {
    color: rgba(238, 244, 237, 0.75);
  }

  /* Wrap the text column in a container so it respects gutter on desktop */
  body[data-hero-variant="overlay"] .hero-grid {
    padding-left: var(--gutter);
    padding-right: var(--gutter);
    max-width: var(--max);
    margin: 0 auto;
  }

  /* RTL: scrim on the right side */
  html[dir="rtl"] body[data-hero-variant="overlay"] .hero-grid > div:nth-child(2)::before {
    background:
      linear-gradient(270deg,
        rgba(11, 37, 69, 0.85) 0%,
        rgba(11, 37, 69, 0.55) 45%,
        rgba(11, 37, 69, 0.20) 75%,
        rgba(11, 37, 69, 0.10) 100%),
      linear-gradient(180deg,
        rgba(11, 37, 69, 0.0) 0%,
        rgba(11, 37, 69, 0.25) 100%);
  }
  html[dir="rtl"] body[data-hero-variant="overlay"] .hero-grid > div:first-child {
    margin-left: auto;
    margin-right: 0;
    text-align: right;
  }
}
