/* ============================================
   ExpertB - Red & White Theme Stylesheet
   Modern Clean Design with Performance Optimizations
   ============================================ */

/* Import Google Fonts with display swap for faster load */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&family=Poppins:wght@400;500;600;700&display=swap');

/* ============================================
   Performance & Smooth Animations
   ============================================ */
* {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

html {
    scroll-behavior: smooth;
}

/* GPU acceleration for animations */
.card, .course-card, .service-card, .btn, button, a, img {
    will-change: transform, opacity;
    transform: translateZ(0);
    backface-visibility: hidden;
}

/* Smooth image loading - only for lazy loaded images */
img[data-src] {
    opacity: 0;
    transition: opacity 0.4s ease;
}

img[data-src].loaded, img.loaded {
    opacity: 1;
}

/* Lazy image placeholder with shimmer effect */
img.lazy-image {
    opacity: 0;
    background: linear-gradient(90deg, #e2e8f0 25%, #f1f5f9 50%, #e2e8f0 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    min-height: 150px;
}

@keyframes shimmer {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* Ensure all regular images are visible */
img:not([data-src]):not(.lazy-image) {
    opacity: 1 !important;
}

/* Logo and intro images always visible */
img[src*="logo"], .intro-logo img, .navbar-brand img, .course-card-image img, .course-card img {
    opacity: 1 !important;
}

/* Smooth hover transitions for all interactive elements */
a, button, .btn, .card, .course-card, input, textarea, select {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Reduce motion for users who prefer it */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    html {
        scroll-behavior: auto;
    }
}

/* Page fade-in animation */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.main-content, .container {
    animation: fadeIn 0.5s ease forwards;
}

/* Staggered card animations */
.course-card, .service-card, .card {
    animation: fadeIn 0.6s ease forwards;
}

.course-card:nth-child(1), .service-card:nth-child(1) { animation-delay: 0.1s; }
.course-card:nth-child(2), .service-card:nth-child(2) { animation-delay: 0.2s; }
.course-card:nth-child(3), .service-card:nth-child(3) { animation-delay: 0.3s; }
.course-card:nth-child(4), .service-card:nth-child(4) { animation-delay: 0.4s; }

/* ============================================
   CSS Variables - Red & White Color Scheme
   ============================================ */
:root {
    /* Primary Colors - Red */
    --primary: #ef4444;
    --primary-light: #f87171;
    --primary-dark: #dc2626;
    --primary-glow: rgba(239, 68, 68, 0.3);
    
    /* Secondary Colors - Dark Gray */
    --secondary: #1f2937;
    --secondary-light: #374151;
    --secondary-dark: #111827;
    
    /* Accent Colors - Red */
    --accent: #ef4444;
    --accent-light: #f87171;
    --accent-dark: #dc2626;
    
    /* Success/Error/Warning */
    --success: #10b981;
    --success-light: #34d399;
    --error: #ef4444;
    --error-light: #f87171;
    --warning: #f59e0b;
    --warning-light: #fbbf24;
    --info: #3b82f6;
    
    /* Background Colors - Light & Clean */
    --bg-primary: #f8f9fa;
    --bg-secondary: #f1f5f9;
    --bg-tertiary: #e5e7eb;
    --bg-card: rgba(255, 255, 255, 0.95);
    --bg-glass: rgba(255, 255, 255, 0.9);
    --bg-glass-light: rgba(255, 255, 255, 0.95);
    --bg-glass-strong: rgba(255, 255, 255, 1);
    
    /* Text Colors - Dark for readability */
    --text-primary: #1f2937;
    --text-secondary: #4b5563;
    --text-muted: #6b7280;
    --text-light: #9ca3af;
    
    /* Border Colors */
    --border-glass: rgba(0, 0, 0, 0.08);
    --border-glass-light: rgba(0, 0, 0, 0.05);
    --border-color: #e5e7eb;
    --glass-border: #e5e7eb;
    
    /* Gradients - Red themed */
    --gradient-primary: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    --gradient-secondary: linear-gradient(135deg, #1f2937 0%, #374151 100%);
    --gradient-light: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%);
    --gradient-card: linear-gradient(135deg, rgba(255,255,255,1) 0%, rgba(255,255,255,0.95) 100%);
    --gradient-hero: linear-gradient(135deg, #fef2f2 0%, #fff1f2 50%, #fdf2f8 100%);
    
    /* Shadows - Soft & Clean */
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.08);
    --shadow-md: 0 4px 15px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 10px 30px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 50px rgba(0, 0, 0, 0.12);
    --shadow-glow: 0 0 30px rgba(239, 68, 68, 0.2);
    --shadow-card: 0 4px 20px rgba(0, 0, 0, 0.06);
    
    /* Glass Effect */
    --glass-blur: blur(10px);
    --glass-blur-heavy: blur(20px);
    --glass-bg: rgba(255, 255, 255, 0.95);
    
    /* Spacing */
    --sidebar-width: 260px;
    --sidebar-collapsed: 80px;
    --header-height: 65px;
    
    /* Border Radius */
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 12px;
    --radius-xl: 16px;
    --radius-full: 9999px;
    
    /* Transitions */
    --transition-fast: 0.15s ease;
    --transition: 0.3s ease;
    --transition-slow: 0.5s ease;
}

/* ============================================
   Reset & Base Styles
   ============================================ */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: var(--gradient-hero);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
    min-height: 100vh;
}

/* Beautiful Animated Background */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(ellipse at 20% 20%, rgba(59, 130, 246, 0.15) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 80%, rgba(139, 92, 246, 0.12) 0%, transparent 50%),
        radial-gradient(ellipse at 50% 50%, rgba(20, 184, 166, 0.1) 0%, transparent 50%);
    pointer-events: none;
    z-index: -1;
    animation: gradientMove 15s ease infinite alternate;
}

@keyframes gradientMove {
    0% { opacity: 1; transform: scale(1); }
    100% { opacity: 0.8; transform: scale(1.1); }
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

ul, ol {
    list-style: none;
}

button {
    cursor: pointer;
    border: none;
    outline: none;
    font-family: inherit;
    background: none;
}

input, textarea, select {
    font-family: inherit;
    outline: none;
}

/* ============================================
   Glass Card Component - Light Theme
   ============================================ */
.glass-card {
    background: var(--bg-glass);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-lg);
    transition: var(--transition);
    box-shadow: var(--shadow-card);
}

.glass-card:hover {
    background: var(--bg-glass-light);
    border-color: var(--border-glass-light);
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.glass-card-heavy {
    background: var(--bg-glass-strong);
    backdrop-filter: var(--glass-blur-heavy);
    -webkit-backdrop-filter: var(--glass-blur-heavy);
    border: 1px solid var(--border-glass-light);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-md);
}

/* ============================================
   Header / Navbar - Glass Effect
   ============================================ */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--header-height);
    background: rgba(255, 255, 255, 0.75);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border-bottom: 1px solid rgba(59, 130, 246, 0.1);
    z-index: 1000;
    display: flex;
    align-items: center;
    padding: 0 30px;
    box-shadow: 0 4px 30px rgba(59, 130, 246, 0.08);
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    max-width: 1600px;
    margin: 0 auto;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
}

/* Logo Image - Ensure visibility */
.logo img,
.logo-img {
    height: 45px !important;
    width: auto !important;
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
}

.logo-icon {
    width: 45px;
    height: 45px;
    background: var(--gradient-primary);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    font-weight: 800;
    color: white;
    box-shadow: var(--shadow-glow);
}

.logo-text {
    font-family: 'Poppins', sans-serif;
    font-size: 26px;
    font-weight: 700;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 8px;
}

.nav-link {
    padding: 10px 20px;
    border-radius: var(--radius-full);
    font-weight: 500;
    font-size: 15px;
    color: var(--text-secondary);
    transition: var(--transition);
}

.nav-link:hover,
.nav-link.active {
    color: var(--primary);
    background: rgba(59, 130, 246, 0.1);
}

.nav-link.active {
    background: var(--gradient-primary);
    color: white;
    box-shadow: var(--shadow-sm);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 15px;
}

.header-search {
    position: relative;
}

.header-search input {
    width: 280px;
    padding: 12px 20px 12px 45px;
    background: rgba(255, 255, 255, 0.8);
    border: 1px solid rgba(59, 130, 246, 0.2);
    border-radius: var(--radius-full);
    color: var(--text-primary);
    font-size: 14px;
    transition: var(--transition);
}

.header-search input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-glow);
    background: white;
}

.header-search input::placeholder {
    color: var(--text-muted);
}

.header-search i {
    position: absolute;
    left: 18px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
}

.icon-btn {
    width: 44px;
    height: 44px;
    border-radius: var(--radius-full);
    background: rgba(255, 255, 255, 0.8);
    border: 1px solid rgba(59, 130, 246, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
    position: relative;
    transition: var(--transition);
}

.icon-btn:hover {
    background: white;
    color: var(--primary);
    border-color: var(--primary);
    box-shadow: var(--shadow-sm);
}

.icon-btn .badge {
    position: absolute;
    top: -2px;
    right: -2px;
    width: 20px;
    height: 20px;
    background: var(--error);
    border-radius: var(--radius-full);
    font-size: 11px;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
}

.user-menu {
    position: relative;
}

.user-avatar {
    width: 44px;
    height: 44px;
    border-radius: var(--radius-full);
    background: var(--gradient-primary);
    border: 2px solid var(--border-glass);
    cursor: pointer;
    overflow: hidden;
    transition: var(--transition);
}

.user-avatar:hover {
    border-color: var(--primary);
    transform: scale(1.05);
}

.user-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* User Dropdown Menu - Light Glass */
.dropdown-menu {
    position: absolute;
    top: 100%;
    right: 0;
    margin-top: 10px;
    min-width: 250px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: 1px solid rgba(59, 130, 246, 0.15);
    border-radius: var(--radius-lg);
    box-shadow: 0 20px 50px rgba(59, 130, 246, 0.15);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: var(--transition);
    z-index: 1000;
    overflow: hidden;
}

.dropdown-menu.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 15px;
    background: rgba(59, 130, 246, 0.05);
    border-bottom: 1px solid rgba(59, 130, 246, 0.1);
}

.dropdown-header img {
    width: 45px;
    height: 45px;
    border-radius: var(--radius-full);
    object-fit: cover;
    border: 2px solid var(--primary);
}

.dropdown-header strong {
    display: block;
    font-size: 14px;
    color: var(--text-primary);
    margin-bottom: 2px;
}

.dropdown-header span {
    font-size: 12px;
    color: var(--text-muted);
    text-transform: capitalize;
}

.dropdown-divider {
    height: 1px;
    background: rgba(59, 130, 246, 0.1);
    margin: 5px 0;
}

.dropdown-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 15px;
    color: var(--text-secondary);
    font-size: 14px;
    transition: var(--transition);
    text-decoration: none;
}

.dropdown-item:hover {
    background: rgba(59, 130, 246, 0.08);
    color: var(--primary);
}

.dropdown-item i {
    width: 18px;
    text-align: center;
    font-size: 14px;
}

.dropdown-item.text-error {
    color: var(--error);
}

.dropdown-item.text-error:hover {
    background: rgba(239, 68, 68, 0.1);
}

/* ============================================
   Sidebar - Light Glass
   ============================================ */
.sidebar {
    position: fixed;
    left: 0;
    top: var(--header-height);
    width: var(--sidebar-width);
    height: calc(100vh - var(--header-height));
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border-right: 1px solid rgba(59, 130, 246, 0.1);
    padding: 20px 15px;
    overflow-y: auto;
    z-index: 900;
    transition: var(--transition);
    box-shadow: 4px 0 30px rgba(59, 130, 246, 0.05);
}

.sidebar::-webkit-scrollbar {
    width: 5px;
}

.sidebar::-webkit-scrollbar-track {
    background: transparent;
}

.sidebar::-webkit-scrollbar-thumb {
    background: var(--border-glass);
    border-radius: var(--radius-full);
}

/* AI Recommendations Scrollable Container */
.ai-courses-container::-webkit-scrollbar,
#aiRecommendResults::-webkit-scrollbar {
    width: 6px;
}

.ai-courses-container::-webkit-scrollbar-track,
#aiRecommendResults::-webkit-scrollbar-track {
    background: rgba(0,0,0,0.05);
    border-radius: 10px;
}

.ai-courses-container::-webkit-scrollbar-thumb,
#aiRecommendResults::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    border-radius: 10px;
}

.ai-courses-container::-webkit-scrollbar-thumb:hover,
#aiRecommendResults::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, #4f46e5, #7c3aed);
}

.ai-courses-container {
    scrollbar-width: thin;
    scrollbar-color: #6366f1 rgba(0,0,0,0.05);
}

#aiRecommendResults {
    scrollbar-width: thin;
    scrollbar-color: #6366f1 rgba(0,0,0,0.05);
}

.sidebar-section {
    margin-bottom: 25px;
}

.sidebar-title {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--text-muted);
    padding: 0 15px;
    margin-bottom: 10px;
}

.sidebar-menu {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.sidebar-link {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px 15px;
    border-radius: var(--radius-md);
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 500;
    transition: var(--transition);
}

.sidebar-link i {
    width: 20px;
    font-size: 18px;
}

.sidebar-link:hover {
    background: var(--bg-glass);
    color: var(--text-primary);
}

.sidebar-link.active {
    background: var(--gradient-primary);
    color: white;
    box-shadow: var(--shadow-glow);
}

.sidebar-link .badge {
    margin-left: auto;
    padding: 2px 8px;
    background: var(--error);
    border-radius: var(--radius-full);
    font-size: 11px;
    font-weight: 600;
    color: white;
}

/* AI Assistant Widget in Sidebar */
.ai-widget {
    background: var(--gradient-glow);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-lg);
    padding: 20px;
    margin-top: 20px;
}

.ai-widget-icon {
    width: 50px;
    height: 50px;
    background: var(--gradient-primary);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    margin-bottom: 15px;
    box-shadow: var(--shadow-glow);
}

.ai-widget h4 {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 8px;
}

.ai-widget p {
    font-size: 13px;
    color: var(--text-secondary);
    margin-bottom: 15px;
}

.ai-widget .btn {
    width: 100%;
}

/* ============================================
   Main Content Area
   ============================================ */
.main-content {
    margin-left: var(--sidebar-width);
    margin-top: var(--header-height);
    padding: 30px;
    min-height: calc(100vh - var(--header-height));
}

.main-content.full-width {
    margin-left: 0;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
}

/* ============================================
   Buttons - Light Glass Theme
   ============================================ */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 12px 28px;
    border-radius: var(--radius-full);
    font-weight: 600;
    font-size: 14px;
    transition: var(--transition);
    cursor: pointer;
    border: none;
    outline: none;
}

.btn-primary {
    background: var(--gradient-primary);
    color: white;
    box-shadow: 0 4px 15px rgba(59, 130, 246, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(59, 130, 246, 0.4);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.8);
    color: var(--text-primary);
    border: 1px solid rgba(59, 130, 246, 0.2);
    backdrop-filter: blur(10px);
}

.btn-secondary:hover {
    background: white;
    border-color: var(--primary);
    color: var(--primary);
}

.btn-outline {
    background: transparent;
    color: var(--primary);
    border: 2px solid var(--primary);
}

.btn-outline:hover {
    background: var(--primary);
    color: white;
    box-shadow: 0 4px 15px rgba(59, 130, 246, 0.3);
}

.btn-success {
    background: linear-gradient(135deg, #22c55e 0%, #16a34a 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(34, 197, 94, 0.3);
}

.btn-success:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(34, 197, 94, 0.4);
}

.btn-danger {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(239, 68, 68, 0.3);
}

.btn-danger:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(239, 68, 68, 0.4);
}

.btn-lg {
    padding: 16px 36px;
    font-size: 16px;
}

.btn-sm {
    padding: 8px 18px;
    font-size: 13px;
}

.btn-icon {
    width: 44px;
    height: 44px;
    padding: 0;
    border-radius: var(--radius-full);
}

/* ============================================
   Form Elements - Light Glass
   ============================================ */
.form-group {
    margin-bottom: 20px;
}

.form-label {
    display: block;
    font-size: 14px;
    font-weight: 500;
    color: var(--text-secondary);
    margin-bottom: 8px;
}

.form-control {
    width: 100%;
    padding: 14px 18px;
    background: rgba(255, 255, 255, 0.8);
    border: 1px solid rgba(59, 130, 246, 0.2);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-size: 15px;
    transition: var(--transition);
    backdrop-filter: blur(10px);
}

.form-control:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
    background: white;
}

.form-control::placeholder {
    color: var(--text-muted);
}

textarea.form-control {
    min-height: 120px;
    resize: vertical;
}

.form-select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%233b82f6' viewBox='0 0 16 16'%3E%3Cpath d='M8 11L3 6h10l-5 5z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 15px center;
    padding-right: 45px;
}

.form-check {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
}

.form-check input {
    width: 20px;
    height: 20px;
    accent-color: var(--primary);
}

/* ============================================
   Cards - Light Glass Theme
   ============================================ */
.card {
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: 1px solid rgba(255, 255, 255, 0.8);
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: var(--transition);
    box-shadow: 0 8px 32px rgba(59, 130, 246, 0.08);
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(59, 130, 246, 0.15);
    border-color: rgba(59, 130, 246, 0.3);
    background: rgba(255, 255, 255, 0.85);
}

.card-img {
    width: 100%;
    height: 140px;
    object-fit: cover;
}

.card-body {
    padding: 15px;
}

.card-title {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 10px;
    line-height: 1.4;
    color: var(--text-primary);
}

.card-text {
    font-size: 14px;
    color: var(--text-secondary);
    margin-bottom: 15px;
}

.card-meta {
    display: flex;
    align-items: center;
    gap: 15px;
    font-size: 13px;
    color: var(--text-muted);
}

.card-price {
    display: flex;
    align-items: center;
    gap: 10px;
}

.card-price .current {
    font-size: 20px;
    font-weight: 700;
    color: var(--primary);
}

.card-price .original {
    font-size: 14px;
    color: var(--text-muted);
    text-decoration: line-through;
}

/* Course Card */
.course-card {
    position: relative;
}

.course-card .badge-featured {
    position: absolute;
    top: 15px;
    left: 15px;
    padding: 6px 12px;
    background: var(--gradient-primary);
    border-radius: var(--radius-full);
    font-size: 11px;
    font-weight: 600;
    color: white;
    z-index: 2;
}

.course-card .badge-bestseller {
    position: absolute;
    top: 15px;
    right: 15px;
    padding: 6px 12px;
    background: var(--warning);
    border-radius: var(--radius-full);
    font-size: 11px;
    font-weight: 600;
    color: white;
    z-index: 2;
}

/* ============================================
   Modern Course Cards - Featured Section
   ============================================ */
.featured-courses-section {
    padding: 60px 0;
    background: linear-gradient(135deg, #fafafa 0%, #f5f5f5 100%);
}

.courses-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 25px;
}

@media (max-width: 992px) {
    .courses-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 576px) {
    .courses-grid {
        grid-template-columns: 1fr;
    }
}

.course-card-modern {
    background: #fff;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.course-card-modern:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(239, 68, 68, 0.15);
}

.course-card-image {
    position: relative;
    height: 220px;
    overflow: hidden;
    display: block;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
}

.course-card-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    transition: transform 0.5s ease;
}

.course-card-modern:hover .course-card-image img {
    transform: scale(1.05);
}

/* Play icon for course card */
.course-card-image .play-icon {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: var(--primary);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    box-shadow: 0 10px 30px rgba(239, 68, 68, 0.4);
}

.course-card-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.7) 0%, transparent 50%);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.course-card-modern:hover .course-card-overlay {
    opacity: 1;
}

.btn-play {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: var(--primary);
    border: none;
    color: white;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transform: scale(0.8);
    transition: all 0.3s ease;
    box-shadow: 0 10px 30px rgba(239, 68, 68, 0.4);
}

.btn-play:hover {
    transform: scale(1);
    background: var(--primary-dark);
}

.btn-play i {
    margin-left: 3px;
}

.course-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: white;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 5px;
    box-shadow: 0 4px 15px rgba(245, 158, 11, 0.4);
    z-index: 2;
}

.course-badge i {
    font-size: 10px;
}

.course-card-content {
    padding: 20px;
}

.course-category {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(239, 68, 68, 0.1);
    color: var(--primary);
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    margin-bottom: 12px;
}

.course-category i {
    font-size: 11px;
}

.course-card-title {
    font-size: 16px;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.4;
    margin-bottom: 15px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 44px;
}

.course-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 15px;
    border-top: 1px solid #f0f0f0;
}

.course-stats {
    display: flex;
    gap: 15px;
}

.course-stats span {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 13px;
    color: var(--text-muted);
}

.course-stats i {
    font-size: 12px;
    color: var(--primary);
}

.btn-enroll {
    background: var(--gradient-primary);
    color: white;
    border: none;
    padding: 8px 18px;
    border-radius: 25px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(239, 68, 68, 0.3);
}

.btn-enroll:hover {
    transform: translateX(5px);
    box-shadow: 0 6px 20px rgba(239, 68, 68, 0.4);
}

.btn-enroll i {
    font-size: 11px;
    transition: transform 0.3s ease;
}

.btn-enroll:hover i {
    transform: translateX(3px);
}

/* ============================================
   End Modern Course Cards
   ============================================ */

.course-rating {
    display: flex;
    align-items: center;
    gap: 5px;
}

.course-rating i {
    color: var(--warning);
    font-size: 14px;
}

.course-rating span {
    font-weight: 600;
    color: var(--text-primary);
}

.course-instructor {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid var(--border-glass);
}

.course-instructor img {
    width: 32px;
    height: 32px;
    border-radius: var(--radius-full);
    object-fit: cover;
}

.course-instructor span {
    font-size: 13px;
    color: var(--text-secondary);
}

/* ============================================
   Hero Section - Image Slider
   ============================================ */
.hero-slider {
    position: relative;
    width: 100%;
    height: 100vh;
    min-height: 650px;
    overflow: hidden;
    margin-top: 0;
    padding-top: 0;
}

@media (max-width: 768px) {
    .hero-slider {
        height: 85vh;
        min-height: 550px;
        padding-bottom: 120px;
    }
    
    .slide {
        background-size: cover !important;
        background-position: top center !important;
    }
}

.slider-container {
    position: relative;
    width: 100%;
    height: 100%;
}

.slides {
    position: relative;
    width: 100%;
    height: 100%;
}

.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: top center;
    background-repeat: no-repeat;
    background-color: #1a1a2e;
    opacity: 0;
    transition: opacity 1s ease-in-out;
}

/* Ensure slide images fill container properly */
.slide::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: inherit;
    background-size: cover;
    background-position: top center;
}

@media (max-width: 992px) {
    .slide {
        background-size: cover;
        background-position: center center;
    }
}

.slide.active {
    opacity: 1;
    z-index: 1;
}

.slide-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to right, rgba(0, 0, 0, 0.6) 0%, rgba(0, 0, 0, 0.3) 50%, rgba(0, 0, 0, 0.1) 100%);
    z-index: 1;
}

@media (max-width: 768px) {
    .slide-overlay {
        background: linear-gradient(to bottom, rgba(0, 0, 0, 0.5) 0%, rgba(0, 0, 0, 0.2) 100%);
    }
}

.slide-content {
    position: absolute;
    top: 50%;
    left: 0;
    transform: translateY(-50%);
    padding: 0 8%;
    padding-top: 40px;
    max-width: 650px;
    color: white;
    z-index: 2;
}

@media (max-width: 768px) {
    .slide-content {
        top: 50%;
        padding: 0 5%;
        padding-top: 60px;
        max-width: 100%;
    }
}

.slide-badge {
    display: inline-block;
    padding: 10px 24px;
    background: var(--primary);
    color: white;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
    border-radius: 4px;
    margin-bottom: 25px;
}

@media (max-width: 768px) {
    .slide-badge {
        padding: 8px 16px;
        font-size: 10px;
        letter-spacing: 1px;
        margin-bottom: 15px;
    }
}

.slide-content h1 {
    font-family: 'Poppins', sans-serif;
    font-size: 46px;
    font-weight: 700;
    line-height: 1.15;
    margin-bottom: 15px;
    color: white;
    text-shadow: 2px 2px 10px rgba(0,0,0,0.4);
}

@media (max-width: 768px) {
    .slide-content h1 {
        font-size: 24px;
        line-height: 1.3;
        margin-bottom: 12px;
    }
}

.slide-content p {
    font-size: 16px;
    line-height: 1.7;
    color: rgba(255, 255, 255, 0.95);
    margin-bottom: 25px;
    max-width: 500px;
}

@media (max-width: 768px) {
    .slide-content p {
        font-size: 14px;
        line-height: 1.5;
        margin-bottom: 20px;
        max-width: 100%;
    }
}

.slide-buttons {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

@media (max-width: 768px) {
    .slide-buttons {
        flex-direction: column;
        gap: 10px;
    }
    
    .slide-buttons .btn {
        width: 100%;
        justify-content: center;
        padding: 12px 20px;
    }
}

.slide-buttons .btn-primary {
    padding: 14px 32px;
    font-size: 15px;
}

.btn-outline-white {
    padding: 14px 32px;
    border: 2px solid white;
    color: white;
    background: transparent;
    border-radius: 5px;
    font-weight: 600;
    font-size: 15px;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
}

.btn-outline-white:hover {
    background: white;
    color: var(--secondary);
}

/* Slider Navigation */
.slider-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 55px;
    height: 55px;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(5px);
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    color: white;
    font-size: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
}

.slider-nav:hover {
    background: var(--primary);
    border-color: var(--primary);
    transform: translateY(-50%) scale(1.1);
}

.slider-nav.prev {
    left: 30px;
}

.slider-nav.next {
    right: 30px;
}

/* Slider Dots */
.slider-dots {
    position: absolute;
    bottom: 130px;
    right: 50px;
    left: auto;
    transform: none;
    display: flex;
    gap: 10px;
    z-index: 10;
}

.dot {
    width: 14px;
    height: 14px;
    background: rgba(255, 255, 255, 0.4);
    border: 2px solid rgba(255, 255, 255, 0.6);
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
}

.dot.active,
.dot:hover {
    background: var(--primary);
    border-color: var(--primary);
    transform: scale(1.2);
}

/* Hero Stats Bar */
.hero-stats-bar {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(15px);
    padding: 28px 0;
    z-index: 10;
    box-shadow: 0 -5px 30px rgba(0, 0, 0, 0.1);
}

@media (max-width: 768px) {
    .hero-stats-bar {
        position: relative;
        padding: 20px 15px;
    }
}

.stats-row {
    display: flex;
    justify-content: center;
    gap: 80px;
    flex-wrap: wrap;
}

@media (max-width: 768px) {
    .stats-row {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 20px;
        text-align: center;
    }
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 15px;
}

@media (max-width: 768px) {
    .stat-item {
        flex-direction: column;
        gap: 8px;
        justify-content: center;
    }
}

.stat-item i {
    font-size: 36px;
    color: var(--primary);
}

@media (max-width: 768px) {
    .stat-item i {
        font-size: 28px;
    }
}

.stat-item .stat-number {
    font-size: 30px;
    font-weight: 700;
    color: var(--secondary);
    display: block;
    line-height: 1;
}

.stat-item .stat-text {
    font-size: 14px;
    color: var(--text-muted);
    margin-top: 3px;
}

/* Responsive Hero Slider */
@media (max-width: 1200px) {
    .slide-content h1 {
        font-size: 44px;
    }
    
    .stats-row {
        gap: 50px;
    }
}

@media (max-width: 991px) {
    .hero-slider {
        height: 85vh;
        min-height: 550px;
    }
    
    .slide-content {
        padding: 0 5%;
        max-width: 90%;
    }
    
    .slide-content h1 {
        font-size: 38px;
    }
    
    .slide-content p {
        font-size: 15px;
    }
    
    .slider-nav {
        width: 45px;
        height: 45px;
        font-size: 16px;
    }
    
    .slider-nav.prev { left: 15px; }
    .slider-nav.next { right: 15px; }
    
    .stats-row {
        gap: 30px;
        padding: 0 20px;
    }
    
    .stat-item .stat-number {
        font-size: 24px;
    }
    
    .stat-item i {
        font-size: 28px;
    }
}

@media (max-width: 768px) {
    .hero-slider {
        height: auto;
        min-height: 100vh;
    }
    
    .slide-content {
        padding: 100px 20px 150px;
        max-width: 100%;
        position: relative;
        top: auto;
        transform: none;
    }
    
    .slide-content h1 {
        font-size: 32px;
    }
    
    .slide-content p {
        font-size: 14px;
        margin-bottom: 25px;
    }
    
    .slide-buttons {
        flex-direction: column;
    }
    
    .slide-buttons .btn,
    .btn-outline-white {
        width: 100%;
        justify-content: center;
        padding: 12px 24px;
    }
    
    .slider-dots {
        bottom: 140px;
    }
    
    .slider-nav {
        display: none;
    }
    
    .hero-stats-bar {
        padding: 20px 0;
    }
    
    .stats-row {
        gap: 20px;
        justify-content: space-around;
    }
    
    .stat-item {
        flex-direction: column;
        text-align: center;
        gap: 8px;
        min-width: 70px;
    }
    
    .stat-item i {
        font-size: 24px;
    }
    
    .stat-item .stat-number {
        font-size: 20px;
    }
    
    .stat-item .stat-text {
        font-size: 11px;
    }
}

/* Old Hero (kept for compatibility) */
.hero {
    padding: 80px 0;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(ellipse at center, rgba(239, 68, 68, 0.15) 0%, transparent 70%);
    animation: rotate 30s linear infinite;
}

@keyframes rotate {
    100% { transform: rotate(360deg); }
}

.hero-content {
    position: relative;
    z-index: 1;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 20px;
    background: rgba(255, 255, 255, 0.8);
    border: 1px solid rgba(239, 68, 68, 0.2);
    border-radius: var(--radius-full);
    font-size: 14px;
    color: var(--text-secondary);
    margin-bottom: 30px;
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 15px rgba(239, 68, 68, 0.1);
}

.hero-badge i {
    color: var(--primary);
}

.hero h1 {
    font-family: 'Poppins', sans-serif;
    font-size: 56px;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 20px;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero p {
    font-size: 20px;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto 40px;
}

.hero-buttons {
    display: flex;
    justify-content: center;
    gap: 15px;
    flex-wrap: wrap;
}

.hero-stats {
    display: flex;
    justify-content: center;
    gap: 60px;
    margin-top: 60px;
}

.hero-stat {
    text-align: center;
    padding: 20px 30px;
    background: rgba(255, 255, 255, 0.6);
    border-radius: var(--radius-lg);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.8);
}

.hero-stat-value {
    font-size: 36px;
    font-weight: 700;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-stat-label {
    font-size: 14px;
    color: var(--text-secondary);
    margin-top: 5px;
}

/* ============================================
   Section Styles
   ============================================ */
.section {
    padding: 80px 0;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 40px;
}

.section-title {
    font-family: 'Poppins', sans-serif;
    font-size: 32px;
    font-weight: 700;
}

.section-subtitle {
    color: var(--text-secondary);
    margin-top: 10px;
}

/* ============================================
   Grid Layouts
   ============================================ */
.grid {
    display: grid;
    gap: 25px;
}

.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

@media (max-width: 1200px) {
    .grid-4 { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 992px) {
    .grid-4, .grid-3 { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
    .grid-4, .grid-3, .grid-2 { grid-template-columns: 1fr; }
}

/* ============================================
   AI Chat Widget
   ============================================ */
.ai-chat-widget {
    position: fixed;
    bottom: 100px;
    right: 20px;
    z-index: 1001;
}

@media (max-width: 768px) {
    .ai-chat-widget {
        bottom: 85px;
        right: 15px;
        z-index: 9980; /* Below mobile bottom nav (9990) */
    }
}

.ai-chat-btn {
    width: 55px;
    height: 55px;
    border-radius: var(--radius-full);
    background: var(--gradient-primary);
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    color: white;
    cursor: pointer;
    box-shadow: var(--shadow-glow);
    transition: var(--transition);
}

.ai-chat-btn:hover {
    transform: scale(1.1);
    box-shadow: 0 10px 40px rgba(99, 102, 241, 0.5);
}

.ai-chat-box {
    position: absolute;
    bottom: 80px;
    right: 0;
    width: 380px;
    height: 500px;
    background: var(--bg-glass-light);
    backdrop-filter: var(--glass-blur-heavy);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-xl);
    display: none;
    flex-direction: column;
    overflow: hidden;
    box-shadow: var(--shadow-xl);
}

.ai-chat-box.active {
    display: flex;
    animation: slideUp 0.3s ease;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.ai-chat-header {
    padding: 20px;
    background: var(--gradient-primary);
    display: flex;
    align-items: center;
    gap: 12px;
}

.ai-chat-header img {
    width: 45px;
    height: 45px;
    border-radius: var(--radius-full);
    border: 2px solid rgba(255,255,255,0.3);
}

.ai-chat-header-info h4 {
    color: white;
    font-size: 16px;
    font-weight: 600;
}

.ai-chat-header-info span {
    font-size: 12px;
    color: rgba(255,255,255,0.8);
}

.ai-chat-close {
    margin-left: auto;
    width: 32px;
    height: 32px;
    border-radius: var(--radius-full);
    background: rgba(255,255,255,0.2);
    border: none;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.ai-chat-close:hover {
    background: rgba(255,255,255,0.3);
}

.ai-chat-messages {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.ai-message {
    max-width: 85%;
    padding: 12px 16px;
    border-radius: var(--radius-lg);
    font-size: 14px;
    line-height: 1.5;
}

.ai-message.bot {
    background: var(--bg-glass);
    border: 1px solid var(--border-glass);
    align-self: flex-start;
}

.ai-message.user {
    background: var(--gradient-primary);
    color: white;
    align-self: flex-end;
}

.ai-chat-input {
    padding: 15px 20px;
    border-top: 1px solid var(--border-glass);
    display: flex;
    gap: 10px;
}

.ai-chat-input input {
    flex: 1;
    padding: 12px 16px;
    background: var(--bg-glass);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-full);
    color: var(--text-primary);
    font-size: 14px;
}

.ai-chat-input input:focus {
    border-color: var(--primary);
}

.ai-chat-input button {
    width: 44px;
    height: 44px;
    border-radius: var(--radius-full);
    background: var(--gradient-primary);
    border: none;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.ai-chat-input button:hover {
    transform: scale(1.05);
}

/* ============================================
   Statistics Cards
   ============================================ */
.stat-card {
    background: var(--bg-glass);
    backdrop-filter: var(--glass-blur);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-lg);
    padding: 25px;
    display: flex;
    align-items: center;
    gap: 20px;
    transition: var(--transition);
}

.stat-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}

.stat-icon {
    width: 60px;
    height: 60px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 26px;
}

.stat-icon.primary {
    background: rgba(99, 102, 241, 0.15);
    color: var(--primary);
}

.stat-icon.success {
    background: rgba(16, 185, 129, 0.15);
    color: var(--success);
}

.stat-icon.warning {
    background: rgba(245, 158, 11, 0.15);
    color: var(--warning);
}

.stat-icon.info {
    background: rgba(6, 182, 212, 0.15);
    color: var(--accent);
}

.stat-content h3 {
    font-size: 28px;
    font-weight: 700;
}

.stat-content p {
    font-size: 14px;
    color: var(--text-secondary);
    margin-top: 5px;
}

.stat-trend {
    margin-left: auto;
    padding: 4px 10px;
    border-radius: var(--radius-full);
    font-size: 12px;
    font-weight: 600;
}

.stat-trend.up {
    background: rgba(16, 185, 129, 0.15);
    color: var(--success);
}

.stat-trend.down {
    background: rgba(239, 68, 68, 0.15);
    color: var(--error);
}

/* ============================================
   Tables
   ============================================ */
.table-container {
    background: var(--bg-glass);
    backdrop-filter: var(--glass-blur);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-lg);
    overflow: hidden;
}

.table {
    width: 100%;
    border-collapse: collapse;
}

.table th {
    background: var(--bg-glass);
    padding: 16px 20px;
    text-align: left;
    font-size: 13px;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 1px solid var(--border-glass);
}

.table td {
    padding: 16px 20px;
    border-bottom: 1px solid var(--border-glass);
    font-size: 14px;
}

.table tr:last-child td {
    border-bottom: none;
}

.table tr:hover td {
    background: var(--bg-glass);
}

/* ============================================
   Badges
   ============================================ */
.badge {
    display: inline-flex;
    align-items: center;
    padding: 4px 12px;
    border-radius: var(--radius-full);
    font-size: 12px;
    font-weight: 600;
}

.badge-primary {
    background: rgba(99, 102, 241, 0.15);
    color: var(--primary);
}

.badge-success {
    background: rgba(16, 185, 129, 0.15);
    color: var(--success);
}

.badge-warning {
    background: rgba(245, 158, 11, 0.15);
    color: var(--warning);
}

.badge-danger {
    background: rgba(239, 68, 68, 0.15);
    color: var(--error);
}

.badge-info {
    background: rgba(6, 182, 212, 0.15);
    color: var(--accent);
}

/* ============================================
   Alerts
   ============================================ */
.alert {
    padding: 16px 20px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
}

.alert-success {
    background: rgba(16, 185, 129, 0.15);
    border: 1px solid rgba(16, 185, 129, 0.3);
    color: var(--success);
}

.alert-error {
    background: rgba(239, 68, 68, 0.15);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: var(--error);
}

.alert-warning {
    background: rgba(245, 158, 11, 0.15);
    border: 1px solid rgba(245, 158, 11, 0.3);
    color: var(--warning);
}

.alert-info {
    background: rgba(99, 102, 241, 0.15);
    border: 1px solid rgba(99, 102, 241, 0.3);
    color: var(--primary);
}

/* ============================================
   Modal
   ============================================ */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(5px);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 2000;
}

.modal-overlay.active {
    display: flex;
}

.modal {
    background: var(--bg-glass-light);
    backdrop-filter: var(--glass-blur-heavy);
    border: 1px solid var(--border-glass);
    border-radius: var(--radius-xl);
    width: 100%;
    max-width: 500px;
    max-height: 90vh;
    overflow: hidden;
    animation: modalSlide 0.3s ease;
}

@keyframes modalSlide {
    from {
        opacity: 0;
        transform: scale(0.95) translateY(-20px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.modal-header {
    padding: 20px 25px;
    border-bottom: 1px solid var(--border-glass);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.modal-header h3 {
    font-size: 18px;
    font-weight: 600;
}

.modal-close {
    width: 36px;
    height: 36px;
    border-radius: var(--radius-full);
    background: var(--bg-glass);
    border: 1px solid var(--border-glass);
    color: var(--text-secondary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.modal-close:hover {
    background: var(--error);
    color: white;
    border-color: var(--error);
}

.modal-body {
    padding: 25px;
    overflow-y: auto;
}

.modal-footer {
    padding: 20px 25px;
    border-top: 1px solid var(--border-glass);
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

/* ============================================
   Footer - Light Glass
   ============================================ */
.footer {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border-top: 1px solid rgba(59, 130, 246, 0.1);
    padding: 60px 0 30px;
    margin-top: 80px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr repeat(3, 1fr);
    gap: 40px;
    margin-bottom: 40px;
}

.footer-brand .logo {
    margin-bottom: 20px;
}

.footer-brand p {
    color: var(--text-secondary);
    font-size: 14px;
    line-height: 1.7;
    margin-bottom: 20px;
}

.footer-social {
    display: flex;
    gap: 12px;
}

.footer-social a {
    width: 40px;
    height: 40px;
    border-radius: var(--radius-full);
    background: rgba(255, 255, 255, 0.8);
    border: 1px solid rgba(59, 130, 246, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
    transition: var(--transition);
}

.footer-social a:hover {
    background: var(--gradient-primary);
    color: white;
    border-color: transparent;
    box-shadow: 0 4px 15px rgba(59, 130, 246, 0.3);
}

.footer-links h4 {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 20px;
    color: var(--text-primary);
}

.footer-links ul {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.footer-links a {
    color: var(--text-secondary);
    font-size: 14px;
    transition: var(--transition);
}

.footer-links a:hover {
    color: var(--primary);
}

.footer-bottom {
    padding-top: 30px;
    border-top: 1px solid rgba(59, 130, 246, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.footer-bottom p {
    color: var(--text-muted);
    font-size: 14px;
}

/* ============================================
   Responsive Design
   ============================================ */
@media (max-width: 1024px) {
    .sidebar {
        transform: translateX(-100%);
    }
    
    .sidebar.active {
        transform: translateX(0);
    }
    
    .main-content {
        margin-left: 0;
    }
    
    .header-search {
        display: none;
    }
}

@media (max-width: 768px) {
    .header {
        padding: 0 20px;
    }
    
    .nav-menu {
        display: none;
    }
    
    .hero h1 {
        font-size: 36px;
    }
    
    .hero-stats {
        flex-direction: column;
        gap: 30px;
    }
    
    .footer-grid {
        grid-template-columns: 1fr;
    }
    
    .ai-chat-box {
        width: calc(100vw - 40px);
        right: -10px;
    }
}

/* ============================================
   Animations
   ============================================ */
@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

@keyframes spin {
    100% { transform: rotate(360deg); }
}

@keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.animate-pulse { animation: pulse 2s infinite; }
.animate-spin { animation: spin 1s linear infinite; }
.animate-bounce { animation: bounce 1s infinite; }

/* Loading Skeleton */
.skeleton {
    background: linear-gradient(90deg, var(--bg-glass) 25%, var(--bg-glass-light) 50%, var(--bg-glass) 75%);
    background-size: 200% 100%;
    animation: skeleton-loading 1.5s infinite;
    border-radius: var(--radius-sm);
}

@keyframes skeleton-loading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* Typing Animation for AI */
.typing-indicator {
    display: flex;
    gap: 5px;
    padding: 15px;
}

.typing-indicator span {
    width: 8px;
    height: 8px;
    background: var(--primary);
    border-radius: var(--radius-full);
    animation: typing 1.4s infinite both;
}

.typing-indicator span:nth-child(2) { animation-delay: 0.2s; }
.typing-indicator span:nth-child(3) { animation-delay: 0.4s; }

@keyframes typing {
    0% { transform: translateY(0); }
    50% { transform: translateY(-5px); }
    100% { transform: translateY(0); }
}

/* ============================================
   Utility Classes
   ============================================ */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.text-primary { color: var(--primary); }
.text-success { color: var(--success); }
.text-error { color: var(--error); }
.text-warning { color: var(--warning); }
.text-muted { color: var(--text-muted); }

.bg-primary { background: var(--primary); }
.bg-glass { background: var(--bg-glass); }

.d-flex { display: flex; }
.d-grid { display: grid; }
.d-none { display: none; }
.d-block { display: block; }

.flex-center { align-items: center; justify-content: center; }
.flex-between { justify-content: space-between; }
.flex-wrap { flex-wrap: wrap; }
.gap-10 { gap: 10px; }
.gap-20 { gap: 20px; }
.gap-30 { gap: 30px; }

.mt-10 { margin-top: 10px; }
.mt-20 { margin-top: 20px; }
.mt-30 { margin-top: 30px; }
.mb-10 { margin-bottom: 10px; }
.mb-20 { margin-bottom: 20px; }
.mb-30 { margin-bottom: 30px; }

.p-20 { padding: 20px; }
.p-30 { padding: 30px; }

.w-100 { width: 100%; }
.h-100 { height: 100%; }

.rounded { border-radius: var(--radius-md); }
.rounded-lg { border-radius: var(--radius-lg); }
.rounded-full { border-radius: var(--radius-full); }

.overflow-hidden { overflow: hidden; }
.overflow-auto { overflow: auto; }

.cursor-pointer { cursor: pointer; }
.user-select-none { user-select: none; }

/* ============================================
   Sidebar Toggle Button
   ============================================ */
.sidebar-toggle {
    position: fixed;
    top: 20px;
    left: 20px;
    width: 45px;
    height: 45px;
    background: var(--gradient-primary);
    border-radius: var(--radius-md);
    border: none;
    display: none !important; /* Hidden on desktop */
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 18px;
    z-index: 1001;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
    cursor: pointer;
}

/* Show sidebar toggle only on mobile/tablet */
@media (max-width: 768px) {
    .sidebar-toggle {
        display: flex !important;
    }
}

.sidebar-toggle:hover {
    transform: scale(1.05);
    box-shadow: var(--shadow-lg);
}

.sidebar {
    position: fixed;
    top: 0;
    left: -300px;
    width: 280px;
    height: 100vh;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: var(--glass-blur-heavy);
    -webkit-backdrop-filter: var(--glass-blur-heavy);
    border-right: 1px solid rgba(59, 130, 246, 0.1);
    z-index: 9999;
    display: flex;
    flex-direction: column;
    transition: left 0.3s ease;
    box-shadow: var(--shadow-xl);
}

.sidebar.active {
    left: 0;
}

.sidebar-header {
    padding: 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid rgba(59, 130, 246, 0.1);
}

.sidebar-logo {
    display: flex;
    align-items: center;
    gap: 10px;
}

.sidebar-logo span {
    font-family: 'Poppins', sans-serif;
    font-size: 22px;
    font-weight: 700;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.sidebar-close {
    width: 35px;
    height: 35px;
    background: rgba(239, 68, 68, 0.1);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--error);
    font-size: 16px;
    cursor: pointer;
    transition: var(--transition);
}

.sidebar-close:hover {
    background: var(--error);
    color: white;
}

.sidebar-nav {
    flex: 1;
    padding: 20px 15px;
    overflow-y: auto;
}

.sidebar-link {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 14px 18px;
    border-radius: var(--radius-md);
    color: var(--text-secondary);
    font-weight: 500;
    font-size: 15px;
    margin-bottom: 5px;
    transition: var(--transition);
}

.sidebar-link i {
    width: 22px;
    font-size: 18px;
    text-align: center;
}

.sidebar-link:hover {
    background: rgba(59, 130, 246, 0.1);
    color: var(--primary);
    transform: translateX(5px);
}

.sidebar-link.active {
    background: var(--gradient-primary);
    color: white;
    box-shadow: var(--shadow-md);
}

.sidebar-footer {
    padding: 20px;
    border-top: 1px solid rgba(59, 130, 246, 0.1);
    background: rgba(59, 130, 246, 0.03);
}

.sidebar-contact {
    margin-bottom: 15px;
}

.sidebar-contact p {
    font-size: 13px;
    color: var(--text-secondary);
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.sidebar-contact p i {
    color: var(--primary);
    width: 16px;
}

.sidebar-social {
    display: flex;
    gap: 10px;
}

.sidebar-social a {
    width: 36px;
    height: 36px;
    background: rgba(59, 130, 246, 0.1);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    font-size: 14px;
    transition: var(--transition);
}

.sidebar-social a:hover {
    background: var(--gradient-primary);
    color: white;
    transform: translateY(-2px);
}

.sidebar-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 9998;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
}

.sidebar-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* Adjust header when sidebar is shown */
@media (max-width: 768px) {
    .nav-menu {
        display: none;
    }
    
    .header-search {
        display: none;
    }
    
    .header {
        padding-left: 70px;
    }
}

/* ============================================
   Mobile Bottom Navigation
   ============================================ */
.mobile-bottom-nav {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.1);
    z-index: 9990;
    padding: 8px 0;
    padding-bottom: calc(8px + env(safe-area-inset-bottom));
    border-top: 1px solid rgba(0, 0, 0, 0.05);
}

@media (max-width: 768px) {
    .mobile-bottom-nav {
        display: flex;
    }
    
    /* Add padding to body for bottom nav */
    body {
        padding-bottom: 70px;
    }
    
    .footer {
        margin-bottom: 70px;
    }
}

.mobile-bottom-nav-items {
    display: flex;
    justify-content: space-around;
    align-items: center;
    width: 100%;
    max-width: 500px;
    margin: 0 auto;
}

.mobile-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 6px 12px;
    color: var(--text-muted);
    text-decoration: none;
    font-size: 10px;
    font-weight: 500;
    transition: all 0.2s ease;
    border-radius: 12px;
    min-width: 60px;
    position: relative;
}

.mobile-nav-item i {
    font-size: 20px;
    margin-bottom: 4px;
    transition: all 0.2s ease;
}

.mobile-nav-item span {
    font-size: 10px;
    line-height: 1;
}

.mobile-nav-item:hover,
.mobile-nav-item.active {
    color: var(--primary);
}

.mobile-nav-item.active {
    background: rgba(239, 68, 68, 0.1);
}

.mobile-nav-item.active i {
    transform: scale(1.1);
}

/* Center button (Enroll/Plus) */
.mobile-nav-item.center-btn {
    background: var(--gradient-primary);
    color: white;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    margin-top: -30px;
    box-shadow: 0 4px 15px rgba(239, 68, 68, 0.4);
    padding: 0;
    min-width: auto;
}

.mobile-nav-item.center-btn i {
    font-size: 22px;
    margin-bottom: 0;
}

.mobile-nav-item.center-btn span {
    display: none;
}

.mobile-nav-item.center-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 20px rgba(239, 68, 68, 0.5);
    color: white;
    background: var(--gradient-primary);
}

/* Badge on mobile nav */
.mobile-nav-item .nav-badge {
    position: absolute;
    top: 0;
    right: 5px;
    background: var(--primary);
    color: white;
    font-size: 10px;
    font-weight: 600;
    min-width: 18px;
    height: 18px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 4px;
}

/* ============================================
   Enhanced Mobile Responsiveness
   ============================================ */
@media (max-width: 992px) {
    .container {
        padding: 0 15px;
    }
    
    .section {
        padding: 40px 0;
    }
    
    .section-header {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    
    .section-title {
        font-size: 24px;
    }
    
    .grid-4 {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .grid-3 {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    /* Header mobile adjustments */
    .header {
        padding: 10px 15px;
        padding-left: 65px;
    }
    
    .header-content {
        gap: 10px;
    }
    
    .header-actions {
        gap: 8px;
    }
    
    .header-actions .btn {
        padding: 8px 12px;
        font-size: 12px;
    }
    
    .logo-img {
        height: 35px !important;
    }
    
    /* Sidebar toggle for mobile */
    .sidebar-toggle {
        top: 12px;
        left: 10px;
        width: 40px;
        height: 40px;
        font-size: 16px;
    }
    
    /* Hero section mobile */
    .hero-slider {
        min-height: 500px;
        height: 70vh;
    }
    
    .slide-content h1 {
        font-size: 24px;
        line-height: 1.3;
    }
    
    .slide-content p {
        font-size: 14px;
    }
    
    .slide-buttons {
        flex-direction: column;
        gap: 10px;
    }
    
    .slide-buttons .btn {
        width: 100%;
    }
    
    /* Stats bar mobile */
    .hero-stats-bar {
        padding: 15px 0;
    }
    
    .stats-row {
        flex-wrap: wrap;
        gap: 15px;
        justify-content: center;
    }
    
    .stat-item {
        flex: 0 0 45%;
        font-size: 12px;
    }
    
    .stat-number {
        font-size: 18px;
    }
    
    /* Section headers mobile */
    .section-header .btn {
        font-size: 12px;
        padding: 8px 16px;
    }
    
    /* Cards mobile */
    .grid-4, .grid-3, .grid-2 {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .courses-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .course-card-modern {
        margin: 0 5px;
    }
    
    .course-card-image {
        height: 200px;
    }
    
    .course-card-image img {
        object-fit: contain;
        object-position: center;
    }
    
    .course-card-image .play-icon {
        width: 50px;
        height: 50px;
        font-size: 16px;
    }
    
    .course-card-content {
        padding: 15px;
    }
    
    .course-card-title {
        font-size: 15px;
        min-height: auto;
    }
    
    .course-card-footer {
        flex-direction: column;
        gap: 12px;
        align-items: stretch;
    }
    
    .course-stats {
        justify-content: center;
    }
    
    .btn-enroll {
        justify-content: center;
        width: 100%;
    }
    
    /* Glass cards mobile */
    .glass-card, .glass-card-heavy {
        padding: 20px !important;
    }
    
    /* Footer mobile */
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 30px;
        text-align: center;
    }
    
    .footer-brand {
        text-align: center;
    }
    
    .footer-social {
        justify-content: center;
    }
    
    .footer-links ul {
        padding: 0;
    }
    
    .footer-bottom {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    
    /* AI chat mobile */
    .ai-chat-box {
        width: calc(100vw - 20px);
        right: 10px;
        bottom: 85px;
        max-height: 60vh;
    }
    
    /* Modal mobile */
    .modal {
        width: 95%;
        max-width: none;
        margin: 10px;
        max-height: 90vh;
    }
    
    .modal-body {
        padding: 15px;
    }
    
    /* Form controls mobile */
    .form-control {
        padding: 12px 15px;
        font-size: 16px; /* Prevents zoom on iOS */
    }
    
    /* Enrollment modal mobile */
    .enroll-modal .modal {
        max-width: 100%;
        width: 100%;
        margin: 0;
        border-radius: 20px 20px 0 0;
        max-height: 85vh;
        position: fixed;
        bottom: 0;
        top: auto;
    }
    
    .enroll-modal .modal-body {
        max-height: calc(85vh - 60px);
        overflow-y: auto;
    }
    
    .form-row {
        grid-template-columns: 1fr !important;
    }
}

@media (max-width: 480px) {
    /* Extra small screens */
    .section-title {
        font-size: 20px;
    }
    
    .section-subtitle {
        font-size: 13px;
    }
    
    .hero-slider {
        min-height: 450px;
    }
    
    .slide-content {
        padding: 15px;
    }
    
    .slide-content h1 {
        font-size: 20px;
    }
    
    .slide-badge {
        font-size: 10px;
        padding: 6px 12px;
    }
    
    .stat-item {
        flex: 0 0 100%;
    }
    
    /* Categories grid */
    .grid[style*="minmax(180px"] {
        grid-template-columns: repeat(2, 1fr) !important;
    }
    
    .stat-icon {
        width: 50px !important;
        height: 50px !important;
        font-size: 20px !important;
    }
}

/* Safe area for notched phones */
@supports (padding: max(0px)) {
    .mobile-bottom-nav {
        padding-bottom: max(8px, env(safe-area-inset-bottom));
    }
    
    body {
        padding-bottom: max(70px, calc(70px + env(safe-area-inset-bottom)));
    }
}

/* Landscape mode adjustments */
@media (max-height: 500px) and (orientation: landscape) {
    .hero-slider {
        min-height: 400px;
        height: 100vh;
    }
    
    .mobile-bottom-nav {
        padding: 5px 0;
    }
    
    .mobile-nav-item {
        padding: 4px 10px;
    }
    
    .mobile-nav-item i {
        font-size: 18px;
    }
    
    .mobile-nav-item.center-btn {
        width: 48px;
        height: 48px;
        margin-top: -20px;
    }
}