/* NCC Auditor Fiscal — base neutra, roxo apenas como acento. */
:root {
  --primary-color: #4A4C9C; --primary-light: #6B6DB8; --primary-dark: #2E3066;
  --success-color: #2E7D32; --danger-color: #C62828; --warning-color: #F57C00; --info-color: #0277BD;
  --admin-button-color: #4DB6AC; --admin-button-hover: #26A69A;
  --text-dark: #1A1A1A; --text-light: #FFFFFF; --text-gray: #666666;
  --bg-light: #F5F5F5; --bg-white: #FFFFFF; --border-light: #ddd;
  --shadow: 0 4px 6px rgba(0,0,0,0.1); --radius: 8px;

  --grafite: #0F1013; --carvao: #17181C; --carvao-2: #202127; --carvao-borda: #2A2C33;
  --conteudo: #F7F8F9; --linha: #E7E8EB; --linha-forte: #D5D7DC; --cabecalho-tabela: #F3F4F6;
  --texto-2: #3D3F45; --texto-3: #8A8D94;
  --sombra-cartao: 0 1px 2px rgba(16,17,19,.05), 0 1px 1px rgba(16,17,19,.03);
  --sombra-modal: 0 24px 64px rgba(16,17,19,.28), 0 2px 8px rgba(16,17,19,.12);
  --fonte: 'Inter', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, 'SFMono-Regular', Menlo, Consolas, monospace;
  --critico-bg: #FDECEC; --atencao-bg: #FFF3E6; --info-bg: #E7F2FA; --ok-bg: #EAF4EB;
  --lateral: 248px; --topo: 52px;
  --ease: cubic-bezier(.2,.7,.2,1);
}
* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
#raiz { min-height: 100%; }
body { font-family: var(--fonte); font-size: 14px; line-height: 1.5; color: var(--text-dark); background: var(--conteudo); -webkit-font-smoothing: antialiased; font-feature-settings: 'cv11', 'ss01'; }
.num, td, .valor { font-variant-numeric: tabular-nums; }
.mono { font-family: var(--mono); font-size: .92em; letter-spacing: -.01em; font-variant-numeric: tabular-nums; }
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--primary-color); outline-offset: 2px; border-radius: 4px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
[hidden] { display: none !important; }
@media (min-width: 1920px) { html { font-size: 17px; } body { font-size: 16px; } }

/* ---------- Botões e campos ---------- */
.btn { text-decoration: none; display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 36px; padding: 0 14px; border-radius: 7px; border: 1px solid var(--linha-forte); background: var(--bg-white); color: var(--text-dark); font-weight: 500; cursor: pointer; white-space: nowrap; transition: background .15s, border-color .15s, box-shadow .15s, transform .08s; }
.btn:hover { background: #F2F3F5; }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .55; cursor: not-allowed; }
.btn-primario { background: var(--primary-color); border-color: var(--primary-color); color: var(--text-light); box-shadow: 0 1px 0 rgba(255,255,255,.12) inset, 0 1px 2px rgba(46,48,102,.3); }
.btn-primario:hover { background: var(--primary-dark); border-color: var(--primary-dark); }
.btn-perigo { color: var(--danger-color); }
.btn-perigo:hover { background: var(--critico-bg); border-color: #F1C0C0; }
.btn-fantasma { border-color: transparent; background: transparent; }
.btn-fantasma:hover { background: rgba(16,17,19,.05); }
.btn-sm { height: 30px; padding: 0 10px; font-size: 13px; }
.btn-icone { width: 36px; padding: 0; }
.btn svg { width: 16px; height: 16px; flex: none; }
.campo { display: grid; gap: 6px; }
.erro-inline svg { width: 16px; height: 16px; flex: none; margin-top: 1px; }
.caps svg { width: 14px; height: 14px; flex: none; }
.campo label { font-size: 13px; font-weight: 500; color: var(--texto-2); }
.entrada { height: 38px; width: 100%; padding: 0 12px; border: 1px solid var(--linha-forte); border-radius: 7px; background: var(--bg-white); transition: border-color .15s, box-shadow .15s; }
textarea.entrada { height: auto; min-height: 92px; padding: 10px 12px; resize: vertical; }
.entrada:focus { outline: none; border-color: var(--primary-color); box-shadow: 0 0 0 3px rgba(74,76,156,.18); }
.dica { font-size: 12.5px; color: var(--text-gray); }
.erro-inline { display: flex; gap: 8px; align-items: flex-start; padding: 10px 12px; border-radius: 7px; background: var(--critico-bg); color: #8E1C1C; font-size: 13px; border: 1px solid #F3C7C7; }

/* ---------- Login ---------- */
.login { min-height: 100vh; display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(380px, .85fr); background: var(--grafite); color: #E9EAEE; }
.login-produto { position: relative; padding: clamp(32px, 6vw, 88px); display: flex; flex-direction: column; justify-content: space-between; border-right: 1px solid #1D1F24; overflow: hidden; }
.marca { display: flex; align-items: center; gap: 10px; font-weight: 600; letter-spacing: -.01em; }
.selo { width: 28px; height: 28px; border-radius: 7px; background: var(--primary-color); display: grid; place-items: center; color: #fff; font-size: 10px; font-weight: 700; letter-spacing: 0; box-shadow: 0 0 0 1px rgba(255,255,255,.08) inset; }
.login-titulo { font-size: clamp(30px, 3.4vw, 46px); line-height: 1.08; letter-spacing: -.035em; font-weight: 600; margin: 0 0 16px; max-width: 14ch; color: #F4F5F7; }
.login-sub { color: #9A9DA6; max-width: 46ch; font-size: 15px; margin: 0; }
.login-demo { margin-top: 44px; display: grid; gap: 10px; max-width: 560px; }
.login-demo .ponte { background: #15161A; border-color: #24262C; color: #D9DBE1; }
.login-demo .ponte-mes, .login-demo .ponte-campo { color: #7D808A; }
.login-demo .ponte-rotulo { color: #C9CBD2; }
.login-demo .ponte-vao::before, .login-demo .ponte-vao::after { background: #5A5D66; }
.login-demo .ponte-marca { background: #15161A; border-color: #5A5D66; color: #7FD28A; }
.login-demo .ponte.erro { background: #1B1416; border-color: #4A2629; }
.login-demo .ponte.erro .ponte-vao::before, .login-demo .ponte.erro .ponte-vao::after { background: #E57373; }
.login-demo .ponte.erro .ponte-lado.b .ponte-valor { color: #FF8A8A; }
.login-demo .ponte-dif { background: rgba(198,40,40,.18); border-color: rgba(229,115,115,.45); color: #FFB4B4; }
.login-rodape { color: #62656E; font-size: 12.5px; }
.login-form-lado { display: grid; place-items: center; padding: 32px; }
.login-cartao { width: 100%; max-width: 380px; background: var(--carvao); border: 1px solid var(--carvao-borda); border-radius: 12px; padding: 28px; box-shadow: 0 30px 80px rgba(0,0,0,.35); }
.login-cartao h2 { margin: 0 0 4px; font-size: 20px; letter-spacing: -.02em; font-weight: 600; color: #F4F5F7; }
.login-cartao p { margin: 0 0 22px; color: #8D909A; font-size: 13.5px; }
.login-cartao .campo label { color: #B8BBC3; }
.login-cartao .entrada { background: var(--grafite); border-color: #2C2E35; color: #F1F2F4; }
.login-cartao .entrada:focus { border-color: var(--primary-light); box-shadow: 0 0 0 3px rgba(107,109,184,.25); }
.login-cartao .erro-inline { background: rgba(198,40,40,.12); border-color: rgba(198,40,40,.35); color: #FFB4B4; }
.senha-wrap { position: relative; }
.senha-wrap .entrada { padding-right: 44px; }
.senha-olho { position: absolute; right: 4px; top: 3px; height: 32px; width: 36px; border: 0; background: transparent; color: #8D909A; cursor: pointer; border-radius: 6px; display: grid; place-items: center; }
.senha-olho:hover { color: #E9EAEE; background: rgba(255,255,255,.06); }
.senha-olho svg { width: 17px; height: 17px; }
.caps { font-size: 12px; color: #F5B26B; display: flex; gap: 6px; align-items: center; }
.login-cartao .btn-primario { width: 100%; height: 40px; margin-top: 6px; }
.login-lembrar { display: flex; align-items: center; gap: 8px; font-size: 13px; color: #A3A6AF; }
.pilha { display: grid; gap: 14px; }
@media (max-width: 900px) { .login { grid-template-columns: 1fr; } .login-produto { border-right: 0; border-bottom: 1px solid #1D1F24; padding-bottom: 28px; } .login-demo { display: none; } }

/* ---------- Shell ---------- */
.app { display: grid; grid-template-columns: var(--lateral) minmax(0, 1fr); min-height: 100vh; }
.lateral { position: sticky; top: 0; height: 100vh; background: var(--carvao); color: #C9CBD2; display: flex; flex-direction: column; padding: 14px 10px; border-right: 1px solid #0B0C0E; z-index: 30; }
.lateral .marca { padding: 4px 8px 18px; color: #F4F5F7; }
.lateral .marca small { display: block; font-weight: 400; color: #7D808A; font-size: 11.5px; letter-spacing: 0; }
.nav { display: grid; gap: 2px; }
.nav a { display: flex; align-items: center; gap: 10px; height: 34px; padding: 0 10px; border-radius: 7px; text-decoration: none; color: #B4B7BF; font-weight: 500; font-size: 13.5px; transition: background .12s, color .12s; }
.nav a svg { width: 17px; height: 17px; opacity: .85; }
.nav a:hover { background: #1F2026; color: #F1F2F4; }
.nav a.ativo { background: #24252D; color: #fff; box-shadow: inset 2px 0 0 var(--primary-light); }
.nav a.ativo svg { color: var(--primary-light); opacity: 1; }
.nav-sep { height: 1px; background: #24262C; margin: 10px 6px; }
.lateral-rodape { margin-top: auto; display: grid; gap: 6px; padding: 8px; border-top: 1px solid #24262C; }
.usuario-mini { display: flex; align-items: center; gap: 10px; min-width: 0; }
.avatar { width: 28px; height: 28px; border-radius: 50%; background: #2B2D35; color: #E6E7EB; display: grid; place-items: center; font-size: 12px; font-weight: 600; flex: none; }
.usuario-mini div { min-width: 0; }
.usuario-mini strong { display: block; font-size: 13px; color: #EDEEF1; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.usuario-mini span { font-size: 12px; color: #7D808A; }
.lateral-acoes { display: flex; gap: 4px; }
.lateral-acoes .btn { background: transparent; border-color: #2A2C33; color: #B4B7BF; height: 30px; font-size: 12.5px; flex: 1; }
.lateral-acoes .btn:hover { background: #1F2026; color: #fff; }
/* Barra lateral clara (alternável) */
.app.lateral-clara .lateral { background: #FFFFFF; color: var(--texto-2); border-right-color: var(--linha); }
.app.lateral-clara .lateral .marca { color: var(--text-dark); }
.app.lateral-clara .nav a { color: var(--texto-2); }
.app.lateral-clara .nav a:hover { background: #F2F3F5; color: var(--text-dark); }
.app.lateral-clara .nav a.ativo { background: #EEEEF7; color: var(--primary-dark); box-shadow: inset 2px 0 0 var(--primary-color); }
.app.lateral-clara .nav a.ativo svg { color: var(--primary-color); }
.app.lateral-clara .nav-sep, .app.lateral-clara .lateral-rodape { background: none; border-color: var(--linha); }
.app.lateral-clara .nav-sep { background: var(--linha); }
.app.lateral-clara .usuario-mini strong { color: var(--text-dark); }
.app.lateral-clara .avatar { background: #ECEDF0; color: var(--texto-2); }
.app.lateral-clara .lateral-acoes .btn { border-color: var(--linha); color: var(--texto-2); }
.app.lateral-clara .lateral-acoes .btn:hover { background: #F2F3F5; color: var(--text-dark); }

.principal { min-width: 0; display: flex; flex-direction: column; }
.topo { position: sticky; top: 0; z-index: 20; height: var(--topo); display: flex; align-items: center; gap: 12px; padding: 0 clamp(16px, 3vw, 32px); background: rgba(247,248,249,.78); backdrop-filter: saturate(1.4) blur(12px); -webkit-backdrop-filter: saturate(1.4) blur(12px); border-bottom: 1px solid rgba(16,17,19,.07); }
.trilha { display: flex; align-items: center; gap: 8px; color: var(--text-gray); font-size: 13px; min-width: 0; }
.trilha a { text-decoration: none; }
.trilha a:hover { color: var(--text-dark); }
.trilha strong { color: var(--text-dark); font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.topo .ambiente { margin-left: auto; font-size: 12px; padding: 2px 8px; border-radius: 999px; border: 1px solid #F3D2A8; background: var(--atencao-bg); color: #9A4B00; }
.btn-menu { display: none; }
.conteudo:focus { outline: none; }
.conteudo { padding: clamp(16px, 3vw, 32px); max-width: 1320px; width: 100%; margin: 0 auto; }
.cab-pagina { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 20px; flex-wrap: wrap; }
.cab-pagina h1 { margin: 0; font-size: 22px; letter-spacing: -.025em; font-weight: 600; }
.cab-pagina p { margin: 4px 0 0; color: var(--text-gray); max-width: 70ch; }
.cab-pagina p a { color: var(--texto-2); text-decoration: none; font-weight: 500; }
.cab-pagina p a:hover { text-decoration: underline; }
.cab-acoes { display: flex; gap: 8px; flex-wrap: wrap; }
.veu { display: none; }
@media (max-width: 980px) {
  .app { grid-template-columns: 1fr; }
  .lateral { position: fixed; left: 0; top: 0; bottom: 0; width: min(84vw, 280px); transform: translateX(-100%); transition: transform .25s var(--ease); }
  .app.menu-aberto .lateral { transform: none; box-shadow: var(--sombra-modal); }
  .app.menu-aberto .veu { display: block; position: fixed; inset: 0; background: rgba(15,16,19,.4); z-index: 25; }
  .btn-menu { display: inline-flex; }
}

/* ---------- Cartões, métricas ---------- */
.cartao { background: var(--bg-white); border: 1px solid var(--linha); border-radius: var(--radius); box-shadow: var(--sombra-cartao); }
.cartao-cab { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 12px; padding: 14px 16px; border-bottom: 1px solid var(--linha); }
.cartao-cab h2, .cartao-cab h3 { margin: 0; font-size: 14.5px; font-weight: 600; letter-spacing: -.01em; }
.cartao-cab .dica { margin: 0; }
.cartao-corpo { padding: 16px; }
.grade-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
@media (max-width: 1100px) { .grade-2 { grid-template-columns: minmax(0, 1fr); } }
.destaque { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: clamp(20px, 4vw, 56px); align-items: center; padding: 22px 24px; margin-bottom: 16px; }
.destaque-numero { font-size: clamp(48px, 6vw, 72px); line-height: .95; font-weight: 600; letter-spacing: -.05em; font-variant-numeric: tabular-nums; }
.destaque-numero.tem { color: var(--danger-color); }
.destaque-rotulo { color: var(--text-gray); margin-top: 8px; font-size: 13.5px; }
.metricas { display: flex; flex-wrap: wrap; }
.metrica { padding: 4px 22px; border-left: 1px solid var(--linha); min-width: 140px; }
.metrica strong { display: block; font-size: 22px; font-weight: 600; letter-spacing: -.03em; font-variant-numeric: tabular-nums; }
.metrica span { font-size: 12.5px; color: var(--text-gray); }
@media (max-width: 720px) { .destaque { grid-template-columns: 1fr; } .metrica { border-left: 0; border-top: 1px solid var(--linha); padding: 10px 0; width: 50%; } }

/* ---------- Tabelas densas ---------- */
.rolagem { overflow-x: auto; -webkit-overflow-scrolling: touch; }
table.tabela { width: 100%; border-collapse: separate; border-spacing: 0; font-size: 13px; }
.tabela th { position: sticky; top: 0; background: var(--cabecalho-tabela); color: var(--texto-2); font-weight: 500; text-align: left; padding: 8px 12px; border-bottom: 1px solid var(--linha); white-space: nowrap; font-size: 12.5px; }
.tabela td { padding: 0 12px; height: 40px; border-bottom: 1px solid var(--linha); white-space: nowrap; max-width: 360px; overflow: hidden; text-overflow: ellipsis; }
.tabela tr:last-child td { border-bottom: 0; }
.tabela tbody tr { transition: background .1s; }
.tabela tbody tr.clicavel { cursor: pointer; }
.tabela tbody tr.clicavel:hover { background: #FAFAFB; }
.tabela .dir { text-align: right; }
table.tabela.fixa { table-layout: fixed; }
.tabela.fixa td { max-width: none; }
.tabela .sub { color: var(--text-gray); font-size: 12px; }
.tabela td.quebra { white-space: normal; min-width: 260px; max-width: 520px; padding-top: 9px; padding-bottom: 9px; line-height: 1.45; }

/* ---------- Selos de severidade / situação ---------- */
.selo-sev { display: inline-flex; align-items: center; gap: 6px; height: 22px; padding: 0 8px; border-radius: 999px; font-size: 12px; font-weight: 500; white-space: nowrap; }
.selo-sev::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.sev-critico { background: var(--critico-bg); color: var(--danger-color); }
.sev-atencao { background: var(--atencao-bg); color: #B45300; }
.sev-info { background: var(--info-bg); color: var(--info-color); }
.sev-ok { background: var(--ok-bg); color: var(--success-color); }
.sev-neutro { background: #F0F1F3; color: var(--texto-2); }
.contadores { display: inline-flex; gap: 6px; }
.contador { font-variant-numeric: tabular-nums; min-width: 26px; height: 22px; padding: 0 7px; border-radius: 6px; display: inline-grid; place-items: center; font-size: 12px; font-weight: 600; }
.contador.zero { background: #F0F1F3; color: #A2A5AC; font-weight: 500; }

/* ---------- Pontes de saldo (elemento central) ---------- */
.pontes { display: grid; gap: 10px; }
.ponte { display: grid; grid-template-columns: minmax(150px, 1fr) minmax(120px, 1.3fr) minmax(150px, 1fr); grid-template-areas: 'rot rot rot' 'a vao b'; align-items: center; gap: 6px 16px; padding: 14px 18px; border: 1px solid var(--linha); border-radius: 10px; background: var(--bg-white); }
.ponte-rotulo { grid-area: rot; font-weight: 500; font-size: 13.5px; display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.ponte-lado { display: grid; gap: 1px; }
.ponte-lado.a { grid-area: a; }
.ponte-lado.b { grid-area: b; text-align: right; }
.ponte-mes { font-size: 12px; color: var(--text-gray); }
.ponte-valor { font-family: var(--mono); font-size: 16px; font-weight: 500; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.ponte-campo { font-family: var(--mono); font-size: 11px; color: var(--texto-3); }
.ponte-vao { grid-area: vao; position: relative; height: 28px; display: grid; place-items: center; }
.ponte-vao::before, .ponte-vao::after { content: ''; position: absolute; top: 50%; height: 2px; background: var(--texto-2); transform-origin: left; }
.ponte-vao::before { left: 0; right: 50%; }
.ponte-vao::after { left: 50%; right: 0; }
.ponte-marca { position: relative; z-index: 1; width: 22px; height: 22px; border-radius: 50%; background: var(--bg-white); border: 2px solid var(--texto-2); display: grid; place-items: center; color: var(--success-color); }
.ponte-marca svg { width: 12px; height: 12px; }
.ponte.erro { border-color: #F0C4C4; background: linear-gradient(0deg, #FFFBFB, #FFFBFB); }
.ponte.erro .ponte-vao::before { right: calc(50% + 46px); background: var(--danger-color); }
.ponte.erro .ponte-vao::after { left: calc(50% + 46px); background: var(--danger-color); }
.ponte-dif { position: relative; z-index: 1; font-family: var(--mono); font-size: 12px; font-weight: 600; color: var(--danger-color); background: var(--critico-bg); border: 1px solid #F0C4C4; padding: 2px 8px; border-radius: 999px; white-space: nowrap; }
.ponte.erro .ponte-lado.b .ponte-valor { color: var(--danger-color); }
.ponte.anima .ponte-vao::before, .ponte.anima .ponte-vao::after { animation: traco .55s var(--ease) both; animation-delay: var(--d, 0ms); }
.ponte.anima .ponte-vao::after { animation-delay: calc(var(--d, 0ms) + 120ms); }
.ponte.anima .ponte-marca, .ponte.anima .ponte-dif { animation: surgir .35s var(--ease) both; animation-delay: calc(var(--d, 0ms) + 380ms); }
@keyframes traco { from { transform: scaleX(0); } to { transform: scaleX(1); } }
@keyframes surgir { from { opacity: 0; transform: scale(.7); } to { opacity: 1; transform: none; } }
.pontes-ok { border: 1px solid var(--linha); border-radius: 10px; overflow: hidden; }
.pontes-ok summary { list-style: none; cursor: pointer; padding: 10px 14px; display: flex; align-items: center; gap: 10px; font-size: 13px; color: var(--texto-2); background: #FAFAFB; }
.pontes-ok summary::-webkit-details-marker { display: none; }
.pontes-ok summary::after { content: ''; margin-left: auto; width: 8px; height: 8px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: rotate(45deg); transition: transform .15s; }
.pontes-ok[open] summary::after { transform: rotate(-135deg); }
.pontes-ok[open] summary { border-bottom: 1px solid var(--linha); }
.ponte.compacta { grid-template-columns: minmax(0, 1.7fr) minmax(110px, 1fr) 56px minmax(110px, 1fr); grid-template-areas: 'rot a vao b'; padding: 7px 14px; border: 0; border-radius: 0; border-bottom: 1px solid var(--linha); }
.ponte.compacta:last-child { border-bottom: 0; }
.ponte.compacta .ponte-rotulo { font-weight: 400; font-size: 13px; color: var(--texto-2); }
.ponte.compacta .ponte-rotulo .dica, .ponte.compacta .ponte-mes, .ponte.compacta .ponte-campo { display: none; }
.ponte.compacta .ponte-valor { font-size: 13px; }
.ponte.compacta .ponte-lado.a { text-align: right; }
.ponte.compacta .ponte-vao { height: 20px; }
.ponte.compacta .ponte-vao::before, .ponte.compacta .ponte-vao::after { height: 1.5px; background: #C3C5CB; }
.ponte.compacta .ponte-marca { width: 18px; height: 18px; border-width: 1.5px; border-color: #C3C5CB; }
@media (max-width: 640px) { .ponte.compacta { grid-template-columns: 1fr 44px 1fr; grid-template-areas: 'rot rot rot' 'a vao b'; } }
@media (max-width: 640px) { .ponte { grid-template-columns: 1fr 1fr; grid-template-areas: 'rot rot' 'a b' 'vao vao'; } }

/* ---------- Upload ---------- */
.soltar { display: block; border: 1.5px dashed var(--linha-forte); border-radius: 12px; background: var(--bg-white); padding: 36px 24px; text-align: center; transition: border-color .15s, background .15s; cursor: pointer; }
.soltar:hover, .soltar.sobre { border-color: var(--primary-color); background: #FBFBFE; }
.soltar h2 { margin: 12px 0 4px; font-size: 16px; font-weight: 600; letter-spacing: -.01em; }
.soltar p { margin: 0 auto; color: var(--text-gray); max-width: 60ch; }
.soltar-icone { width: 44px; height: 44px; margin: 0 auto; border-radius: 10px; background: #F2F2F8; color: var(--primary-color); display: grid; place-items: center; }
.soltar-icone svg { width: 22px; height: 22px; }
.privacidade { display: flex; gap: 10px; align-items: flex-start; margin-top: 14px; padding: 12px 14px; border-radius: 8px; background: #F3F4F6; color: var(--texto-2); font-size: 13px; }
.privacidade svg { width: 16px; height: 16px; flex: none; margin-top: 2px; }
.barra { height: 4px; border-radius: 2px; background: #ECEDF0; overflow: hidden; width: 120px; }
.barra i { display: block; height: 100%; background: var(--texto-2); width: 0; transition: width .2s linear; }

/* ---------- Faturamento: barras de 12 meses ---------- */
.serie { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 8px; align-items: end; height: 190px; padding: 12px 4px 0; }
.serie-col { display: grid; grid-template-rows: 1fr auto; height: 100%; gap: 6px; min-width: 0; }
.serie-barra { align-self: end; border-radius: 4px 4px 2px 2px; background: #C9CBD2; min-height: 3px; transition: height .5s var(--ease); position: relative; }
.serie-col.zerado .serie-barra { background: transparent; border: 1.5px dashed var(--danger-color); height: 100% !important; opacity: .55; }
.serie-col.queda .serie-barra { background: #F1B774; }
.serie-col span { font-size: 11px; color: var(--text-gray); text-align: center; white-space: nowrap; }
.serie-col.zerado span { color: var(--danger-color); font-weight: 600; }

/* ---------- Checklist de contas padrão ---------- */
.checklist { display: grid; gap: 0; }
.check-item { display: grid; grid-template-columns: 24px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 11px 16px; border-bottom: 1px solid var(--linha); }
.check-item:last-child { border-bottom: 0; }
.check-item .sub { color: var(--text-gray); font-size: 12.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.check-icone { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; }
.check-icone svg { width: 13px; height: 13px; }
.check-ok { background: var(--ok-bg); color: var(--success-color); }
.check-erro { background: var(--critico-bg); color: var(--danger-color); }
.check-aviso { background: var(--atencao-bg); color: #B45300; }
.check-neutro { background: #F0F1F3; color: #9A9DA4; }

/* ---------- Filtros, abas, vazio ---------- */
.filtros { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-bottom: 12px; }
.segmentado { display: inline-flex; max-width: 100%; overflow-x: auto; scrollbar-width: none; padding: 3px; background: #ECEDF0; border-radius: 8px; gap: 2px; }
.segmentado button { flex: none; white-space: nowrap; border: 0; background: transparent; height: 28px; padding: 0 12px; border-radius: 6px; font-size: 13px; color: var(--texto-2); cursor: pointer; font-weight: 500; }
.segmentado button.ativo { background: var(--bg-white); color: var(--text-dark); box-shadow: 0 1px 2px rgba(16,17,19,.12); }
.vazio { text-align: center; padding: 48px 24px; }
.vazio h3 { margin: 12px 0 6px; font-size: 15px; font-weight: 600; }
.vazio p { margin: 0 auto 16px; color: var(--text-gray); max-width: 52ch; }
.vazio-icone { width: 40px; height: 40px; margin: 0 auto; border-radius: 10px; background: #F0F1F3; display: grid; place-items: center; color: var(--texto-3); }
.vazio-icone svg { width: 20px; height: 20px; }
.meta { display: flex; flex-wrap: wrap; gap: 0; margin-top: 10px; color: var(--text-gray); font-size: 13px; }
.meta > span { padding: 0 12px; border-left: 1px solid var(--linha-forte); }
.meta > span:first-child { padding-left: 0; border-left: 0; }
.carregando { display: grid; place-items: center; padding: 64px; color: var(--text-gray); }
.giro { width: 20px; height: 20px; border: 2px solid #DADCE1; border-top-color: var(--texto-2); border-radius: 50%; animation: giro .7s linear infinite; }
@keyframes giro { to { transform: rotate(360deg); } }
.linha-regra { display: grid; grid-template-columns: 90px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 10px 16px; border-bottom: 1px solid var(--linha); }
.linha-regra:last-child { border-bottom: 0; }
.linha-regra .sub { color: var(--text-gray); font-size: 12.5px; }
.interruptor { position: relative; width: 36px; height: 20px; flex: none; }
.interruptor input { opacity: 0; width: 0; height: 0; position: absolute; }
.interruptor span { position: absolute; inset: 0; border-radius: 999px; background: #CFD1D6; transition: background .15s; cursor: pointer; }
.interruptor span::after { content: ''; position: absolute; left: 2px; top: 2px; width: 16px; height: 16px; border-radius: 50%; background: #fff; box-shadow: 0 1px 2px rgba(0,0,0,.2); transition: transform .18s var(--ease); }
.interruptor input:checked + span { background: var(--primary-color); }
.interruptor input:checked + span::after { transform: translateX(16px); }
.interruptor input:focus-visible + span { outline: 2px solid var(--primary-color); outline-offset: 2px; }

/* ---------- Modal e toast ---------- */
.modal-fundo { position: fixed; inset: 0; z-index: 100; background: rgba(15,16,19,.46); display: grid; place-items: center; padding: 16px; animation: fundo .18s ease both; }
.modal { width: 100%; max-width: 520px; max-height: calc(100vh - 32px); overflow: auto; background: var(--bg-white); border-radius: 12px; box-shadow: var(--sombra-modal); animation: modal .22s var(--ease) both; }
.modal-cab { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; padding: 18px 20px 6px; }
.modal-cab h2 { margin: 0; font-size: 16.5px; font-weight: 600; letter-spacing: -.015em; }
.modal-corpo { padding: 8px 20px 4px; }
.modal-rodape { display: flex; justify-content: flex-end; gap: 8px; padding: 16px 20px 18px; }
@keyframes fundo { from { opacity: 0; } }
@keyframes modal { from { opacity: 0; transform: translateY(8px) scale(.98); } }
.toasts { position: fixed; right: 16px; bottom: 16px; z-index: 120; display: grid; gap: 8px; }
.toast { display: flex; gap: 10px; align-items: center; min-width: 260px; max-width: 420px; padding: 11px 14px; background: var(--carvao); color: #EDEEF1; border-radius: 9px; box-shadow: var(--sombra-modal); font-size: 13.5px; animation: modal .22s var(--ease) both; }
.toast svg { width: 16px; height: 16px; flex: none; color: #7FD28A; }
.toast.erro svg { color: #FF8A8A; }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation-duration: .01ms !important; animation-delay: 0ms !important; transition-duration: .01ms !important; } }
.ic-busca { position: absolute; left: 11px; top: 11px; width: 16px; height: 16px; color: var(--texto-3); pointer-events: none; }
.ic-busca svg { width: 16px; height: 16px; display: block; }
