/* Retained reports remain usable while the three review tabs are evaluated. */
#teacherDashboardTabs .insights-legacy-tab { color:#68727c; background:#eef0f2; border-color:#d6dce1; }
#teacherDashboardTabs .insights-legacy-tab.active { color:#3e4852; background:#dbe0e5; border-color:#9ca7b1; box-shadow:inset 0 -3px #89949f; }
#teacherDashboardTabs :is(#oversight-tab,#memory-progress-tab,#attention-review-tab) { font-weight:650; }
.insight-review { color:#23384a; padding:1rem 0; }
.insight-heading { display:flex; flex-wrap:wrap; align-items:center; justify-content:space-between; gap:.5rem; }
.insight-heading h2 { font-size:1.35rem; margin:0; font-weight:750; }
.insight-asof,.insight-caption { color:#64748b; font-size:.85rem; }
.insight-caption { margin:.4rem 0 1rem; }
.insight-tools { display:flex; flex-wrap:wrap; align-items:end; gap:.75rem; padding:.85rem; background:#f5f6fc; border:1px solid #e0e4f0; border-radius:12px; margin-bottom:.8rem; }
.insight-control { display:flex; flex-direction:column; gap:.25rem; font-size:.75rem; font-weight:650; max-width:100%; }
.insight-control input { width:180px; }
.insight-control select { min-width:150px; max-width:290px; }
.insight-class-chooser { font-size:.8rem; padding:.4rem; }
.insight-class-chooser label { display:flex; align-items:center; gap:.4rem; margin:.5rem 0; }
.insight-check { border-left:3px solid #399584; padding:.4rem .65rem; background:#eff9f5; font-size:.83rem; margin:.5rem 0; }
.insight-check-error { border-color:#bc3b48; background:#fff1f2; }
.insight-note { font-size:.8rem; color:#5d6b7d; margin:.5rem 0 .8rem; max-width:1100px; }
.insight-table-wrap { overflow-x:auto; border:1px solid #dde4ec; border-radius:12px; max-width:100%; }
.insight-table { margin:0; width:100%; min-width:700px; font-size:.88rem; vertical-align:middle; }
.insight-table thead { background:#f0f3fa; }
.insight-table thead th { background:#f0f3fa; }
.insight-table th { color:#43536b; font-size:.76rem; padding:.7rem .65rem; white-space:nowrap; }
.insight-table td { padding:.65rem; border-color:#e8edf3; }
.insight-table tbody>tr:nth-child(even):not(.insight-detail-row) { background:#fafbfe; }
.insight-table tbody>tr:nth-child(even):not(.insight-detail-row)>td { background:#fafbfe; }
.insight-table tfoot { background:#f1f4fa; font-weight:700; }
.insight-table tfoot td { background:#f1f4fa; }
.insight-sort { border:0; background:transparent; color:inherit; font:inherit; padding:0; text-align:left; }
.insight-table [aria-sort=ascending] .insight-sort::after { content:' \2191'; }
.insight-table [aria-sort=descending] .insight-sort::after { content:' \2193'; }
.insight-student { border:0; background:none; color:#4650a5; font-weight:650; text-decoration:underline; text-decoration-style:dotted; padding:0; text-align:left; }
.insight-unavailable { color:#788395; font-size:.8rem; }
.insight-known-count { display:block; font-weight:400; color:#6d7789; }
.insight-detail-row { background:#f6f7fc; }
.insight-detail-row>td { padding:1.2rem; background:#f6f7fc; }
.insight-detail-title { font-size:1rem; margin:0 0 .8rem; }
.insight-facts { display:grid; grid-template-columns:minmax(150px,220px) 1fr; gap:.5rem 1rem; font-size:.83rem; }
.insight-facts dd { margin:0; }
.insight-detail-row details { padding:.55rem 0; }
.insight-detail-row details p { font-size:.8rem; margin:.5rem 0 .5rem 1rem; }
.insight-export { display:flex; flex-wrap:wrap; gap:.5rem; align-items:center; margin:.7rem 0; font-size:.8rem; }
.insight-export textarea { min-width:300px; min-height:100px; }
.insight-stage-bar { display:flex; min-width:230px; max-width:500px; height:27px; overflow:hidden; border-radius:6px; gap:1px; }
.insight-stage-bar span { flex-basis:0; min-width:0; text-align:center; line-height:27px; font-size:.7rem; overflow:hidden; }
.insight-stage-0 { background:#e1e5eb; color:#465263; }
.insight-stage-1 { background:#f6d3a7; color:#573c15; }
.insight-stage-2 { background:#f2df90; color:#514210; }
.insight-stage-3 { background:#b6e1d0; color:#184b3a; }
.insight-stage-4 { background:#95c5e6; color:#143d58; }
.insight-stage-5 { background:#b7ace4; color:#32215c; }
.insight-legend { display:flex; flex-wrap:wrap; gap:.4rem; margin:.7rem 0; font-size:.73rem; }
.insight-legend span { border-radius:5px; padding:.22rem .55rem; }
.insight-priority-high,.insight-priority-review { display:inline-block; border-radius:20px; padding:.2rem .6rem; font-size:.75rem; font-weight:700; }
.insight-priority-high { color:#9d2235; background:#ffe4e9; }
.insight-priority-review { color:#855b08; background:#fff0c9; }
#attention-review-tab-pane .insight-table td:nth-last-child(2) { white-space:pre-line; font-size:.78rem; min-width:240px; max-width:480px; overflow-wrap:anywhere; }
@media(max-width:650px) { .insight-facts { grid-template-columns:1fr; gap:.2rem; } .insight-facts dd { margin-bottom:.65rem; } .insight-tools { padding:.65rem; gap:.5rem; } .insight-control select { max-width:230px; } .insight-heading h2 { font-size:1.2rem; } }
/* Whole-class comparison stays in one table; overflow belongs to this wrapper. */
.insight-table th { white-space:normal; min-width:88px; max-width:140px; }
.insight-table td { font-variant-numeric:tabular-nums; }
.insight-column-groups th { padding:.35rem .6rem; font-size:.7rem; text-transform:uppercase; letter-spacing:.035em; border-bottom:1px solid #d4dce8; }
.insight-column-groups th:nth-child(2n) { background:#e8edf7; }
.insight-table .insight-average>td { background:#eef1fa; font-weight:750; border-bottom:2px solid #d5dcec; }
.insight-table .insight-select-cell { min-width:34px; width:34px; padding:.55rem; text-align:center; position:sticky; left:0; z-index:1; background:#fff; }
.insight-select-cell input { width:16px; height:16px; accent-color:#5860ad; cursor:pointer; }
#oversight-tab-pane .insight-table,#memory-progress-tab-pane .insight-table { border-collapse:separate; border-spacing:0; }
#oversight-tab-pane .insight-table tr:not(.insight-detail-row):not(.insight-column-groups)>:nth-child(2),
#memory-progress-tab-pane .insight-table tr:not(.insight-detail-row):not(.insight-column-groups)>:nth-child(2) { position:sticky; left:34px; z-index:1; min-width:150px; max-width:195px; background:#fff; box-shadow:2px 0 0 #e4e8f0; }
#oversight-tab-pane .insight-table thead tr:not(.insight-column-groups)>:nth-child(2),
#memory-progress-tab-pane .insight-table thead tr:not(.insight-column-groups)>:nth-child(2) { background:#f0f3fa; }
#oversight-tab-pane .insight-table .insight-average>:nth-child(2),
#memory-progress-tab-pane .insight-table .insight-average>:nth-child(2) { background:#eef1fa; }
.insight-topic-summary { font-size:.8rem; margin:.5rem 0 .8rem; color:#596a80; }

.insight-select-cell span { display:block; font-size:.62rem; font-weight:500; line-height:1.1; }
/* Colour identifies metric families, not an invented performance threshold. */
.insight-group-homework { --insight-tint:#f2f6ff; --insight-shade:#eaf1ff; --insight-head:#dbe7ff; --insight-ink:#285aa0; --insight-edge:#b4c9eb; }
.insight-group-activity { --insight-tint:#f0f9f5; --insight-shade:#e7f5ee; --insight-head:#d2eee1; --insight-ink:#216c53; --insight-edge:#aed6c5; }
.insight-group-questions { --insight-tint:#fffaf0; --insight-shade:#fff4df; --insight-head:#ffebbf; --insight-ink:#815918; --insight-edge:#e7d19e; }
.insight-group-timings { --insight-tint:#f8f4ff; --insight-shade:#f1eafa; --insight-head:#e7dcf8; --insight-ink:#70539c; --insight-edge:#ccbae6; }
.insight-group-learning { --insight-tint:#eef8fb; --insight-shade:#e4f2f7; --insight-head:#d0eaf2; --insight-ink:#286b80; --insight-edge:#acd1de; }
.insight-table thead th[class*="insight-group-"] { background:var(--insight-tint,#f0f3fa); color:var(--insight-ink,#43536b); }
.insight-table .insight-column-groups th[class*="insight-group-"] { background:var(--insight-head,#e9edf6); color:var(--insight-ink,#43536b); padding:.5rem .65rem; }
.insight-table tbody>tr:not(.insight-detail-row):not(.insight-average)>td[class*="insight-group-"] { background:var(--insight-tint,#fff); }
.insight-table tbody>tr:nth-child(odd):not(.insight-detail-row):not(.insight-average)>td[class*="insight-group-"] { background:var(--insight-shade,#f7f9fc); }
.insight-table .insight-group-start { border-left:2px solid var(--insight-edge,#d8e0ec); }
.insight-table td[class*="insight-group-"]:not(.insight-group-student) { text-align:right; }
.insight-table .insight-average>td { background:#e6ebf6; color:#283c60; border-top:1px solid #c8d4e8; border-bottom:2px solid #b8c8e0; }
.insight-value-meter { display:flex; flex-direction:column; align-items:end; gap:.3rem; min-width:46px; }
.insight-meter-track { display:block; width:100%; max-width:65px; height:4px; border-radius:4px; background:#dfe4eb; overflow:hidden; }
.insight-meter-track>span { display:block; height:100%; background:var(--insight-ink,#5860ad); border-radius:inherit; }
.insight-table tbody>tr:not(.insight-detail-row):hover>td[class*="insight-group-"] { box-shadow:inset 0 1px #b6c1d3,inset 0 -1px #b6c1d3; }
