/* ==========================================================================
   LeonSoft — Intelligent Business Blueprint
   Design system v4
   ========================================================================== */

/* --- 1. Tokens ----------------------------------------------------------- */
:root {
  /* surfaces, light to dark */
  --bg:          #f7f8f6;
  --bg-tint:     #edf1f1;
  --paper:       #ffffff;
  --paper-soft:  #fbfbfa;
  --tint:        #eaf4f6;

  /* ink */
  --ink:      #111827;
  --graphite: #1f2937;
  --muted:    #5f6f7b;
  --faint:    #8b9aa5;
  --deep:     #102a43;

  /* signal */
  --teal:      #16a6b6;
  --teal-deep: #0e7f8d;
  --teal-wash: #e4f3f5;
  --green:     #3a8f6b;
  --green-wash:#e7f3ed;
  --amber:     #c9872b;
  --amber-wash:#f9f0e2;

  /* structure */
  --line:      #dfe4e6;
  --line-soft: #ebefef;
  --line-hard: #c9d2d6;

  /* elevation — soft and low, never puffy */
  --sh-1: 0 1px 2px rgba(16,42,67,.04), 0 4px 12px rgba(16,42,67,.05);
  --sh-2: 0 2px 4px rgba(16,42,67,.04), 0 12px 32px rgba(16,42,67,.07);
  --sh-3: 0 8px 16px rgba(16,42,67,.06), 0 32px 72px rgba(16,42,67,.11);

  /* geometry — architectural, not pill-shaped */
  --r-xs: 6px;
  --r-sm: 8px;
  --r-md: 12px;
  --r-lg: 16px;
  --r-xl: 22px;

  --container: 1240px;
  --gutter: 32px;
  --header-h: 74px;

  /* type */
  --display: "Inter Tight", "Assistant", ui-sans-serif, system-ui, "Segoe UI", sans-serif;
  --body:    "Inter", "Assistant", ui-sans-serif, system-ui, "Segoe UI", sans-serif;
  --serif:   "Instrument Serif", Georgia, "Times New Roman", serif;
}

/* --- 2. Base ------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--body);
  font-size: 1rem;
  line-height: 1.6;
  font-feature-settings: "cv05" 1, "ss01" 1;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img, svg { max-width: 100%; }
img { display: block; height: auto; }

a { color: inherit; text-decoration: none; }
p  { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }

button, input, textarea, select { font: inherit; color: inherit; }

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

.skip-link {
  position: absolute; left: 16px; top: -60px; z-index: 200;
  background: var(--ink); color: #fff;
  padding: 10px 16px; border-radius: var(--r-sm); font-weight: 600;
  transition: top .18s ease;
}
.skip-link:focus { top: 14px; }

.visually-hidden {
  position: absolute; width: 1px; height: 1px;
  margin: -1px; padding: 0; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* --- 3. Typography scale ------------------------------------------------- */
h1, h2, h3, h4 {
  margin: 0;
  font-family: var(--display);
  color: var(--ink);
  font-weight: 600;
  letter-spacing: -0.033em;
  text-wrap: balance;
}

h1 {
  font-size: clamp(2.55rem, 3.85vw, 3.5rem);
  line-height: 1.07;
  letter-spacing: -0.038em;
}
h2 {
  font-size: clamp(1.85rem, 2.6vw, 2.5rem);
  line-height: 1.12;
  letter-spacing: -0.035em;
}
h3 { font-size: 1.125rem; line-height: 1.3; letter-spacing: -0.02em; }
h4 { font-size: 0.975rem; line-height: 1.35; letter-spacing: -0.015em; }

.eyebrow {
  margin: 0 0 18px;
  font-family: var(--body);
  font-size: 0.755rem;
  font-weight: 600;
  letter-spacing: 0.17em;
  text-transform: uppercase;
  color: var(--muted);
}

.lead {
  font-size: 1.0625rem;
  line-height: 1.62;
  color: var(--muted);
  max-width: 52ch;
}

.body-text { color: var(--muted); }

/* --- 4. Layout ----------------------------------------------------------- */
.container {
  width: min(var(--container), 100% - (var(--gutter) * 2));
  margin-inline: auto;
}

.section { padding-block: clamp(64px, 7.5vw, 108px); }
.section--tight { padding-block: clamp(52px, 5.5vw, 76px); }

.section--tint { background: var(--bg-tint); }
.section--paper { background: var(--paper-soft); }

/* --- 5. Buttons & links -------------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  gap: 10px;
  min-height: 46px;
  padding: 0 20px;
  border: 1px solid transparent;
  border-radius: var(--r-sm);
  font-family: var(--body);
  font-size: 0.9375rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  cursor: pointer;
  white-space: nowrap;
  transition: background .18s ease, border-color .18s ease,
              color .18s ease, transform .18s ease, box-shadow .18s ease;
}
.btn .ic { width: 16px; height: 16px; }

.btn--dark {
  background: var(--ink); color: #fff;
  box-shadow: var(--sh-1);
}
.btn--dark:hover { background: #000; transform: translateY(-1px); box-shadow: var(--sh-2); }

.btn--light {
  background: var(--paper); color: var(--ink);
  border-color: var(--line-hard);
}
.btn--light:hover { border-color: var(--ink); transform: translateY(-1px); }

.btn--ghost {
  background: rgba(255,255,255,.08); color: #fff;
  border-color: rgba(255,255,255,.28);
}
.btn--ghost:hover { background: rgba(255,255,255,.16); border-color: rgba(255,255,255,.5); }

.btn--on-dark { background: #fff; color: var(--ink); }
.btn--on-dark:hover { background: var(--tint); transform: translateY(-1px); }

.link {
  display: inline-flex; align-items: center; gap: 7px;
  color: var(--teal-deep);
  font-weight: 600;
  font-size: 0.9375rem;
  transition: gap .18s ease, color .18s ease;
}
.link .ic { width: 15px; height: 15px; }
.link:hover { gap: 11px; color: var(--ink); }

/* --- 6. Icons ------------------------------------------------------------ */
.ic {
  width: 20px; height: 20px;
  flex: 0 0 auto;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.ic--solid { fill: currentColor; stroke: none; }

.ic-tile {
  display: grid; place-items: center;
  width: 36px; height: 36px;
  flex: 0 0 auto;
  border-radius: var(--r-sm);
  background: var(--tint);
  color: var(--teal-deep);
}

/* --- 7. Header ----------------------------------------------------------- */
.header {
  position: sticky; top: 0; z-index: 100;
  height: var(--header-h);
  display: flex; align-items: center;
  background: rgba(247,248,246,.86);
  backdrop-filter: saturate(160%) blur(16px);
  -webkit-backdrop-filter: saturate(160%) blur(16px);
  border-bottom: 1px solid transparent;
  transition: border-color .2s ease, background .2s ease;
}
.header.is-stuck {
  border-bottom-color: var(--line);
  background: rgba(247,248,246,.94);
}

.header__inner {
  display: flex; align-items: center; gap: 28px;
  height: 100%;
}

.brand { display: inline-flex; align-items: center; gap: 11px; flex: 0 0 auto; }
.brand__mark { width: 34px; height: 34px; flex: 0 0 auto; }
.brand__name {
  display: block;
  font-family: var(--display);
  font-size: 1.28rem; font-weight: 600; letter-spacing: -0.04em;
  line-height: 1.1;
}
.brand__tag {
  display: block;
  font-size: 0.66rem; font-weight: 500; letter-spacing: 0.01em;
  color: var(--faint); font-style: normal;
}

.nav {
  display: flex; align-items: center; gap: 26px;
  margin-inline: auto;
  font-size: 0.9125rem;
}
.nav a {
  position: relative;
  color: var(--graphite);
  font-weight: 500;
  padding-block: 6px;
  transition: color .16s ease;
}
.nav a::after {
  content: "";
  position: absolute; left: 0; right: 100%; bottom: 0;
  height: 2px; background: var(--teal);
  transition: right .22s ease;
}
.nav a:hover { color: var(--ink); }
.nav a:hover::after, .nav a[aria-current="page"]::after { right: 0; }
.nav a[aria-current="page"] { color: var(--ink); font-weight: 600; }

.header__actions { display: flex; align-items: center; gap: 12px; flex: 0 0 auto; }

/* language switcher */
.lang { position: relative; }
.lang__toggle {
  display: inline-flex; align-items: center; gap: 6px;
  height: 38px; padding: 0 10px;
  background: transparent; border: 1px solid var(--line);
  border-radius: var(--r-sm);
  font-size: 0.85rem; font-weight: 600; color: var(--graphite);
  cursor: pointer;
  transition: border-color .16s ease, background .16s ease;
}
.lang__toggle:hover { border-color: var(--line-hard); background: var(--paper); }
.lang__toggle .ic { width: 16px; height: 16px; }
.lang__chev { width: 12px; height: 12px; transition: transform .2s ease; }
.lang.is-open .lang__chev { transform: rotate(180deg); }

.lang__menu {
  position: absolute; top: calc(100% + 8px); inset-inline-end: 0;
  min-width: 152px; padding: 6px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  box-shadow: var(--sh-2);
  display: none;
}
.lang.is-open .lang__menu { display: block; }
.lang__menu button {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  width: 100%; padding: 9px 11px;
  background: none; border: 0; border-radius: var(--r-xs);
  font-size: 0.9rem; font-weight: 500; text-align: start;
  cursor: pointer;
}
.lang__menu button:hover { background: var(--bg-tint); }
.lang__menu button[aria-selected="true"] { color: var(--teal-deep); font-weight: 600; }
.lang__menu button[aria-selected="true"]::after { content: "✓"; font-size: .85rem; }

.burger {
  display: none;
  width: 40px; height: 40px;
  align-items: center; justify-content: center;
  background: transparent; border: 1px solid var(--line);
  border-radius: var(--r-sm); cursor: pointer;
}

/* --- 8. Hero ------------------------------------------------------------- */
.hero { padding-block: clamp(44px, 5vw, 76px) clamp(40px, 4.5vw, 64px); }

.hero__grid {
  display: grid;
  grid-template-columns: minmax(0, 0.82fr) minmax(0, 1.18fr);
  gap: clamp(36px, 4.5vw, 68px);
  align-items: center;
}

.hero__title { margin-bottom: 22px; max-width: 13ch; }
.hero__lead { max-width: 46ch; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }

/* hero visual: flow + side panel */
.hero__visual {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 190px;
  gap: 26px;
  align-items: start;
  position: relative;
}

/* --- 9. Decision flow ---------------------------------------------------- */
.flow { display: grid; justify-items: center; gap: 0; position: relative; }

.card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  box-shadow: var(--sh-1);
}

.flow__node {
  display: flex; align-items: center; gap: 12px;
  width: 100%;
  padding: 13px 15px;
}
.flow__node strong {
  display: block;
  font-size: 0.875rem; font-weight: 600; letter-spacing: -0.012em;
  line-height: 1.3;
}
.flow__node p {
  font-size: 0.7875rem; line-height: 1.4; color: var(--muted); margin-top: 2px;
}
.flow__node-body { min-width: 0; flex: 1; }

.flow__request { width: 100%; max-width: 330px; }
.flow__request .ic-tile { background: var(--green-wash); color: var(--green); }

.flow__step { max-width: 330px; }
.flow__index {
  font-family: var(--body);
  font-size: 0.72rem; font-weight: 700; color: var(--teal-deep);
  flex: 0 0 auto;
}

.flow__confidence { max-width: 330px; }
.flow__confidence .flow__node-body { display: grid; gap: 7px; }
.meter {
  height: 7px; border-radius: 99px;
  background: var(--line-soft);
  overflow: hidden;
}
.meter span {
  display: block; height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--green), var(--teal));
}
.flow__pct {
  font-size: 0.8125rem; font-weight: 700; color: var(--graphite);
  font-variant-numeric: tabular-nums;
  flex: 0 0 auto;
}

/* connectors */
.flow__link {
  width: 2px; height: 22px;
  background: var(--line-hard);
  position: relative;
}
.flow__link::after {
  content: "";
  position: absolute; bottom: 0; left: 50%;
  width: 7px; height: 7px;
  border-right: 2px solid var(--line-hard);
  border-bottom: 2px solid var(--line-hard);
  transform: translate(-50%, 1px) rotate(45deg);
}

.flow__fork {
  width: 100%; max-width: 620px; height: 40px;
  position: relative;
}
.flow__fork::before {           /* stem down from the confidence node */
  content: "";
  position: absolute; top: 0; left: 50%;
  width: 2px; height: 18px;
  background: var(--line-hard);
  transform: translateX(-50%);
}
.flow__fork::after {            /* horizontal rail */
  content: "";
  position: absolute; top: 18px; left: 16.667%; right: 16.667%;
  height: 2px;
  background: var(--line-hard);
}
.flow__drop {
  position: absolute; top: 18px;
  width: 2px; height: 22px;
  background: var(--line-hard);
}
.flow__drop::after {
  content: "";
  position: absolute; bottom: 0; left: 50%;
  width: 7px; height: 7px;
  border-right: 2px solid var(--line-hard);
  border-bottom: 2px solid var(--line-hard);
  transform: translate(-50%, 1px) rotate(45deg);
}
.flow__drop--a { left: 16.667%; }
.flow__drop--b { left: 50%; }
.flow__drop--c { left: 83.333%; }

.flow__actions {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  width: 100%; max-width: 620px;
}
.flow__action {
  padding: 13px 14px;
  border-radius: var(--r-md);
  border: 1px solid;
  display: grid; gap: 8px;
  align-content: start;
}
.flow__action strong { font-size: 0.8125rem; font-weight: 600; line-height: 1.3; display: block; }
.flow__action p { font-size: 0.75rem; line-height: 1.35; margin-top: 2px; }
.flow__action .ic { width: 17px; height: 17px; }

.flow__action--answer   { background: var(--green-wash); border-color: #bfe0cf; color: var(--green); }
.flow__action--escalate { background: var(--amber-wash); border-color: #e8d2ae; color: var(--amber); }
.flow__action--update   { background: var(--teal-wash);  border-color: #b9dfe4; color: var(--teal-deep); }
.flow__action strong, .flow__action p { color: var(--ink); }
.flow__action p { color: var(--muted); }

.flow__merge {
  width: 100%; max-width: 620px; height: 34px;
  position: relative;
}
.flow__merge::before {
  content: "";
  position: absolute; bottom: 16px; left: 16.667%; right: 16.667%;
  height: 2px; background: var(--line-hard);
}
.flow__merge::after {
  content: "";
  position: absolute; bottom: 0; left: 50%;
  width: 2px; height: 16px;
  background: var(--line-hard);
  transform: translateX(-50%);
}
.flow__rise {
  position: absolute; top: 0;
  width: 2px; height: 18px;
  background: var(--line-hard);
}
.flow__rise--a { left: 16.667%; }
.flow__rise--b { left: 50%; }
.flow__rise--c { left: 83.333%; }

.flow__audit {
  width: 100%; max-width: 440px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  box-shadow: var(--sh-1);
}
.flow__audit .ic-tile { background: var(--deep); color: #fff; }

/* Handwritten annotation.
   Lives in the gap between the flow and the connected panel, so it only
   appears at widths where that gap is actually wide enough to hold it. */
.annotation {
  display: none;
  position: absolute;
  top: 7%;
  inset-inline-end: 206px;
  width: 142px;
  pointer-events: none;
  color: var(--faint);
}
.annotation__text {
  font-family: var(--serif);
  font-style: italic;
  font-size: 1.0625rem;
  line-height: 1.3;
  color: var(--graphite);
  transform: rotate(-4deg);
  display: block;
}
.annotation__arrow {
  width: 62px; height: 52px;
  margin-top: 2px;
  margin-inline-start: 34px;
  stroke: var(--line-hard);
  stroke-width: 1.5;
  fill: none;
}

/* --- 10. Connected panel ------------------------------------------------- */
.connected {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: 18px 16px;
  box-shadow: var(--sh-1);
}
.connected__title {
  font-size: 0.69rem; font-weight: 600;
  letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 14px;
  line-height: 1.45;
}
.connected ul { display: grid; gap: 13px; }
.connected li {
  display: flex; align-items: center; gap: 10px;
  font-size: 0.8375rem; color: var(--graphite);
}
.connected li .ic { width: 17px; height: 17px; color: var(--faint); }

/* --- 11. Trust strip ----------------------------------------------------- */
.trust {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 28px;
  margin-top: clamp(40px, 4.5vw, 60px);
  padding-top: 28px;
  border-top: 1px solid var(--line);
}
.trust__item { display: flex; align-items: flex-start; gap: 13px; }
.trust__item .ic { width: 21px; height: 21px; color: var(--teal-deep); margin-top: 2px; }
.trust__item strong {
  display: block;
  font-size: 0.9125rem; font-weight: 600; letter-spacing: -0.015em;
}
.trust__item span {
  display: block;
  font-size: 0.8125rem; color: var(--muted); margin-top: 2px;
}

/* --- 12. Control layer map ----------------------------------------------- */
.control__grid {
  display: grid;
  grid-template-columns: minmax(0, 0.78fr) minmax(0, 1.22fr);
  gap: clamp(36px, 5vw, 72px);
  align-items: center;
}
.control__intro .lead { margin-bottom: 24px; }

.map {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr) minmax(0, 1fr);
  gap: clamp(12px, 1.6vw, 22px);
  align-items: center;
  position: relative;
}

.map__col {
  display: grid; gap: 4px;
  align-content: start;
}
.map__label {
  font-size: 0.68rem; font-weight: 600;
  letter-spacing: 0.13em; text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 10px;
}
.map__item {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 2px;
  font-size: 0.85rem; color: var(--graphite);
}
.map__item .ic { width: 17px; height: 17px; color: var(--faint); }
.map__item small {
  display: block;
  font-size: 0.74rem; color: var(--faint); line-height: 1.3;
}

.map__hub {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--sh-2);
  padding: 30px 22px;
  text-align: center;
  display: grid; justify-items: center; gap: 14px;
}
.map__hub-mark { width: 52px; height: 52px; color: var(--teal); }
.map__hub h3 {
  font-size: 1.22rem; line-height: 1.22; letter-spacing: -0.03em;
}
.map__hub p {
  font-size: 0.775rem; color: var(--muted); line-height: 1.6;
  letter-spacing: 0.005em;
}

/* connector arrows between columns and hub */
.map__wires {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  pointer-events: none;
  overflow: visible;
}
.map__wires path {
  fill: none;
  stroke: var(--teal);
  stroke-width: 1.4;
  stroke-opacity: .45;
  stroke-linecap: round;
}

/* --- 13. Product lab ----------------------------------------------------- */
.section-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(24px, 4vw, 64px);
  align-items: end;
  margin-bottom: clamp(30px, 3.5vw, 46px);
}
.section-head__aside {
  display: flex; align-items: flex-start; justify-content: space-between;
  gap: 24px;
  padding-bottom: 4px;
}
.section-head__aside p { max-width: 42ch; font-size: 0.9375rem; color: var(--muted); }

.lab-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
}

.lab-card {
  position: relative;
  display: flex; flex-direction: column; justify-content: flex-end;
  min-height: 330px;
  padding: 22px;
  border-radius: var(--r-md);
  overflow: hidden;
  color: #fff;
  isolation: isolate;
  background-color: var(--deep);
  background-size: cover;
  background-position: center;
  transition: transform .28s cubic-bezier(.2,.7,.3,1), box-shadow .28s ease;
}
.lab-card::after {
  content: "";
  position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(180deg,
              rgba(6,16,24,0) 22%,
              rgba(6,16,24,.62) 55%,
              rgba(6,16,24,.93) 100%);
}
.lab-card:hover { transform: translateY(-5px); box-shadow: var(--sh-3); }

.lab-card h3 { color: #fff; font-size: 1.2rem; letter-spacing: -0.03em; }
.lab-card__kicker {
  font-size: 0.8125rem; color: rgba(255,255,255,.72);
  margin: 4px 0 11px; line-height: 1.35;
}
.lab-card__text {
  font-size: 0.8125rem; line-height: 1.5;
  color: rgba(255,255,255,.8);
}
.lab-card__link {
  display: inline-flex; align-items: center; gap: 7px;
  margin-top: 16px;
  font-size: 0.8625rem; font-weight: 600;
  color: #7fdfe9;
  transition: gap .18s ease;
}
.lab-card__link .ic { width: 14px; height: 14px; }
.lab-card:hover .lab-card__link { gap: 11px; }

/* whole-card click target without nesting interactive elements */
.lab-card__link::before { content: ""; position: absolute; inset: 0; }

/* --- 14. Comparison ------------------------------------------------------ */
.compare__grid {
  display: grid;
  /* the quote column needs ~260px of text width or the serif breaks a word per line */
  grid-template-columns: minmax(0, 0.78fr) minmax(0, 1.2fr) minmax(250px, 0.74fr);
  gap: clamp(26px, 3vw, 46px);
  align-items: center;
}

.table {
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  overflow: hidden;
  background: var(--paper);
  box-shadow: var(--sh-1);
}
.table__row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-bottom: 1px solid var(--line-soft);
}
.table__row:last-child { border-bottom: 0; }
.table__row--head { background: var(--bg-tint); }
.table__row--head > * {
  font-family: var(--display);
  font-size: 0.9125rem; font-weight: 600; letter-spacing: -0.02em;
  color: var(--ink);
}
.table__cell {
  padding: 13px 16px;
  font-size: 0.875rem;
  color: var(--muted);
}
.table__cell + .table__cell {
  border-inline-start: 1px solid var(--line-soft);
  color: var(--ink);
  font-weight: 500;
  display: flex; align-items: center; gap: 9px;
}
.table__cell .ic {
  width: 16px; height: 16px;
  color: var(--green);
  flex: 0 0 auto;
}

.pullquote {
  border-inline-start: 1px solid var(--line);
  padding-inline-start: clamp(20px, 2.2vw, 30px);
}
.pullquote__label {
  font-size: 0.68rem; font-weight: 600;
  letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--muted);
  line-height: 1.5;
  margin-bottom: 18px;
}
.pullquote__text {
  font-family: var(--serif);
  font-size: clamp(1.5rem, 1.85vw, 1.85rem);
  line-height: 1.2;
  letter-spacing: -0.015em;
  color: var(--ink);
}
.pullquote__text em { font-style: italic; }
.pullquote__rule {
  width: 34px; height: 2px;
  background: var(--teal);
  margin-top: 22px;
}

/* --- 15. FAQ ------------------------------------------------------------- */
.faq-grid { display: grid; gap: 10px; max-width: 820px; }
.faq-item {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  overflow: hidden;
}
.faq-item summary {
  display: flex; align-items: center; justify-content: space-between; gap: 18px;
  padding: 17px 20px;
  cursor: pointer;
  list-style: none;
  font-family: var(--display);
  font-size: 1rem; font-weight: 600; letter-spacing: -0.02em;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary .ic {
  width: 18px; height: 18px; color: var(--teal-deep);
  transition: transform .22s ease;
}
.faq-item[open] summary .ic { transform: rotate(45deg); }
.faq-item__body {
  padding: 0 20px 18px;
  font-size: 0.9125rem; line-height: 1.6; color: var(--muted);
  max-width: 68ch;
}

/* --- 16. Final CTA ------------------------------------------------------- */
.cta {
  position: relative;
  padding-block: clamp(76px, 8.5vw, 124px);
  background-color: #0a1720;
  background-image: url("assets/cta-horizon.svg");
  background-size: cover;
  background-position: center 68%;
  color: #fff;
  overflow: hidden;
}
/* The SVG already carries its own vignette, so this overlay only needs to
   darken the left third behind the headline — any more and the ridgeline
   and road disappear entirely. */
.cta::before {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(100deg, rgba(5,13,20,.82) 0%, rgba(5,13,20,.42) 44%, rgba(5,13,20,.06) 100%);
}
.cta > * { position: relative; }

.cta__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr) auto;
  gap: clamp(28px, 4vw, 60px);
  align-items: center;
}
.cta h2 { color: #fff; max-width: 15ch; }
.cta .eyebrow { color: rgba(255,255,255,.62); }
.cta__text {
  font-size: 1.0625rem; line-height: 1.6;
  color: rgba(255,255,255,.82);
  max-width: 38ch;
  margin-bottom: 26px;
}

.cta__rail {
  display: grid; gap: 13px;
  padding-inline-start: 22px;
  border-inline-start: 1px solid rgba(255,255,255,.2);
}
.cta__rail span {
  font-size: 0.7rem; font-weight: 600;
  letter-spacing: 0.16em; text-transform: uppercase;
  color: rgba(255,255,255,.55);
}

/* --- 17. Footer ---------------------------------------------------------- */
.footer {
  background: #0b1622;
  color: rgba(255,255,255,.72);
  padding-block: 56px 24px;
  font-size: 0.9rem;
}
.footer a { color: rgba(255,255,255,.72); transition: color .16s ease; }
.footer a:hover { color: #fff; }
.footer .brand__name { color: #fff; }
.footer .brand__tag { color: rgba(255,255,255,.5); }
.footer .brand__mark { color: var(--teal); }

.footer__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) repeat(3, minmax(0, .8fr));
  gap: 38px;
}
.footer__about { max-width: 34ch; margin-top: 16px; line-height: 1.6; }
.footer h4 {
  color: #fff; margin-bottom: 14px;
  font-size: 0.8rem; font-weight: 600;
  letter-spacing: 0.13em; text-transform: uppercase;
}
.footer__col { display: grid; gap: 10px; align-content: start; }

.footer__bottom {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  gap: 14px;
  margin-top: 46px; padding-top: 22px;
  border-top: 1px solid rgba(255,255,255,.12);
  font-size: 0.85rem;
  color: rgba(255,255,255,.55);
}
.footer__legal { display: flex; gap: 20px; flex-wrap: wrap; }

/* --- 18. Motion ---------------------------------------------------------- */
.reveal {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity .7s cubic-bezier(.2,.7,.3,1), transform .7s cubic-bezier(.2,.7,.3,1);
}
.reveal.is-in { opacity: 1; transform: none; }
.reveal[data-delay="1"] { transition-delay: .09s; }
.reveal[data-delay="2"] { transition-delay: .18s; }
.reveal[data-delay="3"] { transition-delay: .27s; }

.meter span {
  transform-origin: left center;
  animation: meter-fill 1.5s cubic-bezier(.2,.7,.3,1) .5s both;
}
@keyframes meter-fill { from { transform: scaleX(0); } to { transform: scaleX(1); } }

/* --- 19. Internal pages (kept from v3, restyled) ------------------------- */
.page-hero { padding-block: clamp(44px, 5vw, 78px) clamp(32px, 4vw, 54px); }
.page-hero__grid {
  display: grid;
  grid-template-columns: minmax(0, .92fr) minmax(0, 1.08fr);
  gap: clamp(36px, 5vw, 72px);
  align-items: center;
}
.blueprint {
  position: relative;
  padding: 26px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--sh-2);
  overflow: hidden;
}
.blueprint::before {
  content: "";
  position: absolute; inset: 0;
  background-image:
    linear-gradient(90deg, rgba(16,42,67,.04) 1px, transparent 1px),
    linear-gradient(rgba(16,42,67,.04) 1px, transparent 1px);
  background-size: 32px 32px;
  pointer-events: none;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}
.feature {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  padding: 22px;
  box-shadow: var(--sh-1);
}
.feature h3 { margin-bottom: 9px; }
.feature p { font-size: .9rem; color: var(--muted); line-height: 1.55; }

.steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 12px;
}
.step {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  padding: 18px;
  box-shadow: var(--sh-1);
}
.step b {
  display: block;
  font-size: .72rem; font-weight: 700; letter-spacing: .1em;
  color: var(--teal-deep); margin-bottom: 14px;
}
.step h3 { font-size: .975rem; margin-bottom: 7px; }
.step p { font-size: .84rem; color: var(--muted); line-height: 1.5; }

.form { display: grid; gap: 14px; }
.form__row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.form label { display: grid; gap: 7px; font-size: .85rem; font-weight: 600; color: var(--graphite); }
.form input, .form textarea, .form select {
  width: 100%;
  padding: 11px 13px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  font-size: .9375rem;
  font-weight: 400;
  transition: border-color .16s ease, box-shadow .16s ease;
}
.form input:focus, .form textarea:focus, .form select:focus {
  outline: none;
  border-color: var(--teal);
  box-shadow: 0 0 0 3px rgba(22,166,182,.14);
}
.form textarea { resize: vertical; min-height: 118px; }
.form__honeypot { position: absolute; left: -10000px; }
.form__status { min-height: 20px; font-size: .875rem; font-weight: 600; color: var(--teal-deep); }

/* breadcrumb */
.breadcrumb {
  display: flex; flex-wrap: wrap; align-items: center; gap: 8px;
  margin-bottom: 20px;
  font-size: .8125rem; color: var(--faint);
}
.breadcrumb a { color: var(--muted); }
.breadcrumb a:hover { color: var(--ink); }
.breadcrumb span[aria-current] { color: var(--graphite); font-weight: 500; }
.breadcrumb .sep { color: var(--line-hard); }

/* mini decision flow inside a blueprint card */
.mini-flow { display: grid; justify-items: center; gap: 0; position: relative; }
.mini-flow__node {
  position: relative; z-index: 1;
  width: 100%; max-width: 300px;
  padding: 12px 16px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  box-shadow: var(--sh-1);
  text-align: center;
  font-size: .875rem; font-weight: 600;
}
.mini-flow__node--ok { border-color: #bfe0cf; background: var(--green-wash); }
.mini-flow__node--audit { background: var(--deep); border-color: transparent; color: #fff; }
.mini-flow__link {
  width: 2px; height: 18px;
  background: var(--line-hard);
}
.mini-flow__branches {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px;
  width: 100%; max-width: 300px;
  position: relative; z-index: 1;
}
.mini-flow__branches span {
  padding: 8px 6px;
  border-radius: 99px;
  background: var(--tint);
  border: 1px solid #b9dfe4;
  color: var(--teal-deep);
  font-size: .78rem; font-weight: 600;
  text-align: center;
}

/* horizontal stage rail — used where the content really is a sequence */
.rail {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(118px, 1fr));
  gap: 10px;
}
.rail span {
  position: relative;
  padding: 16px 12px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  box-shadow: var(--sh-1);
  text-align: center;
  font-size: .85rem; font-weight: 600;
  color: var(--deep);
}
.rail span:not(:last-child)::after {
  content: "";
  position: absolute; inset-inline-end: -7px; top: 50%;
  width: 6px; height: 2px;
  background: var(--teal);
  transform: translateY(-50%);
}

/* tag chips */
.tags { display: flex; flex-wrap: wrap; gap: 8px; }
.tags span {
  padding: 7px 12px;
  border: 1px solid var(--line);
  border-radius: 99px;
  background: var(--paper);
  font-size: .8125rem; color: var(--graphite);
}

/* closing card on internal pages */
.cta-card {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  gap: 28px;
  padding: clamp(26px, 3.5vw, 42px);
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--sh-2);
}
.cta-card h2 { max-width: 18ch; }
.cta-card p { margin-top: 12px; max-width: 54ch; color: var(--muted); font-size: .9375rem; }

/* simple centred page (404, privacy intro) */
.plain { padding-block: clamp(70px, 9vw, 130px); }
.plain h1 { max-width: 16ch; margin-bottom: 20px; }
.plain .prose { max-width: 70ch; display: grid; gap: 16px; }
.plain .prose h2 { font-size: 1.35rem; margin-top: 18px; }
.plain .prose p, .plain .prose li { color: var(--muted); font-size: .9375rem; line-height: 1.65; }
.plain .prose ul { display: grid; gap: 8px; padding-inline-start: 20px; list-style: disc; }

/* --- 20. RTL ------------------------------------------------------------- */
[dir="rtl"] body { font-family: "Assistant", var(--body); }
[dir="rtl"] h1, [dir="rtl"] h2, [dir="rtl"] h3, [dir="rtl"] h4 {
  font-family: "Assistant", var(--display);
  letter-spacing: -0.01em;
}
[dir="rtl"] .brand { direction: ltr; }
[dir="rtl"] .annotation__text { transform: rotate(4deg); }
[dir="rtl"] .meter span { transform-origin: right center; }
[dir="rtl"] .annotation__arrow { transform: scaleX(-1); }
[dir="rtl"] .link:hover, [dir="rtl"] .lab-card:hover .lab-card__link { gap: 11px; }
[dir="rtl"] .pullquote__text { font-family: "Assistant", var(--serif); font-weight: 600; }
[dir="rtl"] .eyebrow, [dir="rtl"] .map__label,
[dir="rtl"] .connected__title, [dir="rtl"] .cta__rail span { letter-spacing: 0.04em; }

/* --- 21. Responsive ------------------------------------------------------ */

/* Wide screens: open a real gutter between the flow and the connected panel
   so the handwritten note has somewhere to sit. */
@media (min-width: 1280px) {
  .hero__visual {
    grid-template-columns: minmax(0, 1fr) 186px;
    column-gap: 152px;
  }
  .annotation { display: block; }
}

@media (max-width: 1160px) {
  .hero__grid,
  .control__grid { grid-template-columns: 1fr; }
  .hero__visual { max-width: 720px; }
  .compare__grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1.3fr); }
  .pullquote {
    grid-column: 1 / -1;
    border-inline-start: 0;
    border-top: 1px solid var(--line);
    padding-inline-start: 0;
    padding-top: 26px;
  }
  .lab-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cta__grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .cta__rail {
    grid-column: 1 / -1;
    display: flex; flex-wrap: wrap; gap: 18px;
    padding-inline-start: 0; padding-top: 22px;
    border-inline-start: 0;
    border-top: 1px solid rgba(255,255,255,.2);
  }
  .footer__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 960px) {
  .nav {
    position: absolute; top: calc(100% + 8px);
    inset-inline: var(--gutter);
    flex-direction: column; align-items: stretch; gap: 0;
    margin: 0; padding: 8px;
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: var(--r-md);
    box-shadow: var(--sh-2);
    display: none;
  }
  .nav.is-open { display: flex; }
  .nav a { padding: 12px 12px; }
  .nav a::after { display: none; }
  .header__inner { justify-content: space-between; }
  .burger { display: inline-flex; }
  .header__cta { display: none; }

  .map { grid-template-columns: 1fr; gap: 16px; }
  .map__wires { display: none; }
  .map__col { background: var(--paper); border: 1px solid var(--line); border-radius: var(--r-md); padding: 16px; }
  .section-head { grid-template-columns: 1fr; }
  .section-head__aside { flex-direction: column; gap: 14px; }
  .feature-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .page-hero__grid { grid-template-columns: 1fr; }
}

@media (max-width: 720px) {
  :root { --gutter: 20px; --header-h: 66px; }

  .trust { grid-template-columns: 1fr; gap: 18px; }
  .hero__visual { grid-template-columns: 1fr; }
  .annotation { display: none; }
  .flow__actions { grid-template-columns: 1fr; }
  .flow__fork { height: 24px; }
  .flow__fork::after, .flow__drop--a, .flow__drop--c { display: none; }
  .flow__merge::before, .flow__rise--a, .flow__rise--c { display: none; }
  .flow__merge { height: 24px; }

  .lab-grid { grid-template-columns: 1fr; }
  .lab-card { min-height: 290px; }
  .compare__grid { grid-template-columns: 1fr; }
  .table__cell { padding: 11px 13px; font-size: .8125rem; }
  .cta__grid { grid-template-columns: 1fr; }
  .footer__grid { grid-template-columns: 1fr; gap: 30px; }
  .form__row, .feature-grid { grid-template-columns: 1fr; }
}

/* --- 22. Reduced motion & print ------------------------------------------ */
@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; }
}

@media print {
  .header, .cta, .footer, .annotation { display: none; }
  body { background: #fff; }
}
