/* ==========================================================
   TO Solutions — site styles
   Base palette follows the TO Solutions brand (black monochrome,
   WCAG AA greys). Blue + lime are web-only accents: remove them
   by pointing --accent / --highlight at black / white.
   ========================================================== */
:root {
  /* brand monochrome */
  --black: #000000;
  --ink: #000000;           /* headings */
  --text: #2d2d2d;          /* body text (14.4:1 on white) */
  --ink-2: #595959;         /* secondary text (7:1 on white) */
  --ink-3: #767676;         /* tertiary text (4.54:1 on white) */
  --line: #e0e0e0;
  --tint: #f5f5f5;          /* neutral card / footer background */
  --paper: #ffffff;
  --hero-bg: #000000;       /* hero + dark sections */
  --muted-bg: #111111;      /* "All your systems" section */

  /* web accents (owner decision — see README) */
  --accent: #3F00FF;        /* ultramarine: fills, buttons, accents on white (7.9:1 with white text) */
  --accent-light: #C7B8FF;  /* decorative only */
  --accent-tint: #EFEAFF;
  --highlight: #00E676;     /* green: fills on dark (black text), accents on black/ultramarine (never on white) */
  --money: #00E676;          /* green accent: saving figure, "busywork.", ticks, quote mark, chips (13:1 on black) */
  --accent-bright: #00E676; /* text/icons on black (13:1) */

  --radius: 22px;
  --font-display: "Inter Tight", "Helvetica Neue", Arial, sans-serif;
  --font-body: "Inter", "Helvetica Neue", Arial, sans-serif;
  --gutter: clamp(16px, 3.5vw, 50px);
}

*, *::before, *::after { box-sizing: border-box; }
html {
  scroll-behavior: smooth;
  background: var(--tint);        /* matches the footer, so iOS overscroll never shows a white band */
  overscroll-behavior-y: none;    /* no rubber-band bounce past the footer (Safari 16+) */
  overflow-x: clip;               /* nothing can widen the page and make Safari zoom out */
}
/* WebKit (iPad Safari / Chrome for iOS) paints the overscroll area with the BODY colour
   blended over the html colour, so a white body showed as a white band below the footer.
   Body is tinted like the footer; the white page background lives on <main> instead. */
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--text);
  background: var(--tint);
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
  overscroll-behavior-y: none;
}
main { display: block; background: var(--paper); }
[hidden] { display: none !important; } /* author display rules (e.g. img { display: block }) must not un-hide */
img { max-width: 100%; height: auto; display: block; }
dialog:not([open]) { display: none !important; } /* a closed pop-up must never take up space */
a { color: inherit; text-decoration: none; }
h1, h2, h3 { font-family: var(--font-display); letter-spacing: -0.035em; margin: 0; font-weight: 500; color: inherit; }
.ico { width: 1.1em; height: 1.1em; flex: none; }

/* ---------- Focus + skip link ---------- */
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 6px; }
.hero :focus-visible, .stepper :focus-visible, .split :focus-visible, .testimonials :focus-visible,
.topbar :focus-visible { outline-color: var(--accent-bright); }
.skip-link { position: absolute; left: 16px; top: -60px; z-index: 100; background: var(--highlight); color: #000; padding: 10px 16px; border-radius: 10px; font-weight: 600; }
.skip-link:focus { top: 16px; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 12px 22px; border-radius: 12px; font-weight: 600; font-size: 15px;
  border: 1.5px solid transparent; transition: transform .2s, background-color .2s, color .2s;
  cursor: pointer; min-height: 44px;
}
.btn:hover { transform: translateY(-2px); }
.btn-lg { padding: 16px 28px; font-size: 17px; }
.btn-light { background: var(--accent); color: #fff; }
.btn-ghost-light { color: #fff; padding-left: 4px; }
.btn-ghost-light:hover .ico { transform: translateX(3px); }
.btn-ghost-light .ico { transition: transform .2s; }
.btn-dark { background: #000; color: #fff; }
.btn-outline-dark { border-color: #000; color: #000; }

/* ---------- Top bar + main menu (fixed) ---------- */
.topbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 60;
  display: flex; justify-content: space-between; align-items: center; gap: 24px;
  padding: 20px var(--gutter); color: #fff;
  transition: background-color .3s, padding .3s, box-shadow .3s;
}
.topbar.scrolled { background: rgba(0,0,0,.92); backdrop-filter: blur(10px); padding-top: 12px; padding-bottom: 12px; box-shadow: 0 1px 0 rgba(255,255,255,.08); }
.logo { display: block; color: #fff; }
.logo svg { display: block; height: 40px; width: calc(40px * 3.39); }
.logo-dark { color: #000; }
.site-nav { display: flex; align-items: center; gap: 4px; font-size: 15px; }
.nav-link, .nav-item > button {
  display: inline-flex; align-items: center; min-height: 44px; padding: 0 14px; border-radius: 99px;
  background: none; border: 0; color: #fff; font: 500 15px var(--font-body); cursor: pointer; white-space: nowrap;
}
.nav-link:hover, .nav-item > button:hover { background: rgba(255,255,255,.1); }
.nav-cta { margin-left: 10px; }
.chev { width: 14px; height: 14px; margin-left: 4px; transition: transform .2s; }
.nav-item.open .chev { transform: rotate(180deg); }
.nav-item { position: relative; }
.nav-menu {
  position: absolute; top: calc(100% + 10px); left: 50%; transform: translate(-50%, -8px);
  background: #fff; color: #000; border-radius: 16px; padding: 8px; min-width: 220px;
  box-shadow: 0 20px 50px rgba(0,0,0,.2); opacity: 0; visibility: hidden; pointer-events: none;
  transition: opacity .2s, transform .2s, visibility .2s;
}
.nav-menu a { display: block; padding: 11px 12px; border-radius: 10px; }
.nav-menu a:hover, .nav-menu a:focus-visible { background: var(--tint); }
.nav-item:hover .nav-menu, .nav-item.open .nav-menu, .nav-item:focus-within .nav-menu {
  opacity: 1; visibility: visible; pointer-events: auto; transform: translate(-50%, 0);
}
.nav-toggle { display: none; width: 44px; height: 44px; border-radius: 12px; border: 1px solid rgba(255,255,255,.25); background: none; color: #fff; cursor: pointer; place-items: center; }
.nav-toggle svg { width: 22px; height: 22px; }
html { scroll-padding-top: 80px; }

/* ---------- Hero (black) ---------- */
.hero {
  position: relative; min-height: 100vh; min-height: 100svh; background: var(--hero-bg);
  color: #fff; overflow: hidden; display: flex; align-items: center; /* centred, so squarer screens (iPad, 4:3) don't get an empty band on top */
  padding: 108px var(--gutter) 28px; /* top = 84px top bar + the same 24-28px as the bottom, so the content sits in the true centre of the visible space */
}
.hero::before { /* soft glow behind the media */
  content: ""; position: absolute; right: -10%; top: -10%; width: 60vw; height: 60vw;
  background: radial-gradient(closest-side, rgba(63,0,255,.35), transparent); pointer-events: none;
}
.hero-inner { position: relative; z-index: 2; width: 100%; display: grid; grid-template-columns: 1.25fr .75fr; gap: 40px; align-items: end; }
.hero-title { font-size: clamp(56px, 9.5vw, 156px); line-height: .92; }
.hero-title em { font-style: normal; color: var(--highlight); }
/* Portrait desktop screens (e.g. a rotated monitor): a full-height hero with bottom-aligned
   content leaves a huge empty band above the headline, so size to the content instead. */
@media (min-width: 901px) and (max-aspect-ratio: 1/1) {
  .hero { min-height: 0; align-items: center; padding-top: 150px; padding-bottom: 110px; }
  .hero-title { font-size: clamp(56px, 8.4vw, 140px); } /* keeps "the repetitive." on one line */
}
/* rotating last word: busywork. -> admin. -> repetitive. */
.rotator { display: inline-grid; vertical-align: bottom; overflow: hidden; padding-bottom: .08em; margin-bottom: -.08em; }
.rot-word { grid-area: 1 / 1; transform: translateY(105%); opacity: 0; transition: transform .27s cubic-bezier(.2,.7,.2,1), opacity .2s ease; }
.rot-word.is-active { transform: none; opacity: 1; }
.rot-word.is-leaving { transform: translateY(-105%); opacity: 0; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.hero-lede { font-size: 20px; line-height: 1.4; max-width: 460px; margin: 28px 0 26px; color: rgba(255,255,255,.85); }
.hero-ctas { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }

.hero-media { position: relative; justify-self: end; width: min(420px, 100%); aspect-ratio: 4 / 5; }
.hero-photo { width: 100%; height: 100%; object-fit: cover; border-radius: 28px; }
.hero-phone { position: absolute; left: -22%; bottom: -8%; width: 52%; filter: drop-shadow(0 30px 50px rgba(0,0,0,.6)); }
.hero-chip {
  position: absolute; right: -6%; top: 10%; display: flex; gap: 10px; align-items: center;
  background: #fff; color: #000; border-radius: 16px; padding: 12px 16px; box-shadow: 0 20px 40px rgba(0,0,0,.35);
}
.hero-chip .ico { width: 34px; height: 34px; padding: 7px; border-radius: 10px; background: var(--accent); color: #fff; }
.hero-chip b { display: block; font-size: 14px; }
.hero-chip small { font-size: 12px; color: var(--ink-2); }

/* ---------- Workflow: connect your whole business ---------- */
.flow-section { background: #000; color: #fff; padding: 16vh var(--gutter); overflow: hidden; }
.flow-inner { display: grid; grid-template-columns: .9fr 1.1fr; gap: 70px; align-items: center; max-width: 1300px; margin: 0 auto; }
.tag.tag-dark { border-color: rgba(255,255,255,.25); color: rgba(255,255,255,.8); }
.flow-title { font-size: clamp(48px, 7vw, 108px); line-height: .95; }
.flow-lede { font-size: 19px; line-height: 1.5; color: rgba(255,255,255,.82); max-width: 460px; margin: 26px 0 28px; }
.flow-points { list-style: none; padding: 0; margin: 0; display: grid; gap: 14px; }
.flow-points li { display: flex; gap: 12px; align-items: center; font-size: 16px; color: rgba(255,255,255,.9); }
.flow-points svg { width: 34px; height: 34px; padding: 7px; border-radius: 10px; background: rgba(255,255,255,.08); color: var(--money); flex: none; }

.flow-stage { position: relative; padding: 50px 0; }
.flow-stage::before { /* brand glow behind the panel */
  content: ""; position: absolute; inset: -10% -15%; z-index: 0; pointer-events: none;
  background: radial-gradient(40% 45% at 30% 30%, rgba(63,0,255,.35), transparent 70%),
              radial-gradient(35% 40% at 75% 80%, rgba(157,133,255,.14), transparent 70%);
}
.flow-chip {
  position: absolute; z-index: 2; display: flex; align-items: center; gap: 12px;
  padding: 12px 16px 12px 12px; border-radius: 16px; color: #fff;
  background: #141a2e; border: 1px solid rgba(255,255,255,.16);
  box-shadow: 0 20px 40px rgba(0,0,0,.4); animation: chipFloat 5s ease-in-out infinite;
}
.flow-chip b { display: block; font-size: 14px; }
.flow-chip small { font-size: 12px; color: rgba(255,255,255,.7); }
.chip-ico { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 10px; background: var(--accent); color: #fff; flex: none; }
.chip-ico.lime { background: var(--money); color: #000; }
.chip-ico svg { width: 18px; height: 18px; }
.chip-in { left: 0; top: 0; }
.chip-out { right: 0; bottom: 0; animation-delay: -2.5s; }
@keyframes chipFloat { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }

.flow-panel {
  position: relative; z-index: 1; max-width: 520px; margin: 0 auto; padding: 34px 30px;
  border-radius: 26px; border: 1px solid rgba(255,255,255,.14);
  background:
    radial-gradient(rgba(255,255,255,.14) 1px, transparent 1.5px) 0 0 / 22px 22px,
    rgba(28,32,48,.72);
  backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px);
  box-shadow: 0 40px 80px rgba(0,0,0,.45);
}
.fnode {
  position: relative; background: #fff; color: #000; border-radius: 16px; padding: 16px 18px;
  box-shadow: 0 10px 24px rgba(0,0,0,.18); transition: box-shadow .3s, transform .3s;
}
.fnode-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 6px; }
.fkind { font: 600 11px var(--font-body); letter-spacing: .1em; text-transform: uppercase; color: var(--ink-2); }
.fnode-ico { width: 20px; height: 20px; color: #000; }
.fnode-title { margin: 0 0 4px; font: 600 17px var(--font-display); letter-spacing: -.01em; }
.fnode-text { margin: 0; font-size: 14px; line-height: 1.45; color: var(--ink-2); }
.fbranch { display: flex; justify-content: space-between; gap: 10px; margin-top: 12px; padding-top: 10px; border-top: 1px solid var(--line); font-size: 13px; font-weight: 600; }
.fbranch span { display: inline-flex; align-items: center; gap: 5px; }
.fbranch svg { width: 15px; height: 15px; }
.fbranch .yes { color: #3F00FF; }
.fbranch .no { color: var(--ink-2); font-weight: 500; }
.fnode-done {
  position: absolute; top: -9px; right: -9px; width: 26px; height: 26px; border-radius: 50%;
  display: grid; place-items: center; background: var(--money); color: #000;
  box-shadow: 0 0 0 3px #1c2030; transform: scale(0); transition: transform .3s cubic-bezier(.3,1.6,.5,1);
}
.fnode-done svg { width: 14px; height: 14px; stroke-width: 2.6; }
.fnode.done .fnode-done { transform: scale(1); }
.fnode.active { box-shadow: 0 0 0 3px var(--accent), 0 16px 34px rgba(63,0,255,.35); transform: translateY(-2px); }
.fnode.active .fnode-ico { color: var(--accent); }

.fconn { position: relative; height: 44px; display: grid; place-items: center; }
.fconn svg { width: 24px; height: 44px; overflow: visible; }
.fconn .fline, .fconn .fhead { fill: none; stroke: rgba(255,255,255,.35); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; transition: stroke .3s; }
.fconn.live .fline, .fconn.live .fhead { stroke: var(--accent-bright); }
.fpulse { position: absolute; left: 50%; top: 0; width: 8px; height: 8px; margin-left: -4px; border-radius: 50%; background: var(--accent-bright); opacity: 0; }
.fconn.live .fpulse { animation: fpulse .9s ease-in both; }
@keyframes fpulse { from { transform: translateY(0); opacity: 1; } to { transform: translateY(34px); opacity: 0; } }

/* ---------- Statement ---------- */
.statement { padding: 18vh var(--gutter); text-align: center; overflow: hidden; }
/* Scroll-linked: JS sets --p from 0 (entering) to 1 (leaving) */
.st-line { display: block; transform-origin: center; will-change: transform; }
.st-less { transform: scale(calc(1 - var(--p, 0) * .35)); opacity: calc(1 - var(--p, 0) * .5); }
.st-more { transform: scale(calc(.9 + var(--p, 0) * .22)); }
.statement-text {
  font-family: var(--font-display); font-size: clamp(40px, 6.5vw, 100px);
  letter-spacing: -0.04em; line-height: 1.05; color: var(--ink); margin: 0;
}
.pill-icon {
  display: inline-grid; place-items: center; vertical-align: middle;
  width: 1.5em; height: .95em; border-radius: .3em; background: #000; color: #fff;
}
.pill-icon.lime { background: var(--accent); color: var(--highlight); }
.pill-icon svg { width: .55em; height: .55em; }

/* ---------- Stepper ---------- */
.stepper { position: relative; background: var(--accent); color: #fff; padding: 12vh max(var(--gutter), 92px); }
.stepper-inner { display: grid; grid-template-columns: 1fr 1fr; gap: 60px; align-items: center; max-width: 1300px; margin: 0 auto; }
.eyebrow { text-transform: uppercase; letter-spacing: .12em; font: 600 13px var(--font-body); }
.stepper-heading { font-size: clamp(44px, 6vw, 88px); line-height: 1; margin: 12px 0 18px; min-height: 1em; }
.stepper-body { font-size: 19px; line-height: 1.45; max-width: 460px; min-height: 84px; margin: 0; }
.stepper-nav { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 30px; }
.step {
  display: flex; align-items: center; gap: 8px; background: none; border: 0; color: #fff;
  font: 500 15px var(--font-body); cursor: pointer; padding: 0; min-height: 44px;
}
.step span { display: grid; place-items: center; width: 40px; height: 40px; border: 1.5px solid rgba(255,255,255,.85); border-radius: 50%; font-size: 13px; }
.step em { font-style: normal; }
.step:not(.active) em { /* visually hidden, still announced */
  position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap;
}
.step-arrow { position: absolute; top: 50%; transform: translateY(-50%); z-index: 2; width: 52px; height: 52px; border-radius: 50%; border: 1.5px solid #fff; background: transparent; color: #fff; cursor: pointer; display: grid; place-items: center; transition: background-color .15s, color .15s; }
#stepPrev { left: 20px; }
#stepNext { right: 20px; }
.step-hint { margin: 18px 0 0; font-size: 14px; color: rgba(255,255,255,.85); }
.step-hint b { color: var(--highlight); font-weight: 700; }
/* pulse on the next arrow until someone uses the controls */
.step-arrow.nudge::after { content: ""; position: absolute; inset: -2px; border-radius: 50%; border: 2px solid var(--highlight); animation: arrowNudge 1.8s ease-out infinite; pointer-events: none; }
@keyframes arrowNudge { 0% { transform: scale(1); opacity: .9; } 100% { transform: scale(1.6); opacity: 0; } }
.step-arrow:hover { background: #fff; color: var(--accent); }
.step-arrow svg { width: 20px; height: 20px; }
.step.active span { background: var(--highlight); color: #000; border-color: var(--highlight); }

.device { background: rgba(255,255,255,.3); border-radius: 30px; padding: 14px; max-width: 460px; margin-left: auto; }
.device-head { display: flex; gap: 6px; padding: 4px 8px 12px; }
.device-head span { width: 10px; height: 10px; border-radius: 50%; background: #fff; opacity: .7; }
.device-body { background: #fff; border-radius: 20px; min-height: 380px; padding: 22px; color: var(--text); }
.device-title { margin: 0 0 4px; font: 600 22px var(--font-display); letter-spacing: -.02em; color: #000; }
.device-body .muted { color: var(--ink-2); font-size: 14px; margin: 0 0 14px; }
.device-body .row { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 13px 0; border-bottom: 1px solid var(--line); font-size: 15px; animation: rowIn .45s both; }
.device-body .row:last-child { border: 0; }
.device-body .row b { font-weight: 600; color: #000; display: flex; align-items: center; gap: 10px; }
.device-body .badge { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; font-weight: 600; padding: 4px 10px; border-radius: 99px; background: var(--accent-tint); color: #3F00FF; white-space: nowrap; }
.device-body .badge.ok { background: #000; color: var(--accent-bright); }
.device-body .badge svg { width: 14px; height: 14px; }
.device-body .ri { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 9px; background: var(--tint); color: #000; flex: none; }
.device-body .ri svg { width: 17px; height: 17px; }
.bubble { max-width: 80%; padding: 10px 14px; border-radius: 16px; font-size: 14px; line-height: 1.4; margin: 0 0 10px; animation: rowIn .45s both; }
.bubble.in { background: var(--tint); color: #000; border-bottom-left-radius: 4px; }
.bubble.out { background: var(--accent); color: #fff; margin-left: auto; border-bottom-right-radius: 4px; }
.mini-bars { display: flex; align-items: flex-end; gap: 10px; height: 120px; margin: 6px 0 14px; }
.mini-bars i { flex: 1; background: var(--line); border-radius: 6px; animation: grow .6s both; transform-origin: bottom; }
.mini-bars i:last-child { background: var(--accent); }
@keyframes rowIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
@keyframes grow { from { transform: scaleY(0); } to { transform: scaleY(1); } }

/* ---------- Split ---------- */
.split { background: var(--muted-bg); color: #fff; padding: 14vh var(--gutter); }
.split-inner { display: grid; grid-template-columns: 1.1fr 1fr; gap: 60px; align-items: center; max-width: 1300px; margin: 0 auto; }
.split-title { font-size: clamp(48px, 7vw, 110px); line-height: .95; }
.split-body { font-size: 19px; line-height: 1.45; max-width: 480px; margin: 24px 0 30px; color: rgba(255,255,255,.85); }
.split-img { border-radius: var(--radius); width: 100%; }

/* ---------- Custom software ---------- */
.headline-block { padding: 16vh var(--gutter); text-align: center; max-width: 1300px; margin: 0 auto; }
.tag { display: inline-block; border: 1px solid var(--line); color: var(--ink-2); border-radius: 99px; padding: 4px 14px; font-size: 13px; margin: 0 0 22px; }
.headline-lg { font-size: clamp(40px, 6vw, 84px); line-height: 1; color: var(--ink); max-width: 1000px; margin: 0 auto; }
.feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-top: 70px; text-align: left; }
.feature { background: var(--tint); border-radius: var(--radius); padding: 14px 14px 28px; }
.feature img { border-radius: 14px; aspect-ratio: 13 / 10; object-fit: cover; width: 100%; margin-bottom: 20px; }
.feature h3 { font-size: 26px; color: #000; margin: 0 14px 10px; }
.feature p { margin: 0 14px; color: var(--ink-2); line-height: 1.5; }

/* ---------- Calculator ---------- */
.calc { padding: 4vh var(--gutter) 16vh; }
.calc-head { text-align: center; margin-bottom: 44px; }
.calc-title { font-size: clamp(40px, 6vw, 84px); color: var(--ink); }
.calc-sub { display: inline-flex; align-items: center; gap: 8px; margin: 16px 0 0; font-size: 17px; color: var(--ink-2); }
.calc-sub svg { width: 22px; height: 22px; color: var(--accent); }
.calc-layout { display: grid; grid-template-columns: 1fr 1.1fr; gap: 20px; max-width: 1060px; margin: 0 auto; align-items: stretch; }

/* the answer: big lime number on black */
.calc-result { background: #000; color: #fff; border-radius: 24px; padding: 36px 34px; display: flex; flex-direction: column; gap: 18px; }
.calc-kicker { font: 600 13px var(--font-body); letter-spacing: .12em; text-transform: uppercase; color: rgba(255,255,255,.7); }
.calc-big { display: block; font: 600 clamp(56px, 7vw, 92px) / 1 var(--font-display); letter-spacing: -.04em; color: var(--money); font-variant-numeric: tabular-nums; }
.calc-big.bump { animation: calcBump .35s ease-out; }
@keyframes calcBump { 0% { transform: scale(1); } 40% { transform: scale(1.04); } 100% { transform: scale(1); } }
.calc-breakdown { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; padding-top: 18px; border-top: 1px solid rgba(255,255,255,.15); }
.calc-breakdown b { display: block; font: 600 26px var(--font-display); color: #fff; font-variant-numeric: tabular-nums; }
.calc-breakdown span { font-size: 14px; color: rgba(255,255,255,.7); }
.calc-result .btn { align-self: flex-start; margin-top: auto; }
.calc-result .btn-light { background: var(--money); color: #000; }
.calc-result small { font-size: 13px; line-height: 1.5; color: rgba(255,255,255,.65); }

/* the inputs: white cards, black tracks, lime handles */
.calc-inputs { display: grid; gap: 16px; align-content: stretch; }
.calc-field { background: #fff; border: 1px solid var(--line); border-radius: 20px; padding: 22px 22px 16px; display: grid; gap: 14px; transition: border-color .2s, box-shadow .2s; }
.calc-field:focus-within, .calc-field:hover { border-color: #000; box-shadow: 0 10px 30px rgba(0,0,0,.06); }
.calc-field-head { display: flex; justify-content: space-between; align-items: center; gap: 14px; }
.calc-field-head label { font-size: 15px; font-weight: 600; color: #000; line-height: 1.35; }
.calc-badge { flex: none; background: #000; color: #fff; font: 600 18px var(--font-display); padding: 6px 14px; border-radius: 99px; font-variant-numeric: tabular-nums; min-width: 84px; text-align: center; }
.calc-control { display: flex; align-items: center; gap: 12px; }
.calc-step { flex: none; width: 40px; height: 40px; border-radius: 50%; border: 1.5px solid #000; background: #fff; color: #000; display: grid; place-items: center; cursor: pointer; transition: background-color .15s, color .15s; }
.calc-step:hover { background: #000; color: #fff; }
.calc-step svg { width: 18px; height: 18px; stroke-width: 2.4; }
.calc-range { position: relative; flex: 1; }
.calc-scale { display: flex; justify-content: space-between; padding: 0 52px; font-size: 12px; color: var(--ink-3); }

.calc-range input[type="range"] { -webkit-appearance: none; appearance: none; display: block; width: 100%; height: 44px; margin: 0; background: transparent; cursor: grab; --fill: 20%; }
.calc-range input[type="range"]:active { cursor: grabbing; }
.calc-range input[type="range"]::-webkit-slider-runnable-track { height: 10px; border-radius: 99px; background: linear-gradient(to right, #000 var(--fill), #e8e8e8 var(--fill)); }
.calc-range input[type="range"]::-webkit-slider-thumb { -webkit-appearance: none; width: 32px; height: 32px; margin-top: -11px; border-radius: 50%; background: var(--accent); border: 3px solid #000; box-shadow: 0 4px 12px rgba(0,0,0,.25); transition: transform .15s; }
.calc-range input[type="range"]:hover::-webkit-slider-thumb, .calc-range input[type="range"]:active::-webkit-slider-thumb { transform: scale(1.12); }
.calc-range input[type="range"]::-moz-range-track { height: 10px; border-radius: 99px; background: #e8e8e8; }
.calc-range input[type="range"]::-moz-range-progress { height: 10px; border-radius: 99px; background: #000; }
.calc-range input[type="range"]::-moz-range-thumb { width: 26px; height: 26px; border-radius: 50%; background: var(--accent); border: 3px solid #000; box-shadow: 0 4px 12px rgba(0,0,0,.25); }
.calc-range input[type="range"]:focus { outline: none; }
.calc-range input[type="range"]:focus-visible::-webkit-slider-thumb { box-shadow: 0 0 0 5px rgba(63,0,255,.45); }
.calc-range input[type="range"]:focus-visible::-moz-range-thumb { box-shadow: 0 0 0 5px rgba(63,0,255,.45); }

/* "Drag me" hint that follows the first handle until someone touches a slider */
.drag-hint {
  position: absolute; bottom: calc(100% + 6px); left: var(--fill, 20%); transform: translateX(-50%);
  background: var(--accent); color: #fff; font: 600 12px var(--font-body); padding: 6px 11px; border-radius: 99px; white-space: nowrap;
  pointer-events: none; animation: hintBob 1.4s ease-in-out infinite; transition: opacity .3s;
}
.drag-hint::after { content: ""; position: absolute; left: 50%; top: 100%; margin-left: -5px; border: 5px solid transparent; border-top-color: var(--accent); }
.drag-hint.gone { opacity: 0; }
@keyframes hintBob { 0%, 100% { transform: translate(-50%, 0); } 50% { transform: translate(-50%, -4px); } }

/* ---------- Testimonials ---------- */
.testimonials { position: relative; isolation: isolate; min-height: 100vh; display: grid; place-items: center; align-content: center; gap: 60px; padding: 14vh var(--gutter); overflow: hidden; color: #fff; background: #000; }
.testimonials-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; }
.testimonials::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(rgba(0,0,0,.6), rgba(0,0,0,.75)); }
.testimonials-title { font-size: clamp(44px, 7vw, 100px); text-align: center; }
.quote-card {
  position: relative; width: min(760px, 100%); background: #fff; color: #000; border-radius: 26px;
  padding: 36px 48px 28px; box-shadow: 0 40px 90px rgba(0,0,0,.45);
}
/* slides stack in one grid cell: the card is always as tall as the longest quote, and they cross-fade */
.quote-track { display: grid; }
.quote { grid-area: 1 / 1; margin: 0; opacity: 0; visibility: hidden; transform: translateY(10px); transition: opacity .5s ease, transform .5s ease, visibility .5s; display: flex; flex-direction: column; }
.quote.is-active { opacity: 1; visibility: visible; transform: none; }
.quote-tag { align-self: flex-start; background: var(--accent); color: #fff; font: 700 13px var(--font-body); letter-spacing: .02em; padding: 7px 14px; border-radius: 99px; margin-bottom: 20px; }
.quote-text { margin: 0 0 28px; font: 500 clamp(20px, 2.2vw, 26px) / 1.4 var(--font-display); letter-spacing: -.01em; color: #000; }
.quote-by { display: flex; align-items: center; gap: 14px; margin-top: auto; }
.quote-by b { display: block; font-size: 16px; color: #000; }
.quote-by small { font-size: 14px; color: var(--ink-2); }
.avatar { width: 46px; height: 46px; border-radius: 50%; display: grid; place-items: center; background: var(--accent); color: #fff; font-weight: 700; font-size: 14px; flex: none; }
.quote-controls { display: flex; align-items: center; justify-content: space-between; margin-top: 26px; padding-top: 18px; border-top: 1px solid var(--line); }
.quote-dots { display: flex; gap: 2px; }
.quote-dots button { width: 40px; height: 40px; border: 0; background: none; cursor: pointer; padding: 0; display: grid; place-items: center; }
.quote-dots button::before { content: ""; width: 8px; height: 8px; border-radius: 99px; background: #cfcfcf; transition: width .3s, background-color .3s; }
.quote-dots button[aria-current="true"]::before { width: 24px; background: #000; }
.quote-nav { display: flex; gap: 8px; }
.quote-btn { width: 42px; height: 42px; border-radius: 50%; border: 1.5px solid #000; background: #fff; color: #000; cursor: pointer; display: grid; place-items: center; transition: background-color .15s, color .15s; }
.quote-btn:hover { background: #000; color: #fff; }
.quote-btn svg { width: 17px; height: 17px; }
.testimonials :focus-visible { outline-color: var(--accent); }
@media (max-width: 600px) { .quote-card { padding: 38px 24px 22px; } }


/* ---------- Big CTA ---------- */
.bigstat { padding: 18vh var(--gutter) 14vh; text-align: center; color: var(--ink); }
.chip-row { display: flex; justify-content: center; margin-bottom: 34px; }
.chip-row span { display: grid; place-items: center; width: 56px; height: 56px; border-radius: 50%; background: #000; color: #fff; border: 3px solid #fff; margin-left: -12px; }
.chip-row span:first-child { margin-left: 0; }
.chip-row span.lime { background: var(--accent); color: #fff; }
.chip-row svg { width: 24px; height: 24px; }
.bigstat-title { font-size: clamp(52px, 9.5vw, 150px); line-height: .92; }
.bigstat-sub { font-size: 20px; margin: 30px 0; color: var(--ink-2); }
.bigstat-ctas { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

/* ---------- Case studies ---------- */
.cases { padding: 4vh var(--gutter) 16vh; max-width: 1300px; margin: 0 auto; }
.cases-head { text-align: center; margin-bottom: 70px; }
.cases-intro { color: var(--ink-2); font-size: 18px; margin: 18px 0 0; }
.cs { display: grid; grid-template-columns: 1.35fr 1fr; gap: 60px; align-items: center; margin-bottom: 110px; }
.cs:last-child { margin-bottom: 0; }
.cs-reverse .cs-media { order: 2; }
.cs-frame { border-radius: 18px; overflow: hidden; background: #fff; border: 1px solid var(--line); box-shadow: 0 30px 70px rgba(0,0,0,.14); }
.cs-bar { display: flex; align-items: center; gap: 6px; padding: 10px 14px; background: var(--tint); border-bottom: 1px solid var(--line); }
.cs-bar i { width: 10px; height: 10px; border-radius: 50%; background: #d6d6d6; }
.cs-bar span { margin-left: 12px; font-size: 12px; color: var(--ink-3); background: #fff; border-radius: 99px; padding: 3px 12px; }
.cs-screen { position: relative; aspect-ratio: 16 / 10; background: var(--tint); }
.cs-video, .cs-still { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: top; }
.cs-thumbs { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.cs-thumb {
  display: inline-flex; align-items: center; gap: 6px; min-height: 40px; padding: 0 16px; border-radius: 99px;
  border: 1px solid var(--line); background: #fff; color: var(--text); font: 500 14px var(--font-body); cursor: pointer;
}
.cs-thumb svg { width: 13px; height: 13px; }
.cs-thumb:hover { border-color: #000; }
.cs-thumb[aria-pressed="true"] { background: #000; color: #fff; border-color: #000; }
.cs-kicker { font: 600 13px var(--font-body); letter-spacing: .12em; text-transform: uppercase; color: var(--accent); margin: 0 0 10px; }
.cs-title { font-size: clamp(34px, 4vw, 54px); line-height: 1; color: #000; margin: 0 0 18px; }
.cs-summary { font-size: 17px; line-height: 1.55; color: var(--text); margin: 0 0 22px; }
.cs-points { list-style: none; padding: 0; margin: 0 0 24px; display: grid; gap: 10px; }
.cs-points li { display: flex; gap: 10px; align-items: flex-start; font-size: 15px; line-height: 1.45; color: var(--text); }
.cs-points svg { width: 20px; height: 20px; padding: 3px; border-radius: 50%; background: var(--accent); color: #fff; flex: none; stroke-width: 2.6; }
.cs-stack { display: flex; flex-wrap: wrap; gap: 6px; }
.cs-stack span { font-size: 12px; font-weight: 600; padding: 5px 11px; border-radius: 99px; background: var(--tint); color: var(--ink-2); }

/* ---------- Footer ---------- */
.site-footer { background: var(--tint); padding: 70px var(--gutter) 50px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 30px; max-width: 1300px; margin: 0 auto; }
.footer-h { margin: 0 0 12px; font: 600 14px var(--font-body); letter-spacing: 0; color: #000; }
.footer-grid a:not(.logo) { display: block; color: var(--ink-2); margin-bottom: 8px; font-size: 15px; }
.footer-grid a:not(.logo):hover { color: #000; }
.footer-grid p { color: var(--ink-2); }
.site-footer .logo svg { height: 34px; width: calc(34px * 3.39); margin-bottom: 14px; }
.legal { max-width: 1300px; margin: 50px auto 0; font-size: 13px; color: var(--ink-2); }

/* ---------- Reveal on scroll ---------- */
.reveal { opacity: 0; transform: translateY(40px); transition: opacity .9s ease, transform .9s cubic-bezier(.2,.7,.2,1); }
.reveal.in { opacity: 1; transform: none; }
.no-js .reveal { opacity: 1; transform: none; }

/* ---------- Reduced motion: switch every animation off ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .reveal { opacity: 1; transform: none; }
  .st-line { transform: none !important; opacity: 1 !important; }
  .btn:hover { transform: none; }
}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .hero { padding-top: 104px; min-height: 0; align-items: flex-start; padding-bottom: 72px; }  /* message first, right under the top bar */
  .hero-inner { grid-template-columns: 1fr; }
  .hero-media { justify-self: center; width: min(280px, 72%); margin-top: 28px; }  /* photo goes UNDER the message on phones */
  .hero-phone { left: -18%; width: 48%; }
  .hero-chip { right: -10%; }
  .flow-inner { grid-template-columns: 1fr; gap: 40px; }
  .chip-in { left: 0; top: 0; }
  .chip-out { right: 0; bottom: 0; }
  .stepper-inner, .split-inner, .calc-layout { grid-template-columns: 1fr; }
  .device { margin: 0 auto; }
  .device-body { min-height: 0; }
  .feature-grid { grid-template-columns: 1fr; }
  .cs { grid-template-columns: 1fr; gap: 28px; }
  .cs-reverse .cs-media { order: 0; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .nav-toggle { display: grid; }
  .site-nav {
    position: fixed; inset: 72px 12px auto 12px; flex-direction: column; align-items: stretch; gap: 2px;
    background: #000; border: 1px solid rgba(255,255,255,.15); border-radius: 20px; padding: 12px;
    max-height: calc(100vh - 90px); overflow-y: auto; box-shadow: 0 30px 60px rgba(0,0,0,.4);
    opacity: 0; visibility: hidden; transform: translateY(-8px); transition: opacity .2s, transform .2s, visibility .2s;
  }
  .topbar.menu-open .site-nav { opacity: 1; visibility: visible; transform: none; }
  .topbar.menu-open { background: #000; }
  .nav-link, .nav-item > button { width: 100%; justify-content: space-between; padding: 0 12px; }
  .nav-menu { position: static; transform: none; box-shadow: none; min-width: 0; background: #111; color: #fff; display: none; opacity: 1; visibility: visible; pointer-events: auto; margin: 2px 0 6px; }
  .nav-item.open .nav-menu { display: block; transform: none; }
  .nav-item:hover .nav-menu, .nav-item:focus-within .nav-menu { transform: none; }
  .nav-menu a:hover, .nav-menu a:focus-visible { background: rgba(255,255,255,.08); }
  .nav-cta { margin: 10px 0 0; }
}
@media (max-width: 480px) {
  .logo svg { height: 32px; width: calc(32px * 3.39); }
  .topbar .btn { padding: 10px 14px; font-size: 14px; }
  .hero-lede { font-size: 18px; }
  .footer-grid { grid-template-columns: 1fr; }
}

/* ---------- Phone layout: tighter rhythm, controls next to what they control ---------- */
@media (max-width: 700px) {
  /* consistent, tighter vertical rhythm between sections (was 16vh+ = 250-300px gaps) */
  .flow-section, .statement, .split, .headline-block, .testimonials, .bigstat { padding-top: 72px; padding-bottom: 72px; }
  .calc { padding-top: 24px; padding-bottom: 72px; }
  .cases { padding-top: 16px; padding-bottom: 72px; }
  .testimonials { min-height: 0; gap: 36px; }
  .statement-text { font-size: clamp(38px, 11vw, 56px); }
  .headline-block .feature-grid { margin-top: 40px; }
  .cases-head { margin-bottom: 40px; }
  .cs { margin-bottom: 64px; }
  .calc-head { margin-bottom: 28px; }
  .calc-sub { display: block; }
  .calc-sub svg { display: inline-block; vertical-align: -5px; margin-right: 6px; }
  .bigstat-title { font-size: clamp(44px, 12vw, 64px); }

  /* services: arrows sit directly under the panel, side by side */
  .stepper { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; padding: 64px var(--gutter) 56px; }
  .stepper-inner { width: 100%; order: 0; gap: 32px; }
  .step-arrow { position: static; transform: none; order: 1; width: 48px; height: 48px; margin-top: 12px; }
  .stepper-nav { margin-top: 22px; }
  .step-hint { margin-top: 12px; }

  /* case-study screen buttons fit on one line */
  .cs-thumbs { gap: 6px; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
  .cs-thumbs::-webkit-scrollbar { display: none; }
  .cs-thumb { padding: 0 12px; font-size: 13px; white-space: nowrap; flex: none; }
}
