/* ============================================
   Grading Stream - Modern Grading Center
   ============================================ */

.grading-stream {
    display: flex;
    flex-direction: column;
    height: 100%;
    background-color: #f8fafc;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
}

.grading-stream--loading {
    justify-content: center;
    align-items: center;
}

/* ============================================
   Loading State
   ============================================ */

.grading-stream__loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 48px;
    color: #64748b;
}

.grading-stream__loading-spinner {
    margin-bottom: 16px;
    color: #3b82f6;
}

.grading-stream__loading-text {
    font-size: 14px;
}

/* ============================================
   Error State
   ============================================ */

.grading-stream__error {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 48px;
    text-align: center;
}

.grading-stream__error-icon {
    margin-bottom: 16px;
}

.grading-stream__error-message {
    margin-bottom: 24px;
    color: #64748b;
    font-size: 14px;
    max-width: 400px;
}

/* ============================================
   Content Container
   ============================================ */

.grading-stream__content {
    display: flex;
    flex-direction: column;
    height: 100%;
    overflow: hidden;
}

/* ============================================
   Toolbar
   ============================================ */

.grading-stream__toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: 12px 16px 0;
    padding: 10px 14px;
    background-color: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
    gap: 12px;
    flex-wrap: wrap;
}

.grading-stream__toolbar-left,
.grading-stream__toolbar-right {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.grading-stream__toolbar-divider {
    width: 1px;
    height: 22px;
    background-color: #e2e8f0;
}

.grading-stream__btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    height: 32px;
    padding: 0 10px;
    font-size: 12px;
    font-weight: 600;
    color: #475569;
    background-color: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    transition: background-color 180ms cubic-bezier(.16, 1, .3, 1), border-color 180ms cubic-bezier(.16, 1, .3, 1);
}

.grading-stream__btn:hover {
    background-color: #f8fafc;
    border-color: #cbd5e1;
}

.grading-stream__btn:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}

/* ============================================
   Filters
   ============================================ */

.grading-stream__filter {
    display: flex;
    align-items: center;
    gap: 8px;
}

.grading-stream__filter-label {
    font-size: 10px;
    font-weight: 700;
    color: #6c757d;
    text-transform: uppercase;
    letter-spacing: 0.4px;
    margin: 0;
    white-space: nowrap;
}

.grading-stream__filter-select {
    min-width: 140px;
    max-width: 190px;
    height: 32px;
    font-size: 12px;
    border-radius: 6px;
    border: 1px solid #e2e8f0;
    transition: border-color 180ms cubic-bezier(.16, 1, .3, 1), box-shadow 180ms cubic-bezier(.16, 1, .3, 1);
}

.grading-stream__filter-select:hover {
    border-color: #cbd5e1;
}

.grading-stream__filter-select:focus {
    border-color: #0074C5;
    outline: none;
    box-shadow: 0 0 0 2px rgba(0, 116, 197, 0.15);
}

/* ============================================
   View Toggle
   ============================================ */

.grading-stream__view-toggle .btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 32px;
    padding: 0 10px;
    background-color: #ffffff;
    color: #475569;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    transition: background-color 180ms cubic-bezier(.16, 1, .3, 1), color 180ms cubic-bezier(.16, 1, .3, 1), border-color 180ms cubic-bezier(.16, 1, .3, 1);
}

.grading-stream__view-toggle .btn:hover {
    background-color: #f8fafc;
}

.grading-stream__view-toggle .btn.active {
    background-color: #0074C5;
    color: #ffffff;
    border-color: #0074C5;
}

.grading-stream__view-toggle .btn:first-child {
    border-top-right-radius: 0;
    border-bottom-right-radius: 0;
}

.grading-stream__view-toggle .btn:last-child {
    border-top-left-radius: 0;
    border-bottom-left-radius: 0;
    border-left: none;
}

/* ============================================
   Connection Status
   ============================================ */

.grading-stream__connection {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 10px;
    border-radius: 16px;
    background-color: #fee2e2;
    font-size: 12px;
    font-weight: 500;
    color: #dc2626;
}

.grading-stream__connection--connected {
    background-color: #dcfce7;
    color: #16a34a;
}

.grading-stream__connection-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: currentColor;
}

.grading-stream__connection--connected .grading-stream__connection-dot {
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

/* ============================================
   Quick Filters
   ============================================ */

.grading-stream__quick-filters {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    padding: 12px 16px;
    background-color: #ffffff;
    border-bottom: 1px solid #e2e8f0;
}

.grading-stream__quick-filter {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    background-color: #f1f5f9;
    border: 1px solid transparent;
    border-radius: 14px;
    font-size: 11px;
    font-weight: 600;
    color: #475569;
    cursor: pointer;
    transition: background-color 180ms cubic-bezier(.16, 1, .3, 1), border-color 180ms cubic-bezier(.16, 1, .3, 1), color 180ms cubic-bezier(.16, 1, .3, 1);
    white-space: nowrap;
}

.grading-stream__quick-filter:hover {
    filter: brightness(0.97);
}

/* Semantic tint per chip - faint tint + colored icon by default,
   stronger pastel tint + matching 1px border when active. */
.grading-stream__quick-filter--review {
    background-color: rgba(217, 119, 6, 0.08);
}

.grading-stream__quick-filter--review.grading-stream__quick-filter--active {
    background-color: #fff3cd;
    border-color: #856404;
    color: #856404;
}

.grading-stream__quick-filter--missing {
    background-color: rgba(220, 38, 38, 0.08);
}

.grading-stream__quick-filter--missing.grading-stream__quick-filter--active {
    background-color: #f8d7da;
    border-color: #721c24;
    color: #721c24;
}

.grading-stream__quick-filter--late {
    background-color: rgba(133, 77, 14, 0.08);
}

.grading-stream__quick-filter--late.grading-stream__quick-filter--active {
    background-color: #fff3cd;
    border-color: #856404;
    color: #856404;
}

.grading-stream__quick-filter--complete {
    background-color: rgba(22, 101, 52, 0.08);
}

.grading-stream__quick-filter--complete.grading-stream__quick-filter--active {
    background-color: #d4edda;
    border-color: #155724;
    color: #155724;
}

.grading-stream__quick-filter--inProgress {
    background-color: rgba(37, 99, 235, 0.08);
}

.grading-stream__quick-filter--inProgress.grading-stream__quick-filter--active {
    background-color: #d1ecf1;
    border-color: #0c5460;
    color: #0c5460;
}

.grading-stream__quick-filter--notStarted {
    background-color: rgba(148, 163, 184, 0.08);
}

.grading-stream__quick-filter--notStarted.grading-stream__quick-filter--active {
    background-color: #e9ecef;
    border-color: #6c757d;
    color: #6c757d;
}

.grading-stream__quick-filter-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
}

.grading-stream__quick-filter-dot--attention {
    background-color: #f59e0b;
}

.grading-stream__quick-filter-dot--missing {
    background-color: #ef4444;
}

.grading-stream__quick-filter-dot--late {
    background-color: #8b5cf6;
}

.grading-stream__quick-filter-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 1px 6px;
    border-radius: 8px;
    background-color: rgba(0, 0, 0, 0.06);
    color: inherit;
    font-weight: 600;
    font-size: 10px;
    opacity: 0.85;
}

.grading-stream__quick-filter-clear {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    background: none;
    border: none;
    border-radius: 14px;
    font-size: 11px;
    font-weight: 600;
    color: #6c757d;
    cursor: pointer;
    transition: color 180ms cubic-bezier(.16, 1, .3, 1), background-color 180ms cubic-bezier(.16, 1, .3, 1);
}

.grading-stream__quick-filter-clear:hover {
    color: #0074C5;
    background-color: rgba(0, 116, 197, 0.08);
}

/* ============================================
   Batch Progress Bar (Axol AI runs + Assign All)
   ============================================ */

.grading-stream__batch-progress {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 16px;
    background-color: rgba(0, 116, 197, 0.08);
    border-bottom: 1px solid #e2e8f0;
}

.grading-stream__batch-progress-label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    font-weight: 600;
    color: #0074C5;
    white-space: nowrap;
}

.grading-stream__batch-progress-failed {
    color: #721c24;
}

.grading-stream__batch-progress-track {
    flex: 1;
    height: 6px;
    border-radius: 3px;
    background-color: rgba(0, 116, 197, 0.15);
    overflow: hidden;
}

.grading-stream__batch-progress-fill {
    height: 100%;
    border-radius: 3px;
    background-color: #0074C5;
    transition: width 180ms cubic-bezier(.16, 1, .3, 1);
}

/* ============================================
   Load More (item 3 - large-roster batching)
   ============================================ */

.grading-stream__load-more {
    display: flex;
    justify-content: center;
    padding: 12px 16px;
    background-color: #ffffff;
    border-top: 1px solid #e2e8f0;
}

.grading-stream__load-more-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    font-size: 13px;
    font-weight: 500;
    background-color: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    transition: background-color 180ms cubic-bezier(.16, 1, .3, 1), border-color 180ms cubic-bezier(.16, 1, .3, 1);
}

.grading-stream__load-more-btn:hover {
    background-color: #f8fafc;
    border-color: #cbd5e1;
}

/* ============================================
   Grid Container
   ============================================ */

.grading-stream__grid-container {
    flex: 1;
    overflow: hidden;
    padding: 16px;
}

.grading-stream__grid-container--hidden {
    height: 0;
    padding: 0;
    overflow: visible;
    flex: 0;
}

.grading-stream-grid-wrapper {
    height: 100%;
    width: 100%;
}

.grading-stream-grid-wrapper .ag-theme-alpine {
    height: 100%;
    width: 100%;
}

/* ============================================
   Card Container
   ============================================ */

.grading-stream__card-container {
    flex: 1;
    overflow: auto;
    padding: 16px;
}

/* ============================================
   Empty State
   ============================================ */

.grading-stream__empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 64px 24px;
    text-align: center;
}

.grading-stream__empty-icon {
    margin-bottom: 16px;
}

.grading-stream__empty-message {
    color: #64748b;
    font-size: 14px;
    margin-bottom: 12px;
}

/* ============================================
   Bulk Actions Bar
   ============================================ */

.grading-stream-bulk-actions {
    position: fixed;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1000;
}

.grading-stream-bulk-actions__bar {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 20px;
    background-color: #1e293b;
    border-radius: 12px;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.25);
    color: #ffffff;
}

.grading-stream-bulk-actions__count {
    font-size: 14px;
    font-weight: 600;
    padding-right: 12px;
    border-right: 1px solid #475569;
}

.grading-stream-bulk-actions__btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    background-color: #3b82f6;
    border: none;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 500;
    color: #ffffff;
    cursor: pointer;
    transition: background-color 0.15s ease;
}

.grading-stream-bulk-actions__btn:hover {
    background-color: #2563eb;
}

.grading-stream-bulk-actions__btn--secondary {
    background-color: #475569;
}

.grading-stream-bulk-actions__btn--secondary:hover {
    background-color: #334155;
}

.grading-stream-bulk-actions__close {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    background: none;
    border: none;
    border-radius: 6px;
    color: #94a3b8;
    cursor: pointer;
    margin-left: 4px;
}

.grading-stream-bulk-actions__close:hover {
    background-color: #334155;
    color: #ffffff;
}

/* ============================================
   Grid View Styles
   ============================================ */

.grading-stream-grid {
    height: 100%;
    width: 100%;
    background-color: #ffffff;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
    overflow: hidden;
}

.grading-stream-grid .ag-header {
    background-color: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
}

.grading-stream-grid .ag-header-cell {
    padding: 0 12px;
    font-size: 12px;
    font-weight: 600;
    color: #475569;
    text-transform: uppercase;
    letter-spacing: 0.025em;
}

.grading-stream-grid .ag-row {
    border-bottom: 1px solid #f1f5f9;
}

.grading-stream-grid .ag-row:hover {
    background-color: #f8fafc;
}

.grading-stream-grid .ag-row-selected {
    background-color: #eff6ff !important;
}

.grading-stream-grid .ag-cell {
    display: flex;
    align-items: center;
    padding: 0 12px;
    font-size: 13px;
}

/* ============================================
   Student Cell
   ============================================ */

.grading-stream-student-cell {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 0;
    width: 100%;
}

.grading-stream-student-cell__checkbox {
    width: 16px;
    height: 16px;
    cursor: pointer;
    accent-color: #3b82f6;
}

.grading-stream-student-cell__info {
    flex: 1;
    min-width: 0;
}

.grading-stream-student-cell__name {
    font-size: 14px;
    font-weight: 500;
    color: #1e293b;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.grading-stream-student-cell__id {
    font-size: 12px;
    color: #64748b;
}

.grading-stream-student-cell__average {
    text-align: right;
}

.grading-stream-student-cell__average-value {
    font-size: 14px;
    font-weight: 600;
    color: #1e293b;
}

.grading-stream-student-cell__average-label {
    font-size: 10px;
    color: #94a3b8;
    text-transform: uppercase;
}

/* ============================================
   Score Cell
   ============================================ */

.grading-stream-score-cell {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    cursor: pointer;
}

.grading-stream-score-cell__value {
    font-size: 14px;
    font-weight: 600;
    color: #1e293b;
}

.grading-stream-score-cell__points {
    font-size: 11px;
    color: #64748b;
}

.grading-stream-score-cell__status {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
}

.grading-stream-score-cell__dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
}

.grading-stream-score-cell__dot--success {
    background-color: #10b981;
}

.grading-stream-score-cell__dot--attention {
    background-color: #f59e0b;
}

.grading-stream-score-cell__dot--missing {
    background-color: #ef4444;
}

.grading-stream-score-cell__dot--progress {
    background-color: #94a3b8;
}

.grading-stream-score-cell--missing .grading-stream-score-cell__status {
    color: #dc2626;
}

.grading-stream-score-cell--attention .grading-stream-score-cell__status {
    color: #d97706;
}

.grading-stream-score-cell__late {
    font-size: 10px;
    font-weight: 600;
    color: #8b5cf6;
    text-transform: uppercase;
    margin-top: 2px;
}

.grading-stream-score-cell__dash {
    color: #cbd5e1;
    font-size: 18px;
}

/* AI-graded identity dot - small marker in the top-right of a score cell
   for results that came from Axol AI grading (click to review). */
.grading-stream-score-cell {
    position: relative;
}

.grading-stream-score-cell__ai-dot {
    position: absolute;
    top: 4px;
    right: 4px;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background-color: #dc2626;
    cursor: pointer;
}

/* Brief highlight flash applied to a student's row/cell when an Axol batch
   result lands for them (see vm.isRowFlashing in the controller). Fades over
   ~1.5s to match the timeout that removes the flag. */
.grading-stream-row--ai-flash,
.grading-stream-card--ai-flash {
    background-color: rgba(220, 38, 38, 0.08);
    transition: background-color 1.5s ease;
}

/* ============================================
   Card View Styles
   ============================================ */

.grading-stream-cards {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 16px;
}

.grading-stream-card {
    background-color: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    overflow: hidden;
    transition: box-shadow 0.15s ease;
}

.grading-stream-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.grading-stream-card--selected {
    border-color: #3b82f6;
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.2);
}

.grading-stream-card__header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px;
    border-bottom: 1px solid #f1f5f9;
}

.grading-stream-card__checkbox {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: #3b82f6;
}

.grading-stream-card__avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: #e2e8f0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    font-weight: 600;
    color: #64748b;
    flex-shrink: 0;
    overflow: hidden;
}

.grading-stream-card__avatar-img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
}

.grading-stream-card__info {
    flex: 1;
    min-width: 0;
}

.grading-stream-card__name {
    font-size: 14px;
    font-weight: 600;
    color: #1e293b;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.grading-stream-card__id {
    font-size: 12px;
    color: #64748b;
}

.grading-stream-card__average {
    text-align: right;
}

.grading-stream-card__average-value {
    font-size: 18px;
    font-weight: 700;
    color: #1e293b;
}

.grading-stream-card__average-label {
    font-size: 10px;
    color: #94a3b8;
    text-transform: uppercase;
}

.grading-stream-card__body {
    padding: 12px 16px;
}

.grading-stream-card__assignment {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid #f1f5f9;
    cursor: pointer;
}

.grading-stream-card__assignment:last-child {
    border-bottom: none;
}

.grading-stream-card__assignment:hover {
    background-color: #f8fafc;
    margin: 0 -16px;
    padding: 8px 16px;
}

.grading-stream-card__assignment-name {
    font-size: 13px;
    color: #475569;
    flex: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-right: 12px;
}

.grading-stream-card__assignment-score {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    font-weight: 500;
}

.grading-stream-card__assignment-score--complete {
    color: #10b981;
}

.grading-stream-card__assignment-score--attention {
    color: #f59e0b;
}

.grading-stream-card__assignment-score--missing {
    color: #ef4444;
}

.grading-stream-card__assignment-score--progress {
    color: #3b82f6;
}

.grading-stream-card__assignment-score--assigned {
    color: #94a3b8;
}

.grading-stream-card__assignment-score--retry {
    color: #ca8a04;
}

.grading-stream-card__assignment-score--empty {
    color: #cbd5e1;
    font-size: 16px;
}

.grading-stream-card__assignment-score--late {
    color: #ca8a04;
}

.grading-stream-card__assignment:hover .grading-stream-card__assignment-score--empty {
    color: #3b82f6;
}

/* Card view progress bars */
.grading-stream-card__bar {
    position: relative;
    width: 80px;
    height: 18px;
    background: #f1f5f9;
    border-radius: 9px;
    overflow: hidden;
    flex-shrink: 0;
}

.grading-stream-card__bar-fill {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    border-radius: 9px;
    transition: width 0.3s ease;
}

.grading-stream-card__bar-fill--high { background: linear-gradient(90deg, #22c55e, #16a34a); }
.grading-stream-card__bar-fill--mid { background: linear-gradient(90deg, #f59e0b, #d97706); }
.grading-stream-card__bar-fill--low { background: linear-gradient(90deg, #fb923c, #ea580c); }
.grading-stream-card__bar-fill--danger { background: linear-gradient(90deg, #ef4444, #dc2626); }

.grading-stream-card__bar-label {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    font-weight: 600;
    color: #fff;
    text-shadow: 0 1px 2px rgba(0,0,0,0.2);
    z-index: 1;
}

/* ============================================
   Score Popover
   ============================================ */

.grading-stream-popover {
    position: absolute;
    z-index: 1100;
    background-color: #ffffff;
    border-radius: 8px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
    padding: 16px;
    min-width: 200px;
}

.grading-stream-popover__title {
    font-size: 12px;
    font-weight: 600;
    color: #64748b;
    text-transform: uppercase;
    margin-bottom: 12px;
}

.grading-stream-popover__input-group {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
}

.grading-stream-popover__input {
    flex: 1;
    height: 36px;
    padding: 0 12px;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    font-size: 14px;
}

.grading-stream-popover__input:focus {
    border-color: #3b82f6;
    outline: none;
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.1);
}

.grading-stream-popover__suffix {
    font-size: 14px;
    color: #64748b;
}

.grading-stream-popover__actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
}

.grading-stream-popover__btn {
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
}

.grading-stream-popover__btn--primary {
    background-color: #3b82f6;
    border: none;
    color: #ffffff;
}

.grading-stream-popover__btn--primary:hover {
    background-color: #2563eb;
}

.grading-stream-popover__btn--secondary {
    background-color: #ffffff;
    border: 1px solid #e2e8f0;
    color: #475569;
}

.grading-stream-popover__btn--secondary:hover {
    background-color: #f8fafc;
}

/* ============================================
   Inline Editor
   ============================================ */

.grading-stream-inline-editor {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 4px;
    background-color: #ffffff;
    border-radius: 4px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.grading-stream-inline-editor__input {
    width: 60px;
    height: 28px;
    padding: 0 8px;
    border: 1px solid #3b82f6;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 500;
    text-align: center;
}

.grading-stream-inline-editor__input:focus {
    outline: none;
}

.grading-stream-inline-editor__suffix {
    font-size: 13px;
    color: #64748b;
}

/* ============================================
   Header Renderer
   ============================================ */

.grading-stream-header {
    display: flex;
    flex-direction: column;
    justify-content: center;
    height: 100%;
    padding: 8px 0;
}

.grading-stream-header__name {
    font-size: 12px;
    font-weight: 600;
    color: #475569;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
}

.grading-stream-header__type-icon {
    margin-top: 4px;
    opacity: 0.7;
}

/* Column header stats: submitted count / class average / empty state */
.grading-stream-header__stats {
    font-size: 11px;
    margin-top: 2px;
}

.grading-stream-header__stats--avg {
    color: #475569;
    font-weight: 600;
}

.grading-stream-header__stats--submitted {
    color: #2563eb;
}

.grading-stream-header__stats--empty {
    color: #94a3b8;
    font-style: italic;
}

/* ============================================
   Responsive Adjustments
   ============================================ */

@media (max-width: 768px) {
    .grading-stream__toolbar {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
        margin: 12px 12px 0;
    }

    .grading-stream__toolbar-left,
    .grading-stream__toolbar-right {
        justify-content: space-between;
    }

    .grading-stream__filter {
        flex: 1;
    }

    .grading-stream__filter-select {
        max-width: none;
        width: 100%;
    }

    .grading-stream__quick-filters {
        padding: 8px 12px;
    }

    .grading-stream__quick-filter {
        padding: 4px 10px;
        font-size: 11px;
    }

    .grading-stream-bulk-actions__bar {
        flex-wrap: wrap;
        justify-content: center;
        max-width: 90vw;
    }
}

/* Display options popover */
.grading-stream__display { position: relative; }
.grading-stream__btn--active { border-color: #0074C5; color: #0074C5; background: rgba(0,116,197,0.06); }
.grading-stream__display-dot { position: absolute; top: 4px; right: 4px; width: 7px; height: 7px; border-radius: 50%; background: #0074C5; }
.grading-stream__display-backdrop { position: fixed; inset: 0; z-index: 1049; }
.grading-stream__display-panel { position: absolute; right: 0; top: calc(100% + 6px); z-index: 1050; width: 240px; background: #fff; border: 1px solid #e2e8f0; border-radius: 8px; box-shadow: 0 4px 16px rgba(0,0,0,0.12); padding: 12px 14px; display: flex; flex-direction: column; gap: 10px; }
.grading-stream__display-row { display: flex; flex-direction: column; gap: 3px; }
.grading-stream__display-row .grading-stream__filter-select { width: 100%; }
