/* =============================================================
   DMApp Tesouraria — Sistema de Design Global
   ARGBLS 19 de Novembro Nr. 145
   ============================================================= */

/* ---- Variáveis ---- */
:root {
    --sidebar-width: 240px;
    --sidebar-collapsed-width: 62px;
    --topbar-height: 56px;

    --color-sidebar-bg:           #1a2332;
    --color-sidebar-hover:        #243447;
    --color-sidebar-active-bg:    rgba(201, 162, 39, 0.12);
    --color-sidebar-active-border:#c9a227;
    --color-sidebar-text:         #9aafc8;
    --color-sidebar-text-active:  #ffffff;
    --color-sidebar-group:        #4d637f;
    --color-sidebar-divider:      rgba(255,255,255,0.06);

    --color-accent:               #c9a227;
    --color-accent-hover:         #d4af37;
    --color-brand:                #1a4a7c;
    --color-brand-dark:           #132f50;

    --color-topbar-bg:            #ffffff;
    --color-topbar-border:        #e5e9f0;
    --color-page-bg:              #f0f2f5;

    --transition: 0.22s ease;
    --radius:     8px;
}

/* ---- Reset / Base ---- */
body.app-layout {
    background: var(--color-page-bg);
    margin: 0;
    padding: 0;
    font-family: 'Segoe UI', system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
    font-size: 0.88rem;
    color: #2d3748;
}

/* ============================================================
   TOPBAR
   ============================================================ */
.app-topbar {
    position: fixed;
    top: 0; left: 0; right: 0;
    height: var(--topbar-height);
    background: var(--color-topbar-bg);
    border-bottom: 1px solid var(--color-topbar-border);
    z-index: 1040;
    display: flex;
    align-items: center;
    padding: 0 16px;
    gap: 8px;
    box-shadow: 0 1px 6px rgba(0,0,0,0.07);
}

.topbar-toggle {
    background: none;
    border: none;
    width: 36px; height: 36px;
    border-radius: 6px;
    color: #6b7280;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: background var(--transition), color var(--transition);
}
.topbar-toggle:hover { background: #f3f4f6; color: #111827; }

.topbar-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: var(--color-brand);
    flex-shrink: 0;
    margin-left: 4px;
}
.topbar-brand img {
    height: 32px; width: 32px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--color-accent);
}
.topbar-brand-text strong {
    display: block;
    font-size: 0.85rem;
    font-weight: 700;
    line-height: 1.2;
    color: var(--color-brand-dark);
}
.topbar-brand-text small {
    font-size: 0.68rem;
    color: #9ca3af;
    font-weight: 400;
}

.topbar-spacer { flex: 1; }

.topbar-date {
    font-size: 0.75rem;
    color: #9ca3af;
    font-weight: 500;
}

.topbar-user-btn {
    background: none;
    border: none;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 4px 8px;
    border-radius: 8px;
    cursor: pointer;
    transition: background var(--transition);
}
.topbar-user-btn:hover { background: #f3f4f6; }

.user-avatar {
    width: 32px; height: 32px;
    border-radius: 50%;
    background: var(--color-brand);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.72rem;
    font-weight: 700;
    flex-shrink: 0;
    letter-spacing: 0.02em;
}
.topbar-username {
    font-size: 0.82rem;
    font-weight: 600;
    color: #374151;
}
.topbar-chevron {
    font-size: 0.6rem;
    color: #9ca3af;
}

/* ============================================================
   SIDEBAR
   ============================================================ */
.app-sidebar {
    position: fixed;
    top: var(--topbar-height);
    left: 0;
    bottom: 0;
    width: var(--sidebar-width);
    background: var(--color-sidebar-bg);
    z-index: 1030;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    overflow-x: hidden;
    transition: width var(--transition);
    scrollbar-width: thin;
    scrollbar-color: rgba(255,255,255,0.1) transparent;
}
.app-sidebar::-webkit-scrollbar { width: 3px; }
.app-sidebar::-webkit-scrollbar-track { background: transparent; }
.app-sidebar::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.12); border-radius: 4px; }

/* ---- Itens da sidebar ---- */
.sidebar-nav { flex: 1; padding: 6px 0 8px; }

.sidebar-group-label {
    font-size: 0.62rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--color-sidebar-group);
    padding: 18px 16px 5px;
    white-space: nowrap;
    overflow: hidden;
}

.sidebar-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 16px;
    color: var(--color-sidebar-text);
    text-decoration: none;
    font-size: 0.82rem;
    font-weight: 400;
    border-left: 3px solid transparent;
    white-space: nowrap;
    overflow: hidden;
    transition: background var(--transition), color var(--transition), border-color var(--transition);
    position: relative;
}
.sidebar-item:hover {
    background: var(--color-sidebar-hover);
    color: var(--color-sidebar-text-active);
    text-decoration: none;
}
.sidebar-item.active {
    background: var(--color-sidebar-active-bg);
    border-left-color: var(--color-sidebar-active-border);
    color: var(--color-sidebar-text-active);
    font-weight: 600;
}
.sidebar-item i {
    width: 16px;
    text-align: center;
    font-size: 0.85rem;
    flex-shrink: 0;
    color: inherit;
    transition: color var(--transition);
}
.sidebar-item.active i { color: var(--color-accent); }

.sidebar-label { flex: 1; overflow: hidden; text-overflow: ellipsis; }

.sidebar-badge {
    margin-left: auto;
    background: #dc3545;
    color: #fff;
    font-size: 0.62rem;
    font-weight: 700;
    padding: 1px 6px;
    border-radius: 10px;
    min-width: 18px;
    text-align: center;
    flex-shrink: 0;
}

.sidebar-divider {
    height: 1px;
    background: var(--color-sidebar-divider);
    margin: 6px 0;
}

/* ---- Bottom da sidebar (perfil + logout) ---- */
.sidebar-bottom {
    border-top: 1px solid var(--color-sidebar-divider);
    padding: 6px 0;
}
.sidebar-item.logout-item:hover {
    background: rgba(220, 53, 69, 0.12);
    color: #f87171;
}

/* ============================================================
   SIDEBAR COLAPSADA (desktop)
   ============================================================ */
body.sidebar-collapsed .app-sidebar { width: var(--sidebar-collapsed-width); }

body.sidebar-collapsed .sidebar-label,
body.sidebar-collapsed .sidebar-group-label,
body.sidebar-collapsed .sidebar-badge { display: none; }

body.sidebar-collapsed .sidebar-item {
    justify-content: center;
    padding: 11px 0;
    border-left-color: transparent;
}
body.sidebar-collapsed .sidebar-item.active {
    border-left-color: var(--color-sidebar-active-border);
}
body.sidebar-collapsed .sidebar-item i {
    font-size: 1rem;
    width: auto;
}

body.sidebar-collapsed .app-main { margin-left: var(--sidebar-collapsed-width); }

/* ============================================================
   MAIN CONTENT
   ============================================================ */
.app-main {
    margin-left: var(--sidebar-width);
    margin-top: var(--topbar-height);
    min-height: calc(100vh - var(--topbar-height));
    transition: margin-left var(--transition);
}

.app-content { padding: 24px; }

/* ============================================================
   COMPONENTES DE PÁGINA
   ============================================================ */

/* Page header padrão */
.page-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 20px;
    padding-bottom: 14px;
    border-bottom: 2px solid #e5e9f0;
}
.page-title {
    font-size: 1.05rem;
    font-weight: 700;
    color: #1a2332;
    margin: 0 0 2px;
}
.page-subtitle {
    font-size: 0.74rem;
    color: #9ca3af;
    margin: 0;
}

/* Neutraliza container-fluid legado dentro do app-content */
.app-content .container-fluid { padding-left: 0; padding-right: 0; }

/* Breadcrumb */
.app-breadcrumb {
    font-size: 0.74rem;
    color: #9ca3af;
    margin-bottom: 14px;
    display: flex;
    align-items: center;
    gap: 4px;
}
.app-breadcrumb a { color: #9ca3af; text-decoration: none; }
.app-breadcrumb a:hover { color: var(--color-accent); }
.app-breadcrumb .sep { opacity: 0.5; }

/* Cards */
.card {
    border: none;
    border-radius: var(--radius);
    box-shadow: 0 1px 4px rgba(0,0,0,0.07);
}
.card-accent {
    border-left: 4px solid var(--color-accent);
}

/* ---- Stat cards ---- */
.stat-card {
    background: #fff;
    border-radius: var(--radius);
    padding: 16px 20px;
    box-shadow: 0 1px 4px rgba(0,0,0,0.07);
    border-left: 4px solid var(--color-accent);
    display: flex;
    align-items: center;
    gap: 14px;
}
.stat-icon {
    width: 40px; height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    flex-shrink: 0;
}
.stat-icon.green  { background: rgba(25, 135, 84, 0.1);  color: #198754; }
.stat-icon.red    { background: rgba(220, 53, 69, 0.1);  color: #dc3545; }
.stat-icon.gold   { background: rgba(201, 162, 39, 0.12); color: var(--color-accent); }
.stat-icon.blue   { background: rgba(26, 74, 124, 0.1);  color: var(--color-brand); }
.stat-value { font-size: 1.5rem; font-weight: 700; color: #1a2332; line-height: 1; }
.stat-label { font-size: 0.72rem; color: #9ca3af; margin-top: 3px; font-weight: 500; }

/* ---- Alerta de capitação ---- */
.alerta-capitacao {
    margin-bottom: 20px;
    border-radius: var(--radius);
    border: none;
    border-left: 4px solid #f59e0b;
    background: #fffbeb;
}

/* ============================================================
   UTILITÁRIOS LEGADOS (mantidos para compatibilidade)
   ============================================================ */
.negativo { color: #dc3545; font-weight: 600; }
.positivo { color: var(--color-brand); font-weight: 600; }
.id-box {
    font-family: monospace;
    background: #e9ecef;
    padding: 2px 6px;
    border-radius: 4px;
    font-weight: 700;
    font-size: 0.85em;
    margin-right: 5px;
}
.badge-mutua {
    font-size: 0.68em;
    color: #666;
    font-style: italic;
    border: 1px solid #ccc;
    padding: 1px 4px;
    border-radius: 4px;
}

/* Tabelas */
.table { font-size: 0.85rem; }
.table-dark { background: var(--color-brand-dark); }
thead.table-dark th { background: var(--color-brand-dark); color: #e2e8f0; font-weight: 600; font-size: 0.78rem; }

/* ============================================================
   OVERLAY MOBILE
   ============================================================ */
.sidebar-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.45);
    z-index: 1029;
    cursor: pointer;
}

/* ============================================================
   RESPONSIVIDADE
   ============================================================ */
@media (max-width: 767.98px) {
    .app-sidebar {
        transform: translateX(-100%);
        width: var(--sidebar-width) !important;
        transition: transform var(--transition), width var(--transition);
    }
    .app-sidebar.mobile-open {
        transform: translateX(0);
        box-shadow: 4px 0 20px rgba(0,0,0,0.3);
    }
    .app-sidebar.mobile-open ~ .sidebar-overlay,
    .sidebar-overlay.active { display: block; }

    .app-main { margin-left: 0 !important; }
    .app-content { padding: 14px; }

    .topbar-desktop-toggle { display: none; }
    .topbar-brand-text small { display: none; }
    .topbar-date { display: none; }
}

@media (min-width: 768px) {
    .topbar-mobile-toggle { display: none; }
}

/* ============================================================
   MODAIS
   ============================================================ */
.modal-content {
    border: none;
    border-radius: 12px;
    box-shadow: 0 12px 40px rgba(0,0,0,0.2);
    overflow: hidden;
}
.modal-navy {
    background: var(--color-brand-dark);
    color: #fff;
    border-bottom: 2px solid var(--color-accent);
}
.modal-navy .btn-close { filter: invert(1) brightness(2); }
.modal-navy .modal-title { font-size: 0.95rem; font-weight: 600; }

.modal-header.bg-danger .btn-close,
.modal-header.bg-success .btn-close { filter: invert(1) brightness(2); }

.modal-footer {
    background: #f8fafc;
    border-top: 1px solid #e5e9f0;
}
.modal-body { padding: 20px; }

/* Form controls dentro de modais */
.modal .form-control,
.modal .form-select {
    border-radius: 8px;
    border: 1px solid #e5e7eb;
    font-size: 0.86rem;
}
.modal .form-control:focus,
.modal .form-select:focus {
    border-color: var(--color-brand);
    box-shadow: 0 0 0 3px rgba(26,74,124,0.1);
}
.modal label.small, .modal label.fw-bold { font-size: 0.76rem; color: #4b5563; }

/* ============================================================
   PRINT
   ============================================================ */
@media print {
    .app-topbar, .app-sidebar, .sidebar-overlay,
    .topbar-toggle, #toastContainer { display: none !important; }
    .app-main  { margin-left: 0 !important; margin-top: 0 !important; }
    .app-content { padding: 0 !important; }
    .card { box-shadow: none !important; border: 1px solid #ddd !important; }
    .btn, form button { display: none !important; }
    a[href]:after { content: none !important; }
}

/* ============================================================
   LOGIN PAGE
   ============================================================ */
body.login-page {
    margin: 0;
    padding: 0;
    min-height: 100vh;
    background: linear-gradient(135deg, #0f1923 0%, #1a2d4a 50%, #0d1e33 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
}
.login-card {
    width: 100%;
    max-width: 400px;
    background: #fff;
    border-radius: 14px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.4);
    overflow: hidden;
}
.login-header {
    background: var(--color-sidebar-bg);
    padding: 32px 32px 24px;
    text-align: center;
    position: relative;
}
.login-header::after {
    content: '';
    position: absolute;
    bottom: 0; left: 0; right: 0;
    height: 3px;
    background: linear-gradient(90deg, transparent, var(--color-accent), transparent);
}
.login-logo {
    width: 72px; height: 72px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--color-accent);
    display: block;
    margin: 0 auto 14px;
}
.login-title {
    color: #fff;
    font-size: 1rem;
    font-weight: 700;
    margin: 0 0 4px;
}
.login-subtitle {
    color: var(--color-sidebar-group);
    font-size: 0.75rem;
    margin: 0;
}
.login-body { padding: 28px 32px 32px; }
.login-label { font-size: 0.78rem; font-weight: 600; color: #4b5563; margin-bottom: 4px; }
.login-input {
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 10px 14px;
    font-size: 0.88rem;
    transition: border-color var(--transition), box-shadow var(--transition);
}
.login-input:focus {
    border-color: var(--color-brand);
    box-shadow: 0 0 0 3px rgba(26,74,124,0.12);
    outline: none;
}
.login-btn {
    background: var(--color-brand);
    border: none;
    border-radius: 8px;
    color: #fff;
    font-weight: 700;
    font-size: 0.9rem;
    padding: 11px;
    width: 100%;
    cursor: pointer;
    transition: background var(--transition), transform 0.1s;
}
.login-btn:hover { background: var(--color-brand-dark); }
.login-btn:active { transform: scale(0.99); }
.login-footer {
    text-align: center;
    font-size: 0.72rem;
    color: #9ca3af;
    margin-top: 18px;
}
.login-error {
    background: #fef2f2;
    border: 1px solid #fecaca;
    border-radius: 8px;
    color: #b91c1c;
    font-size: 0.82rem;
    padding: 10px 14px;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* ============================================================
   TABELAS — REFINAMENTO GLOBAL (Fase 7)
   ============================================================ */

/* Thead padronizado com fundo sutil */
.table thead th {
    background: #f1f5f9;
    color: #374151;
    font-size: 0.74rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    border-bottom: 2px solid #e2e8f0;
    white-space: nowrap;
    padding-top: 10px;
    padding-bottom: 10px;
}

/* Hover com transição suave */
.table-hover > tbody > tr {
    transition: background-color 0.13s ease;
}
.table-hover > tbody > tr:hover > td {
    background-color: #f0f4ff;
}

/* Células de dados menores */
.table td { font-size: 0.83rem; vertical-align: middle; }

/* Bordas mais sutis */
.table { border-color: #e9edf2; }

/* Tfoot destaque */
.table tfoot td {
    background: #f8fafc;
    font-size: 0.82rem;
    border-top: 2px solid #e2e8f0;
}

/* Tabelas dentro de cards sem padding lateral extra */
.card > .table, .card > .table-responsive > .table { margin-bottom: 0; }

/* ============================================================
   CHIPS DE STATUS FINANCEIRO
   ============================================================ */

/* Sobrescreve os badges de saldo do painel principal */
.badge.bg-success {
    background-color: #16a34a !important;
    font-size: 0.72rem;
    font-weight: 600;
    padding: 3px 8px;
    border-radius: 20px;
    letter-spacing: 0.02em;
}
.badge.bg-danger {
    background-color: #dc2626 !important;
    font-size: 0.72rem;
    font-weight: 600;
    padding: 3px 8px;
    border-radius: 20px;
}
.badge.bg-info {
    background-color: #0284c7 !important;
    color: #fff !important;
    font-size: 0.72rem;
    font-weight: 600;
    padding: 3px 8px;
    border-radius: 20px;
}
.badge.bg-warning {
    background-color: #d97706 !important;
    color: #fff !important;
    font-size: 0.72rem;
    font-weight: 600;
    padding: 3px 8px;
    border-radius: 20px;
}
.badge.bg-secondary {
    background-color: #64748b !important;
    font-size: 0.72rem;
    padding: 3px 8px;
    border-radius: 20px;
}

/* Chip leve (bg-light) sem override agressivo */
.badge.bg-light {
    font-size: 0.72rem;
    padding: 3px 8px;
    border-radius: 20px;
}

/* ============================================================
   CARD HEADERS DE SEÇÃO
   ============================================================ */

/* Card-header modal-navy reutilizado em cards de seção */
.card-header.modal-navy {
    border-radius: 0 !important;
    font-size: 0.85rem;
}

/* Card-header padrão do sistema */
.card-header {
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.01em;
}

/* ============================================================
   UTILITÁRIOS
   ============================================================ */

/* Cor de destaque dourada */
.text-accent { color: var(--color-accent) !important; }

/* Valores monetários */
.valor-positivo { color: #16a34a; font-weight: 700; }
.valor-negativo { color: #dc2626; font-weight: 700; }
.valor-zero     { color: #9ca3af; font-weight: 500; }

/* Linha de tabela clicável */
.cursor-pointer { cursor: pointer; }
.cursor-pointer:hover { background-color: #f0f4ff !important; }

/* Scrollable card body */
.card-body-scroll { max-height: 340px; overflow-y: auto; }

/* Separador vertical nos toolbars */
.toolbar-sep {
    width: 1px;
    height: 28px;
    background: #e5e9f0;
    flex-shrink: 0;
}

/* Form switch estilizado */
.form-check.form-switch.styled {
    background: #f8fafc;
    border: 1px solid #e5e9f0;
    border-radius: 8px;
    padding: 10px 12px 10px 48px;
}

/* ============================================================
   FECHAR MÊS / ALERTS DE AÇÃO
   ============================================================ */
.alert { border-radius: 8px; font-size: 0.84rem; }
.alert-info  { background: #eff6ff; border-color: #bfdbfe; color: #1e40af; }
.alert-warning { background: #fffbeb; border-color: #fde68a; color: #92400e; }
.alert-danger  { background: #fef2f2; border-color: #fecaca; color: #991b1b; }
.alert-success { background: #f0fdf4; border-color: #bbf7d0; color: #166534; }

/* ============================================================
   TERMÔMETRO DE COBERTURA — audit_budget_balanco.php (Fase 8)
   ============================================================ */
.termometro-wrapper {
    height: 36px;
    border-radius: 6px;
    overflow: hidden;
    background: #e9ecef;
    display: flex;
    position: relative;
    width: 100%;
    box-shadow: inset 0 1px 3px rgba(0,0,0,0.15);
}
.termo-at-close {
    background: #198754;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    font-weight: bold;
    color: #fff;
    white-space: nowrap;
    overflow: hidden;
    min-width: 0;
    transition: width 0.4s ease;
}
.termo-cascade {
    height: 100%;
    background: repeating-linear-gradient(135deg,#198754,#198754 4px,#75b798 4px,#75b798 9px);
    opacity: 0.85;
    min-width: 0;
    transition: width 0.4s ease;
}
.termo-gap { height: 100%; background: #f8d7da; flex: 1; min-width: 0; }
.termo-surplus {
    background: #0d6efd;
    height: 100%;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    font-weight: bold;
    color: #fff;
}
.badge-fonte-cascata {
    font-size: 0.65rem;
    padding: 1px 5px;
    border-radius: 10px;
    background: #d1e7dd;
    color: #0f5132;
    border: 1px solid #a3cfbb;
}
.legenda-bar { display: flex; align-items: center; gap: 6px; font-size: 0.72rem; flex-wrap: wrap; margin-top: 5px; }
.legenda-sq  { width: 12px; height: 12px; border-radius: 2px; flex-shrink: 0; }
.sq-fechado  { background: #6c757d; }
.sq-verde    { background: #198754; }
.sq-cascata  { background: repeating-linear-gradient(135deg,#198754,#198754 3px,#75b798 3px,#75b798 7px); }
.sq-gap      { background: #f8d7da; border: 1px solid #f5c2c7; }
.sq-surplus  { background: #0d6efd; }
.mes-card { transition: box-shadow 0.2s; }
.mes-card:hover { box-shadow: 0 4px 16px rgba(0,0,0,0.12) !important; }
.balde-row-ok     { background: #d1e7dd22; }
.balde-row-warn   { background: #fff3cd44; }
.balde-row-danger { background: #f8d7da44; }

/* ============================================================
   PERMISSÕES — tabela sticky com coluna fixa (admin_permissoes)
   ============================================================ */
.perm-table .col-modulo {
    position: sticky;
    left: 0;
    z-index: 2;
    background: #fff;
    min-width: 180px;
    border-right: 2px solid #dee2e6 !important;
}
.perm-table thead .col-modulo {
    z-index: 4;
    background: #212529;
}
.perm-table .row-section .col-modulo {
    z-index: 3;
    background: #dbeafe;
}
.perm-table .row-section td {
    background: #dbeafe;
    font-weight: 700;
    font-size: .8rem;
    text-transform: uppercase;
    letter-spacing: .04em;
    color: #1e40af;
    padding: 4px 8px;
}
.perm-table tbody tr:hover .col-modulo { background: #f8f9fa; }
.perm-check.pendente { outline: 2px solid #fd7e14; outline-offset: 1px; }
.cell-pendente { background-color: #fff3cd !important; }

/* ============================================================
   IMPORTAR LOTE — drop zone de imagens
   ============================================================ */
.drop-zone {
    border: 3px dashed var(--color-brand);
    border-radius: var(--radius);
    padding: 60px 30px;
    text-align: center;
    color: var(--color-brand);
    cursor: pointer;
    transition: var(--transition);
    background: #f8fbff;
}
.drop-zone:hover,
.drop-zone.dragover { background: #eef6ff; border-color: var(--color-brand-dark); }
.log-area {
    background: #1a2332;
    color: #4ade80;
    padding: 14px;
    border-radius: var(--radius);
    font-family: 'Courier New', monospace;
    font-size: 0.82rem;
    max-height: 220px;
    overflow-y: auto;
    margin-top: 16px;
    white-space: pre-wrap;
}

/* ============================================================
   UTILITÁRIOS RESIDUAIS
   ============================================================ */
.congelado {
    opacity: 0.5 !important;
    pointer-events: none !important;
    cursor: not-allowed !important;
    filter: grayscale(100%);
}

/* ============================================================
   BUDGET — tabela compacta de células editáveis (Fase 8)
   ============================================================ */
#budgetTabsContent th,
#budgetTabsContent td {
    padding: 0.2rem 0.1rem !important;
    vertical-align: middle !important;
}
#budgetTabsContent th[style],
#budgetTabsContent td[style] { min-width: 55px !important; }
#budgetTabsContent th:first-child,
#budgetTabsContent td:first-child {
    min-width: 110px !important;
    max-width: 140px !important;
    white-space: normal !important;
    font-size: 0.75rem !important;
    line-height: 1.1;
}
#budgetTabsContent .form-control {
    font-size: 0.7rem !important;
    padding: 0.1rem !important;
    height: 24px !important;
    width: 100% !important;
    text-align: center;
}
#budgetTabsContent .small { font-size: 0.6rem !important; }
