/* =========================================================================
   Apex Financial Solutions — experience layer
   Loaded after site.css. Adds the 3D glass system, the animated hero scene,
   the financial icon treatments, and the bolder typographic scale.

   Everything here is additive. site.css still defines the underlying layout,
   so removing this file leaves a working, if plainer, site.
   ========================================================================= */

/* ---------- 1. Extended tokens ---------- */

:root {
  /* glass on dark fields */
  --glass-bg: linear-gradient(150deg, rgba(255, 255, 255, 0.115), rgba(255, 255, 255, 0.035) 46%, rgba(165, 204, 237, 0.06));
  --glass-border: rgba(165, 204, 237, 0.24);
  --glass-hi: rgba(255, 255, 255, 0.55);
  --glass-blur: 18px;
  --glass-shadow: 0 32px 70px -34px rgba(0, 0, 0, 0.75);

  /* glass on light fields */
  --glass-bg-light: linear-gradient(150deg, rgba(255, 255, 255, 0.92), rgba(244, 247, 251, 0.72));
  --glass-border-light: rgba(11, 21, 47, 0.09);
  --glass-shadow-light: 0 30px 60px -34px rgba(11, 21, 47, 0.35);

  /* accent gradients, kept inside the brand family */
  --grad-brand: linear-gradient(96deg, var(--blue-light) 0%, #7fb6e8 38%, var(--blue-mid) 100%);
  --grad-deep: linear-gradient(140deg, #16264c 0%, #0b152f 55%, #14284f 100%);
  --grad-line: linear-gradient(90deg, transparent, var(--blue-light), transparent);

  /* 3D */
  --persp: 1250px;
  --tilt: 0deg;

  /* Slightly tighter vertical rhythm than site.css: the page carries more
     visual weight per section now. */
  --section-y: clamp(3.4rem, 6.6vw, 6rem);

  --ease-soft: cubic-bezier(0.32, 0.72, 0.24, 1);
}

/* ---------- 2. Bolder typography ---------- */

:root {
  --fs-display: clamp(2.25rem, 3.5vw, 3.4rem);
  --fs-h1: clamp(2.05rem, 3.8vw, 3.15rem);
  --fs-h2: clamp(1.75rem, 3vw, 2.6rem);
}

.hero h1,
.page-hero h1,
.section-head h2,
.cta-band h2,
.display {
  font-weight: 680;
  letter-spacing: -0.032em;
}

.hero h1 { max-width: 21ch; line-height: 1.08; }

/* Gradient accent for one phrase inside a heading. */
.grad {
  background: var(--grad-brand);
  -webkit-background-clip: text;
          background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}

/* Kickers get a glass pill on dark fields so they read as a label, not stray text. */
.kicker--pill {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  margin-bottom: 1.35rem;
  padding: 0.5rem 0.95rem 0.5rem 0.8rem;
  background: rgba(165, 204, 237, 0.09);
  border: 1px solid var(--glass-border);
  border-radius: 100px;
  backdrop-filter: blur(10px);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--blue-light);
}

.kicker--pill::before {
  content: "";
  width: 7px; height: 7px;
  flex: none;
  border-radius: 50%;
  background: var(--blue-light);
  box-shadow: 0 0 0 4px rgba(165, 204, 237, 0.16);
  animation: pulse-dot 2.6s var(--ease) infinite;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.45; transform: scale(0.82); }
}

/* ---------- 3. Scroll progress ---------- */

.scroll-progress {
  position: fixed;
  inset: 0 0 auto;
  z-index: 120;
  height: 3px;
  background: transparent;
  pointer-events: none;
}

.scroll-progress span {
  display: block;
  height: 100%;
  width: 100%;
  transform: scaleX(0);
  transform-origin: left center;
  background: var(--grad-brand);
  box-shadow: 0 0 14px rgba(165, 204, 237, 0.7);
}

/* ---------- 4. Icons ---------- */

.icon-sprite {
  position: absolute;
  width: 0; height: 0;
  overflow: hidden;
}

.icon {
  display: block;
  width: 24px; height: 24px;
  flex: none;
}

/* Glass tile holding an icon. Used on cards, pillars, and stats. */
.icon-tile {
  display: grid;
  place-items: center;
  width: 52px; height: 52px;
  flex: none;
  position: relative;
  border-radius: 14px;
  background: linear-gradient(150deg, rgba(36, 81, 164, 0.12), rgba(165, 204, 237, 0.16));
  border: 1px solid rgba(36, 81, 164, 0.18);
  color: var(--blue);
  overflow: hidden;
  transition: transform var(--dur) var(--ease-out), border-color var(--dur) var(--ease),
              color var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
}

/* moving sheen */
.icon-tile::after {
  content: "";
  position: absolute;
  inset: -60% -120%;
  background: linear-gradient(72deg, transparent 42%, rgba(255, 255, 255, 0.55) 50%, transparent 58%);
  transform: translateX(-70%);
  transition: transform 0.85s var(--ease-out);
}

.icon-tile .icon { width: 26px; height: 26px; }

.card:hover .icon-tile,
.pillar:hover .icon-tile {
  transform: translateY(-3px) scale(1.04);
  border-color: rgba(36, 81, 164, 0.4);
  box-shadow: 0 14px 28px -16px rgba(36, 81, 164, 0.55);
}

.card:hover .icon-tile::after,
.pillar:hover .icon-tile::after { transform: translateX(70%); }

.icon-tile--dark {
  background: linear-gradient(150deg, rgba(165, 204, 237, 0.26), rgba(255, 255, 255, 0.07));
  border-color: rgba(165, 204, 237, 0.42);
  color: #cfe6f8;
  backdrop-filter: blur(10px);
}

.pillar:hover .icon-tile--dark,
.card--dark:hover .icon-tile--dark {
  border-color: rgba(165, 204, 237, 0.7);
  box-shadow: 0 14px 28px -16px rgba(165, 204, 237, 0.45);
}

.icon-tile--lg { width: 62px; height: 62px; border-radius: 18px; }
.icon-tile--lg .icon { width: 30px; height: 30px; }

/* ---------- 5. Glass surfaces ---------- */

.glass {
  position: relative;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 18px;
  backdrop-filter: blur(var(--glass-blur)) saturate(150%);
  -webkit-backdrop-filter: blur(var(--glass-blur)) saturate(150%);
  box-shadow: var(--glass-shadow), inset 0 1px 0 rgba(255, 255, 255, 0.14);
  isolation: isolate;
}

/* bright top edge, the detail that makes glass read as glass */
.glass::before {
  content: "";
  position: absolute;
  top: 0; left: 12%; right: 12%;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--glass-hi), transparent);
  pointer-events: none;
}

.glass--light {
  background: var(--glass-bg-light);
  border-color: var(--glass-border-light);
  box-shadow: var(--glass-shadow-light), inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

/* ---------- 6. The header, as glass ---------- */

/* Opaque enough to stay clean white over the dark sections; a lower alpha
   pulls navy through the blur and reads as dirty grey. */
.site-header.is-stuck,
.site-header:not(.site-header--overlay) {
  background: rgba(255, 255, 255, 0.93);
  backdrop-filter: blur(20px) saturate(170%);
  -webkit-backdrop-filter: blur(20px) saturate(170%);
}

.site-header--overlay.is-stuck { background: rgba(255, 255, 255, 0.93); }

/* ---------- 7. Hero: the 3D scene ---------- */

.hero {
  background: var(--grad-deep);
  isolation: isolate;
}

.hero__grid { align-items: center; }

@media (min-width: 981px) {
  .hero__grid { grid-template-columns: minmax(0, 1.02fr) minmax(0, 0.98fr); }
}

/* Soft moving aurora behind the whole hero. */
.hero__aurora {
  position: absolute;
  inset: -20% -10%;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(38% 42% at 78% 18%, rgba(50, 106, 179, 0.5), transparent 70%),
    radial-gradient(32% 38% at 18% 78%, rgba(36, 81, 164, 0.42), transparent 72%),
    radial-gradient(26% 30% at 62% 82%, rgba(165, 204, 237, 0.18), transparent 74%);
  filter: blur(28px);
  animation: aurora 22s var(--ease) infinite alternate;
}

@keyframes aurora {
  0%   { transform: translate3d(0, 0, 0) scale(1); }
  50%  { transform: translate3d(-2.5%, 1.8%, 0) scale(1.07); }
  100% { transform: translate3d(2%, -2%, 0) scale(1.03); }
}

/* --- stage --- */

.stage {
  position: relative;
  container-type: inline-size;
  width: 100%;
  aspect-ratio: 1 / 1;
  perspective: var(--persp);
  /* Centred origin keeps the perspective magnification symmetrical, so panel
     insets are enough to guarantee the scene stays inside its column. */
  perspective-origin: 50% 50%;
}

.stage__scene {
  position: absolute;
  inset: 0;
  transform-style: preserve-3d;
  transform: rotateX(var(--sx, 0deg)) rotateY(var(--sy, 0deg));
  transition: transform 0.5s var(--ease-soft);
}

/* Receding grid plane. Gives the panels something to float above. */
.stage__floor {
  position: absolute;
  left: -18%; right: -18%;
  bottom: -2%;
  height: 62%;
  transform: rotateX(74deg) translateZ(-60px);
  transform-origin: bottom center;
  background-image:
    linear-gradient(to right, rgba(165, 204, 237, 0.3) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(165, 204, 237, 0.3) 1px, transparent 1px);
  background-size: 8cqw 8cqw;
  -webkit-mask-image: linear-gradient(to top, #000, transparent 78%);
          mask-image: linear-gradient(to top, #000, transparent 78%);
  pointer-events: none;
}

/* Orbiting square, straight from the brand pattern. */
.stage__orbit {
  position: absolute;
  top: 8%; right: 6%;
  width: 16cqw; height: 16cqw;
  border: 1px solid rgba(165, 204, 237, 0.35);
  border-radius: 6px;
  transform: translateZ(-40px) rotate(14deg);
  animation: orbit-spin 26s linear infinite;
  pointer-events: none;
}

.stage__orbit::after {
  content: "";
  position: absolute;
  inset: 22%;
  border: 1px solid rgba(165, 204, 237, 0.22);
  border-radius: 3px;
}

@keyframes orbit-spin {
  to { transform: translateZ(-40px) rotate(374deg); }
}

/* --- panels --- */

/* Depth lives on the `translate` property, which composes with the `transform`
   used by the idle float instead of overwriting it. */
.panel {
  position: absolute;
  translate: 0 0 var(--z, 0px);
  padding: 4.2cqw;
  border-radius: 20px;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  backdrop-filter: blur(var(--glass-blur)) saturate(160%);
  -webkit-backdrop-filter: blur(var(--glass-blur)) saturate(160%);
  box-shadow: var(--glass-shadow), inset 0 1px 0 rgba(255, 255, 255, 0.16);
  color: var(--on-dark);
  transform-style: preserve-3d;
  will-change: transform;
}

.panel::before {
  content: "";
  position: absolute;
  top: 0; left: 14%; right: 14%;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--glass-hi), transparent);
}

.panel__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2cqw;
  margin-bottom: 3.4cqw;
}

.panel__label {
  font-size: 2.35cqw;
  font-weight: 700;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  white-space: nowrap;
  color: var(--blue-light);
}

.panel__title {
  font-size: 3.6cqw;
  font-weight: 650;
  letter-spacing: -0.02em;
  color: #fff;
  line-height: 1.2;
}

.panel__pill {
  display: inline-flex;
  align-items: center;
  gap: 1.1cqw;
  padding: 1cqw 2.1cqw;
  font-size: 2.2cqw;
  font-weight: 650;
  letter-spacing: 0.05em;
  border-radius: 100px;
  background: rgba(165, 204, 237, 0.14);
  border: 1px solid rgba(165, 204, 237, 0.28);
  color: var(--blue-light);
  white-space: nowrap;
}

.panel__pill i {
  width: 1.5cqw; height: 1.5cqw;
  border-radius: 50%;
  background: currentColor;
  animation: pulse-dot 2.4s var(--ease) infinite;
}

/* main dashboard panel */
/* Scene layout. Each panel is inset far enough from the stage edge that
   perspective magnification at its depth still lands inside the column:
   inset > (depth / perspective) x 50. */
.panel--board {
  top: 3%;
  left: 0;
  width: 60cqw;
  --z: 0px;
}

/* bar chart */
.chart {
  display: flex;
  align-items: flex-end;
  gap: 1.9cqw;
  height: 18cqw;
}

.chart__bar {
  position: relative;
  flex: 1;
  border-radius: 3px 3px 2px 2px;
  background: linear-gradient(to top, rgba(165, 204, 237, 0.26), rgba(165, 204, 237, 0.72));
  height: var(--h, 40%);
  transform-origin: bottom center;
}

.chart__bar--peak {
  background: linear-gradient(to top, var(--blue-mid), #cfe6f8);
  box-shadow: 0 0 22px rgba(165, 204, 237, 0.6);
}

.chart__axis {
  display: flex;
  justify-content: space-between;
  margin-top: 2.2cqw;
  padding-top: 2cqw;
  border-top: 1px solid var(--line-dark);
  font-size: 2.1cqw;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--on-dark-70);
}

/* sparkline */
.spark { display: block; width: 100%; height: auto; }
.spark__line { fill: none; stroke: var(--blue-light); stroke-width: 2.4; stroke-linecap: round; }
.spark__area { fill: url(#sparkFill); opacity: 0.9; }
.spark__dot { fill: #fff; stroke: var(--blue-light); stroke-width: 2; }

/* checklist panel */
.panel--close {
  bottom: 3%;
  left: 4%;
  width: 50cqw;
  --z: 70px;
}

.ticks { display: grid; gap: 2.1cqw; }

.ticks li {
  display: flex;
  align-items: center;
  gap: 2.1cqw;
  font-size: 2.55cqw;
  line-height: 1.25;
  white-space: nowrap;
  color: var(--on-dark);
}

.ticks span {
  display: grid;
  place-items: center;
  width: 4.6cqw; height: 4.6cqw;
  flex: none;
  border-radius: 50%;
  border: 1px solid rgba(165, 204, 237, 0.4);
  color: var(--blue-light);
}

.ticks span svg { width: 2.6cqw; height: 2.6cqw; }

.ticks li[data-state="done"] span {
  background: var(--grad-brand);
  border-color: transparent;
  color: var(--navy);
}

.ticks li[data-state="active"] span {
  border-color: var(--blue-light);
  box-shadow: 0 0 0 0.7cqw rgba(165, 204, 237, 0.14);
}

.ticks li[data-state="active"] span::after {
  content: "";
  width: 1.7cqw; height: 1.7cqw;
  border-radius: 50%;
  background: var(--blue-light);
  animation: pulse-dot 2s var(--ease) infinite;
}

/* progress ring panel */
.panel--ring {
  right: 5%;
  bottom: 4%;
  width: 27cqw;
  text-align: center;
  --z: 90px;
}

.ring { position: relative; display: block; width: 100%; }
.ring svg { display: block; width: 100%; height: auto; transform: rotate(-90deg); }
.ring__track { fill: none; stroke: rgba(165, 204, 237, 0.16); stroke-width: 9; }

.ring__value {
  fill: none;
  stroke: url(#ringGrad);
  stroke-width: 9;
  stroke-linecap: round;
  stroke-dasharray: 283;
  stroke-dashoffset: 283;
}

.ring__num {
  position: absolute;
  inset: 0;
  display: grid;
  grid-auto-flow: column;
  align-items: baseline;
  justify-content: center;
  align-content: center;
  gap: 0.06em;
  font-size: 6.4cqw;
  font-weight: 700;
  letter-spacing: -0.04em;
  font-variant-numeric: tabular-nums;
  color: #fff;
}

.ring__num sub {
  font-size: 0.46em;
  font-weight: 600;
  vertical-align: baseline;
  bottom: 0;
  color: var(--blue-light);
}

.panel--ring .panel__label { display: block; margin-top: 2.4cqw; }

/* tax chips panel */
.panel--chips {
  top: 0;
  right: 0;
  width: 38cqw;
  --z: 40px;
}

.chips-mini { display: flex; flex-wrap: wrap; gap: 1.5cqw; }

.chips-mini li {
  padding: 1.1cqw 2cqw;
  font-size: 2.2cqw;
  font-weight: 650;
  letter-spacing: 0.07em;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(165, 204, 237, 0.22);
  color: var(--on-dark);
}

.chips-mini li:first-child {
  background: rgba(165, 204, 237, 0.18);
  border-color: rgba(165, 204, 237, 0.4);
  color: #fff;
}

/* floating status chip */
.panel--flag {
  right: 7%;
  top: 40%;
  width: 40cqw;
  padding: 2.8cqw 3.4cqw;
  border-radius: 14px;
  --z: 110px;
}

.flag { display: flex; align-items: center; gap: 2.4cqw; }

.flag .icon-tile {
  width: 8.4cqw; height: 8.4cqw;
  border-radius: 10px;
}

.flag .icon-tile .icon { width: 4.4cqw; height: 4.4cqw; }
.flag b { display: block; font-size: 2.7cqw; font-weight: 650; color: #fff; line-height: 1.25; white-space: nowrap; }
.flag small { display: block; margin-top: 0.5cqw; font-size: 2.15cqw; color: var(--on-dark-70); white-space: nowrap; }

/* Idle float. Only `transform` is animated, so each panel keeps the depth set
   on its `translate` property. Used when GSAP is not driving the scene. */
@keyframes float-up {
  from { transform: translateY(1.4cqw); }
  to   { transform: translateY(-1.8cqw); }
}

@keyframes float-down {
  from { transform: translateY(-1.6cqw); }
  to   { transform: translateY(1.5cqw); }
}

.panel--board { animation: float-up 9s var(--ease) infinite alternate; }
.panel--close { animation: float-down 11s var(--ease) infinite alternate; }
.panel--ring  { animation: float-up 8s var(--ease) infinite alternate; }
.panel--chips { animation: float-down 10s var(--ease) infinite alternate; }
.panel--flag  { animation: float-up 7.5s var(--ease) infinite alternate; }

/* Mobile: flatten the depth, drop the busiest panels, keep the idea. */
@media (max-width: 980px) {
  .stage { aspect-ratio: 1 / 0.92; max-width: 560px; margin-inline: auto; }
  .panel--chips { display: none; }
  .panel--flag { right: 2%; top: 50%; width: 46cqw; }
}

@media (max-width: 560px) {
  .stage { aspect-ratio: 1 / 1.05; }
  .panel--flag,
  .stage__orbit { display: none; }
  .panel--board { width: 84cqw; left: 0; top: 8%; }
  .panel--close { width: 56cqw; }
  .panel--ring { width: 38cqw; bottom: 20%; }
}

/* ---------- 8. Hero supporting detail ---------- */

.hero__credibility li { font-weight: 500; }

.hero__credibility li::before {
  width: 9px; height: 9px;
  background: var(--grad-brand);
  box-shadow: 0 0 10px rgba(165, 204, 237, 0.6);
}

/* Scroll hint under the hero. */
.scroll-hint {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  margin-top: 2.25rem;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--on-dark-70);
}

.scroll-hint i {
  position: relative;
  display: block;
  width: 24px; height: 38px;
  flex: none;
  border: 1.5px solid rgba(165, 204, 237, 0.5);
  border-radius: 13px;
}

.scroll-hint i::after {
  content: "";
  position: absolute;
  top: 6px; left: 50%;
  width: 3px; height: 7px;
  margin-left: -1.5px;
  border-radius: 2px;
  background: var(--blue-light);
  animation: wheel 2.1s var(--ease) infinite;
}

@keyframes wheel {
  0%, 100% { transform: translateY(0); opacity: 1; }
  60% { transform: translateY(11px); opacity: 0.2; }
}

/* ---------- 9. Cards, upgraded ---------- */

/* The 3D tilt is written by GSAP straight onto `transform`, so the hover lift
   uses the separate `translate` property. The two compose instead of one
   overwriting the other. */
.card {
  border-radius: 18px;
  background: linear-gradient(165deg, #fff, #fbfcfe);
  transform-style: preserve-3d;
  transition: translate 0.45s var(--ease-soft), box-shadow var(--dur) var(--ease),
              border-color var(--dur) var(--ease);
}

.card:hover,
.card:focus-within { translate: 0 -6px; }

/* gradient hairline that appears on hover */
.card::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: var(--grad-brand);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
          mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
          mask-composite: exclude;
  opacity: 0;
  transition: opacity var(--dur) var(--ease);
  pointer-events: none;
}

.card:hover::after,
.card:focus-within::after { opacity: 0.85; }

/* pointer-tracked glare */
.card__glare {
  position: absolute;
  inset: 0;
  border-radius: inherit;
  opacity: 0;
  background: radial-gradient(22rem 22rem at var(--mx, 50%) var(--my, 0%),
    rgba(165, 204, 237, 0.4), transparent 62%);
  transition: opacity var(--dur) var(--ease);
  pointer-events: none;
  mix-blend-mode: multiply;
}

.card:hover .card__glare { opacity: 0.55; }

.card__head {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 0.35rem;
}

.card__head .card__num { margin-left: auto; }

.card--dark {
  background: var(--glass-bg);
  border-color: var(--glass-border);
  backdrop-filter: blur(14px) saturate(150%);
  -webkit-backdrop-filter: blur(14px) saturate(150%);
}

.card--dark .card__glare { mix-blend-mode: screen; }

.card--dark:hover {
  border-color: rgba(165, 204, 237, 0.45);
  box-shadow: 0 30px 60px -32px rgba(0, 0, 0, 0.7);
}

/* ---------- 10. Stats, as glass tiles with sparklines ---------- */

.stats {
  gap: 1px;
  border-radius: 20px;
  overflow: hidden;
}

.stat {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  overflow: hidden;
  transition: background-color var(--dur) var(--ease);
}

.stat::after {
  content: "";
  position: absolute;
  inset: auto 0 0 0;
  height: 2px;
  background: var(--grad-brand);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.7s var(--ease-out);
}

.stat:hover { background: #fcfdff; }
.stat:hover::after { transform: scaleX(1); }

.stat .icon-tile {
  width: 42px; height: 42px;
  margin-bottom: 1.1rem;
  border-radius: 11px;
}

.stat .icon-tile .icon { width: 22px; height: 22px; }

/* Tighter than the base rule: the very large numerals carry a lot of leading,
   which left the tiles looking half empty. */
.stat {
  padding: clamp(1.4rem, 2.4vw, 2rem);
  gap: 0;
}

.stat dt {
  font-size: clamp(2.1rem, 3.4vw, 3.3rem);
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

.stat dd { margin-top: 0.55rem; }

/* ---------- 11. Pillars: pinned scroll sequence ---------- */

.pillars {
  position: relative;
  background: transparent;
  border: 0;
  gap: clamp(1rem, 2vw, 1.5rem);
}

.pillar {
  position: relative;
  padding: clamp(1.75rem, 3vw, 2.6rem);
  border-radius: 20px;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  backdrop-filter: blur(16px) saturate(150%);
  -webkit-backdrop-filter: blur(16px) saturate(150%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
  transition: transform 0.6s var(--ease-soft), border-color var(--dur) var(--ease),
              box-shadow var(--dur) var(--ease);
}

.pillar::before {
  content: "";
  position: absolute;
  top: 0; left: 16%; right: 16%;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--glass-hi), transparent);
}

.pillar:hover {
  transform: translateY(-5px);
  border-color: rgba(165, 204, 237, 0.42);
  box-shadow: 0 30px 60px -34px rgba(0, 0, 0, 0.7), inset 0 1px 0 rgba(255, 255, 255, 0.16);
}

.pillar__step {
  display: block;
  margin-bottom: 1.1rem;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--blue-light);
}

/* progress rail drawn as the section scrolls */
.rail {
  position: relative;
  height: 1px;
  margin-bottom: clamp(2rem, 4vw, 3rem);
  background: var(--line-dark);
}

.rail span {
  position: absolute;
  inset: 0 auto 0 0;
  width: 100%;
  transform: scaleX(0);
  transform-origin: left;
  background: var(--grad-brand);
  box-shadow: 0 0 12px rgba(165, 204, 237, 0.7);
}

/* ---------- 12. CTA band ---------- */

.cta-band {
  background: var(--grad-deep);
  isolation: isolate;
}

.cta-band__glow {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(46% 70% at 82% 30%, rgba(50, 106, 179, 0.55), transparent 70%),
    radial-gradient(40% 60% at 12% 80%, rgba(36, 81, 164, 0.4), transparent 72%);
}

.cta-band .btn--light {
  box-shadow: 0 24px 48px -22px rgba(0, 0, 0, 0.6);
}

/* ---------- 12b. Internal page heroes ----------
   Applied by selector rather than by adding classes to fifteen fragments. */

.page-hero {
  background: var(--grad-deep);
  isolation: isolate;
}

.page-hero::after {
  content: "";
  position: absolute;
  inset: -30% -10% auto;
  height: 150%;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(34% 46% at 84% 22%, rgba(50, 106, 179, 0.45), transparent 70%),
    radial-gradient(28% 40% at 14% 84%, rgba(36, 81, 164, 0.36), transparent 72%);
  filter: blur(22px);
}

/* The kicker becomes a glass pill on dark page headers, with a pulsing dot in
   place of the usual rule. */
.page-hero .kicker {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.5rem 0.95rem 0.5rem 0.8rem;
  background: rgba(165, 204, 237, 0.09);
  border: 1px solid var(--glass-border);
  border-radius: 100px;
  backdrop-filter: blur(10px);
  font-size: 0.72rem;
}

.page-hero .kicker::before {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--blue-light);
  box-shadow: 0 0 0 4px rgba(165, 204, 237, 0.16);
  animation: pulse-dot 2.6s var(--ease) infinite;
}

/* Closing CTA glow, without needing an extra element on every page. */
.cta-band::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(46% 70% at 82% 30%, rgba(50, 106, 179, 0.5), transparent 70%),
    radial-gradient(40% 60% at 12% 80%, rgba(36, 81, 164, 0.38), transparent 72%);
}

/* ---------- 12c. Shared components across the internal pages ---------- */

/* Engagement process steps: numbered glass tiles. */
.steps {
  background: transparent;
  border: 0;
  gap: clamp(0.75rem, 1.5vw, 1.15rem);
}

.step {
  border-radius: 16px;
  border: 1px solid var(--line);
  background: linear-gradient(165deg, #fff, #f8fafd);
  transition: transform 0.5s var(--ease-soft), box-shadow var(--dur) var(--ease),
              border-color var(--dur) var(--ease);
}

.step:hover {
  transform: translateY(-4px);
  border-color: rgba(36, 81, 164, 0.28);
  box-shadow: 0 24px 44px -30px rgba(11, 21, 47, 0.45);
  background: #fff;
}

.step b {
  background: var(--grad-brand);
  -webkit-background-clip: text;
          background-clip: text;
  -webkit-text-fill-color: transparent;
  font-size: 2.3rem;
  font-weight: 700;
  letter-spacing: -0.05em;
}

.section--dark .step,
.section--dark .steps { background: transparent; }

/* Accordion rows pick up a soft highlight as they open. */
.ac {
  border-radius: 14px;
  padding-inline: clamp(0.5rem, 1.5vw, 1.15rem);
  transition: background-color var(--dur) var(--ease);
}

.ac:has(.ac__head[aria-expanded="true"]) { background: rgba(36, 81, 164, 0.04); }
.section--dark .ac:has(.ac__head[aria-expanded="true"]) { background: rgba(165, 204, 237, 0.06); }

.ac__icon { transition: transform var(--dur) var(--ease-out), background-color var(--dur) var(--ease); }

.ac__head[aria-expanded="true"] .ac__icon {
  background: var(--grad-brand);
  border-color: transparent;
  color: var(--navy);
}

/* Case studies and downloads. */
.case { background: linear-gradient(165deg, #fff, #f9fbfd); }
.case:hover { border-color: rgba(36, 81, 164, 0.24); }

/* Enquiry form as a light glass card. */
.form {
  background: var(--glass-bg-light);
  border-color: var(--glass-border-light);
  box-shadow: var(--glass-shadow-light);
  backdrop-filter: blur(12px);
}

.aside-card {
  background: var(--glass-bg-light);
  border-color: var(--glass-border-light);
}

/* Credential and client plates. */
.trust__list li { transition: background-color var(--dur) var(--ease), transform var(--dur) var(--ease); }
.trust__list li:hover { transform: translateY(-2px); }

/* ---------- 13. Section rhythm and headings ---------- */

.section-head h2 { position: relative; }

/* A thin brand rule that draws itself in beside section headings. */
.section-head--split > div:first-child { position: relative; }

.insight,
.case,
.download,
.form,
.aside-card,
.steps,
.trust__list,
.client-logo-marquee { border-radius: 18px; }

.insight { transition: transform 0.5s var(--ease-soft), box-shadow var(--dur) var(--ease), border-color var(--dur) var(--ease); }
.insight:hover { transform: translateY(-6px); }

/* ---------- 14. Buttons ----------
   Flat brand colour, no gradient. The wipe overlay from site.css is switched
   off and replaced by a small, quiet shift on hover. */

.btn {
  border-radius: 100px;
  letter-spacing: 0.005em;
  transition: background-color var(--dur-fast) var(--ease),
              color var(--dur-fast) var(--ease),
              box-shadow var(--dur-fast) var(--ease),
              translate var(--dur-fast) var(--ease);
}

.btn::after { display: none; }

.btn:not(.btn--ghost):not(.btn--light) {
  background: var(--blue);
  color: #fff;
}

.btn:not(.btn--ghost):not(.btn--light):hover {
  background: #1d4489;
  color: #fff;
  translate: 0 -1px;
  box-shadow: 0 10px 22px -14px rgba(11, 21, 47, 0.55);
}

.btn--light {
  background: #fff;
  color: var(--navy);
}

.btn--light:hover {
  background: #eef4fb;
  color: var(--navy);
  translate: 0 -1px;
  box-shadow: 0 10px 22px -14px rgba(0, 0, 0, 0.45);
}

.btn--ghost:hover {
  translate: 0 -1px;
  box-shadow: none;
}

.hero .btn--ghost:hover,
.page-hero .btn--ghost:hover,
.cta-band .btn--ghost:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
}

.btn:active { translate: 0 0; }

.btn__arrow { transition: transform var(--dur-fast) var(--ease); }
.btn:hover .btn__arrow { transform: translateX(2px); }

.chip { border-radius: 100px; }

/* ---------- 15. Motion states owned by GSAP ----------
   When GSAP is present it takes over every transform on the hero panels and on
   the scene, so the CSS keyframes and transitions stand down to avoid two
   systems writing the same property. */

/* GSAP writes depth into its own transform matrix, so the CSS `translate`
   depth is cleared to stop the two stacking up. */
html.gsap-ready .panel { animation: none; translate: none; }
html.gsap-ready .stage__scene { transition: none; }

/* site.css runs a CSS keyframe entrance on the hero; GSAP replaces it. */
html.gsap-ready .hero [data-enter] { animation: none; }


/* When GSAP is driving the page it takes over the reveal states, so the
   stylesheet only has to provide the starting position. */
html.gsap-ready [data-reveal] {
  opacity: 0;
  transform: none;
  transition: none;
}

html.gsap-ready [data-reveal].is-in {
  opacity: 1;
  transition: none;
}

/* Split-text units for the headline reveal.
   The mask is per word and must stay inline, or every word becomes its own
   line. Padding plus a matching negative margin stops descenders clipping. */
.split-line {
  display: inline-block;
  overflow: hidden;
  vertical-align: bottom;
  padding-bottom: 0.14em;
  margin-bottom: -0.14em;
}

.split-word {
  display: inline-block;
  will-change: transform;
}

/* ---------- 16. Reduced motion and no-JS ---------- */

@media (prefers-reduced-motion: reduce) {
  .hero__aurora,
  .stage__orbit,
  .panel,
  .kicker--pill::before,
  .panel__pill i,
  .ticks li[data-state="active"] span::after,
  .scroll-hint i::after {
    animation: none !important;
  }

  .stage__scene { transform: none !important; }
  .panel { transform: none !important; }

  /* Stack the scene instead of overlapping it in 3D. */
  .stage {
    aspect-ratio: auto;
    perspective: none;
  }

  .stage__scene { position: static; display: grid; gap: 1rem; }
  .stage__floor { display: none; }

  .panel--board,
  .panel--close,
  .panel--ring,
  .panel--chips,
  .panel--flag {
    position: static;
    width: 100%;
    inset: auto;
  }

  .card { transform: none !important; }
  .scroll-progress { display: none; }
}

/* Without JavaScript the panels are still laid out by CSS, and the reveal
   states never engage because html.gsap-ready is never added. */

/* ---------- 17. Full-height scenes ----------
   Sections that hold the viewport and animate content in on arrival and out on
   exit, rather than sitting still. Used only where the content suits it;
   listings such as Insights stay conventional. */

.scene {
  position: relative;
  display: grid;
  align-content: center;
  min-height: 100svh;
}

/* Phones and short viewports fall back to normal flow, or tall stacked content
   would be cropped. */
@media (max-width: 900px), (max-height: 740px) {
  .scene { min-height: 0; }
}

/* Oversized outlined numeral behind a scene, for depth. */
.scene__watermark {
  position: absolute;
  z-index: 0;
  top: 50%;
  right: clamp(-1rem, 2vw, 3rem);
  translate: 0 -50%;
  font-size: clamp(11rem, 30vw, 26rem);
  font-weight: 700;
  line-height: 0.8;
  letter-spacing: -0.06em;
  color: transparent;
  -webkit-text-stroke: 1px rgba(11, 21, 47, 0.07);
  pointer-events: none;
  user-select: none;
}

.section--dark .scene__watermark { -webkit-text-stroke-color: rgba(165, 204, 237, 0.1); }

/* Card deck: three cards dealt out of a stack as the section arrives. */
.deck {
  perspective: 1600px;
  perspective-origin: 50% 45%;
}

.deck > .card {
  transform-style: preserve-3d;
  will-change: transform;
}

/* Track record as glass tiles on navy. */
.stats--glass {
  background: transparent;
  border: 0;
  gap: clamp(0.75rem, 1.5vw, 1.15rem);
  overflow: visible;
  perspective: 1200px;
}

.stats--glass .stat {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 18px;
  backdrop-filter: blur(16px) saturate(150%);
  -webkit-backdrop-filter: blur(16px) saturate(150%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
  transform-style: preserve-3d;
  will-change: transform;
}

.stats--glass .stat::after { display: none; }

.stats--glass .stat:hover {
  border-color: rgba(165, 204, 237, 0.45);
  background: var(--glass-bg);
}

.stats--glass .stat dt { color: #fff; }
.stats--glass .stat dd { color: var(--on-dark-70); }

/* Pinned principles sequence. */
.pillars { perspective: 1400px; }

.pillar {
  transform-style: preserve-3d;
  will-change: transform, opacity;
}

.pillar.is-focus {
  border-color: rgba(165, 204, 237, 0.5);
  box-shadow: 0 34px 70px -34px rgba(0, 0, 0, 0.75), inset 0 1px 0 rgba(255, 255, 255, 0.18);
}

.rail { margin-bottom: clamp(1.5rem, 3vw, 2.25rem); }

/* Who We Serve cards swing in from alternating sides. */
.swing { perspective: 1500px; }

.swing > .card {
  transform-style: preserve-3d;
  will-change: transform, opacity;
}

/* Closing call to action, given room to breathe. */
.cta-band--scene { min-height: 76svh; }

.cta-band--scene .cta-band__inner {
  align-content: center;
  min-height: inherit;
}

.cta-band--scene h2 {
  font-size: clamp(2.1rem, 4.6vw, 3.9rem);
  max-width: 24ch;
}

/* Scenes collapse to ordinary stacked sections when motion is reduced. */
@media (prefers-reduced-motion: reduce) {
  .scene { min-height: 0; }
  .scene__watermark { display: none; }

  .deck > .card,
  .swing > .card,
  .stats--glass .stat,
  .pillar {
    transform: none !important;
    opacity: 1 !important;
  }
}

/* ---------- 18. Scene corrections ---------- */

/* A four-tile band does not fill a full-height scene on its own, so the tiles
   are given real height and the numerals real scale. */
.stats--glass .stat {
  min-height: clamp(180px, 30vh, 300px);
  justify-content: space-between;
  padding: clamp(1.4rem, 2.4vw, 2.1rem);
}

.stats--glass .stat .icon-tile { margin-bottom: 0; }

.stats--glass .stat dt {
  margin-top: auto;
  font-size: clamp(2.5rem, 4.6vw, 4.4rem);
  letter-spacing: -0.055em;
}

.stats--glass .stat dd {
  margin-top: 0.7rem;
  font-size: 0.74rem;
}

/* Outlined numerals behind the scenes read as stray geometry once cropped, so
   they are withdrawn. */
.scene__watermark { display: none; }

/* The base rule colours the numeral spans blue, which is unreadable on navy.
   Target the spans directly, not just the wrapping <dt>. */
.stats--glass .stat dt span { color: #fff; }
.stats--glass .stat dt span:last-child { color: var(--blue-light); }

/* Reserve two lines for the label so every numeral sits on the same baseline
   regardless of how the label wraps. */
.stats--glass .stat dd { min-height: 2.6em; }

/* "Professionals trained" is the widest label and does not fit a half-width
   tile at the default tracking. Tightened rather than broken mid-word. */
@media (max-width: 620px) {
  .stats--glass .stat dd {
    font-size: 0.62rem;
    letter-spacing: 0.05em;
    min-height: 3em;
  }

  .stats--glass .stat { min-height: clamp(160px, 24vh, 220px); }
  .stats--glass .stat dt { font-size: clamp(2rem, 9vw, 2.6rem); }
}
