:root {
    --purple: #6d28d9;
    --purple-soft: #ede9fe;
    --purple-light: #f5f3ff;
    --purple-dark: #4c1d95;
    --white: #ffffff;
    --ink: #1f2937;
    --muted: #6b7280;
    --line: #e5e7eb;
    --bg: #faf9ff;
    --success: #15803d;
    --danger: #b91c1c;
    --warning: #a16207;
    --shadow: 0 18px 45px rgba(76, 29, 149, .08);
}

* { box-sizing: border-box; }
body {
    margin: 0;
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: linear-gradient(135deg, #ffffff 0%, var(--bg) 45%, #f4f0ff 100%);
    color: var(--ink);
}

a { color: inherit; text-decoration: none; }

.app-shell { display: flex; min-height: 100vh; }
.sidebar {
    width: 280px;
    padding: 24px;
    background: rgba(255,255,255,.88);
    border-right: 1px solid var(--line);
    position: sticky;
    top: 0;
    height: 100vh;
}
.brand-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px;
    border-radius: 24px;
    background: var(--purple-light);
    border: 1px solid #ddd6fe;
}
.brand-mark {
    width: 44px; height: 44px;
    border-radius: 15px;
    background: var(--purple);
    color: white;
    display: grid;
    place-items: center;
    font-weight: 800;
}
.brand-title { font-weight: 800; color: var(--purple-dark); }
.brand-subtitle { font-size: 12px; color: var(--muted); }
.nav-list { display: grid; gap: 10px; margin-top: 24px; }
.nav-link {
    padding: 12px 14px;
    border-radius: 16px;
    color: var(--muted);
    font-weight: 700;
}
.nav-link.active, .nav-link:hover { background: var(--purple); color: #fff; }

.main-content { flex: 1; padding: 32px; overflow-x: hidden; }
.page-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 22px;
}
.page-header.compact { margin-bottom: 16px; }
.eyebrow {
    margin: 0 0 6px;
    color: var(--purple);
    font-size: 12px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: .08em;
}
h1 { margin: 0; font-size: clamp(28px, 4vw, 42px); color: var(--purple-dark); }
h2 { margin: 0; font-size: 21px; color: var(--purple-dark); }
.header-copy, .panel-header p { color: var(--muted); margin: 8px 0 0; max-width: 760px; }

.btn {
    border: 0;
    border-radius: 15px;
    padding: 12px 16px;
    font-weight: 800;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    white-space: nowrap;
}
.btn.primary { background: var(--purple); color: white; box-shadow: 0 12px 28px rgba(109, 40, 217, .22); }
.btn.ghost { background: var(--purple-soft); color: var(--purple-dark); }
.btn.small { padding: 8px 11px; font-size: 13px; border-radius: 12px; }
.btn:disabled { opacity: .55; cursor: not-allowed; }

.btn.back-dashboard-btn {
    background: #2563eb;
    color: #ffffff;
    padding: 10px 18px;
    min-width: 88px;
    min-height: 38px;
    border-radius: 14px;
    font-size: 14px;
    font-weight: 900;
    box-shadow: 0 12px 28px rgba(37, 99, 235, .24);
    text-decoration: none;
}

.btn.back-dashboard-btn:hover {
    background: #1d4ed8;
    color: #ffffff;
}


.panel, .stat-card, .info-strip {
    background: rgba(255,255,255,.92);
    border: 1px solid var(--line);
    border-radius: 26px;
    box-shadow: var(--shadow);
}
.panel { padding: 22px; margin-bottom: 20px; }
.panel-header { display: flex; justify-content: space-between; gap: 14px; align-items: flex-start; margin-bottom: 16px; }
.stats-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin-bottom: 20px; }
.stat-card { padding: 18px; }
.stat-card span { color: var(--muted); font-weight: 700; font-size: 13px; }
.stat-card strong { display: block; font-size: 30px; color: var(--purple-dark); margin-top: 8px; }

.table-wrap, .assessment-table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
th {
    text-align: left;
    color: var(--purple-dark);
    background: var(--purple-light);
    font-size: 13px;
    padding: 13px 12px;
    border-bottom: 1px solid #ddd6fe;
}
td { padding: 14px 12px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.dashboard-table tr:hover td { background: #fcfbff; }
.block { display: block; }
.muted { color: var(--muted); font-size: 12px; }
.score-pill {
    display: inline-block;
    min-width: 68px;
    text-align: center;
    padding: 6px 10px;
    border-radius: 999px;
    background: var(--purple-soft);
    color: var(--purple-dark);
    font-weight: 800;
}
.empty-state { text-align: center; padding: 40px; color: var(--muted); }

.alert { padding: 14px 16px; border-radius: 18px; margin-bottom: 18px; font-weight: 700; }
.alert.success { background: #ecfdf5; color: #166534; border: 1px solid #bbf7d0; }
.alert.error { background: #fef2f2; color: #991b1b; border: 1px solid #fecaca; }
.alert ul { margin-bottom: 0; }

.student-form { display: grid; gap: 16px; }
.form-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
label span { display: block; color: var(--muted); font-weight: 800; margin-bottom: 7px; font-size: 13px; }
input, textarea {
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 12px 13px;
    font: inherit;
    background: white;
    outline: none;
}
input:focus, textarea:focus { border-color: var(--purple); box-shadow: 0 0 0 4px var(--purple-soft); }
.form-actions { display: flex; justify-content: flex-end; }
.info-strip {
    padding: 14px 18px;
    margin-bottom: 18px;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    color: var(--muted);
    font-size: 13px;
}
.info-strip strong { color: var(--purple-dark); }

.sem-grid { display: grid; grid-template-columns: repeat(4, minmax(250px, 1fr)); gap: 14px; margin-top: 16px; }
.sem-card { background: var(--purple-light); border: 1px solid #ddd6fe; border-radius: 22px; padding: 14px; }
.sem-card.locked { opacity: .68; filter: grayscale(.25); }
.sem-card-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; }
.unlock-btn, .mini-unlock {
    width: 28px; height: 28px;
    border-radius: 10px;
    border: 1px solid #c4b5fd;
    background: white;
    color: var(--purple);
    font-weight: 900;
    cursor: pointer;
}
.mini-unlock { width: 23px; height: 23px; font-size: 12px; vertical-align: middle; }
.date-row { display: grid; gap: 8px; margin-bottom: 12px; }
.lock-badge { display: block; margin-top: 10px; color: var(--muted); font-size: 12px; font-weight: 800; }
.lock-badge.open { color: var(--success); }
.lock-badge.locked { color: var(--warning); }

.module-title-row { display: flex; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.assessment-table { min-width: 1280px; }
.assessment-col { width: 310px; }
.assessment-text { font-weight: 700; color: #374151; }
.sem-head { text-align: center; background: #eee8ff; }
.assessment-table th:not(.assessment-col), .assessment-table td:not(.assessment-text) { text-align: center; }
.check-box {
    width: 34px; height: 34px;
    border-radius: 10px;
    border: 2px solid #c4b5fd;
    background: #fff;
    color: white;
    cursor: pointer;
    font-weight: 900;
    font-size: 18px;
}
.check-box.selected { background: var(--success); border-color: var(--success); }
.check-box.selected.no { background: var(--danger); border-color: var(--danger); }
.check-box.locked { background: #f3f4f6; color: #9ca3af; border-color: #d1d5db; cursor: not-allowed; }
.cell-status { color: var(--muted); font-size: 12px; font-weight: 800; }
.cell-status.saved { color: var(--success); }
.cell-status.saving { color: var(--warning); }
.score-table .overall { font-weight: 900; color: var(--purple-dark); background: var(--purple-light); }
.toast {
    position: fixed;
    right: 22px;
    bottom: 22px;
    background: var(--purple-dark);
    color: white;
    padding: 13px 16px;
    border-radius: 16px;
    box-shadow: var(--shadow);
    z-index: 1000;
    font-weight: 800;
}

@media (max-width: 1100px) {
    .app-shell { display: block; }
    .sidebar { width: auto; height: auto; position: static; display: flex; justify-content: space-between; align-items: center; gap: 14px; }
    .nav-list { margin-top: 0; grid-auto-flow: column; }
    .stats-grid, .form-grid, .info-strip { grid-template-columns: repeat(2, 1fr); }
    .sem-grid { grid-template-columns: repeat(2, minmax(240px, 1fr)); }
}

@media (max-width: 720px) {
    .main-content, .sidebar { padding: 18px; }
    .page-header { align-items: flex-start; flex-direction: column; }
    .stats-grid, .form-grid, .info-strip, .sem-grid { grid-template-columns: 1fr; }
    .sidebar { display: block; }
    .nav-list { grid-auto-flow: row; }
}

.assessment-table-wide {
    min-width: 1850px;
}
.assessment-table-wide .assessment-col {
    width: 275px;
    min-width: 275px;
}
.assessment-table-wide .answer-col {
    width: 58px;
    min-width: 58px;
    text-align: center;
}
.assessment-table-wide .status-col {
    width: 82px;
    min-width: 82px;
    text-align: center;
}
.sem-assessment-head {
    background: var(--purple-light);
    vertical-align: middle;
}
.sem-assessment-text {
    text-align: left !important;
    line-height: 1.35;
    color: #111827;
}

/* Hamburger sidebar menu */
.app-shell {
    display: block;
}
.hamburger-btn {
    position: fixed;
    top: 14px;
    left: 14px;
    z-index: 1200;
    width: 42px;
    height: 42px;
    border: 1px solid #ddd6fe;
    border-radius: 12px;
    background: #ffffff;
    box-shadow: 0 10px 24px rgba(76, 29, 149, .12);
    display: grid;
    place-content: center;
    gap: 4px;
    cursor: pointer;
}
.hamburger-btn span {
    display: block;
    width: 20px;
    height: 2px;
    border-radius: 999px;
    background: var(--purple-dark);
}
.sidebar {
    position: fixed;
    top: 0;
    left: 0;
    z-index: 1100;
    width: 260px;
    max-width: 82vw;
    height: 100vh;
    transform: translateX(-105%);
    transition: transform .22s ease;
    box-shadow: 18px 0 45px rgba(76, 29, 149, .13);
}
.sidebar-open .sidebar {
    transform: translateX(0);
}
.sidebar-backdrop {
    position: fixed;
    inset: 0;
    z-index: 1000;
    background: rgba(17, 24, 39, .28);
    opacity: 0;
    pointer-events: none;
    transition: opacity .18s ease;
}
.sidebar-open .sidebar-backdrop {
    opacity: 1;
    pointer-events: auto;
}
.main-content {
    width: 100%;
    padding: 26px 26px 26px 70px;
    overflow-x: hidden;
}

/* Compact typography and no horizontal module-table scrollbar */
body {
    font-size: 13px;
}
h1 {
    font-size: clamp(22px, 3vw, 32px);
}
h2 {
    font-size: 17px;
}
.eyebrow {
    font-size: 10px;
    margin-bottom: 4px;
}
.header-copy,
.panel-header p,
.info-strip,
label span,
.muted {
    font-size: 11px;
}
.btn {
    padding: 9px 12px;
    border-radius: 12px;
    font-size: 12px;
}
.panel {
    padding: 16px;
    margin-bottom: 16px;
    border-radius: 20px;
}
.module-title-row {
    margin-bottom: 10px;
}
.assessment-table-wrap {
    overflow-x: hidden;
    width: 100%;
}
.assessment-table,
.assessment-table-wide {
    width: 100%;
    min-width: 0;
    table-layout: fixed;
}
.assessment-table th,
.assessment-table td {
    padding: 5px 4px;
    font-size: 9px;
    line-height: 1.2;
    overflow-wrap: anywhere;
    word-break: normal;
}
.assessment-table-wide .assessment-col,
.assessment-table .assessment-col,
.sem-assessment-text {
    width: 16.8%;
    min-width: 0;
}
.assessment-table-wide .answer-col {
    width: 2.5%;
    min-width: 0;
}
.assessment-table-wide .status-col {
    width: 3.2%;
    min-width: 0;
}
.assessment-text {
    font-weight: 700;
}
.check-box {
    width: 18px;
    height: 18px;
    border-radius: 5px;
    border-width: 1px;
    font-size: 11px;
    padding: 0;
    line-height: 1;
}
.cell-status {
    font-size: 8px;
    font-weight: 800;
}
.mini-unlock {
    width: 17px;
    height: 17px;
    border-radius: 6px;
    font-size: 9px;
    padding: 0;
}
th {
    font-size: 11px;
    padding: 8px 7px;
}
td {
    padding: 9px 7px;
}
.score-table th,
.score-table td,
.dashboard-table th,
.dashboard-table td {
    font-size: 11px;
}
.sem-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}
.sem-card {
    padding: 10px;
    border-radius: 16px;
}
input,
textarea {
    padding: 9px 10px;
    border-radius: 11px;
    font-size: 12px;
}

@media (max-width: 1100px) {
    .app-shell { display: block; }
    .sidebar {
        position: fixed;
        width: 260px;
        height: 100vh;
        display: block;
    }
    .nav-list {
        grid-auto-flow: row;
        margin-top: 24px;
    }
    .main-content {
        padding: 22px 16px 22px 64px;
    }
    .sem-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 720px) {
    .main-content {
        padding: 68px 12px 18px;
    }
    .hamburger-btn {
        top: 12px;
        left: 12px;
    }
    .sem-grid {
        grid-template-columns: 1fr;
    }
    .assessment-table th,
    .assessment-table td {
        font-size: 8px;
        padding: 4px 2px;
    }
    .check-box {
        width: 15px;
        height: 15px;
    }
    .cell-status {
        font-size: 7px;
    }
}

/* Latest assessment table adjustments */
.assessment-table th,
.assessment-table td {
    font-size: 10.5px;
    padding: 6px 5px;
    line-height: 1.25;
}
.assessment-table-wide .assessment-col,
.assessment-table .assessment-col,
.sem-assessment-text {
    width: 18.5%;
    min-width: 0;
}
.assessment-table-wide .answer-col {
    width: 3.25%;
    min-width: 0;
}
.check-box {
    width: 20px;
    height: 20px;
    font-size: 12px;
}
.mini-unlock {
    width: 18px;
    height: 18px;
    font-size: 10px;
}

.result-summary-table {
    width: auto;
    max-width: 940px;
    table-layout: fixed;
    border: 2px solid #111827;
    background: #fff;
}
.result-summary-table th,
.result-summary-table td {
    border: 1px solid #111827;
    padding: 7px 8px;
    color: #000;
    font-size: 13px;
    line-height: 1.2;
    text-align: center;
    background: #f3f4f6;
}
.result-summary-table th {
    background: #fff;
    font-weight: 900;
}
.result-summary-table .score-sem-head,
.result-summary-table .result-title-col {
    font-size: 14px;
}
.result-summary-table .module-result-name {
    width: 190px;
    text-align: left;
    font-weight: 900;
    background: #fff;
}
.result-summary-table .age-result-cell {
    width: 110px;
    background: #d9d9d9;
}
.result-summary-table td:nth-child(n+3) {
    background: #d9d9d9;
    font-weight: 800;
}
.dashboard-table td[rowspan] {
    vertical-align: middle;
}

@media (max-width: 720px) {
    .assessment-table th,
    .assessment-table td {
        font-size: 9px;
        padding: 4px 2px;
    }
    .check-box {
        width: 16px;
        height: 16px;
    }
}
.result-summary-table [data-score-achieved],
.result-summary-table [data-score-assessed],
.result-summary-table [data-score-percentage] {
    background: #d9d9d9;
    font-weight: 800;
}

/* Unlock button state fix */
.unlock-btn.unlocked,
.mini-unlock.unlocked {
    background: var(--success);
    border-color: var(--success);
    color: #fff;
}

/* Dashboard filter and 2-row student list */
.dashboard-filter-panel {
    margin-bottom: 14px;
}
.dashboard-filter-form {
    display: grid;
    grid-template-columns: minmax(190px, 1.15fr) minmax(190px, 1.15fr) minmax(160px, 1fr) minmax(260px, 1.45fr) auto;
    gap: 12px;
    align-items: end;
}
.dashboard-filter-form .teacher-filter-field {
    min-width: 260px;
}
.dashboard-filter-form label {
    display: grid;
    gap: 6px;
}
.dashboard-filter-form select {
    width: 100%;
    border: 1px solid #ddd6fe;
    border-radius: 11px;
    padding: 9px 10px;
    font: inherit;
    background: #fff;
    color: var(--text);
}
.filter-actions {
    display: flex;
    gap: 8px;
    align-items: center;
    justify-content: flex-end;
}
.dashboard-table td[rowspan] {
    vertical-align: middle;
    background: #fff;
}
.dashboard-table th,
.dashboard-table td {
    white-space: normal;
}
@media (max-width: 900px) {
    .dashboard-filter-form {
        grid-template-columns: 1fr 1fr;
    }
    .filter-actions {
        justify-content: flex-start;
    }
}
@media (max-width: 620px) {
    .dashboard-filter-form {
        grid-template-columns: 1fr;
    }
}

.header-actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.sem-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 8px; }
.open-sem-btn { min-width: 92px; }
.report-notes-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 42px; }
.report-note-block { min-height: 330px; padding: 8px 10px; }
.report-note-block h3 { text-align: center; font-family: Georgia, 'Times New Roman', serif; font-size: 18px; color: #111827; margin: 0 0 16px; font-weight: 600; }
.comment-row { display: grid; grid-template-columns: 135px 1fr; align-items: start; gap: 12px; margin-bottom: 12px; }
.comment-row > span { font-family: Georgia, 'Times New Roman', serif; font-size: 16px; color: #111827; font-weight: 400; padding-top: 10px; }
.comment-row textarea { border: 0; border-bottom: 1px solid #111827; border-radius: 0; resize: vertical; min-height: 42px; padding: 8px; font-family: Georgia, 'Times New Roman', serif; background: transparent; box-shadow: none; }
.parent-signature-space { height: 120px; padding-top: 28px; font-family: Georgia, 'Times New Roman', serif; font-size: 16px; color: #111827; }
.signature-line { display: grid; grid-template-columns: 52px 1fr; align-items: center; max-width: 300px; margin-bottom: 8px; font-family: Georgia, 'Times New Roman', serif; font-size: 16px; }
.signature-line span { font-weight: 400; color: #111827; }
.signature-line input { border: 0; border-bottom: 1px solid #111827; border-radius: 0; padding: 5px 6px; background: transparent; box-shadow: none; }

@media (max-width: 900px) {
    .report-notes-grid { grid-template-columns: 1fr; gap: 20px; }
}

@media print {
    @page { size: A4 landscape; margin: 8mm; }
    body { background: #fff !important; color: #000 !important; font-family: Arial, sans-serif; }
    .sidebar, .print-hide, .toast, .btn, button, .nav-list { display: none !important; }
    .app-shell { display: block !important; min-height: 0 !important; }
    .main-content { padding: 0 !important; overflow: visible !important; }
    .panel, .stat-card, .info-strip { box-shadow: none !important; border: 1px solid #000 !important; border-radius: 0 !important; background: #fff !important; padding: 10px !important; margin-bottom: 10px !important; break-inside: avoid; }
    .student-panel input, .report-notes-panel input, .report-notes-panel textarea { border: 0 !important; border-bottom: 1px solid #000 !important; border-radius: 0 !important; background: transparent !important; padding: 3px 4px !important; box-shadow: none !important; }
    .student-form .form-grid { grid-template-columns: repeat(4, 1fr) !important; gap: 8px !important; }
    label span { color: #000 !important; font-size: 10px !important; }
    h1, h2, .eyebrow { color: #000 !important; }
    .module-title-row { margin-bottom: 6px !important; }
    .assessment-table-wrap, .table-wrap { overflow: visible !important; }
    .assessment-table { min-width: 0 !important; width: 100% !important; font-size: 8px !important; table-layout: fixed !important; }
    .assessment-col { width: auto !important; }
    th, td { border: 1px solid #000 !important; padding: 3px 4px !important; color: #000 !important; background: #fff !important; }
    .check-box { display: inline-flex !important; width: 14px !important; height: 14px !important; min-width: 14px !important; border: 1px solid #000 !important; border-radius: 2px !important; color: #000 !important; background: #fff !important; font-size: 10px !important; line-height: 1 !important; align-items: center !important; justify-content: center !important; padding: 0 !important; }
    .check-box.selected, .check-box.selected.no { background: #fff !important; color: #000 !important; }
    .score-table { font-size: 8px !important; }
    .report-notes-grid { grid-template-columns: repeat(2, 1fr) !important; gap: 24px !important; }
    .report-notes-panel { border: 0 !important; }
    .report-note-block h3, .comment-row > span, .parent-signature-space, .signature-line { font-family: Georgia, 'Times New Roman', serif !important; color: #000 !important; }
    .comment-row textarea { min-height: 34px !important; resize: none !important; }
    .parent-signature-space { height: 90px !important; }
}

/* 2026-05-20: School label, readable module table, edit/submit placement */
body {
    font-size: 14px;
}
h1 {
    font-size: clamp(25px, 3vw, 36px);
}
h2 {
    font-size: 19px;
}
label span,
.header-copy,
.panel-header p,
.info-strip,
.muted {
    font-size: 12.5px;
}
.assessment-table-wrap {
    overflow-x: auto;
}
.assessment-table,
.assessment-table-wide {
    min-width: 1760px;
    table-layout: fixed;
}
.assessment-table th,
.assessment-table td {
    font-size: 12px;
    padding: 8px 7px;
    line-height: 1.35;
    vertical-align: middle;
}
.assessment-table-wide .assessment-col,
.assessment-table .assessment-col,
.sem-assessment-text {
    width: 19%;
    min-width: 255px;
}
.assessment-table-wide .answer-col {
    width: 3.75%;
    min-width: 52px;
}
.sem-assessment-text {
    text-align: left !important;
    word-break: normal;
    overflow-wrap: break-word;
}
.check-box {
    width: 24px;
    height: 24px;
    font-size: 14px;
    border-radius: 7px;
}
.edit-sem-btn {
    min-width: 72px;
}
.open-sem-btn {
    min-width: 0;
}
.submit-sem-row td {
    background: #faf7ff;
    border-top: 2px solid #ddd6fe;
    text-align: center !important;
    padding-top: 10px;
    padding-bottom: 10px;
}
.submit-sem-cell .btn {
    margin: 0 auto;
}
.comment-row input {
    border: 0;
    border-bottom: 1px solid #111827;
    border-radius: 0;
    padding: 8px;
    font-family: Georgia, 'Times New Roman', serif;
    background: transparent;
    box-shadow: none;
}
.comment-row input:focus {
    box-shadow: none;
}

@media (max-width: 720px) {
    .assessment-table th,
    .assessment-table td {
        font-size: 10px;
        padding: 5px 3px;
    }
    .check-box {
        width: 18px;
        height: 18px;
    }
}

@media print {
    .student-panel input,
    .report-notes-panel input {
        border: 0 !important;
        border-bottom: 1px solid #000 !important;
        border-radius: 0 !important;
        background: transparent !important;
        padding: 3px 4px !important;
        box-shadow: none !important;
    }
    .assessment-table,
    .assessment-table-wide {
        min-width: 0 !important;
    }
    .assessment-table th,
    .assessment-table td {
        font-size: 8px !important;
        padding: 3px 3px !important;
    }
    .comment-row input {
        height: auto !important;
        min-height: 0 !important;
        overflow: visible !important;
        font-family: Georgia, 'Times New Roman', serif !important;
        color: #000 !important;
    }
}

/* 2026-05-20 redo: one submit at Module 6, larger table text, centered score, two-line remarks */
.score-panel .table-wrap {
    display: flex;
    justify-content: center;
    width: 100%;
}
.score-panel .result-summary-table {
    margin-left: auto;
    margin-right: auto;
}
.assessment-table,
.assessment-table-wide {
    min-width: 1960px;
}
.assessment-table th,
.assessment-table td {
    font-size: 14px;
    padding: 10px 9px;
    line-height: 1.45;
}
.assessment-table th {
    font-size: 13.5px;
    font-weight: 900;
}
.sem-assessment-text {
    font-weight: 700;
}
.assessment-table-wide .assessment-col,
.assessment-table .assessment-col,
.sem-assessment-text {
    min-width: 300px;
}
.assessment-table-wide .answer-col {
    min-width: 58px;
}
.check-box {
    width: 28px;
    height: 28px;
    font-size: 16px;
}
.submit-assessment-row td {
    background: #faf7ff;
    border-top: 2px solid #ddd6fe;
    padding: 16px 10px !important;
    text-align: center !important;
}
.submit-assessment-cell .btn,
.submit-all-assessment {
    margin: 0 auto;
    min-width: 190px;
}
.print-only {
    display: none;
}
.comment-row {
    grid-template-columns: 145px 1fr;
}
.comment-row .remark-field {
    min-height: 54px;
    height: 54px;
    line-height: 1.35;
    border: 0;
    border-bottom: 1px solid #111827;
    border-radius: 0;
    padding: 6px 8px;
    font-family: Georgia, 'Times New Roman', serif;
    background: transparent;
    box-shadow: none;
    resize: vertical;
    overflow: auto;
    white-space: pre-wrap;
}
.comment-row .remark-field:focus {
    box-shadow: none;
}

@media (max-width: 720px) {
    .assessment-table th,
    .assessment-table td {
        font-size: 12px;
        padding: 7px 5px;
    }
}

@media print {
    .assessment-table th,
    .assessment-table td {
        font-size: 8.5px !important;
        padding: 3px 3px !important;
    }
    .print-only {
        display: block !important;
    }
    .comment-row .remark-field {
        display: none !important;
    }
    .remark-print-value {
        min-height: 34px;
        line-height: 1.2;
        white-space: pre-wrap;
        overflow-wrap: anywhere;
        border-bottom: 1px solid #000;
        padding: 2px 4px 4px;
        font-family: Georgia, 'Times New Roman', serif !important;
        color: #000 !important;
    }
}

/* 2026-05-20 refinement: compact readable module tables, larger summary text, aligned dynamic print comments */
.assessment-table-wrap {
    overflow-x: hidden !important;
    width: 100%;
}
.assessment-table,
.assessment-table-wide {
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
    table-layout: fixed !important;
}
.assessment-table th,
.assessment-table td {
    font-size: 13.5px !important;
    padding: 7px 5px !important;
    line-height: 1.28 !important;
    vertical-align: middle !important;
}
.assessment-table th {
    font-size: 13px !important;
}
.assessment-table-wide .assessment-col,
.assessment-table .assessment-col,
.sem-assessment-text {
    width: 19.1% !important;
    min-width: 0 !important;
}
.assessment-table-wide .answer-col {
    width: 2.95% !important;
    min-width: 0 !important;
}
.sem-assessment-text {
    overflow-wrap: anywhere !important;
    word-break: normal !important;
}
.check-box {
    width: 25px !important;
    height: 25px !important;
    font-size: 15px !important;
}
.result-summary-table th,
.result-summary-table td {
    font-size: 14px !important;
    padding: 8px 9px !important;
    line-height: 1.25 !important;
}
.result-summary-table .score-sem-head,
.result-summary-table .result-title-col {
    font-size: 15px !important;
}
.result-summary-table {
    max-width: 1040px !important;
}
.comment-row .remark-field {
    min-height: 64px !important;
    height: 64px !important;
    line-height: 1.35 !important;
}

@supports (grid-template-rows: subgrid) {
    .report-notes-grid {
        grid-template-rows: auto auto auto auto auto auto;
        align-items: stretch;
    }
    .report-note-block {
        display: grid;
        grid-template-rows: subgrid;
        grid-row: span 6;
        align-content: start;
        min-height: 0;
    }
    .report-note-block h3,
    .report-note-block .comment-row,
    .report-note-block .parent-signature-space,
    .report-note-block .signature-line {
        margin-top: 0;
    }
}

@media print {
    .report-notes-grid {
        display: grid !important;
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
        gap: 22px !important;
        align-items: stretch !important;
    }
    @supports (grid-template-rows: subgrid) {
        .report-notes-grid {
            grid-template-rows: auto auto auto auto auto auto !important;
        }
        .report-note-block {
            display: grid !important;
            grid-template-rows: subgrid !important;
            grid-row: span 6 !important;
            min-height: 0 !important;
        }
    }
    .report-note-block {
        padding: 0 4px !important;
    }
    .report-note-block h3 {
        font-size: 16px !important;
        margin: 0 0 8px !important;
    }
    .comment-row {
        grid-template-columns: 98px 1fr !important;
        gap: 8px !important;
        margin-bottom: 8px !important;
        align-items: start !important;
    }
    .comment-row > span {
        font-size: 12px !important;
        padding-top: 3px !important;
        line-height: 1.2 !important;
    }
    .remark-print-value {
        min-height: 30px !important;
        height: auto !important;
        max-height: none !important;
        white-space: pre-wrap !important;
        overflow-wrap: anywhere !important;
        word-break: break-word !important;
        overflow: visible !important;
        font-size: 12px !important;
        line-height: 1.18 !important;
        padding: 0 3px 3px !important;
    }
    .parent-signature-space {
        height: 72px !important;
        padding-top: 18px !important;
        font-size: 13px !important;
    }
    .signature-line {
        grid-template-columns: 42px 1fr !important;
        max-width: 260px !important;
        margin-bottom: 5px !important;
        font-size: 12px !important;
    }
    .signature-line input {
        font-size: 12px !important;
        padding: 2px 3px !important;
    }
    .assessment-table th,
    .assessment-table td {
        font-size: 8px !important;
        padding: 2px 2px !important;
        line-height: 1.12 !important;
    }
    .result-summary-table th,
    .result-summary-table td {
        font-size: 9px !important;
        padding: 3px 4px !important;
    }
}


/* 2026-05-20: static student details on edit page */
.student-static-panel {
    padding: 16px 18px;
    margin-bottom: 18px;
}
.student-static-head {
    margin-bottom: 10px;
}
.student-static-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
}
.student-static-item {
    border: 1px solid #e5e7eb;
    background: #faf7ff;
    border-radius: 16px;
    padding: 12px 14px;
    min-height: 68px;
}
.student-static-item span {
    display: block;
    color: var(--muted);
    font-size: 12px;
    font-weight: 900;
    margin-bottom: 6px;
}
.student-static-item strong {
    display: block;
    color: #1f2937;
    font-size: 15px;
    font-weight: 900;
    line-height: 1.25;
    overflow-wrap: anywhere;
}

@media (max-width: 900px) {
    .student-static-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}
@media (max-width: 560px) {
    .student-static-grid {
        grid-template-columns: 1fr;
    }
}

@media print {
    .student-static-panel {
        border: 1px solid #000 !important;
        padding: 6px !important;
        margin-bottom: 8px !important;
        break-inside: avoid;
    }
    .student-static-head {
        margin-bottom: 4px !important;
    }
    .student-static-grid {
        grid-template-columns: repeat(4, 1fr) !important;
        gap: 4px !important;
    }
    .student-static-item {
        border: 1px solid #000 !important;
        background: #fff !important;
        border-radius: 0 !important;
        padding: 4px 5px !important;
        min-height: 0 !important;
    }
    .student-static-item span {
        color: #000 !important;
        font-size: 8px !important;
        margin-bottom: 2px !important;
    }
    .student-static-item strong {
        color: #000 !important;
        font-size: 10px !important;
        line-height: 1.15 !important;
    }
}

/* 2026-05-21: compact page width + clearer dashboard/assessment table readability */
.main-content {
    width: 100%;
    max-width: 1580px;
    margin: 0 auto;
    padding-left: 24px;
    padding-right: 24px;
}

.page-header,
.panel,
.stats-grid {
    width: 100%;
}

/* Teacher dashboard: larger text and visible row/column lines */
.dashboard-table {
    border-collapse: collapse !important;
    table-layout: fixed;
    font-size: 15.5px;
    border: 1px solid #d8dceb;
    background: #ffffff;
}
.dashboard-table th,
.dashboard-table td {
    border: 1px solid #d8dceb !important;
    border-bottom: 1px solid #d8dceb !important;
    padding: 13px 12px !important;
    font-size: 15.5px !important;
    line-height: 1.35 !important;
    vertical-align: middle !important;
}
.dashboard-table th {
    background: #f2efff !important;
    color: var(--purple-dark) !important;
    font-size: 14px !important;
    font-weight: 900 !important;
    letter-spacing: .01em;
}
.dashboard-table td[rowspan] {
    border-right: 1px solid #cfd5e6 !important;
}
.dashboard-table tbody tr:nth-child(4n+1) td,
.dashboard-table tbody tr:nth-child(4n+2) td {
    background: #ffffff;
}
.dashboard-table tbody tr:nth-child(4n+3) td,
.dashboard-table tbody tr:nth-child(4n+4) td {
    background: #fbfaff;
}
.dashboard-table tr:hover td {
    background: #f7f3ff !important;
}
.dashboard-table strong {
    font-size: 15.8px;
}
.dashboard-table .muted {
    font-size: 13px !important;
    margin-top: 4px;
}
.dashboard-table .score-pill {
    font-size: 14px;
    min-width: 74px;
    padding: 7px 10px;
}
.dashboard-table .btn.small {
    font-size: 14px;
    padding: 9px 13px;
}

.student-list-table .student-list-col-no {
    width: 70px;
}
.student-list-table .student-list-col-name {
    width: 62%;
}
.student-list-table .student-list-col-class {
    width: 22%;
}
.student-list-table th:first-child,
.student-list-table td.student-list-number {
    text-align: center;
}
.student-list-table td.student-list-number {
    font-weight: 800;
    white-space: nowrap;
}
.dashboard-filter-form label span,
.dashboard-filter-form input,
.dashboard-filter-form select {
    font-size: 15px;
}

/* Assessment page: keep page compact, readable, and without module-table scrollbars */
.module-card.panel,
.score-panel,
.report-notes-panel,
.student-static-panel,
.semester-panel,
.student-panel {
    max-width: 100%;
}
.assessment-table-wrap,
.table-wrap {
    max-width: 100%;
}
.assessment-table,
.assessment-table-wide {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    table-layout: fixed !important;
    border-collapse: collapse !important;
    border: 1px solid #d8dceb !important;
}
.assessment-table th,
.assessment-table td {
    border: 1px solid #d8dceb !important;
    font-size: 14.2px !important;
    padding: 8px 6px !important;
    line-height: 1.3 !important;
}
.assessment-table th {
    font-size: 13.6px !important;
    font-weight: 900 !important;
    background: #f2efff !important;
}
.assessment-table-wide .assessment-col,
.assessment-table .assessment-col,
.sem-assessment-text {
    width: 19.25% !important;
    min-width: 0 !important;
}
.assessment-table-wide .answer-col {
    width: 2.875% !important;
    min-width: 0 !important;
}
.sem-assessment-text {
    overflow-wrap: anywhere !important;
    word-break: normal !important;
}
.result-summary-table {
    max-width: 1120px !important;
    border-collapse: collapse !important;
    border: 1px solid #d8dceb !important;
}
.result-summary-table th,
.result-summary-table td {
    border: 1px solid #d8dceb !important;
    font-size: 15px !important;
    padding: 9px 10px !important;
}
.result-summary-table .score-sem-head,
.result-summary-table .result-title-col {
    font-size: 15.5px !important;
}

@media (min-width: 1700px) {
    .main-content {
        max-width: 1560px;
    }
}

@media (max-width: 900px) {
    .main-content {
        padding-left: 18px;
        padding-right: 18px;
        max-width: 100%;
    }
    .dashboard-table {
        min-width: 900px;
        table-layout: auto;
    }
    .table-wrap {
        overflow-x: auto;
    }
}

@media print {
    .main-content {
        max-width: none !important;
        padding: 0 !important;
    }
}

/* 2026-05-21: standalone layout, sidebar removed for dashboard and assessment pages */
.standalone-shell {
    display: block !important;
    min-height: 100vh;
    width: 100%;
}
.standalone-content {
    width: min(100% - 48px, 1560px) !important;
    max-width: 1560px !important;
    margin: 0 auto !important;
    padding: 30px 0 42px !important;
    overflow-x: hidden !important;
}
.hamburger-btn,
.sidebar,
.sidebar-backdrop,
.nav-list,
.brand-card {
    display: none !important;
}

@media (max-width: 900px) {
    .standalone-content {
        width: min(100% - 28px, 100%) !important;
        padding-top: 18px !important;
        padding-bottom: 28px !important;
    }
}

@media print {
    .standalone-content {
        width: 100% !important;
        max-width: none !important;
        padding: 0 !important;
    }
}


/* 2026-05-21: assessment form branded header/footer images */
.assessment-brand-header {
    width: 100%;
    margin: 0 0 18px;
}
.assessment-brand-header img,
.assessment-brand-footer img {
    display: block;
    width: 100%;
    height: auto;
    border: 1px solid #d8dceb;
    background: #ffffff;
}
.assessment-brand-header img {
    border-radius: 0;
    object-fit: cover;
}
.assessment-brand-actions {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 10px;
    margin-top: 12px;
}
.assessment-brand-footer {
    width: 100%;
    margin: 22px 0 0;
}
.assessment-brand-footer img {
    border-radius: 0;
}

@media (max-width: 700px) {
    .assessment-brand-actions {
        justify-content: stretch;
        flex-direction: column;
        align-items: stretch;
    }
    .assessment-brand-actions .btn {
        width: 100%;
    }
}

@media print {
    .assessment-brand-header {
        margin: 0 0 6px !important;
        break-inside: avoid;
    }
    .assessment-brand-header img,
    .assessment-brand-footer img {
        border: 0 !important;
        border-radius: 0 !important;
        width: 100% !important;
    }
    .assessment-brand-footer {
        margin-top: 8px !important;
        break-inside: avoid;
    }
}

.not-assessed-text {
    color: #111827;
    background: #f8fafc;
}

.not-assessed-cell {
    background: #f8fafc;
    text-align: center;
}

.not-assessed-mark {
    color: #94a3b8;
    font-weight: 700;
    font-size: 15px;
}


/* 2026-05-21: remove create alert and compact print layout */
@media print {
    .alert,
    .alert.success {
        display: none !important;
    }

    @page {
        size: A4 landscape;
        margin: 6mm;
    }

    html,
    body {
        width: 100% !important;
        margin: 0 !important;
        padding: 0 !important;
        background: #fff !important;
    }

    .standalone-content,
    .main-content {
        width: 100% !important;
        max-width: none !important;
        margin: 0 !important;
        padding: 0 !important;
        overflow: visible !important;
    }

    .assessment-brand-header {
        margin: 0 0 4px !important;
        break-inside: avoid !important;
        page-break-inside: avoid !important;
    }

    .assessment-brand-header img {
        width: 100% !important;
        max-height: 54px !important;
        object-fit: cover !important;
        display: block !important;
        border: 0 !important;
        border-radius: 0 !important;
    }

    .student-static-panel {
        margin: 0 0 5px !important;
        padding: 4px !important;
        border: 1px solid #000 !important;
        break-inside: avoid !important;
        page-break-inside: avoid !important;
    }

    .student-static-head {
        margin-bottom: 2px !important;
    }

    .student-static-head .eyebrow {
        font-size: 7px !important;
        line-height: 1 !important;
        margin: 0 0 2px !important;
    }

    .student-static-grid {
        grid-template-columns: repeat(4, 1fr) !important;
        gap: 2px !important;
    }

    .student-static-item {
        padding: 2px 4px !important;
        min-height: 0 !important;
        border: 1px solid #000 !important;
    }

    .student-static-item span {
        font-size: 6.5px !important;
        line-height: 1 !important;
        margin: 0 0 1px !important;
    }

    .student-static-item strong {
        font-size: 7px !important;
        line-height: 1.05 !important;
    }

    .panel {
        margin: 0 0 5px !important;
        padding: 5px !important;
        box-shadow: none !important;
        border-radius: 0 !important;
    }

    .module-card.panel {
        margin: 0 0 5px !important;
        padding: 5px !important;
        break-inside: auto !important;
        page-break-inside: auto !important;
        break-before: auto !important;
        page-break-before: auto !important;
    }

    .module-title-row {
        margin: 0 0 3px !important;
        padding: 0 !important;
    }

    .module-title-row .eyebrow {
        font-size: 6.5px !important;
        line-height: 1 !important;
        margin: 0 0 1px !important;
        letter-spacing: .08em !important;
    }

    .module-title-row h2 {
        font-size: 10px !important;
        line-height: 1.05 !important;
        margin: 0 !important;
    }

    .assessment-table-wrap,
    .table-wrap {
        overflow: visible !important;
    }

    .assessment-table,
    .assessment-table-wide {
        width: 100% !important;
        min-width: 0 !important;
        max-width: 100% !important;
        table-layout: fixed !important;
        border-collapse: collapse !important;
    }

    .assessment-table th,
    .assessment-table td {
        font-size: 6.8px !important;
        padding: 1px 1.5px !important;
        line-height: 1.05 !important;
        vertical-align: middle !important;
        border: 1px solid #000 !important;
    }

    .assessment-table th {
        font-size: 6.8px !important;
        font-weight: 900 !important;
    }

    .assessment-table-wide .assessment-col,
    .assessment-table .assessment-col,
    .sem-assessment-text {
        width: 19.4% !important;
    }

    .assessment-table-wide .answer-col {
        width: 2.8% !important;
    }

    .check-box {
        width: 9px !important;
        height: 9px !important;
        min-width: 9px !important;
        font-size: 7px !important;
        border-radius: 0 !important;
        padding: 0 !important;
    }

    .not-assessed-mark {
        font-size: 7px !important;
        line-height: 1 !important;
    }

    .score-panel,
    .report-notes-panel {
        break-inside: auto !important;
        page-break-inside: auto !important;
    }

    .assessment-brand-footer {
        margin-top: 4px !important;
        break-inside: avoid !important;
        page-break-inside: avoid !important;
    }
}

/* 2026-05-21: duration gate, summary table lines, per-semester print reports */
.sem-card-buttons {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.lock-badge.pending {
    background: #fff7ed;
    color: #9a3412;
    border-color: #fed7aa;
}

.check-box.locked {
    opacity: .45;
    cursor: not-allowed;
}

.result-summary-table,
.result-summary-table th,
.result-summary-table td {
    background: transparent !important;
    border: 1.5px solid #111827 !important;
}

.result-summary-table th,
.result-summary-table td {
    color: #111827;
}

.result-summary-table .score-sem-head {
    background: transparent !important;
}

.result-summary-table .percentage-sem-1 {
    background: #eaf4ff !important;
    color: #0f4c81 !important;
    font-weight: 900;
}

.result-summary-table .percentage-sem-2 {
    background: #f3e8ff !important;
    color: #5b21b6 !important;
    font-weight: 900;
}

.report-notes-grid-sem {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 24px;
}

.report-note-block[data-comment-sem] {
    min-height: 260px;
}

@media (max-width: 900px) {
    .sem-card-head {
        align-items: flex-start;
        gap: 10px;
    }
    .sem-card-buttons {
        justify-content: flex-start;
    }
    .report-notes-grid-sem {
        grid-template-columns: 1fr;
    }
}

@media print {
    body[data-print-scope] [data-sem-col],
    body[data-print-scope] [data-score-sem-col],
    body[data-print-scope] .result-summary-table tbody tr,
    body[data-print-scope] [data-comment-sem] {
        display: none !important;
    }

    body[data-print-scope="sem1"] [data-sem-col="1"],
    body[data-print-scope="sem2"] [data-sem-col="1"],
    body[data-print-scope="sem2"] [data-sem-col="2"],
    body[data-print-scope="sem3"] [data-sem-col="3"],
    body[data-print-scope="sem4"] [data-sem-col="3"],
    body[data-print-scope="sem4"] [data-sem-col="4"] {
        display: table-cell !important;
    }

    body[data-print-scope="sem1"] [data-score-sem-col="1"],
    body[data-print-scope="sem2"] [data-score-sem-col="1"],
    body[data-print-scope="sem2"] [data-score-sem-col="2"],
    body[data-print-scope="sem3"] [data-score-sem-col="1"],
    body[data-print-scope="sem4"] [data-score-sem-col="1"],
    body[data-print-scope="sem4"] [data-score-sem-col="2"] {
        display: table-cell !important;
    }

    body[data-print-scope="sem1"] .result-summary-table tbody tr[data-score-age="2"],
    body[data-print-scope="sem2"] .result-summary-table tbody tr[data-score-age="2"],
    body[data-print-scope="sem3"] .result-summary-table tbody tr[data-score-age="3"],
    body[data-print-scope="sem4"] .result-summary-table tbody tr[data-score-age="3"] {
        display: table-row !important;
    }

    body[data-print-scope="sem1"] [data-comment-sem="1"],
    body[data-print-scope="sem2"] [data-comment-sem="2"],
    body[data-print-scope="sem3"] [data-comment-sem="3"],
    body[data-print-scope="sem4"] [data-comment-sem="4"] {
        display: block !important;
    }

    body[data-print-scope] .assessment-table,
    body[data-print-scope] .assessment-table-wide {
        table-layout: auto !important;
    }

    body[data-print-scope] .assessment-table-wide .assessment-col,
    body[data-print-scope] .assessment-table .assessment-col,
    body[data-print-scope] .sem-assessment-text,
    body[data-print-scope] .assessment-table-wide .answer-col {
        width: auto !important;
    }

    body[data-print-scope] .result-summary-table,
    body[data-print-scope] .result-summary-table th,
    body[data-print-scope] .result-summary-table td {
        border: 1.4px solid #000 !important;
        background: transparent !important;
    }

    body[data-print-scope] .result-summary-table .percentage-sem-1 {
        background: #eaf4ff !important;
        color: #000 !important;
    }

    body[data-print-scope] .result-summary-table .percentage-sem-2 {
        background: #f3e8ff !important;
        color: #000 !important;
    }

    body[data-print-scope] .report-notes-grid-sem {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 18px !important;
    }

    body[data-print-scope="sem1"] .report-notes-grid-sem,
    body[data-print-scope="sem2"] .report-notes-grid-sem,
    body[data-print-scope="sem3"] .report-notes-grid-sem,
    body[data-print-scope="sem4"] .report-notes-grid-sem {
        grid-template-columns: 1fr !important;
    }

    body[data-print-scope] .report-note-block[data-comment-sem] {
        min-height: 170px !important;
        border: 0 !important;
        padding: 4px 8px !important;
        break-inside: avoid !important;
        page-break-inside: avoid !important;
    }

    body[data-print-scope] .report-note-block h3 {
        margin-bottom: 8px !important;
    }

    body[data-print-scope] .comment-row textarea {
        display: none !important;
    }

    body[data-print-scope] .signature-line input[type="text"] {
        border: 0 !important;
        border-bottom: 1px solid #000 !important;
        border-radius: 0 !important;
        background: transparent !important;
        box-shadow: none !important;
        padding: 3px 4px !important;
    }
}

/* 2026-05-21: compact readable per-semester print layout */
@media print {
    @page {
        size: A4 portrait;
        margin: 7mm;
    }

    body[data-print-scope] {
        background: #fff !important;
        font-size: 9.5px !important;
    }

    body[data-print-scope] .assessment-brand-header,
    body[data-print-scope] .student-static-panel,
    body[data-print-scope] .module-card.panel,
    body[data-print-scope] .score-panel,
    body[data-print-scope] .report-notes-panel {
        width: 184mm !important;
        max-width: 184mm !important;
        margin-left: auto !important;
        margin-right: auto !important;
    }

    body[data-print-scope="sem1"] .module-card.panel,
    body[data-print-scope="sem3"] .module-card.panel,
    body[data-print-scope="sem1"] .score-panel,
    body[data-print-scope="sem3"] .score-panel,
    body[data-print-scope="sem1"] .report-notes-panel,
    body[data-print-scope="sem3"] .report-notes-panel {
        width: 176mm !important;
        max-width: 176mm !important;
    }

    body[data-print-scope] .assessment-brand-header img {
        max-height: 44px !important;
        object-fit: cover !important;
        object-position: center !important;
    }

    body[data-print-scope] .student-static-panel {
        padding: 5px !important;
        margin-bottom: 5px !important;
    }

    body[data-print-scope] .student-static-head .eyebrow {
        font-size: 8.5px !important;
    }

    body[data-print-scope] .student-static-item span {
        font-size: 7.5px !important;
    }

    body[data-print-scope] .student-static-item strong {
        font-size: 8.5px !important;
    }

    body[data-print-scope] .module-card.panel {
        padding: 5px 6px !important;
        margin-bottom: 5px !important;
        border: 1px solid #000 !important;
        break-inside: auto !important;
        page-break-inside: auto !important;
    }

    body[data-print-scope] .module-title-row .eyebrow {
        font-size: 7.6px !important;
        letter-spacing: .06em !important;
    }

    body[data-print-scope] .module-title-row h2 {
        font-size: 11.5px !important;
        line-height: 1.12 !important;
    }

    body[data-print-scope] .assessment-table,
    body[data-print-scope] .assessment-table-wide {
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        table-layout: fixed !important;
        border-collapse: collapse !important;
        margin: 0 auto !important;
    }

    body[data-print-scope] .assessment-table th,
    body[data-print-scope] .assessment-table td {
        font-size: 8.7px !important;
        line-height: 1.18 !important;
        padding: 2px 3px !important;
        border: 1px solid #000 !important;
        vertical-align: top !important;
        word-break: normal !important;
        overflow-wrap: anywhere !important;
    }

    body[data-print-scope] .assessment-table th {
        font-size: 8.3px !important;
        text-align: center !important;
        vertical-align: middle !important;
        font-weight: 900 !important;
    }

    body[data-print-scope] .sem-assessment-text {
        width: auto !important;
        text-align: left !important;
        font-weight: 700 !important;
    }

    body[data-print-scope] .answer-col,
    body[data-print-scope] .answer-cell {
        width: 8mm !important;
        max-width: 8mm !important;
        min-width: 8mm !important;
        text-align: center !important;
        vertical-align: middle !important;
        padding-left: 1px !important;
        padding-right: 1px !important;
    }

    body[data-print-scope="sem2"] .answer-col,
    body[data-print-scope="sem2"] .answer-cell,
    body[data-print-scope="sem4"] .answer-col,
    body[data-print-scope="sem4"] .answer-cell {
        width: 6mm !important;
        max-width: 6mm !important;
        min-width: 6mm !important;
    }

    body[data-print-scope] .check-box {
        width: 10px !important;
        height: 10px !important;
        min-width: 10px !important;
        font-size: 8px !important;
        line-height: 1 !important;
        margin: 0 auto !important;
    }

    body[data-print-scope] .score-panel {
        padding: 7px !important;
        margin-top: 6px !important;
        border: 1px solid #000 !important;
        break-inside: avoid !important;
        page-break-inside: avoid !important;
    }

    body[data-print-scope] .score-panel .panel-header {
        margin-bottom: 5px !important;
    }

    body[data-print-scope] .score-panel h2 {
        font-size: 13px !important;
    }

    body[data-print-scope] .score-panel p {
        font-size: 8.5px !important;
        line-height: 1.25 !important;
        margin-top: 3px !important;
    }

    body[data-print-scope] .result-summary-table {
        width: 100% !important;
        table-layout: fixed !important;
        font-size: 8.5px !important;
    }

    body[data-print-scope] .result-summary-table th,
    body[data-print-scope] .result-summary-table td {
        font-size: 8.5px !important;
        line-height: 1.15 !important;
        padding: 3px 4px !important;
        border: 1.5px solid #000 !important;
    }

    body[data-print-scope] .result-summary-table .result-title-col,
    body[data-print-scope] .result-summary-table .module-result-name {
        width: 32mm !important;
    }

    body[data-print-scope] .result-summary-table .age-result-cell {
        width: 17mm !important;
    }

    body[data-print-scope] .report-notes-panel {
        padding: 7px !important;
        border: 1px solid #000 !important;
        break-inside: avoid !important;
        page-break-inside: avoid !important;
    }

    body[data-print-scope] .report-note-block[data-comment-sem] {
        min-height: 105px !important;
        padding: 4px 6px !important;
    }

    body[data-print-scope] .report-note-block h3 {
        font-size: 11px !important;
        margin-bottom: 5px !important;
    }

    body[data-print-scope] .remark-print-value,
    body[data-print-scope] .signature-line,
    body[data-print-scope] .parent-signature-space {
        font-size: 9.5px !important;
        line-height: 1.3 !important;
    }
}


/* 2026-05-21: print refinements for header/footer, static student details, and summary table widths */
@media print {
    body[data-print-scope] {
        display: flex !important;
        flex-direction: column !important;
        min-height: 277mm !important;
        background: #fff !important;
        font-size: 10px !important;
    }

    body[data-print-scope] .assessment-brand-header,
    body[data-print-scope] .student-static-panel,
    body[data-print-scope] .module-card.panel,
    body[data-print-scope] .score-panel,
    body[data-print-scope] .report-notes-panel,
    body[data-print-scope] .assessment-brand-footer {
        width: 186mm !important;
        max-width: 186mm !important;
        margin-left: auto !important;
        margin-right: auto !important;
    }

    body[data-print-scope="sem1"] .module-card.panel,
    body[data-print-scope="sem3"] .module-card.panel,
    body[data-print-scope="sem1"] .score-panel,
    body[data-print-scope="sem3"] .score-panel,
    body[data-print-scope="sem1"] .report-notes-panel,
    body[data-print-scope="sem3"] .report-notes-panel,
    body[data-print-scope="sem1"] .assessment-brand-header,
    body[data-print-scope="sem3"] .assessment-brand-header,
    body[data-print-scope="sem1"] .student-static-panel,
    body[data-print-scope="sem3"] .student-static-panel,
    body[data-print-scope="sem1"] .assessment-brand-footer,
    body[data-print-scope="sem3"] .assessment-brand-footer {
        width: 178mm !important;
        max-width: 178mm !important;
    }

    body[data-print-scope] .assessment-brand-header {
        margin-bottom: 4mm !important;
    }

    body[data-print-scope] .assessment-brand-header img {
        width: 100% !important;
        height: auto !important;
        max-height: none !important;
        object-fit: contain !important;
        object-position: center top !important;
        border: 1px solid #000 !important;
        background: #fff !important;
    }

    body[data-print-scope] .student-static-panel {
        background: transparent !important;
        border: 0 !important;
        box-shadow: none !important;
        padding: 0 !important;
        margin-bottom: 4mm !important;
    }

    body[data-print-scope] .student-static-head {
        margin: 0 0 1mm !important;
        padding: 0 !important;
    }

    body[data-print-scope] .student-static-head .eyebrow {
        margin: 0 !important;
        color: #000 !important;
        font-size: 8.4px !important;
        letter-spacing: .06em !important;
    }

    body[data-print-scope] .student-static-grid {
        display: grid !important;
        grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
        gap: 0 !important;
        border-top: 1px solid #000 !important;
        border-left: 1px solid #000 !important;
    }

    body[data-print-scope] .student-static-item {
        border-right: 1px solid #000 !important;
        border-bottom: 1px solid #000 !important;
        border-radius: 0 !important;
        background: transparent !important;
        min-height: auto !important;
        padding: 2px 3px !important;
    }

    body[data-print-scope] .student-static-item span {
        display: block !important;
        font-size: 6.8px !important;
        color: #000 !important;
        margin-bottom: 1px !important;
        font-weight: 700 !important;
        text-transform: none !important;
    }

    body[data-print-scope] .student-static-item strong {
        display: block !important;
        font-size: 8.4px !important;
        line-height: 1.2 !important;
        color: #000 !important;
        font-weight: 800 !important;
    }

    body[data-print-scope] .score-panel .panel-header {
        margin-bottom: 4px !important;
    }

    body[data-print-scope] .score-panel h2 {
        font-size: 13px !important;
        line-height: 1.15 !important;
    }

    body[data-print-scope] .result-summary-table th,
    body[data-print-scope] .result-summary-table td {
        vertical-align: top !important;
        word-break: normal !important;
        overflow-wrap: anywhere !important;
    }

    body[data-print-scope="sem1"] .result-summary-table .result-title-col,
    body[data-print-scope="sem1"] .result-summary-table .module-result-name,
    body[data-print-scope="sem3"] .result-summary-table .result-title-col,
    body[data-print-scope="sem3"] .result-summary-table .module-result-name {
        width: 56mm !important;
    }

    body[data-print-scope="sem1"] .result-summary-table .age-result-cell,
    body[data-print-scope="sem3"] .result-summary-table .age-result-cell {
        width: 16mm !important;
        white-space: nowrap !important;
    }

    body[data-print-scope="sem1"] .result-summary-table th[data-score-sem-col="1"],
    body[data-print-scope="sem1"] .result-summary-table td[data-score-sem-col="1"],
    body[data-print-scope="sem3"] .result-summary-table th[data-score-sem-col="1"],
    body[data-print-scope="sem3"] .result-summary-table td[data-score-sem-col="1"] {
        width: 20mm !important;
        text-align: center !important;
        vertical-align: middle !important;
    }

    body[data-print-scope="sem2"] .result-summary-table .result-title-col,
    body[data-print-scope="sem2"] .result-summary-table .module-result-name,
    body[data-print-scope="sem4"] .result-summary-table .result-title-col,
    body[data-print-scope="sem4"] .result-summary-table .module-result-name {
        width: 34mm !important;
    }

    body[data-print-scope="sem2"] .result-summary-table .age-result-cell,
    body[data-print-scope="sem4"] .result-summary-table .age-result-cell {
        width: 14mm !important;
        white-space: nowrap !important;
    }

    body[data-print-scope="sem2"] .result-summary-table th[data-score-sem-col],
    body[data-print-scope="sem2"] .result-summary-table td[data-score-sem-col],
    body[data-print-scope="sem4"] .result-summary-table th[data-score-sem-col],
    body[data-print-scope="sem4"] .result-summary-table td[data-score-sem-col] {
        width: 18mm !important;
        text-align: center !important;
        vertical-align: middle !important;
    }

    body[data-print-scope] .assessment-brand-footer {
        margin-top: auto !important;
        padding-top: 4mm !important;
        break-inside: avoid !important;
        page-break-inside: avoid !important;
    }

    body[data-print-scope] .assessment-brand-footer img {
        width: 100% !important;
        height: auto !important;
        max-height: none !important;
        object-fit: contain !important;
        object-position: center bottom !important;
        border: 0 !important;
        background: #fff !important;
    }
}

/* 2026-05-21: combined semester print shows only final semester comment/signature */
@media print {
    body[data-print-scope="sem2"] [data-comment-sem="1"],
    body[data-print-scope="sem4"] [data-comment-sem="3"] {
        display: none !important;
    }
}


/* 2026-05-21: sem card button colors and print duration block */
.sem-card .btn,
.sem-card .btn:disabled {
    opacity: 1 !important;
    filter: none !important;
}

.sem-card .btn.ghost {
    background: #dbeafe !important;
    color: #1d4ed8 !important;
    border: 1px solid #bfdbfe !important;
    box-shadow: none !important;
}

.sem-card .btn.primary {
    background: #8b5cf6 !important;
    color: #fff !important;
    box-shadow: none !important;
}

.print-duration-panel {
    display: none;
}

.print-duration-head h2 {
    margin: 0 0 10px;
}

.print-duration-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.print-duration-item {
    border: 1px solid #000;
    padding: 6px 8px;
    background: transparent;
}

.print-duration-title {
    font-weight: 800;
    margin-bottom: 4px;
}

.print-duration-row {
    display: grid;
    grid-template-columns: 42px 1fr;
    gap: 6px;
    font-size: 12px;
    line-height: 1.35;
}

.print-duration-row span {
    font-weight: 700;
}

@media print {
    body[data-print-scope] .print-duration-panel {
        display: block !important;
        padding: 6px 8px !important;
        margin-bottom: 5px !important;
        border: 1px solid #000 !important;
        box-shadow: none !important;
        background: #fff !important;
        break-inside: avoid !important;
        page-break-inside: avoid !important;
    }

    body[data-print-scope] .print-duration-head h2 {
        font-size: 11.5px !important;
        line-height: 1.15 !important;
        margin: 0 0 4px !important;
        color: #000 !important;
    }

    body[data-print-scope] .print-duration-grid {
        display: grid !important;
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
        gap: 4px !important;
    }

    body[data-print-scope] .print-duration-item {
        display: none !important;
        border: 1px solid #000 !important;
        padding: 4px 6px !important;
        background: transparent !important;
    }

    body[data-print-scope="sem1"] .print-duration-item[data-duration-sem="1"],
    body[data-print-scope="sem2"] .print-duration-item[data-duration-sem="1"],
    body[data-print-scope="sem2"] .print-duration-item[data-duration-sem="2"],
    body[data-print-scope="sem3"] .print-duration-item[data-duration-sem="3"],
    body[data-print-scope="sem4"] .print-duration-item[data-duration-sem="3"],
    body[data-print-scope="sem4"] .print-duration-item[data-duration-sem="4"] {
        display: block !important;
    }

    body[data-print-scope="sem1"] .print-duration-grid,
    body[data-print-scope="sem3"] .print-duration-grid {
        grid-template-columns: 1fr !important;
    }

    body[data-print-scope] .print-duration-title {
        font-size: 8.8px !important;
        line-height: 1.15 !important;
        margin-bottom: 3px !important;
        font-weight: 800 !important;
        color: #000 !important;
    }

    body[data-print-scope] .print-duration-row {
        grid-template-columns: 30px 1fr !important;
        gap: 5px !important;
        font-size: 8px !important;
        line-height: 1.2 !important;
    }

    body[data-print-scope] .remark-print-value {
        border-bottom: 0 !important;
        padding: 1px 0 2px !important;
        min-height: 20px !important;
    }

    body[data-print-scope] .comment-row {
        margin-bottom: 8px !important;
    }
}


/* 2026-05-21: clearer semester action buttons + compact summary table */
.sem-card [data-edit-sem],
.sem-card [data-print-sem] {
    opacity: 1 !important;
    filter: none !important;
    cursor: pointer !important;
    font-weight: 800 !important;
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.08) !important;
}

.sem-card [data-edit-sem],
.sem-card [data-edit-sem]:disabled {
    background: #dbeafe !important;
    color: #2563eb !important;
    border: 1px solid #93c5fd !important;
}

.sem-card [data-print-sem],
.sem-card [data-print-sem]:disabled {
    background: #a78bfa !important;
    color: #ffffff !important;
    border: 1px solid #8b5cf6 !important;
}

.sem-card [data-edit-sem]:hover,
.sem-card [data-print-sem]:hover {
    transform: translateY(-1px);
}

.score-panel .table-wrap {
    display: flex;
    justify-content: center;
}

.result-summary-table {
    width: 100% !important;
    max-width: 1160px !important;
    margin: 0 auto !important;
    table-layout: fixed !important;
}

.result-summary-table th,
.result-summary-table td {
    font-size: 12.5px !important;
    line-height: 1.18 !important;
    padding: 6px 7px !important;
}

.result-summary-table .score-sem-head,
.result-summary-table .result-title-col {
    font-size: 13px !important;
}

.result-summary-table .module-result-name,
.result-summary-table .result-title-col {
    width: 31% !important;
    text-align: left !important;
    vertical-align: middle !important;
}

.result-summary-table .age-result-cell {
    width: 9% !important;
    white-space: nowrap !important;
    text-align: center !important;
    vertical-align: middle !important;
}

.result-summary-table th[data-score-sem-col],
.result-summary-table td[data-score-sem-col] {
    width: 10% !important;
    text-align: center !important;
    vertical-align: middle !important;
    font-size: 11.5px !important;
    padding-left: 5px !important;
    padding-right: 5px !important;
}

.result-summary-table .module-result-name {
    word-break: normal !important;
    overflow-wrap: anywhere !important;
}

@media print {
    body[data-print-scope] .result-summary-table .module-result-name,
    body[data-print-scope] .result-summary-table .result-title-col {
        width: 34% !important;
    }

    body[data-print-scope] .result-summary-table .age-result-cell {
        width: 8% !important;
    }

    body[data-print-scope] .result-summary-table th[data-score-sem-col],
    body[data-print-scope] .result-summary-table td[data-score-sem-col] {
        width: 9.5% !important;
        font-size: 8.2px !important;
        padding: 3px 4px !important;
    }
}

/* 2026-05-21: final requested layout corrections */
.sem-card.locked {
    opacity: 1 !important;
    filter: none !important;
}

.sem-card input:disabled,
.sem-card .save-sem:disabled {
    opacity: .58 !important;
    cursor: not-allowed !important;
}

.sem-card [data-edit-sem],
.sem-card [data-edit-sem]:disabled,
.sem-card [data-print-sem],
.sem-card [data-print-sem]:disabled {
    opacity: 1 !important;
    filter: none !important;
    pointer-events: auto !important;
}

.result-summary-table col.summary-module-col {
    width: 34% !important;
}

.result-summary-table col.summary-age-col {
    width: 6% !important;
}

.result-summary-table col.summary-score-col {
    width: 10% !important;
}

.result-summary-table .module-result-name,
.result-summary-table .result-title-col {
    width: auto !important;
}

.result-summary-table .age-result-cell {
    width: auto !important;
    white-space: nowrap !important;
}

.result-summary-table th[data-score-sem-col],
.result-summary-table td[data-score-sem-col] {
    width: auto !important;
    font-size: 12px !important;
    line-height: 1.15 !important;
    padding-left: 6px !important;
    padding-right: 6px !important;
    word-break: normal !important;
    overflow-wrap: anywhere !important;
}

@media print {
    body[data-print-scope] .print-duration-panel {
        width: 186mm !important;
        max-width: 186mm !important;
        margin-left: auto !important;
        margin-right: auto !important;
        padding: 4px 6px !important;
        overflow: hidden !important;
    }

    body[data-print-scope="sem1"] .print-duration-panel,
    body[data-print-scope="sem3"] .print-duration-panel {
        width: 178mm !important;
        max-width: 178mm !important;
    }

    body[data-print-scope] .print-duration-grid {
        width: 100% !important;
        max-width: 100% !important;
        gap: 3px !important;
    }

    body[data-print-scope] .print-duration-item {
        min-width: 0 !important;
        padding: 3px 5px !important;
        overflow-wrap: anywhere !important;
    }

    body[data-print-scope] .print-duration-title {
        font-size: 8px !important;
        line-height: 1.1 !important;
    }

    body[data-print-scope] .print-duration-row {
        grid-template-columns: 22px minmax(0, 1fr) !important;
        gap: 3px !important;
        font-size: 7.5px !important;
        line-height: 1.15 !important;
    }

    body[data-print-scope] .result-summary-table col.summary-module-col {
        width: 30% !important;
    }

    body[data-print-scope] .result-summary-table col.summary-age-col {
        width: 5% !important;
    }

    body[data-print-scope] .result-summary-table col.summary-score-col {
        width: 10.833% !important;
    }

    body[data-print-scope] .result-summary-table th,
    body[data-print-scope] .result-summary-table td {
        padding: 3px 3px !important;
        word-break: normal !important;
        overflow-wrap: anywhere !important;
    }

    body[data-print-scope] .result-summary-table .age-result-cell {
        width: auto !important;
        white-space: nowrap !important;
        font-size: 8px !important;
    }

    body[data-print-scope] .result-summary-table th[data-score-sem-col],
    body[data-print-scope] .result-summary-table td[data-score-sem-col] {
        width: auto !important;
        font-size: 8px !important;
        line-height: 1.1 !important;
        padding-left: 3px !important;
        padding-right: 3px !important;
        text-align: center !important;
        vertical-align: middle !important;
    }

    body[data-print-scope] .result-summary-table .result-title-col,
    body[data-print-scope] .result-summary-table .module-result-name {
        width: auto !important;
    }
}

/* 2026-05-21: summary table module merge on teacher screen + print age-column removal */
.result-summary-table .screen-module-result-name {
    vertical-align: middle !important;
}

@media print {
    body[data-print-scope] .module-card.panel[data-module="module_6"] {
        break-before: page !important;
        page-break-before: always !important;
        margin-top: 8mm !important;
    }

    body[data-print-scope] .result-summary-table col.summary-module-col {
        width: 0 !important;
        visibility: collapse !important;
    }

    body[data-print-scope] .result-summary-table .screen-module-result-name {
        display: none !important;
        width: 0 !important;
        padding: 0 !important;
        border: 0 !important;
    }

    body[data-print-scope] .result-summary-table .age-result-cell {
        display: table-cell !important;
        width: 52mm !important;
        white-space: normal !important;
        text-align: left !important;
        vertical-align: middle !important;
        font-weight: 900 !important;
        overflow-wrap: anywhere !important;
    }

    body[data-print-scope] .result-summary-table .age-result-cell strong {
        display: none !important;
    }

    body[data-print-scope] .result-summary-table .age-result-cell::before {
        content: attr(data-print-module);
        display: block;
        color: #000;
        font-weight: 900;
    }

    body[data-print-scope="sem1"] .result-summary-table .age-result-cell,
    body[data-print-scope="sem3"] .result-summary-table .age-result-cell {
        width: 64mm !important;
    }

    body[data-print-scope="sem2"] .result-summary-table .age-result-cell,
    body[data-print-scope="sem4"] .result-summary-table .age-result-cell {
        width: 42mm !important;
    }
}

/* 2026-05-21 hotfix: use a dedicated print summary table so age-column removal does not break rowspan layout */
.print-result-summary-table {
    display: none;
}

@media print {
    body[data-print-scope] .result-summary-table {
        display: none !important;
    }

    body[data-print-scope] .print-result-summary-table {
        display: table !important;
        width: 100% !important;
        table-layout: fixed !important;
        border-collapse: collapse !important;
        margin: 0 auto !important;
        font-size: 8.4px !important;
    }

    body[data-print-scope] .print-result-summary-table th,
    body[data-print-scope] .print-result-summary-table td {
        border: 1.4px solid #000 !important;
        background: transparent !important;
        color: #000 !important;
        font-size: 8.4px !important;
        line-height: 1.12 !important;
        padding: 3px 4px !important;
        vertical-align: middle !important;
        word-break: normal !important;
        overflow-wrap: anywhere !important;
    }

    body[data-print-scope] .print-result-summary-table th {
        text-align: center !important;
        font-weight: 900 !important;
    }

    body[data-print-scope] .print-result-summary-table .module-result-name {
        text-align: left !important;
        font-weight: 900 !important;
    }

    body[data-print-scope] .print-result-summary-table td:not(.module-result-name) {
        text-align: center !important;
        font-weight: 800 !important;
    }

    body[data-print-scope] .print-result-summary-table .percentage-sem-1 {
        background: #eaf4ff !important;
        font-weight: 900 !important;
    }

    body[data-print-scope] .print-result-summary-table .percentage-sem-2 {
        background: #f3e8ff !important;
        font-weight: 900 !important;
    }

    body[data-print-scope] .print-result-summary-table tbody tr[data-print-score-age] {
        display: none !important;
    }

    body[data-print-scope="sem1"] .print-result-summary-table tbody tr[data-print-score-age="2"],
    body[data-print-scope="sem2"] .print-result-summary-table tbody tr[data-print-score-age="2"],
    body[data-print-scope="sem3"] .print-result-summary-table tbody tr[data-print-score-age="3"],
    body[data-print-scope="sem4"] .print-result-summary-table tbody tr[data-print-score-age="3"] {
        display: table-row !important;
    }

    body[data-print-scope] .print-result-summary-table [data-score-sem-col] {
        display: none !important;
    }

    body[data-print-scope="sem1"] .print-result-summary-table [data-score-sem-col="1"],
    body[data-print-scope="sem2"] .print-result-summary-table [data-score-sem-col="1"],
    body[data-print-scope="sem2"] .print-result-summary-table [data-score-sem-col="2"],
    body[data-print-scope="sem3"] .print-result-summary-table [data-score-sem-col="1"],
    body[data-print-scope="sem4"] .print-result-summary-table [data-score-sem-col="1"],
    body[data-print-scope="sem4"] .print-result-summary-table [data-score-sem-col="2"] {
        display: table-cell !important;
    }

    body[data-print-scope="sem1"] .print-result-summary-table .print-summary-module-col,
    body[data-print-scope="sem3"] .print-result-summary-table .print-summary-module-col {
        width: 70mm !important;
    }

    body[data-print-scope="sem2"] .print-result-summary-table .print-summary-module-col,
    body[data-print-scope="sem4"] .print-result-summary-table .print-summary-module-col {
        width: 48mm !important;
    }
}

/* 2026-05-21: combined semester print pagination fix
   - Combined reports (Sem 2 / Sem 4) start Module 4 on a new page.
   - Module 6 no longer starts a new page; it continues after Module 5.
*/
@media print {
    body[data-print-scope="sem2"] .module-card.panel[data-module="module_4"],
    body[data-print-scope="sem4"] .module-card.panel[data-module="module_4"] {
        break-before: page !important;
        page-break-before: always !important;
        margin-top: 8mm !important;
    }

    body[data-print-scope="sem2"] .module-card.panel[data-module="module_6"],
    body[data-print-scope="sem4"] .module-card.panel[data-module="module_6"] {
        break-before: auto !important;
        page-break-before: auto !important;
        margin-top: 0 !important;
    }
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.super-stats-grid .stat-card strong {
    font-size: 28px;
}

.school-card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 16px;
    margin-top: 18px;
}

.school-card {
    display: grid;
    gap: 16px;
    min-height: 210px;
    padding: 22px;
    border-radius: 28px;
    background: rgba(255,255,255,.94);
    border: 1px solid #ddd6fe;
    box-shadow: var(--shadow);
    transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}

.school-card:hover {
    transform: translateY(-3px);
    border-color: #a78bfa;
    box-shadow: 0 22px 55px rgba(76, 29, 149, .14);
}

.school-card h2 {
    font-size: 24px;
    line-height: 1.2;
}

.school-card-top,
.school-card-footer,
.school-card-metrics {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.school-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 7px 11px;
    border-radius: 999px;
    background: var(--purple-soft);
    color: var(--purple-dark);
    font-size: 12px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: .06em;
}

.school-card-metrics {
    align-items: stretch;
}

.school-card-metrics div {
    flex: 1;
    padding: 14px;
    border-radius: 18px;
    background: var(--purple-light);
    border: 1px solid #ddd6fe;
}

.school-card-metrics span,
.school-card-footer span {
    display: block;
    color: var(--muted);
    font-size: 12px;
    font-weight: 800;
}

.school-card-metrics strong {
    display: block;
    margin-top: 5px;
    color: var(--purple-dark);
    font-size: 22px;
}

.school-card-footer strong {
    color: var(--purple-dark);
    white-space: nowrap;
}

.management-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 0 0 18px;
}
.management-shortcut {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}
.management-form { display: grid; gap: 14px; }
.management-form-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.management-form-grid.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
select {
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 12px 13px;
    font: inherit;
    background: white;
    outline: none;
}
select:focus { border-color: var(--purple); box-shadow: 0 0 0 4px var(--purple-soft); }
select[multiple] { padding: 8px; min-height: 112px; }
select[multiple] option { padding: 7px 8px; border-radius: 8px; }
.compact-table th, .compact-table td { padding: 10px 11px; }
.action-cell { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.action-cell form { margin: 0; }
.btn.danger { background: #fee2e2; color: var(--danger); }
.management-stats { grid-template-columns: repeat(4, minmax(0, 1fr)); }

@media (max-width: 900px) {
    .management-form-grid,
    .management-form-grid.three,
    .management-stats { grid-template-columns: 1fr; }
    .management-shortcut { align-items: flex-start; flex-direction: column; }
}

.field-title {
    display: block;
    margin-bottom: 8px;
    color: var(--text);
    font-weight: 900;
}
.checkbox-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 10px;
}
.school-checkbox-grid,
.class-checkbox-grid {
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    max-height: 310px;
    overflow-y: auto;
    padding: 10px;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: #f8fafc;
}
.checkbox-list-search {
    width: 100%;
    margin: 0 0 10px;
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 11px 13px;
    font: inherit;
    background: white;
    outline: none;
}
.checkbox-list-search:focus { border-color: var(--purple); box-shadow: 0 0 0 4px var(--purple-soft); }
.check-card {
    display: flex;
    align-items: flex-start;
    gap: 9px;
    padding: 10px 12px;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: #fff;
    font-weight: 800;
}
.check-card input { margin-top: 3px; }
.check-card em {
    display: block;
    margin-top: 2px;
    color: var(--muted);
    font-size: 12px;
    font-style: normal;
    font-weight: 800;
}
.create-toggle { display: grid; gap: 16px; }
.create-toggle > summary {
    width: fit-content;
    list-style: none;
    cursor: pointer;
}
.create-toggle > summary::-webkit-details-marker { display: none; }
.stacked-lines {
    display: grid;
    gap: 4px;
}
.stacked-lines span {
    display: block;
    padding: 2px 0;
    border-bottom: 1px solid #eef2ff;
}
.stacked-lines span:last-child { border-bottom: 0; }
.small-note { margin: -4px 0 8px; }
.merged-overview-table td[rowspan] {
    vertical-align: top;
    background: #faf5ff;
}

.action-cell-nowrap {
    flex-wrap: nowrap;
    white-space: nowrap;
}
.import-form {
    gap: 12px;
}
.import-actions {
    justify-content: flex-start;
    gap: 10px;
}
.import-result ul {
    margin: 8px 0 0 18px;
    padding: 0;
}
.import-result li {
    margin: 3px 0;
}

.dashboard-table td.action-cell {
    display: table-cell;
    vertical-align: middle;
}
.dashboard-table td.action-cell .btn,
.dashboard-table td.action-cell form {
    display: inline-flex;
    vertical-align: middle;
    margin-right: 8px;
}
.dashboard-table td.action-cell form:last-child,
.dashboard-table td.action-cell .btn:last-child {
    margin-right: 0;
}


.playschool-search-panel {
    margin-top: 14px;
    padding: 18px 20px;
}

.playschool-search-label {
    display: block;
    margin-bottom: 8px;
    color: var(--purple-dark);
    font-weight: 900;
    font-size: 13px;
}

.playschool-card-search {
    width: 100%;
    min-height: 46px;
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 0 15px;
    font-weight: 800;
    background: #fff;
}

.playschool-card-search:focus {
    outline: 3px solid rgba(109, 40, 217, .14);
    border-color: #8b5cf6;
}

.compact-checkbox-grid.class-checkbox-grid {
    grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
    max-height: none;
}
.compact-check-card {
    align-items: center;
    justify-content: flex-start;
    min-height: 42px;
}
.form-note {
    margin: 7px 0 0;
    color: var(--muted);
    font-size: 12px;
    font-weight: 800;
}

/* Student bulk import - Admin standalone dashboard only */
.bulk-import-panel {
    display: none;
}
.bulk-import-panel.is-open {
    display: block;
}
.bulk-import-panel input[type="file"] {
    min-height: 46px;
    padding: 10px 12px;
}


.btn.bulk-import-toggle {
    background: #ede4ff;
    color: #5b21b6;
    border: 1px solid #ddd0ff;
    box-shadow: 0 10px 22px rgba(109, 40, 217, .14);
}

.btn.bulk-import-toggle:hover {
    background: #e4d7ff;
    color: #4c1d95;
    transform: translateY(-1px);
}

/* Assessment 3M standalone local login */
.assessment-login-page {
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 36px 20px;
}
.assessment-login-wrap {
    width: min(1060px, 100%);
    display: grid;
    grid-template-columns: 1.05fr .95fr;
    background: rgba(255,255,255,.94);
    border: 1px solid #e5e7eb;
    border-radius: 32px;
    overflow: hidden;
    box-shadow: 0 30px 80px rgba(76,29,149,.13);
}
.assessment-login-intro {
    padding: 52px;
    background: linear-gradient(145deg, #4c1d95 0%, #6d28d9 58%, #8b5cf6 100%);
    color: #fff;
}
.assessment-login-logo {
    width: 68px;
    height: 68px;
    border-radius: 22px;
    display: grid;
    place-items: center;
    background: rgba(255,255,255,.16);
    border: 1px solid rgba(255,255,255,.25);
    font-weight: 900;
    font-size: 24px;
    margin-bottom: 30px;
}
.assessment-login-intro .eyebrow { color: #ddd6fe; }
.assessment-login-intro h1 { color: #fff; max-width: 520px; line-height: 1.08; }
.assessment-login-copy { color: #ede9fe; line-height: 1.7; margin: 18px 0 30px; max-width: 520px; }
.assessment-role-preview { display: grid; gap: 12px; }
.assessment-role-preview > div {
    padding: 15px 16px;
    border-radius: 16px;
    background: rgba(255,255,255,.10);
    border: 1px solid rgba(255,255,255,.13);
}
.assessment-role-preview strong, .assessment-role-preview span { display: block; }
.assessment-role-preview span { color: #ede9fe; font-size: 12px; margin-top: 4px; line-height: 1.5; }
.assessment-login-card { padding: 52px; align-self: center; }
.assessment-login-heading h2 { font-size: 30px; margin-top: 10px; }
.assessment-login-heading p { color: var(--muted); margin: 8px 0 26px; }
.assessment-login-badge {
    display: inline-flex;
    padding: 6px 10px;
    border-radius: 999px;
    background: var(--purple-soft);
    color: var(--purple-dark);
    font-size: 11px;
    font-weight: 900;
    letter-spacing: .08em;
}
.assessment-login-card .login-form { display: grid; gap: 17px; }
.assessment-password-field { position: relative; }
.assessment-password-field input { padding-right: 72px; }
.assessment-password-toggle {
    position: absolute;
    top: 50%;
    right: 9px;
    transform: translateY(-50%);
    border: 0;
    background: var(--purple-soft);
    color: var(--purple-dark);
    border-radius: 10px;
    padding: 7px 10px;
    font-weight: 800;
    cursor: pointer;
}
.assessment-login-submit { width: 100%; margin-top: 3px; }
.assessment-test-accounts { margin-top: 24px; padding-top: 20px; border-top: 1px solid var(--line); }
.assessment-test-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; color: var(--muted); font-size: 12px; }
.assessment-test-head strong { color: var(--ink); font-size: 13px; }
.assessment-test-head code { color: var(--purple-dark); font-weight: 800; }
.assessment-account-buttons { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; margin-top: 12px; }
.assessment-account-buttons button {
    border: 1px solid #ddd6fe;
    background: #faf8ff;
    color: var(--purple-dark);
    border-radius: 12px;
    padding: 10px;
    font-weight: 800;
    cursor: pointer;
}
.assessment-account-buttons button:hover { background: var(--purple-soft); }
@media (max-width: 820px) {
    .assessment-login-wrap { grid-template-columns: 1fr; }
    .assessment-login-intro, .assessment-login-card { padding: 32px 24px; }
}

/* Assessment 3M - Teacher home and School Readiness Rubric */
.teacher-home-top {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 20px;
    align-items: stretch;
    margin-bottom: 22px;
}

.teacher-profile-card {
    background: #fff;
    border: 1px solid #d9e0ee;
    border-radius: 18px;
    padding: 22px 24px;
    box-shadow: 0 10px 28px rgba(31, 42, 84, .07);
}

.teacher-profile-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    padding-bottom: 16px;
    margin-bottom: 16px;
    border-bottom: 1px solid #e8ebf2;
}

.teacher-profile-heading h1 { margin: 2px 0 0; font-size: 28px; line-height: 1.15; }
.teacher-status-badge { display: inline-flex; align-items: center; padding: 7px 12px; border-radius: 999px; font-size: 12px; font-weight: 800; background: #eef1f6; color: #596276; }
.teacher-status-badge.is-active { background: #e7f8ee; color: #1a7f45; }
.teacher-detail-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.teacher-detail-item { min-width: 0; padding: 12px 14px; border: 1px solid #e4e8f1; border-radius: 12px; background: #f9fafc; }
.teacher-detail-item span { display: block; margin-bottom: 5px; color: #737b8c; font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: .04em; }
.teacher-detail-item strong { display: block; color: #20263a; font-size: 14px; line-height: 1.4; overflow-wrap: anywhere; }
.teacher-detail-wide { grid-column: span 2; }

.teacher-home-actions {
    width: 190px;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    gap: 10px;
}
.teacher-home-actions .btn { width: 100%; justify-content: center; min-height: 46px; }
.teacher-add-student-btn { font-weight: 800; }

.readiness-rubric-card {
    overflow: hidden;
    background: #fff;
    border: 1px solid #b8bfd0;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(31, 42, 84, .07);
    margin: 0 0 28px;
}
.readiness-rubric-title {
    background: #21187a;
    color: #fff;
    text-align: center;
    font-size: 24px;
    line-height: 1.2;
    font-weight: 900;
    padding: 8px 14px;
}
.readiness-rubric-legend {
    background: #f2c5c7;
    text-align: center;
    padding: 10px 16px 14px;
    color: #080808;
    font-size: 15px;
    line-height: 1.5;
}
.readiness-category-row { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 14px; align-items: center; margin-top: 4px; }
.readiness-category-row > strong { flex-basis: 100%; }
.rubric-dot { display: inline-block; width: 17px; height: 17px; border: 1.5px solid #111; border-radius: 50%; vertical-align: -3px; margin-right: 4px; }
.rubric-dot.ready { background: #00f02a; }
.rubric-dot.developing { background: #fff600; }
.rubric-dot.support { background: #ff281d; }
.readiness-table-scroll { width: 100%; overflow-x: auto; }
.readiness-rubric-table { width: 100%; min-width: 1180px; border-collapse: collapse; table-layout: fixed; font-size: 12px; color: #050505; }
.readiness-rubric-table th,
.readiness-rubric-table td { border: 1px solid #1c1c1c; padding: 6px 7px; vertical-align: middle; line-height: 1.28; }
.readiness-rubric-table thead th { background: #21187a; color: #fff; font-size: 15px; font-weight: 900; text-align: center; padding: 4px 7px; }
.readiness-rubric-table .domain-col { width: 11.5%; }
.readiness-rubric-table .element-col { width: 20%; }
.readiness-rubric-table thead th:nth-child(3),
.readiness-rubric-table thead th:nth-child(4),
.readiness-rubric-table thead th:nth-child(5) { width: 14.5%; }
.readiness-rubric-table .goal-col { width: 24.5%; }
.rubric-domain-cell { background: #c9daf0; text-align: center; font-size: 17px; font-weight: 900; white-space: normal; }
.rubric-goal-cell { background: #f2c5c7; white-space: normal; vertical-align: middle !important; }
.readiness-rubric-table tr.domain-start > td { border-top: 17px solid #21187a; }
.readiness-rubric-table tr.domain-start > .rubric-domain-cell,
.readiness-rubric-table tr.domain-start > .rubric-goal-cell { border-top: 17px solid #21187a; }

@media (max-width: 980px) {
    .teacher-home-top { grid-template-columns: 1fr; }
    .teacher-home-actions { width: 100%; flex-direction: row; }
    .teacher-home-actions .btn { width: auto; flex: 1; }
    .teacher-detail-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .teacher-detail-wide { grid-column: span 2; }
    .readiness-rubric-title { font-size: 19px; }
}

@media (max-width: 620px) {
    .teacher-profile-card { padding: 17px; }
    .teacher-profile-heading { flex-direction: column; }
    .teacher-detail-grid { grid-template-columns: 1fr; }
    .teacher-detail-wide { grid-column: span 1; }
    .teacher-home-actions { flex-direction: column; }
    .teacher-home-actions .btn { width: 100%; }
    .readiness-rubric-title { font-size: 16px; }
    .readiness-rubric-legend { font-size: 12px; }
}

/* Teacher PSRMs class assessment workspace */
.readiness-workspace-head {
    display:flex;
    align-items:flex-start;
    justify-content:space-between;
    gap:24px;
    margin-bottom:18px;
}
.readiness-workspace-head h1 { margin:2px 0 5px; }
.readiness-workspace-head p { margin:0; }
.readiness-context-panel,
.readiness-student-entry-panel { margin-bottom:18px; }
.readiness-context-form,
.readiness-student-form,
.readiness-import-form {
    display:grid;
    gap:14px;
    align-items:end;
}
.readiness-context-form { grid-template-columns:repeat(2,minmax(220px,1fr)); }
.readiness-student-form { grid-template-columns:2fr 1fr 1.25fr 1.25fr 1.25fr auto; }
.readiness-context-form label,
.readiness-student-form label,
.readiness-import-form label { display:grid; gap:6px; }
.readiness-context-form label > span,
.readiness-student-form label > span,
.readiness-import-form label > span { font-size:12px; font-weight:800; }
.readiness-context-form input,
.readiness-context-form select,
.readiness-student-form input,
.readiness-student-form select,
.readiness-import-form input {
    width:100%;
    min-height:42px;
    border:1px solid #d8dce8;
    border-radius:10px;
    background:#fff;
    padding:9px 11px;
}
.readiness-add-action { display:flex; align-items:end; }
.readiness-add-action .btn { min-height:42px; white-space:nowrap; }
.readiness-entry-heading { align-items:center; }
.readiness-inline-import { margin-top:15px; }
.readiness-inline-import.is-open { display:block; }
.readiness-import-top { display:flex; justify-content:space-between; gap:18px; align-items:center; margin-bottom:12px; }
.readiness-import-top p { margin:3px 0 0; color:#6b7280; font-size:12px; }
.readiness-import-form { grid-template-columns:minmax(280px,1fr) auto; }

.readiness-tabs-shell { margin-top:20px; }
.readiness-assessment-tabs {
    display:flex;
    gap:8px;
    margin-bottom:10px;
    position:sticky;
    top:0;
    z-index:20;
    background:#f7f7fb;
    padding:8px 0;
}
.readiness-tab {
    border:1px solid #21187a;
    background:#fff;
    color:#21187a;
    border-radius:9px;
    padding:10px 18px;
    font-weight:900;
    cursor:pointer;
}
.readiness-tab.is-active { background:#21187a; color:#fff; }
.readiness-assessment-pane { display:none; }
.readiness-assessment-pane.is-active { display:block; }
.psrm-title {
    background:#21187a;
    color:#fff;
    text-align:center;
    font-size:24px;
    font-weight:900;
    padding:7px 12px;
}
.psrm-scale {
    background:#e2e2e2;
    color:#000;
    text-align:center;
    font-size:13px;
    font-weight:800;
    padding:4px 12px;
}
.psrm-assessment-title {
    color:#ff1818;
    text-align:center;
    font-size:19px;
    font-weight:900;
    padding:5px 12px 2px;
}
.readiness-grid-scroll {
    width:100%;
    overflow:auto;
    border-left:1px solid #111;
    border-right:1px solid #111;
}
.readiness-summary-grid,
.readiness-score-grid {
    border-collapse:collapse;
    color:#050505;
    background:#fff;
    width:max-content;
    min-width:100%;
    table-layout:fixed;
}
.readiness-summary-grid th,
.readiness-summary-grid td,
.readiness-score-grid th,
.readiness-score-grid td {
    border:1px solid #111;
    padding:5px 7px;
    vertical-align:middle;
}
.readiness-summary-grid { font-size:12px; }
.readiness-summary-grid .summary-label {
    width:270px;
    min-width:270px;
    text-align:right;
    background:#bdd2ea;
    font-weight:900;
}
.readiness-summary-grid .student-head,
.readiness-summary-grid td {
    width:105px;
    min-width:105px;
    text-align:center;
}
.readiness-summary-grid .student-head {
    background:#21187a;
    color:#fff;
    border-color:#21187a;
    font-weight:900;
}
.readiness-summary-grid tr:not(.percentage-row) td { background:#21187a; color:#fff; }
.readiness-summary-grid .percentage-row td { font-size:14px; font-weight:900; }
.readiness-summary-grid .readiness-category-label { text-align:right; white-space:normal; }
.readiness-summary-grid .readiness-category-label span { display:block; }
.readiness-summary-grid .domain-summary-label { background:#fff; }
.readiness-summary-grid tr:has(.domain-summary-label) td { background:#fff; color:#111; font-weight:800; }
.student-percentage.category-ry1 { background:#6db34f !important; color:#fff !important; }
.student-percentage.category-d { background:#fff500 !important; color:#111 !important; }
.student-percentage.category-ns { background:#f4c7c3 !important; color:#111 !important; }

.readiness-score-scroll { margin-top:14px; border-top:1px solid #111; }
.readiness-score-grid { font-size:12px; }
.readiness-score-grid .goal-head,
.readiness-score-grid .indicator-head,
.readiness-score-grid .students-super-head,
.readiness-score-grid .student-score-head {
    background:#21187a;
    color:#fff;
    font-weight:900;
    text-align:center;
}
.readiness-score-grid .goal-head { width:300px; min-width:300px; }
.readiness-score-grid .indicator-head { width:285px; min-width:285px; }
.readiness-score-grid .student-score-head { width:105px; min-width:105px; }
.readiness-score-grid thead tr:nth-child(2) th:first-child,
.readiness-score-grid thead tr:nth-child(2) th:nth-child(2) { background:#21187a; border-color:#21187a; }
.readiness-score-grid .domain-band-row th {
    background:#ff0808;
    color:#fff;
    text-align:center;
    font-weight:900;
    padding:3px 7px;
}
.readiness-score-grid .domain-band-row td { background:#050505; padding:3px; }
.readiness-score-grid .end-goal-cell {
    background:#f4c7c3;
    font-weight:700;
    line-height:1.35;
    width:300px;
    min-width:300px;
}
.readiness-score-grid .indicator-cell {
    width:285px;
    min-width:285px;
    background:#fff;
    line-height:1.25;
}
.readiness-score-grid .score-input-cell {
    width:105px;
    min-width:105px;
    text-align:center;
    background:#fff;
    padding:5px 7px;
}
.readiness-score-select {
    width:82px;
    height:25px;
    border:0;
    border-radius:14px;
    text-align:center;
    text-align-last:center;
    font-weight:800;
    color:#111;
    cursor:pointer;
    appearance:auto;
}
.readiness-score-select.score-empty { background:#e9ecef; }
.readiness-score-select.score-1 { background:#ffc5c0; }
.readiness-score-select.score-2 { background:#fffb8f; }
.readiness-score-select.score-3 { background:#c8f6ae; }
.readiness-formula-note { margin:8px 0 0; color:#5b6170; font-size:12px; }
.empty-score-cell { background:#f0f1f3 !important; color:#888; }

@media (max-width: 1100px) {
    .readiness-student-form { grid-template-columns:repeat(3,minmax(180px,1fr)); }
    .readiness-add-action { align-self:end; }
}
@media (max-width: 720px) {
    .readiness-workspace-head { flex-direction:column; }
    .readiness-context-form,
    .readiness-student-form,
    .readiness-import-form { grid-template-columns:1fr; }
    .readiness-import-top { align-items:flex-start; flex-direction:column; }
    .psrm-title { font-size:18px; }
}

/* PSRMs: keep the information columns fixed; only student columns move horizontally. */
.readiness-summary-grid .summary-label {
    position: sticky;
    left: 0;
    z-index: 8;
    box-shadow: 2px 0 0 #111;
}
.readiness-summary-grid tr:first-child .summary-label {
    z-index: 10;
}

/* Assessment matrix fixed columns: End Goal + Indicator. */
.readiness-score-grid .goal-head,
.readiness-score-grid .end-goal-cell {
    position: sticky;
    left: 0;
    z-index: 8;
}
.readiness-score-grid .indicator-head,
.readiness-score-grid .indicator-cell {
    position: sticky;
    left: 300px;
    z-index: 8;
    box-shadow: 2px 0 0 #111;
}
.readiness-score-grid .goal-head,
.readiness-score-grid .indicator-head {
    z-index: 12;
}

/* The second header row has two blank fixed cells before student names. */
.readiness-score-grid thead tr:nth-child(2) th:first-child {
    position: sticky;
    left: 0;
    z-index: 11;
    width: 300px;
    min-width: 300px;
}
.readiness-score-grid thead tr:nth-child(2) th:nth-child(2) {
    position: sticky;
    left: 300px;
    z-index: 11;
    width: 285px;
    min-width: 285px;
    box-shadow: 2px 0 0 #111;
}

/* Domain title occupies both fixed columns and stays fixed while student cells scroll. */
.readiness-score-grid .domain-band-row th {
    position: sticky;
    left: 0;
    z-index: 9;
    width: 585px;
    min-width: 585px;
    max-width: 585px;
    box-shadow: 2px 0 0 #111;
}

/* Keep the fixed information area visually solid when rows slide beneath it. */
.readiness-score-grid .end-goal-cell { background:#f4c7c3; }
.readiness-score-grid .indicator-cell { background:#fff; }
.readiness-score-grid .goal-head,
.readiness-score-grid .indicator-head,
.readiness-score-grid thead tr:nth-child(2) th:first-child,
.readiness-score-grid thead tr:nth-child(2) th:nth-child(2) { background:#21187a; }

/* 2026-08-10: PSRMs workspace expands across the browser.
   The parent standalone content must expand too; do not fake full width with negative margins. */
body:has(.readiness-workspace-page) .standalone-content {
    width: calc(100% - 24px) !important;
    max-width: none !important;
    margin: 0 auto !important;
    padding: 24px 0 36px !important;
    overflow-x: hidden !important;
}

.readiness-workspace-page {
    width: 100%;
    max-width: none;
    margin: 0;
}

.readiness-workspace-page .readiness-context-panel,
.readiness-workspace-page .readiness-student-entry-panel,
.readiness-workspace-page .readiness-tabs-shell,
.readiness-workspace-page .readiness-workspace-head {
    width: 100%;
    max-width: none;
}

@media (max-width: 900px) {
    body:has(.readiness-workspace-page) .standalone-content {
        width: calc(100% - 16px) !important;
        padding-top: 16px !important;
        padding-bottom: 24px !important;
    }
}

/* 2026-08-10: PSRMs readability + clean horizontal scrolling.
   Keep the tables wide and readable; hide the visual scrollbar only. */
.readiness-grid-scroll {
    overflow-x: auto !important;
    overflow-y: visible !important;
    scrollbar-width: none;          /* Firefox */
    -ms-overflow-style: none;       /* legacy Edge/IE */
    -webkit-overflow-scrolling: touch;
}
.readiness-grid-scroll::-webkit-scrollbar {
    width: 0;
    height: 0;
    display: none;
}

/* Summary table: larger readable text and roomier student columns. */
.readiness-summary-grid {
    font-size: 14px !important;
}
.readiness-summary-grid th,
.readiness-summary-grid td {
    padding: 7px 9px !important;
    line-height: 1.25;
}
.readiness-summary-grid .summary-label {
    width: 300px !important;
    min-width: 300px !important;
    font-size: 13px;
}
.readiness-summary-grid .student-head,
.readiness-summary-grid td {
    width: 118px !important;
    min-width: 118px !important;
}
.readiness-summary-grid .student-head {
    font-size: 13px;
}
.readiness-summary-grid .percentage-row td {
    font-size: 16px !important;
}

/* Assessment matrix: don't shrink text just because there are many students. */
.readiness-score-grid {
    font-size: 14px !important;
}
.readiness-score-grid th,
.readiness-score-grid td {
    padding: 7px 9px !important;
    line-height: 1.3;
}
.readiness-score-grid .goal-head,
.readiness-score-grid .end-goal-cell {
    width: 330px !important;
    min-width: 330px !important;
}
.readiness-score-grid .indicator-head,
.readiness-score-grid .indicator-cell {
    width: 320px !important;
    min-width: 320px !important;
}
.readiness-score-grid .student-score-head,
.readiness-score-grid .score-input-cell {
    width: 118px !important;
    min-width: 118px !important;
}
.readiness-score-grid .student-score-head {
    font-size: 13px;
}
.readiness-score-grid .end-goal-cell {
    font-size: 13.5px;
    line-height: 1.45;
}
.readiness-score-grid .indicator-cell {
    font-size: 13.5px;
    line-height: 1.35;
}

/* Score dropdown: selected number must stay visible, not just the colour. */
.readiness-score-select {
    width: 92px !important;
    min-width: 92px;
    height: 30px !important;
    padding: 0 24px 0 10px !important;
    font-size: 14px !important;
    line-height: 30px !important;
    font-weight: 900 !important;
    color: #111 !important;
    -webkit-text-fill-color: #111 !important;
    opacity: 1 !important;
    text-align: center !important;
    text-align-last: center !important;
}
.readiness-score-select option {
    color: #111 !important;
    background: #fff;
    font-size: 14px;
    font-weight: 800;
}
.readiness-score-select:disabled {
    color: #111 !important;
    -webkit-text-fill-color: #111 !important;
    opacity: 1 !important;
}

/* Re-align sticky assessment columns after increasing their widths. */
.readiness-score-grid .indicator-head,
.readiness-score-grid .indicator-cell,
.readiness-score-grid thead tr:nth-child(2) th:nth-child(2) {
    left: 330px !important;
}
.readiness-score-grid thead tr:nth-child(2) th:first-child {
    width: 330px !important;
    min-width: 330px !important;
}
.readiness-score-grid thead tr:nth-child(2) th:nth-child(2) {
    width: 320px !important;
    min-width: 320px !important;
}
.readiness-score-grid .domain-band-row th {
    width: 650px !important;
    min-width: 650px !important;
    max-width: 650px !important;
}

/* 2026-08-10: harden fixed PSRMs columns so horizontally scrolling student
   content never paints/bleeds behind the static information area. Applies to
   both Baseline and Final panes because both use the same grid classes. */
.readiness-grid-scroll {
    position: relative;
    isolation: isolate;
    background: #fff;
}

/* Summary: left information column is a fully opaque layer above students. */
.readiness-summary-grid .summary-label {
    z-index: 60 !important;
    opacity: 1 !important;
    background-clip: border-box !important;
    overflow: hidden;
    transform: translateZ(0);
    box-shadow: 3px 0 0 #111 !important;
}
.readiness-summary-grid .summary-label::after {
    content: "";
    position: absolute;
    top: 0;
    right: -1px;
    width: 3px;
    height: 100%;
    background: #111;
    pointer-events: none;
}
.readiness-summary-grid .summary-label.domain-summary-label {
    background: #fff !important;
}
.readiness-summary-grid .readiness-category-label,
.readiness-summary-grid tr:not(.percentage-row) .summary-label {
    background: #bdd2ea !important;
}

/* Assessment matrix: the two left columns are independent opaque layers. */
.readiness-score-grid .goal-head,
.readiness-score-grid .end-goal-cell,
.readiness-score-grid thead tr:nth-child(2) th:first-child {
    z-index: 70 !important;
    opacity: 1 !important;
    background-clip: border-box !important;
    overflow: hidden;
    transform: translateZ(0);
}
.readiness-score-grid .indicator-head,
.readiness-score-grid .indicator-cell,
.readiness-score-grid thead tr:nth-child(2) th:nth-child(2) {
    z-index: 72 !important;
    opacity: 1 !important;
    background-clip: border-box !important;
    overflow: hidden;
    transform: translateZ(0);
    box-shadow: 3px 0 0 #111 !important;
}
.readiness-score-grid .indicator-head::after,
.readiness-score-grid .indicator-cell::after,
.readiness-score-grid thead tr:nth-child(2) th:nth-child(2)::after {
    content: "";
    position: absolute;
    top: 0;
    right: -1px;
    width: 3px;
    height: 100%;
    background: #111;
    pointer-events: none;
}
.readiness-score-grid .goal-head,
.readiness-score-grid .indicator-head,
.readiness-score-grid thead tr:nth-child(2) th:first-child,
.readiness-score-grid thead tr:nth-child(2) th:nth-child(2) {
    background: #21187a !important;
}
.readiness-score-grid .end-goal-cell {
    background: #f4c7c3 !important;
}
.readiness-score-grid .indicator-cell {
    background: #fff !important;
}

/* Domain strip spans the complete fixed area and must also mask students. */
.readiness-score-grid .domain-band-row th {
    z-index: 74 !important;
    opacity: 1 !important;
    background: #ff0808 !important;
    background-clip: border-box !important;
    overflow: hidden;
    transform: translateZ(0);
    box-shadow: 3px 0 0 #111 !important;
}
.readiness-score-grid .domain-band-row th::after {
    content: "";
    position: absolute;
    top: 0;
    right: -1px;
    width: 3px;
    height: 100%;
    background: #111;
    pointer-events: none;
}

/* Student cells always stay below the fixed layers. */
.readiness-summary-grid .student-head,
.readiness-summary-grid td,
.readiness-score-grid .students-super-head,
.readiness-score-grid .student-score-head,
.readiness-score-grid .score-input-cell,
.readiness-score-grid .domain-band-row td {
    position: relative;
    z-index: 1;
}

/* 2026-08-10 definitive sticky-column fix.
   Chrome can render collapsed table borders/content through sticky cells while
   horizontally scrolling. Use separate borders for the two PSRMs tables and
   keep the fixed cells in one opaque compositing layer. */
.readiness-summary-grid,
.readiness-score-grid {
    border-collapse: separate !important;
    border-spacing: 0 !important;
}

.readiness-summary-grid th,
.readiness-summary-grid td,
.readiness-score-grid th,
.readiness-score-grid td {
    border-right: 1px solid #111 !important;
    border-bottom: 1px solid #111 !important;
    border-left: 0 !important;
    border-top: 0 !important;
}
.readiness-summary-grid tr:first-child > *,
.readiness-score-grid thead tr:first-child > * {
    border-top: 1px solid #111 !important;
}
.readiness-summary-grid tr > *:first-child,
.readiness-score-grid tr > *:first-child {
    border-left: 1px solid #111 !important;
}

/* Do not force GPU transforms on sticky table cells; that can create the
   exact 'moving behind the left column' artefact on Chromium. */
.readiness-summary-grid .summary-label,
.readiness-score-grid .goal-head,
.readiness-score-grid .end-goal-cell,
.readiness-score-grid .indicator-head,
.readiness-score-grid .indicator-cell,
.readiness-score-grid thead tr:nth-child(2) th:first-child,
.readiness-score-grid thead tr:nth-child(2) th:nth-child(2),
.readiness-score-grid .domain-band-row th {
    transform: none !important;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
    background-origin: border-box !important;
    background-clip: border-box !important;
    clip-path: inset(0);
}

/* Explicit fixed widths/offsets. */
.readiness-summary-grid .summary-label {
    left: 0 !important;
    width: 300px !important;
    min-width: 300px !important;
    max-width: 300px !important;
    z-index: 100 !important;
}
.readiness-score-grid .goal-head,
.readiness-score-grid .end-goal-cell,
.readiness-score-grid thead tr:nth-child(2) th:first-child {
    left: 0 !important;
    width: 330px !important;
    min-width: 330px !important;
    max-width: 330px !important;
    z-index: 110 !important;
}
.readiness-score-grid .indicator-head,
.readiness-score-grid .indicator-cell,
.readiness-score-grid thead tr:nth-child(2) th:nth-child(2) {
    left: 330px !important;
    width: 320px !important;
    min-width: 320px !important;
    max-width: 320px !important;
    z-index: 112 !important;
}
.readiness-score-grid .domain-band-row th {
    left: 0 !important;
    width: 650px !important;
    min-width: 650px !important;
    max-width: 650px !important;
    z-index: 114 !important;
}

/* Solid backgrounds for every fixed state. */
.readiness-summary-grid .summary-label { background:#bdd2ea !important; }
.readiness-summary-grid .domain-summary-label { background:#fff !important; }
.readiness-score-grid .goal-head,
.readiness-score-grid .indicator-head,
.readiness-score-grid thead tr:nth-child(2) th:first-child,
.readiness-score-grid thead tr:nth-child(2) th:nth-child(2) { background:#21187a !important; }
.readiness-score-grid .end-goal-cell { background:#f4c7c3 !important; }
.readiness-score-grid .indicator-cell { background:#fff !important; }
.readiness-score-grid .domain-band-row th { background:#ff0808 !important; }

/* One clean divider on the edge of the fixed area. */
.readiness-summary-grid .summary-label,
.readiness-score-grid .indicator-head,
.readiness-score-grid .indicator-cell,
.readiness-score-grid thead tr:nth-child(2) th:nth-child(2),
.readiness-score-grid .domain-band-row th {
    box-shadow: 3px 0 0 #111 !important;
}

/* Student side must never establish a competing stacking layer. */
.readiness-summary-grid .student-head,
.readiness-summary-grid td:not(.summary-label),
.readiness-score-grid .students-super-head,
.readiness-score-grid .student-score-head,
.readiness-score-grid .score-input-cell,
.readiness-score-grid .domain-band-row td {
    position: relative;
    z-index: 0 !important;
    transform: none !important;
}


/* 2026-08-10: lock summary + assessment student columns to one shared grid.
   The summary's fixed information block must end at the exact same x-position
   as End Goal + Indicator below. Student columns then use identical widths,
   while JavaScript synchronizes both horizontal scroll positions. */
.readiness-assessment-pane {
    --psrm-goal-width: 330px;
    --psrm-indicator-width: 320px;
    --psrm-fixed-width: 650px;
    --psrm-student-width: 118px;
}

/* Summary fixed block = End Goal + Indicator combined width. */
.readiness-summary-grid .summary-label {
    left: 0 !important;
    width: var(--psrm-fixed-width) !important;
    min-width: var(--psrm-fixed-width) !important;
    max-width: var(--psrm-fixed-width) !important;
}

/* Every student column is exactly the same width in both tables. */
.readiness-summary-grid .student-head,
.readiness-summary-grid td:not(.summary-label),
.readiness-score-grid .student-score-head,
.readiness-score-grid .score-input-cell {
    width: var(--psrm-student-width) !important;
    min-width: var(--psrm-student-width) !important;
    max-width: var(--psrm-student-width) !important;
    box-sizing: border-box !important;
}

/* Lower fixed block uses the same combined 650px width. */
.readiness-score-grid .goal-head,
.readiness-score-grid .end-goal-cell,
.readiness-score-grid thead tr:nth-child(2) th:first-child {
    left: 0 !important;
    width: var(--psrm-goal-width) !important;
    min-width: var(--psrm-goal-width) !important;
    max-width: var(--psrm-goal-width) !important;
}
.readiness-score-grid .indicator-head,
.readiness-score-grid .indicator-cell,
.readiness-score-grid thead tr:nth-child(2) th:nth-child(2) {
    left: var(--psrm-goal-width) !important;
    width: var(--psrm-indicator-width) !important;
    min-width: var(--psrm-indicator-width) !important;
    max-width: var(--psrm-indicator-width) !important;
}
.readiness-score-grid .domain-band-row th {
    left: 0 !important;
    width: var(--psrm-fixed-width) !important;
    min-width: var(--psrm-fixed-width) !important;
    max-width: var(--psrm-fixed-width) !important;
}

/* Make intrinsic table sizing deterministic so matching student indexes stay aligned. */
.readiness-summary-grid,
.readiness-score-grid {
    table-layout: fixed !important;
}
.readiness-summary-grid .student-head,
.readiness-score-grid .student-score-head {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}


/* 2026-08-10: align the upper summary fixed area to the lower End Goal + Indicator grid.
   The blank left spacer mirrors End Goal; the blue information column mirrors Indicator. */
.readiness-summary-grid .summary-goal-spacer {
    position: sticky !important;
    left: 0 !important;
    width: var(--psrm-goal-width) !important;
    min-width: var(--psrm-goal-width) !important;
    max-width: var(--psrm-goal-width) !important;
    box-sizing: border-box !important;
    background: #fff !important;
    z-index: 121 !important;
    padding: 0 !important;
    border-color: transparent !important;
}
.readiness-summary-grid .summary-label {
    left: var(--psrm-goal-width) !important;
    width: var(--psrm-indicator-width) !important;
    min-width: var(--psrm-indicator-width) !important;
    max-width: var(--psrm-indicator-width) !important;
    z-index: 122 !important;
    box-shadow: 3px 0 0 #111 !important;
}
.readiness-summary-grid .summary-goal-spacer + .summary-label {
    border-left: 0 !important;
}
/* Preserve the requested blue summary information column, while the spacer remains visually blank. */
.readiness-summary-grid .summary-label,
.readiness-summary-grid .domain-summary-label {
    background: #bdd2ea !important;
}
/* Student columns begin after 330px + 320px, exactly matching the lower matrix. */
.readiness-summary-grid .student-head,
.readiness-summary-grid td:not(.summary-label) {
    width: var(--psrm-student-width) !important;
    min-width: var(--psrm-student-width) !important;
    max-width: var(--psrm-student-width) !important;
}

/* 2026-08-10: summary spacer is layout-only.
   The visible black boundary must start together with the blue Indicator-aligned
   summary column, not at the far-left edge of the invisible End Goal spacer. */
.readiness-summary-grid {
    border-left: 0 !important;
}
.readiness-summary-grid .summary-goal-spacer {
    border: 0 !important;
    box-shadow: none !important;
    outline: 0 !important;
    background: transparent !important;
}
.readiness-summary-grid tr:first-child > .summary-goal-spacer,
.readiness-summary-grid tr > .summary-goal-spacer:first-child {
    border: 0 !important;
}
.readiness-summary-grid .summary-label {
    border-left: 1px solid #111 !important;
}
/* Keep the summary's outer/visible left rule exactly at the Indicator start. */
.readiness-summary-grid .summary-goal-spacer + .summary-label {
    border-left: 1px solid #111 !important;
}

/* 2026-08-10: keep the PSRMs workspace wide, but not edge-to-edge on desktop. */
@media (min-width: 901px) {
    body:has(.readiness-workspace-page) .standalone-content {
        width: 94% !important;
        max-width: 1760px !important;
        margin-left: auto !important;
        margin-right: auto !important;
        padding-left: 0 !important;
        padding-right: 0 !important;
    }

    .readiness-workspace-page {
        width: 100% !important;
        max-width: 100% !important;
        margin: 0 auto !important;
    }
}

/* 2026-08-10: final summary left-gutter cleanup.
   The End Goal-width spacer is layout-only: it stays opaque to mask scrolled
   student cells, but has no visible rule. The first visible rule is exactly
   the left edge of the blue Indicator-aligned summary column. */
.readiness-summary-scroll {
    border-left: 0 !important;
}
.readiness-summary-grid .summary-goal-spacer {
    background: #fff !important;
    opacity: 1 !important;
    z-index: 130 !important;
    border: 0 !important;
    box-shadow: none !important;
    outline: 0 !important;
    clip-path: inset(0) !important;
}
.readiness-summary-grid tr:first-child > .summary-goal-spacer,
.readiness-summary-grid tr > .summary-goal-spacer:first-child {
    border: 0 !important;
}
.readiness-summary-grid .summary-label,
.readiness-summary-grid .summary-goal-spacer + .summary-label {
    border-left: 1px solid #111 !important;
}

/* 2026-08-10: spreadsheet-style readiness summary colouring.
   No assessment entries yet = grey. Once a domain has at least one score,
   trace its average colour like the Class 1 spreadsheet: <2 pink, 2-<3 yellow, 3 green. */
.readiness-summary-grid td.summary-empty {
    background: #a6a6a6 !important;
    color: #e9e9e9 !important;
    font-weight: 800 !important;
}
.readiness-summary-grid td.domain-pink {
    background: #f4c7c3 !important;
    color: #111 !important;
    font-weight: 800 !important;
}
.readiness-summary-grid td.domain-yellow {
    background: #fffca8 !important;
    color: #111 !important;
    font-weight: 800 !important;
}
.readiness-summary-grid td.domain-green {
    background: #b6d7a8 !important;
    color: #111 !important;
    font-weight: 800 !important;
}

/* 2026-08-10: Final Assessment comparison mode.
   Each student gets two sub-columns: Baseline reference + Final entry. */
.readiness-summary-grid .student-sub-head,
.readiness-score-grid .student-sub-head {
    background: #21187a;
    color: #fff;
    font-weight: 900;
    text-align: center;
    width: var(--psrm-student-width) !important;
    min-width: var(--psrm-student-width) !important;
    max-width: var(--psrm-student-width) !important;
    box-sizing: border-box !important;
}

.readiness-summary-grid.is-comparison-grid .student-head[colspan="2"],
.readiness-score-grid.is-comparison-grid .student-score-head[colspan="2"] {
    width: calc(var(--psrm-student-width) * 2) !important;
    min-width: calc(var(--psrm-student-width) * 2) !important;
    max-width: calc(var(--psrm-student-width) * 2) !important;
}

.readiness-summary-grid.is-comparison-grid td[colspan="2"] {
    width: calc(var(--psrm-student-width) * 2) !important;
    min-width: calc(var(--psrm-student-width) * 2) !important;
    max-width: calc(var(--psrm-student-width) * 2) !important;
    box-sizing: border-box !important;
}

.readiness-summary-grid .summary-compare-row td,
.readiness-summary-grid .summary-compare-row th {
    background: #21187a !important;
    color: #fff !important;
}

.readiness-score-grid .compare-score-cell {
    background: #fff !important;
    text-align: center;
}

.readiness-score-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 92px;
    min-width: 92px;
    height: 30px;
    border-radius: 14px;
    font-size: 14px;
    font-weight: 900;
    color: #111;
    line-height: 1;
}
.readiness-score-pill.score-empty { background: #e9ecef; }
.readiness-score-pill.score-1 { background: #ffc5c0; }
.readiness-score-pill.score-2 { background: #fffb8f; }
.readiness-score-pill.score-3 { background: #c8f6ae; }

/* Extra header rows in Final Assessment must keep the two fixed left placeholders sticky. */
.readiness-score-grid .sticky-goal-placeholder,
.readiness-score-grid .sticky-indicator-placeholder {
    position: sticky !important;
    top: auto;
    background: #21187a !important;
    color: #fff;
    z-index: 111 !important;
}
.readiness-score-grid .sticky-goal-placeholder {
    left: 0 !important;
    width: var(--psrm-goal-width) !important;
    min-width: var(--psrm-goal-width) !important;
    max-width: var(--psrm-goal-width) !important;
}
.readiness-score-grid .sticky-indicator-placeholder {
    left: var(--psrm-goal-width) !important;
    width: var(--psrm-indicator-width) !important;
    min-width: var(--psrm-indicator-width) !important;
    max-width: var(--psrm-indicator-width) !important;
    box-shadow: 3px 0 0 #111 !important;
    z-index: 112 !important;
}
.readiness-score-grid .sticky-indicator-placeholder::after {
    content: "";
    position: absolute;
    top: 0;
    right: -1px;
    width: 3px;
    height: 100%;
    background: #111;
    pointer-events: none;
}

.readiness-score-grid.is-comparison-grid .students-super-head {
    z-index: 1 !important;
}
.readiness-score-grid.is-comparison-grid .student-score-head,
.readiness-score-grid.is-comparison-grid .student-sub-head,
.readiness-score-grid.is-comparison-grid .score-input-cell,
.readiness-summary-grid.is-comparison-grid .student-sub-head,
.readiness-summary-grid.is-comparison-grid td:not(.summary-label) {
    width: var(--psrm-student-width) !important;
    min-width: var(--psrm-student-width) !important;
    max-width: var(--psrm-student-width) !important;
}

/* Keep comparison sub-headers readable without forcing ellipsis everywhere. */
.readiness-score-grid .student-sub-head,
.readiness-summary-grid .student-sub-head {
    font-size: 12px;
    white-space: nowrap;
}

/* 2026-08-10: tidy Final Assessment comparison header and summary placement. */
/* The blank End Goal-alignment gutter must stay visually empty, including the Assessment row. */
.readiness-summary-grid .summary-compare-row .summary-goal-spacer {
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
}
.readiness-summary-grid .summary-compare-row .summary-label {
    background: #bdd2ea !important;
    color: #21187a !important;
    border-left: 1px solid #111 !important;
}
.readiness-summary-grid .summary-compare-row .student-sub-head {
    background: #21187a !important;
    color: #fff !important;
}

/* Merge End Goal and Indicator vertically across all student header rows.
   This removes the empty duplicate blue cells and their double horizontal lines. */
.readiness-score-grid .goal-head[rowspan],
.readiness-score-grid .indicator-head[rowspan] {
    vertical-align: middle !important;
    border-bottom: 1px solid #111 !important;
}
.readiness-score-grid.is-comparison-grid thead tr:nth-child(2) .student-score-head,
.readiness-score-grid.is-comparison-grid thead tr:nth-child(3) .student-sub-head {
    border-top: 0 !important;
}
.readiness-score-grid.is-comparison-grid thead tr:nth-child(2) .student-score-head {
    border-bottom: 1px solid #111 !important;
}
.readiness-score-grid.is-comparison-grid thead tr:nth-child(3) .student-sub-head {
    border-bottom: 1px solid #111 !important;
}

/* Remove styling for legacy blank fixed header cells; they are no longer rendered. */
.readiness-score-grid.is-comparison-grid .sticky-goal-placeholder,
.readiness-score-grid.is-comparison-grid .sticky-indicator-placeholder {
    display: none !important;
}

/* One clean divider after Indicator; avoid the previous doubled heavy rule. */
.readiness-score-grid .indicator-head,
.readiness-score-grid .indicator-cell,
.readiness-score-grid .domain-band-row th {
    box-shadow: 2px 0 0 #111 !important;
}
.readiness-score-grid .indicator-head::after,
.readiness-score-grid .indicator-cell::after,
.readiness-score-grid .domain-band-row th::after {
    display: none !important;
}

/* 2026-08-10: Baseline assessment header cleanup.
   End Goal and Indicator now span both header rows, so the old blank
   placeholder cells are no longer rendered. Keep student-name cells in the
   second header row behaving as normal scrolling student columns. */
.readiness-score-grid:not(.is-comparison-grid) thead tr:nth-child(2) .student-score-head {
    position: relative !important;
    left: auto !important;
    width: 105px !important;
    min-width: 105px !important;
    z-index: 1 !important;
    box-shadow: none !important;
    clip-path: none !important;
    background: #21187a !important;
}
.readiness-score-grid:not(.is-comparison-grid) thead tr:nth-child(2) .student-score-head::after {
    content: none !important;
}

/* Compact parent assessment result email popup */
.readiness-tabs-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 16px;
}

.readiness-tabs-toolbar .readiness-assessment-tabs {
    margin-bottom: 0;
}

.readiness-send-parent-btn {
    flex: 0 0 auto;
    white-space: nowrap;
}

.parent-email-modal[hidden] {
    display: none !important;
}

.parent-email-modal {
    position: fixed;
    inset: 0;
    z-index: 1200;
    display: grid;
    place-items: center;
    padding: 20px;
}

.parent-email-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(24, 18, 54, .40);
    backdrop-filter: blur(5px);
}

.parent-email-modal-card {
    position: relative;
    z-index: 1;
    width: min(460px, 100%);
    border: 1px solid #e2def4;
    border-radius: 16px;
    background: #fff;
    box-shadow: 0 24px 70px rgba(35, 24, 92, .22);
    padding: 22px;
}

.parent-email-modal-close {
    position: absolute;
    top: 12px;
    right: 14px;
    width: 32px;
    height: 32px;
    border: 0;
    border-radius: 50%;
    background: #f4f1fb;
    color: #3b247c;
    font-size: 22px;
    line-height: 1;
    cursor: pointer;
}

.parent-email-modal-head {
    padding-right: 34px;
    margin-bottom: 18px;
}

.parent-email-modal-head h3 {
    margin: 0 0 5px;
    color: #3a178b;
    font-size: 18px;
}

.parent-email-modal-head p {
    margin: 0;
    color: #737080;
    font-size: 12px;
}

.parent-email-modal-form {
    display: grid;
    gap: 14px;
}

.parent-email-modal-form label {
    display: grid;
    gap: 6px;
}

.parent-email-modal-form label > span {
    font-size: 12px;
    font-weight: 700;
    color: #555063;
}

.parent-email-modal-form select,
.parent-email-modal-form input {
    width: 100%;
    min-height: 42px;
}

.parent-email-modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    margin-top: 4px;
}

body.parent-email-modal-open {
    overflow: hidden;
}

@media (max-width: 640px) {
    .readiness-tabs-toolbar {
        align-items: stretch;
        flex-direction: column;
    }

    .readiness-send-parent-btn {
        align-self: flex-end;
    }

    .parent-email-modal-card {
        padding: 20px 16px 16px;
    }
}


/* Student list assessment result tabs */
.student-result-panel{margin-top:22px}
.student-result-head{display:flex;align-items:flex-end;justify-content:space-between;gap:18px;margin-bottom:14px}
.student-result-head h2{margin:0 0 4px;color:#4517a6}
.student-result-head p{margin:0;color:#6b7280}
.student-result-tabs{display:flex;gap:8px;flex-wrap:wrap}
.student-result-tab{border:1px solid #6d28d9;background:#fff;color:#4c1d95;border-radius:9px;padding:10px 16px;font-weight:700;cursor:pointer}
.student-result-tab.is-active{background:#4c1d95;color:#fff}
.result-formula-box{border:1px solid #e4dcfb;background:#faf8ff;border-radius:12px;padding:13px 15px;margin-bottom:18px}
.result-formula-box>strong{display:block;color:#42149a;margin-bottom:8px}
.result-formula-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:7px 18px;font-size:12px;color:#4b5563;line-height:1.45}
.student-result-pane{display:none}
.student-result-pane.is-active{display:block}
.class-result-block{border:1px solid #ddd6f6;border-radius:14px;overflow:hidden;margin-bottom:20px;background:#fff}
.class-result-title{background:#120052;color:#fff;padding:11px 15px;display:flex;align-items:center;justify-content:space-between;gap:15px}
.class-result-title strong{font-size:16px}
.class-result-title span{font-size:12px;opacity:.9;text-align:right}
.summary-comparison-wrap{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:14px;padding:14px;background:#f9f8ff}
.summary-result-side{min-width:0;background:#fff;border:1px solid #e5e0f7;border-radius:10px;overflow:hidden}
.summary-side-title{background:#6d28d9;color:#fff;font-weight:800;text-align:center;padding:9px 10px;text-transform:uppercase;letter-spacing:.02em}
.result-table-wrap{margin:0;overflow-x:auto}
.result-summary-table,.student-performance-table{width:100%;border-collapse:collapse;font-size:12px}
.result-summary-table th,.result-summary-table td,.student-performance-table th,.student-performance-table td{border:1px solid #d7d9e8;padding:8px 9px;vertical-align:middle}
.result-summary-table th,.student-performance-table th{background:#24147f;color:#fff;font-weight:700;white-space:nowrap}
.result-summary-table td:first-child{font-weight:700;background:#eef4ff;min-width:155px}
.result-summary-table td:not(:first-child){text-align:center}
.performance-group-head{text-align:center!important}
.student-performance-table td:nth-child(1),.student-performance-table td:nth-last-child(-n+3){text-align:center}
.performance-score{display:inline-block;min-width:70px;padding:5px 9px;border-radius:999px;font-weight:800;text-align:center}
.baseline-score{background:#eee9ff;color:#4c1d95}
.final-score{background:#e8f6ec;color:#166534}
.performance-change{font-weight:800}
.performance-change.is-positive{color:#15803d}
.performance-change.is-negative{color:#b91c1c}
.result-empty{padding:28px;text-align:center}
@media (max-width:1100px){.summary-comparison-wrap{grid-template-columns:1fr}.student-result-head{align-items:flex-start;flex-direction:column}.result-formula-grid{grid-template-columns:1fr}}

/* 2026-08-10: summary report table colours aligned with provided spreadsheet reference */
.student-result-panel .summary-result-side .summary-side-title{
    background:#ff1010 !important;
    color:#fff !important;
    font-size:15px;
    font-weight:900;
    text-align:center;
    padding:9px 10px;
    text-transform:uppercase;
    border-radius:0;
}
.student-result-panel .result-summary-table thead,
.student-result-panel .result-summary-table thead tr,
.student-result-panel .result-summary-table thead th{
    visibility:visible !important;
    opacity:1 !important;
    height:auto !important;
}
.student-result-panel .result-summary-table thead th{
    color:#fff !important;
    background:#221680 !important;
    border:1px solid #111 !important;
    padding:8px 7px !important;
    font-size:12px !important;
    font-weight:900 !important;
    line-height:1.15 !important;
    text-align:center !important;
    white-space:normal !important;
}
.student-result-panel .result-summary-table thead th.summary-head-ry1{
    background:#b7dda8 !important;
    color:#000 !important;
}
.student-result-panel .result-summary-table thead th.summary-head-d{
    background:#fff9a6 !important;
    color:#000 !important;
}
.student-result-panel .result-summary-table thead th.summary-head-ns{
    background:#efc2c2 !important;
    color:#000 !important;
}
.student-result-panel .result-summary-table thead th.summary-head-domain,
.student-result-panel .result-summary-table thead th.summary-head-element,
.student-result-panel .result-summary-table thead th.summary-head-ranking{
    background:#221680 !important;
    color:#fff !important;
}
.student-result-panel .result-summary-table td{
    border:1px solid #111 !important;
    color:#000;
    background:#fff;
}
.student-result-panel .result-summary-table td:first-child{
    background:#c9daf4 !important;
    color:#000 !important;
    font-weight:800;
}
.student-result-panel .class-result-title{
    background:#000 !important;
    color:#fff !important;
    border-radius:0;
}
.student-result-panel .class-result-block{
    border:1px solid #111;
    border-radius:0;
}
.student-result-panel .summary-result-side{
    border:1px solid #111;
    border-radius:0;
}
.student-result-panel .summary-comparison-wrap{
    background:#fff;
    gap:26px;
}

/* 2026-08-10: Summary Result rebuilt to match supplied spreadsheet material */
.student-result-panel .spreadsheet-summary-block{
    border:0 !important;
    border-radius:0 !important;
    overflow:visible;
    margin-bottom:22px;
    background:#fff;
}
.student-result-panel .summary-sheet-wrap{
    overflow-x:auto;
    background:#fff;
    padding:0;
}
.student-result-panel .summary-sheet-table{
    width:100%;
    min-width:980px;
    table-layout:fixed;
    border-collapse:collapse;
    font-size:12px;
}
.student-result-panel .summary-sheet-table th,
.student-result-panel .summary-sheet-table td{
    border:1px solid #111 !important;
    padding:5px 7px !important;
    line-height:1.05;
    vertical-align:middle;
    text-align:center !important;
}
.student-result-panel .summary-sheet-table .summary-assessment-head-row th{
    height:46px;
    font-size:14px !important;
    font-weight:900 !important;
}
.student-result-panel .summary-sheet-table .summary-top-empty{
    width:25%;
    background:#fff !important;
    border-top-color:#fff !important;
    border-left-color:#fff !important;
    color:#000 !important;
}
.student-result-panel .summary-sheet-table .summary-head-ry1{
    background:#b7dda8 !important;
    color:#000 !important;
}
.student-result-panel .summary-sheet-table .summary-head-d{
    background:#fff9a6 !important;
    color:#000 !important;
}
.student-result-panel .summary-sheet-table .summary-head-ns{
    background:#efc2c2 !important;
    color:#000 !important;
}
.student-result-panel .summary-sheet-table .summary-assessment-title{
    background:#ff1010 !important;
    color:#fff !important;
    text-transform:uppercase;
    font-size:14px !important;
    font-weight:900 !important;
    line-height:1.12 !important;
}
.student-result-panel .summary-sheet-table .summary-separator{
    width:26px;
    min-width:26px;
    padding:0 !important;
    background:#000 !important;
    border-color:#000 !important;
}
.student-result-panel .summary-sheet-table .summary-class-title-row th{
    background:#000 !important;
    color:#fff !important;
    text-align:center !important;
    font-size:17px !important;
    font-weight:900 !important;
    padding:5px 10px !important;
    line-height:1.05 !important;
    text-transform:none;
}
.student-result-panel .summary-sheet-table .summary-column-head-row th{
    background:#221680 !important;
    color:#fff !important;
    font-size:13px !important;
    font-weight:900 !important;
    padding:5px 7px !important;
}
.student-result-panel .summary-sheet-table .summary-column-head-row .summary-separator{
    background:#000 !important;
}
.student-result-panel .summary-sheet-table tbody td{
    background:#fff !important;
    color:#000 !important;
    font-weight:700;
}
.student-result-panel .summary-sheet-table tbody .summary-domain-cell{
    background:#c9daf4 !important;
    color:#000 !important;
    font-weight:800 !important;
    text-align:right !important;
    width:25%;
}
.student-result-panel .summary-sheet-table tbody .summary-separator{
    background:#000 !important;
}
.student-result-panel .summary-sheet-table th:nth-child(2),
.student-result-panel .summary-sheet-table th:nth-child(3),
.student-result-panel .summary-sheet-table th:nth-child(4),
.student-result-panel .summary-sheet-table td:nth-child(2),
.student-result-panel .summary-sheet-table td:nth-child(3),
.student-result-panel .summary-sheet-table td:nth-child(4),
.student-result-panel .summary-sheet-table th:nth-child(8),
.student-result-panel .summary-sheet-table th:nth-child(9),
.student-result-panel .summary-sheet-table th:nth-child(10),
.student-result-panel .summary-sheet-table td:nth-child(8),
.student-result-panel .summary-sheet-table td:nth-child(9),
.student-result-panel .summary-sheet-table td:nth-child(10){
    width:7.3%;
}
.student-result-panel .summary-sheet-table .summary-head-element,
.student-result-panel .summary-sheet-table .summary-head-ranking{
    width:9%;
}
@media (max-width:1100px){
    .student-result-panel .summary-sheet-table{min-width:980px}
}


/* 2026-08-10: stretch Summary Result tables to the full result container */
.student-result-panel .student-result-pane[data-result-pane="summary"],
.student-result-panel .spreadsheet-summary-block,
.student-result-panel .summary-sheet-wrap{
    width:100% !important;
    max-width:none !important;
    box-sizing:border-box;
}
.student-result-panel .summary-sheet-wrap{
    overflow-x:auto;
}
.student-result-panel .summary-sheet-table{
    width:100% !important;
    min-width:100% !important;
    max-width:none !important;
    table-layout:fixed !important;
    margin:0 !important;
}
.student-result-panel .summary-sheet-table .summary-top-empty,
.student-result-panel .summary-sheet-table tbody .summary-domain-cell{
    width:25% !important;
}
.student-result-panel .summary-sheet-table th:nth-child(2),
.student-result-panel .summary-sheet-table th:nth-child(3),
.student-result-panel .summary-sheet-table th:nth-child(4),
.student-result-panel .summary-sheet-table td:nth-child(2),
.student-result-panel .summary-sheet-table td:nth-child(3),
.student-result-panel .summary-sheet-table td:nth-child(4),
.student-result-panel .summary-sheet-table th:nth-child(8),
.student-result-panel .summary-sheet-table th:nth-child(9),
.student-result-panel .summary-sheet-table th:nth-child(10),
.student-result-panel .summary-sheet-table td:nth-child(8),
.student-result-panel .summary-sheet-table td:nth-child(9),
.student-result-panel .summary-sheet-table td:nth-child(10){
    width:6.5% !important;
}
.student-result-panel .summary-sheet-table .summary-head-element,
.student-result-panel .summary-sheet-table .summary-head-ranking{
    width:8% !important;
}
.student-result-panel .summary-sheet-table .summary-separator{
    width:2% !important;
    min-width:18px !important;
}
@media (max-width:1100px){
    .student-result-panel .summary-sheet-table{
        min-width:980px !important;
    }
}

/* 2026-08-10: fit Summary Result table exactly inside its container, without horizontal scrolling */
.student-result-panel .student-result-pane[data-result-pane="summary"],
.student-result-panel .spreadsheet-summary-block,
.student-result-panel .summary-sheet-wrap {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    box-sizing: border-box !important;
}

.student-result-panel .summary-sheet-wrap {
    overflow-x: hidden !important;
    overflow-y: visible !important;
}

.student-result-panel .summary-sheet-table {
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
    table-layout: fixed !important;
    border-collapse: collapse !important;
    margin: 0 !important;
}

/* Fixed 100% column distribution keeps every class table the same size/alignment. */
.student-result-panel .summary-sheet-table col.summary-col-domain { width: 25% !important; }
.student-result-panel .summary-sheet-table col.summary-col-status { width: 6.5% !important; }
.student-result-panel .summary-sheet-table col.summary-col-metric { width: 8.5% !important; }
.student-result-panel .summary-sheet-table col.summary-col-separator { width: 2% !important; }

.student-result-panel .summary-sheet-table th,
.student-result-panel .summary-sheet-table td {
    width: auto !important;
    min-width: 0 !important;
    max-width: none !important;
    box-sizing: border-box !important;
    white-space: normal !important;
    overflow-wrap: break-word !important;
    word-break: normal !important;
}

.student-result-panel .summary-sheet-table .summary-top-empty,
.student-result-panel .summary-sheet-table tbody .summary-domain-cell,
.student-result-panel .summary-sheet-table .summary-head-element,
.student-result-panel .summary-sheet-table .summary-head-ranking,
.student-result-panel .summary-sheet-table .summary-separator,
.student-result-panel .summary-sheet-table th:nth-child(2),
.student-result-panel .summary-sheet-table th:nth-child(3),
.student-result-panel .summary-sheet-table th:nth-child(4),
.student-result-panel .summary-sheet-table td:nth-child(2),
.student-result-panel .summary-sheet-table td:nth-child(3),
.student-result-panel .summary-sheet-table td:nth-child(4),
.student-result-panel .summary-sheet-table th:nth-child(8),
.student-result-panel .summary-sheet-table th:nth-child(9),
.student-result-panel .summary-sheet-table th:nth-child(10),
.student-result-panel .summary-sheet-table td:nth-child(8),
.student-result-panel .summary-sheet-table td:nth-child(9),
.student-result-panel .summary-sheet-table td:nth-child(10) {
    width: auto !important;
    min-width: 0 !important;
}

@media (max-width: 1100px) {
    .student-result-panel .summary-sheet-table {
        min-width: 0 !important;
        width: 100% !important;
    }

    .student-result-panel .summary-sheet-table th,
    .student-result-panel .summary-sheet-table td {
        padding-left: 4px !important;
        padding-right: 4px !important;
        font-size: 11px !important;
    }

    .student-result-panel .summary-sheet-table .summary-class-title-row th {
        font-size: 14px !important;
    }
}

/* 2026-08-10: Student Performance separated into one table per class */
.student-result-panel [data-result-pane="performance"]{
    display:block;
}
.student-result-panel [data-result-pane="performance"][hidden]{
    display:none !important;
}
.student-result-panel .performance-class-wrap{
    overflow:visible;
    margin-bottom:22px;
    border-radius:0;
}
.student-result-panel .performance-class-wrap:last-child{
    margin-bottom:0;
}
.student-result-panel .student-performance-class-table{
    width:100%;
    min-width:0;
    border-collapse:collapse;
    table-layout:fixed;
    background:#fff;
}
.student-result-panel .student-performance-class-table th,
.student-result-panel .student-performance-class-table td{
    border:1px solid #bfc5d7;
    padding:8px 10px;
    font-size:12px;
    text-align:center;
    vertical-align:middle;
}
.student-result-panel .student-performance-class-table .performance-grid-title-row th{
    background:#ff1515;
    color:#fff;
    font-size:15px;
    font-weight:900;
    padding:10px 8px;
}
.student-result-panel .student-performance-class-table .performance-grid-class-row th,
.student-result-panel .student-performance-class-table .performance-grid-subhead-row th,
.student-result-panel .student-performance-class-table .performance-grid-score-row th{
    background:#24147f;
    color:#fff;
    font-weight:800;
}
.student-result-panel .student-performance-class-table .performance-grid-class-title{
    font-size:13px;
    line-height:1.2;
}
.student-result-panel .student-performance-class-table .performance-grid-class-title span{
    display:block;
}
.student-result-panel .student-performance-class-table .performance-grid-class-title small{
    display:block;
    margin-top:3px;
    font-size:10px;
    font-weight:600;
    opacity:.92;
}
.student-result-panel .student-performance-class-table col.performance-col-no{
    width:6%;
}
.student-result-panel .student-performance-class-table col.performance-col-student{
    width:54%;
}
.student-result-panel .student-performance-class-table col.performance-col-score{
    width:20%;
}
.student-result-panel .student-performance-class-table .performance-grid-bil,
.student-result-panel .student-performance-class-table .performance-grid-number{
    background:#24147f;
    color:#fff;
    font-weight:800;
    white-space:nowrap;
}
.student-result-panel .student-performance-class-table .performance-grid-student-head{
    text-align:center;
}
.student-result-panel .student-performance-class-table .performance-grid-student-name{
    text-align:left;
    font-weight:700;
    background:#fff;
    white-space:normal;
    overflow-wrap:anywhere;
}
.student-result-panel .student-performance-class-table td{
    background:#fff;
}
.student-result-panel .student-performance-class-table .performance-score{
    min-width:64px;
    width:auto;
    padding:4px 8px;
    font-size:inherit;
}
.student-result-panel .student-performance-class-table .empty-state{
    text-align:center;
    padding:18px 10px;
}
@media (max-width:700px){
    .student-result-panel .performance-class-wrap{
        overflow-x:auto;
    }
    .student-result-panel .student-performance-class-table{
        min-width:620px;
    }
}



/* Teacher management list: give long emails enough room and prevent column text collisions. */
.staff-management-table {
    width: 100% !important;
    table-layout: fixed !important;
}
.staff-management-table col.staff-col-name   { width: 14%; }
.staff-management-table col.staff-col-email  { width: 23%; }
.staff-management-table col.staff-col-role   { width: 9%; }
.staff-management-table col.staff-col-school { width: 16%; }
.staff-management-table col.staff-col-class  { width: 10%; }
.staff-management-table col.staff-col-total  { width: 10%; }
.staff-management-table col.staff-col-status { width: 8%; }
.staff-management-table col.staff-col-action { width: 10%; }

.staff-management-table th,
.staff-management-table td {
    box-sizing: border-box;
    min-width: 0;
    overflow: hidden;
}

.staff-management-table th:nth-child(2),
.staff-management-table td:nth-child(2) {
    white-space: nowrap;
    overflow: visible;
    overflow-wrap: normal !important;
    word-break: normal !important;
}

.staff-management-table th:nth-child(3),
.staff-management-table td:nth-child(3) {
    white-space: normal;
    overflow-wrap: break-word;
}

.staff-management-table td.action-cell {
    white-space: nowrap;
}

@media (max-width: 1250px) {
    .staff-management-table {
        min-width: 1180px;
    }
    .staff-management-table + * { max-width: 100%; }
}

/* 2026-08-12: PSRMs horizontal-scroll + Final Assessment sticky-header fix.
   Keep the left information columns fully opaque while student columns move,
   and expose a real scrollbar for both Baseline and Final tables. */
.readiness-grid-scroll {
    overflow-x: scroll !important;
    overflow-y: hidden !important;
    scrollbar-width: auto !important;
    -ms-overflow-style: auto !important;
    scrollbar-gutter: stable;
}
.readiness-grid-scroll::-webkit-scrollbar {
    display: block !important;
    width: auto !important;
    height: 12px !important;
}
.readiness-grid-scroll::-webkit-scrollbar-track {
    background: #ececec;
}
.readiness-grid-scroll::-webkit-scrollbar-thumb {
    background: #8d8d8d;
    border-radius: 999px;
    border: 2px solid #ececec;
}
.readiness-grid-scroll::-webkit-scrollbar-thumb:hover {
    background: #6f6f6f;
}

/* The Final Assessment "Assessment" row previously made this spacer
   transparent, so Baseline/Final cells showed through when scrolled. */
.readiness-summary-grid .summary-compare-row .summary-goal-spacer,
.readiness-summary-grid .summary-goal-spacer {
    background: #fff !important;
    opacity: 1 !important;
}

/* Avoid Chrome rowspan/sticky painting glitches by using one sticky fixed
   cell in every header row. The repeated cells are visually merged. */
.readiness-score-grid .goal-head,
.readiness-score-grid .sticky-goal-placeholder {
    position: sticky !important;
    left: 0 !important;
    width: var(--psrm-goal-width) !important;
    min-width: var(--psrm-goal-width) !important;
    max-width: var(--psrm-goal-width) !important;
    background: #21187a !important;
    z-index: 160 !important;
    box-sizing: border-box !important;
}
.readiness-score-grid .indicator-head,
.readiness-score-grid .sticky-indicator-placeholder {
    position: sticky !important;
    left: var(--psrm-goal-width) !important;
    width: var(--psrm-indicator-width) !important;
    min-width: var(--psrm-indicator-width) !important;
    max-width: var(--psrm-indicator-width) !important;
    background: #21187a !important;
    z-index: 161 !important;
    box-sizing: border-box !important;
    box-shadow: 2px 0 0 #111 !important;
}
.readiness-score-grid .sticky-goal-placeholder,
.readiness-score-grid .sticky-indicator-placeholder,
.readiness-score-grid.is-comparison-grid .sticky-goal-placeholder,
.readiness-score-grid.is-comparison-grid .sticky-indicator-placeholder {
    display: table-cell !important;
    padding: 0 !important;
    color: transparent !important;
}

/* Remove internal lines between the visually merged End Goal / Indicator
   header cells, while keeping the bottom edge of the final header row. */
.readiness-score-grid thead tr:not(:last-child) .goal-head,
.readiness-score-grid thead tr:not(:last-child) .indicator-head,
.readiness-score-grid thead tr:not(:last-child) .sticky-goal-placeholder,
.readiness-score-grid thead tr:not(:last-child) .sticky-indicator-placeholder {
    border-bottom-color: #21187a !important;
}
.readiness-score-grid thead tr:last-child .sticky-goal-placeholder,
.readiness-score-grid thead tr:last-child .sticky-indicator-placeholder {
    border-bottom: 1px solid #111 !important;
}

/* Student header/data cells must always paint below the fixed header block. */
.readiness-score-grid .students-super-head,
.readiness-score-grid .student-score-head,
.readiness-score-grid .student-sub-head,
.readiness-score-grid .score-input-cell {
    z-index: 1 !important;
}
