/* Estilos do módulo caixa-bancos (prefixo cxb-). As janelas vêm do motor de cadastros-nativos (classes cn-*). */

.cxb-neg { color: #c00000; }
.cxb-vermelho { color: #c00000; }

/* Movimento do lançamento (TcxImageComboBox com ícone + / - / transferência) */
.cxb-receita .cn-input, .cxb-despesa .cn-input, .cxb-transf .cn-input { color: #e8590c; padding-left: 20px; }
.cxb-receita::before, .cxb-despesa::before, .cxb-transf::before { position: absolute; left: 5px; top: 50%; transform: translateY(-50%); font-weight: 700; z-index: 1; }
.cxb-receita::before { content: '+'; color: #2b8a3e; font-size: 15px; }
.cxb-despesa::before { content: '−'; color: #c92a2a; font-size: 15px; }
.cxb-transf::before { content: '⇄'; color: #1c7ed6; font-size: 12px; }

/* Barra lateral (TdxNavBar) */
.cxb-nav { position: absolute; z-index: 2; display: flex; flex-direction: column; gap: 2px; padding: 0 0 6px; background: #eef3fa; border: 1px solid #b9c9dd; border-radius: 3px; overflow: auto; }
.cxb-nav-tit { padding: 5px 8px; font-weight: 700; color: #fff; background: linear-gradient(#5b86c2, #3d6aa8); font-size: 12px; }
.cxb-nav-item { display: flex; align-items: center; gap: 6px; margin: 0 4px; padding: 5px 6px; border: 0; background: none; color: #1f3f73; font: inherit; font-size: 12px; text-align: left; cursor: pointer; border-radius: 2px; }
.cxb-nav-item:hover:not(:disabled) { background: #d7e5f7; text-decoration: underline; }
.cxb-nav-item:disabled { color: #9aa6b5; cursor: default; }
.cxb-nav-item .erp-ico { width: 16px; height: 16px; flex: none; }
.cxb-nav-sep { display: block; height: 1px; margin: 4px 8px; background: #c4d2e4; }

/* Menu suspenso dos botões da barra (Consultas, Gerar Arq. Remessa) */
.cxb-menu { position: fixed; z-index: 3000; min-width: 220px; padding: 3px; background: #fff; border: 1px solid #9fb3cc; box-shadow: 0 4px 14px rgba(0, 0, 0, .18); }
.cxb-menu button { display: block; width: 100%; padding: 6px 10px; border: 0; background: none; text-align: left; font: inherit; font-size: 12px; cursor: pointer; }
.cxb-menu button:hover:not(:disabled) { background: #dbe8f8; }
.cxb-menu button:disabled { color: #9aa6b5; cursor: default; }

/* Período das disponibilidades */
.cxb-periodo-disp { position: absolute; left: 6px; right: 6px; top: 22px; display: flex; flex-direction: column; gap: 10px; z-index: 1; }
.cxb-periodo-disp label { display: flex; flex-direction: column; gap: 3px; color: #1f4e8c; font-size: 12px; }
.cxb-periodo-disp input { height: 26px; padding: 0 6px; }

/* Controles trocados no lugar de componentes que o motor não desenha */
.cxb-navegador { display: flex; align-items: flex-start; }
.cxb-cal { width: 100%; height: 26px; }
.cxb-select { width: 100%; height: 100%; }

/* Janelas auxiliares (contas de cobrança, remessas geradas, log de registro) */
.cxb-janela-grade { min-height: 360px; }
.cxb-janela-dupla { display: flex; flex-direction: column; gap: 6px; }
.cxb-sub { font-weight: 600; color: var(--erp-rotulo, #1f4e8c); padding: 4px 2px 0; border-bottom: 1px solid var(--erp-borda, #c9d3e0); }
.cxb-log { margin: 0; min-height: 110px; max-height: 200px; overflow: auto; padding: 6px 8px; font: 11px/1.4 Consolas, Menlo, monospace;
  background: var(--erp-fundo-campo, #fff); border: 1px solid var(--erp-borda, #c9d3e0); white-space: pre-wrap; word-break: break-word; }

/* Consultar Titulos (liquidações on-line) */
.cxb-liq-cab { margin: 6px 8px 0; padding: 4px 10px 8px; border: 1px solid #c4d2e4; border-radius: 3px; font-size: 12px; }
.cxb-liq-cab legend { color: #1f4e8c; padding: 0 4px; }
.cxb-liq-cab div { display: flex; gap: 10px; padding: 3px 0; flex-wrap: wrap; }
.cxb-liq-cab b { color: #1f3f73; min-width: 60px; }
.cxb-liq-cab span { min-width: 140px; }
.cxb-liq-botoes { display: flex; gap: 4px; padding: 8px; flex-wrap: wrap; }
.cxb-liq-botoes .erp-botao { min-width: 96px; }

/* Gráfico de disponibilidades */
.cxb-grafico { display: flex; flex-direction: column; gap: 6px; padding: 6px 2px; font-size: 12px; }
.cxb-graf-linha { display: grid; grid-template-columns: 220px 1fr 110px; align-items: center; gap: 8px; }
.cxb-graf-rot { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cxb-graf-barras { display: flex; flex-direction: column; gap: 2px; }
.cxb-graf-barras i { display: block; height: 9px; min-width: 1px; }
.cxb-graf-val { text-align: right; font-variant-numeric: tabular-nums; }
.cxb-graf-saldo { background: #3b82c4; }
.cxb-graf-saldo.neg { background: #c92a2a; }
.cxb-graf-acomp { background: #f08c00; }
.cxb-graf-leg { display: flex; gap: 16px; padding-top: 6px; }
.cxb-graf-leg i { display: inline-block; width: 12px; height: 9px; margin-right: 4px; }

/* Recibo avulso (pré-visualização A4 com duas vias) */
.cxb-pagina { padding: 36px 44px; box-sizing: border-box; background: #fff; color: #000; font: 13px/1.5 Arial, Helvetica, sans-serif; }
.cxb-recibo { border: 1px solid #000; padding: 18px 22px; position: relative; height: 470px; box-sizing: border-box; }
.cxb-recibo-cab { display: flex; align-items: center; gap: 14px; border-bottom: 1px solid #000; padding-bottom: 10px; margin-bottom: 14px; font-size: 11px; }
.cxb-recibo-cab img { max-height: 54px; max-width: 120px; object-fit: contain; }
.cxb-recibo-cab > div:not(.cxb-recibo-num) { flex: 1; }
.cxb-recibo-num { text-align: right; font-size: 14px; white-space: nowrap; }
.cxb-recibo-num span { display: inline-block; margin-top: 4px; padding: 3px 10px; border: 1px solid #000; font-weight: 700; font-size: 15px; }
.cxb-recibo-texto { text-align: justify; margin: 10px 0; }
.cxb-recibo-data { text-align: right; margin-top: 18px; }
.cxb-recibo-ass { position: absolute; left: 50%; bottom: 48px; transform: translateX(-50%); width: 60%; border-top: 1px solid #000; text-align: center; padding-top: 4px; display: flex; flex-direction: column; font-size: 12px; }
.cxb-recibo-via { position: absolute; right: 10px; bottom: 6px; font-size: 10px; color: #555; }
.cxb-recibo-corte { border: 0; border-top: 1px dashed #777; margin: 40px 0; }

/* Quadro de resumo no fim do DRE e do balanço */
.cxb-dre-res { margin: 14px 0 0 auto; border-collapse: collapse; font-size: 12px; min-width: 50%; }
.cxb-dre-res td { padding: 3px 8px; border-top: 1px solid #999; }
.cxb-dre-res td:nth-child(n+2) { text-align: right; font-variant-numeric: tabular-nums; font-weight: 700; }
.cxb-dre-res tr:last-child td { border-bottom: 2px solid #000; }

/* Encerrante Financeiro (TFENCERRANTE) */
.cxb-enc { display: flex; flex-direction: column; gap: 6px; font-size: 12px; }
.cxb-enc-aviso { display: flex; gap: 10px; align-items: flex-start; padding: 6px 8px; border: 1px solid #f0c36d; background: #fff8e1; border-radius: 4px; color: #5b4300; }
.cxb-enc-aviso b { color: #c00000; white-space: nowrap; }
.cxb-enc-meio { display: grid; grid-template-columns: 1fr 300px; gap: 8px; }
.cxb-enc-meio .erp-grupo { margin: 0; }
.cxb-enc-pag > .erp-botao { margin-top: 6px; }
.cxb-enc-data { display: flex; align-items: center; gap: 8px; font-weight: 700; color: #004080; }
.cxb-enc-data .erp-input { width: 150px; }
.cxb-enc-filtro { display: flex; gap: 10px; align-items: center; margin-bottom: 6px; }
.cxb-enc-filtro label { display: flex; gap: 4px; align-items: center; }

/* Perfil dos pagamentos do retorno bancário (TAdvProgressBar do FLerRetorno) */
.cxb-progresso { position: relative; height: 100%; min-height: 14px; border: 1px solid #8aa; background: #fff; }
.cxb-progresso i { position: absolute; left: 0; top: 0; bottom: 0; background: #4caf50; }
.cxb-progresso span { position: relative; display: block; text-align: center; font-size: 11px; line-height: 14px; }

/* TFCHEQUE "Cheque": campos sobre a imagem do talão (Image1 do .dfm), posições do formulário */
.cxb-cheque { position: relative; width: 712px; height: 230px; background: #fff url('imagens/cheque.jpg') center / 100% 100% no-repeat; font-family: Tahoma, Arial, sans-serif; }
.cxb-cheque-campo { position: absolute; box-sizing: border-box; border: 0; padding: 0 4px; background: #dff0ff; color: #000; font: 11px Tahoma, Arial, sans-serif; outline: none; }
.cxb-cheque-campo.dir { text-align: right; }
.cxb-cheque-rot { position: absolute; height: 15px; line-height: 15px; color: #000; font: 700 12px Tahoma, Arial, sans-serif; white-space: nowrap; overflow: hidden; }
.cxb-cheque-rot.dir { text-align: right; }
.cxb-cheque-rot.centro { text-align: center; }
.cxb-cheque-btn { position: absolute; width: 32px; height: 25px; display: flex; align-items: center; justify-content: center; padding: 0; border: 1px solid #a9b8c9; border-radius: 3px; background: linear-gradient(#fff, #e3eaf3); cursor: pointer; }
.cxb-cheque-btn:hover { border-color: #6f9bd1; }
.cxb-cheque-btn svg { width: 16px; height: 16px; }
.cxb-janela-cheque .erp-janela-corpo { padding: 0; }
