/* Financeiro: escuro premium. Superfícies grafite, um acento dourado, verde só para entrada, vermelho só para saldo negativo e atraso, âmbar para atenção. */

@font-face {
  font-family: 'Geist';
  src: url('fonts/geist.woff2') format('woff2');
  font-weight: 100 900;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Geist';
  src: url('fonts/geist-ext.woff2') format('woff2');
  font-weight: 100 900;
  font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root {
  color-scheme: dark;
  --bg: #0e0f11;
  --s1: #16181b;
  --s2: #1c1f23;
  --s3: #23272c;
  --ln: #2a2d32;
  --ln2: #3a3e45;
  --tx: #f2f3f5;
  --tx2: #a3a7ae;
  --tx3: #8a8f97;
  --gold: #e4b84d;
  --gold-forte: #f0c95f;
  --gold-tx: #1a1405;
  --gold-fundo: rgb(228 184 77 / 0.12);
  --green: #3ecf8e;
  --red: #ff8080;
  --red-fundo: rgb(255 128 128 / 0.13);
  --amber: #ffa552;
  --amber-fundo: rgb(255 165 82 / 0.13);
  --raio: 14px;
  --raio-p: 10px;
  --sombra: 0 24px 64px rgb(0 0 0 / 0.55), 0 2px 8px rgb(0 0 0 / 0.4);
  --fonte: 'Geist', system-ui, 'Segoe UI', sans-serif;
  --mono: ui-monospace, 'Cascadia Mono', Consolas, monospace;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--tx);
  font: 400 14px/1.45 var(--fonte); font-variant-numeric: tabular-nums;
  -webkit-font-smoothing: antialiased; caret-color: var(--gold); accent-color: var(--gold);
}
::selection { background: var(--gold); color: var(--gold-tx); }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; border-radius: 6px; }
a { color: var(--gold); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }
h1, h2, h3, p { margin: 0; }
h1 { font-size: 26px; font-weight: 600; letter-spacing: -0.025em; }
h2 { font-size: 15px; font-weight: 600; letter-spacing: -0.01em; }
button, input, select { font: inherit; color: inherit; }
[hidden] { display: none !important; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.i { display: block; flex: none; width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; }
* { scrollbar-color: var(--ln2) transparent; scrollbar-width: thin; }
.envolve { max-width: 1240px; margin: 0 auto; padding: 0 32px; }
.nowrap { white-space: nowrap; }

/* ---------- topo ---------- */

.topo { position: sticky; top: 0; z-index: 10; border-bottom: 1px solid var(--ln); background: var(--bg); }
.barra { display: flex; align-items: center; gap: 48px; height: 64px; }
.marca { display: inline-flex; align-items: center; gap: 10px; color: var(--tx); font-size: 19px; font-weight: 600; letter-spacing: -0.02em; }
.marca:hover { text-decoration: none; }
.marca-icone { width: 24px; height: 24px; }
.marca-icone rect { fill: var(--gold); }
.marca-icone path { fill: none; stroke: var(--bg); stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.abas { display: flex; gap: 32px; align-self: stretch; flex: 1; }
.abas a { position: relative; display: flex; align-items: center; gap: 8px; padding-top: 2px; color: var(--tx2); font-weight: 500; border-bottom: 2px solid transparent; }
.abas a:hover { color: var(--tx); text-decoration: none; }
.abas a[aria-current='page'] { color: var(--tx); border-color: var(--gold); }
.abas .i { display: none; }
.aba-alerta { width: 7px; height: 7px; border-radius: 50%; background: var(--amber); }

/* ---------- botões e campos ---------- */

.btn-ouro, .btn, .btn-linha, .btn-fantasma {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 40px; padding: 0 16px;
  border-radius: var(--raio-p); border: 1px solid transparent; font-weight: 600; font-size: 14px; cursor: pointer; white-space: nowrap;
  transition: background-color 140ms ease-out, border-color 140ms ease-out, color 140ms ease-out;
}
.btn-ouro { background: var(--gold); color: var(--gold-tx); padding: 0 18px 0 14px; }
.btn-ouro:hover { background: var(--gold-forte); }
.btn { background: var(--s2); border-color: var(--ln); color: var(--tx); }
.btn:hover { background: var(--s3); border-color: var(--ln2); }
.btn-linha { background: none; border-color: var(--gold); color: var(--gold); font-weight: 500; }
.btn-linha:hover { background: var(--gold-fundo); }
.btn-fantasma { background: none; border-color: var(--ln); color: var(--tx2); font-weight: 500; }
.btn-fantasma:hover { color: var(--tx); border-color: var(--ln2); }
.pequeno { height: 32px; padding: 0 12px; font-size: 13px; border-radius: 8px; }
.btn-ouro:disabled, .btn:disabled, .btn-linha:disabled { opacity: 0.5; cursor: progress; }
.btn-icone { width: 40px; padding: 0; }

.campo { display: grid; gap: 6px; min-width: 0; }
.campo > span { font-size: 12.5px; font-weight: 500; color: var(--tx2); }
.campo small { font-size: 12px; color: var(--tx3); }
.entrada {
  width: 100%; height: 42px; padding: 0 12px; border: 1px solid var(--ln); border-radius: var(--raio-p);
  background: var(--bg); color: var(--tx); font-size: 14px; transition: border-color 140ms ease-out;
}
.entrada:hover { border-color: var(--ln2); }
.entrada:focus-visible { outline: none; border-color: var(--gold); box-shadow: 0 0 0 3px var(--gold-fundo); }
.entrada::placeholder { color: var(--tx3); }
.entrada[aria-invalid='true'] { border-color: var(--red); }
.dinheiro { text-align: right; font-weight: 500; }
.codigo { font-family: var(--mono); font-size: 12.5px; color: var(--tx3); }
.marcar { display: flex; align-items: center; gap: 10px; font-size: 13.5px; color: var(--tx2); cursor: pointer; }
.marcar input { width: 18px; height: 18px; margin: 0; }

.segmentos { display: inline-flex; padding: 3px; border-radius: 11px; background: var(--s1); border: 1px solid var(--ln); }
.segmentos button, .segmentos label {
  display: inline-flex; align-items: center; height: 32px; padding: 0 14px; border: 0; border-radius: 8px; background: none;
  font-size: 13px; font-weight: 500; color: var(--tx2); cursor: pointer;
}
.segmentos input { position: absolute; opacity: 0; pointer-events: none; }
.segmentos [aria-pressed='true'], .segmentos label:has(input:checked) { background: var(--s3); color: var(--tx); }
.segmentos label:has(input:focus-visible) { outline: 2px solid var(--gold); outline-offset: 1px; }

.tag { display: inline-flex; align-items: center; height: 20px; padding: 0 8px; border-radius: 99px; font-size: 11.5px; font-weight: 500; white-space: nowrap; }
.tag.am { background: var(--amber-fundo); color: var(--amber); }
.tag.rd { background: var(--red-fundo); color: var(--red); }
.tag.ok { background: rgb(62 207 142 / 0.12); color: var(--green); }
.tag.cz { background: var(--s3); color: var(--tx2); }
.pos { color: var(--green); }
.neg { color: var(--red); }

/* ---------- estrutura ---------- */

main { outline: none; }
.tela { padding-block: 36px 64px; }
.card { background: var(--s1); border: 1px solid var(--ln); border-radius: var(--raio); overflow: hidden; }
.card-topo { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 18px 24px 16px; }
.card-topo > span, .sub { color: var(--tx3); font-size: 12.5px; }
.sub { margin-top: 2px; }
.mais { display: inline-flex; align-items: center; gap: 2px; border: 0; background: none; padding: 0; color: var(--gold); font-size: 13px; font-weight: 500; cursor: pointer; }
.mais .i { width: 16px; height: 16px; }
.colunas { display: grid; grid-template-columns: minmax(0, 1fr) 384px; gap: 24px; align-items: start; margin-top: 24px; }
.lateral { display: grid; gap: 24px; }
.cabecalho { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 24px; }
.meses { display: inline-flex; align-items: center; gap: 6px; }
.meses strong { min-width: 150px; text-align: center; font-size: 15px; font-weight: 500; }
.nota { color: var(--tx3); font-size: 13px; }
.erro-texto { color: var(--red); font-size: 13px; }

/* ---------- herói da tela inicial ---------- */

.heroi { display: flex; align-items: flex-end; margin-bottom: 24px; }
.saldo { flex: 1; min-width: 0; }
.rotulo { display: flex; align-items: center; gap: 8px; color: var(--tx2); font-size: 13px; font-weight: 500; }
.rotulo i { font-style: normal; font-weight: 400; color: var(--tx3); }
.grande { margin: 4px 0 8px; font-size: 64px; font-weight: 300; line-height: 1.1; letter-spacing: -0.04em; white-space: nowrap; }
.grande small { margin-right: 0.35em; font-size: 0.38em; font-weight: 400; letter-spacing: 0; color: var(--tx2); }
.grande span { font-size: 0.56em; color: var(--tx2); }
.grande.neg { color: var(--red); }
.origem { display: flex; align-items: center; gap: 6px; color: var(--tx3); font-size: 13px; }
.origem .i { width: 14px; height: 14px; }
.numero { display: flex; flex-direction: column; min-width: 236px; margin-left: 32px; padding-left: 32px; border-left: 1px solid var(--ln); }
.numero b { margin: 6px 0 2px; font-size: 28px; font-weight: 400; letter-spacing: -0.025em; white-space: nowrap; }
.numero small { color: var(--tx3); font-size: 12.5px; }

.atalhos { display: flex; gap: 28px; margin: 0 0 28px; padding: 0; list-style: none; }
.atalho {
  display: grid; justify-items: center; gap: 8px; width: 84px; padding: 0; border: 0; background: none; color: var(--tx2);
  font-size: 12.5px; font-weight: 500; cursor: pointer; text-align: center;
}
.atalho > span:first-child {
  display: grid; place-items: center; width: 52px; height: 52px; border-radius: 50%; background: var(--s1); border: 1px solid var(--ln); color: var(--gold);
  transition: background-color 140ms ease-out, border-color 140ms ease-out, transform 140ms ease-out;
}
.atalho .i { width: 22px; height: 22px; }
.atalho:hover { color: var(--tx); text-decoration: none; }
.atalho:hover > span:first-child { background: var(--s2); border-color: var(--gold); }
.atalho:active > span:first-child { transform: scale(0.96); }
.atalho:disabled { cursor: progress; opacity: 0.6; }

/* ---------- gráfico ---------- */

.grafico-card { padding: 20px 24px 14px; }
.grafico-topo { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; margin-bottom: 14px; }
.legenda { display: flex; gap: 20px; color: var(--tx2); font-size: 12.5px; }
.legenda span { display: flex; align-items: center; gap: 8px; }
.legenda .traco { width: 16px; height: 2px; border-radius: 2px; background: var(--gold); }
.legenda .bola { width: 8px; height: 8px; border-radius: 50%; background: var(--amber); }
.grafico { position: relative; height: 230px; }
.grafico svg { display: block; width: 100%; height: 100%; overflow: visible; }
.grafico .eixo text { fill: var(--tx3); stroke: none; font-size: 11.5px; }
.grafico .grade { stroke: var(--ln); stroke-width: 1; }
.grafico .marca-mes { stroke: var(--ln2); stroke-width: 1; stroke-dasharray: 3 4; }
.grafico .zero { stroke: var(--red); stroke-width: 1; stroke-dasharray: 4 4; opacity: 0.7; }
.grafico .serie { fill: none; stroke: var(--gold); stroke-width: 2; stroke-linejoin: round; }
.grafico .serie-neg { fill: none; stroke: var(--red); stroke-width: 2; }
.grafico .area { stroke: none; }
.grafico .ponto-min { fill: var(--amber); stroke: var(--s1); stroke-width: 3; }
.grafico .mira line { stroke: var(--tx3); stroke-width: 1; }
.grafico .mira circle { fill: var(--s1); stroke: var(--gold); stroke-width: 2; }
.etiqueta-min {
  position: absolute; padding: 3px 9px; border-radius: 7px; background: var(--s2); border: 1px solid var(--ln);
  font-size: 12px; white-space: nowrap; transform: translate(-20px, 14px); pointer-events: none;
}
.etiqueta-min i { margin-right: 4px; font-style: normal; color: var(--amber); }
.dica {
  position: absolute; top: 0; padding: 8px 10px; border-radius: 8px; background: var(--s3); border: 1px solid var(--ln2);
  font-size: 12px; color: var(--tx2); line-height: 1.35; pointer-events: none; white-space: nowrap; transform: translateX(-50%); box-shadow: var(--sombra); z-index: 2;
}
.dica strong { display: block; color: var(--tx); font-size: 14px; font-weight: 500; }

/* ---------- itens (vencimentos, bancos, sugestões) ---------- */

.lista { list-style: none; margin: 0; padding: 0; }
.item { border-top: 1px solid var(--ln); }
.item-linha {
  display: grid; width: 100%; grid-template-columns: 36px minmax(0, 1fr) 64px 140px; grid-template-areas: 'ic nm tm am' 'ic mt tm am';
  column-gap: 14px; align-items: center; padding: 12px 24px; border: 0; background: none; text-align: left; cursor: pointer;
  transition: background-color 140ms ease-out;
}
.item-linha:hover { background: var(--s2); }
.item-linha:hover .nm { text-decoration: underline; text-decoration-color: var(--ln2); text-underline-offset: 4px; }
.item-linha[aria-expanded='true'] { background: var(--s2); }
.ic {
  grid-area: ic; display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%;
  color: var(--c, var(--tx2)); background: color-mix(in srgb, var(--c, #a3a7ae) 13%, var(--s1));
}
.ic.mono { background: var(--s2); border: 1px solid var(--ln); color: var(--tx2); font-size: 11.5px; font-weight: 600; letter-spacing: 0.02em; }
.nm { grid-area: nm; align-self: end; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mt { grid-area: mt; align-self: start; display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; min-width: 0; color: var(--tx3); font-size: 12.5px; }
.tm { grid-area: tm; color: var(--tx2); font-size: 13px; text-align: right; }
.tm.late { color: var(--red); }
.am { grid-area: am; text-align: right; }
.am b { display: block; font-weight: 500; white-space: nowrap; }
.am small { display: block; color: var(--tx3); font-size: 12px; white-space: nowrap; }
.am small.tight { color: var(--amber); }
.am small.neg { color: var(--red); }
.paga .nm { text-decoration: line-through; text-decoration-color: var(--tx3); color: var(--tx2); }
.paga .ic { opacity: 0.6; }
.divisor-mes { padding: 14px 24px 8px; border-top: 1px solid var(--ln); color: var(--tx3); font-size: 12px; font-weight: 500; text-transform: capitalize; }
.rodape-lista { display: flex; justify-content: center; padding: 12px 24px 14px; border-top: 1px solid var(--ln); }
.recalcula .am small { animation: desliza 420ms cubic-bezier(0.16, 1, 0.3, 1) both; animation-delay: calc(var(--i, 0) * 18ms); }
@keyframes desliza { from { opacity: 0.2; transform: translateY(-5px); } }

.linha-simples {
  display: grid; grid-template-columns: 36px minmax(0, 1fr) auto; grid-template-areas: 'ic nm am' 'ic mt am';
  column-gap: 14px; align-items: center; width: 100%; padding: 12px 24px; border: 0; border-top: 1px solid var(--ln); background: none; text-align: left;
}
button.linha-simples { cursor: pointer; transition: background-color 140ms ease-out; }
button.linha-simples:hover { background: var(--s2); }
.linha-simples.com-chev { grid-template-columns: 36px minmax(0, 1fr) auto 18px; grid-template-areas: 'ic nm am ch' 'ic mt am ch'; }
.linha-simples .chev { grid-area: ch; color: var(--tx3); }
.extra { grid-column: 2 / -1; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 10px; font-size: 12.5px; }
.aviso-linha { display: flex; align-items: center; gap: 8px; color: var(--amber); font-size: 12.5px; }
.aviso-linha .i { width: 14px; height: 14px; }
.extra.aviso-linha { flex-wrap: nowrap; align-items: flex-start; }
.extra.aviso-linha .i { margin-top: 2px; }
.linha-simples + .corpo { padding-top: 16px; border-top: 1px solid var(--ln); }
.aviso-linha.erro { color: var(--red); }
.alerta { display: flex; gap: 10px; align-items: flex-start; margin: 0 24px 16px; padding: 12px 14px; border-radius: var(--raio-p); background: var(--amber-fundo); color: var(--tx); font-size: 13px; }
.alerta .i { width: 16px; height: 16px; margin-top: 1px; color: var(--amber); }
.alerta.erro { background: var(--red-fundo); }
.alerta.erro .i { color: var(--red); }

/* a ficha da conta, aberta embaixo da linha */
.data-m { display: none; }
.item.aberta { outline: 1px solid var(--ln2); outline-offset: -1px; }
.item.aberta:focus-within { outline: 2px solid var(--gold); outline-offset: -2px; }
.item.aberta > .item-linha:focus-visible { outline: none; }
.ficha { display: grid; gap: 14px; padding: 12px 24px 20px 74px; background: var(--s2); animation: abrir 180ms cubic-bezier(0.16, 1, 0.3, 1); }
.ficha-linha { display: flex; flex-wrap: wrap; align-items: end; gap: 10px; }
.ficha-linha .campo { flex: 1 1 220px; }
.ficha-linha .campo-valor { flex: 0 1 150px; }
.ficha-info { color: var(--tx2); font-size: 13.5px; }
.ficha .entrada { background: var(--s1); }
@keyframes abrir { from { opacity: 0; transform: translateY(-4px); } }

/* ---------- vazio ---------- */

.vazio { display: grid; gap: 12px; justify-items: start; padding: 28px 24px 30px; border-top: 1px solid var(--ln); }
.vazio h2 { font-size: 17px; }
.vazio p { color: var(--tx2); max-width: 56ch; }
.vazio div { display: flex; gap: 10px; flex-wrap: wrap; }

/* ---------- contas, extrato, bancos ---------- */

.filtros { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-bottom: 20px; }
.filtros .entrada { width: auto; min-width: 200px; }
.resumo { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); margin-bottom: 24px; }
.resumo > div { padding: 18px 24px; }
.resumo > div + div { border-left: 1px solid var(--ln); }
.resumo span { display: block; color: var(--tx3); font-size: 12.5px; }
.resumo strong { display: block; margin-top: 4px; font-size: 22px; font-weight: 400; letter-spacing: -0.02em; white-space: nowrap; }
.resumo.tres { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.categorias { display: grid; gap: 10px; padding: 4px 24px 20px; }
.categoria { display: grid; grid-template-columns: 150px 1fr 110px; gap: 14px; align-items: center; font-size: 13px; color: var(--tx2); }
.categoria .barra { height: 6px; border-radius: 3px; background: var(--s3); overflow: hidden; }
.categoria .barra span { display: block; height: 100%; border-radius: 3px; background: var(--gold); }
.categoria .valor { text-align: right; color: var(--tx); }
.dia { padding: 12px 24px 6px; border-top: 1px solid var(--ln); color: var(--tx3); font-size: 12px; font-weight: 500; }
.secoes { display: grid; gap: 24px; }
.secao .linha-simples + .corpo { padding-top: 20px; }
.tela > .card + .card { margin-top: 24px; }
.secao { padding-bottom: 22px; }
.secao .corpo { display: grid; gap: 16px; padding: 0 24px; }
.passos { margin: 0; padding-left: 20px; display: grid; gap: 6px; color: var(--tx2); font-size: 13.5px; max-width: 72ch; }
.formulario { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 12px; align-items: end; }
details summary { cursor: pointer; color: var(--tx2); font-size: 13px; }
details[open] summary { margin-bottom: 12px; }
.conta-acoes { grid-area: am; display: flex; align-items: center; gap: 14px; }

/* ---------- folha (formulário lateral) ---------- */

.folha {
  width: min(500px, 100vw); max-width: 100vw; height: 100dvh; max-height: 100dvh; margin: 0 0 0 auto; padding: 0; border: 0;
  border-left: 1px solid var(--ln); background: var(--s1); color: var(--tx); box-shadow: var(--sombra);
}
.folha[open] { animation: entra 260ms cubic-bezier(0.16, 1, 0.3, 1); }
.folha::backdrop { background: rgb(0 0 0 / 0.6); }
@keyframes entra { from { transform: translateX(32px); opacity: 0; } }
.folha form { display: flex; flex-direction: column; height: 100%; }
.folha-topo { display: flex; align-items: center; justify-content: space-between; gap: 12px; height: 64px; padding: 0 16px 0 24px; border-bottom: 1px solid var(--ln); flex: none; }
.folha-topo h2 { font-size: 17px; }
.folha-corpo { flex: 1; overflow-y: auto; padding: 24px; display: grid; align-content: start; gap: 18px; }
.folha-rodape { display: flex; gap: 10px; padding: 16px 24px; border-top: 1px solid var(--ln); flex: none; }
.folha-rodape .esquerda { margin-right: auto; }
.duas { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.lido { padding: 10px 12px; border-radius: var(--raio-p); background: var(--gold-fundo); color: var(--tx); font-size: 13px; }
.lido.erro { background: var(--red-fundo); color: var(--red); }

/* ---------- entrar ---------- */

.entrar { min-height: 100dvh; display: grid; place-items: center; padding: 24px; }
.entrar form { width: min(380px, 100%); display: grid; gap: 16px; padding: 32px; }
.entrar .marca { margin-bottom: 8px; }

.aviso {
  position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 16px); padding: 12px 18px; border-radius: 10px;
  background: var(--s3); border: 1px solid var(--ln2); color: var(--tx); font-size: 13.5px; font-weight: 500; box-shadow: var(--sombra);
  opacity: 0; pointer-events: none; transition: opacity 160ms ease-out, transform 220ms cubic-bezier(0.16, 1, 0.3, 1); z-index: 30;
}
.aviso.visivel { opacity: 1; transform: translate(-50%, 0); }
.aviso.erro { border-color: var(--red); color: var(--red); }

/* ---------- telas menores ---------- */

@media (max-width: 1000px) {
  .colunas { grid-template-columns: 1fr; }
  .heroi { flex-wrap: wrap; row-gap: 20px; }
  .saldo { flex-basis: 100%; }
  .heroi .numero:nth-child(2) { margin-left: 0; padding-left: 0; border-left: 0; }
}

@media (max-width: 640px) {
  body { padding-bottom: calc(76px + env(safe-area-inset-bottom)); }
  .envolve { padding: 0 16px; }
  .barra { height: 56px; justify-content: space-between; gap: 12px; }
  .btn-ouro.no-topo { width: 40px; padding: 0; border-radius: 50%; }
  .btn-ouro.no-topo span { display: none; }
  .abas {
    position: fixed; z-index: 20; inset: auto 0 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 0;
    padding: 6px 8px calc(8px + env(safe-area-inset-bottom)); background: rgb(22 24 27 / 0.97); border-top: 1px solid var(--ln);
  }
  .abas a { flex-direction: column; justify-content: center; gap: 4px; padding: 6px 0 2px; border: 0; font-size: 11.5px; }
  .abas .i { display: block; width: 22px; height: 22px; }
  .abas a[aria-current='page'] { color: var(--gold); }
  .aba-alerta { position: absolute; top: 6px; left: calc(50% + 8px); }
  .tela { padding-block: 20px 24px; }
  h1 { font-size: 22px; }
  .heroi { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 18px; }
  .saldo { grid-column: 1 / -1; margin-bottom: 6px; }
  .grande { font-size: 46px; }
  .numero, .heroi .numero:nth-child(2) { min-width: 0; margin: 0; padding: 12px 14px; border: 1px solid var(--ln); border-radius: 12px; background: var(--s1); }
  .numero .rotulo { flex-wrap: wrap; row-gap: 4px; font-size: 12.5px; }
  .numero b { margin-top: 8px; font-size: 19px; }
  .numero small { font-size: 12px; }
  .atalhos { justify-content: space-between; gap: 4px; margin-bottom: 20px; }
  .atalho { width: 76px; font-size: 12px; }
  .grafico-card { padding: 16px 16px 12px; }
  .legenda { display: none; }
  .grafico { height: 170px; }
  .colunas, .lateral { gap: 16px; }
  .colunas { margin-top: 16px; }
  .card-topo { padding: 14px 16px 12px; }
  .item-linha { grid-template-columns: 36px minmax(0, 1fr) auto; grid-template-areas: 'ic nm am' 'ic mt am'; column-gap: 12px; padding: 12px 16px; }
  .item-linha .tm { display: none; }
  .data-m { display: inline; }
  .nm { white-space: normal; }
  .linha-simples { padding: 12px 16px; column-gap: 12px; }
  .ficha { padding: 4px 16px 18px; }
  .divisor-mes, .dia { padding-inline: 16px; }
  .alerta { margin: 0 16px 14px; }
  .resumo { grid-template-columns: 1fr 1fr; }
  .resumo > div { padding: 14px 16px; }
  .resumo > div:nth-child(3) { border-left: 0; }
  .resumo > div:nth-child(n+3) { border-top: 1px solid var(--ln); }
  .resumo.tres > div:nth-child(3) { grid-column: 1 / -1; }
  .categorias { padding: 4px 16px 16px; }
  .categoria { grid-template-columns: 96px 1fr 88px; }
  .secao .corpo { padding: 0 16px; }
  .vazio { padding: 22px 16px; }
  .duas { grid-template-columns: 1fr; }
  .folha { width: 100vw; border-left: 0; }
  .filtros .entrada { flex: 1 1 100%; }
  .aviso { bottom: calc(84px + env(safe-area-inset-bottom)); }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 1ms !important; animation-delay: 0ms !important; transition-duration: 1ms !important; }
}
