/* Assistente do financeiro — estilo (2026-09-21). Bootstrap 5 dá a base; aqui
   fica só o que é desta casa: o painel do chat e as tabelas de dinheiro. */

:root {
    --pt-azul: #0b3d6b;
    --pt-azul-claro: #1466a8;
    --pt-fundo: #f4f6f9;
    --pt-borda: #dde3ea;
}

body { background: var(--pt-fundo); font-size: .94rem; }

.navbar-pt { background: var(--pt-azul); }
.navbar-pt .navbar-brand, .navbar-pt .nav-link { color: #fff; }
.navbar-pt .nav-link.ativo { background: rgba(255,255,255,.15); border-radius: .3rem; }

.cartao { background: #fff; border: 1px solid var(--pt-borda); border-radius: .5rem; }
.cartao-num { font-size: 1.6rem; font-weight: 600; line-height: 1.1; }
.cartao-rot { font-size: .78rem; text-transform: uppercase; letter-spacing: .04em; color: #6c757d; }

/* Dinheiro alinhado à direita e tabular: coluna de valor só se lê rápido
   quando os dígitos ficam na mesma posição em todas as linhas. */
.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.negativo { color: #b02a37; }
.positivo { color: #14663a; }

table.tabela-fin { background: #fff; font-size: .88rem; }
table.tabela-fin th { background: #eef2f6; font-weight: 600; white-space: nowrap; }

/* ---------- Chat ---------- */
#chat-abrir {
    position: fixed; right: 20px; bottom: 20px; z-index: 1040;
    border: 0; border-radius: 999px; padding: .7rem 1.2rem;
    background: var(--pt-azul-claro); color: #fff; font-weight: 600;
    box-shadow: 0 4px 14px rgba(0,0,0,.25);
}
#chat-painel {
    position: fixed; top: 0; right: 0; z-index: 1045;
    width: min(460px, 100vw); height: 100vh;
    background: #fff; border-left: 1px solid var(--pt-borda);
    display: flex; flex-direction: column;
    transform: translateX(100%); transition: transform .22s ease;
    box-shadow: -6px 0 24px rgba(0,0,0,.12);
}
#chat-painel.aberto { transform: translateX(0); }
#chat-cabecalho {
    background: var(--pt-azul); color: #fff;
    padding: .7rem 1rem; display: flex; align-items: center; gap: .5rem;
}
#chat-msgs { flex: 1; overflow-y: auto; padding: 1rem; }
#chat-rodape { border-top: 1px solid var(--pt-borda); padding: .7rem; }
#chat-entrada { resize: none; }

.chat-msg { margin-bottom: .9rem; }
.chat-msg p { margin: 0 0 .5rem; }
.chat-msg p:last-child { margin-bottom: 0; }
.chat-user {
    background: var(--pt-azul-claro); color: #fff;
    padding: .5rem .8rem; border-radius: .8rem .8rem .2rem .8rem;
    margin-left: 2.5rem;
}
.chat-assistant, .chat-sistema { padding: .1rem .1rem; }
.chat-erro { color: #b02a37; }
.chat-pensando { color: #6c757d; font-style: italic; }
.chat-exemplos { display: flex; flex-direction: column; gap: .35rem; margin-top: .6rem; }
.chat-exemplo {
    text-align: left; border: 1px solid var(--pt-borda); background: #fff;
    border-radius: .4rem; padding: .4rem .6rem; font-size: .85rem;
}
.chat-exemplo:hover { border-color: var(--pt-azul-claro); color: var(--pt-azul-claro); }
table.tabela-chat { width: 100%; font-size: .82rem; margin: .4rem 0; border-collapse: collapse; }
table.tabela-chat th, table.tabela-chat td {
    border: 1px solid var(--pt-borda); padding: .25rem .4rem;
}
table.tabela-chat th { background: #eef2f6; }
