:root {
    --report-ink: #19364a;
    --report-muted: #64727c;
    --report-line: #dce4e7;
    --report-paper: #ffffff;
    --report-blue: #3272a5;
    --report-amber: #c48a20;
    --report-green: #25836d;
    --report-coral: #cb6258;
    --report-teal: #167f82;
}

body {
    overflow-x: hidden;
    font-size: .9375rem;
    line-height: 1.5;
}

main.container > h1,
main.container > .h1,
main.container > .d-flex h1,
.report-heading h1 {
    font-size: clamp(1.45rem, 1.2rem + .65vw, 1.75rem);
    line-height: 1.25;
}

.navbar-brand { font-size: 1rem; }
.navbar .nav-link,
.navbar-text { font-size: .875rem; }

.form-label { font-size: .875rem; }
.form-control,
.form-select { font-size: .9rem; }

.table {
    font-size: .875rem;
    line-height: 1.4;
}

.table > :not(caption) > * > * {
    padding: .55rem .7rem;
}

.table thead th {
    color: #526773;
    font-size: .78rem;
    font-weight: 700;
    letter-spacing: .015em;
}

.table .badge { font-size: .72rem; }

main.container,
.navbar .container,
.navbar-collapse,
.navbar-nav,
.card,
.row > * {
    min-width: 0;
}

.navbar-brand {
    max-width: 100%;
    white-space: normal;
    overflow-wrap: anywhere;
}

.navbar-text {
    white-space: normal;
    overflow-wrap: anywhere;
}

.form-control,
.form-select {
    min-width: 0;
    max-width: 100%;
}

.table-responsive {
    max-width: 100%;
    -webkit-overflow-scrolling: touch;
}

.table-responsive > .table {
    min-width: 720px;
}

.report-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.25rem;
    padding: 1.4rem 1.5rem;
    color: var(--report-ink);
    background: #e9f2ef;
    border-left: 5px solid var(--report-teal);
    border-radius: 8px;
}

.report-heading h1 {
    margin: 0 0 .35rem;
    font-size: 1.8rem;
    font-weight: 700;
}

.report-heading p:not(.report-eyebrow) {
    color: #526773;
}

.report-eyebrow,
.report-panel__eyebrow {
    margin: 0 0 .35rem;
    color: #56736f;
    font-size: .72rem;
    font-weight: 700;
    letter-spacing: .08em;
}

.report-export {
    flex: 0 0 auto;
    white-space: nowrap;
}

.report-actions,
.report-chart-legend,
.report-chart-legend span {
    display: flex;
    align-items: center;
}

.report-actions { flex: 0 0 auto; gap: .55rem; }
.report-export span {
    margin-right: .35rem;
    font-size: 1.05rem;
}

.report-status-visual {
    display: flex;
    justify-content: center;
    margin: .25rem 0 1rem;
}

.report-donut {
    position: relative;
    display: grid;
    width: 144px;
    height: 144px;
    place-items: center;
    border-radius: 50%;
}

.report-donut::before {
    position: absolute;
    width: 96px;
    height: 96px;
    background: var(--report-paper);
    border-radius: 50%;
    content: "";
}

.report-donut > span {
    z-index: 1;
    display: grid;
    color: var(--report-ink);
    text-align: center;
}

.report-donut strong { font-size: 1.6rem; line-height: 1.1; }
.report-donut small { color: var(--report-muted); font-size: .72rem; }

.report-chart-legend { flex-wrap: wrap; gap: .75rem; color: var(--report-muted); font-size: .76rem; }
.report-chart-legend span { gap: .35rem; }
.report-dot--total { background: var(--report-blue); }
.report-dot--resolved { background: var(--report-green); }

.report-month-chart {
    display: grid;
    grid-template-columns: repeat(12, minmax(0, 1fr));
    gap: .45rem;
    min-height: 190px;
    padding: .75rem .25rem 0;
    border-bottom: 1px solid var(--report-line);
}

.report-month-chart__column {
    display: grid;
    grid-template-rows: 1fr auto auto;
    gap: .3rem;
    min-width: 0;
    color: var(--report-muted);
    text-align: center;
    font-size: .68rem;
}

.report-month-chart__column > strong { color: var(--report-ink); font-size: .72rem; }
.report-month-chart__bars { display: flex; align-items: flex-end; justify-content: center; gap: 3px; height: 130px; }
.report-month-chart__bar { width: min(35%, 18px); min-height: 0; border-radius: 4px 4px 0 0; }
.report-month-chart__bar--total { background: var(--report-blue); }
.report-month-chart__bar--resolved { background: var(--report-green); }

.report-kpi {
    height: 100%;
    padding: 1rem 1.1rem;
    background: var(--report-paper);
    border: 1px solid var(--report-line);
    border-top: 4px solid var(--kpi-tone, var(--report-teal));
    border-radius: 8px;
}

.report-kpi--total { --kpi-tone: var(--report-teal); }
.report-kpi--blue { --kpi-tone: var(--report-blue); }
.report-kpi--amber { --kpi-tone: var(--report-amber); }
.report-kpi--green { --kpi-tone: var(--report-green); }
.report-kpi--coral { --kpi-tone: var(--report-coral); }

.report-kpi__label {
    min-height: 1.4em;
    color: var(--report-muted);
    font-size: .84rem;
    font-weight: 600;
}

.report-kpi__value {
    display: block;
    margin: .35rem 0 .55rem;
    color: var(--report-ink);
    font-size: 1.9rem;
    line-height: 1.1;
    font-variant-numeric: tabular-nums;
}

.report-kpi__meta {
    display: flex;
    justify-content: space-between;
    gap: .5rem;
    color: var(--report-muted);
    font-size: .75rem;
}

.report-kpi__track,
.report-category__track {
    overflow: hidden;
    height: 6px;
    margin-top: .55rem;
    background: #edf1f2;
    border-radius: 999px;
}

.report-kpi__track span,
.report-category__track span {
    display: block;
    height: 100%;
    background: var(--kpi-tone, var(--report-teal));
    border-radius: inherit;
}

.report-panel,
.report-table-panel {
    overflow: hidden;
    background: var(--report-paper);
    border: 1px solid var(--report-line);
    border-radius: 8px;
}

.report-panel {
    padding: 1.25rem;
}

.report-panel__heading,
.report-table-panel__heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: .75rem;
    margin-bottom: 1.1rem;
}

.report-panel__heading h2,
.report-table-panel__heading h2 {
    margin: 0;
    color: var(--report-ink);
    font-size: 1.08rem;
    font-weight: 700;
}

.report-panel__total {
    flex: 0 0 auto;
    padding: .25rem .55rem;
    color: #526773;
    background: #f0f4f4;
    border-radius: 5px;
    font-size: .76rem;
    font-variant-numeric: tabular-nums;
}

.report-stack {
    display: flex;
    gap: 3px;
    overflow: hidden;
    height: 12px;
    margin-bottom: 1rem;
    background: #edf1f2;
    border-radius: 999px;
}

.report-stack__segment { min-width: 3px; }
.report-stack__segment--blue { background: var(--report-blue); }
.report-stack__segment--amber { background: var(--report-amber); }
.report-stack__segment--green { background: var(--report-green); }
.report-stack__segment--coral { background: var(--report-coral); }

.report-legend {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: .2rem 1rem;
}

.report-legend li,
.report-legend__name,
.report-legend li > strong {
    display: flex;
    align-items: center;
}

.report-legend li {
    justify-content: space-between;
    gap: .4rem;
    padding: .55rem 0;
    border-bottom: 1px solid #edf1f2;
    color: var(--report-ink);
    font-size: .83rem;
}

.report-legend__name { gap: .45rem; min-width: 0; }
.report-legend li > strong { gap: .4rem; font-variant-numeric: tabular-nums; }
.report-legend small { color: var(--report-muted); font-size: .72rem; font-weight: 500; }

.report-dot {
    flex: 0 0 9px;
    width: 9px;
    height: 9px;
    border-radius: 50%;
}

.report-dot--blue { background: var(--report-blue); }
.report-dot--amber { background: var(--report-amber); }
.report-dot--green { background: var(--report-green); }
.report-dot--coral { background: var(--report-coral); }

.report-category-list { display: grid; gap: .9rem; }
.report-category__heading { display: flex; justify-content: space-between; gap: .75rem; color: var(--report-ink); font-size: .85rem; }
.report-category__heading > span { display: flex; align-items: center; gap: .55rem; min-width: 0; overflow-wrap: anywhere; }
.report-category__heading > strong { flex: 0 0 auto; font-variant-numeric: tabular-nums; }
.report-category__rank { display: inline-grid; flex: 0 0 1.4rem; width: 1.4rem; height: 1.4rem; place-items: center; color: #54717b; background: #edf3f2; border-radius: 4px; font-size: .7rem; font-style: normal; }
.report-category__track { margin-top: .4rem; }
.report-category__track span { background: var(--report-teal); }
.report-empty { padding: 1rem; color: var(--report-muted); background: #f5f7f7; border-radius: 6px; }

.report-table-panel__heading {
    align-items: center;
    margin: 0;
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--report-line);
}

.report-table-panel .table { margin-bottom: 0; }
.report-table-panel .table th { color: #526773; font-size: .76rem; font-weight: 700; white-space: nowrap; }
.report-table-panel .table td { white-space: nowrap; }

@media (min-width: 768px) and (max-width: 1199.98px) {
    .card > .card-body > form.row.g-2 > .col-md-2 {
        flex: 0 0 auto;
        width: 33.33333333%;
    }
}

@media (max-width: 767.98px) {
    .report-heading { align-items: flex-start; flex-direction: column; padding: 1.1rem; }
    .report-actions { width: 100%; }
    .report-actions > * { flex: 1 1 0; }
    .report-panel { padding: 1rem; }
    .report-kpi { padding: .9rem; }
    .report-kpi__value { font-size: 1.65rem; }
    .report-table-panel__heading { padding: .9rem 1rem; }
}

@media print {
    @page { size: A4 portrait; margin: 13mm; }

    body { overflow: visible; color: #172b3a; background: #fff !important; font-size: 9pt; }
    .navbar,
    footer,
    .report-filter,
    .report-actions,
    .btn { display: none !important; }
    .report-methodology { display: block !important; }
    main.container { width: 100%; max-width: 184mm; margin: 0 auto; padding: 0 !important; }
    .report-heading { align-items: flex-start; padding: 0 0 6mm; color: #172b3a; background: #fff; border-bottom: 2px solid #167f82; border-left: 0; border-radius: 0; }
    .report-heading h1 { font-size: 18pt; }
    .report-heading p:not(.report-eyebrow) { margin: 0; }
    .report-executive-kpis,
    .report-panel,
    .report-table-panel { break-inside: avoid; }
    .report-executive-kpis,
    .report-dashboard > .row:first-child {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 3mm;
        margin: 0 0 5mm !important;
    }
    .report-executive-kpis > *,
    .report-dashboard > .row:first-child > * {
        width: auto;
        padding: 0;
    }
    .report-dashboard > .row.g-3:not(:first-child) {
        display: grid;
        grid-template-columns: minmax(0, 1fr);
        gap: 4mm;
        margin: 0 0 5mm;
    }
    .report-dashboard > .row.g-3 > * { width: auto; padding: 0; }
    .report-panel,
    .report-table-panel,
    .report-kpi { border-color: #cbd5da; box-shadow: none !important; }
    .report-panel { padding: 4mm; }
    .report-month-chart { min-height: 125px; }
    .report-month-chart__bars { height: 78px; }
    .report-table-panel .table-responsive { overflow: visible; }
    .report-table-panel .table { min-width: 0; width: 100%; table-layout: fixed; font-size: 7.5pt; }
    .report-table-panel .table th:nth-child(1) { width: 9%; }
    .report-table-panel .table th:nth-child(2) { width: 14%; }
    .report-table-panel .table th:nth-child(3) { width: 13%; }
    .report-table-panel .table th:nth-child(4) { width: 10%; }
    .report-table-panel .table th:nth-child(5) { width: 10%; }
    .report-table-panel .table th:nth-child(6) { width: 14%; }
    .report-table-panel .table th:nth-child(7),
    .report-table-panel .table th:nth-child(8) { width: 15%; }
    .report-table-panel .table th,
    .report-table-panel .table td {
        padding: 2.5px;
        white-space: normal;
        overflow-wrap: anywhere;
        vertical-align: top;
    }
    .report-table-panel .table th { font-size: 6.8pt; white-space: nowrap; }
    .report-table-panel thead { display: table-header-group; }
    .report-table-panel tr { break-inside: avoid; }
    .report-table-panel__heading { break-after: avoid; }
    .report-category__track,
    .report-month-chart__bar,
    .report-donut,
    .report-kpi__track span { print-color-adjust: exact; -webkit-print-color-adjust: exact; }
    a { color: inherit; text-decoration: none; }
}

@media (max-width: 575.98px) {
    .container { padding-right: 1rem; padding-left: 1rem; }
    .navbar-brand { font-size: .95rem; }
    .navbar-toggler { flex: 0 0 auto; }
    .table { font-size: .8125rem; }
    .table > :not(caption) > * > * { padding: .5rem .55rem; }
    .table thead th { font-size: .72rem; }
    .report-legend { grid-template-columns: 1fr; }
    .report-kpi__label { font-size: .78rem; }
    .report-panel__heading h2,
    .report-table-panel__heading h2 { font-size: 1rem; }
}