/* projecao.css */

.proj-table {
  border-collapse: collapse;
  width: 100%;
  table-layout: fixed;
  background: #ffffff;
}

.proj-table th, .proj-table td {
  border: 1px solid #e2e8f0;
  padding: 6px 8px !important;
  vertical-align: middle;
  font-size: 0.75rem !important;
  word-wrap: break-word;
  white-space: normal !important;
}

/* Bordas mais grossas para separar as ZONAS (Projeção | Realizado | Resultado) */
.col-divider {
  border-right: 2px solid #94a3b8 !important;
}

/* Largura das Colunas */
.proj-table th:first-child,
.proj-table td:first-child {
  width: 20%; 
  text-align: left !important;
}

.proj-table th:not(:first-child) {
  text-align: center !important;
  line-height: 1.2;
}

.proj-table td:not(:first-child) {
  text-align: right !important;
}

/* Cabeçalhos Principais */
.th-categoria { background-color: #f1f5f9; color: #334155; }
.th-meta { background-color: #eff6ff; color: #1e3a8a; border-bottom: 3px solid #3b82f6 !important; }
.th-real { background-color: #f0fdf4; color: #14532d; border-bottom: 3px solid #22c55e !important; }
.th-diff { background-color: #fefce8; color: #713f12; border-bottom: 3px solid #eab308 !important; }

/* Sub-cabeçalhos (Títulos das colunas) */
.sub-header th {
  background-color: #f8fafc;
  color: #475569;
  font-size: 0.65rem !important;
  text-transform: uppercase;
  font-weight: 700;
}

/* Linhas Macro (Ex: INFERIOR - Casual) */
.macro-row {
  background-color: #1e293b; 
  color: #f8fafc;
  font-weight: 700;
}
.macro-row td {
  border-color: #334155 !important;
}
.macro-name {
  color: #facc15 !important; 
  font-size: 0.85rem !important;
  text-transform: uppercase;
}

/* Linhas dos Itens Normais */
.item-row td:first-child {
  padding-left: 16px !important;
  font-weight: 600;
  color: #334155;
}

/* Fundos sutis para colunas de leitura */
.bg-meta { background-color: #fbfeff; }
.bg-real { background-color: #fcfffb; }

/* Caixas de Digitação (Inputs) */
.proj-input {
  width: 100%;
  padding: 6px;
  border: 1px solid #cbd5e1;
  border-radius: 4px;
  text-align: right;
  font-family: inherit;
  font-size: 0.75rem;
  font-weight: 600;
  color: #0f172a;
  background: #ffffff;
  transition: all 0.2s;
  box-sizing: border-box;
}
.proj-input:focus {
  outline: none;
  border-color: #3b82f6;
  box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.2);
}

/* Tags de Resultado (Cores fortes e legíveis) */
.val-positive { color: #166534; font-weight: 700; background: #bbf7d0; padding: 4px 6px; border-radius: 4px; display: inline-block; min-width: 50px; text-align: center; }
.val-negative { color: #991b1b; font-weight: 700; background: #fecaca; padding: 4px 6px; border-radius: 4px; display: inline-block; min-width: 50px; text-align: center; }
.val-neutral { color: #64748b; font-weight: 500; display: inline-block; padding: 4px 6px; }

/* Totais no fim/topo */
.row-total-geral {
  background-color: #0f172a !important;
  color: #ffffff !important;
  font-size: 0.85rem !important;
  font-weight: 800 !important;
}