/* =========================================================
   Mindspace AI - stylesheet
   ========================================================= */

:root{
  --bg:#020712;
  --bg-alt:#040c1c;
  --panel:rgba(255,255,255,.032);
  --panel-2:rgba(255,255,255,.055);
  --line:rgba(255,255,255,.09);
  --line-soft:rgba(255,255,255,.06);

  --text:#eef4ff;
  --muted:#93a4c4;
  --muted-2:#6d7f9f;

  --brand:#2f80ff;
  --brand-2:#59b0ff;
  --brand-3:#8f6dff;
  --brand-glow:rgba(47,128,255,.55);

  /* Surfaces and accents that can't survive a theme flip on their own
     (translucent-white overlays vanish on light ground, etc).
     main.js interpolates every token below as you scroll. */
  --surface:rgba(255,255,255,.04);
  --text-soft:#d7e3f8;
  --input-bg:rgba(3,9,22,.6);
  /* Opaque counterpart. Chrome's autofill background can only be masked
     with an inset shadow, and a translucent one lets the white through. */
  --input-solid:#080e1c;
  --placeholder:#5b6b88;
  --grad-a:#ffffff;
  --grad-b:#8fc0ff;
  --icon-fg:#bcd8ff;
  --icon-bg:rgba(255,255,255,.08);
  --nav-bg:rgba(3,8,20,.78);
  --nav-solid:rgba(4,10,24,.96);
  --pill-bg:#f2f6ff;
  --pill-fg:#061024;

  /* Primary button. Fixed rather than theme-interpolated — the button
     reads the same on the dark and light halves of the page.
     --btn-rgb is a bare triplet so it can be alpha-composed in rgba(). */
  --btn-from:#0e8ea6;
  --btn-to:#0b7489;
  --btn-rgb:11,116,137;

  --radius:16px;
  --radius-lg:22px;
  --maxw:1180px;

  --ease:cubic-bezier(.22,.61,.36,1);
}

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

html{scroll-behavior:smooth;-webkit-text-size-adjust:100%}

body{
  margin:0;
  background:var(--bg);
  color:var(--text);
  font-family:"Inter",system-ui,-apple-system,"Segoe UI",sans-serif;
  font-size:16px;
  line-height:1.65;
  -webkit-font-smoothing:antialiased;
  overflow-x:hidden;
}

img,svg{max-width:100%;display:block}
a{color:inherit;text-decoration:none}
h1,h2,h3,h4{margin:0;font-weight:600;letter-spacing:-.02em;line-height:1.12}
p{margin:0}
ul,ol{margin:0;padding:0;list-style:none}

.skip-link{
  position:absolute;left:-9999px;top:0;z-index:200;
  background:var(--brand);color:#fff;padding:.7rem 1.1rem;border-radius:0 0 10px 0;
}
.skip-link:focus{left:0}

:focus-visible{outline:2px solid var(--brand-2);outline-offset:3px;border-radius:6px}

.container{width:min(100% - 2.5rem,var(--maxw));margin-inline:auto}
.container--narrow{width:min(100% - 2.5rem,860px)}

/* ---------------- Nav ---------------- */
.nav{
  position:fixed;inset:0 0 auto 0;z-index:100;
  padding:1rem 0;
  /* Kept short: the theme tokens animate per frame from JS, so a long
     transition here would leave the bar lagging behind the page. */
  transition:background .2s var(--ease),backdrop-filter .2s var(--ease),border-color .2s var(--ease);
  border-bottom:1px solid transparent;
}
.nav.is-stuck{
  background:var(--nav-bg);
  backdrop-filter:blur(14px);
  border-bottom-color:var(--line-soft);
}
.nav__inner{
  width:min(100% - 2.5rem,var(--maxw));margin-inline:auto;
  display:flex;align-items:center;gap:2rem;
}
.logo{display:inline-flex;align-items:center;gap:.55rem;font-weight:600;font-size:1.05rem;letter-spacing:-.02em}
.logo__mark{width:22px;height:22px;color:var(--brand-2)}
.nav__links{display:flex;gap:1.9rem;font-size:.92rem;color:var(--muted);margin-right:auto}
.nav__links a{transition:color .2s var(--ease)}
.nav__links a:hover{color:var(--text)}

.nav__toggle{
  display:none;width:42px;height:42px;border:1px solid var(--line);
  background:var(--panel);border-radius:12px;cursor:pointer;
  flex-direction:column;justify-content:center;align-items:center;gap:5px;
}
.nav__toggle span{display:block;width:16px;height:1.6px;background:var(--text);transition:transform .3s var(--ease),opacity .3s var(--ease)}
.nav__toggle[aria-expanded="true"] span:first-child{transform:translateY(3.3px) rotate(45deg)}
.nav__toggle[aria-expanded="true"] span:last-child{transform:translateY(-3.3px) rotate(-45deg)}

.nav__mobile{
  display:none;flex-direction:column;gap:.25rem;
  width:min(100% - 2.5rem,var(--maxw));margin:.9rem auto 0;
  padding:1rem;border:1px solid var(--line);border-radius:var(--radius);
  background:var(--nav-solid);backdrop-filter:blur(14px);
}
.nav__mobile a{padding:.7rem .5rem;color:var(--muted);border-radius:10px}
.nav__mobile a:hover{color:var(--text);background:var(--panel)}
.nav__mobile .btn{margin-top:.5rem;color:var(--pill-fg)}

/* ---------------- Buttons ---------------- */
.btn{
  display:inline-flex;align-items:center;justify-content:center;gap:.5rem;
  font-size:.92rem;font-weight:500;letter-spacing:-.01em;
  padding:.72rem 1.35rem;border-radius:999px;border:1px solid transparent;
  cursor:pointer;white-space:nowrap;
  transition:transform .2s var(--ease),box-shadow .3s var(--ease),background .25s var(--ease),border-color .25s var(--ease);
}
.btn:hover{transform:translateY(-1px)}
.btn__arrow{width:15px;height:15px}

.btn--primary{
  background:linear-gradient(180deg,var(--btn-from),var(--btn-to));
  color:#fff;
  box-shadow:0 10px 30px -10px rgba(var(--btn-rgb),.85),inset 0 1px 0 rgba(255,255,255,.28);
}
.btn--primary:hover{box-shadow:0 16px 40px -12px rgba(var(--btn-rgb),.95),inset 0 1px 0 rgba(255,255,255,.35)}

.btn--ghost{background:var(--panel);border-color:var(--line);color:var(--text)}
.btn--ghost:hover{background:var(--panel-2);border-color:rgba(255,255,255,.18)}

.btn--pill{
  background:var(--pill-bg);color:var(--pill-fg);font-weight:600;
  box-shadow:0 8px 24px -12px rgba(0,0,0,.8);
}
.btn--pill:hover{filter:brightness(1.12)}

/* Header CTA sits shorter than the standard button. The hero's own button
   is the same box, but nested inside the input pill, so it reads smaller —
   this matches that perceived height. */
.nav .btn--pill{padding-block:.5rem}

.btn--block{width:100%}

/* ---------------- Hero ---------------- */
/* Bottom padding used to come from .hero__trusted, which now sits inside
   the copy block, so the section carries it directly. */
.hero{position:relative;padding:9.5rem 0 5.5rem;isolation:isolate;overflow:hidden}
.hero__bg{position:absolute;inset:0;z-index:-1}

/* Scan-field canvas mounts here (assets/js/scanner.js). The gradient is
   not decoration behind the canvas — it is the fallback that shows when
   WebGL2 is missing, and it also gives the shader's transparent regions
   some depth to sit on. */
.hero__scanner{
  position:absolute;inset:0;
  overflow:hidden;
  background:
    radial-gradient(52% 46% at 50% 38%,rgba(11,116,137,.40),transparent 70%),
    radial-gradient(40% 36% at 64% 28%,rgba(14,142,166,.22),transparent 72%),
    radial-gradient(75% 62% at 50% 64%,rgba(4,45,56,.55),transparent 74%);
}
/* Hero footage, held to the left of the frame and blended into the scan
   field. `screen` drops the clip's dark pixels out against the dark
   ground, so it reads as light in the scene rather than a pasted panel;
   the radial mask feathers every edge so there is no rectangle. */
.hero__video{
  position:absolute;
  /* left/top come from main.js each cycle; the translate centres the clip
     on that point so a position near an edge overhangs evenly. */
  left:50%;top:50%;
  transform:translate(-50%,-50%);
  opacity:0;
  transition:opacity 1.1s var(--ease);
  /* Box matches the clip's native 16:9, so the whole frame shows —
     the previous fixed height cropped the sides heavily. */
  width:min(54%,800px);height:auto;
  aspect-ratio:16/9;
  object-fit:contain;
  mix-blend-mode:screen;
  pointer-events:none;
  /* Vignette. `farthest-side` inscribes the ellipse so it touches all four
     edges — the mask therefore reaches fully transparent exactly at the
     edges, with the corners already clear, leaving no boundary anywhere.
     (A dark overlay would do nothing here: under `screen` blending, black
     is the no-op colour. Fading the alpha is the only way to soften it.) */
  -webkit-mask-image:radial-gradient(farthest-side at 50% 50%,
    #000 16%,rgba(0,0,0,.78) 42%,rgba(0,0,0,.34) 68%,transparent 100%);
  mask-image:radial-gradient(farthest-side at 50% 50%,
    #000 16%,rgba(0,0,0,.78) 42%,rgba(0,0,0,.34) 68%,transparent 100%);
}

.hero__vignette{
  position:absolute;inset:0;
  background:
    radial-gradient(80% 60% at 50% 0%,transparent 40%,rgba(2,7,18,.55) 100%),
    linear-gradient(to bottom,transparent 55%,var(--bg) 97%);
}

.hero__inner{
  position:relative;display:grid;grid-template-columns:minmax(0,1fr);
  align-items:center;justify-items:center;text-align:center;
  gap:2rem;min-height:min(78vh,660px);
}
.hero__copy{max-width:60rem;margin-inline:auto}

.eyebrow{
  display:inline-flex;align-items:center;gap:.5rem;
  font-size:.8rem;color:var(--muted);letter-spacing:.01em;margin-bottom:1.3rem;
}
.eyebrow__dot{
  width:7px;height:7px;border-radius:50%;
  background:var(--brand-2);box-shadow:0 0 12px 2px var(--brand-glow);
}

.hero__title{
  /* Sized so all 34 characters fit one line inside the container — a
     centred line wider than its box overflows both edges and stops
     reading as centred at all. */
  font-size:clamp(1.9rem,4.6vw,3.6rem);
  font-weight:300;letter-spacing:-.035em;line-height:1.03;
  margin-bottom:1.4rem;
}
/* Forced only where it provably fits; below this it wraps naturally
   rather than risking a clipped headline. */
@media (min-width:700px){
  .hero__title{white-space:nowrap}
}
.hero__sub{color:var(--muted);font-size:1.02rem;max-width:34rem;margin:0 auto 2.1rem}
.hero__actions{display:flex;gap:.8rem;flex-wrap:wrap;justify-content:center}

/* Inline email capture. The submit button is collapsed to zero width and
   grows out of the right-hand end of the pill once the address is valid. */
.hero__signup{
  display:flex;align-items:center;
  padding:5px;border-radius:999px;
  /* Opaque so the autofill mask below matches it exactly */
  background:var(--input-solid);
  border:1px solid var(--line);
  transition:border-color .25s var(--ease),box-shadow .25s var(--ease);
}
.hero__signup:focus-within{
  border-color:rgba(90,150,255,.6);
  box-shadow:0 0 0 3px rgba(47,128,255,.16);
}
/* Dial code picker. The container must not clip — the open list escapes
   it — so the collapse animation lives on the toggle instead. */
.dial{flex:none;position:relative}

.dial__toggle{
  display:flex;align-items:center;gap:.4rem;
  max-width:0;padding:0;
  overflow:hidden;white-space:nowrap;
  opacity:0;
  font:inherit;font-size:.92rem;color:var(--text);
  background:transparent;border:0;cursor:pointer;
  transition:max-width .3s var(--ease),padding .3s var(--ease),opacity .25s var(--ease);
}
.hero__signup.is-phone .dial__toggle{
  max-width:6rem;
  padding:.42rem .9rem .42rem .9rem;
  opacity:1;
}
/* Caret, drawn the same way as the contact form's selects */
.dial__toggle::after{
  content:"";
  width:9px;height:9px;flex:none;
  border-right:1.6px solid var(--muted);
  border-bottom:1.6px solid var(--muted);
  transform:rotate(45deg) translate(-2px,-2px);
  transition:transform .25s var(--ease);
}
.dial__toggle[aria-expanded="true"]::after{transform:rotate(-135deg) translate(-2px,-2px)}

.dial__list{
  position:absolute;top:calc(100% + .55rem);left:0;
  z-index:60;
  width:17rem;max-height:16rem;overflow-y:auto;
  padding:.35rem;
  border-radius:14px;
  background:var(--bg-alt);
  border:1px solid var(--line);
  box-shadow:0 26px 50px -22px rgba(3,10,22,.6);
  text-align:left;
}
.dial__list[hidden]{display:none}
.dial__option{
  display:flex;align-items:center;justify-content:space-between;gap:1rem;
  padding:.5rem .7rem;border-radius:9px;
  font-size:.88rem;color:var(--text);cursor:pointer;
}
.dial__option span:last-child{color:var(--muted-2);font-variant-numeric:tabular-nums}
.dial__option:hover,
.dial__option.is-active{background:rgba(var(--btn-rgb),.1)}
.dial__option[aria-selected="true"]{background:rgba(var(--btn-rgb),.16)}
/* Sits tight against the code so the two read as one field */
.hero__signup.is-phone .hero__signup-input{padding-left:.35rem}

.hero__signup-input{
  font:inherit;font-size:.92rem;color:var(--text);
  background:transparent;border:0;outline:none;
  /* Rounded so the autofill mask follows the pill instead of showing
     square corners inside it */
  border-radius:999px;
  padding:.42rem .9rem;
  /* Shrinks rather than pushing the button out of the pill on narrow screens */
  flex:1 1 auto;width:19rem;min-width:0;
}
.hero__signup-input::placeholder{color:var(--placeholder)}

.hero__signup-btn{
  flex:none;
  margin-left:.35rem;
  white-space:nowrap;
}
/* The base lift would bob the button inside its own pill */
.hero__signup-btn:hover{transform:none}

.hero__signup-status{
  margin-top:.9rem;min-height:1.2em;
  font-size:.87rem;color:var(--brand-2);
}
.hero__signup-status.is-error{color:#ff8b8b}

/* Chrome paints its own background on autofilled fields and ignores
   background-color. A large inset shadow is the only way to mask it, and
   the long transition delay stops the yellow flash before it applies. */
.hero__signup-input:-webkit-autofill,
.hero__signup-input:-webkit-autofill:hover,
.hero__signup-input:-webkit-autofill:focus,
.modal__offer-input:-webkit-autofill,
.modal__offer-input:-webkit-autofill:hover,
.modal__offer-input:-webkit-autofill:focus,
.field input:-webkit-autofill,
.field input:-webkit-autofill:hover,
.field input:-webkit-autofill:focus,
.field textarea:-webkit-autofill,
.field select:-webkit-autofill{
  -webkit-text-fill-color:var(--text);
  -webkit-box-shadow:0 0 0 1000px var(--input-solid) inset;
  box-shadow:0 0 0 1000px var(--input-solid) inset;
  caret-color:var(--text);
  transition:background-color 6000s ease-in-out 0s;
}

/* Trusted row — sits inside .hero__copy, below the email field */
.hero__trusted{position:relative;margin-top:3rem;text-align:center}

/* Held back until the first scroll (see main.js). Gated on .js so a
   blocked script leaves the row visible rather than permanently hidden. */
.js .hero__trusted{
  opacity:0;
  transform:translateY(16px);
  transition:opacity .6s var(--ease),transform .6s var(--ease);
}
.js .hero__trusted.is-revealed{opacity:1;transform:none}
.trusted__label{font-size:.85rem;color:var(--muted);margin-bottom:1.6rem}
.logo-row{
  display:flex;align-items:center;justify-content:center;gap:clamp(1.5rem,4vw,3.2rem);
  flex-wrap:wrap;padding-inline:1.25rem;
  color:var(--text-soft);font-size:clamp(.9rem,1.6vw,1.05rem);font-weight:500;letter-spacing:-.01em;
}
/* Press logos. Their aspect ratios run from 1:1 to 11.5:1, so a single
   height would leave the square one tiny and the wordmarks enormous —
   each gets its own height, tuned for comparable optical weight. */
.logo-row__item{
  height:var(--h,26px);
  width:auto;
  opacity:.62;
  /* Source artwork is black on transparent and the hero is dark, so it is
     forced to white. Drop this line to show the original brand colours. */
  filter:brightness(0) invert(1);
  transition:opacity .25s var(--ease);
}
.logo-row__item:hover{opacity:1}

.logo-row__item--inc {--h:30px}
.logo-row__item--tedx{--h:26px}
.logo-row__item--csun{--h:25px}
.logo-row__item--tbi {--h:38px}
.logo-row__item--vcp {--h:13px}
.logo-row__item--vb  {--h:20px}

/* ---------------- Sections ---------------- */
.section{padding:6.5rem 0;position:relative}
.section--tight{padding:2.5rem 0 4rem}
.section--alt{background:var(--bg-alt);border-block:1px solid var(--line-soft)}

.section__head{max-width:44rem;margin-bottom:3.2rem}
.section__title{font-size:clamp(1.9rem,3.6vw,2.8rem);font-weight:300;letter-spacing:-.03em;margin-bottom:1rem}
.section__sub{color:var(--muted);font-size:1rem}

.br-md{display:none}
@media (min-width:760px){.br-md{display:inline}}

/* Stats */
.stats__grid{
  display:grid;grid-template-columns:repeat(4,1fr);gap:1px;
  background:var(--line-soft);border:1px solid var(--line-soft);border-radius:var(--radius-lg);overflow:hidden;
}
.stat{background:var(--bg);padding:1.8rem 1.5rem;display:flex;flex-direction:column;gap:.35rem}
.stat__num{
  font-size:clamp(1.6rem,3vw,2.2rem);font-weight:600;letter-spacing:-.03em;
  background:linear-gradient(120deg,var(--grad-a),var(--grad-b));
  -webkit-background-clip:text;background-clip:text;color:transparent;
}
.stat__label{font-size:.86rem;color:var(--muted-2)}

/* Team photos. Tiles hold a 4:5 box whether the contents are the SVG
   placeholders or real photographs, so swapping them changes no layout. */
.team{display:grid;grid-template-columns:repeat(4,1fr);gap:1.1rem;margin-top:1.6rem}
.team__member{margin:0;position:relative}

/* Name plate over the foot of the tile. The scrim keeps it readable
   whatever a real photograph turns out to look like underneath. */
.team__caption{
  position:absolute;left:0;right:0;bottom:0;
  display:flex;flex-direction:column;gap:.1rem;
  padding:2.4rem .95rem .85rem;
  border-radius:0 0 var(--radius-lg) var(--radius-lg);
  background:linear-gradient(to top,rgba(3,10,22,.86),rgba(3,10,22,.5) 52%,transparent);
  pointer-events:none;
}
.team__caption strong{font-size:.92rem;font-weight:600;letter-spacing:-.01em;color:#fff}
.team__caption span{font-size:.77rem;line-height:1.35;color:rgba(255,255,255,.74)}
.team__photo{
  aspect-ratio:4/5;
  border-radius:var(--radius-lg);
  overflow:hidden;
  border:1px solid var(--line);
  display:grid;place-items:end center;
  background:linear-gradient(160deg,rgba(var(--btn-rgb),.22),rgba(var(--btn-rgb),.05));
  color:rgba(var(--btn-rgb),.42);
}
/* Slight variation so four identical tiles do not read as a rendering bug */
.team__member:nth-child(2) .team__photo{
  background:linear-gradient(200deg,rgba(var(--btn-rgb),.14),rgba(var(--btn-rgb),.04));
  color:rgba(var(--btn-rgb),.34);
}
.team__member:nth-child(3) .team__photo{
  background:linear-gradient(140deg,rgba(var(--btn-rgb),.27),rgba(var(--btn-rgb),.07));
  color:rgba(var(--btn-rgb),.46);
}
.team__member:nth-child(4) .team__photo{
  background:linear-gradient(185deg,rgba(var(--btn-rgb),.17),rgba(var(--btn-rgb),.05));
  color:rgba(var(--btn-rgb),.38);
}
/* Same rule serves a real <img> once one is dropped in */
.team__photo svg,
.team__photo img{width:100%;height:100%;object-fit:cover;display:block}
.team__photo svg{width:76%;height:auto}

@media (max-width:760px){
  .team{grid-template-columns:repeat(2,1fr)}
}

/* Cards */
.cards{display:grid;grid-template-columns:repeat(3,1fr);gap:1.1rem}
.card{
  padding:1.9rem 1.7rem;border-radius:var(--radius-lg);
  background:var(--surface);
  border:1px solid var(--line);
  transition:transform .35s var(--ease),border-color .35s var(--ease),box-shadow .35s var(--ease);
}
.card:hover{
  transform:translateY(-4px);
  border-color:rgba(var(--btn-rgb),.45);
  box-shadow:0 24px 50px -30px rgba(var(--btn-rgb),.9);
}
.card__icon{
  width:44px;height:44px;border-radius:13px;margin-bottom:1.2rem;
  display:grid;place-items:center;
  background:var(--icon-bg);
  border:1px solid var(--line);
  color:var(--icon-fg);
}
.card__icon svg{width:22px;height:22px}
.card h3{font-size:1.12rem;margin-bottom:.6rem}
.card p{color:var(--muted);font-size:.94rem}
.card__list{margin-top:1.1rem;padding-top:1.1rem;border-top:1px solid var(--line-soft);display:grid;gap:.45rem}
.card__list li{font-size:.86rem;color:var(--muted-2);padding-left:1.1rem;position:relative}
.card__list li::before{
  content:"";position:absolute;left:0;top:.62em;
  width:5px;height:5px;border-radius:50%;background:var(--brand-2);opacity:.8;
}

/* Extra headroom so the dark → light hand-off (one screen-height as
   Services leaves) plays out over open space rather than under the
   Process heading. */
#process{padding-top:clamp(10rem,24vh,18rem)}

/* "Ten" struck out, "four" revealed — triggered from main.js when the
   heading scrolls into view. */
.strike-swap{display:inline-flex;align-items:baseline;white-space:nowrap}
.strike-swap__old{position:relative;transition:opacity .4s var(--ease) .2s}
.strike-swap__old::after{
  content:"";
  position:absolute;left:-.06em;right:-.06em;top:.54em;height:.06em;
  background:currentColor;border-radius:2px;
  transform:scaleX(0);transform-origin:left center;
  transition:transform .45s var(--ease);
}
.strike-swap.is-struck .strike-swap__old::after{transform:scaleX(1)}
.strike-swap.is-struck .strike-swap__old{opacity:.42}

.strike-swap__new{
  /* Collapsed rather than hidden, so the line grows into place instead of
     the heading reflowing when the word appears. */
  max-width:0;margin-left:0;opacity:0;overflow:hidden;
  transition:max-width .5s var(--ease),margin-left .5s var(--ease),opacity .4s var(--ease);
}
.strike-swap.is-swapped .strike-swap__new{max-width:6em;margin-left:.3em;opacity:1}

/* Steps */
.steps{display:grid;grid-template-columns:repeat(4,1fr);gap:1.1rem;counter-reset:step}
.step{
  position:relative;padding:1.7rem 1.5rem;border-radius:var(--radius-lg);
  background:var(--surface);border:1px solid var(--line);
}
.step__num{
  display:inline-block;font-size:.78rem;font-weight:600;
  letter-spacing:.08em;color:var(--brand-2);margin-bottom:1rem;
}
.step h3{font-size:1.08rem;margin-bottom:.55rem}
.step p{color:var(--muted);font-size:.92rem;margin-bottom:1.1rem}
.step__meta{
  font-size:.78rem;color:var(--muted-2);
  border:1px solid var(--line);border-radius:999px;padding:.25rem .7rem;display:inline-block;
}

/* Scrubbed video — the track gives it scroll length, the stage pins,
   and main.js maps progress onto the video's currentTime. */
.scrub{padding:0}
.scrub-track{position:relative;height:340vh}
.scrub-stage{
  position:sticky;top:0;height:100vh;overflow:hidden;
  background:#f6f8fc;
  display:grid;place-items:center;
}
/* Fixed frame — the push-in happens to the footage inside it, so the
   card itself never changes size on screen. */
.scrub-frame{
  position:relative;
  width:min(62.5%,1125px);
  aspect-ratio:16/9;
  border-radius:18px;
  overflow:hidden;
}
/* White vignette — feathers all four edges into the page ground so the
   clip has no visible frame line. Two crossed gradients rather than a
   radial, which would fade the middle of each edge more than the corners. */
.scrub-frame::after{
  content:"";
  position:absolute;inset:0;z-index:2;pointer-events:none;
  background:
    linear-gradient(to right,#f6f8fc,transparent 15%,transparent 85%,#f6f8fc),
    linear-gradient(to bottom,#f6f8fc,transparent 18%,transparent 82%,#f6f8fc);
}
.scrub-frame video{
  position:absolute;inset:0;
  width:100%;height:100%;object-fit:cover;display:block;
}

@media (max-width:1100px){
  .scrub-frame{width:87.5%}
}
/* The light ground the clip fades up out of and sinks back into.
   Starts opaque only when JS is running — otherwise it would leave a
   blank white block where the video should be. */
.scrub-veil{
  position:absolute;inset:0;pointer-events:none;
  background:#f6f8fc;opacity:0;
  will-change:opacity;
}
.js .scrub-veil{opacity:1}

/* Work — scroll-pinned title, then cards in one at a time.
   The track supplies the scroll distance; the stage pins inside it and
   main.js maps track progress onto the transforms below. */
/* Pulled up over the scrub section's final screen. That makes the stage
   pin at the exact moment the video finishes, so the title is inside an
   already-fixed container the instant it becomes visible — nothing has to
   chase the scroll to hold it still. */
.work-section{padding:0;margin-top:-100vh}
.work-track{position:relative;height:300vh}
.work-stage{
  position:sticky;top:0;height:100vh;
  display:flex;flex-direction:column;justify-content:center;
  overflow:hidden;
}
.work__head{
  margin-bottom:3rem;
  margin-inline:auto;
  text-align:center;
  will-change:transform,opacity;
}
.js .work__head{opacity:0}
.work__title{
  /* Centre origin so the growth phase expands evenly either side
     and the block stays centred on screen throughout. */
  transform-origin:center center;
  will-change:transform;
  /* Scaling to 1.32 does not affect layout, so the title visually
     overhangs its own box by (1.32-1)/2 of its height and eats into the
     standard 1rem gap. The em term gives that height back, so the space
     to the description matches every other section. */
  margin-bottom:calc(1rem + .36em);
}
/* Hidden with opacity rather than display, so the header keeps its full
   height and the centring measurement stays stable throughout. */
.js .work__sub{
  opacity:0;
  transform:translateY(14px);
  will-change:opacity,transform;
}
.js .work__item{
  opacity:0;
  transform:translateY(38px);
  will-change:opacity,transform;
}

/* Work */
.work{display:grid;grid-template-columns:repeat(3,1fr);gap:1.1rem}
.work__item{
  padding:1.9rem 1.7rem;border-radius:var(--radius-lg);
  /* Brand tint layered over the theme surface — a translucent accent
     reads correctly on both dark and light ground, a white one doesn't. */
  background:linear-gradient(180deg,rgba(var(--btn-rgb),.10),rgba(var(--btn-rgb),.02)),var(--surface);
  border:1px solid var(--line);
  display:flex;flex-direction:column;
  /* No transform transition — main.js drives transform per frame here,
     and a 350ms ease would leave it trailing the scroll. */
  transition:border-color .35s var(--ease);
}
.work__item:hover{border-color:rgba(var(--btn-rgb),.5)}
.work__tag{
  font-size:.76rem;color:var(--btn-to);letter-spacing:.02em;margin-bottom:1rem;
  border:1px solid rgba(var(--btn-rgb),.35);border-radius:999px;padding:.28rem .75rem;align-self:flex-start;
}
.work__item h3{font-size:1.18rem;margin-bottom:.7rem;line-height:1.25}
.work__item > p{color:var(--muted);font-size:.93rem;margin-bottom:1.6rem}
.work__stats{
  margin-top:auto;display:grid;grid-template-columns:repeat(3,1fr);gap:.75rem;
  padding-top:1.3rem;border-top:1px solid var(--line-soft);
}
.work__stats div{display:flex;flex-direction:column;gap:.15rem}
/* Kept compact: the pinned stage is a fixed 100vh, so every pixel added
   to a card eats into the room the block has to sit centred. */
.work__cta{
  width:100%;
  margin-top:1.2rem;
  padding:.58rem 1.1rem;
  font-size:.86rem;
  position:relative;z-index:1;
  /* Opaque, not the ghost button's translucent panel — the peeking
     mascot below must be properly hidden where it tucks behind. */
  background:var(--bg-alt);
}
.work__cta:hover{transform:none;border-color:rgba(var(--btn-rgb),.5);background:var(--bg-alt)}

/* Mascot rising from behind the button on hover */
.work__cta-wrap{position:relative;margin-top:1.2rem}
.work__cta-wrap .work__cta{margin-top:0;overflow:hidden}

/* Label crossfade. Both sit in the same spot so the button never resizes,
   and both sit above the sweeping flare rather than under it. */
.work__cta-label{
  position:relative;z-index:1;
  transition:opacity .24s var(--ease),transform .24s var(--ease);
}
.work__cta-label--alt{
  position:absolute;inset:0;
  display:grid;place-items:center;
  opacity:0;transform:translateY(5px);
}
.work__cta-wrap:hover .work__cta-label,
.work__cta-wrap:focus-within .work__cta-label{
  opacity:0;transform:translateY(-5px);
}
.work__cta-wrap:hover .work__cta-label--alt,
.work__cta-wrap:focus-within .work__cta-label--alt{
  opacity:1;transform:none;
}

/* Goes black on hover, with a highlight sweeping across on a loop.
   Scoped to the wrapped button — the other two cards keep the plain
   ghost treatment. */
.work__cta-wrap:hover .work__cta,
.work__cta-wrap:focus-within .work__cta{
  background:#05080f;
  border-color:#05080f;
  color:#fff;
}
.work__cta-wrap .work__cta::after{
  content:"";
  position:absolute;inset:0;
  pointer-events:none;
  background:linear-gradient(105deg,
    transparent 38%,
    rgba(255,255,255,.42) 50%,
    transparent 62%);
  transform:translateX(-130%);
  opacity:0;
}
.work__cta-wrap:hover .work__cta::after,
.work__cta-wrap:focus-within .work__cta::after{
  opacity:1;
  animation:cta-flare 1.9s linear infinite;
}
@keyframes cta-flare{
  from{transform:translateX(-130%)}
  to  {transform:translateX(130%)}
}
/* Clipping window sitting above the button, with its lower edge tucked
   24px *inside* it. The mascot is taller than the button, so it can never
   be hidden behind it — clipping is what stops it appearing below. */
.work__peek-clip{
  position:absolute;
  right:14%;                  /* offset toward the right of the button */
  bottom:calc(100% - 24px);
  width:86px;
  aspect-ratio:150/225;       /* the source image's own proportions */
  overflow:hidden;
  z-index:0;                  /* under the button, which is z-index 1 */
  pointer-events:none;
}
.work__peek{
  position:absolute;inset:0;
  width:100%;height:100%;
  object-fit:contain;
  display:block;
  /* Resting state is already a slight reveal — just the sign and the top
     of the arms clear the button — with a gentle bob to draw the eye. */
  transform:translateY(76%);
  animation:peek-tease 1.9s ease-in-out infinite;
  /* Retract on a shorter curve than the rise — see the hover rule, which
     overrides this with a slower one. */
  transition:transform .5s var(--ease);
}
/* Idle nudge: after scrolling settles, the sign lifts just above the
   button and bobs, hinting there is more behind it. Sits before the hover
   rules so hover — equal specificity, later in the file — takes over. */
@keyframes peek-tease{
  0%,100%{transform:translateY(76%)}
  50%    {transform:translateY(68%)}
}

.work__cta-wrap:hover .work__peek,
.work__cta-wrap:focus-within .work__peek{
  /* Cancelled explicitly: a running animation would otherwise keep
     overriding the transform below. */
  animation:none;
  /* Slow, steady climb — it should look like it is deciding to stand up,
     not springing. No overshoot for the same reason. */
  transition:transform 1.5s cubic-bezier(.32,.14,.24,1);
  transform:translateY(0);
}

.work__stats strong{font-size:1.05rem;letter-spacing:-.02em;color:var(--text)}
.work__stats span{font-size:.74rem;color:var(--muted-2);line-height:1.35}

/* ---------------- Case studies page ---------------- */
.page-head{padding-top:11rem}
.page-head .section__title{max-width:20ch;margin-bottom:1.1rem}
.page-head .section__sub{max-width:52ch}

.crumbs{font-size:.82rem;color:var(--muted-2);margin-bottom:1.6rem;display:flex;gap:.5rem}
.crumbs a{color:var(--muted)}
.crumbs a:hover{color:var(--text)}

.cases{display:grid;gap:4.5rem}

.case{
  padding:2.2rem;border-radius:var(--radius-lg);
  background:linear-gradient(180deg,rgba(var(--btn-rgb),.09),rgba(var(--btn-rgb),.02)),var(--surface);
  border:1px solid var(--line);
  scroll-margin-top:7rem; /* deep links clear the fixed header */
}
.case__head{max-width:56ch;margin-bottom:2rem}
.case__head h2{font-size:clamp(1.45rem,2.6vw,2rem);font-weight:400;margin:.9rem 0 .8rem}
.case__lede{color:var(--muted);font-size:1rem}

.case__body{display:grid;grid-template-columns:minmax(0,1.55fr) minmax(0,.95fr);gap:2.5rem;align-items:start}
.case__col h3{
  font-size:.82rem;font-weight:600;letter-spacing:.06em;text-transform:uppercase;
  color:var(--brand-2);margin:1.9rem 0 .7rem;
}
.case__col h3:first-child{margin-top:0}
.case__col p{color:var(--muted);font-size:.95rem}
.case__list{display:grid;gap:.65rem}
.case__list li{font-size:.94rem;color:var(--muted);padding-left:1.5rem;position:relative}
.case__list li::before{
  content:"";position:absolute;left:0;top:.45em;width:13px;height:7px;
  border-left:1.8px solid var(--btn-to);border-bottom:1.8px solid var(--btn-to);
  transform:rotate(-45deg);
}

.case__results{
  position:sticky;top:7rem;
  padding:1.6rem;border-radius:var(--radius);
  background:var(--bg-alt);border:1px solid var(--line);
}
.case__results-title{
  font-size:.78rem;font-weight:600;letter-spacing:.06em;text-transform:uppercase;
  color:var(--muted-2);margin-bottom:1.2rem;
}
.case__metric{display:flex;flex-direction:column;gap:.15rem;padding:.75rem 0;border-bottom:1px solid var(--line-soft)}
.case__metric:last-of-type{border-bottom:0}
.case__metric strong{
  font-size:1.6rem;font-weight:600;letter-spacing:-.03em;
  background:linear-gradient(120deg,var(--grad-a),var(--grad-b));
  -webkit-background-clip:text;background-clip:text;color:transparent;
}
.case__metric span{font-size:.8rem;color:var(--muted-2)}
.case__meta{margin-top:1.1rem;font-size:.76rem;color:var(--muted-2);line-height:1.5}

.case__quote{
  margin:2.2rem 0 0;padding-top:1.8rem;border-top:1px solid var(--line-soft);
  display:flex;flex-direction:column;gap:1.2rem;
}
.case__quote blockquote{margin:0;color:var(--text-soft);font-size:1rem;line-height:1.7;max-width:64ch}
.case__quote figcaption{display:flex;align-items:center;gap:.8rem}
.case__quote figcaption > span:last-child{display:flex;flex-direction:column;font-size:.82rem;color:var(--muted-2);line-height:1.4}
.case__quote figcaption strong{color:var(--text);font-size:.9rem;font-weight:600}

.cta__closer{text-align:center}
.cta__closer .eyebrow,.cta__closer .section__title,.cta__closer .section__sub{margin-inline:auto}
.cta__closer .section__sub{max-width:48ch}
.cta__closer-actions{margin-top:1.8rem}

@media (max-width:900px){
  .page-head{padding-top:9rem}
  .case{padding:1.5rem}
  .case__body{grid-template-columns:1fr;gap:2rem}
  .case__results{position:static}
}

/* Quotes — stacked on the left, video alongside on the right */
.testimonials{
  display:grid;grid-template-columns:minmax(0,1.12fr) minmax(0,.88fr);
  gap:2.2rem;align-items:start;
}
/* Beats the responsive `.quotes` rules further down, which would
   otherwise put the stack back into columns inside this narrow track. */
.testimonials .quotes{grid-template-columns:1fr}

.testimonial-video{
  /* Follows the reader down the taller column of quotes */
  position:sticky;top:6.5rem;
}
.testimonial-video__media{
  position:relative;aspect-ratio:16/9;
  border-radius:var(--radius-lg);overflow:hidden;
  border:1px solid var(--line);
  background:var(--surface);
}
.testimonial-video__media video{
  position:absolute;inset:0;
  width:100%;height:100%;object-fit:cover;display:block;
}
.testimonial-video__caption{
  margin-top:.85rem;font-size:.82rem;color:var(--muted-2);
}

.quotes{display:grid;grid-template-columns:repeat(3,1fr);gap:1.1rem}
.quote{
  margin:0;padding:1.8rem 1.6rem;border-radius:var(--radius-lg);
  background:var(--surface);border:1px solid var(--line);
  display:flex;flex-direction:column;gap:1.4rem;
}
.quote blockquote{margin:0;color:var(--text-soft);font-size:.97rem;line-height:1.7}
.quote figcaption{display:flex;align-items:center;gap:.8rem;margin-top:auto}
.quote__avatar{
  width:40px;height:40px;border-radius:50%;flex:none;display:grid;place-items:center;
  font-size:.8rem;font-weight:600;color:var(--icon-fg);
  background:linear-gradient(150deg,rgba(70,140,255,.4),rgba(140,90,255,.28));
  border:1px solid rgba(140,190,255,.3);
}
.quote figcaption > span:last-child{display:flex;flex-direction:column;font-size:.82rem;color:var(--muted-2);line-height:1.4}
.quote figcaption strong{color:var(--text);font-size:.9rem;font-weight:600}

/* CTA sitting astride a section boundary. Zero height so it adds no
   layout of its own; the button is pulled up half its size to centre
   on the dividing line. */
.edge-cta{
  position:relative;z-index:5;
  height:0;
  display:flex;justify-content:center;
}
.edge-cta .btn{
  transform:translateY(-50%);
  padding:1.35rem 3.2rem;
  font-size:1.08rem;
  box-shadow:0 20px 50px -16px rgba(var(--btn-rgb),.9),
             0 0 0 9px var(--bg-alt),
             inset 0 1px 0 rgba(255,255,255,.28);
}
.edge-cta .btn__arrow{width:19px;height:19px}

/* Hover flair: the glow blooms and a ring pulses outward.
   The ring sits entirely outside the button's own box, so it never
   paints across the face regardless of stacking. */
.edge-cta .btn{position:relative}
.edge-cta .btn::after{
  content:"";
  position:absolute;inset:-7px;
  border-radius:999px;
  border:1.5px solid rgba(var(--btn-rgb),.75);
  opacity:0;
  pointer-events:none;
}
.edge-cta .btn:hover{
  box-shadow:0 26px 62px -14px rgba(var(--btn-rgb),1),
             0 0 0 9px var(--bg-alt),
             0 0 38px 7px rgba(var(--btn-rgb),.45),
             inset 0 1px 0 rgba(255,255,255,.36);
}
.edge-cta .btn:hover::after{animation:flair 1.8s var(--ease) infinite}
.edge-cta .btn:hover .btn__arrow{transform:translateX(3px)}
.edge-cta .btn__arrow{transition:transform .3s var(--ease)}

@keyframes flair{
  0%  {opacity:.75;transform:scale(1)}
  70% {opacity:0;transform:scale(1.3)}
  100%{opacity:0;transform:scale(1.3)}
}
.edge-cta .btn:hover{transform:translateY(-50%) translateY(-2px)}

/* About */
.about{display:grid;grid-template-columns:1.35fr 1fr;gap:3.5rem;align-items:center}
.about__copy p{color:var(--muted);margin-bottom:1.1rem}
.about__points{display:grid;gap:.8rem;margin-top:1.8rem}
.about__points li{font-size:.93rem;color:var(--muted);padding-left:1.4rem;position:relative}
.about__points li::before{
  content:"";position:absolute;left:0;top:.62em;width:6px;height:6px;border-radius:50%;
  background:var(--brand-2);box-shadow:0 0 10px 1px var(--brand-glow);
}
.about__points strong{color:var(--text);font-weight:600}
.about__cta{margin-top:2rem}
.about__panel{
  display:grid;grid-template-columns:1fr 1fr;gap:1px;
  background:var(--line-soft);border:1px solid var(--line);border-radius:var(--radius-lg);overflow:hidden;
}
.about__stat{background:var(--bg-alt);padding:1.7rem 1.4rem;display:flex;flex-direction:column;gap:.3rem}
.about__stat strong{
  font-size:1.7rem;font-weight:600;letter-spacing:-.03em;
  background:linear-gradient(120deg,var(--grad-a),var(--grad-b));
  -webkit-background-clip:text;background-clip:text;color:transparent;
}
.about__stat span{font-size:.82rem;color:var(--muted-2)}

/* FAQ */
#faq .section__head{text-align:center;margin-inline:auto}

.faq{display:grid;gap:.7rem}
.faq__item{
  border:1px solid var(--line);border-radius:var(--radius);
  background:var(--surface);padding:1.1rem 1.4rem;
  transition:border-color .3s var(--ease),background .3s var(--ease);
}
.faq__item[open]{border-color:rgba(var(--btn-rgb),.4);background:rgba(var(--btn-rgb),.07)}
.faq__item summary{
  cursor:pointer;list-style:none;font-weight:500;font-size:1rem;
  display:flex;align-items:center;justify-content:space-between;gap:1rem;
}
.faq__item summary::-webkit-details-marker{display:none}
.faq__item summary::after{
  content:"";flex:none;width:9px;height:9px;
  border-right:1.8px solid var(--muted);border-bottom:1.8px solid var(--muted);
  transform:rotate(45deg) translateY(-2px);transition:transform .3s var(--ease);
}
.faq__item[open] summary::after{transform:rotate(-135deg) translateY(-2px)}
.faq__item p{color:var(--muted);font-size:.93rem;margin-top:.9rem}

/* CTA + Form */
.cta{position:relative;overflow:hidden;border-top:1px solid var(--line-soft)}
.cta__glow{
  position:absolute;left:50%;top:-30%;transform:translateX(-50%);
  width:min(1100px,140%);height:700px;
  background:radial-gradient(50% 50% at 50% 50%,rgba(var(--btn-rgb),.30),transparent 70%);
  filter:blur(20px);pointer-events:none;
}
.cta__inner{position:relative;display:grid;grid-template-columns:1fr 1fr;gap:3.5rem;align-items:start}
.cta__points{display:grid;gap:.6rem;margin-top:1.8rem}
.cta__points li{font-size:.92rem;color:var(--muted);padding-left:1.5rem;position:relative}
.cta__points li::before{
  content:"";position:absolute;left:0;top:.42em;width:14px;height:8px;
  border-left:1.8px solid var(--brand-2);border-bottom:1.8px solid var(--brand-2);
  transform:rotate(-45deg);
}
.cta__direct{margin-top:1.8rem;font-size:.9rem;color:var(--muted-2)}
.cta__direct a{color:var(--brand-2);text-decoration:underline;text-underline-offset:3px}

.form{
  padding:1.9rem;border-radius:var(--radius-lg);
  background:var(--surface);
  border:1px solid var(--line);
  backdrop-filter:blur(8px);
  display:grid;gap:1rem;
}
.form__row{display:grid;grid-template-columns:1fr 1fr;gap:1rem}
.field{display:grid;gap:.45rem}
.field > span{font-size:.83rem;color:var(--muted)}
.field input,.field select,.field textarea{
  width:100%;font:inherit;font-size:.93rem;color:var(--text);
  background:var(--input-bg);border:1px solid var(--line);border-radius:11px;
  padding:.75rem .9rem;resize:vertical;
  transition:border-color .25s var(--ease),box-shadow .25s var(--ease);
}
.field input::placeholder,.field textarea::placeholder{color:var(--placeholder)}
.field input:focus,.field select:focus,.field textarea:focus{
  outline:none;border-color:rgba(90,150,255,.6);
  box-shadow:0 0 0 3px rgba(47,128,255,.16);
}
.field select{appearance:none;background-image:linear-gradient(45deg,transparent 50%,var(--muted) 50%),linear-gradient(135deg,var(--muted) 50%,transparent 50%);background-position:calc(100% - 18px) 50%,calc(100% - 13px) 50%;background-size:5px 5px,5px 5px;background-repeat:no-repeat}
.field input[aria-invalid="true"],.field textarea[aria-invalid="true"]{border-color:#ff6b6b}
.form__status{font-size:.87rem;min-height:1.2em;color:var(--brand-2)}
.form__status.is-error{color:#ff8b8b}
.form__fine{font-size:.78rem;color:var(--muted-2)}
.form__fine a{text-decoration:underline;text-underline-offset:3px}

/* Footer */
.footer{border-top:1px solid var(--line-soft);background:var(--bg-alt);padding:4rem 0 2rem}
.footer__inner{display:grid;grid-template-columns:1.7fr 1fr 1fr 1fr 1.35fr;gap:2.5rem}
.footer__brand p{color:var(--muted-2);font-size:.9rem;max-width:24rem;margin-top:1rem}
.footer__social{display:flex;gap:.6rem;margin-top:1.4rem}
.footer__social a{
  width:36px;height:36px;border-radius:10px;display:grid;place-items:center;
  border:1px solid var(--line);background:var(--panel);color:var(--muted);font-size:.85rem;
  transition:color .25s var(--ease),border-color .25s var(--ease);
}
.footer__social a:hover{color:var(--text);border-color:rgba(90,150,255,.45)}
/* Brand marks inherit the link colour, so the hover transition above
   carries the icon with it rather than only the border. */
.footer__social a svg{width:17px;height:17px;display:block;fill:currentColor}
.footer__col{display:flex;flex-direction:column;gap:.6rem}
.footer__col h4{font-size:.88rem;margin-bottom:.4rem;letter-spacing:0}
.footer__col a{font-size:.88rem;color:var(--muted-2);transition:color .2s var(--ease)}
.footer__col a:hover{color:var(--text)}

/* Offices. Spacing comes from margins here rather than the column's flex
   gap, so the country heading sits tight against its own address. */
.footer__offices{gap:0}
.footer__office h5{
  font-size:.85rem;font-weight:600;letter-spacing:0;
  margin:1.1rem 0 .4rem;color:var(--text);
}
.footer__office:first-of-type h5{margin-top:0}
.footer__office address{
  font-style:normal;               /* address defaults to italic */
  font-size:.85rem;line-height:1.7;color:var(--muted-2);
}
.footer__base{
  display:flex;justify-content:space-between;gap:1rem;flex-wrap:wrap;
  margin-top:3rem;padding-top:1.5rem;border-top:1px solid var(--line-soft);
  font-size:.82rem;color:var(--muted-2);
}

/* ---------------- Case study dialog ---------------- */
.modal{
  position:fixed;inset:0;z-index:200;
  display:grid;place-items:center;
  padding:1.5rem;
}
.modal[hidden]{display:none}

.modal__backdrop{
  position:absolute;inset:0;
  background:rgba(3,10,22,.62);
  backdrop-filter:blur(6px);
  opacity:0;transition:opacity .3s var(--ease);
}
.modal__panel{
  position:relative;
  width:min(100%,940px);
  max-height:calc(100vh - 3rem);
  overflow:auto;
  border-radius:var(--radius-lg);
  background:var(--bg-alt);
  border:1px solid var(--line);
  box-shadow:0 50px 100px -40px rgba(3,10,22,.7);
  opacity:0;transform:translateY(14px) scale(.985);
  transition:opacity .3s var(--ease),transform .35s var(--ease);
}
.modal.is-open .modal__backdrop{opacity:1}
.modal.is-open .modal__panel{opacity:1;transform:none}

.modal__close{
  position:absolute;top:1rem;right:1rem;z-index:2;
  width:34px;height:34px;border-radius:50%;
  display:grid;place-items:center;cursor:pointer;
  background:var(--panel);border:1px solid var(--line);color:var(--muted);
  transition:color .25s var(--ease),border-color .25s var(--ease);
}
.modal__close:hover{color:var(--text);border-color:rgba(var(--btn-rgb),.5)}
.modal__close svg{width:13px;height:13px}

.modal__body{display:grid;grid-template-columns:minmax(0,1.05fr) minmax(0,.95fr)}
.modal__info{padding:2.4rem 2rem 2.4rem 2.4rem}
.modal__title{font-size:clamp(1.3rem,2.2vw,1.7rem);font-weight:400;margin:.9rem 0 .8rem;line-height:1.25}
.modal__lede{color:var(--muted);font-size:.95rem}

.modal__stats{
  display:grid;grid-template-columns:repeat(3,1fr);gap:.75rem;
  margin-top:1.6rem;padding-top:1.4rem;border-top:1px solid var(--line-soft);
}
.modal__stats div{display:flex;flex-direction:column;gap:.15rem}
.modal__stats strong{font-size:1.15rem;letter-spacing:-.02em;color:var(--text)}
.modal__stats span{font-size:.74rem;color:var(--muted-2);line-height:1.35}

/* Per-case discount capture. A sibling of the audit form, never nested —
   forms inside forms are invalid and the inner one stops submitting. */
.modal__offer{
  margin-top:1.6rem;padding-top:1.4rem;
  border-top:1px solid var(--line-soft);
}
.modal__offer[hidden]{display:none}
.modal__offer-title{font-size:.9rem;font-weight:600;margin-bottom:.7rem}
.modal__offer-form{
  display:flex;align-items:center;
  padding:5px;border-radius:999px;
  background:var(--input-solid);
  border:1px solid var(--line);
  transition:border-color .25s var(--ease),box-shadow .25s var(--ease);
}
.modal__offer-form:focus-within{
  border-color:rgba(var(--btn-rgb),.55);
  box-shadow:0 0 0 3px rgba(var(--btn-rgb),.14);
}
.modal__offer-input{
  flex:1 1 auto;min-width:0;
  font:inherit;font-size:.9rem;color:var(--text);
  background:transparent;border:0;outline:none;border-radius:999px;
  padding:.42rem .9rem;
}
.modal__offer-input::placeholder{color:var(--placeholder)}
.modal__offer-btn{flex:none;margin-left:.35rem;padding:.55rem 1.15rem;font-size:.86rem}
.modal__offer-btn:hover{transform:none}
.modal__offer-note{margin-top:.6rem;font-size:.78rem;color:var(--muted-2)}
.modal__offer .form__status{margin-top:.4rem;font-size:.82rem}

.modal__form{
  padding:2.4rem 2.4rem 2.4rem 2rem;
  display:grid;gap:.9rem;align-content:start;
  background:var(--surface);
  border-left:1px solid var(--line-soft);
}
.modal__form-title{font-size:1.02rem;font-weight:600;letter-spacing:-.01em}
.modal__form-sub{font-size:.86rem;color:var(--muted);margin-bottom:.4rem}
.modal__form .btn{margin-top:.4rem}

@media (max-width:760px){
  .modal{padding:1rem}
  .modal__body{grid-template-columns:1fr}
  .modal__info{padding:2rem 1.5rem 1.5rem}
  .modal__form{padding:1.5rem;border-left:0;border-top:1px solid var(--line-soft)}
}

/* Page beneath is frozen while the dialog is up. --sbw replaces the
   scrollbar's width so the layout does not jump sideways when it goes. */
.is-modal-open body{overflow:hidden;padding-right:var(--sbw,0px)}
.is-modal-open .nav{padding-right:var(--sbw,0px)}

/* ---------------- Floating showreel ---------------- */
.float-video{
  position:fixed;right:1.5rem;bottom:1.5rem;z-index:90;
  width:264px;padding:8px;
  border-radius:16px;
  background:var(--bg-alt);
  border:1px solid var(--line);
  box-shadow:0 30px 60px -28px rgba(0,0,0,.6);
  opacity:0;transform:translateY(26px) scale(.96);
  pointer-events:none;
  /* Grows toward the middle of the screen rather than off the corner */
  transform-origin:bottom right;
  transition:opacity .5s var(--ease),transform .45s var(--ease);
}
.float-video.is-visible{opacity:1;transform:none;pointer-events:auto}

/* Grows when the reader reaches the foot of the page (toggled in main.js) */
.float-video.is-visible.is-expanded{transform:scale(1.55)}

/* Only for real pointers — on touch there is no hover to leave, so the
   panel would stay blown up after a tap. Listed last, and the second
   selector outweighs .is-expanded, so hover always wins. */
@media (hover:hover){
  .float-video.is-visible:hover,
  .float-video.is-visible.is-expanded:hover{transform:scale(2)}
}

.float-video__media{
  position:relative;aspect-ratio:16/10;border-radius:10px;overflow:hidden;
  /* Stands in for the video until a file exists at the source path */
  background:radial-gradient(circle at 40% 55%,#f2a24a,#8a2f1c 45%,#1b0a08 85%);
}
.float-video__media iframe{
  position:absolute;inset:0;width:100%;height:100%;border:0;display:block;
}

.float-video__close{
  position:absolute;top:-9px;right:-9px;z-index:2;
  width:26px;height:26px;border-radius:50%;
  display:grid;place-items:center;cursor:pointer;
  background:var(--bg-alt);border:1px solid var(--line);color:var(--muted);
  transition:color .25s var(--ease),border-color .25s var(--ease);
}
.float-video__close:hover{color:var(--text);border-color:var(--brand-2)}
.float-video__close svg{width:12px;height:12px}

.float-video__label{
  display:flex;align-items:center;justify-content:space-between;gap:.5rem;
  font-size:.78rem;color:var(--muted);padding:.6rem .35rem .2rem;
}
.float-video__label span{color:var(--muted-2);font-variant-numeric:tabular-nums}

@media (max-width:640px){
  .float-video{right:1rem;bottom:1rem;width:184px;padding:6px}
  .float-video__label{font-size:.72rem}
  /* Gentler growth — 1.55x here would bury the footer on a phone */
  .float-video.is-visible.is-expanded{transform:scale(1.25)}
}

/* Reveal on scroll */
.reveal{opacity:0;transform:translateY(22px);transition:opacity .7s var(--ease),transform .7s var(--ease)}
.reveal.is-visible{opacity:1;transform:none}

/* ---------------- Responsive ---------------- */
@media (max-width:1040px){
  .cards,.work,.quotes{grid-template-columns:repeat(2,1fr)}
  /* Video drops below the quotes and stops following the scroll */
  .testimonials{grid-template-columns:1fr;gap:2rem}
  .testimonial-video{position:static}
  .steps{grid-template-columns:repeat(2,1fr)}
  .stats__grid{grid-template-columns:repeat(2,1fr)}
  /* Two columns rather than three — five items across three tracks would
     strand Offices alone on its own row */
  .footer__inner{grid-template-columns:1fr 1fr;gap:2rem}
  .footer__brand{grid-column:1/-1}
}

@media (max-width:900px){
  .nav__links{display:none}
  .nav .btn--pill{display:none}
  .nav__toggle{display:flex;margin-left:auto}
  .nav__mobile{display:flex}
  .nav__mobile[hidden]{display:none}

  .hero{padding-top:7.5rem}
  .hero__inner{grid-template-columns:1fr;min-height:60vh;gap:3rem}

  .about{grid-template-columns:1fr;gap:2.5rem}
  .cta__inner{grid-template-columns:1fr;gap:2.5rem}
}

@media (max-width:640px){
  .section{padding:4.5rem 0}
  #process{padding-top:8rem}
  .cards,.work,.quotes,.steps{grid-template-columns:1fr}
  .stats__grid{grid-template-columns:1fr 1fr}
  .form__row{grid-template-columns:1fr}
  .form{padding:1.4rem}
  .hero__actions{width:100%;flex-direction:column;align-items:stretch}
  .hero__signup{width:100%}
  .hero__signup-input{width:100%}
  .footer__inner{grid-template-columns:1fr 1fr}
  /* Extra headroom so the headline clears the fixed nav and sits lower
     in the frame rather than starting right under it */
  /* Hidden on phones: a half-width clip behind centred text is unreadable
     once the column is this narrow */
  .hero__video{display:none}
  .hero{padding-top:15rem;padding-bottom:3.5rem}
  /* Visible from the outset here — the first-scroll reveal is skipped on
     phones, so the hidden starting state must not apply either. */
  .js .hero__trusted{opacity:1;transform:none}
  .hero__trusted{margin-top:2.25rem}
}

/* Pinning is unpleasant on short/touch viewports and pointless without
   motion — in both cases the section falls back to a normal stacked layout. */
@media (max-width:760px),(prefers-reduced-motion:reduce){
  /* Frame-accurate seeking is unreliable and expensive on touch devices,
     so the clip plays as an ordinary looping banner instead. */
  .scrub-track{height:auto}
  .scrub-stage{position:static;height:56vh}
  .scrub-frame{
    width:100%;height:100%;aspect-ratio:auto;
    border-radius:0;
  }
  .scrub-frame::after{display:none}
  .scrub-veil{display:none}

  .work-section{padding:6.5rem 0;margin-top:0}
  .work-track{height:auto}
  .work-stage{position:static;height:auto;overflow:visible;display:block}
  .work__head{opacity:1 !important;transform:none !important}
  /* No scaling here, so no overhang to compensate for */
  .work__title{transform:none !important;margin-bottom:1rem}
  .work__sub,
  .work__item{opacity:1 !important;transform:none !important}
}
@media (max-width:640px){
  .work-section{padding:4.5rem 0}
}

@media (prefers-reduced-motion:reduce){
  html{scroll-behavior:auto}
  *,*::before,*::after{animation-duration:.001ms !important;animation-iteration-count:1 !important;transition-duration:.001ms !important}
  .reveal{opacity:1;transform:none}
}

/* Back link at the foot of a single case study */
.case__back{margin-top:1.5rem;font-size:.87rem}
.case__back a{color:var(--btn-to);text-decoration:underline;text-underline-offset:3px}

/* Logos scale down with the rest of the hero on phones */
@media (max-width:640px){
  .logo-row__item{height:calc(var(--h,26px) * .78)}
}

/* Linked logos. The anchor wraps the image, so it must size to it rather
   than to the flex line, and the hover brighten has to work from either. */
.logo-row a{display:inline-flex;align-items:center}
.logo-row a:hover .logo-row__item{opacity:1}

/* Careers roles reuse the FAQ accordion. The summary carries a location
   alongside the title, so it needs to sit before the chevron rather than
   push it out of line. */
.role__meta{
  margin-left:auto;margin-right:.9rem;
  font-size:.8rem;font-weight:400;color:var(--muted-2);white-space:nowrap;
}
.role__apply{margin-top:1rem}
.role__apply a{
  font-size:.88rem;font-weight:500;color:var(--btn-to);
  text-decoration:underline;text-underline-offset:3px;
}

@media (max-width:560px){
  /* Stacked: the two lines will not share a row at this width */
  .faq__item summary{flex-wrap:wrap}
  .role__meta{margin-left:0;flex-basis:100%;margin-top:.3rem}
}

/* ---------------- Blog listing ---------------- */
.posts{display:grid;grid-template-columns:repeat(3,1fr);gap:1.1rem}

.post{
  display:flex;flex-direction:column;
  padding:1.7rem;
  border-radius:var(--radius-lg);
  background:var(--surface);
  border:1px solid var(--line);
  transition:border-color .3s var(--ease),transform .3s var(--ease);
}
.post:hover{border-color:rgba(var(--btn-rgb),.45);transform:translateY(-3px)}

.post__tag{
  align-self:flex-start;margin-bottom:.9rem;
  font-size:.74rem;letter-spacing:.02em;color:var(--btn-to);
  border:1px solid rgba(var(--btn-rgb),.35);border-radius:999px;
  padding:.24rem .7rem;
}
.post h2,.post h3{font-weight:400;line-height:1.25;margin-bottom:.7rem}
.post h3{font-size:1.1rem}
.post a{transition:color .2s var(--ease)}
.post a:hover{color:var(--btn-to)}
.post p{color:var(--muted);font-size:.93rem}

.post__meta{
  margin-top:auto;padding-top:1.2rem;
  border-top:1px solid var(--line-soft);
  font-size:.78rem;color:var(--muted-2);
}

/* The lead post runs the full width above the grid */
.post--featured{margin-bottom:1.1rem;padding:2.2rem}
.post--featured h2{font-size:clamp(1.4rem,2.6vw,2rem)}
.post--featured p{font-size:1rem;max-width:64ch}
.post--featured .post__meta{border-top:0;padding-top:1.4rem;max-width:none}

@media (max-width:1040px){
  .posts{grid-template-columns:repeat(2,1fr)}
}
@media (max-width:640px){
  .posts{grid-template-columns:1fr}
  .post--featured{padding:1.6rem}
}

/* Avatars are photographs now rather than initials, so the gradient and
   centring the letters needed are irrelevant — but the sizing and the
   ring are kept, and cover stops non-square crops distorting. */
img.quote__avatar{
  object-fit:cover;
  background:none;
  display:block;
}

/* ---------------- Legal pages ---------------- */
.legal__stamp{margin-top:1.4rem;font-size:.82rem;color:var(--muted-2)}

.legal h2{
  font-size:1.15rem;font-weight:600;
  margin:2.4rem 0 .8rem;
  padding-top:1.6rem;border-top:1px solid var(--line-soft);
}
.legal h2:first-child{margin-top:0;padding-top:0;border-top:0}
.legal p{color:var(--muted);font-size:.95rem;margin-bottom:.9rem;max-width:70ch}
.legal a{color:var(--btn-to);text-decoration:underline;text-underline-offset:3px}

.legal__list{display:grid;gap:.7rem;margin:0 0 1.1rem}
.legal__list li{
  font-size:.94rem;color:var(--muted);
  padding-left:1.4rem;position:relative;max-width:70ch;
}
.legal__list li::before{
  content:"";position:absolute;left:0;top:.62em;
  width:5px;height:5px;border-radius:50%;
  background:var(--btn-to);opacity:.7;
}
.legal__list strong{color:var(--text);font-weight:600}

/* Honeypot field — moved off-screen rather than display:none, which some
   bots detect and skip. */
.hp{
  position:absolute!important;
  width:1px;height:1px;
  padding:0;border:0;
  overflow:hidden;
  clip:rect(0 0 0 0);clip-path:inset(50%);
  white-space:nowrap;
}
