/* --- VARIABLES DE DISEÑO GLOBAL --- */
:root {
    --bg-dark: #0a0a0a;
    --bg-sidebar: linear-gradient(180deg, #1a1a1a 0%, #0a0a0a 100%);
    --bg-card: #1a1a1a;
    --primary-color: #8000ff;
    --primary-hover: #9d4edd;
    --text-main: #ffffff;
    --text-muted: #888888;
    --border-color: #333333;
    --success: #28a745;
    --danger: #dc3545;
    --warning: #ffc107;
    --info: #17a2b8;
}

html, body {
    margin: 0;
    padding: 0;
    width: 100%;
    height: 100%;
    background-color: var(--bg-dark);
    color: var(--text-main);
    font-family: 'Segoe UI', sans-serif;
}

/* --- CLASES GLOBALES DE UI --- */
.card-panel {
    background: var(--bg-card);
    padding: 1.5rem;
    border-radius: 8px;
    border: 1px solid var(--border-color);
}

.btn {
    padding: 0.5rem 1rem;
    border-radius: 6px;
    border: none;
    cursor: pointer;
    font-weight: 500;
    transition: 0.3s;
    color: white;
}

.btn-primary { background: var(--primary-color); }
.btn-primary:hover { background: var(--primary-hover); }

.btn-success { background: var(--success); }
.btn-danger { background: var(--danger); }

/* --- ESTRUCTURA RESPONSIVA DE ADMIN --- */
.admin-wrapper {
    display: flex;
    width: 100%;
    min-height: 100vh;
    transition: all 0.3s ease;
}

/* Sidebar */
.admin-sidebar {
    width: 280px;
    height: 100vh;
    position: fixed;
    top: 0;
    left: 0;
    background: var(--bg-sidebar);
    border-right: 1px solid var(--primary-color);
    z-index: 1000;
    transition: all 0.3s ease;
}

.sidebar-collapsed .admin-sidebar {
    left: -280px;
}

.sidebar-collapsed .admin-main {
    margin-left: 0;
}

.admin-main {
    flex: 1;
    margin-left: 280px;
    background-color: var(--bg-dark);
    display: flex;
    flex-direction: column;
    transition: all 0.3s ease;
}

/* Header Global Rediseñado */
.admin-header-global {
    background: rgba(15, 10, 25, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(128, 0, 255, 0.3);
    padding: 0.75rem 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 99;
}

.header-left, .header-right {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.btn-toggle-sidebar, .btn-logout-header {
    background: transparent;
    border: 1px solid var(--primary-color);
    color: #b87aff;
    padding: 0.5rem;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-toggle-sidebar:hover, .btn-logout-header:hover {
    background: var(--primary-color);
    color: white;
}

.admin-content {
    padding: 2rem;
    flex: 1;
}

/* Responsividad */
@media (max-width: 991.98px) {
    .admin-sidebar {
        left: -280px;
    }
    
    .admin-main {
        margin-left: 0;
    }
    
    .admin-wrapper:not(.sidebar-collapsed) .admin-sidebar {
        left: 0;
        box-shadow: 5px 0 25px rgba(0, 0, 0, 0.8);
    }
}

.sidebar-header {
    padding: 1.5rem 1rem;
    border-bottom: 2px solid var(--primary-color);
    margin-bottom: 1rem;
}

.sidebar-logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.2rem;
    font-weight: bold;
    color: #b87aff;
}

.sidebar-nav {
    flex: 1;
    padding: 0 0.75rem;
    overflow-y: auto;
    height: calc(100vh - 80px); 
}

.nav-section-title {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-muted);
    padding: 0.5rem 0.75rem;
}

.sidebar-link {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    color: #e0e0e0;
    text-decoration: none;
    border-radius: 8px;
    transition: all 0.3s;
    margin-bottom: 0.25rem;
}

.sidebar-link i {
    font-size: 1.2rem;
    color: var(--primary-color);
}

.sidebar-link:hover, .sidebar-link.active {
    background: rgba(128, 0, 255, 0.1);
    color: white;
    border-left: 3px solid var(--primary-color);
}
/* Estilos del tour - COMPARTIDOS */
.tour-highlight {
    position: relative;
    z-index: 9999 !important;
    box-shadow: 0 0 0 4px #7c3aed, 0 0 0 8px rgba(124, 58, 237, 0.3) !important;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.tour-tooltip {
    position: fixed;
    z-index: 9999;
    background: white;
    border-radius: 16px;
    padding: 24px;
    max-width: 380px;
    width: 100%;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    border: 1px solid #e5e7eb;
    animation: tourSlideIn 0.3s ease;
}