.analytics-nav {
    display: flex;
    gap: 25px;
    background: #fafbf7;
    padding: 13px 4%;
    border-bottom: 1px solid #e1e7dc;
    overflow-x: auto;
    font-size: 10px;
    color: #6f806e;
    white-space: nowrap;
}

.analytics-nav a.active {
    color: #214b3a;
    font-weight: 700;
}

.analytics-nav a:hover {
    color: #214b3a;
}

.module-filters {
    flex-wrap: wrap;
    gap: 13px;
}

.module-filters select {
    min-width: 150px;
}

.module-filters input {
    border: 1px solid #dbe0d7;
    border-radius: 5px;
    background: white;
    padding: 10px 12px;
    height: 37px;
    font-size: 12px;
    color: #51694f;
    min-width: 0;
}

.export-report {
    border: 1px solid #d3decb;
    border-radius: 5px;
    padding: 12px 16px;
    color: #688060;
    font-size: 11px;
    white-space: nowrap;
}

.report-metrics {
    /* A quantidade de indicadores varia por análise (4 a 12). */
    grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
}

@media (max-width:720px) {
    .report-metrics {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    }
}

.report-metrics .metric strong {
    font-size: 23px;
    letter-spacing: -.8px;
    overflow-wrap: anywhere;
}

.report-metrics .metric p {
    line-height: 1.7;
}

.report-table {
    margin-top: 25px;
}

.report-table h2 {
    margin-bottom: 17px;
}

.distribution {
    margin-bottom: 25px;
}

.distribution-row {
    display: grid;
    grid-template-columns: 200px minmax(0,1fr) 200px;
    align-items: center;
    gap: 20px;
    margin: 20px 0;
    font-size: 11px;
    color: #829077;
}

.distribution-row>strong {
    font-size: 10px;
    color: #607351;
    font-weight: 500;
    text-align: right;
}

.distribution-track {
    position: relative;
    height: 8px;
    background: #edf1e7;
    border-radius: 3px;
    overflow: hidden;
}

.distribution-track i,
.distribution-track b {
    position: absolute;
    left: 0;
    top: 0;
    display: block;
    height: 100%;
    border-radius: 3px;
}

.distribution-track i {
    background: #608463;
}

/* Barra secundária (ex.: lançado, previsto, contratado) atrás da principal. */
.distribution-track b {
    background: #d8c9a6;
}

.distribution-row.compact {
    grid-template-columns: 90px minmax(0, 1fr) 150px;
    margin: 12px 0;
}

.chart-legend {
    display: flex;
    gap: 16px;
    font-size: 10px;
    color: var(--muted);
}

.chart-legend i {
    display: inline-block;
    width: 10px;
    height: 8px;
    border-radius: 2px;
    margin-right: 6px;
    vertical-align: middle;
}

.chart-legend .primary i {
    background: #608463;
}

.chart-legend .secondary i {
    background: #d8c9a6;
}

/* Colunas mensais (análises). */
.column-panel {
    margin-bottom: 25px;
}

.column-chart {
    display: flex;
    gap: 6px;
    height: 170px;
    align-items: stretch;
    border-bottom: 1px solid var(--line);
}

.column {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    font-size: 8px;
    color: var(--muted);
}

.column-track {
    flex: 1;
    width: 70%;
    display: flex;
    align-items: flex-end;
}

.column-track i {
    display: block;
    width: 100%;
    background: #426558;
    border-radius: 3px 3px 0 0;
}

.column.negative .column-track i {
    background: #b0795b;
}

.column.projected .column-track i {
    opacity: .45;
}

.column>span {
    padding: 8px 0 4px;
    white-space: nowrap;
}

/* Curva S. */
:root {
    --curve-physical-planned: #8fb2a2;
    --curve-physical-actual: #173e35;
    --curve-financial-planned: #d8c59f;
    --curve-financial-actual: #a9853f;
}

.curve-panel {
    margin-bottom: 25px;
}

.curve-legend {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    margin-top: 18px;
    font-size: 9px;
    color: #6f806e;
}

.curve-legend i {
    display: inline-block;
    width: 16px;
    height: 0;
    border-top: 3px solid var(--line-color);
    margin-right: 7px;
    vertical-align: middle;
}

.curve-legend i.dashed {
    border-top-style: dashed;
}

.s-curve {
    display: block;
    width: 100%;
    max-height: 330px;
    margin-top: 16px;
}

.s-curve-grid path {
    stroke: #e8ede5;
    fill: none;
}

.s-curve-axis {
    fill: #859380;
    font-size: 10px;
}

.s-curve polyline {
    fill: none;
    stroke-width: 3;
    stroke-linejoin: round;
}

.s-curve polyline.dashed {
    stroke-dasharray: 6 5;
    stroke-width: 2.5;
}

.s-curve-reference line {
    stroke: var(--gold);
    stroke-dasharray: 2 3;
}

.s-curve-reference text {
    fill: var(--gold);
    font-size: 9px;
}

/* Gantt. */
.gantt-scroll {
    overflow: auto;
    margin-top: 20px;
}

.gantt {
    min-width: 900px;
}

.gantt-row {
    display: grid;
    grid-template-columns: 220px minmax(0, 1fr) 50px;
    gap: 20px;
    align-items: center;
    min-height: 52px;
    border-bottom: 1px solid #e8eee1;
}

.gantt-header {
    min-height: 32px;
    font-size: 9px;
    color: var(--muted);
    letter-spacing: .5px;
    text-transform: uppercase;
}

.gantt-scale {
    display: flex;
    justify-content: space-between;
}

.gantt-group {
    padding: 16px 0 6px;
    font-size: 11px;
    font-weight: 700;
    color: var(--green);
    border-bottom: 1px solid var(--line);
}

.gantt-row strong {
    font-weight: 500;
    font-size: 11px;
    color: #4f6254;
}

.gantt-row small {
    display: block;
    font-size: 9px;
    color: #8c9b88;
    margin-top: 4px;
}

.gantt-row>span {
    font-size: 10px;
    color: #62755f;
}

.gantt-row>span.is-behind {
    color: #a5623f;
    font-weight: 700;
}

.gantt-track {
    height: 52px;
    position: relative;
    background: repeating-linear-gradient(to right, transparent 0, transparent calc(10% - 1px), #edf1e6 10%);
}

/* Linha da data-base. */
.gantt-track::after {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    left: var(--reference);
    border-left: 1px dashed var(--gold);
}

.gantt-bar {
    position: absolute;
    top: 17px;
    height: 18px;
    background: #dbe6d9;
    border-radius: 3px;
    overflow: hidden;
}

.gantt-bar i {
    display: block;
    height: 100%;
    background: #5d8570;
}

.gantt-bar.behind i {
    background: #b58a55;
}

/* Marcador do previsto na data-base. */
.gantt-bar b {
    position: absolute;
    top: 0;
    bottom: 0;
    width: 2px;
    margin-left: -1px;
    background: var(--green);
}

.pagination {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 20px;
    font-size: 10px;
    margin-top: 24px;
    color: #94a780;
}

.pagination a {
    padding: 8px 12px;
    background: #f2f5ec;
    border: 1px solid #e0e8d6;
    border-radius: 3px;
}

.report-note {
    font-size: 10px;
    color: #8c9b7b;
    line-height: 1.9;
    padding: 20px 0;
    max-width: 1000px;
}

.report-table summary {
    cursor: pointer;
    font-size: 13px;
    color: #7f956b;
}

.report-table summary+div {
    margin-top: 20px;
}

@media (max-width:900px) {
    .report-metrics .metric strong {
        font-size: 18px;
    }
    .distribution-row {
        grid-template-columns: 130px minmax(0,1fr) 150px;
        gap: 12px;
    }
}

@media (max-width:650px) {
    .analytics-nav {
        font-size: 9px;
        gap: 23px;
        padding: 13px 18px;
    }
    .module-filters label {
        min-width: 130px;
    }
    .module-filters select {
        min-width: 0;
    }
    .module-filters input {
        width: 100%;
    }
    .report-metrics .metric strong {
        font-size: 18px;
        letter-spacing: -.7px;
    }
    .distribution-row {
        grid-template-columns: 1fr 1fr;
        gap: 10px;
        font-size: 10px;
    }
    .distribution-track {
        grid-column: 1/-1;
        grid-row: auto;
    }
    .distribution-row>strong {
        grid-column: 2;
        grid-row: auto;
        font-size: 9px;
    }
    .distribution-row>span {
        grid-column: 1/-1;
    }
    .distribution-row .distribution-track {
        grid-column: 1;
    }
    .export-report {
        font-size: 9px;
        padding: 9px;
        max-width: 110px;
        white-space: normal;
    }
    .curve-legend {
        gap: 12px;
        font-size: 8px;
    }
    .pagination {
        gap: 12px;
        font-size: 9px;
        justify-content: center;
    }
    .report-note {
        font-size: 9px;
    }
    .report-table h2 {
        font-size: 16px;
    }
}
