:root {
    --bg: #f5f7fb;
    --panel: #ffffff;
    --ink: #172033;
    --muted: #647084;
    --line: #d9e0ea;
    --accent: #1f6fb2;
    --accent-dark: #174f7f;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    min-height: 100vh;
    background: var(--bg);
    color: var(--ink);
    font-family: Arial, Helvetica, sans-serif;
}

.app-shell {
    width: min(1120px, calc(100% - 32px));
    margin: 0 auto;
    padding: 40px 0;
}

.hero {
    display: flex;
    align-items: center;
    min-height: 260px;
    border-bottom: 1px solid var(--line);
}

.topbar {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 24px;
    padding: 40px 0 28px;
    border-bottom: 1px solid var(--line);
}

.actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.inline-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.eyebrow {
    margin: 0 0 10px;
    color: var(--accent-dark);
    font-size: 13px;
    font-weight: 700;
    text-transform: uppercase;
}

h1 {
    margin: 0;
    max-width: 760px;
    font-size: clamp(34px, 6vw, 58px);
    line-height: 1;
    letter-spacing: 0;
}

.lead {
    max-width: 720px;
    margin: 18px 0 0;
    color: var(--muted);
    font-size: 18px;
    line-height: 1.55;
}

.hero-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 22px;
}

.grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
    margin-top: 24px;
}

.detail-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
    margin-top: 24px;
}

.metric-row {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
    margin-top: 24px;
}

.metric-row article {
    min-height: 135px;
}

.metric-row h2 {
    margin-top: 8px;
    font-size: 34px;
}

.map-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 320px;
    gap: 18px;
    margin-top: 24px;
    align-items: stretch;
}

.municipal-map {
    position: relative;
    min-height: 560px;
    background: #eef3f7;
    border: 1px solid var(--line);
    border-radius: 8px;
    overflow: hidden;
}

.municipal-map::before {
    content: "";
    position: absolute;
    inset: 28px 36px;
    background: #ffffff;
    border: 2px solid #b8c6d7;
    border-radius: 46% 54% 48% 52% / 42% 44% 56% 58%;
}

.municipal-map-seccional {
    display: flex;
    flex-direction: column;
    min-height: 560px;
    padding: 18px;
    background: linear-gradient(180deg, #f8fbfd 0%, #edf3f7 100%);
}

.municipal-map-seccional::before {
    display: none;
}

.map-stage {
    display: grid;
    place-items: center;
    min-height: 620px;
    background: #ffffff;
    border: 1px solid #d5dee9;
    border-radius: 8px;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.6);
    overflow: hidden;
}

.sectional-svg {
    width: min(100%, 940px);
    height: auto;
    max-height: 640px;
}

.sectional-svg-general {
    display: block;
}

.map-general-image {
    pointer-events: none;
}

.map-section {
    cursor: pointer;
}

.map-section-image {
    opacity: 0.34;
    filter: saturate(0.25) contrast(1.08);
    pointer-events: none;
}

.map-section-tint {
    stroke: none;
    opacity: 0;
    transition: opacity 160ms ease;
}

.map-section-border {
    fill: transparent;
    stroke: rgba(31, 111, 178, 0);
    stroke-width: 4;
    stroke-linejoin: round;
    filter: none;
    transition: filter 160ms ease, stroke 160ms ease, stroke-width 160ms ease;
}

.map-section-high .map-section-tint {
    fill: #bfe9d0;
}

.map-section-medium .map-section-tint {
    fill: #ffe6a6;
}

.map-section-low .map-section-tint {
    fill: #f6c0bd;
}

.map-section:hover .map-section-tint,
.map-section:focus .map-section-tint {
    opacity: 0.22;
}

.map-section:hover .map-section-border,
.map-section:focus .map-section-border {
    stroke: rgba(31, 111, 178, 0.38);
    stroke-width: 2;
    filter: drop-shadow(0 8px 12px rgba(23, 32, 51, 0.14));
}

.map-section:focus {
    outline: 0;
}

.map-callout-line {
    stroke: #60758d;
    stroke-width: 2;
    stroke-dasharray: 4 4;
    opacity: 0.28;
    transition: opacity 160ms ease, stroke-width 160ms ease;
}

.map-section:hover .map-callout-line,
.map-section:focus .map-callout-line {
    opacity: 0.85;
    stroke-width: 3;
}

.map-label rect {
    fill: rgba(255, 255, 255, 0.96);
    stroke: #b9c6d5;
    stroke-width: 2;
    transition: stroke 160ms ease, stroke-width 160ms ease;
}

.map-label-code {
    fill: #132033;
    font-size: 24px;
    font-weight: 800;
}

.map-label-coverage {
    fill: #132033;
    font-size: 14px;
    font-weight: 700;
}

.map-section:hover .map-label rect,
.map-section:focus .map-label rect {
    stroke: rgba(31, 111, 178, 0.72);
    stroke-width: 3;
}

.map-legend-row {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-wrap: wrap;
    margin-top: 12px;
    color: var(--muted);
    font-size: 13px;
}

.map-legend-row span {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.map-legend-row strong {
    margin-left: auto;
    color: var(--accent-dark);
    font-size: 12px;
}

.legend-dot {
    width: 12px;
    height: 12px;
    border: 1px solid rgba(23, 32, 51, 0.18);
    border-radius: 50%;
}

.legend-high {
    background: #bfe9d0;
}

.legend-medium {
    background: #ffe6a6;
}

.legend-low {
    background: #f6c0bd;
}

.zone {
    position: absolute;
    display: grid;
    place-items: center;
    min-width: 78px;
    min-height: 58px;
    padding: 8px;
    color: #102033;
    border: 1px solid rgba(23, 32, 51, 0.18);
    border-radius: 8px;
    text-align: center;
    box-shadow: 0 8px 18px rgba(23, 32, 51, 0.08);
    cursor: pointer;
}

.zone:hover,
.zone:focus {
    outline: 3px solid rgba(31, 111, 178, 0.25);
    transform: translateY(-1px);
}

.zone strong {
    font-size: 18px;
}

.zone span {
    font-size: 12px;
    font-weight: 700;
}

.zone-high {
    background: #bfe9d0;
}

.zone-medium {
    background: #ffe6a6;
}

.zone-low {
    background: #f6c0bd;
}

.zone-1 { left: 31%; top: 8%; }
.zone-2 { left: 45%; top: 7%; }
.zone-3 { left: 59%; top: 12%; }
.zone-4 { left: 18%; top: 22%; }
.zone-5 { left: 34%; top: 24%; }
.zone-6 { left: 49%; top: 24%; }
.zone-7 { left: 65%; top: 27%; }
.zone-8 { left: 73%; top: 40%; }
.zone-9 { left: 26%; top: 42%; }
.zone-10 { left: 42%; top: 44%; }
.zone-11 { left: 56%; top: 45%; }
.zone-12 { left: 16%; top: 58%; }
.zone-13 { left: 33%; top: 61%; }
.zone-14 { left: 49%; top: 62%; }
.zone-15 { left: 64%; top: 64%; }
.zone-16 { left: 38%; top: 78%; }
.zone-17 { left: 55%; top: 80%; }

.map-panel {
    padding: 22px;
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 8px;
}

.section-card {
    min-height: 0;
    padding: 18px;
}

.section-card-high {
    border-top: 4px solid #35a867;
}

.section-card-medium {
    border-top: 4px solid #d99a16;
}

.section-card-low {
    border-top: 4px solid #d75b55;
}

.section-card-header {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: flex-start;
}

.section-card-header h2 {
    margin: 6px 0 0;
    font-size: 18px;
}

.section-card-header strong {
    padding: 5px 8px;
    color: var(--accent-dark);
    background: #e8f1f8;
    border-radius: 999px;
    font-size: 12px;
}

.section-card-main {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin-top: 16px;
}

.section-card-main div {
    padding: 10px;
    background: #f8fafc;
    border: 1px solid var(--line);
    border-radius: 8px;
}

.section-card-main small,
.progress-label span {
    display: block;
    color: var(--muted);
    font-size: 12px;
    font-weight: 700;
}

.section-card-main strong {
    display: block;
    margin-top: 5px;
    font-size: 21px;
}

.progress-block {
    display: grid;
    gap: 7px;
    margin-top: 14px;
}

.progress-label {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    align-items: center;
}

.progress-label strong {
    font-size: 13px;
}

.progress-track {
    height: 9px;
    overflow: hidden;
    background: #edf2f7;
    border-radius: 999px;
}

.progress-track span {
    display: block;
    height: 100%;
    background: var(--accent);
    border-radius: inherit;
}

.progress-track-muted span {
    background: #35a867;
}

.section-card-footer {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    margin-top: 14px;
    padding-top: 12px;
    color: var(--muted);
    border-top: 1px solid var(--line);
    font-size: 12px;
    font-weight: 700;
}

.modal-backdrop {
    position: fixed;
    inset: 0;
    z-index: 50;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: rgba(12, 21, 35, 0.58);
}

.modal-backdrop.is-open {
    display: flex;
}

.modal-card {
    width: min(960px, 100%);
    max-height: min(760px, calc(100vh - 48px));
    overflow: auto;
    background: var(--panel);
    box-shadow: 0 24px 70px rgba(12, 21, 35, 0.28);
}

.section-map-preview {
    margin-top: 18px;
    padding-top: 16px;
    border-top: 1px solid var(--line);
}

.section-map-heading {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: center;
    margin-bottom: 12px;
}

.section-map-heading span {
    color: var(--accent-dark);
    font-size: 13px;
    font-weight: 700;
}

.section-map-heading strong {
    color: var(--muted);
    font-size: 12px;
}

.section-map-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 12px;
}

.section-map-grid a {
    display: block;
    background: #f8fafc;
    border: 1px solid var(--line);
    border-radius: 8px;
    overflow: hidden;
}

.section-map-grid img {
    display: block;
    width: 100%;
    height: auto;
}

.modal-header-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.modal-header-actions strong {
    padding: 5px 8px;
    color: var(--accent-dark);
    background: #e8f1f8;
    border-radius: 999px;
    font-size: 12px;
}

.modal-close {
    display: grid;
    place-items: center;
    width: 34px;
    height: 34px;
    min-height: 34px;
    padding: 0;
    color: var(--ink);
    background: #f2f5f8;
    border: 1px solid var(--line);
    border-radius: 50%;
    font-size: 22px;
    line-height: 1;
}

article {
    min-height: 190px;
    padding: 20px;
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 8px;
}

article span {
    color: var(--accent);
    font-size: 13px;
    font-weight: 700;
}

h2 {
    margin: 12px 0 8px;
    font-size: 19px;
    line-height: 1.2;
}

article p {
    margin: 0;
    color: var(--muted);
    line-height: 1.5;
}

.auth-page {
    display: grid;
    min-height: calc(100vh - 80px);
    place-items: center;
}

.auth-panel {
    width: min(100%, 460px);
}

.form-card {
    display: grid;
    gap: 16px;
    margin-top: 24px;
    padding: 22px;
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 8px;
}

.filter-bar {
    display: grid;
    grid-template-columns: minmax(240px, 1.6fr) minmax(180px, 1fr) minmax(160px, 0.8fr) minmax(120px, 0.55fr) auto;
    gap: 14px;
    align-items: end;
    margin-top: 24px;
    padding: 16px;
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 8px;
}

.audit-filter-bar {
    grid-template-columns: minmax(190px, 1.2fr) minmax(160px, 1fr) minmax(150px, 1fr) minmax(130px, 0.75fr) minmax(130px, 0.75fr) minmax(110px, 0.55fr) auto;
}

.filter-actions {
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
}

.list-summary {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    margin-top: 16px;
    color: var(--muted);
    font-size: 13px;
    font-weight: 700;
}

label {
    display: grid;
    gap: 7px;
    color: var(--ink);
    font-size: 14px;
    font-weight: 700;
}

input {
    width: 100%;
    min-height: 44px;
    padding: 10px 12px;
    color: var(--ink);
    background: #ffffff;
    border: 1px solid var(--line);
    border-radius: 6px;
    font: inherit;
}

textarea {
    width: 100%;
    padding: 10px 12px;
    color: var(--ink);
    background: #ffffff;
    border: 1px solid var(--line);
    border-radius: 6px;
    font: inherit;
    resize: vertical;
}

select {
    width: 100%;
    min-height: 44px;
    padding: 10px 12px;
    color: var(--ink);
    background: #ffffff;
    border: 1px solid var(--line);
    border-radius: 6px;
    font: inherit;
}

input:focus,
select:focus,
textarea:focus {
    outline: 2px solid rgba(31, 111, 178, 0.22);
    border-color: var(--accent);
}

button,
.button,
.secondary-button {
    min-height: 42px;
    padding: 10px 14px;
    color: #ffffff;
    background: var(--accent);
    border: 0;
    border-radius: 6px;
    font: inherit;
    font-weight: 700;
    cursor: pointer;
    text-decoration: none;
}

.link-button {
    min-height: auto;
    padding: 0;
    color: var(--accent-dark);
    background: transparent;
    border: 0;
    font: inherit;
    font-weight: 700;
    cursor: pointer;
}

.secondary-button {
    color: var(--accent-dark);
    background: #e8f1f8;
}

.danger-button {
    color: #ffffff;
    background: #a73434;
}

.alert {
    margin-top: 16px;
    padding: 12px 14px;
    border-radius: 6px;
    font-weight: 700;
}

.alert-error {
    color: #8f1d1d;
    background: #fdeaea;
    border: 1px solid #f4c7c7;
}

.alert-warning {
    color: #73510a;
    background: #fff4d6;
    border: 1px solid #f0d083;
}

.alert-success {
    color: #1f6638;
    background: #e8f7ee;
    border: 1px solid #afe2bf;
}

.audit-note article {
    min-height: 0;
    margin-top: 24px;
}

.audit-note p {
    max-width: 900px;
}

.wide-form {
    max-width: 920px;
}

.prefill-panel {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(320px, 0.95fr);
    gap: 18px;
    align-items: stretch;
    margin-top: 24px;
    padding: 22px;
    background: #ffffff;
    border: 1px solid var(--line);
    border-radius: 8px;
}

.prefill-copy {
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-height: 240px;
}

.prefill-copy h2 {
    margin: 0;
    font-size: 26px;
}

.prefill-copy p {
    max-width: 520px;
    margin: 12px 0 0;
    color: var(--muted);
    line-height: 1.55;
}

.prefill-status {
    display: grid;
    gap: 4px;
    width: min(100%, 480px);
    margin-top: 18px;
    padding: 12px 14px;
    background: #f1f8f4;
    border: 1px solid #b7dec5;
    border-radius: 8px;
}

.prefill-status strong {
    color: #1f6638;
}

.prefill-status span,
.prefill-status small {
    color: var(--muted);
    font-size: 13px;
    font-weight: 700;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

.capture-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
    margin-top: 20px;
}

.capture-card {
    display: grid;
    gap: 14px;
    padding: 18px;
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 8px;
}

.capture-card h3 {
    margin: 0;
    font-size: 18px;
}

.capture-card p {
    margin: 8px 0 0;
    color: var(--muted);
    line-height: 1.45;
}

.prefill-capture-card {
    margin-top: 0;
}

.document-status-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
    margin-top: 20px;
}

.document-status-card {
    display: grid;
    gap: 16px;
    min-height: 0;
    padding: 18px;
}

.document-status-header {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    align-items: flex-start;
}

.document-status-header h3 {
    margin: 0;
    font-size: 20px;
}

.document-status-header p {
    margin: 8px 0 0;
    color: var(--muted);
    line-height: 1.4;
    word-break: break-word;
}

.document-viewer {
    display: grid;
    place-items: center;
    min-height: 260px;
    overflow: hidden;
    color: var(--muted);
    background: #f8fbfd;
    border: 1px solid var(--line);
    border-radius: 8px;
    font-size: 13px;
    font-weight: 700;
}

.document-viewer img {
    width: 100%;
    height: 100%;
    max-height: 320px;
    object-fit: contain;
    background: #ffffff;
}

.document-status-actions {
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
}

.document-replace-form {
    display: grid;
    gap: 12px;
    padding-top: 14px;
    border-top: 1px solid var(--line);
}

.capture-input input[type="file"] {
    padding: 9px;
}

.document-preview {
    display: grid;
    place-items: center;
    min-height: 190px;
    overflow: hidden;
    color: var(--muted);
    background: #f8fbfd;
    border: 1px dashed #b8c6d7;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 700;
}

.document-preview img {
    width: 100%;
    height: 100%;
    max-height: 260px;
    object-fit: contain;
    background: #ffffff;
}

.document-preview-small {
    min-height: 96px;
}

.document-quality {
    min-height: 20px;
    color: var(--muted);
    font-size: 13px;
    font-weight: 700;
    line-height: 1.35;
}

.document-quality-good {
    color: #1f6638;
}

.document-quality-warn {
    color: #73510a;
}

.document-quality-bad {
    color: #8f1d1d;
}

.document-quality-neutral {
    color: var(--muted);
}

button:disabled {
    cursor: not-allowed;
    opacity: 0.55;
}

.compact-upload-form {
    margin-top: 16px;
}

.validation-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
    margin-top: 24px;
}

.validation-card {
    min-height: 220px;
}

.validation-form {
    margin-top: 18px;
}

.validation-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.validation-history {
    display: grid;
    gap: 12px;
    margin-top: 18px;
}

.validation-history h3 {
    margin: 0;
    font-size: 17px;
}

.validation-history article {
    padding: 14px;
    background: #f8fbfd;
    border: 1px solid var(--line);
    border-radius: 8px;
}

.validation-history article span {
    display: block;
    margin-top: 4px;
    color: var(--muted);
}

.validation-history article p {
    margin-top: 8px;
}

fieldset {
    display: grid;
    gap: 16px;
    margin: 0;
    padding: 18px;
    border: 1px solid var(--line);
    border-radius: 8px;
}

legend {
    padding: 0 8px;
    color: var(--accent-dark);
    font-weight: 700;
}

.span-2 {
    grid-column: span 2;
}

.table-wrap {
    margin-top: 24px;
    overflow-x: auto;
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 8px;
}

.table-wrap-fixed {
    max-height: 520px;
    overflow: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
    min-width: 860px;
}

th,
td {
    padding: 14px 16px;
    border-bottom: 1px solid var(--line);
    text-align: left;
    vertical-align: middle;
}

small {
    color: var(--muted);
}

th {
    position: sticky;
    top: 0;
    z-index: 2;
    color: var(--muted);
    background: #f9fbfd;
    font-size: 12px;
    text-transform: uppercase;
}

td {
    font-size: 14px;
}

tr:last-child td {
    border-bottom: 0;
}

.pill {
    display: inline-flex;
    padding: 5px 8px;
    color: var(--accent-dark);
    background: #e8f1f8;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
}

.card-link {
    display: inline-flex;
    margin-top: 14px;
    color: var(--accent-dark);
    font-weight: 700;
    text-decoration: none;
}

.ocr-text {
    max-height: 360px;
    overflow: auto;
    padding: 16px;
    color: var(--ink);
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 8px;
    white-space: pre-wrap;
    word-break: break-word;
}

.ocr-apply-list {
    display: grid;
    gap: 12px;
}

.ocr-apply-row {
    display: grid;
    grid-template-columns: minmax(160px, 0.8fr) minmax(150px, 0.8fr) minmax(220px, 1.4fr);
    gap: 14px;
    align-items: end;
    padding: 14px;
    background: #f8fbfd;
    border: 1px solid var(--line);
    border-radius: 8px;
}

.ocr-apply-check {
    display: flex;
    align-items: center;
    gap: 10px;
    min-height: 44px;
}

.ocr-apply-check input {
    width: 18px;
    min-height: 18px;
}

.ocr-current-value {
    display: grid;
    gap: 7px;
}

.ocr-current-value strong {
    min-height: 44px;
    padding: 11px 12px;
    color: var(--muted);
    background: #ffffff;
    border: 1px solid var(--line);
    border-radius: 6px;
    font-size: 14px;
    font-weight: 700;
    word-break: break-word;
}

.table-link {
    color: var(--accent-dark);
    font-weight: 700;
    text-decoration: none;
}

.ocr-action-button {
    min-height: 36px;
    padding: 8px 12px;
    color: #ffffff;
    background: #0f7f4f;
    border: 0;
    border-radius: 6px;
    box-shadow: 0 8px 16px rgba(15, 127, 79, 0.16);
    font-size: 13px;
}

.documents-table-heading {
    margin-top: 28px;
}

.audit-json {
    max-width: 360px;
    max-height: 180px;
    overflow: auto;
    margin: 10px 0 0;
    padding: 10px;
    color: var(--ink);
    background: #f8fbfd;
    border: 1px solid var(--line);
    border-radius: 6px;
    font-size: 12px;
    white-space: pre-wrap;
}

details summary {
    color: var(--accent-dark);
    font-weight: 700;
    cursor: pointer;
}

.panel-section {
    margin-top: 26px;
}

.section-heading {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    align-items: flex-end;
}

.section-heading h2 {
    margin: 0;
}

dl {
    display: grid;
    grid-template-columns: 150px 1fr;
    gap: 8px 12px;
    margin: 16px 0 0;
}

dt {
    color: var(--muted);
    font-size: 13px;
    font-weight: 700;
}

dd {
    margin: 0;
    font-size: 14px;
}

.button {
    display: inline-flex;
    align-items: center;
}

.pagination {
    display: flex;
    justify-content: center;
    gap: 14px;
    align-items: center;
    margin-top: 18px;
}

.pagination span {
    color: var(--muted);
    font-weight: 700;
}

@media (max-width: 900px) {
    .grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .detail-grid {
        grid-template-columns: 1fr;
    }

    .metric-row,
    .map-layout,
    .capture-grid,
    .prefill-panel,
    .document-status-grid,
    .validation-grid {
        grid-template-columns: 1fr;
    }

    .municipal-map {
        min-height: 500px;
    }
}

@media (max-width: 560px) {
    .app-shell {
        width: min(100% - 20px, 1120px);
        padding: 24px 0;
    }

    .hero {
        min-height: 220px;
    }

    .grid {
        grid-template-columns: 1fr;
    }

    .topbar {
        display: grid;
    }

    .form-grid {
        grid-template-columns: 1fr;
    }

    .filter-bar {
        grid-template-columns: 1fr;
    }

    .span-2 {
        grid-column: span 1;
    }

    dl {
        grid-template-columns: 1fr;
    }

    .ocr-apply-row {
        grid-template-columns: 1fr;
    }
}
