/* ============================================================
   OCR — Key Technologies page. Layers on top of the shared
   document-verification.css (root .p-document-verification). This
   sheet only adds/overrides what the OCR variant needs, all scoped
   to .p-keytech-ocr. Loaded AFTER document-verification.css.

   Ronda 2 (owner order): OCR = READING a document. Every constructed
   visual speaks that language — the site's canonical ID
   (id-illustrations.svg) scanned by a blue beam, extracted fields
   streaming out to structured data. G13 style throughout: white
   ground, grey skeletons, hairlines, ONE blue accent, discreet chip.
   ============================================================ */

/* ---- shared mock chrome: greppable + unmistakably a mockup ---- */
.p-keytech-ocr .ocr-shot { position: relative; }
.p-keytech-ocr .ocr-shot__chip {
  position: absolute; top: 10px; right: 10px; z-index: 4;
  padding: 2px 8px; border-radius: 999px;
  background: var(--color-placeholder-yellow); color: var(--color-black);
  font-size: 11px; font-weight: 600; line-height: 1.4;
}

/* ---- shared window bar (both read scene + result console) ------------- */
.p-keytech-ocr .ocr-bar {
  display: flex; align-items: center; gap: 9px;
  height: 36px; padding: 0 14px;
  background: var(--color-grey-50); border-bottom: 1px solid var(--color-border-light);
}
.p-keytech-ocr .ocr-bar__lights { display: inline-flex; gap: 5px; }
.p-keytech-ocr .ocr-bar__lights i { width: 7px; height: 7px; border-radius: 50%; background: var(--color-grey-200); }
.p-keytech-ocr .ocr-bar__tab { font-size: 11px; color: var(--color-grey-400); }
.p-keytech-ocr .ocr-bar__done {
  margin-left: auto; display: inline-flex; align-items: center; gap: 6px;
  font-size: 11px; color: var(--color-green-600);
}
.p-keytech-ocr .ocr-bar__done::before {
  content: ""; width: 8px; height: 8px; border-radius: 50%;
  background: var(--color-green-flow); box-shadow: 0 0 0 3px color-mix(in oklab, var(--color-green-flow) 22%, transparent);
}

/* ---- shared green status chiplet -------------------------------------- */
.p-keytech-ocr .ocr-chiplet {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 10px; border-radius: 999px;
  font-size: var(--fs-xs); color: var(--color-green-600);
  background: color-mix(in oklab, var(--color-green-flow) 12%, var(--color-white));
  border: 1px solid color-mix(in oklab, var(--color-green-flow) 30%, var(--color-white));
}
.p-keytech-ocr .ocr-chiplet::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--color-green-flow); }

/* ---- stats band: 3 verified stats now (25% removed, ronda 3) → 3 columns
   so the row stays balanced and one-line at 1440/1280 (G6). ---- */
@media (min-width: 768px) {
  .p-keytech-ocr .dv-stats__grid { grid-template-columns: repeat(3, 1fr); max-width: 960px; margin-inline: auto; gap: 48px; }
}

/* ============================================================
   HERO — EXACT document-verification geometry (owner order 2026-08-03):
   zero inner overrides, so the copy group (pill · title · sub · actions)
   sits pixel-identical to /technology/document-verification/. The read
   scene lives ONLY in the shared .dv-hero__foot band (the DV ID-row box).
   ============================================================ */
.p-keytech-ocr .ocr-hero__copy { display: contents; }

/* ---- the read scene: white console floating on the aurora, centered
   inside the foot band ------------- */
.p-keytech-ocr .ocr-scan {
  width: min(500px, calc(100% - 40px));
  margin-bottom: -48px;
  border-radius: 16px; overflow: hidden;
  background: var(--color-white); border: 1px solid var(--color-border-light);
  box-shadow: none;
}
.p-keytech-ocr .ocr-scan__body {
  display: grid; grid-template-columns: 1.02fr 18px 0.98fr;
  align-items: center; gap: 12px; padding: 16px;
}
/* left: the canonical ID inside a viewfinder, swept by a scan beam */
.p-keytech-ocr .ocr-scan__stage {
  position: relative; overflow: hidden; aspect-ratio: 5 / 4;
  display: grid; place-items: center; padding: 14px 12px;
  border-radius: 12px; background: var(--color-grey-50); border: 1px solid var(--color-border-light);
}
/* ---- canonical ID card (ronda 3): white ground, grey skeleton lines, hairline,
   and the person shown as the site user glyph in a light circular chip — the
   avatar rule replacement for the grey silhouette bust that shipped inside
   id-illustrations.svg. Reused in the hero read-scene AND the output console. -- */
.p-keytech-ocr .ocr-idcard {
  position: relative; width: 100%;
  display: grid; grid-template-columns: auto 1fr;
  grid-template-areas: "photo body" "mrz mrz";
  align-items: center; gap: 10px 12px;
  padding: 13px 14px; border-radius: 10px;
  background: var(--color-white); border: 1px solid var(--color-border-light);
  box-shadow: none;
}
.p-keytech-ocr .ocr-idcard__photo {
  grid-area: photo; width: 40px; height: 40px; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--color-grey-100); color: var(--color-grey-400);
}
.p-keytech-ocr .ocr-idcard__photo svg { width: 24px; height: 24px; }
.p-keytech-ocr .ocr-idcard__body { grid-area: body; display: grid; gap: 6px; }
.p-keytech-ocr .ocr-idcard__line { height: 6px; border-radius: 999px; background: var(--color-grey-200); }
.p-keytech-ocr .ocr-idcard__line--head { width: 58%; background: var(--color-grey-300); }
.p-keytech-ocr .ocr-idcard__line--short { width: 74%; }
.p-keytech-ocr .ocr-idcard__mrz { grid-area: mrz; display: grid; gap: 4px; margin-top: 3px; }
.p-keytech-ocr .ocr-idcard__mrz i { height: 5px; border-radius: 3px; background: var(--color-grey-100); }
.p-keytech-ocr .ocr-idcard__mrz i:nth-child(2) { width: 82%; }
/* hero size */
.p-keytech-ocr .ocr-idcard--lg { max-width: 200px; padding: 15px 16px; }
.p-keytech-ocr .ocr-idcard--lg .ocr-idcard__photo { width: 44px; height: 44px; }
.p-keytech-ocr .ocr-idcard--lg .ocr-idcard__photo svg { width: 26px; height: 26px; }
/* output-thumbnail size (no MRZ row) */
.p-keytech-ocr .ocr-idcard--xs { gap: 6px; padding: 7px 8px; border-radius: 7px; box-shadow: none; }
.p-keytech-ocr .ocr-idcard--xs .ocr-idcard__photo { width: 20px; height: 20px; }
.p-keytech-ocr .ocr-idcard--xs .ocr-idcard__photo svg { width: 13px; height: 13px; }
.p-keytech-ocr .ocr-idcard--xs .ocr-idcard__line { height: 4px; }
.p-keytech-ocr .ocr-scan__corner { position: absolute; width: 15px; height: 15px; border: 2px solid var(--color-blue-500); }
.p-keytech-ocr .ocr-scan__corner--tl { top: 8px; left: 8px; border-right: 0; border-bottom: 0; border-radius: 5px 0 0 0; }
.p-keytech-ocr .ocr-scan__corner--tr { top: 8px; right: 8px; border-left: 0; border-bottom: 0; border-radius: 0 5px 0 0; }
.p-keytech-ocr .ocr-scan__corner--bl { bottom: 8px; left: 8px; border-right: 0; border-top: 0; border-radius: 0 0 0 5px; }
.p-keytech-ocr .ocr-scan__corner--br { bottom: 8px; right: 8px; border-left: 0; border-top: 0; border-radius: 0 0 5px 0; }
.p-keytech-ocr .ocr-scan__beam {
  position: absolute; left: 8px; right: 8px; top: 12%; height: 2px; border-radius: 2px;
  background: var(--color-blue-500);
  box-shadow: none;
  animation: ocr-beam 2.8s var(--ease-out-expo) infinite;
}
@keyframes ocr-beam { 0% { top: 12%; opacity: 0; } 12% { opacity: 1; } 50% { top: 82%; opacity: 1; } 64%, 100% { top: 82%; opacity: 0; } }
.p-keytech-ocr .ocr-scan__flow { display: grid; place-items: center; color: var(--color-grey-300); }
/* right: extracted fields stream out, staggered */
.p-keytech-ocr .ocr-scan__fields { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 11px; }
.p-keytech-ocr .ocr-scan__field {
  display: grid; grid-template-columns: 1fr 16px; grid-template-areas: "label label" "val tick";
  gap: 4px 8px; align-items: center;
  animation: ocr-fieldin 0.5s var(--ease-out-expo) both; animation-delay: calc(var(--i) * 0.12s + 0.35s);
}
@keyframes ocr-fieldin { from { opacity: 0; transform: translateX(8px); } to { opacity: 1; transform: none; } }
.p-keytech-ocr .ocr-scan__flabel { grid-area: label; font-size: 10px; color: var(--color-grey-400); }
.p-keytech-ocr .ocr-scan__fval { grid-area: val; height: 9px; border-radius: 999px; background: var(--color-grey-100); }
.p-keytech-ocr .ocr-scan__ftick {
  grid-area: tick; display: grid; place-items: center; width: 16px; height: 16px; border-radius: 999px;
  background: var(--color-blue-100); color: var(--color-blue-500);
}
@media (max-width: 460px) {
  .p-keytech-ocr .ocr-scan__body { grid-template-columns: 1fr; }
  .p-keytech-ocr .ocr-scan__flow { display: none; }
}

/* ============================================================
   PROBLEM (dv-threat) — retune the shared red aurora to a neutral
   BLUE for OCR (it's a data-extraction problem, not a fraud threat).
   ============================================================ */
.p-keytech-ocr .dv-threat::before {
  background: radial-gradient(900px 480px at 50% -10%, color-mix(in oklab, var(--color-blue-500) 18%, transparent), transparent 60%);
}
.p-keytech-ocr .dv-kicker--threat { color: var(--color-blue-200); }
.p-keytech-ocr .dv-threat__type:hover { border-color: color-mix(in oklab, var(--color-blue-500) 45%, transparent); }
.p-keytech-ocr .dv-threat__type-num { color: var(--color-blue-200); }
.p-keytech-ocr .dv-threat__value {
  background: linear-gradient(90deg, var(--color-white) 34%, var(--color-blue-500) 100%);
  -webkit-background-clip: text; background-clip: text;
}
/* two problem stat slots carry short verified text, not big numbers */
.p-keytech-ocr .dv-threat__value--text { font-size: clamp(28px, 3.4vw, 42px); line-height: 1.05; }

/* ============================================================
   THE OUTPUT — light section: copy left, dashboard result console right
   ============================================================ */
.p-keytech-ocr .ocr-output { background: var(--color-white); border-top: 1px solid var(--color-border-light); }
.p-keytech-ocr .ocr-output__grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 40px; }
@media (min-width: 1024px) {
  .p-keytech-ocr .ocr-output__grid { grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); gap: 64px; align-items: center; }
}
.p-keytech-ocr .ocr-output__points { margin-top: 28px; display: flex; flex-direction: column; gap: 18px; }
.p-keytech-ocr .ocr-output__point { display: grid; grid-template-columns: auto 1fr; gap: 14px; }
.p-keytech-ocr .ocr-output__icon {
  width: 38px; height: 38px; border-radius: var(--radius-md); display: grid; place-items: center;
  background: var(--color-blue-100); color: var(--color-blue-500);
}
.p-keytech-ocr .ocr-output__icon .ds-icon { width: 20px; height: 20px; }
.p-keytech-ocr .ocr-output__pname { display: block; font-family: var(--font-display); font-weight: 500; font-size: var(--fs-xl); color: var(--color-black); }
.p-keytech-ocr .ocr-output__pline { display: block; margin-top: 3px; font-size: var(--fs-sm); line-height: 1.55; color: var(--color-grey-on-white); }

/* ------------------------------------------------------------------
   OUTPUT VISUAL — Single Session dashboard window (STATIC, page-scoped
   oco-*). Shares the light browser-window template with liveness-detection
   / deepfake-detection (chrome → de-emphasised nav → app head with a green
   Pass pill + muted Session ID → body: a schematic DOCUMENT tile left, the
   validation checks as hairline label · pill rows right). Tokens only; the
   one amber Warn pill uses --color-amber-100/600.
   ------------------------------------------------------------------ */
.p-keytech-ocr .oco-deck {
  position: relative; display: flex; flex-direction: column;
  width: min(100%, 560px); margin-inline: auto;
  border-radius: 14px; border: 1px solid var(--color-border-light);
  background: var(--color-white); box-shadow: none; overflow: hidden;
}
/* browser chrome now comes from the canonical BrowserChrome component
   (components/browser-chrome.css) — the bespoke .oco-chrome CSS was removed */
/* the dashboard inside the window: de-emphasised nav + main */
.p-keytech-ocr .oco-app { display: flex; align-items: stretch; min-height: 260px; }
.p-keytech-ocr .oco-appnav {
  flex-shrink: 0; width: 108px; display: flex; flex-direction: column; gap: 15px; padding: 18px 12px;
  background: var(--color-grey-50); border-right: 1px solid var(--color-grey-100);
}
.p-keytech-ocr .oco-appnav__line { height: 7px; border-radius: 999px; background: var(--color-grey-200); }
.p-keytech-ocr .oco-appmain { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.p-keytech-ocr .oco-apphead {
  display: flex; align-items: center; gap: 10px; height: 44px; padding: 0 20px;
  border-bottom: 1px solid var(--color-grey-100); flex-shrink: 0;
}
.p-keytech-ocr .oco-apphead__pass {
  padding: 4px 12px; border-radius: 999px; background: var(--color-green-100); color: var(--color-green-600);
  font-size: 12px; font-weight: 600;
}
.p-keytech-ocr .oco-apphead__sid { font-size: 12px; font-weight: 500; color: var(--color-grey-400); }
.p-keytech-ocr .oco-body { display: flex; align-items: stretch; flex: 1; min-width: 0; }
/* document tile (left): a schematic ID — blue header bar + grey lines */
.p-keytech-ocr .oco-doc {
  flex-shrink: 0; display: flex; align-items: flex-start; justify-content: center;
  padding: 18px 20px; border-right: 1px solid var(--color-grey-100);
}
.p-keytech-ocr .oco-doc__tile {
  width: 132px; padding: 12px; display: flex; flex-direction: column; gap: 9px;
  border-radius: 10px; background: var(--color-white); border: 1px solid var(--color-grey-100);
  box-shadow: none;
}
.p-keytech-ocr .oco-doc__bar {
  height: 26px; border-radius: 6px; background: var(--color-blue-100);
  border: 1px solid color-mix(in oklab, var(--color-blue-500) 22%, transparent);
}
.p-keytech-ocr .oco-doc__line { height: 7px; border-radius: 999px; background: var(--color-grey-200); }
.p-keytech-ocr .oco-doc__line--short { width: 66%; }
/* checks (right): head + hairline label · pill rows */
.p-keytech-ocr .oco-checks { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 12px; padding: 18px 20px; }
.p-keytech-ocr .oco-head {
  display: flex; align-items: center; gap: 8px; font-size: var(--fs-sm); font-weight: 600; color: var(--color-grey-on-white);
}
.p-keytech-ocr .oco-head .ds-icon { width: 18px; height: 18px; color: var(--color-grey-400); }
.p-keytech-ocr .oco-table { display: flex; flex-direction: column; }
.p-keytech-ocr .oco-trow {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 12px;
  padding: 12px 0; border-bottom: 1px solid var(--color-border-light);
}
.p-keytech-ocr .oco-trow:last-child { border-bottom: 0; }
.p-keytech-ocr .oco-trow__lbl { font-size: 12px; font-weight: 500; color: var(--color-grey-500); }
.p-keytech-ocr .oco-pill {
  white-space: nowrap; justify-self: end; font-size: 10px; font-weight: 600; line-height: 1.5;
  padding: 3px 9px; border-radius: 999px;
}
.p-keytech-ocr .oco-pill--good { background: var(--color-green-100); color: var(--color-green-600); }
.p-keytech-ocr .oco-pill--warn { background: var(--color-amber-100); color: var(--color-amber-600); }
/* footer chips */
.p-keytech-ocr .oco-row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-top: auto; }
.p-keytech-ocr .oco-chip {
  padding: 3px 10px; border-radius: 999px; background: var(--color-grey-100); color: var(--color-grey-on-white);
  font-size: var(--fs-xs); font-weight: 600;
}
.p-keytech-ocr .oco-chip--accent { background: color-mix(in oklab, var(--color-blue-500) 14%, transparent); color: var(--color-blue); }
/* mobile: the deck no longer reflows — dashFit (site.js, data-dash-fit on
   .oco-deck) renders the exact 560px desktop layout scaled down to the
   column, so the doc tile stays BESIDE the checks exactly as on desktop */

/* the result console */
.p-keytech-ocr .ocr-panel {
  border-radius: 18px; overflow: hidden;
  background: var(--color-white); border: 1px solid var(--color-border-light);
  box-shadow: none;
}
.p-keytech-ocr .ocr-panel__body { padding: 20px 22px 22px; }
.p-keytech-ocr .ocr-panel__head { display: flex; align-items: center; gap: 14px; padding-bottom: 16px; border-bottom: 1px solid var(--color-border-light); }
.p-keytech-ocr .ocr-panel__thumb { flex: 0 0 auto; width: 66px; display: block; }
.p-keytech-ocr .ocr-panel__htext { display: flex; flex-direction: column; gap: 3px; }
.p-keytech-ocr .ocr-panel__htitle { font-family: var(--font-display); font-weight: 500; font-size: var(--fs-body); color: var(--color-black); }
.p-keytech-ocr .ocr-panel__hsub { font-size: var(--fs-xs); color: var(--color-grey-400); }

.p-keytech-ocr .ocr-panel__fields { list-style: none; margin: 16px 0 0; padding: 0; display: grid; gap: 14px; }
.p-keytech-ocr .ocr-frow { display: grid; grid-template-columns: 116px 1fr auto; align-items: center; gap: 14px; }
.p-keytech-ocr .ocr-frow__label { font-size: var(--fs-xs); color: var(--color-grey-400); }
.p-keytech-ocr .ocr-frow__val { height: 11px; width: var(--w, 70%); border-radius: 999px; background: var(--color-grey-100); }
.p-keytech-ocr .ocr-frow__conf { display: inline-flex; align-items: center; gap: 9px; }
.p-keytech-ocr .ocr-frow__meter { width: 44px; height: 5px; border-radius: 999px; background: var(--color-grey-100); overflow: hidden; }
.p-keytech-ocr .ocr-frow__meter::after { content: ""; display: block; height: 100%; width: var(--c, 90%); border-radius: 999px; background: var(--color-blue-500); }
.p-keytech-ocr .ocr-frow__tick { display: grid; place-items: center; width: 16px; height: 16px; border-radius: 999px; background: var(--color-blue-100); color: var(--color-blue-500); }

.p-keytech-ocr .ocr-panel__mrz {
  margin-top: 18px; padding: 12px 14px; border-radius: 10px;
  background: var(--color-grey-50); border: 1px solid var(--color-border-light);
  display: flex; flex-direction: column; gap: 6px;
}
.p-keytech-ocr .ocr-mrz__line {
  font-family: var(--font-display); font-weight: 500; font-size: var(--fs-xs);
  letter-spacing: 0; color: var(--color-grey-400); font-variant-numeric: tabular-nums;
  white-space: nowrap; overflow: hidden; text-overflow: clip;
}
.p-keytech-ocr .ocr-mrz__tag { align-self: flex-start; margin-top: 4px; }
.p-keytech-ocr .ocr-panel__chips { margin-top: 16px; display: flex; flex-wrap: wrap; gap: 8px; }

/* ═══════════════════════════════════════════════════════════════
   RECOVERED 2026-08-18 (Sofia: the How-it-works walk rendered raw on
   /technology/ocr/). The single-session card kit + the scroll-pinned
   step-walk styles below shipped in #1256 and were dropped by the #1285
   ocr.css rewrite while the page markup kept referencing them — the deck
   has been unstyled since. Restored verbatim from 8692cf2f6:ocr.css with
   soft shadows neutralized per the 2026-08-17 no-shadows rule.
   ═══════════════════════════════════════════════════════════════ */
/* ---- single-session validation card (at-how deck aesthetic) ----------
   Ported from the use-cases decks (kyc-aml / know-your-business at-how__*)
   and rescoped to .p-keytech-ocr so the key-tech and solution pages read as
   one system. Static single screen (no stepper). It is the OUTPUT column's
   single visual: the document-validation results of one OCR read.
   Head = icon + surface label; rows = status dot + real check name + status
   pill; the OK/WARN/FAIL status vocabulary and every check label come verbatim
   from the dashboard (singleSession.idVerification*Tests + overallStatus,
   ms-incode-dashboard develop-AI-clean, src/locales/en.json). */
.p-keytech-ocr .ocr-output__visuals { display: flex; flex-direction: column; gap: 20px; }

.p-keytech-ocr .at-how__deck {
  display: flex; flex-direction: column;
  border-radius: 16px; overflow: hidden;
  border: 1px solid var(--color-border-light);
  background: var(--color-white);
  box-shadow: none;
}
.p-keytech-ocr .at-how__screen { display: flex; flex-direction: column; gap: 14px; padding: 22px; }
.p-keytech-ocr .at-how__head {
  display: flex; align-items: center; gap: 8px;
  font-size: var(--fs-sm); font-weight: 600; color: var(--color-grey-on-white);
}
.p-keytech-ocr .at-how__head .ds-icon { width: 18px; height: 18px; color: var(--color-grey-400); }

.p-keytech-ocr .at-how__audit { display: flex; flex-direction: column; gap: 7px; }
.p-keytech-ocr .at-how__audit-row {
  display: flex; align-items: center; gap: 9px;
  padding: 9px 12px; border-radius: 10px;
  border: 1px solid var(--color-border-light); background: var(--color-white);
}
.p-keytech-ocr .at-how__audit-row > span {
  flex: 1; min-width: 0; overflow: hidden; white-space: nowrap; text-overflow: ellipsis;
  font-size: var(--fs-xs); font-weight: 500; color: var(--color-grey-600);
}
.p-keytech-ocr .at-how__audit-dot { flex: none; width: 8px; height: 8px; border-radius: 50%; background: var(--color-grey-300); }
.p-keytech-ocr .at-how__audit-dot--ok { background: var(--color-green-500); }
.p-keytech-ocr .at-how__audit-dot--warn { background: var(--color-amber-600); }
.p-keytech-ocr .at-how__audit-dot--flag { background: var(--color-red-500); }
.p-keytech-ocr .at-how__audit-pill {
  flex: none; padding: 2px 8px; border-radius: 999px;
  font-size: 9.5px; font-weight: 600;
  background: var(--color-grey-100); color: var(--color-grey-on-white);
}
.p-keytech-ocr .at-how__audit-pill--ok { background: color-mix(in oklab, var(--color-green-500) 13%, transparent); color: var(--color-green-600); }
.p-keytech-ocr .at-how__audit-pill--warn { background: var(--color-amber-100); color: var(--color-amber-600); }
.p-keytech-ocr .at-how__audit-pill--flag { background: color-mix(in oklab, var(--color-red-400) 15%, transparent); color: var(--color-red-500); }

.p-keytech-ocr .at-how__row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-top: 2px; }
.p-keytech-ocr .at-how__pill {
  padding: 3px 10px; border-radius: 999px;
  background: var(--color-grey-100); color: var(--color-grey-on-white);
  font-size: var(--fs-xs); font-weight: 600;
}
.p-keytech-ocr .at-how__pill--accent {
  background: color-mix(in oklab, var(--color-blue-500) 14%, transparent);
  color: var(--color-blue);
}

/* ============================================================
   HOW IT WORKS — SCROLL-PINNED STEP-WALK (2026-08-07). Replaces the
   shared <HowItWorks> for this page: a sol-how__* rail (base styles from
   solution.css — the section sits in a bare .p-solution scope, like
   face-recognition's tech walk) + an at-how__* deck whose illustration
   swaps per step. Driven by the SHARED /js/behaviors/section-walk.js
   ([data-ka-walk] / [data-at-step] / [data-at-screen]). The walk mechanic
   mirrors face-recognition.css's frx-tech, rescoped to
   .p-keytech-ocr .ocr-how; the extra .ocr-how ancestor (0,3,0) beats both
   solution.css's .p-solution .sol-how__* (0,2,0) and this sheet's static
   at-how__deck / at-how__screen (0,2,0, the "Output" card). Every rule
   scoped .p-keytech-ocr .ocr-how; tokens only.
   ============================================================ */

/* rail: jump-free reveal — every description opens to the SAME measured
   height (--at-reveal-h, set by section-walk.js), so the rail's total
   height holds still on step change. Overrides solution.css's 0fr→1fr grid. */
.p-keytech-ocr .ocr-how .sol-how__reveal {
  display: block;
  height: 0;
  overflow: hidden;
  transition: height 0.45s cubic-bezier(0.23, 1, 0.32, 1);
}
.p-keytech-ocr .ocr-how .sol-how__step.is-active .sol-how__reveal {
  height: var(--at-reveal-h, 56px);
}
.p-keytech-ocr .ocr-how .sol-how__line { padding-top: 10px; }

/* scroll-pin walk (wide + motion): the section grows tall and its inner
   pins for the length of the walk, so scroll SELECTS the step. Static
   fallback (narrow / reduced-motion): normal height, pin not sticky. */
.p-keytech-ocr .ocr-how__pin { position: relative; }
.p-keytech-ocr .ocr-how.is-walk {
  height: calc(100svh + 72svh * var(--ka-steps, 5));
}
.p-keytech-ocr .ocr-how.is-walk .ocr-how__pin {
  position: sticky;
  top: 0;
  min-height: 100svh;
  display: flex;
  align-items: center;
}

/* active-step underline. Walk mode: the active bar tracks the in-band scroll
   fraction (--ka-scrub), walked-past steps hold a full bar. Static mode: a
   timed fill matching auto-advance (sol-how-fill keyframes live in
   solution.css). */
.p-keytech-ocr .ocr-how.is-walk .sol-how__step.is-active .sol-how__fill {
  transform: scaleX(var(--ka-scrub, 0));
  transition: transform 0.18s linear;
}
.p-keytech-ocr .ocr-how.is-walk .sol-how__step.is-done .sol-how__fill {
  transform: scaleX(1);
  transition: transform 0.4s ease;
}
.p-keytech-ocr .ocr-how:not(.is-walk) .sol-how__step.is-active .sol-how__fill {
  animation: sol-how-fill var(--sol-hold, 6s) linear forwards;
}
@media (prefers-reduced-motion: reduce) {
  .p-keytech-ocr .ocr-how:not(.is-walk) .sol-how__step.is-active .sol-how__fill { animation: none; }
}

/* the deck — a constant-height slot the stage centers, with a card whose
   height morphs to the active screen (top edge holds still). Overrides the
   static single-screen at-how__deck (the "Output" card) WITHIN this section
   only; the card border / bg / radius / shadow / overflow carry over from the
   base rule above. */
.p-keytech-ocr .ocr-how .at-how__slot {
  width: min(100%, 420px);
  height: var(--at-slot-h, auto);
}
.p-keytech-ocr .ocr-how .at-how__deck {
  position: relative;
  display: grid;
  width: 100%;
  height: var(--at-screen-h, auto);
  transition: height 0.45s cubic-bezier(0.23, 1, 0.32, 1);
}
/* Capture step floats on the gradient stage — strip the deck's white card
   chrome (bg / border / shadow) while the chrome-less capture screen is active */
.p-keytech-ocr .ocr-how .at-how__deck:has(.ocr-scr--capture.is-active) {
  background: transparent;
  border-color: transparent;
  box-shadow: none;
}
.p-keytech-ocr .ocr-how .at-how__screen {
  grid-area: 1 / 1;
  align-self: start;
  min-height: 236px;
  opacity: 0;
  transition: opacity 0.2s ease;
  pointer-events: none;
}
.p-keytech-ocr .ocr-how .at-how__screen.is-active {
  opacity: 1;
  transition: opacity 0.35s ease 0.05s;
}
@media (prefers-reduced-motion: reduce) {
  .p-keytech-ocr .ocr-how .at-how__deck,
  .p-keytech-ocr .ocr-how .at-how__screen,
  .p-keytech-ocr .ocr-how .sol-how__reveal { transition: none; }
}

/* -- deck head status chip (pushed right; green = the result passed) -- */
.p-keytech-ocr .ocr-how .at-how__head .ocr-scr__chip {
  margin-left: auto;
  display: inline-flex; align-items: center; gap: 4px;
  padding: 2px 8px; border-radius: 999px;
  font-size: 9.5px; font-weight: 600; letter-spacing: 0.01em;
  background: color-mix(in oklab, var(--color-green-500) 13%, transparent);
  color: var(--color-green-600);
}
.p-keytech-ocr .ocr-how .ocr-scr__chip svg { width: 11px; height: 11px; }

/* -- 01 · capture — the real guided-capture experience. Reuses the SAME
   snapshot the /technology/document-verification "How it works" Capture step
   renders (/technology/screen-id-capture.jpg): a portrait phone screen with
   "Frame the front of your ID", a live camera frame around a real ID, and an
   "All data is encrypted" footer. The tall phone screenshot is height-capped
   and centered in a grey panel (mirroring the panel the other steps sit on)
   so it reads as an intentional device mock beside the other 4 walk screens
   instead of overflowing the deck. -- */
.p-keytech-ocr .ocr-scr__capshot {
  flex: 1; min-height: 168px;
  display: grid; place-items: center;
  padding: 18px;
  border-radius: 12px;
  background: var(--color-grey-50);
  box-shadow: inset 0 0 0 1px var(--color-border-light);
}
.p-keytech-ocr .ocr-scr__capshot img {
  display: block;
  height: 300px; width: auto; max-width: 100%;
  border-radius: 18px;
  box-shadow: none;
}

/* -- 02 · classify — matched document type + country -- */
.p-keytech-ocr .ocr-scr__match {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 14px; border-radius: 12px;
  border: 1px solid var(--color-border-light); background: var(--color-white);
}
.p-keytech-ocr .ocr-scr__match-glyph {
  flex: none; display: grid; place-items: center; width: 38px; height: 38px;
  border-radius: var(--radius-md);
  background: var(--color-blue-100); color: var(--color-blue-500);
}
.p-keytech-ocr .ocr-scr__match-glyph .ds-icon { width: 20px; height: 20px; }
.p-keytech-ocr .ocr-scr__match-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.p-keytech-ocr .ocr-scr__match-type { font-family: var(--font-display); font-weight: 600; font-size: var(--fs-sm); color: var(--color-black); }
.p-keytech-ocr .ocr-scr__match-sub { font-size: var(--fs-xs); color: var(--color-grey-on-white); }
.p-keytech-ocr .ocr-scr__cap { margin: 0; font-size: var(--fs-xs); color: var(--color-grey-on-white); }

/* -- 03 · read — extracted fields (label · value · check) -- */
.p-keytech-ocr .ocr-fields { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.p-keytech-ocr .ocr-field {
  display: grid; grid-template-columns: 1fr auto auto; align-items: center; gap: 10px;
  padding: 9px 12px; border-radius: 10px;
  border: 1px solid var(--color-border-light); background: var(--color-white);
}
.p-keytech-ocr .ocr-field__k { font-size: var(--fs-xs); font-weight: 500; color: var(--color-grey-on-white); }
.p-keytech-ocr .ocr-field__v {
  font-family: var(--font-display); font-weight: 600; font-size: var(--fs-xs);
  color: var(--color-grey-600); font-variant-numeric: tabular-nums;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 148px;
}
.p-keytech-ocr .ocr-field__ok {
  flex: none; display: grid; place-items: center; width: 16px; height: 16px; border-radius: 50%;
  color: var(--color-white); background: var(--color-green-500);
}
.p-keytech-ocr .ocr-field__ok svg { width: 9px; height: 9px; }

/* -- 04 · decode — the machine-readable zone, decoded -- */
.p-keytech-ocr .ocr-mrz {
  padding: 12px 14px; border-radius: 12px;
  border: 1px solid var(--color-border-light); background: var(--color-grey-50);
}
.p-keytech-ocr .ocr-mrz__label {
  display: block; margin-bottom: 8px;
  font-size: 9.5px; font-weight: 700; letter-spacing: var(--track-wide);
  text-transform: uppercase; color: var(--color-grey-400);
}
.p-keytech-ocr .ocr-mrz__lines {
  display: flex; flex-direction: column; gap: 4px;
  font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  font-size: 10px; line-height: 1.3; letter-spacing: 0.04em;
  color: var(--color-grey-600); word-break: break-all;
}

/* -- 05 · structure — the clean structured output (JSON-ish) -- */
.p-keytech-ocr .ocr-json {
  padding: 14px 16px; border-radius: 12px;
  border: 1px solid var(--color-border-light); background: var(--color-grey-50);
  font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  font-size: 11px; line-height: 1.5;
  display: flex; flex-direction: column;
}
.p-keytech-ocr .ocr-json__brace { color: var(--color-grey-400); }
.p-keytech-ocr .ocr-json__row { padding-left: 16px; color: var(--color-grey-400); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.p-keytech-ocr .ocr-json__key { color: var(--color-blue); }
.p-keytech-ocr .ocr-json__str { color: var(--color-grey-600); }


/* ============================================================
   ACCURACY — text banner + benchmark stat cards (fact-bank F15;
   the built mockup chart was removed, owner order 2026-08-03)
   ============================================================ */
.p-keytech-ocr .ocr-accuracy__cards {
  list-style: none; margin: 44px 0 0; padding: 0;
  display: grid; gap: 14px;
}
@media (min-width: 640px) { .p-keytech-ocr .ocr-accuracy__cards { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1024px) { .p-keytech-ocr .ocr-accuracy__cards { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; } }
.p-keytech-ocr .ocr-accuracy__card {
  display: flex; flex-direction: column; gap: 8px;
  padding: 26px 26px 24px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.04);
}
.p-keytech-ocr .ocr-accuracy__field {
  font-size: var(--fs-sm); font-weight: 500; color: rgba(255, 255, 255, 0.7);
}
.p-keytech-ocr .ocr-accuracy__val {
  font-family: var(--font-display); font-weight: 500; letter-spacing: var(--track-tighter);
  font-size: clamp(44px, 4.5vw, 60px); line-height: 1; font-variant-numeric: tabular-nums;
}
.p-keytech-ocr .ocr-accuracy__vs {
  font-size: var(--fs-sm); line-height: var(--leading-snug); color: rgba(255, 255, 255, 0.55);
}
.p-keytech-ocr .ocr-accuracy__note {
  margin-top: 18px; font-size: var(--fs-xs); color: rgba(255, 255, 255, 0.45);
}

/* ============================================================
   Reduced motion
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
  .p-keytech-ocr .ocr-scan__beam { animation: none; opacity: 1; top: 50%; }
  .p-keytech-ocr .ocr-scan__field { animation: none; opacity: 1; transform: none; }
}
