/* eMathrix LMS 2026 - Enhanced Vibrant Stylesheet
   Color Scheme: Vibrant Purple Gradients with Modern Design
*/

:root {
    /* Primary Purple Gradient (Vibrant) */
    --primary-purple: #8B5CF6;
    --primary-purple-dark: #6D28D9;
    --primary-purple-light: #A78BFA;
    --primary-purple-hover: #7C3AED;

    /* Legacy blue variables (mapped to purple for compatibility) */
    --primary-blue: #8B5CF6;
    --primary-blue-dark: #6D28D9;
    --primary-blue-light: #A78BFA;
    --primary-blue-hover: #7C3AED;

    /* Whites and Neutrals (70%) */
    --white: #FFFFFF;
    --off-white: #F8FAFC;
    --light-gray: #F1F5F9;
    --border-gray: #E2E8F0;
    --text-gray: #64748B;

    /* Vibrant Accent Colors */
    --success-green: #10B981;
    --warning-orange: #F59E0B;
    --danger-red: #EF4444;
    --info-purple: #8B5CF6;
    --accent-teal: #14B8A6;
    --accent-gold: #ffd43b;
    --accent-pink: #EC4899;

    /* Text Colors */
    --text-dark: #1E293B;
    --text-medium: #475569;
    --text-light: #94A3B8;

    /* Shadows - More Vibrant */
    --shadow-sm: 0 1px 2px rgba(139, 92, 246, 0.1);
    --shadow-md: 0 4px 12px rgba(139, 92, 246, 0.15);
    --shadow-lg: 0 10px 25px rgba(139, 92, 246, 0.2);
    --shadow-glow: 0 0 20px rgba(139, 92, 246, 0.3);

    /* Card theme colors - More Vibrant */
    --card-blue: linear-gradient(135deg, #E0E7FF 0%, #C7D2FE 100%);
    --card-green: linear-gradient(135deg, #D1FAE5 0%, #A7F3D0 100%);
    --card-purple: linear-gradient(135deg, #EDE9FE 0%, #DDD6FE 100%);
    --card-orange: linear-gradient(135deg, #FEF3C7 0%, #FDE68A 100%);
    --card-pink: linear-gradient(135deg, #FCE7F3 0%, #FBCFE8 100%);
    --card-teal: linear-gradient(135deg, #CCFBF1 0%, #99F6E4 100%);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-color: var(--off-white);
    color: var(--text-dark);
    line-height: 1.6;
    min-height: 100vh;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 2rem;
    position: relative;
    z-index: 1;
}

/* Ensure main content is always interactive */
main {
    position: relative;
    z-index: 1;
}

/* Reset any accidental overlays */
body > *:not(.modal):not(nav) {
    pointer-events: auto;
}

/* ============== NAVBAR ============== */

.navbar {
    background: linear-gradient(135deg, #8B5CF6 0%, #6D28D9 50%, #4C1D95 100%);
    padding: 0.75rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 4px 20px rgba(139, 92, 246, 0.4);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.nav-brand a {
    color: var(--white);
    text-decoration: none;
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: -0.5px;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.nav-brand .brand-icon {
    font-size: 1.75rem;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.nav-links a {
    color: var(--white);
    text-decoration: none;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    font-weight: 500;
    transition: all 0.2s ease;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.nav-links a:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

.nav-links a.active {
    background: rgba(255, 255, 255, 0.25);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.nav-links .nav-game-btn {
    background: linear-gradient(135deg, #ffd43b, #F59E0B);
    color: #1a1a2e !important;
    border-radius: 20px;
    font-weight: 600;
    box-shadow: 0 4px 15px rgba(255, 212, 59, 0.4);
}

.nav-links .nav-game-btn:hover {
    background: linear-gradient(135deg, #FFE066, #ffd43b);
    transform: translateY(-2px) scale(1.02);
}

.nav-links .nav-game-btn.active {
    background: linear-gradient(135deg, #FFE066, #ffd43b);
    box-shadow: 0 4px 20px rgba(255, 212, 59, 0.5);
}

.nav-user {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: var(--white);
}

.nav-user img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid rgba(255, 255, 255, 0.4);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.nav-user span {
    font-size: 0.9rem;
}

.btn-logout {
    background: var(--danger-red) !important;
    color: var(--white) !important;
}

.btn-logout:hover {
    background: #DC2626 !important;
}

/* ============== NAV RIGHT SECTION ============== */

.nav-right {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    position: relative;
}

.nav-icon-btn {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
    font-size: 1.1rem;
}

.nav-icon-btn:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: scale(1.05);
}

.nav-icon-btn .badge {
    position: absolute;
    top: -2px;
    right: -2px;
    background: var(--danger-red);
    color: white;
    font-size: 0.7rem;
    font-weight: 700;
    min-width: 18px;
    height: 18px;
    border-radius: 9px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 4px;
    border: 2px solid #6D28D9;
}

.nav-user-dropdown {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 6px 12px 6px 6px;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.2s ease;
    color: white;
    margin-left: 0.5rem;
}

.nav-user-dropdown:hover {
    background: rgba(255, 255, 255, 0.25);
}

.nav-user-dropdown img {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid rgba(255, 255, 255, 0.5);
}

.nav-user-dropdown span {
    font-size: 0.9rem;
    font-weight: 500;
    max-width: 120px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.nav-user-dropdown i {
    font-size: 0.75rem;
    transition: transform 0.2s ease;
}

/* ============== DROPDOWN MENUS ============== */

.dropdown-menu {
    position: absolute;
    top: 100%;
    right: 0;
    margin-top: 10px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    min-width: 320px;
    max-height: 400px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.2s ease;
    z-index: 1001;
    overflow: hidden;
}

.dropdown-menu.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    background: linear-gradient(135deg, #8B5CF6, #6D28D9);
    color: white;
    font-weight: 600;
}

.dropdown-header a {
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.8rem;
    text-decoration: none;
}

.dropdown-header a:hover {
    color: white;
    text-decoration: underline;
}

.dropdown-content {
    max-height: 320px;
    overflow-y: auto;
}

.dropdown-user-info {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 15px 20px;
    background: #F9FAFB;
}

.dropdown-user-info img {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid #8B5CF6;
}

.dropdown-user-info strong {
    display: block;
    color: #1F2937;
    font-size: 0.95rem;
}

.dropdown-user-info small {
    color: #6B7280;
    font-size: 0.8rem;
}

.dropdown-divider {
    height: 1px;
    background: #E5E7EB;
    margin: 0;
}

.dropdown-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 20px;
    color: #374151;
    text-decoration: none;
    transition: all 0.2s ease;
}

.dropdown-item:hover {
    background: #F5F3FF;
    color: #6D28D9;
}

.dropdown-item i {
    width: 20px;
    text-align: center;
    font-size: 1rem;
}

.dropdown-item.logout {
    color: var(--danger-red);
}

.dropdown-item.logout:hover {
    background: #FEF2F2;
    color: #DC2626;
}

/* Notification & Message Items */
.notification-item, .message-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 12px 15px;
    text-decoration: none;
    color: #374151;
    border-bottom: 1px solid #F3F4F6;
    transition: all 0.2s ease;
}

.notification-item:hover, .message-item:hover {
    background: #F5F3FF;
}

.notification-item.unread, .message-item.unread {
    background: #EDE9FE;
}

.notif-icon {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    background: #8B5CF6;
    color: white;
}

.notif-icon.message { background: #0EA5E9; }
.notif-icon.grade { background: #10B981; }
.notif-icon.alert { background: #F59E0B; }
.notif-icon.announcement { background: #EC4899; }

.notif-content p, .message-content p {
    margin: 0;
    font-size: 0.9rem;
    color: #374151;
}

.notif-content small, .message-content small {
    color: #9CA3AF;
    font-size: 0.75rem;
}

.message-item img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

.message-content {
    flex: 1;
    min-width: 0;
}

.message-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2px;
}

.message-header strong {
    font-size: 0.9rem;
    color: #1F2937;
}

.message-content p {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.empty-state {
    text-align: center;
    padding: 40px 20px;
    color: #9CA3AF;
}

.empty-state i {
    font-size: 2.5rem;
    margin-bottom: 10px;
    display: block;
}

.empty-state p {
    margin: 0;
}

/* User dropdown specific */
.user-dropdown {
    min-width: 240px;
}

@media (max-width: 768px) {
    .nav-user-dropdown span {
        display: none;
    }

    .nav-user-dropdown {
        padding: 6px;
        border-radius: 50%;
    }

    .nav-user-dropdown i {
        display: none;
    }

    .dropdown-menu {
        min-width: 280px;
        right: -10px;
    }
}

/* ============== ALERTS ============== */

.alert {
    padding: 1rem 1.25rem;
    border-radius: 8px;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    animation: slideDown 0.3s ease;
    position: relative;
    z-index: 1;
}

@keyframes slideDown {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

.alert-success {
    background: #D1FAE5;
    color: #065F46;
    border: 1px solid #A7F3D0;
}

.alert-error, .alert-danger {
    background: #FEE2E2;
    color: #991B1B;
    border: 1px solid #FECACA;
}

.alert-warning {
    background: #FEF3C7;
    color: #92400E;
    border: 1px solid #FDE68A;
}

.alert-info {
    background: #DBEAFE;
    color: #1E40AF;
    border: 1px solid #BFDBFE;
}

/* ============== LOGIN PAGE ============== */

.login-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    background: linear-gradient(135deg, #8B5CF6 0%, #6D28D9 50%, #4C1D95 100%);
    padding: 2rem;
    position: relative;
}

.login-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    pointer-events: none;
}

.login-box {
    background: var(--white);
    padding: 2.5rem;
    border-radius: 20px;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.35);
    width: 100%;
    max-width: 440px;
    position: relative;
    z-index: 1;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.login-box h1 {
    text-align: center;
    background: linear-gradient(135deg, #8B5CF6, #6D28D9);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 0.5rem;
    font-size: 2rem;
    font-weight: 700;
}

.login-box .subtitle {
    text-align: center;
    color: var(--text-gray);
    margin-bottom: 2rem;
    font-size: 0.9rem;
}

/* ============== FORMS ============== */

.form-group {
    margin-bottom: 1.25rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: var(--text-medium);
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid var(--border-gray);
    border-radius: 8px;
    font-size: 0.95rem;
    background: var(--white);
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #8B5CF6;
    box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.15);
}

textarea.form-control {
    min-height: 120px;
    resize: vertical;
}

/* ============== BUTTONS ============== */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.625rem 1.25rem;
    border: none;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.2s ease;
}

.btn:hover {
    transform: translateY(-1px);
}

.btn-primary {
    background: linear-gradient(135deg, #8B5CF6, #6D28D9);
    color: var(--white);
    box-shadow: 0 4px 15px rgba(139, 92, 246, 0.4);
}

.btn-primary:hover {
    background: linear-gradient(135deg, #7C3AED, #5B21B6);
    box-shadow: 0 6px 20px rgba(139, 92, 246, 0.5);
}

.btn-secondary {
    background: var(--light-gray);
    color: var(--text-medium);
    border: 1px solid var(--border-gray);
}

.btn-secondary:hover {
    background: var(--border-gray);
}

.btn-success {
    background: var(--success-green);
    color: var(--white);
}

.btn-success:hover {
    background: #059669;
}

.btn-danger {
    background: var(--danger-red);
    color: var(--white);
}

.btn-danger:hover {
    background: #DC2626;
}

.btn-warning {
    background: var(--warning-orange);
    color: var(--white);
}

.btn-warning:hover {
    background: #D97706;
}

.btn-sm {
    padding: 0.375rem 0.75rem;
    font-size: 0.8rem;
}

.btn-lg {
    padding: 0.875rem 1.75rem;
    font-size: 1rem;
}

.btn-full {
    width: 100%;
}

/* Button Color Variants */
.btn-emerald { background-color: #10B981; }
.btn-emerald:hover { background-color: #059669; }

.btn-violet { background-color: #8B5CF6; }
.btn-violet:hover { background-color: #7C3AED; }

.btn-amber { background-color: #F59E0B; }
.btn-amber:hover { background-color: #D97706; }

.btn-rose { background-color: #F43F5E; }
.btn-rose:hover { background-color: #E11D48; }

.btn-sky { background-color: #0EA5E9; }
.btn-sky:hover { background-color: #0284C7; }

.btn-teal { background-color: #14B8A6; }
.btn-teal:hover { background-color: #0D9488; }

.btn-indigo { background-color: #6366F1; }
.btn-indigo:hover { background-color: #4F46E5; }

.btn-orange { background-color: #F97316; }
.btn-orange:hover { background-color: #EA580C; }

.btn-cyan { background-color: #06B6D4; }
.btn-cyan:hover { background-color: #0891B2; }

.btn-lime { background-color: #84CC16; }
.btn-lime:hover { background-color: #65A30D; }

/* ============== STATS CARDS ============== */

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.stat-card {
    background: var(--white);
    border-radius: 12px;
    padding: 1.5rem;
    border: 1px solid var(--border-gray);
    text-align: center;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    animation: fadeIn 0.3s ease;
}

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

.stat-card.blue { background: var(--card-blue); border-color: #7DD3FC; }
.stat-card.green { background: var(--card-green); border-color: #6EE7B7; }
.stat-card.purple { background: var(--card-purple); border-color: #C4B5FD; }
.stat-card.orange { background: var(--card-orange); border-color: #FCD34D; }
.stat-card.teal { background: var(--card-teal); border-color: #5EEAD4; }

.stat-number {
    font-size: 2.5rem;
    font-weight: 700;
    background: linear-gradient(135deg, #8B5CF6, #6D28D9);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1;
}

.stat-card.blue .stat-number { color: #0284C7; }
.stat-card.green .stat-number { color: #059669; }
.stat-card.purple .stat-number { color: #7C3AED; }
.stat-card.orange .stat-number { color: #D97706; }
.stat-card.teal .stat-number { color: #0D9488; }

.stat-label {
    color: var(--text-medium);
    font-size: 0.9rem;
    margin-top: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

/* ============== CARDS ============== */

.card {
    background: var(--white);
    border-radius: 12px;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-gray);
    overflow: hidden;
    margin-bottom: 1.5rem;
    animation: fadeIn 0.3s ease;
}

.card-header {
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid var(--border-gray);
    background: var(--light-gray);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.card-header h3, .card-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-dark);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.card-body {
    padding: 1.5rem;
}

/* ============== SUBJECT/CLASS CARDS ============== */

.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.subject-card {
    background: var(--white);
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--border-gray);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    animation: fadeIn 0.3s ease;
}

.subject-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
}

.subject-card-header {
    padding: 1.25rem;
}

.subject-card-header.blue { background: var(--card-blue); }
.subject-card-header.green { background: var(--card-green); }
.subject-card-header.purple { background: var(--card-purple); }
.subject-card-header.orange { background: var(--card-orange); }
.subject-card-header.pink { background: var(--card-pink); }
.subject-card-header.teal { background: var(--card-teal); }

.schedule-badge {
    display: inline-block;
    background: linear-gradient(135deg, #8B5CF6, #6D28D9);
    color: var(--white);
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
    box-shadow: 0 2px 8px rgba(139, 92, 246, 0.3);
}

.subject-card h3 {
    color: var(--text-dark);
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.subject-card .section-info {
    color: var(--text-medium);
    font-size: 0.85rem;
}

.subject-card-body {
    padding: 1rem 1.25rem;
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.subject-card-body .btn {
    flex: 1;
    min-width: 80px;
}

/* ============== PAGE HEADER ============== */

.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.page-header h1 {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--text-dark);
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.page-header p {
    color: var(--text-gray);
    margin-top: 0.25rem;
}

/* ============== TABLES ============== */

.table-container {
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
}

th, td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid var(--border-gray);
}

th {
    background: var(--light-gray);
    font-weight: 600;
    color: var(--text-medium);
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

tr:hover {
    background: var(--off-white);
}

.student-cell {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.student-cell img {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--border-gray);
}

/* ============== SESSION LIST ============== */

.session-list {
    list-style: none;
}

.session-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.25rem;
    background: var(--white);
    border: 1px solid var(--border-gray);
    border-radius: 10px;
    margin-bottom: 0.75rem;
    transition: all 0.2s ease;
}

.session-item:hover {
    border-color: #A78BFA;
    box-shadow: 0 4px 15px rgba(139, 92, 246, 0.15);
}

.session-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.session-number {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #8B5CF6, #6D28D9);
    color: var(--white);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.1rem;
    box-shadow: 0 4px 12px rgba(139, 92, 246, 0.3);
}

.session-title {
    font-weight: 600;
    color: var(--text-dark);
}

.session-meta {
    font-size: 0.85rem;
    color: var(--text-gray);
}

.session-actions {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

/* ============== VISIBILITY TOGGLE ============== */

.visibility-toggle {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.toggle-switch {
    position: relative;
    width: 44px;
    height: 24px;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--border-gray);
    border-radius: 24px;
    transition: 0.3s;
}

.toggle-slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background: var(--white);
    border-radius: 50%;
    transition: 0.3s;
}

input:checked + .toggle-slider {
    background: var(--success-green);
}

input:checked + .toggle-slider:before {
    transform: translateX(20px);
}

.toggle-label {
    font-size: 0.85rem;
    color: var(--text-gray);
}

/* ============== BADGES ============== */

.badge {
    display: inline-block;
    padding: 0.25rem 0.625rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
}

.badge-visible { background: #D1FAE5; color: #065F46; }
.badge-hidden { background: #FEE2E2; color: #991B1B; }
.badge-pending { background: #FEF3C7; color: #92400E; }
.badge-active { background: #DBEAFE; color: #1E40AF; }

/* ============== CAMERA & PHOTO ============== */

.camera-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
    padding: 2rem;
    border: 2px dashed #8B5CF6;
    border-radius: 16px;
    background: linear-gradient(135deg, #EDE9FE 0%, #DDD6FE 100%);
}

.camera-preview {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    background: #000;
    object-fit: cover;
    border: 4px solid #8B5CF6;
    box-shadow: 0 8px 25px rgba(139, 92, 246, 0.3);
}

.camera-controls {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
    justify-content: center;
}

.photo-upload-label {
    color: var(--primary-blue);
    cursor: pointer;
    font-weight: 600;
    text-decoration: underline;
}

/* ============== PROFILE ============== */

.profile-card {
    display: grid;
    grid-template-columns: 250px 1fr;
    gap: 2rem;
}

.profile-photo-section {
    text-align: center;
}

.profile-photo-large {
    width: 180px;
    height: 180px;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid #8B5CF6;
    margin-bottom: 1rem;
    box-shadow: 0 8px 25px rgba(139, 92, 246, 0.3);
}

.profile-name {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-dark);
}

.profile-role {
    color: var(--text-gray);
    font-size: 0.9rem;
    text-transform: capitalize;
}

/* ============== QUIZ/EXAM ============== */

.question-card {
    background: var(--light-gray);
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 1.25rem;
    border: 1px solid var(--border-gray);
}

.question-card h4 {
    margin-bottom: 1rem;
    color: var(--text-dark);
}

.options-list {
    list-style: none;
}

.options-list li {
    padding: 0.875rem 1rem;
    margin-bottom: 0.5rem;
    background: var(--white);
    border: 1px solid var(--border-gray);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.options-list li:hover {
    border-color: #8B5CF6;
    background: #F5F3FF;
}

.options-list input[type="radio"],
.options-list input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: #8B5CF6;
}

/* ============== GRADES ============== */

.grade-display {
    font-size: 1.5rem;
    font-weight: bold;
    background: linear-gradient(135deg, #8B5CF6, #6D28D9);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.grade-a, .grade-good { color: var(--success-green); }
.grade-b { color: #3B82F6; }
.grade-c, .grade-average { color: var(--warning-orange); }
.grade-d, .grade-poor { color: var(--danger-red); }

.grade-input {
    width: 80px;
    padding: 0.5rem;
    text-align: center;
    border: 1px solid var(--border-gray);
    border-radius: 6px;
}

/* ============== MODALS ============== */

.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: -1;
    pointer-events: none;
    visibility: hidden;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.modal.active {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    z-index: 2000;
    pointer-events: auto;
    visibility: visible;
    opacity: 1;
    overflow-y: auto;
    padding: 20px;
}

.modal-content {
    background: var(--white);
    width: 100%;
    max-width: 500px;
    margin: 50px 0;
    padding: 2rem;
    border-radius: 16px;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.25);
    position: relative;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.modal-close {
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-gray);
    transition: color 0.2s;
}

.modal-close:hover {
    color: var(--danger-red);
}

/* ============== UPLOAD SECTION ============== */

.upload-section {
    background: var(--light-gray);
    border: 2px dashed var(--border-gray);
    border-radius: 12px;
    padding: 2rem;
    text-align: center;
    margin-top: 1.5rem;
    transition: all 0.2s ease;
}

.upload-section:hover {
    border-color: #8B5CF6;
    background: #F5F3FF;
}

.upload-section h3 {
    margin-bottom: 1rem;
    color: var(--text-dark);
}

/* ============== EMPTY STATE ============== */

.empty-state {
    text-align: center;
    padding: 4rem 2rem;
}

.empty-state i {
    font-size: 4rem;
    color: var(--text-light);
    margin-bottom: 1rem;
}

.empty-state p {
    color: var(--text-gray);
    margin-bottom: 1.5rem;
}

/* ============== ANIMATIONS ============== */

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

.camera-preview.recording {
    animation: pulse 1.5s infinite;
}

/* ============== UTILITY CLASSES ============== */

.text-center { text-align: center; }
.text-right { text-align: right; }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-20 { margin-top: 20px; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-20 { margin-bottom: 20px; }
.flex { display: flex; }
.flex-between { display: flex; justify-content: space-between; align-items: center; }
.gap-1 { gap: 0.5rem; }
.gap-2 { gap: 1rem; }
.gap-10 { gap: 10px; }
.justify-between { justify-content: space-between; }
.items-center { align-items: center; }

/* ============== RESPONSIVE ============== */

@media (max-width: 768px) {
    .navbar {
        padding: 0.75rem 1rem;
        flex-wrap: wrap;
        gap: 1rem;
    }

    .nav-links {
        gap: 0.25rem;
        flex-wrap: wrap;
        width: 100%;
        justify-content: center;
    }

    .nav-links a {
        padding: 0.4rem 0.75rem;
        font-size: 0.8rem;
    }

    .container {
        padding: 1rem;
    }

    .stats-grid, .dashboard-grid {
        grid-template-columns: 1fr;
    }

    .profile-card {
        grid-template-columns: 1fr;
    }

    .session-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }

    .page-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .camera-preview {
        width: 180px;
        height: 180px;
    }

    .nav-user {
        display: none;
    }
}
