/* ============================================================
   Bolso+ Web — App responsivo (desktop-first → mobile)
   Shell com sidebar + topbar, dashboard em grid, tabelas.
   Usa os tokens de bolso-tokens.css.
   ============================================================ */

*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; height: 100%; }

body {
    font-family: var(--fonte);
    color: var(--bolso-texto);
    background: var(--bolso-fundo);
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; }
h1, h2, h3, h4 { margin: 0; }

/* FocusOnNavigate (Routes.razor) foca o h1 ao navegar — bom p/ leitor de tela, mas
   não deve desenhar o contorno preto pra quem usa mouse. O h1 tem tabindex=-1
   (fora da ordem de Tab), então esconder o outline não prejudica navegação por teclado. */
h1:focus { outline: none; }

:root {
    --sidebar-w: 256px;
    --topbar-h: 68px;
    --maxw: 1320px;
}

/* ============================================================
   SHELL
   ============================================================ */
.shell { display: flex; height: 100vh; overflow: hidden; }

/* ---------- Sidebar ---------- */
.sidebar {
    width: var(--sidebar-w);
    flex-shrink: 0;
    background: #fff;
    border-right: 1px solid var(--bolso-linha);
    display: flex;
    flex-direction: column;
    padding: 22px 16px;
    position: sticky;
    top: 0;
    height: 100vh;
    overflow-y: auto; /* tela baixa: a própria sidebar rola (MoodCard + usuário no rodapé não cortam) */
    z-index: 50; /* acima do conteúdo: destrava o painel de notificações (fixed) preso no contexto da sidebar sticky */
}

.brand {
    display: flex;
    align-items: center;
    gap: 11px;
    padding: 4px 10px 22px;
}
.brand .logo {
    width: 38px; height: 38px;
    border-radius: 11px;
    background: var(--bolso-roxo-vibrante);
    display: grid; place-items: center;
    color: #fff; font-weight: 800; font-size: 20px;
    box-shadow: 0 8px 18px rgba(109, 53, 255, .35);
}
.brand .name { font-size: 20px; font-weight: 800; letter-spacing: -0.3px; }

.nav { display: flex; flex-direction: column; gap: 4px; }
.nav-item {
    display: flex;
    align-items: center;
    gap: 13px;
    padding: 11px 14px;
    border-radius: 13px;
    color: var(--bolso-texto-2);
    font-weight: 600;
    font-size: 14.5px;
    transition: background .15s, color .15s;
}
.nav-item:hover { background: var(--bolso-fundo); color: var(--bolso-texto); }
.nav-item.active {
    background: var(--bolso-roxo-tint);
    color: var(--bolso-roxo-vibrante);
}
.ico { width: 20px; height: 20px; flex-shrink: 0; }
.nav-sep { height: 1px; background: var(--bolso-linha); margin: 14px 8px; }
.nav-label { font-size: 11px; font-weight: 700; letter-spacing: .6px; text-transform: uppercase; color: var(--bolso-placeholder); padding: 6px 14px 4px; }

.sidebar-foot { margin-top: auto; }
.logout-btn {
    display: flex; align-items: center; gap: 11px;
    width: 100%;
    padding: 11px 14px;
    border-radius: 13px;
    color: var(--bolso-vermelho);
    font-weight: 600; font-size: 14.5px;
}
.logout-btn:hover { background: var(--bolso-vermelho-tint); }

/* ---------- Conteúdo ---------- */
.main { flex: 1; min-width: 0; display: flex; flex-direction: column; height: 100vh; min-height: 0; }

.topbar {
    height: var(--topbar-h);
    flex-shrink: 0;
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 0 32px;
    border-bottom: 1px solid var(--bolso-linha);
    background: rgba(255,255,255,.75);
    backdrop-filter: blur(8px);
    position: sticky; top: 0; z-index: 20;
}
.topbar .page-h { font-size: 19px; font-weight: 800; letter-spacing: -0.3px; }
.topbar .spacer { flex: 1; }
.topbar .menu-toggle { display: none; }

.month-pill {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 8px 14px;
    border-radius: var(--r-pill);
    background: var(--bolso-fundo);
    border: 1px solid var(--bolso-linha);
    font-weight: 700; font-size: 13.5px;
}
.user-chip {
    display: inline-flex; align-items: center; gap: 10px;
    padding: 6px 12px 6px 6px;
    border-radius: var(--r-pill);
    background: var(--bolso-fundo);
    border: 1px solid var(--bolso-linha);
    font-weight: 700; font-size: 13.5px;
}
.user-chip .av {
    width: 30px; height: 30px; border-radius: 50%;
    background: linear-gradient(135deg, #8B5CF6, var(--bolso-roxo-vibrante));
    color: #fff; display: grid; place-items: center; font-size: 13px; font-weight: 800;
}

.content {
    padding: 28px 32px 48px;
    width: 100%;
    max-width: var(--maxw);
    margin: 0 auto;
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
    scrollbar-width: none;       /* Firefox: rola, mas sem barra visível */
    -ms-overflow-style: none;    /* Edge antigo */
}
/* WebKit (Chrome/Edge/Safari): some com a barra mantendo a rolagem */
.content::-webkit-scrollbar, .sidebar::-webkit-scrollbar { width: 0; height: 0; }
.sidebar { scrollbar-width: none; -ms-overflow-style: none; }
.content > .page-title { font-size: 24px; font-weight: 800; letter-spacing: -0.5px; margin-bottom: 4px; }
.content > .page-sub { color: var(--bolso-texto-2); font-size: 14px; margin-bottom: 24px; }

/* ============================================================
   CARDS / GRID
   ============================================================ */
.card {
    background: var(--bolso-card);
    border: 1px solid var(--bolso-linha);
    border-radius: var(--r-card);
    box-shadow: var(--sombra-card);
}
.card-pad { padding: 22px 24px; }
.card-title { font-size: 15px; font-weight: 800; }

.grid { display: grid; gap: 20px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-dash { grid-template-columns: 1.3fr 1fr; align-items: start; }

/* ---------- Stat cards ---------- */
.stat {
    padding: 20px 22px;
    display: flex; flex-direction: column; gap: 10px;
}
.stat .lbl { display: flex; align-items: center; gap: 9px; color: var(--bolso-texto-2); font-size: 13.5px; font-weight: 600; }
.stat .ico-badge { width: 34px; height: 34px; border-radius: 11px; display: grid; place-items: center; }
.stat .val { font-size: 25px; font-weight: 800; letter-spacing: -0.5px; white-space: nowrap; }
.tint-green { background: var(--bolso-verde-tint); color: var(--bolso-verde); }
.tint-red   { background: var(--bolso-vermelho-tint); color: var(--bolso-vermelho); }
.tint-purple{ background: var(--bolso-roxo-tint); color: var(--bolso-roxo-vibrante); }
.tint-blue  { background: var(--bolso-azul-tint); color: var(--bolso-azul); }
.tint-orange{ background: var(--bolso-laranja-tint); color: var(--bolso-laranja); }
.c-green { color: var(--bolso-verde); }
.c-red   { color: var(--bolso-vermelho); }

/* ---------- Balance hero ---------- */
.hero {
    background: var(--bolso-saldo-grad);
    border-radius: var(--r-card-lg);
    box-shadow: var(--sombra-saldo);
    color: #fff;
    padding: 26px 28px;
    display: flex; flex-direction: column; gap: 6px;
}
.hero .lbl { color: var(--bolso-saldo-texto-2); font-size: 13.5px; font-weight: 600; }
.hero .big { font-size: 38px; font-weight: 800; letter-spacing: -1px; }
.hero .row { display: flex; gap: 28px; margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--bolso-saldo-divisor); }
.hero .row .k { color: var(--bolso-saldo-texto-2); font-size: 12.5px; }
.hero .row .v { font-size: 16px; font-weight: 700; margin-top: 2px; }

/* ============================================================
   TABELA DE TRANSAÇÕES
   ============================================================ */
.table-wrap { overflow-x: auto; }
table.tx { width: 100%; border-collapse: collapse; }
table.tx th {
    text-align: left;
    font-size: 12px; font-weight: 700; letter-spacing: .3px; text-transform: uppercase;
    color: var(--bolso-placeholder);
    padding: 0 16px 12px;
    border-bottom: 1px solid var(--bolso-linha);
}
table.tx td { padding: 14px 16px; border-bottom: 1px solid var(--bolso-linha); font-size: 14px; vertical-align: middle; }
table.tx tbody tr:last-child td { border-bottom: none; }
table.tx tbody tr:hover { background: var(--bolso-fundo); }
.tx-cat { display: flex; align-items: center; gap: 12px; }
.tx-cat .badge {
    width: 38px; height: 38px; border-radius: 11px;
    display: grid; place-items: center; flex-shrink: 0;
}
.tx-cat .desc { font-weight: 700; }
.tx-cat .sub { color: var(--bolso-texto-2); font-size: 12.5px; }
.amount { font-weight: 800; text-align: right; white-space: nowrap; }
.chip {
    display: inline-block; padding: 4px 11px; border-radius: var(--r-pill);
    font-size: 12px; font-weight: 700;
    background: var(--bolso-fundo); color: var(--bolso-texto-2);
}

/* ---------- Donut (despesas por categoria) ---------- */
.donut-row { display: flex; align-items: center; gap: 24px; }
.legend { display: flex; flex-direction: column; gap: 12px; flex: 1; }
.legend .li { display: flex; align-items: center; gap: 10px; font-size: 13.5px; }
.legend .dot { width: 11px; height: 11px; border-radius: 50%; flex-shrink: 0; }
.legend .li .nm { font-weight: 600; }
.legend .li .vl { margin-left: auto; font-weight: 700; color: var(--bolso-texto-2); }

.empty { text-align: center; color: var(--bolso-texto-2); padding: 28px 10px; }

/* ---------- Cabeçalho de página com ações ---------- */
.page-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 22px; flex-wrap: wrap; }
.page-head .htext .page-title { margin: 0; }
.page-head .htext .page-sub { margin: 2px 0 0; }
.page-head .hactions { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }

.month-nav { display: inline-flex; align-items: center; gap: 4px; background: #fff; border: 1px solid var(--bolso-linha); border-radius: var(--r-pill); padding: 5px 6px; }
.month-nav .mn-btn { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; color: var(--bolso-texto-2); }
.month-nav .mn-btn:hover { background: var(--bolso-fundo); color: var(--bolso-roxo-vibrante); }
.month-nav .mn-cur { font-weight: 700; font-size: 14px; min-width: 118px; text-align: center; }

.seg { display: inline-flex; gap: 5px; background: var(--bolso-fundo); border: 1px solid var(--bolso-linha); border-radius: var(--r-pill); padding: 4px; }
.seg a { padding: 8px 16px; border-radius: var(--r-pill); font-weight: 600; font-size: 13.5px; color: var(--bolso-texto-2); }
.seg a.active { background: #fff; color: var(--bolso-roxo-vibrante); box-shadow: var(--sombra-acao); }

.mini-stats { display: flex; gap: 14px; margin-bottom: 20px; flex-wrap: wrap; }
.mini-stat { display: flex; align-items: center; gap: 10px; background: #fff; border: 1px solid var(--bolso-linha); border-radius: 16px; padding: 12px 18px; }
.mini-stat .k { color: var(--bolso-texto-2); font-size: 12.5px; }
.mini-stat .v { font-weight: 800; font-size: 17px; }

/* ---------- Gráfico de barras (relatórios) ---------- */
.bars { display: flex; align-items: flex-end; gap: 16px; height: 240px; padding: 12px 4px 0; }
.bars .col { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 10px; height: 100%; justify-content: flex-end; }
.bars .pair { display: flex; align-items: flex-end; gap: 6px; height: 100%; width: 100%; justify-content: center; }
.bars .bar { width: 18px; border-radius: 6px 6px 0 0; min-height: 3px; transition: height .2s; }
.bars .bar.inc { background: var(--bolso-verde); }
.bars .bar.exp { background: var(--bolso-vermelho); }
.bars .mlabel { font-size: 12px; color: var(--bolso-texto-2); font-weight: 600; }
.legend-row { display: flex; gap: 20px; margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--bolso-linha); }
.legend-row .li { display: flex; align-items: center; gap: 8px; font-size: 13.5px; color: var(--bolso-texto-2); }
.legend-row .sw { width: 12px; height: 12px; border-radius: 4px; }

/* ---------- Barra de progresso ---------- */
.progress { height: 10px; border-radius: 999px; background: var(--bolso-trilho); overflow: hidden; }
.progress > span { display: block; height: 100%; border-radius: 999px; background: var(--bolso-roxo-vibrante); transition: width .25s; }
.progress > span.ok { background: var(--bolso-verde); }
.progress > span.over { background: var(--bolso-vermelho); }

/* ---------- Cards de metas ---------- */
.cards-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 18px; }
.gcard { padding: 22px 24px; }
.gcard .gtop { display: flex; align-items: center; gap: 13px; margin-bottom: 16px; }
.gcard .gi { width: 46px; height: 46px; border-radius: 14px; display: grid; place-items: center; flex-shrink: 0; }
.gcard .gname { font-weight: 800; font-size: 16px; }
.gcard .gsub { color: var(--bolso-texto-2); font-size: 12.5px; margin-top: 1px; }
.gcard .gvals { display: flex; justify-content: space-between; align-items: baseline; margin-top: 12px; font-size: 13.5px; }
.gcard .gvals .cur { font-weight: 800; font-size: 16px; }
.gcard .gvals .tgt { color: var(--bolso-texto-2); }
.pill-ok { display: inline-block; padding: 3px 10px; border-radius: 999px; font-size: 11px; font-weight: 700; background: var(--bolso-verde-tint); color: var(--bolso-verde); }

/* ---------- Lista de contas ---------- */
.acc-list { display: flex; flex-direction: column; }
.acc-list .acc { display: flex; align-items: center; gap: 14px; padding: 16px 0; border-bottom: 1px solid var(--bolso-linha); }
.acc-list .acc:last-child { border-bottom: none; }
.acc-list .acc .ai { width: 44px; height: 44px; border-radius: 13px; display: grid; place-items: center; flex-shrink: 0; }
.acc-list .acc .an { font-weight: 700; }
.acc-list .acc .at { color: var(--bolso-texto-2); font-size: 12.5px; }
.acc-list .acc .ab { margin-left: auto; font-weight: 800; font-size: 16px; }

/* ---------- Perfil ---------- */
.av-lg { width: 64px; height: 64px; border-radius: 20px; flex-shrink: 0;
    background: linear-gradient(135deg, #8B5CF6, var(--bolso-roxo-vibrante));
    color: #fff; display: grid; place-items: center; font-size: 26px; font-weight: 800;
    box-shadow: 0 10px 22px rgba(109, 53, 255, .32); }
.plan-badge { display: inline-flex; align-items: center; gap: 6px; padding: 7px 14px; border-radius: 999px;
    font-weight: 700; font-size: 13px; background: var(--bolso-roxo-tint); color: var(--bolso-roxo-vibrante); }
.plan-badge.premium { background: #FFF3D6; color: #B7791F; }
.deflist { display: flex; flex-direction: column; }
.deflist .row { display: flex; align-items: center; justify-content: space-between; padding: 13px 0; border-bottom: 1px solid var(--bolso-linha); }
.deflist .row:last-child { border-bottom: none; }
.deflist .k { color: var(--bolso-texto-2); font-size: 14px; }
.deflist .v { font-weight: 700; font-size: 14px; }
.logout-link { display: inline-flex; align-items: center; gap: 8px; padding: 12px 18px; border-radius: 13px;
    font-weight: 700; color: var(--bolso-vermelho); background: var(--bolso-vermelho-tint); }
.logout-link:hover { filter: brightness(.98); }

/* ---------- Família ---------- */
.member { display: flex; align-items: center; gap: 13px; padding: 14px 0; border-bottom: 1px solid var(--bolso-linha); }
.member:last-child { border-bottom: none; }
.member .mav { width: 42px; height: 42px; border-radius: 50%; flex-shrink: 0;
    background: linear-gradient(135deg, #8B5CF6, var(--bolso-roxo-vibrante)); color: #fff;
    display: grid; place-items: center; font-weight: 800; }
.member .mn { font-weight: 700; }
.member .me { color: var(--bolso-texto-2); font-size: 12.5px; }
.upsell { display: flex; flex-direction: column; gap: 10px; }
.upsell .ut { display: flex; align-items: center; gap: 10px; font-weight: 800; color: #B7791F; }

.btn {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 11px 18px; border-radius: 13px;
    font-weight: 700; font-size: 14px;
    background: var(--bolso-roxo-vibrante); color: #fff;
    box-shadow: 0 8px 18px rgba(109, 53, 255, .28);
    transition: filter .15s;
}
.btn:hover { filter: brightness(1.06); }
.btn-ghost { background: var(--bolso-fundo); color: var(--bolso-texto); box-shadow: none; border: 1px solid var(--bolso-linha); }

/* ============================================================
   LOGIN
   ============================================================ */
.auth-stage {
    min-height: 100vh;
    display: grid;
    grid-template-columns: 1.05fr .95fr;
}
.auth-aside {
    background: var(--bolso-saldo-grad);
    color: #fff;
    padding: 56px 64px;
    display: flex; flex-direction: column; justify-content: center; gap: 18px;
}
.auth-aside .logo { width: 52px; height: 52px; border-radius: 15px; background: rgba(255,255,255,.14); display: grid; place-items: center; font-weight: 800; font-size: 26px; }
.auth-aside h1 { font-size: 40px; font-weight: 800; letter-spacing: -1px; line-height: 1.1; }
.auth-aside p { color: var(--bolso-saldo-texto-2); font-size: 16px; max-width: 420px; line-height: 1.5; }
.auth-aside .feats { display: flex; flex-direction: column; gap: 12px; margin-top: 12px; }
.auth-aside .feat { display: flex; align-items: center; gap: 12px; font-size: 14.5px; color: #efeaff; }
.auth-aside .feat .ck { width: 24px; height: 24px; border-radius: 50%; background: rgba(255,255,255,.16); display: grid; place-items: center; }

.auth-main { display: grid; place-items: center; padding: 40px; }
.auth-box { width: 100%; max-width: 380px; }
.auth-box h2 { font-size: 26px; font-weight: 800; letter-spacing: -0.5px; }
.auth-box .lead { color: var(--bolso-texto-2); margin: 6px 0 26px; }
.field { margin-bottom: 16px; }
.field label { display: block; font-size: 13px; font-weight: 600; color: var(--bolso-texto-2); margin-bottom: 7px; }
.field input {
    width: 100%; padding: 13px 15px;
    border: 1px solid var(--bolso-linha); border-radius: 13px;
    font-size: 15px; font-family: inherit; background: var(--bolso-fundo);
    transition: border-color .15s, background .15s;
}
.field input:focus { outline: none; border-color: var(--bolso-roxo-vibrante); background: #fff; }
.auth-box .btn { width: 100%; justify-content: center; padding: 14px; margin-top: 6px; }
.auth-box .alt { text-align: center; margin-top: 18px; color: var(--bolso-texto-2); font-size: 14px; }
.auth-box .alt a { color: var(--bolso-roxo-vibrante); font-weight: 700; }
.auth-error { background: var(--bolso-vermelho-tint); color: var(--bolso-vermelho); padding: 12px 14px; border-radius: 12px; font-size: 13.5px; margin-bottom: 18px; }

/* ============================================================
   RESPONSIVO
   ============================================================ */
.scrim { display: none; }

@media (max-width: 1024px) {
    .grid-dash { grid-template-columns: 1fr; }
}

@media (max-width: 860px) {
    .grid-3 { grid-template-columns: 1fr; }
    .auth-stage { grid-template-columns: 1fr; }
    .auth-aside { display: none; }
}

@media (max-width: 768px) {
    .sidebar {
        position: fixed; left: 0; top: 0; z-index: 60;
        transform: translateX(-100%);
        transition: transform .22s ease;
        box-shadow: 0 0 60px rgba(23,16,74,.25);
    }
    #navToggle:checked ~ .shell .sidebar { transform: translateX(0); }
    #navToggle:checked ~ .shell .scrim {
        display: block; position: fixed; inset: 0; z-index: 50;
        background: rgba(23,16,74,.35);
    }
    .topbar .menu-toggle { display: inline-grid; place-items: center; width: 40px; height: 40px; border-radius: 11px; background: var(--bolso-fundo); }
    .content { padding: 20px 16px 40px; }
    .topbar { padding: 0 16px; }
    .hero .big { font-size: 32px; }
}

/* ============================================================
   REFAC PREMIUM (Organizze / YNAB / Copilot Money)
   Verde como cor principal · fundo claro · cantos 16px · espaçamento generoso
   Este bloco vem por último: re-skina o app inteiro repointando os tokens.
   ============================================================ */
:root {
    /* Verde/vermelho ficam APENAS na semântica financeira (receita/despesa, deltas). */
    --green: #16A34A;
    --green-deep: #15803D;
    --green-tint: #E7F6EE;
    --green-soft: #DCFCE7;

    /* Primário = ROXO/AZUL (paleta original da marca). */
    --bolso-roxo-vibrante: #6D35FF;
    --bolso-roxo-medio: #7B3DFF;
    --bolso-roxo-tint: #EFEAFF;

    /* fundo claro levemente lilás (combina com o roxo) + cantos premium */
    --bolso-fundo: #F7F7FD;
    --r-card: 16px;
    --r-card-lg: 18px;
    --r-badge: 14px;
}

/* avatares e sombras de marca → roxo */
.user-chip .av,
.av-lg,
.member .mav { background: linear-gradient(135deg, #9B6BFF, var(--bolso-roxo-vibrante)); }
.brand .logo { box-shadow: 0 8px 18px rgba(109, 53, 255, .32); }
.btn { box-shadow: 0 8px 18px rgba(109, 53, 255, .26); }

/* sidebar: item ativo com leve barra verde à esquerda */
.nav-item.active { position: relative; }
.nav-item.active::before {
    content: ""; position: absolute; left: 0; top: 9px; bottom: 9px; width: 3px;
    border-radius: 0 3px 3px 0; background: var(--bolso-roxo-vibrante);
}

/* títulos de sub-páginas consistentes (independe do aninhamento) */
.content > .page-title,
.page-head .page-title,
.page-title { font-size: 26px; font-weight: 800; letter-spacing: -0.5px; }

/* ---------- Dashboard premium ---------- */
.dash-greeting { font-size: 36px; font-weight: 700; letter-spacing: -1.2px; margin: 0 0 4px; }
.dash-sub { color: var(--bolso-texto-2); font-size: 15px; margin: 0 0 30px; }

.scards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-bottom: 26px; }
.scard {
    background: #fff; border: 1px solid var(--bolso-linha); border-radius: 16px;
    box-shadow: var(--sombra-card); padding: 26px 28px;
}
.scard .shead { display: flex; align-items: center; justify-content: space-between; }
.scard .slabel { color: var(--bolso-texto-2); font-size: 13.5px; font-weight: 600; }
.scard .sico { width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center;
    color: var(--bolso-texto-2); background: var(--bolso-fundo); }
.scard .sval { font-size: 29px; font-weight: 800; letter-spacing: -0.8px; margin-top: 16px; white-space: nowrap; }

.delta { display: inline-flex; align-items: center; gap: 5px; font-size: 12.5px; font-weight: 700;
    margin-top: 12px; padding: 4px 10px; border-radius: 999px; }
.delta.good { color: var(--green-deep); background: var(--green-tint); }
.delta.bad { color: var(--bolso-vermelho); background: var(--bolso-vermelho-tint); }
.delta.flat { color: var(--bolso-texto-2); background: var(--bolso-fundo); }

.insights { display: grid; grid-template-columns: repeat(auto-fit, minmax(255px, 1fr)); gap: 16px; margin-bottom: 26px; }
.insight { display: flex; gap: 14px; align-items: flex-start;
    background: #fff; border: 1px solid var(--bolso-linha); border-radius: 16px;
    box-shadow: var(--sombra-card); padding: 18px 20px; }
.insight .iemoji { width: 44px; height: 44px; border-radius: 13px; display: grid; place-items: center;
    font-size: 21px; flex-shrink: 0; }
.insight .it { font-weight: 700; font-size: 14.5px; line-height: 1.35; }
.insight .id { color: var(--bolso-texto-2); font-size: 12.5px; margin-top: 3px; }

.goal-row { padding: 15px 0; border-bottom: 1px solid var(--bolso-linha); }
.goal-row:last-child { border-bottom: none; padding-bottom: 2px; }
.goal-row .gr-top { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 9px; gap: 12px; }
.goal-row .gr-name { font-weight: 700; font-size: 14.5px; }
.goal-row .gr-pct { font-weight: 800; font-size: 13.5px; color: var(--bolso-roxo-vibrante); }
.goal-row .gr-val { font-size: 12.5px; color: var(--bolso-texto-2); margin-top: 8px; }
.goal-row .gr-val b { color: var(--bolso-texto); font-weight: 700; }

.section-h { display: flex; align-items: center; justify-content: space-between; }

/* ---------- Modal + formulário ---------- */
.modal-scrim { position: fixed; inset: 0; background: rgba(23, 16, 74, .42); display: grid; place-items: center; z-index: 100; padding: 20px; }
.modal { background: #fff; border-radius: 18px; width: 100%; max-width: 470px; box-shadow: 0 30px 70px rgba(23, 16, 74, .3); max-height: 92vh; display: flex; flex-direction: column; overflow: hidden; }
.modal .mhead { display: flex; align-items: center; justify-content: space-between; padding: 20px 24px 16px; flex-shrink: 0; }
.modal .mhead h3 { font-size: 19px; font-weight: 800; }
.modal .mbody { padding: 0 24px 8px; flex: 1 1 auto; min-height: 0; overflow-y: auto; }
.modal .mfoot { padding: 16px 24px 22px; display: flex; gap: 12px; flex-shrink: 0; }
.modal .mfoot .btn, .modal .mfoot .btn-ghost { flex: 1; justify-content: center; }
.mclose { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; color: var(--bolso-texto-2); font-size: 20px; }
.mclose:hover { background: var(--bolso-fundo); }

/* Paginação reutilizável (ListPager): seletor 30/50/100 + Anterior/Próxima */
.pgr { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding: 14px 4px 2px; }
.pgr-size { display: inline-flex; align-items: center; gap: 8px; font-size: 12.5px; color: var(--dx-muted); font-weight: 600; }
.pgr-size select { height: 34px; border-radius: 10px; border: 1px solid var(--dx-border); background: var(--bolso-card, #fff); color: var(--dx-ink); font-size: 13px; font-weight: 700; padding: 0 8px; cursor: pointer; }
.pgr-nav { display: inline-flex; align-items: center; gap: 8px; }
.pgr-info { font-size: 12.5px; color: var(--dx-muted); }
.pgr-page { font-size: 13px; font-weight: 700; color: var(--dx-ink); min-width: 50px; text-align: center; }
.pgr-btn { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; border: 1px solid var(--dx-border); background: var(--bolso-card, #fff); color: var(--dx-muted); cursor: pointer; transition: .15s; }
.pgr-btn:hover:not(:disabled) { color: var(--bolso-roxo-vibrante); border-color: var(--bolso-roxo-vibrante); }
.pgr-btn:disabled { opacity: .4; cursor: default; }

.f-row { margin-bottom: 14px; }
.f-label { display: block; font-size: 13px; font-weight: 600; color: var(--bolso-texto-2); margin-bottom: 7px; }
.f-input, .f-select { width: 100%; padding: 12px 14px; border: 1px solid var(--bolso-linha); border-radius: 12px;
    font-size: 14.5px; font-family: inherit; background: var(--bolso-fundo); color: var(--bolso-texto); }
.f-input:focus, .f-select:focus { outline: none; border-color: var(--bolso-roxo-vibrante); background: #fff; }
.type-toggle { display: flex; background: var(--bolso-fundo); border-radius: 14px; padding: 4px; margin-bottom: 16px; }
.type-toggle button { flex: 1; padding: 10px; border-radius: 11px; font-weight: 700; color: var(--bolso-texto-2); }
.type-toggle button.on-exp { background: var(--bolso-vermelho); color: #fff; }
.type-toggle button.on-inc { background: var(--green); color: #fff; }
.f-error { background: var(--bolso-vermelho-tint); color: var(--bolso-vermelho); padding: 10px 13px; border-radius: 10px; font-size: 13px; margin-bottom: 14px; }

.row-actions { display: inline-flex; gap: 4px; }
.icon-btn { width: 32px; height: 32px; border-radius: 9px; display: grid; place-items: center; color: var(--bolso-chevron); }
.icon-btn:hover { background: var(--bolso-fundo); color: var(--bolso-texto); }
.icon-btn.danger:hover { background: var(--bolso-vermelho-tint); color: var(--bolso-vermelho); }

/* ============================================================
   FINTECH PREMIUM V2 — Dashboard redesign
   (Nubank / Inter / Cora / Stripe / Linear) · raio 20px ·
   profundidade em camadas · espaçamento generoso · micro-animações
   Este bloco vem por último (sobrescreve o necessário).
   ============================================================ */
:root {
    --r-card: 20px;
    --r-card-lg: 24px;
    --r-badge: 14px;
    --ink: #0E1525;
    --shadow-sm: 0 1px 2px rgba(14,21,37,.04), 0 1px 3px rgba(14,21,37,.05);
    --shadow-md: 0 2px 6px rgba(14,21,37,.05), 0 14px 30px rgba(14,21,37,.08);
    --shadow-lg: 0 10px 30px rgba(14,21,37,.10), 0 30px 60px rgba(14,21,37,.10);
    --shadow-hero: 0 24px 60px rgba(11,17,32,.32);
    --ease: cubic-bezier(.2,.7,.2,1);
}
body { background: #F7F7FD; }

/* ---------- Profundidade + lift nos cards ---------- */
.card { box-shadow: var(--shadow-sm); transition: transform .2s var(--ease), box-shadow .2s var(--ease); }
.card:hover { box-shadow: var(--shadow-md); }

/* ---------- Animação de entrada (reveal escalonado) ---------- */
@keyframes fadeUp { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
.reveal { animation: fadeUp .55s var(--ease) both; }
.reveal.d1 { animation-delay: .04s; }
.reveal.d2 { animation-delay: .10s; }
.reveal.d3 { animation-delay: .16s; }
.reveal.d4 { animation-delay: .22s; }
.reveal.d5 { animation-delay: .28s; }
@media (prefers-reduced-motion: reduce) { .reveal { animation: none; } }

/* ---------- Layout do dashboard ---------- */
.dash { display: flex; flex-direction: column; gap: 30px; }
.dash-hi { font-size: 34px; font-weight: 800; letter-spacing: -1px; margin: 0 0 4px; color: var(--ink); }
.dash-hi .wave { display: inline-block; transform-origin: 70% 70%; animation: wave 2.4s ease-in-out 1; }
@keyframes wave { 0%,60%,100%{transform:rotate(0)} 20%{transform:rotate(16deg)} 40%{transform:rotate(-8deg)} }
.dash-cap { color: var(--bolso-texto-2); font-size: 15px; margin: 0; }

/* ---------- HERO financeiro (escuro, sofisticado) ---------- */
.hero {
    position: relative; overflow: hidden;
    border-radius: var(--r-card-lg);
    background:
        radial-gradient(120% 140% at 85% 0%, rgba(123,61,255,.30) 0%, rgba(123,61,255,0) 45%),
        linear-gradient(135deg, #131A2B 0%, #0E1525 55%, #0B1120 100%);
    color: #fff;
    box-shadow: var(--shadow-hero);
    padding: 30px 34px;
    display: grid; grid-template-columns: 1.05fr 1fr; gap: 24px; align-items: center;
}
.hero::after { content: ""; position: absolute; right: -60px; top: -60px; width: 240px; height: 240px;
    background: radial-gradient(circle, rgba(123,61,255,.22), transparent 70%); pointer-events: none; }
.hero .h-label { color: #9FB0C9; font-size: 13.5px; font-weight: 600; display: flex; align-items: center; gap: 8px; }
.hero .h-bal { font-size: 46px; font-weight: 800; letter-spacing: -1.5px; margin: 10px 0 2px; line-height: 1; }
.hero .h-delta { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 700;
    padding: 5px 11px; border-radius: 999px; margin-top: 6px; }
.hero .h-delta.up { background: rgba(34,197,94,.18); color: #5BE584; }
.hero .h-delta.down { background: rgba(255,99,114,.16); color: #FF8A95; }
.hero .h-delta.flat { background: rgba(255,255,255,.08); color: #9FB0C9; }
.hero .h-pills { display: flex; gap: 22px; margin-top: 22px; }
.hero .h-pill .k { color: #8595AE; font-size: 12px; display: flex; align-items: center; gap: 6px; }
.hero .h-pill .v { font-size: 18px; font-weight: 700; margin-top: 3px; }
.hero .h-chart { align-self: stretch; min-height: 130px; display: flex; align-items: center; }
.hero .h-chart svg { width: 100%; height: 130px; display: block; }

/* ---------- Cards premium (saldo/receitas/despesas) ---------- */
.pcards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.pcard {
    background: #fff; border: 1px solid var(--bolso-linha); border-radius: var(--r-card);
    box-shadow: var(--shadow-sm); padding: 24px 26px;
    transition: transform .2s var(--ease), box-shadow .2s var(--ease);
}
.pcard:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.pcard .p-top { display: flex; align-items: center; justify-content: space-between; }
.pcard .p-ico { width: 46px; height: 46px; border-radius: 14px; display: grid; place-items: center; }
.pcard .p-label { color: var(--bolso-texto-2); font-size: 13.5px; font-weight: 600; }
.pcard .p-val { font-size: 30px; font-weight: 800; letter-spacing: -.8px; margin-top: 16px; white-space: nowrap; }
.p-delta { display: inline-flex; align-items: center; gap: 5px; font-size: 12.5px; font-weight: 700;
    margin-top: 12px; padding: 4px 10px; border-radius: 999px; }
.p-delta.good { color: var(--green-deep); background: var(--green-tint); }
.p-delta.bad { color: var(--bolso-vermelho); background: var(--bolso-vermelho-tint); }
.p-delta.flat { color: var(--bolso-texto-2); background: var(--bolso-fundo); }

/* ---------- Card de gráfico (evolução) ---------- */
.panel { background: #fff; border: 1px solid var(--bolso-linha); border-radius: var(--r-card);
    box-shadow: var(--shadow-sm); padding: 24px 26px; }
.panel-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 6px; }
.panel-title { font-size: 16px; font-weight: 800; letter-spacing: -.3px; color: var(--ink); }
.panel-sub { color: var(--bolso-texto-2); font-size: 13px; }
.chart-legend { display: flex; gap: 18px; }
.chart-legend .li { display: flex; align-items: center; gap: 7px; font-size: 12.5px; color: var(--bolso-texto-2); font-weight: 600; }
.chart-legend .dot { width: 9px; height: 9px; border-radius: 3px; }
.evo-svg { width: 100%; height: 230px; display: block; overflow: visible; }
.evo-x { font-size: 11px; fill: var(--bolso-placeholder); font-weight: 600; }
.evo-grid { stroke: var(--bolso-linha); stroke-width: 1; }

/* ---------- Insights premium ---------- */
.ins-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(258px, 1fr)); gap: 18px; }
.ins-card { display: flex; gap: 15px; align-items: flex-start; background: #fff; border: 1px solid var(--bolso-linha);
    border-radius: var(--r-card); box-shadow: var(--shadow-sm); padding: 20px 22px;
    transition: transform .2s var(--ease), box-shadow .2s var(--ease); }
.ins-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
.ins-card .i-emoji { width: 46px; height: 46px; border-radius: 14px; display: grid; place-items: center; font-size: 22px; flex-shrink: 0; }
.ins-card .i-t { font-weight: 700; font-size: 14.5px; line-height: 1.35; color: var(--ink); }
.ins-card .i-d { color: var(--bolso-texto-2); font-size: 12.5px; margin-top: 3px; }

/* ---------- Metas em cards ---------- */
.gcards { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 18px; }
.gcard2 { background: #fff; border: 1px solid var(--bolso-linha); border-radius: var(--r-card);
    box-shadow: var(--shadow-sm); padding: 22px; transition: transform .2s var(--ease), box-shadow .2s var(--ease); }
.gcard2:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
.gcard2 .g-top { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
.gcard2 .g-ico { width: 42px; height: 42px; border-radius: 13px; display: grid; place-items: center; flex-shrink: 0; }
.gcard2 .g-name { font-weight: 700; font-size: 14.5px; color: var(--ink); }
.gcard2 .g-pct { margin-left: auto; font-weight: 800; font-size: 14px; color: var(--bolso-roxo-vibrante); }
.gcard2 .progress { height: 9px; }
.gcard2 .g-vals { margin-top: 11px; font-size: 12.5px; color: var(--bolso-texto-2); }
.gcard2 .g-vals b { color: var(--ink); }

/* ---------- Skeleton loading (shimmer) ---------- */
.sk { position: relative; overflow: hidden; background: #EAEDF1; border-radius: 12px; }
.sk::after { content: ""; position: absolute; inset: 0;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,.65), transparent);
    transform: translateX(-100%); animation: shimmer 1.4s infinite; }
@keyframes shimmer { 100% { transform: translateX(100%); } }
.sk-hero { height: 196px; border-radius: var(--r-card-lg); }
.sk-card { height: 116px; border-radius: var(--r-card); }
.sk-panel { height: 300px; border-radius: var(--r-card); }
.sk-line { height: 13px; border-radius: 7px; }

/* ---------- Sidebar moderna ---------- */
.sidebar { padding: 24px 18px; }
.brand { padding: 4px 10px 26px; }
.brand .logo { width: 40px; height: 40px; border-radius: 13px; font-size: 21px; }
.nav-item { padding: 12px 14px; border-radius: 14px; font-size: 14.5px; gap: 14px; }
.nav-item .ico { width: 19px; height: 19px; }
.nav-item.active { font-weight: 700; box-shadow: inset 0 0 0 1px rgba(109,53,255,.12); }
.nav-item.active::before { top: 11px; bottom: 11px; }
.nav-label { padding: 14px 14px 6px; }
.user-chip { padding: 6px 14px 6px 6px; }
.user-chip .av { box-shadow: 0 4px 10px rgba(109,53,255,.30); }

/* ---------- Responsivo ---------- */
@media (max-width: 1100px) {
    .hero { grid-template-columns: 1fr; }
    .hero .h-chart { min-height: 96px; }
    .hero .h-chart svg { height: 96px; }
}
@media (max-width: 920px) {
    .pcards { grid-template-columns: 1fr; }
    .dash { gap: 22px; }
    .dash-hi { font-size: 28px; }
    .hero .h-bal { font-size: 38px; }
}

/* ---------- Lista premium de movimentações ---------- */
.mv { display: flex; flex-direction: column; }
.mv .row { display: flex; align-items: center; gap: 14px; padding: 14px 0; border-bottom: 1px solid var(--bolso-linha); }
.mv .row:last-child { border-bottom: none; padding-bottom: 0; }
.mv .badge { width: 42px; height: 42px; border-radius: 13px; display: grid; place-items: center; flex-shrink: 0; }
.mv .desc { font-weight: 700; font-size: 14px; color: var(--ink); }
.mv .sub { color: var(--bolso-texto-2); font-size: 12.5px; margin-top: 1px; }
.mv .amt { margin-left: auto; font-weight: 800; font-size: 14.5px; white-space: nowrap; }
.mv .day { color: var(--bolso-placeholder); font-size: 11.5px; margin-top: 2px; }

.pchip { display: inline-flex; align-items: center; gap: 8px; padding: 9px 15px; border-radius: 999px;
    background: #fff; border: 1px solid var(--bolso-linha); box-shadow: var(--shadow-sm);
    font-weight: 700; font-size: 13.5px; color: var(--ink); }
.see-all { font-size: 13px; font-weight: 700; color: var(--bolso-roxo-vibrante); display: inline-flex; align-items: center; gap: 4px; }
.see-all:hover { gap: 7px; transition: gap .15s var(--ease); }
.dash-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; flex-wrap: wrap; }

/* ============================================================
   PREMIUM POLISH — páginas internas (cohesão com o dashboard)
   ============================================================ */
/* entrada suave só nas páginas internas (têm .page-head; o dashboard usa .dash-head) */
.content:has(.page-head) { animation: fadeUp .4s var(--ease) both; }

.page-head { margin-bottom: 16px; }
.page-title { font-size: 23px; font-weight: 800; letter-spacing: -.6px; color: var(--ink); }
.page-sub { font-size: 13.5px; }
.card-pad { padding: 16px 20px; }
.empty { padding: 24px 10px; font-size: 14px; }
.modal { border-radius: 20px; }

/* mini-stats → mini cards premium (Transações/Relatórios) */
.mini-stats { gap: 14px; margin-bottom: 16px; }
.mini-stat { gap: 12px; padding: 13px 18px; border-radius: 16px; box-shadow: var(--shadow-sm);
    transition: transform .2s var(--ease), box-shadow .2s var(--ease); }
.mini-stat:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
.mini-stat .ico-badge { width: 38px; height: 38px; border-radius: 12px; }
.mini-stat .k { font-size: 12.5px; font-weight: 600; }
.mini-stat .v { font-size: 17px; }

/* filtros e seletor de mês com profundidade */
.seg { padding: 5px; box-shadow: var(--shadow-sm); }
.seg a { padding: 9px 18px; }
.month-nav { padding: 6px 7px; box-shadow: var(--shadow-sm); }
.month-nav .mn-btn { width: 34px; height: 34px; }

/* cards de meta/orçamento com respiro e lift */
.gcard { padding: 24px 26px; transition: transform .2s var(--ease), box-shadow .2s var(--ease); }
.gcard:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
.gcard .gi { width: 48px; height: 48px; border-radius: 15px; }
.gcard .gname { font-size: 16px; color: var(--ink); }

/* tabela mais leve / menos "admin" */
table.tx th { padding-bottom: 14px; font-size: 11.5px; }
table.tx td { padding: 16px; }
table.tx .tx-cat .badge { width: 42px; height: 42px; border-radius: 13px; }

/* contas e membros com respiro */
.acc-list .acc { padding: 18px 0; }
.acc-list .acc .ai { width: 46px; height: 46px; border-radius: 14px; }
.member .mav { width: 46px; height: 46px; }

/* botões com micro-lift */
.btn, .btn-ghost { border-radius: 14px; transition: transform .15s var(--ease), filter .15s, box-shadow .2s var(--ease), background .15s; }
.btn:hover { transform: translateY(-1px); }

/* barras do Relatórios premium (gradiente + arredondado) */
.bars .bar { width: 22px; }
.bars .bar.inc { background: linear-gradient(180deg, #34D399, #16A34A); border-radius: 8px 8px 0 0; }
.bars .bar.exp { background: linear-gradient(180deg, #FF6171, #E11D48); border-radius: 8px 8px 0 0; }

/* avatar do Perfil com mais presença */
.av-lg { width: 72px; height: 72px; border-radius: 22px; font-size: 28px; }

/* ============================================================
   DASHBOARD V3 — Referência fiel (Stripe / Mercury / Ramp / Linear)
   Paleta roxo #6D28D9 · cantos 20px · sombras sutis · muito branco.
   Bloco final autoritativo: redefine sidebar + dashboard (.dx-*).
   ============================================================ */
:root {
    --dx-primary: #6D28D9;
    --dx-primary-dark: #5B21B6;
    --dx-primary-soft: #F5F3FF;
    --dx-success: #22C55E;
    --dx-danger: #EF4444;
    --dx-ink: #0F172A;
    --dx-muted: #64748B;
    --dx-border: #EEF2F7;
    --dx-line: #F1F5F9;
    --dx-bg: #FAFBFC;
    --dx-shadow: 0 4px 20px rgba(15, 23, 42, .04);
    --dx-shadow-h: 0 10px 30px rgba(15, 23, 42, .08);
    --dx-r: 20px;
}

body { background: var(--dx-bg); color: var(--dx-ink); }

/* ---------- Conteúdo: header é da página, sem topbar no desktop ---------- */
.content { max-width: none; padding: 14px 28px 16px; margin: 0; }
.topbar-m { display: none; }

/* ============================================================
   SIDEBAR (spec)
   ============================================================ */
.sidebar {
    width: 260px;
    background: linear-gradient(180deg, #0F172A 0%, #1E1B4B 100%);
    border-right: none;
    padding: 24px 16px 20px;
    gap: 0;
}
.sb-brand { padding: 6px 12px 26px; }
.sb-logo { font-size: 23px; font-weight: 800; letter-spacing: -.5px; color: #fff; }
.sb-logo .plus { color: var(--dx-success); }
.sb-logo.sm { font-size: 19px; }
.sb-logo-img { height: 38px; width: auto; max-width: 100%; display: block; }
.sb-logo-img.sm { height: 30px; }
/* sino na sidebar escura */
.sidebar .nb-btn { color: #A9B4CC; }
.sidebar .nb-btn:hover, .sidebar .nb-btn.on { background: rgba(255, 255, 255, .08); color: #fff; }

.sb-nav { display: flex; flex-direction: column; gap: 4px; }
.sb-item {
    display: flex; align-items: center; gap: 13px;
    padding: 12px 14px; border-radius: 14px;
    color: #A9B4CC; font-weight: 600; font-size: 14.5px;
    transition: background .15s, color .15s;
}
.sb-item .ico { width: 20px; height: 20px; flex-shrink: 0; }
.sb-item:hover { background: #312E81; color: #fff; }
.sb-item.active { background: linear-gradient(135deg, #6D28D9, #7C3AED); color: #fff; font-weight: 700;
    border-radius: 16px; box-shadow: 0 10px 22px rgba(124, 58, 237, .35); }
.sb-item.active .ico { color: #fff; }

.sb-foot { margin-top: auto; display: flex; flex-direction: column; gap: 16px; padding-top: 18px; }

/* Card Pro (gradiente roxo→azul) */
.sb-pro {
    border-radius: 18px; padding: 18px;
    background: linear-gradient(150deg, #4C1D95 0%, #5B21B6 48%, #4338CA 100%);
    color: #fff;
}
.sb-pro-top { display: flex; align-items: center; gap: 8px; font-size: 16px; font-weight: 800; }
.sb-pro-top b { letter-spacing: -.3px; }
.sb-pro-tag { font-size: 11px; font-weight: 700; padding: 2px 8px; border-radius: 999px; background: rgba(255,255,255,.18); }
.sb-pro p { color: #DDD6FE; font-size: 12.5px; margin: 8px 0 12px; line-height: 1.45; }
.sb-pro ul { list-style: none; margin: 0 0 14px; padding: 0; display: flex; flex-direction: column; gap: 7px; }
.sb-pro li { display: flex; align-items: center; gap: 8px; font-size: 12.5px; color: #EDE9FE; }
.sb-pro li .ico { width: 15px; height: 15px; color: #5BE584; flex-shrink: 0; }
.sb-pro-btn {
    display: block; text-align: center; padding: 11px; border-radius: 12px;
    background: var(--dx-success); color: #06351E; font-weight: 800; font-size: 13.5px;
    transition: filter .15s;
}
.sb-pro-btn:hover { filter: brightness(1.05); }

/* Humor financeiro (premium) — substitui o card Pro no rodapé do sidebar */
.mood-card { border-radius: 18px; padding: 18px 18px 20px; color: #fff; text-align: center; }
.mood-emoji { font-size: 40px; line-height: 1; margin-bottom: 6px; }
.mood-head { font-weight: 800; font-size: 16px; letter-spacing: -.2px; }
.mood-amt-lbl { font-size: 11px; font-weight: 600; color: rgba(255, 255, 255, .7); margin-top: 11px; text-transform: uppercase; letter-spacing: .04em; }
.mood-amt { font-weight: 800; font-size: 19px; margin-top: 2px; }
.mood-sub { font-size: 12px; line-height: 1.45; color: rgba(255, 255, 255, .9); margin-top: 9px; }
.mood--danger { background: linear-gradient(150deg, #9F1239 0%, #BE123C 50%, #7F1D1D 100%); }
.mood--warn { background: linear-gradient(150deg, #9A3412 0%, #C2410C 50%, #7C2D12 100%); }
.mood--calm { background: linear-gradient(150deg, #1E3A8A 0%, #1D4ED8 50%, #3730A3 100%); }
.mood--good { background: linear-gradient(150deg, #065F46 0%, #047857 50%, #064E3B 100%); }
.mood--great { background: linear-gradient(150deg, #047857 0%, #10B981 50%, #059669 100%); }
.mood-sk { border-radius: 18px; padding: 18px; background: rgba(255, 255, 255, .05); display: flex; flex-direction: column;
    gap: 10px; align-items: center; justify-content: center; min-height: 120px; }
.mood-sk .ln { height: 12px; border-radius: 6px; background: rgba(255, 255, 255, .10); animation: moodpulse 1.2s ease-in-out infinite; }
.mood-sk .ln.a { width: 40px; height: 30px; border-radius: 50%; }
.mood-sk .ln.b { width: 70%; }
.mood-sk .ln.c { width: 88%; }
@keyframes moodpulse { 0%, 100% { opacity: .5; } 50% { opacity: 1; } }

/* ===== Empréstimos ===== */
.lo { display: flex; flex-direction: column; gap: 18px; }
.lo-kpis { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.lo-kpi { display: flex; flex-direction: column; background: var(--bolso-card, #fff); border: 1px solid var(--dx-border); border-radius: 20px; box-shadow: var(--dx-shadow); padding: 18px 20px; }
.lo-kpi--green { background: linear-gradient(135deg, rgba(34, 197, 94, .07), var(--bolso-card, #fff) 55%); }
.lo-kpi--red { background: linear-gradient(135deg, rgba(251, 113, 133, .07), var(--bolso-card, #fff) 55%); }
.lo-kpi--purple { background: linear-gradient(135deg, rgba(109, 60, 246, .08), var(--bolso-card, #fff) 55%); }
.lo-kpi-top { display: flex; align-items: center; gap: 10px; }
.lo-kpi-ic { width: 38px; height: 38px; border-radius: 11px; display: grid; place-items: center; flex-shrink: 0; }
.lo-kpi-k { font-size: 13px; color: var(--dx-muted); font-weight: 700; }
.lo-kpi-v { font-size: 26px; font-weight: 800; color: var(--dx-ink); margin: 11px 0 0; letter-spacing: -.4px; }
.lo-kpi-foot { display: flex; align-items: flex-end; justify-content: space-between; gap: 10px; margin-top: 5px; }
.lo-kpi-d { font-size: 11.5px; color: var(--dx-muted); }
.lo-spark { width: 64px; height: 26px; flex-shrink: 0; opacity: .9; }

.lo-tabs { display: flex; gap: 8px; flex-wrap: wrap; }
.lo-tab { display: inline-flex; align-items: center; gap: 6px; padding: 8px 16px; border-radius: 999px; border: 1px solid var(--dx-border); background: var(--bolso-card, #fff); color: var(--dx-muted); font-weight: 700; font-size: 13px; cursor: pointer; transition: .15s; }
.lo-tab:hover { color: var(--bolso-roxo-vibrante); }
.lo-tab.on { background: linear-gradient(135deg, #6D28D9, #4F46E5); color: #fff; border-color: transparent; box-shadow: 0 6px 16px rgba(109, 40, 217, .28); }
.lo-tab-ck { display: inline-flex; }

/* Toolbar (filtros + busca) */
.lo-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.lo-search-wrap { display: flex; align-items: center; gap: 8px; }
.lo-search { display: inline-flex; align-items: center; gap: 8px; padding: 0 14px; height: 40px; border-radius: 999px; background: var(--bolso-card, #fff); border: 1px solid var(--dx-border); color: var(--dx-muted); min-width: 230px; }
.lo-search input { border: none; outline: none; background: transparent; font-size: 13.5px; color: var(--dx-ink); width: 100%; }
.lo-search input::placeholder { color: var(--dx-muted); }
.lo-filter-btn { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: var(--bolso-card, #fff); border: 1px solid var(--dx-border); color: var(--dx-muted); cursor: pointer; transition: .15s; }
.lo-filter-btn:hover { color: var(--bolso-roxo-vibrante); border-color: var(--bolso-roxo-vibrante); }

/* Estado vazio ilustrado */
.lo-empty-card { background: var(--bolso-card, #fff); border: 1px solid var(--dx-border); border-radius: 22px; box-shadow: var(--dx-shadow); padding: 46px 24px; display: flex; flex-direction: column; align-items: center; text-align: center; }
.lo-illus { width: 132px; height: 110px; margin-bottom: 8px; }
.lo-illus svg { width: 100%; height: 100%; display: block; }
.lo-empty-t { font-size: 18px; font-weight: 800; color: var(--dx-ink); margin: 6px 0 0; }
.lo-empty-s { font-size: 13.5px; color: var(--dx-muted); margin: 6px 0 0; }
.lo-empty-btn { margin-top: 18px; }

/* Card informativo */
.lo-info { display: flex; align-items: flex-start; gap: 14px; background: var(--bolso-card, #fff); border: 1px solid var(--dx-border); border-radius: 18px; box-shadow: var(--dx-shadow); padding: 16px 18px; }
.lo-info-ic { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; flex-shrink: 0; background: rgba(109, 60, 246, .12); color: var(--bolso-roxo-vibrante); }
.lo-info-tx { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.lo-info-tx b { font-size: 13.5px; font-weight: 800; color: var(--dx-ink); }
.lo-info-tx span { font-size: 12.5px; color: var(--dx-muted); line-height: 1.45; }
.lo-info-x { width: 28px; height: 28px; border-radius: 8px; display: grid; place-items: center; border: none; background: transparent; color: var(--dx-muted); cursor: pointer; flex-shrink: 0; }
.lo-info-x:hover { background: var(--dx-line); color: var(--dx-ink); }

/* Rodapé */
.lo-copyright { text-align: center; font-size: 12px; color: var(--dx-muted); padding: 6px 0 2px; }

.lo-empty { background: var(--bolso-card, #fff); border: 1px dashed var(--dx-border); border-radius: var(--dx-r, 16px); padding: 40px; text-align: center; color: var(--dx-muted); font-size: 14px; }
.lo-empty.sm { padding: 18px; }

.lo-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(330px, 1fr)); gap: 16px; }
.lo-card { background: var(--bolso-card, #fff); border: 1px solid var(--dx-border); border-radius: var(--dx-r, 16px); box-shadow: var(--dx-shadow); padding: 18px; display: flex; flex-direction: column; gap: 11px; }
.lo-card-top { display: flex; align-items: center; gap: 11px; }
.lo-av { width: 40px; height: 40px; border-radius: 50%; flex-shrink: 0; background: linear-gradient(135deg, #8B5CF6, var(--bolso-roxo-vibrante)); color: #fff; display: grid; place-items: center; font-weight: 800; font-size: 15px; }
.lo-av.sm { width: 32px; height: 32px; font-size: 13px; }
.lo-card-id { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.lo-name { font-weight: 700; font-size: 14.5px; color: var(--dx-ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lo-dir { font-size: 12px; font-weight: 700; }
.lo-dir.in { color: var(--bolso-verde); }
.lo-dir.out { color: var(--bolso-vermelho); }
.lo-status { font-size: 11px; font-weight: 800; padding: 4px 10px; border-radius: 999px; white-space: nowrap; }
.lo-status.open { background: rgba(109, 60, 246, .12); color: var(--bolso-roxo-vibrante); }
.lo-status.done { background: rgba(46, 204, 113, .16); color: #1F9D57; }
.lo-desc { font-size: 12.5px; color: var(--dx-muted); }
.lo-amt-row { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; }
.lo-amt-k { font-size: 11.5px; color: var(--dx-muted); font-weight: 600; }
.lo-amt-v { font-size: 22px; font-weight: 800; }
.lo-amt-side { display: flex; flex-direction: column; gap: 2px; text-align: right; font-size: 11px; color: var(--dx-muted); }
.lo-bar { height: 7px; border-radius: 999px; background: var(--dx-line); overflow: hidden; }
.lo-bar span { display: block; height: 100%; border-radius: 999px; background: linear-gradient(90deg, #8B5CF6, var(--bolso-roxo-vibrante)); transition: width .4s; }
.lo-meta { display: flex; align-items: center; justify-content: space-between; gap: 8px; font-size: 11.5px; color: var(--dx-muted); flex-wrap: wrap; }
.lo-chip { display: inline-flex; align-items: center; gap: 4px; padding: 3px 8px; border-radius: 999px; background: rgba(33, 118, 255, .12); color: #2176FF; font-weight: 700; font-size: 10.5px; }
.lo-due { font-size: 11.5px; color: var(--dx-muted); display: inline-flex; align-items: center; gap: 5px; }
.lo-acts { display: flex; align-items: center; gap: 8px; margin-top: 4px; }
.lo-pay { flex: 1; display: inline-flex; align-items: center; justify-content: center; gap: 7px; padding: 9px; border-radius: 11px; border: none; background: var(--bolso-roxo-vibrante); color: #fff; font-weight: 700; font-size: 13px; cursor: pointer; transition: filter .15s; }
.lo-pay:hover { filter: brightness(1.06); }
.lo-act { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; border: 1px solid var(--dx-border); background: var(--bolso-card, #fff); color: var(--dx-muted); cursor: pointer; transition: .15s; }
.lo-act:hover { color: var(--bolso-roxo-vibrante); border-color: var(--bolso-roxo-vibrante); }
.lo-act.danger:hover { color: var(--bolso-vermelho); border-color: var(--bolso-vermelho); }

.lo-hint { font-size: 11.5px; color: var(--dx-muted); margin-top: 6px; line-height: 1.4; }
.f-grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }

/* ===== Modal "Nova conta standby" — premium, escopado em .lo-modal ===== */
.lo-scrim { backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); background: rgba(28, 25, 56, .45); }
.lo-modal { max-width: 560px; padding: 0; border-radius: 28px; box-shadow: 0 40px 90px rgba(15, 23, 42, .28); max-height: 92vh; display: flex; flex-direction: column; overflow: hidden; }
.lo-modal .mhead { padding: 22px 28px 4px; align-items: flex-start; flex-shrink: 0; }
.lo-modal .mhead h3 { font-size: 23px; font-weight: 800; color: var(--dx-ink); letter-spacing: -.5px; }
.lo-modal .mclose { width: 40px; height: 40px; border-radius: 12px; border: 1px solid var(--dx-border); background: var(--bolso-card, #fff); color: var(--dx-muted); box-shadow: 0 2px 8px rgba(15, 23, 42, .06); display: grid; place-items: center; transition: .18s; }
.lo-modal .mclose:hover { background: rgba(109, 60, 246, .08); color: var(--bolso-roxo-vibrante); border-color: #E5DEFF; }
.lo-modal .mbody { padding: 12px 28px 12px; display: flex; flex-direction: column; gap: 13px; flex: 1 1 auto; min-height: 0; overflow-y: auto; }
.lo-modal .mfoot { padding: 14px 28px 20px; display: flex; gap: 14px; flex-shrink: 0; border-top: 1px solid var(--dx-border); }
.lo-modal .mfoot .btn-ghost, .lo-modal .mfoot .btn { flex: 1; }
.lo-modal .mfoot .btn.lo-save { flex: 1.3; }

/* segmented control */
.lo-seg { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; padding: 6px; background: var(--dx-line); border: 1px solid var(--dx-border); border-radius: 16px; }
.lo-seg-btn { display: inline-flex; align-items: center; justify-content: center; gap: 9px; padding: 12px; border-radius: 12px; border: 1.5px solid transparent; background: transparent; color: var(--dx-muted); font-weight: 700; font-size: 14.5px; cursor: pointer; transition: .18s; }
.lo-seg-ic { width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; flex-shrink: 0; }
.lo-seg-ic.in { background: rgba(34, 197, 94, .14); color: #16A34A; }
.lo-seg-ic.out { background: rgba(244, 63, 94, .14); color: #F43F5E; }
.lo-seg-btn.on.in { background: rgba(34, 197, 94, .10); border-color: rgba(34, 197, 94, .42); color: #16A34A; box-shadow: 0 4px 12px rgba(34, 197, 94, .12); }
.lo-seg-btn.on.out { background: rgba(244, 63, 94, .10); border-color: rgba(244, 63, 94, .42); color: #F43F5E; box-shadow: 0 4px 12px rgba(244, 63, 94, .12); }

/* labels com ícone */
.lo-fl { display: flex; align-items: center; gap: 9px; font-size: 14px; font-weight: 700; color: var(--dx-ink); margin-bottom: 7px; }
.lo-fl-ic { width: 28px; height: 28px; border-radius: 9px; display: grid; place-items: center; background: rgba(109, 60, 246, .10); color: var(--bolso-roxo-vibrante); flex-shrink: 0; }
.lo-opt { font-weight: 500; color: var(--dx-muted); font-size: 12.5px; }
.lo-link { color: var(--bolso-roxo-vibrante); font-weight: 700; }

/* inputs (escopados) */
.lo-modal .f-input, .lo-modal .f-select { height: 48px; border-radius: 14px; border: 1px solid var(--dx-border); font-size: 15px; transition: border-color .18s, box-shadow .18s; }
.lo-modal .f-input:focus, .lo-modal .f-select:focus { border-color: var(--bolso-roxo-vibrante); box-shadow: 0 0 0 4px rgba(109, 60, 246, .12); outline: none; }
.lo-field { position: relative; }
.lo-field .f-input { padding-right: 56px; }
.lo-suffix { position: absolute; right: 8px; top: 50%; transform: translateY(-50%); padding: 6px 11px; border-radius: 10px; background: var(--dx-line); color: var(--dx-muted); font-weight: 800; font-size: 13px; pointer-events: none; }

/* checkbox como card */
.lo-switch { display: flex; align-items: center; gap: 12px; padding: 14px 16px; border: 1px solid var(--dx-border); border-radius: 15px; cursor: pointer; transition: .18s; }
.lo-switch:hover { background: rgba(109, 60, 246, .05); border-color: #E5DEFF; }
.lo-switch.on { background: rgba(109, 60, 246, .10); border-color: #DDD3FF; }
.lo-switch input { position: absolute; opacity: 0; width: 0; height: 0; }
.lo-switch-box { width: 22px; height: 22px; border-radius: 7px; border: 2px solid var(--bolso-chevron, #C7C3DA); flex-shrink: 0; display: grid; place-items: center; transition: .18s; }
.lo-switch input:checked + .lo-switch-box { background: var(--bolso-roxo-vibrante); border-color: var(--bolso-roxo-vibrante); }
.lo-switch input:checked + .lo-switch-box::after { content: ""; width: 6px; height: 11px; border: solid #fff; border-width: 0 2.5px 2.5px 0; transform: rotate(45deg) translate(-1px, -1px); }
.lo-switch-tx { font-size: 14px; font-weight: 700; color: var(--dx-ink); }
.lo-switch-tx em { font-style: normal; font-weight: 500; color: var(--dx-muted); }

/* botões (escopados) */
.lo-modal .mfoot .btn-ghost { height: 48px; border-radius: 14px; background: var(--bolso-card, #fff); border: 1px solid var(--dx-border); color: var(--dx-ink); font-weight: 700; box-shadow: 0 2px 8px rgba(15, 23, 42, .05); transition: .18s; }
.lo-modal .mfoot .btn-ghost:hover { background: var(--dx-line); }
.lo-modal .btn.lo-save { border-radius: 15px; display: inline-flex; align-items: center; justify-content: center; gap: 9px; background: linear-gradient(135deg, #6D28D9, #7C3AED 55%, #9333EA); color: #fff; font-weight: 800; border: none; box-shadow: 0 10px 24px rgba(109, 40, 217, .32); transition: .18s; }
.lo-modal .mfoot .btn.lo-save { height: 48px; }
.lo-modal .btn.lo-save.sm { height: 38px; border-radius: 12px; padding: 0 18px; font-size: 13px; box-shadow: 0 6px 16px rgba(109, 40, 217, .26); }
.lo-modal .btn.lo-save:hover { filter: brightness(1.06); transform: translateY(-1px); box-shadow: 0 14px 28px rgba(109, 40, 217, .4); }
.lo-modal .btn.lo-save:disabled { opacity: .7; transform: none; }

@media (max-width: 560px) {
    .lo-modal .mfoot { flex-direction: column; }
    .lo-modal .mhead, .lo-modal .mbody, .lo-modal .mfoot { padding-left: 20px; padding-right: 20px; }
}

.modal-sm { max-width: 420px; }
.lo-settle-info { display: flex; flex-direction: column; gap: 3px; padding: 12px 14px; background: var(--dx-line); border-radius: 12px; margin-bottom: 6px; font-size: 13px; color: var(--dx-muted); }
.lo-settle-info b { color: var(--dx-ink); font-size: 14.5px; }
.lo-fill { width: 100%; padding: 9px; border-radius: 10px; border: 1px dashed var(--dx-border); background: transparent; color: var(--bolso-roxo-vibrante); font-weight: 700; font-size: 12.5px; cursor: pointer; margin-top: 8px; }
.lo-fill:hover { background: rgba(109, 60, 246, .06); }

.lo-contact-actions { display: flex; justify-content: flex-end; gap: 8px; margin: 4px 0 14px; }
.btn.sm, .btn-ghost.sm { padding: 8px 16px; font-size: 13px; min-width: 0; }
.lo-contact-list { display: flex; flex-direction: column; gap: 8px; max-height: 280px; overflow-y: auto; }
.lo-contact-row { display: flex; align-items: center; gap: 11px; padding: 8px; border: 1px solid var(--dx-border); border-radius: 12px; }
.lo-contact-meta { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.lo-contact-meta .nm { font-weight: 700; font-size: 13.5px; color: var(--dx-ink); }
.lo-contact-meta .ph { font-size: 11.5px; color: var(--dx-muted); }

@media (max-width: 720px) { .lo-kpis { grid-template-columns: 1fr; } .f-grid2 { grid-template-columns: 1fr; } }

/* Perfil do usuário no rodapé */
.sb-user { display: flex; align-items: center; gap: 11px; padding: 14px 4px 4px; border-top: 1px solid rgba(255, 255, 255, .08); }
.sb-av {
    width: 38px; height: 38px; border-radius: 50%; flex-shrink: 0;
    background: linear-gradient(135deg, #8B5CF6, var(--dx-primary));
    color: #fff; display: grid; place-items: center; font-weight: 800; font-size: 14px;
}
.sb-user-meta { min-width: 0; flex: 1; display: flex; flex-direction: column; }
.sb-user-meta .nm { font-weight: 700; font-size: 13.5px; color: #fff; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sb-user-meta .em { font-size: 11.5px; color: #8B95AD; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sb-logout { width: 32px; height: 32px; border-radius: 9px; display: grid; place-items: center; color: #8B95AD; flex-shrink: 0; }
.sb-logout .ico { width: 18px; height: 18px; }
.sb-logout:hover { background: rgba(255, 90, 90, .16); color: #FF8A8A; }

/* ============================================================
   DASHBOARD (.dx-*)
   ============================================================ */
.dx { display: flex; flex-direction: column; gap: 9px; }

/* Header */
.dx-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.dx-title { font-size: 26px; font-weight: 800; letter-spacing: -.6px; color: var(--dx-ink); }
.dx-head-actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.dx-iconbtn {
    width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center;
    background: #fff; border: 1px solid var(--dx-border); color: var(--dx-muted); transition: .15s;
}
.dx-iconbtn:hover { color: var(--dx-primary); border-color: #DDD6FE; }
/* sino de notificações dentro do header (mesmo visual dos botões de ícone) */
.dx-head-actions .nb { display: inline-flex; }
.dx-head-actions .nb-btn { width: 42px; height: 42px; border-radius: 12px; background: #fff; border: 1px solid var(--dx-border); color: var(--dx-muted); transition: .15s; }
.dx-head-actions .nb-btn svg { width: 20px; height: 20px; }
.dx-head-actions .nb-btn:hover, .dx-head-actions .nb-btn.on { color: var(--dx-primary); border-color: #DDD6FE; }
.dx-period {
    display: inline-flex; align-items: center; gap: 8px; height: 42px; padding: 0 14px;
    border-radius: 12px; background: #fff; border: 1px solid var(--dx-border);
    font-weight: 700; font-size: 13.5px; color: var(--dx-ink);
}
.dx-period svg:first-child { color: var(--dx-muted); }
/* Seletor de mês (dropdown nativo <details>, funciona sem circuito) */
.dx-period-wrap { position: relative; }
.dx-period-wrap > summary.dx-period { cursor: pointer; list-style: none; user-select: none; transition: border-color .15s, background .15s; }
.dx-period-wrap > summary.dx-period::-webkit-details-marker { display: none; }
.dx-period-wrap > summary.dx-period:hover { border-color: #DDD6FE; }
.dx-period-wrap[open] > summary.dx-period { border-color: var(--dx-primary); background: var(--bolso-roxo-tint); }
.dx-period-wrap[open] > summary.dx-period svg:last-child { transform: rotate(180deg); }
.dx-period-menu {
    position: absolute; top: calc(100% + 8px); right: 0; z-index: 60;
    min-width: 190px; max-height: 320px; overflow-y: auto;
    background: #fff; border: 1px solid var(--dx-border); border-radius: 14px;
    box-shadow: 0 18px 44px rgba(15, 23, 42, .16); padding: 6px;
    display: flex; flex-direction: column; gap: 2px; animation: dxPeriodIn .14s ease;
}
@keyframes dxPeriodIn { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }
.dx-period-opt { padding: 9px 12px; border-radius: 9px; font-size: 13.5px; font-weight: 600; color: var(--dx-ink); white-space: nowrap; transition: background .12s, color .12s; }
.dx-period-opt:hover { background: var(--bolso-roxo-tint); color: var(--bolso-roxo-vibrante); }
.dx-period-opt.on { background: var(--bolso-roxo-tint); color: var(--bolso-roxo-vibrante); font-weight: 800; }

/* ── Modo privacidade: desfoca os valores monetários do dashboard quando data-hide="on" ── */
/* Esconde o número real (transparente, mantém o espaço) e sobrepõe "R$ ••••" em tom neutro. */
[data-hide="on"] .dx-kpi-val,
[data-hide="on"] .dx-sum-v,
[data-hide="on"] .dx-dist-vl,
[data-hide="on"] .dx-tx-amt,
[data-hide="on"] .dx-goal-meta .vl,
[data-hide="on"] .dx-acc-bal,
[data-hide="on"] .cal-tip-l b {
    color: transparent !important;
    position: relative;
    user-select: none;
}
[data-hide="on"] .dx-kpi-val::after,
[data-hide="on"] .dx-sum-v::after,
[data-hide="on"] .dx-dist-vl::after,
[data-hide="on"] .dx-tx-amt::after,
[data-hide="on"] .dx-goal-meta .vl::after,
[data-hide="on"] .dx-acc-bal::after,
[data-hide="on"] .cal-tip-l b::after {
    content: "R$ ••••";
    position: absolute;
    left: 0; right: 0; top: 0; bottom: 0;
    display: flex;
    align-items: center;
    justify-content: flex-end;     /* listas: valor à direita */
    color: var(--dx-muted);
    letter-spacing: 1px;
    pointer-events: none;
}
/* KPIs e metas são alinhados à esquerda */
[data-hide="on"] .dx-kpi-val::after,
[data-hide="on"] .dx-goal-meta .vl::after { justify-content: flex-start; }
/* Card roxo "Saldo atual": pontos em tom claro pra contrastar com o gradiente */
[data-hide="on"] .dx-kpi.feat .dx-kpi-val::after { color: #C9C2F5; }
/* MoodCard (premium, fundo colorido): leve desfoque em vez de pontos */
[data-hide="on"] .mood-amt,
[data-hide="on"] .mood-sub {
    filter: blur(5px);
    -webkit-filter: blur(5px);
    opacity: .5;
    user-select: none;
    pointer-events: none;
}

/* Olho no card "Saldo atual": alterna entre olho (mostrando) e olho-cortado (oculto) */
.dx-eye { display: inline-flex; align-items: center; justify-content: center; width: 24px; height: 22px; border-radius: 7px; color: inherit; opacity: .85; vertical-align: middle; transition: opacity .15s, background .15s; }
.dx-eye:hover { opacity: 1; background: rgba(255, 255, 255, .18); }
.dx-eye .dx-eye-on { display: inline-flex; }
.dx-eye .dx-eye-off { display: none; }
[data-hide="on"] .dx-eye .dx-eye-on { display: none; }
[data-hide="on"] .dx-eye .dx-eye-off { display: inline-flex; }
.dx-admin-btn {
    display: inline-flex; align-items: center; gap: 7px; height: 42px; padding: 0 15px;
    border-radius: 12px; font-weight: 800; font-size: 13.5px;
    background: linear-gradient(135deg, #312E81, #6D28D9); color: #fff;
    box-shadow: 0 8px 18px rgba(76, 29, 149, .28); transition: filter .15s, transform .15s;
}
.dx-admin-btn:hover { filter: brightness(1.08); transform: translateY(-1px); }
.dx-admin-btn svg { color: #fff; }

.dx-cta {
    display: inline-flex; align-items: center; gap: 8px; height: 48px; padding: 0 20px;
    border-radius: 14px; background: var(--dx-primary); color: #fff; font-weight: 700; font-size: 14.5px;
    box-shadow: 0 8px 18px rgba(109, 40, 217, .25); transition: background .15s, transform .15s;
}
.dx-cta:hover { background: var(--dx-primary-dark); transform: translateY(-1px); }

/* Greeting */
.dx-greet { margin-top: -7px; }
.dx-hi { font-size: 22px; font-weight: 800; letter-spacing: -1px; color: var(--dx-ink); margin: 0 0 1px; }
.dx-wave { display: inline-block; transform-origin: 70% 70%; animation: wave 2.4s ease-in-out 1; }
.dx-cap { color: var(--dx-muted); font-size: 14px; margin: 0; }

/* KPI cards */
.dx-kpis { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1fr; gap: 20px; }
.dx-kpi {
    position: relative; overflow: hidden;
    background: #fff; border: 1px solid var(--dx-border); border-radius: var(--dx-r);
    box-shadow: var(--dx-shadow); padding: 11px 18px;
    transition: transform .2s, box-shadow .2s;
}
.dx-kpi:hover { transform: translateY(-3px); box-shadow: var(--dx-shadow-h); }
.dx-spark { position: absolute; right: 22px; top: 26px; width: clamp(90px, 38%, 150px); height: 54px; opacity: .92; }
.dx-spark svg { width: 100%; height: 100%; display: block; }
.dx-kpi-top { display: flex; align-items: center; gap: 11px; }
.dx-kpi-ic { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; flex-shrink: 0; }
.dx-kpi-label { color: var(--dx-muted); font-size: 13.5px; font-weight: 600; display: inline-flex; align-items: center; gap: 6px; }
.dx-kpi-label svg { color: var(--bolso-chevron); }
.dx-kpi-val { font-size: 23px; font-weight: 800; letter-spacing: -.7px; margin: 3px 0 0; white-space: nowrap; color: var(--dx-ink); }
.dx-delta { display: inline-flex; align-items: center; gap: 4px; font-size: 12.5px; font-weight: 700; margin-top: 5px; }
.dx-delta.good { color: #16A34A; }
.dx-delta.bad { color: var(--dx-danger); }
.dx-delta.flat { color: var(--bolso-placeholder); }

/* Card de destaque: Saldo atual (gradiente roxo premium) */
.dx-kpi.feat { background: linear-gradient(135deg, #312E81 0%, #6D28D9 100%); border: none; padding: 14px 20px; box-shadow: 0 14px 34px rgba(76, 29, 149, .32); }
.dx-kpi.feat:hover { box-shadow: 0 20px 44px rgba(76, 29, 149, .4); }
.dx-kpi.feat .dx-kpi-label { color: #C9C2F5; font-weight: 600; }
.dx-kpi.feat .dx-kpi-label svg { color: #C9C2F5; }
.dx-kpi.feat .dx-kpi-val { color: #fff; font-size: 26px; margin-top: 5px; }
.dx-kpi.feat .dx-delta { margin-top: 10px; padding: 4px 11px; border-radius: 999px; background: rgba(34, 197, 94, .2); color: #6EE7A8; }
.dx-kpi.feat .dx-delta.flat { background: rgba(255, 255, 255, .12); color: #C9C2F5; }
.dx-kpi.feat .dx-spark { top: auto; bottom: 14px; right: 16px; width: 46%; height: 62px; opacity: 1; }
.dx-kpi-badge { position: absolute; top: 18px; right: 18px; width: 42px; height: 42px; border-radius: 13px; background: rgba(255, 255, 255, .15); color: #fff; display: grid; place-items: center; z-index: 1; }

/* Rows (3 colunas como a referência) — alturas iguais por linha (encaixe) */
.dx-row { display: grid; grid-template-columns: 1.55fr 1.25fr 1fr; gap: 24px; align-items: stretch; }
.dx-col { display: flex; flex-direction: column; gap: 11px; }

.dx-card {
    display: flex; flex-direction: column;
    background: #fff; border: 1px solid var(--dx-border); border-radius: var(--dx-r);
    box-shadow: var(--dx-shadow); padding: 13px 18px;
}
.dx-card-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 6px; }
.dx-card-title { font-size: 16px; font-weight: 800; letter-spacing: -.3px; color: var(--dx-ink); }
.dx-link { font-size: 13px; font-weight: 700; color: var(--dx-primary); }
.dx-link:hover { color: var(--dx-primary-dark); }
.dx-tag { display: inline-flex; align-items: center; gap: 5px; font-size: 12.5px; font-weight: 700; color: var(--dx-muted);
    padding: 6px 11px; border-radius: 9px; background: #F8FAFC; border: 1px solid var(--dx-border); }
.dx-more { color: var(--bolso-chevron); display: grid; place-items: center; }

/* Fluxo de caixa (barras) */
.dx-legend { display: flex; gap: 18px; margin-bottom: 14px; }
.dx-legend .li { display: flex; align-items: center; gap: 7px; font-size: 12.5px; color: var(--dx-muted); font-weight: 600; }
.dx-legend .sw { width: 11px; height: 11px; border-radius: 3px; }
.dx-bars { display: flex; gap: 12px; margin-top: 6px; }
.dx-bars-y { display: flex; flex-direction: column; justify-content: space-between; height: 160px; min-width: 46px; text-align: right; }
.dx-bars-y span { font-size: 11px; color: var(--bolso-placeholder); font-weight: 600; line-height: 1; }
.dx-bars-main { flex: 1; min-width: 0; }
/* Gráfico de área (linhas suaves com preenchimento) */
.dx-area { position: relative; height: 160px; width: 100%;
    background-image: repeating-linear-gradient(to top, var(--dx-line) 0 1px, transparent 1px 25%); }
.dx-area svg { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.dx-tip { position: absolute; top: 6px; left: 53%; min-width: 152px; pointer-events: none;
    background: var(--bolso-card, #fff); border: 1px solid var(--dx-border); border-radius: 12px;
    box-shadow: 0 10px 26px rgba(15, 23, 42, .14); padding: 10px 13px; display: flex; flex-direction: column; gap: 5px; }
.dx-tip-h { font-size: 12px; font-weight: 800; color: var(--dx-ink); }
.dx-tip-l { display: flex; align-items: center; gap: 7px; font-size: 11.5px; color: var(--dx-muted); font-weight: 600; }
.dx-tip-l i { width: 8px; height: 8px; border-radius: 3px; flex-shrink: 0; }
.dx-tip-l b { margin-left: auto; color: var(--dx-ink); font-weight: 800; padding-left: 10px; }
.dx-bars-x { display: flex; justify-content: space-between; gap: 10px; margin-top: 10px; }
.dx-bars-x span { flex: 1; text-align: center; font-size: 11.5px; color: var(--dx-muted); font-weight: 600; }

/* ===== Calendário financeiro (substitui o fluxo de caixa) ===== */
.cal-card { min-height: 320px; }
.cal-nav { display: flex; align-items: center; gap: 6px; }
.cal-navbtn { display: inline-flex; align-items: center; justify-content: center; width: 28px; height: 28px;
    border-radius: 9px; border: 1px solid var(--dx-border); background: transparent; color: var(--dx-muted); cursor: pointer; transition: .15s; }
.cal-navbtn:hover { color: var(--bolso-roxo-vibrante); border-color: var(--bolso-roxo-vibrante); }
.cal-month { font-size: 13.5px; font-weight: 800; color: var(--dx-ink); min-width: 108px; text-align: center; }
.cal-legend { margin-top: 8px; margin-bottom: 0; }
.cal-ring { display: inline-block; width: 10px; height: 10px; border-radius: 50%; border: 2px solid var(--dx-muted); background: transparent; }

.cal-dow { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; margin-top: 9px; }
.cal-dow span { text-align: center; font-size: 10.5px; font-weight: 700; color: var(--dx-muted); text-transform: uppercase; letter-spacing: .03em; }

.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 5px; margin-top: 5px; }
.cal-cell { position: relative; min-height: 37px; border-radius: 10px; border: 1px solid var(--dx-border);
    padding-top: 5px; display: flex; flex-direction: column; align-items: center; gap: 3px; }
.cal-cell.void { visibility: hidden; }
.cal-cell.has { background: var(--dx-line); }
.cal-cell.today { background: rgba(109, 60, 246, .12); border-color: rgba(109, 60, 246, .35); }
.cal-cell.today .cal-num { color: var(--bolso-roxo-vibrante); font-weight: 800; }
.cal-num { font-size: 12.5px; font-weight: 600; color: var(--dx-ink); line-height: 1; }
.cal-dots { display: flex; gap: 4px; min-height: 7px; }
.cal-dot { width: 7px; height: 7px; border-radius: 50%; }
.cal-dot.inc { background: #22C55E; color: #22C55E; }
.cal-dot.exp { background: #EF4444; color: #EF4444; }
.cal-dot.proj { background: transparent; box-shadow: inset 0 0 0 1.6px currentColor; }
.cal-sk { min-height: 46px; border-radius: 11px; }

.cal-tip { position: absolute; bottom: calc(100% + 9px); left: 50%; transform: translateX(-50%) translateY(4px);
    width: 222px; background: var(--bolso-card, #fff); border: 1px solid var(--dx-border); border-radius: 12px;
    box-shadow: 0 14px 34px rgba(2, 6, 23, .16); padding: 10px 12px; display: flex; flex-direction: column; gap: 7px;
    opacity: 0; pointer-events: none; transition: opacity .15s, transform .15s; z-index: 30; }
.cal-cell.has:hover .cal-tip { opacity: 1; transform: translateX(-50%) translateY(0); }
.cal-tip-h { font-size: 11.5px; font-weight: 800; color: var(--dx-ink); text-transform: capitalize; }
.cal-tip-l { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--dx-muted); }
.cal-tip-l i { width: 8px; height: 8px; border-radius: 50%; flex: 0 0 auto; }
.cal-tip-l .t { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cal-tip-l b { font-weight: 800; font-size: 11.5px; }

/* Distribuição de despesas — barras horizontais */
.dx-dist { flex: 1; display: flex; flex-direction: column; gap: 17px; justify-content: center; padding: 6px 0; }
.dx-dist-row { display: grid; grid-template-columns: 34px minmax(64px, max-content) 1fr auto 92px; align-items: center; gap: 13px; }
.dx-dist-ic { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; flex-shrink: 0; }
.dx-dist-nm { font-size: 13.5px; font-weight: 600; color: var(--dx-ink); white-space: nowrap; }
.dx-dist-bar { height: 8px; border-radius: 999px; background: #EEF1F6; overflow: hidden; }
.dx-dist-bar i { display: block; height: 100%; border-radius: 999px; transition: width .45s ease; }
.dx-dist-pc { font-size: 13px; font-weight: 800; color: var(--dx-muted); text-align: right; }
.dx-dist-vl { font-size: 13px; font-weight: 700; color: var(--dx-ink); white-space: nowrap; text-align: right; }

/* Resumo do mês */
.dx-sum { display: flex; flex-direction: column; }
.dx-sum-row { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--dx-line); }
.dx-sum-row:first-child { padding-top: 2px; }
.dx-sum-ic { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; flex-shrink: 0; }
.dx-sum-k { flex: 1; color: var(--dx-muted); font-size: 14px; font-weight: 600; }
.dx-sum-v { font-weight: 800; font-size: 15px; color: var(--dx-ink); white-space: nowrap; }
.dx-sum-row:last-child { border-bottom: none; }
/* Saldo total: mesma linha das demais (ícone + label + valor); só com divisor em cima e fixado embaixo. */
.dx-sum-total { display: flex; align-items: center; gap: 12px; margin-top: auto;
    padding: 10px 0 2px; border-top: 1px solid var(--dx-line); }

/* Transações recentes */
.dx-tx { display: flex; flex-direction: column; }
.dx-tx-row { display: flex; align-items: center; gap: 13px; padding: 6px 0; border-bottom: 1px solid var(--dx-line); }
.dx-tx-row:last-child { border-bottom: none; padding-bottom: 0; }
.dx-tx-ic { width: 36px; height: 36px; border-radius: 11px; display: grid; place-items: center; flex-shrink: 0; }
.dx-tx-meta { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.dx-tx-meta .t { font-weight: 700; font-size: 14px; color: var(--dx-ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dx-tx-meta .s { font-size: 12px; color: var(--dx-muted); }
.dx-tx-day { font-size: 12px; color: var(--bolso-placeholder); font-weight: 600; white-space: nowrap; }
.dx-tx-amt { font-weight: 800; font-size: 14px; white-space: nowrap; min-width: 84px; text-align: right; }

/* Metas */
.dx-goals { flex: 1; display: flex; flex-direction: column; gap: 9px; justify-content: space-between; }
.dx-tx, .dx-accs { flex: 1; }
.dx-goal-top { display: flex; align-items: center; gap: 12px; margin-bottom: 7px; }
.dx-goal-ic { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; flex-shrink: 0; }
.dx-goal-meta { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.dx-goal-meta .nm { font-weight: 700; font-size: 14px; color: var(--dx-ink); }
.dx-goal-meta .vl { font-size: 12px; color: var(--dx-muted); }
.dx-goal-pct { font-weight: 800; font-size: 13.5px; color: var(--dx-primary); }
.dx-bar-track { height: 8px; border-radius: 999px; background: #EEF0F5; overflow: hidden; }
.dx-bar-track > span { display: block; height: 100%; border-radius: 999px;
    background: linear-gradient(90deg, var(--dx-primary), #4F46E5); transition: width .35s; }
.dx-bar-track > span.ok { background: linear-gradient(90deg, #22C55E, #16A34A); }

/* Contas */
.dx-accs { display: flex; flex-direction: column; }
.dx-acc { display: flex; align-items: center; gap: 12px; padding: 6px 0; border-bottom: 1px solid var(--dx-line); }
.dx-acc:last-child { border-bottom: none; padding-bottom: 0; }
.dx-acc-ic { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; flex-shrink: 0; }
.dx-acc-meta { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.dx-acc-meta .nm { font-weight: 700; font-size: 14px; color: var(--dx-ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dx-acc-meta .ty { font-size: 12px; color: var(--dx-muted); }
.dx-acc-bal { font-weight: 800; font-size: 14px; color: var(--dx-ink); white-space: nowrap; }

/* Card motivacional */
.dx-motiv {
    display: flex; align-items: center; justify-content: space-between; gap: 12px;
    background: linear-gradient(135deg, #F5F3FF, #EDE9FE); border: 1px solid #E9E3FF;
    border-radius: var(--dx-r); padding: 10px 16px;
}
.dx-motiv-txt { display: flex; flex-direction: column; gap: 2px; }
.dx-motiv-txt b { font-size: 14px; color: var(--dx-primary-dark); }
.dx-motiv-txt span { font-size: 12px; color: #6D5BA8; line-height: 1.35; }
.dx-motiv-ic { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; flex-shrink: 0;
    background: #fff; color: var(--dx-primary); box-shadow: var(--dx-shadow); }

/* Skeletons */
.dx-sk-kpi { height: 138px; border-radius: var(--dx-r); }
.dx-sk-panel { height: 300px; border-radius: var(--dx-r); }

/* ============================================================
   RESPONSIVO (desktop 1440 · tablet 1024 · mobile empilhado)
   ============================================================ */
@media (max-width: 1320px) {
    .dx-kpis { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 1180px) {
    .dx-row { grid-template-columns: 1fr 1fr; }
    .dx-row > .dx-card:first-child { grid-column: 1 / -1; }
}
@media (max-width: 820px) {
    .dx-row { grid-template-columns: 1fr; }
    .dx-row > .dx-card:first-child { grid-column: auto; }
}
@media (max-width: 600px) {
    .dx-kpis { grid-template-columns: 1fr; }
}
/* Barra de erro do Blazor: oculta por padrão; o runtime a exibe (inline) só em erro real. */
#blazor-error-ui {
    display: none;
    position: fixed; left: 0; bottom: 0; width: 100%; z-index: 1000;
    padding: 12px 20px; background: #FEF3C7; color: #7C5E10;
    box-shadow: 0 -2px 14px rgba(15, 23, 42, .12); font-size: 14px; font-weight: 600;
}
#blazor-error-ui .reload { color: var(--dx-primary, #6D28D9); font-weight: 700; margin-left: 6px; }
#blazor-error-ui .dismiss { cursor: pointer; position: absolute; right: 16px; top: 11px; color: #7C5E10; }

/* ============================================================
   LOGIN PREMIUM (.lg-*) — split screen estilo Stripe/Mercury/Arc
   Esquerda escura imersiva · direita card branco · microinterações
   ============================================================ */
.lg-stage { display: grid; grid-template-columns: 55% 45%; min-height: 100vh; }

/* ---------- ESQUERDA ---------- */
.lg-left {
    position: relative; overflow: hidden;
    background: linear-gradient(135deg, #0F044C 0%, #170A68 40%, #090035 100%);
    display: flex; align-items: center;
    padding: 64px clamp(48px, 6vw, 110px);
}
.lg-fx { position: absolute; inset: 0; pointer-events: none; }
.lg-glow { position: absolute; border-radius: 50%; filter: blur(90px); opacity: .55; }
.lg-glow.g1 { width: 460px; height: 460px; top: -120px; left: -120px; background: #7C3AED; }
.lg-glow.g2 { width: 520px; height: 520px; bottom: -180px; left: 8%; background: #2563EB; opacity: .42; }
.lg-glow.g3 { width: 360px; height: 360px; top: 26%; right: -120px; background: #C026D3; opacity: .38; }
.lg-waves { position: absolute; inset: 0; width: 100%; height: 100%; }
.lg-grid {
    position: absolute; top: 60px; right: 64px; width: 110px; height: 92px;
    background-image: radial-gradient(rgba(255,255,255,.18) 1.4px, transparent 1.4px);
    background-size: 18px 18px; opacity: .6;
}
.lg-dot { position: absolute; width: 5px; height: 5px; border-radius: 50%; background: rgba(255,255,255,.5); box-shadow: 0 0 10px rgba(167,139,250,.9); animation: lgFloat 7s ease-in-out infinite; }
.lg-dot.d1 { top: 18%; left: 22%; } .lg-dot.d2 { top: 64%; left: 14%; animation-delay: 1s; }
.lg-dot.d3 { top: 38%; left: 48%; animation-delay: 2s; } .lg-dot.d4 { top: 80%; left: 40%; animation-delay: 1.6s; }
.lg-dot.d5 { top: 12%; left: 60%; animation-delay: .6s; } .lg-dot.d6 { top: 72%; left: 64%; animation-delay: 2.4s; }

.lg-tile {
    position: absolute; width: 64px; height: 64px; border-radius: 18px; display: grid; place-items: center;
    background: rgba(255,255,255,.05); border: 1px solid rgba(255,255,255,.10); color: rgba(255,255,255,.55);
    backdrop-filter: blur(8px); animation: lgFloat 8s ease-in-out infinite;
}
.lg-tile.tile-a { top: 8%; left: 5%; }
.lg-tile.tile-b { top: 50%; right: 6%; width: 70px; height: 70px; animation-delay: 1.2s; }

/* Widgets flutuantes (vidro) */
.lg-widget {
    position: absolute; z-index: 2; border-radius: 18px; padding: 16px 18px;
    background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.12);
    backdrop-filter: blur(20px); box-shadow: 0 20px 50px rgba(5,2,30,.35); color: #fff; width: 210px;
}
.lg-widget .wk { font-size: 12px; color: rgba(255,255,255,.65); font-weight: 600; }
.lg-widget .wv { font-size: 24px; font-weight: 800; letter-spacing: -.5px; margin-top: 3px; }
.lg-widget .wd { font-size: 12px; color: rgba(255,255,255,.65); margin-top: 2px; }
.lg-widget .wd .up { color: #5BE584; font-weight: 700; }
.w-spark { width: 100%; height: 34px; margin-top: 8px; display: block; }
.w-balance { top: 12%; right: 7%; }
.w-goal { bottom: 12%; right: 7%; }
.w-goal .wg-vals { font-size: 13px; margin-top: 4px; } .w-goal .wg-vals b { font-weight: 800; }
.wg-track { height: 7px; border-radius: 999px; background: rgba(255,255,255,.15); overflow: hidden; margin: 9px 0 6px; }
.wg-track > span { display: block; height: 100%; border-radius: 999px; background: linear-gradient(90deg, #A78BFA, #6D28D9); }
.w-goal .wg-pct { font-size: 12px; font-weight: 800; color: #C4B5FD; text-align: right; }
.float-a { animation: lgFloat 6.5s ease-in-out infinite; }
.float-b { animation: lgFloat 7.5s ease-in-out infinite reverse; }

.lg-left-inner { position: relative; z-index: 3; max-width: 600px; }
.lg-logo { margin-bottom: 38px; }
.lg-logo img { width: 420px; max-width: 70%; height: auto; display: block; filter: drop-shadow(0 20px 60px rgba(0,0,0,.35)); }
.lg-logo-fb { display: none; align-items: center; font-size: 56px; font-weight: 900; letter-spacing: -1.5px; color: #fff; }
.lg-logo-fb span { color: #F59E0B; }
.lg-headline { font-size: clamp(40px, 5vw, 72px); font-weight: 900; line-height: .95; letter-spacing: -2px; color: #fff; margin: 0 0 22px; }
.lg-sub { font-size: clamp(17px, 1.4vw, 22px); color: rgba(255,255,255,.75); line-height: 1.6; max-width: 560px; margin: 0 0 34px; }

.lg-benefits { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; max-width: 440px; }
.lg-benefit {
    display: flex; align-items: center; gap: 13px; padding: 13px 18px; border-radius: 16px;
    background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.08); backdrop-filter: blur(20px);
    color: rgba(255,255,255,.92); font-size: 15px; font-weight: 600; transition: background .2s, transform .2s;
}
.lg-benefit:hover { background: rgba(255,255,255,.1); transform: translateX(4px); }
.lg-benefit .ck { width: 26px; height: 26px; border-radius: 50%; flex-shrink: 0; display: grid; place-items: center;
    background: linear-gradient(135deg, #8B5CF6, #6D28D9); color: #fff; box-shadow: 0 6px 14px rgba(124,58,237,.4); }

/* ---------- DIREITA ---------- */
.lg-right { background: #F8FAFC; display: flex; padding: 40px; overflow-y: auto; }
.lg-card {
    width: 100%; max-width: 560px; margin: auto; background: #fff; border: 1px solid #EAECEF; border-radius: 32px;
    padding: clamp(30px, 4vw, 56px); box-shadow: 0 30px 100px rgba(15,23,42,.08);
    animation: lgRise .5s cubic-bezier(.2,.7,.2,1) both;
}
.lg-title { font-size: clamp(34px, 4vw, 56px); font-weight: 800; letter-spacing: -1.5px; color: #0F172A; text-align: center; line-height: 1; }
.lg-welcome { font-size: clamp(16px, 1.4vw, 22px); color: #64748B; text-align: center; margin: 12px 0 30px; }
.lg-error { background: #FEE2E2; color: #B91C1C; padding: 12px 15px; border-radius: 14px; font-size: 13.5px; font-weight: 600; margin-bottom: 18px; }

.lg-label { display: block; font-size: 14px; font-weight: 700; color: #0F172A; margin: 0 0 8px; }
.lg-input { position: relative; display: flex; align-items: center; margin-bottom: 18px; }
.lg-input .ic { position: absolute; left: 18px; color: #94A3B8; display: grid; place-items: center; pointer-events: none; }
.lg-input input {
    width: 100%; height: 64px; padding: 0 18px 0 50px; border: 1px solid #E2E8F0; border-radius: 18px;
    background: #fff; font-size: 16px; font-family: inherit; color: #0F172A; transition: border-color .15s, box-shadow .15s;
}
.lg-input input::placeholder { color: #94A3B8; }
.lg-input input:focus { outline: none; border-color: #7C3AED; box-shadow: 0 0 0 4px rgba(124,58,237,.15); }
.lg-eye { position: absolute; right: 16px; width: 34px; height: 34px; border-radius: 9px; display: grid; place-items: center; color: #94A3B8; }
.lg-eye:hover { color: #6D28D9; background: #F5F3FF; }

.lg-aux { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 4px 0 24px; }
.lg-check { display: inline-flex; align-items: center; gap: 9px; font-size: 14px; color: #475569; font-weight: 600; cursor: pointer; user-select: none; }
.lg-check input { width: 18px; height: 18px; accent-color: #6D28D9; cursor: pointer; }
.lg-forgot { font-size: 14px; font-weight: 700; color: #6D28D9; }
.lg-forgot:hover { color: #5B21B6; }

.lg-btn {
    width: 100%; height: 64px; border-radius: 18px; color: #fff; font-size: 16px; font-weight: 800;
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    background: linear-gradient(90deg, #7C3AED, #6D28D9); box-shadow: 0 15px 40px rgba(109,40,217,.35);
    transition: transform .15s, box-shadow .2s, filter .15s;
}
.lg-btn:hover { transform: translateY(-2px); box-shadow: 0 20px 48px rgba(109,40,217,.42); filter: brightness(1.04); }
.lg-btn:active { transform: translateY(0); }

.lg-or { display: flex; align-items: center; gap: 14px; margin: 24px 0; color: #94A3B8; font-size: 13px; font-weight: 600; }
.lg-or::before, .lg-or::after { content: ""; flex: 1; height: 1px; background: #E2E8F0; }

.lg-social { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.lg-social.solo { grid-template-columns: 1fr; } /* um único botão (o provedor do S.O.) ocupa a largura toda */
.lg-soc {
    height: 58px; border-radius: 18px; background: #fff; border: 1px solid #E2E8F0;
    display: inline-flex; align-items: center; justify-content: center; gap: 10px;
    font-size: 15px; font-weight: 700; color: #0F172A; text-decoration: none;
    transition: border-color .15s, background .15s, transform .15s;
}
.lg-soc:hover { border-color: #CBD5E1; background: #F8FAFC; transform: translateY(-1px); }
/* Apple (HIG): botão preto com texto branco. */
.lg-soc-apple { background: #000; border-color: #000; color: #fff; }
.lg-soc-apple:hover { background: #1a1a1a; border-color: #1a1a1a; }
[data-theme="dark"] .lg-soc-apple { background: #fff; border-color: #fff; color: #000; }
[data-theme="dark"] .lg-soc-apple:hover { background: #f2f2f2; border-color: #f2f2f2; }

.lg-foot { text-align: center; margin: 26px 0 0; color: #64748B; font-size: 14.5px; }
.lg-foot a { color: #6D28D9; font-weight: 700; }
.lg-foot a:hover { color: #5B21B6; }
.lg-soon { text-align: center; margin: 14px 0 0; font-size: 13px; font-weight: 600; color: #6D28D9; }

/* ============================================================
   CADASTRO (.cd-*) — reaproveita o split-screen do login
   ============================================================ */
.cd-feats { display: flex; flex-direction: column; gap: 13px; max-width: 470px; }
.cd-feat {
    display: flex; align-items: flex-start; gap: 14px; padding: 15px 18px; border-radius: 18px;
    background: rgba(255,255,255,.05); border: 1px solid rgba(255,255,255,.08); backdrop-filter: blur(20px);
    transition: background .2s, transform .2s;
}
.cd-feat:hover { background: rgba(255,255,255,.09); transform: translateX(4px); }
.cd-feat-ic {
    width: 44px; height: 44px; border-radius: 13px; flex-shrink: 0; display: grid; place-items: center;
    background: linear-gradient(135deg, rgba(139,92,246,.35), rgba(109,40,217,.55)); color: #C4B5FD;
    border: 1px solid rgba(255,255,255,.1);
}
.cd-feat-t { font-size: 15px; font-weight: 700; color: #fff; }
.cd-feat-d { font-size: 13px; color: rgba(255,255,255,.62); line-height: 1.45; margin-top: 2px; }

/* Widget donut (cadastro) */
.w-donut { top: 44%; right: 7%; }
.w-donut-row { display: flex; align-items: center; gap: 12px; margin-top: 8px; }
.w-donut-ring {
    width: 62px; height: 62px; border-radius: 50%; flex-shrink: 0;
    background: conic-gradient(#22C55E 0 40%, #FF6171 40% 72%, #A78BFA 72% 100%);
    -webkit-mask: radial-gradient(circle, transparent 54%, #000 55%);
            mask: radial-gradient(circle, transparent 54%, #000 55%);
}
.w-donut-leg { display: flex; flex-direction: column; gap: 5px; font-size: 11.5px; color: rgba(255,255,255,.78); }
.w-donut-leg span { display: flex; align-items: center; gap: 6px; }
.w-donut-leg i { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }

/* Força da senha + termos */
.cd-strength { display: flex; align-items: center; gap: 10px; margin: -8px 0 16px; }
.cd-str-track { flex: 1; height: 5px; border-radius: 999px; background: #E2E8F0; overflow: hidden; }
.cd-str-track > span { display: block; width: 0; height: 100%; border-radius: 999px; transition: width .25s, background .25s; }
.cd-str-text { font-size: 12.5px; color: #64748B; font-weight: 600; white-space: nowrap; }
.lg-terms { display: flex; align-items: flex-start; gap: 10px; margin: 0 0 22px; font-size: 13.5px; color: #475569; cursor: pointer; line-height: 1.4; }
.lg-terms input { width: 18px; height: 18px; margin-top: 1px; accent-color: #6D28D9; flex-shrink: 0; cursor: pointer; }
.lg-terms a { color: #6D28D9; font-weight: 700; }

/* ============================================================
   PÁGINAS SOLO (esqueci / redefinir senha) + banner de sucesso
   ============================================================ */
.lg-solo { min-height: 100vh; background: #F8FAFC; display: flex; align-items: center; justify-content: center; padding: 40px; overflow-y: auto; }
.lg-card-sm { max-width: 440px; text-align: center; }
.lg-card-sm .lg-title.sm { font-size: clamp(26px, 3vw, 36px); letter-spacing: -1px; }
.lg-card-sm .lg-welcome { margin: 12px 0 24px; }
.lg-card-sm form, .lg-card-sm .lg-label, .lg-card-sm .lg-error, .lg-card-sm .lg-devlink { text-align: left; }
.lg-solo-ic { width: 60px; height: 60px; border-radius: 18px; display: inline-grid; place-items: center; margin: 0 auto 18px; background: #F5F3FF; color: #6D28D9; }
.lg-devlink { background: #FEF9C3; border: 1px solid #FDE68A; border-radius: 14px; padding: 14px 16px; font-size: 13px; color: #854D0E; line-height: 1.5; margin-bottom: 6px; }
.lg-devlink a { display: inline-block; margin-top: 8px; color: #6D28D9; font-weight: 700; }
.lg-ok { background: #DCFCE7; color: #166534; padding: 12px 15px; border-radius: 14px; font-size: 13.5px; font-weight: 600; margin-bottom: 18px; }

/* Cadastro proporcional ao login: headline menor + card/campos compactos (cabe sem scroll feio). */
.cd-stage .lg-headline { font-size: clamp(30px, 3.3vw, 50px); letter-spacing: -1.5px; }
.cd-stage .lg-sub { font-size: clamp(15px, 1.2vw, 18px); margin-bottom: 24px; }
.cd-stage .cd-feats { gap: 10px; }
.cd-stage .cd-feat { padding: 12px 16px; }
.cd-stage .lg-card { padding: clamp(26px, 2.6vw, 42px); }
.cd-stage .lg-title { font-size: clamp(28px, 3vw, 44px); }
.cd-stage .lg-welcome { margin: 8px 0 18px; }
.cd-stage .lg-input { margin-bottom: 13px; }
.cd-stage .lg-label { margin-bottom: 6px; }
.cd-stage .lg-or { margin: 18px 0; }
.cd-stage .lg-foot { margin-top: 18px; }

/* ============================================================
   MOVIMENTAÇÕES (.tx2-*) — tabela premium estilo SaaS
   ============================================================ */
.tx2 { display: flex; flex-direction: column; gap: 22px; }

.tx2-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.tx2-title { font-size: 30px; font-weight: 800; letter-spacing: -.6px; color: var(--dx-ink); }
.tx2-sub { color: var(--dx-muted); font-size: 15px; margin-top: 4px; }
.tx2-actions { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }

.tx2-seg { display: inline-flex; background: #F1F5F9; border: 1px solid var(--dx-border); border-radius: 999px; padding: 4px; }
.tx2-seg a { padding: 8px 18px; border-radius: 999px; font-weight: 600; font-size: 14px; color: var(--dx-muted); transition: .15s; }
.tx2-seg a.on { background: #fff; color: var(--dx-primary); box-shadow: 0 6px 18px rgba(15, 23, 42, .08); font-weight: 700; }

.tx2-month { display: inline-flex; align-items: center; gap: 3px; height: 46px; padding: 0 6px; background: #fff; border: 1px solid var(--dx-border); border-radius: 999px; }
.tx2-mbtn { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; color: var(--dx-muted); transition: .15s; }
.tx2-mbtn:hover { background: #F1F5F9; color: var(--dx-primary); }
.tx2-mcur { display: inline-flex; align-items: center; gap: 7px; font-weight: 700; font-size: 14px; padding: 0 8px; color: var(--dx-ink); white-space: nowrap; }
.tx2-mcur svg { color: var(--dx-muted); }

.tx2-new { display: inline-flex; align-items: center; gap: 8px; height: 46px; padding: 0 20px; border-radius: 14px;
    background: var(--dx-primary); color: #fff; font-weight: 700; font-size: 14.5px;
    box-shadow: 0 12px 24px rgba(124, 58, 237, .28); transition: transform .15s, background .15s; }
.tx2-new:hover { background: var(--dx-primary-dark); transform: translateY(-2px); }

/* Cards de resumo */
.tx2-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 290px)); gap: 20px; }
.tx2-card { display: flex; align-items: center; gap: 14px; background: #fff; border: 1px solid var(--dx-border);
    border-radius: 20px; padding: 18px 20px; box-shadow: var(--dx-shadow);
    transition: transform .2s, box-shadow .2s; animation: fadeUp .45s var(--ease) both; }
.tx2-card:hover { transform: translateY(-3px); box-shadow: var(--dx-shadow-h); }
.tx2-card-ic { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; flex-shrink: 0; }
.tx2-card-body { min-width: 0; }
.tx2-card-k { font-size: 13.5px; color: var(--dx-muted); font-weight: 600; }
.tx2-card-v { font-size: 22px; font-weight: 800; letter-spacing: -.4px; margin: 1px 0 2px; white-space: nowrap; color: var(--dx-ink); }
.tx2-delta { font-size: 12.5px; font-weight: 700; }
.tx2-delta.good { color: #16A34A; }
.tx2-delta.bad { color: var(--dx-danger); }
.tx2-delta.flat { color: var(--bolso-placeholder); }

/* Tabela */
.tx2-table { background: #fff; border: 1px solid var(--dx-border); border-radius: 22px; box-shadow: var(--dx-shadow); overflow: hidden; }
.tx2-thead, .tx2-row { display: grid; grid-template-columns: 2.4fr 1.2fr 1.2fr 1fr 1fr .7fr; align-items: center; padding: 0 24px; gap: 12px; }
.tx2-thead { height: 52px; border-bottom: 1px solid var(--dx-line); }
.tx2-thead span { font-size: 11.5px; font-weight: 800; letter-spacing: .5px; text-transform: uppercase; color: #A3A0C2; }
.tx2-thead .c-val { text-align: right; }
.tx2-row { min-height: 72px; border-bottom: 1px solid var(--dx-line); transition: background .12s; }
.tx2-tbody .tx2-row:last-child { border-bottom: none; }
.tx2-row:hover { background: #FAF7FF; }
.c-desc { display: flex; align-items: center; gap: 14px; min-width: 0; }
.tx2-row-ic { width: 42px; height: 42px; border-radius: 13px; display: grid; place-items: center; flex-shrink: 0; }
.tx2-row-ic.exp { background: #FFE4EA; color: #FF3B5F; }
.tx2-row-ic.inc { background: #DCFCE7; color: #22C55E; }
.tx2-row-desc { font-weight: 700; font-size: 14.5px; color: var(--dx-ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tx2-badge { display: inline-block; padding: 6px 12px; border-radius: 999px; background: #F4F2FA; color: #7C7896; font-size: 12px; font-weight: 700; }
.tx2-dash { color: var(--bolso-placeholder); }
.c-acc, .c-date { color: var(--dx-muted); font-size: 14px; }
.c-val { text-align: right; font-weight: 800; font-size: 14.5px; white-space: nowrap; }
.c-act { display: flex; justify-content: flex-end; gap: 4px; }
.tx2-act-btn { width: 34px; height: 34px; border-radius: 9px; display: grid; place-items: center; color: #B8B2D6; transition: .15s; }
.tx2-act-btn:hover { color: var(--dx-primary); background: #F5F3FF; }
.tx2-act-btn.danger:hover { color: var(--dx-danger); background: var(--bolso-vermelho-tint); }
.tx2-empty { text-align: center; color: var(--dx-muted); padding: 44px 20px; font-size: 14px; }

/* Rodapé / paginação */
.tx2-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 15px 24px; border-top: 1px solid var(--dx-line); }
.tx2-foot-info { color: var(--dx-muted); font-size: 14px; }
.tx2-page { display: flex; align-items: center; gap: 6px; }
.tx2-pbtn { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; color: var(--dx-muted); border: 1px solid var(--dx-border); background: #fff; transition: .15s; }
.tx2-pbtn:hover:not(:disabled) { border-color: #CBD5E1; color: var(--dx-primary); }
.tx2-pbtn:disabled { opacity: .4; cursor: default; }
.tx2-pnum { min-width: 34px; height: 34px; padding: 0 8px; border-radius: 10px; display: inline-grid; place-items: center; font-weight: 700; font-size: 14px; color: var(--dx-muted); }
.tx2-pnum.on { background: var(--dx-primary); color: #fff; }

/* Responsivo */
@media (max-width: 1080px) {
    .tx2-cards { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 920px) {
    .tx2-thead, .tx2-row { grid-template-columns: 2.2fr 1.2fr 1fr 1fr .7fr; }
    .tx2-thead .c-acc, .tx2-row .c-acc { display: none; }
}
@media (max-width: 680px) {
    .tx2-cards { grid-template-columns: 1fr; }
    .tx2-thead { display: none; }
    .tx2-row { grid-template-columns: 1fr auto; row-gap: 4px; padding: 14px 16px; min-height: 0; }
    .tx2-row .c-desc { grid-row: 1; }
    .tx2-row .c-val { grid-row: 1; grid-column: 2; }
    .tx2-row .c-cat { grid-row: 2; grid-column: 1; }
    .tx2-row .c-date { grid-row: 2; grid-column: 2; text-align: right; }
    .tx2-row .c-act { grid-row: 3; grid-column: 1 / -1; justify-content: flex-start; }
    .tx2-actions { width: 100%; }
}

@keyframes lgFloat { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-12px); } }
@keyframes lgRise { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .lg-dot, .lg-tile, .lg-widget, .lg-card { animation: none; } }

/* ---------- Responsivo ---------- */
@media (max-width: 980px) {
    .lg-stage { grid-template-columns: 1fr; }
    .lg-left { display: none; }
    .lg-right { padding: 24px 18px; min-height: 100vh; }
}

@media (max-width: 760px) {
    .content { padding: 16px; }
    .topbar-m { display: flex; align-items: center; gap: 12px; height: 60px; padding: 0 4px 12px; }
    .menu-toggle { display: inline-grid; place-items: center; width: 42px; height: 42px; border-radius: 12px;
        background: #fff; border: 1px solid var(--dx-border); color: var(--dx-ink); }
    .dx-head { gap: 12px; }
    .dx-head-actions { width: 100%; }
    .dx-cta { flex: 1; justify-content: center; }
}

/* ============================================================
   TEMA ESCURO — [data-theme="dark"] sobrescreve tokens + superfícies
   ============================================================ */
[data-theme="dark"] {
    color-scheme: dark;
    /* marca */
    --bolso-texto: #E8ECF6;
    --bolso-texto-2: #97A1B8;
    --bolso-fundo: #0B1120;
    --bolso-card: #151C2C;
    --bolso-linha: #232C42;
    --bolso-placeholder: #5E6A82;
    --bolso-chevron: #5E6A82;
    --bolso-trilho: #232C42;
    --bolso-fundo-externo: #070B14;
    --bolso-verde-tint: rgba(46, 204, 113, .16);
    --bolso-vermelho-tint: rgba(255, 59, 79, .16);
    --bolso-roxo-tint: rgba(124, 58, 237, .22);
    --bolso-azul-tint: rgba(33, 118, 255, .18);
    --bolso-laranja-tint: rgba(255, 159, 28, .18);
    --ink: #E8ECF6;
    /* dx (dashboard/transações) */
    --dx-ink: #E8ECF6;
    --dx-muted: #97A1B8;
    --dx-border: #28324C;
    --dx-line: #1F2840;
    --dx-bg: #0B1120;
    --dx-primary-soft: rgba(124, 58, 237, .20);
    --dx-shadow: 0 4px 20px rgba(0, 0, 0, .38);
    --dx-shadow-h: 0 12px 32px rgba(0, 0, 0, .55);
    /* sombras genéricas */
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, .3), 0 1px 3px rgba(0, 0, 0, .35);
    --shadow-md: 0 2px 6px rgba(0, 0, 0, .35), 0 14px 30px rgba(0, 0, 0, .42);
    --shadow-lg: 0 10px 30px rgba(0, 0, 0, .5), 0 30px 60px rgba(0, 0, 0, .5);
    --sombra-card: 0 12px 30px rgba(0, 0, 0, .35);
    --sombra-acao: 0 8px 18px rgba(0, 0, 0, .3);
}

[data-theme="dark"] body { background: var(--dx-bg); }

/* superfícies brancas → card escuro */
[data-theme="dark"] .sidebar,
[data-theme="dark"] .topbar-m,
[data-theme="dark"] .menu-toggle,
[data-theme="dark"] .dx-iconbtn,
[data-theme="dark"] .dx-period,
[data-theme="dark"] .dx-kpi,
[data-theme="dark"] .dx-card,
[data-theme="dark"] .panel,
[data-theme="dark"] .gcard2,
[data-theme="dark"] .ins-card,
[data-theme="dark"] .mini-stat,
[data-theme="dark"] .month-nav,
[data-theme="dark"] .modal,
[data-theme="dark"] .tx2-card,
[data-theme="dark"] .tx2-table,
[data-theme="dark"] .tx2-month,
[data-theme="dark"] .tx2-pbtn,
[data-theme="dark"] .lg-card,
[data-theme="dark"] .lg-card-sm { background: var(--bolso-card); }

/* fundos claros de páginas de login/solo */
[data-theme="dark"] .lg-right,
[data-theme="dark"] .lg-solo,
[data-theme="dark"] .lg-stage { background: #070B14; }

/* textos do login/cadastro no dark — eram #0F172A (quase preto) e sumiam no card escuro */
[data-theme="dark"] .lg-title,
[data-theme="dark"] .lg-label { color: #E8ECF6; }
[data-theme="dark"] .lg-welcome { color: var(--dx-muted, #97A1B8); }

/* segmentos / hovers / badges */
[data-theme="dark"] .tx2-seg { background: #0F1626; }
[data-theme="dark"] .seg a.active,
[data-theme="dark"] .tx2-seg a.on { background: #20283C; color: #C4B5FD; }
[data-theme="dark"] .sb-item:hover { background: #1A2234; }
[data-theme="dark"] .tx2-row:hover { background: rgba(124, 58, 237, .10); }
[data-theme="dark"] .tx2-mbtn:hover,
[data-theme="dark"] .dx-iconbtn:hover { background: #20283C; }
[data-theme="dark"] .tx2-badge { background: #20283C; color: #B7BFD2; }
[data-theme="dark"] .dx-chip { background: #0F1626; }
[data-theme="dark"] .tx2-row-ic.exp { background: rgba(255, 59, 95, .18); }
[data-theme="dark"] .tx2-row-ic.inc { background: rgba(34, 197, 94, .18); }
[data-theme="dark"] .plan-badge { background: #20283C; color: #C4B5FD; }

/* inputs */
[data-theme="dark"] .f-input,
[data-theme="dark"] .f-select,
[data-theme="dark"] .field input,
[data-theme="dark"] .lg-input {
    background: #0F1626;
    border-color: var(--dx-border);
    color: var(--bolso-texto);
}
[data-theme="dark"] .field input:focus,
[data-theme="dark"] .f-input:focus,
[data-theme="dark"] .f-select:focus,
[data-theme="dark"] .lg-input:focus { background: #0F1626; border-color: var(--bolso-roxo-vibrante); }
[data-theme="dark"] .lg-input::placeholder,
[data-theme="dark"] .f-input::placeholder,
[data-theme="dark"] .field input::placeholder { color: var(--bolso-placeholder); }

/* botões sociais (login) */
[data-theme="dark"] .lg-soc { background: #0F1626; border-color: var(--dx-border); color: var(--bolso-texto); }
[data-theme="dark"] .lg-soc:hover { background: #1A2234; border-color: #3A4564; }

/* ============================================================
   ANIMAÇÃO FINANCEIRA — boas-vindas (login) e despedida (logout)
   ============================================================ */
.fin-ov {
    position: fixed; inset: 0; z-index: 9999;
    display: grid; place-items: center;
    background: radial-gradient(120% 120% at 50% 0%, #2C2068 0%, #17104A 45%, #0B0A24 100%);
    opacity: 0; visibility: hidden; pointer-events: none;
    transition: opacity .5s ease, visibility .5s ease;
}
.fin-ov.show { opacity: 1; visibility: visible; pointer-events: auto; }
.fin-stage { text-align: center; color: #fff; padding: 30px; }

.fin-coins { display: flex; justify-content: center; gap: 14px; height: 52px; margin-bottom: 4px; }
.fin-coin {
    width: 48px; height: 48px; border-radius: 50%;
    display: grid; place-items: center;
    font-weight: 900; font-size: 15px; color: #7A4A00;
    background: radial-gradient(circle at 35% 30%, #FFE69A, #F5A623 70%, #E08A00);
    box-shadow: 0 8px 18px rgba(0, 0, 0, .35), inset 0 -3px 6px rgba(180, 110, 0, .4);
    opacity: 0;
}
.fin-ov.show .fin-coin { animation: coinDrop .7s cubic-bezier(.3, 1.4, .5, 1) forwards; }
.fin-ov.show .fin-coin.c1 { animation-delay: .05s; }
.fin-ov.show .fin-coin.c2 { animation-delay: .22s; }
.fin-ov.show .fin-coin.c3 { animation-delay: .39s; }
@keyframes coinDrop {
    0% { transform: translateY(-150px) rotate(-25deg); opacity: 0; }
    60% { opacity: 1; }
    80% { transform: translateY(10px) rotate(4deg); }
    100% { transform: translateY(0) rotate(0); opacity: 1; }
}

.fin-emblem {
    width: 92px; height: 92px; margin: 8px auto 0;
    border-radius: 26px; display: grid; place-items: center;
    background: linear-gradient(135deg, #7B3DFF, #6D35FF);
    box-shadow: 0 18px 40px rgba(109, 53, 255, .5);
    transform: scale(.4); opacity: 0;
}
.fin-emblem svg { width: 46px; height: 46px; color: #fff; }
.fin-ov.show .fin-emblem { animation: embPop .6s cubic-bezier(.2, 1.5, .4, 1) .12s forwards; }
@keyframes embPop { to { transform: scale(1); opacity: 1; } }

.fin-bars { display: flex; align-items: flex-end; justify-content: center; gap: 9px; height: 62px; margin: 20px 0 4px; }
.fin-bars i { width: 16px; border-radius: 6px 6px 3px 3px; height: 0; background: linear-gradient(180deg, #9F7BFF, #6D35FF); }
.fin-bars i:nth-child(2) { background: linear-gradient(180deg, #4DE6A8, #2ECC71); }
.fin-ov.show .fin-bars i { animation: barGrow .5s cubic-bezier(.2, .8, .2, 1) forwards; }
.fin-ov.show .fin-bars i:nth-child(1) { animation-delay: .35s; }
.fin-ov.show .fin-bars i:nth-child(2) { animation-delay: .47s; }
.fin-ov.show .fin-bars i:nth-child(3) { animation-delay: .59s; }
.fin-ov.show .fin-bars i:nth-child(4) { animation-delay: .71s; }
@keyframes barGrow { to { height: var(--h); } }

.fin-title { font-size: 25px; font-weight: 800; letter-spacing: -.5px; margin-top: 16px; opacity: 0; }
.fin-sub { font-size: 14.5px; color: #C9C3F0; margin-top: 6px; opacity: 0; }
.fin-ov.show .fin-title { animation: finText .5s ease .55s forwards; }
.fin-ov.show .fin-sub { animation: finText .5s ease .7s forwards; }
@keyframes finText { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

/* despedida: emblema + texto, fundo um tom mais profundo */
.fin-bye { background: radial-gradient(120% 120% at 50% 0%, #241a5c 0%, #140E38 55%, #0B0A24 100%); }
.fin-bye .fin-emblem { background: linear-gradient(135deg, #6D35FF, #4A1FB0); }
.fin-bye .fin-title, .fin-bye .fin-sub { opacity: 0; }
.fin-bye.show .fin-title { animation: finText .45s ease .25s forwards; }
.fin-bye.show .fin-sub { animation: finText .45s ease .38s forwards; }

@media (prefers-reduced-motion: reduce) {
    .fin-ov.show .fin-coin,
    .fin-ov.show .fin-emblem,
    .fin-ov.show .fin-bars i,
    .fin-ov.show .fin-title,
    .fin-ov.show .fin-sub { animation: none; opacity: 1; transform: none; }
    .fin-ov.show .fin-bars i { height: var(--h); }
    .fin-ov.show .fin-emblem { transform: scale(1); }
}

/* ── Seletor de tema (Configurações) ── */
.theme-pick { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; max-width: 420px; }
.theme-opt {
    display: flex; flex-direction: column; align-items: center; gap: 8px;
    padding: 16px 10px; border-radius: 16px;
    border: 1.5px solid var(--bolso-linha); background: var(--bolso-card);
    color: var(--bolso-texto-2); cursor: pointer; transition: .15s;
}
.theme-opt:hover { border-color: var(--bolso-chevron); color: var(--bolso-texto); }
.theme-opt .theme-ic svg { width: 22px; height: 22px; display: block; }
.theme-opt .theme-nm { font-size: 13.5px; font-weight: 700; }
.theme-opt.on { border-color: var(--bolso-roxo-vibrante); color: var(--bolso-roxo-vibrante); background: var(--bolso-roxo-tint); }

/* card "Premium ativo" (Perfil) — adapta ao tema */
.premium-active { border-color: #FCE8B6; background: #FFFBF0; }
[data-theme="dark"] .premium-active { border-color: rgba(245, 166, 35, .35); background: rgba(245, 166, 35, .10); }

/* ============================================================
   PLANEJAMENTO / ORÇAMENTOS (.pl-*) — premium limpo (Linear/Copilot)
   ============================================================ */
.pl { display: flex; flex-direction: column; gap: 20px; max-width: 1600px; }

.pl-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.pl-title { font-size: 24px; font-weight: 800; letter-spacing: -.5px; color: var(--dx-ink); }
.pl-sub { color: var(--dx-muted); font-size: 15px; margin-top: 4px; }
.pl-actions { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }

.pl-month { display: inline-flex; align-items: center; gap: 4px; height: 48px; padding: 0 8px; background: var(--bolso-card); border: 1px solid var(--dx-border); border-radius: 16px; }
.pl-mbtn { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; color: var(--dx-muted); transition: .15s; }
.pl-mbtn:hover { background: var(--dx-line); color: var(--dx-primary); }
.pl-mcur { display: inline-flex; align-items: center; gap: 8px; font-weight: 700; font-size: 14.5px; padding: 0 6px; color: var(--dx-ink); white-space: nowrap; }
.pl-mcur svg { color: var(--dx-muted); }

.pl-new { display: inline-flex; align-items: center; gap: 8px; height: 48px; padding: 0 22px; border-radius: 16px;
    background: linear-gradient(90deg, #7C3AED, #6D28D9); color: #fff; font-weight: 700; font-size: 14.5px;
    box-shadow: 0 12px 30px rgba(124, 58, 237, .25); transition: transform .15s, box-shadow .15s; }
.pl-new:hover { transform: translateY(-2px); box-shadow: 0 16px 36px rgba(124, 58, 237, .32); }

.pl-pageerror { background: var(--bolso-vermelho-tint); color: var(--bolso-vermelho); border-radius: 14px; padding: 12px 16px; font-size: 14px; font-weight: 600; }

/* resumo — faixa única, 4 colunas */
.pl-summary { display: grid; grid-template-columns: repeat(4, 1fr); background: var(--bolso-card); border: 1px solid var(--dx-border); border-radius: 22px; padding: 22px; }
.pl-sum { display: flex; align-items: center; gap: 14px; padding: 0 26px; }
.pl-sum:not(:first-child) { border-left: 1px solid var(--dx-line); }
.pl-sum:first-child { padding-left: 0; }
.pl-sum:last-child { padding-right: 0; }
.pl-sum-ic { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; flex-shrink: 0; }
.pl-sum-ic svg { width: 19px; height: 19px; }
.pl-sum-k { color: var(--dx-muted); font-size: 12.5px; font-weight: 600; }
.pl-sum-v { font-size: 18.5px; font-weight: 800; letter-spacing: -.4px; color: var(--dx-ink); margin: 1px 0; white-space: nowrap; }
.pl-sum-v.neg { color: var(--bolso-vermelho); }
.pl-sum-d { color: var(--dx-muted); font-size: 11.5px; }

/* lista de categorias */
.pl-list { display: flex; flex-direction: column; gap: 12px; }
.pl-cat { display: flex; align-items: center; gap: 16px; background: var(--bolso-card); border: 1px solid var(--dx-border); border-radius: 18px; padding: 13px 20px;
    transition: transform .18s var(--ease), box-shadow .18s var(--ease); }
.pl-cat:hover { transform: translateY(-2px); box-shadow: 0 12px 30px rgba(15, 23, 42, .06); }
/* card com menu aberto fica acima do scrim (o transform do hover cria stacking context) */
.pl-cat.menu-open { position: relative; z-index: 40; }
.pl-cat.menu-open:hover { transform: none; }
.pl-cat-ic { width: 46px; height: 46px; border-radius: 13px; display: grid; place-items: center; flex-shrink: 0; }
.pl-cat-ic svg { width: 21px; height: 21px; }
.pl-cat-id { width: 150px; flex-shrink: 0; }
.pl-cat-name { font-size: 14.5px; font-weight: 700; letter-spacing: -.1px; color: var(--dx-ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pl-cat-sub { color: var(--dx-muted); font-size: 11.5px; margin-top: 1px; }
.pl-cat-prog { flex: 1; min-width: 0; }
.pl-cat-vals { font-size: 12px; color: var(--dx-muted); margin-bottom: 7px; }
.pl-cat-vals b { font-size: 14px; font-weight: 700; color: var(--dx-ink); }
.pl-bar { height: 8px; border-radius: 999px; background: #ECECF3; overflow: hidden; }
.pl-bar-fill { display: block; height: 100%; border-radius: 999px; transition: width .6s var(--ease); }
.bar-red { background: #EF4444; } .bar-purple { background: #7C3AED; } .bar-green { background: #22C55E; } .bar-orange { background: #F59E0B; } .bar-blue { background: #2176FF; }
.pl-cat-used { font-size: 11.5px; font-weight: 700; margin-top: 7px; }
.pl-cat-right { width: 132px; flex-shrink: 0; text-align: right; }
.pl-pct { font-size: 23px; font-weight: 800; letter-spacing: -.7px; line-height: 1; }
.pl-badge { display: inline-block; margin: 6px 0 5px; padding: 5px 10px; border-radius: 999px; font-size: 9.5px; font-weight: 800; letter-spacing: .4px; }
.pl-rem { font-size: 13.5px; font-weight: 700; white-space: nowrap; }

/* status — cor de %, badge, restante e "X% utilizado" */
.st-estourado { color: #DC2626; } .st-atencao { color: #7C3AED; } .st-controlado { color: #16A34A; } .st-saudavel { color: #D97706; }
.pl-badge.st-estourado { background: #FEE2E2; } .pl-badge.st-atencao { background: #F3E8FF; } .pl-badge.st-controlado { background: #DCFCE7; } .pl-badge.st-saudavel { background: #FEF3C7; }

/* menu de contexto */
.pl-menu-wrap { position: relative; flex-shrink: 0; }
.pl-menu-btn { width: 38px; height: 38px; border-radius: 11px; display: grid; place-items: center; color: var(--bolso-chevron); transition: .15s; }
.pl-menu-btn:hover { background: var(--dx-line); color: var(--dx-ink); }
.pl-menu { position: absolute; top: 44px; right: 0; z-index: 30; min-width: 168px; background: var(--bolso-card); border: 1px solid var(--dx-border);
    border-radius: 14px; box-shadow: 0 16px 40px rgba(15, 23, 42, .14); padding: 6px; animation: fadeUp .15s var(--ease) both; }
.pl-menu button { display: flex; align-items: center; gap: 10px; width: 100%; padding: 10px 12px; border-radius: 9px; font-size: 14px; font-weight: 600; color: var(--dx-ink); transition: .12s; }
.pl-menu button:hover { background: var(--dx-line); }
.pl-menu button.danger { color: var(--bolso-vermelho); }
.pl-menu button.danger:hover { background: var(--bolso-vermelho-tint); }
.pl-menu-scrim { position: fixed; inset: 0; z-index: 20; }

/* dica (rodapé) */
.pl-tip { display: flex; align-items: center; gap: 12px; background: var(--bolso-card); border: 1px dashed #D8B4FE; border-radius: 18px; padding: 16px 20px; color: var(--dx-muted); font-size: 14px; }
.pl-tip-ic { width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; background: var(--bolso-roxo-tint); color: var(--bolso-roxo-vibrante); flex-shrink: 0; }

/* vazio */
.pl-empty { display: flex; flex-direction: column; align-items: center; gap: 12px; background: var(--bolso-card); border: 1px solid var(--dx-border); border-radius: 24px; padding: 48px 20px; color: var(--dx-muted); }
.pl-empty-cta { padding: 10px 18px; border-radius: 12px; background: var(--dx-primary); color: #fff; font-weight: 700; font-size: 14px; }

/* responsivo */
@media (max-width: 1100px) {
    .pl-summary { grid-template-columns: repeat(2, 1fr); row-gap: 24px; }
    .pl-sum:nth-child(3) { border-left: none; padding-left: 0; }
}
@media (max-width: 820px) {
    .pl-cat { flex-wrap: wrap; gap: 16px; }
    .pl-cat-id { width: auto; flex: 1; }
    .pl-cat-prog { flex-basis: 100%; order: 3; }
    .pl-cat-right { width: auto; }
    .pl-pct { font-size: 32px; }
}
@media (max-width: 560px) {
    .pl-summary { grid-template-columns: 1fr; }
    .pl-sum { border-left: none !important; padding: 0 !important; }
    .pl-sum:not(:first-child) { border-top: 1px solid var(--dx-line); padding-top: 18px !important; margin-top: 4px; }
}

/* dark */
[data-theme="dark"] .pl-bar { background: #232C42; }
[data-theme="dark"] .pl-summary,
[data-theme="dark"] .pl-cat,
[data-theme="dark"] .pl-tip,
[data-theme="dark"] .pl-empty,
[data-theme="dark"] .pl-month,
[data-theme="dark"] .pl-menu { background: var(--bolso-card); }
[data-theme="dark"] .pl-tip { border-color: rgba(216, 180, 254, .3); }
[data-theme="dark"] .pl-badge.st-estourado { background: rgba(220, 38, 38, .18); color: #FCA5A5; }
[data-theme="dark"] .pl-badge.st-atencao { background: rgba(124, 58, 237, .22); color: #C4B5FD; }
[data-theme="dark"] .pl-badge.st-controlado { background: rgba(22, 163, 74, .2); color: #86EFAC; }
[data-theme="dark"] .pl-badge.st-saudavel { background: rgba(217, 119, 6, .2); color: #FCD34D; }
[data-theme="dark"] .st-estourado { color: #F87171; }
[data-theme="dark"] .st-atencao { color: #C4B5FD; }
[data-theme="dark"] .st-controlado { color: #4ADE80; }
[data-theme="dark"] .st-saudavel { color: #FBBF24; }

/* status extras p/ Metas: ok (concluída/verde) e info (no rumo/azul) */
.st-ok { color: #16A34A; } .pl-badge.st-ok { background: #DCFCE7; }
.st-info { color: #2563EB; } .pl-badge.st-info { background: #DBEAFE; }
[data-theme="dark"] .st-ok { color: #4ADE80; } [data-theme="dark"] .pl-badge.st-ok { background: rgba(22, 163, 74, .2); color: #86EFAC; }
[data-theme="dark"] .st-info { color: #93C5FD; } [data-theme="dark"] .pl-badge.st-info { background: rgba(37, 99, 235, .2); color: #93C5FD; }

/* botão Aportar (Metas) */
.mt-aportar { display: inline-flex; align-items: center; gap: 6px; height: 36px; padding: 0 14px; border-radius: 11px; flex-shrink: 0;
    background: var(--bolso-roxo-tint); color: var(--bolso-roxo-vibrante); font-weight: 700; font-size: 12.5px; white-space: nowrap; transition: .15s; }
.mt-aportar:hover { background: var(--dx-primary); color: #fff; }
.mt-aportar:disabled { opacity: .45; cursor: default; }
.mt-aportar:disabled:hover { background: var(--bolso-roxo-tint); color: var(--bolso-roxo-vibrante); }

/* ============================================================
   RECORRENTES (.rc-*) — premium SaaS (Stripe Billing / Ramp)
   ============================================================ */
.rc { display: flex; flex-direction: column; gap: 24px; max-width: 1600px; }

.rc-sec { display: inline-flex; align-items: center; gap: 8px; height: 48px; padding: 0 18px; border-radius: 16px;
    background: var(--bolso-card); border: 1px solid var(--dx-border); color: var(--dx-ink); font-weight: 700; font-size: 14px; transition: .15s; }
.rc-sec:hover { border-color: var(--dx-primary); color: var(--dx-primary); }
.rc-sec:disabled { opacity: .6; }
.rc-flash { background: var(--bolso-roxo-tint); color: var(--bolso-roxo-vibrante); border-radius: 14px; padding: 12px 16px; font-size: 14px; font-weight: 600; }

/* KPIs */
.rc-kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.rc-kpi { display: flex; align-items: center; gap: 16px; background: var(--bolso-card); border: 1px solid var(--dx-border); border-radius: 24px; padding: 22px 24px; box-shadow: var(--dx-shadow); transition: transform .18s var(--ease), box-shadow .18s; }
.rc-kpi:hover { transform: translateY(-2px); box-shadow: var(--dx-shadow-h); }
.rc-kpi-ic { width: 50px; height: 50px; border-radius: 15px; display: grid; place-items: center; flex-shrink: 0; }
.rc-kpi-k { color: var(--dx-muted); font-size: 13.5px; font-weight: 600; }
.rc-kpi-v { font-size: 25px; font-weight: 800; letter-spacing: -.6px; color: var(--dx-ink); margin: 2px 0; white-space: nowrap; }
.rc-kpi-d { color: var(--dx-muted); font-size: 12.5px; }

/* card base */
.rc-card { background: var(--bolso-card); border: 1px solid var(--dx-border); border-radius: 24px; box-shadow: var(--dx-shadow); }
.rc-card-title { font-size: 17px; font-weight: 800; color: var(--dx-ink); letter-spacing: -.3px; }
.rc-card-head { display: flex; align-items: center; justify-content: space-between; padding: 22px 24px 6px; }
.rc-pill { display: inline-flex; align-items: center; gap: 6px; height: 36px; padding: 0 14px; border-radius: 12px; background: var(--bolso-fundo); border: 1px solid var(--dx-border); color: var(--dx-muted); font-size: 13px; font-weight: 600; }
.rc-empty { padding: 40px 24px; text-align: center; color: var(--dx-muted); font-size: 14px; }

/* Linha 2 */
.rc-mid { display: grid; grid-template-columns: 2fr 1fr; gap: 24px; align-items: start; }
.rc-side { display: flex; flex-direction: column; gap: 24px; }

/* timeline */
.rc-tl-card { display: flex; flex-direction: column; padding-bottom: 16px; }
.rc-timeline { position: relative; padding: 8px 24px; }
.rc-timeline::before { content: ""; position: absolute; left: 91px; top: 30px; bottom: 30px; width: 2px; background: var(--dx-line); }
.rc-tl-item { display: grid; grid-template-columns: 46px 16px 44px 1fr auto auto auto; align-items: center; gap: 14px; padding: 14px 0; }
.rc-tl-item:not(:last-child) { border-bottom: 1px solid var(--dx-line); }
.rc-tl-date { text-align: center; line-height: 1.05; }
.rc-tl-date b { display: block; font-size: 18px; font-weight: 800; color: var(--dx-ink); }
.rc-tl-date span { font-size: 10.5px; font-weight: 700; color: var(--dx-muted); letter-spacing: .5px; }
.rc-tl-today { display: block; font-size: 8.5px; font-weight: 800; color: var(--dx-primary); letter-spacing: .5px; }
.rc-tl-dot { width: 13px; height: 13px; border-radius: 50%; justify-self: center; box-shadow: 0 0 0 4px var(--bolso-card); position: relative; z-index: 1; }
.rc-tl-dot.inc { background: var(--bolso-verde); }
.rc-tl-dot.exp { background: var(--bolso-vermelho); }
.rc-tl-ic { width: 44px; height: 44px; border-radius: 13px; display: grid; place-items: center; }
.rc-tl-name { font-weight: 700; font-size: 14.5px; color: var(--dx-ink); }
.rc-tl-sub { font-size: 12.5px; color: var(--dx-muted); margin-top: 1px; }
.rc-tl-val { text-align: right; }
.rc-tl-amt { font-weight: 800; font-size: 15px; }
.rc-tl-freq { font-size: 12px; color: var(--dx-muted); }

.rc-badge { display: inline-block; padding: 5px 11px; border-radius: 999px; font-size: 11.5px; font-weight: 700; white-space: nowrap; }
.rc-badge.b-inc, .rc-badge.b-active { background: #DCFCE7; color: #16A34A; }
.rc-badge.b-exp { background: #FEE2E2; color: #DC2626; }
.rc-badge.b-paused { background: #FEF3C7; color: #D97706; }

.rc-seeall { margin: 6px 24px 0; height: 46px; border-radius: 14px; background: var(--bolso-roxo-tint); color: var(--bolso-roxo-vibrante); font-weight: 700; font-size: 14px; transition: .15s; }
.rc-seeall:hover { background: var(--dx-primary); color: #fff; }

/* resumo por tipo */
.rc-type { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 10px; padding: 18px 24px 8px; }
.rc-type-col { text-align: center; }
.rc-type-n { font-size: 30px; font-weight: 800; letter-spacing: -1px; }
.rc-type-k { font-size: 13px; color: var(--dx-muted); font-weight: 600; }
.rc-type-v { font-size: 13px; font-weight: 700; margin-top: 2px; }
.rc-donut { position: relative; width: 104px; height: 104px; }
.rc-donut-ring { width: 100%; height: 100%; border-radius: 50%; }
.rc-donut-hole { position: absolute; inset: 17px; border-radius: 50%; background: var(--bolso-card); }
.rc-saldo { display: flex; align-items: center; justify-content: space-between; margin: 8px 24px 24px; padding: 14px 16px; border-radius: 14px; background: var(--bolso-verde-tint); }
.rc-saldo span { color: var(--dx-ink); font-weight: 600; font-size: 13.5px; }
.rc-saldo b { font-size: 15px; }

/* recorrências por categoria */
.rc-catlist { padding: 6px 24px 22px; display: flex; flex-direction: column; gap: 14px; }
.rc-catrow { display: grid; grid-template-columns: 28px 84px 1fr 24px 92px; align-items: center; gap: 12px; }
.rc-cat-ic { width: 28px; height: 28px; border-radius: 9px; display: grid; place-items: center; }
.rc-cat-nm { font-size: 13.5px; font-weight: 600; color: var(--dx-ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rc-cat-bar { height: 8px; border-radius: 999px; background: var(--bolso-linha); overflow: hidden; }
.rc-cat-fill { display: block; height: 100%; border-radius: 999px; }
.rc-cat-q { font-size: 13px; color: var(--dx-muted); text-align: center; }
.rc-cat-v { font-size: 13px; font-weight: 700; color: var(--dx-ink); text-align: right; white-space: nowrap; }

/* tabela */
.rc-table-card { display: flex; flex-direction: column; }
.rc-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 16px 24px; flex-wrap: wrap; }
.rc-tabs { display: flex; gap: 6px; flex-wrap: wrap; }
.rc-tab { height: 36px; padding: 0 16px; border-radius: 999px; font-size: 13.5px; font-weight: 600; color: var(--dx-muted); transition: .15s; }
.rc-tab:hover { background: var(--dx-line); color: var(--dx-ink); }
.rc-tab.on { background: var(--bolso-roxo-tint); color: var(--bolso-roxo-vibrante); font-weight: 700; }
.rc-search { display: inline-flex; align-items: center; gap: 8px; height: 40px; padding: 0 14px; border-radius: 12px; background: var(--bolso-card); border: 1px solid var(--dx-border); min-width: 230px; }
.rc-search-ic { color: var(--dx-muted); display: grid; place-items: center; }
.rc-search input { border: none; background: transparent; outline: none; font-size: 14px; color: var(--dx-ink); width: 100%; font-family: inherit; }

.rc-tbl-head, .rc-tbl-row { display: grid; grid-template-columns: 2.2fr 1.1fr .9fr 1fr 1.3fr 1fr .9fr .8fr; align-items: center; gap: 12px; padding: 0 24px; }
.rc-tbl-head { height: 46px; border-top: 1px solid var(--dx-line); border-bottom: 1px solid var(--dx-line); }
.rc-tbl-head span { font-size: 11px; font-weight: 800; letter-spacing: .5px; text-transform: uppercase; color: #A3A0C2; }
.rc-tbl-head .r, .rc-tbl-row .r { text-align: right; justify-self: end; }
.rc-tbl-row { min-height: 66px; border-bottom: 1px solid var(--dx-line); transition: background .12s; }
.rc-tbl-row:last-child { border-bottom: none; }
.rc-tbl-row:hover { background: #FAF7FF; }
.rc-td-desc { display: flex; align-items: center; gap: 12px; min-width: 0; }
.rc-row-ic { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; flex-shrink: 0; }
.rc-row-name { font-weight: 700; font-size: 14px; color: var(--dx-ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rc-tag { display: inline-block; padding: 5px 11px; border-radius: 999px; background: var(--bolso-fundo); color: var(--dx-muted); font-size: 12px; font-weight: 600; }
.rc-muted { color: var(--dx-muted); font-size: 13.5px; }
.rc-date { display: inline-flex; align-items: center; gap: 6px; }
.rc-amt { font-weight: 800; font-size: 14px; }
.rc-acts { display: inline-flex; gap: 4px; }
.rc-act { width: 34px; height: 34px; border-radius: 9px; display: grid; place-items: center; color: var(--bolso-chevron); transition: .15s; }
.rc-act:hover { background: var(--dx-line); color: var(--dx-primary); }
.rc-act.danger:hover { color: var(--bolso-vermelho); background: var(--bolso-vermelho-tint); }

.rc-foot { display: flex; align-items: center; justify-content: center; gap: 8px; color: var(--dx-muted); font-size: 13px; padding: 4px; }

/* responsivo */
@media (max-width: 1200px) {
    .rc-kpis { grid-template-columns: repeat(2, 1fr); }
    .rc-mid { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
    .rc-kpis { grid-template-columns: 1fr; }
    .rc-tbl-head { display: none; }
    .rc-tbl-row { grid-template-columns: 1fr auto; row-gap: 6px; padding: 14px 16px; min-height: 0; }
    .rc-tbl-row > span:nth-child(2), .rc-tbl-row > .rc-muted { display: none; }
}

/* dark */
[data-theme="dark"] .rc-kpi, [data-theme="dark"] .rc-card, [data-theme="dark"] .rc-sec,
[data-theme="dark"] .rc-search, [data-theme="dark"] .rc-donut-hole { background: var(--bolso-card); }
[data-theme="dark"] .rc-pill, [data-theme="dark"] .rc-tag { background: #0F1626; }
[data-theme="dark"] .rc-tbl-row:hover { background: rgba(124, 58, 237, .08); }
[data-theme="dark"] .rc-tab:hover, [data-theme="dark"] .rc-act:hover { background: #20283C; }
[data-theme="dark"] .rc-badge.b-inc, [data-theme="dark"] .rc-badge.b-active { background: rgba(22, 163, 74, .2); color: #86EFAC; }
[data-theme="dark"] .rc-badge.b-exp { background: rgba(220, 38, 38, .18); color: #FCA5A5; }
[data-theme="dark"] .rc-badge.b-paused { background: rgba(217, 119, 6, .2); color: #FCD34D; }
[data-theme="dark"] .rc-saldo { background: rgba(46, 204, 113, .14); }

/* ============================================================
   TRANSAÇÕES (.tn-*) — cards + tabela com estado vazio
   ============================================================ */
.tn { display: flex; flex-direction: column; gap: 22px; max-width: 1600px; }
.tn-title { font-size: 30px; font-weight: 800; letter-spacing: -.5px; color: var(--dx-ink); }

.tn-bar { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.tn-menu-wrap { position: relative; }
.tn-todas { display: inline-flex; align-items: center; gap: 8px; height: 44px; padding: 0 22px; border-radius: 999px;
    background: var(--dx-primary); color: #fff; font-weight: 700; font-size: 14.5px; box-shadow: 0 10px 24px rgba(124, 58, 237, .28); transition: .15s; }
.tn-todas:hover { background: var(--dx-primary-dark); }
.tn-tools { display: flex; align-items: center; gap: 10px; }
.tn-circ { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; background: var(--bolso-card); border: 1px solid var(--dx-border); color: var(--dx-muted); box-shadow: var(--dx-shadow); transition: .15s; }
.tn-circ:hover, .tn-circ.on { color: var(--dx-primary); border-color: #DDD6FE; }
.tn-add { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; flex-shrink: 0;
    background: linear-gradient(135deg, #7C3AED 0%, #6D28D9 100%); color: #fff;
    box-shadow: 0 10px 24px rgba(124, 58, 237, .35); transition: transform .15s, box-shadow .15s, filter .15s; }
.tn-add svg { width: 22px; height: 22px; stroke-width: 2.4; }
.tn-add:hover { transform: translateY(-1px) scale(1.05); box-shadow: 0 16px 32px rgba(124, 58, 237, .48); filter: brightness(1.06); }
.tn-add:active { transform: translateY(0) scale(.98); }
.tn-add:focus-visible { outline: 2px solid #C4B5FD; outline-offset: 2px; }

/* ───────── Modal premium de transação (txm) ───────── */
.txm-scrim { position: fixed; inset: 0; z-index: 100; display: flex; justify-content: center; overflow-y: auto; padding: 24px;
    background: rgba(15, 23, 42, .35); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
    animation: txmFade .18s var(--ease) both; }
@keyframes txmFade { from { opacity: 0; } to { opacity: 1; } }
.txm-modal { margin: auto; width: min(580px, 100%);
    background: #fff; border: 1px solid #EEF2F7; border-radius: 26px; box-shadow: 0 24px 80px rgba(15, 23, 42, .12);
    padding: 28px 30px; display: flex; flex-direction: column; gap: 14px; animation: fadeUp .2s var(--ease) both; }

.txm-head { display: flex; align-items: center; gap: 14px; }
.txm-head-ic { width: 50px; height: 50px; border-radius: 16px; flex-shrink: 0; display: grid; place-items: center;
    background: #F4EEFF; color: #7C3AED; }
.txm-head-ic svg { width: 24px; height: 24px; }
.txm-head-tt { flex: 1; min-width: 0; }
.txm-head-tt h3 { font-size: clamp(21px, 2.6vw, 26px); font-weight: 700; line-height: 1.12; color: #0F172A; letter-spacing: -.4px; }
.txm-head-tt p { margin-top: 3px; font-size: 14px; color: #667085; }
.txm-close { width: 40px; height: 40px; border-radius: 12px; flex-shrink: 0; display: grid; place-items: center;
    background: #F8FAFC; color: #64748B; border: 1px solid #EEF2F7; transition: .15s; }
.txm-close:hover { background: #EEF2F7; color: #0F172A; }

.txm-seg { display: grid; grid-template-columns: 1fr 1fr; gap: 5px; height: 54px; padding: 5px; margin-top: 2px;
    background: #fff; border: 1px solid #E9EAF3; border-radius: 16px; }
.txm-seg button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border-radius: 12px;
    font-size: 15px; font-weight: 700; color: #667085; transition: .15s; }
.txm-seg button:hover { color: #0F172A; }
.txm-seg button.on-exp { background: var(--bolso-vermelho-tint, #FEECEC); color: var(--bolso-vermelho, #E11D48); }
.txm-seg button.on-inc { background: #ECFDF3; color: #16A34A; }

.txm-group { display: flex; flex-direction: column; }
.txm-label { font-size: 13.5px; font-weight: 600; color: #344054; margin-bottom: 7px; }
.txm-field { display: flex; align-items: center; gap: 12px; height: 54px; padding: 0 14px;
    background: #fff; border: 1px solid #E5E7EB; border-radius: 15px; transition: border-color .15s, box-shadow .15s; }
.txm-field:focus-within, .txm-select.open { border-color: #C4B5FD; box-shadow: 0 0 0 4px rgba(124, 58, 237, .10); }
.txm-chip { width: 38px; height: 38px; border-radius: 12px; flex-shrink: 0; display: grid; place-items: center;
    background: #F4EEFF; color: #7C3AED; }
.txm-field input { flex: 1; min-width: 0; border: none; background: transparent; outline: none;
    font-size: 15px; font-weight: 500; color: #0F172A; font-family: inherit; height: 100%; }
.txm-field input::placeholder { color: #98A2B3; font-weight: 500; }
.txm-suffix { font-size: 14px; font-weight: 700; color: #94A3B8; flex-shrink: 0; }
.txm-chev { color: #94A3B8; flex-shrink: 0; pointer-events: none; display: inline-flex; transition: transform .15s; }
.txm-select.open .txm-chev { transform: rotate(180deg); }
.txm-date::-webkit-calendar-picker-indicator { opacity: .5; cursor: pointer; }

/* select customizado (categoria / conta) com ícone + cor exata do cadastro */
.txm-selectwrap { position: relative; }
.txm-select { width: 100%; cursor: pointer; text-align: left; font-family: inherit; }
.txm-select-val { flex: 1; min-width: 0; font-size: 15px; font-weight: 600; color: #0F172A;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.txm-select-ph { flex: 1; min-width: 0; font-size: 15px; font-weight: 500; color: #98A2B3; }
.txm-opt-ic { width: 34px; height: 34px; border-radius: 11px; flex-shrink: 0; display: grid; place-items: center; }
.txm-dd { position: absolute; top: calc(100% + 6px); left: 0; right: 0; z-index: 30; max-height: 248px; overflow-y: auto;
    background: #fff; border: 1px solid #EEF2F7; border-radius: 16px; box-shadow: 0 16px 44px rgba(15, 23, 42, .18);
    padding: 6px; display: flex; flex-direction: column; gap: 2px; animation: fadeUp .14s var(--ease) both; }
.txm-dd-opt { display: flex; align-items: center; gap: 11px; width: 100%; text-align: left; padding: 8px 10px; border-radius: 12px;
    font-size: 14.5px; font-weight: 600; color: #0F172A; transition: background .12s; }
.txm-dd-opt:hover, .txm-dd-opt.sel { background: #F4EEFF; }
.txm-dd-nm { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.txm-dd-check { color: #7C3AED; flex-shrink: 0; display: inline-flex; }
.txm-dd-empty { padding: 14px; text-align: center; font-size: 13.5px; color: #98A2B3; }

.txm-error { display: flex; align-items: center; gap: 8px; padding: 11px 14px; border-radius: 13px;
    background: var(--bolso-vermelho-tint, #FEF2F2); color: var(--bolso-vermelho, #DC2626); font-size: 13.5px; font-weight: 600; }

.txm-tip { display: flex; align-items: flex-start; gap: 12px; padding: 14px 16px; border-radius: 16px;
    background: #F8F5FF; border: 1px solid #E9DDFD; }
.txm-tip-ic { width: 36px; height: 36px; border-radius: 11px; flex-shrink: 0; display: grid; place-items: center;
    background: #fff; color: #7C3AED; }
.txm-tip-tt { display: flex; flex-direction: column; gap: 1px; }
.txm-tip-tt b { font-size: 14px; font-weight: 700; color: #7C3AED; }
.txm-tip-tt span { font-size: 13px; color: #667085; line-height: 1.5; }

.txm-acts { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 4px; }
.txm-btn { height: 54px; border-radius: 16px; display: inline-flex; align-items: center; justify-content: center; gap: 9px;
    font-size: 15px; font-weight: 700; transition: transform .15s, box-shadow .15s, filter .15s, background .15s; }
.txm-btn-cancel { background: #fff; border: 1px solid #E5E7EB; color: #344054; }
.txm-btn-cancel:hover { background: #F8FAFC; }
.txm-btn-save { background: linear-gradient(135deg, #6D28D9 0%, #7C3AED 100%); color: #fff;
    box-shadow: 0 10px 24px rgba(124, 58, 237, .25); }
.txm-btn-save:hover { transform: translateY(-1px); box-shadow: 0 14px 30px rgba(124, 58, 237, .34); filter: brightness(1.05); }
.txm-btn-save:active { transform: translateY(0); }
.txm-btn-save:disabled { opacity: .7; cursor: default; transform: none; box-shadow: 0 10px 24px rgba(124, 58, 237, .2); }
.txm-close:focus-visible, .txm-btn:focus-visible { outline: 2px solid #7C3AED; outline-offset: 2px; }
.txm-seg button:focus-visible, .txm-select:focus-visible { outline: 2px solid #C4B5FD; outline-offset: -2px; }
[data-theme="dark"] .txm-close:focus-visible, [data-theme="dark"] .txm-btn:focus-visible,
[data-theme="dark"] .txm-seg button:focus-visible { outline-color: #C4B5FD; }

@media (max-width: 560px) {
    .txm-modal { padding: 22px 18px; border-radius: 22px; }
    .txm-field, .txm-seg, .txm-btn { height: 50px; }
    .txm-acts { grid-template-columns: 1fr; }
}

/* Dark */
[data-theme="dark"] .txm-modal { background: var(--bolso-card); border-color: var(--dx-border); box-shadow: 0 24px 80px rgba(0, 0, 0, .5); }
[data-theme="dark"] .txm-head-tt h3 { color: var(--dx-ink); }
[data-theme="dark"] .txm-head-tt p { color: var(--dx-muted); }
[data-theme="dark"] .txm-head-ic, [data-theme="dark"] .txm-chip { background: rgba(124, 58, 237, .20); color: #C4B5FD; }
[data-theme="dark"] .txm-close { background: rgba(255, 255, 255, .05); border-color: var(--dx-border); color: var(--dx-muted); }
[data-theme="dark"] .txm-close:hover { background: rgba(255, 255, 255, .10); color: var(--dx-ink); }
[data-theme="dark"] .txm-seg { background: var(--bolso-card); border-color: var(--dx-border); }
[data-theme="dark"] .txm-seg button { color: var(--dx-muted); }
[data-theme="dark"] .txm-seg button.on-exp { background: rgba(239, 68, 68, .18); color: #F87171; }
[data-theme="dark"] .txm-seg button.on-inc { background: rgba(22, 163, 74, .18); color: #4ADE80; }
[data-theme="dark"] .txm-label { color: var(--dx-ink); }
[data-theme="dark"] .txm-field { background: rgba(255, 255, 255, .03); border-color: var(--dx-border); }
[data-theme="dark"] .txm-field input { color: var(--dx-ink); }
[data-theme="dark"] .txm-select-val { color: var(--dx-ink); }
[data-theme="dark"] .txm-date { color-scheme: dark; }
[data-theme="dark"] .txm-dd { background: var(--bolso-card); border-color: var(--dx-border); }
[data-theme="dark"] .txm-dd-opt { color: var(--dx-ink); }
[data-theme="dark"] .txm-dd-opt:hover, [data-theme="dark"] .txm-dd-opt.sel { background: rgba(124, 58, 237, .18); }
[data-theme="dark"] .txm-dd-check { color: #C4B5FD; }
[data-theme="dark"] .txm-tip { background: rgba(124, 58, 237, .10); border-color: rgba(124, 58, 237, .30); }
[data-theme="dark"] .txm-tip-ic { background: rgba(124, 58, 237, .20); color: #C4B5FD; }
[data-theme="dark"] .txm-tip-tt b { color: #C4B5FD; }
[data-theme="dark"] .txm-tip-tt span { color: var(--dx-muted); }
[data-theme="dark"] .txm-btn-cancel { background: rgba(255, 255, 255, .03); border-color: var(--dx-border); color: var(--dx-ink); }
[data-theme="dark"] .txm-btn-cancel:hover { background: rgba(255, 255, 255, .07); }

.tn-dd { position: absolute; top: 52px; left: 0; z-index: 50; min-width: 184px; background: var(--bolso-card); border: 1px solid var(--dx-border); border-radius: 14px; box-shadow: 0 16px 40px rgba(15, 23, 42, .14); padding: 6px; animation: fadeUp .15s var(--ease) both; }
.tn-dd.right { left: auto; right: 0; }
.tn-dd button { display: flex; align-items: center; gap: 10px; width: 100%; padding: 10px 12px; border-radius: 9px; font-size: 14px; font-weight: 600; color: var(--dx-ink); transition: .12s; }
.tn-dd button:hover { background: var(--dx-line); }
.tn-dd button.on { color: var(--dx-primary); background: var(--dx-primary-soft); }
.tn-dd button.danger { color: var(--bolso-vermelho); }
.tn-dd button.danger:hover { background: var(--bolso-vermelho-tint); }
.tn-scrim { position: fixed; inset: 0; z-index: 40; }

.tn-search { display: flex; align-items: center; gap: 10px; height: 46px; padding: 0 16px; background: var(--bolso-card); border: 1px solid var(--dx-border); border-radius: 14px; box-shadow: var(--dx-shadow); color: var(--dx-muted); }
.tn-search input { flex: 1; border: none; background: transparent; outline: none; font-size: 15px; color: var(--dx-ink); font-family: inherit; }
.tn-search-x { width: 28px; height: 28px; border-radius: 8px; color: var(--dx-muted); font-size: 20px; line-height: 1; }
.tn-search-x:hover { background: var(--dx-line); }

.tn-cards { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; }
.tn-card { position: relative; display: flex; align-items: center; gap: 14px; background: var(--bolso-card); border: 1px solid var(--dx-border); border-radius: 18px; padding: 20px 22px; box-shadow: var(--dx-shadow); transition: transform .18s var(--ease), box-shadow .18s; }
.tn-card:hover { transform: translateY(-2px); box-shadow: var(--dx-shadow-h); }
.tn-card-ic { width: 46px; height: 46px; border-radius: 50%; display: grid; place-items: center; color: #fff; flex-shrink: 0; }
.tn-card-ic.ic-blue { background: #2F73F4; }
.tn-card-ic.ic-green { background: #22C55E; }
.tn-card-ic.ic-red { background: #EF4444; }
.tn-card-ic.ic-teal { background: #0E9E8E; }
.tn-card-k { color: var(--dx-muted); font-size: 14px; font-weight: 500; }
.tn-card-v { font-size: 21px; font-weight: 800; letter-spacing: -.4px; color: var(--dx-ink); margin-top: 2px; white-space: nowrap; }
.tn-card-go { position: absolute; top: 15px; right: 15px; color: var(--bolso-chevron); display: grid; place-items: center; }

.tn-panel { background: var(--bolso-card); border: 1px solid var(--dx-border); border-radius: 22px; box-shadow: var(--dx-shadow); overflow: hidden; }
.tn-monthnav { display: flex; align-items: center; justify-content: center; gap: 14px; padding: 20px; }
.tn-mbtn { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; color: var(--dx-primary); transition: .15s; }
.tn-mbtn:hover { background: var(--dx-primary-soft); }
.tn-mpill { display: inline-flex; align-items: center; height: 40px; padding: 0 22px; border-radius: 999px; border: 1.5px solid var(--dx-primary); color: var(--dx-primary); font-weight: 700; font-size: 15px; }

.tn-thead, .tn-row { display: grid; grid-template-columns: 46px 92px 112px 2.2fr 1.4fr 1.4fr 1.1fr 92px; align-items: center; gap: 12px; padding: 0 24px; }
.tn-thead { height: 52px; background: var(--bolso-fundo); border-top: 1px solid var(--dx-line); border-bottom: 1px solid var(--dx-line); }
.tn-thead span { font-size: 13px; font-weight: 600; color: var(--dx-muted); }
.tn-thead .r, .tn-row .r { text-align: right; justify-self: end; }
.tn-row { min-height: 62px; border-bottom: 1px solid var(--dx-line); transition: background .12s; }
.tn-row:last-child { border-bottom: none; }
.tn-row:hover { background: #FAF7FF; }
.tn-row.sel { background: var(--dx-primary-soft); }
.tc-chk input { width: 17px; height: 17px; accent-color: var(--dx-primary); cursor: pointer; }
.tn-status { width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; background: var(--bolso-verde-tint); color: var(--bolso-verde); }
.tc-date { color: var(--dx-muted); font-size: 14px; }
.tc-desc { display: flex; align-items: center; gap: 12px; min-width: 0; }
.tn-row-ic { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; flex-shrink: 0; }
.tn-row-ic.inc { background: var(--bolso-verde-tint); color: var(--bolso-verde); }
.tn-row-ic.exp { background: var(--bolso-vermelho-tint); color: var(--bolso-vermelho); }
.tn-row-name { font-weight: 600; font-size: 14.5px; color: var(--dx-ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tn-badge { display: inline-block; padding: 5px 11px; border-radius: 999px; background: var(--bolso-fundo); color: var(--dx-muted); font-size: 12.5px; font-weight: 600; }
.tn-cat { display: inline-flex; align-items: center; gap: 6px; padding: 4px 11px 4px 8px; border-radius: 999px; font-size: 12.5px; font-weight: 600; max-width: 100%; }
.tn-cat svg { flex-shrink: 0; }

/* chip de categoria na legenda do donut (Resumo) */
.dx-donut-legend .li { display: flex; align-items: center; gap: 8px; }
.dx-leg-chip { display: inline-flex; align-items: center; gap: 6px; padding: 4px 11px 4px 8px; border-radius: 999px; font-size: 12.5px; font-weight: 600; }
.dx-leg-chip svg { flex-shrink: 0; }
.dx-donut-legend .pc { margin-left: auto; font-weight: 700; color: var(--dx-ink); }
.tn-dash { color: var(--bolso-placeholder); }
.tc-acc { color: var(--dx-muted); font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tc-val { font-weight: 800; font-size: 14.5px; white-space: nowrap; }
.tc-act { display: inline-flex; gap: 4px; }
.tn-act { width: 32px; height: 32px; border-radius: 9px; display: grid; place-items: center; color: var(--bolso-chevron); transition: .15s; }
.tn-act:hover { color: var(--dx-primary); background: var(--dx-line); }
.tn-act.danger:hover { color: var(--bolso-vermelho); background: var(--bolso-vermelho-tint); }

.tn-noresult { display: flex; flex-direction: column; align-items: center; gap: 14px; padding: 56px 20px; }
.tn-art { display: block; }
.tn-noresult-txt { color: var(--dx-muted); font-size: 14.5px; }

@media (max-width: 1100px) { .tn-cards { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 720px) {
    .tn-cards { grid-template-columns: 1fr; }
    .tn-thead { display: none; }
    .tn-row { grid-template-columns: 24px 1fr auto; row-gap: 4px; padding: 12px 16px; min-height: 0; }
    .tn-row .tc-sit, .tn-row .tc-date, .tn-row .tc-cat, .tn-row .tc-acc { display: none; }
}

/* dark */
[data-theme="dark"] .tn-circ, [data-theme="dark"] .tn-search, [data-theme="dark"] .tn-card,
[data-theme="dark"] .tn-panel, [data-theme="dark"] .tn-dd { background: var(--bolso-card); }
[data-theme="dark"] .tn-thead, [data-theme="dark"] .tn-badge { background: #0F1626; }
[data-theme="dark"] .tn-row:hover { background: rgba(124, 58, 237, .08); }
[data-theme="dark"] .tn-act:hover, [data-theme="dark"] .tn-mbtn:hover { background: #20283C; }
[data-theme="dark"] .tn-noresult circle[fill="#F5F3FF"] { fill: #20283C; }

/* ============================================================
   NOTIFICAÇÕES — sino (.nb-*) + central/preferências (.nt-*)
   ============================================================ */
.sb-brand { display: flex; align-items: center; justify-content: space-between; gap: 8px; }

.nb { position: relative; }
.nb-btn { position: relative; width: 38px; height: 38px; border-radius: 11px; display: grid; place-items: center; color: var(--dx-muted); transition: .15s; }
.nb-btn svg { width: 20px; height: 20px; }
.nb-btn:hover, .nb-btn.on { background: var(--dx-line); color: var(--dx-primary); }
.nb-badge { position: absolute; top: 1px; right: 1px; min-width: 16px; height: 16px; padding: 0 4px; border-radius: 999px; background: var(--bolso-vermelho); color: #fff; font-size: 10px; font-weight: 800; display: grid; place-items: center; box-shadow: 0 0 0 2px var(--bolso-card); }

/* ===== Central de notificações — modal premium (centralizado + backdrop blur) ===== */
.nb-scrim { position: fixed; inset: 0; z-index: 100; background: rgba(17, 12, 46, .38);
    backdrop-filter: blur(7px); -webkit-backdrop-filter: blur(7px); animation: nbFade .2s ease both; }
.nb-panel { position: fixed; z-index: 101; top: 50%; left: 50%; transform: translate(-50%, -50%);
    width: min(412px, calc(100vw - 28px)); max-height: min(720px, 92vh); display: flex; flex-direction: column;
    background: #fff; border-radius: 28px; box-shadow: 0 20px 60px rgba(0, 0, 0, .12); overflow: hidden;
    animation: nbPop .26s cubic-bezier(.16, 1, .3, 1) both; }

.nb-head { display: flex; align-items: flex-start; gap: 12px; padding: 22px 22px 16px; flex-shrink: 0; }
.nb-head-ic { width: 48px; height: 48px; border-radius: 15px; background: #F3EEFF; color: #7C3AED; display: grid; place-items: center; flex-shrink: 0; }
.nb-head-ic svg { width: 22px; height: 22px; }
.nb-head-tt { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; padding-top: 3px; }
.nb-title { font-weight: 800; font-size: 23px; letter-spacing: -.5px; color: #0F172A; line-height: 1.08; }
.nb-sub { font-size: 13.5px; font-weight: 600; color: #7C3AED; }
.nb-allread { display: inline-flex; align-items: center; gap: 7px; max-width: 116px; padding: 9px 12px; border-radius: 13px;
    background: #F8F5FF; border: 1px solid #E9DDFD; color: #7C3AED; font-size: 12px; font-weight: 700; line-height: 1.2; text-align: left; flex-shrink: 0; transition: background .15s; }
.nb-allread svg { width: 15px; height: 15px; flex-shrink: 0; }
.nb-allread:hover { background: #F0E8FF; }

.nb-list { position: relative; flex: 1; overflow-y: auto; padding: 8px 20px 12px; display: flex; flex-direction: column; gap: 14px;
    scroll-snap-type: y proximity; scroll-padding-top: 8px; }
.nb-list .nb-item { scroll-snap-align: start; }
.nb-list::-webkit-scrollbar { width: 8px; }
.nb-list::-webkit-scrollbar-thumb { background: #EADFF9; border-radius: 999px; }
.nb-list::-webkit-scrollbar-track { background: transparent; }

.nb-empty { display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 54px 16px; color: #94A3B8; font-size: 14px; }
.nb-empty svg { width: 30px; height: 30px; opacity: .55; }

.nb-item { position: relative; display: flex; align-items: center; gap: 13px; width: 100%; text-align: left;
    height: 104px; flex-shrink: 0; overflow: hidden;
    padding: 10px 16px 10px 22px; border-radius: 18px; background: #fff; box-shadow: 0 4px 16px rgba(0, 0, 0, .05);
    cursor: pointer; transition: transform .14s, box-shadow .14s; }
.nb-item:hover { transform: translateY(-2px); box-shadow: 0 10px 28px rgba(0, 0, 0, .09); }
/* barra vertical colorida à esquerda (substitui o ponto) */
.nb-item::before { content: ""; position: absolute; left: 9px; top: 16px; bottom: 16px; width: 5px; border-radius: 999px; background: var(--nbc, #7C3AED); }
.nb-item-ic { width: 42px; height: 42px; border-radius: 13px; display: grid; place-items: center; flex-shrink: 0;
    background: var(--nbc-soft, #EEF2FF); color: var(--nbc, #7C3AED); }
.nb-item-ic svg { width: 20px; height: 20px; }
.nb-item-body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.nb-item-title { font-weight: 700; font-size: 15px; color: #0F172A; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nb-item-text { font-size: 13.5px; color: #64748B; line-height: 1.42; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.nb-item-time { font-size: 12.5px; color: #94A3B8; margin-top: 3px; }
.nb-dot { width: 10px; height: 10px; border-radius: 50%; background: #7C3AED; flex-shrink: 0; align-self: center; }
.nb-detail { align-self: center; flex-shrink: 0; padding: 10px 15px; border-radius: 12px; background: #F8F5FF; color: #7C3AED; font-size: 12.5px; font-weight: 700; white-space: nowrap; transition: background .15s; }
.nb-item:hover .nb-detail { background: #F0E8FF; }

/* cores por tipo: barra lateral + ícone */
.nb-k-info  { --nbc: #3B82F6; --nbc-soft: #EAF2FE; }
.nb-k-sec   { --nbc: #22C55E; --nbc-soft: #E7F8EE; }
.nb-k-alert { --nbc: #FF5A5A; --nbc-soft: #FFECEC; }
.nb-k-promo { --nbc: #7C3AED; --nbc-soft: #F3EEFF; }
.nb-k-bill  { --nbc: #F59E0B; --nbc-soft: #FEF3DD; }

.nb-foot { position: relative; display: flex; align-items: center; justify-content: space-between; gap: 10px; margin: 18px 20px 20px; height: 64px; flex-shrink: 0; padding: 0 22px;
    border-radius: 18px; background: #F8F5FF; border: 1px solid #E9DDFD; color: #7C3AED; font-size: 15px; font-weight: 700; transition: background .15s; }
/* divisória de largura total entre a lista e o rodapé */
.nb-foot::before { content: ""; position: absolute; left: -20px; right: -20px; top: -9px; height: 1px; background: #D6DDE8; }
[data-theme="dark"] .nb-foot::before { background: rgba(255, 255, 255, .14); }
.nb-foot:hover { background: #F0E8FF; }
.nb-foot-l { display: inline-flex; align-items: center; gap: 11px; }
.nb-foot svg { width: 19px; height: 19px; }

@keyframes nbFade { from { opacity: 0; } to { opacity: 1; } }
@keyframes nbPop { from { opacity: 0; transform: translate(-50%, -47%) scale(.97); } to { opacity: 1; transform: translate(-50%, -50%) scale(1); } }

/* central / preferências */
.nt-card { background: var(--bolso-card); border: 1px solid var(--dx-border); border-radius: 20px; box-shadow: var(--dx-shadow); padding: 22px 24px; }
.nt-card-h { font-size: 16px; font-weight: 800; color: var(--dx-ink); }
.nt-card-sub { color: var(--dx-muted); font-size: 13.5px; margin: 4px 0 14px; }
.nt-prefs { display: flex; flex-direction: column; }
.nt-prefs-head, .nt-prefs-row { display: grid; grid-template-columns: 1fr 70px 70px; align-items: center; gap: 12px; padding: 11px 4px; }
.nt-prefs-head { font-size: 11.5px; font-weight: 800; color: var(--dx-muted); text-transform: uppercase; letter-spacing: .4px; border-bottom: 1px solid var(--dx-line); }
.nt-prefs-head span:not(:first-child) { justify-self: center; }
.nt-prefs-row { border-bottom: 1px solid var(--dx-line); }
.nt-prefs-row:last-child { border-bottom: none; }
.nt-prefs-row > .nt-switch { justify-self: center; }
.nt-prefs-k { display: flex; align-items: center; gap: 11px; font-size: 14px; font-weight: 600; color: var(--dx-ink); }
.nt-prefs-ic { width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; flex-shrink: 0; }

.nt-switch { display: inline-flex; cursor: pointer; }
.nt-switch input { position: absolute; opacity: 0; width: 0; height: 0; }
.nt-switch-track { width: 40px; height: 23px; border-radius: 999px; background: var(--bolso-linha); position: relative; transition: background .15s; }
.nt-switch-knob { position: absolute; top: 2px; left: 2px; width: 19px; height: 19px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .2); transition: transform .15s; }
.nt-switch.on .nt-switch-track { background: var(--dx-primary); }
.nt-switch.on .nt-switch-knob { transform: translateX(17px); }
.nt-switch.locked { opacity: .5; cursor: default; }

/* Lembrete de contas a vencer: antecedência (chips) + WhatsApp */
.nt-set { padding: 14px 4px; border-top: 1px solid var(--dx-line); }
.nt-set:first-of-type { border-top: none; padding-top: 4px; }
.nt-set-top { display: flex; align-items: center; gap: 8px; }
.nt-set-label { font-size: 14px; font-weight: 700; color: var(--dx-ink); }
.nt-premium { font-size: 10px; font-weight: 800; letter-spacing: .5px; color: var(--dx-primary);
    background: rgba(124, 58, 237, .12); border-radius: 999px; padding: 2px 8px; }
.nt-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.nt-chip { display: inline-flex; align-items: center; height: 40px; padding: 0 16px; border-radius: 12px;
    border: 1px solid var(--dx-border); background: var(--bolso-fundo); color: var(--dx-ink);
    font-size: 13.5px; font-weight: 700; cursor: pointer;
    transition: background .12s, border-color .12s, color .12s; }
.nt-chip:hover { border-color: var(--dx-primary); }
.nt-chip.on { background: var(--dx-primary); border-color: var(--dx-primary); color: #fff; }
.nt-chip.locked { margin-top: 10px; cursor: default; opacity: .75; }
.nt-chip.locked:hover { border-color: var(--dx-border); }
.nt-set-hint { font-size: 12px; color: var(--dx-muted); margin: 8px 0 0; }
.nt-phone { display: flex; gap: 8px; align-items: center; margin-top: 8px; max-width: 440px; }
.nt-phone-input { flex: 1; min-width: 0; padding: 13px 15px; border: 1px solid var(--bolso-linha);
    border-radius: 13px; font-size: 15px; font-family: inherit; background: var(--bolso-fundo); color: var(--dx-ink);
    transition: border-color .15s, background .15s; }
.nt-phone-input:focus { outline: none; border-color: var(--dx-primary); background: var(--bolso-card); }
.nt-saved { font-size: 12px; color: var(--dx-primary); font-weight: 600; margin: 8px 0 0; }

.nt-list { display: flex; flex-direction: column; margin-top: 4px; }
.nt-item { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; padding: 13px 8px; border-bottom: 1px solid var(--dx-line); transition: background .12s; border-radius: 10px; }
.nt-item:last-child { border-bottom: none; }
.nt-item:hover { background: var(--bolso-fundo); }
.nt-item.unread .nt-item-title { font-weight: 800; }
.nt-item-body { display: flex; flex-direction: column; gap: 2px; min-width: 0; flex: 1; }
.nt-item-title { font-weight: 600; font-size: 14px; color: var(--dx-ink); }
.nt-item-text { font-size: 13px; color: var(--dx-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nt-item-time { font-size: 12px; color: var(--bolso-placeholder); white-space: nowrap; flex-shrink: 0; }

[data-theme="dark"] .nb-panel, [data-theme="dark"] .nt-card { background: var(--bolso-card); }
[data-theme="dark"] .nb-title { color: var(--dx-ink); }
[data-theme="dark"] .nb-head-ic { background: rgba(124, 58, 237, .2); }
[data-theme="dark"] .nb-item { background: #121A2B; box-shadow: 0 4px 18px rgba(0, 0, 0, .3); }
[data-theme="dark"] .nb-item-title { color: var(--dx-ink); }
[data-theme="dark"] .nb-item-text { color: var(--dx-muted); }
[data-theme="dark"] .nb-allread,
[data-theme="dark"] .nb-foot,
[data-theme="dark"] .nb-detail { background: rgba(124, 58, 237, .16); border-color: rgba(124, 58, 237, .34); color: #C9B6FB; }
[data-theme="dark"] .nb-allread:hover,
[data-theme="dark"] .nb-foot:hover,
[data-theme="dark"] .nb-item:hover .nb-detail { background: rgba(124, 58, 237, .26); }
[data-theme="dark"] .nt-item:hover { background: #0F1626; }
[data-theme="dark"] .nt-switch-track { background: #2A3550; }

/* ============================================================
   TONS EXTRAS (paleta de cores das categorias)
   ============================================================ */
.tint-teal { background: #CCFBF1; color: #0D9488; }
.tint-pink { background: #FCE7F3; color: #DB2777; }
.tint-yellow { background: #FEF9C3; color: #CA8A04; }
.tint-indigo { background: #E0E7FF; color: #4F46E5; }
.tint-slate { background: #E2E8F0; color: #475569; }
[data-theme="dark"] .tint-teal { background: rgba(13, 148, 136, .18); color: #5EEAD4; }
[data-theme="dark"] .tint-pink { background: rgba(236, 72, 153, .18); color: #F9A8D4; }
[data-theme="dark"] .tint-yellow { background: rgba(202, 138, 4, .2); color: #FDE047; }
[data-theme="dark"] .tint-indigo { background: rgba(99, 102, 241, .2); color: #A5B4FC; }
[data-theme="dark"] .tint-slate { background: rgba(100, 116, 139, .25); color: #CBD5E1; }

/* ============================================================
   CATEGORIAS (.ct-*) — gerenciar ícone + cor
   ============================================================ */
.ct { display: flex; flex-direction: column; gap: 20px; max-width: 1200px; }
.ct-group { background: var(--bolso-card); border: 1px solid var(--dx-border); border-radius: 22px; box-shadow: var(--dx-shadow); padding: 22px 24px; }
.ct-group-h { display: flex; align-items: center; gap: 10px; font-size: 16px; font-weight: 800; color: var(--dx-ink); margin-bottom: 16px; }
.ct-gdot { width: 10px; height: 10px; border-radius: 50%; }
.ct-gdot.exp { background: var(--bolso-vermelho); }
.ct-gdot.inc { background: var(--bolso-verde); }
.ct-count { margin-left: auto; font-size: 13px; font-weight: 700; color: var(--dx-muted); background: var(--bolso-fundo); border-radius: 999px; padding: 3px 11px; }
.ct-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(195px, 1fr)); gap: 12px; }
.ct-chip { position: relative; display: flex; align-items: center; gap: 12px; padding: 11px 14px; border-radius: 14px; border: 1px solid var(--dx-border); background: var(--bolso-card); transition: .15s; }
.ct-chip:not(.sys) { cursor: pointer; }
.ct-chip:not(.sys):hover { border-color: var(--bolso-roxo-vibrante); box-shadow: 0 6px 18px rgba(124, 58, 237, .1); }
.ct-chip-ic { width: 40px; height: 40px; border-radius: 11px; display: grid; place-items: center; flex-shrink: 0; }
.ct-chip-nm { font-size: 14px; font-weight: 600; color: var(--dx-ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; flex: 1; }
.ct-sys { font-size: 9.5px; font-weight: 800; text-transform: uppercase; letter-spacing: .4px; color: var(--dx-muted); background: var(--bolso-fundo); border-radius: 6px; padding: 3px 7px; }
.ct-chip-x { width: 28px; height: 28px; border-radius: 8px; display: grid; place-items: center; color: var(--bolso-chevron); opacity: 0; transition: .15s; }
.ct-chip:hover .ct-chip-x { opacity: 1; }
.ct-chip-x:hover { color: var(--bolso-vermelho); background: var(--bolso-vermelho-tint); }
.ct-add { display: flex; align-items: center; justify-content: center; gap: 8px; padding: 11px 14px; border-radius: 14px; border: 1.5px dashed var(--dx-border); color: var(--dx-muted); font-weight: 600; font-size: 14px; transition: .15s; }
.ct-add:hover { border-color: var(--bolso-roxo-vibrante); color: var(--bolso-roxo-vibrante); }

.ct-modal { max-width: 520px; }
.ct-preview { display: flex; align-items: center; gap: 14px; padding: 16px; border-radius: 14px; background: var(--bolso-fundo); margin-bottom: 18px; }
.ct-preview .ct-chip-ic { width: 50px; height: 50px; border-radius: 14px; }
.ct-preview-nm { font-size: 16px; font-weight: 700; color: var(--dx-ink); }
.ct-preview-sub { font-size: 13px; color: var(--dx-muted); }
.ct-swatches { display: flex; flex-wrap: wrap; gap: 10px; }
.ct-sw { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; color: #fff; box-shadow: 0 2px 6px rgba(0, 0, 0, .15); transition: transform .12s; }
.ct-sw:hover { transform: scale(1.1); }
.ct-sw.sel { box-shadow: 0 0 0 2px var(--bolso-card), 0 0 0 4px rgba(0, 0, 0, .25); }
.ct-iconpick { display: grid; grid-template-columns: repeat(auto-fill, minmax(46px, 1fr)); gap: 8px; max-height: 224px; overflow-y: auto; padding: 2px; }
.ct-ic { aspect-ratio: 1; border-radius: 11px; display: grid; place-items: center; background: var(--bolso-fundo); color: var(--dx-muted); border: 1.5px solid transparent; transition: .12s; }
.ct-ic:hover { transform: translateY(-1px); color: var(--dx-ink); }
.ct-ic.sel { border-color: currentColor; }

[data-theme="dark"] .ct-group, [data-theme="dark"] .ct-chip { background: var(--bolso-card); }
[data-theme="dark"] .ct-count, [data-theme="dark"] .ct-sys, [data-theme="dark"] .ct-preview, [data-theme="dark"] .ct-ic { background: #0F1626; }
[data-theme="dark"] .ct-sw.sel { box-shadow: 0 0 0 2px var(--bolso-card), 0 0 0 4px rgba(255, 255, 255, .35); }

/* ═══════════ Relatórios (rc) ═══════════ */
.rc { max-width: 1600px; margin: 0 auto; display: flex; flex-direction: column; gap: 10px; animation: fadeUp .25s var(--ease) both; }
.rc-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.rc-title { font-size: 27px; font-weight: 800; color: #0F172A; letter-spacing: -.7px; line-height: 1.05; }
.rc-sub { margin-top: 2px; font-size: 14px; color: #64748B; }
.rc-seg { display: inline-flex; gap: 4px; padding: 4px; background: #fff; border: 1px solid #E2E8F0; border-radius: 999px; }
.rc-seg a { padding: 8px 16px; border-radius: 999px; font-size: 13.5px; font-weight: 600; color: #64748B; transition: .15s; }
.rc-seg a:hover { color: #0F172A; }
.rc-seg a.on { background: #F5F3FF; color: #6D28D9; font-weight: 700; }
.rc-filters { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.rc-range { display: inline-flex; align-items: center; gap: 6px; padding: 4px 4px 4px 6px; background: #fff; border: 1px solid #E2E8F0; border-radius: 999px; }
.rc-range.on { border-color: #C4B5FD; box-shadow: 0 0 0 3px rgba(124, 58, 237, .10); }
.rc-range-in { border: none; background: #F1F5F9; border-radius: 999px; padding: 7px 11px; font-size: 13px; font-weight: 600; color: #334155; font-family: inherit; outline: none; cursor: pointer; color-scheme: light; }
.rc-range-in:focus { box-shadow: 0 0 0 2px #C4B5FD inset; }
.rc-range-sep { font-size: 12.5px; color: #94A3B8; font-weight: 500; }
.rc-range-btn { background: #6D28D9; color: #fff; border-radius: 999px; padding: 8px 16px; font-size: 13px; font-weight: 700; transition: background .15s; }
.rc-range-btn:hover { background: #5B21B6; }
[data-theme="dark"] .rc-range { background: var(--bolso-card); border-color: var(--dx-border); }
[data-theme="dark"] .rc-range-in { background: rgba(255, 255, 255, .05); color: var(--dx-ink); color-scheme: dark; }
[data-theme="dark"] .rc-range-sep { color: var(--dx-muted); }
/* Botão "Período" (details/summary) que revela o filtro de datas */
.rc-period { position: relative; }
.rc-period-btn { display: inline-flex; align-items: center; gap: 7px; padding: 9px 15px; border-radius: 999px;
    background: #fff; border: 1px solid #E2E8F0; font-size: 13.5px; font-weight: 600; color: #475569;
    cursor: pointer; list-style: none; user-select: none; transition: .15s; }
.rc-period-btn::-webkit-details-marker { display: none; }
.rc-period-btn::marker { content: ""; }
.rc-period-btn svg { width: 15px; height: 15px; }
.rc-period-btn svg:last-child { opacity: .65; transition: transform .15s; }
.rc-period[open] .rc-period-btn svg:last-child { transform: rotate(180deg); }
.rc-period-btn:hover { border-color: #C4B5FD; color: #6D28D9; }
.rc-period.on .rc-period-btn, .rc-period[open] .rc-period-btn { background: #F5F3FF; border-color: #DDD6FE; color: #6D28D9; }
.rc-period-pop { position: absolute; top: calc(100% + 8px); right: 0; z-index: 40; background: #fff;
    border: 1px solid #EEF2F7; border-radius: 16px; box-shadow: 0 16px 44px rgba(15, 23, 42, .16); padding: 12px;
    animation: fadeUp .14s var(--ease) both; }
.rc-period:not([open]) .rc-period-pop { display: none; }
.rc-range-form { display: flex; align-items: center; gap: 8px; }
[data-theme="dark"] .rc-period-btn { background: var(--bolso-card); border-color: var(--dx-border); color: var(--dx-muted); }
[data-theme="dark"] .rc-period.on .rc-period-btn, [data-theme="dark"] .rc-period[open] .rc-period-btn { background: rgba(124, 58, 237, .22); border-color: rgba(124, 58, 237, .4); color: #C4B5FD; }
[data-theme="dark"] .rc-period-pop { background: var(--bolso-card); border-color: var(--dx-border); }

/* ═══════════ Contas (ac) ═══════════ */
.ac { max-width: 1600px; margin: 0 auto; display: flex; flex-direction: column; gap: 12px; animation: fadeUp .25s var(--ease) both; }
.ac-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.ac-title { font-size: 26px; font-weight: 800; color: #0F172A; letter-spacing: -.8px; line-height: 1.05; }
.ac-sub { margin-top: 2px; font-size: 14px; color: #64748B; }
.ac-new { height: 42px; padding: 0 18px; border-radius: 13px; display: inline-flex; align-items: center; gap: 8px;
    background: linear-gradient(90deg, #7C3AED, #6D28D9); color: #fff; font-weight: 700; font-size: 14px;
    box-shadow: 0 10px 24px rgba(124, 58, 237, .28); transition: transform .15s, box-shadow .15s, filter .15s; }
.ac-new:hover { transform: translateY(-1px); box-shadow: 0 14px 30px rgba(124, 58, 237, .36); filter: brightness(1.05); }
.ac-flash { padding: 11px 14px; border-radius: 13px; background: var(--bolso-vermelho-tint, #FEF2F2); color: var(--bolso-vermelho, #DC2626); font-weight: 600; font-size: 14px; }
.ac-loading, .ac-empty-page { padding: 56px; text-align: center; color: #94A3B8; background: #fff; border: 1px solid #EEF2F7; border-radius: 18px; }

/* KPIs */
.ac-kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.ac-kpi { position: relative; overflow: hidden; min-height: 116px; background: #fff; border: 1px solid #EEF2F7; border-radius: 18px;
    padding: 14px 18px; box-shadow: 0 8px 30px rgba(15, 23, 42, .04); transition: transform .15s, box-shadow .15s; }
.ac-kpi:hover { transform: translateY(-2px); box-shadow: 0 16px 40px rgba(15, 23, 42, .08); }
.ac-kpi-ic { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; margin-bottom: 8px; }
.ac-kpi-k { font-size: 12.5px; color: #64748B; font-weight: 500; }
.ac-kpi-v { font-size: 22px; font-weight: 800; color: #0F172A; letter-spacing: -.5px; margin-top: 1px; line-height: 1.1; white-space: nowrap; }
.ac-kpi-name { font-size: 18px; }
.ac-kpi-sub { font-size: 14px; font-weight: 700; margin-top: 1px; }
.ac-kpi-d { font-size: 12px; color: #94A3B8; margin-top: 3px; position: relative; z-index: 1; }
.ac-spark { position: absolute; left: 0; right: 0; bottom: 0; width: 100%; height: 30px; pointer-events: none; }

/* row 2 */
.ac-row2 { display: grid; grid-template-columns: 7fr 5fr; gap: 14px; }
.ac-card { background: #fff; border: 1px solid #EEF2F7; border-radius: 18px; padding: 16px 18px; box-shadow: 0 8px 30px rgba(15, 23, 42, .04); }
.ac-card-h { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.ac-card-t { font-size: 15.5px; font-weight: 700; color: #0F172A; }
.ac-chip { font-size: 12.5px; font-weight: 600; color: #475569; background: #F1F5F9; border: 1px solid #E2E8F0; border-radius: 10px; padding: 6px 12px; }

/* donut */
.ac-donutwrap { display: flex; align-items: center; gap: 24px; }
.ac-donut { position: relative; width: 150px; height: 150px; flex-shrink: 0; }
.ac-donut-svg { width: 100%; height: 100%; }
.ac-donut-track { fill: none; stroke: #F1F5F9; stroke-width: 4.2; }
.ac-donut-center { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; }
.ac-donut-total { font-size: 17px; font-weight: 800; color: #0F172A; letter-spacing: -.4px; }
.ac-donut-lbl { font-size: 12px; color: #94A3B8; margin-top: 1px; }
.ac-legend { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.ac-legrow { display: grid; grid-template-columns: 14px 1fr auto 48px; align-items: center; gap: 12px; padding: 8px 4px; border-bottom: 1px solid #F4F6FA; }
.ac-legrow:last-child { border-bottom: none; }
.ac-leg-dot { width: 11px; height: 11px; border-radius: 50%; }
.ac-leg-nm { font-size: 14px; font-weight: 600; color: #0F172A; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ac-leg-v { font-size: 14px; font-weight: 600; color: #334155; white-space: nowrap; }
.ac-leg-pct { font-size: 13px; font-weight: 700; color: #64748B; text-align: right; }

/* resumo */
.ac-summary { display: flex; flex-direction: column; gap: 11px; }
.ac-sumrow { display: grid; grid-template-columns: 36px 1fr auto; grid-template-rows: auto auto; column-gap: 12px; align-items: center; }
.ac-sum-ic { grid-row: 1 / 3; width: 36px; height: 36px; border-radius: 11px; display: grid; place-items: center; }
.ac-sum-nm { font-size: 14.5px; font-weight: 700; color: #0F172A; }
.ac-sum-bal { font-size: 13px; color: #64748B; }
.ac-sum-pct { grid-column: 3; grid-row: 1; font-size: 14px; font-weight: 700; color: #475569; }
.ac-sum-bar { grid-column: 2 / 4; grid-row: 2; height: 8px; border-radius: 999px; background: #EEF2F7; overflow: hidden; margin-top: 7px; }
.ac-sum-bar i { display: block; height: 100%; border-radius: 999px; }

/* cards de conta */
.ac-purple { --ac-c: #7C3AED; --ac-soft: #F5F3FF; }
.ac-blue { --ac-c: #3B82F6; --ac-soft: #EFF6FF; }
.ac-green { --ac-c: #22C55E; --ac-soft: #ECFDF5; }
.ac-orange { --ac-c: #F59E0B; --ac-soft: #FFF7ED; }
.ac-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.ac-acct { background: #fff; border: 1px solid #EEF2F7; border-radius: 18px; overflow: hidden; box-shadow: 0 8px 30px rgba(15, 23, 42, .04); transition: transform .15s, box-shadow .15s; }
.ac-acct:hover { transform: translateY(-2px); box-shadow: 0 16px 40px rgba(15, 23, 42, .08); }
.ac-acct-h { display: flex; align-items: center; gap: 11px; padding: 13px 16px; background: var(--ac-soft); }
.ac-acct-ic { width: 42px; height: 42px; border-radius: 13px; background: var(--ac-c); color: #fff; display: grid; place-items: center; flex-shrink: 0; }
.ac-acct-nm { font-size: 16px; font-weight: 700; color: #0F172A; flex: 1; min-width: 0; }
.ac-acct-badge { font-size: 11.5px; font-weight: 700; color: #16A34A; background: #DCFCE7; padding: 4px 11px; border-radius: 999px; }
.ac-menuwrap { position: relative; flex-shrink: 0; }
.ac-acct-menu { color: #94A3B8; padding: 4px; border-radius: 8px; transition: .12s; }
.ac-acct-menu:hover { color: #475569; background: rgba(15, 23, 42, .05); }
.ac-menu { position: absolute; top: calc(100% + 6px); right: 0; z-index: 30; min-width: 150px; background: #fff; border: 1px solid #EEF2F7;
    border-radius: 14px; box-shadow: 0 16px 40px rgba(15, 23, 42, .16); padding: 6px; display: flex; flex-direction: column; animation: fadeUp .12s var(--ease) both; }
.ac-menu button { display: flex; align-items: center; gap: 9px; padding: 9px 11px; border-radius: 9px; font-size: 14px; font-weight: 600; color: #334155; text-align: left; }
.ac-menu button:hover { background: #F4F6FA; }
.ac-menu button.danger { color: #DC2626; }
.ac-menu button.danger:hover { background: #FEF2F2; }
.ac-scrim { position: fixed; inset: 0; z-index: 20; }
.ac-acct-b { padding: 16px 18px; }
.ac-acct-bal { font-size: 24px; font-weight: 800; color: #0F172A; letter-spacing: -.8px; }
.ac-acct-desc { font-size: 13px; color: #64748B; margin-top: 2px; }
.ac-acct-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin: 12px 0; padding-top: 12px; border-top: 1px solid #F1F5F9; }
.ac-acct-stats b { font-size: 16px; font-weight: 800; color: #0F172A; display: block; }
.ac-acct-stats span { font-size: 12px; color: #94A3B8; }
.ac-acct-btn { width: 100%; height: 42px; border-radius: 13px; background: var(--ac-soft); color: var(--ac-c);
    font-weight: 700; font-size: 13.5px; display: inline-flex; align-items: center; justify-content: center; gap: 6px; transition: filter .15s; }
.ac-acct-btn:hover { filter: brightness(.96); }

.ac-foot { display: flex; align-items: center; justify-content: center; gap: 8px; padding: 4px; font-size: 13px; color: #64748B; }
.ac-foot svg { width: 16px; height: 16px; color: #94A3B8; }

@media (max-width: 1100px) {
    .ac-kpis { grid-template-columns: repeat(2, 1fr); }
    .ac-row2 { grid-template-columns: 1fr; }
    .ac-cards { grid-template-columns: 1fr; }
}
@media (max-width: 560px) { .ac-kpis { grid-template-columns: 1fr; } .ac-title { font-size: 28px; } }

/* Dark */
[data-theme="dark"] .ac-title, [data-theme="dark"] .ac-card-t, [data-theme="dark"] .ac-kpi-v, [data-theme="dark"] .ac-donut-total,
[data-theme="dark"] .ac-leg-nm, [data-theme="dark"] .ac-sum-nm, [data-theme="dark"] .ac-acct-nm, [data-theme="dark"] .ac-acct-bal,
[data-theme="dark"] .ac-acct-stats b { color: var(--dx-ink); }
[data-theme="dark"] .ac-sub, [data-theme="dark"] .ac-kpi-k, [data-theme="dark"] .ac-leg-v, [data-theme="dark"] .ac-sum-bal, [data-theme="dark"] .ac-acct-desc { color: var(--dx-muted); }
[data-theme="dark"] .ac-kpi, [data-theme="dark"] .ac-card, [data-theme="dark"] .ac-acct, [data-theme="dark"] .ac-loading, [data-theme="dark"] .ac-empty-page, [data-theme="dark"] .ac-menu { background: var(--bolso-card); border-color: var(--dx-border); box-shadow: none; }
[data-theme="dark"] .ac-chip { background: rgba(255, 255, 255, .04); border-color: var(--dx-border); color: var(--dx-muted); }
[data-theme="dark"] .ac-donut-track { stroke: var(--dx-border); }
[data-theme="dark"] .ac-legrow { border-color: var(--dx-border); }
[data-theme="dark"] .ac-sum-bar { background: var(--dx-border); }
[data-theme="dark"] .ac-acct-h { background: rgba(255, 255, 255, .03); }
[data-theme="dark"] .ac-acct-stats { border-color: var(--dx-border); }
[data-theme="dark"] .ac-acct-btn { background: rgba(124, 58, 237, .14); }
[data-theme="dark"] .ac-menu button { color: var(--dx-ink); }
[data-theme="dark"] .ac-menu button:hover { background: rgba(255, 255, 255, .05); }
.rc-loading, .rc-empty-page { padding: 56px; text-align: center; color: #94A3B8; background: #fff; border: 1px solid #EEF2F7; border-radius: 20px; }

.rc-kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.rc-kpi { display: flex; gap: 12px; align-items: center; background: #fff; border: 1px solid #EEF2F7; border-radius: 16px;
    padding: 11px 16px; box-shadow: 0 8px 30px rgba(15, 23, 42, .04); transition: transform .15s, box-shadow .15s; }
.rc-kpi:hover { transform: translateY(-2px); box-shadow: 0 16px 40px rgba(15, 23, 42, .08); }
.rc-kpi-ic { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; flex-shrink: 0; }
.rc-kpi-b { min-width: 0; }
.rc-kpi-k { font-size: 12.5px; color: #64748B; font-weight: 500; }
.rc-kpi-v { font-size: 22px; font-weight: 800; color: #0F172A; letter-spacing: -.5px; margin-top: 1px; white-space: nowrap; }
.rc-kpi-d { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 600; margin-top: 3px; }
.rc-kpi-d.muted { color: #94A3B8; font-weight: 500; }

.rc-row { display: grid; gap: 10px; }
.rc-row-83 { grid-template-columns: 8fr 3fr; }
.rc-row-2 { grid-template-columns: 1fr 1fr; }

.rc-card { background: #fff; border: 1px solid #EEF2F7; border-radius: 16px; padding: 12px 16px; box-shadow: 0 8px 30px rgba(15, 23, 42, .04); }
.rc-card-h { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 9px; }
.rc-card-t { font-size: 15.5px; font-weight: 700; color: #0F172A; }
.rc-card-tools { display: flex; align-items: center; gap: 16px; }
.rc-card-ic { color: #7C3AED; display: inline-flex; }
.rc-chip { font-size: 12.5px; font-weight: 600; color: #475569; background: #F1F5F9; border: 1px solid #E2E8F0; border-radius: 10px; padding: 6px 12px; white-space: nowrap; }
.rc-legend { display: flex; gap: 14px; }
.rc-li { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 600; color: #475569; }
.rc-li .dot { width: 10px; height: 10px; border-radius: 3px; }
.dot.green { background: #22C55E; }
.dot.red { background: #EF4444; }
.rc-empty { padding: 40px; text-align: center; color: #94A3B8; }

/* barras */
.rc-barwrap { display: grid; grid-template-columns: 52px 1fr; gap: 10px; height: 152px; }
.rc-yaxis { display: flex; flex-direction: column; justify-content: space-between; text-align: right; padding-bottom: 22px; }
.rc-yaxis span { font-size: 11px; color: #94A3B8; font-weight: 500; white-space: nowrap; line-height: 1; }
.rc-barsarea { position: relative; }
.rc-grid { position: absolute; inset: 0 0 22px 0; display: flex; flex-direction: column; justify-content: space-between; }
.rc-grid i { height: 1px; background: #F1F5F9; }
.rc-bars { position: absolute; inset: 0; display: flex; }
.rc-bcol { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.rc-bpair { flex: 1; display: flex; align-items: flex-end; justify-content: center; gap: 6px; }
.rc-bmonth { height: 22px; flex-shrink: 0; display: grid; place-items: center; font-size: 12.5px; font-weight: 600; color: #64748B; }
.rc-bmonth.on { color: #6D28D9; }
.rc-bar { position: relative; width: 22px; max-width: 30%; border-radius: 6px 6px 0 0; min-height: 4px; transition: height .55s var(--ease); }
.rc-bar.green { background: linear-gradient(180deg, #34D399, #22C55E); }
.rc-bar.red { background: linear-gradient(180deg, #FB7185, #EF4444); }
.rc-bar:hover { filter: brightness(1.06); }
.rc-bval { position: absolute; top: -16px; left: 50%; transform: translateX(-50%); font-size: 10px; font-weight: 700; color: #334155; white-space: nowrap; }

/* resumo do período */
.rc-sum-list { display: flex; flex-direction: column; gap: 3px; }
.rc-sum { display: flex; align-items: center; gap: 12px; padding: 8px 10px; border-radius: 13px; transition: background .15s; }
.rc-sum:hover { background: #F8FAFC; }
.rc-sum-ic { width: 38px; height: 38px; border-radius: 11px; display: grid; place-items: center; flex-shrink: 0; }
.rc-sum-k { font-size: 12px; color: #94A3B8; font-weight: 500; }
.rc-sum-v { font-size: 16px; font-weight: 800; color: #0F172A; letter-spacing: -.3px; }
.rc-sum-s { font-size: 11.5px; color: #94A3B8; }

/* donut */
.rc-donutwrap { display: flex; align-items: center; gap: 22px; }
.rc-donut { position: relative; width: 132px; height: 132px; flex-shrink: 0; }
.rc-donut-svg { width: 100%; height: 100%; }
.rc-donut-track { fill: none; stroke: #F1F5F9; stroke-width: 4.2; }
.rc-donut-center { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; }
.rc-donut-total { font-size: 16px; font-weight: 800; color: #0F172A; letter-spacing: -.4px; }
.rc-donut-lbl { font-size: 11.5px; color: #94A3B8; margin-top: 1px; }
.rc-cats { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.rc-catrow { display: grid; grid-template-columns: 13px 1fr auto 52px; align-items: center; gap: 12px; padding: 6px 2px; border-bottom: 1px solid #F4F6FA; }
.rc-catrow:last-child { border-bottom: none; }
.rc-cat-dot { width: 11px; height: 11px; border-radius: 4px; }
.rc-cat-nm { font-size: 14px; font-weight: 600; color: #0F172A; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rc-cat-val { font-size: 14px; font-weight: 600; color: #334155; white-space: nowrap; }
.rc-cat-pct { font-size: 13px; font-weight: 700; color: #64748B; text-align: right; }

/* linha */
.rc-linewrap { display: grid; grid-template-columns: 52px 1fr; gap: 10px; height: 140px; }
.rc-linearea { position: relative; }
.rc-line-plot { position: absolute; inset: 12px 8px 22px 8px; }
.rc-line-svg { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.rc-line-pt { position: absolute; transform: translate(-50%, -50%); }
.rc-line-pt i { display: block; width: 10px; height: 10px; border-radius: 50%; background: #7C3AED; border: 3px solid #fff; box-shadow: 0 2px 6px rgba(124, 58, 237, .4); }
.rc-line-pt b { position: absolute; bottom: 12px; left: 50%; transform: translateX(-50%); font-size: 11px; font-weight: 700; color: #6D28D9; white-space: nowrap; }
.rc-line-x { position: absolute; left: 8px; right: 8px; bottom: 0; height: 22px; display: flex; justify-content: space-between; align-items: center; }
.rc-line-x span { font-size: 13px; font-weight: 600; color: #64748B; }
.rc-line-x span.on { color: #6D28D9; font-weight: 700; }

/* tabela */
.rc-table { display: flex; flex-direction: column; }
.rc-tr { display: grid; grid-template-columns: 28px 1.3fr 1fr 1fr 1fr 1fr 1.2fr; align-items: center; gap: 12px; padding: 5px 8px; border-radius: 9px; transition: background .12s; }
.rc-tr:not(.rc-th):hover { background: #F8FAFC; }
.rc-th { font-size: 12px; font-weight: 700; color: #94A3B8; text-transform: uppercase; letter-spacing: .04em; border-bottom: 1px solid #EEF2F7; border-radius: 0; }
.rc-tr .r { text-align: right; }
.rc-tr .b { font-weight: 800; color: #0F172A; }
.rc-tr span { font-size: 14px; font-weight: 600; color: #334155; }
.rc-th span { font-size: 12px; font-weight: 700; color: #94A3B8; }
.rc-th .th-inc, .rc-th .th-eco { color: var(--bolso-verde, #16A34A); }
.rc-th .th-exp { color: var(--bolso-vermelho, #EF4444); }
.rc-th .th-bal { color: var(--bolso-roxo-vibrante, #7C3AED); }
[data-theme="dark"] .rc-th .th-inc, [data-theme="dark"] .rc-th .th-eco { color: #34D399; }
[data-theme="dark"] .rc-th .th-exp { color: #FB7185; }
[data-theme="dark"] .rc-th .th-bal { color: #A78BFA; }
.rc-trend { display: inline-flex; }
.rc-trend.up { color: #22C55E; }
.rc-trend.down { color: #EF4444; }
.rc-tm { color: #0F172A !important; font-weight: 700 !important; }
.rc-ecocell { display: flex; align-items: center; gap: 10px; justify-content: flex-end; }
.rc-ecobar { width: 84px; height: 6px; background: #EEF2F7; border-radius: 999px; overflow: hidden; flex-shrink: 0; }
.rc-ecobar i { display: block; height: 100%; background: linear-gradient(90deg, #34D399, #22C55E); border-radius: 999px; }
.rc-ecocell b { font-size: 13px; font-weight: 700; color: #64748B; min-width: 32px; text-align: right; }

.rc-foot { display: flex; align-items: center; justify-content: center; gap: 8px; padding: 4px; font-size: 13px; color: #64748B; }
.rc-foot svg { width: 16px; height: 16px; color: #94A3B8; }

@media (max-width: 1100px) {
    .rc-kpis { grid-template-columns: repeat(2, 1fr); }
    .rc-row-83, .rc-row-2 { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
    .rc-kpis { grid-template-columns: 1fr; }
    .rc-title { font-size: 24px; }
    .rc-table { overflow-x: auto; -webkit-overflow-scrolling: touch; }
    .rc-tr { grid-template-columns: 28px 130px repeat(4, 92px) 120px; min-width: 660px; }
}

/* Dark */
[data-theme="dark"] .rc-title, [data-theme="dark"] .rc-card-t, [data-theme="dark"] .rc-kpi-v,
[data-theme="dark"] .rc-sum-v, [data-theme="dark"] .rc-donut-total, [data-theme="dark"] .rc-cat-nm,
[data-theme="dark"] .rc-tr .b, [data-theme="dark"] .rc-tm { color: var(--dx-ink) !important; }
[data-theme="dark"] .rc-sub, [data-theme="dark"] .rc-kpi-k, [data-theme="dark"] .rc-cat-val,
[data-theme="dark"] .rc-tr span { color: var(--dx-muted); }
[data-theme="dark"] .rc-kpi, [data-theme="dark"] .rc-card, [data-theme="dark"] .rc-seg,
[data-theme="dark"] .rc-loading, [data-theme="dark"] .rc-empty-page { background: var(--bolso-card); border-color: var(--dx-border); box-shadow: none; }
[data-theme="dark"] .rc-seg a.on { background: rgba(124, 58, 237, .22); color: #C4B5FD; }
[data-theme="dark"] .rc-chip { background: rgba(255, 255, 255, .04); border-color: var(--dx-border); color: var(--dx-muted); }
[data-theme="dark"] .rc-grid i, [data-theme="dark"] .rc-donut-track { background: var(--dx-border); stroke: var(--dx-border); }
[data-theme="dark"] .rc-grid i { background: var(--dx-border); }
[data-theme="dark"] .rc-sum:hover, [data-theme="dark"] .rc-tr:not(.rc-th):hover { background: rgba(255, 255, 255, .03); }
[data-theme="dark"] .rc-th { border-color: var(--dx-border); }
[data-theme="dark"] .rc-catrow { border-color: var(--dx-border); }
[data-theme="dark"] .rc-line-pt i { border-color: var(--bolso-card); }
[data-theme="dark"] .rc-ecobar { background: var(--dx-border); }
[data-theme="dark"] .rc-bval { color: var(--dx-ink); }

/* ============================================================
   PERFIL (.pf-*) — premium fiel (Stripe / Mercury / Revolut)
   cantos 28px · muito branco · sombras sutis · 200ms
   ============================================================ */
.pf { display: flex; flex-direction: column; gap: 20px; }
.pf-msg { display: inline-block; margin: 0 0 16px; color: var(--bolso-verde); }

/* Botão único de tema (canto superior direito do Perfil) */
.pf-theme-btn { display: inline-flex; align-items: center; gap: 8px; padding: 9px 14px; border-radius: 12px;
    border: 1px solid var(--bolso-linha); background: var(--bolso-card); font-weight: 700; font-size: 13.5px;
    cursor: pointer; transition: .18s; }
.pf-theme-btn:hover { border-color: var(--bolso-chevron); box-shadow: 0 6px 16px rgba(16, 24, 40, .07); }
.pf-theme-ic { display: inline-flex; color: var(--bolso-roxo-vibrante); }
.pf-theme-ic svg { width: 18px; height: 18px; display: block; }
[data-theme="dark"] .pf-theme-btn { background: var(--bolso-card); border-color: var(--dx-border); }

/* topo (usuário + assinatura) e "Seu plano" (2 cards): mesmas 2 colunas, colunas alinhadas
   entre as linhas e cards da mesma linha com a mesma altura (align-items: stretch) */
.pf-top, .pf-plan-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; align-items: stretch; }
.pf-top .pf-benefits { grid-template-columns: repeat(2, 1fr); gap: 14px 18px; margin: 18px 0 20px; }
@media (max-width: 860px) { .pf-top, .pf-plan-grid { grid-template-columns: 1fr; } }

/* card principal do usuário */
.pf-hero { position: relative; overflow: hidden; display: flex; flex-direction: column; justify-content: space-between; align-items: flex-start; gap: 20px; padding: 26px 28px; border-radius: 28px; }
.pf-hero-main { display: flex; align-items: center; gap: 20px; width: 100%; }
.pf-hero::after { content: ""; position: absolute; top: -50px; right: -30px; width: 280px; height: 280px; border-radius: 50%;
    background: radial-gradient(circle at 32% 32%, rgba(124, 58, 237, .10), rgba(124, 58, 237, 0) 70%); pointer-events: none; }
.pf-hero > * { position: relative; z-index: 1; }
.pf-hero-id { flex: 1; min-width: 0; }
.pf-name { font-size: 21px; font-weight: 800; letter-spacing: -.01em; }
.pf-email { color: var(--bolso-texto-2); font-size: 14.5px; margin-top: 1px; }
.pf-since { display: inline-flex; align-items: center; gap: 6px; color: var(--bolso-texto-2); font-size: 13px; margin-top: 9px; }
.pf-hero-actions { display: flex; flex-direction: column; align-items: flex-end; gap: 12px; }
.pf-manage { display: inline-flex; align-items: center; gap: 5px; text-decoration: none; }

/* card de assinatura (Premium ativo / oferta) */
.pf-premium, .pf-upsell { position: relative; overflow: hidden; padding: 28px 30px; border-radius: 28px; }
.pf-premium { background: linear-gradient(135deg, #FFF8E7, #FFFDF8); border: 1px solid #FDE7A3; }
.pf-upsell { background: linear-gradient(135deg, var(--bolso-roxo-tint), rgba(255, 255, 255, 0)); border: 1px solid #E3D9FF; }
.pf-premium-illus { position: absolute; top: 50%; right: 22px; transform: translateY(-50%); width: 116px; height: 116px; pointer-events: none; }
.pf-premium-head { display: flex; align-items: flex-start; gap: 16px; position: relative; z-index: 1; }
.pf-diamond { width: 54px; height: 54px; border-radius: 16px; flex-shrink: 0; display: grid; place-items: center;
    background: linear-gradient(135deg, #FBE4A0, #F2C13F); color: #8A6212; box-shadow: 0 8px 18px rgba(228, 178, 60, .35); }
.pf-upsell .pf-diamond { background: linear-gradient(135deg, #B79BFF, var(--bolso-roxo-vibrante)); color: #fff; box-shadow: 0 8px 18px rgba(109, 53, 255, .30); }
.pf-premium-title { font-size: 17px; font-weight: 800; }
.pf-premium-sub { color: #97824f; font-size: 13.5px; margin-top: 3px; max-width: 460px; }
.pf-upsell .pf-premium-sub { color: var(--bolso-texto-2); }
.pf-benefits { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; margin: 20px 0 22px; position: relative; z-index: 1; }
.pf-benefit { display: flex; align-items: flex-start; gap: 10px; }
.pf-bcheck { width: 22px; height: 22px; border-radius: 50%; flex-shrink: 0; display: grid; place-items: center; background: #F6E3A8; color: #97700F; }
.pf-upsell .pf-bcheck { background: var(--bolso-verde-tint); color: var(--bolso-verde); }
.pf-bt { font-weight: 700; font-size: 13.5px; }
.pf-bs { color: #9b8456; font-size: 12px; margin-top: 1px; }
.pf-upsell .pf-bs { color: var(--bolso-texto-2); }
.pf-premium-foot { display: flex; align-items: center; justify-content: flex-end; position: relative; z-index: 1; }
.pf-upsell .pf-premium-foot { justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.pf-price { font-weight: 800; font-size: 18px; }
.pf-price-mo { font-weight: 500; font-size: 13px; color: var(--bolso-texto-2); }

/* "Cancelar assinatura" — discreto sobre o creme; vira vermelho (ação destrutiva) no hover */
.pf-cancel { display: inline-flex; align-items: center; gap: 7px; padding: 10px 18px; border-radius: 12px;
    font-weight: 700; font-size: 13.5px; color: var(--bolso-texto-2); cursor: pointer; transition: .18s;
    background: rgba(255, 255, 255, .72); border: 1px solid #ECDCAE; box-shadow: 0 1px 2px rgba(120, 90, 20, .07); }
.pf-cancel svg { width: 15px; height: 15px; }
.pf-cancel:hover { color: var(--bolso-vermelho); border-color: var(--bolso-vermelho);
    background: var(--bolso-vermelho-tint); box-shadow: 0 6px 16px rgba(239, 68, 68, .14); }
.pf-cancel:disabled { opacity: .55; cursor: default; box-shadow: none; }
[data-theme="dark"] .pf-cancel { background: rgba(255, 255, 255, .05); border-color: rgba(245, 166, 35, .30); color: var(--dx-muted); box-shadow: none; }
[data-theme="dark"] .pf-cancel:hover { color: #FB7185; border-color: #FB7185; background: rgba(251, 113, 133, .12); box-shadow: none; }

/* cards genéricos (Seu plano / Aparência / Segurança) */
.pf-card { padding: 26px 28px; border-radius: 28px; }
.pf-h { display: flex; align-items: center; gap: 11px; }
.pf-h-ic { width: 34px; height: 34px; border-radius: 11px; display: grid; place-items: center; flex-shrink: 0; }
.pf-h-t { font-size: 16px; font-weight: 800; }
.pf-h-sub { color: var(--bolso-texto-2); font-size: 13.5px; margin: 3px 0 18px; }

/* tabela do plano */
.pf-rows { display: flex; flex-direction: column; margin-top: 6px; }
.pf-row { display: flex; align-items: center; gap: 13px; padding: 13px 2px; border-bottom: 1px solid var(--bolso-linha); }
.pf-row:last-child { border-bottom: none; }
.pf-row-ic { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; flex-shrink: 0; }
.pf-row-k { color: var(--bolso-texto-2); font-size: 14px; }
.pf-row-v { margin-left: auto; font-weight: 700; font-size: 14px; }
.pf-row-v.good { color: var(--bolso-verde); }

/* seletor de tema com preview */
.pf-themes { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.pf-topt { position: relative; display: flex; flex-direction: column; gap: 13px; padding: 16px 16px 18px; border-radius: 20px;
    border: 1.5px solid var(--bolso-linha); background: var(--bolso-card); cursor: pointer; transition: .18s; }
.pf-topt:hover { border-color: var(--bolso-chevron); box-shadow: 0 8px 20px rgba(16, 24, 40, .07); }
.pf-topt.on { border-color: var(--bolso-roxo-vibrante); box-shadow: 0 0 0 3px var(--bolso-roxo-tint); }
.pf-topt-head { display: flex; align-items: center; justify-content: space-between; }
.pf-topt-ic { color: var(--bolso-texto-2); }
.pf-topt-ic svg { width: 22px; height: 22px; display: block; }
.pf-topt.on .pf-topt-ic { color: var(--bolso-roxo-vibrante); }
.pf-radio { width: 22px; height: 22px; border-radius: 50%; border: 1.5px solid var(--bolso-linha); display: grid; place-items: center; color: #fff; flex-shrink: 0; }
.pf-topt.on .pf-radio { background: var(--bolso-roxo-vibrante); border-color: var(--bolso-roxo-vibrante); }
.pf-topt-nm { font-weight: 700; font-size: 14px; text-align: center; }
.pf-prev { position: relative; height: 116px; border-radius: 13px; overflow: hidden; border: 1px solid var(--bolso-linha); display: flex; flex-direction: column; }
.pf-prev-bar { height: 22px; flex-shrink: 0; }
.pf-prev-main { flex: 1; display: flex; }
.pf-prev-nav { width: 34%; }
.pf-prev-lines { flex: 1; padding: 11px; display: flex; flex-direction: column; gap: 7px; }
.pf-prev-lines i { height: 7px; border-radius: 4px; }
.pf-prev-lines i:nth-child(1) { width: 86%; }
.pf-prev-lines i:nth-child(2) { width: 64%; }
.pf-prev-lines i:nth-child(3) { width: 74%; }
.pf-prev-lines i:nth-child(4) { width: 52%; }
.pf-prev.is-light { background: #fff; }
.pf-prev.is-light .pf-prev-bar { background: #EBEEF4; }
.pf-prev.is-light .pf-prev-nav { background: #F4F6FA; border-right: 1px solid #E7EBF2; }
.pf-prev.is-light .pf-prev-lines i { background: #E1E6EE; }
.pf-prev.is-dark { background: #0F1422; }
.pf-prev.is-dark .pf-prev-bar { background: #1B2233; }
.pf-prev.is-dark .pf-prev-nav { background: #161D2C; border-right: 1px solid #232C40; }
.pf-prev.is-dark .pf-prev-lines i { background: #2A3346; }
.pf-prev.is-split { background: linear-gradient(90deg, #fff 50%, #0F1422 50%); }
.pf-prev.is-split .pf-prev-bar { background: linear-gradient(90deg, #EBEEF4 50%, #1B2233 50%); }
.pf-prev.is-split .pf-prev-nav { background: linear-gradient(90deg, #F4F6FA 50%, #161D2C 50%); }
.pf-prev.is-split .pf-prev-lines i { background: linear-gradient(90deg, #E1E6EE 50%, #2A3346 50%); }
.pf-prev.is-split::after { content: ""; position: absolute; top: 0; bottom: 0; left: 50%; width: 1px; background: rgba(120, 120, 140, .35); }

/* segurança da conta */
.pf-sec-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.pf-sec-card { display: flex; align-items: center; gap: 12px; padding: 16px; border-radius: 16px;
    border: 1px solid var(--bolso-linha); background: var(--bolso-card); min-height: 74px; }
.pf-sec-card.is-link { cursor: pointer; transition: .15s; text-decoration: none; color: inherit; }
.pf-sec-card.is-link:hover { border-color: var(--bolso-roxo-vibrante); box-shadow: 0 8px 20px rgba(16, 24, 40, .07); }
.pf-sec-ic { width: 38px; height: 38px; border-radius: 11px; display: grid; place-items: center; flex-shrink: 0; }
.pf-sec-txt { min-width: 0; flex: 1; }
.pf-sec-k { font-size: 12.5px; color: var(--bolso-texto-2); font-weight: 600; }
.pf-sec-v { font-weight: 700; font-size: 13.5px; margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pf-sec-chev { color: var(--bolso-chevron); flex-shrink: 0; }

/* rodapé + sair */
.pf-foot { display: flex; align-items: center; justify-content: center; gap: 8px; color: var(--bolso-texto-2); font-size: 13px; padding: 8px 0 2px; }
.pf-logout { display: flex; justify-content: center; padding-bottom: 4px; }

/* botão do card Senha (mantém o visual de card, sem aparência de <button>) */
button.pf-sec-card { font: inherit; text-align: left; width: 100%; }

/* modal de troca de senha (in-place) */
.pf-modal-backdrop { position: fixed; inset: 0; z-index: 1000; display: grid; place-items: center; padding: 20px;
    background: rgba(16, 24, 40, .45); backdrop-filter: blur(2px); animation: pf-fade .15s ease; }
.pf-modal { width: 100%; max-width: 440px; background: var(--bolso-card); border: 1px solid var(--bolso-linha);
    border-radius: 22px; padding: 24px; box-shadow: 0 24px 60px rgba(16, 24, 40, .28); animation: pf-pop .18s ease;
    max-height: 92vh; overflow-y: auto; }
.pf-modal-head { display: flex; align-items: flex-start; gap: 13px; margin-bottom: 18px; }
.pf-modal-t { font-size: 17px; font-weight: 800; }
.pf-modal-s { color: var(--bolso-texto-2); font-size: 13px; margin-top: 2px; }
.pf-modal-err { margin-bottom: 14px; }
.pf-field { margin-bottom: 14px; }
.pf-field label { display: block; font-size: 13px; font-weight: 600; color: var(--bolso-texto-2); margin-bottom: 6px; }
.pf-field input { width: 100%; padding: 11px 13px; border-radius: 12px; border: 1px solid var(--bolso-linha);
    background: var(--bolso-fundo); font-size: 14.5px; font-family: inherit; color: var(--bolso-texto); box-sizing: border-box; }
.pf-field input:focus { outline: none; border-color: var(--bolso-roxo-vibrante); background: var(--bolso-card); }
.pf-modal-foot { display: flex; justify-content: flex-end; gap: 10px; margin-top: 6px; }
@keyframes pf-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes pf-pop { from { opacity: 0; transform: translateY(8px) scale(.98); } to { opacity: 1; transform: none; } }
[data-theme="dark"] .pf-modal { background: var(--bolso-card); border-color: var(--dx-border); }
[data-theme="dark"] .pf-field input { background: rgba(255, 255, 255, .03); border-color: var(--dx-border); color: var(--dx-ink); }
.pf-field input[type=text] { letter-spacing: .04em; }

/* zona de perigo (apagar todos os dados) */
.pf-danger { border-color: #F6D6D6; }
[data-theme="dark"] .pf-danger { border-color: rgba(251, 113, 133, .26); }
.pf-ic-danger { background: var(--bolso-vermelho-tint); color: var(--bolso-vermelho); }
.pf-danger-btn { display: inline-flex; align-items: center; gap: 8px; padding: 11px 18px; border-radius: 12px;
    font-weight: 700; font-size: 14px; color: var(--bolso-vermelho); background: var(--bolso-vermelho-tint);
    border: 1px solid transparent; cursor: pointer; transition: .18s; }
.pf-danger-btn:hover { background: var(--bolso-vermelho); color: #fff; box-shadow: 0 8px 20px rgba(239, 68, 68, .25); }
.pf-danger-btn svg { width: 15px; height: 15px; }
.pf-danger-note { font-size: 12.5px; color: var(--bolso-vermelho); background: var(--bolso-vermelho-tint);
    padding: 10px 12px; border-radius: 10px; margin-bottom: 14px; }
[data-theme="dark"] .pf-danger-note { background: rgba(251, 113, 133, .12); color: #FB7185; }
.pf-btn-danger { display: inline-flex; align-items: center; gap: 7px; padding: 11px 18px; border-radius: 12px;
    font-weight: 700; font-size: 14px; color: #fff; background: var(--bolso-vermelho); border: none; cursor: pointer;
    transition: .18s; box-shadow: 0 8px 18px rgba(239, 68, 68, .28); }
.pf-btn-danger:hover { filter: brightness(.95); }
.pf-btn-danger:disabled { opacity: .5; cursor: default; box-shadow: none; }

/* dark */
[data-theme="dark"] .plan-badge.premium { background: rgba(245, 166, 35, .18); color: #F0CE6B; }
[data-theme="dark"] .pf-premium { background: rgba(245, 166, 35, .10); border-color: rgba(245, 166, 35, .32); }
[data-theme="dark"] .pf-premium-sub, [data-theme="dark"] .pf-bs { color: #C9B68A; }
[data-theme="dark"] .pf-bt, [data-theme="dark"] .pf-premium-title { color: var(--dx-ink); }
[data-theme="dark"] .pf-bcheck { background: rgba(245, 166, 35, .22); color: #F0CE6B; }
[data-theme="dark"] .pf-upsell { background: rgba(124, 58, 237, .12); border-color: rgba(124, 58, 237, .30); }
[data-theme="dark"] .pf-sec-card, [data-theme="dark"] .pf-topt { background: var(--bolso-card); border-color: var(--dx-border); }
[data-theme="dark"] .pf-row { border-color: var(--dx-border); }
[data-theme="dark"] .pf-topt.on { border-color: var(--bolso-roxo-vibrante); box-shadow: 0 0 0 3px rgba(124, 58, 237, .25); }

@media (max-width: 920px) {
    .pf-benefits { grid-template-columns: repeat(2, 1fr); }
    .pf-sec-grid { grid-template-columns: repeat(2, 1fr); }
    .pf-hero { flex-wrap: wrap; }
    .pf-hero-actions { align-items: flex-start; width: 100%; flex-direction: row; justify-content: space-between; }
}
@media (max-width: 560px) {
    .pf-themes, .pf-sec-grid, .pf-benefits { grid-template-columns: 1fr; }
    .pf-premium-illus { display: none; }
    .pf-upsell .pf-premium-foot { flex-direction: column; align-items: stretch; }
}

/* ============================================================
   PAINEL ADMIN (backoffice) — Dashboard. Prefixo .adm-*.
   Usa os tokens --bolso-* (tema escuro funciona automaticamente).
   ============================================================ */

/* Shell: sidebar fixa + conteúdo */
.adm-shell { display: flex; min-height: 100vh; background: #F8FAFC; color: var(--bolso-texto); font-family: var(--fonte); }
[data-theme="dark"] .adm-shell { background: #0E1422; }

/* ---- Sidebar ---- */
.adm-side { width: 250px; flex-shrink: 0; background: var(--bolso-card); border-right: 1px solid var(--bolso-linha);
    display: flex; flex-direction: column; position: sticky; top: 0; height: 100vh; }
.adm-brand { display: flex; align-items: center; gap: 10px; padding: 20px 18px 20px 22px; }
.adm-logo-img { height: 30px; width: auto; max-width: 100%; display: block; }
.adm-admin-tag { font-size: 10px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase;
    color: var(--bolso-roxo-vibrante); background: var(--bolso-roxo-tint); padding: 3px 8px; border-radius: 999px; }
/* Botão de alternar tema (claro/escuro) — ao lado da logo */
.adm-theme-toggle { margin-left: auto; flex-shrink: 0; display: inline-grid; place-items: center;
    width: 36px; height: 36px; border-radius: 10px; border: 1px solid var(--bolso-linha);
    background: var(--bolso-fundo); color: var(--bolso-texto-2); cursor: pointer; transition: .15s var(--ease); }
.adm-theme-toggle:hover { color: var(--bolso-roxo-vibrante); border-color: var(--bolso-roxo-vibrante); }
.adm-theme-toggle .th-ic { display: inline-flex; }
.adm-theme-toggle .th-sun { display: none; }
[data-theme="dark"] .adm-theme-toggle .th-sun { display: inline-flex; }
[data-theme="dark"] .adm-theme-toggle .th-moon { display: none; }
.adm-logo-mark { display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: 10px;
    background: linear-gradient(135deg, var(--bolso-roxo-vibrante), var(--bolso-roxo-medio)); color: #fff; }
.adm-logo-txt { font-weight: 800; font-size: 17px; letter-spacing: -.3px; line-height: 1.05; }
.adm-logo-txt .plus { color: var(--bolso-roxo-vibrante); }
.adm-logo-txt small { display: block; font-size: 10px; font-weight: 700; letter-spacing: .14em;
    text-transform: uppercase; color: var(--bolso-texto-2); margin-top: 1px; }

.adm-back { display: inline-flex; align-items: center; gap: 9px; margin: 0 14px 4px; padding: 10px 13px; border-radius: 11px;
    font-size: 13.5px; font-weight: 700; color: var(--bolso-texto-2); text-decoration: none;
    border: 1px solid var(--bolso-linha); background: var(--bolso-fundo); transition: background .15s, color .15s, border-color .15s; }
.adm-back:hover { background: var(--bolso-roxo-tint); color: var(--bolso-roxo-vibrante); border-color: #DDD6FE; }

.adm-nav { display: flex; flex-direction: column; gap: 2px; padding: 10px 12px; flex: 1; overflow-y: auto; }
.adm-nav-item { display: flex; align-items: center; gap: 11px; padding: 10px 12px; border-radius: 11px;
    font-size: 14px; font-weight: 600; color: var(--bolso-texto-2); text-decoration: none; cursor: pointer;
    transition: background .15s var(--ease), color .15s var(--ease); }
.adm-nav-item .adm-nav-ic { display: inline-flex; color: currentColor; }
.adm-nav-item:hover { background: var(--bolso-roxo-tint); color: var(--bolso-roxo-vibrante); }
.adm-nav-item.active { background: var(--bolso-roxo-vibrante); color: #fff; box-shadow: 0 6px 16px rgba(109, 53, 255, .28); }
.adm-nav-item.disabled { cursor: default; opacity: .55; }
.adm-nav-item.disabled:hover { background: transparent; color: var(--bolso-texto-2); }
.adm-soon { margin-left: auto; font-size: 9px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase;
    background: var(--bolso-linha); color: var(--bolso-texto-2); padding: 2px 7px; border-radius: 999px; }

.adm-side-foot { border-top: 1px solid var(--bolso-linha); padding: 14px 12px; display: flex; flex-direction: column; gap: 10px; }
.adm-op { display: flex; align-items: center; gap: 10px; padding: 2px 6px; min-width: 0; }
.adm-op-av { display: inline-grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; flex-shrink: 0;
    background: linear-gradient(135deg, var(--bolso-roxo-vibrante), var(--bolso-roxo-medio)); color: #fff; font-weight: 800; font-size: 15px; }
.adm-op-meta { display: flex; flex-direction: column; min-width: 0; }
.adm-op-nm { font-weight: 700; font-size: 13.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.adm-op-em { font-size: 11.5px; color: var(--bolso-texto-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.adm-logout-form { margin: 0; }
.adm-logout { width: 100%; display: flex; align-items: center; justify-content: center; gap: 8px; padding: 9px 12px;
    border: 1px solid var(--bolso-linha); background: transparent; border-radius: 11px; color: var(--bolso-texto-2);
    font-weight: 700; font-size: 13px; cursor: pointer; transition: .15s var(--ease); }
.adm-logout:hover { border-color: var(--bolso-vermelho); color: var(--bolso-vermelho); background: var(--bolso-vermelho-tint); }

/* ---- Conteúdo ---- */
.adm-main { flex: 1; min-width: 0; padding: 18px 26px 24px; }
.adm-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 16px; flex-wrap: wrap; }
.adm-title { font-size: 21px; font-weight: 800; letter-spacing: -.5px; margin: 0; }
.adm-sub { margin: 3px 0 0; font-size: 13px; color: var(--bolso-texto-2); }
.adm-role { display: inline-flex; align-items: center; gap: 8px; padding: 7px 14px; border-radius: 999px; font-size: 12.5px; font-weight: 700; }
.adm-role-dot { width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.adm-role-admin { background: var(--bolso-roxo-tint); color: var(--bolso-roxo-vibrante); }
.adm-role-support { background: var(--bolso-azul-tint); color: var(--bolso-azul); }

/* ---- Grid de cards: 4 / 2 / 1 ---- */
.adm-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; align-items: start; }
@media (max-width: 1180px) { .adm-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .adm-grid { grid-template-columns: 1fr; } }

/* ---- Card de métrica ---- */
.adm-card { background: var(--bolso-card); border: 1px solid var(--bolso-linha); border-radius: 18px; padding: 20px;
    box-shadow: 0 1px 2px rgba(16, 24, 40, .04); display: flex; flex-direction: column; min-height: 100%;
    transition: transform .18s var(--ease), box-shadow .18s var(--ease); }
.adm-card:hover { transform: translateY(-3px); box-shadow: 0 14px 30px rgba(16, 24, 40, .10); }
.adm-card-head { display: flex; align-items: center; gap: 10px; margin-bottom: 11px; }
.adm-card-ic { display: inline-grid; place-items: center; width: 40px; height: 40px; border-radius: 12px; flex-shrink: 0; }
.adm-card-title { font-size: 15px; font-weight: 700; margin: 0; color: var(--bolso-texto); }
.adm-hero { margin-bottom: 10px; }
.adm-hero-val { display: block; font-size: 30px; font-weight: 800; letter-spacing: -.6px; line-height: 1.05; color: var(--bolso-texto); }
.adm-hero-label { display: block; margin-top: 3px; font-size: 12px; color: var(--bolso-texto-2); }
.adm-card-body { display: flex; flex-direction: column; gap: 1px; border-top: 1px solid var(--bolso-linha); padding-top: 6px; margin-top: auto; }
.adm-plan-acts { display: flex; gap: 10px; margin-top: 14px; flex-wrap: wrap; }
.adm-card-off { opacity: .6; }
.adm-card-off .adm-card-ic { filter: grayscale(.65); }

/* ---- Item de métrica ---- */
.adm-metric { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 5px 0; }
.adm-metric-label { font-size: 13px; color: var(--bolso-texto-2); }
.adm-metric-value { font-size: 14px; font-weight: 700; color: var(--bolso-texto); }

/* ---- Badge de status (pílula colorida) ---- */
.adm-badge { display: inline-block; padding: 3px 11px; border-radius: 999px; font-size: 12px; font-weight: 700; line-height: 1.45; }
.adm-badge-green { background: var(--bolso-verde-tint); color: var(--green-deep); }
.adm-badge-red { background: var(--bolso-vermelho-tint); color: var(--bolso-vermelho); }
.adm-badge-purple { background: var(--bolso-roxo-tint); color: var(--bolso-roxo-vibrante); }
.adm-badge-amber { background: var(--bolso-laranja-tint); color: #B45309; }
.adm-badge-blue { background: var(--bolso-azul-tint); color: var(--bolso-azul); }
.adm-badge-gray { background: var(--bolso-linha); color: var(--bolso-texto-2); }

/* ---- Skeleton de carregamento ---- */
.adm-sk { position: relative; overflow: hidden; background: var(--bolso-linha); border-radius: 8px; }
.adm-sk::after { content: ""; position: absolute; inset: 0; transform: translateX(-100%);
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .55), transparent); animation: admShimmer 1.3s infinite; }
[data-theme="dark"] .adm-sk::after { background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .07), transparent); }
@keyframes admShimmer { 100% { transform: translateX(100%); } }
.adm-sk-ic { width: 40px; height: 40px; border-radius: 12px; }
.adm-sk-title { width: 90px; height: 14px; }
.adm-sk-hero { width: 62%; height: 30px; margin-bottom: 16px; border-radius: 10px; }
.adm-sk-row { height: 14px; margin: 9px 0; }
.adm-sk-row:nth-child(odd) { width: 78%; }

/* ---- Banner de erro ---- */
.adm-error { display: flex; align-items: flex-start; gap: 12px; padding: 15px 18px; margin-bottom: 20px;
    background: var(--bolso-vermelho-tint); border: 1px solid rgba(255, 59, 79, .25); border-radius: 14px; color: var(--bolso-vermelho); }
.adm-error-ic { display: inline-flex; margin-top: 1px; flex-shrink: 0; }
.adm-error-txt { display: flex; flex-direction: column; gap: 2px; }
.adm-error-txt strong { font-size: 14px; }
.adm-error-txt > span { font-size: 13px; color: var(--bolso-texto); }
.adm-error-trace { font-size: 12px; color: var(--bolso-texto-2) !important; }
.adm-error-trace code { font-family: ui-monospace, "Cascadia Code", monospace; background: rgba(0, 0, 0, .05); padding: 1px 5px; border-radius: 5px; }
.adm-retry { margin-left: auto; align-self: center; border: 1px solid var(--bolso-vermelho); background: transparent; color: var(--bolso-vermelho);
    font-weight: 700; font-size: 12.5px; padding: 7px 14px; border-radius: 10px; cursor: pointer; white-space: nowrap; transition: .15s var(--ease); }
.adm-retry:hover { background: var(--bolso-vermelho); color: #fff; }

/* ---- Acesso restrito (403) ---- */
.adm-restricted { text-align: center; max-width: 440px; margin: 56px auto; padding: 38px 28px;
    background: var(--bolso-card); border: 1px solid var(--bolso-linha); border-radius: 18px; box-shadow: 0 1px 2px rgba(16, 24, 40, .04); }
.adm-restricted-ic { display: inline-grid; place-items: center; width: 64px; height: 64px; border-radius: 16px;
    background: var(--bolso-vermelho-tint); color: var(--bolso-vermelho); margin-bottom: 16px; }
.adm-restricted h2 { font-size: 20px; font-weight: 800; margin: 0 0 8px; }
.adm-restricted p { font-size: 14px; color: var(--bolso-texto-2); margin: 0; line-height: 1.55; }

/* entrada suave dos cards */
.adm-grid .reveal { animation: admUp .4s var(--ease) both; }
.adm-grid .reveal:nth-child(2) { animation-delay: .05s; }
.adm-grid .reveal:nth-child(3) { animation-delay: .1s; }
.adm-grid .reveal:nth-child(4) { animation-delay: .15s; }
@keyframes admUp { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .adm-grid .reveal { animation: none; } .adm-sk::after { animation: none; } }

/* responsivo: a sidebar vira faixa superior em telas estreitas */
@media (max-width: 860px) {
    .adm-shell { flex-direction: column; }
    .adm-side { width: 100%; height: auto; position: static; flex-direction: row; flex-wrap: wrap; align-items: center; gap: 8px 0; }
    .adm-brand { padding: 14px 18px; }
    .adm-nav { flex-direction: row; flex-wrap: wrap; flex: 1 1 100%; order: 3; border-top: 1px solid var(--bolso-linha); }
    .adm-nav-item { padding: 8px 11px; }
    .adm-soon { display: none; }
    .adm-side-foot { border-top: none; padding: 12px 18px; flex-direction: row; align-items: center; margin-left: auto; }
    .adm-logout { width: auto; }
    .adm-logout span { display: none; }
    .adm-main { padding: 22px 18px 36px; }
}

/* ============================================================
   PAINEL ADMIN — listas, filtros, formulários, modal, detalhe.
   ============================================================ */

/* Voltar / breadcrumb */
.adm-back { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 600;
    color: var(--bolso-texto-2); text-decoration: none; margin-bottom: 12px; }
.adm-back:hover { color: var(--bolso-roxo-vibrante); }

/* Painel branco genérico (envolve tabelas e detalhes) */
.adm-panel { background: var(--bolso-card); border: 1px solid var(--bolso-linha); border-radius: 16px;
    box-shadow: 0 1px 2px rgba(16, 24, 40, .04); overflow: hidden; }
.adm-panel-pad { padding: 20px 22px; }

/* Barra de filtros / ações da lista */
.adm-toolbar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 16px; }
.adm-toolbar .adm-spacer { flex: 1; }

/* Inputs */
.adm-input, .adm-select { height: 38px; padding: 0 12px; border-radius: 10px; border: 1px solid var(--bolso-linha);
    background: var(--bolso-card); color: var(--bolso-texto); font-size: 14px; font-family: inherit; transition: border-color .15s var(--ease); }
.adm-input:focus, .adm-select:focus { outline: none; border-color: var(--bolso-roxo-vibrante); }
.adm-select { cursor: pointer; padding-right: 30px; }
.adm-search { position: relative; }
.adm-search .adm-input { padding-left: 36px; min-width: 240px; }
.adm-search .adm-search-ic { position: absolute; left: 11px; top: 50%; transform: translateY(-50%); color: var(--bolso-texto-2); display: inline-flex; pointer-events: none; }
textarea.adm-input { height: auto; min-height: 88px; padding: 10px 12px; resize: vertical; line-height: 1.5; }

/* Botões */
.adm-btn { display: inline-flex; align-items: center; justify-content: center; gap: 7px; height: 38px; padding: 0 16px;
    border-radius: 10px; border: none; background: var(--bolso-roxo-vibrante); color: #fff; font-weight: 700; font-size: 13.5px;
    font-family: inherit; cursor: pointer; transition: filter .15s var(--ease), opacity .15s; white-space: nowrap; }
.adm-btn:hover { filter: brightness(1.06); }
.adm-btn:disabled { opacity: .55; cursor: not-allowed; }
.adm-btn.danger { background: var(--bolso-vermelho); }
.adm-btn-ghost { display: inline-flex; align-items: center; justify-content: center; gap: 7px; height: 38px; padding: 0 14px;
    border-radius: 10px; border: 1px solid var(--bolso-linha); background: var(--bolso-card); color: var(--bolso-texto);
    font-weight: 700; font-size: 13.5px; font-family: inherit; cursor: pointer; transition: .15s var(--ease); white-space: nowrap; }
.adm-btn-ghost:hover { border-color: var(--bolso-chevron, var(--bolso-texto-2)); background: var(--bolso-fundo); }
.adm-btn-ghost:disabled { opacity: .5; cursor: not-allowed; }
.adm-btn-ghost.danger { color: var(--bolso-vermelho); }
.adm-btn-ghost.danger:hover { border-color: var(--bolso-vermelho); background: var(--bolso-vermelho-tint); }
.adm-btn-sm { height: 32px; padding: 0 11px; font-size: 12.5px; border-radius: 9px; }

/* Tabela */
.adm-table-wrap { overflow-x: auto; }
.adm-table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.adm-table thead th { text-align: left; font-size: 11.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em;
    color: var(--bolso-texto-2); padding: 12px 16px; border-bottom: 1px solid var(--bolso-linha); white-space: nowrap; background: var(--bolso-card); }
.adm-table tbody td { padding: 13px 16px; border-bottom: 1px solid var(--bolso-linha); vertical-align: middle; }
.adm-table tbody tr:last-child td { border-bottom: none; }
.adm-table tbody tr.clickable { cursor: pointer; transition: background .12s var(--ease); }
.adm-table tbody tr.clickable:hover { background: var(--bolso-roxo-tint); }
.adm-table .col-num { text-align: right; font-variant-numeric: tabular-nums; }
.adm-cell-main { font-weight: 700; color: var(--bolso-texto); }
.adm-cell-sub { font-size: 12px; color: var(--bolso-texto-2); }
.adm-cell-actions { display: flex; gap: 6px; justify-content: flex-end; }

/* Avatar pequeno em célula */
.adm-ava { display: inline-grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; flex-shrink: 0;
    background: linear-gradient(135deg, var(--bolso-roxo-vibrante), var(--bolso-roxo-medio)); color: #fff; font-weight: 800; font-size: 13px; }
.adm-id-cell { display: flex; align-items: center; gap: 11px; }

/* Paginação */
.adm-pager { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 18px; border-top: 1px solid var(--bolso-linha); flex-wrap: wrap; }
.adm-pager-info { font-size: 12.5px; color: var(--bolso-texto-2); }
.adm-pager-right { display: inline-flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.adm-pager-size { display: inline-flex; align-items: center; gap: 7px; font-size: 12.5px; color: var(--bolso-texto-2); }
.adm-pager-size select { height: 34px; border-radius: 9px; border: 1px solid var(--bolso-linha); background: var(--bolso-card); color: var(--bolso-texto); font-size: 13px; font-weight: 700; padding: 0 8px; cursor: pointer; }
.adm-pager-btns { display: flex; gap: 8px; }
.adm-pager-btn { height: 34px; padding: 0 14px; border-radius: 9px; border: 1px solid var(--bolso-linha); background: var(--bolso-card);
    color: var(--bolso-texto); font-weight: 600; font-size: 13px; cursor: pointer; transition: .15s var(--ease); }
.adm-pager-btn:hover:not(:disabled) { border-color: var(--bolso-roxo-vibrante); color: var(--bolso-roxo-vibrante); }
.adm-pager-btn:disabled { opacity: .45; cursor: not-allowed; }

/* Estado vazio */
.adm-empty { text-align: center; padding: 48px 20px; color: var(--bolso-texto-2); font-size: 14px; }
.adm-empty-ic { display: inline-grid; place-items: center; width: 52px; height: 52px; border-radius: 14px;
    background: var(--bolso-fundo); color: var(--bolso-texto-2); margin-bottom: 12px; }

/* Feedback de sucesso (pós-ação) */
.adm-feedback { display: flex; align-items: center; gap: 10px; padding: 12px 16px; margin-bottom: 18px;
    background: var(--bolso-verde-tint); border: 1px solid rgba(46, 204, 113, .3); border-radius: 12px; color: var(--green-deep); font-size: 13.5px; font-weight: 600; }
.adm-feedback .adm-fb-ic { display: inline-flex; }

/* Skeleton genérico de linha (listas) */
.adm-sk-rows { padding: 14px 18px; }
.adm-sk-rows .adm-sk { height: 16px; margin: 14px 0; }
.adm-sk-rows .adm-sk:nth-child(odd) { width: 70%; }

/* ---- Modal ---- */
.adm-scrim { position: fixed; inset: 0; background: rgba(16, 16, 30, .5); backdrop-filter: blur(2px);
    display: grid; place-items: center; padding: 20px; z-index: 1000; animation: admFade .15s var(--ease); }
.adm-modal { width: 100%; max-width: 460px; background: var(--bolso-card); border: 1px solid var(--bolso-linha);
    border-radius: 18px; box-shadow: var(--shadow-lg, 0 24px 60px rgba(16, 24, 40, .25)); overflow: hidden; animation: admUp .2s var(--ease) both;
    max-height: 92vh; display: flex; flex-direction: column; }
.adm-modal-head { display: flex; align-items: center; gap: 12px; padding: 20px 22px 8px; flex-shrink: 0; }
.adm-modal-head h3 { margin: 0; font-size: 17px; font-weight: 800; }
.adm-modal-ic { display: inline-grid; place-items: center; width: 40px; height: 40px; border-radius: 12px; flex-shrink: 0;
    background: var(--bolso-roxo-tint); color: var(--bolso-roxo-vibrante); }
.adm-modal-ic.danger { background: var(--bolso-vermelho-tint); color: var(--bolso-vermelho); }
.adm-modal-body { padding: 6px 22px 8px; flex: 1 1 auto; min-height: 0; overflow-y: auto; }
.adm-modal-body p { margin: 0 0 12px; font-size: 14px; color: var(--bolso-texto-2); line-height: 1.55; }
.adm-confirm-type { display: block; font-size: 13px; color: var(--bolso-texto-2); margin-top: 6px; }
.adm-confirm-type .adm-input { display: block; width: 100%; margin-top: 6px; }
.adm-modal-foot { display: flex; justify-content: flex-end; gap: 10px; padding: 14px 22px 20px; flex-shrink: 0; }

/* ---- Detalhe (usuário / grupo) ---- */
.adm-detail-head { display: flex; align-items: center; gap: 16px; margin-bottom: 22px; flex-wrap: wrap; }
.adm-detail-ava { display: inline-grid; place-items: center; width: 60px; height: 60px; border-radius: 16px; flex-shrink: 0;
    background: linear-gradient(135deg, var(--bolso-roxo-vibrante), var(--bolso-roxo-medio)); color: #fff; font-weight: 800; font-size: 26px; }
.adm-detail-id h1 { margin: 0; font-size: 22px; font-weight: 800; letter-spacing: -.4px; }
.adm-detail-id .sub { margin: 3px 0 0; font-size: 14px; color: var(--bolso-texto-2); }
.adm-detail-actions { margin-left: auto; display: flex; gap: 8px; flex-wrap: wrap; }
.adm-detail-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 20px; align-items: start; }
@media (max-width: 920px) { .adm-detail-grid { grid-template-columns: 1fr; } }
.adm-section-title { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--bolso-texto-2); margin: 0 0 12px; }
.adm-kv { display: flex; justify-content: space-between; gap: 14px; padding: 9px 0; border-bottom: 1px solid var(--bolso-linha); font-size: 13.5px; }
.adm-kv:last-child { border-bottom: none; }
.adm-kv-k { color: var(--bolso-texto-2); }
.adm-kv-v { font-weight: 600; color: var(--bolso-texto); text-align: right; }

/* ---- Formulário (plano / push) ---- */
.adm-form { display: flex; flex-direction: column; gap: 16px; }
.adm-form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 640px) { .adm-form-grid { grid-template-columns: 1fr; } }
.adm-field { display: flex; flex-direction: column; gap: 6px; }
.adm-field.full { grid-column: 1 / -1; }
.adm-label { font-size: 12.5px; font-weight: 700; color: var(--bolso-texto); }
.adm-field .adm-input, .adm-field .adm-select { width: 100%; }
.adm-help { font-size: 11.5px; color: var(--bolso-texto-2); }
.adm-flags { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
@media (max-width: 640px) { .adm-flags { grid-template-columns: 1fr; } }
.adm-flag { display: flex; align-items: center; gap: 9px; padding: 11px 13px; border: 1px solid var(--bolso-linha); border-radius: 11px; font-size: 13.5px; font-weight: 600; cursor: pointer; }
.adm-flag input { width: 17px; height: 17px; accent-color: var(--bolso-roxo-vibrante); cursor: pointer; }
.adm-days { display: flex; flex-wrap: wrap; gap: 8px; }
.adm-day { display: inline-flex; align-items: center; justify-content: center; min-width: 44px; height: 38px; padding: 0 10px;
    border: 1px solid var(--bolso-linha); border-radius: 10px; font-size: 13px; font-weight: 700; cursor: pointer; user-select: none; transition: .12s var(--ease); }
.adm-day.on { background: var(--bolso-roxo-vibrante); border-color: var(--bolso-roxo-vibrante); color: #fff; }
.adm-form-foot { display: flex; justify-content: flex-end; gap: 10px; }
.adm-form-error { color: var(--bolso-vermelho); font-size: 13px; font-weight: 600; }

/* mudanças de auditoria (JSON) */
.adm-changes { font-family: ui-monospace, "Cascadia Code", monospace; font-size: 11.5px; white-space: pre-wrap; word-break: break-word;
    background: var(--bolso-fundo); border: 1px solid var(--bolso-linha); border-radius: 8px; padding: 8px 10px; margin: 6px 0 0; max-height: 180px; overflow: auto; color: var(--bolso-texto-2); }

@keyframes admFade { from { opacity: 0; } to { opacity: 1; } }

[data-theme="dark"] .adm-search .adm-input,
[data-theme="dark"] .adm-input, [data-theme="dark"] .adm-select { background: var(--bolso-card); border-color: var(--dx-border, var(--bolso-linha)); }
[data-theme="dark"] .adm-changes { background: rgba(255, 255, 255, .03); }

/* Cabeçalho do dashboard: ações à direita + timestamp */
.adm-head-right { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.adm-updated { font-size: 12px; color: var(--bolso-texto-2); white-space: nowrap; }

/* Chip de tendência período-a-período (últimos 30d vs. 30d anteriores) */
.adm-trend { display: inline-flex; align-items: center; gap: 4px; margin-top: 9px; padding: 3px 9px; border-radius: 999px;
    font-size: 11.5px; font-weight: 700; line-height: 1.4; }
.adm-trend-up { background: var(--bolso-verde-tint); color: var(--green-deep); }
.adm-trend-down { background: var(--bolso-vermelho-tint); color: var(--bolso-vermelho); }
.adm-trend-flat { background: var(--bolso-linha); color: var(--bolso-texto-2); }

/* ============================================================
   DASHBOARD ADMIN — acabamento premium (sobrescreve o básico).
   Paleta: primária #6D3CF6 · fundo #F8F9FC · borda #ECECF4.
   ============================================================ */
.adm-shell { background: #F8F9FC; }
[data-theme="dark"] .adm-shell { background: #0E1422; }

/* Sidebar */
.adm-side { width: 240px; border-right: 1px solid #ECECF4; }
[data-theme="dark"] .adm-side { border-right-color: var(--bolso-linha); }
.adm-nav-item { border-radius: 14px; }
.adm-nav-item:hover { background: #F4F5FA; color: var(--bolso-texto); }
.adm-nav-item.active, .adm-nav-item.active:hover { background: linear-gradient(135deg, #7B45FF, #6D3CF6); color: #fff; box-shadow: 0 8px 20px rgba(109, 60, 246, .30); }
[data-theme="dark"] .adm-nav-item:hover { background: rgba(255, 255, 255, .05); color: var(--bolso-texto); }

/* Cabeçalho leve */
.adm-role-admin { background: #F3EEFF; color: #6D3CF6; }
.adm-updated { display: inline-flex; align-items: center; gap: 6px; }

/* Cards principais */
.adm-grid { gap: 16px; align-items: stretch; }
.adm-card { border: 1px solid #ECECF4; border-radius: 16px; padding: 18px; box-shadow: 0 8px 30px rgba(15, 23, 42, .04); }
.adm-card:hover { transform: translateY(-2px); box-shadow: 0 18px 45px rgba(15, 23, 42, .08); }
[data-theme="dark"] .adm-card { border-color: var(--bolso-linha); box-shadow: 0 1px 2px rgba(0, 0, 0, .3); }
.adm-card-ic { width: 40px; height: 40px; border-radius: 12px; }
.adm-card-ic.tint-purple { background: #F3EEFF; color: #6D3CF6; }
.adm-card-ic.tint-blue { background: #EEF5FF; color: #3B82F6; }
.adm-card-ic.tint-green { background: #EAFBF3; color: #22C55E; }
.adm-card-ic.tint-orange { background: #FFF4E9; color: #F59E0B; }
[data-theme="dark"] .adm-card-ic.tint-purple { background: rgba(109, 60, 246, .18); }
[data-theme="dark"] .adm-card-ic.tint-blue { background: rgba(59, 130, 246, .18); }
[data-theme="dark"] .adm-card-ic.tint-green { background: rgba(34, 197, 94, .18); }
[data-theme="dark"] .adm-card-ic.tint-orange { background: rgba(245, 158, 11, .18); }
.adm-card-title { font-size: 14.5px; font-weight: 600; }
.adm-hero-val { font-size: 27px; font-weight: 700; letter-spacing: -.6px; }

/* Seção 2 colunas (gráfico + recentes) */
.adm-dash-2col { display: grid; grid-template-columns: 1.6fr 1fr; gap: 16px; margin-top: 16px; align-items: start; }
@media (max-width: 1100px) { .adm-dash-2col { grid-template-columns: 1fr; } }
.adm-panel { border-color: #ECECF4; border-radius: 16px; box-shadow: 0 8px 30px rgba(15, 23, 42, .04); }
[data-theme="dark"] .adm-panel { border-color: var(--bolso-linha); box-shadow: none; }
.adm-panel-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.adm-panel-title { font-size: 15px; font-weight: 700; margin: 0; }
.adm-period { font-size: 12.5px; font-weight: 600; color: var(--bolso-texto-2); background: #F4F5FA; border: 1px solid #ECECF4; padding: 6px 12px; border-radius: 10px; }
[data-theme="dark"] .adm-period { background: rgba(255, 255, 255, .04); border-color: var(--bolso-linha); }
.adm-link { font-size: 13px; font-weight: 600; color: #6D3CF6; text-decoration: none; }
.adm-link:hover { text-decoration: underline; }

/* Gráfico SVG */
.adm-chart { width: 100%; height: auto; display: block; }
.adm-chart-grid { stroke: #EEF0F6; stroke-width: 1; }
[data-theme="dark"] .adm-chart-grid { stroke: rgba(255, 255, 255, .07); }
.adm-chart-ylab, .adm-chart-xlab { fill: var(--bolso-texto-2); font-size: 11px; font-weight: 500; font-family: var(--fonte); }
.adm-chart-cur { stroke: #6D3CF6; stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round; }
.adm-chart-prev { stroke: #C9B8FB; stroke-width: 2; stroke-dasharray: 5 5; stroke-linecap: round; }
.adm-chart-dot { fill: #6D3CF6; stroke: #fff; stroke-width: 2; }
[data-theme="dark"] .adm-chart-dot { stroke: var(--bolso-card); }
.adm-legend { display: flex; gap: 20px; margin: 8px 0 2px; flex-wrap: wrap; }
.adm-leg { display: inline-flex; align-items: center; gap: 7px; font-size: 12.5px; color: var(--bolso-texto-2); }
.adm-leg-dot { width: 16px; height: 3px; border-radius: 2px; display: inline-block; }
.adm-leg-dot.cur { background: #6D3CF6; }
.adm-leg-dot.prev { background: #C9B8FB; }

/* Mini KPIs */
.adm-mini-kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-top: 12px; }
@media (max-width: 720px) { .adm-mini-kpis { grid-template-columns: repeat(2, 1fr); } }
.adm-mini { display: flex; align-items: center; gap: 11px; height: 58px; padding: 0 13px; border-radius: 14px; background: var(--bolso-card); border: 1px solid #F1F2F7; }
[data-theme="dark"] .adm-mini { border-color: var(--bolso-linha); background: rgba(255, 255, 255, .02); }
.adm-mini-ic { display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: 10px; flex-shrink: 0; }
.adm-mini-val { font-size: 17px; font-weight: 700; color: var(--bolso-texto); letter-spacing: -.3px; }
.adm-mini-lbl { font-size: 11.5px; color: var(--bolso-texto-2); margin-top: 1px; }

/* Atividades recentes */
.adm-acts { display: flex; flex-direction: column; }
.adm-act { display: flex; align-items: center; gap: 12px; padding: 9px 8px; border-radius: 11px; transition: background .12s var(--ease); }
.adm-act:not(:last-child) { border-bottom: 1px solid var(--bolso-linha); }
.adm-act:hover { background: #FAFAFC; }
[data-theme="dark"] .adm-act:hover { background: rgba(255, 255, 255, .03); }
.adm-act-ic { display: inline-grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; flex-shrink: 0; }
.adm-act-body { flex: 1; min-width: 0; }
.adm-act-title { font-size: 13.5px; font-weight: 600; color: var(--bolso-texto); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.adm-act-sub { font-size: 12px; color: var(--bolso-texto-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.adm-act-time { font-size: 11.5px; color: var(--bolso-texto-2); white-space: nowrap; flex-shrink: 0; }

/* Dica de administrador */
.adm-tip { display: flex; align-items: center; gap: 16px; margin-top: 24px; padding: 22px 26px; border-radius: 22px;
    background: linear-gradient(90deg, #F4F0FF, #FAF9FF); border: 1px solid #ECECF4; }
[data-theme="dark"] .adm-tip { background: linear-gradient(90deg, rgba(109, 60, 246, .12), rgba(109, 60, 246, .04)); border-color: var(--bolso-linha); }
.adm-tip-ic { display: inline-grid; place-items: center; width: 46px; height: 46px; border-radius: 14px; background: #fff; color: #6D3CF6; flex-shrink: 0; box-shadow: 0 4px 14px rgba(109, 60, 246, .14); }
[data-theme="dark"] .adm-tip-ic { background: rgba(255, 255, 255, .06); }
.adm-tip-txt { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.adm-tip-txt strong { font-size: 14.5px; color: var(--bolso-texto); }
.adm-tip-txt span { font-size: 13px; color: var(--bolso-texto-2); }
.adm-tip .adm-btn-ghost { background: #fff; }
[data-theme="dark"] .adm-tip .adm-btn-ghost { background: var(--bolso-card); }

/* ============================================================
   COESÃO PREMIUM — listas, tabelas, formulários, detalhe, modal.
   Alinha as telas internas ao acabamento do dashboard.
   ============================================================ */

/* Tabelas mais arejadas e limpas */
.adm-table thead th { padding: 13px 18px; border-bottom-color: #ECECF4; }
.adm-table tbody td { padding: 15px 18px; border-bottom-color: #F1F2F7; }
.adm-table tbody tr.clickable:hover { background: #FAFAFC; }
[data-theme="dark"] .adm-table thead th { border-bottom-color: var(--bolso-linha); }
[data-theme="dark"] .adm-table tbody td { border-bottom-color: var(--bolso-linha); }
[data-theme="dark"] .adm-table tbody tr.clickable:hover { background: rgba(255, 255, 255, .03); }

/* Pílulas de status no padrão do spec */
.adm-badge { padding: 4px 11px; font-weight: 600; }

/* Inputs / selects / busca / paginação: borda e foco do dashboard */
.adm-input, .adm-select, .adm-pager-btn { border-color: #ECECF4; }
.adm-input:focus, .adm-select:focus { border-color: #6D3CF6; box-shadow: 0 0 0 3px rgba(109, 60, 246, .12); }
.adm-pager-btn:hover:not(:disabled) { border-color: #6D3CF6; color: #6D3CF6; }
[data-theme="dark"] .adm-input, [data-theme="dark"] .adm-select, [data-theme="dark"] .adm-pager-btn { border-color: var(--bolso-linha); }

/* Botões e links na cor primária do dashboard (#6D3CF6) */
.adm-btn { background: #6D3CF6; }
.adm-btn:hover { filter: brightness(1.07); }
.adm-link { color: #6D3CF6; }

/* Avatares e marca no gradiente do dashboard */
.adm-ava, .adm-op-av, .adm-logo-mark, .adm-detail-ava { background: linear-gradient(135deg, #7B45FF, #6D3CF6); }

/* Mais respiro nos painéis e modal mais suave */
.adm-panel-pad { padding: 16px 18px; }
.adm-toolbar { margin-bottom: 18px; }
.adm-modal { border-radius: 20px; }
.adm-feedback { border-radius: 14px; }

/* ============================================================
   PÁGINAS LEGAIS (/termos e /privacidade) — públicas, SSR
   ============================================================ */
.legal-page { min-height: 100vh; background: var(--bg, #F6F4FB); padding: 48px 20px 72px; }
.legal-wrap { max-width: 760px; margin: 0 auto; }
.legal-card { background: var(--card, #fff); border: 1px solid var(--line, #E7E2F5); border-radius: 16px; padding: 40px 44px; box-shadow: 0 8px 30px rgba(60, 40, 120, .06); }
.legal-brand { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 26px; flex-wrap: wrap; }
.legal-brand img { height: 34px; }
.legal-back { font-size: 13.5px; color: var(--primary, #6D28D9); text-decoration: none; font-weight: 600; }
.legal-back:hover { text-decoration: underline; }
.legal-card h1 { font-size: 26px; margin: 0 0 4px; color: var(--ink, #241E4E); letter-spacing: -.02em; }
.legal-version { font-size: 13px; color: var(--muted, #6E6893); margin: 0 0 26px; }
.legal-card h2 { font-size: 17px; margin: 28px 0 8px; color: var(--ink, #241E4E); }
.legal-card p, .legal-card li { font-size: 14.5px; line-height: 1.65; color: #4A4467; }
.legal-card ul { padding-left: 20px; margin: 8px 0; }
.legal-card li { margin-bottom: 5px; }
.legal-note { background: var(--wash, #F1EDFB); border-radius: 10px; padding: 12px 16px; font-size: 13.5px; margin-top: 26px; }
.legal-foot { text-align: center; margin-top: 18px; font-size: 13px; color: var(--muted, #6E6893); }
.legal-foot a { color: var(--primary, #6D28D9); }
[data-theme="dark"] .legal-page { background: #14101F; }
[data-theme="dark"] .legal-card { background: #1D1730; border-color: #2C2547; }
[data-theme="dark"] .legal-card h1, [data-theme="dark"] .legal-card h2 { color: #EDE9FA; }
[data-theme="dark"] .legal-card p, [data-theme="dark"] .legal-card li { color: #B9B2D4; }
[data-theme="dark"] .legal-note { background: #251D3E; }

/* ============================================================
   Esqueci a senha — identidade premium (escopo .fp-stage)
   Dark fixo, independente do tema (design escuro específico).
   ============================================================ */
.fp-stage {
    min-height: 100vh;
    display: flex; align-items: center; justify-content: center;
    padding: 40px 20px;
    background:
        radial-gradient(46% 40% at 50% 33%, rgba(139, 92, 246, .20), rgba(139, 92, 246, 0) 72%),
        linear-gradient(155deg, #070B16 0%, #0B1020 100%) !important;
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
}
.fp-stage .fp-card {
    width: 100%; max-width: 480px;
    padding: 48px;
    border-radius: 28px !important;
    background: rgba(21, 28, 44, .82) !important;
    border: 1px solid rgba(255, 255, 255, .08) !important;
    -webkit-backdrop-filter: blur(16px) saturate(130%);
    backdrop-filter: blur(16px) saturate(130%);
    box-shadow: 0 25px 80px rgba(0, 0, 0, .45) !important;
    text-align: center;
    animation: fpCardIn .5s cubic-bezier(.22, 1, .36, 1) both;
}
@keyframes fpCardIn {
    from { opacity: 0; transform: translateY(14px) scale(.985); }
    to   { opacity: 1; transform: none; }
}
/* ícone superior (cadeado) */
.fp-stage .fp-badge {
    width: 72px; height: 72px; margin: 0 auto 26px;
    display: inline-grid; place-items: center;
    border-radius: 20px; color: #fff;
    background: linear-gradient(155deg, #9C6BFF, #6D28D9);
    box-shadow:
        0 12px 30px rgba(139, 92, 246, .45),
        0 0 0 1px rgba(139, 92, 246, .25),
        inset 0 1px 0 rgba(255, 255, 255, .30),
        inset 0 -3px 8px rgba(0, 0, 0, .28);
    animation: fpBadgeIn .55s cubic-bezier(.22, 1, .36, 1) both;
}
@keyframes fpBadgeIn {
    from { opacity: 0; transform: translateY(-6px) scale(.9); }
    to   { opacity: 1; transform: none; }
}
/* título */
.fp-stage .lg-title {
    font-size: 42px !important; font-weight: 800;
    color: #FFFFFF !important; letter-spacing: -.02em;
    line-height: 1.06; margin: 0; text-align: center;
}
/* descrição */
.fp-stage .lg-welcome {
    font-size: 21px !important; color: #A8B3CF !important;
    line-height: 1.5; margin: 18px auto 0 !important;
    max-width: 30ch; text-align: center;
}
/* form + label */
.fp-stage form { margin-top: 40px; text-align: left; }
.fp-stage .lg-label {
    font-size: 14px !important; font-weight: 600;
    color: rgba(255, 255, 255, .85) !important; margin: 0 0 10px !important;
}
/* campo de e-mail */
.fp-stage .lg-input { margin: 0 !important; }
.fp-stage .lg-input .ic { left: 20px; color: #8B5CF6; }
.fp-stage .lg-input input {
    height: 60px; width: 100%;
    padding: 0 22px 0 52px !important;
    background: #20283C !important;
    border: 1px solid rgba(255, 255, 255, .08) !important;
    border-radius: 18px !important;
    color: #FFFFFF !important; font-size: 16px; font-family: inherit;
    transition: border-color .2s ease, box-shadow .2s ease, background .2s ease;
}
.fp-stage .lg-input input::placeholder { color: #7C86A0 !important; }
.fp-stage .lg-input input:focus {
    outline: none;
    border-color: #8B5CF6 !important;
    background: #232C42 !important;
    box-shadow: 0 0 0 4px rgba(139, 92, 246, .22) !important;
}
/* botão principal */
.fp-stage .lg-btn {
    height: 60px; width: 100%; margin-top: 24px;
    display: inline-flex; align-items: center; justify-content: center; gap: 10px;
    border: none; border-radius: 18px !important; cursor: pointer;
    background: linear-gradient(135deg, #8B5CF6 0%, #6D28D9 100%) !important;
    color: #fff; font-size: 18px; font-weight: 600; font-family: inherit;
    box-shadow: 0 12px 30px rgba(139, 92, 246, .35) !important;
    transition: transform .2s ease, box-shadow .2s ease, filter .2s ease;
}
.fp-stage .lg-btn svg { transition: transform .2s ease; }
.fp-stage .lg-btn:hover {
    transform: translateY(-2px);
    filter: brightness(1.08) saturate(1.06);
    box-shadow: 0 18px 46px rgba(139, 92, 246, .52) !important;
}
.fp-stage .lg-btn:hover svg { transform: translateX(4px); }
.fp-stage .lg-btn:active { transform: translateY(0); }
/* separador "ou" */
.fp-stage .fp-sep {
    display: flex; align-items: center; gap: 16px;
    margin: 34px 0 0; color: #6B7590; font-size: 14px; font-weight: 500;
}
.fp-stage .fp-sep::before, .fp-stage .fp-sep::after {
    content: ""; flex: 1; height: 1px; background: rgba(255, 255, 255, .09);
}
/* link inferior */
.fp-stage .lg-foot { margin: 28px 0 0 !important; text-align: center; }
.fp-stage .lg-foot a {
    color: #8B5CF6 !important; font-weight: 600; font-size: 15px;
    text-decoration: none; transition: color .18s ease;
}
.fp-stage .lg-foot a:hover { color: #FFFFFF !important; }
/* dev-link coeso no dark */
.fp-stage .lg-devlink {
    background: rgba(139, 92, 246, .10) !important;
    border: 1px solid rgba(139, 92, 246, .30) !important;
    color: #C9B6FB !important; border-radius: 14px; margin-top: 4px;
}
.fp-stage .lg-devlink a { color: #A78BFA !important; }
@media (prefers-reduced-motion: reduce) {
    .fp-stage .fp-card, .fp-stage .fp-badge { animation: none; }
    .fp-stage .lg-btn, .fp-stage .lg-btn svg, .fp-stage .lg-input input { transition: none; }
}
@media (max-width: 520px) {
    .fp-stage .fp-card { padding: 34px 24px; }
    .fp-stage .lg-title { font-size: 34px !important; }
    .fp-stage .lg-welcome { font-size: 18px !important; }
}

/* ============================================================
   Confirmação de e-mail (.ec-*) — tela premium (dark), escopada
   ============================================================ */
.ec-stage {
    min-height: 100vh; width: 100%; position: relative; overflow: hidden;
    display: flex; align-items: center; justify-content: center;
    background: linear-gradient(160deg, #060814 0%, #0D1224 100%);
    font-family: 'Inter', -apple-system, "Segoe UI", system-ui, sans-serif;
    -webkit-font-smoothing: antialiased;
}
.ec-glow {
    position: absolute; top: 50%; left: 50%; width: 640px; height: 640px; border-radius: 50%;
    transform: translate(-50%, -64%);
    background: radial-gradient(circle, rgba(34,197,94,.17) 0%, rgba(34,197,94,.05) 45%, rgba(34,197,94,0) 66%);
    pointer-events: none; animation: ecPulse 4.5s ease-in-out infinite;
}
.ec-err .ec-glow { background: radial-gradient(circle, rgba(244,63,94,.15) 0%, rgba(244,63,94,.04) 45%, rgba(244,63,94,0) 66%); }
.ec-load .ec-glow { background: radial-gradient(circle, rgba(139,92,246,.15) 0%, rgba(139,92,246,.04) 45%, rgba(139,92,246,0) 66%); }
.ec-content {
    position: relative; z-index: 1; width: 100%; max-width: 620px;
    display: flex; flex-direction: column; align-items: center; text-align: center;
    padding: 32px 24px; animation: ecFade .6s ease both;
}
.ec-svg { width: 176px; height: 168px; margin-bottom: 42px; animation: ecPop .7s cubic-bezier(.2,.85,.25,1) both; }
.ec-svg-sm { width: 128px; height: 128px; margin-bottom: 34px; }
.ec-title { margin: 0; font-size: 56px; font-weight: 800; letter-spacing: -.025em; line-height: 1.04; color: #F8FAFC; }
.ec-grad { background: linear-gradient(90deg, #22C55E, #2DD4BF); -webkit-background-clip: text; background-clip: text; color: transparent; }
.ec-sub { margin: 22px 0 0; font-size: 22px; font-weight: 500; line-height: 1.5; color: #A8B0C5; max-width: 34ch; }
.ec-sub-err { max-width: 42ch; }
.ec-sub-load { margin-top: 32px; }
.ec-brand { color: #8B5CF6; font-weight: 600; }
.ec-btn {
    margin-top: 46px; width: 480px; max-width: 100%; height: 64px;
    display: inline-flex; align-items: center; justify-content: center; gap: 12px;
    border-radius: 16px; text-decoration: none; font-size: 22px; font-weight: 600; color: #fff;
    background: linear-gradient(90deg, #8B5CF6 0%, #4F46E5 100%);
    box-shadow: 0 12px 34px rgba(79,70,229,.32);
    transition: transform .2s ease, box-shadow .2s ease, filter .2s ease;
}
.ec-arrow { transition: transform .2s ease; }
.ec-btn:hover { transform: scale(1.02); filter: brightness(1.08); box-shadow: 0 18px 48px rgba(139,92,246,.5); }
.ec-btn:hover .ec-arrow { transform: translateX(5px); }
.ec-btn-ghost {
    background: transparent; color: #A8B0C5; font-size: 17px; font-weight: 600; height: 52px;
    width: auto; padding: 0 28px; margin-top: 36px; border: 1px solid rgba(255,255,255,.12); box-shadow: none;
}
.ec-btn-ghost:hover { background: rgba(255,255,255,.04); color: #F8FAFC; transform: none; filter: none; box-shadow: none; border-color: rgba(255,255,255,.22); }
.ec-foot { margin-top: 30px; display: inline-flex; align-items: center; gap: 9px; color: #70798F; font-size: 18px; font-weight: 500; }
.ec-trail { animation: ecDash 3s linear infinite; }
.ec-spinner {
    width: 54px; height: 54px; border-radius: 50%;
    border: 4px solid rgba(139,92,246,.18); border-top-color: #8B5CF6; animation: ecSpin .9s linear infinite;
}
@keyframes ecFade { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
@keyframes ecPop { from { opacity: 0; transform: scale(.9); } to { opacity: 1; transform: scale(1); } }
@keyframes ecPulse { 0%,100% { opacity: .65; transform: translate(-50%,-64%) scale(1); } 50% { opacity: 1; transform: translate(-50%,-64%) scale(1.05); } }
@keyframes ecDash { to { stroke-dashoffset: -28; } }
@keyframes ecSpin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) {
    .ec-content, .ec-svg, .ec-glow, .ec-trail { animation: none !important; }
}
@media (max-width: 560px) {
    .ec-title { font-size: 34px; }
    .ec-sub { font-size: 18px; }
    .ec-btn { height: 58px; font-size: 19px; }
    .ec-foot { font-size: 15px; }
    .ec-svg { width: 148px; height: 142px; }
}

/* Segmento de direção travado na edição (conta standby com histórico) */
.lo-seg-ro { opacity: .72; }
.lo-seg-ro .lo-seg-btn { cursor: default; }
.lo-seg-ro .lo-seg-btn:disabled { pointer-events: none; }
