/* Main CSS - School Management System */
/* Professional Color Scheme - Default & Theme Support */
:root {
    /* Primary Brand Colors - Professional & Formal */
    --primary-blue: #1E3A8A;        /* Deep Professional Blue */
    --secondary-blue: #3B82F6;      /* Medium Blue */
    --accent-blue: #60A5FA;         /* Light Blue */
    
    --success-green: #059669;       /* Professional Green */
    --danger-red: #DC2626;          /* Professional Red */
    --warning-orange: #D97706;      /* Professional Orange */
    --info-blue: #0284C7;           /* Professional Info Blue */
    
    /* Light Mode (Default) - Clean & Professional with Ash/Light Grey Tones */
    --bg-primary: #E8EAED;          /* Light Ash Gray Background */
    --bg-secondary: #F5F5F5;        /* Light Grey */
    --bg-card: #F8F9FA;             /* Very Light Grey Card */
    --bg-hover: #E0E0E0;            /* Hover Light Grey */
    
    --text-primary: #000000;        /* Pure Black Text for Maximum Clarity */
    --text-secondary: #374151;      /* Dark Gray Text for Better Contrast */
    --text-tertiary: #6B7280;       /* Medium Gray Text */
    
    --border-color: #E5E7EB;        /* Light Border */
    --border-focus: #3B82F6;        /* Focus Border */
    
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px -1px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1);
    --shadow-hover: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
    
    /* Gradients */
    --gradient-primary: linear-gradient(135deg, #1E3A8A 0%, #3B82F6 100%);
    --gradient-success: linear-gradient(135deg, #059669 0%, #10B981 100%);
    --gradient-danger: linear-gradient(135deg, #DC2626 0%, #EF4444 100%);
}

[data-theme="dark"] {
    /* Dark Mode - Professional & Easy on Eyes */
    --bg-primary: #0F172A;          /* Deep Navy Background */
    --bg-secondary: #1E293B;        /* Slate Background */
    --bg-card: #1E293B;             /* Card Slate */
    --bg-hover: #334155;            /* Hover Slate */
    
    --text-primary: #F8FAFC;        /* Almost White Text */
    --text-secondary: #CBD5E1;      /* Light Gray Text */
    --text-tertiary: #94A3B8;       /* Medium Gray Text */
    
    --border-color: #334155;        /* Dark Border */
    --border-focus: #60A5FA;        /* Focus Light Blue */
    
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.3);
    --shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.4), 0 1px 2px -1px rgba(0, 0, 0, 0.4);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.4), 0 2px 4px -2px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.4), 0 4px 6px -4px rgba(0, 0, 0, 0.4);
    --shadow-hover: 0 20px 25px -5px rgba(0, 0, 0, 0.4), 0 8px 10px -6px rgba(0, 0, 0, 0.4);
    
    /* Gradients for Dark Mode */
    --gradient-primary: linear-gradient(135deg, #1E3A8A 0%, #2563EB 100%);
    --gradient-success: linear-gradient(135deg, #059669 0%, #059669 100%);
    --gradient-danger: linear-gradient(135deg, #DC2626 0%, #DC2626 100%);
}

/* Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    transition: background-color 0.3s ease, color 0.3s ease;
    margin: 0;
    padding: 0;
}

a {
    text-decoration: none;
    color: var(--primary-blue);
    transition: color 0.3s ease;
}

a:hover {
    color: var(--secondary-blue);
}

/* Theme Toggle Button */
.theme-toggle {
    position: fixed;
    top: 20px;
    right: 20px;
    width: 50px;
    height: 50px;
    background: var(--bg-card);
    border: 2px solid var(--border-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 1000;
    box-shadow: var(--shadow);
    transition: all 0.3s ease;
}

.theme-toggle:hover {
    transform: scale(1.1);
    box-shadow: var(--shadow-hover);
    background: var(--bg-hover);
}

.theme-toggle i {
    font-size: 20px;
    color: var(--warning-orange);
    transition: color 0.3s ease;
}

/* Login Page Styles */
.login-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--bg-primary) 0%, var(--bg-secondary) 100%);
    padding: 20px;
    width: 100%;
    height: auto;
    overflow-y: auto !important;
    overflow-x: hidden;
}

.login-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    max-width: 1200px;
    width: 100%;
    background: var(--bg-card);
    border-radius: 20px;
    overflow: visible;
    box-shadow: var(--shadow-hover);
    min-height: auto;
    height: auto;
}

.login-box {
    padding: 60px 50px;
    background: #1a2744;
}

[data-theme="light"] .login-box {
    background: #F5F5F5;  /* Light Grey instead of white */
}

[data-theme="light"] .login-header h1,
[data-theme="light"] h1,
[data-theme="light"] h2,
[data-theme="light"] h3,
[data-theme="light"] h4,
[data-theme="light"] h5,
[data-theme="light"] h6 {
    color: #000000 !important;
}

[data-theme="light"] p,
[data-theme="light"] span,
[data-theme="light"] div,
[data-theme="light"] td,
[data-theme="light"] th,
[data-theme="light"] label {
    color: #000000;
}

[data-theme="light"] .text-secondary,
[data-theme="light"] small {
    color: #374151;
}

.login-header {
    text-align: center;
    margin-bottom: 40px;
}

.login-header .logo {
    width: 80px;
    height: 80px;
    background: #5B8DEE;
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    box-shadow: 0 4px 6px -1px rgba(91, 141, 238, 0.3), 0 2px 4px -2px rgba(91, 141, 238, 0.2);
}

.login-header .logo i {
    font-size: 40px;
    color: white;
}

.login-header h1 {
    font-size: 28px;
    margin-bottom: 10px;
    color: #5B8DEE;
    font-weight: 700;
}

.login-header p {
    color: #94A3B8;
    font-size: 14px;
}

[data-theme="light"] .login-header p {
    color: #6B7280;
}

/* Alerts */
.alert {
    padding: 15px 20px;
    border-radius: 10px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.alert i {
    font-size: 18px;
}

.alert-error {
    background: rgba(255, 61, 113, 0.1);
    color: var(--danger-red);
    border: 1px solid var(--danger-red);
}

.alert-success {
    background: rgba(0, 214, 143, 0.1);
    color: var(--success-green);
    border: 1px solid var(--success-green);
}

.alert-warning {
    background: rgba(255, 170, 0, 0.1);
    color: var(--warning-orange);
    border: 1px solid var(--warning-orange);
}

.alert-info {
    background: rgba(0, 149, 255, 0.1);
    color: var(--info-blue);
    border: 1px solid var(--info-blue);
}

/* Form Styles */
.form-group {
    margin-bottom: 25px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #cbd5e1;
    font-size: 14px;
}

[data-theme="light"] .form-group label {
    color: #000000;
    font-weight: 600;
}

.form-group label i {
    margin-right: 5px;
    color: #5B8DEE;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #2d3748;
    border-radius: 10px;
    background: #0f1623;
    color: #e2e8f0;
    font-size: 14px;
    transition: all 0.3s ease;
}

[data-theme="light"] .form-group input,
[data-theme="light"] .form-group select,
[data-theme="light"] .form-group textarea {
    background: #ffffff;
    color: #000000;
    border: 2px solid #d1d5db;
}

[data-theme="light"] .form-group input::placeholder,
[data-theme="light"] .form-group select::placeholder,
[data-theme="light"] .form-group textarea::placeholder {
    color: #6b7280;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--border-focus);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.password-input {
    position: relative;
}

.toggle-password {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
    color: var(--text-secondary);
}

.toggle-password:hover {
    color: var(--primary-blue);
}

.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
}

.remember-me {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: #94a3b8;
    cursor: pointer;
}

[data-theme="light"] .remember-me {
    color: #000000;
}

.remember-me input[type="checkbox"] {
    width: auto;
    cursor: pointer;
}

.forgot-password {
    font-size: 14px;
    color: #5B8DEE;
}

/* Buttons */
.btn {
    padding: 12px 24px;
    border: none;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
}

.btn-primary {
    background: #5B8DEE;
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(91, 141, 238, 0.4);
    opacity: 0.95;
}

.btn-secondary {
    background: var(--bg-secondary);
    color: var(--text-primary);
    border: 2px solid var(--border-color);
}

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

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

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

.btn-info {
    background: var(--info-blue);
    color: white;
}

.btn-block {
    width: 100%;
    justify-content: center;
}

.btn-sm {
    padding: 8px 16px;
    font-size: 12px;
}

.btn-lg {
    padding: 16px 32px;
    font-size: 16px;
}

/* Login Footer */
.login-footer {
    text-align: center;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #2d3748;
}

[data-theme="light"] .login-footer {
    border-top: 1px solid #e5e7eb;
}

.login-footer p {
    color: #94a3b8;
    font-size: 13px;
    margin-bottom: 5px;
}

[data-theme="light"] .login-footer p {
    color: #6b7280;
}

.login-footer strong {
    color: #5B8DEE;
}

.copyright {
    font-size: 12px !important;
}

/* Login Illustration */
.login-illustration {
    background: #5B8DEE;
    padding: 60px 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
}

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

.illustration-content h2 {
    font-size: 36px;
    margin-bottom: 15px;
}

.illustration-content > p {
    font-size: 16px;
    margin-bottom: 40px;
    opacity: 0.9;
}

.features {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.feature-item {
    background: rgba(255, 255, 255, 0.1);
    padding: 20px;
    border-radius: 10px;
    backdrop-filter: blur(10px);
}

.feature-item i {
    font-size: 30px;
    margin-bottom: 10px;
    display: block;
}

.feature-item span {
    font-size: 14px;
    display: block;
}

/* Dashboard Layout */
.dashboard-wrapper {
    display: flex;
    min-height: 100vh;
}

/* Sidebar */
.sidebar {
    width: 280px;
    background: var(--bg-card);
    border-right: 1px solid var(--border-color);
    padding: 20px 0;
    position: fixed;
    height: 100vh;
    overflow-y: auto;
    transition: all 0.3s ease;
}

.sidebar-header {
    padding: 0 20px 20px;
    border-bottom: 1px solid var(--border-color);
}

.sidebar-logo {
    display: flex;
    align-items: center;
    gap: 15px;
}

.sidebar-logo-icon {
    width: 50px;
    height: 50px;
    background: var(--gradient-primary);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-md);
}

.sidebar-logo-icon i {
    font-size: 24px;
    color: white;
}

.sidebar-logo-text h2 {
    font-size: 18px;
    margin-bottom: 2px;
}

.sidebar-logo-text p {
    font-size: 12px;
    color: var(--text-secondary);
}

.sidebar-menu {
    padding: 20px 0;
}

.menu-section {
    margin-bottom: 30px;
}

.menu-title {
    padding: 0 20px;
    font-size: 11px;
    text-transform: uppercase;
    color: var(--text-secondary);
    font-weight: 600;
    margin-bottom: 10px;
    letter-spacing: 1px;
}

.menu-item {
    padding: 12px 20px;
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--text-secondary);
    transition: all 0.3s ease;
    cursor: pointer;
}

.menu-item:hover {
    background: var(--bg-hover);
    color: var(--primary-blue);
}

.menu-item.active {
    background: linear-gradient(90deg, rgba(59, 130, 246, 0.1), transparent);
    color: var(--primary-blue);
    border-left: 3px solid var(--primary-blue);
}

.menu-item i {
    font-size: 18px;
    width: 20px;
}

.menu-item span {
    font-size: 14px;
    font-weight: 500;
}

.menu-badge {
    margin-left: auto;
    background: var(--danger-red);
    color: white;
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 11px;
    font-weight: 600;
}

/* Main Content */
.main-content {
    margin-left: 280px;
    flex: 1;
    background: var(--bg-primary);
    min-height: 100vh;
}

/* Header */
.header {
    background: var(--bg-card);
    border-bottom: 1px solid var(--border-color);
    padding: 20px 30px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-left h1 {
    font-size: 24px;
    margin-bottom: 5px;
}

.breadcrumb {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: var(--text-secondary);
}

.breadcrumb a {
    color: var(--text-secondary);
}

.breadcrumb a:hover {
    color: var(--primary-blue);
}

.header-right {
    display: flex;
    align-items: center;
    gap: 20px;
}

.search-box {
    position: relative;
}

.search-box input {
    padding: 10px 40px 10px 15px;
    border: 2px solid var(--border-color);
    border-radius: 10px;
    background: var(--bg-secondary);
    color: var(--text-primary);
    width: 300px;
    transition: all 0.3s ease;
}

.search-box input:focus {
    outline: none;
    border-color: var(--border-focus);
    width: 350px;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.search-box i {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-secondary);
}

.header-icon {
    width: 40px;
    height: 40px;
    background: var(--bg-secondary);
    border: 2px solid var(--border-color);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    position: relative;
    transition: all 0.3s ease;
}

.header-icon:hover {
    background: var(--bg-hover);
    border-color: var(--primary-blue);
}

.header-icon:hover i {
    color: white;
}

.header-icon i {
    font-size: 18px;
    color: var(--text-secondary);
}

.notification-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: var(--danger-red);
    color: white;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    font-size: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
}

.user-profile {
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    padding: 8px 12px;
    border-radius: 10px;
    transition: all 0.3s ease;
}

.user-profile:hover {
    background: var(--bg-secondary);
}

.user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    background: var(--gradient-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    overflow: hidden;
}

.user-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 10px;
}

.user-info h4 {
    font-size: 14px;
    margin-bottom: 2px;
}

.user-info p {
    font-size: 12px;
    color: var(--text-secondary);
}

/* Content Area */
.content {
    padding: 30px;
}

/* Stats Cards */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: var(--bg-card);
    border-radius: 15px;
    padding: 25px;
    box-shadow: var(--shadow);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: var(--gradient-primary);
}

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

.stat-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 15px;
}

.stat-icon {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
}

.stat-icon.blue {
    background: rgba(30, 58, 138, 0.1);
    color: var(--primary-blue);
}

.stat-icon.secondary {
    background: rgba(59, 130, 246, 0.1);
    color: var(--secondary-blue);
}

.stat-icon.orange {
    background: rgba(217, 119, 6, 0.1);
    color: var(--warning-orange);
}

.stat-icon.green {
    background: rgba(5, 150, 105, 0.1);
    color: var(--success-green);
}

.stat-icon.red {
    background: rgba(220, 38, 38, 0.1);
    color: var(--danger-red);
}

.stat-trend {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 12px;
    padding: 4px 8px;
    border-radius: 6px;
}

.stat-trend.up {
    background: rgba(5, 150, 105, 0.1);
    color: var(--success-green);
}

.stat-trend.down {
    background: rgba(220, 38, 38, 0.1);
    color: var(--danger-red);
}

.stat-body h3 {
    font-size: 28px;
    margin-bottom: 5px;
}

.stat-body p {
    font-size: 14px;
    color: var(--text-secondary);
}

/* Cards */
.card {
    background: var(--bg-card);
    border-radius: 15px;
    padding: 25px;
    box-shadow: var(--shadow);
    margin-bottom: 20px;
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--border-color);
}

.card-header h3 {
    font-size: 18px;
}

.card-actions {
    display: flex;
    gap: 10px;
}

/* Tables */
.table-responsive {
    overflow-x: auto;
}

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

table thead {
    background: var(--bg-secondary);
}

table th {
    padding: 15px;
    text-align: left;
    font-size: 13px;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

table td {
    padding: 15px;
    border-bottom: 1px solid var(--border-color);
    font-size: 14px;
}

table tbody tr {
    transition: all 0.3s ease;
}

table tbody tr:hover {
    background: var(--bg-hover);
}

/* Badges */
.badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.badge-success {
    background: rgba(5, 150, 105, 0.1);
    color: var(--success-green);
}

.badge-danger {
    background: rgba(220, 38, 38, 0.1);
    color: var(--danger-red);
}

.badge-warning {
    background: rgba(217, 119, 6, 0.1);
    color: var(--warning-orange);
}

.badge-info {
    background: rgba(2, 132, 199, 0.1);
    color: var(--info-blue);
}

.badge-primary {
    background: rgba(30, 58, 138, 0.1);
    color: var(--primary-blue);
}

/* Responsive Design */
@media (max-width: 1024px) {
    .sidebar {
        width: 70px;
    }
    
    .sidebar-logo-text,
    .menu-title,
    .menu-item span {
        display: none;
    }
    
    .main-content {
        margin-left: 70px;
    }
    
    .login-container {
        grid-template-columns: 1fr;
        max-height: none;
        overflow-y: visible;
    }
    
    .login-illustration {
        display: none;
    }
}

@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
    }
    
    .sidebar.active {
        transform: translateX(0);
    }
    
    .main-content {
        margin-left: 0;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .search-box input {
        width: 200px;
    }
    
    .search-box input:focus {
        width: 250px;
    }
    
    /* Mobile Login Page Fixes */
    .login-page {
        padding: 10px;
        min-height: 100vh;
        height: auto;
        overflow-y: auto !important;
        overflow-x: hidden !important;
        display: block !important;
    }
    
    .login-container {
        width: 100%;
        max-width: 100%;
        border-radius: 15px;
        box-shadow: none;
        margin: 20px auto;
        max-height: none;
        height: auto;
        overflow-y: visible;
    }
    
    .login-box {
        padding: 30px 20px;
    }
    
    .login-header h1 {
        font-size: 24px;
    }
    
    .form-group {
        margin-bottom: 20px;
    }
    
    .form-group input,
    .form-group select,
    .form-group textarea {
        padding: 12px 15px;
        font-size: 16px; /* Prevent zoom on iOS */
    }
    
    .btn {
        padding: 12px 20px;
        font-size: 16px;
    }
}

/* Mobile Menu Toggle */
.mobile-menu-toggle {
    display: none;
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 60px;
    height: 60px;
    background: var(--gradient-primary);
    border-radius: 50%;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 24px;
    cursor: pointer;
    box-shadow: var(--shadow-hover);
    z-index: 1001;
    transition: all 0.3s ease;
}

.mobile-menu-toggle:hover {
    transform: scale(1.1);
    box-shadow: var(--shadow-lg);
}

@media (max-width: 768px) {
    .mobile-menu-toggle {
        display: flex;
    }
}

/* Loading Spinner */
.spinner {
    border: 3px solid var(--border-color);
    border-top: 3px solid var(--primary-blue);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Utility Classes */
.text-center { text-align: center; }
.text-right { text-align: right; }
.text-left { text-align: left; }
.mt-1 { margin-top: 10px; }
.mt-2 { margin-top: 20px; }
.mt-3 { margin-top: 30px; }
.mb-1 { margin-bottom: 10px; }
.mb-2 { margin-bottom: 20px; }
.mb-3 { margin-bottom: 30px; }
.p-1 { padding: 10px; }
.p-2 { padding: 20px; }
.p-3 { padding: 30px; }
.d-flex { display: flex; }
.align-items-center { align-items: center; }
.justify-content-between { justify-content: space-between; }
.gap-1 { gap: 10px; }
.gap-2 { gap: 20px; }
.gap-3 { gap: 30px; }

/* ============================================
   SCI-FI ANIMATIONS & EFFECTS
   ============================================ */

/* Sci-Fi Keyframe Animations */
@keyframes glow {
    0%, 100% {
        box-shadow: 0 0 5px rgba(59, 130, 246, 0.5),
                    0 0 10px rgba(59, 130, 246, 0.3),
                    0 0 15px rgba(59, 130, 246, 0.1);
    }
    50% {
        box-shadow: 0 0 10px rgba(59, 130, 246, 0.8),
                    0 0 20px rgba(59, 130, 246, 0.5),
                    0 0 30px rgba(59, 130, 246, 0.3);
    }
}

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

@keyframes slideInLeft {
    from {
        transform: translateX(-100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

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

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes shimmer {
    0% {
        background-position: -1000px 0;
    }
    100% {
        background-position: 1000px 0;
    }
}

@keyframes neonBorder {
    0%, 100% {
        border-color: rgba(59, 130, 246, 0.5);
        box-shadow: 0 0 5px rgba(59, 130, 246, 0.5);
    }
    50% {
        border-color: rgba(59, 130, 246, 1);
        box-shadow: 0 0 20px rgba(59, 130, 246, 0.8),
                    0 0 30px rgba(59, 130, 246, 0.4);
    }
}

@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-10px);
    }
}

@keyframes rotateIn {
    from {
        transform: rotate(-180deg) scale(0);
        opacity: 0;
    }
    to {
        transform: rotate(0) scale(1);
        opacity: 1;
    }
}

@keyframes scanLine {
    0% {
        transform: translateY(-100%);
    }
    100% {
        transform: translateY(100%);
    }
}

/* Apply animations to cards */
.card, .stat-card {
    animation: fadeIn 0.6s ease-out;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.card::before, .stat-card::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(
        to bottom,
        rgba(255, 255, 255, 0) 0%,
        rgba(255, 255, 255, 0.03) 50%,
        rgba(255, 255, 255, 0) 100%
    );
    transform: rotate(45deg);
    animation: scanLine 3s linear infinite;
    pointer-events: none;
}

.card:hover, .stat-card:hover {
    transform: translateY(-5px) scale(1.02);
    box-shadow: 0 20px 40px rgba(59, 130, 246, 0.2),
                0 0 20px rgba(59, 130, 246, 0.1);
}

/* Sidebar animations */
.sidebar {
    animation: slideInLeft 0.5s ease-out;
}

.menu-item {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
}

.menu-item::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    width: 3px;
    background: linear-gradient(to bottom, #3B82F6, #60A5FA);
    transform: scaleY(0);
    transition: transform 0.3s ease;
}

.menu-item:hover::before, .menu-item.active::before {
    transform: scaleY(1);
}

.menu-item:hover {
    transform: translateX(5px);
    background: linear-gradient(90deg, rgba(59, 130, 246, 0.15), transparent);
}

.menu-item i {
    transition: all 0.3s ease;
}

.menu-item:hover i {
    transform: scale(1.2) rotate(5deg);
    color: #60A5FA;
}

/* Header animations */
.header {
    animation: slideInUp 0.5s ease-out;
    backdrop-filter: blur(10px);
}

/* Button sci-fi effects */
.btn {
    position: relative;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.btn:hover::before {
    width: 300px;
    height: 300px;
}

.btn:hover {
    transform: translateY(-2px) scale(1.05);
    box-shadow: 0 10px 25px rgba(59, 130, 246, 0.4),
                0 0 20px rgba(59, 130, 246, 0.3);
}

.btn:active {
    transform: translateY(0) scale(0.98);
}

.btn-primary {
    animation: glow 2s ease-in-out infinite;
}

/* Table animations */
table tbody tr {
    animation: slideInUp 0.5s ease-out;
    animation-fill-mode: both;
    transition: all 0.3s ease;
}

table tbody tr:nth-child(1) { animation-delay: 0.05s; }
table tbody tr:nth-child(2) { animation-delay: 0.1s; }
table tbody tr:nth-child(3) { animation-delay: 0.15s; }
table tbody tr:nth-child(4) { animation-delay: 0.2s; }
table tbody tr:nth-child(5) { animation-delay: 0.25s; }

table tbody tr:hover {
    transform: scale(1.01);
    box-shadow: 0 5px 15px rgba(59, 130, 246, 0.1);
}

/* Input animations */
.form-group input,
.form-group select,
.form-group textarea {
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    transform: scale(1.02);
    animation: neonBorder 2s ease-in-out infinite;
}

/* Stats grid animations */
.stats-grid {
    display: grid;
    gap: 20px;
}

.stat-card:nth-child(1) { animation-delay: 0.1s; }
.stat-card:nth-child(2) { animation-delay: 0.2s; }
.stat-card:nth-child(3) { animation-delay: 0.3s; }
.stat-card:nth-child(4) { animation-delay: 0.4s; }

.stat-icon {
    transition: all 0.4s ease;
    animation: float 3s ease-in-out infinite;
}

.stat-card:hover .stat-icon {
    transform: scale(1.2) rotate(360deg);
}

/* Badge animations */
.badge {
    transition: all 0.3s ease;
    animation: pulse 2s ease-in-out infinite;
}

.badge:hover {
    transform: scale(1.1);
}

/* User avatar animation */
.user-avatar {
    transition: all 0.4s ease;
    animation: glow 3s ease-in-out infinite;
}

.user-avatar:hover {
    transform: rotate(360deg) scale(1.1);
}

/* Header icons animation */
.header-icon {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.header-icon:hover {
    transform: scale(1.2) rotate(15deg);
    animation: pulse 0.6s ease-in-out;
}

.notification-badge {
    animation: pulse 1.5s ease-in-out infinite;
}

/* Search box animation */
.search-box input {
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.search-box input:focus {
    animation: glow 2s ease-in-out infinite;
}

/* Theme toggle animation */
.theme-toggle {
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    animation: float 4s ease-in-out infinite;
}

.theme-toggle:hover {
    transform: scale(1.2) rotate(180deg);
    animation: glow 1s ease-in-out infinite;
}

/* Alert animations */
.alert {
    animation: slideInRight 0.5s ease-out;
    border-left-width: 4px;
    transition: all 0.3s ease;
}

.alert:hover {
    transform: translateX(-5px);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
}

/* Loading shimmer effect */
.shimmer {
    background: linear-gradient(
        90deg,
        rgba(255, 255, 255, 0) 0%,
        rgba(255, 255, 255, 0.2) 50%,
        rgba(255, 255, 255, 0) 100%
    );
    background-size: 1000px 100%;
    animation: shimmer 2s infinite;
}

/* Page load animation */
@keyframes pageLoad {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.content {
    animation: pageLoad 0.6s ease-out;
}

/* Breadcrumb animation */
.breadcrumb {
    animation: slideInRight 0.5s ease-out;
}

.breadcrumb a {
    transition: all 0.3s ease;
    position: relative;
}

.breadcrumb a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -2px;
    left: 0;
    background: #3B82F6;
    transition: width 0.3s ease;
}

.breadcrumb a:hover::after {
    width: 100%;
}

/* Dropdown and modal animations */
@keyframes dropDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Particle effect background */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        radial-gradient(circle at 20% 50%, rgba(59, 130, 246, 0.05) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(96, 165, 250, 0.05) 0%, transparent 50%),
        radial-gradient(circle at 40% 20%, rgba(59, 130, 246, 0.03) 0%, transparent 50%);
    pointer-events: none;
    z-index: -1;
    animation: pulse 10s ease-in-out infinite;
}

/* Glassmorphism effect for cards in dark mode */
[data-theme="dark"] .card,
[data-theme="dark"] .stat-card {
    background: rgba(30, 41, 59, 0.7);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(59, 130, 246, 0.1);
}

[data-theme="dark"] .card:hover,
[data-theme="dark"] .stat-card:hover {
    border-color: rgba(246, 59, 199, 0.3);
    background: rgba(4, 19, 43, 0.9);
}

/* Smooth scroll behavior */
html {
    scroll-behavior: smooth;
}

/* Link hover effects */
a {
    position: relative;
    transition: all 0.3s ease;
}

a:hover {
    text-shadow: 0 0 8px rgba(190, 9, 94, 0.5);
}

/* Form labels animation */
.form-group label {
    transition: all 0.3s ease;
}

.form-group:hover label {
    transform: translateX(5px);
    color: #3B82F6;
}

/* Login box animation */
.login-box {
    animation: fadeIn 0.8s ease-out;
}

.login-illustration {
    animation: slideInRight 0.8s ease-out;
}

/* Mobile menu toggle animation */
.mobile-menu-toggle {
    animation: pulse 2s ease-in-out infinite;
    transition: all 0.3s ease;
}

.mobile-menu-toggle:hover {
    animation: rotateIn 0.5s ease-out;
}

/* Responsive adjustments */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* ========================================
   LIGHT MODE CLARITY ENHANCEMENTS
   Ensures all text is black/dark for maximum readability
   ======================================== */

[data-theme="light"] {
    /* Ensure body text is black */
    color: #000000;
}

[data-theme="light"] body,
[data-theme="light"] .sidebar,
[data-theme="light"] .main-content,
[data-theme="light"] .dashboard {
    color: #000000;
}

/* Headings - Pure Black */
[data-theme="light"] h1,
[data-theme="light"] h2,
[data-theme="light"] h3,
[data-theme="light"] h4,
[data-theme="light"] h5,
[data-theme="light"] h6,
[data-theme="light"] .card-title,
[data-theme="light"] .section-title,
[data-theme="light"] .page-title {
    color: #000000 !important;
}

/* Paragraphs and Text Elements */
[data-theme="light"] p,
[data-theme="light"] span:not(.badge),
[data-theme="light"] div:not(.alert),
[data-theme="light"] li,
[data-theme="light"] td,
[data-theme="light"] th,
[data-theme="light"] strong,
[data-theme="light"] b {
    color: #000000;
}

/* Table Headers - Bold Black */
[data-theme="light"] thead th,
[data-theme="light"] thead td {
    color: #000000 !important;
    font-weight: 600;
}

/* Table Body */
[data-theme="light"] tbody td,
[data-theme="light"] tbody th {
    color: #000000;
}

/* Navigation and Sidebar */
[data-theme="light"] .sidebar-menu a,
[data-theme="light"] .nav-link,
[data-theme="light"] .menu-item {
    color: #000000;
}

[data-theme="light"] .sidebar-menu a:hover {
    color: #1E3A8A;
}

/* Cards */
[data-theme="light"] .card,
[data-theme="light"] .card-header,
[data-theme="light"] .card-body,
[data-theme="light"] .card-footer {
    color: #000000;
}

/* Card Headings and Titles */
[data-theme="light"] .card h1,
[data-theme="light"] .card h2,
[data-theme="light"] .card h3,
[data-theme="light"] .card h4,
[data-theme="light"] .card h5,
[data-theme="light"] .card h6,
[data-theme="light"] .card-title,
[data-theme="light"] .card-header h3,
[data-theme="light"] .card-header h4 {
    color: #000000 !important;
    font-weight: 600;
}

/* Card Body Text */
[data-theme="light"] .card p,
[data-theme="light"] .card span:not(.badge),
[data-theme="light"] .card div:not(.badge):not(.btn),
[data-theme="light"] .card label,
[data-theme="light"] .card li {
    color: #000000;
}

/* Card Links */
[data-theme="light"] .card a:not(.btn) {
    color: #1E3A8A;
}

[data-theme="light"] .card a:not(.btn):hover {
    color: #3B82F6;
}

/* Stats and Metrics */
[data-theme="light"] .stat-value,
[data-theme="light"] .metric-value,
[data-theme="light"] .count,
[data-theme="light"] .amount {
    color: #000000 !important;
}

/* Secondary Text - Dark Gray for Contrast */
[data-theme="light"] .text-secondary,
[data-theme="light"] .secondary-text,
[data-theme="light"] small,
[data-theme="light"] .small-text {
    color: #374151 !important;
}

/* Muted Text - Medium Gray */
[data-theme="light"] .text-muted,
[data-theme="light"] .muted-text {
    color: #6B7280 !important;
}

/* Links in Light Mode */
[data-theme="light"] a:not(.btn) {
    color: #1E3A8A;
}

[data-theme="light"] a:not(.btn):hover {
    color: #3B82F6;
}

/* Form Elements Text */
[data-theme="light"] label,
[data-theme="light"] .form-label,
[data-theme="light"] legend {
    color: #000000 !important;
    font-weight: 600;
}

[data-theme="light"] input,
[data-theme="light"] select,
[data-theme="light"] textarea,
[data-theme="light"] .form-control {
    color: #000000 !important;
}

[data-theme="light"] input::placeholder,
[data-theme="light"] select::placeholder,
[data-theme="light"] textarea::placeholder {
    color: #6B7280 !important;
}

/* Dropdown Options */
[data-theme="light"] option {
    color: #000000;
    background: #ffffff;
}

/* Buttons - Ensure text is visible */
[data-theme="light"] .btn-secondary,
[data-theme="light"] .btn-outline {
    color: #000000 !important;
}

/* Modal and Dialog Text */
[data-theme="light"] .modal,
[data-theme="light"] .dialog,
[data-theme="light"] .popup {
    color: #000000;
}

/* Alert Text */
[data-theme="light"] .alert-error {
    color: #991B1B !important;
}

[data-theme="light"] .alert-success {
    color: #065F46 !important;
}

[data-theme="light"] .alert-warning {
    color: #92400E !important;
}

[data-theme="light"] .alert-info {
    color: #1E40AF !important;
}

/* Dashboard Stats */
[data-theme="light"] .stat-card h3,
[data-theme="light"] .stat-card p,
[data-theme="light"] .stat-card span {
    color: #000000 !important;
}

/* Dashboard Stat Cards - Comprehensive */
[data-theme="light"] .stat-card,
[data-theme="light"] .stats-card,
[data-theme="light"] .dashboard-card {
    color: #000000;
}

[data-theme="light"] .stat-card .stat-value,
[data-theme="light"] .stat-card .stat-label,
[data-theme="light"] .stat-card .stat-number,
[data-theme="light"] .stats-card .value,
[data-theme="light"] .stats-card .label {
    color: #000000 !important;
}

/* Card Numbers and Values */
[data-theme="light"] .card .value,
[data-theme="light"] .card .count,
[data-theme="light"] .card .number,
[data-theme="light"] .card .amount,
[data-theme="light"] .card .total {
    color: #000000 !important;
    font-weight: 700;
}

/* Card Descriptions and Labels */
[data-theme="light"] .card .description,
[data-theme="light"] .card .label,
[data-theme="light"] .card .caption {
    color: #374151;
}

/* Card Icons (keep their designated colors) */
[data-theme="light"] .card i.fa,
[data-theme="light"] .card i.fas,
[data-theme="light"] .card i.far {
    /* Icons keep their designated colors - no override needed */
}

/* Lists */
[data-theme="light"] ul li,
[data-theme="light"] ol li {
    color: #000000;
}

/* Breadcrumb */
[data-theme="light"] .breadcrumb,
[data-theme="light"] .breadcrumb-item {
    color: #374151;
}

[data-theme="light"] .breadcrumb-item.active {
    color: #000000;
    font-weight: 600;
}

/* Footer */
[data-theme="light"] footer,
[data-theme="light"] .footer {
    color: #374151;
}

/* Empty States */
[data-theme="light"] .empty-state h3,
[data-theme="light"] .empty-state p {
    color: #000000 !important;
}

/* Status Indicators - Maintain their colors but ensure readability */
[data-theme="light"] .status-active,
[data-theme="light"] .badge-success {
    background: #D1FAE5;
    color: #065F46 !important;
    border: 1px solid #10B981;
}

[data-theme="light"] .status-inactive,
[data-theme="light"] .badge-danger {
    background: #FEE2E2;
    color: #991B1B !important;
    border: 1px solid #EF4444;
}

[data-theme="light"] .status-pending,
[data-theme="light"] .badge-warning {
    background: #FEF3C7;
    color: #92400E !important;
    border: 1px solid #F59E0B;
}

[data-theme="light"] .badge-info {
    background: #DBEAFE;
    color: #1E40AF !important;
    border: 1px solid #3B82F6;
}

/* Payment Receipt Text */
[data-theme="light"] .receipt-container,
[data-theme="light"] .student-receipt {
    color: #000000;
}

/* Info Cards and Summary Cards */
[data-theme="light"] .info-card,
[data-theme="light"] .summary-card,
[data-theme="light"] .overview-card,
[data-theme="light"] .detail-card {
    color: #000000;
}

[data-theme="light"] .info-card h3,
[data-theme="light"] .info-card h4,
[data-theme="light"] .summary-card h3,
[data-theme="light"] .summary-card h4 {
    color: #000000 !important;
}

/* Card Grid Items */
[data-theme="light"] .grid-card,
[data-theme="light"] .card-grid-item {
    color: #000000;
}

[data-theme="light"] .grid-card h3,
[data-theme="light"] .grid-card h4,
[data-theme="light"] .card-grid-item h3,
[data-theme="light"] .card-grid-item h4 {
    color: #000000 !important;
    font-weight: 600;
}

/* Metric Cards */
[data-theme="light"] .metric-card,
[data-theme="light"] .kpi-card {
    color: #000000;
}

[data-theme="light"] .metric-card .metric,
[data-theme="light"] .metric-card .kpi,
[data-theme="light"] .kpi-card .value {
    color: #000000 !important;
    font-weight: 700;
}

/* List Cards */
[data-theme="light"] .list-card,
[data-theme="light"] .card-list {
    color: #000000;
}

[data-theme="light"] .list-card ul li,
[data-theme="light"] .card-list ul li,
[data-theme="light"] .list-card ol li,
[data-theme="light"] .card-list ol li {
    color: #000000;
}

/* Ensure all text in light mode has proper contrast */
[data-theme="light"] * {
    text-shadow: none;
}
