/* ============================================
   ZyaCBT Modern UI - Design System v2.0
   Professional, Contrasting, Responsive
   Bootstrap 5 Override & Custom Styles
   ============================================ */

/* --- CSS Custom Properties (Design Tokens) --- */
:root {
    --font-primary: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --color-primary: #4f46e5;
    --color-primary-hover: #4338ca;
    --color-primary-light: #eef2ff;
    --color-primary-dark: #3730a3;
    --color-secondary: #0ea5e9;
    --color-secondary-light: #e0f2fe;
    --color-success: #059669;
    --color-success-light: #d1fae5;
    --color-warning: #d97706;
    --color-warning-light: #fef3c7;
    --color-danger: #dc2626;
    --color-danger-light: #fee2e2;
    --color-body-bg: #f1f5f9;
    --color-surface: #ffffff;
    --color-text: #0f172a;
    --color-text-secondary: #334155;
    --color-text-muted: #64748b;
    --color-border: #e2e8f0;
    --color-border-light: #f1f5f9;
    --sidebar-bg: linear-gradient(180deg, #1e1b4b 0%, #312e81 50%, #3730a3 100%);
    --sidebar-width: 264px;
    --sidebar-collapsed-width: 72px;
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --shadow-xs: 0 1px 2px rgba(0, 0, 0, .05);
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, .08), 0 1px 2px rgba(0, 0, 0, .06);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, .08), 0 2px 4px -2px rgba(0, 0, 0, .05);
    --shadow-lg: 0 10px 25px -5px rgba(0, 0, 0, .1), 0 8px 10px -6px rgba(0, 0, 0, .06);
    --shadow-xl: 0 20px 40px -8px rgba(0, 0, 0, .12);
    --transition-fast: 180ms cubic-bezier(.4, 0, .2, 1);
    --transition-normal: 280ms cubic-bezier(.4, 0, .2, 1);
    --transition-slow: 400ms cubic-bezier(.4, 0, .2, 1);
}

/* --- Global Reset & Base --- */
*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    font-size: 15px;
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-primary);
    background-color: var(--color-body-bg);
    color: var(--color-text);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

/* --- Typography --- */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-weight: 700;
    line-height: 1.3;
    color: var(--color-text);
}

/* --- Bootstrap 5 Overrides --- */
.btn {
    font-family: var(--font-primary);
    font-weight: 600;
    border-radius: var(--radius-sm);
    padding: .5rem 1.15rem;
    font-size: .875rem;
    transition: all var(--transition-fast);
    border: none;
    letter-spacing: .01em;
}

.btn:active {
    transform: scale(.97);
}

.btn-primary {
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-hover) 100%);
    color: #fff;
    box-shadow: 0 2px 8px rgba(79, 70, 229, .25);
}

.btn-primary:hover,
.btn-primary:focus {
    background: linear-gradient(135deg, var(--color-primary-hover) 0%, var(--color-primary-dark) 100%);
    color: #fff;
    box-shadow: 0 4px 12px rgba(79, 70, 229, .35);
    transform: translateY(-1px);
}

.btn-success {
    background: linear-gradient(135deg, #059669, #047857);
    color: #fff;
    box-shadow: 0 2px 8px rgba(5, 150, 105, .25);
}

.btn-success:hover {
    box-shadow: 0 4px 12px rgba(5, 150, 105, .35);
    transform: translateY(-1px);
    color: #fff;
}

.btn-warning {
    background: linear-gradient(135deg, #d97706, #b45309);
    color: #fff;
    box-shadow: 0 2px 8px rgba(217, 119, 6, .25);
}

.btn-warning:hover {
    box-shadow: 0 4px 12px rgba(217, 119, 6, .35);
    transform: translateY(-1px);
    color: #fff;
}

.btn-danger {
    background: linear-gradient(135deg, #dc2626, #b91c1c);
    color: #fff;
    box-shadow: 0 2px 8px rgba(220, 38, 38, .25);
}

.btn-danger:hover {
    box-shadow: 0 4px 12px rgba(220, 38, 38, .35);
    transform: translateY(-1px);
    color: #fff;
}

.btn-outline-secondary {
    border: 1.5px solid var(--color-border);
    color: var(--color-text-secondary);
    background: var(--color-surface);
}

.btn-outline-secondary:hover {
    background: var(--color-body-bg);
    border-color: #cbd5e1;
    color: var(--color-text);
}

.btn-lg {
    padding: .7rem 1.6rem;
    font-size: 1rem;
    border-radius: var(--radius-md);
}

/* Card */
.card {
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    background: var(--color-surface);
    transition: box-shadow var(--transition-normal), transform var(--transition-normal);
}

.card:hover {
    box-shadow: var(--shadow-md);
}

.card-body {
    padding: 1.35rem;
}

.card-header {
    padding: .85rem 1.35rem;
    border-bottom: 1px solid var(--color-border-light);
    font-weight: 600;
}

/* Form */
.form-control,
.form-select {
    font-family: var(--font-primary);
    border: 1.5px solid var(--color-border);
    border-radius: var(--radius-sm);
    padding: .6rem .9rem;
    font-size: .9rem;
    transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
    background-color: var(--color-surface);
    color: var(--color-text);
}

.form-control:focus,
.form-select:focus {
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(79, 70, 229, .15);
}

.form-label {
    font-weight: 600;
    font-size: .85rem;
    color: var(--color-text);
    margin-bottom: .4rem;
}

/* Table */
.table {
    --bs-table-bg: transparent;
    font-size: .875rem;
}

.table>thead>tr>th {
    font-weight: 700;
    font-size: .78rem;
    text-transform: uppercase;
    letter-spacing: .05em;
    color: #475569;
    background: #f8fafc;
    border-bottom: 2px solid var(--color-border);
    padding: .8rem .75rem;
    white-space: nowrap;
}

.table>tbody>tr>td {
    padding: .75rem;
    vertical-align: middle;
    border-bottom: 1px solid var(--color-border-light);
}

.table>tbody>tr:last-child>td {
    border-bottom: none;
}

.table>tbody>tr:hover>td {
    background: rgba(79, 70, 229, .03);
}

/* Badge */
.badge {
    font-weight: 600;
    font-size: .72rem;
    padding: .35em .7em;
    border-radius: 999px;
    letter-spacing: .02em;
}

/* Modal */
.modal-content {
    border: none;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xl);
    overflow: hidden;
}

.modal-header {
    border-bottom: 1px solid var(--color-border-light);
    padding: 1rem 1.25rem;
    background: var(--color-body-bg);
}

.modal-header .modal-title,
.modal-header div {
    font-weight: 700;
    font-size: 1rem;
}

.modal-footer {
    border-top: 1px solid var(--color-border-light);
    padding: 1rem 1.25rem;
}

.modal-body {
    padding: 1.25rem;
    overflow-y: auto;
    overflow-x: hidden;
    max-height: 70vh;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

/* Fix BS3 .row-fluid and .box-body inside modals to prevent content overflow */
.modal .row-fluid {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
}

.modal .row-fluid > *,
.modal .box-body {
    flex-shrink: 1 !important;
    min-width: 0 !important;
    flex: 1 1 100% !important;
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
    word-wrap: break-word !important;
    overflow-wrap: break-word !important;
    white-space: normal !important;
}

/* Alert */
.alert {
    border: none;
    border-radius: var(--radius-sm);
    font-size: .875rem;
    font-weight: 500;
}

/* --- Navbar (Student Pages) --- */
.zy-navbar {
    background: var(--color-surface);
    border-bottom: 1px solid var(--color-border);
    box-shadow: var(--shadow-xs);
    padding: .55rem 0;
    position: sticky;
    top: 0;
    z-index: 1030;
}

.zy-navbar .navbar-brand {
    font-weight: 800;
    font-size: 1.08rem;
    color: var(--color-primary);
    letter-spacing: -.02em;
}

.zy-navbar .nav-link {
    color: var(--color-text-muted);
    font-size: .85rem;
    font-weight: 500;
}

/* --- Login Page --- */
.login-page {
    min-height: 100vh;
    display: flex;
    background: var(--color-body-bg);
}

.login-brand-panel {
    flex: 1;
    background: linear-gradient(135deg, #1e1b4b 0%, #3730a3 40%, #4f46e5 100%);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 3rem;
    color: #fff;
    position: relative;
    overflow: hidden;
}

.login-brand-panel::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -30%;
    width: 160%;
    height: 200%;
    background: radial-gradient(ellipse at 30% 50%, rgba(255, 255, 255, .08) 0%, transparent 60%);
    pointer-events: none;
    animation: floatGradient 15s ease-in-out infinite alternate;
}

@keyframes floatGradient {
    0% {
        transform: translate(0, 0) scale(1);
    }

    100% {
        transform: translate(5%, 3%) scale(1.05);
    }
}

.login-brand-panel h1 {
    font-size: 2.4rem;
    font-weight: 800;
    color: #fff;
    z-index: 1;
    letter-spacing: -.03em;
}

.login-brand-panel p {
    opacity: .85;
    max-width: 380px;
    text-align: center;
    z-index: 1;
    font-size: .95rem;
    line-height: 1.7;
}

.login-form-panel {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 2rem;
}

.login-card {
    width: 100%;
    max-width: 420px;
}

.login-card .card-body {
    padding: 2.25rem;
}

.login-card h2 {
    font-size: 1.6rem;
    font-weight: 800;
    margin-bottom: .5rem;
    color: var(--color-text);
}

.login-card .text-muted {
    font-size: .875rem;
}

.login-card .card {
    box-shadow: var(--shadow-lg);
    border: none;
}

@media (max-width: 767.98px) {
    .login-brand-panel {
        display: none;
    }

    .login-form-panel {
        padding: 1.5rem;
    }

    .login-card .card-body {
        padding: 1.75rem;
    }
}

/* --- Dashboard Student (Exam List) --- */
.exam-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1rem;
}

.exam-card {
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    background: var(--color-surface);
    padding: 1.25rem;
    transition: all var(--transition-normal);
    display: flex;
    flex-direction: column;
    gap: .75rem;
    border-left: 4px solid var(--color-primary);
}

.exam-card:hover {
    box-shadow: var(--shadow-md);
    border-left-color: var(--color-primary-hover);
    transform: translateY(-2px);
}

.exam-card .exam-title {
    font-weight: 700;
    font-size: 1.05rem;
    color: var(--color-text);
}

.exam-card .exam-meta {
    font-size: .8rem;
    color: var(--color-text-muted);
    display: flex;
    flex-direction: column;
    gap: .25rem;
}

.exam-card .btn-start {
    align-self: flex-end;
    margin-top: auto;
}

/* --- Exam Page (Critical) --- */
.exam-timer-bar {
    position: sticky;
    top: 0;
    z-index: 1020;
    background: var(--color-surface);
    border-bottom: 2px solid var(--color-border);
    padding: .55rem 1rem;
    display: flex;
    align-items: center;
    gap: .5rem;
    box-shadow: var(--shadow-sm);
}

.exam-timer-bar .timer-display {
    font-variant-numeric: tabular-nums;
    font-weight: 800;
    font-size: 1.05rem;
    color: var(--color-primary);
    display: flex;
    align-items: center;
    gap: .4rem;
    background: var(--color-primary-light);
    padding: .35rem .75rem;
    border-radius: var(--radius-sm);
}

.exam-timer-bar .timer-display.timer-warning {
    color: var(--color-warning);
    background: var(--color-warning-light);
}

.exam-timer-bar .timer-display.timer-danger {
    color: var(--color-danger);
    background: var(--color-danger-light);
    animation: timerPulse 1s ease-in-out infinite;
}

@keyframes timerPulse {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: .6;
    }
}

.exam-container {
    display: grid;
    grid-template-columns: 1fr 260px;
    gap: 1.25rem;
    max-width: 1100px;
    margin: 1.25rem auto;
    padding: 0 1rem;
}

@media (max-width: 991.98px) {
    .exam-container {
        grid-template-columns: 1fr;
    }
}

.exam-question-panel {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    padding: 1.5rem;
    min-height: 400px;
    box-shadow: var(--shadow-xs);
}

@media (max-width: 575.98px) {
    .exam-container {
        padding: 0 .5rem;
        margin-top: .75rem;
    }

    .exam-question-panel {
        padding: 1rem;
        border-radius: var(--radius-sm);
    }
}

.exam-question-panel .question-header {
    font-size: .78rem;
    text-transform: uppercase;
    letter-spacing: .06em;
    color: var(--color-primary);
    font-weight: 700;
    margin-bottom: 1rem;
    padding-bottom: .75rem;
    border-bottom: 2px solid var(--color-primary-light);
}

.exam-question-panel .question-body {
    font-size: inherit;
    line-height: inherit;
    word-wrap: break-word;
    word-break: break-word;
}

.exam-question-panel .question-body,
.exam-question-panel .question-body p,
.exam-question-panel .question-body div,
.exam-question-panel .question-body span {
    text-align: left !important;
}

.exam-question-panel .question-body table {
    display: block;
    width: 100% !important;
    max-width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin-bottom: 1rem;
}

.exam-question-panel img {
    max-width: 100% !important;
    height: auto !important;
    border-radius: var(--radius-sm);
    margin: .5rem 0;
    object-fit: contain;
}

/* Answer Options */
label.answer-option {
    display: flex !important;
    align-items: flex-start;
    gap: .75rem;
    padding: .9rem 1rem;
    border: 1.5px solid var(--color-border);
    border-radius: var(--radius-sm);
    margin-bottom: .5rem;
    cursor: pointer;
    transition: all var(--transition-fast);
    background: var(--color-surface);
    font-size: inherit;
}

.exam-question-panel label.answer-option,
.exam-question-panel label.answer-option>div,
.exam-question-panel label.answer-option>div * {
    font-size: inherit !important;
    line-height: inherit !important;
}

label.answer-option>div {
    flex: 1;
    overflow-x: auto;
    width: 100%;
    font-size: inherit;
}

label.answer-option>div *:first-child {
    margin-top: 0;
}

label.answer-option>div *:last-child {
    margin-bottom: 0;
}

label.answer-option:hover {
    border-color: var(--color-primary);
    background: var(--color-primary-light);
    transform: translateX(4px);
}

label.answer-option.selected {
    border-color: var(--color-primary);
    background: var(--color-primary-light);
    box-shadow: 0 0 0 3px rgba(79, 70, 229, .12);
}

label.answer-option input[type="radio"],
label.answer-option input[type="checkbox"] {
    margin-top: .2rem;
    accent-color: var(--color-primary);
    width: 18px;
    height: 18px;
    flex-shrink: 0;
}

/* Benar-Salah Kompleks Table */
.bs-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
}

.bs-table th {
    font-weight: 700;
    font-size: .78rem;
    text-transform: uppercase;
    letter-spacing: .04em;
    padding: .65rem .75rem;
    background: var(--color-body-bg);
    border-bottom: 2px solid var(--color-border);
    text-align: center;
}

.bs-table th:first-child {
    text-align: left;
}

.bs-table td {
    padding: .75rem;
    border-bottom: 1px solid var(--color-border-light);
    vertical-align: middle;
}

.bs-table td:not(:first-child) {
    text-align: center;
}

.bs-table input[type="radio"] {
    width: 18px;
    height: 18px;
    accent-color: var(--color-primary);
}

/* Menjodohkan / Matching */
.matching-item {
    display: flex;
    align-items: center;
    gap: .75rem;
    margin-bottom: .65rem;
    flex-wrap: wrap;
}

.matching-item .match-left {
    flex: 1;
    min-width: 150px;
    padding: .6rem .85rem;
    background: var(--color-body-bg);
    border-radius: var(--radius-sm);
    font-size: .9rem;
    border: 1px solid var(--color-border-light);
}

.matching-item .match-right {
    flex: 1;
    min-width: 150px;
}

.matching-item .form-select {
    font-size: .85rem;
}

/* Navigation Buttons */
.question-nav-buttons {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: .75rem;
    margin-top: 1.25rem;
    padding-top: 1rem;
    border-top: 2px solid var(--color-border-light);
}

.btn-doubt {
    background: var(--color-warning-light);
    color: #92400e;
    border: 1.5px solid #fcd34d;
    font-size: .85rem;
    display: flex;
    align-items: center;
    gap: .35rem;
    font-weight: 600;
}

.btn-doubt:hover {
    background: #fde68a;
    color: #78350f;
}

/* Question Navigator Sidebar */
.exam-nav-panel {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    padding: 1rem;
    position: sticky;
    top: 70px;
    max-height: calc(100vh - 90px);
    overflow-y: auto;
    box-shadow: var(--shadow-xs);
}

.exam-nav-panel h6 {
    font-size: .72rem;
    text-transform: uppercase;
    letter-spacing: .06em;
    color: var(--color-text-muted);
    font-weight: 700;
    margin-bottom: .75rem;
}

.question-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 6px;
}

.question-grid .q-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    aspect-ratio: 1;
    border: 1.5px solid var(--color-border);
    border-radius: var(--radius-sm);
    font-size: .8rem;
    font-weight: 700;
    cursor: pointer;
    transition: all var(--transition-fast);
    background: var(--color-surface);
    color: var(--color-text-muted);
    text-decoration: none;
    line-height: 1;
}

.question-grid .q-btn:hover {
    border-color: var(--color-primary);
    color: var(--color-primary);
}

.question-grid .q-btn.q-active,
.question-grid .q-btn.q-answered {
    background: var(--color-primary);
    color: #fff;
    border-color: var(--color-primary);
    box-shadow: 0 2px 6px rgba(79, 70, 229, .3);
}

.question-grid .q-btn.q-doubt {
    background: var(--color-warning);
    color: #fff;
    border-color: var(--color-warning);
}

.question-grid .q-btn.q-current {
    box-shadow: 0 0 0 2px var(--color-primary), 0 0 0 4px rgba(79, 70, 229, .2);
}

.nav-legend {
    display: flex;
    flex-wrap: wrap;
    gap: .5rem;
    margin-top: .85rem;
    font-size: .72rem;
    color: var(--color-text-muted);
}

.nav-legend span {
    display: flex;
    align-items: center;
    gap: .3rem;
}

.nav-legend .dot {
    width: 10px;
    height: 10px;
    border-radius: 3px;
    display: inline-block;
}

.nav-legend .dot-answered {
    background: var(--color-primary);
}

.nav-legend .dot-doubt {
    background: var(--color-warning);
}

.nav-legend .dot-empty {
    background: var(--color-surface);
    border: 1.5px solid var(--color-border);
}

/* ============================================
   ADMIN SIDEBAR LAYOUT
   ============================================ */
.admin-wrapper {
    display: flex;
    min-height: 100vh;
}

.admin-sidebar {
    width: var(--sidebar-width);
    background: var(--sidebar-bg);
    color: #e2e8f0;
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 1040;
    transition: transform var(--transition-normal), width var(--transition-normal);
    overflow-y: auto;
    box-shadow: 4px 0 20px rgba(0, 0, 0, .15);
}

.admin-sidebar .sidebar-brand {
    padding: 1.2rem 1.3rem;
    font-weight: 800;
    font-size: 1.15rem;
    color: #fff;
    border-bottom: 1px solid rgba(255, 255, 255, .08);
    letter-spacing: -.02em;
    display: flex;
    align-items: center;
    gap: .5rem;
}

.admin-sidebar .sidebar-brand i {
    color: #a5b4fc;
}

.admin-sidebar .sidebar-user {
    padding: 1rem 1.3rem;
    display: flex;
    align-items: center;
    gap: .75rem;
    border-bottom: 1px solid rgba(255, 255, 255, .06);
    background: rgba(255, 255, 255, .03);
}

.admin-sidebar .sidebar-user .avatar {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: linear-gradient(135deg, #818cf8, #6366f1);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: .82rem;
    color: #fff;
    box-shadow: 0 2px 8px rgba(99, 102, 241, .4);
}

.admin-sidebar .sidebar-user .user-name {
    font-weight: 600;
    font-size: .88rem;
    color: #fff;
}

.admin-sidebar .sidebar-user .user-role {
    font-size: .72rem;
    color: #a5b4fc;
}

.sidebar-nav-label {
    font-size: .65rem;
    text-transform: uppercase;
    letter-spacing: .1em;
    color: #818cf8;
    padding: 1.2rem 1.3rem .4rem;
    font-weight: 700;
}

.sidebar-nav a {
    display: flex;
    align-items: center;
    gap: .7rem;
    padding: .6rem 1.3rem;
    font-size: .87rem;
    color: #c7d2fe;
    text-decoration: none;
    transition: all var(--transition-fast);
    border-left: 3px solid transparent;
    font-weight: 500;
}

.sidebar-nav a:hover {
    background: rgba(255, 255, 255, .08);
    color: #fff;
    border-left-color: rgba(165, 180, 252, .4);
}

.sidebar-nav a.active {
    background: rgba(99, 102, 241, .2);
    color: #fff;
    border-left-color: #818cf8;
    font-weight: 600;
}

.sidebar-nav a i,
.sidebar-nav a .bi {
    font-size: 1.05rem;
    width: 22px;
    text-align: center;
    opacity: .8;
}

.sidebar-nav a.active i,
.sidebar-nav a.active .bi {
    opacity: 1;
}

/* Admin Main */
.admin-main {
    flex: 1;
    min-width: 0;
    margin-left: var(--sidebar-width);
    display: flex;
    flex-direction: column;
    transition: margin-left var(--transition-normal);
    overflow-x: hidden;
}

.admin-topbar {
    background: var(--color-surface);
    border-bottom: 1px solid var(--color-border);
    box-shadow: var(--shadow-xs);
    padding: .65rem 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 1020;
}

.admin-topbar .breadcrumb {
    margin: 0;
    font-size: .8rem;
    background: none;
    padding: 0;
}

.admin-topbar h6 {
    font-weight: 700;
    color: var(--color-text);
}

.admin-content {
    padding: 1.5rem;
    flex: 1;
    min-width: 0;
    overflow-x: auto;
}

.admin-footer {
    padding: .85rem 1.5rem;
    font-size: .75rem;
    color: var(--color-text-muted);
    border-top: 1px solid var(--color-border);
    background: var(--color-surface);
    text-align: center;
}

/* Stat Cards (Admin Dashboard) */
.stat-card {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    padding: 1.25rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    transition: all var(--transition-normal);
    border-left: 4px solid var(--color-border);
}

.stat-card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.stat-card .stat-icon {
    width: 50px;
    height: 50px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    flex-shrink: 0;
}

.stat-card .stat-icon.bg-blue {
    background: var(--color-primary-light);
    color: var(--color-primary);
}

.stat-card .stat-icon.bg-green {
    background: var(--color-success-light);
    color: var(--color-success);
}

.stat-card .stat-icon.bg-yellow {
    background: var(--color-warning-light);
    color: var(--color-warning);
}

.stat-card .stat-icon.bg-red {
    background: var(--color-danger-light);
    color: var(--color-danger);
}

.stat-card .stat-value {
    font-size: 1.5rem;
    font-weight: 800;
    line-height: 1;
}

.stat-card .stat-label {
    font-size: .78rem;
    color: var(--color-text-muted);
    font-weight: 500;
}

/* Dynamic stat-card border colors */
.stat-card:has(.bg-blue) {
    border-left-color: var(--color-primary);
}

.stat-card:has(.bg-green) {
    border-left-color: var(--color-success);
}

.stat-card:has(.bg-yellow) {
    border-left-color: var(--color-warning);
}

.stat-card:has(.bg-red) {
    border-left-color: var(--color-danger);
}

/* ============================================
   SIDEBAR COLLAPSED MODE (Desktop)
   ============================================ */
.sidebar-collapsed .admin-sidebar {
    width: var(--sidebar-collapsed-width);
    overflow-x: hidden;
}

.sidebar-collapsed .sidebar-brand {
    padding: .85rem .5rem;
    font-size: 0;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    letter-spacing: 0;
    justify-content: center;
}

.sidebar-collapsed .sidebar-brand i,
.sidebar-collapsed .sidebar-brand .bi {
    font-size: 1.3rem;
    margin: 0;
}

.sidebar-collapsed .sidebar-user {
    padding: .65rem 0;
    justify-content: center;
}

.sidebar-collapsed .sidebar-user>div:last-child {
    display: none;
}

.sidebar-collapsed .sidebar-nav-label {
    font-size: 0;
    padding: .6rem 0 .15rem;
    text-align: center;
    overflow: hidden;
    line-height: 1;
}

.sidebar-collapsed .sidebar-nav-label::after {
    content: '···';
    font-size: .55rem;
    color: #6366f1;
    letter-spacing: 2px;
}

.sidebar-collapsed .sidebar-nav>a {
    font-size: 0 !important;
    line-height: 0 !important;
    padding: .75rem 0 !important;
    justify-content: center !important;
    align-items: center !important;
    border-left: 3px solid transparent;
    overflow: hidden;
    white-space: nowrap;
    gap: 0 !important;
    color: #c7d2fe;
    text-align: center;
}

.sidebar-collapsed .sidebar-nav>a i,
.sidebar-collapsed .sidebar-nav>a .fa,
.sidebar-collapsed .sidebar-nav>a .bi {
    font-size: 1.15rem !important;
    line-height: 1 !important;
    width: 22px;
    margin: 0 !important;
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
}

.sidebar-collapsed .sidebar-nav>a>span {
    font-size: 0 !important;
    line-height: 0 !important;
    gap: 0 !important;
    overflow: hidden;
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    width: auto;
    max-width: 22px;
}

.sidebar-collapsed .sidebar-nav>a>.bi-chevron-down,
.sidebar-collapsed .sidebar-nav>a>i.bi-chevron-down {
    display: none !important;
}

.sidebar-collapsed .sidebar-nav>.collapse,
.sidebar-collapsed .sidebar-nav>.collapse.show,
.sidebar-collapsed .sidebar-nav>div[class*="collapse"] {
    display: none !important;
    height: 0 !important;
    overflow: hidden !important;
}

.sidebar-collapsed .sidebar-nav>a.active {
    background: rgba(99, 102, 241, .2);
    color: #fff;
    border-left-color: #818cf8;
}

.sidebar-collapsed .admin-main {
    margin-left: var(--sidebar-collapsed-width);
}

.admin-sidebar,
.admin-main {
    transition: all .25s ease;
}

/* ============================================
   MOBILE RESPONSIVE
   ============================================ */
@media (max-width: 991.98px) {
    .admin-sidebar {
        transform: translateX(-100%);
    }

    .admin-sidebar.show {
        transform: translateX(0);
        box-shadow: 8px 0 30px rgba(0, 0, 0, .3);
    }

    .admin-main {
        margin-left: 0;
    }

    .admin-content {
        padding: 1rem;
    }

    .admin-topbar {
        padding: .6rem 1rem;
    }

    .sidebar-collapsed .admin-sidebar {
        width: var(--sidebar-width);
    }

    .sidebar-collapsed .admin-main {
        margin-left: 0;
    }

    .sidebar-collapsed .sidebar-brand {
        font-size: 1.15rem;
        text-align: left;
        padding: 1.2rem 1.3rem;
        justify-content: flex-start;
    }

    .sidebar-collapsed .sidebar-user {
        padding: 1rem 1.3rem;
        justify-content: flex-start;
    }

    .sidebar-collapsed .sidebar-user>div:last-child {
        display: block;
    }

    .sidebar-collapsed .sidebar-nav-label {
        font-size: .65rem;
        padding: 1.2rem 1.3rem .4rem;
        text-align: left;
        line-height: normal;
    }

    .sidebar-collapsed .sidebar-nav-label::after {
        content: none;
    }

    .sidebar-collapsed .sidebar-nav>a {
        font-size: .87rem;
        line-height: 1.5;
        padding: .6rem 1.3rem;
        justify-content: space-between;
        gap: .7rem;
    }

    .sidebar-collapsed .sidebar-nav>a>span {
        font-size: .87rem;
        line-height: 1.5;
        gap: .7rem;
        max-width: none;
    }

    .sidebar-collapsed .sidebar-nav>a>.bi-chevron-down,
    .sidebar-collapsed .sidebar-nav>a>i.bi-chevron-down {
        display: inline-block !important;
        font-size: .7rem;
    }

    .sidebar-collapsed .sidebar-nav>.collapse.show,
    .sidebar-collapsed .sidebar-nav>div[class*="collapse"].show {
        display: block !important;
        height: auto !important;
        overflow: visible !important;
    }
}

@media (max-width: 575.98px) {
    .stat-card {
        padding: 1rem;
    }

    .stat-card .stat-icon {
        width: 42px;
        height: 42px;
        font-size: 1.1rem;
    }

    .stat-card .stat-value {
        font-size: 1.3rem;
    }

    .box-body {
        padding: .75rem;
    }

    .admin-content {
        padding: .75rem;
    }

    h1 {
        font-size: 1.2rem;
    }
}

/* --- Toast / Notification --- */
.zy-toast-container {
    position: fixed;
    top: 1rem;
    right: 1rem;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: .5rem;
    max-width: 380px;
}

.zy-toast {
    display: flex;
    align-items: flex-start;
    gap: .65rem;
    padding: .9rem 1.1rem;
    border-radius: var(--radius-sm);
    background: var(--color-surface);
    box-shadow: var(--shadow-lg);
    border-left: 4px solid var(--color-primary);
    font-size: .85rem;
    animation: toastIn var(--transition-normal) ease-out;
    transition: all var(--transition-normal);
}

.zy-toast.toast-success {
    border-left-color: var(--color-success);
}

.zy-toast.toast-error {
    border-left-color: var(--color-danger);
}

.zy-toast.toast-info {
    border-left-color: var(--color-primary);
}

.zy-toast.toast-out {
    opacity: 0;
    transform: translateX(100%);
}

@keyframes toastIn {
    from {
        opacity: 0;
        transform: translateX(100%);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* --- Utility --- */
.text-primary-custom {
    color: var(--color-primary) !important;
}

.bg-surface {
    background: var(--color-surface);
}

.border-subtle {
    border-color: var(--color-border) !important;
}

.fs-sm {
    font-size: .85rem !important;
}

.fs-xs {
    font-size: .75rem !important;
}

.fw-semibold {
    font-weight: 600 !important;
}

/* Loading Overlay */
.loading-overlay {
    position: fixed;
    inset: 0;
    background: rgba(255, 255, 255, .75);
    -webkit-backdrop-filter: blur(4px);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9998;
}

.loading-overlay .spinner {
    width: 40px;
    height: 40px;
    border: 3px solid var(--color-border);
    border-top-color: var(--color-primary);
    border-radius: 50%;
    animation: spin .6s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Print */
@media print {

    .zy-navbar,
    .exam-timer-bar,
    .exam-nav-panel,
    .admin-sidebar,
    .admin-topbar,
    .no-print {
        display: none !important;
    }

    .admin-main {
        margin-left: 0 !important;
    }

    .exam-container {
        grid-template-columns: 1fr !important;
    }
}

/* ============================================
   AdminLTE Backward Compatibility Layer
   ============================================ */
.content-header {
    padding: 0 0 1.25rem;
}

.content-header h1 {
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--color-text);
    margin: 0;
    line-height: 1.4;
}

.content-header h1 small {
    display: block;
    font-size: .82rem;
    font-weight: 400;
    color: var(--color-text-muted);
    margin-top: .25rem;
}

.content-header .breadcrumb {
    list-style: none;
    display: flex;
    gap: .35rem;
    padding: 0;
    margin: .5rem 0 0;
    font-size: .8rem;
    background: none;
}

.content-header .breadcrumb li+li::before {
    content: '/';
    margin-right: .35rem;
    color: var(--color-text-muted);
}

.content-header .breadcrumb li a {
    color: var(--color-primary);
    text-decoration: none;
}

.content-header .breadcrumb li.active {
    color: var(--color-text-muted);
}

section.content {
    padding: 0;
}

/* Box (AdminLTE Card) */
.box {
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    background: var(--color-surface);
    box-shadow: var(--shadow-sm);
    margin-bottom: 1.25rem;
    overflow: hidden;
}

.box-header {
    padding: .9rem 1.15rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: .5rem;
}

.box-header.with-border {
    border-bottom: 2px solid var(--color-border-light);
}

.box-title {
    font-weight: 700;
    font-size: .95rem;
    color: var(--color-text);
    margin: 0;
}

h3.box-title {
    font-size: .95rem;
}

.box-tools {
    display: flex;
    align-items: center;
    gap: .5rem;
}

.box-tools a {
    color: var(--color-primary);
    font-weight: 600;
    font-size: .875rem;
    text-decoration: none;
}

.box-tools a:hover {
    text-decoration: underline;
}

.box-body {
    padding: 1.15rem;
    overflow-x: auto;
}

.box-footer {
    padding: .85rem 1.15rem;
    border-top: 1px solid var(--color-border-light);
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: .5rem;
    background: var(--color-body-bg);
}

/* Callout */
.callout {
    padding: 1rem 1.15rem;
    border-left: 4px solid var(--color-primary);
    background: var(--color-primary-light);
    border-radius: var(--radius-sm);
    margin-bottom: 1rem;
}

.callout h4 {
    font-size: .95rem;
    font-weight: 700;
    margin: 0 0 .35rem;
    color: var(--color-text);
}

.callout p {
    font-size: .875rem;
    color: var(--color-text-muted);
    margin: 0;
}

.callout-info {
    border-left-color: var(--color-primary);
    background: var(--color-primary-light);
}

.callout-warning {
    border-left-color: var(--color-warning);
    background: var(--color-warning-light);
}

.callout-danger {
    border-left-color: var(--color-danger);
    background: var(--color-danger-light);
}

.callout-success {
    border-left-color: var(--color-success);
    background: var(--color-success-light);
}

/* BS3 Utility Compat */
.pull-right {
    float: right !important;
}

.pull-left {
    float: left !important;
}

.text-center {
    text-align: center;
}

/* BS3 Button Compat */
.btn-default {
    background: var(--color-surface);
    border: 1.5px solid var(--color-border);
    color: var(--color-text);
}

.btn-default:hover {
    background: var(--color-body-bg);
    color: var(--color-text);
    border-color: #cbd5e1;
}

.btn-xs {
    padding: .2rem .55rem;
    font-size: .75rem;
    border-radius: 6px;
}

.btn-sm {
    padding: .35rem .7rem;
    font-size: .8rem;
}

.btn-info {
    background: linear-gradient(135deg, #0ea5e9, #0284c7);
    color: #fff;
}

.btn-info:hover {
    background: linear-gradient(135deg, #0284c7, #0369a1);
    color: #fff;
    box-shadow: 0 2px 8px rgba(14, 165, 233, .3);
}

.btn-flat {
    border-radius: 0;
}

/* BS3 Form Compat */
.form-group {
    margin-bottom: 1rem;
}

.form-group label {
    font-weight: 600;
    font-size: .85rem;
    margin-bottom: .35rem;
    display: block;
    color: var(--color-text-secondary);
}

.control-label {
    font-weight: 600;
    font-size: .85rem;
    padding-top: .4rem;
}

.input-sm {
    padding: .35rem .65rem;
    font-size: .85rem;
}

.form-horizontal .form-group {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    margin-bottom: 1rem;
    margin-right: -.5rem;
    margin-left: -.5rem;
}

.form-horizontal .form-group>* {
    padding-right: .5rem;
    padding-left: .5rem;
    flex-shrink: 0;
}

.form-horizontal .control-label {
    text-align: right;
    padding-top: .5rem;
    margin-bottom: 0;
}

/* BS3 Label Compat */
.label {
    display: inline-block;
    padding: .25em .6em;
    font-size: .73rem;
    font-weight: 600;
    border-radius: 6px;
    color: #fff;
    letter-spacing: .02em;
}

.label-primary {
    background-color: var(--color-primary);
}

.label-success {
    background-color: var(--color-success);
}

.label-warning {
    background-color: var(--color-warning);
}

.label-danger {
    background-color: var(--color-danger);
}

.label-info {
    background-color: #0ea5e9;
    color: #fff;
}

.label-default {
    background-color: #94a3b8;
}

/* BS3 Table Compat */
.table-bordered {
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    overflow: hidden;
}

.table-bordered th,
.table-bordered td {
    border: 1px solid var(--color-border-light) !important;
}

.table-hover>tbody>tr:hover>td {
    background-color: rgba(79, 70, 229, .04);
}

.table-striped>tbody>tr:nth-of-type(odd)>td {
    background-color: rgba(79, 70, 229, .02);
}

/* DataTables override */
.dataTables_wrapper .dataTables_length select {
    padding: .35rem 1.8rem .35rem .55rem;
    border: 1.5px solid var(--color-border);
    border-radius: var(--radius-sm);
    font-size: .85rem;
    background-color: var(--color-surface);
}

.dataTables_wrapper .dataTables_filter input {
    border: 1.5px solid var(--color-border);
    border-radius: var(--radius-sm);
    padding: .4rem .7rem;
    font-size: .85rem;
    transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.dataTables_wrapper .dataTables_filter input:focus {
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(79, 70, 229, .12);
    outline: none;
}

.dataTables_wrapper .dataTables_paginate .paginate_button {
    padding: .35rem .7rem;
    border-radius: var(--radius-sm) !important;
    font-size: .82rem;
    font-weight: 600;
}

.dataTables_wrapper .dataTables_info {
    font-size: .8rem;
    color: var(--color-text-muted);
}

/* Progress bar Compat */
.progress {
    height: 22px;
    border-radius: var(--radius-sm);
    background: var(--color-body-bg);
    overflow: hidden;
}

.progress-bar {
    background: linear-gradient(90deg, var(--color-primary), #818cf8);
    font-size: .75rem;
    line-height: 22px;
    color: #fff;
    text-align: center;
    transition: width .5s ease;
}

/* Nav Tabs Compat */
.nav-tabs>li {
    list-style: none;
}

.nav-tabs>li>a {
    display: block;
    padding: .55rem 1.1rem;
    text-decoration: none;
    color: var(--color-text-muted);
    border: 1.5px solid transparent;
    border-radius: var(--radius-sm) var(--radius-sm) 0 0;
    font-size: .875rem;
    font-weight: 500;
}

.nav-tabs>li.active>a,
.nav-tabs>li>a.active {
    color: var(--color-primary);
    border-color: var(--color-border) var(--color-border) #fff;
    background: var(--color-surface);
    font-weight: 700;
}

.tab-content>.tab-pane {
    display: none;
}

.tab-content>.tab-pane.active {
    display: block;
}

/* Select2 Fix */
.select2-container--default .select2-selection--single {
    border: 1.5px solid var(--color-border);
    border-radius: var(--radius-sm);
    height: 38px;
}

.select2-container--default .select2-selection--single .select2-selection__rendered {
    line-height: 36px;
    font-size: .875rem;
}

/* Fix for .close inside modals (BS3 to BS5) */
button.close {
    background: none;
    border: none;
    font-size: 1.4rem;
    font-weight: 700;
    line-height: 1;
    color: #000;
    opacity: .5;
    cursor: pointer;
    padding: 0;
}

button.close:hover {
    opacity: .75;
}

/* Misc Admin Compat */
.margin {
    margin: 5px;
}

.info-box {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.1rem;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    margin-bottom: 1rem;
    box-shadow: var(--shadow-xs);
}

.info-box-icon {
    width: 55px;
    height: 55px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-md);
    font-size: 1.5rem;
    color: #fff;
}

.info-box-content {
    flex: 1;
}

.info-box-text {
    font-size: .78rem;
    color: var(--color-text-muted);
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: .03em;
}

.info-box-number {
    font-size: 1.3rem;
    font-weight: 800;
}

.bg-aqua {
    background-color: #0ea5e9 !important;
}

.bg-green {
    background-color: var(--color-success) !important;
}

.bg-yellow {
    background-color: var(--color-warning) !important;
}

.bg-red {
    background-color: var(--color-danger) !important;
}

.bg-blue {
    background-color: var(--color-primary) !important;
}

.bg-light-blue {
    background-color: #0ea5e9 !important;
}

/* BS3 to BS5 Grid */
.row {
    display: flex;
    flex-wrap: wrap;
    margin-right: -.5rem;
    margin-left: -.5rem;
}

.row>* {
    flex-shrink: 0;
    padding-right: .5rem;
    padding-left: .5rem;
}

.col-xs-1 {
    flex: 0 0 auto;
    width: 8.333333%;
}

.col-xs-2 {
    flex: 0 0 auto;
    width: 16.666667%;
}

.col-xs-3 {
    flex: 0 0 auto;
    width: 25%;
}

.col-xs-4 {
    flex: 0 0 auto;
    width: 33.333333%;
}

.col-xs-5 {
    flex: 0 0 auto;
    width: 41.666667%;
}

.col-xs-6 {
    flex: 0 0 auto;
    width: 50%;
}

.col-xs-7 {
    flex: 0 0 auto;
    width: 58.333333%;
}

.col-xs-8 {
    flex: 0 0 auto;
    width: 66.666667%;
}

.col-xs-9 {
    flex: 0 0 auto;
    width: 75%;
}

.col-xs-10 {
    flex: 0 0 auto;
    width: 83.333333%;
}

.col-xs-11 {
    flex: 0 0 auto;
    width: 91.666667%;
}

.col-xs-12 {
    flex: 0 0 auto;
    width: 100%;
}

.hide {
    display: none !important;
}

.row-fluid {
    display: flex;
    flex-wrap: wrap;
    width: 100%;
}

.row-fluid>* {
    flex-shrink: 0;
}

.help-block {
    display: block;
    margin-top: .35rem;
    font-size: .8rem;
    color: var(--color-text-muted);
}

.radio,
.checkbox {
    margin-bottom: .5rem;
}

.radio label,
.checkbox label {
    display: flex;
    align-items: flex-start;
    gap: .5rem;
    cursor: pointer;
    font-weight: 400;
}

.radio input[type="radio"],
.checkbox input[type="checkbox"] {
    margin-top: .25rem;
    flex-shrink: 0;
    accent-color: var(--color-primary);
}

.btn-app {
    display: inline-block;
    padding: .5rem 1rem;
    font-size: .85rem;
    border: 1.5px solid var(--color-border);
    border-radius: var(--radius-sm);
    background: var(--color-surface);
    color: var(--color-text);
    cursor: pointer;
    text-align: center;
}

.btn-app:hover {
    background: var(--color-body-bg);
}

/* Small Box (AdminLTE metric widget) */
.small-box {
    border-radius: var(--radius-md);
    padding: 1.25rem 1.5rem;
    color: #fff;
    position: relative;
    overflow: hidden;
    margin-bottom: 1.25rem;
    box-shadow: var(--shadow-md);
}

.small-box .inner h3 {
    font-size: 2.2rem;
    font-weight: 800;
    margin: 0 0 .25rem;
    color: #fff;
    letter-spacing: -.02em;
}

.small-box .inner p {
    font-size: .9rem;
    font-weight: 500;
    margin: 0;
    opacity: .9;
}

.small-box .icon {
    position: absolute;
    right: 1rem;
    top: 50%;
    transform: translateY(-50%);
    font-size: 3.5rem;
    opacity: .2;
}

.small-box .small-box-footer {
    display: block;
    padding: .5rem 1rem;
    background: rgba(0, 0, 0, .1);
    color: rgba(255, 255, 255, .85);
    text-decoration: none;
    font-size: .82rem;
    margin: 1rem -1.5rem -1.25rem;
    text-align: center;
}

/* Input group BS3 compat */
.input-group-btn {
    display: flex;
}

.input-group-btn .btn {
    border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
    border: 1.5px solid var(--color-border);
    border-left: none;
}

/* Responsive table wrapper for mobile */
@media (max-width: 767.98px) {
    .box-body .table {
        display: block;
        width: 100%;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .box-body {
        padding: .75rem;
    }

    .box-header {
        padding: .75rem 1rem;
    }

    .box-footer {
        padding: .65rem 1rem;
    }

    .content-header h1 {
        font-size: 1.15rem;
    }

    .content-header h1 small {
        font-size: .75rem;
    }

    table img {
        max-width: 100px !important;
    }
}

/* Accordion */
.accordion-item {
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm) !important;
    overflow: hidden;
}

.accordion-button {
    font-weight: 600;
    font-size: .9rem;
    padding: .85rem 1.15rem;
}

.accordion-button:not(.collapsed) {
    background: var(--color-primary-light);
    color: var(--color-primary);
}

.accordion-button:focus {
    box-shadow: 0 0 0 3px rgba(79, 70, 229, .12);
}

.accordion-body {
    font-size: .875rem;
}

/* ============================================
   PROKTOR DASHBOARD
   ============================================ */

/* Clock */
.proktor-clock {
    display: flex;
    align-items: center;
    gap: .4rem;
    background: var(--color-primary-light);
    color: var(--color-primary);
    padding: .4rem .85rem;
    border-radius: var(--radius-sm);
    font-weight: 700;
    font-size: .9rem;
    font-variant-numeric: tabular-nums;
}

/* Clickable stat cards */
.proktor-filter-card {
    transition: box-shadow .2s, transform .15s;
    position: relative;
}

.proktor-filter-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, .1);
}

.proktor-filter-card.active {
    box-shadow: 0 0 0 3px var(--color-primary), 0 4px 16px rgba(79, 70, 229, .15);
}

/* Progress bar */
.proktor-progress-wrap {
    width: 100%;
    height: 8px;
    background: var(--color-border-light);
    border-radius: 999px;
    overflow: hidden;
    margin-bottom: 3px;
}

.proktor-progress-bar {
    height: 100%;
    border-radius: 999px;
    transition: width 0.5s ease;
    min-width: 2px;
}

.proktor-progress-text {
    font-size: .72rem;
    color: var(--color-text-muted);
    font-weight: 600;
    font-variant-numeric: tabular-nums;
}

/* Status badges */
.proktor-badge {
    display: inline-flex;
    align-items: center;
    gap: .3rem;
    padding: .3em .7em;
    border-radius: 999px;
    font-size: .72rem;
    font-weight: 600;
    white-space: nowrap;
}

.proktor-badge-active {
    background: var(--color-success-light);
    color: var(--color-success);
}

.proktor-badge-active i {
    font-size: .5rem;
    animation: proktorPulse 1.5s ease-in-out infinite;
}

.proktor-badge-done {
    background: var(--color-warning-light);
    color: var(--color-warning);
}

.proktor-badge-warning {
    background: var(--color-danger-light);
    color: var(--color-danger);
    animation: proktorPulse 1s ease-in-out infinite;
}

.proktor-badge-idle {
    background: var(--color-border-light);
    color: var(--color-text-muted);
}

@keyframes proktorPulse {

    0%,
    100% {
        opacity: 1
    }

    50% {
        opacity: .5
    }
}

/* Timer danger */
.proktor-timer-danger {
    color: var(--color-danger);
    font-weight: 700;
    animation: proktorPulse 1s ease-in-out infinite;
}

/* Live indicator */
.proktor-live-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--color-success);
    display: inline-block;
    animation: proktorPulse 1.5s ease-in-out infinite;
}

.proktor-live-dot.pulse {
    box-shadow: 0 0 0 4px rgba(5, 150, 105, .25);
}

/* Action buttons */
.proktor-actions {
    display: flex;
    gap: 4px;
    justify-content: center;
}

.proktor-actions .btn {
    padding: .25rem .45rem;
    font-size: .8rem;
}

/* Toolbar overrides for proktor table */
.proktor-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: .85rem 1.25rem;
    gap: 1rem;
    flex-wrap: wrap;
}

.proktor-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: .85rem 1.25rem;
    border-top: 1px solid var(--color-border-light);
    font-size: .8rem;
    gap: 1rem;
    flex-wrap: wrap;
}

/* Responsive */
@media (max-width: 767.98px) {
    .proktor-header h4 {
        font-size: 1.1rem;
    }

    .proktor-toolbar {
        flex-direction: column;
        align-items: stretch;
    }

    .proktor-footer {
        flex-direction: column;
        align-items: center;
    }
}

/* DataTables Responsive - Fix "+" icon alignment with row number */
table.dataTable.dtr-inline.collapsed > tbody > tr > td:first-child,
table.dataTable.dtr-inline.collapsed > tbody > tr > th:first-child {
    padding-left: 30px;
    position: relative;
    vertical-align: middle;
}

table.dataTable.dtr-inline.collapsed > tbody > tr > td:first-child:before,
table.dataTable.dtr-inline.collapsed > tbody > tr > th:first-child:before {
    top: 50%;
    transform: translateY(-50%);
    left: 4px;
    height: 18px;
    width: 18px;
    display: block;
    position: absolute;
    color: white;
    border: 2px solid white;
    border-radius: 50%;
    text-align: center;
    line-height: 14px;
    box-shadow: 0 0 3px rgba(0, 0, 0, .2);
    box-sizing: content-box;
    content: '+';
    background-color: var(--color-success);
    font-size: .85rem;
    font-weight: 700;
}

table.dataTable.dtr-inline.collapsed > tbody > tr.parent > td:first-child:before,
table.dataTable.dtr-inline.collapsed > tbody > tr.parent > th:first-child:before {
    content: '-';
    background-color: var(--color-danger);
}