/* ==========================================================================
   DASHBOARD STYLES (css/dashboard.css)
   Tema: Elegant Clean (Sinergi dengan Halaman Utama HerAI: Pink & Purple)
   ========================================================================== */

   :root {
    --primary-pink: #FF1493;
    --light-pink: #fff5f8;
    --dark-purple: #4B0082;
    --secondary-purple: #8A2BE2;
    --gray-bg: #f8f9ff;
    --gray-border: #edf2f7;
    --text-dark: #2d3748;
    --text-muted: #718096;
    --success: #2ecc71;
    --danger: #e74c3c;
}

/* --- LAYOUT UTAMA --- */
.dashboard-layout {
    display: flex;
    height: 100vh;
    background: var(--gray-bg);
    font-family: 'Inter', sans-serif;
    overflow: hidden;
}

/* --- SIDEBAR --- */
.sidebar {
    width: 280px;
    background: #ffffff;
    display: flex;
    flex-direction: column;
    padding: 35px 25px;
    z-index: 100;
    box-shadow: 4px 0 30px rgba(0,0,0,0.03);
    border-right: 1px solid var(--gray-border);
}

.sidebar-brand h2 {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 2.2rem;
    font-weight: 800;
    margin: 0;
    letter-spacing: 1px;
    color: var(--dark-purple);
}
.sidebar-brand span { color: var(--primary-pink); }
.sidebar-brand p { font-size: 0.85rem; color: var(--text-muted); margin-top: 5px; margin-bottom: 40px; font-weight: 500; }

.nav-menu { list-style: none; padding: 0; margin: 0; flex: 1; }
.nav-item { margin-bottom: 8px; }

.nav-link {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 14px 20px;
    color: var(--text-muted);
    text-decoration: none;
    border-radius: 12px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.nav-link:hover, .nav-link.active {
    background: var(--light-pink);
    color: var(--primary-pink);
}
.nav-link.active { border-left: 4px solid var(--primary-pink); }
.nav-link i { font-size: 1.2rem; width: 24px; text-align: center; color: #a0aec0; transition: all 0.3s ease; }
.nav-link:hover i, .nav-link.active i { color: var(--primary-pink); }

.nav-link.locked { opacity: 0.6; cursor: not-allowed; }
.nav-link.locked:hover { background: transparent; color: var(--text-muted); }
.nav-link.locked:hover i { color: #a0aec0; }
.badge-soon { margin-left: auto; background: var(--gray-border); font-size: 0.7rem; padding: 4px 10px; border-radius: 20px; color: var(--text-muted); }

.logout-btn { background: #fff5f5; color: var(--danger); margin-top: auto; border: 1px solid #fed7d7; }
.logout-btn i { color: var(--danger); }
.logout-btn:hover { background: var(--danger); color: #fff; }
.logout-btn:hover i { color: #fff; }

/* --- MAIN CONTENT & TOPBAR --- */
.main-content {
    flex: 1;
    padding: 30px 40px;
    overflow-y: auto;
}

.topbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 40px;
}

.page-title { font-family: 'Space Grotesk', sans-serif; color: var(--dark-purple); font-size: 2.2rem; margin: 0 0 8px 0; font-weight: 800; }
.page-subtitle { color: var(--text-muted); margin: 0; font-size: 1rem; font-weight: 500; }

.admin-profile { display: flex; align-items: center; gap: 15px; text-align: right; }
.admin-info h4 { margin: 0; color: var(--dark-purple); font-size: 1rem; }
.admin-info p { margin: 0; color: var(--success); font-size: 0.8rem; font-weight: 600; }
.admin-avatar {
    width: 45px; height: 45px;
    background: var(--light-pink); color: var(--primary-pink);
    border-radius: 50%; display: flex; align-items: center; justify-content: center;
    font-size: 1.2rem; border: 2px solid #ffe4f0;
}

/* --- GLASS PANEL DIBUAT JADI WHITE CARD ELEGAN --- */
.glass-panel {
    background: #ffffff;
    border: 1px solid var(--gray-border);
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.03);
}

/* --- STATS GRID --- */
.stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 25px; margin-bottom: 40px; }
.stat-card { padding: 25px; display: flex; align-items: center; gap: 20px; transition: transform 0.3s ease; }
.stat-card:hover { transform: translateY(-5px); box-shadow: 0 15px 35px rgba(0,0,0,0.06); }

.stat-icon {
    width: 60px; height: 60px; border-radius: 16px;
    display: flex; align-items: center; justify-content: center; font-size: 1.8rem;
}

/* Konversi warna neon ke warna kalem HerAI */
.neon-blue { background: rgba(138, 43, 226, 0.1); color: var(--secondary-purple); }
.neon-purple { background: rgba(75, 0, 130, 0.1); color: var(--dark-purple); }
.neon-pink { background: var(--light-pink); color: var(--primary-pink); }
.neon-green { background: rgba(46, 204, 113, 0.1); color: var(--success); }

.stat-data p { margin: 0 0 5px 0; color: var(--text-muted); font-size: 0.85rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.5px; }
.stat-data h3 { margin: 0; color: var(--dark-purple); font-size: 1.8rem; font-family: 'Space Grotesk', sans-serif; font-weight: 800; }

/* --- TABLE SECTION --- */
.data-section { padding: 30px; }
.table-header { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 20px; margin-bottom: 25px; }
.table-title h3 { margin: 0; color: var(--dark-purple); font-size: 1.4rem; font-family: 'Space Grotesk', sans-serif; font-weight: 800; }
.table-controls { display: flex; gap: 15px; flex-wrap: wrap; }

.search-box { position: relative; display: flex; align-items: center; }
.search-box i { position: absolute; left: 15px; color: var(--text-muted); }
.search-box input {
    padding: 12px 15px 12px 40px;
    border: 1px solid var(--gray-border); border-radius: 12px;
    background: #fafbfe; outline: none; font-family: 'Inter', sans-serif; width: 250px;
    color: var(--text-dark); transition: all 0.3s;
}
.search-box input:focus { border-color: var(--primary-pink); background: #fff; box-shadow: 0 0 0 3px rgba(255, 20, 147, 0.1); }

.cyber-select {
    padding: 12px 20px; border: 1px solid var(--gray-border); border-radius: 12px;
    background: #fafbfe; outline: none; font-family: 'Inter', sans-serif; color: var(--text-dark); cursor: pointer;
}
.cyber-select:focus { border-color: var(--primary-pink); }

.btn-cyber {
    background: var(--primary-pink); color: #fff; border: none; padding: 12px 25px; border-radius: 12px;
    font-weight: 600; cursor: pointer; transition: all 0.3s ease; display: flex; align-items: center; gap: 8px;
}
.btn-cyber:hover { transform: translateY(-2px); box-shadow: 0 6px 20px rgba(255, 20, 147, 0.3); background: #e01081; }

/* Tabel */
.table-responsive { overflow-x: auto; }
.cyber-table { width: 100%; border-collapse: collapse; text-align: left; }
.cyber-table th {
    color: var(--text-muted); font-size: 0.85rem; font-weight: 700;
    text-transform: uppercase; padding: 15px; border-bottom: 2px solid var(--gray-border); background: #fafbfe;
}
.cyber-table th:first-child { border-radius: 12px 0 0 12px; }
.cyber-table th:last-child { border-radius: 0 12px 12px 0; }
.cyber-table td { padding: 18px 15px; border-bottom: 1px solid var(--gray-border); color: var(--text-dark); font-size: 0.95rem; }
.cyber-table tr:last-child td { border-bottom: none; }
.cyber-table tr:hover td { background: #fafbfe; }

/* Status Badges */
.badge { padding: 6px 12px; border-radius: 8px; font-size: 0.8rem; font-weight: 600; display: inline-flex; align-items: center; gap: 6px;}
.badge.pending { background: #fff8e1; color: #f39c12; border: 1px solid #ffecb3;}
.badge.lolos { background: #e8f5e9; color: #2ecc71; border: 1px solid #c8e6c9;}
.badge.gugur { background: #ffebee; color: #e74c3c; border: 1px solid #ffcdd2;}

/* --- MODALS --- */
.modal-overlay {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.6); backdrop-filter: blur(5px);
    z-index: 999; display: none; align-items: center; justify-content: center;
    opacity: 0; transition: opacity 0.3s ease;
}
.modal-overlay.active { display: flex; opacity: 1; }
.modal-content {
    background: #fff; width: 90%; max-width: 650px; border-radius: 24px; position: relative;
    transform: translateY(20px); transition: transform 0.3s ease; overflow: hidden; box-shadow: 0 25px 50px rgba(0,0,0,0.15);
}
.modal-overlay.active .modal-content { transform: translateY(0); }
.modal-header { padding: 25px 30px; border-bottom: 1px solid var(--gray-border); display: flex; justify-content: space-between; align-items: center; background: #fafbfe; }
.modal-header h2 { margin: 0; color: var(--dark-purple); font-size: 1.4rem; font-weight: 800; font-family: 'Space Grotesk', sans-serif;}
.btn-close { background: none; border: none; font-size: 1.5rem; color: var(--text-muted); cursor: pointer; transition: color 0.2s; }
.btn-close:hover { color: var(--primary-pink); }
.modal-body { padding: 30px; max-height: 60vh; overflow-y: auto; color: var(--text-dark); line-height: 1.6; }
.modal-footer { padding: 20px 30px; border-top: 1px solid var(--gray-border); display: flex; justify-content: flex-end; gap: 15px; background: #fafbfe;}

.confirm-icon-wrapper { width: 80px; height: 80px; background: rgba(46, 204, 113, 0.1); border-radius: 50%; display: flex; align-items: center; justify-content: center; margin: 0 auto 20px; }
.confirm-icon-wrapper i { font-size: 3rem; color: var(--success); }

@media (max-width: 992px) {
    .dashboard-layout { flex-direction: column; overflow-y: auto; }
    .sidebar { width: 100%; padding: 20px; flex-direction: row; align-items: center; justify-content: space-between; border-right: none; border-bottom: 1px solid var(--gray-border);}
    .nav-menu { display: none; }
    .sidebar-brand p { margin-bottom: 0; }
    .topbar { flex-direction: column; align-items: flex-start; gap: 20px; }
    .table-controls { width: 100%; }
    .search-box { width: 100%; }
    .search-box input { width: 100%; }
}