@font-face {
    font-family: Inter;
    src: url("fonts/inter-latin.woff2") format("woff2");
    font-style: normal;
    font-weight: 100 900;
    font-display: swap;
}

:root {
    color-scheme: light;
    --bg-app: #f4f6fa;
    --surface: #fff;
    --surface-subtle: #f9fafb;
    --fill-muted: #f2f4f7;
    --border-card: #e4e7ec;
    --border-divider: #eaecf0;
    --border-row: #f2f4f7;
    --border-control: #d0d5dd;
    --text-primary: #101828;
    --text-secondary: #344054;
    --text-tertiary: #475467;
    --text-muted: #667085;
    --primary: #4f46e5;
    --primary-deep: #4338ca;
    --primary-soft: #eef2ff;
    --on-primary: #fff;
    --success-text: #166534;
    --success-bg: #dcfce7;
    --danger-text: #b42318;
    --danger-bg: #fee4e2;
    --warning-text: #92400e;
    --warning-bg: #fef3c7;
    --info-text: #1d4ed8;
    --info-bg: #e0eaff;
    --radius-sm: .4375rem;
    --radius-md: .5rem;
    --radius-lg: .625rem;
    --radius-card: .875rem;
    --shadow-card: 0 2px 10px -2px rgb(10 18 38 / .1);
    --nav-bg: #282f74;
    --nav-text: #fff;
    --nav-active: rgb(255 255 255 / .14);
    --nav-indicator: #c7d2fe;
    --auth-action: #1a2c63;
    --auth-action-hover: #14224e;
    --auth-action-text: #fff;
    --focus: #4f46e5;
    font-family: Inter, system-ui, -apple-system, "Segoe UI", sans-serif;
    font-size: 100%;
    line-height: 1.5;
    scroll-padding-block-start: 8rem;
}

:root[data-fonte="menor"] { font-size: 93.75%; }
:root[data-fonte="maior"] { font-size: 112.5%; }

:root[data-alto-contraste] {
    color-scheme: dark;
    --bg-app: #000;
    --surface: #111;
    --surface-subtle: #191919;
    --fill-muted: #222;
    --border-card: #a0a0a0;
    --border-divider: #777;
    --border-row: #666;
    --border-control: #ddd;
    --text-primary: #fff;
    --text-secondary: #fff;
    --text-tertiary: #f5f5f5;
    --text-muted: #e0e0e0;
    --primary: #ffed72;
    --primary-deep: #fff3aa;
    --primary-soft: #24194a;
    --primary-soft-hover: #35284c;
    --on-primary: #000;
    --success-text: #b7ffc6;
    --success-bg: #0d2b14;
    --danger-text: #ffd4d4;
    --danger-bg: #440c0c;
    --warning-text: #fff0b3;
    --warning-bg: #362509;
    --info-text: #cee3ff;
    --info-bg: #142842;
    --nav-bg: #000;
    --nav-active: #262033;
    --nav-indicator: #ffed72;
    --auth-action: #ffed72;
    --auth-action-hover: #fff3aa;
    --auth-action-text: #000;
    --focus: #ffed72;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
body {
    min-width: 0;
    margin: 0;
    background: var(--bg-app);
    color: var(--text-primary);
    font-size: .875rem;
}

button, input, select { font: inherit; }
button, summary { cursor: pointer; }
a { color: var(--primary-deep); text-underline-offset: .18em; }
p, h1, h2, h3 { margin: 0; }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 3px; }

.skip-link {
    position: fixed;
    z-index: 20;
    inset: .75rem auto auto .75rem;
    padding: .55rem .9rem;
    transform: translateY(-200%);
    border-radius: var(--radius-sm);
    background: var(--surface);
    box-shadow: var(--shadow-card);
    font-weight: 650;
}

.skip-link:focus { transform: translateY(0); }

.taxas-container {
    width: min(100%, 100rem);
    min-width: 0;
    margin-inline: auto;
    padding-inline: clamp(1rem, 2.75vw, 2rem);
}

.taxas-chrome {
    position: sticky;
    z-index: 5;
    inset-block-start: 0;
}

.taxas-topbar {
    border-bottom: 1px solid var(--border-card);
    background: var(--surface);
}

.taxas-topbar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 4.125rem;
    gap: .75rem;
}

.taxas-marca {
    display: inline-flex;
    align-items: center;
    gap: .58rem;
    min-height: 2.75rem;
    color: var(--text-primary);
    font-size: 1.25rem;
    font-weight: 800;
    letter-spacing: .065em;
    text-decoration: none;
}

.taxas-marca-simbolo {
    display: inline-grid;
    flex: 0 0 auto;
    place-items: center;
    width: 1.95rem;
    height: 1.95rem;
    border-radius: var(--radius-md);
    background: var(--primary);
    color: var(--on-primary);
    font-size: 1.05rem;
    letter-spacing: 0;
}

.taxas-topbar-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    min-width: 0;
    gap: .65rem;
}

.taxas-municipio {
    display: flex;
    align-items: center;
    gap: .35rem;
    color: var(--text-muted);
    font-size: .75rem;
}

.taxas-municipio strong {
    color: var(--text-secondary);
    font-weight: 615;
    overflow-wrap: anywhere;
}

.taxas-topbar-panel { position: relative; }
.taxas-topbar-panel > summary,
.taxas-menu-trigger {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .45rem;
    min-height: 2.75rem;
    padding: .3rem .6rem;
    border: 1px solid transparent;
    border-radius: var(--radius-md);
    background: transparent;
    color: var(--text-secondary);
    list-style: none;
}

.taxas-topbar-panel > summary::-webkit-details-marker { display: none; }
.taxas-topbar-panel > summary:hover,
.taxas-topbar-panel[open] > summary,
.taxas-menu-trigger:hover,
.taxas-menu-trigger[aria-expanded="true"] {
    border-color: var(--border-card);
    background: var(--fill-muted);
    color: var(--text-primary);
}

.taxas-access-trigger { min-width: 2.75rem; font-weight: 700; }
.taxas-perfil-trigger { min-width: 2.75rem; }
.taxas-avatar {
    display: inline-grid;
    flex: 0 0 auto;
    place-items: center;
    width: 1.875rem;
    height: 1.875rem;
    border-radius: 50%;
    background: var(--primary-soft);
    color: var(--primary-deep);
    font-weight: 750;
}
.taxas-avatar::before { content: attr(data-inicial); }

.taxas-perfil-nome {
    max-width: min(18vw, 13rem);
    overflow: hidden;
    font-size: .8125rem;
    font-weight: 625;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.taxas-chevron {
    width: .36rem;
    height: .36rem;
    margin: -.2rem .125rem 0 .15rem;
    transform: rotate(45deg);
    border: solid currentColor;
    border-width: 0 1.5px 1.5px 0;
}

.taxas-dropdown {
    position: absolute;
    z-index: 2;
    inset-block-start: calc(100% + .375rem);
    inset-inline-end: 0;
    width: max-content;
    min-width: 11.75rem;
    max-width: min(18rem, calc(100vw - 2rem));
    padding: .85rem;
    border: 1px solid var(--border-card);
    border-radius: var(--radius-lg);
    background: var(--surface);
    box-shadow: 0 12px 26px -10px rgb(16 24 40 / .24);
}

.taxas-menu-heading { color: var(--text-primary); font-weight: 650; overflow-wrap: anywhere; }
.taxas-perfil-municipio { margin-block: .2rem .7rem; color: var(--text-muted); font-size: .75rem; overflow-wrap: anywhere; }
.taxas-perfil-dropdown .btn { width: 100%; }
.taxas-access-dropdown { display: grid; gap: .65rem; }
.taxas-font-options { display: grid; grid-template-columns: repeat(3, 1fr); gap: .3rem; }
.taxas-dropdown .btn[aria-pressed="true"] {
    border-color: var(--primary-deep);
    background: var(--primary-soft);
    color: var(--primary-deep);
}

.taxas-menu-trigger { min-width: 2.75rem; }
.taxas-menu-icon {
    width: 1.125rem;
    height: .8rem;
    border-block: 2px solid currentColor;
    background: linear-gradient(currentColor, currentColor) center / 100% 2px no-repeat;
}

.taxas-navbar { background: var(--nav-bg); color: var(--nav-text); }
.taxas-navbar-inner { display: flex; align-items: stretch; min-height: 3.25rem; gap: .25rem; }
.taxas-navbar a {
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    min-height: 2.75rem;
    padding: .65rem .875rem;
    color: var(--nav-text);
    font-size: .8125rem;
    font-weight: 560;
    text-decoration: none;
}

.taxas-navbar a[aria-current="page"] {
    background: var(--nav-active);
    box-shadow: inset 0 -2px var(--nav-indicator);
    font-weight: 650;
}

.taxas-navbar a:hover { background: var(--nav-active); }
.taxas-navbar a:focus-visible { outline-color: var(--nav-indicator); outline-offset: -4px; }
.taxas-navbar-legado { margin-inline-start: auto; }
.taxas-external { font-size: 1rem; line-height: 1; }
.taxas-nav-icon { position: relative; display: inline-block; flex: 0 0 auto; width: 1rem; height: 1rem; }
.taxas-nav-icon--cadastro {
    border: 1.5px solid currentColor;
    border-radius: 3px;
    background: linear-gradient(currentColor, currentColor) center 35% / 53% 1px no-repeat,
        linear-gradient(currentColor, currentColor) center 66% / 53% 1px no-repeat;
}

.taxas-nav-icon--regras {
    background: linear-gradient(currentColor, currentColor) 0 24% / 100% 1.5px no-repeat,
        linear-gradient(currentColor, currentColor) 0 75% / 100% 1.5px no-repeat;
}

.taxas-nav-icon--regras::before, .taxas-nav-icon--regras::after {
    position: absolute;
    width: 4px;
    height: 4px;
    border-radius: 1px;
    background: currentColor;
    content: "";
}

.taxas-nav-icon--regras::before { inset: 12% auto auto 30%; }
.taxas-nav-icon--regras::after { inset: auto 20% 12% auto; }

.page-content { padding-block: 1.45rem 2rem; }

.auth-page {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    min-height: 100dvh;
    background: var(--surface);
}

.auth-topbar { padding: 1.2rem clamp(1rem, 3vw, 2rem); }
.auth-main {
    display: grid;
    flex: 1 0 auto;
    place-items: center;
    padding: 1.5rem 1rem 4rem;
}

.auth-card {
    width: min(100%, 31.25rem);
    border: 1px solid var(--border-card);
    border-radius: var(--radius-md);
    background: var(--surface);
    box-shadow: 0 2px 8px rgb(16 24 40 / .06);
}

.auth-card-inner { padding: clamp(1.25rem, 4vw, 3rem); }
.auth-title { color: var(--text-primary); font-size: 1.6rem; font-weight: 625; line-height: 1.25; }
.auth-subtitle { margin: .45rem 0 1.55rem; color: var(--text-tertiary); font-size: .9rem; }
.auth-card .btn-auth-primary {
    position: relative;
    width: 100%;
    min-height: 3rem;
    padding: .75rem 2rem;
    border-radius: .25rem;
    background: var(--auth-action);
    color: var(--auth-action-text);
    font-size: .875rem;
    letter-spacing: .06em;
    text-transform: uppercase;
}

.auth-card .btn-auth-primary:hover { background: var(--auth-action-hover); color: var(--auth-action-text); }
.auth-card .btn-auth-primary span { position: absolute; inset-inline-end: .85rem; font-size: 1rem; }
.auth-help { margin-block-start: .9rem; color: var(--text-tertiary); font-size: .8125rem; }
.auth-code { margin-bottom: .4rem; color: var(--text-muted); font-size: .8125rem; font-weight: 650; }

@media (max-width: 991.98px) {
    :root { scroll-padding-block-start: 0; }
    .taxas-chrome { position: relative; }
    .taxas-navbar-inner { flex-direction: column; gap: 0; padding-block: .35rem; }
    .taxas-navbar a { padding-inline: .75rem; }
    .taxas-navbar a[aria-current="page"] { box-shadow: inset .1875rem 0 var(--nav-indicator); }
    .taxas-navbar-legado { margin-inline-start: 0; }
    .page-content { padding-block-start: 1.15rem; }
    .auth-main { padding-block-end: 2.75rem; }
    .auth-card { border-color: transparent; box-shadow: none; }
}

@media (max-width: 575.98px) {
    .taxas-municipio, .taxas-perfil-nome, .taxas-chevron { display: none; }
    .taxas-topbar-actions { gap: .25rem; }
    .taxas-topbar-inner { min-height: 3.625rem; gap: .3rem; }
    .taxas-perfil-trigger { padding-inline: .35rem; }
    .taxas-dropdown { position: fixed; inset: 3.6rem .75rem auto auto; }
    .auth-topbar { padding-block: .8rem; }
    .auth-main { align-items: start; padding-block-start: clamp(2.6rem, 10vh, 5rem); }
    .auth-card-inner { padding: .95rem .45rem; }
}

@media (forced-colors: active) {
    .taxas-navbar a[aria-current="page"] { border-block-end: 2px solid Highlight; }
    .taxas-menu-icon { background: none; }
    .taxas-nav-icon--regras { border-block: 1px solid currentColor; }
}
