.range-filter {
    display: flex;
    gap: 10px;
}

.range-filter select {
    flex: 1;
}:root {
    --primary: #1b3a57;
    --primary-light: #29567d;
    --secondary: #f89c1c;
    --background: #eaedf2;
    --card-bg: #ffffff;
    --text: #333333;
    --text-light: #f1f1f1;
    --border: #e0e0e0;
    --shadow: rgba(0, 0, 0, 0.1);
    --chart-blue: #1e88e5;
    --chart-skyblue: rgba(136,167,217,255);
    --chart-pink: #ec407a;
    --sidebar-width: 250px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background-color: var(--background);
    color: var(--text);
    overflow-x: hidden;
}

.dashboard-layout {
    display: flex;
    min-height: 100vh;
}

/* Sidebar Styles */
.sidebar {
    width: var(--sidebar-width);
    background-color: var(--primary);
    color: var(--text-light);
    box-shadow: 4px 0 10px rgba(0, 0, 0, 0.1);
    z-index: 10;
    overflow-y: auto;
    position: fixed;
    height: 100vh;
}

.profile-section {
    padding: 30px 20px;
    text-align: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.profile-image {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background-color: white;
    margin: 0 auto 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.profile-image i {
    font-size: 50px;
    color: var(--primary);
}

.profile-section h3 {
    font-size: 18px;
    margin-bottom: 5px;
}

.profile-section p {
    font-size: 14px;
    opacity: 0.8;
}

.sidebar-nav ul {
    list-style: none;
    padding: 0;
}

.sidebar-nav li {
    margin-bottom: 5px;
}

.sidebar-nav a {
    display: flex;
    align-items: center;
    padding: 15px 20px;
    color: var(--text-light);
    text-decoration: none;
    transition: background-color 0.3s;
}

.sidebar-nav a:hover, .sidebar-nav li.active a {
    background-color: var(--primary-light);
}

.sidebar-nav i {
    margin-right: 10px;
    font-size: 18px;
    min-width: 24px;
    text-align: center;
}

.filter-section {
    border-left: 3px solid var(--secondary);
}

.filters-container {
    padding: 0 20px 20px 50px;
}

.filter-group {
    margin-bottom: 15px;
}

.filter-label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    font-size: 13px;
    color: var(--text-light);
}

.filters-container select {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 5px;
    background-color: var(--primary-light);
    color: white;
    font-size: 13px;
}

.filters-container button {
    width: 100%;
    padding: 10px 15px;
    background-color: var(--secondary);
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-weight: 600;
    margin-top: 5px;
    transition: background-color 0.3s;
}

.filters-container button:hover {
    background-color: #e6910a;
}

/* Main Content Styles */
.main-content {
    flex: 1;
    padding: 20px;
    margin-left: var(--sidebar-width);
    width: calc(100% - var(--sidebar-width));
}

.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    background-color: var(--card-bg);
    padding: 15px 20px;
    border-radius: 10px;
    box-shadow: 0 2px 5px var(--shadow);
}

.dashboard-header h1 {
    font-size: 20px;
    font-weight: 600;
    color: var(--primary);
}

.header-controls {
    display: flex;
    gap: 10px;
}

.btn-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: var(--background);
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background-color 0.3s;
}

.btn-icon:hover {
    background-color: var(--border);
}

/* Stats Cards */
.stats-container {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 25px;
}

.stat-card {
    background-color: var(--card-bg);
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 2px 5px var(--shadow);
    flex: 1;
    min-width: 180px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 5px;
    height: 100%;
    background-color: var(--chart-blue);
}

.stat-card:nth-child(2)::before {
    background-color: var(--chart-pink);
}

.stat-card:nth-child(3)::before {
    background-color: var(--chart-skyblue);
}

.stat-card:nth-child(4)::before {
    background-color: var(--secondary);
}

.stat-value {
    font-size: 28px;
    font-weight: 700;
    margin: 5px 0;
    color: var(--primary);
}

.stat-label {
    font-size: 14px;
    color: #757575;
    font-weight: 500;
}

/* Dashboard Charts */
.dashboard {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 20px;
    margin-bottom: 25px;
}

.chart-container {
    background-color: var(--card-bg);
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 2px 5px var(--shadow);
    transition: transform 0.3s, box-shadow 0.3s;
    height: auto;
    position: relative;
}

.chart-container:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 12px var(--shadow);
}

.chart-container canvas {
    max-height: 350px;
    width: 100% !important;
}

//* Estilos específicos para el gráfico Top 10 Carreras */
.chart-container:has(#careersChart) {
    height: 350px;
    min-height: 350px;
    display: flex;
    flex-direction: column;
}

.chart-container:has(#careersChart) canvas {
    flex: 1;
    min-height: 250px;
}
.chart-title {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 20px;
    color: var(--primary);
    text-align: center;
    position: relative;
    padding-bottom: 10px;
}

.chart-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 50px;
    height: 3px;
    background-color: var(--secondary);
    border-radius: 3px;
}

.large-chart {
    grid-column: span 2;
}

/* Loading Overlay */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(255, 255, 255, 0.9);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.spinner {
    border: 4px solid rgba(0, 0, 0, 0.1);
    width: 50px;
    height: 50px;
    border-radius: 50%;
    border-left-color: var(--secondary);
    animation: spin 1s linear infinite;
}

.loading-text {
    margin-top: 15px;
    font-weight: 600;
    color: var(--primary);
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Footer */
footer {
    text-align: center;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid var(--border);
    font-size: 14px;
    color: #757575;
}

/* Error Message */
.error-message {
    background-color: #f44336;
    color: white;
    padding: 20px;
    border-radius: 10px;
    margin: 20px 0;
    text-align: center;
    box-shadow: 0 2px 5px var(--shadow);
}

.error-message button {
    background-color: white;
    color: #f44336;
    border: none;
    padding: 10px 20px;
    margin-top: 15px;
    border-radius: 5px;
    cursor: pointer;
    font-weight: 600;
    transition: background-color 0.3s;
}

.error-message button:hover {
    background-color: #f1f1f1;
}

/* File Input */
.file-input-container {
    text-align: center;
    padding: 30px;
    background-color: var(--card-bg);
    border-radius: 10px;
    margin-bottom: 20px;
    box-shadow: 0 2px 5px var(--shadow);
}

.file-input-container label {
    display: block;
    margin-bottom: 15px;
    font-weight: 600;
    color: var(--primary);
}

.file-input-container input[type="file"] {
    display: block;
    margin: 0 auto;
    padding: 15px;
    border: 2px dashed var(--border);
    border-radius: 10px;
    width: 100%;
    max-width: 500px;
    background-color: var(--background);
}

/* Responsive Design */
@media (max-width: 992px) {
    .large-chart {
        grid-column: span 1;
    }
}

@media (max-width: 768px) {
    .sidebar {
        width: 70px;
        overflow: visible;
    }
    
    .sidebar:hover {
        width: var(--sidebar-width);
    }
    
    .profile-section h3, .profile-section p, .filter-label, .filters-container {
        display: none;
    }
    
    .sidebar:hover .profile-section h3, 
    .sidebar:hover .profile-section p, 
    .sidebar:hover .filter-label, 
    .sidebar:hover .filters-container {
        display: block;
    }
    
    .sidebar-nav span {
        display: none;
    }
    
    .sidebar:hover .sidebar-nav span {
        display: inline;
    }
    
    .main-content {
        margin-left: 70px;
        width: calc(100% - 70px);
    }
    
    .dashboard {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 576px) {
    .stats-container {
        flex-direction: column;
    }
    
    .dashboard-header {
        flex-direction: column;
        gap: 10px;
        align-items: flex-start;
    }
}