/* Custom Admin Styles for English Academy */

:root {
    --sidebar-width: 250px;
    --primary-color: #0d6efd;
    --secondary-color: #14b8a6;
}

/* Sidebar */
.sidebar {
    width: var(--sidebar-width);
    min-height: 100vh;
    position: fixed;
    left: 0;
    top: 0;
    transition: all 0.3s;
    z-index: 1000;
    display: flex;
    flex-direction: column;
}

.sidebar.collapsed {
    margin-left: calc(-1 * var(--sidebar-width));
}

.sidebar .nav-link {
    padding: 12px 20px;
    border-radius: 0;
    transition: all 0.2s;
}

.sidebar .nav-link:hover {
    background: rgba(255, 255, 255, 0.1);
}

.sidebar .nav-link.active {
    background: rgba(255, 255, 255, 0.2);
    border-left: 3px solid var(--secondary-color);
}

.sidebar-footer {
    margin-top: auto;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* Main Content */
.main-content {
    margin-left: var(--sidebar-width);
    min-height: 100vh;
    background: #f5f6fa;
    transition: all 0.3s;
}

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

/* Cards */
.card {
    border: none;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

/* Buttons */
.btn-primary {
    background: var(--primary-color);
    border-color: var(--primary-color);
}

.btn-primary:hover {
    background: #0b5ed7;
    border-color: #0a58ca;
}

/* Tables */
.table {
    background: white;
}

.table thead th {
    border-bottom: 2px solid #dee2e6;
    font-weight: 600;
    color: #495057;
}

/* Forms */
.form-control:focus,
.form-select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.15);
}

/* Badges */
.badge {
    font-weight: 500;
}

/* Responsive */
@media (max-width: 768px) {
    .sidebar {
        margin-left: calc(-1 * var(--sidebar-width));
    }
    
    .sidebar.show {
        margin-left: 0;
    }
    
    .main-content {
        margin-left: 0;
    }
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #a1a1a1;
}

/* Loading spinner */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

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

.fade-in {
    animation: fadeIn 0.3s ease-out;
}

/* Status colors */
.status-present { color: #198754; }
.status-absent { color: #dc3545; }
.status-sick { color: #fd7e14; }
.status-excused { color: #6c757d; }

/* Jazzmin overrides */
.main-sidebar {
    background: linear-gradient(180deg, #1a1a2e 0%, #16213e 100%) !important;
}

.brand-link {
    border-bottom: 1px solid rgba(255, 255, 255, 0.1) !important;
}

.nav-sidebar > .nav-item > .nav-link.active {
    background: rgba(20, 184, 166, 0.2) !important;
    color: #14b8a6 !important;
}
