/* ========================================
   CCNA 200-301 STYLE - Cisco / Pearson Vue
   ======================================== */

:root {
    --cisco-blue: #005073;
    --cisco-blue-dark: #003853;
    --cisco-blue-light: #049fd9;
    --bg-primary: #f2f2f2;
    --bg-card: #ffffff;
    --text-primary: #333333;
    --text-secondary: #666666;
    --text-muted: #999999;
    --border-color: #d9d9d9;
    --accent-green: #6aab58;
    --accent-red: #d15b47;
    --accent-orange: #ed7d31;
    --hover-bg: #e8f4fd;
    --shadow: 0 2px 8px rgba(0,0,0,0.1);
    --correct-bg: #eaf7e7;
    --incorrect-bg: #fde8e4;
    --sidebar-width: 220px;
    --font-stack: 'Segoe UI', 'Helvetica Neue', Arial, sans-serif;
}

/* ========================================
   ANIMATIONS
   ======================================== */

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(20px); }
    to   { opacity: 1; transform: translateY(0); }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}

@keyframes slideInRight {
    from { opacity: 0; transform: translateX(30px); }
    to   { opacity: 1; transform: translateX(0); }
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50%       { transform: scale(1.03); }
}

@keyframes shimmer {
    0%   { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

.animate-fade-in-up {
    animation: fadeInUp 0.4s ease-out both;
}

.animate-fade-in {
    animation: fadeIn 0.3s ease-out both;
}

.animate-slide-in {
    animation: slideInRight 0.35s ease-out both;
}

.animate-pulse-hover:hover {
    animation: pulse 0.3s ease;
}

.stagger-1 { animation-delay: 0.05s; }
.stagger-2 { animation-delay: 0.1s; }
.stagger-3 { animation-delay: 0.15s; }
.stagger-4 { animation-delay: 0.2s; }
.stagger-5 { animation-delay: 0.25s; }

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: var(--font-stack);
    background: var(--bg-primary);
    color: var(--text-primary);
    min-height: 100vh;
    font-size: 16px;
    line-height: 1.5;
}

#app {
    min-height: 100vh;
}

/* ========================================
   LOGIN
   ======================================== */

#loginScreen {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 20px;
    background: linear-gradient(135deg, #f5f7fa 0%, #e4e9f0 100%);
}

.login-box {
    background: var(--bg-card);
    padding: 40px 44px;
    box-shadow: 0 4px 24px rgba(0,0,0,0.12);
    width: 100%;
    max-width: 420px;
    text-align: center;
}

.login-box h1 { font-size: 1.6rem; font-weight: 700; color: var(--cisco-blue); letter-spacing: 1px; margin-bottom: 28px; }
.login-subtitle { color: var(--text-muted); font-size: 0.95rem; margin-bottom: 32px; }



.login-error {
    background: #fff0ee; border: 1px solid var(--accent-red);
    color: var(--accent-red); font-size: 0.9rem;
    padding: 12px; margin-bottom: 18px; text-align: center;
}

.login-success {
    background: #eaf7e7; border: 1px solid var(--accent-green);
    color: var(--accent-green); font-size: 0.9rem;
    padding: 12px; margin-bottom: 18px; text-align: center;
}

.login-btn { width: 100%; padding: 14px; font-size: 1.1rem; }

/* ========================================
   MAIN LAYOUT (sidebar + content)
   ======================================== */

#mainLayout {
    display: flex;
    min-height: 100vh;
}

#mainRight {
    flex: 1;
    margin-left: var(--sidebar-width);
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    transition: margin-left 0.3s ease;
}

/* SIDEBAR */
#sidebar {
    width: var(--sidebar-width);
    background: var(--cisco-blue-dark);
    color: white;
    display: flex;
    flex-direction: column;
    flex-shrink: 0;
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    z-index: 100;
    transition: width 0.3s ease;
}

#sidebar.compact {
    width: 60px;
}

#sidebar.compact .sidebar-header {
    justify-content: center;
    padding: 22px 0 14px;
}

#sidebar.compact .logo-text-sm {
    font-size: 1rem;
}

#sidebar.compact .sidebar-version,
#sidebar.compact .sidebar-menu li span:not(.menu-icon),
#sidebar.compact .sidebar-footer,
#sidebar.compact .submenu-arrow {
    display: none;
}

#sidebar.compact .sidebar-menu li a,
#sidebar.compact .sidebar-menu li {
    justify-content: center;
    padding: 12px 0;
}

#sidebar.compact .sidebar-menu li .menu-icon {
    font-size: 1.3rem;
    margin: 0;
}

#sidebar.compact .sidebar-submenu-trigger {
    justify-content: center;
    padding: 12px 0;
}

#sidebar.compact .sidebar-submenu-trigger .menu-icon {
    margin: 0;
    font-size: 1.3rem;
}

/* In compact mode, submenus appear as dropdowns */
#sidebar.compact .sidebar-submenu {
    display: none;
    position: fixed;
    left: 60px;
    top: auto;
    min-width: 200px;
    background: var(--cisco-blue-dark);
    border-radius: 0 10px 10px 0;
    box-shadow: 4px 6px 20px rgba(0,0,0,0.35);
    padding: 6px 0;
    z-index: 200;
    border-left: 3px solid var(--cisco-blue-light);
}

#sidebar.compact .sidebar-submenu.open {
    display: block;
}

/* Hover support */
#sidebar.compact .sidebar-submenu-trigger:hover + .sidebar-submenu,
#sidebar.compact .sidebar-submenu:hover {
    display: block;
}

#sidebar.compact .sidebar-submenu li {
    padding: 12px 18px;
    font-size: 0.9rem;
    justify-content: flex-start;
    gap: 10px;
    cursor: pointer;
    color: rgba(255,255,255,0.75);
    transition: all 0.15s;
}

#sidebar.compact .sidebar-submenu li:hover {
    background: rgba(255,255,255,0.1);
    color: white;
    padding-left: 22px;
}

#sidebar.compact .sidebar-submenu li span:not(.menu-icon) {
    display: inline !important;
    font-size: 0.9rem;
}

#sidebar.compact .sidebar-submenu li .sub-icon {
    font-size: 0.85rem;
}

/* Sidebar toggle button */
.sidebar-toggle-btn {
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 1.3rem;
    cursor: pointer;
    padding: 0 12px 0 4px;
    line-height: 1;
    transition: color 0.2s;
}

.sidebar-toggle-btn {
    color: rgba(255,255,255,0.7);
}

.sidebar-toggle-btn:hover {
    color: white;
}

.sidebar-header {
    padding: 22px 18px 14px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    display: flex;
    align-items: center;
    gap: 8px;
}

.logo-text-sm { font-size: 1.3rem; font-weight: 700; letter-spacing: 1px; }
.sidebar-version { font-size: 0.75rem; background: rgba(255,255,255,0.15); padding: 3px 10px; }

.sidebar-user {
    padding: 14px 18px;
    font-size: 0.9rem;
    border-bottom: 1px solid rgba(255,255,255,0.08);
    color: rgba(255,255,255,0.8);
}

.sidebar-menu {
    list-style: none;
    flex: 1;
    padding: 10px 0;
}

.sidebar-menu li {
    padding: 14px 18px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.95rem;
    color: rgba(255,255,255,0.7);
    transition: all 0.2s;
    border-left: 3px solid transparent;
}

.sidebar-menu li:hover {
    background: rgba(255,255,255,0.08);
    color: white;
    padding-left: 22px;
}

.sidebar-menu li.active {
    background: rgba(255,255,255,0.12);
    color: white;
    border-left-color: var(--cisco-blue-light);
}

.menu-icon { font-size: 1.2rem; width: 26px; text-align: center; }
.sub-icon { font-size: 0.7rem; width: 26px; text-align: center; opacity: 0.6; }

.submenu-arrow {
    margin-left: auto;
    transition: transform 0.2s;
    font-size: 0.85rem;
    opacity: 0.5;
}

.submenu-arrow.open {
    transform: rotate(90deg);
}

/* Submenu */
.sidebar-submenu {
    list-style: none;
    padding: 0;
    margin: 0;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease, padding 0.3s ease;
}

.sidebar-submenu.open {
    max-height: 120px;
}

.sidebar-submenu li {
    padding: 10px 18px 10px 52px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.85rem;
    color: rgba(255,255,255,0.55);
    transition: all 0.15s;
    border-left: 3px solid transparent;
}

.sidebar-submenu li:hover {
    background: rgba(255,255,255,0.06);
    color: white;
    padding-left: 56px;
}

.sidebar-submenu li.active {
    color: white;
    border-left-color: var(--cisco-blue-light);
    background: rgba(255,255,255,0.08);
}

.sidebar-submenu-trigger {
    user-select: none;
}

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

.btn-logout {
    width: 100%;
    padding: 10px;
    background: rgba(255,255,255,0.1);
    border: none;
    color: rgba(255,255,255,0.7);
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.15s;
    font-family: var(--font-stack);
}

.btn-logout:hover { background: rgba(255,255,255,0.2); color: white; }

/* MAIN CONTENT */
#mainContent {
    flex: 1;
    padding: 28px 36px;
    overflow-y: auto;
}

.page-content { max-width: 100%; }

.page-content h2 { font-size: 1.6rem; font-weight: 600; color: var(--cisco-blue); margin-bottom: 6px; }
.page-subtitle { color: var(--text-muted); font-size: 0.95rem; margin-bottom: 32px; }

/* ========================================
   BUTTONS
   ======================================== */

button {
    background: var(--cisco-blue);
    color: white; border: none;
    padding: 12px 30px; border-radius: 4px;
    font-size: 1rem; font-family: var(--font-stack);
    cursor: pointer; font-weight: 500;
    transition: all 0.15s;
    letter-spacing: 0.2px;
}

button:hover { background: var(--cisco-blue-dark); }
button:active { transform: scale(0.98); }

.btn-primary { background: var(--cisco-blue); }
.btn-secondary { background: #888; }
.btn-secondary:hover { background: #666; }
.btn-danger { background: var(--accent-red); min-width: 120px; }
.btn-danger:hover { background: #b94a3a; }
.btn-lg { min-width: 200px; font-size: 1.1rem; padding: 14px 32px; }

/* ========================================
   DASHBOARD
   ======================================== */

.stat-card {
    background: var(--bg-card);
    box-shadow: var(--shadow);
    border-radius: 16px;
    padding: 24px 20px;
    display: flex;
    align-items: center;
    gap: 16px;
    transition: transform 0.2s, box-shadow 0.2s;
}

.stat-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.12);
}

.stat-icon {
    font-size: 2.2rem;
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--hover-bg);
    border-radius: 14px;
}

.stat-gradient-1 .stat-icon {
    background: linear-gradient(135deg, #e3f2fd, #bbdefb);
}
.stat-gradient-2 .stat-icon {
    background: linear-gradient(135deg, #e8f5e9, #c8e6c9);
}
.stat-gradient-3 .stat-icon {
    background: linear-gradient(135deg, #fff3e0, #ffe0b2);
}
.stat-gradient-4 .stat-icon {
    background: linear-gradient(135deg, #fce4ec, #f8bbd0);
}

.stat-body {
    display: flex;
    flex-direction: column;
}

.stat-value {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.2;
}

.stat-label {
    font-size: 0.78rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 600;
}

.dash-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 18px;
    margin-bottom: 36px;
    width: 100%;
}

.dashboard-card {
    background: var(--bg-card);
    box-shadow: var(--shadow);
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 20px;
}

.dashboard-card-title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 16px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--border-color);
}

.dash-card {
    background: var(--bg-card);
    padding: 28px;
    box-shadow: var(--shadow);
    text-align: center;
    width: 100%;
    transition: transform 0.2s, box-shadow 0.2s;
    cursor: default;
}

.dash-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.12);
}

.dash-value { font-size: 2.2rem; font-weight: 700; color: var(--cisco-blue); }
.dash-label { font-size: 0.85rem; color: var(--text-muted); margin-top: 4px; text-transform: uppercase; letter-spacing: 0.3px; }

.dash-chart-title {
    font-size: 1rem; font-weight: 600;
    color: var(--text-primary); margin-bottom: 14px; margin-top: 28px;
}

.dash-chart {
    display: flex;
    align-items: flex-end;
    gap: 8px;
    background: var(--bg-card);
    padding: 24px 20px;
    box-shadow: var(--shadow);
    min-height: 180px;
    width: 100%;
}

.chart-container {
    display: flex;
    align-items: flex-end;
    justify-content: space-around;
    height: 200px;
    gap: 4px;
    padding: 10px 0;
}

.chart-bar-wrap {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    height: 140px;
    justify-content: flex-end;
}

.chart-bar {
    width: 28px;
    min-height: 4px;
    border-radius: 2px 2px 0 0;
    transition: height 0.5s ease;
    animation: fadeInUp 0.5s ease-out both;
}

.chart-green { background: var(--accent-green); }
.chart-red { background: var(--accent-red); }
.chart-gray { background: #ddd; }

.chart-label { font-size: 0.7rem; color: var(--text-muted); margin-top: 4px; }
.chart-val { font-size: 0.75rem; font-weight: 600; color: var(--text-secondary); margin-top: 2px; }

.chart-empty {
    width: 100%;
    text-align: center;
    color: var(--text-muted);
    padding: 20px;
    font-size: 0.95rem;
}

/* ========================================
   EXAM CONFIG
   ======================================== */

.exam-config {
    background: var(--bg-card);
    box-shadow: var(--shadow);
    padding: 36px;
    max-width: 100%;
    width: 100%;
    transition: box-shadow 0.2s;
}

.exam-config:hover {
    box-shadow: 0 6px 20px rgba(0,0,0,0.12);
}

.config-group {
    margin-bottom: 22px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.config-group label { font-weight: 500; font-size: 0.95rem; color: var(--text-primary); }

.config-group input {
    width: 100px; padding: 10px 12px;
    border: 1px solid var(--border-color);
    font-size: 1.1rem; text-align: center;
    font-weight: 600; color: var(--text-primary);
    outline: none; font-family: var(--font-stack);
}

.config-group input:focus {
    border-color: var(--cisco-blue-light);
    box-shadow: 0 0 0 2px rgba(4, 159, 217, 0.2);
}

/* ========================================
   EXAM IN PROGRESS
   ======================================== */

#exam-header-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--bg-card);
    padding: 14px 24px;
    margin-bottom: 18px;
    box-shadow: var(--shadow);
    font-size: 0.9rem;
    color: var(--text-secondary);
    width: 100%;
}

#temporizador { color: var(--accent-orange); font-weight: 700; font-variant-numeric: tabular-nums; }

#preguntaContainer {
    background: var(--bg-card);
    padding: 32px 36px;
    margin-bottom: 18px;
    box-shadow: var(--shadow);
    width: 100%;
}

#preguntaNumero {
    color: var(--cisco-blue); font-weight: 700; font-size: 0.85rem;
    text-transform: uppercase; letter-spacing: 0.5px;
    padding-bottom: 10px; border-bottom: 2px solid var(--cisco-blue);
    display: inline-block;
}

#preguntaTexto { font-size: 1.05rem; line-height: 1.7; margin: 20px 0 28px; color: var(--text-primary); }

.tipo-pregunta { color: var(--text-secondary); font-size: 0.85rem; font-weight: 400; text-transform: uppercase; }

/* Options */
.opcion {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 12px 16px;
    border: 1px solid transparent;
    cursor: pointer;
    transition: all 0.2s;
    border-left: 3px solid transparent;
    animation: fadeInUp 0.35s ease-out both;
}

.opcion:nth-child(1) { animation-delay: 0.05s; }
.opcion:nth-child(2) { animation-delay: 0.1s; }
.opcion:nth-child(3) { animation-delay: 0.15s; }
.opcion:nth-child(4) { animation-delay: 0.2s; }

.opcion:hover { background: var(--hover-bg); border-left-color: var(--cisco-blue-light); }
.opcion.seleccionada { background: #e1f0fa; border-left-color: var(--cisco-blue); }
.opcion.correcta { background: var(--correct-bg); border-left-color: var(--accent-green); }
.opcion.incorrecta { background: var(--incorrect-bg); border-left-color: var(--accent-red); }

.letra {
    width: 30px; height: 30px;
    display: flex; align-items: center; justify-content: center;
    border: 1px solid var(--border-color);
    font-weight: 700; font-size: 0.9rem; flex-shrink: 0;
    color: var(--text-primary); background: white;
    transition: all 0.15s;
}

.opcion.seleccionada .letra { background: var(--cisco-blue); border-color: var(--cisco-blue); color: white; }
.opcion.correcta .letra { background: var(--accent-green); border-color: var(--accent-green); color: white; }
.opcion.incorrecta .letra { background: var(--accent-red); border-color: var(--accent-red); color: white; }

.checkbox-indicator {
    display: inline-flex; width: 20px; height: 20px;
    align-items: center; justify-content: center;
    font-size: 1.2rem; flex-shrink: 0;
}

.texto { line-height: 1.5; padding-top: 3px; color: var(--text-primary); }

/* Exhibit */
.exhibit-placeholder {
    display: inline-flex; align-items: center; gap: 8px;
    margin: 14px 0; padding: 12px 18px;
    background: #f0f7fb; border: 1px dashed var(--cisco-blue-light);
    color: var(--cisco-blue); cursor: pointer; font-size: 0.95rem;
    transition: background 0.15s; border-radius: 4px;
}
.exhibit-placeholder:hover { background: #e0f0fa; }
.exhibit-icon { font-size: 1.4rem; }
.pregunta-img { max-width: 100%; height: auto; margin: 14px 0; border: 1px solid var(--border-color); border-radius: 4px; display: block; }

/* Feedback */
#feedback {
    margin-top: 24px; padding: 18px 24px;
    background: #fafafa; border: 1px solid var(--border-color);
    border-left: 4px solid var(--cisco-blue);
    font-size: 0.95rem; line-height: 1.6; color: var(--text-primary);
}

/* Navigation */
#navegacion { display: flex; justify-content: space-between; gap: 8px; margin-bottom: 18px; flex-wrap: wrap; width: 100%; }

/* Mini Grid */
#miniGrid {
    display: flex; flex-wrap: wrap; gap: 5px; justify-content: center;
    background: var(--bg-card); padding: 16px 20px; box-shadow: var(--shadow);
    width: 100%;
}

.cuadro {
    width: 34px; height: 34px; background: white;
    border: 1px solid var(--border-color);
    display: flex; align-items: center; justify-content: center;
    font-size: 0.75rem; cursor: pointer; font-weight: 500; color: var(--text-primary);
    transition: all 0.1s;
}
.cuadro:hover { border-color: var(--cisco-blue-light); background: var(--hover-bg); }
.cuadro.actual { background: var(--cisco-blue); border-color: var(--cisco-blue); color: white; font-weight: 700; }
.cuadro.respondida { background: #e1f0fa; border-color: var(--cisco-blue-light); }
.cuadro.correcta-final { background: var(--accent-green); border-color: #4a8a3a; color: white; }
.cuadro.incorrecta-final { background: var(--accent-red); border-color: #a43a2a; color: white; }

/* ========================================
   RESULTS
   ======================================== */

#resultadoPuntaje {
    font-size: 2.2rem; font-weight: 700; text-align: center;
    padding: 28px; background: #fafafa; border: 1px solid var(--border-color);
    margin-bottom: 32px;
    width: 100%;
}
#resultadoPuntaje.aprobado { color: var(--accent-green); border-left: 6px solid var(--accent-green); }
#resultadoPuntaje.reprobado { color: var(--accent-red); border-left: 6px solid var(--accent-red); }

#resultadoDetalle { margin: 24px 0; }

.resultado-pregunta {
    padding: 12px 16px; margin-bottom: 6px;
    background: #fafafa; border-left: 4px solid var(--border-color);
    font-size: 0.9rem; cursor: pointer; transition: background 0.15s, transform 0.15s;
    animation: fadeInUp 0.3s ease-out both;
}
.resultado-pregunta:hover { background: var(--hover-bg); transform: translateX(3px); }
.resultado-pregunta.correcta { border-left-color: var(--accent-green); }
.resultado-pregunta.incorrecta { border-left-color: var(--accent-red); }
.resultado-pregunta .num { font-weight: 700; color: var(--cisco-blue); }

.pregunta-respuesta-tuya { color: var(--text-secondary); font-size: 0.85rem; margin-top: 4px; }

/* ========================================
   HISTORY
   ======================================== */

#historyFilter {
    display: flex; gap: 8px; margin-bottom: 24px;
}

.filter-btn {
    background: #e0e0e0; color: var(--text-secondary);
    padding: 8px 18px; font-size: 0.85rem;
}
.filter-btn.active { background: var(--cisco-blue); color: white; }
.filter-btn:hover { background: var(--cisco-blue); color: white; }

.history-item {
    display: flex; justify-content: space-between; align-items: center;
    background: var(--bg-card); padding: 16px 20px;
    margin-bottom: 8px; box-shadow: 0 1px 3px rgba(0,0,0,0.06);
    border-left: 4px solid transparent;
    width: 100%;
    transition: transform 0.15s, box-shadow 0.15s;
}

.history-item:hover {
    transform: translateX(4px);
    box-shadow: 0 3px 10px rgba(0,0,0,0.1);
}

.history-pass { border-left-color: var(--accent-green); }
.history-fail { border-left-color: var(--accent-red); }

.history-date { font-size: 0.9rem; font-weight: 600; color: var(--text-primary); }
.history-detail { font-size: 0.85rem; color: var(--text-secondary); margin-top: 2px; }

.badge-pass {
    background: var(--accent-green); color: white;
    padding: 6px 16px; font-size: 0.8rem; font-weight: 700; letter-spacing: 1px;
}
.badge-fail {
    background: var(--accent-red); color: white;
    padding: 6px 16px; font-size: 0.8rem; font-weight: 700; letter-spacing: 1px;
}

.history-empty {
    text-align: center; color: var(--text-muted); padding: 40px; font-size: 0.95rem;
}

/* ========================================
   USER MANAGEMENT
   ======================================== */

.user-status {
    font-size: 0.8rem;
    padding: 3px 10px;
    margin-right: 6px;
}

.user-status.active {
    background: #d4edda;
    color: #155724;
}

.user-status.inactive {
    background: #f8d7da;
    color: #721c24;
}

.user-inactive {
    opacity: 0.5;
}

.btn-warning {
    background: #f0ad4e;
    color: #fff;
    border: none;
    cursor: pointer;
    font-size: 0.85rem;
}

.btn-warning:hover {
    background: #ec971f;
}

.btn-success {
    background: #5cb85c;
    color: #fff;
    border: none;
    cursor: pointer;
    font-size: 0.85rem;
}

.btn-success:hover {
    background: #449d44;
}

/* ========================================
   SETTINGS (page config)
   ======================================== */

.settings-section-title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 16px;
}

.theme-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    gap: 12px;
    margin-bottom: 16px;
}

.theme-option {
    cursor: pointer;
    text-align: center;
    padding: 8px;
    border: 2px solid transparent;
    transition: border-color 0.2s, transform 0.15s;
}

.theme-option:hover {
    transform: translateY(-2px);
}

.theme-option.selected {
    border-color: var(--cisco-blue);
}

.theme-preview {
    width: 100%;
    height: 60px;
    margin-bottom: 6px;
}

.theme-name {
    font-size: 0.8rem;
    color: var(--text-secondary);
    font-weight: 500;
}

/* Theme preview colors */
.theme-default {
    background: linear-gradient(135deg, #003853 0%, #005073 50%, #049fd9 100%);
}
.theme-dark {
    background: linear-gradient(135deg, #1a1a2e 0%, #2d2d44 50%, #444466 100%);
}
.theme-ocean {
    background: linear-gradient(135deg, #0c3b5e 0%, #2a6f97 50%, #7ec8e3 100%);
}
.theme-forest {
    background: linear-gradient(135deg, #1b3a2a 0%, #2d6a4f 50%, #95d5b2 100%);
}
.theme-midnight {
    background: linear-gradient(135deg, #0a0a1a 0%, #1a1a3a 50%, #3a3a6a 100%);
}

/* ========================================
   SETTINGS (profile)
   ======================================== */

.settings-box {
    background: var(--bg-card);
    box-shadow: var(--shadow);
    padding: 36px;
    max-width: 100%;
    width: 100%;
    transition: box-shadow 0.2s;
}

.settings-box:hover {
    box-shadow: 0 6px 20px rgba(0,0,0,0.12);
}

/* ========================================
   USERS (admin)
   ======================================== */

.user-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 28px;
    width: 100%;
}

@media (max-width: 800px) {
    .user-grid { grid-template-columns: 1fr; }
}

.user-list-section h3,
.user-create-section h3 {
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 18px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--cisco-blue);
}

.user-list-section {
    background: var(--bg-card);
    box-shadow: var(--shadow);
    padding: 24px;
    width: 100%;
}

.user-create-section {
    background: var(--bg-card);
    box-shadow: var(--shadow);
    padding: 24px;
    width: 100%;
}

.user-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px;
    border-bottom: 1px solid var(--border-color);
}

.user-row:last-child { border-bottom: none; }

.user-row-info strong { font-size: 0.95rem; }

.user-role-badge {
    display: inline-block;
    padding: 3px 10px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-left: 6px;
}

.user-role-badge.admin {
    background: #1e3a5f;
    color: white;
}

.user-role-badge.user {
    background: #e8f0fe;
    color: var(--cisco-blue);
}

.user-row-date {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-top: 3px;
}

.btn-sm {
    padding: 8px 16px;
    font-size: 0.85rem;
    min-width: auto;
}

.separator {
    height: 1px;
    background: var(--border-color);
    margin: 24px 0;
    border: none;
}

.user-create-section select {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border-color);
    font-family: var(--font-stack);
    font-size: 1rem;
    background: white;
    color: var(--text-primary);
    outline: none;
}

.user-create-section select:focus {
    border-color: var(--cisco-blue-light);
    box-shadow: 0 0 0 2px rgba(4, 159, 217, 0.15);
}

/* ========================================
   USER TOP BAR (name + dropdown)
   ======================================== */

#topBar {
    background: var(--cisco-blue-dark);
    border-bottom: 1px solid rgba(255,255,255,0.1);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 12px;
    min-height: 60px;
}

#userTopBar {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 28px;
}

#userTopName {
    font-size: 0.9rem;
    color: rgba(255,255,255,0.65);
    font-weight: 400;
}

#userTopBtn {
    background: rgba(255,255,255,0.1);
    color: rgba(255,255,255,0.7);
    border: 1px solid rgba(255,255,255,0.15);
    width: 28px;
    height: 28px;
    font-size: 0.75rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.15s;
}

#userTopBtn:hover {
    background: rgba(255,255,255,0.2);
    color: #fff;
}

.user-top-dropdown {
    position: relative;
}

.user-top-menu {
    position: absolute;
    right: 0;
    top: calc(100% + 6px);
    background: #fff;
    box-shadow: 0 4px 16px rgba(0,0,0,0.15);
    min-width: 180px;
    display: none;
    z-index: 100;
    border: 1px solid var(--border-color);
}

.user-top-menu a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 18px;
    font-size: 0.95rem;
    color: var(--text-primary);
    cursor: pointer;
    transition: background 0.12s;
}

.user-top-menu a:hover {
    background: #eef3fb;
    color: var(--cisco-blue);
}

.user-top-menu.show {
    display: block;
}

/* ========================================
   MODAL (change password)
   ======================================== */

.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;
}

.modal-box {
    background: white;
    padding: 36px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.2);
    width: 100%;
    max-width: 420px;
}

.modal-box h3 {
    font-size: 1.2rem;
    color: var(--cisco-blue);
    margin-bottom: 6px;
}

.modal-buttons {
    display: flex;
    gap: 8px;
    margin-top: 10px;
}

.modal-buttons button {
    flex: 1;
}

/* ========================================
   DASHBOARD FOOTER
   ======================================== */

.dash-footer {
    margin-top: 48px;
    padding: 24px 0 12px;
    border-top: 1px solid var(--border-color);
    text-align: center;
    animation: fadeIn 0.5s ease-out both;
    animation-delay: 0.3s;
}

.dash-footer p {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin: 0;
}

.dash-footer strong {
    color: var(--text-secondary);
    font-weight: 600;
}

.dash-footer a {
    color: var(--cisco-blue);
    text-decoration: none;
}

.dash-footer a:hover {
    text-decoration: underline;
}

/* ========================================
   RESPONSIVE
   ======================================== */

@media (max-width: 768px) {
    #sidebar { width: 60px; }
    .sidebar-header { justify-content: center; }
    /* ========================================
   TUTORIAL
   ======================================== */

.tutorial-overlay {
    position: fixed;
    top: 0; left: 0;
    width: 100vw; height: 100vh;
    background: rgba(0,0,0,0.6);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.tutorial-modal {
    background: var(--bg-card);
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
    max-width: 700px;
    width: 90%;
    max-height: 85vh;
    overflow-y: auto;
    padding: 32px;
}

.tutorial-card {
    text-align: center;
}

.tutorial-card .tutorial-icon {
    font-size: 3.5rem;
    margin-bottom: 16px;
}

.tutorial-card h3 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--cisco-blue);
}

.tutorial-card h4 {
    font-size: 1.15rem;
    font-weight: 600;
    margin-bottom: 12px;
    color: var(--text-primary);
}

.tutorial-card p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 8px;
}

.tutorial-features {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 12px;
    margin: 20px 0;
    text-align: left;
}

.tutorial-feature-item {
    background: var(--hover-bg);
    border-radius: 10px;
    padding: 14px;
    transition: transform 0.15s;
}

.tutorial-feature-item:hover {
    transform: translateY(-2px);
}

.tutorial-feature-item strong {
    display: block;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.tutorial-feature-item span {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.tutorial-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 24px;
    padding-top: 16px;
    border-top: 1px solid var(--border-color);
}

.tutorial-dots {
    display: flex;
    gap: 6px;
}

.tutorial-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--border-color);
    transition: background 0.2s;
    cursor: pointer;
}

.tutorial-dot.active {
    background: var(--cisco-blue);
    transform: scale(1.3);
}

/* ========================================
   BACK TO TOP
   ======================================== */

#backToTop {
    position: fixed;
    bottom: 30px;
    right: 20px;
    left: auto;
    width: 48px;
    height: 48px;
    background: var(--cisco-blue);
    color: white;
    border: none;
    border-radius: 50%;
    font-size: 1.3rem;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    z-index: 999;
    display: none;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    opacity: 0;
}

#backToTop.visible {
    display: flex;
    opacity: 1;
}

#backToTop:hover {
    background: var(--cisco-blue-dark);
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.3);
}

@keyframes bounceUp {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-5px); }
}

#backToTop.bounce {
    animation: bounceUp 0.6s ease infinite;
}

/* ========================================
   RESPONSIVE
   ======================================== */

.sidebar-version, .sidebar-user, .sidebar-menu li span:not(.menu-icon), .sidebar-footer, .sidebar-submenu, .submenu-arrow { display: none; }
    #mainRight { margin-left: 60px; }
    #mainContent { padding: 20px 16px; }
    .dash-grid { grid-template-columns: 1fr 1fr; }
}
