/* ========================================
   Admin Styles - VC Don Bosco
   ======================================== */

/* Login Page */
.admin-login-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
}

.login-container {
    width: 100%;
    max-width: 400px;
    padding: 20px;
}

.login-box {
    background: var(--accent);
    border-radius: var(--radius);
    padding: 40px;
    box-shadow: var(--shadow-lg);
}

.login-header {
    text-align: center;
    margin-bottom: 30px;
}

.login-header h1 {
    color: var(--primary);
    font-size: 1.8rem;
    margin-bottom: 5px;
}

.login-header p {
    color: var(--text-light);
}

.login-footer {
    text-align: center;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid var(--bg-alt);
}

.login-footer a {
    color: var(--text-light);
    font-size: 0.9rem;
}

/* Admin Layout */
.admin-body {
    background: var(--bg);
}

.admin-wrapper {
    display: flex;
    min-height: 100vh;
}

/* Sidebar */
.admin-sidebar {
    width: 260px;
    background: var(--primary-dark);
    color: var(--accent);
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    z-index: 100;
}

.sidebar-header {
    padding: 25px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.sidebar-logo {
    color: var(--accent);
    display: flex;
    flex-direction: column;
}

.sidebar-logo span {
    font-size: 1.3rem;
    font-weight: 700;
}

.sidebar-logo small {
    font-size: 0.8rem;
    color: var(--secondary);
}

.sidebar-nav {
    flex: 1;
    padding: 20px 0;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 20px;
    color: rgba(255, 255, 255, 0.7);
    transition: var(--transition);
    border-left: 3px solid transparent;
}

.nav-item:hover {
    background: rgba(255, 255, 255, 0.05);
    color: var(--accent);
}

.nav-item.active {
    background: rgba(255, 255, 255, 0.1);
    color: var(--secondary);
    border-left-color: var(--secondary);
}

.nav-item svg {
    flex-shrink: 0;
}

.sidebar-footer {
    padding: 20px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.nav-item.logout:hover {
    background: rgba(229, 62, 62, 0.2);
    color: #fc8181;
}

/* Main Content */
.admin-main {
    flex: 1;
    margin-left: 260px;
    padding: 30px;
}

.admin-content h1 {
    color: var(--primary);
    font-size: 1.8rem;
    margin-bottom: 5px;
}

.admin-content .subtitle {
    color: var(--text-light);
    margin-bottom: 30px;
}

/* Stats Cards */
.stats-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: var(--accent);
    border-radius: var(--radius);
    padding: 25px;
    display: flex;
    align-items: center;
    gap: 20px;
    box-shadow: var(--shadow);
}

.stat-icon {
    width: 60px;
    height: 60px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent);
}

.stat-info h3 {
    font-size: 2rem;
    color: var(--primary);
    margin-bottom: 5px;
}

.stat-info p {
    color: var(--text-light);
    font-size: 0.9rem;
}

/* Dashboard Grid */
.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 20px;
}

.dashboard-card {
    background: var(--accent);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    overflow: hidden;
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid var(--bg-alt);
}

.card-header h2 {
    font-size: 1.1rem;
    color: var(--primary);
}

.btn-link {
    color: var(--secondary);
    font-size: 0.9rem;
    font-weight: 500;
}

.card-body {
    padding: 20px;
}

.empty-state {
    text-align: center;
    color: var(--text-light);
    padding: 20px;
}

/* Simple List */
.simple-list {
    list-style: none;
}

.simple-list li {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid var(--bg-alt);
}

.simple-list li:last-child {
    border-bottom: none;
}

.list-info strong {
    display: block;
    color: var(--text);
    margin-bottom: 3px;
}

.list-info span {
    font-size: 0.85rem;
    color: var(--text-light);
}

/* Badges */
.badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
}

.badge-primary {
    background: var(--primary);
    color: var(--accent);
}

.badge-warning {
    background: #fef3c7;
    color: #92400e;
}

.badge-success {
    background: #d1fae5;
    color: #065f46;
}

.badge-danger {
    background: #fee2e2;
    color: #991b1b;
}

/* Data Table */
.data-table {
    width: 100%;
    border-collapse: collapse;
}

.data-table th,
.data-table td {
    padding: 15px;
    text-align: left;
    border-bottom: 1px solid var(--bg-alt);
}

.data-table th {
    background: var(--bg-alt);
    color: var(--primary);
    font-weight: 600;
    font-size: 0.9rem;
}

.data-table tr:hover {
    background: var(--bg);
}

/* Action Buttons */
.action-btns {
    display: flex;
    gap: 8px;
}

.btn-sm {
    padding: 6px 12px;
    font-size: 0.85rem;
    border-radius: 6px;
}

.btn-success {
    background: var(--success);
    color: var(--accent);
}

.btn-danger {
    background: var(--error);
    color: var(--accent);
}

.btn-info {
    background: #0066CC;
    color: var(--accent);
}

/* Page Header */
.page-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.page-actions h1 {
    margin-bottom: 0;
}

/* Filters */
.filters {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.filters select,
.filters input {
    padding: 10px 15px;
    border: 2px solid var(--bg-alt);
    border-radius: var(--radius);
    font-size: 0.9rem;
}

/* Modal */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    display: none;
}

.modal-overlay.active {
    display: flex;
}

.modal {
    background: var(--accent);
    border-radius: var(--radius);
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
}

.modal-header {
    padding: 20px;
    border-bottom: 1px solid var(--bg-alt);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h2 {
    color: var(--primary);
    font-size: 1.2rem;
}

.modal-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-light);
}

.modal-body {
    padding: 20px;
}

.modal-footer {
    padding: 20px;
    border-top: 1px solid var(--bg-alt);
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

/* Responsive */
@media (max-width: 992px) {
    .admin-sidebar {
        width: 80px;
    }
    
    .sidebar-logo span,
    .sidebar-logo small,
    .nav-item span {
        display: none;
    }
    
    .nav-item {
        justify-content: center;
        padding: 15px;
    }
    
    .admin-main {
        margin-left: 80px;
    }
    
    .dashboard-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .admin-sidebar {
        display: none;
    }
    
    .admin-main {
        margin-left: 0;
        padding: 20px;
    }
    
    .stats-cards {
        grid-template-columns: 1fr 1fr;
    }
}
