/* ============================================================================
   NZT Lab deck — Buona Fortuna AI transformation (Danifo design system)
   Light, study-friendly redesign. Imports vendored tokens, then:
   readability type-scale overrides -> base/reset -> chrome -> bands/utilities
   -> NZT Lab wordmark -> forked df- components -> infographics.
   Accessibility: essential text is navy-on-white (~12.6:1) or white-on-navy.
   Orange (#F47929) = 2.76:1 on white (fail) but 4.86:1 on navy (AA) -> used
   for navy-surface accents, icon strokes, rules, units, and CTA fills only.
   ============================================================================ */
@import "./tokens.css";

/* ---- Readability type-scale overrides (the core fix) ------------------- */
:root {
  --ts-display: clamp(38px, 4.6vw, 66px);
  --ts-h1: clamp(40px, 5vw, 64px);
  --ts-h2: clamp(32px, 3.4vw, 52px);
  --ts-h3: clamp(24px, 2vw, 32px);
  --ts-lead: clamp(20px, 1.6vw, 28px);
  --ts-body: clamp(18px, 1.15vw, 21px);
  --ts-small: 16px;
  --ts-eyebrow: 14px;
  --ts-foot: 13px;
  --lh-display: 1.02;
  --lh-h1: 1.06;
  --lh-h2: 1.1;
  --lh-h3: 1.22;
  --lh-lead: 1.38;
  --lh-body: 1.6;
  --lh-small: 1.5;
  --measure: 68ch;
  --nav-h: 64px;
  --color-danger: #C0392B;   /* «было» крест — ≈4.7:1 на белом */
  --color-success: #178A53;  /* «стало» галочка — ≈4.6:1 на белом */
}

/* ---- Reset / base ----------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--nav-h) + var(--space-4));
  overflow-x: clip; /* backstop vs accidental horizontal overflow; safe for sticky nav (unlike overflow:hidden) */
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
body {
  margin: 0;
  font-family: var(--danifo-font-body);
  font-size: var(--ts-body);
  line-height: var(--lh-body);
  color: var(--text-primary);
  background: var(--surface-default);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}
h1, h2, h3, p, ul, ol, dl, figure, blockquote { margin: 0; }
img, svg { display: block; max-width: 100%; }
a { color: inherit; }
ul, ol { padding: 0; list-style: none; }
strong { font-weight: 700; }
.t-display, .t-h1 { letter-spacing: -0.01em; }
.measure { max-width: var(--measure); }
.visually-hidden {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
:focus-visible { outline: 3px solid var(--text-accent); outline-offset: 2px; border-radius: 3px; }

/* base icon: stroke="currentColor" symbols — color set via `color` */
.icon { width: 1em; height: 1em; flex: none; }
.icon--accent { color: var(--action-default); }

/* ---- Reveal on scroll (hidden only when JS active -> no-JS shows all) -- */
.reveal {
  transition: opacity var(--duration-slow) var(--ease-standard),
              transform var(--duration-slow) var(--ease-standard);
}
.js .reveal { opacity: 0; transform: translateY(18px); }
.reveal.revealed { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .js .reveal { opacity: 1; transform: none; }
  .reveal { transition: none; }
}

/* ---- Layout: container + bands ---------------------------------------- */
.container {
  max-width: 1240px;
  margin-inline: auto;
  padding-inline: clamp(20px, 4vw, 48px);
}
.band { padding-block: var(--space-8); }
@media (max-width: 480px) { .band { padding-block: var(--space-7); } }
.band--navy { background: var(--surface-navy); color: var(--text-on-dark); }
.band--gray { background: var(--surface-elevated); }
.band--navy .t-h2, .band--navy .t-h1, .band--navy .t-h3 { color: #fff; }

.section-head { max-width: 760px; margin-bottom: var(--space-7); }
.section-head .t-h2 { margin-top: var(--space-2); }
.section-head__sub {
  margin-top: var(--space-4);
  font-size: var(--ts-lead);
  line-height: var(--lh-lead);
  color: var(--text-secondary);
  max-width: var(--measure);
}
.band--navy .section-head__sub { color: rgba(255, 255, 255, 0.78); }

/* grids */
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: var(--space-5); }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-5); }
.cards-6 { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-5); }
.stats-4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--space-7) var(--space-5); }
@media (max-width: 980px) {
  .grid-3, .cards-6 { grid-template-columns: repeat(2, 1fr); }
  .stats-4 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 620px) {
  /* minmax(0,1fr) removes the implicit min-width:auto so a single track can shrink
     below its content's min-content width (canonical grid-overflow fix). */
  .grid-2, .grid-3, .cards-6, .stats-4 { grid-template-columns: minmax(0, 1fr); }
}

/* ---- Chrome: sticky nav ----------------------------------------------- */
.nav {
  position: sticky; top: 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between;
  gap: var(--space-4);
  min-height: var(--nav-h);
  padding: var(--space-2) clamp(20px, 4vw, 48px);
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border-subtle);
  transition: box-shadow var(--duration-base) var(--ease-standard),
              border-color var(--duration-base) var(--ease-standard);
}
.nav.is-scrolled {
  box-shadow: 0 6px 24px rgba(41, 37, 106, 0.09);
  border-bottom-color: rgba(41, 37, 106, 0.18);
}
.nav__links { display: flex; align-items: center; gap: var(--space-5); }
.nav__link {
  font-family: var(--danifo-font-body); font-weight: 700;
  font-size: var(--ts-small); color: var(--text-secondary);
  text-decoration: none; transition: color var(--duration-base);
}
.nav__link:hover { color: var(--text-primary); }
.nav__toggle {
  display: none; /* desktop: hidden; shown only on narrow screens when JS is active */
  align-items: center; justify-content: center;
  width: 44px; height: 44px; margin: calc(var(--space-2) * -1) 0; /* keep 44px tap area without growing the bar */
  padding: 0; border: 0; background: transparent; cursor: pointer;
  color: var(--text-primary); border-radius: var(--radius-sm);
}
.nav__toggle .icon { width: 26px; height: 26px; }
.nav__toggle-close { display: none; }
.nav__brand { display: inline-flex; align-items: center; gap: var(--space-3); text-decoration: none; }
.nav__suffix {
  font-family: var(--danifo-font-body); font-weight: 700;
  font-size: var(--ts-small); color: var(--text-secondary); white-space: nowrap;
}
.nav__back {
  display: inline-flex; align-items: center; gap: var(--space-2);
  font-family: var(--danifo-font-body); font-weight: 700;
  font-size: var(--ts-small); color: var(--text-primary); text-decoration: none;
}
.nav__back .icon { width: 1.2em; height: 1.2em; color: var(--action-default); transition: transform var(--duration-base); }
.nav__back:hover .icon { transform: translateX(-3px); }
@media (max-width: 720px) {
  /* With JS: collapse links into a dropdown panel behind a hamburger toggle.
     Without JS (.js absent), links stay visible and wrap — navigation is never lost. */
  .js .nav__toggle { display: inline-flex; }
  .js .nav__links {
    display: none;
    position: absolute; top: 100%; left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 0;
    padding: var(--space-2) 0;
    background: rgba(255, 255, 255, 0.97);
    backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
    border-bottom: 1px solid var(--border-subtle);
    box-shadow: 0 12px 28px rgba(41, 37, 106, 0.12);
  }
  .js .nav.is-open .nav__links { display: flex; }
  .js .nav.is-open .nav__toggle-open { display: none; }
  .js .nav.is-open .nav__toggle-close { display: inline; }
  .js .nav__links .nav__link {
    display: flex; align-items: center; min-height: 48px;
    padding: var(--space-3) clamp(20px, 4vw, 48px);
    font-size: var(--ts-body);
  }
  .js .nav__links li + li .nav__link { border-top: 1px solid var(--border-subtle); }
}

/* ---- NZT Lab wordmark (no Danifo logo) -------------------------------- */
.nzt {
  font-family: var(--danifo-font-display);
  font-weight: 400;
  letter-spacing: 0.04em;
  line-height: 1;
  color: var(--text-primary);
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
  font-size: 20px;
}
.nzt__lab { margin-left: 0.18em; text-transform: none; }
.nzt__spark {
  width: 0.62em; height: 0.62em;
  margin-left: 0.16em;
  color: var(--action-default);   /* stroked sparkle -> orange outline */
  transform: translateY(-0.04em);
  flex: none;
}
.nzt--on-dark { color: var(--text-on-dark); }
.nzt--on-dark .nzt__spark { color: var(--action-default); }
.nzt--lg { font-size: clamp(24px, 3.4vw, 38px); }
.nzt--foot { font-size: var(--ts-foot); letter-spacing: 0.06em; }

/* ---- Hero ------------------------------------------------------------- */
.hero { position: relative; overflow: hidden; }
.hero__inner {
  position: relative; z-index: 1;
  display: flex; flex-direction: column; align-items: flex-start;
  gap: var(--space-5);
  max-width: 900px;
  padding-block: clamp(56px, 11vh, 132px);
}
.hero__lockup { margin-bottom: var(--space-2); }
.hero__heading { display: flex; flex-direction: column; align-items: flex-start; gap: var(--space-4); }
.hero__title { max-width: 20ch; }
.hero .hl-muted { color: rgba(255, 255, 255, 0.6); }
.hero .hl-em { color: var(--action-default); }   /* orange on navy = AA-large */
.hero__sub {
  font-size: var(--ts-lead); line-height: var(--lh-lead);
  color: rgba(255, 255, 255, 0.82); max-width: 48ch;
}
/* Top hero fits one viewport (scoped to header.hero; final CTA section untouched) */
header.hero { padding-block: 0; }   /* inner supplies its own padding-block below; avoids double band padding */
header.hero .hero__inner {
  min-height: calc(100svh - var(--nav-h));
  justify-content: center;
  padding-block: clamp(20px, 4vh, 52px);
  gap: var(--space-7);
}
header.hero .hero__lockup { margin-bottom: 0; }
header.hero .hero__illus { bottom: 0; }   /* no negative bleed past the band -> hero fits viewport with no scroll */
/* Hero before -> after metrics (time + cost) */
.hero__metrics {
  display: flex; flex-wrap: wrap; gap: var(--space-4) var(--space-7);
  margin-top: var(--space-2); padding-top: var(--space-4);
  border-top: 1px solid rgba(255, 255, 255, 0.16);
}
.hero__metric { display: flex; flex-direction: column; gap: var(--space-2); }
.hero__metric-label {
  font-family: var(--danifo-font-body); font-weight: 700;
  font-size: var(--ts-eyebrow); letter-spacing: var(--tracking-eyebrow, 0.08em);
  text-transform: uppercase; color: rgba(255, 255, 255, 0.55);
}
.hero__metric-row { display: inline-flex; align-items: center; gap: var(--space-3); }
.hero__metric-was {
  font-family: var(--danifo-font-body); font-size: clamp(16px, 1.4vw, 20px);
  color: rgba(255, 255, 255, 0.5);
  text-decoration: line-through; text-decoration-thickness: 1px;
}
.hero__metric-arrow {
  width: 1.15em; height: 1.15em; color: var(--action-default); flex: none;
}
.hero__metric-now {
  font-family: var(--danifo-font-body); font-weight: 700;
  font-size: clamp(18px, 1.8vw, 26px); color: var(--action-default); line-height: 1.05;
}
.hero__illus {
  position: absolute; right: -1%; bottom: -3%; z-index: 0;
  width: clamp(320px, 42vw, 640px);
  opacity: 0.92; pointer-events: none; user-select: none;
}
@media (max-width: 900px) {
  .hero__illus { opacity: 0.16; right: -8%; bottom: -2%; width: 80%; }
}

/* ---- df-eyebrow ------------------------------------------------------- */
.df-eyebrow {
  font-family: var(--danifo-font-body); font-weight: 700;
  font-size: var(--ts-eyebrow); line-height: var(--lh-eyebrow);
  letter-spacing: var(--tracking-eyebrow); text-transform: uppercase;
  color: var(--text-accent); margin: 0 0 var(--space-3) 0;   /* purple 7.2:1 on white */
}
.df-eyebrow--accent { color: var(--text-accent); }
.df-eyebrow--on-dark { color: var(--action-default); }   /* orange 4.86:1 on navy */

/* ---- df-cta ----------------------------------------------------------- */
.df-cta {
  display: inline-flex; align-items: center; justify-content: center; gap: var(--space-2);
  min-height: 44px; /* comfortable touch target */
  padding: var(--space-3) var(--space-5);
  background: var(--action-default); color: var(--action-on-dark);
  font-family: var(--danifo-font-body); font-weight: 700;
  font-size: var(--ts-body); line-height: 1;
  border: none; border-radius: var(--radius-pill);
  text-decoration: none; cursor: pointer;
  transition: background var(--duration-base) var(--ease-standard),
              transform var(--duration-base) var(--ease-standard);
}
.df-cta:hover, .df-cta:focus-visible { background: var(--action-hover); }
.df-cta:active { transform: translateY(1px); }
.df-cta__icon { width: 1.15em; height: 1.15em; color: currentColor; transition: transform var(--duration-base); }
.df-cta:hover .df-cta__icon { transform: translateX(3px); }
.df-cta--ghost {
  background: transparent; color: var(--text-primary);
  box-shadow: inset 0 0 0 1.5px var(--border-strong);
}
.df-cta--ghost:hover, .df-cta--ghost:focus-visible { background: var(--surface-elevated); }
.df-cta--ghost .df-cta__icon { color: var(--action-default); }

/* ---- df-service cards ------------------------------------------------- */
.df-service {
  position: relative;
  display: flex; flex-direction: column; gap: var(--space-3);
  padding: var(--space-5);
  background: var(--surface-default);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
}
.df-service__icon { width: 34px; height: 34px; color: var(--action-default); }
.df-service__num {
  position: absolute; top: var(--space-4); right: var(--space-5);
  font-family: var(--danifo-font-display); font-weight: 900;
  font-size: var(--ts-h3); color: var(--text-primary); line-height: 1;   /* navy ~13:1 — not orange (2.8:1 fails) */
}
.df-service__title {
  font-family: var(--danifo-font-display); font-weight: 900;
  font-size: var(--ts-h3); line-height: var(--lh-h3);
  color: var(--text-primary); max-width: 18ch;
  overflow-wrap: break-word;
}
.df-service__body {
  font-family: var(--danifo-font-body); font-size: var(--ts-body);
  line-height: var(--lh-body); color: var(--text-secondary);
}
.df-service--link {
  text-decoration: none; color: inherit;
  transition: border-color var(--duration-base) var(--ease-standard),
              transform var(--duration-base) var(--ease-standard),
              box-shadow var(--duration-base) var(--ease-standard);
}
.df-service--link:hover {
  border-color: var(--border-strong);
  transform: translateY(-3px);
  box-shadow: 0 14px 34px rgba(41, 37, 106, 0.10);
}
.df-service--link .df-service__title { font-size: clamp(19px, 1.5vw, 23px); max-width: 20ch; }
#effect .df-service__title { font-size: var(--ts-body); }
.cards-6 { align-items: stretch; grid-auto-rows: 1fr; }
.df-service--link { padding: var(--space-4) var(--space-5); }
.df-service__more {
  margin-top: auto; display: inline-flex; align-items: center; align-self: flex-start;
  font-family: var(--danifo-font-body); font-weight: 700;
  font-size: var(--ts-small); color: var(--text-primary);
  text-decoration: underline; text-decoration-color: var(--action-default);
  text-decoration-thickness: 2px; text-underline-offset: 3px;
}
.df-service--link:hover .df-service__more { text-decoration-color: var(--text-primary); }

/* ---- Numbered callouts (reuse df-service shell) ----------------------- */
.callout .df-service__num {
  font-size: clamp(30px, 3.4vw, 42px); top: var(--space-4); right: var(--space-4); opacity: 0.92;
}
.callout .df-service__title {
  font-size: clamp(19px, 1.5vw, 23px); line-height: var(--lh-h3);
  max-width: 24ch; padding-right: 3.25rem;
}

/* ============================================================================
   DETAIL PAGES
   ============================================================================ */
.page-wrapper { /* container provided per-page */ }
.page-header {
  padding-block: clamp(40px, 7vh, 88px) var(--space-6);
  display: grid; grid-template-columns: minmax(0, 1fr) auto;
  gap: var(--space-7); align-items: center;
}
.page-header__text { min-width: 0; }
.page-header__illus {
  width: clamp(180px, 22vw, 300px); height: auto; justify-self: end;
  opacity: 0.96; pointer-events: none; user-select: none;
}
.page-title { color: var(--text-primary); margin-top: var(--space-3); max-width: 20ch; }
.page-subtitle {
  margin-top: var(--space-5);
  font-size: var(--ts-lead); line-height: var(--lh-lead);
  color: var(--text-secondary); max-width: var(--measure);
}
@media (max-width: 820px) {
  .page-header { grid-template-columns: 1fr; }
  .page-header__illus { display: none; }
}

.detail-block { padding-block: var(--space-7); border-top: 1px solid var(--border-subtle); }
.detail-block:first-of-type { border-top: none; }
.detail-label {
  display: flex; align-items: center; gap: var(--space-3);
  font-family: var(--danifo-font-display); font-weight: 900;
  font-size: var(--ts-h3); line-height: var(--lh-h3);
  color: var(--text-primary); margin: 0 0 var(--space-5) 0;
}
.detail-label::before {
  content: ""; width: 30px; height: 4px; flex: none;
  background: var(--action-default); border-radius: 2px;
}
.detail-body { max-width: var(--measure); }
.detail-body > p {
  font-size: var(--ts-body); line-height: var(--lh-body);
  color: var(--text-primary); margin: 0 0 var(--space-4) 0;
}
.detail-body > p:last-child { margin-bottom: 0; }
.detail-body strong { font-weight: 700; color: var(--text-primary); }

/* ---- df-step (transformed step-list) ---------------------------------- */
.df-step { counter-reset: dfstep; display: flex; flex-direction: column; gap: var(--space-6); }
.df-step__item { counter-increment: dfstep; position: relative; padding-left: 4.25rem; }
.df-step__item::before {
  content: counter(dfstep, decimal-leading-zero);
  position: absolute; left: 0; top: -0.1rem; width: 2.8rem; text-align: center;
  font-family: var(--danifo-font-display); font-weight: 900;
  font-size: 1.9rem; line-height: 1.1; color: var(--text-primary);   /* navy numerals */
}
.df-step__item:not(:last-child)::after {
  content: ""; position: absolute; left: 1.4rem; top: 2.5rem;
  bottom: calc(-1 * var(--space-6)); width: 2px;
  background: var(--border-subtle); transform: translateX(-1px);
}
.df-step__title {
  font-family: var(--danifo-font-display); font-weight: 900;
  font-size: var(--ts-h3); line-height: var(--lh-h3);
  color: var(--text-primary); margin: 0 0 var(--space-2) 0;
  display: flex; align-items: center; gap: var(--space-2); flex-wrap: wrap;
}
.df-step__icon { width: 1.05em; height: 1.05em; color: var(--action-default); }
.df-step__body {
  font-family: var(--danifo-font-body); font-size: var(--ts-body);
  line-height: var(--lh-body); color: var(--text-secondary);
  margin: 0; max-width: var(--measure);
}

/* ---- df-kpi (transformed kpi-list) ------------------------------------ */
.df-kpi { display: grid; gap: 0; }
.df-kpi__item {
  display: grid; grid-template-columns: minmax(130px, 210px) 1fr;
  gap: var(--space-4) var(--space-5); align-items: baseline;
  padding-block: var(--space-5); border-top: 1px solid var(--border-subtle);
}
.df-kpi__item:first-child { border-top: none; padding-top: var(--space-2); }
.df-kpi__value {
  font-family: var(--danifo-font-display); font-weight: 900;
  font-size: clamp(34px, 4.2vw, 52px); line-height: 1; color: var(--text-primary);
}
.df-kpi__unit { color: var(--text-primary); }   /* navy — unit reads as part of the numeral */
.df-kpi__label {
  font-family: var(--danifo-font-body); font-size: var(--ts-body);
  line-height: var(--lh-body); color: var(--text-secondary);
}
@media (max-width: 560px) {
  .df-kpi__item { grid-template-columns: 1fr; gap: var(--space-2); }
}

/* ---- df-stat (index effect row) — value+unit navy, orange rule accent -- */
.df-stat { display: flex; flex-direction: column; gap: var(--space-3); }
.df-stat__rule { width: 40px; height: 4px; border-radius: 2px; background: var(--action-default); }
.df-stat__value {
  font-family: var(--danifo-font-display); font-weight: 900;
  font-size: clamp(38px, 4.4vw, 58px); line-height: 1; color: var(--text-primary);
}
.df-stat__unit { font-size: 0.5em; }   /* navy, smaller — reads as part of the numeral */
.df-stat__label {
  font-family: var(--danifo-font-body); font-size: var(--ts-body);
  line-height: var(--lh-body); color: var(--text-secondary); max-width: 30ch;
}
.stats-note { margin-top: var(--space-6); font-size: var(--ts-small); line-height: var(--lh-small); color: var(--text-secondary); max-width: var(--measure); }

/* ---- df-features (transformed feature-list) --------------------------- */
.df-features { display: flex; flex-direction: column; gap: var(--space-3); max-width: var(--measure); }
.df-features li {
  display: grid; grid-template-columns: 1.6em 1fr; gap: var(--space-3);
  align-items: start; font-size: var(--ts-body); line-height: var(--lh-body);
  color: var(--text-primary);
}
.df-features .icon { width: 1.5em; height: 1.5em; color: var(--action-default); margin-top: 0.12em; }

/* ---- highlight-box ---------------------------------------------------- */
.highlight-box {
  display: grid; grid-template-columns: auto 1fr; gap: var(--space-4);
  align-items: start; max-width: var(--measure);
  background: var(--surface-purple-soft);
  border-left: 4px solid var(--action-default);
  border-radius: var(--radius-md);
  padding: var(--space-5);
}
.highlight-box .icon { width: 30px; height: 30px; color: var(--action-default); margin-top: 0.1em; }
.highlight-box p { font-size: var(--ts-body); line-height: var(--lh-body); color: var(--text-primary); }
.highlight-box p + p { margin-top: var(--space-3); }
.highlight-box--full { max-width: none; }

/* ---- ba: связанные строки «Было → Стало» ----------------------------- */
.ba { display: flex; flex-direction: column; gap: var(--space-4); }
.ba__head, .ba__row {
  display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  gap: var(--space-4); align-items: stretch;
}
.ba__label {
  font-family: var(--danifo-font-display); font-weight: 900;
  font-size: var(--ts-small); text-transform: uppercase; letter-spacing: 0.06em;
}
.ba__label--bad { color: var(--color-danger); }
.ba__label--good { color: var(--color-success); }
.ba__cell {
  display: grid; grid-template-columns: 1.5em 1fr; gap: var(--space-3);
  align-items: start; padding: var(--space-4);
  background: var(--surface-default); border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  font-size: var(--ts-body); line-height: var(--lh-body); color: var(--text-primary);
}
.ba__icon { width: 1.5em; height: 1.5em; margin-top: 0.1em; }
.ba__icon--bad { color: var(--color-danger); }
.ba__icon--good { color: var(--color-success); }
.ba__arrow { width: 28px; height: 28px; color: var(--text-secondary); align-self: center; justify-self: center; }
@media (max-width: 620px) {
  .ba__head { display: none; }
  .ba__row { grid-template-columns: minmax(0, 1fr); gap: var(--space-3); }
  .ba__arrow { transform: rotate(90deg); justify-self: start; }
}

/* ---- df-foot ---------------------------------------------------------- */
.df-foot {
  display: flex; align-items: center; justify-content: space-between;
  gap: var(--space-4);
  padding: var(--space-5) clamp(20px, 4vw, 48px);
  border-top: 1px solid var(--border-subtle);
  font-family: var(--danifo-font-body); font-weight: 700;
  font-size: var(--ts-foot); letter-spacing: 0.05em; text-transform: uppercase;
  color: var(--text-secondary);
}
.df-foot__brand { display: inline-flex; align-items: center; gap: var(--space-2); }
.df-foot__page { color: var(--text-primary); }

/* ============================================================================
   INFOGRAPHICS (hand-built, no charting libs)
   ============================================================================ */
.ig { margin-top: var(--space-6); }
.ig__title {
  font-family: var(--danifo-font-display); font-weight: 900;
  font-size: var(--ts-h3); color: var(--text-primary); margin: 0 0 var(--space-5) 0;
}
.band--navy .ig__title { color: #fff; }
.ig__note { margin-top: var(--space-4); font-size: var(--ts-small); line-height: var(--lh-small); color: var(--text-secondary); max-width: var(--measure); }
.band--navy .ig__note { color: rgba(255, 255, 255, 0.7); }

/* shared list with leading orange check (vectors, etc.) */
.ig-list { display: flex; flex-direction: column; gap: var(--space-3); }
.ig-list li { display: grid; grid-template-columns: 1.5em 1fr; gap: var(--space-3); align-items: start; font-size: var(--ts-body); line-height: var(--lh-body); }
.ig-list__icon { width: 1.5em; height: 1.5em; color: var(--action-default); margin-top: 0.1em; }

/* ---- Bars: compression (A) + manual-vs-AI ----------------------------- */
.ig-bars { display: flex; flex-direction: column; gap: var(--space-4); }
.ig-bars__row {
  display: grid; grid-template-columns: minmax(72px, auto) 1fr minmax(96px, auto);
  gap: var(--space-3) var(--space-4); align-items: center;
}
.ig-bars__label {
  font-family: var(--danifo-font-body); font-weight: 700; font-size: var(--ts-small);
  text-transform: uppercase; letter-spacing: 0.06em; color: var(--text-secondary);
}
.ig-bars__track {
  height: 46px; border-radius: var(--radius-pill); overflow: hidden;
  background: #fff; box-shadow: inset 0 0 0 1.5px var(--border-subtle);
}
.ig-bars__fill { height: 100%; border-radius: var(--radius-pill); transition: width var(--duration-slow) var(--ease-emphasized); }
.ig-bars__fill--navy { background: var(--surface-navy); }
.ig-bars__fill--orange { background: var(--action-default); }
.ig-bars__val {
  font-family: var(--danifo-font-display); font-weight: 900;
  font-size: var(--ts-h3); color: var(--text-primary); text-align: right; white-space: nowrap;
}
.ig-bars__arrow { display: flex; justify-content: center; }   /* flex parent — grid props were inert */
.ig-bars__arrow .icon { width: 28px; height: 28px; color: var(--action-default); }
@media (max-width: 560px) {
  .ig-bars__row { grid-template-columns: 1fr auto; }
  .ig-bars__track { grid-column: 1 / -1; order: 3; }
}

/* ---- Split diagram (B) ------------------------------------------------ */
.ig-split { display: flex; flex-direction: column; align-items: center; gap: var(--space-4); }
.ig-split__source {
  font-family: var(--danifo-font-display); font-weight: 900; font-size: var(--ts-h3);
  color: var(--text-primary); background: var(--surface-default);
  border: 2px solid var(--border-strong); border-radius: var(--radius-pill);
  padding: var(--space-3) var(--space-6); text-align: center;
}
.ig-split__arrows { display: grid; grid-template-columns: 1fr 1fr; width: min(560px, 86%); }
.ig-split__arrows .icon { width: 30px; height: 30px; color: var(--action-default); justify-self: center; }
.ig-split__panels { display: grid; grid-template-columns: 1fr auto 1fr; gap: var(--space-4); align-items: stretch; width: 100%; }
.ig-split__panel {
  background: var(--surface-default); border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg); padding: var(--space-5);
  display: flex; flex-direction: column; gap: var(--space-4);
}
.ig-split__title { font-family: var(--danifo-font-display); font-weight: 900; font-size: var(--ts-h3); color: var(--text-primary); }
.ig-split__plus {
  align-self: center; display: flex; align-items: center; justify-content: center;
  width: 52px; height: 52px; border-radius: 50%; background: var(--action-default); flex: none;
}
.ig-split__plus .icon { width: 28px; height: 28px; color: #fff; }
@media (max-width: 720px) {
  .ig-split__panels { grid-template-columns: 1fr; }
  .ig-split__plus { width: 44px; height: 44px; }
  .ig-split__arrows { width: 60%; }
}

/* ---- Roadmap timeline (C) — on navy ----------------------------------- */
.ig-timeline__track {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-5);
  position: relative;
}
.ig-timeline__track::before {
  content: ""; position: absolute; left: 4%; right: 4%; top: 11px; height: 2px;
  background: var(--action-default); opacity: 0.55;
}
.ig-timeline__phase { position: relative; display: flex; flex-direction: column; gap: var(--space-3); }
.ig-timeline__node {
  width: 22px; height: 22px; border-radius: 50%;
  background: var(--action-default); border: 4px solid var(--surface-navy);
  position: relative; z-index: 1;
}
.ig-timeline__card {
  display: flex; flex-direction: column; gap: var(--space-2);
  border: 1px solid rgba(255, 255, 255, 0.18); border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.04); padding: var(--space-4);
}
.ig-timeline__tag {
  font-family: var(--danifo-font-body); font-weight: 700; font-size: var(--ts-small);
  letter-spacing: 0.08em; text-transform: uppercase; color: var(--action-default);
}
.ig-timeline__name { font-family: var(--danifo-font-display); font-weight: 900; font-size: var(--ts-h3); color: #fff; }
.ig-timeline__when { font-size: var(--ts-small); color: rgba(255, 255, 255, 0.7); margin-bottom: var(--space-2); }
.ig-timeline__card .ig-list li { color: rgba(255, 255, 255, 0.92); font-size: var(--ts-small); }
.ig-timeline__ruler {
  display: flex; justify-content: space-between; margin-top: var(--space-5);
  font-size: var(--ts-small); color: rgba(255, 255, 255, 0.6);
}
@media (max-width: 760px) {
  .ig-timeline__track { grid-template-columns: 1fr; gap: var(--space-6); }
  .ig-timeline__track::before { display: none; }
  .ig-timeline__ruler { display: none; }
}

/* ---- Maturity bars (D) — on gray -------------------------------------- */
.ig-maturity { display: flex; flex-direction: column; gap: var(--space-4); }
.ig-maturity__row {
  display: grid; grid-template-columns: minmax(130px, 220px) 1fr auto;
  gap: var(--space-4); align-items: center;
}
.ig-maturity__label { font-family: var(--danifo-font-body); font-weight: 700; font-size: var(--ts-body); color: var(--text-primary); }
.ig-maturity__bar { display: grid; grid-template-columns: repeat(5, 1fr); gap: var(--space-2); }
.ig-maturity__bar .seg {
  height: 20px; border-radius: var(--radius-sm);
  background: #fff; box-shadow: inset 0 0 0 1px rgba(41, 37, 106, 0.18);
}
.ig-maturity__bar .seg.is-on { background: var(--surface-navy); box-shadow: none; }
.ig-maturity__bar .seg.is-on.is-gap { background: var(--action-default); }
.ig-maturity__score { font-family: var(--danifo-font-display); font-weight: 900; font-size: var(--ts-h3); color: var(--text-primary); }
.ig-maturity__tag { font-size: var(--ts-small); color: var(--text-secondary); grid-column: 1 / -1; margin-top: calc(-1 * var(--space-2)); }
@media (max-width: 620px) {
  .ig-maturity__row { grid-template-columns: 1fr auto; }
  .ig-maturity__bar { grid-column: 1 / -1; order: 3; }
}

/* ---- Cycle / flow (flywheel, referral) -------------------------------- */
.ig-cycle { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-3); }
.ig-cycle__node {
  background: var(--surface-default); border: 1.5px solid var(--border-strong);
  border-radius: var(--radius-pill); padding: var(--space-3) var(--space-4);
  font-family: var(--danifo-font-body); font-weight: 700; font-size: var(--ts-small);
  color: var(--text-primary); text-align: center;
}
.ig-cycle__node--accent { border-color: var(--action-default); }
.ig-cycle__arrow { width: 26px; height: 26px; color: var(--action-default); flex: none; }
.ig-cycle__loop {
  margin-top: var(--space-4); display: flex; align-items: center; gap: var(--space-2);
  font-size: var(--ts-small); color: var(--text-secondary);
  border-top: 2px dashed var(--border-subtle); padding-top: var(--space-3);
}
.ig-cycle__loop .icon { width: 1.2em; height: 1.2em; color: var(--action-default); }

/* ---- Mock card (02-crm) ----------------------------------------------- */
.ig-card {
  background: var(--surface-default); border: 2px solid var(--border-strong);
  border-radius: var(--radius-lg); padding: var(--space-5); max-width: 580px;
}
.ig-card__head {
  display: flex; align-items: center; gap: var(--space-3);
  padding-bottom: var(--space-3); margin-bottom: var(--space-4);
  border-bottom: 1px solid var(--border-subtle);
}
.ig-card__head .icon { width: 30px; height: 30px; color: var(--action-default); }
.ig-card__head span { font-family: var(--danifo-font-display); font-weight: 900; font-size: var(--ts-h3); color: var(--text-primary); }
.ig-card__fields { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-4); }
.ig-card__fields > div { display: flex; flex-direction: column; gap: 2px; }
.ig-card__fields dt {
  font-family: var(--danifo-font-body); font-weight: 700; font-size: var(--ts-small);
  text-transform: uppercase; letter-spacing: 0.05em; color: var(--text-secondary);
}
.ig-card__fields dd { margin: 0; font-size: var(--ts-body); color: var(--text-primary); }
.ig-card__channels {
  display: flex; flex-wrap: wrap; gap: var(--space-2);
  margin-top: var(--space-5); padding-top: var(--space-4); border-top: 1px solid var(--border-subtle);
}
.chip {
  display: inline-flex; align-items: center; gap: var(--space-2);
  background: var(--surface-purple-soft); border-radius: var(--radius-pill);
  padding: var(--space-2) var(--space-3);
  font-family: var(--danifo-font-body); font-weight: 700; font-size: var(--ts-small);
  color: var(--text-primary);
}
.chip .icon { width: 1.15em; height: 1.15em; color: var(--action-default); }
@media (max-width: 480px) { .ig-card__fields { grid-template-columns: 1fr; } }

/* ---- Day timeline (03-followup) --------------------------------------- */
.ig-days { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-5); position: relative; }
.ig-days::before { content: ""; position: absolute; left: 6%; right: 6%; top: 10px; height: 2px; background: var(--action-default); opacity: 0.5; }
.ig-days__stop { position: relative; display: flex; flex-direction: column; gap: var(--space-2); }
.ig-days__node { width: 20px; height: 20px; border-radius: 50%; background: var(--action-default); border: 3px solid #fff; box-shadow: 0 0 0 1px var(--border-subtle); }
.ig-days__when { font-family: var(--danifo-font-display); font-weight: 900; font-size: var(--ts-h3); color: var(--text-primary); }
.ig-days__desc { font-size: var(--ts-small); line-height: var(--lh-small); color: var(--text-secondary); }
@media (max-width: 700px) {
  .ig-days { grid-template-columns: 1fr; }
  .ig-days::before { display: none; }
}

/* ---- Funnel (04-visualization) ---------------------------------------- */
.ig-funnel { display: flex; flex-direction: column; align-items: center; gap: var(--space-2); }
.ig-funnel__tier {
  width: var(--w, 100%); max-width: 640px; min-height: 66px;
  display: flex; align-items: center; justify-content: center; text-align: center;
  padding: var(--space-3) var(--space-5);
  color: #fff; font-family: var(--danifo-font-body); font-weight: 700; font-size: var(--ts-body);
  clip-path: polygon(7% 0, 93% 0, 84% 100%, 16% 100%);
}
.ig-funnel__tier:nth-of-type(1) { background: #29256A; }
.ig-funnel__tier:nth-of-type(2) { background: #3a3585; }
.ig-funnel__tier:nth-of-type(3) { background: #4d4799; }
.ig-funnel__tier strong { color: #fff; }
.ig-funnel__arrow { width: 26px; height: 26px; color: var(--action-default); }

/* ---- Competency matrix (05-knowledge) --------------------------------- */
.ig-matrix-wrap { overflow-x: auto; }
.ig-matrix { border-collapse: separate; border-spacing: var(--space-2); min-width: 460px; }
.ig-matrix th {
  font-family: var(--danifo-font-body); font-weight: 700; font-size: var(--ts-small);
  color: var(--text-primary); text-align: left; padding: var(--space-2); white-space: nowrap;
}
.ig-matrix thead th { text-align: center; color: var(--text-secondary); }
.ig-matrix tbody th { color: var(--text-primary); }
.ig-matrix td {
  width: 52px; height: 42px; border-radius: var(--radius-sm); text-align: center; vertical-align: middle;
}
.ig-matrix td .icon { width: 18px; height: 18px; color: #fff; display: inline-block; vertical-align: middle; }
.ig-matrix td.g { background: #2e9e5b; }
.ig-matrix td.y { background: #e3a92b; }
.ig-matrix td.r { background: #cf4b5d; }
.ig-matrix td.y .icon { color: var(--text-primary); }
.ig-legend { display: flex; flex-wrap: wrap; gap: var(--space-4); margin-top: var(--space-4); }
.ig-legend li { display: flex; align-items: center; gap: var(--space-2); font-size: var(--ts-small); color: var(--text-secondary); }
.ig-legend .sw { width: 18px; height: 18px; border-radius: 4px; flex: none; }
.ig-legend .sw.g { background: #2e9e5b; }
.ig-legend .sw.y { background: #e3a92b; }
.ig-legend .sw.r { background: #cf4b5d; }
.ig-legend .sw.navy { background: var(--surface-navy); }
.ig-legend .sw.orange { background: var(--action-default); }

/* ---- 24/7 ring (06-ecommerce) ----------------------------------------- */
.ig-availability { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-7); }
.ig-ring-wrap { position: relative; width: min(280px, 78vw); flex: none; }
.ig-ring { width: 100%; height: auto; display: block; }
.ig-ring__bg { fill: none; stroke: var(--action-default); stroke-width: 22; }
.ig-ring__seg {
  fill: none; stroke: var(--surface-navy); stroke-width: 22;
  stroke-dasharray: 181 322; stroke-linecap: butt;
  transform: rotate(-90deg); transform-origin: 100px 100px;
}
.ig-ring-wrap__center { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.ig-ring-wrap__big { font-family: var(--danifo-font-display); font-weight: 900; font-size: clamp(30px, 6vw, 42px); color: var(--text-primary); line-height: 1; }
.ig-ring-wrap__small { font-family: var(--danifo-font-body); font-weight: 700; font-size: var(--ts-small); text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-secondary); margin-top: var(--space-1); }
.ig-availability__legend { display: flex; flex-direction: column; gap: var(--space-3); }

/* ---- approach: our column highlighted with an orange rule ------------- */
.approach--ours { box-shadow: inset 0 0 0 2px var(--action-default); }

/* ---- AI-OS centerpiece (D) — on navy ---------------------------------- */
.ig-aios {
  margin-top: var(--space-6);
  display: flex; flex-direction: column; align-items: center; gap: var(--space-4);
  width: 100%;
}
.ig-aios__cap {
  font-family: var(--danifo-font-body); font-weight: 700; font-size: var(--ts-small);
  text-transform: uppercase; letter-spacing: 0.08em;
  color: rgba(255, 255, 255, 0.7); text-align: center;
}
.ig-aios__agents {
  display: flex; flex-wrap: wrap; justify-content: center; gap: var(--space-3);
  width: 100%;
}
.ig-aios__agent {
  display: inline-flex; align-items: center; gap: var(--space-2);
  padding: var(--space-2) var(--space-4); border-radius: var(--radius-pill);
  border: 1.5px solid var(--action-default); background: rgba(255, 255, 255, 0.04);
  font-family: var(--danifo-font-body); font-weight: 700; font-size: var(--ts-small);
  color: #fff;
}
.ig-aios__agent .icon { width: 18px; height: 18px; color: var(--action-default); flex: none; }
.ig-aios__flow {
  display: flex; justify-content: space-between; width: min(520px, 80%);
}
.ig-aios__flow .icon { width: 26px; height: 26px; color: var(--action-default); opacity: 0.7; }
.ig-aios__core {
  display: flex; flex-direction: column; align-items: center; gap: var(--space-1);
  width: min(560px, 100%); text-align: center;
  padding: var(--space-5) var(--space-6);
  border: 2px solid var(--action-default); border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.05);
}
.ig-aios__core-title {
  font-family: var(--danifo-font-display); font-weight: 900; font-size: var(--ts-h3); color: #fff;
}
.ig-aios__core-sub {
  font-family: var(--danifo-font-body); font-size: var(--ts-small); color: rgba(255, 255, 255, 0.7);
}
.ig-aios__domains {
  display: flex; flex-wrap: wrap; justify-content: center; gap: var(--space-2);
  width: min(720px, 100%);
}
.ig-aios__chip {
  padding: var(--space-2) var(--space-3); border-radius: var(--radius-pill);
  border: 1px solid rgba(255, 255, 255, 0.22); background: transparent;
  font-family: var(--danifo-font-body); font-weight: 600; font-size: var(--ts-small);
  color: rgba(255, 255, 255, 0.9);
}
.ig-aios__systems {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: var(--space-3);
}
.ig-aios__sys {
  padding: var(--space-2) var(--space-4); border-radius: var(--radius-pill);
  border: 1.5px solid rgba(255, 255, 255, 0.3); background: rgba(255, 255, 255, 0.06);
  font-family: var(--danifo-font-body); font-weight: 700; font-size: var(--ts-small);
  text-transform: uppercase; letter-spacing: 0.06em; color: #fff;
}
.ig-aios__link { width: 22px; height: 22px; color: var(--action-default); flex: none; }
.ig-aios__note {
  display: flex; align-items: flex-start; gap: var(--space-3);
  margin-top: var(--space-3); max-width: var(--measure); margin-inline: auto;
  font-size: var(--ts-small); line-height: var(--lh-small); color: rgba(255, 255, 255, 0.7);
}
.ig-aios__note .icon { width: 26px; height: 26px; color: var(--action-default); flex: none; margin-top: 0.05em; }
@media (max-width: 560px) {
  .ig-aios__flow { width: 70%; }
  .ig-aios__systems { flex-direction: column; }
}

/* ============================================================================
   Page-level footer wrap
   ============================================================================ */
.page-foot { margin-top: 0; }
