/**
 * MODUL TEMA & MODERN DASHBOARD ELEVISION
 * Elearning Pesantren Amanah Muhammadiyah
 * Mendukung 6 Tema Berbeda: ANBK, Pesantren, Indigo, Maroon, Dark, Classic
 */

/* ==========================================
   1. ROOT VARIABLES & THEME DEFINITIONS
   ========================================== */

/* DEFAULT / TEMA 1: ANBK / UNBK NAVY */
:root, .theme-anbk {
    --theme-primary: #173d6b;
    --theme-primary-dark: #0f243e;
    --theme-primary-light: #205493;
    --theme-accent: #f39c12;
    --theme-accent-hover: #d68910;
    --theme-bg: #f0f3f8;
    --theme-card-bg: #ffffff;
    --theme-text: #1e293b;
    --theme-text-muted: #64748b;
    --theme-navbar-gradient: linear-gradient(135deg, #0e223d 0%, #173d6b 100%);
    --theme-hero-gradient: linear-gradient(135deg, #102a4d 0%, #1b4d89 60%, #205a9e 100%);
}

/* TEMA 2: PESANTREN HIJAU (ISLAMIC EMERALD) */
.theme-pesantren {
    --theme-primary: #065f46;
    --theme-primary-dark: #064e3b;
    --theme-primary-light: #047857;
    --theme-accent: #10b981;
    --theme-accent-hover: #059669;
    --theme-bg: #f0fdf4;
    --theme-card-bg: #ffffff;
    --theme-text: #132a1c;
    --theme-text-muted: #4b6354;
    --theme-navbar-gradient: linear-gradient(135deg, #064e3b 0%, #065f46 60%, #047857 100%);
    --theme-hero-gradient: linear-gradient(135deg, #064e3b 0%, #047857 60%, #059669 100%);
}

/* TEMA 3: MODERN INDIGO (TECH BLUE) */
.theme-indigo {
    --theme-primary: #4338ca;
    --theme-primary-dark: #1e1b4b;
    --theme-primary-light: #4f46e5;
    --theme-accent: #818cf8;
    --theme-accent-hover: #6366f1;
    --theme-bg: #f5f3ff;
    --theme-card-bg: #ffffff;
    --theme-text: #1e1b4b;
    --theme-text-muted: #6b7280;
    --theme-navbar-gradient: linear-gradient(135deg, #1e1b4b 0%, #3730a3 50%, #4f46e5 100%);
    --theme-hero-gradient: linear-gradient(135deg, #312e81 0%, #4338ca 60%, #6366f1 100%);
}

/* TEMA 4: MUHAMMADIYAH MAROON (CRIMSON) */
.theme-maroon {
    --theme-primary: #991b1b;
    --theme-primary-dark: #7f1d1d;
    --theme-primary-light: #b91c1c;
    --theme-accent: #f87171;
    --theme-accent-hover: #ef4444;
    --theme-bg: #fef2f2;
    --theme-card-bg: #ffffff;
    --theme-text: #450a0a;
    --theme-text-muted: #7f1d1d;
    --theme-navbar-gradient: linear-gradient(135deg, #7f1d1d 0%, #991b1b 60%, #b91c1c 100%);
    --theme-hero-gradient: linear-gradient(135deg, #7f1d1d 0%, #991b1b 60%, #dc2626 100%);
}

/* TEMA 5: DARK MODE (CYBER NIGHT) */
.theme-dark {
    --theme-primary: #1e293b;
    --theme-primary-dark: #0f172a;
    --theme-primary-light: #334155;
    --theme-accent: #38bdf8;
    --theme-accent-hover: #0ea5e9;
    --theme-bg: #090d16;
    --theme-card-bg: #111827;
    --theme-text: #f1f5f9;
    --theme-text-muted: #94a3b8;
    --theme-navbar-gradient: linear-gradient(135deg, #0a0f1d 0%, #0f172a 60%, #1e293b 100%);
    --theme-hero-gradient: linear-gradient(135deg, #0f172a 0%, #1e293b 60%, #334155 100%);
}
.theme-dark body {
    background-color: #090d16 !important;
    color: #e2e8f0 !important;
}
.theme-dark .well,
.theme-dark .module,
.theme-dark .widget-menu,
.theme-dark .table {
    background-color: #111827 !important;
    color: #f1f5f9 !important;
    border-color: #1f2937 !important;
}
.theme-dark .table th {
    background-color: #1f2937 !important;
    color: #38bdf8 !important;
    border-color: #374151 !important;
}
.theme-dark .table td {
    border-color: #1f2937 !important;
    color: #cbd5e1 !important;
}

/* TEMA 6: CLASSIC LIGHT */
.theme-classic {
    --theme-primary: #2c3e50;
    --theme-primary-dark: #1a252f;
    --theme-primary-light: #34495e;
    --theme-accent: #3498db;
    --theme-accent-hover: #2980b9;
    --theme-bg: #f8f9fa;
    --theme-card-bg: #ffffff;
    --theme-text: #2c3e50;
    --theme-text-muted: #7f8c8d;
    --theme-navbar-gradient: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
    --theme-hero-gradient: linear-gradient(135deg, #2c3e50 0%, #34495e 60%, #4a6572 100%);
}

/* ==========================================
   2. NAVBAR INTEGRATION
   ========================================== */
.navbar .navbar-inner {
    background: var(--theme-navbar-gradient) !important;
    border-bottom: 3px solid var(--theme-accent) !important;
    box-shadow: 0 3px 12px rgba(0, 0, 0, 0.25) !important;
    min-height: 52px;
}
.navbar .brand .brand-txt {
    color: #ffffff !important;
    font-size: 18px;
    font-weight: 700;
}
.navbar .nav > li > a {
    color: #f0f4f9 !important;
    font-weight: 600;
}
.navbar .nav > li > a:hover {
    color: var(--theme-accent) !important;
}

/* DROPDOWN TEMA DI NAVBAR */
.theme-picker-menu {
    border-radius: 8px !important;
    box-shadow: 0 8px 25px rgba(0,0,0,0.2) !important;
    border: 1px solid #dce2eb !important;
}
.theme-picker-menu li a {
    padding: 8px 16px !important;
    display: flex !important;
    align-items: center;
    font-weight: 600;
    font-size: 13px;
    color: #334155 !important;
    transition: all 0.15s ease;
}
.theme-picker-menu li a:hover {
    background-color: #f1f5f9 !important;
    color: var(--theme-primary) !important;
}
.theme-dot {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    display: inline-block;
    margin-right: 10px;
    flex-shrink: 0;
}

/* ==========================================
   3. CLEAN & MODERN SIDEBAR (FIX GELAP)
   ========================================== */
.widget-menu {
    background: #ffffff !important;
    border-radius: 8px !important;
    border: 1px solid #e2e8f0 !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04) !important;
    margin-bottom: 20px !important;
    overflow: hidden !important;
}
.widget-menu > li + li {
    border-top: 1px solid #f1f5f9 !important;
}
.widget-menu > li > a {
    background-color: #ffffff !important;
    color: #334155 !important;
    font-weight: 600 !important;
    font-size: 13.5px !important;
    padding: 12px 18px !important;
    border-left: 4px solid transparent !important;
    transition: all 0.2s ease !important;
    text-shadow: none !important;
}
.widget-menu > li > a .menu-icon {
    color: var(--theme-primary) !important;
    font-size: 16px !important;
    margin-right: 10px !important;
    transition: transform 0.2s;
}
.widget-menu > li > a:hover {
    background-color: #f8fafc !important;
    color: var(--theme-primary) !important;
    border-left: 4px solid var(--theme-accent) !important;
    padding-left: 22px !important;
}
.widget-menu > li > a:hover .menu-icon {
    transform: scale(1.15);
}
.widget-menu .label {
    border-radius: 12px !important;
    font-size: 11px !important;
    padding: 3px 8px !important;
    font-weight: 700 !important;
    box-shadow: none !important;
}

/* ==========================================
   4. DASHBOARD HERO BANNER (KEKINIAN)
   ========================================== */
.dash-hero-card {
    background: var(--theme-hero-gradient);
    border-radius: 12px;
    color: #ffffff;
    padding: 25px 30px;
    margin-bottom: 25px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
    position: relative;
    overflow: hidden;
}
.dash-hero-card::after {
    content: "";
    position: absolute;
    top: -50px;
    right: -50px;
    width: 250px;
    height: 250px;
    background: radial-gradient(circle, rgba(255,255,255,0.15) 0%, rgba(255,255,255,0) 70%);
    border-radius: 50%;
    pointer-events: none;
}
.dash-hero-title {
    font-size: 24px;
    font-weight: 800;
    color: #ffffff;
    line-height: 1.25;
    margin: 0 0 8px 0;
    text-shadow: 0 2px 4px rgba(0,0,0,0.15);
}
.dash-hero-sub {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.9);
    margin: 0 0 15px 0;
    line-height: 1.5;
}
.dash-hero-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}
.dash-chip {
    background: rgba(255, 255, 255, 0.18);
    backdrop-filter: blur(5px);
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 20px;
    padding: 4px 12px;
    font-size: 12px;
    font-weight: 600;
    color: #ffffff;
    display: inline-flex;
    align-items: center;
}
.dash-chip i {
    margin-right: 6px;
    color: var(--theme-accent);
}
.dash-hero-actions {
    margin-top: 18px;
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}
.btn-hero-action {
    background: rgba(255, 255, 255, 0.95);
    color: var(--theme-primary) !important;
    border: none !important;
    font-weight: 700;
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 13px;
    box-shadow: 0 3px 8px rgba(0,0,0,0.15);
    transition: all 0.2s ease;
}
.btn-hero-action:hover {
    background: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 5px 14px rgba(0,0,0,0.25);
    color: var(--theme-primary-dark) !important;
}

/* ==========================================
   5. MODERN STAT CARDS (4 KARTU KEKINIAN)
   ========================================== */
.dash-stats-row {
    margin-bottom: 25px;
}
.dash-stat-card {
    border-radius: 12px;
    padding: 22px 20px;
    color: #ffffff;
    position: relative;
    overflow: hidden;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.08);
    transition: all 0.25s ease;
    display: block;
    text-decoration: none !important;
}
.dash-stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.16);
    color: #ffffff !important;
}
.dash-stat-card::after {
    content: "";
    position: absolute;
    right: -20px;
    bottom: -20px;
    width: 110px;
    height: 110px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    pointer-events: none;
}
.dash-stat-icon {
    position: absolute;
    right: 20px;
    top: 22px;
    font-size: 44px;
    color: rgba(255, 255, 255, 0.3);
    transition: transform 0.25s;
}
.dash-stat-card:hover .dash-stat-icon {
    transform: scale(1.15) rotate(5deg);
    color: rgba(255, 255, 255, 0.45);
}
.dash-stat-label {
    font-size: 13px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 4px;
}
.dash-stat-number {
    font-size: 32px;
    font-weight: 900;
    line-height: 1.1;
    margin: 4px 0 8px 0;
    color: #ffffff;
}
.dash-stat-footer {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.85);
    display: flex;
    align-items: center;
}
.dash-stat-footer i {
    margin-right: 5px;
}

/* GRADIENTS 4 KARTU STATISTIK */
.stat-card-1 {
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
}
.stat-card-2 {
    background: linear-gradient(135deg, #059669 0%, #10b981 100%);
}
.stat-card-3 {
    background: linear-gradient(135deg, #d97706 0%, #f59e0b 100%);
}
.stat-card-4 {
    background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%);
}

/* ==========================================
   6. QUICK SHORTCUT TILES
   ========================================== */
.dash-shortcuts-card {
    background: #ffffff;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    padding: 18px 22px;
    margin-bottom: 25px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}
.dash-section-title {
    font-size: 15px;
    font-weight: 700;
    color: #1e293b;
    margin: 0 0 14px 0;
    display: flex;
    align-items: center;
}
.dash-section-title i {
    color: var(--theme-accent);
    margin-right: 8px;
    font-size: 17px;
}
.shortcut-btn {
    display: flex;
    align-items: center;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 12px 16px;
    color: #1e293b !important;
    text-decoration: none !important;
    font-weight: 600;
    font-size: 13.5px;
    transition: all 0.2s ease;
    margin-bottom: 10px;
}
.shortcut-btn i {
    font-size: 20px;
    margin-right: 12px;
    color: var(--theme-primary);
    transition: transform 0.2s;
}
.shortcut-btn:hover {
    background: #ffffff;
    border-color: var(--theme-accent);
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    transform: translateY(-2px);
    color: var(--theme-primary) !important;
}
.shortcut-btn:hover i {
    transform: scale(1.2);
    color: var(--theme-accent);
}

/* ==========================================
   7. MODERN WIDGET PANELS
   ========================================== */
.dash-widget {
    background: #ffffff;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    box-shadow: 0 2px 10px rgba(0,0,0,0.04);
    margin-bottom: 25px;
    overflow: hidden;
}
.dash-widget-head {
    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
    padding: 14px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.dash-widget-head h4 {
    margin: 0;
    font-size: 15px;
    font-weight: 700;
    color: #1e293b;
    display: flex;
    align-items: center;
}
.dash-widget-head h4 i {
    margin-right: 8px;
    color: var(--theme-primary);
}
.dash-widget-body {
    padding: 15px 20px;
}
.dash-list-item {
    padding: 10px 0;
    border-bottom: 1px solid #f1f5f9;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.dash-list-item:last-child {
    border-bottom: none;
}
.dash-list-item a {
    color: #334155;
    font-weight: 600;
    text-decoration: none;
    transition: color 0.15s;
}
.dash-list-item a:hover {
    color: var(--theme-primary);
}

/* ==========================================
   8. MOBILE RESPONSIVE & PWA ENHANCEMENTS
   ========================================== */
@media (max-width: 767px) {
    /* Responsive Table Container */
    .table-responsive {
        width: 100%;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        margin-bottom: 15px;
        border: 1px solid #e2e8f0;
        border-radius: 8px;
    }
    
    /* Make standard tables inside widgets scrollable smoothly */
    .module-body > table,
    .content > table,
    .module-body table.table {
        display: block;
        width: 100%;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    /* PWA safe area support for iOS / Android with notches */
    body {
        padding-bottom: calc(20px + env(safe-area-inset-bottom, 0px));
    }
    
    .navbar-fixed-top {
        padding-top: env(safe-area-inset-top, 0px);
    }
    
    /* Optimize buttons for touch */
    .btn {
        padding: 6px 12px;
        touch-action: manipulation;
    }
    
    /* Stat cards on mobile: 2 per row or 1 per row */
    .stat-card-modern {
        margin-bottom: 12px;
    }
    
    /* Pop-up chat button safe spacing on mobile */
    #fb-chat-trigger-btn {
        bottom: calc(16px + env(safe-area-inset-bottom, 0px)) !important;
        right: 16px !important;
    }
    
    #pwaInstallBanner {
        bottom: calc(16px + env(safe-area-inset-bottom, 0px)) !important;
    }
}


/* ========================================================
   MODERN PUBLIC & AUTHENTICATION PORTAL (LOGIN PAGE V2)
   ======================================================== */

.public-body {
    background-color: var(--theme-bg, #f0f3f8);
    background-image: 
        radial-gradient(circle at 10% 20%, rgba(23, 61, 107, 0.05) 0%, transparent 45%),
        radial-gradient(circle at 90% 80%, rgba(243, 156, 18, 0.06) 0%, transparent 45%),
        radial-gradient(circle at 50% 50%, rgba(16, 185, 129, 0.03) 0%, transparent 60%);
    min-height: 100vh;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

.public-wrapper {
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    padding: 25px 0 40px !important;
}

/* Modern Top Navbar */
.modern-public-navbar {
    border-bottom: 1px solid rgba(226, 232, 240, 0.8) !important;
    box-shadow: 0 4px 20px -5px rgba(0, 0, 0, 0.05) !important;
}

.modern-public-navbar .navbar-inner {
    background: rgba(255, 255, 255, 0.95) !important;
    backdrop-filter: blur(12px) !important;
    -webkit-backdrop-filter: blur(12px) !important;
    border: none !important;
    padding: 8px 0 !important;
}

.modern-public-navbar .brand {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 16px;
    font-weight: 700;
    color: var(--theme-primary, #173d6b) !important;
    text-shadow: none !important;
    padding: 5px 15px;
}

.modern-public-navbar .brand img {
    height: 38px;
    width: auto;
    object-fit: contain;
}

.modern-public-navbar .nav > li > a {
    color: #475569 !important;
    font-weight: 600;
    font-size: 13.5px;
    border-radius: 8px;
    transition: all 0.2s ease;
    padding: 8px 16px;
    text-shadow: none !important;
}

.modern-public-navbar .nav > li > a:hover {
    color: var(--theme-primary, #173d6b) !important;
    background: rgba(23, 61, 107, 0.06) !important;
}

/* Portal Container Card */
.login-portal-card {
    background: #ffffff;
    border-radius: 24px;
    box-shadow: 0 25px 50px -12px rgba(15, 23, 42, 0.15), 0 0 0 1px rgba(226, 232, 240, 0.8);
    overflow: hidden;
    margin: 15px auto 35px;
    max-width: 1060px;
    display: flex;
    flex-wrap: wrap;
    transition: all 0.3s ease;
}

/* Hero Branding (Left Side) */
.login-hero-side {
    background: var(--theme-hero-gradient, linear-gradient(135deg, #102a4d 0%, #173d6b 60%, #205493 100%));
    color: #ffffff;
    padding: 45px 40px;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    box-sizing: border-box;
    width: 54%;
}

.login-hero-side::before {
    content: '';
    position: absolute;
    top: -50px;
    right: -50px;
    width: 320px;
    height: 320px;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.12) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}

.login-hero-side::after {
    content: '';
    position: absolute;
    bottom: -60px;
    left: -60px;
    width: 280px;
    height: 280px;
    background: radial-gradient(circle, rgba(243, 156, 18, 0.18) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}

.login-brand-pill {
    display: inline-flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.25);
    padding: 6px 14px;
    border-radius: 30px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    color: #ffffff;
    margin-bottom: 25px;
    width: fit-content;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.login-brand-pill .pill-dot {
    width: 8px;
    height: 8px;
    background: #10b981;
    border-radius: 50%;
    margin-right: 8px;
    box-shadow: 0 0 8px #10b981;
}

.login-school-banner {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 28px;
    position: relative;
    z-index: 2;
}

.login-logo-circle {
    width: 70px;
    height: 70px;
    background: #ffffff;
    border-radius: 18px;
    padding: 8px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.login-logo-circle img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.login-school-text h1 {
    font-size: 23px;
    font-weight: 800;
    line-height: 1.25;
    margin: 0 0 5px 0;
    color: #ffffff;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.25);
}

.login-school-text p {
    font-size: 13.5px;
    color: rgba(255, 255, 255, 0.9);
    margin: 0;
    line-height: 1.4;
}

/* Feature items in hero */
.login-features-list {
    margin: 15px 0 25px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    position: relative;
    z-index: 2;
}

.login-feature-card {
    display: flex;
    align-items: center;
    gap: 14px;
    background: rgba(255, 255, 255, 0.09);
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 14px;
    padding: 12px 16px;
    backdrop-filter: blur(4px);
    transition: all 0.25s ease;
}

.login-feature-card:hover {
    background: rgba(255, 255, 255, 0.16);
    transform: translateX(4px);
}

.login-feature-icon {
    width: 38px;
    height: 38px;
    border-radius: 11px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 17px;
    flex-shrink: 0;
}

.login-feature-icon.cbt { background: rgba(56, 189, 248, 0.25); color: #7dd3fc; }
.login-feature-icon.materi { background: rgba(52, 211, 153, 0.25); color: #6ee7b7; }
.login-feature-icon.pwa { background: rgba(251, 191, 36, 0.25); color: #fde047; }

.login-feature-info strong {
    display: block;
    font-size: 13.5px;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 2px;
}

.login-feature-info span {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.78);
    line-height: 1.35;
    display: block;
}

.login-quote-box {
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid rgba(255, 255, 255, 0.16);
    font-size: 12px;
    font-style: italic;
    color: rgba(255, 255, 255, 0.85);
    line-height: 1.5;
    position: relative;
    z-index: 2;
}

/* Form Card (Right Side) */
.login-form-side {
    background: #ffffff;
    padding: 45px 42px;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    justify-content: center;
    width: 46%;
}

.login-form-header {
    margin-bottom: 28px;
}

.login-form-badge {
    width: 46px;
    height: 46px;
    border-radius: 14px;
    background: rgba(23, 61, 107, 0.08);
    color: var(--theme-primary, #173d6b);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    margin-bottom: 14px;
}

.login-form-header h2 {
    font-size: 25px;
    font-weight: 800;
    color: #1e293b;
    margin: 0 0 6px 0;
    letter-spacing: -0.4px;
}

.login-form-header p {
    font-size: 13.5px;
    color: #64748b;
    margin: 0;
}

/* Modern Form Inputs */
.modern-login-form {
    margin: 0;
}

.modern-form-group {
    margin-bottom: 22px;
}

.modern-form-label {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 13px;
    font-weight: 600;
    color: #334155;
    margin-bottom: 8px;
}

.modern-form-label a.forgot-link {
    font-size: 12.5px;
    font-weight: 600;
    color: var(--theme-primary, #173d6b);
    text-decoration: none;
    transition: color 0.2s ease;
}

.modern-form-label a.forgot-link:hover {
    text-decoration: underline;
    color: var(--theme-primary-light, #205493);
}

.modern-input-wrapper {
    position: relative;
    display: block;
    width: 100%;
}

.modern-input-wrapper .input-leading-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 16px;
    color: #94a3b8;
    pointer-events: none;
    z-index: 2;
}

.modern-input-field {
    width: 100% !important;
    height: 48px !important;
    background: #f8fafc !important;
    border: 1.5px solid #e2e8f0 !important;
    border-radius: 12px !important;
    padding: 10px 14px 10px 42px !important;
    font-size: 14px !important;
    color: #1e293b !important;
    box-sizing: border-box !important;
    transition: all 0.2s ease !important;
    box-shadow: none !important;
}

.modern-input-field:focus {
    background: #ffffff !important;
    border-color: var(--theme-primary-light, #205493) !important;
    box-shadow: 0 0 0 4px rgba(32, 84, 147, 0.12) !important;
    outline: none !important;
}

.modern-input-wrapper.has-toggle .modern-input-field {
    padding-right: 44px !important;
}

.btn-toggle-eye {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    border: none;
    padding: 8px;
    font-size: 16px;
    color: #94a3b8;
    cursor: pointer;
    border-radius: 8px;
    z-index: 3;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s ease;
}

.btn-toggle-eye:hover {
    color: #334155;
    background: rgba(0, 0, 0, 0.04);
}

.btn-modern-login {
    width: 100%;
    height: 48px;
    background: var(--theme-navbar-gradient, linear-gradient(135deg, #173d6b 0%, #205493 100%));
    color: #ffffff !important;
    border: none;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 700;
    letter-spacing: 0.4px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    cursor: pointer;
    box-shadow: 0 8px 20px -4px rgba(23, 61, 107, 0.4);
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    margin-top: 10px;
}

.btn-modern-login:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 26px -4px rgba(23, 61, 107, 0.5);
    color: #ffffff;
}

.btn-modern-login:active {
    transform: translateY(0);
}

/* Quick Access Guide Box */
.login-guide-box {
    margin-top: 24px;
    padding: 14px 16px;
    background: #f8fafc;
    border: 1px dashed #cbd5e1;
    border-radius: 12px;
}

.login-guide-title {
    font-size: 11.5px;
    font-weight: 700;
    text-transform: uppercase;
    color: #64748b;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.login-guide-items {
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-size: 12.5px;
    color: #475569;
}

.login-guide-item {
    display: flex;
    align-items: center;
    gap: 8px;
}

.login-guide-item b {
    color: #1e293b;
}

/* Clean Alert styling */
.login-form-side .alert {
    border-radius: 10px;
    font-size: 13.5px;
    padding: 10px 14px;
    margin-bottom: 18px;
}

/* Slider in Hero if exists */
.login-slider-container {
    margin: 15px 0 20px;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.25);
    position: relative;
    z-index: 2;
}

/* RESPONSIVE BREAKPOINTS */
@media (max-width: 900px) {
    .login-hero-side {
        width: 100%;
        padding: 35px 25px;
    }
    .login-form-side {
        width: 100%;
        padding: 35px 25px;
    }
    .login-portal-card {
        margin: 10px 12px 25px;
        border-radius: 18px;
    }
}

@media (max-width: 480px) {
    .login-school-banner {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    .login-school-text h1 {
        font-size: 20px;
    }
    .login-features-list {
        display: none;
    }
    .login-form-side {
        padding: 25px 18px;
    }
}
