/* Investigation product layout. Semantic color is derived from saved assessments. */
:root { --report-red:#a12e35; --report-green:#176846; --report-muted:#586679; }
.tone-regressed { color:var(--report-red); }
.tone-improved { color:var(--report-green); }
.tone-neutral { color:var(--report-muted); }
.tone-caution { color:#805718; }
.result-badge { display:inline-flex; align-items:center; gap:5px; padding:4px 9px; border-radius:5px; background:#eef2f6; color:#48586d; font-size:11px; font-weight:650; line-height:1.4; white-space:normal; }
.result-badge.tone-regressed { background:#fae9eb; color:var(--report-red); }
.result-badge.tone-improved { background:#e5f3ec; color:var(--report-green); }
.result-badge.tone-caution { background:#fff3da; color:#805718; }
.investigation-report { display:flex; flex-direction:column; gap:28px; max-width:1500px; margin:auto; color:var(--text); }
.investigation-report h2 { font-size:19px; letter-spacing:-.025em; margin:0; }
.investigation-report h3 { font-size:14px; margin:0 0 10px; line-height:1.5; }
.investigation-report p { line-height:1.65; }
.section-heading { display:flex; align-items:center; justify-content:space-between; gap:14px; flex-wrap:wrap; margin-bottom:16px; }
.result-hero { background:white; border:1px solid var(--line); border-left:4px solid #637e9d; border-radius:12px; padding:24px 28px; color:var(--text); }
.result-hero.tone-regressed { border-left-color:var(--report-red); }
.result-hero h2 { font-size:29px; line-height:1.25; max-width:1000px; }
.result-hero .result-answer { max-width:1050px; margin:10px 0 14px; color:#526278; }
.result-statuses,.result-context { display:flex; flex-wrap:wrap; gap:8px 20px; align-items:center; }
.result-context { font-size:12px; color:#526278; }
.result-context strong { color:#23374f; font-size:14px; }
.scope-strip { display:flex; gap:20px 36px; flex-wrap:wrap; border-top:1px solid #edf0f4; padding-top:16px; margin-top:16px; }
.scope-strip>div { display:grid; gap:4px; }
.scope-strip span { color:#64748b; font-size:11px; }
.scope-strip strong { font-size:12px; font-weight:550; }
.scope-filters,.freshness-note { font-size:12px; color:#526278; margin:10px 0 0; }
.kpi-grid { display:grid; grid-template-columns:repeat(6,minmax(0,1fr)); gap:12px; }
.kpi-card { background:white; border:1px solid var(--line); border-radius:10px; padding:18px 16px; min-width:0; }
.kpi-card h3 { font-size:12px; color:#526278; min-height:36px; margin-bottom:8px; }
.kpi-value { font-size:28px; letter-spacing:-.04em; line-height:1.25; font-weight:650; font-variant-numeric:tabular-nums; overflow-wrap:anywhere; }
.kpi-value small { font-size:12px; letter-spacing:0; color:#64748b; font-weight:450; }
.kpi-status { display:flex; flex-direction:column; align-items:flex-start; gap:8px; margin-top:14px; font-size:11px; font-variant-numeric:tabular-nums; }
.kpi-card>p { margin:10px 0 0; font-size:11px; color:#637185; }
.kpi-volume { background:#f1f5f9; }
.finding-grid { display:grid; grid-template-columns:repeat(auto-fit,minmax(230px,1fr)); gap:14px; }
.finding-card { padding:18px 20px; border-radius:9px; background:white; border-left:3px solid #a8b5c5; color:var(--text); }
.finding-card.tone-regressed { border-left-color:var(--report-red); }
.finding-card.tone-improved { border-left-color:var(--report-green); }
.finding-card h3 { margin-top:10px; }
.finding-card p { margin:6px 0; font-size:13px; }
.finding-card small { color:#637185; }
.performance-panels { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:18px; align-items:start; }
.chart-panel { background:white; border:1px solid var(--line); border-radius:10px; padding:22px; min-width:0; }
.transfer-panel { grid-column:1/-1; }
.comparison-label { display:flex; align-items:center; justify-content:space-between; gap:10px; margin-bottom:8px; font-size:12px; }
.investigation-report .report-comparison { margin:18px 0; }
.investigation-report .comparison-row { display:grid; grid-template-columns:60px minmax(0,1fr) 95px; gap:10px; align-items:center; font-size:11px; margin-top:6px; }
.investigation-report .comparison-row b { text-align:right; font-size:12px; font-variant-numeric:tabular-nums; }
.investigation-report .bar-track { height:7px; }
.investigation-report .bar-fill { background:#386d9e; }
.investigation-report .bar-fill.baseline { background:#abbcd0; }
.availability-grid { display:grid; grid-template-columns:repeat(auto-fit,minmax(190px,1fr)); gap:14px; }
.coverage-panel { padding:24px; background:#fff; border:1px solid var(--line); border-radius:10px; }
.coverage-grid { display:grid; grid-template-columns:repeat(auto-fit,minmax(145px,1fr)); gap:12px; margin-bottom:20px; }
.coverage-grid details { background:#f5f7fa; border-radius:7px; padding:12px; }
.coverage-grid summary { display:flex; flex-direction:column; gap:10px; align-items:flex-start; cursor:pointer; font-size:12px; }
.coverage-grid p { font-size:12px; }
.contributor-summary { border-top:1px solid var(--line); padding-top:18px; }
.contributor-summary p { font-size:13px; }
.coverage-panel>details { margin-top:16px; font-size:12px; }
.insight-panel.ai-panel { padding:24px 28px; border:1px solid #d4e0ed; border-radius:12px; background:#f9fbfe; }
.insight-lead,.insight-full { max-width:1000px; }
.insight-panel p { font-size:14px; line-height:1.8; }
.insight-panel>.muted-text { font-size:12px; }
.insight-preview { display:grid; grid-template-columns:1fr 1fr; gap:24px; margin:20px 0; }
.insight-preview article { border-top:1px solid #dce5ef; padding-top:16px; }
.insight-full { padding-top:20px; }
.insight-full section { margin-bottom:24px; }
.insight-citations summary { color:#436389; font-size:12px; cursor:pointer; }
.insight-citations div { padding:10px 0; }
.report-disclosure { border:1px solid var(--line); border-radius:9px; background:white; overflow:hidden; }
.report-disclosure>summary { padding:17px 20px; cursor:pointer; font-size:13px; font-weight:600; }
.report-disclosure>div,.report-disclosure>p { padding:0 20px 20px; }
.insight-panel .report-disclosure { background:transparent; }
.report-actions { display:flex; align-items:center; flex-wrap:wrap; gap:12px; margin-top:-14px; }
.report-actions .muted-text { font-size:12px; }
.metric-details td:not(:first-child) { text-align:right; font-variant-numeric:tabular-nums; }
.metric-details th[scope=row] { font-size:12px; text-transform:none; font-weight:550; letter-spacing:0; }
.metric-details table { min-width:700px; }
.diagnostic-sections { display:grid; grid-template-columns:1fr 1fr; align-items:start; gap:28px; }
.diagnostic-sections>section { min-width:0; padding-top:16px; border-top:1px solid var(--line); }
.diagnostic-list { margin:10px 0; }
.diagnostic-list>div { display:flex; justify-content:space-between; align-items:baseline; gap:20px; padding:8px 0; border-bottom:1px solid #f0f3f6; font-size:12px; }
.diagnostic-list dt { color:#637185; }
.diagnostic-list dd { margin:0; text-align:right; font-variant-numeric:tabular-nums; overflow-wrap:anywhere; min-width:0; }
.diagnostic-sections p,.diagnostic-sections li { font-size:12px; }
.diagnostic-sections details { margin-top:12px; }
.diagnostic-sections summary { font-size:12px; cursor:pointer; }
.attempt-record { border-left:2px solid #dce5ef; padding-left:12px; }
.execution-diagnostics>button { margin:0 20px 20px; }
.plan-summary { border-radius:9px; background:#f4f7fa; padding:20px; }
.plan-summary-heading { display:flex; gap:12px; align-items:center; flex-wrap:wrap; margin-bottom:18px; }
.plan-summary-heading strong { overflow-wrap:anywhere; }
.plan-windows { display:grid; grid-template-columns:1fr 1fr; gap:18px; margin:0; }
.plan-windows dt { font-size:12px; color:#526278; margin-bottom:5px; }
.plan-windows dd { margin:0; font-size:14px; line-height:1.7; }
.plan-windows small { display:block; color:#637185; }
.plan-technical { margin-top:16px; font-size:12px; }
.plan-technical summary { cursor:pointer; padding:8px 0; }
.plan-action-footer { position:sticky; bottom:0; background:white; padding:16px 0; border-top:1px solid var(--line); z-index:2; }
.history-more { padding:14px 20px; }
.history-more summary { cursor:pointer; font-size:12px; }
.workflow-compact { margin:4px 0 14px; }
.nl-result-heading { margin:0 auto 22px; max-width:1500px; }
.nl-result-heading p { font-size:15px; color:#33475e; margin:8px 0; }
.stage-progress { display:grid; grid-template-columns:repeat(4,1fr); gap:12px; list-style:none; padding:0; }
.stage-progress li { padding:14px; border-radius:7px; background:#f1f4f8; }
.stage-progress .current { background:#e7effa; color:#234f88; }
.stage-progress .done { color:#176846; }
@media(max-width:1350px) { .kpi-grid { grid-template-columns:repeat(3,minmax(0,1fr)); } }
@media(max-width:850px) { .performance-panels,.diagnostic-sections,.insight-preview,.plan-windows { grid-template-columns:1fr; } .transfer-panel { grid-column:auto; } .result-hero h2 { font-size:24px; } .result-hero,.coverage-panel,.insight-panel.ai-panel { padding:20px; } }
@media(max-width:520px) { .kpi-grid,.availability-grid { grid-template-columns:repeat(2,minmax(0,1fr)); gap:10px; } .kpi-card { padding:14px 12px; } .kpi-value { font-size:24px; } .section-heading>.muted-text { font-size:11px; } .scope-strip { flex-direction:column; gap:12px; } .result-statuses { gap:6px; } .stage-progress { grid-template-columns:1fr 1fr; } .comparison-label { align-items:flex-start; flex-direction:column; } .chart-panel { padding:16px; } .investigation-report .comparison-row { grid-template-columns:48px minmax(0,1fr) 78px; gap:7px; } }

.lineage-link { display:block; border:0; background:transparent; color:var(--accent,#2563eb); padding:6px 0; font:inherit; font-weight:600; white-space:nowrap; cursor:pointer; }
.lineage-link:hover { text-decoration:underline; }
.lineage-link:focus-visible { outline:2px solid currentColor; outline-offset:3px; border-radius:3px; }
#drawer-content dd { overflow-wrap:anywhere; }
