/* =========================================================
   Tempus Dynamics — static rebuild
   Brand: navy #1E2844 / blue accent #1863DC
   Fonts: Montserrat (headings), Open Sans (body)
   ========================================================= */

:root {
  --navy: #1E2844;
  --navy-deep: #161e35;
  --blue: #1863DC;
  --blue-dark: #134eb0;
  --ink: #222831;
  --muted: #5b6472;
  --line: #e4e7ee;
  --bg: #ffffff;
  --bg-alt: #f5f7fb;
  --white: #ffffff;
  --radius: 10px;
  --maxw: 1140px;
  --shadow: 0 10px 30px rgba(22, 30, 53, 0.08);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: "Open Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  line-height: 1.7;
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  font-family: "Montserrat", sans-serif;
  font-weight: 700;
  line-height: 1.2;
  color: var(--navy);
  margin: 0 0 .6em;
}

h1 { font-size: clamp(2.1rem, 5vw, 3.2rem); }
h2 { font-size: clamp(1.6rem, 3.5vw, 2.3rem); }
h3 { font-size: 1.3rem; }

p { margin: 0 0 1.1em; }

a { color: var(--blue); text-decoration: none; }
a:hover { text-decoration: underline; }

img { max-width: 100%; display: block; }

.container {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px;
}

.section { padding: 80px 0; }
.section--alt { background: var(--bg-alt); }
.section--navy { background: var(--navy); color: #d8deec; }
.section--navy h2, .section--navy h3 { color: #fff; }

.lead { font-size: 1.15rem; color: var(--muted); }
.center { text-align: center; }
.eyebrow {
  font-family: "Montserrat", sans-serif;
  text-transform: uppercase;
  letter-spacing: .12em;
  font-size: .8rem;
  font-weight: 700;
  color: var(--blue);
  margin-bottom: .5em;
  display: block;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  font-family: "Montserrat", sans-serif;
  font-weight: 600;
  font-size: .95rem;
  padding: 14px 30px;
  border-radius: 50px;
  background: var(--blue);
  color: #fff !important;
  text-decoration: none !important;
  border: 2px solid var(--blue);
  cursor: pointer;
  transition: all .2s ease;
}
.btn {
  position: relative;
  overflow: hidden;
  transition: background .25s ease, border-color .25s ease,
              transform .25s cubic-bezier(.22,.61,.36,1),
              box-shadow .25s ease;
}
.btn:hover {
  background: var(--blue-dark);
  border-color: var(--blue-dark);
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(24,99,220,.28);
}
.btn:active { transform: translateY(0); }
.btn--ghost {
  background: transparent;
  color: #fff !important;
  border-color: #fff;
}
.btn--ghost:hover { background: #fff; color: var(--navy) !important; }
.btn--lg { padding: 16px 40px; font-size: 1.05rem; }

/* ---------- Header / Nav ---------- */
.site-header {
  background: var(--navy);
  position: sticky;
  top: 0;
  z-index: 50;
  box-shadow: 0 2px 12px rgba(0,0,0,.18);
}
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 24px;
  max-width: var(--maxw);
  margin: 0 auto;
  gap: 20px;
}
/* The brand SVG is dark navy artwork; on our dark header it would be
   near-invisible, so render it white. Remove this filter if you swap in
   a true white/reversed logo file. */
.nav__logo img {
  height: 38px;
  width: auto;
  filter: brightness(0) invert(1);
}
.nav__menu {
  display: flex;
  align-items: center;
  gap: 28px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.nav__menu a {
  color: #eef1f8;
  font-family: "Montserrat", sans-serif;
  font-weight: 500;
  font-size: .95rem;
  text-decoration: none;
}
.nav__menu a:hover { color: #fff; }
.nav__dropdown { position: relative; }
.nav__dropdown > span { cursor: default; color: #eef1f8; font-family:"Montserrat",sans-serif; font-weight:500; font-size:.95rem; }
.nav__submenu {
  position: absolute;
  top: 130%;
  left: 50%;
  transform: translateX(-50%);
  background: #fff;
  min-width: 180px;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 8px 0;
  opacity: 0;
  visibility: hidden;
  transition: all .18s ease;
  list-style: none;
  margin: 0;
}
.nav__dropdown:hover .nav__submenu { opacity: 1; visibility: visible; top: 115%; }
.nav__submenu a { display: block; padding: 9px 18px; color: var(--ink); }
.nav__submenu a:hover { background: var(--bg-alt); color: var(--blue); }
.nav__toggle {
  display: none;
  background: none;
  border: 0;
  color: #fff;
  font-size: 1.7rem;
  cursor: pointer;
  line-height: 1;
}

/* =========================================================
   MOTION SYSTEM
   Subtle, professional. Everything here is disabled for
   users who prefer reduced motion (see the block at the end).
   ========================================================= */

/* Scroll reveal — elements start slightly low and faded,
   then settle into place when scrolled into view. */
[data-reveal] {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity .7s cubic-bezier(.22,.61,.36,1),
              transform .7s cubic-bezier(.22,.61,.36,1);
  will-change: opacity, transform;
}
[data-reveal="left"]  { transform: translateX(-24px); }
[data-reveal="right"] { transform: translateX(24px); }
[data-reveal="fade"]  { transform: none; }
[data-reveal].is-visible {
  opacity: 1;
  transform: none;
}
/* Stagger: set --d on a child or use data-delay */
[data-delay="1"] { transition-delay: .10s; }
[data-delay="2"] { transition-delay: .20s; }
[data-delay="3"] { transition-delay: .30s; }
[data-delay="4"] { transition-delay: .40s; }
[data-delay="5"] { transition-delay: .50s; }

/* ---------- Angled section dividers (the "tilt" look) ---------- */
.section, .hero { position: relative; }
.tilt-top::before,
.tilt-bottom::after {
  content: "";
  position: absolute;
  /* Must stay at 0/100%: skewY only shifts vertically, so a wider
     element buys nothing and causes horizontal overflow on phones. */
  left: 0;
  width: 100%;
  height: 70px;
  background: inherit;
  z-index: 0;
}
.tilt-top::before    { top: 0;    transform: skewY(-1.6deg); transform-origin: top left; }
.tilt-bottom::after  { bottom: 0; transform: skewY(-1.6deg); transform-origin: bottom right; }
.tilt-top > *, .tilt-bottom > * { position: relative; z-index: 1; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  background: var(--navy-deep);
  background-size: cover;
  background-position: center;
  color: #fff;
  text-align: center;
  padding: 120px 0;
  overflow: hidden;
}
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(22,30,53,.78), rgba(22,30,53,.88));
}
/* Slow drifting gradient wash — the lightweight alternative to a
   background video. Costs nothing and never blocks rendering. */
.hero::after {
  content: "";
  position: absolute;
  inset: -40%;
  background:
    radial-gradient(closest-side, rgba(24,99,220,.30), transparent 70%) 20% 30%/55% 55% no-repeat,
    radial-gradient(closest-side, rgba(110,160,255,.20), transparent 70%) 78% 65%/50% 50% no-repeat;
  animation: heroDrift 22s ease-in-out infinite alternate;
  pointer-events: none;
}
@keyframes heroDrift {
  0%   { transform: translate3d(-2%, -1%, 0) scale(1); }
  50%  { transform: translate3d(2%, 2%, 0) scale(1.06); }
  100% { transform: translate3d(1%, -2%, 0) scale(1.02); }
}
.hero .container { position: relative; z-index: 3; }

/* ---------- Scroll-driven workflow hero (homepage) ----------
   An automation network sits behind the headline and advances as the
   visitor scrolls through the hero: paths draw, nodes activate in
   sequence. Progress is driven by scroll position, so it reads as
   "something is running" rather than a decorative loop. */
.hero--flow {
  min-height: 88vh;
  display: flex;
  align-items: center;
  padding: 100px 0;
}
.hero__flow {
  position: absolute;
  inset: 0;
  z-index: 2;
  opacity: .62;
  pointer-events: none;
}
.hero__flow svg { width: 100%; height: 100%; display: block; }

.flow-path {
  fill: none;
  stroke: #6ea0ff;
  stroke-width: 2.2;
  stroke-linecap: round;
  opacity: .55;
}
.flow-path--faint { stroke: #8fb4ff; opacity: .3; stroke-dasharray: 5 7; stroke-width: 1.8; }

.flow-node {
  opacity: 0;
  transform-box: fill-box;
  transform-origin: center;
  transition: opacity .25s linear;
}
.flow-node__ring { fill: none; stroke: #6ea0ff; stroke-width: 2; }
.flow-node__core { fill: #6ea0ff; }
.flow-node__halo { fill: rgba(110,160,255,.18); }

/* Scroll hint at the base of the hero */
.hero__hint {
  position: absolute;
  left: 50%;
  bottom: 26px;
  transform: translateX(-50%);
  z-index: 3;
  color: rgba(255,255,255,.62);
  font-family: "Montserrat", sans-serif;
  font-size: .72rem;
  letter-spacing: .16em;
  text-transform: uppercase;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}
.hero__hint span { display: block; width: 1px; height: 26px; background: linear-gradient(rgba(255,255,255,.6), transparent); animation: hintDrop 2.4s ease-in-out infinite; }
@keyframes hintDrop { 0%,100% { transform: scaleY(.4); opacity:.4 } 50% { transform: scaleY(1); opacity:1 } }

@media (max-width: 880px) {
  .hero--flow { min-height: 76vh; padding: 80px 0; }
  .hero__flow { opacity: .42; }
  .hero__hint { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .hero__hint span { animation: none; }
  .flow-node { opacity: 1 !important; transform: none !important; }
}
.hero h1 { color: #fff; max-width: 850px; margin-left: auto; margin-right: auto; }
.hero p { font-size: 1.2rem; color: #d8deec; max-width: 680px; margin: 0 auto 1.8em; }
.hero--short { padding: 90px 0; }

/* ---------- Generic layout helpers ---------- */
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: center;
}
.split img { border-radius: var(--radius); box-shadow: var(--shadow); }
.split--reverse .split__media { order: 2; }

/* ---------- Stats ---------- */
.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
  text-align: center;
}
.stat__num {
  font-family: "Montserrat", sans-serif;
  font-weight: 800;
  font-size: clamp(2.4rem, 6vw, 3.6rem);
  color: var(--blue);
  line-height: 1;
}
.section--navy .stat__num { color: #6ea0ff; }
.stat__label { font-size: 1rem; color: var(--muted); margin-top: .4em; }
.section--navy .stat__label { color: #b9c2d8; }

/* ---------- Service cards ---------- */
.cards {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 28px;
}
.card {
  position: relative;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 34px;
  box-shadow: var(--shadow);
  overflow: hidden;
  transition: transform .3s cubic-bezier(.22,.61,.36,1),
              box-shadow .3s ease,
              border-color .3s ease;
}
/* Accent bar that sweeps in on hover */
.card::before {
  content: "";
  position: absolute;
  top: 0; left: 0;
  height: 3px; width: 100%;
  background: linear-gradient(90deg, var(--blue), #6ea0ff);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .4s cubic-bezier(.22,.61,.36,1);
}
.card:hover {
  transform: translateY(-6px);
  box-shadow: 0 18px 40px rgba(22,30,53,.14);
  border-color: #cfd8ea;
}
.card:hover::before { transform: scaleX(1); }
.card h3 { color: var(--navy); }
.card h3 span { color: var(--blue); }
.card .btn { margin-top: 10px; }
a.card {
  color: inherit;
  display: block;
}
a.card:hover { text-decoration: none; }
a.card p { color: var(--ink); }
.case-study { scroll-margin-top: 96px; }

/* Service icon tile */
.card__icon {
  width: 58px; height: 58px;
  border-radius: 14px;
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, rgba(24,99,220,.12), rgba(110,160,255,.18));
  margin-bottom: 18px;
  transition: transform .35s cubic-bezier(.22,.61,.36,1), background .35s ease;
}
.card__icon svg { width: 30px; height: 30px; display: block; }
.card:hover .card__icon {
  transform: translateY(-2px) rotate(-4deg);
  background: linear-gradient(135deg, rgba(24,99,220,.20), rgba(110,160,255,.28));
}
.card__thumb {
  display: block;
  border-radius: 8px;
  overflow: hidden;
  margin: -10px -10px 20px;
  background: var(--bg-alt);
  border: 1px solid var(--line);
  cursor: pointer;
}
.card__thumb img {
  width: 100%;
  height: 340px;
  object-fit: contain;
  object-position: center;
  box-shadow: none;
  border-radius: 0;
  transition: transform .25s ease;
}
.card__thumb:hover img { transform: scale(1.03); }

/* ---------- Feature list ---------- */
.feature-list { list-style: none; padding: 0; margin: 0; }
.feature-list li {
  position: relative;
  padding: 8px 0 8px 34px;
  border-bottom: 1px solid var(--line);
}
.feature-list li::before {
  content: "→";
  position: absolute;
  left: 4px;
  color: var(--blue);
  font-weight: 700;
}

/* ---------- Testimonials ---------- */
.quotes {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 26px;
}
.quote {
  background: #fff;
  border-left: 4px solid var(--blue);
  border-radius: var(--radius);
  padding: 28px 30px;
  box-shadow: var(--shadow);
}
.quote p { font-style: italic; color: var(--ink); }
.quote cite {
  display: block;
  font-style: normal;
  font-weight: 700;
  font-family: "Montserrat", sans-serif;
  color: var(--navy);
  margin-top: 12px;
}
.quote cite span { display: block; font-weight: 400; font-size: .9rem; color: var(--muted); }

/* ---------- Team ---------- */
.team {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 26px;
}
.member { text-align: center; }
.member__avatar {
  width: 150px; height: 150px;
  border-radius: 50%;
  margin: 0 auto 16px;
  background: linear-gradient(135deg, var(--navy), var(--blue));
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-family: "Montserrat", sans-serif;
  font-weight: 700;
  font-size: 2rem;
  overflow: hidden;
}
.member__photo {
  width: 150px; height: 150px;
  border-radius: 50%;
  object-fit: cover;
  object-position: center top;
  margin: 0 auto 16px;
  box-shadow: var(--shadow);
}
.member__name { font-family: "Montserrat", sans-serif; font-weight: 700; color: var(--navy); margin: 0; }
.member__role { color: var(--muted); font-size: .92rem; }

/* ---------- Forms ---------- */
.form-card {
  background: #fff;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 40px;
  max-width: 720px;
  margin: 0 auto;
}
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.field { margin-bottom: 18px; }
.field label {
  display: block;
  font-weight: 600;
  font-size: .9rem;
  margin-bottom: 6px;
  font-family: "Montserrat", sans-serif;
  color: var(--navy);
}
.field .req { color: var(--blue); }
.field input, .field select, .field textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  font-family: inherit;
  font-size: 1rem;
  background: #fcfdff;
}
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none; border-color: var(--blue); box-shadow: 0 0 0 3px rgba(24,99,220,.12);
}
.checks { display: flex; flex-wrap: wrap; gap: 14px; }
.checks label { display: flex; align-items: center; gap: 7px; font-weight: 400; font-family: "Open Sans", sans-serif; color: var(--ink); }
.checks input { width: auto; }
.form-note { font-size: .85rem; color: var(--muted); }

/* Honeypot: hidden from humans, visible to dumb bots */
.hp-field {
  position: absolute !important;
  left: -9999px !important;
  top: -9999px !important;
  width: 1px; height: 1px;
  overflow: hidden;
}
.cf-turnstile { margin: 4px 0 20px; }

/* ---------- Footer ---------- */
.site-footer {
  background: var(--navy-deep);
  color: #aab3c9;
  padding: 56px 0 28px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 36px;
}
/* Footer is dark too — same reversal as the header logo. */
.site-footer img {
  height: 40px;
  margin-bottom: 16px;
  filter: brightness(0) invert(1);
}
.site-footer h4 { color: #fff; font-size: 1rem; margin-bottom: 14px; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: 8px; }
.site-footer a { color: #aab3c9; }
.site-footer a:hover { color: #fff; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.12);
  padding-top: 20px;
  font-size: .85rem;
  text-align: center;
}

/* ---------- Privacy / long-form ---------- */
.prose { max-width: 820px; margin: 0 auto; }
.prose h2 { margin-top: 1.6em; font-size: 1.5rem; }
.prose h3 { margin-top: 1.3em; color: var(--blue); }
.prose table { width: 100%; border-collapse: collapse; margin: 1.4em 0; font-size: .9rem; }
.prose th, .prose td { border: 1px solid var(--line); padding: 10px 12px; text-align: left; vertical-align: top; }
.prose th { background: var(--bg-alt); }

/* =========================================================
   PRODUCT PAGE COMPONENTS
   Per-product accent — set a class on <body> to tint a page.
   Kept in the cool/brand family so pages feel distinct but related.
   ========================================================= */
body { --accent: var(--blue); }
body.p-inquest { --accent: #1863DC; }
body.p-insight { --accent: #0E8F9E; }
body.p-synapse { --accent: #4C5FD5; }
body.p-nexus   { --accent: #6A4CD5; }

.eyebrow { color: var(--accent); }

/* Schematic figure wrapper — for the animated SVG product visuals */
.figure {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 16px;
  box-shadow: var(--shadow);
  padding: 26px;
}
.figure svg { width: 100%; height: auto; display: block; }
.figure img {
  width: 100%;
  height: auto;
  display: block;
  margin: 0 auto;
}
.case-study .figure {
  max-width: 680px;
  margin: 32px auto 0;
  padding: 18px;
}
.figure__cap {
  margin: 16px 0 0;
  font-size: .88rem;
  color: var(--muted);
  text-align: center;
}

/* Filter chips */
.chips { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }
.chip {
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 50px;
  padding: 8px 18px;
  font-size: .9rem;
  font-family: "Montserrat", sans-serif;
  font-weight: 600;
  color: var(--navy);
  transition: border-color .25s ease, color .25s ease, transform .25s ease;
}
/* No hover state: these are labels, not controls. A hover effect on a
   non-interactive element reads as "clickable" and does nothing, which
   the team flagged. Same reasoning applies to .inst below. */
.chip--accent { background: var(--accent); border-color: var(--accent); color: #fff; }

/* Feature tiles (question types, capabilities) */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.feature-tile {
  background: #fff;
  border: 1px solid var(--line);
  border-left: 3px solid var(--accent);
  border-radius: 10px;
  padding: 22px 22px 20px;
  transition: transform .28s cubic-bezier(.22,.61,.36,1), box-shadow .28s ease;
}
.feature-tile:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.feature-tile h4 {
  font-family: "Montserrat", sans-serif;
  margin: 0 0 6px;
  color: var(--navy);
  font-size: 1.02rem;
}
.feature-tile p { margin: 0; font-size: .93rem; color: var(--muted); }

/* Differentiator callout */
.callout {
  background: linear-gradient(135deg, rgba(24,99,220,.05), rgba(110,160,255,.09));
  border: 1px solid var(--line);
  border-left: 4px solid var(--accent);
  border-radius: 12px;
  padding: 30px 34px;
}
.callout__tag {
  display: inline-block;
  font-family: "Montserrat", sans-serif;
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: #fff;
  background: var(--accent);
  border-radius: 50px;
  padding: 5px 13px;
  margin-bottom: 12px;
}
.callout h3 { margin: 0 0 8px; }
.callout p:last-child { margin-bottom: 0; }

/* Two-sided layout (Nexus: participants vs researchers) */
.sides { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; }
.side {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 32px;
  background: #fff;
  box-shadow: var(--shadow);
}
.side__label {
  font-family: "Montserrat", sans-serif;
  font-size: .74rem;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 10px;
}
.side ul { list-style: none; padding: 0; margin: 0; }
.side li { position: relative; padding: 7px 0 7px 26px; font-size: .95rem; }
.side li::before {
  content: "";
  position: absolute; left: 2px; top: 15px;
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--accent);
}

/* Related products cross-links */
.related {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}
.related a {
  display: block;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 22px 24px;
  background: #fff;
  text-decoration: none;
  transition: transform .28s cubic-bezier(.22,.61,.36,1), box-shadow .28s ease, border-color .28s ease;
}
.related a:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: var(--accent); text-decoration: none; }
.related strong {
  display: block;
  font-family: "Montserrat", sans-serif;
  color: var(--navy);
  margin-bottom: 4px;
}
.related span { font-size: .9rem; color: var(--muted); }

/* ---------- Mobile counterparts to the wide diagrams ----------
   Shown only under 880px (see the media query). Vertical, text-based,
   and legible at any width — no shrinking, no sideways scrolling. */
.only-mobile { display: none; }
.only-desktop { display: block; }

/* Vertical step flow */
.flowsteps { list-style: none; margin: 0; padding: 0; position: relative; }
.flowsteps::before {
  content: "";
  position: absolute;
  left: 15px; top: 14px; bottom: 14px;
  width: 2px;
  background: linear-gradient(180deg, var(--accent), rgba(24,99,220,.15));
}
.flowsteps li {
  position: relative;
  padding: 0 0 22px 46px;
}
.flowsteps li:last-child { padding-bottom: 0; }
.flowsteps__dot {
  position: absolute;
  left: 8px; top: 2px;
  width: 16px; height: 16px;
  border-radius: 50%;
  background: #fff;
  border: 2.5px solid var(--accent);
}
.flowsteps li:last-child .flowsteps__dot { background: var(--accent); }
.flowsteps strong {
  display: block;
  font-family: "Montserrat", sans-serif;
  color: var(--navy);
  font-size: 1rem;
  margin-bottom: 2px;
}
.flowsteps p { margin: 0; font-size: .92rem; color: var(--muted); }
.flowsteps li.is-branch { padding-left: 68px; }
.flowsteps li.is-branch .flowsteps__dot { left: 30px; width: 12px; height: 12px; border-style: dashed; }
.flowsteps__tag {
  display: inline-block;
  font-family: "Montserrat", sans-serif;
  font-size: .64rem;
  font-weight: 700;
  letter-spacing: .09em;
  text-transform: uppercase;
  color: var(--accent);
  border: 1px solid currentColor;
  border-radius: 40px;
  padding: 2px 8px;
  margin-bottom: 5px;
}

/* Compact KPI list (mobile stand-in for the Insight dashboard) */
.minidash { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.minidash__cell {
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 14px 16px;
  background: #fff;
}
.minidash__cell span {
  display: block;
  font-size: .68rem;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 4px;
}
.minidash__cell strong {
  font-family: "Montserrat", sans-serif;
  font-size: 1.45rem;
  font-weight: 800;
  color: var(--navy);
}
.minidash__cell--accent strong { color: var(--accent); }
.minidash__bars { grid-column: 1 / -1; display: flex; align-items: flex-end; gap: 7px; height: 78px; padding: 14px 16px 0; border: 1px solid var(--line); border-radius: 10px; background: #fff; }
.minidash__bars i { flex: 1; border-radius: 4px 4px 0 0; background: var(--accent); opacity: .85; }

/* ---------- Shared schematic animation helpers ---------- */
.fig-draw { stroke-dasharray: 200; stroke-dashoffset: 200; }
.is-visible .fig-draw { animation: figDraw 1s ease forwards; }
@keyframes figDraw { to { stroke-dashoffset: 0; } }

.fig-in { opacity: 0; }
.is-visible .fig-in { animation: figIn .55s ease forwards; }
@keyframes figIn { to { opacity: 1; } }

.fig-grow { transform: scaleY(0); transform-origin: bottom; }
.is-visible .fig-grow { animation: figGrow .8s cubic-bezier(.22,.61,.36,1) forwards; }
@keyframes figGrow { to { transform: scaleY(1); } }

.fig-loop { animation: figLoop 3s ease-in-out infinite; }
@keyframes figLoop { 0%,100% { opacity:.3 } 50% { opacity:1 } }

@media (prefers-reduced-motion: reduce) {
  .fig-draw { stroke-dashoffset: 0; }
  .fig-in { opacity: 1; }
  .fig-grow { transform: none; }
  .fig-loop { animation: none; opacity: 1; }
}

/* =========================================================
   LEFT WORKFLOW RAIL
   A fixed vertical spine in the left margin. As you scroll, the
   connecting line grows and a new node locks in at each section —
   so the page reads as a workflow completing step by step.
   Nodes are generated from [data-flow-step] sections by main.js,
   so adding a section automatically adds a node.
   ========================================================= */
.railflow {
  position: fixed;
  left: 34px;
  top: 0;
  bottom: 0;
  width: 210px;
  z-index: 40;
  pointer-events: none;
  opacity: 0;
  transition: opacity .5s ease;
}
.railflow.is-active { opacity: 1; }

/* the track and the growing fill */
.railflow__track,
.railflow__fill {
  position: absolute;
  left: 7px;
  width: 2px;
  border-radius: 2px;
}
.railflow__track { top: 14vh; bottom: 14vh; background: rgba(30,40,68,.13); }
.railflow__fill {
  top: 14vh;
  height: 0;
  background: linear-gradient(180deg, var(--blue), #6ea0ff);
  box-shadow: 0 0 10px rgba(24,99,220,.35);
  transition: height .12s linear;
}

/* nodes */
.railflow__node {
  position: absolute;
  left: 0;
  display: flex;
  align-items: center;
  gap: 12px;
  transform: translateY(-50%);
  pointer-events: auto;
  cursor: pointer;
  text-decoration: none;
}
.railflow__dot {
  position: relative;
  width: 16px; height: 16px;
  flex: 0 0 16px;
  border-radius: 50%;
  background: #fff;
  border: 2px solid rgba(30,40,68,.22);
  transition: border-color .35s ease, transform .35s cubic-bezier(.22,.61,.36,1), box-shadow .35s ease;
}
.railflow__dot::after {
  content: "";
  position: absolute;
  inset: 3px;
  border-radius: 50%;
  background: var(--blue);
  opacity: 0;
  transform: scale(.4);
  transition: opacity .35s ease, transform .35s cubic-bezier(.22,.61,.36,1);
}
.railflow__label {
  font-family: "Montserrat", sans-serif;
  font-size: .72rem;
  font-weight: 600;
  letter-spacing: .04em;
  color: var(--muted);
  white-space: nowrap;
  opacity: 0;
  transform: translateX(-6px);
  transition: opacity .35s ease, transform .35s ease, color .35s ease;
}

/* reached state */
.railflow__node.is-done .railflow__dot { border-color: var(--blue); }
.railflow__node.is-done .railflow__dot::after { opacity: 1; transform: scale(1); }
.railflow__node.is-done .railflow__label { opacity: .75; transform: none; }

/* the section you're currently in */
.railflow__node.is-current .railflow__dot {
  transform: scale(1.35);
  box-shadow: 0 0 0 5px rgba(24,99,220,.14);
}
.railflow__node.is-current .railflow__label { opacity: 1; color: var(--navy); }
.railflow__node:hover .railflow__label { opacity: 1; color: var(--blue); }
.railflow__node:hover .railflow__dot { border-color: var(--blue); }

/* Dots-only when there isn't room for labels; hidden entirely on narrow screens */
@media (max-width: 1440px) {
  .railflow { width: 24px; }
  .railflow__label { display: none; }
}
@media (max-width: 1160px) {
  .railflow { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .railflow__fill { transition: none; }
  .railflow__dot, .railflow__dot::after, .railflow__label { transition: none; }
}

/* ---------- Institution wall (social proof) ---------- */
.inst-wall {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 16px;
}
.inst {
  border: 1px solid var(--line);
  background: #fff;
  border-radius: var(--radius);
  padding: 22px 16px;
  text-align: center;
  font-family: "Montserrat", sans-serif;
  font-weight: 600;
  font-size: .88rem;
  line-height: 1.35;
  color: var(--navy);
  display: flex; align-items: center; justify-content: center;
  min-height: 96px;
  transition: transform .3s cubic-bezier(.22,.61,.36,1), box-shadow .3s ease, color .3s ease;
}
/* Deliberately no hover state — see .chip above. */

/* ---------- Animated workflow diagram (Synapse) ---------- */
.wf {
  width: 100%;
  max-width: 900px;
  margin: 0 auto;
  display: block;
}
.wf .wf-node {
  opacity: 0;
  animation: wfNodeIn .5s ease forwards;
}
.wf .wf-line {
  stroke-dasharray: 90;
  stroke-dashoffset: 90;
  animation: wfDraw .55s ease forwards;
}
.wf .wf-pulse {
  animation: wfPulse 3.2s ease-in-out infinite;
}
@keyframes wfNodeIn { to { opacity: 1; } }
@keyframes wfDraw   { to { stroke-dashoffset: 0; } }
@keyframes wfPulse {
  0%, 100% { opacity: .25; r: 4; }
  50%      { opacity: 1;   r: 6; }
}
/* Only start the diagram once it scrolls into view */
.wf:not(.is-visible) .wf-node,
.wf:not(.is-visible) .wf-line { animation-play-state: paused; }

/* ---------- Adaptive Synapse workflow (Synapse page) ---------- */
.sf-block { margin: 0; }
.sf-block + .sf-block { margin-top: 52px; }
.sf-heading {
  font-family: "Montserrat", sans-serif;
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--accent);
  text-align: center;
  margin: 0 0 8px;
}
.sf-lead {
  text-align: center;
  color: var(--muted);
  max-width: 560px;
  margin: 0 auto 24px;
  font-size: .98rem;
}
.sf-rail {
  font-family: "Montserrat", sans-serif;
  font-size: .7rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--accent);
  border: 1.5px dashed rgba(76, 95, 213, .55);
  border-radius: 40px;
  text-align: center;
  padding: 8px 16px;
  margin: 0 0 22px;
  background: rgba(76, 95, 213, .06);
}
.sf-board {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 22px minmax(0, 1fr) 22px minmax(0, 1fr);
  column-gap: 0;
  row-gap: 12px;
  align-items: start;
}
.sf-n1 { grid-column: 1; grid-row: 1; }
.sf-f1 { grid-column: 1; grid-row: 2; }
.sf-a1 { grid-column: 2; grid-row: 1; }
.sf-n2 { grid-column: 3; grid-row: 1; }
.sf-f2 { grid-column: 3; grid-row: 2; }
.sf-a2 { grid-column: 4; grid-row: 1; }
.sf-n3 { grid-column: 5; grid-row: 1; }
.sf-f3 { grid-column: 5; grid-row: 2; }
.sf-groups { grid-column: 1 / -1; grid-row: 3; margin-top: 6px; }
.sf-a3 { grid-column: 1 / -1; grid-row: 4; }
.sf-n4 { grid-column: 1 / -1; grid-row: 5; justify-self: center; width: min(100%, 240px); }
.sf-f4 {
  grid-column: 1 / -1;
  grid-row: 6;
  justify-self: center;
  width: min(100%, 240px);
}
.sf-node {
  position: relative;
  background: #fff;
  border: 2px solid var(--accent);
  border-radius: 14px;
  padding: 16px 12px 14px;
  text-align: center;
  min-height: 88px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
  min-width: 0;
}
.sf-node strong {
  font-family: "Montserrat", sans-serif;
  font-size: .92rem;
  font-weight: 600;
  color: var(--navy);
  line-height: 1.25;
  overflow-wrap: break-word;
}
.sf-node__sub {
  display: block;
  font-family: "Open Sans", sans-serif;
  font-size: .75rem;
  font-weight: 400;
  color: var(--muted);
  line-height: 1.35;
}
.sf-pulse {
  display: block;
  width: 8px;
  height: 8px;
  margin: 0 auto 6px;
  border-radius: 50%;
  background: var(--accent);
  animation: sfPulse 3.2s ease-in-out infinite;
}
@keyframes sfPulse {
  0%, 100% { opacity: .25; transform: scale(1); }
  50%      { opacity: 1;   transform: scale(1.35); }
}
.sf-arrow {
  display: flex;
  align-items: center;
  justify-content: center;
  align-self: center;
  height: 88px;
}
.sf-arrow--down {
  height: 22px;
  transform: rotate(90deg);
  justify-self: center;
}
.sf-groups__label {
  font-family: "Montserrat", sans-serif;
  font-size: .64rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--accent);
  text-align: center;
  margin: 0 0 10px;
}
.sf-lanes {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}
.sf-lane {
  background: #fff;
  border: 2px solid var(--accent);
  border-radius: 14px;
  padding: 12px 10px 11px;
  text-align: center;
  min-width: 0;
}
.sf-lane strong {
  display: block;
  font-family: "Montserrat", sans-serif;
  font-size: .82rem;
  font-weight: 600;
  color: var(--navy);
  line-height: 1.25;
}
.sf-lane .sf-node__sub { margin-top: 4px; }
.sf-lane--bypass {
  border-style: dashed;
  border-color: #9fb2d4;
  background: var(--bg-alt);
}
.sf-lane--bypass strong { color: var(--muted); }
.sf-fork {
  list-style: none;
  margin: 0;
  padding: 10px 0 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
  position: relative;
  min-width: 0;
}
.sf-fork::before {
  content: "";
  position: absolute;
  top: 0;
  left: 50%;
  width: 2px;
  height: 10px;
  background: #c5cde0;
  transform: translateX(-50%);
}
.sf-leaf {
  background: var(--bg-alt);
  border: 1.5px solid #c5cde0;
  border-radius: 12px;
  padding: 10px 10px;
  text-align: center;
  font-family: "Montserrat", sans-serif;
  font-size: .78rem;
  font-weight: 600;
  color: var(--navy);
  line-height: 1.3;
}
.sf-leaf--exit {
  border-style: dashed;
  color: var(--muted);
  background: #fff;
}
.sf-leaf--navy {
  background: var(--navy);
  border-color: var(--navy);
  color: #fff;
}
.sf-leaf--loop {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  border-color: var(--accent);
  background: rgba(76, 95, 213, .06);
}
.sf-leaf--loop strong {
  display: block;
  font-size: .78rem;
  color: var(--navy);
}
.sf-leaf--loop .sf-node__sub { margin-top: 1px; }
.sf-loop-icon { flex: 0 0 14px; color: var(--accent); }
.sf-log {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  margin: 22px 0 0;
  padding: 8px 14px;
  background: var(--bg-alt);
  border: 1px solid var(--line);
  border-radius: 8px;
  font-size: .75rem;
  color: var(--muted);
}
.sf-log__label {
  font-family: "Montserrat", sans-serif;
  font-weight: 700;
  font-size: .64rem;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--navy);
  opacity: .65;
}
.sf-log__ticks {
  display: inline-block;
  width: 88px;
  height: 6px;
  background: repeating-linear-gradient(
    90deg,
    #9fb2d4 0 4px,
    transparent 4px 12px
  );
  opacity: .7;
  border-radius: 2px;
}
.figure.sf .figure__cap { text-align: left; }

/* ---------- Reduced motion: honor the user's OS setting ----------
   Anyone who has asked their system to minimize animation gets a
   completely static site. This is an accessibility requirement,
   not a nicety — motion can trigger nausea and vestibular issues. */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
    scroll-behavior: auto !important;
  }
  [data-reveal] { opacity: 1 !important; transform: none !important; }
  .hero::after { animation: none; }
  .card:hover, .btn:hover, .inst:hover { transform: none; }
  .wf .wf-node { opacity: 1 !important; }
  .wf .wf-line { stroke-dashoffset: 0 !important; }
  .sf-pulse { opacity: 1 !important; }
}

/* ---------- Responsive ---------- */
@media (max-width: 880px) {
  .nav__menu {
    position: fixed;
    top: 70px; left: 0; right: 0;
    background: var(--navy);
    flex-direction: column;
    align-items: flex-start;
    padding: 18px 24px;
    gap: 16px;
    transform: translateY(-150%);
    transition: transform .25s ease;
    box-shadow: 0 10px 20px rgba(0,0,0,.25);
  }
  .nav__menu.open { transform: translateY(0); }
  .nav__toggle { display: block; }
  .nav__submenu { position: static; transform: none; opacity: 1; visibility: visible; box-shadow: none; background: transparent; padding: 6px 0 0 14px; }
  .nav__submenu a { color: #cdd5e8; padding: 6px 0; }
  .nav__dropdown:hover .nav__submenu { top: auto; }
  .split, .stats, .cards, .quotes, .footer-grid { grid-template-columns: 1fr; }
  .split--reverse .split__media { order: 0; }
  .team { grid-template-columns: repeat(2, 1fr); }
  .form-row { grid-template-columns: 1fr; }
  .section { padding: 56px 0; }
  .hero { padding: 90px 0; }
  .inst-wall { grid-template-columns: repeat(2, 1fr); }
  .feature-grid, .related { grid-template-columns: 1fr; }
  .sides { grid-template-columns: 1fr; }

  /* Wide horizontal schematics can't shrink to a phone and stay legible,
     and scrolling one sideways inside a card reads as broken. Each wide
     diagram has a vertical counterpart (.flowsteps / .minidash) that
     takes over here instead. Nothing scrolls sideways. */
  .figure { padding: 18px; }
  .only-desktop { display: none !important; }
  .only-mobile  { display: block !important; }
  .sf-block + .sf-block { margin-top: 40px; }
  .sf-board {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding-left: 18px;
    border-left: 2px solid rgba(76, 95, 213, .22);
  }
  .sf-arrow {
    transform: rotate(90deg);
    height: 22px;
    align-self: flex-start;
    margin-left: -2px;
  }
  .sf-arrow--down { margin-left: -2px; }
  .sf-fork { padding-top: 0; }
  .sf-fork::before { display: none; }
  .sf-node { min-height: 0; }
  .sf-n4, .sf-f4 { width: 100%; }
  .sf-groups { margin-top: 2px; }
  .sf-lanes { grid-template-columns: 1fr; }
  .sf-log__ticks { width: 48px; }
  /* the KPI stack is a grid, so it must not be forced back to block */
  .minidash.only-mobile { display: grid !important; }
  /* Long-form tables shouldn't blow out the page width either */
  .prose table { display: block; overflow-x: auto; white-space: nowrap; }
  /* Shorter travel on small screens so reveals feel snappy, not laggy */
  [data-reveal] { transform: translateY(10px); }
  [data-reveal="left"], [data-reveal="right"] { transform: translateY(10px); }
  [data-delay] { transition-delay: 0s; }
  .tilt-top::before, .tilt-bottom::after { height: 40px; }
}
@media (max-width: 480px) {
  .team { grid-template-columns: 1fr; }
}

/* Skip link: hidden until focused with the keyboard */
.skip-link {
  position: absolute; left: 12px; top: -60px; z-index: 100;
  background: #fff; color: var(--navy); padding: 10px 16px;
  border-radius: 8px; font-weight: 600; box-shadow: var(--shadow);
}
.skip-link:focus { top: 12px; }

/* Services dropdown opens for keyboard users too */
.nav__dropdown:focus-within .nav__submenu { opacity: 1; visibility: visible; top: 115%; }
.nav__dropdown > span:focus-visible { outline: 2px solid #6ea0ff; outline-offset: 4px; border-radius: 4px; }
@media (max-width: 880px) { .nav__dropdown:focus-within .nav__submenu { top: auto; } }

/* Short pages (404, thank-you): push the footer to the bottom of the window */
body.page-short { min-height: 100vh; display: flex; flex-direction: column; }
body.page-short .site-footer { margin-top: auto; }
