/* ==========================================================================
   Emertec — site styles
   Brand: Emertec palette + Inter. Interaction: Apple fluid-interface principles
   (instant press feedback, critically damped motion, translucent chrome,
   size-specific tracking, reduced-motion/transparency/contrast support).
   ========================================================================== */

:root {
  /* Brand palette (the only five colours) */
  --em-orange:   #dd8531;
  --em-purple:   #853b90;
  --em-offwhite: #fff9f9;
  --em-dark:     #140228;
  --em-steel:    #8798a7;

  /* Derived tokens */
  --bg:          var(--em-offwhite);
  --surface:     #ffffff;
  --text:        var(--em-dark);
  --text-muted:  #4a3d5c;               /* dark at reduced strength — passes AA on off-white */
  --text-inv:    var(--em-offwhite);
  --text-inv-muted: rgba(255, 249, 249, 0.72);
  --line:        rgba(135, 152, 167, 0.28);
  --line-strong: rgba(135, 152, 167, 0.5);
  --link:        var(--em-purple);
  --accent:      var(--em-orange);
  --orange-text: #b8641a;               /* orange darkened for small text on light (AA) */

  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif;

  /* Spacing scale in rem so it grows with the user's text size */
  --s-1: .25rem; --s-2: .5rem; --s-3: .75rem; --s-4: 1rem; --s-5: 1.5rem;
  --s-6: 2rem; --s-7: 3rem; --s-8: 4rem; --s-9: 6rem; --s-10: 8rem;

  --radius-sm: .75rem;
  --radius:    1.25rem;
  --radius-lg: 1.75rem;

  --gutter: clamp(1rem, 4vw, 2.5rem);
  --max:    75rem;
  --max-text: 42rem;

  --nav-h: 4rem;

  /* Motion — critically damped feel (no overshoot) for UI */
  --ease-out: cubic-bezier(.22, 1, .36, 1);
  --ease-in: cubic-bezier(.64, 0, .78, 0);      /* inverse of --ease-out: exits retrace the entry path */
  --ease-in-out: cubic-bezier(.65, 0, .35, 1);
  --dur-press: 100ms;
  --dur-fast: 200ms;
  --dur: 400ms;
  --dur-slow: 700ms;

  --shadow-sm: 0 1px 2px rgba(20, 2, 40, .06), 0 2px 8px rgba(20, 2, 40, .05);
  --shadow:    0 2px 4px rgba(20, 2, 40, .04), 0 12px 32px rgba(20, 2, 40, .08);
  --shadow-lg: 0 4px 8px rgba(20, 2, 40, .05), 0 24px 64px rgba(20, 2, 40, .14);
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--nav-h) + 1rem); }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0;
  font: 400 1.0625rem/1.6 var(--font);
  font-optical-sizing: auto;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
img, video, svg { display: block; max-width: 100%; height: auto; }
button { font: inherit; color: inherit; }
a { color: var(--link); text-underline-offset: .18em; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--em-purple); outline-offset: 3px; border-radius: 6px; }
.section--dark :focus-visible, .hero :focus-visible, .footer :focus-visible { outline-color: var(--em-orange); }
p { margin: 0 0 1em; }
ul { margin: 0 0 1em; padding-left: 1.2em; }
li { margin-bottom: .35em; }
::selection { background: rgba(221, 133, 49, .3); }

.skip-link {
  position: absolute; left: var(--s-4); top: -100px; z-index: 200;
  background: var(--em-dark); color: var(--em-offwhite); padding: .75rem 1rem; border-radius: var(--radius-sm);
  text-decoration: none; font-weight: 600;
}
.skip-link:focus { top: var(--s-4); }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- Typography (size-specific tracking & leading) ---------- */
h1, h2, h3, h4 { margin: 0 0 .5em; font-weight: 700; color: inherit; text-wrap: balance; }
.display {
  font-size: clamp(2.5rem, 7vw, 5.5rem);
  line-height: 1.02;
  letter-spacing: -0.035em;
  font-weight: 800;
}
h1, .h1 { font-size: clamp(2.25rem, 5.5vw, 4.25rem); line-height: 1.05; letter-spacing: -0.03em; font-weight: 800; }
h2, .h2 { font-size: clamp(1.875rem, 4vw, 3rem); line-height: 1.1; letter-spacing: -0.025em; }
h3, .h3 { font-size: clamp(1.25rem, 2vw, 1.5rem); line-height: 1.25; letter-spacing: -0.012em; }
h4 { font-size: 1.0625rem; line-height: 1.35; letter-spacing: -0.005em; }
.lead { font-size: clamp(1.125rem, 1.6vw, 1.375rem); line-height: 1.5; letter-spacing: -0.008em; color: var(--text-muted); text-wrap: pretty; }
.small { font-size: .875rem; letter-spacing: .005em; }
.eyebrow {
  display: inline-block; margin-bottom: var(--s-4);
  font-size: .875rem; font-weight: 600; letter-spacing: .02em; line-height: 1.3;
  color: var(--orange-text);
}
.section--dark .eyebrow, .hero .eyebrow { color: var(--em-orange); }
.text-orange { color: var(--em-orange); }
.text-gradient {
  background: linear-gradient(90deg, #ac6d3a, #dd8531 45%, #d28944);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}

/* ---------- Layout ---------- */
.container { width: 100%; max-width: var(--max); margin-inline: auto; padding-inline: var(--gutter); }
.container--narrow { max-width: calc(var(--max-text) + 2 * var(--gutter)); }
.section { padding-block: clamp(2rem, 4vw, 3.5rem); position: relative; }
.section--tight { padding-block: clamp(2rem, 4vw, 3.5rem); }
.section--white { background: var(--surface); }
.section--dark { background: var(--em-dark); color: var(--text-inv); }
.section--dark .lead, .section--dark .muted { color: var(--text-inv-muted); }
.section--dark a:not(.btn) { color: #e0a8e8; }
.section-head { max-width: 48rem; margin-bottom: clamp(2.5rem, 5vw, 4rem); }
.section-head--center { margin-inline: auto; text-align: center; }
.muted { color: var(--text-muted); }

.grid { display: grid; gap: clamp(1rem, 2vw, 1.5rem); }
.grid--2 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 22rem), 1fr)); }
.grid--3 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 18rem), 1fr)); }
.grid--4 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 14rem), 1fr)); }

.split {
  display: grid; gap: clamp(2rem, 5vw, 5rem); align-items: center;
  grid-template-columns: 1fr;
}
@media (min-width: 56rem) {
  .split { grid-template-columns: 1fr 1fr; }
  .split--reverse > :first-child { order: 2; }
  .split--wide-media { grid-template-columns: 5fr 6fr; }
}

.media {
  border-radius: var(--radius-lg); overflow: hidden; background: #241238;
  box-shadow: var(--shadow-lg); position: relative; isolation: isolate;
}
.media img { width: 100%; height: 100%; object-fit: cover; aspect-ratio: 4 / 3; }
.media--wide img { aspect-ratio: 16 / 10; }
.media--tall img { aspect-ratio: 4 / 5; }
.media--contain { background: var(--surface); }
.media--contain img { object-fit: contain; aspect-ratio: auto; }

/* ---------- Buttons — feedback on press, instantly ---------- */
.btn {
  --btn-bg: var(--em-orange); --btn-fg: var(--em-dark);
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  min-height: 2.875rem; padding: .7rem 1.4rem;
  border: 0; border-radius: 999px;
  background: var(--btn-bg); color: var(--btn-fg);
  font-weight: 600; font-size: 1rem; letter-spacing: -0.005em; line-height: 1.2;
  text-decoration: none; cursor: pointer; white-space: nowrap;
  transition: transform var(--dur-fast) var(--ease-out), background-color var(--dur-fast) var(--ease-out), box-shadow var(--dur-fast) var(--ease-out);
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}
.btn:hover { background: #e4934a; text-decoration: none; }
.btn:active { transform: scale(.96); transition-duration: var(--dur-press); }
.btn svg { width: 1em; height: 1em; transition: transform var(--dur) var(--ease-out); }
@media (hover: hover) { .btn:hover svg { transform: translateX(3px); } }
.btn--secondary { --btn-bg: transparent; --btn-fg: var(--em-purple); box-shadow: inset 0 0 0 2px var(--em-purple); }
.btn--secondary:hover { background: rgba(133, 59, 144, .08); }
.btn--ghost { --btn-bg: rgba(255, 249, 249, .12); --btn-fg: var(--em-offwhite); box-shadow: inset 0 0 0 1px rgba(255, 249, 249, .28); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); }
.btn--ghost:hover { background: rgba(255, 249, 249, .2); }
.btn--sm { min-height: 2.25rem; padding: .45rem 1rem; font-size: .9375rem; }
.btn-row { display: flex; flex-wrap: wrap; gap: var(--s-3); align-items: center; }

.link-arrow {
  display: inline-flex; align-items: center; gap: .35em; font-weight: 600; text-decoration: none; color: var(--link);
}
.link-arrow svg { width: .95em; height: .95em; transition: transform var(--dur) var(--ease-out); }
@media (hover: hover) { .link-arrow:hover svg, .card:hover .link-arrow svg { transform: translateX(4px); } }

/* ---------- Navigation — translucent material, content scrolls beneath ---------- */
.nav {
  position: fixed; inset: 0 0 auto; z-index: 100; height: var(--nav-h);
  background: rgba(255, 249, 249, .86);
  backdrop-filter: saturate(180%) blur(20px); -webkit-backdrop-filter: saturate(180%) blur(20px);
  transition: box-shadow var(--dur) var(--ease-out), background-color var(--dur) var(--ease-out);
}
/* Scroll-edge effect instead of a hard divider, only once content is underneath */
.nav::after {
  content: ""; position: absolute; inset: 100% 0 auto; height: .75rem; pointer-events: none;
  background: linear-gradient(rgba(20, 2, 40, .07), rgba(20, 2, 40, 0));
  opacity: 0; transition: opacity var(--dur) var(--ease-out);
}
.nav.is-scrolled::after { opacity: 1; }
.nav__inner { height: 100%; display: flex; align-items: center; justify-content: space-between; gap: var(--s-5); }
.nav__logo { display: block; flex-shrink: 0; border-radius: 6px; }
.nav__logo img { width: 128px; height: auto; }
.nav__links { display: none; align-items: center; gap: var(--s-1); list-style: none; margin: 0; padding: 0; }
.nav__links > li { margin: 0; position: relative; }
.nav__link {
  display: inline-flex; align-items: center; gap: .3em;
  padding: .5rem .85rem; border-radius: 999px; border: 0; background: transparent;
  color: var(--text); font-size: .9375rem; font-weight: 500; letter-spacing: -0.005em;
  text-decoration: none; cursor: pointer;
  transition: background-color var(--dur-fast) var(--ease-out), transform var(--dur-fast) var(--ease-out);
}
.nav__link:hover, .nav__link[aria-expanded="true"] { background: rgba(20, 2, 40, .06); text-decoration: none; }
.nav__link:active { transform: scale(.96); transition-duration: var(--dur-press); }
.nav__link[aria-current="page"] { color: var(--em-purple); }
.nav__link svg { width: .75rem; height: .75rem; transition: transform var(--dur) var(--ease-out); }
.nav__link[aria-expanded="true"] svg { transform: rotate(180deg); }
.nav__cta { display: none; }

@media (min-width: 60rem) {
  .nav__links { display: flex; }
  .nav__cta { display: inline-flex; }
  .nav__toggle { display: none !important; }
}

/* Dropdown — anchored to its trigger, materialises (scale + blur + fade together) */
.dropdown {
  position: absolute; top: calc(100% + .6rem); left: 50%;
  width: min(38rem, 90vw); padding: var(--s-3);
  background: rgba(255, 255, 255, .86);
  backdrop-filter: saturate(180%) blur(24px); -webkit-backdrop-filter: saturate(180%) blur(24px);
  border: 1px solid rgba(255, 255, 255, .7); border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  display: grid; grid-template-columns: 1fr 1fr; gap: var(--s-1);
  transform-origin: top center;
  opacity: 0; visibility: hidden; transform: translateX(-50%) translateY(-6px) scale(.97); filter: blur(4px);
  transition: opacity var(--dur-fast) var(--ease-in), transform var(--dur-fast) var(--ease-in), filter var(--dur-fast) var(--ease-in), visibility 0s linear var(--dur-fast);
}
.dropdown.is-open {
  opacity: 1; visibility: visible; transform: translateX(-50%) translateY(0) scale(1); filter: none;
  transition: opacity var(--dur-fast) var(--ease-out), transform var(--dur) var(--ease-out), filter var(--dur-fast) var(--ease-out), visibility 0s;
}
.dropdown a {
  display: grid; gap: .15rem; padding: .8rem 1rem; border-radius: var(--radius-sm);
  color: var(--text); text-decoration: none;
  transition: background-color var(--dur-fast) var(--ease-out), transform var(--dur-fast) var(--ease-out);
}
.dropdown a:hover { background: rgba(133, 59, 144, .07); }
.dropdown a:active { transform: scale(.98); transition-duration: var(--dur-press); }
.dropdown strong { font-size: .9375rem; font-weight: 600; letter-spacing: -0.005em; }
.dropdown span { font-size: .8125rem; line-height: 1.4; color: var(--text-muted); letter-spacing: .005em; }

/* Mobile menu toggle */
.nav__toggle {
  display: inline-grid; place-items: center; width: 2.75rem; height: 2.75rem; margin-right: -.5rem;
  border: 0; border-radius: 999px; background: transparent; cursor: pointer;
  transition: background-color var(--dur-fast) var(--ease-out), transform var(--dur-fast) var(--ease-out);
  -webkit-tap-highlight-color: transparent;
}
.nav__toggle:active { transform: scale(.92); background: rgba(20, 2, 40, .06); transition-duration: var(--dur-press); }
.nav__toggle span { position: relative; width: 1.25rem; height: 2px; background: currentColor; border-radius: 2px; transition: background-color var(--dur-fast); }
.nav__toggle span::before, .nav__toggle span::after {
  content: ""; position: absolute; left: 0; width: 100%; height: 2px; background: currentColor; border-radius: 2px;
  transition: transform var(--dur) var(--ease-out);
}
.nav__toggle span::before { transform: translateY(-6px); }
.nav__toggle span::after { transform: translateY(6px); }
.nav__toggle[aria-expanded="true"] span { background: transparent; }
.nav__toggle[aria-expanded="true"] span::before { transform: rotate(45deg); }
.nav__toggle[aria-expanded="true"] span::after { transform: rotate(-45deg); }

/* Mobile sheet — emerges from the toggle (top-right), returns the same way */
.mobile-menu {
  position: fixed; z-index: 99; inset: calc(var(--nav-h) + .5rem) .75rem auto;
  max-height: calc(100dvh - var(--nav-h) - 1.5rem); overflow-y: auto; overscroll-behavior: contain;
  padding: var(--s-4);
  background: rgba(255, 255, 255, .9);
  backdrop-filter: saturate(180%) blur(28px); -webkit-backdrop-filter: saturate(180%) blur(28px);
  border: 1px solid rgba(255, 255, 255, .7); border-radius: var(--radius-lg); box-shadow: var(--shadow-lg);
  transform-origin: top right;
  opacity: 0; visibility: hidden; transform: scale(.94) translateY(-8px); filter: blur(6px);
  transition: opacity var(--dur-fast) var(--ease-in), transform var(--dur-fast) var(--ease-in), filter var(--dur-fast) var(--ease-in), visibility 0s linear var(--dur-fast);
}
.mobile-menu.is-open {
  opacity: 1; visibility: visible; transform: none; filter: none;
  transition: opacity var(--dur-fast) var(--ease-out), transform var(--dur) var(--ease-out), filter var(--dur-fast) var(--ease-out), visibility 0s;
}
.mobile-menu__group { padding-block: var(--s-2); }
.mobile-menu__group + .mobile-menu__group { border-top: 1px solid var(--line); }
.mobile-menu__label { display: block; padding: .5rem .75rem .25rem; font-size: .8125rem; font-weight: 600; color: var(--text-muted); letter-spacing: .01em; }
.mobile-menu a:not(.btn) {
  display: flex; align-items: center; min-height: 2.875rem; padding: .5rem .75rem; border-radius: var(--radius-sm);
  color: var(--text); text-decoration: none; font-size: 1.0625rem; font-weight: 500; letter-spacing: -0.01em;
  transition: background-color var(--dur-fast);
}
.mobile-menu a:not(.btn):active { background: rgba(133, 59, 144, .08); }
.mobile-menu .btn { width: 100%; margin-top: var(--s-3); }
.scrim {
  position: fixed; inset: 0; z-index: 98; background: rgba(20, 2, 40, .28);
  opacity: 0; visibility: hidden; transition: opacity var(--dur-fast) var(--ease-in), visibility 0s linear var(--dur-fast);
}
.scrim.is-open { opacity: 1; visibility: visible; transition: opacity var(--dur) var(--ease-out), visibility 0s; }
@media (min-width: 60rem) { .mobile-menu, .scrim { display: none; } }

/* ---------- Hero ---------- */
.hero {
  position: relative; isolation: isolate; overflow: hidden;
  min-height: min(56rem, 100svh);
  display: flex; align-items: center;
  padding-top: calc(var(--nav-h) + clamp(3rem, 8vw, 6rem)); padding-bottom: clamp(3rem, 8vw, 6rem);
  background: var(--em-dark); color: var(--text-inv);
}
.hero--page { min-height: min(40rem, 88svh); }
.hero__bg { position: absolute; inset: 0; z-index: -2; }
.hero__bg img, .hero__bg video { width: 100%; height: 100%; object-fit: cover; }
/* Legibility scrim: heavier where the text sits */
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    linear-gradient(90deg, rgba(20, 2, 40, .92) 0%, rgba(20, 2, 40, .7) 45%, rgba(20, 2, 40, .25) 100%),
    linear-gradient(0deg, rgba(20, 2, 40, .9) 0%, rgba(20, 2, 40, 0) 40%);
}
/* Black fade weighted behind left-aligned text, easing out to show the background on the right */
.hero--fade::before {
  background:
    linear-gradient(90deg, rgba(0, 0, 0, .9) 0%, rgba(0, 0, 0, .75) 35%, rgba(0, 0, 0, .3) 70%, rgba(0, 0, 0, 0) 100%),
    linear-gradient(0deg, rgba(0, 0, 0, .85) 0%, rgba(0, 0, 0, 0) 40%);
}
.hero--center::before { background: radial-gradient(ellipse at center, rgba(20, 2, 40, .55), rgba(20, 2, 40, .9) 75%), linear-gradient(0deg, rgba(20, 2, 40, 1), rgba(20, 2, 40, 0) 35%); }
.hero__content { max-width: 52rem; }
.hero--center .hero__content { margin-inline: auto; text-align: center; }
.hero--center .btn-row { justify-content: center; }
.hero .lead { color: var(--text-inv-muted); max-width: 40rem; margin-bottom: var(--s-6); }
.hero--center .lead { margin-inline: auto; }
.hero h1 { margin-bottom: var(--s-5); }
.hero__tagline { display: flex; flex-wrap: wrap; gap: .4rem .6rem; margin-top: var(--s-6); padding: 0; list-style: none; }
.hero--center .hero__tagline { justify-content: center; }
.hero__tagline li {
  margin: 0; padding: .35rem .85rem; border-radius: 999px; font-size: .875rem; font-weight: 500; letter-spacing: .005em;
  background: rgba(255, 249, 249, .1); box-shadow: inset 0 0 0 1px rgba(255, 249, 249, .18);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
}
.hero__scroll {
  position: absolute; left: 50%; bottom: 1.5rem; transform: translateX(-50%);
  width: 1.5rem; height: 2.4rem; border-radius: 999px; box-shadow: inset 0 0 0 2px rgba(255, 249, 249, .45);
}
.hero__scroll::after {
  content: ""; position: absolute; left: 50%; top: .5rem; width: 4px; height: .5rem; margin-left: -2px; border-radius: 2px;
  background: var(--em-orange); animation: scroll-hint 2.2s var(--ease-in-out) 1s 3 backwards;
}
@keyframes scroll-hint { 0%, 100% { transform: translateY(0); opacity: 1; } 60% { transform: translateY(.7rem); opacity: 0; } }
@media (max-height: 40rem) { .hero__scroll { display: none; } }

/* ---------- Cards ---------- */
.card {
  position: relative; display: flex; flex-direction: column; gap: var(--s-3);
  padding: clamp(1.5rem, 3vw, 2rem); border-radius: var(--radius);
  background: var(--surface); box-shadow: var(--shadow-sm), inset 0 0 0 1px var(--line);
  color: var(--text); text-decoration: none;
  transition: transform var(--dur) var(--ease-out), box-shadow var(--dur) var(--ease-out);
}
.card h3 { margin: 0; }
.card p { margin: 0; color: var(--text-muted); }
.card .link-arrow { margin-top: auto; padding-top: var(--s-3); }
@media (hover: hover) { a.card:hover, .card--interactive:hover { transform: translateY(-4px); box-shadow: var(--shadow), inset 0 0 0 1px var(--line); text-decoration: none; } }
a.card:active { transform: translateY(-1px) scale(.985); transition-duration: var(--dur-press); }
a.card, a.contact-card, .logo-wall figure { -webkit-tap-highlight-color: transparent; }
.card__icon {
  display: grid; place-items: center; width: 3rem; height: 3rem; border-radius: .9rem;
  background: rgba(221, 133, 49, .12); color: var(--orange-text);
}
.card__icon svg { width: 1.5rem; height: 1.5rem; }
.card__icon--purple { background: rgba(133, 59, 144, .1); color: var(--em-purple); }
.card__tag { font-size: .8125rem; font-weight: 600; color: var(--em-purple); letter-spacing: .01em; }

.section--dark .card { background: rgba(255, 249, 249, .05); box-shadow: inset 0 0 0 1px rgba(255, 249, 249, .1); color: var(--text-inv); }
.section--dark .card p { color: var(--text-inv-muted); }
.section--dark a.card:hover { background: rgba(255, 249, 249, .08); box-shadow: inset 0 0 0 1px rgba(255, 249, 249, .18); }
.section--dark .card__icon { background: rgba(221, 133, 49, .16); color: var(--em-orange); }
.section--dark .card__icon--purple { background: rgba(224, 168, 232, .12); color: #e0a8e8; }

/* Feature card with image header */
.card--media { padding: 0; overflow: hidden; }
.card--media .card__img { aspect-ratio: 16 / 9; overflow: hidden; background: #241238; }
.card--media .card__img img { width: 100%; height: 100%; object-fit: cover; transition: transform var(--dur-slow) var(--ease-out); }
@media (hover: hover) { a.card--media:hover .card__img img { transform: scale(1.04); } }
.card--media .card__body { display: flex; flex-direction: column; gap: var(--s-3); padding: clamp(1.25rem, 3vw, 1.75rem); flex: 1; }

/* Bento grid for solutions */
.bento { display: grid; gap: clamp(1rem, 2vw, 1.5rem); grid-template-columns: 1fr; }
@media (min-width: 48rem) {
  .bento { grid-template-columns: repeat(6, 1fr); }
  .bento > :nth-child(1) { grid-column: span 4; }
  .bento > :nth-child(2) { grid-column: span 2; }
  .bento > :nth-child(3) { grid-column: span 2; }
  .bento > :nth-child(4) { grid-column: span 2; }
  .bento > :nth-child(5) { grid-column: span 2; }
  .bento > :nth-child(6) { grid-column: span 3; }
  .bento > :nth-child(7) { grid-column: span 3; }
}
.bento .card--feature {
  background: var(--em-dark); color: var(--text-inv); overflow: hidden; min-height: 22rem; justify-content: flex-end;
  box-shadow: var(--shadow);
}
.bento .card--feature p { color: var(--text-inv-muted); }
.bento .card--feature .link-arrow { color: var(--em-orange); }
.bento .card--feature .card__bg { position: absolute; inset: 0; z-index: 0; }
.bento .card--feature .card__bg img { width: 100%; height: 100%; object-fit: cover; opacity: .5; transition: transform var(--dur-slow) var(--ease-out), opacity var(--dur) var(--ease-out); }
@media (hover: hover) { .bento .card--feature:hover .card__bg img { transform: scale(1.04); opacity: .65; } }
.bento .card--feature::before { content: ""; position: absolute; inset: 0; z-index: 0; background: linear-gradient(0deg, rgba(20, 2, 40, .96) 35%, rgba(20, 2, 40, .62) 100%); }
.bento .card--feature > *:not(.card__bg) { position: relative; z-index: 1; }
.bento .card--feature .card__tag { color: var(--em-orange); }

/* ---------- Lists ---------- */
.checklist { list-style: none; padding: 0; margin: 0 0 1em; display: grid; gap: .6rem; }
.checklist li { position: relative; padding-left: 2rem; margin: 0; }
.checklist li::before {
  content: ""; position: absolute; left: 0; top: .2em; width: 1.25rem; height: 1.25rem; border-radius: 999px;
  background: rgba(221, 133, 49, .14) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='%23b8641a' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5.5 10.5l3 3 6-7'/%3E%3C/svg%3E") center / .85rem no-repeat;
}
.section--dark .checklist li::before { background-color: rgba(221, 133, 49, .2); background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='%23dd8531' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5.5 10.5l3 3 6-7'/%3E%3C/svg%3E"); }
.checklist--cols { grid-template-columns: repeat(auto-fit, minmax(min(100%, 14rem), 1fr)); gap: .75rem 1.5rem; }

.pill-list { display: flex; flex-wrap: wrap; gap: .5rem; padding: 0; margin: 0; list-style: none; }
.pill-list li { margin: 0; padding: .45rem .95rem; border-radius: 999px; background: var(--surface); box-shadow: inset 0 0 0 1px var(--line-strong); font-size: .9375rem; font-weight: 500; }
.section--dark .pill-list li { background: rgba(255, 249, 249, .06); box-shadow: inset 0 0 0 1px rgba(255, 249, 249, .16); }

/* ---------- Stats ---------- */
.stats { display: grid; gap: 1px; grid-template-columns: 1fr; background: rgba(255, 249, 249, .1); border-radius: var(--radius-lg); overflow: hidden; }
@media (min-width: 36rem) { .stats { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 56rem) { .stats { grid-template-columns: repeat(3, 1fr); } }
.stat { padding: clamp(1.5rem, 3vw, 2.25rem); background: var(--em-dark); }
.stat__value {
  display: block; margin-bottom: .35rem;
  font-size: clamp(2.75rem, 6vw, 4.25rem); font-weight: 800; line-height: 1; letter-spacing: -0.04em;
  font-variant-numeric: tabular-nums; color: var(--em-orange);
}
.stat__label { display: block; font-size: 1.0625rem; font-weight: 600; letter-spacing: -0.008em; margin-bottom: .35rem; }
.stat p { margin: 0; color: var(--text-inv-muted); font-size: .9375rem; line-height: 1.5; }

/* Big number callout */
.callout-number { font-size: clamp(4rem, 12vw, 9rem); font-weight: 800; line-height: .9; letter-spacing: -0.05em; }

/* ---------- Accordion (native details, smooth where supported) ---------- */
.accordion { display: grid; gap: .75rem; }
.accordion details {
  border-radius: var(--radius); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line);
  transition: box-shadow var(--dur) var(--ease-out);
  interpolate-size: allow-keywords;
}
.accordion details[open] { box-shadow: var(--shadow-sm), inset 0 0 0 1px var(--line-strong); }
.accordion summary {
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding: 1.25rem 1.5rem; cursor: pointer; list-style: none;
  font-size: 1.125rem; font-weight: 600; letter-spacing: -0.01em; border-radius: var(--radius);
  -webkit-tap-highlight-color: transparent;
}
.accordion summary::-webkit-details-marker { display: none; }
.accordion summary::after {
  content: ""; flex-shrink: 0; width: 1.75rem; height: 1.75rem; border-radius: 999px;
  background: rgba(133, 59, 144, .08) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='%23853b90' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M10 5v10M5 10h10'/%3E%3C/svg%3E") center / 1rem no-repeat;
  transition: transform var(--dur) var(--ease-out);
}
.accordion details[open] summary::after { transform: rotate(45deg); }
.accordion summary { transition: transform var(--dur-fast) var(--ease-out); }
.accordion summary:active { transform: scale(.995); transition-duration: var(--dur-press); }
.accordion details::details-content { block-size: 0; overflow: hidden; transition: block-size var(--dur) var(--ease-out), content-visibility var(--dur) allow-discrete; }
.accordion details[open]::details-content { block-size: auto; }
.accordion .accordion__body { padding: 0 1.5rem 1.4rem; color: var(--text-muted); }
.accordion .accordion__body p:last-child { margin: 0; }
.section--dark .accordion details { background: rgba(255, 249, 249, .05); box-shadow: inset 0 0 0 1px rgba(255, 249, 249, .12); }
.section--dark .accordion .accordion__body { color: var(--text-inv-muted); }
.section--dark .accordion summary::after { background-color: rgba(221, 133, 49, .16); background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='%23dd8531' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M10 5v10M5 10h10'/%3E%3C/svg%3E"); }

/* ---------- Segmented control + tab panels ---------- */
.segmented {
  position: relative; display: inline-flex; padding: .3rem; border-radius: 999px;
  background: rgba(20, 2, 40, .06); max-width: 100%; overflow-x: auto; scrollbar-width: none;
}
.segmented::-webkit-scrollbar { display: none; }
.segmented__indicator {
  position: absolute; top: .3rem; bottom: .3rem; left: 0; width: 0; border-radius: 999px;
  background: var(--surface); box-shadow: 0 1px 2px rgba(20, 2, 40, .1), 0 4px 12px rgba(20, 2, 40, .08);
  transition: transform var(--dur) var(--ease-out), width var(--dur) var(--ease-out);
}
.segmented button {
  position: relative; z-index: 1; border: 0; background: transparent; cursor: pointer;
  padding: .6rem 1.25rem; border-radius: 999px; font-size: .9375rem; font-weight: 600; letter-spacing: -0.005em;
  color: var(--text-muted); white-space: nowrap; transition: color var(--dur-fast), transform var(--dur-fast) var(--ease-out);
  -webkit-tap-highlight-color: transparent;
}
.segmented button[aria-selected="true"] { color: var(--text); }
.segmented button:active { transform: scale(.95); transition-duration: var(--dur-press); }
.no-js .segmented button[aria-selected="true"] { background: var(--surface); }
.tab-panel { animation: panel-in var(--dur) var(--ease-out); }
.js .tab-panel { animation: none; }
.js .tab-panel.is-entering { animation: panel-in var(--dur) var(--ease-out); }
.tab-panel[hidden] { display: none; }
@keyframes panel-in { from { opacity: 0; transform: translateX(var(--panel-from, 0)) translateY(var(--panel-rise, 8px)); } to { opacity: 1; transform: none; } }

.partner-panel {
  display: grid; gap: clamp(1.5rem, 4vw, 3rem); align-items: start;
  margin-top: var(--s-6); padding: clamp(1.5rem, 4vw, 3rem);
  background: var(--surface); border-radius: var(--radius-lg); box-shadow: var(--shadow-sm), inset 0 0 0 1px var(--line);
}
@media (min-width: 56rem) { .partner-panel { grid-template-columns: 16rem 1fr; } }
.partner-panel__logo { display: grid; place-items: center; padding: 1.5rem; border-radius: var(--radius); background: var(--em-offwhite); box-shadow: inset 0 0 0 1px var(--line); min-height: 8rem; }
.partner-panel__logo img { max-height: 4rem; width: auto; }
.partner-panel p { color: var(--text-muted); }
.partner-panel p:last-of-type { margin-bottom: var(--s-5); }

/* Logo wall */
.logo-wall { display: grid; gap: clamp(.75rem, 2vw, 1rem); grid-template-columns: repeat(2, 1fr); }
@media (min-width: 36rem) { .logo-wall { grid-template-columns: repeat(4, 1fr); } }
.logo-wall li { list-style: none; margin: 0; }
.logo-wall figure {
  margin: 0; aspect-ratio: 1; display: grid; place-items: center; padding: 12%;
  background: #fff; border-radius: var(--radius); box-shadow: inset 0 0 0 1px var(--line);
  transition: transform var(--dur) var(--ease-out), box-shadow var(--dur) var(--ease-out);
}
@media (hover: hover) { .logo-wall figure:hover { transform: translateY(-3px); box-shadow: var(--shadow), inset 0 0 0 1px var(--line); } }
.logo-wall img { width: 100%; height: auto; mix-blend-mode: multiply; }
.logo-wall { padding: 0; margin: 0; }

/* ---------- Outcome tiles ---------- */
.outcomes { display: grid; gap: clamp(.75rem, 2vw, 1rem); grid-template-columns: repeat(auto-fit, minmax(min(100%, 10rem), 1fr)); list-style: none; padding: 0; margin: 0; }
.outcomes li {
  margin: 0; display: grid; justify-items: center; gap: .75rem; text-align: center;
  padding: 1.5rem 1rem; border-radius: var(--radius); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line);
  font-weight: 600; letter-spacing: -0.008em;
}
.outcomes img { width: 3.5rem; height: 3.5rem; }

/* ---------- Steps / numbered ---------- */
.steps { counter-reset: step; list-style: none; padding: 0; margin: 0; display: grid; gap: clamp(1rem, 2vw, 1.5rem); grid-template-columns: repeat(auto-fit, minmax(min(100%, 15rem), 1fr)); }
.steps li { counter-increment: step; margin: 0; padding: 1.5rem; border-radius: var(--radius); background: rgba(255, 249, 249, .05); box-shadow: inset 0 0 0 1px rgba(255, 249, 249, .1); }
.steps li::before { content: counter(step, decimal-leading-zero); display: block; margin-bottom: .75rem; font-size: .875rem; font-weight: 700; color: var(--em-orange); letter-spacing: .02em; }
.steps h3 { font-size: 1.125rem; margin-bottom: .35rem; }
.steps p { margin: 0; color: var(--text-inv-muted); font-size: .9375rem; }
.steps--light li { background: var(--surface); box-shadow: var(--shadow-sm), inset 0 0 0 1px var(--line); }
.steps--light li::before { color: var(--orange-text); }
.steps--light p { color: var(--text-muted); }

/* ---------- Quote ---------- */
.pullquote {
  margin: clamp(2rem, 5vw, 3rem) 0; padding: clamp(1.5rem, 4vw, 2.5rem); border-radius: var(--radius-lg);
  background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); position: relative;
}
.pullquote blockquote { margin: 0 0 1rem; font-size: clamp(1.25rem, 2.4vw, 1.625rem); line-height: 1.35; letter-spacing: -0.015em; font-weight: 600; color: var(--text); text-wrap: pretty; }
.pullquote blockquote::before { content: "“"; display: block; font-size: 4rem; line-height: .6; height: 1.6rem; color: var(--em-orange); font-weight: 800; }
.pullquote p { color: var(--text-muted); }
.pullquote cite { font-style: normal; font-size: .9375rem; }
.statement {
  font-size: clamp(1.75rem, 4.2vw, 3.25rem); line-height: 1.12; letter-spacing: -0.03em; font-weight: 700;
  max-width: 56rem; margin: 0 auto; text-align: center; text-wrap: balance;
}
.statement--left { margin-inline: 0; text-align: left; }

/* ---------- Prose (article / policy) ---------- */
.prose { font-size: 1.125rem; line-height: 1.7; }
.prose > * { max-width: var(--max-text); }
.prose h2 { font-size: clamp(1.625rem, 3vw, 2.125rem); margin-top: 2.5em; }
.prose h3 { font-size: 1.25rem; margin-top: 2em; }
.prose h2:first-child, .prose h3:first-child { margin-top: 0; }
.prose ul { padding-left: 1.25em; }
.prose li::marker { color: var(--em-orange); }
.prose .source { font-size: .9375rem; color: var(--text-muted); }

.doc-layout { display: grid; gap: clamp(2rem, 5vw, 4rem); }
@media (min-width: 64rem) { .doc-layout { grid-template-columns: 15rem minmax(0, 1fr); } }
.toc { position: sticky; top: calc(var(--nav-h) + 1.5rem); align-self: start; }
.toc h2 { font-size: .875rem; letter-spacing: .02em; color: var(--text-muted); margin-bottom: .75rem; }
.toc ol { list-style: none; margin: 0; padding: 0; display: grid; gap: .1rem; border-left: 2px solid var(--line); }
.toc li { margin: 0; }
.toc a { display: block; padding: .35rem 0 .35rem 1rem; margin-left: -2px; border-left: 2px solid transparent; color: var(--text-muted); text-decoration: none; font-size: .9375rem; line-height: 1.4; transition: color var(--dur-fast), border-color var(--dur-fast); }
.toc a:hover { color: var(--text); }
.toc a.is-active { color: var(--em-purple); border-left-color: var(--em-purple); font-weight: 600; }
@media (max-width: 63.99rem) { .toc { position: static; } .toc ol { grid-template-columns: repeat(auto-fit, minmax(12rem, 1fr)); border: 0; } .toc a { border: 0; padding-left: 0; } }

.policy-section { padding-block: 1.5rem; border-top: 1px solid var(--line); }
.policy-section:first-child { border-top: 0; padding-top: 0; }
.policy-section h2 { font-size: clamp(1.375rem, 2.4vw, 1.75rem); margin-top: 0; }

.table-wrap { overflow-x: auto; border-radius: var(--radius); box-shadow: inset 0 0 0 1px var(--line); background: var(--surface); max-width: 100% !important; }
table { width: 100%; border-collapse: collapse; font-size: .9375rem; line-height: 1.45; }
th, td { padding: .85rem 1rem; text-align: left; vertical-align: top; }
thead th { background: var(--em-dark); color: var(--em-offwhite); font-weight: 600; white-space: nowrap; }
tbody tr + tr td { border-top: 1px solid var(--line); }
tbody tr:nth-child(even) td { background: rgba(135, 152, 167, .06); }

/* ---------- Contact ---------- */
.contact-cards { display: grid; gap: 1rem; }
.contact-card { display: flex; gap: 1rem; align-items: flex-start; padding: 1.25rem 1.5rem; border-radius: var(--radius); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); color: var(--text); text-decoration: none; transition: transform var(--dur) var(--ease-out), box-shadow var(--dur) var(--ease-out); }
@media (hover: hover) { a.contact-card:hover { transform: translateY(-2px); box-shadow: var(--shadow), inset 0 0 0 1px var(--line); text-decoration: none; } }
a.contact-card:active { transform: scale(.985); transition-duration: var(--dur-press); }
.contact-card strong { display: block; font-weight: 600; letter-spacing: -0.005em; }
.contact-card span { color: var(--text-muted); font-size: .9375rem; }
.form-frame { border-radius: var(--radius-lg); overflow: hidden; background: var(--surface); box-shadow: var(--shadow-lg), inset 0 0 0 1px var(--line); }
.form-frame iframe { display: block; width: 100%; height: 820px; border: 0; }

/* ---------- CTA band ---------- */
.cta-band {
  position: relative; isolation: isolate; overflow: hidden; text-align: center;
  padding: clamp(3rem, 8vw, 6rem) var(--gutter); border-radius: var(--radius-lg);
  background: var(--em-dark); color: var(--text-inv);
}
.cta-band::before {
  content: ""; position: absolute; z-index: -1; inset: -40% -10% auto; height: 120%;
  background: radial-gradient(closest-side, rgba(221, 133, 49, .35), transparent 70%), radial-gradient(closest-side at 30% 60%, rgba(133, 59, 144, .45), transparent 70%);
  filter: blur(20px);
}
.cta-band h2 { max-width: 44rem; margin-inline: auto; }
.cta-band .lead { color: var(--text-inv-muted); max-width: 36rem; margin: 0 auto var(--s-6); }
.cta-band .btn-row { justify-content: center; }

/* ---------- Footer ---------- */
.footer { background: var(--em-dark); color: var(--em-steel); padding-block: clamp(3rem, 7vw, 5rem) 2rem; font-size: .9375rem; }
.footer a { color: var(--em-offwhite); text-decoration: none; }
.footer a:hover { text-decoration: underline; }
.footer__grid { display: grid; gap: 2.5rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 12rem), 1fr)); }
.footer__brand { grid-column: 1 / -1; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1.5rem; align-items: center; padding-bottom: 2.5rem; border-bottom: 1px solid rgba(135, 152, 167, .25); }
.footer__logo { display: inline-block; padding: .65rem .9rem; background: #fff; border-radius: .75rem; }
.footer__logo img { width: 116px; }
.footer h2 { font-size: .875rem; font-weight: 600; letter-spacing: .02em; color: var(--em-offwhite); margin-bottom: 1rem; }
.footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: .55rem; }
.footer li { margin: 0; }
.footer address { font-style: normal; line-height: 1.7; }
.footer__legal { margin-top: 3rem; padding-top: 1.5rem; border-top: 1px solid rgba(135, 152, 167, .25); display: grid; gap: .5rem; font-size: .8125rem; line-height: 1.6; }
.footer__legal p { margin: 0; }
.badges { display: flex; flex-wrap: wrap; gap: .5rem; }
.badge { display: inline-flex; align-items: center; gap: .4rem; padding: .35rem .75rem; border-radius: 999px; font-size: .8125rem; font-weight: 600; color: var(--em-offwhite); background: rgba(255, 249, 249, .07); box-shadow: inset 0 0 0 1px rgba(255, 249, 249, .14); }
.badge svg { width: .95rem; height: .95rem; color: var(--em-orange); }

/* ---------- Lightbox (dialog) ---------- */
.zoomable { cursor: zoom-in; border: 0; padding: 0; background: none; display: block; width: 100%; border-radius: var(--radius-lg); }
.zoomable { transition: transform var(--dur-fast) var(--ease-out); }
.zoomable:active { transform: scale(.99); transition-duration: var(--dur-press); }
.lightbox {
  width: min(72rem, 94vw); max-height: 92vh; padding: 0; border: 0; border-radius: var(--radius-lg);
  background: #fff; box-shadow: var(--shadow-lg); overflow: hidden;
}
.lightbox img { width: 100%; height: auto; max-height: 92vh; object-fit: contain; }
.lightbox::backdrop { background: rgba(20, 2, 40, .6); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); }
.lightbox[open] { animation: lightbox-in var(--dur) var(--ease-out); }
.lightbox[open]::backdrop { animation: fade-in var(--dur) var(--ease-out); }
.lightbox__close {
  position: absolute; top: .75rem; right: .75rem; width: 2.5rem; height: 2.5rem; border-radius: 999px; border: 0; cursor: pointer;
  display: grid; place-items: center; background: rgba(20, 2, 40, .7); color: #fff;
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); transition: transform var(--dur-fast) var(--ease-out);
}
.lightbox__close:active { transform: scale(.9); transition-duration: var(--dur-press); }
.lightbox__close svg { width: 1.1rem; height: 1.1rem; }
@keyframes lightbox-in { from { opacity: 0; transform: scale(.96); } to { opacity: 1; transform: none; } }
@keyframes fade-in { from { opacity: 0; } to { opacity: 1; } }

/* ---------- Scroll reveal (only when JS is running) ---------- */
.js .reveal { opacity: 0; transform: translateY(24px); transition: opacity var(--dur-slow) var(--ease-out), transform var(--dur-slow) var(--ease-out); transition-delay: var(--delay, 0ms); }
.js .reveal.is-visible { opacity: 1; transform: none; }

/* ---------- Utilities ---------- */
.mt-0 { margin-top: 0; } .mb-0 { margin-bottom: 0; }
.mt-6 { margin-top: var(--s-6); } .mt-7 { margin-top: var(--s-7); } .mt-8 { margin-top: var(--s-8); }
.center { text-align: center; }
.stack > * + * { margin-top: var(--s-5); }

/* ==========================================================================
   Accessibility preferences
   ========================================================================== */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 1ms !important; animation-iteration-count: 1 !important; }
  .js .reveal { transform: none; transition: opacity 300ms ease; }
  .btn:active, a.card:active, .nav__link:active, .segmented button:active { transform: none; }
  a.card:hover, .logo-wall figure:hover, a.contact-card:hover { transform: none; }
  .dropdown, .dropdown.is-open, .mobile-menu, .mobile-menu.is-open { transform: translateX(var(--tx, 0)); filter: none; }
  .dropdown, .dropdown.is-open { --tx: -50%; }
  .card--media .card__img img, .bento .card--feature .card__bg img { transition: none; transform: none !important; }
  .hero__scroll::after { animation: none; }
  .segmented__indicator { transition: none; }
}
@media (prefers-reduced-transparency: reduce) {
  .nav { background: var(--em-offwhite); backdrop-filter: none; -webkit-backdrop-filter: none; }
  .dropdown, .mobile-menu { background: #fff; backdrop-filter: none; -webkit-backdrop-filter: none; }
  .btn--ghost, .hero__tagline li { background: rgba(20, 2, 40, .7); backdrop-filter: none; -webkit-backdrop-filter: none; }
  .lightbox::backdrop { backdrop-filter: none; background: rgba(20, 2, 40, .85); }
}
@media (prefers-contrast: more) {
  :root { --text-muted: var(--em-dark); --line: rgba(20, 2, 40, .5); --line-strong: var(--em-dark); --text-inv-muted: var(--em-offwhite); }
  .nav { background: var(--em-offwhite); border-bottom: 1px solid var(--em-dark); backdrop-filter: none; }
  .card, .accordion details, .partner-panel { box-shadow: inset 0 0 0 1.5px var(--em-dark); }
  .hero::before { background: rgba(20, 2, 40, .9); }
}
@media print {
  .nav, .mobile-menu, .scrim, .hero__bg, .hero__scroll, .cta-band, .form-frame { display: none !important; }
  .hero, .section--dark, .footer { background: #fff !important; color: #000 !important; }
  .js .reveal { opacity: 1; transform: none; }
}
