/* ==========================================================================
   RANESHCA DIGITAL GROUP
   Design system:
     Pattern    Scroll-triggered storytelling (intro -> chapters -> climax CTA)
     Type       Outfit (display) + Work Sans (body)
     Colour     Brand blue #1668F0, taken from the RDG logo
     Motion     Complex tier, fully disabled under prefers-reduced-motion
   All colours live in the :root blocks below. Change them once, here.
   ========================================================================== */

/* ---------- 0. FONT FALLBACK METRICS ------------------------------------
   Outfit loads from Google Fonts with font-display:swap. Arial is ~19% wider,
   so the fallback wrapped the hero headline onto an extra line and the whole
   hero collapsed upward when Outfit arrived (measured CLS 0.29 at 1280px).
   size-adjust:84% matches Arial's advance widths to Outfit's (measured 1564 vs
   1864 units at 100px/800), so line counts match and the swap no longer moves
   layout. Uses a local system font only - nothing extra is downloaded.
   ------------------------------------------------------------------------ */
@font-face {
  font-family: "Outfit Fallback";
  src: local("Arial"), local("Helvetica"), local("Liberation Sans");
  size-adjust: 84%;
}

@font-face {
  /* Work Sans is ~11% wider than the system fallback (measured 2859 vs 2576
     units at 100px), so body copy re-wrapped and grew when it loaded. */
  font-family: "Work Sans Fallback";
  src: local("Segoe UI"), local("Arial"), local("Helvetica");
  size-adjust: 111%;
}

/* ---------- 1. TOKENS --------------------------------------------------- */
:root {
  /* Brand */
  --blue:        #1668f0;
  --blue-400:    #4d94ff;
  --blue-700:    #0b47ad;
  --blue-glow:   rgba(22, 104, 240, 0.45);

  /* Spacing scale */
  --s-1: 8px;  --s-2: 16px;  --s-3: 24px;  --s-4: 32px;
  --s-5: 48px; --s-6: 64px;  --s-7: 96px;  --s-8: 128px;

  /* Layout */
  --wrap: 1180px;
  --pad: 24px;
  --r-sm: 10px;
  --r-md: 16px;
  --r-lg: 24px;
  --r-pill: 999px;

  /* Motion */
  --e-out: cubic-bezier(0.22, 1, 0.36, 1);
  --e-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --t-fast: 180ms;
  --t-mid: 320ms;
  --t-slow: 700ms;

  --nav-h: 72px;

}

/* Dark theme (default) */
[data-theme="dark"] {
  --bg:          #070910;
  --bg-2:        #0b0e18;
  --bg-3:        #0f1320;
  --fg:          #ffffff;
  --fg-soft:     #b6bdcc;
  --fg-mute:     #949cae;
  --line:        rgba(255, 255, 255, 0.10);
  --line-strong: rgba(255, 255, 255, 0.18);
  --glass:       rgba(255, 255, 255, 0.045);
  --glass-hi:    rgba(255, 255, 255, 0.075);
  --shadow:      0 24px 60px rgba(0, 0, 0, 0.55);
  --sheen:       linear-gradient(135deg, rgba(255,255,255,.10), rgba(255,255,255,0) 42%);
}

/* Light theme */
[data-theme="light"] {
  --bg:          #ffffff;
  --bg-2:        #f5f7fb;
  --bg-3:        #eef2f8;
  --fg:          #0a0d14;
  --fg-soft:     #3f4757;
  --fg-mute:     #5c6371;
  --line:        rgba(10, 13, 20, 0.10);
  --line-strong: rgba(10, 13, 20, 0.16);
  --glass:       rgba(255, 255, 255, 0.72);
  --glass-hi:    rgba(255, 255, 255, 0.9);
  --shadow:      0 20px 50px rgba(16, 24, 40, 0.10);
  --sheen:       linear-gradient(135deg, rgba(255,255,255,.9), rgba(255,255,255,0) 45%);
}

/* ---------- 2. RESET ---------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--nav-h) + 16px);
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: "Work Sans", "Work Sans Fallback", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  transition: background var(--t-mid) ease, color var(--t-mid) ease;
}

img { max-width: 100%; height: auto; display: block; }
h1, h2, h3, p, ul, ol, figure { margin: 0; padding: 0; }
ul, ol { list-style: none; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }

:focus-visible {
  outline: 2px solid var(--blue-400);
  outline-offset: 3px;
  border-radius: 6px;
}

.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 200;
  background: var(--blue); color: #fff; padding: 12px 20px; border-radius: 0 0 8px 0;
}
.skip-link:focus { left: 0; }

/* ---------- 3. LAYOUT --------------------------------------------------- */
.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: var(--pad);
}

.section { padding: var(--s-8) 0; position: relative; }
.section--alt { background: var(--bg-2); }
[data-theme="dark"] .section--alt { border-block: 1px solid var(--line); }

.sechead { text-align: center; max-width: 720px; margin: 0 auto var(--s-6); }

/* ---------- 4. TYPOGRAPHY ----------------------------------------------- */
.h2 {
  font-family: "Outfit", "Outfit Fallback", sans-serif;
  font-size: clamp(1.85rem, 4.4vw, 3.1rem);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.03em;
  margin-bottom: var(--s-3);
  text-wrap: balance;
}

.grad {
  background: linear-gradient(100deg, var(--blue-400), var(--blue) 45%, #8ab4ff);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
[data-theme="light"] .grad {
  background: linear-gradient(100deg, var(--blue), var(--blue-700));
  -webkit-background-clip: text;
  background-clip: text;
}

.eyebrow {
  font-family: "Outfit", "Outfit Fallback", sans-serif;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--blue-400);
  margin-bottom: var(--s-2);
}
[data-theme="light"] .eyebrow { color: var(--blue); }

.lede { color: var(--fg-soft); font-size: 1.06rem; max-width: 62ch; }
.lede + .lede { margin-top: var(--s-2); }
.lede--center { margin-inline: auto; }

/* ---------- 5. BUTTONS -------------------------------------------------- */
.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 48px;
  padding: 0 26px;
  border-radius: var(--r-pill);
  font-family: "Outfit", "Outfit Fallback", sans-serif;
  font-weight: 600;
  font-size: 0.98rem;
  letter-spacing: -0.01em;
  cursor: pointer;
  overflow: hidden;
  transition: transform var(--t-fast) var(--e-out),
              box-shadow var(--t-mid) var(--e-out),
              background var(--t-mid) ease,
              border-color var(--t-mid) ease;
  will-change: transform;
}
.btn--sm { min-height: 40px; padding: 0 18px; font-size: 0.9rem; }
.btn--lg { min-height: 60px; padding: 0 34px; font-size: 1.06rem; }

.btn--primary {
  background: linear-gradient(135deg, var(--blue-400), var(--blue) 55%, var(--blue-700));
  color: #fff;
  box-shadow: 0 10px 30px -8px var(--blue-glow);
}
.btn--primary::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(120deg, transparent 20%, rgba(255,255,255,.35) 50%, transparent 80%);
  transform: translateX(-130%);
  transition: transform 620ms var(--e-out);
}
.btn--primary:hover::after { transform: translateX(130%); }
.btn--primary:hover { box-shadow: 0 16px 44px -8px var(--blue-glow); }

.btn--ghost {
  border: 1px solid var(--line-strong);
  background: var(--glass);
  color: var(--fg);
  backdrop-filter: blur(10px);
}
.btn--ghost:hover { border-color: var(--blue); background: var(--glass-hi); }

.btn:active { transform: scale(0.97); }
.btn span, .btn svg { position: relative; z-index: 1; }

/* ---------- 6. NAV ------------------------------------------------------ */
.progress {
  position: fixed; inset: 0 0 auto 0; height: 3px; z-index: 120;
  background: transparent; pointer-events: none;
}
.progress__bar {
  display: block; height: 100%; width: 0%;
  background: linear-gradient(90deg, var(--blue-700), var(--blue), var(--blue-400));
  box-shadow: 0 0 14px var(--blue-glow);
  transition: width 90ms linear;
}

.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 110;
  height: var(--nav-h);
  transition: background var(--t-mid) ease, border-color var(--t-mid) ease,
              backdrop-filter var(--t-mid) ease, height var(--t-mid) ease;
  border-bottom: 1px solid transparent;
}
.nav.is-stuck {
  background: color-mix(in srgb, var(--bg) 78%, transparent);
  backdrop-filter: blur(18px) saturate(140%);
  -webkit-backdrop-filter: blur(18px) saturate(140%);
  border-bottom-color: var(--line);
}

.nav__inner {
  height: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: var(--pad);
  display: flex; align-items: center; justify-content: space-between; gap: var(--s-3);
}

.nav__brand { display: flex; align-items: center; gap: 11px; }
.nav__brand img { width: 38px; height: 38px; object-fit: contain; }
.nav__brandtext { display: flex; flex-direction: column; line-height: 1.05; }
.nav__brandtext strong {
  font-family: "Outfit", "Outfit Fallback", sans-serif; font-size: 0.95rem;
  font-weight: 700; letter-spacing: 0.16em;
}
.nav__brandtext em {
  font-style: normal; font-size: 0.66rem; letter-spacing: 0.2em;
  text-transform: uppercase; color: var(--blue-400);
}
[data-theme="light"] .nav__brandtext em { color: var(--blue); }

.nav__links { display: none; gap: 4px; align-items: center; }
@media (min-width: 940px) { .nav__links { display: flex; } }

.nav__link {
  position: relative;
  padding: 9px 15px;
  border-radius: var(--r-pill);
  font-size: 0.94rem;
  color: var(--fg-soft);
  transition: color var(--t-fast) ease, background var(--t-fast) ease;
}
.nav__link:hover { color: var(--fg); background: var(--glass); }
.nav__link.is-active { color: var(--fg); background: var(--glass-hi); }
.nav__link.is-active::after {
  content: ""; position: absolute; left: 50%; bottom: 3px;
  width: 16px; height: 2px; border-radius: 2px; background: var(--blue);
  transform: translateX(-50%);
}

.nav__actions { display: flex; align-items: center; gap: 10px; }

.iconbtn {
  width: 42px; height: 42px;
  display: grid; place-items: center;
  border-radius: var(--r-pill);
  border: 1px solid var(--line);
  background: var(--glass);
  color: var(--fg-soft);
  transition: color var(--t-fast) ease, border-color var(--t-fast) ease,
              transform var(--t-fast) var(--e-spring), background var(--t-fast) ease;
}
.iconbtn:hover { color: var(--fg); border-color: var(--blue); transform: translateY(-2px); }

[data-theme="dark"] .i-sun  { display: none; }
[data-theme="light"] .i-moon { display: none; }

.nav__burger { flex-direction: column; gap: 4px; }
.nav__burger span {
  display: block; width: 17px; height: 2px; border-radius: 2px;
  background: currentColor; transition: transform var(--t-mid) var(--e-out), opacity var(--t-fast) ease;
}
.nav__burger.is-open span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.nav__burger.is-open span:nth-child(2) { opacity: 0; }
.nav__burger.is-open span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }
@media (min-width: 940px) { .nav__burger { display: none; } }
@media (max-width: 620px) { .nav__actions .btn--sm { display: none; } }

.mobilemenu {
  position: absolute; top: var(--nav-h); left: 0; right: 0;
  background: color-mix(in srgb, var(--bg) 96%, transparent);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--line);
  padding: var(--s-2) var(--pad) var(--s-3);
  display: flex; flex-direction: column;
}
.mobilemenu[hidden] { display: none; }
.mobilemenu a {
  padding: 15px 4px;
  font-family: "Outfit", "Outfit Fallback", sans-serif; font-size: 1.06rem; font-weight: 500;
  border-bottom: 1px solid var(--line);
}
.mobilemenu a:last-child { border-bottom: 0; }

/* ---------- 7. HERO ----------------------------------------------------- */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex; align-items: center;
  padding: calc(var(--nav-h) + var(--s-6)) 0 var(--s-7);
  overflow: hidden;
  isolation: isolate;
}

.hero__bg { position: absolute; inset: 0; z-index: -1; overflow: hidden; }

.orb {
  position: absolute; border-radius: 50%; filter: blur(90px); opacity: .55;
  will-change: transform;
}
.orb--1 { width: 620px; height: 620px; top: -14%; left: 50%; margin-left: -310px;
          background: radial-gradient(circle, var(--blue) 0%, transparent 68%); }
.orb--2 { width: 480px; height: 480px; top: 32%; left: -8%;
          background: radial-gradient(circle, var(--blue-700) 0%, transparent 70%); opacity: .5; }
.orb--3 { width: 420px; height: 420px; bottom: -6%; right: -6%;
          background: radial-gradient(circle, #6d5bff 0%, transparent 70%); opacity: .38; }
.orb--4 { width: 720px; height: 720px; top: 50%; left: 50%;
          transform: translate(-50%, -50%);
          background: radial-gradient(circle, var(--blue) 0%, transparent 66%); opacity: .3; }
[data-theme="light"] .orb { opacity: .2; }
[data-theme="light"] .orb--3 { opacity: .14; }

.grid-lines {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(to right, var(--line) 1px, transparent 1px),
    linear-gradient(to bottom, var(--line) 1px, transparent 1px);
  background-size: 72px 72px;
  mask-image: radial-gradient(ellipse 80% 60% at 50% 40%, #000 30%, transparent 78%);
  -webkit-mask-image: radial-gradient(ellipse 80% 60% at 50% 40%, #000 30%, transparent 78%);
  opacity: .8;
}

.hero__triangle {
  position: absolute; bottom: -160px; left: 50%; transform: translateX(-50%);
  width: 860px; height: 560px; max-width: 160vw;
  clip-path: polygon(50% 0%, 100% 100%, 0% 100%);
  background: linear-gradient(180deg, var(--blue-glow), transparent 72%);
  opacity: .3;
}

.hero__inner { position: relative; text-align: center; display: grid; justify-items: center; }

.tagpill {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 8px 18px 8px 14px;
  border: 1px solid var(--line-strong);
  border-radius: var(--r-pill);
  background: var(--glass);
  backdrop-filter: blur(10px);
  font-size: 0.82rem; letter-spacing: 0.04em; color: var(--fg-soft);
  margin-bottom: var(--s-4);
}
.tagpill__dot {
  width: 7px; height: 7px; border-radius: 50%; background: #22c55e;
  box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.55);
  animation: pulse 2.4s infinite;
}
@keyframes pulse {
  70%  { box-shadow: 0 0 0 9px rgba(34, 197, 94, 0); }
  100% { box-shadow: 0 0 0 0 rgba(34, 197, 94, 0); }
}

.hero__logo {
  width: min(210px, 46vw);
  margin-bottom: var(--s-4);
  filter: drop-shadow(0 18px 40px var(--blue-glow));
  animation: floaty 6s ease-in-out infinite;
}
@keyframes floaty {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-12px); }
}

.hero__title {
  font-family: "Outfit", "Outfit Fallback", sans-serif;
  font-size: clamp(2.1rem, 6.4vw, 4.5rem);
  font-weight: 800;
  line-height: 1.05;
  letter-spacing: -0.04em;
  max-width: 16ch;
  text-wrap: balance;
}

.hero__sub {
  margin-top: var(--s-3);
  max-width: 58ch;
  color: var(--fg-soft);
  font-size: clamp(1rem, 2.1vw, 1.16rem);
}

.hero__cta { display: flex; flex-wrap: wrap; gap: 14px; justify-content: center; margin-top: var(--s-5); }

.stats {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: center;
  gap: var(--s-3) var(--s-5);
  margin-top: var(--s-7);
  padding-top: var(--s-4);
  border-top: 1px solid var(--line);
  width: 100%; max-width: 860px;
}
.stat { display: grid; justify-items: center; gap: 2px; min-width: 116px; }
.stat__num {
  font-family: "Outfit", "Outfit Fallback", sans-serif;
  font-size: clamp(1.7rem, 3.6vw, 2.5rem);
  font-weight: 700; letter-spacing: -0.03em;
  background: linear-gradient(180deg, var(--fg), var(--fg-mute));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.stat__label { font-size: 0.8rem; letter-spacing: 0.04em; color: var(--fg-mute); }
.stat__sep { width: 1px; height: 34px; background: var(--line); display: none; }
@media (min-width: 760px) { .stat__sep { display: block; } }

.scrollcue { position: absolute; bottom: 26px; left: 50%; transform: translateX(-50%); }
.scrollcue__mouse {
  display: block; width: 25px; height: 40px;
  border: 1.6px solid var(--line-strong); border-radius: 14px;
  position: relative;
}
.scrollcue__mouse span {
  position: absolute; top: 8px; left: 50%; margin-left: -2px;
  width: 4px; height: 7px; border-radius: 2px; background: var(--blue-400);
  animation: wheel 1.8s var(--e-out) infinite;
}
@keyframes wheel {
  0%   { opacity: 0; transform: translateY(0); }
  35%  { opacity: 1; }
  100% { opacity: 0; transform: translateY(13px); }
}

/* ---------- 8. MARQUEE -------------------------------------------------- */
.marquee {
  border-block: 1px solid var(--line);
  background: var(--bg-2);
  overflow: hidden;
  padding: 16px 0;
  mask-image: linear-gradient(to right, transparent, #000 12%, #000 88%, transparent);
  -webkit-mask-image: linear-gradient(to right, transparent, #000 12%, #000 88%, transparent);
}
.marquee__track {
  display: flex; align-items: center; gap: 34px; width: max-content;
  animation: scrollx 42s linear infinite;
}
.marquee:hover .marquee__track { animation-play-state: paused; }
.marquee__track span {
  font-family: "Outfit", "Outfit Fallback", sans-serif; font-size: 1.02rem; font-weight: 500;
  letter-spacing: 0.02em; color: var(--fg-mute); white-space: nowrap;
}
.marquee__track i { color: var(--blue); font-style: normal; font-size: 0.6rem; }
@keyframes scrollx { to { transform: translateX(-50%); } }

/* ---------- 9. GLASS / CARDS -------------------------------------------- */
.glass {
  position: relative;
  background: var(--glass);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  backdrop-filter: blur(14px) saturate(130%);
  -webkit-backdrop-filter: blur(14px) saturate(130%);
  box-shadow: var(--shadow);
}
.glass::before {
  content: ""; position: absolute; inset: 0;
  border-radius: inherit; background: var(--sheen);
  pointer-events: none;
}

.about {
  display: grid; grid-template-columns: 1fr; gap: var(--s-6); align-items: center;
}
@media (min-width: 940px) { .about { grid-template-columns: 1.05fr 0.95fr; gap: var(--s-7); } }

.ticks { margin-top: var(--s-4); display: grid; gap: 12px; }
.ticks li {
  position: relative; padding-left: 32px; color: var(--fg-soft); font-size: 1rem;
}
.ticks li::before {
  content: ""; position: absolute; left: 0; top: 7px;
  width: 18px; height: 18px; border-radius: 50%;
  background: linear-gradient(135deg, var(--blue-400), var(--blue));
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--blue) 14%, transparent);
}
.ticks li::after {
  content: ""; position: absolute; left: 5px; top: 12px;
  width: 8px; height: 4px;
  border-left: 2px solid #fff; border-bottom: 2px solid #fff;
  transform: rotate(-45deg);
}

.about__panel { padding: var(--s-3); transform-style: preserve-3d; }
.panel__head {
  display: flex; align-items: center; gap: 7px;
  padding-bottom: var(--s-2); border-bottom: 1px solid var(--line); margin-bottom: var(--s-3);
}
.dot { width: 10px; height: 10px; border-radius: 50%; }
.dot--r { background: #ff5f57; } .dot--y { background: #febc2e; } .dot--g { background: #28c840; }
.panel__title {
  margin-left: 8px; font-family: "Outfit", "Outfit Fallback", sans-serif; font-size: 0.86rem;
  letter-spacing: 0.08em; text-transform: uppercase; color: var(--fg-mute);
}
.panel__rows { display: grid; gap: 15px; }
.row { display: grid; grid-template-columns: 128px 1fr; align-items: center; gap: 14px; }
.row__k { font-size: 0.86rem; color: var(--fg-soft); }
.row__bar { height: 8px; border-radius: 6px; background: var(--line); overflow: hidden; }
.row__bar i {
  display: block; height: 100%; width: 0;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--blue-700), var(--blue), var(--blue-400));
  box-shadow: 0 0 12px var(--blue-glow);
  transition: width 1.1s var(--e-out);
}
.is-visible .row__bar i { width: var(--w); }
.panel__foot {
  margin-top: var(--s-3); padding-top: var(--s-2); border-top: 1px solid var(--line);
  font-size: 0.83rem; color: var(--fg-mute);
}

.cards { display: grid; grid-template-columns: 1fr; gap: var(--s-3); }
@media (min-width: 800px) { .cards { grid-template-columns: repeat(3, 1fr); gap: var(--s-3); } }

.card {
  padding: var(--s-4) var(--s-3) var(--s-4);
  overflow: hidden;
  transform-style: preserve-3d;
  transition: border-color var(--t-mid) ease, box-shadow var(--t-mid) ease;
}
.card:hover { border-color: color-mix(in srgb, var(--blue) 55%, transparent); }
.card__glow {
  position: absolute; width: 320px; height: 320px; border-radius: 50%;
  background: radial-gradient(circle, var(--blue-glow), transparent 62%);
  opacity: 0; pointer-events: none;
  transform: translate(-50%, -50%);
  left: var(--mx, 50%); top: var(--my, 50%);
  transition: opacity var(--t-mid) ease;
  filter: blur(14px);
}
.card:hover .card__glow { opacity: .5; }

.card__num {
  position: absolute; top: 16px; right: 20px;
  font-family: "Outfit", "Outfit Fallback", sans-serif; font-size: 2.6rem; font-weight: 800;
  color: var(--fg); opacity: .06; letter-spacing: -0.04em;
}
.card__icon {
  display: grid; place-items: center;
  width: 52px; height: 52px; border-radius: 14px;
  background: linear-gradient(135deg, color-mix(in srgb, var(--blue) 26%, transparent), transparent);
  border: 1px solid var(--line-strong);
  color: var(--blue-400);
  margin-bottom: var(--s-3);
  transition: transform var(--t-mid) var(--e-spring);
}
[data-theme="light"] .card__icon { color: var(--blue); }
.card:hover .card__icon { transform: translateY(-4px) rotate(-6deg) scale(1.06); }

.card__title {
  font-family: "Outfit", "Outfit Fallback", sans-serif; font-size: 1.28rem; font-weight: 600;
  letter-spacing: -0.02em; margin-bottom: 10px;
}
.card__body { color: var(--fg-soft); font-size: 0.97rem; }

.chips { display: flex; flex-wrap: wrap; gap: 7px; margin-top: var(--s-3); }
.chips li {
  padding: 5px 12px; border-radius: var(--r-pill);
  border: 1px solid var(--line); background: var(--glass);
  font-size: 0.76rem; letter-spacing: 0.03em; color: var(--fg-mute);
  white-space: nowrap;
}

/* ---------- 10. STEPS --------------------------------------------------- */
.steps { display: grid; grid-template-columns: 1fr; gap: var(--s-3); counter-reset: s; }
@media (min-width: 700px) { .steps { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1040px) { .steps { grid-template-columns: repeat(4, 1fr); } }

.step {
  position: relative;
  padding: var(--s-4) var(--s-3);
  border-radius: var(--r-md);
  border: 1px solid var(--line);
  background: var(--bg-2);
  transition: transform var(--t-mid) var(--e-out), border-color var(--t-mid) ease,
              background var(--t-mid) ease;
}
[data-theme="light"] .step { background: var(--bg); }
.step:hover { transform: translateY(-6px); border-color: color-mix(in srgb, var(--blue) 50%, transparent); }
.step::after {
  content: ""; position: absolute; left: var(--s-3); right: var(--s-3); top: 0; height: 2px;
  background: linear-gradient(90deg, var(--blue), transparent);
  transform: scaleX(0); transform-origin: left;
  transition: transform var(--t-slow) var(--e-out);
}
.step.is-visible::after { transform: scaleX(1); }
.step__n {
  font-family: "Outfit", "Outfit Fallback", sans-serif; font-size: 0.82rem; font-weight: 700;
  letter-spacing: 0.16em; color: var(--blue-400);
}
[data-theme="light"] .step__n { color: var(--blue); }
.step__t {
  font-family: "Outfit", "Outfit Fallback", sans-serif; font-size: 1.14rem; font-weight: 600;
  margin: 8px 0 8px; letter-spacing: -0.01em;
}
.step__b { color: var(--fg-soft); font-size: 0.94rem; }

/* ---------- 11. CTA ----------------------------------------------------- */
.cta {
  position: relative; overflow: hidden; isolation: isolate;
  padding: var(--s-8) 0;
  text-align: center;
  border-top: 1px solid var(--line);
}
.cta__bg { position: absolute; inset: 0; z-index: -1; }
.cta__inner { display: grid; justify-items: center; }
.cta__title { max-width: 20ch; }
.cta .btn { margin-top: var(--s-4); }

/* ---------- 12. FOOTER -------------------------------------------------- */
.footer { background: var(--bg-2); border-top: 1px solid var(--line); padding-top: var(--s-6); }
[data-theme="light"] .footer { background: var(--bg-3); }

.footer__inner {
  display: flex; flex-direction: column; gap: var(--s-4);
  justify-content: space-between; padding-bottom: var(--s-5);
}
@media (min-width: 760px) { .footer__inner { flex-direction: row; align-items: flex-start; } }

.footer__brand { display: flex; gap: 14px; align-items: flex-start; max-width: 420px; }
.footer__brand img { width: 44px; height: 44px; object-fit: contain; }
.footer__name { font-family: "Outfit", "Outfit Fallback", sans-serif; font-weight: 700; letter-spacing: 0.02em; }
.footer__tag { font-size: 0.9rem; color: var(--fg-mute); margin-top: 4px; }

.footer__nav { display: grid; gap: 10px; }
.footer__nav a {
  color: var(--fg-soft); font-size: 0.94rem; width: fit-content;
  transition: color var(--t-fast) ease, transform var(--t-fast) ease;
}
.footer__nav a:hover { color: var(--blue-400); transform: translateX(3px); }
[data-theme="light"] .footer__nav a:hover { color: var(--blue); }

.footer__base {
  display: flex; flex-direction: column; gap: 8px;
  justify-content: space-between;
  padding: var(--s-3) var(--pad);
  border-top: 1px solid var(--line);
  font-size: 0.84rem; color: var(--fg-mute);
}
@media (min-width: 620px) { .footer__base { flex-direction: row; align-items: center; } }
.footer__base a { border-bottom: 1px solid var(--line-strong); padding-bottom: 1px; }
.footer__base a:hover { color: var(--fg); border-color: var(--blue); }

/* ---------- 14. UTILITIES / EFFECTS ------------------------------------- */
.cursor-glow {
  position: fixed; top: 0; left: 0; width: 380px; height: 380px;
  margin: -190px 0 0 -190px;
  border-radius: 50%;
  background: radial-gradient(circle, var(--blue-glow) 0%, transparent 62%);
  opacity: 0; pointer-events: none; z-index: 1;
  filter: blur(50px);
  transition: opacity 400ms ease;
  will-change: transform;
}
[data-theme="light"] .cursor-glow { opacity: 0 !important; }
@media (hover: hover) and (pointer: fine) {
  .cursor-glow.is-on { opacity: .5; }
}

.totop {
  position: fixed; right: 22px; bottom: 22px; z-index: 101;
  width: 46px; height: 46px; display: grid; place-items: center;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
  background: var(--glass-hi);
  backdrop-filter: blur(12px);
  color: var(--fg);
  opacity: 0; transform: translateY(14px) scale(0.9); pointer-events: none;
  transition: opacity var(--t-mid) ease, transform var(--t-mid) var(--e-spring),
              border-color var(--t-fast) ease;
}
.totop.is-on { opacity: 1; transform: none; pointer-events: auto; }
.totop:hover { border-color: var(--blue); }

/* Scroll reveal */
[data-anim] { opacity: 1; }
.js [data-anim] {
  opacity: 0;
  transition: opacity var(--t-slow) var(--e-out), transform var(--t-slow) var(--e-out);
  transition-delay: var(--d, 0ms);
  will-change: opacity, transform;
}
.js [data-anim="fade-up"]   { transform: translateY(28px); }
.js [data-anim="fade-left"] { transform: translateX(34px); }
.js [data-anim="zoom"]      { transform: scale(0.9); }
.js [data-anim].is-visible  { opacity: 1; transform: none; }

/* Headline split reveal */
.word { display: inline-block; overflow: hidden; vertical-align: top; }
.word > i {
  display: inline-block; font-style: normal;
  transform: translateY(105%);
  transition: transform 820ms var(--e-out);
  transition-delay: var(--d, 0ms);
}
.is-visible .word > i { transform: none; }

/* ---------- 15. REDUCED MOTION ------------------------------------------ */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
  .js [data-anim] { opacity: 1 !important; transform: none !important; }
  .word > i { transform: none !important; }
  .row__bar i { width: var(--w) !important; }
  .cursor-glow { display: none; }
  .marquee__track { animation: none; }
}

/* ---------- 16. SMALL SCREENS ------------------------------------------- */
@media (max-width: 640px) {
  :root { --pad: 20px; }
  .section { padding: var(--s-7) 0; }
  .hero { padding-top: calc(var(--nav-h) + var(--s-4)); }
  .stats { gap: var(--s-3); margin-top: var(--s-5); }
  .stat { min-width: 44%; }
  .row { grid-template-columns: 104px 1fr; }
}

/* ==========================================================================
   17. WORK / GALLERY PAGE  (work.html)
   ========================================================================== */
.page-work { padding-top: 0; }

.workhead {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  text-align: center;
  padding: calc(var(--nav-h) + var(--s-7)) 0 var(--s-6);
}
.workhead__bg { position: absolute; inset: 0; z-index: -1; }
.workhead__inner { display: grid; justify-items: center; }
.workhead__title { max-width: 18ch; }

/* --- Filters --- */
.filters {
  display: flex; flex-wrap: wrap; justify-content: center; gap: 8px;
  margin-bottom: var(--s-2);
}
.filter {
  min-height: 44px;
  padding: 0 20px;
  border-radius: var(--r-pill);
  border: 1px solid var(--line);
  background: var(--glass);
  color: var(--fg-soft);
  font-family: "Outfit", "Outfit Fallback", sans-serif;
  font-size: 0.93rem; font-weight: 500;
  transition: color var(--t-fast) ease, background var(--t-fast) ease,
              border-color var(--t-fast) ease, transform var(--t-fast) var(--e-out);
}
.filter:hover { color: var(--fg); border-color: var(--line-strong); transform: translateY(-2px); }
.filter.is-on {
  color: #fff;
  background: linear-gradient(135deg, var(--blue-400), var(--blue) 60%, var(--blue-700));
  border-color: transparent;
  box-shadow: 0 8px 22px -8px var(--blue-glow);
}

.filters__count {
  text-align: center;
  font-size: 0.84rem;
  color: var(--fg-mute);
  margin-bottom: var(--s-4);
}

/* --- Grid --- */
.grid-work {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: var(--s-3);
}

.tile { position: relative; }
.tile[hidden] { display: none; }

.tile__btn {
  position: relative;
  display: block;
  width: 100%;
  padding: 0;
  overflow: hidden;
  border-radius: var(--r-md);
  border: 1px solid var(--line);
  background: var(--bg-3);
  transition: transform var(--t-mid) var(--e-out),
              border-color var(--t-mid) ease, box-shadow var(--t-mid) ease;
}
.tile__btn:hover {
  transform: translateY(-5px);
  border-color: color-mix(in srgb, var(--blue) 55%, transparent);
  box-shadow: 0 20px 44px -14px rgba(0, 0, 0, 0.6);
}
[data-theme="light"] .tile__btn:hover { box-shadow: 0 20px 44px -16px rgba(16, 24, 40, 0.28); }

.tile__media {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  display: block;
  transition: transform var(--t-slow) var(--e-out), filter var(--t-mid) ease;
}
.tile__btn:hover .tile__media { transform: scale(1.05); }

/* Play badge for video tiles */
.tile__play {
  position: absolute; top: 12px; left: 12px;
  display: grid; place-items: center;
  width: 40px; height: 40px;
  border-radius: 50%;
  background: rgba(10, 13, 20, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.28);
  backdrop-filter: blur(8px);
  color: #fff;
  padding-left: 3px;
  transition: transform var(--t-mid) var(--e-spring), background var(--t-mid) ease;
}
.tile__btn:hover .tile__play { transform: scale(1.12); background: var(--blue); }

/* Caption plate */
.tile__meta {
  position: absolute; left: 0; right: 0; bottom: 0;
  display: flex; flex-direction: column; gap: 3px;
  padding: 34px 14px 13px;
  text-align: left;
  background: linear-gradient(to top, rgba(6, 8, 14, 0.92) 22%, rgba(6, 8, 14, 0));
}
.tile__title {
  font-family: "Outfit", "Outfit Fallback", sans-serif;
  font-size: 0.95rem; font-weight: 600; color: #fff;
  letter-spacing: -0.01em;
}
.tile__tag {
  font-size: 0.72rem; letter-spacing: 0.1em; text-transform: uppercase;
  color: #b9c6de;
}

/* --- Lightbox --- */
.lb {
  position: fixed; inset: 0; z-index: 200;
  display: grid; place-items: center;
  padding: clamp(16px, 4vw, 48px);
  background: rgba(4, 6, 12, 0.94);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  opacity: 0;
  transition: opacity var(--t-mid) ease;
}
.lb[hidden] { display: none; }
.lb.is-on { opacity: 1; }

.lb__stage {
  margin: 0;
  display: grid;
  justify-items: center;
  gap: 14px;
  max-width: min(1100px, 100%);
  max-height: 100%;
}
.lb__media {
  display: grid;
  place-items: center;
  max-height: min(76vh, 900px);
  transform: scale(0.96);
  transition: transform var(--t-mid) var(--e-spring);
}
.lb.is-on .lb__media { transform: none; }
.lb__media img, .lb__media video {
  max-width: 100%;
  max-height: min(76vh, 900px);
  width: auto; height: auto;
  border-radius: var(--r-md);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6);
  background: #05070c;
}

.lb__cap { text-align: center; max-width: 60ch; }
.lb__cap strong {
  display: block;
  font-family: "Outfit", "Outfit Fallback", sans-serif;
  font-size: 1.05rem; font-weight: 600; color: #fff;
}
.lb__cap span { font-size: 0.88rem; color: #a8b2c6; }

.lb__close, .lb__nav {
  position: absolute;
  display: grid; place-items: center;
  width: 46px; height: 46px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  transition: background var(--t-fast) ease, border-color var(--t-fast) ease,
              transform var(--t-fast) var(--e-spring);
}
.lb__close:hover, .lb__nav:hover {
  background: var(--blue); border-color: transparent; transform: scale(1.08);
}
.lb__close { top: 18px; right: 18px; }
.lb__nav--prev { left: 14px; top: 50%; margin-top: -23px; }
.lb__nav--next { right: 14px; top: 50%; margin-top: -23px; }

@media (max-width: 640px) {
  .grid-work { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
  .tile__meta { padding: 26px 10px 10px; }
  .tile__title { font-size: 0.84rem; }
  .lb__nav--prev { left: 8px; }
  .lb__nav--next { right: 8px; }
  .lb__close { top: 10px; right: 10px; }
}

@media (prefers-reduced-motion: reduce) {
  .tile__btn:hover { transform: none; }
  .tile__btn:hover .tile__media { transform: none; }
  .lb__media { transform: none !important; }
}

.cards__more { text-align: center; margin-top: var(--s-5); }

/* ==========================================================================
   18. TEAM PAGE  (team.html)
   ========================================================================== */
.people {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--s-5);
}
@media (min-width: 860px) {
  .people { grid-template-columns: repeat(2, 1fr); gap: var(--s-6); }
}

.person { display: flex; flex-direction: column; gap: var(--s-3); }

.person__frame {
  position: relative;
  overflow: hidden;
  border-radius: var(--r-lg);
  border: 1px solid var(--line);
  background: var(--bg-3);
  box-shadow: var(--shadow);
}
/* a whisper of brand colour over the portrait, so the two shots — taken in
   different places under different light — read as one set */
.person__frame::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(170deg, transparent 62%, color-mix(in srgb, var(--blue) 20%, transparent));
  pointer-events: none;
  opacity: .55;
  transition: opacity var(--t-mid) ease;
}
.person:hover .person__frame::after { opacity: .3; }

.person__photo {
  display: block;
  width: 100%;
  /* the source headshots are square and well composed — don't crop them */
  aspect-ratio: 1 / 1;
  object-fit: cover;
  object-position: 50% 50%;
  transition: transform var(--t-slow) var(--e-out);
}
.person:hover .person__photo { transform: scale(1.03); }

.person__body { display: flex; flex-direction: column; gap: 10px; }

.person__role {
  font-family: "Outfit", "Outfit Fallback", sans-serif;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--blue-400);
}
[data-theme="light"] .person__role { color: var(--blue); }

.person__name {
  font-family: "Outfit", "Outfit Fallback", sans-serif;
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.1;
  margin: 0;
}

.person__bio { color: var(--fg-soft); font-size: 1rem; max-width: 46ch; }

.person__focus { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 2px; }
.person__focus li {
  padding: 5px 12px;
  border-radius: var(--r-pill);
  border: 1px solid var(--line);
  background: var(--glass);
  font-size: 0.76rem;
  letter-spacing: 0.03em;
  color: var(--fg-mute);
  white-space: nowrap;
}

/* the principles list on this page is 3-up, not the 4-up used on the home page */
.page-team .steps { grid-template-columns: 1fr; }
@media (min-width: 760px)  { .page-team .steps { grid-template-columns: repeat(3, 1fr); } }

@media (prefers-reduced-motion: reduce) {
  .person:hover .person__photo { transform: none; }
}
