/* text-panes.css — Findings + Details panes (v4 P11; v5 W2-C, PLAN_v5 §3.9, §3.11, §4.3). Owns the tx- prefix only.
   Component recipes (pane head, rail body, centre body, card, kv, stat, plate sections, seg, iv utilities) come from
   tokens.css and components.css; the fold mini chart's marks from chart.css. Light only; tokens only (no hex except #fff);
   no font-size below var(--text-min); text never in the deep coral or the faint ink (coral may be a border). */

/* ================================================================ shared */
.tx-card{display:flex;flex-direction:column;gap:10px;flex:none}
.tx-prose{margin:0;font-family:var(--os-font-sans);font-weight:300;font-size:var(--text-body);line-height:var(--lh-body);color:var(--iv-ink)}
.tx-prose--sm{font-size:var(--text-body-sm);line-height:1.5}
.tx-prose strong,.tx-prose b{font-weight:400}
.tx-prose em{font-style:italic}
.tx-measure{max-width:640px}

/* kv variants: long prose values wrap */
.tx-kv>dt{white-space:nowrap;align-self:stretch}   /* stretched: a ruled kv's term rule meets its value's rule (the text stays at the top) */
.tx-kv>dd{line-height:1.5;min-width:0;overflow-wrap:anywhere}

/* sentence lists (UI definitions, corrections): prose in sans */
.tx-list{margin:0;padding:0;list-style:none;display:flex;flex-direction:column;gap:8px}
.tx-list>li{font-family:var(--os-font-sans);font-weight:300;font-size:var(--text-body-sm);line-height:1.5;color:var(--iv-ink);padding-bottom:8px;border-bottom:1px solid var(--iv-hairline)}
.tx-list>li:last-child{padding-bottom:0;border-bottom:0}
[data-ref]{cursor:help}

/* plate */
.tx-plate-head{gap:0}
.tx-plate-sections{flex:1;min-height:0;overflow:hidden}
.tx-plate-sec{gap:8px}

/* ================================================================ Findings */
.tx-rail{gap:18px}
.tx-stat{flex:none}
.tx-stat-value{font-variant-numeric:tabular-nums;font-feature-settings:"tnum" 1;white-space:nowrap}
/* eyebrows that carry physics symbols keep their case (an uppercased σ / β reads as Σ / B) */
.tx-stat .iv-eyebrow,.tx-card--fold .iv-eyebrow{text-transform:none;letter-spacing:0.12em}
.tx-stat--headline .tx-stat-value{font-size:var(--text-h1);line-height:var(--lh-h1);letter-spacing:var(--track-h1)}

.tx-centre--findings{gap:12px}

/* fold table: 3 rows × 7 walls, 8 % rules */
.tx-table{width:100%;border-collapse:collapse;font-family:var(--os-font-mono);font-weight:400;font-size:12px;letter-spacing:0.02em;color:var(--iv-ink);font-variant-numeric:tabular-nums;font-feature-settings:"tnum" 1}
.tx-table th,.tx-table td{padding:6px 10px 6px 0;border-bottom:1px solid var(--iv-hairline);text-align:left;vertical-align:baseline}
.tx-table th{color:var(--iv-ink-muted);font-weight:400;white-space:nowrap;width:1%;padding-right:20px}
.tx-table tr:last-child th,.tx-table tr:last-child td{border-bottom:0}

/* notes under the fold table */
.tx-note{margin:0;font-family:var(--os-font-mono);font-weight:400;font-size:10.5px;letter-spacing:0.04em;line-height:1.5;color:var(--iv-ink-muted)}
.tx-note--correction{color:var(--iv-ink);border-left:2px solid var(--iv-coral);padding-left:8px}

/* bottom row: the control card (FI-5) beside the fold mini chart (FI-6) */
.tx-row-pair{display:flex;gap:12px;flex:1 1 auto;min-height:190px}
.tx-row-pair>.tx-card{min-height:0}
.tx-card--control{flex:1 1 0;min-width:0;gap:8px}
.tx-card-head{display:flex;align-items:baseline;justify-content:space-between;gap:10px;flex-wrap:wrap}
.tx-status{font-family:var(--os-font-mono);font-weight:400;font-size:var(--text-min);letter-spacing:0.06em;color:var(--sfr-warn);border:1px solid currentColor;border-radius:var(--radius-control);padding:1px 6px;white-space:nowrap}
.tx-card--fold{flex:0 0 300px;min-width:0}
.tx-toggle{font-size:var(--text-min);color:var(--iv-ink-muted)}
.tx-fold-plot{position:relative;min-height:140px}
.tx-fold-line{fill:none;stroke:var(--iv-rule-35);stroke-width:1;stroke-linejoin:round}
.tx-fold-dot{fill:var(--iv-ink);stroke:#fff;stroke-width:1}
.tx-fold-design{stroke:var(--iv-ink-muted)}
.tx-fold-design-label{fill:var(--iv-ink-muted)}

/* Findings definitions: the terms are too wide for a two-column kv in a 244-px plate, so inside the plate the kv
   stacks term over text, one rule per definition */
.tx-plate-sec .tx-kv{font-size:11px;grid-template-columns:minmax(0,1fr);row-gap:4px}
.tx-plate-sec .tx-kv>dt{border-bottom:0;padding-bottom:0}
.tx-plate-sec .tx-kv>dd{padding-bottom:10px;margin-bottom:4px}
.tx-plate-sec .tx-kv>dd:last-child{border-bottom:0;padding-bottom:0;margin-bottom:0}

/* ================================================================ Details */
/* rail: the anchor index (DT-2) — the rail itself never scrolls */
.tx-index{display:flex;flex-direction:column;gap:10px}
.tx-index-list{margin:0;padding:0;list-style:none;display:flex;flex-direction:column;gap:2px}
.tx-index-item{display:block;width:100%;min-height:var(--size-hit);margin:0;padding:4px 10px;border:0;border-left:2px solid transparent;background:transparent;text-align:left;cursor:pointer;
  font-family:var(--os-font-sans);font-weight:300;font-size:var(--text-body-sm);line-height:1.3;color:var(--iv-ink-muted);-webkit-appearance:none;appearance:none}
.tx-index-item:hover{color:var(--iv-ink);background:var(--iv-surface-hover)}
.tx-index-item[aria-current="true"]{color:var(--iv-ink);font-weight:400;border-left-color:var(--iv-ink);background:var(--iv-surface)}

/* centre: the one scroller; sections ≤ 640 px, centred */
.tx-centre--details{position:relative;gap:14px;overflow-x:hidden;overflow-y:auto;overscroll-behavior:contain}
.tx-sec{flex:none;width:100%;max-width:640px;align-self:center;scroll-margin-top:0}
.tx-sec:focus{outline:none}
.tx-sec:focus-visible>.tx-card{outline:2px solid var(--sfr-focus);outline-offset:1px}
.tx-lead{font-size:var(--text-body)}

/* the model rows: a bold one-line claim over a collapsed justification */
.tx-rows{display:flex;flex-direction:column;border-top:1px solid var(--iv-hairline)}
.tx-row{border-bottom:1px solid var(--iv-hairline)}
.tx-row-sum{display:grid;grid-template-columns:12px 92px minmax(0,1fr);align-items:baseline;column-gap:8px;min-height:var(--size-hit);padding:7px 0;cursor:pointer;list-style:none}
.tx-row-sum::-webkit-details-marker{display:none}
.tx-row-sum::marker{content:""}
.tx-row-sum::before{content:"";display:block;width:0;height:0;margin-left:2px;border-top:4px solid transparent;border-bottom:4px solid transparent;border-left:6px solid var(--iv-ink-muted);transform:translateY(-1px);transition:transform var(--dur-fast) var(--ease-standard)}
.tx-row[open]>.tx-row-sum::before{transform:translateY(-1px) rotate(90deg)}
.tx-row-sum:hover .tx-claim{text-decoration:underline;text-decoration-color:var(--iv-rule);text-underline-offset:3px}
.tx-row-sum:focus-visible{outline:2px solid var(--sfr-focus);outline-offset:1px}
.tx-row-label{font-family:var(--os-font-mono);font-weight:400;font-size:var(--text-mono-sm);letter-spacing:0.04em;color:var(--iv-ink-muted);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.tx-claim{font-family:var(--os-font-sans);font-weight:400;font-size:var(--text-body-sm);line-height:1.4;color:var(--iv-ink)}
.tx-just{margin:0 0 10px 112px;font-family:var(--os-font-sans);font-weight:300;font-size:var(--text-body-sm);line-height:1.55;color:var(--iv-ink);overflow-wrap:anywhere}

/* model parameters: value line, then the source line under it (sans); the file reference is hover-only */
.tx-kv--params,.tx-kv--operator,.tx-kv--provenance{font-size:11.5px}
.tx-kv--params>dt,.tx-kv--operator>dt,.tx-kv--provenance>dt{padding-top:1px}
.tx-kv--params>dd{display:flex;flex-direction:column;gap:3px}
.tx-param-value{font-family:var(--os-font-mono);font-weight:400;color:var(--iv-ink)}
.tx-param-source{font-family:var(--os-font-sans);font-weight:300;font-size:11.5px;line-height:1.45;color:var(--iv-ink-muted)}
.tx-kv--operator>dt{white-space:normal;max-width:120px}
.tx-kv--operator>dd{font-family:var(--os-font-sans);font-weight:300;font-size:var(--text-body-sm);line-height:1.5}
.tx-card--correction{border-left:3px solid var(--iv-coral)}

/* plate: what is real vs approximated — sized to fit the 692-px plate without a second scroller */
.tx-honest{padding-top:14px;padding-bottom:12px}
.tx-prose--honest{font-size:11px;line-height:1.5}
