.graficos-page {
    max-width: 1100px;
    padding: 1.25rem 1rem 2.5rem;
}

.g-top {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 1rem;
}

.g-top h1 {
    margin: 0;
    font-size: 1.4rem;
}

.g-top p {
    margin: 0.25rem 0 0;
    color: #6b7280;
    font-size: 0.9rem;
}

.g-nav {
    display: flex;
    gap: 0.75rem;
    font-size: 0.88rem;
}

.g-nav a {
    color: #1d4ed8;
    text-decoration: none;
    font-weight: 600;
}

.g-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: 0.75rem;
    margin-bottom: 1.25rem;
    padding: 0.75rem 1rem;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
}

.g-bar label {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    font-size: 0.85rem;
    font-weight: 600;
}

.g-bar input {
    padding: 0.5rem;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    font: inherit;
}

.g-btn {
    padding: 0.55rem 1.1rem;
    background: #1d4ed8;
    color: #fff;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
}

.g-kpi {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.65rem;
    margin-bottom: 1.25rem;
}

.g-kpi-box {
    background: #fef2f2;
    color: #991b1b;
    text-align: center;
    padding: 0.85rem;
    border-radius: 10px;
    font-size: 0.8rem;
    font-weight: 600;
}

.g-kpi-box span {
    display: block;
    font-size: 1.6rem;
    font-weight: 800;
    line-height: 1.2;
}

.g-kpi-box.g-amber { background: #fffbeb; color: #92400e; }
.g-kpi-box.g-green { background: #ecfdf5; color: #047857; }
.g-kpi-box.g-blue { background: #eff6ff; color: #1d4ed8; }

.g-grid-charts {
    display: grid;
    grid-template-columns: 1.2fr 1fr 1fr;
    gap: 1rem;
    margin-bottom: 1rem;
}

.g-card {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 1rem 1.1rem;
    margin-bottom: 1rem;
}

.g-card-wide {
    margin-bottom: 1rem;
}

.g-card h2 {
    margin: 0 0 0.75rem;
    font-size: 0.95rem;
    font-weight: 700;
}

.g-hint {
    margin: -0.35rem 0 0.75rem;
    font-size: 0.8rem;
    color: #6b7280;
}

.g-chart-wrap {
    position: relative;
    height: 220px;
}

.g-chart-sm {
    height: 200px;
}

.g-chart-tall {
    height: 420px;
}

.g-heatmap-wrap {
    overflow-x: auto;
}

.g-heatmap {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.85rem;
}

.g-heatmap th,
.g-heatmap td {
    padding: 0.5rem 0.4rem;
    text-align: center;
    border: 1px solid #f3f4f6;
}

.g-heatmap th {
    background: #f9fafb;
    font-weight: 700;
    font-size: 0.78rem;
}

.g-prov-name {
    text-align: left !important;
    font-weight: 600;
    white-space: nowrap;
    min-width: 140px;
}

.g-cell.ok {
    background: #d1fae5;
    color: #047857;
    font-weight: 700;
}

.g-cell.no {
    background: #f3f4f6;
    color: #9ca3af;
}

.g-total {
    font-weight: 700;
    background: #f9fafb;
}

@media (max-width: 900px) {
    .g-grid-charts {
        grid-template-columns: 1fr;
    }

    .g-kpi {
        grid-template-columns: repeat(2, 1fr);
    }
}
