.mensual-container {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.mensual-chart {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    height: 160px;
    gap: 0.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid #e5e7eb;
}

.mensual-grupo {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.25rem;
}

.mensual-barras {
    display: flex;
    gap: 2px;
    height: 140px;
    align-items: flex-end;
}

.mensual-barra {
    width: 14px;
    border-radius: 8px 3px 0 0;
    transition: height 0.5s ease;
    min-height: 4px;
}

.mensual-barra.abierta { background: #dc2626; }
.mensual-barra.cerrada { background: #16a34a; }

.mensual-label {
    font-size: 0.6875rem;
    color: #6b7280;
}

.mensual-legend {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    font-size: 0.75rem;
    color: #6b7280;
}

.cumplimiento-container {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.cumplimiento-item {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.cumplimiento-header {
    display: flex;
    justify-content: space-between;
    font-size: 0.8125rem;
}

.cumplimiento-area { color: #374151; }
.cumplimiento-pct { font-weight: 600; color: var(--enaex-gris-corp); }

.cumplimiento-bar {
    height: 8px;
    background: #e5e7eb;
    border-radius: 8px;
    overflow: hidden;
}

.cumplimiento-fill {
    height: 100%;
    border-radius: 8px;
    transition: width 0.5s ease;
}

.cumplimiento-fill.alto { background: #16a34a; }
.cumplimiento-fill.medio { background: #f59e0b; }
.cumplimiento-fill.bajo { background: #dc2626; }

.riesgo-item {
    display: flex;
    flex-direction: column;
    gap: 0.375rem;
}

.riesgo-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.riesgo-valor {
    font-weight: 600;
    color: var(--enaex-gris-corp);
}

.riesgo-bar {
    height: 8px;
    background: #e5e7eb;
    border-radius: 8px;
    overflow: hidden;
}

.riesgo-fill {
    height: 100%;
    border-radius: 8px;
}

.riesgo-fill.critico { background: #dc2626; }
.riesgo-fill.alto { background: #ea580c; }
.riesgo-fill.medio { background: #f59e0b; }
.riesgo-fill.bajo { background: #16a34a; }

.tendencia-container {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.tendencia-stats {
    display: flex;
    gap: 2rem;
}

.tendencia-stat {
    display: flex;
    flex-direction: column;
}

.stat-valor.positivo { color: #16a34a; }
.stat-valor.negativo { color: #dc2626; }

.tendencia-chart {
    display: flex;
    align-items: flex-end;
    height: 80px;
    gap: 4px;
    border-bottom: 1px solid #e5e7eb;
    padding-bottom: 0.5rem;
}

.tendencia-punto {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    min-height: 10px;
    background: linear-gradient(to top, #35424A20, #35424A05);
    border-radius: 8px 4px 0 0;
}

.tendencia-labels {
    display: flex;
    justify-content: space-between;
    font-size: 0.625rem;
    color: #9ca3af;
}

.btn-limpiar {
    padding: 0.375rem 0.75rem;
    background: #f3f4f6;
    color: #374151;
    border: 1px solid var(--gris-300);
    border-radius: 8px;
    font-size: 0.75rem;
    cursor: pointer;
    transition: background 0.2s;
}

.btn-limpiar:hover {
    background: #e5e7eb;
}

@media (max-width: 600px) {
    .tabla-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
}

@media (max-width: 480px) {
    .dashboard-page {
        padding: 0.5rem;
    }

    .seccion-kpis {
        gap: 0.5rem;
    }

    .kpi-card {
        padding: 0.65rem 0.75rem;
        gap: 0.55rem;
        border-radius: 6px;
    }

    .kpi-valor {
        font-size: 1.3rem;
    }

    .chart-card {
        padding: 0.6rem;
        border-radius: 6px;
    }

    .chart-total-badge {
        right: 8px;
        bottom: 8px;
        padding: 2px 7px;
        font-size: 11px;
    }

    .seccion-graficos {
        gap: 0.5rem;
    }

    .filtro-select {
        font-size: 16px;
        padding: 0.5rem 0.75rem;
        width: 100%;
    }

    .dashboard-header {
        flex-direction: column;
        align-items: stretch;
        gap: 0.5rem;
        margin-bottom: 0.75rem;
    }

    .dashboard-header h1 {
        font-size: 1.15rem;
    }

    .estado-carga {
        padding: 1.5rem;
    }
}
