/* ==========================================================================
   Msindaha site stylesheet
   One file, no framework. Replaces the live site's Bootstrap 4 + jQuery +
   Owl Carousel + Animate.css + Magnific Popup + 3 Font Awesome copies.

   Palette, and what each colour is allowed to do:

     navy  #0f3b68   Msindaha's own. Structure: header, headings, primary
                     buttons, dark sections.
     teal  #005a77   HLB Jordan's brand colour, taken from hlbjordan.com.
                     Everything interactive: links, icon badges, focus
                     rings, hover accents, the rule under each eyebrow.
     gold  #d4af37   Reserved for the single highest-priority call to
                     action on a page. Used sparingly so it still reads as
                     emphasis rather than decoration.

   Three colours, three jobs. Every value below is contrast-checked against
   the surface it sits on in both light and dark mode; where HLB's bright
   #0093a7 fails 4.5:1 on white it is used only for large text and fills,
   and the darker #007f91 / #005a77 carry body-sized text instead.
   ========================================================================== */

/* --- Tokens ------------------------------------------------------------- */

:root {
  /* Msindaha navy */
  --navy-900: #0a2846;
  --navy-800: #0f3b68;
  --navy-700: #184e8a;
  --navy-600: #2a649f;
  --navy-400: #5d8fc7;
  --navy-100: #e9eff6;

  /* HLB Jordan teal (hlbjordan.com) */
  --teal-900: #004559;
  --teal-800: #005a77; /* 7.7:1 on white  */
  --teal-700: #007f91; /* 4.7:1 on white  */
  --teal-500: #0093a7; /* HLB bright: fills and large text only */
  --teal-300: #3fc3d6; /* dark-mode text  */
  --teal-100: #e4f2f5;

  /* Accent gold */
  --gold-600: #b8952e;
  --gold-500: #d4af37;
  --gold-400: #e4c878;

  --primary: var(--navy-800);
  --primary-hover: var(--navy-700);

  /* Interactive accent. Kept as its own token so the colour that answers a
     click is never confused with the colour that builds the page. */
  --accent: var(--teal-800);
  --accent-hover: var(--teal-700);
  --accent-bright: var(--teal-500);
  --accent-tint: var(--teal-100);
  --accent-on-dark: var(--teal-300);

  --bg: #ffffff;
  --bg-alt: #f5f8fa;
  --bg-deep: var(--navy-900);
  --surface: #ffffff;
  --surface-2: #f8fafc;
  --border: #e3e9ef;
  --border-strong: #c7d2dd;

  --text: #0f172a;
  --text-muted: #55657d;
  --text-on-dark: #ffffff;
  --text-on-dark-muted: rgba(255, 255, 255, 0.78);

  --ok: #1e7e4d;
  --warn: #b45309;
  --danger: #c0392b;

  /* Radii: a tighter, more even ramp than before. Swiss-minimal wants
     restraint, so nothing is rounder than it needs to be. */
  --radius-sm: 6px;
  --radius: 10px;
  --radius-lg: 16px;
  --radius-pill: 999px;

  /* Shadows: short and tight rather than big and soft, so cards read as
     crisp sheets of paper instead of glowing. */
  --shadow-sm: 0 1px 2px rgba(10, 40, 70, 0.05),
    0 1px 3px rgba(10, 40, 70, 0.05);
  --shadow: 0 2px 4px rgba(10, 40, 70, 0.05),
    0 8px 20px -10px rgba(10, 40, 70, 0.18);
  --shadow-lg: 0 4px 8px rgba(10, 40, 70, 0.06),
    0 20px 40px -18px rgba(10, 40, 70, 0.26);
  --ring: 0 0 0 3px rgba(0, 90, 119, 0.28);

  /* Motion vocabulary for the whole site. Four curves and four durations;
     nothing moves at a speed or on a curve the rest of the page has not
     already used.

       --ease-out   arriving: decelerates into place. Most things.
       --ease-in    leaving:  accelerates away. Always paired with --t-fast,
                    because an exit should be quicker than an entrance.
       --ease       moving between two on-screen states.
       --ease-soft  a gentle overshoot, for things that should feel light. */
  --ease: cubic-bezier(0.4, 0, 0.2, 1);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in: cubic-bezier(0.4, 0, 1, 1);
  --ease-soft: cubic-bezier(0.34, 1.4, 0.64, 1);

  --t-fast: 140ms;
  --t: 220ms;
  --t-slow: 420ms;
  --t-panel: 320ms;

  --header-h: 72px;

  --font: "Montserrat", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    "Helvetica Neue", Arial, sans-serif;

  /* Spacing scale: every vertical gap on the page is one of these. */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.5rem;
  --space-6: 2rem;
  --space-7: 3rem;
  --space-8: 4rem;

  --wrap: 1200px;
  --gutter: 20px;
  --measure: 68ch; /* comfortable reading width for body copy */
}

/* Dark mode: follows the OS, and [data-theme] overrides it when the visitor
   picks a side with the header toggle. */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0b1420;
    --bg-alt: #0f1b2b;
    --bg-deep: #060e18;
    --surface: #131f30;
    --surface-2: #18273b;
    --border: #24344a;
    --border-strong: #354863;

    --text: #e8eef6;
    --text-muted: #a3b4ca;

    --navy-100: #16293d;

    --primary: #6fa3d8;
    --primary-hover: #8dbbe6;

    /* HLB teal, lifted for a dark surface: #3fc3d6 reads 8.8:1 on the
       page background, where the daylight #005a77 would disappear. */
    --accent: var(--teal-300);
    --accent-hover: #6fd6e4;
    --accent-bright: var(--teal-300);
    --accent-tint: rgba(63, 195, 214, 0.14);
    --accent-on-dark: var(--teal-300);

    --ring: 0 0 0 3px rgba(63, 195, 214, 0.38);

    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.45), 0 1px 3px rgba(0, 0, 0, 0.35);
    --shadow: 0 2px 4px rgba(0, 0, 0, 0.4), 0 8px 20px -10px rgba(0, 0, 0, 0.6);
    --shadow-lg: 0 4px 8px rgba(0, 0, 0, 0.45),
      0 20px 40px -18px rgba(0, 0, 0, 0.7);
  }
}

:root[data-theme="dark"] {
  --bg: #0b1420;
  --bg-alt: #0f1b2b;
  --bg-deep: #060e18;
  --surface: #131f30;
  --surface-2: #18273b;
  --border: #24344a;
  --border-strong: #354863;

  --text: #e8eef6;
  --text-muted: #a3b4ca;

  --navy-100: #16293d;

  --primary: #6fa3d8;
  --primary-hover: #8dbbe6;

  /* HLB teal, lifted for a dark surface: #3fc3d6 reads 8.8:1 on the
     page background, where the daylight #005a77 would disappear. */
  --accent: var(--teal-300);
  --accent-hover: #6fd6e4;
  --accent-bright: var(--teal-300);
  --accent-tint: rgba(63, 195, 214, 0.14);
  --accent-on-dark: var(--teal-300);

  --ring: 0 0 0 3px rgba(63, 195, 214, 0.38);

  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.45), 0 1px 3px rgba(0, 0, 0, 0.35);
  --shadow: 0 2px 4px rgba(0, 0, 0, 0.4), 0 8px 20px -10px rgba(0, 0, 0, 0.6);
  --shadow-lg: 0 4px 8px rgba(0, 0, 0, 0.45),
    0 20px 40px -18px rgba(0, 0, 0, 0.7);
}

/* --- Reset -------------------------------------------------------------- */

*,
*::before,
*::after {
  box-sizing: border-box;
}

/* A `display` rule in a component outranks the hidden attribute, which
   would leave panels we mean to hide (calculator results, country detail
   cards) on screen. Settle it once, here. */
[hidden] {
  display: none !important;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 16px);
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  /* Delays matter as much as durations here: an entrance with a 270ms
     delay and a backwards fill would otherwise hold the element invisible
     for 270ms even with the animation itself reduced to nothing. */
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-delay: 0ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    transition-delay: 0ms !important;
    scroll-behavior: auto !important;
  }
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 1rem;
  line-height: 1.65;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img,
svg,
video {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Headings tighten as they grow: large type needs less leading and a
   little negative tracking to stay optically even with the body copy. */
h1,
h2,
h3,
h4,
h5 {
  margin: 0 0 0.5em;
  font-weight: 700;
  color: var(--text);
  text-wrap: balance;
}

h1 {
  font-size: clamp(2.05rem, 1.35rem + 2.8vw, 3.35rem);
  line-height: 1.1;
  letter-spacing: -0.022em;
}
h2 {
  font-size: clamp(1.6rem, 1.22rem + 1.6vw, 2.35rem);
  line-height: 1.18;
  letter-spacing: -0.018em;
}
h3 {
  font-size: clamp(1.14rem, 1.03rem + 0.45vw, 1.35rem);
  line-height: 1.3;
  letter-spacing: -0.01em;
}
h4 {
  font-size: 1.05rem;
  line-height: 1.35;
  letter-spacing: -0.005em;
}

p {
  margin: 0 0 1rem;
  max-width: var(--measure);
  text-wrap: pretty;
}

/* Centred blocks and tight layouts set their own width. */
.section-head--center p,
.stat p,
.card p,
.step p,
.footer p,
.cta-band p,
.hero p,
.page-hero p,
.form-note,
.field__hint {
  max-width: none;
}

p:last-child {
  margin-bottom: 0;
}

a {
  color: var(--accent);
  text-decoration: none;
  text-underline-offset: 0.2em;
  text-decoration-thickness: 1px;
  transition: color var(--t) var(--ease),
    text-decoration-color var(--t) var(--ease);
}

a:hover {
  color: var(--accent-hover);
}

/* Links inside running text underline on hover so they are findable
   without colour alone carrying the meaning. */
.prose a,
p > a:not(.btn):not(.link-arrow),
li > a:not(.btn):not(.link-arrow):not(.nav__link) {
  text-decoration: underline;
  text-decoration-color: color-mix(in srgb, var(--accent) 35%, transparent);
}

.prose a:hover,
p > a:not(.btn):not(.link-arrow):hover,
li > a:not(.btn):not(.link-arrow):not(.nav__link):hover {
  text-decoration-color: currentColor;
}

ul,
ol {
  margin: 0 0 1rem;
  padding-left: 1.2rem;
}

/* A single focus treatment for the whole site. The ring sits outside the
   element so it stays visible on dark panels and inside scrolling areas. */
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 4px;
}

/* On dark backgrounds the daylight teal would vanish, so the ring switches
   to the lifted one. */
.section--deep :focus-visible,
.hero :focus-visible,
.page-hero :focus-visible,
.cta-band :focus-visible,
.footer :focus-visible,
.topbar :focus-visible {
  outline-color: var(--teal-300);
}

/* --- Layout helpers ---------------------------------------------------- */

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.wrap-narrow {
  max-width: 820px;
}

.section {
  padding-block: clamp(3rem, 2rem + 4vw, 5.5rem);
}

.section--alt {
  background: var(--bg-alt);
}

/* Navy into HLB teal: the brand pairing, used wherever the page goes
   dark, so the two identities read as one. */
.section--deep {
  background: linear-gradient(
    155deg,
    var(--navy-900) 0%,
    var(--navy-800) 48%,
    var(--teal-900) 100%
  );
  color: var(--text-on-dark);
}

.section--deep h1,
.section--deep h2,
.section--deep h3,
.section--deep h4 {
  color: var(--text-on-dark);
}

.section--deep p {
  color: var(--text-on-dark-muted);
}

.section-head {
  max-width: 46rem;
  margin-bottom: clamp(2rem, 1.4rem + 2vw, 3rem);
}

.section-head--center {
  margin-inline: auto;
  text-align: center;
}

.section-head p {
  color: var(--text-muted);
  font-size: 1.05rem;
}

.section--deep .section-head p {
  color: var(--text-on-dark-muted);
}

/* A short label above a heading. No leading rule or dash: the uppercase
   setting and the accent colour already mark it as a label. */
.eyebrow {
  display: block;
  margin-bottom: 0.75rem;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
}

.section--deep .eyebrow,
.hero .eyebrow,
.page-hero .eyebrow {
  color: var(--accent-on-dark);
}

.section-head--center .eyebrow {
  text-align: center;
}

.lede {
  font-size: 1.12rem;
  color: var(--text-muted);
}

.grid {
  display: grid;
  gap: clamp(1rem, 0.7rem + 1vw, 1.75rem);
}

/* A real two-column grid rather than auto-fit, so a four-card section
   lands as 2x2 instead of three across with one orphan underneath. */
.grid--2 {
  grid-template-columns: 1fr;
}

@media (min-width: 760px) {
  .grid--2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
.grid--3 {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr));
}
.grid--4 {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 230px), 1fr));
}

.split {
  display: grid;
  gap: clamp(1.75rem, 1rem + 3vw, 3.5rem);
  align-items: center;
}

@media (min-width: 900px) {
  .split {
    grid-template-columns: 1fr 1fr;
  }
  .split--text-first > :first-child {
    order: -1;
  }
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  left: 50%;
  top: 0;
  transform: translate(-50%, -120%);
  z-index: 200;
  padding: 0.7rem 1.2rem;
  background: var(--primary);
  color: #fff;
  border-radius: 0 0 var(--radius-sm) var(--radius-sm);
  font-weight: 600;
  transition: transform 0.2s var(--ease);
}

.skip-link:focus {
  transform: translate(-50%, 0);
  color: #fff;
}

/* --- Buttons ----------------------------------------------------------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  min-height: 44px; /* comfortable touch target */
  padding: 0.75rem 1.5rem;
  border: 1px solid transparent;
  border-radius: var(--radius-pill);
  font: inherit;
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1.25;
  text-align: center;
  cursor: pointer;
  transition: transform var(--t-fast) var(--ease),
    background-color var(--t) var(--ease), border-color var(--t) var(--ease),
    box-shadow var(--t) var(--ease), color var(--t) var(--ease);
}

/* A 1px rise reads as responsive without the button appearing to jump. */
.btn:hover {
  transform: translateY(-1px);
}

.btn:active {
  transform: translateY(0);
  transition-duration: 60ms;
}

.btn .icon {
  width: 1.1em;
  height: 1.1em;
  flex: none;
}

.btn--primary {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
  box-shadow: var(--shadow-sm);
}

.btn--primary:hover {
  background: var(--primary-hover);
  border-color: var(--primary-hover);
  color: #fff;
  box-shadow: var(--shadow);
}

.btn--gold {
  background: var(--gold-500);
  border-color: var(--gold-500);
  color: #2a1f00;
  box-shadow: 0 8px 22px -8px rgba(212, 175, 55, 0.6);
}

.btn--gold:hover {
  background: var(--gold-400);
  border-color: var(--gold-400);
  color: #2a1f00;
}

.btn--ghost {
  background: transparent;
  border-color: var(--border-strong);
  color: var(--text);
}

.btn--ghost:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-tint);
}

.btn--on-dark {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.4);
  color: #fff;
  backdrop-filter: blur(6px);
}

.btn--on-dark:hover {
  background: rgba(255, 255, 255, 0.2);
  border-color: #fff;
  color: #fff;
}

.btn--block {
  width: 100%;
}

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.5rem;
}

.btn-row--center {
  justify-content: center;
}

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-weight: 600;
  font-size: 0.95rem;
}

.link-arrow .icon {
  width: 1em;
  height: 1em;
  transition: transform 0.2s var(--ease);
}

.link-arrow:hover .icon {
  transform: translateX(4px);
}

[dir="rtl"] .link-arrow:hover .icon {
  transform: translateX(-4px);
}

/* --- Icons ------------------------------------------------------------- */

.icon {
  width: 1.25rem;
  height: 1.25rem;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex: none;
}

.icon-badge {
  display: inline-grid;
  place-items: center;
  width: 3rem;
  height: 3rem;
  border-radius: var(--radius);
  background: var(--accent-tint);
  color: var(--accent);
  margin-bottom: 1.1rem;
  transition: background-color var(--t) var(--ease), color var(--t) var(--ease);
}

.icon-badge .icon {
  width: 1.45rem;
  height: 1.45rem;
}

.icon-badge--gold {
  background: rgba(212, 175, 55, 0.16);
  color: var(--gold-600);
}

.section--deep .icon-badge {
  background: rgba(255, 255, 255, 0.12);
  color: var(--accent-on-dark);
}

/* --- Top bar ----------------------------------------------------------- */

.topbar {
  background: var(--navy-900);
  color: var(--text-on-dark-muted);
  font-size: 0.82rem;
}

.topbar__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 40px;
  flex-wrap: wrap;
}

.topbar a {
  color: var(--text-on-dark-muted);
}

.topbar a:hover {
  color: #fff;
}

.topbar__contact {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  flex-wrap: wrap;
}

.topbar__contact a,
.topbar__hours {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  white-space: nowrap;
}

.topbar__contact .icon {
  width: 0.95rem;
  height: 0.95rem;
  color: var(--accent-on-dark);
}

.topbar__right {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.social-link {
  display: inline-grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  color: var(--text-on-dark-muted);
  transition: background-color 0.2s var(--ease), color 0.2s var(--ease);
}

.social-link:hover {
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
}

.social-link .icon {
  width: 1rem;
  height: 1rem;
}

@media (max-width: 860px) {
  .topbar__inner {
    justify-content: center;
    gap: 0.5rem;
  }
  /* Keep the strip to a single line: email plus the social icons. */
  .topbar__contact a:not(:first-child),
  .topbar__hours {
    display: none;
  }
}

/* --- Header / nav ------------------------------------------------------ */

.header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid var(--border);
  transition: box-shadow 0.25s var(--ease);
}

.header.is-stuck {
  box-shadow: var(--shadow-sm);
}

.header__inner {
  display: flex;
  align-items: center;
  gap: 1rem;
  min-height: var(--header-h);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  flex: none;
  margin-inline-end: auto;
}

.brand img {
  height: 46px;
  width: auto;
}

/* The logo is the wordmark, so the lockup only adds the parent-firm line
   beside it rather than repeating the name as text. */
.brand__text {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding-inline-start: 0.7rem;
  border-inline-start: 1px solid var(--border);
  line-height: 1.2;
}

.brand__sub {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--text-muted);
  max-width: 7ch;
}

/* The wordmark's navy reads as grey on a dark background. */
:root[data-theme="dark"] .brand img {
  filter: brightness(0) invert(1);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .brand img {
    filter: brightness(0) invert(1);
  }
}

.nav {
  display: flex;
  align-items: center;
}

.nav__list {
  display: flex;
  align-items: center;
  gap: 0.15rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.nav__item {
  position: relative;
  list-style: none;
}

.nav__link {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.6rem 0.75rem;
  border-radius: var(--radius-sm);
  font-size: 0.93rem;
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
  background: none;
  border: 0;
  font-family: inherit;
  cursor: pointer;
}

.nav__link:hover {
  color: var(--primary);
  background: var(--bg-alt);
}

.nav__link[aria-current="page"] {
  color: var(--primary);
}

.nav__link[aria-current="page"]::after {
  content: "";
  position: absolute;
  left: 0.75rem;
  right: 0.75rem;
  bottom: 0.2rem;
  height: 2px;
  background: var(--accent);
  border-radius: 2px;
}

.nav__caret {
  width: 0.7rem;
  height: 0.7rem;
  transition: transform 0.2s var(--ease);
}

.nav__item--open > .nav__link .nav__caret {
  transform: rotate(180deg);
}

/* Dropdown + mega panel */
.nav__panel {
  position: absolute;
  top: calc(100% + 10px);
  left: 0;
  min-width: 270px;
  padding: 0.6rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-6px);
  transition: opacity 0.18s var(--ease), transform 0.18s var(--ease),
    visibility 0.18s var(--ease);
}

.nav__item--open > .nav__panel {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.nav__panel--mega {
  width: min(680px, calc(100vw - 2 * var(--gutter)));
  left: 50%;
  transform: translate(-50%, -6px);
}

.nav__item--open > .nav__panel--mega {
  transform: translate(-50%, 0);
}

.nav__panel-link {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.6rem 0.7rem;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text);
}

.nav__panel-link:hover {
  background: var(--bg-alt);
  color: var(--primary);
}

.nav__panel-link .icon {
  width: 1.1rem;
  height: 1.1rem;
  color: var(--primary);
}

.nav__panel-group {
  margin-top: 0.4rem;
  padding-top: 0.5rem;
  border-top: 1px solid var(--border);
}

.nav__panel-label {
  padding: 0.35rem 0.7rem;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.mega__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.3rem 0.7rem 0.7rem;
  border-bottom: 1px solid var(--border);
  margin-bottom: 0.6rem;
}

.mega__title {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.mega__count {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--primary);
}

.mega__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 0.15rem;
}

.mega__link {
  display: block;
  padding: 0.45rem 0.7rem;
  border-radius: var(--radius-sm);
  font-size: 0.87rem;
  font-weight: 500;
  color: var(--text);
}

.mega__link:hover {
  background: var(--bg-alt);
  color: var(--primary);
}

.mega__foot {
  margin-top: 0.6rem;
  padding: 0.6rem 0.7rem 0.2rem;
  border-top: 1px solid var(--border);
}

/* Header actions */
.header__actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex: none;
}

.icon-btn {
  display: inline-grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--text);
  cursor: pointer;
  transition: border-color 0.2s var(--ease), color 0.2s var(--ease),
    background-color 0.2s var(--ease);
}

.icon-btn:hover {
  border-color: var(--primary);
  color: var(--primary);
}

.theme-toggle .icon-moon {
  display: none;
}

:root[data-theme="dark"] .theme-toggle .icon-sun,
.theme-toggle .icon-sun {
  display: block;
}

:root[data-theme="dark"] .theme-toggle .icon-sun {
  display: none;
}

:root[data-theme="dark"] .theme-toggle .icon-moon {
  display: block;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .theme-toggle .icon-sun {
    display: none;
  }
  :root:not([data-theme="light"]) .theme-toggle .icon-moon {
    display: block;
  }
}

/* Language switcher */
.lang {
  position: relative;
}

.lang__current {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.5rem 0.7rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--text);
  font: inherit;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
}

.lang__current:hover {
  border-color: var(--primary);
}

.lang__flag img {
  width: 20px;
  height: 15px;
  border-radius: 2px;
  object-fit: cover;
}

.lang__menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 215px;
  padding: 0.45rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-6px);
  transition: opacity 0.18s var(--ease), transform 0.18s var(--ease),
    visibility 0.18s var(--ease);
}

.lang.is-open .lang__menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.lang__head {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.6rem 0.6rem;
  border-bottom: 1px solid var(--border);
  margin-bottom: 0.35rem;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.lang__option {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.5rem 0.6rem;
  border-radius: var(--radius-sm);
  color: var(--text);
  font-size: 0.9rem;
}

.lang__option:hover {
  background: var(--bg-alt);
}

.lang__names {
  display: flex;
  flex-direction: column;
  line-height: 1.25;
  margin-inline-end: auto;
}

.lang__native {
  font-weight: 600;
}

.lang__local {
  font-size: 0.72rem;
  color: var(--text-muted);
}

.lang__check {
  width: 1rem;
  height: 1rem;
  color: var(--ok);
}

/* Login dropdown */
.portal__menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  width: 290px;
  padding: 0.85rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-6px);
  transition: opacity 0.18s var(--ease), transform 0.18s var(--ease),
    visibility 0.18s var(--ease);
}

.portal.is-open .portal__menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.portal__head {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 0.6rem;
}

.portal__item {
  display: flex;
  align-items: flex-start;
  gap: 0.7rem;
  padding: 0.65rem;
  border-radius: var(--radius-sm);
  color: var(--text);
}

.portal__item:hover {
  background: var(--bg-alt);
}

.portal__item .icon {
  width: 1.2rem;
  height: 1.2rem;
  margin-top: 0.15rem;
  color: var(--primary);
}

.portal__item strong {
  display: block;
  font-size: 0.92rem;
}

.portal__item span {
  font-size: 0.78rem;
  color: var(--text-muted);
}

/* Mobile nav */
.nav-toggle {
  display: none;
}

@media (max-width: 1079px) {
  /* backdrop-filter makes an element the containing block for its
     position:fixed descendants, which would clip the drawer to the height
     of the header bar. The glass effect is a desktop nicety; drop it here
     so the drawer can size itself against the viewport. */
  .header {
    backdrop-filter: none;
    background: var(--bg);
  }

  .nav-toggle {
    display: inline-grid;
  }

  .nav {
    position: fixed;
    inset: 0 0 0 auto;
    width: min(380px, 86vw);
    flex-direction: column;
    align-items: stretch;
    padding: 1rem 1rem 3rem;
    background: var(--surface);
    border-left: 1px solid var(--border);
    box-shadow: var(--shadow-lg);
    overflow-y: auto;
    transform: translateX(100%);
    transition: transform 0.28s var(--ease);
    z-index: 120;
  }

  .nav__list {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
  }

  [dir="rtl"] .nav {
    inset: 0 auto 0 0;
    border-left: 0;
    border-right: 1px solid var(--border);
    transform: translateX(-100%);
  }

  .nav.is-open {
    transform: translateX(0);
  }

  .nav__close {
    align-self: flex-end;
    margin-bottom: 0.5rem;
  }

  .nav__link {
    width: 100%;
    justify-content: space-between;
    padding: 0.85rem 0.6rem;
    font-size: 1rem;
    border-bottom: 1px solid var(--border);
    border-radius: 0;
  }

  .nav__link[aria-current="page"]::after {
    display: none;
  }

  .nav__panel,
  .nav__panel--mega {
    position: static;
    width: auto;
    min-width: 0;
    opacity: 1;
    visibility: visible;
    transform: none;
    border: 0;
    box-shadow: none;
    background: var(--bg-alt);
    border-radius: var(--radius-sm);
    margin: 0.4rem 0;
    padding: 0.4rem;
    display: none;
  }

  .nav__item--open > .nav__panel,
  .nav__item--open > .nav__panel--mega {
    display: block;
    transform: none;
  }

  .nav__panel--mega {
    left: auto;
  }

  .mega__grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .nav-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(6, 14, 24, 0.5);
    backdrop-filter: blur(2px);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s var(--ease), visibility 0.25s var(--ease);
    z-index: 110;
  }

  .nav-backdrop.is-open {
    opacity: 1;
    visibility: visible;
  }
}

@media (min-width: 1080px) {
  .nav__close {
    display: none;
  }
}

/* The header has to fit brand + language + login + theme + menu on a phone.
   Below each breakpoint the least essential label is the one that goes, so
   the menu toggle is never pushed off the edge. */
@media (max-width: 900px) {
  .header__actions {
    gap: 0.35rem;
  }
  /* "Employee Login" collapses to its padlock. */
  .portal > .btn {
    padding: 0;
    width: 40px;
    height: 40px;
    border-radius: var(--radius-sm);
  }
  .portal > .btn > span {
    display: none;
  }
  .portal > .btn .icon {
    width: 1.2em;
    height: 1.2em;
  }
}

@media (max-width: 640px) {
  .brand__text {
    display: none;
  }
  .lang__current {
    padding: 0.5rem;
  }
  .lang__current .lang__name,
  .lang__current .nav__caret {
    display: none;
  }
}

@media (max-width: 400px) {
  .brand img {
    height: 36px;
  }
  .theme-toggle {
    display: none;
  }
}

/* --- Hero -------------------------------------------------------------- */

.hero {
  position: relative;
  display: grid;
  align-items: center;
  min-height: clamp(460px, 62vh, 660px);
  padding-block: clamp(3rem, 2rem + 5vw, 6rem);
  color: var(--text-on-dark);
  isolation: isolate;
  overflow: hidden;
}

.hero__slide {
  position: absolute;
  inset: 0;
  z-index: -2;
  opacity: 0;
  transition: opacity 0.9s var(--ease);
}

.hero__slide.is-active {
  opacity: 1;
}

.hero__slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(
    100deg,
    rgba(8, 22, 38, 0.93) 0%,
    rgba(15, 59, 104, 0.84) 46%,
    rgba(0, 90, 119, 0.58) 100%
  );
}

.hero__content {
  position: relative;
  max-width: 660px;
}

.hero h1,
.hero h2 {
  color: #fff;
  /* Later slides use h2 so the page has a single h1; they must still read
     as the same headline. */
  font-size: clamp(2rem, 1.3rem + 2.8vw, 3.4rem);
}

.hero p {
  font-size: clamp(1.02rem, 0.96rem + 0.4vw, 1.22rem);
  color: rgba(255, 255, 255, 0.88);
  max-width: 52ch;
}

.hero__panel {
  display: none;
}

/* The first slide paints immediately: it carries the <h1> and is the
   largest element on the page, so fading it in from opacity 0 would just
   delay the headline. Only slides the rotator switches to get the
   animation, applied by site.js as .is-entering. */
.hero__panel.is-active {
  display: block;
}

.hero__panel.is-entering {
  animation: fade-up 0.6s var(--ease);
}

@keyframes fade-up {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero__dot {
  position: relative;
  width: 44px;
  height: 4px;
  padding: 0;
  border: 0;
  border-radius: 2px;
  background: rgba(255, 255, 255, 0.3);
  cursor: pointer;
  overflow: hidden;
  transition: background-color var(--t) var(--ease);
}

/* The fill is a scaled child rather than a change of width: scaling runs
   on the compositor, where changing width would re-lay-out the strip and
   shove the neighbouring dots sideways every time the slide advanced. */
.hero__dot::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: var(--gold-500);
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform var(--t-slow) var(--ease-out);
}

[dir="rtl"] .hero__dot::after {
  transform-origin: right center;
}

.hero__dot[aria-selected="true"]::after {
  transform: scaleX(1);
}

.hero__dot:hover {
  background: rgba(255, 255, 255, 0.5);
}

.hero__trust {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.75rem;
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.18);
}

.hero__trust-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.85);
}

.hero__trust-item .icon {
  width: 1.05rem;
  height: 1.05rem;
  color: var(--accent-on-dark);
}

/* Page hero (inner pages) */
.page-hero {
  position: relative;
  padding-block: clamp(2.75rem, 2rem + 4vw, 5rem);
  color: var(--text-on-dark);
  background: linear-gradient(150deg, var(--navy-900), var(--navy-800));
  isolation: isolate;
  overflow: hidden;
}

.page-hero__bg {
  position: absolute;
  inset: 0;
  z-index: -2;
}

.page-hero__bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.page-hero__bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    110deg,
    rgba(8, 22, 38, 0.94) 0%,
    rgba(15, 59, 104, 0.87) 52%,
    rgba(0, 90, 119, 0.64) 100%
  );
}

.page-hero h1 {
  color: #fff;
  max-width: 24ch;
}

.page-hero p {
  color: rgba(255, 255, 255, 0.85);
  max-width: 62ch;
  font-size: 1.08rem;
}

/* Default colours are for a light background (the team bios put the
   breadcrumb in an ordinary section); the hero overrides them below. */
.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem;
  margin: 0 0 1.1rem;
  padding: 0;
  list-style: none;
  font-size: 0.82rem;
  color: var(--text-muted);
}

.breadcrumb a {
  color: var(--text-muted);
  font-weight: 600;
}

.breadcrumb a:hover {
  color: var(--primary);
}

.breadcrumb li + li::before {
  content: "/";
  margin-inline-end: 0.4rem;
  opacity: 0.5;
}

.breadcrumb [aria-current="page"] {
  color: var(--text);
  font-weight: 600;
}

.page-hero .breadcrumb {
  color: rgba(255, 255, 255, 0.7);
}

.page-hero .breadcrumb a {
  color: rgba(255, 255, 255, 0.82);
}

.page-hero .breadcrumb a:hover {
  color: #fff;
}

.page-hero .breadcrumb [aria-current="page"] {
  color: var(--accent-on-dark);
}

/* --- Cards ------------------------------------------------------------- */

.card {
  display: flex;
  flex-direction: column;
  padding: clamp(1.4rem, 1.1rem + 0.8vw, 2rem);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  transition: transform var(--t) var(--ease), box-shadow var(--t) var(--ease),
    border-color var(--t) var(--ease);
}

.card--link:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
  border-color: var(--accent);
}

/* The badge fills in as the card is picked up, so the whole tile reacts
   as one object rather than the border alone. */
.card--link:hover .icon-badge {
  background: var(--accent);
  color: #fff;
}

/* On a dark panel the accent is the lifted teal, which would not carry
   white text, so the badge brightens instead of inverting. */
.section--deep .card--link:hover .icon-badge,
.cta-band .card--link:hover .icon-badge {
  background: rgba(63, 195, 214, 0.22);
  color: var(--accent-on-dark);
}

:root[data-theme="dark"] .card--link:hover .icon-badge {
  background: rgba(63, 195, 214, 0.2);
  color: var(--accent);
}

.card h3 {
  margin-bottom: 0.5rem;
}

.card p {
  color: var(--text-muted);
  font-size: 0.95rem;
}

.card__foot {
  margin-top: auto;
  padding-top: 1.1rem;
}

.section--deep .card {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.14);
  box-shadow: none;
}

.section--deep .card p {
  color: var(--text-on-dark-muted);
}

/* Compact list card (payroll services) */
.tick-list {
  display: grid;
  gap: 0.75rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.tick-list li {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 0.9rem 1.1rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 0.95rem;
  box-shadow: var(--shadow-sm);
}

.tick-list .icon {
  width: 1.15rem;
  height: 1.15rem;
  margin-top: 0.15rem;
  color: var(--ok);
}

/* Feature list with icon + text */
.feature-list {
  display: grid;
  gap: 1.25rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.feature-list > li {
  display: flex;
  gap: 1rem;
}

.feature-list .icon-badge {
  margin-bottom: 0;
  width: 2.6rem;
  height: 2.6rem;
  border-radius: var(--radius-sm);
}

.feature-list .icon-badge .icon {
  width: 1.2rem;
  height: 1.2rem;
}

.feature-list h3 {
  font-size: 1.02rem;
  margin-bottom: 0.25rem;
}

.feature-list p {
  font-size: 0.93rem;
  color: var(--text-muted);
}

/* Pills */
.pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.pill {
  padding: 0.45rem 1rem;
  border-radius: var(--radius-pill);
  background: var(--navy-100);
  color: var(--primary);
  font-size: 0.85rem;
  font-weight: 600;
}

.section--deep .pill {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
}

/* --- Stats ------------------------------------------------------------- */

.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 170px), 1fr));
  gap: clamp(1rem, 0.7rem + 1vw, 1.75rem);
}

.stat {
  text-align: center;
  padding: clamp(1.25rem, 1rem + 0.8vw, 1.9rem) 1rem;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: var(--radius-lg);
}

.stat__value {
  display: block;
  font-size: clamp(2.1rem, 1.6rem + 2vw, 3.1rem);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.03em;
  color: #fff;
  font-variant-numeric: tabular-nums;
}

.stat__suffix {
  color: var(--gold-500);
}

.stat__label {
  display: block;
  margin-top: 0.6rem;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.75);
}

/* --- Process timeline -------------------------------------------------- */

.steps {
  display: grid;
  gap: clamp(1rem, 0.7rem + 1vw, 1.5rem);
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 270px), 1fr));
  counter-reset: step;
  margin: 0;
  padding: 0;
  list-style: none;
}

.step {
  position: relative;
  padding: 1.6rem 1.4rem 1.4rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease);
}

.step:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
  border-color: var(--accent);
}

.step__n {
  position: absolute;
  top: -0.9rem;
  inset-inline-start: 1.4rem;
  display: grid;
  place-items: center;
  width: 2.2rem;
  height: 2.2rem;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
  font-size: 0.9rem;
  font-weight: 700;
  box-shadow: 0 4px 12px -4px rgba(10, 40, 70, 0.45);
  transition: background-color var(--t) var(--ease);
}

.step:hover .step__n {
  background: var(--accent);
}

.step h3 {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  margin: 0.6rem 0 0.5rem;
  font-size: 1.05rem;
}

.step h3 .icon {
  width: 1.15rem;
  height: 1.15rem;
  color: var(--accent);
}

.step p {
  font-size: 0.93rem;
  color: var(--text-muted);
}

/* --- Team -------------------------------------------------------------- */

.person {
  overflow: hidden;
  padding: 0;
}

/* The team portraits are cut-outs on white with a lot of headroom, so they
   are framed from the top rather than the centre and sit on a tinted panel
   that reads as intentional where the cut-out is transparent. */
.person__photo {
  position: relative;
  aspect-ratio: 4 / 3;
  background: linear-gradient(180deg, var(--navy-100), var(--surface-2));
  overflow: hidden;
}

.person__photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 12%;
  mix-blend-mode: multiply;
  transition: transform 0.45s var(--ease);
}

:root[data-theme="dark"] .person__photo img,
.bio-header__photo img {
  mix-blend-mode: normal;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .person__photo img {
    mix-blend-mode: normal;
  }
}

.person:hover .person__photo img {
  transform: scale(1.05);
}

.person__body {
  padding: 1.3rem 1.4rem 1.5rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.person__name {
  margin-bottom: 0.15rem;
  font-size: 1.1rem;
}

.person__role {
  display: block;
  margin-bottom: 0.7rem;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
}

.person__body p {
  font-size: 0.92rem;
}

/* Bio page */
.bio-header {
  display: grid;
  gap: clamp(1.5rem, 1rem + 2vw, 3rem);
  align-items: center;
}

@media (min-width: 820px) {
  .bio-header {
    grid-template-columns: 300px 1fr;
  }
}

/* `contain` on the large portrait so the full cut-out is shown rather than
   cropped at the chest. */
.bio-header__photo {
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow);
  aspect-ratio: 1;
  background: linear-gradient(180deg, var(--navy-100), var(--surface-2));
}

.bio-header__photo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center bottom;
}

.bio-section {
  padding-block: clamp(2rem, 1.5rem + 2vw, 3.25rem);
  border-top: 1px solid var(--border);
}

.bio-section:first-of-type {
  border-top: 0;
}

/* --- FAQ (accordion) --------------------------------------------------- */

.faq {
  display: grid;
  gap: 0.75rem;
  max-width: 860px;
  margin-inline: auto;
}

.faq__item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  transition: border-color 0.2s var(--ease);
}

.faq__item[open] {
  border-color: var(--navy-400);
}

.faq__q {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1.1rem 1.3rem;
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  list-style: none;
  color: var(--text);
}

.faq__q::-webkit-details-marker {
  display: none;
}

.faq__q:hover {
  color: var(--primary);
}

.faq__q .icon {
  margin-inline-start: auto;
  width: 1.1rem;
  height: 1.1rem;
  color: var(--primary);
  transition: transform 0.25s var(--ease);
}

.faq__item[open] .faq__q .icon {
  transform: rotate(45deg);
}

.faq__a {
  padding: 0 1.3rem 1.3rem;
  color: var(--text-muted);
  font-size: 0.95rem;
}

/* --- Testimonials ------------------------------------------------------ */

.quote {
  position: relative;
  padding: 2.2rem 1.6rem 1.6rem;
}

.quote::before {
  content: "\201C";
  position: absolute;
  top: 0.35rem;
  inset-inline-start: 1.3rem;
  font-size: 4.5rem;
  line-height: 1;
  font-family: Georgia, "Times New Roman", serif;
  color: var(--accent);
  opacity: 0.55;
}

.quote p {
  position: relative;
  font-size: 0.98rem;
  color: var(--text);
}

.quote__who {
  margin-top: 1.2rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
}

.quote__name {
  display: block;
  font-weight: 700;
  font-size: 0.95rem;
}

.quote__role {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* --- Countries --------------------------------------------------------- */

#map {
  height: clamp(300px, 46vh, 480px);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  z-index: 1;
  background: var(--bg-alt);
}

.leaflet-container {
  font-family: var(--font);
  border-radius: var(--radius-lg);
}

.country-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: center;
  margin-bottom: 1.5rem;
}

.search {
  position: relative;
  flex: 1 1 260px;
  max-width: 380px;
}

.search .icon {
  position: absolute;
  inset-inline-start: 0.9rem;
  top: 50%;
  transform: translateY(-50%);
  width: 1.1rem;
  height: 1.1rem;
  color: var(--text-muted);
  pointer-events: none;
}

.search input {
  width: 100%;
  padding: 0.75rem 1rem 0.75rem 2.6rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  background: var(--surface);
  color: var(--text);
  font: inherit;
  font-size: 0.93rem;
}

[dir="rtl"] .search input {
  padding: 0.75rem 2.6rem 0.75rem 1rem;
}

.search input:focus {
  border-color: var(--primary);
  outline: none;
  box-shadow: 0 0 0 3px rgba(15, 59, 104, 0.14);
}

.country-count {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-weight: 600;
}

.country-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 190px), 1fr));
  gap: 0.85rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.country-btn {
  display: flex;
  align-items: flex-end;
  width: 100%;
  min-height: 118px;
  padding: 0.85rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--text);
  font: inherit;
  font-size: 0.93rem;
  font-weight: 700;
  text-align: start;
  cursor: pointer;
  overflow: hidden;
  position: relative;
  isolation: isolate;
  transition: transform var(--t) var(--ease), box-shadow var(--t) var(--ease),
    border-color var(--t) var(--ease);
}

.country-btn img {
  position: absolute;
  inset: 0;
  z-index: -2;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.45s var(--ease);
}

.country-btn::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(
    to top,
    rgba(6, 18, 32, 0.9) 0%,
    rgba(6, 18, 32, 0.45) 55%,
    rgba(6, 18, 32, 0.2) 100%
  );
  transition: background 0.3s var(--ease);
}

.country-btn > span {
  color: #fff;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.6);
}

.country-btn:hover,
.country-btn[aria-pressed="true"] {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
  border-color: var(--accent-bright);
}

.country-btn:hover img {
  transform: scale(1.07);
}

.country-btn[aria-pressed="true"]::after {
  background: linear-gradient(
    to top,
    rgba(15, 59, 104, 0.95) 0%,
    rgba(15, 59, 104, 0.6) 100%
  );
}

.country-btn[hidden] {
  display: none;
}

/* Country detail panel */
.country-detail {
  margin-top: clamp(1.5rem, 1rem + 2vw, 2.5rem);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--surface);
  box-shadow: var(--shadow);
  scroll-margin-top: calc(var(--header-h) + 20px);
}

.country-detail__media {
  position: relative;
  aspect-ratio: 21 / 7;
  background: var(--navy-100);
}

.country-detail__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.country-detail__media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(6, 18, 32, 0.9), rgba(6, 18, 32, 0.12));
}

.country-detail__title {
  position: absolute;
  inset-inline-start: clamp(1.1rem, 2.5vw, 2.2rem);
  bottom: clamp(0.9rem, 2vw, 1.6rem);
  z-index: 1;
  margin: 0;
  color: #fff;
  font-size: clamp(1.25rem, 1rem + 1.4vw, 2rem);
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

.country-detail__body {
  padding: clamp(1.25rem, 1rem + 1.5vw, 2.2rem);
  display: grid;
  gap: clamp(1.25rem, 1rem + 1.5vw, 2rem);
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr));
}

.country-detail__empty {
  padding: clamp(1.5rem, 1.2rem + 1.5vw, 2.5rem);
  text-align: center;
  color: var(--text-muted);
}

.detail-group h3 {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.9rem;
  padding-bottom: 0.6rem;
  border-bottom: 2px solid var(--accent);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--primary);
}

.detail-rows {
  display: grid;
  gap: 0.1rem;
  margin: 0;
}

.detail-row {
  display: grid;
  grid-template-columns: minmax(110px, 38%) 1fr;
  gap: 0.6rem;
  padding: 0.6rem 0;
  border-bottom: 1px dashed var(--border);
  font-size: 0.89rem;
}

.detail-row:last-child {
  border-bottom: 0;
}

.detail-row dt {
  font-weight: 600;
  color: var(--text-muted);
}

.detail-row dd {
  margin: 0;
  font-weight: 500;
}

.detail-row dd ul {
  margin: 0;
  padding-inline-start: 1rem;
}

/* --- Insights ---------------------------------------------------------- */

.post {
  overflow: hidden;
  padding: 0;
}

.post__media {
  aspect-ratio: 16 / 9;
  background: var(--navy-100);
  overflow: hidden;
}

.post__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.45s var(--ease);
}

.post:hover .post__media img {
  transform: scale(1.04);
}

.post__body {
  padding: 1.3rem 1.4rem 1.5rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.post__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.7rem;
  font-size: 0.76rem;
  font-weight: 600;
  color: var(--text-muted);
}

.tag {
  padding: 0.2rem 0.6rem;
  border-radius: var(--radius-pill);
  background: var(--navy-100);
  color: var(--primary);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.post__title {
  font-size: 1.05rem;
  margin-bottom: 0.5rem;
}

.post--featured {
  display: grid;
  gap: 0;
}

@media (min-width: 860px) {
  .post--featured {
    grid-template-columns: 1.15fr 1fr;
  }
  .post--featured .post__media {
    aspect-ratio: auto;
    height: 100%;
  }
  .post--featured .post__body {
    padding: clamp(1.5rem, 1.2rem + 1.5vw, 2.5rem);
    justify-content: center;
  }
}

.empty-state {
  padding: clamp(2rem, 1.5rem + 2vw, 3.5rem);
  text-align: center;
  color: var(--text-muted);
  background: var(--surface);
  border: 1px dashed var(--border-strong);
  border-radius: var(--radius-lg);
}

.empty-state .icon {
  width: 2.2rem;
  height: 2.2rem;
  margin-bottom: 0.9rem;
  color: var(--border-strong);
}

/* --- Forms ------------------------------------------------------------- */

.form {
  display: grid;
  gap: 1.1rem;
}

.form-row {
  display: grid;
  gap: 1.1rem;
}

@media (min-width: 620px) {
  .form-row--2 {
    grid-template-columns: 1fr 1fr;
  }
}

.field label,
.field > .field__label {
  display: block;
  margin-bottom: 0.4rem;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text);
}

.field .req {
  color: #c0392b;
}

.field input,
.field select,
.field textarea {
  width: 100%;
  padding: 0.8rem 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--text);
  font: inherit;
  font-size: 0.95rem;
  transition: border-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}

.field select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%235a6b84' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.9rem center;
  background-size: 1.1rem;
  padding-inline-end: 2.6rem;
}

[dir="rtl"] .field select {
  background-position: left 0.9rem center;
}

.field textarea {
  min-height: 150px;
  resize: vertical;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  border-color: var(--primary);
  outline: none;
  box-shadow: 0 0 0 3px rgba(15, 59, 104, 0.14);
}

.field input:user-invalid,
.field textarea:user-invalid {
  border-color: #c0392b;
}

.field__hint {
  margin-top: 0.35rem;
  font-size: 0.78rem;
  color: var(--text-muted);
}

.form-note {
  display: flex;
  gap: 0.6rem;
  padding: 0.9rem 1.1rem;
  border-radius: var(--radius-sm);
  background: var(--bg-alt);
  border: 1px solid var(--border);
  font-size: 0.85rem;
  color: var(--text-muted);
}

.form-note .icon {
  width: 1.1rem;
  height: 1.1rem;
  flex: none;
  margin-top: 0.1rem;
  color: var(--primary);
}

.alert {
  display: flex;
  gap: 0.7rem;
  padding: 1rem 1.2rem;
  border-radius: var(--radius-sm);
  font-size: 0.92rem;
  font-weight: 500;
}

.alert .icon {
  flex: none;
  margin-top: 0.1rem;
}

.alert--ok {
  background: rgba(30, 126, 77, 0.1);
  border: 1px solid rgba(30, 126, 77, 0.35);
  color: var(--ok);
}

.alert[hidden] {
  display: none;
}

/* --- Contact details --------------------------------------------------- */

.contact-list {
  display: grid;
  gap: 1.1rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.contact-list > li {
  display: flex;
  gap: 0.9rem;
  align-items: flex-start;
}

.contact-list .icon-badge {
  margin-bottom: 0;
  width: 2.6rem;
  height: 2.6rem;
  border-radius: var(--radius-sm);
}

.contact-list dt {
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 0.15rem;
}

.contact-list dd {
  margin: 0;
  font-weight: 600;
  font-size: 0.97rem;
}

/* --- Calculator -------------------------------------------------------- */

.calc {
  display: grid;
  gap: clamp(1.5rem, 1rem + 2vw, 2.5rem);
  align-items: start;
}

@media (min-width: 960px) {
  .calc {
    grid-template-columns: minmax(0, 420px) 1fr;
  }
}

.calc__results {
  display: grid;
  gap: 0.85rem;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr));
}

.calc-stat {
  padding: 1.1rem 1.2rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}

.calc-stat__label {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.calc-stat__label .icon {
  width: 1rem;
  height: 1rem;
  color: var(--primary);
}

.calc-stat__value {
  display: block;
  margin-top: 0.5rem;
  font-size: 1.55rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
}

.calc-stat__value small {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--text-muted);
  margin-inline-start: 0.3rem;
}

.calc-stat--highlight {
  background: linear-gradient(150deg, var(--navy-800), var(--navy-700));
  border-color: transparent;
}

.calc-stat--highlight .calc-stat__label,
.calc-stat--highlight .calc-stat__label .icon {
  color: var(--accent-on-dark);
}

.calc-stat--highlight .calc-stat__value {
  color: #fff;
}

.calc-stat--highlight .calc-stat__value small {
  color: rgba(255, 255, 255, 0.7);
}

.calc__placeholder {
  display: grid;
  place-items: center;
  min-height: 240px;
  padding: 2rem;
  text-align: center;
  color: var(--text-muted);
  background: var(--surface-2);
  border: 1px dashed var(--border-strong);
  border-radius: var(--radius-lg);
}

.calc__placeholder .icon {
  width: 2.4rem;
  height: 2.4rem;
  margin-bottom: 0.8rem;
  color: var(--border-strong);
}

.badge-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 2rem;
}

.badge {
  padding: 0.7rem 1.1rem;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  text-align: center;
  min-width: 100px;
}

.badge strong {
  display: block;
  font-size: 1.05rem;
  color: #fff;
}

.badge span {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent-on-dark);
}

/* --- CTA band ---------------------------------------------------------- */

.cta-band {
  position: relative;
  padding-block: clamp(2.5rem, 2rem + 3vw, 4.5rem);
  background: linear-gradient(
    115deg,
    var(--navy-900) 0%,
    var(--navy-800) 55%,
    var(--teal-900) 100%
  );
  color: #fff;
  overflow: hidden;
  isolation: isolate;
}

.cta-band::before {
  content: "";
  position: absolute;
  inset-block: -40%;
  inset-inline-end: -10%;
  width: 55%;
  z-index: -1;
  background: radial-gradient(
    circle at center,
    rgba(63, 195, 214, 0.22),
    transparent 68%
  );
}

.cta-band h2 {
  color: #fff;
}

.cta-band p {
  color: rgba(255, 255, 255, 0.85);
  max-width: 58ch;
}

.cta-band__inner {
  display: flex;
  flex-wrap: wrap;
  gap: 1.75rem;
  align-items: center;
  justify-content: space-between;
}

.cta-band__text {
  max-width: 620px;
}

.cta-band .btn-row {
  margin-top: 0;
}

/* --- Footer ------------------------------------------------------------ */

.footer {
  background: var(--navy-900);
  color: var(--text-on-dark-muted);
  font-size: 0.92rem;
}

.footer a {
  color: var(--text-on-dark-muted);
}

.footer a:hover {
  color: #fff;
}

.footer__cards {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
  padding-block: clamp(2rem, 1.5rem + 2vw, 3rem);
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.footer-card {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
  padding: 1.4rem 1.5rem;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-lg);
  transition: background-color var(--t) var(--ease),
    border-color var(--t) var(--ease), transform var(--t) var(--ease);
}

.footer-card:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(63, 195, 214, 0.5);
  transform: translateY(-2px);
}

.footer-card .icon-badge {
  margin-bottom: 0;
  width: 2.8rem;
  height: 2.8rem;
  border-radius: var(--radius-sm);
  background: rgba(63, 195, 214, 0.16);
  color: var(--accent-on-dark);
}

.footer-card h3 {
  margin-bottom: 0.3rem;
  font-size: 1.02rem;
  color: #fff;
}

.footer-card p {
  margin-bottom: 0.7rem;
  font-size: 0.88rem;
  color: var(--text-on-dark-muted);
}

.footer__main {
  display: grid;
  gap: clamp(1.75rem, 1.2rem + 2vw, 3rem);
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 210px), 1fr));
  padding-block: clamp(2.25rem, 1.75rem + 2vw, 3.5rem);
}

.footer__brand {
  grid-column: span 1;
  max-width: 340px;
}

@media (min-width: 900px) {
  .footer__main {
    grid-template-columns: 1.5fr 1fr 1fr 1.2fr;
  }
}

.footer__logo {
  height: 46px;
  width: auto;
  margin-bottom: 1rem;
}

.footer__heading {
  margin-bottom: 1.1rem;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  color: #fff;
}

.footer__list {
  display: grid;
  gap: 0.55rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.footer__list a {
  font-size: 0.9rem;
}

.footer__social {
  display: flex;
  gap: 0.5rem;
  margin-top: 1.25rem;
  padding: 0;
  list-style: none;
}

.footer__social .social-link {
  width: 38px;
  height: 38px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
}

.footer__social .social-link:hover {
  background: var(--gold-500);
  border-color: var(--gold-500);
  color: #2a1f00;
}

.footer__contact {
  display: grid;
  gap: 0.7rem;
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 0.9rem;
}

.footer__contact li {
  display: flex;
  gap: 0.6rem;
  align-items: flex-start;
}

.footer__contact .icon {
  width: 1rem;
  height: 1rem;
  flex: none;
  margin-top: 0.3rem;
  color: var(--accent-on-dark);
}

.footer__bottom {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.5rem;
  align-items: center;
  justify-content: space-between;
  padding-block: 1.4rem;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  font-size: 0.82rem;
}

.footer__legal {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 1.2rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

/* --- Floating actions -------------------------------------------------- */

.footer__legal li {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}

.footer__legal-icon {
  width: 0.95rem;
  height: 0.95rem;
  color: var(--accent-on-dark);
  flex: none;
}

/* --- Floating actions -------------------------------------------------- */

.fab-stack {
  position: fixed;
  inset-inline-end: 18px;
  bottom: 18px;
  z-index: 90;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.fab {
  display: grid;
  place-items: center;
  width: 50px;
  height: 50px;
  border: 0;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
  box-shadow: var(--shadow);
  cursor: pointer;
  transition: transform 0.2s var(--ease), background-color 0.2s var(--ease),
    opacity 0.25s var(--ease), visibility 0.25s var(--ease);
}

.fab:hover {
  transform: translateY(-3px);
  color: #fff;
}

.fab--whatsapp {
  background: #25d366;
  color: #0b2e16;
}

.fab--whatsapp:hover {
  background: #1fb857;
  color: #0b2e16;
}

.fab--top {
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border);
  opacity: 0;
  visibility: hidden;
}

.fab--top.is-visible {
  opacity: 1;
  visibility: visible;
}

.fab--top:hover {
  color: var(--primary);
}

.fab .icon {
  width: 1.45rem;
  height: 1.45rem;
}

/* --- Reveal on scroll (see the Motion section) ------------------------- */

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .card--link:hover .icon-badge {
    background: rgba(63, 195, 214, 0.2);
    color: var(--accent);
  }
}

@media (prefers-reduced-motion: reduce) {
  .js .reveal {
    opacity: 1;
    transform: none;
  }
}

/* --- Locale typography -------------------------------------------------
   Montserrat covers neither Arabic nor Chinese, so those locales put a
   face that does in front of it. The head loads the matching webfont.
   ----------------------------------------------------------------------- */

:root[data-locale="ar"] {
  --font: "Cairo", "Noto Sans Arabic", "Segoe UI", Tahoma, sans-serif;
}

:root[data-locale="zh"] {
  --font: "Noto Sans SC", "Montserrat", "PingFang SC", "Microsoft YaHei",
    sans-serif;
}

/* Arabic and Chinese read better slightly larger and more open than
   Montserrat's defaults, and neither language wants Latin letter-spacing
   on headings. */
:root[data-locale="ar"] body,
:root[data-locale="zh"] body {
  line-height: 1.8;
}

:root[data-locale="ar"] h1,
:root[data-locale="ar"] h2,
:root[data-locale="ar"] h3,
:root[data-locale="zh"] h1,
:root[data-locale="zh"] h2,
:root[data-locale="zh"] h3 {
  letter-spacing: 0;
  line-height: 1.4;
}

:root[data-locale="ar"] .eyebrow,
:root[data-locale="zh"] .eyebrow,
:root[data-locale="ar"] .stat__label,
:root[data-locale="zh"] .stat__label,
:root[data-locale="ar"] .footer__heading,
:root[data-locale="zh"] .footer__heading,
:root[data-locale="ar"] .person__role,
:root[data-locale="zh"] .person__role,
:root[data-locale="ar"] .detail-group h3,
:root[data-locale="zh"] .detail-group h3 {
  letter-spacing: 0.02em;
}

/* Arabic has no case distinction; uppercasing it does nothing useful and
   Chinese uppercase transforms are meaningless too. */
:root[data-locale="ar"] .eyebrow,
:root[data-locale="zh"] .eyebrow,
:root[data-locale="ar"] .stat__label,
:root[data-locale="zh"] .stat__label,
:root[data-locale="ar"] .footer__heading,
:root[data-locale="zh"] .footer__heading,
:root[data-locale="ar"] .person__role,
:root[data-locale="zh"] .person__role,
:root[data-locale="ar"] .mega__title,
:root[data-locale="zh"] .mega__title,
:root[data-locale="ar"] .nav__panel-label,
:root[data-locale="zh"] .nav__panel-label,
:root[data-locale="ar"] .portal__head,
:root[data-locale="zh"] .portal__head,
:root[data-locale="ar"] .lang__head,
:root[data-locale="zh"] .lang__head,
:root[data-locale="ar"] .brand__sub,
:root[data-locale="zh"] .brand__sub,
:root[data-locale="ar"] .contact-list dt,
:root[data-locale="zh"] .contact-list dt,
:root[data-locale="ar"] .calc-stat__label,
:root[data-locale="zh"] .calc-stat__label,
:root[data-locale="ar"] .badge span,
:root[data-locale="zh"] .badge span,
:root[data-locale="ar"] .tag,
:root[data-locale="zh"] .tag,
:root[data-locale="ar"] .detail-group h3,
:root[data-locale="zh"] .detail-group h3 {
  text-transform: none;
}

/* The brand lock-up's "by HLB Jordan" needs more room once translated. */
:root[data-locale="ar"] .brand__sub,
:root[data-locale="zh"] .brand__sub,
:root[data-locale="fr"] .brand__sub {
  max-width: 11ch;
}

/* --- RTL --------------------------------------------------------------- */

[dir="rtl"] body {
  letter-spacing: 0;
}

[dir="rtl"] .nav__panel {
  left: auto;
  right: 0;
}

[dir="rtl"] .nav__panel--mega {
  left: 50%;
  right: auto;
}

[dir="rtl"] .lang__menu,
[dir="rtl"] .portal__menu {
  right: auto;
  left: 0;
}

/* Arrow glyphs point the other way in a right-to-left layout. */
[dir="rtl"] .link-arrow .icon,
[dir="rtl"] .btn .icon-arrow,
[dir="rtl"] .footer-card .link-arrow .icon {
  transform: scaleX(-1);
}

[dir="rtl"] .link-arrow:hover .icon {
  transform: scaleX(-1) translateX(4px);
}

/* Keep numbers, phone numbers and Latin product names reading left to
   right inside Arabic text. */
[dir="rtl"] .stat__value,
[dir="rtl"] .calc-stat__value,
[dir="rtl"] .mega__count,
[dir="rtl"] .step__n,
[dir="rtl"] .footer__contact a[href^="tel:"],
[dir="rtl"] .contact-list dd {
  direction: ltr;
  text-align: start;
}

[dir="rtl"] .stat__value,
[dir="rtl"] .calc-stat__value,
[dir="rtl"] .step__n,
[dir="rtl"] .mega__count {
  unicode-bidi: isolate;
}

[dir="rtl"] .stat {
  text-align: center;
}

[dir="rtl"] .detail-row dd {
  direction: rtl;
}

[dir="rtl"] .search input {
  text-align: right;
}

[dir="rtl"] .hero__dots,
[dir="rtl"] .pills,
[dir="rtl"] .btn-row {
  flex-direction: row;
}

/* --- Hero controls ------------------------------------------------------
   Dots alone are not reachable by keyboard in any obvious way, so the
   strip is flanked by real previous/next buttons and a pause toggle. The
   whole row is one control group.
   ----------------------------------------------------------------------- */

.hero__controls {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-top: 2.25rem;
}

.hero__nav {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  flex: none;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  cursor: pointer;
  backdrop-filter: blur(4px);
  transition: background-color var(--t) var(--ease),
    border-color var(--t) var(--ease), transform var(--t-fast) var(--ease);
}

.hero__nav:hover {
  background: rgba(255, 255, 255, 0.2);
  border-color: #fff;
}

.hero__nav:active {
  transform: scale(0.94);
}

.hero__nav .icon {
  width: 1.05rem;
  height: 1.05rem;
}

[dir="rtl"] .hero__nav .icon {
  transform: scaleX(-1);
}

/* The pause button shows one glyph or the other, never both. */
.hero__pause .icon-play {
  display: none;
}

.hero__pause.is-paused .icon-pause {
  display: none;
}

.hero__pause.is-paused .icon-play {
  display: block;
}

.hero__dots {
  display: flex;
  gap: 0.5rem;
  margin: 0;
}

.hero__counter {
  margin-inline-start: auto;
  font-size: 0.82rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.6);
  font-variant-numeric: tabular-nums;
  direction: ltr;
}

.hero__counter b {
  color: #fff;
}

@media (max-width: 560px) {
  .hero__counter {
    display: none;
  }
}

/* --- Process timeline ---------------------------------------------------
   A hairline runs behind the numbered steps on wide screens so the seven
   stages read as one sequence rather than seven separate cards.
   ----------------------------------------------------------------------- */

.steps {
  position: relative;
}

@media (min-width: 900px) {
  .steps::before {
    content: "";
    position: absolute;
    inset-inline: 1.5rem;
    top: 0.2rem;
    height: 1px;
    background: linear-gradient(
      to right,
      transparent,
      var(--border-strong) 12%,
      var(--border-strong) 88%,
      transparent
    );
    z-index: 0;
  }

  .step {
    z-index: 1;
  }
}

/* --- Touch targets ------------------------------------------------------
   On a touch screen every control is given at least 44x44px of hit area,
   without changing how it looks. The padding box grows; the visible box
   does not.
   ----------------------------------------------------------------------- */

@media (pointer: coarse) {
  .social-link,
  .icon-btn,
  .nav__panel-link,
  .mega__link,
  .lang__option,
  .footer__list a,
  .footer__legal a,
  .breadcrumb a {
    position: relative;
  }

  .social-link::after,
  .icon-btn::after,
  .mega__link::after,
  .footer__list a::after,
  .footer__legal a::after,
  .breadcrumb a::after {
    content: "";
    position: absolute;
    inset: 50% auto auto 50%;
    width: max(100%, 44px);
    height: max(100%, 44px);
    transform: translate(-50%, -50%);
  }

  .nav__panel-link,
  .lang__option,
  .portal__item {
    min-height: 44px;
  }

  .hero__dot {
    padding-block: 12px;
    background-clip: content-box;
  }
}

/* --- Interactive accents ------------------------------------------------ */

/* The current page is marked with the HLB accent rather than the brand
   navy, so "where am I" and "what can I click" share one colour. */
.nav__link[aria-current="page"] {
  color: var(--accent);
}

.nav__link:hover {
  color: var(--accent);
  background: var(--accent-tint);
}

.nav__panel-link:hover,
.mega__link:hover {
  background: var(--accent-tint);
  color: var(--accent);
}

.nav__panel-link .icon {
  color: var(--accent);
}

.icon-btn:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-tint);
}

.lang__current:hover,
.search input:focus {
  border-color: var(--accent);
}

.search input:focus {
  box-shadow: var(--ring);
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  border-color: var(--accent);
  box-shadow: var(--ring);
}

.faq__item[open] {
  border-color: var(--accent);
}

.faq__q:hover {
  color: var(--accent);
}

.faq__q .icon {
  color: var(--accent);
}

.tag,
.pill {
  background: var(--accent-tint);
  color: var(--accent);
}

.detail-group h3 {
  color: var(--accent);
  border-bottom-color: var(--accent);
}

.quote::before {
  color: var(--accent);
  opacity: 0.35;
}

.tick-list .icon {
  color: var(--accent);
}

.calc-stat__label .icon {
  color: var(--accent);
}

.contact-list .icon-badge {
  background: var(--accent-tint);
  color: var(--accent);
}

.form-note .icon {
  color: var(--accent);
}

.mega__count {
  color: var(--accent);
}

/* Smoother, consistent hover on the two list-style links. */
.link-arrow {
  transition: color var(--t) var(--ease), gap var(--t) var(--ease);
}

.link-arrow:hover {
  color: var(--accent-hover);
}

/* --- Selection ---------------------------------------------------------- */

::selection {
  background: color-mix(in srgb, var(--accent) 24%, transparent);
  color: var(--text);
}

/* --- Scrollbar ---------------------------------------------------------- */

@supports (scrollbar-color: auto) {
  :root {
    scrollbar-color: var(--border-strong) transparent;
  }
}

/* ==========================================================================
   Motion
   Everything here animates `transform` and `opacity` only, so the work
   stays on the compositor and never forces the browser to re-lay-out the
   page mid-animation. Entrances decelerate, exits accelerate and are
   quicker. The whole layer is switched off under prefers-reduced-motion
   by the single rule in the Reset, so no individual effect needs to
   remember to opt out.
   ========================================================================== */

/* --- Entrances ---------------------------------------------------------- */

@keyframes rise {
  from {
    opacity: 0;
    transform: translate3d(0, 14px, 0);
  }
}

@keyframes settle {
  from {
    opacity: 0;
    transform: translate3d(0, 8px, 0) scale(0.985);
  }
}

@keyframes fade {
  from {
    opacity: 0;
  }
}

/* The page's own first impression: the hero text arrives a beat after the
   image, which reads as deliberate rather than as a slow load. */
.js .hero__panel.is-active > *,
.js .page-hero .wrap > * {
  animation: rise var(--t-slow) var(--ease-out) backwards;
}

.js .hero__panel.is-active > *:nth-child(1),
.js .page-hero .wrap > *:nth-child(1) {
  animation-delay: 60ms;
}
.js .hero__panel.is-active > *:nth-child(2),
.js .page-hero .wrap > *:nth-child(2) {
  animation-delay: 130ms;
}
.js .hero__panel.is-active > *:nth-child(3),
.js .page-hero .wrap > *:nth-child(3) {
  animation-delay: 200ms;
}
.js .hero__panel.is-active > *:nth-child(n + 4),
.js .page-hero .wrap > *:nth-child(n + 4) {
  animation-delay: 270ms;
}

/* Hero chrome follows the copy in. */
.js .hero__controls,
.js .hero__trust {
  animation: fade var(--t-slow) var(--ease-out) 340ms backwards;
}

/* --- Scroll reveal ------------------------------------------------------ */

.js .reveal {
  opacity: 0;
  transform: translate3d(0, 16px, 0);
  transition: opacity var(--t-slow) var(--ease-out),
    transform var(--t-slow) var(--ease-out);
}

.js .reveal.is-in {
  opacity: 1;
  transform: none;
}

/* --- Interactive feedback ----------------------------------------------- */

/* Anything that lifts on hover drops back faster than it rose. */
.btn,
.card,
.step,
.country-btn,
.footer-card {
  transition-timing-function: var(--ease-in);
  transition-duration: var(--t-fast);
}

.btn:hover,
.card--link:hover,
.step:hover,
.country-btn:hover,
.footer-card:hover {
  transition-timing-function: var(--ease-out);
  transition-duration: var(--t);
}

/* Icons inside a link travel with it rather than sitting still. */
.link-arrow .icon,
.btn .icon {
  transition: transform var(--t) var(--ease-out);
}

.btn:hover .icon {
  transform: translateX(2px);
}

[dir="rtl"] .btn:hover .icon {
  transform: translateX(-2px);
}

.btn--on-dark:hover .icon,
.btn--ghost:hover .icon {
  transform: none;
}

/* A press should feel immediate: no easing in, straight to the state. */
.btn:active,
.icon-btn:active,
.country-btn:active,
.hero__nav:active,
.fab:active {
  transition-duration: 60ms;
  transition-timing-function: linear;
}

/* --- Panels and menus --------------------------------------------------- */

/* Dropdowns grow very slightly as they arrive, which reads as the panel
   coming forward rather than simply appearing. */
.nav__panel,
.lang__menu,
.portal__menu {
  transform-origin: top center;
  transition: opacity var(--t-fast) var(--ease-in),
    transform var(--t-fast) var(--ease-in),
    visibility var(--t-fast) var(--ease-in);
}

.nav__item--open > .nav__panel,
.lang.is-open .lang__menu,
.portal.is-open .portal__menu {
  transition: opacity var(--t) var(--ease-out),
    transform var(--t) var(--ease-out), visibility var(--t) var(--ease-out);
}

@media (min-width: 1080px) {
  .nav__panel {
    transform: translateY(-6px) scale(0.985);
  }

  .nav__item--open > .nav__panel {
    transform: translateY(0) scale(1);
  }

  .nav__panel--mega {
    transform: translate(-50%, -6px) scale(0.985);
  }

  .nav__item--open > .nav__panel--mega {
    transform: translate(-50%, 0) scale(1);
  }
}

.lang__menu,
.portal__menu {
  transform: translateY(-6px) scale(0.985);
}

.lang.is-open .lang__menu,
.portal.is-open .portal__menu {
  transform: translateY(0) scale(1);
}

/* Items in the mobile drawer arrive one after another. */
@media (max-width: 1079px) {
  .nav.is-open .nav__item {
    animation: rise var(--t-panel) var(--ease-out) backwards;
  }

  .nav.is-open .nav__item:nth-child(1) { animation-delay: 40ms; }
  .nav.is-open .nav__item:nth-child(2) { animation-delay: 80ms; }
  .nav.is-open .nav__item:nth-child(3) { animation-delay: 120ms; }
  .nav.is-open .nav__item:nth-child(4) { animation-delay: 160ms; }
  .nav.is-open .nav__item:nth-child(5) { animation-delay: 200ms; }
  .nav.is-open .nav__item:nth-child(n + 6) { animation-delay: 240ms; }
}

/* --- FAQ ----------------------------------------------------------------
   <details> cannot animate its own height without animating layout, so the
   panel opens instantly and its contents ease in. The movement is on the
   compositor; the height change is a single reflow of one row.
   ----------------------------------------------------------------------- */

.js .faq__item[open] .faq__a {
  animation: settle var(--t-panel) var(--ease-out);
}

.faq__q .icon {
  transition: transform var(--t) var(--ease-soft), color var(--t) var(--ease);
}

/* --- Country detail ----------------------------------------------------- */

.js .country-detail:not([hidden]) {
  animation: settle var(--t-panel) var(--ease-out);
}

/* --- Theme switch -------------------------------------------------------
   Colour tokens are not transitioned in general: doing so would make every
   hover repaint the page. During a theme change only, a short global
   transition is switched on so the swap is a fade rather than a jolt.
   ----------------------------------------------------------------------- */

.theme-changing,
.theme-changing *,
.theme-changing *::before,
.theme-changing *::after {
  transition: background-color 300ms var(--ease),
    border-color 300ms var(--ease), color 300ms var(--ease),
    fill 300ms var(--ease) !important;
}

/* --- Images -------------------------------------------------------------- */

.person__photo img,
.post__media img,
.country-btn img {
  transition: transform var(--t-slow) var(--ease-out);
}

/* --- Floating controls --------------------------------------------------- */

.fab {
  transition: transform var(--t) var(--ease-soft),
    background-color var(--t) var(--ease), opacity var(--t) var(--ease),
    visibility var(--t) var(--ease);
}

.fab:hover {
  transform: translateY(-3px) scale(1.04);
}

/* --- Header -------------------------------------------------------------
   A few pixels of compaction once the page has moved, so the header feels
   anchored to the scroll without the layout jumping.
   ----------------------------------------------------------------------- */

.brand img {
  transition: transform var(--t) var(--ease);
}

.header.is-stuck .brand img {
  transform: scale(0.94);
}

.header {
  transition: box-shadow var(--t) var(--ease),
    background-color var(--t) var(--ease);
}

/* --- Print ------------------------------------------------------------- */

@media print {
  .topbar,
  .header,
  .fab-stack,
  .footer__cards,
  .hero__dots,
  .nav-backdrop {
    display: none !important;
  }

  body {
    background: #fff;
    color: #000;
  }

  .hero,
  .page-hero,
  .section--deep,
  .cta-band,
  .footer {
    background: #fff !important;
    color: #000 !important;
  }

  .hero h1,
  .page-hero h1,
  .section--deep h2,
  .cta-band h2 {
    color: #000 !important;
  }

  a {
    color: #000;
    text-decoration: underline;
  }

  .card,
  .step,
  .faq__item {
    box-shadow: none;
    border: 1px solid #ccc;
    break-inside: avoid;
  }

  .faq__a {
    display: block !important;
  }
}
