/* KLEVELUP - Online Classes Management System - Modern UI/UX */

:root {
    --primary-gradient: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --primary-color: #667eea;
    --primary-dark: #764ba2;
    --secondary-color: #f093fb;
    --accent-color: #4facfe;
    --success-color: #00d4aa;
    --danger-color: #ff6b6b;
    --warning-color: #ffa502;
    --info-color: #0dcaf0;
    --light-bg: #f8f9ff;
    --card-shadow: 0 10px 40px rgba(102, 126, 234, 0.15);
    --hover-shadow: 0 20px 60px rgba(102, 126, 234, 0.25);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Segoe UI', 'Inter', -apple-system, BlinkMacSystemFont, Tahoma, Geneva, Verdana, sans-serif;
    background-color: var(--light-bg);
    color: #2d3748;
    line-height: 1.6;
}

/* ==================== NAVBAR ==================== */
.navbar {
    background: var(--primary-gradient) !important;
    box-shadow: 0 8px 32px rgba(102, 126, 234, 0.2);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.navbar-brand {
    font-weight: 800;
    font-size: 1.5rem;
    background: linear-gradient(to right, #fff, #f0f0ff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -0.5px;
    display: flex;
    align-items: center;
}

.navbar-brand i {
    margin-right: 12px;
    font-size: 1.8rem;
    color: #fff;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.navbar-nav .nav-link {
    color: rgba(255, 255, 255, 0.9) !important;
    font-weight: 500;
    margin: 0 8px;
    padding: 8px 16px !important;
    border-radius: 8px;
    transition: all 0.3s ease;
    position: relative;
}

.navbar-nav .nav-link:hover {
    color: #fff !important;
    background-color: rgba(255, 255, 255, 0.15);
    transform: translateY(-2px);
}

.navbar-nav .nav-link i {
    margin-right: 6px;
}

.navbar-toggler {
    border-color: rgba(255, 255, 255, 0.5);
}

/* ==================== SIDEBAR ==================== */
.sidebar {
    background: white;
    box-shadow: var(--card-shadow);
    border-radius: 12px;
    overflow: hidden;
}

.sidebar-header {
    background: var(--primary-gradient);
    color: white;
    padding: 20px;
    font-weight: 700;
    font-size: 1.1rem;
}

.list-group-item {
    border: none;
    border-left: 4px solid transparent;
    padding: 12px 16px;
    margin-bottom: 2px;
    color: #555;
    font-weight: 500;
    transition: all 0.3s ease;
    cursor: pointer;
}

.list-group-item:hover {
    background-color: #f0f4ff;
    border-left-color: var(--primary-color);
    padding-left: 20px;
    color: var(--primary-color);
}

.list-group-item.active {
    background: linear-gradient(90deg, rgba(102, 126, 234, 0.1) 0%, transparent 100%);
    border-left-color: var(--primary-color);
    color: var(--primary-color);
    font-weight: 700;
}

.list-group-item i {
    margin-right: 12px;
    width: 20px;
    color: inherit;
}

/* ==================== CARDS ==================== */
.card {
    border: none;
    border-radius: 12px;
    box-shadow: var(--card-shadow);
    transition: all 0.3s ease;
    overflow: hidden;
    background: white;
    border-top: 4px solid var(--primary-color);
}

.card:hover {
    box-shadow: var(--hover-shadow);
    transform: translateY(-8px);
}

.card-header {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: white;
    border: none;
    padding: 20px;
    font-weight: 700;
}

.card-body {
    padding: 24px;
}

.card-title {
    font-weight: 700;
    color: #2d3748;
    margin-bottom: 12px;
}

.card-text {
    color: #718096;
    font-size: 0.95rem;
}

/* ==================== FORMS ==================== */
.form-control,
.form-select {
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    padding: 10px 14px;
    transition: all 0.3s ease;
    font-size: 0.95rem;
}

.form-control:focus,
.form-select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.form-label {
    font-weight: 600;
    color: #2d3748;
    margin-bottom: 8px;
}

.input-group-text {
    background-color: transparent;
    border: 2px solid #e2e8f0;
    border-right: none;
}

.form-control + .input-group-text {
    border-left: none;
}

/* ==================== BUTTONS ==================== */
.btn {
    border: none;
    border-radius: 8px;
    font-weight: 600;
    padding: 10px 20px;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    cursor: pointer;
}

.btn-primary {
    background: var(--primary-gradient);
    color: white;
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary-color) 100%);
    box-shadow: 0 10px 25px rgba(102, 126, 234, 0.3);
    transform: translateY(-2px);
    color: white;
}

.btn-outline-primary {
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
}

.btn-outline-primary:hover {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.btn-success {
    background: linear-gradient(135deg, var(--success-color) 0%, #00b896 100%);
    color: white;
}

.btn-success:hover {
    box-shadow: 0 10px 25px rgba(0, 212, 170, 0.3);
    transform: translateY(-2px);
}

.btn-danger {
    background: linear-gradient(135deg, var(--danger-color) 0%, #e63946 100%);
    color: white;
}

.btn-danger:hover {
    box-shadow: 0 10px 25px rgba(255, 107, 107, 0.3);
    transform: translateY(-2px);
}

.btn-lg {
    padding: 14px 32px;
    font-size: 1.1rem;
}

/* ==================== TABLES ==================== */
.table {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--card-shadow);
    margin-bottom: 0;
}

.table thead {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: white;
}

.table thead th {
    border: none;
    font-weight: 700;
    padding: 16px;
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 0.5px;
}

.table tbody td {
    border: none;
    border-bottom: 1px solid #e2e8f0;
    padding: 14px 16px;
    vertical-align: middle;
}

.table tbody tr:hover {
    background-color: #f8f9ff;
}

.table tbody tr:last-child td {
    border-bottom: none;
}

/* ==================== BADGES ==================== */
.badge {
    padding: 8px 14px;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.8rem;
}

.badge-success {
    background-color: rgba(0, 212, 170, 0.2);
    color: var(--success-color);
}

.badge-danger {
    background-color: rgba(255, 107, 107, 0.2);
    color: var(--danger-color);
}

.badge-warning {
    background-color: rgba(255, 165, 2, 0.2);
    color: var(--warning-color);
}

.badge-primary {
    background-color: rgba(102, 126, 234, 0.2);
    color: var(--primary-color);
}

/* ==================== ALERTS ==================== */
.alert {
    border: none;
    border-radius: 12px;
    border-left: 4px solid;
    padding: 16px 20px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.alert-success {
    background-color: rgba(0, 212, 170, 0.1);
    border-left-color: var(--success-color);
    color: var(--success-color);
}

.alert-danger {
    background-color: rgba(255, 107, 107, 0.1);
    border-left-color: var(--danger-color);
    color: var(--danger-color);
}

.alert-warning {
    background-color: rgba(255, 165, 2, 0.1);
    border-left-color: var(--warning-color);
    color: var(--warning-color);
}

.alert-info {
    background-color: rgba(79, 172, 254, 0.1);
    border-left-color: var(--accent-color);
    color: var(--accent-color);
}

/* ==================== DASHBOARD STATS ==================== */
.stat-card {
    background: white;
    border-radius: 12px;
    padding: 24px;
    box-shadow: var(--card-shadow);
    transition: all 0.3s ease;
    border: none;
    position: relative;
    overflow: hidden;
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--primary-gradient);
}

.stat-card:hover {
    box-shadow: var(--hover-shadow);
    transform: translateY(-8px);
}

.stat-value {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--primary-color);
    line-height: 1;
}

.stat-label {
    font-size: 0.9rem;
    color: #718096;
    font-weight: 600;
    margin-top: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.stat-icon {
    font-size: 2.5rem;
    opacity: 0.1;
    position: absolute;
    top: 10px;
    right: 15px;
    color: var(--primary-color);
}

/* ==================== PROGRESS BARS ==================== */
.progress {
    background-color: #e2e8f0;
    border-radius: 10px;
    height: 10px;
    overflow: hidden;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.05);
}

.progress-bar {
    background: var(--primary-gradient);
    border-radius: 10px;
    transition: width 0.3s ease;
}

.progress-bar.bg-success {
    background: linear-gradient(90deg, var(--success-color) 0%, #00b896 100%) !important;
}

.progress-bar.bg-danger {
    background: linear-gradient(90deg, var(--danger-color) 0%, #e63946 100%) !important;
}

/* ==================== HERO SECTION ==================== */
.hero-section {
    background: var(--primary-gradient);
    color: white;
    padding: 80px 20px;
    text-align: center;
    border-radius: 16px;
    position: relative;
    overflow: hidden;
    box-shadow: var(--hover-shadow);
}

.hero-section::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -10%;
    width: 500px;
    height: 500px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
}

.hero-section::after {
    content: '';
    position: absolute;
    bottom: -30%;
    left: -10%;
    width: 300px;
    height: 300px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 800;
    margin-bottom: 20px;
    position: relative;
    z-index: 1;
    text-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.hero-subtitle {
    font-size: 1.3rem;
    margin-bottom: 30px;
    opacity: 0.95;
    position: relative;
    z-index: 1;
}

/* ==================== FEATURE CARDS ==================== */
.feature-card {
    background: white;
    border-radius: 16px;
    padding: 32px 24px;
    text-align: center;
    box-shadow: var(--card-shadow);
    transition: all 0.3s ease;
    height: 100%;
    position: relative;
    overflow: hidden;
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.05) 0%, transparent 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.feature-card:hover {
    box-shadow: var(--hover-shadow);
    transform: translateY(-12px);
}

.feature-card:hover::before {
    opacity: 1;
}

.feature-icon {
    font-size: 3rem;
    margin-bottom: 20px;
    display: inline-block;
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.2) 0%, rgba(240, 147, 251, 0.2) 100%);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
}

.feature-title {
    font-size: 1.3rem;
    font-weight: 700;
    color: #2d3748;
    margin-bottom: 12px;
}

.feature-description {
    color: #718096;
    font-size: 0.95rem;
    line-height: 1.6;
}

/* ==================== FOOTER ==================== */
.footer {
    background: linear-gradient(180deg, var(--primary-gradient) 0%, var(--primary-dark) 100%);
    color: white;
    padding: 40px 0;
    margin-top: 60px;
}

.footer-link {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: all 0.3s ease;
}

.footer-link:hover {
    color: white;
    text-decoration: underline;
}

/* ==================== RESPONSIVE ==================== */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2.5rem;
    }

    .hero-subtitle {
        font-size: 1rem;
    }

    .stat-value {
        font-size: 2rem;
    }

    .navbar-brand {
        font-size: 1.2rem;
    }

    .feature-card {
        margin-bottom: 20px;
    }

    .sidebar {
        margin-bottom: 20px;
    }
}

/* ==================== ANIMATIONS ==================== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade-in-up {
    animation: fadeInUp 0.5s ease-out;
}
