:root {
    --admin-bg: #f4f6f9;
    --admin-sidebar-bg: #14213d;
    --admin-sidebar-text: #b8c2d9;
    --admin-sidebar-active: #ffffff;
    --admin-accent: #2f6fed;
    --admin-card-radius: 14px;
}

* { box-sizing: border-box; }

body {
    background: var(--admin-bg);
    font-family: 'Poppins', system-ui, sans-serif;
    color: #1f2937;
}

/* ---------- LOGIN ---------- */
.login-page { background: linear-gradient(135deg, #14213d 0%, #2f6fed 100%); min-height: 100vh; }
.login-wrapper { min-height: 100vh; padding: 1.5rem; }
.login-card { width: 100%; max-width: 400px; border-radius: 18px; }

/* ---------- LAYOUT ---------- */
.admin-layout {
    display: flex;
    min-height: 100vh;
}

.admin-sidebar {
    width: 250px;
    background: var(--admin-sidebar-bg);
    color: var(--admin-sidebar-text);
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    padding: 1.25rem 0.75rem;
    position: sticky;
    top: 0;
    height: 100vh;
    overflow-y: auto;
}

.sidebar-brand {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 700;
    font-size: 1.1rem;
    color: #fff;
    padding: 0 0.5rem 1.25rem;
}

.sidebar-nav { display: flex; flex-direction: column; gap: 0.15rem; }

.nav-section-title {
    text-transform: uppercase;
    font-size: 0.68rem;
    letter-spacing: 0.06em;
    color: #6b7a99;
    margin: 0.9rem 0.6rem 0.35rem;
    font-weight: 600;
}

.admin-sidebar .nav-link {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.55rem 0.65rem;
    border-radius: 8px;
    color: var(--admin-sidebar-text);
    font-size: 0.9rem;
    transition: background 0.15s ease, color 0.15s ease;
}

.admin-sidebar .nav-link:hover { background: rgba(255,255,255,0.06); color: #fff; }
.admin-sidebar .nav-link.active { background: var(--admin-accent); color: #fff; }

.admin-content { flex: 1; min-width: 0; display: flex; flex-direction: column; }

.admin-topbar {
    background: #fff;
    padding: 0.85rem 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    border-bottom: 1px solid #e9ecef;
    position: sticky;
    top: 0;
    z-index: 10;
}

.topbar-user { display: flex; align-items: center; gap: 0.4rem; font-size: 0.9rem; color: #495057; }

.admin-main { padding: 1.5rem; flex: 1; }

/* ---------- CARDS ---------- */
.card-panel {
    background: #fff;
    border-radius: var(--admin-card-radius);
    padding: 1.25rem 1.5rem;
    box-shadow: 0 1px 3px rgba(0,0,0,0.04);
    margin-bottom: 1.25rem;
}

.stat-card {
    background: #fff;
    border-radius: var(--admin-card-radius);
    padding: 1.1rem 1.25rem;
    display: flex;
    align-items: center;
    gap: 0.9rem;
    box-shadow: 0 1px 3px rgba(0,0,0,0.04);
    height: 100%;
}

.stat-icon {
    width: 46px;
    height: 46px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
}

.stat-value { font-size: 1.4rem; font-weight: 700; line-height: 1; }
.stat-label { font-size: 0.8rem; color: #6c757d; margin-top: 0.2rem; }

.stat-card-sm {
    background: #fff;
    border-radius: var(--admin-card-radius);
    padding: 1rem;
    text-align: center;
    box-shadow: 0 1px 3px rgba(0,0,0,0.04);
}

.stat-card-sm .stat-value { font-size: 1.3rem; color: var(--admin-accent); }
.stat-card-sm .stat-label { font-size: 0.75rem; }

/* ---------- RESPONSIVO ---------- */
@media (max-width: 991.98px) {
    .admin-sidebar {
        position: fixed;
        left: -260px;
        z-index: 1050;
        transition: left 0.2s ease;
        box-shadow: 0 0 30px rgba(0,0,0,0.2);
    }
    .admin-layout.sidebar-open .admin-sidebar { left: 0; }
}
