/* ============================================================================================================
   Platform/trust page kit (shared by platform, platform-intelligence, platform-investigation, platform-remediation
   and trust; copied into each page file at build time). Background layers, product-UI illustration primitives,
   marquee. Navy/teal only; crimson only for risk. No amber or yellow anywhere.
   ============================================================================================================ */

/* ------------------------------------------------------------ product UI primitives */
.ui { position: relative; background: linear-gradient(180deg, var(--navy-850), var(--navy-900)); border: 1px solid var(--line); border-radius: var(--r-md); overflow: hidden;
  box-shadow: var(--e1); color: var(--ink-200); font: 400 var(--fs-sm)/1.4 var(--display); text-align: left; }
.ui-bar { display: flex; align-items: center; gap: 10px; height: 38px; padding: 0 14px; border-bottom: 1px solid var(--line); background: color-mix(in srgb, var(--navy-950) 55%, transparent); white-space: nowrap; }
.ui-bar .dots { display: flex; gap: 6px; margin-right: 4px; }
.ui-bar .dots i { width: 8px; height: 8px; border-radius: var(--r-full); background: var(--line); }
.ui-bar .t { font: 600 var(--fs-xs)/1 var(--display); color: var(--ink-50); }
.ui-bar .crumb { font: 400 var(--fs-xs)/1 var(--mono); color: var(--ink-400); overflow: hidden; text-overflow: ellipsis; }
.ui-bar .end { margin-left: auto; display: flex; gap: 8px; align-items: center; }
.ui-body { padding: 14px; }
.rows { display: grid; margin-top: 10px; border: 1px solid var(--line); border-radius: var(--r-md); overflow: hidden; }
.row { display: flex; align-items: center; gap: 10px; padding: 9px 12px; background: color-mix(in srgb, var(--navy-950) 25%, transparent); min-width: 0; }
.row + .row { border-top: 1px solid var(--line); }
.row b { font-weight: 500; color: var(--ink-50); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.row .m { color: var(--ink-400); font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.row .end { margin-left: auto; display: flex; gap: 8px; align-items: center; flex: none; }
.chip { display: inline-flex; align-items: center; gap: 6px; padding: 3px 8px; border-radius: var(--r-xs); border: 1px solid var(--line); font: 500 var(--fs-xs)/1.2 var(--mono); letter-spacing: var(--tr-label); color: var(--ink-200); white-space: nowrap; }
.chip.ok { color: var(--teal-300); border-color: var(--teal-a40); background: var(--teal-a06); }
.chip.risk { color: var(--red-300); border-color: color-mix(in srgb, var(--red-500) 60%, transparent); background: color-mix(in srgb, var(--red-500) 12%, transparent); }
.btn-ui { display: inline-flex; align-items: center; padding: 5px 10px; border-radius: var(--r-sm); border: 1px solid var(--line-strong); font: 500 var(--fs-xs)/1 var(--display); color: var(--ink-50); white-space: nowrap; }
.btn-ui.pri { background: var(--teal-400); border-color: transparent; color: var(--navy-950); }
.ver { font: 400 var(--fs-xs)/1 var(--mono); color: var(--ink-200); }

/* PAGE 05 · Remediation. H2 · Console (rollout step 3): the skeleton (hero heading, stage, callouts, step cards, spec
   rows, close) is in core (system.css). Here: the authorization request on the hero stage, the Proposed -> Reviewed ->
   Authorize chain across the top, the four request fields side by side; numbered marks match the callouts. */
.approval { border-color: var(--teal-a24); box-shadow: var(--e1); }
.chain { display: flex; align-items: center; gap: 16px; padding: 16px 20px; border-bottom: 1px solid var(--line); background: color-mix(in srgb, var(--navy-700) 30%, transparent); }
.who { display: grid; grid-template-columns: auto auto auto; column-gap: 10px; align-items: center; justify-content: start; font-size: var(--fs-xs); color: var(--ink-400); white-space: nowrap; }
.who .av { grid-row: span 2; }
.who b { grid-column: 2; font: 500 var(--fs-sm)/1.3 var(--display); color: var(--ink-50); }
.who .r-mk { grid-column: 3; grid-row: 1 / span 2; }
.who.pending .av { background: none; border: 1.5px dashed var(--teal-400); }
.arrow { flex: 1; height: 1px; background: linear-gradient(90deg, var(--teal-400), var(--teal-a24)); position: relative; min-width: 24px; }
.arrow::after { content: ''; position: absolute; right: 0; top: -3px; width: 6px; height: 6px; border-top: 1px solid var(--teal-400); border-right: 1px solid var(--teal-400); transform: rotate(45deg); }
.av { width: 30px; height: 30px; flex: none; display: grid; place-items: center; border-radius: 7px; background: var(--navy-800); font: 600 12px/1 var(--display); color: var(--teal-300); }
.ap-rows { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); margin: 0; }
.ap-rows div { display: grid; gap: 8px; align-content: start; padding: 18px 20px 20px; min-width: 0; }
.ap-rows div + div { border-left: 1px solid var(--line); }
.ap-rows dt { display: flex; align-items: center; gap: 8px; min-height: 20px; font: 500 var(--fs-xs)/1.4 var(--mono); letter-spacing: var(--tr-label); text-transform: uppercase; color: var(--ink-400); }
.ap-rows dd { margin: 0; color: var(--ink-50); font-size: var(--fs-sm); line-height: 1.45; }
.ap-actions { display: flex; align-items: center; gap: 8px; padding: 14px 20px; border-top: 1px solid var(--line); background: color-mix(in srgb, var(--navy-950) 35%, transparent); }
.ap-note { margin-right: auto; font: 400 var(--fs-sm)/1.3 var(--display); color: var(--ink-400); }
.ap-actions .btn-ui { padding: 9px 18px; font-size: var(--fs-sm); border-radius: var(--r-full); }
/* numbered notes: a small index on the panel, the matching note under it */
.r-mk { display: inline-grid; place-items: center; flex: none; width: 22px; height: 22px; border-radius: var(--r-xs); border: 1px solid var(--teal-a60); background: color-mix(in srgb, var(--teal-400) 24%, var(--navy-900)); color: var(--teal-300);
  font: 600 var(--fs-xs)/1 var(--mono); font-style: normal; letter-spacing: 0; }

/* ------------------------------------------------------------ lifecycle drawing (static, on a stage after the step cards)
   Restored from the tabbed stepper (owner, 24 Nov 2026). Every stage is live, so one solid track; no scroll motion.
   A stage is chosen by click or the arrow keys (/assets/js/tabs.js). */
figure.stage-fig.r-life { margin-top: var(--sp-7); }
.r-life .stage-frame { margin-top: 0; }
.groups { display: grid; grid-template-columns: 4fr 2fr; gap: 12px; }
.groups > span { padding-bottom: 12px; }
.g-next { border-left: 1px dashed color-mix(in srgb, var(--violet-300) 40%, transparent); padding-left: 14px; }
.stepper { position: relative; }
.track { position: absolute; left: calc(100% / 12); right: calc(100% / 12); top: 28px; height: 2px; background: var(--line); }
.track .fill-now { position: absolute; left: 0; top: 0; height: 2px; width: calc(60% * var(--now, 1)); background: var(--teal-400); box-shadow: none; }
.track .fill-next { position: absolute; left: 60%; top: 0; height: 0; width: calc(40% * var(--next, 1)); border-top: 2px dashed color-mix(in srgb, var(--violet-300) 60%, transparent); }
.tabs { position: relative; display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 12px; }
.tabs [role="tab"] { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 16px 6px 14px; border: 1px solid transparent; border-radius: var(--r-md); background: none; color: var(--ink-200); cursor: pointer; font: inherit; }
.tabs [role="tab"] i { width: 26px; height: 26px; border-radius: var(--r-full); border: 2px solid var(--teal-400); background: var(--navy-850); }
.tabs [role="tab"] b { font: 600 var(--fs-xs)/1 var(--mono); letter-spacing: var(--tr-label); text-transform: uppercase; color: var(--ink-50); }
.tabs [role="tab"] span { font: 500 var(--fs-xs)/1 var(--mono); letter-spacing: var(--tr-label); text-transform: uppercase; color: var(--teal-300); }
.tabs [role="tab"]:hover { background: color-mix(in srgb, var(--white) 3%, transparent); }
.tabs [role="tab"][aria-selected="true"] { border-color: var(--line); background: color-mix(in srgb, var(--navy-850) 85%, transparent); }
.tabs [role="tab"][aria-selected="true"] i { background: var(--teal-400); box-shadow: 0 0 0 6px var(--teal-a12); }
.panels { margin-top: 18px; }
.panel { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 24px; align-items: center; padding: 24px 26px; border: 1px solid var(--line); border-radius: var(--r-md); background: linear-gradient(180deg, color-mix(in srgb, var(--navy-850) 85%, transparent), color-mix(in srgb, var(--navy-950) 85%, transparent)); }
.panel[hidden] { display: none; }
.p-txt { display: grid; gap: 10px; justify-items: start; }
.p-k { font: 500 var(--fs-xs)/1 var(--mono); letter-spacing: var(--tr-label); color: var(--ink-400); }
.p-txt .h3 { font-size: var(--fs-2xl); font-weight: var(--fw-h2); letter-spacing: var(--tr-tight); }
.p-d { color: var(--ink-200); max-width: 46ch; }
.p-vis { box-shadow: var(--e1); }
.p-vis .rows { margin-top: 0; }
.p-vis .row .m { margin-left: auto; }
.checks { display: grid; gap: 10px; }
.checks li { display: flex; gap: 10px; align-items: center; color: var(--ink-50); }
.checks li::before { content: ''; width: 14px; height: 7px; margin-top: -4px; border-left: 2px solid var(--teal-400); border-bottom: 2px solid var(--teal-400); transform: rotate(-45deg); }
.auth-btns { display: flex; gap: 8px; margin-bottom: 12px; }
.auth-btns .btn-ui { padding: 9px 18px; border-radius: var(--r-full); font-size: 13px; }
/* Every stage live: one solid teal track, the second group drawn like the first. */
.g-next.live { border-left: 1px solid var(--teal-a40); }
.track.all-now .fill-now { width: calc(100% * var(--now, 1)); }
.track.all-now .fill-next { display: none; }

@media (max-width: 767px) {
  figure.stage-fig.r-life { margin-top: var(--sp-6); }
  .groups, .track { display: none; }
  .tabs { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
  .tabs [role="tab"] { border-color: var(--line); }
  .panel { padding: 20px; }
}
@media (max-width: 1023px) { .panel { grid-template-columns: minmax(0, 1fr); } }

/* ------------------------------------------------------------ safeguard chain (navy section, owner 24 Nov 2026)
   The four safeguards around each change on a stage: a rail of numbered stages (square marks joined by a teal arrow,
   not the lifecycle stepper's round track), each with a small drawn record. The Monitor line is a note under it. */
.sg-flow { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--sp-6) var(--sp-5); margin: 0; padding: 0; list-style: none; }
.sg-step { display: flex; flex-direction: column; min-width: 0; }
.sg-rail { position: relative; display: flex; align-items: center; gap: var(--sp-3); margin-bottom: var(--sp-4); }
.sg-phase { font: 500 var(--fs-xs)/1 var(--mono); letter-spacing: var(--tr-label); text-transform: uppercase; color: var(--teal-300); white-space: nowrap; }
.sg-step:not(:last-child) .sg-rail::after { content: ''; flex: 1; height: 1px; min-width: var(--sp-5); margin-right: calc(var(--sp-5) * -1 + 4px);
  background: linear-gradient(90deg, var(--teal-a40), var(--teal-400)); }
.sg-step:not(:last-child) .sg-rail::before { content: ''; position: absolute; right: calc(var(--sp-5) * -1 + 4px); top: 50%; width: 7px; height: 7px; margin-top: -4px;
  border-top: 1px solid var(--teal-400); border-right: 1px solid var(--teal-400); transform: rotate(45deg); }
.sg-step .h3 { margin: 0; color: var(--ink-50); }
.sg-d { margin: var(--sp-2) 0 var(--sp-5); color: var(--ink-200); font-size: var(--fs-sm); line-height: 1.5; }
.sg-ui { flex: 1; display: flex; flex-direction: column; border-color: var(--teal-a24);
  box-shadow: var(--e1), 0 24px 48px -28px var(--teal-a24); }
.sg-ui .ui-body { flex: 1; display: flex; flex-direction: column; }
.sg-ui .rows { margin-top: auto; }
.sg-ui .row .m { margin-left: auto; font-family: var(--mono); }
/* 1 · backup: the 30-day retention, large */
.sg-keep { display: grid; gap: var(--sp-2); justify-items: start; }
.sg-k { font: 500 var(--fs-xs)/1 var(--mono); letter-spacing: var(--tr-label); text-transform: uppercase; color: var(--ink-400); }
.sg-big { display: inline-flex; align-items: baseline; gap: 6px; font: 600 var(--fs-3xl)/1 var(--display); letter-spacing: var(--tr-tight); color: var(--teal-300); }
.sg-big small { font: 500 var(--fs-sm)/1 var(--display); letter-spacing: 0; color: var(--ink-200); }
.sg-bar { position: relative; height: 6px; margin-top: var(--sp-3); border-radius: var(--r-full); background: var(--line); overflow: hidden; }
.sg-bar i { position: absolute; inset: 0; border-radius: inherit; background: linear-gradient(90deg, var(--teal-400), var(--teal-a40)); }
.sg-scale { display: flex; justify-content: space-between; gap: var(--sp-2); margin: var(--sp-2) 0 var(--sp-4); font: 400 var(--fs-xs)/1.2 var(--mono); color: var(--ink-400); white-space: nowrap; }
/* 2 · authorization: who, then when and on what evidence */
.sg-who { display: flex; align-items: center; gap: var(--sp-3); margin-bottom: var(--sp-4); }
.sg-who > span:last-child { display: grid; gap: 2px; min-width: 0; }
.sg-who b { font: 500 var(--fs-sm)/1.3 var(--display); color: var(--ink-50); }
.sg-who > span:last-child > span { font-size: var(--fs-xs); color: var(--ink-400); }
.sg-who .av { width: 36px; height: 36px; border: 1px solid var(--teal-a40); background: var(--teal-a12); }
/* 3 · execution: a short log, each line with its result */
.sg-log { display: grid; margin: 0; padding: 0; list-style: none; border: 1px solid var(--line); border-radius: var(--r-md); overflow: hidden; }
.sg-log li { display: flex; align-items: center; gap: var(--sp-3); padding: 9px 12px; background: color-mix(in srgb, var(--navy-950) 25%, transparent); min-width: 0; }
.sg-log li + li { border-top: 1px solid var(--line); }
.sg-log b { flex: 1; min-width: 0; font-weight: 500; color: var(--ink-50); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sg-t { font: 400 var(--fs-xs)/1 var(--mono); color: var(--ink-400); }
/* 4 · restore: pick the backup, one button */
.sg-ui .sg-vers { margin-top: 0; }
.sg-vers .row.sel { background: var(--teal-a12); box-shadow: inset 2px 0 0 var(--teal-400); }
.sg-go { justify-content: center; margin-top: auto; padding: 9px 18px; border-radius: var(--r-full); font-size: var(--fs-sm); }
.sg-ui .sg-vers { margin-bottom: var(--sp-4); }
.sg-hint { margin-top: auto; padding-bottom: var(--sp-3); text-align: center; font: 400 var(--fs-xs)/1.2 var(--mono); color: var(--ink-400); }
.sg-hint + .sg-go { margin-top: 0; }
/* the Monitor note under the stage */
.sg-note { display: flex; align-items: flex-start; gap: var(--sp-3); max-width: 72ch; margin-top: var(--sp-5); color: var(--ink-200); font-size: var(--fs-sm); line-height: 1.5; }
.sg-note svg { flex: none; width: 20px; height: 20px; margin-top: 1px; fill: none; stroke: var(--teal-300); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }

@media (max-width: 1199px) {
  .sg-flow { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .sg-step:nth-child(2n) .sg-rail::after, .sg-step:nth-child(2n) .sg-rail::before { display: none; }
}
@media (max-width: 767px) {
  .sg-flow { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .sg-step { position: relative; padding: 0 0 var(--sp-6) calc(28px + var(--sp-4)); }
  .sg-step:last-child { padding-bottom: 0; }
  .sg-rail { position: static; margin-bottom: var(--sp-2); }
  .sg-rail .mk-n { position: absolute; left: 0; top: -6px; }
  .sg-step .sg-rail::after, .sg-step .sg-rail::before { display: none; }
  .sg-step:not(:last-child)::before { content: ''; position: absolute; left: 14px; top: 28px; bottom: 0; width: 1px; background: linear-gradient(180deg, var(--teal-400), var(--teal-a24)); }
}

/* ------------------------------------------------------------ responsive */
@media (max-width: 1023px) {
  .ap-rows { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ap-rows div:nth-child(3) { border-left: 0; }
  .ap-rows div:nth-child(n+3) { border-top: 1px solid var(--line); }
}
@media (max-width: 767px) {
  .chain { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: start; gap: 8px; padding: 12px 14px; }
  .approval .ui-bar .dots, .approval .ui-bar .crumb { display: none; }
  .arrow { display: none; }
  .who { grid-template-columns: auto; row-gap: 4px; white-space: normal; }
  .who .av { grid-row: auto; }
  .who b, .who .r-mk { grid-column: auto; grid-row: auto; }
  .who b { font-size: var(--fs-xs); }
  .ap-rows { grid-template-columns: minmax(0, 1fr); }
  .ap-rows .r-x { display: none; }
  .ap-rows div { padding: 12px 14px; gap: 4px; }
  .ap-rows div + div { border-left: 0; border-top: 1px solid var(--line); }
  .ap-actions { flex-wrap: wrap; padding: 12px 14px; }
  .ap-note { flex-basis: 100%; }
}

/* ------------------------------------------------------------ review 2: proof line (C13), related links (E3) */

@media (max-width: 479px) {   /* C14: one breadcrumb line; the current page truncates */
  .breadcrumbs li { flex: none; white-space: nowrap; }
  .breadcrumbs li:last-child { flex: 0 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
}

/* ---- Copy round, 25 Nov 2026 (owner: "i want the answers i chose...fix if it cut off"): the chosen labels in the
   product drawings wrap to a second line instead of being cut with an ellipsis, and tab rows wrap. Same fonts, colors
   and spacing; no text is shortened. ---- */
.ui-row > *, .ui-top .t, .ui-file, .ui-meta > *, .ui-tile .k, .ui-tile .ui-sub, .ui-row .ui-chip, .ui-body > .ui-chip,
.row b, .row .m, .d-tr b, .d-tr .m, .sg-log b, .rp-stats span, .rp-s, .i-ph .crumb, .ctx-feed li, .i-files li span,
.ev-list li > span:nth-child(2), .hit span, .ui-bar .crumb, .tile .l, .tri-row b, .cl-row b, .cl-crumb {
  white-space: normal; overflow: visible; text-overflow: clip; overflow-wrap: anywhere; min-width: 0; }
.ui-tabs, .cb-tabs { flex-wrap: wrap; row-gap: 8px; }
.cb-tabs span { white-space: normal; }
.ui-row .ui-chip, .ui-body > .ui-chip { max-width: 100%; }
