/* ============================================
   TAILWIND MIGRATION - ULTRA COMPACT MODE
   ============================================ */

/* REDUÇÃO AGRESSIVA DE LINE-HEIGHT */
* {
    line-height: 1.2 !important;
    /* MUITO mais compacto */
}

h1,
h2,
h3,
h4,
h5,
h6 {
    line-height: 1.1 !important;
    margin-bottom: 0.25rem !important;
}

p {
    margin-bottom: 0.25rem !important;
}

/* REDUZIR ESPAÇAMENTO VERTICAL EM GRIDS */
.grid.gap-4 {
    gap: 0.25rem !important;
}

.grid.gap-6 {
    gap: 0.5rem !important;
}

/* REDUZIR PADDING EM CARDS - ULTRA COMPACTO */
.p-6 {
    padding: 0.5rem !important;
}

.px-6 {
    padding-left: 0.5rem !important;
    padding-right: 0.5rem !important;
}

.py-6 {
    padding-top: 0.5rem !important;
    padding-bottom: 0.5rem !important;
}

/* REDUZIR PADDING EM TABELAS */
.px-6.py-4 {
    padding: 0.25rem 0.5rem !important;
}

.px-6.py-3 {
    padding: 0.2rem 0.5rem !important;
}

/* REDUZIR ESPAÇAMENTO ENTRE CARDS */
.space-y-6>*+* {
    margin-top: 0.5rem !important;
}

/* GARANTIR VISIBILIDADE DE TEXTO EM BOTÕES */
.bg-cyan-600,
.bg-cyan-700,
.hover\:bg-cyan-700:hover {
    color: white !important;
}

.bg-red-600,
.bg-red-700,
.hover\:bg-red-700:hover {
    color: white !important;
}

.bg-gray-600,
.bg-gray-700,
.hover\:bg-gray-700:hover {
    color: white !important;
}

/* REDUZIR ALTURA DAS LINHAS DA TABELA */
table tbody tr {
    line-height: 1.1 !important;
}

table thead th {
    line-height: 1.1 !important;
    padding: 0.25rem 0.5rem !important;
}

/* REDUZIR TODAS AS MARGENS */
.mb-6 {
    margin-bottom: 0.5rem !important;
}

.mt-6 {
    margin-top: 0.5rem !important;
}

.mb-4 {
    margin-bottom: 0.375rem !important;
}

.mt-4 {
    margin-top: 0.375rem !important;
}

.mb-3 {
    margin-bottom: 0.25rem !important;
}

.mb-2 {
    margin-bottom: 0.15rem !important;
}

.mb-1 {
    margin-bottom: 0.1rem !important;
}

/* COMPACTAR GRIDS RESPONSIVOS */
.grid.grid-cols-1.md\:grid-cols-2,
.grid.grid-cols-1.md\:grid-cols-3,
.grid.grid-cols-1.md\:grid-cols-4 {
    row-gap: 0.25rem !important;
    column-gap: 0.5rem !important;
}

/* REDUZIR PADDING GERAL */
.p-4 {
    padding: 0.375rem !important;
}

.py-4 {
    padding-top: 0.375rem !important;
    padding-bottom: 0.375rem !important;
}

.py-3 {
    padding-top: 0.25rem !important;
    padding-bottom: 0.25rem !important;
}

.py-2 {
    padding-top: 0.15rem !important;
    padding-bottom: 0.15rem !important;
}

.px-4 {
    padding-left: 0.375rem !important;
    padding-right: 0.375rem !important;
}

.px-3 {
    padding-left: 0.25rem !important;
    padding-right: 0.25rem !important;
}

/* COMPACTAR HEADERS DE CARDS */
.bg-gradient-to-r {
    padding: 0.375rem 0.5rem !important;
}

/* REDUZIR TAMANHO DE FONTES */
.text-lg {
    font-size: 0.95rem !important;
    line-height: 1.1 !important;
}

.text-xl {
    font-size: 1rem !important;
    line-height: 1.1 !important;
}

.text-sm {
    font-size: 0.8rem !important;
    line-height: 1.1 !important;
}

.text-xs {
    font-size: 0.7rem !important;
    line-height: 1.1 !important;
}

/* COMPACTAR BADGES */
.rounded-full {
    padding: 0.15rem 0.5rem !important;
}

/* REDUZIR ESPAÇAMENTO EM GRIDS DE DADOS */
.grid.gap-x-4 {
    column-gap: 0.375rem !important;
}

.grid.gap-y-2 {
    row-gap: 0.15rem !important;
}

/* COMPACTAR ALERTAS */
.border-l-4 {
    padding: 0.375rem !important;
}

/* COMPACTAR ELEMENTOS SMALL */
small {
    line-height: 1.1 !important;
    display: block;
    margin-bottom: 0.1rem !important;
}

/* REDUZIR ESPAÇAMENTO EM LISTAS */
dl {
    margin-bottom: 0 !important;
}

dt {
    margin-bottom: 0.1rem !important;
    line-height: 1.1 !important;
}

dd {
    margin-bottom: 0.15rem !important;
    line-height: 1.1 !important;
}

/* COMPACTAR OVERFLOW CONTAINERS */
.overflow-hidden {
    padding: 0 !important;
}

/* REDUZIR PADDING EM CARDS SIDEBAR */
.lg\:col-span-1 .p-6 {
    padding: 0.375rem !important;
}

/* COMPACTAR ESPAÇAMENTO VERTICAL GLOBAL */
.pt-4 {
    padding-top: 0.375rem !important;
}

.pb-4 {
    padding-bottom: 0.375rem !important;
}

.pt-2 {
    padding-top: 0.15rem !important;
}

.pb-2 {
    padding-bottom: 0.15rem !important;
}

/* COMPACTAR DIVS INTERNAS */
div {
    margin-bottom: 0 !important;
}

/* REDUZIR ESPAÇAMENTO EM BORDERS */
.border-l-4 {
    padding-left: 0.5rem !important;
}

/* COMPACTAR STRONG E LABELS */
strong,
label {
    line-height: 1.1 !important;
    display: block;
    margin-bottom: 0.1rem !important;
}

/* REDUZIR ESPAÇAMENTO EM CARDS COLORIDOS */
.bg-gray-50 {
    padding: 0.375rem !important;
}

/* COMPACTAR ROUNDED CONTAINERS */
.rounded-lg {
    padding: 0 !important;
}

/* REDUZIR SHADOW SPACING */
.shadow-sm {
    margin-bottom: 0.5rem !important;
}

/* COMPACTAR FLEX ITEMS */
.flex.items-center {
    gap: 0.25rem !important;
}

/* REDUZIR ESPAÇAMENTO EM BOTÕES */
button,
a.inline-flex {
    padding: 0.375rem 0.75rem !important;
    line-height: 1.1 !important;
}

/* COMPACTAR INPUTS E SELECTS */
input,
select,
textarea {
    padding: 0.375rem !important;
    line-height: 1.2 !important;
}

/* REDUZIR ESPAÇAMENTO NO BODY */
body {
    line-height: 1.2 !important;
}

/* COMPACTAR CONTAINERS PRINCIPAIS */
.container,
.container-fluid {
    padding-top: 0.5rem !important;
    padding-bottom: 0.5rem !important;
}

/* ============================================
   REGRAS ESPECÍFICAS PARA CARDS DE VALORES
   ============================================ */

/* Compactar boxes de valores centralizados */
.text-center.p-4 {
    padding: 0.25rem !important;
}

.text-center.bg-gray-50 {
    padding: 0.25rem !important;
}

/* Reduzir fontes grandes em valores */
.text-2xl {
    font-size: 1.25rem !important;
    line-height: 1.1 !important;
    margin: 0 !important;
}

h3.text-2xl {
    font-size: 1.25rem !important;
    line-height: 1.1 !important;
    margin: 0 !important;
}

/* Compactar labels acima dos valores */
.text-center small {
    margin-bottom: 0.1rem !important;
    line-height: 1 !important;
}

/* Reduzir espaçamento em grids de 3 colunas */
.grid.md\:grid-cols-3 {
    gap: 0.25rem !important;
}

/* Compactar rounded boxes */
.rounded-lg.bg-gray-50 {
    padding: 0.25rem !important;
}

/* Reduzir altura de h5 em cards */
h5.font-semibold {
    font-size: 0.9rem !important;
    line-height: 1.1 !important;
    margin: 0 !important;
}

/* ============================================
   CORREÇÃO DE BOTÕES BRANCOS E QUEBRA DE LINHA
   ============================================ */

/* Garantir que TODOS os botões inline-flex tenham texto visível */
a.inline-flex,
button.inline-flex {
    color: white !important;
}

/* Prevenir quebra de linha em códigos de patrimônio */
td:first-child {
    white-space: nowrap !important;
}

/* Prevenir quebra de linha em células de tabela */
td {
    white-space: nowrap !important;
}

/* Garantir que links em células não quebrem */
td a {
    white-space: nowrap !important;
}

/* Código patrimonial específico */
td strong,
td .text-blue-600 {
    white-space: nowrap !important;
    display: inline-block !important;
}

/* ============================================
   CORREÇÃO DE HEADERS E ÍCONES DE AÇÕES
   ============================================ */

/* 1. CENTRALIZAR TÍTULO "AÇÕES" EM COLABORADORES */
thead th:last-child {
    text-align: center !important;
}

/* 2. GARANTIR HEADER VISÍVEL EM PATRIMÔNIOS */
thead.bg-gray-50 {
    background-color: #f9fafb !important;
}

thead.bg-blue-600 {
    background-color: #2563eb !important;
}

/* 3. ÍCONES DE AÇÕES SEMPRE VISÍVEIS E ESCUROS */
td a i,
td button i {
    color: inherit !important;
    opacity: 1 !important;
}

/* Ícones em links de ação */
a.text-blue-600 i,
a.text-gray-600 i {
    color: inherit !important;
}

/* 4. REMOVER HOVER QUE DEIXA ÍCONES FRACOS */
tr:hover td a i {
    opacity: 1 !important;
}

/* 5. GARANTIR COR DOS ÍCONES EM MOVIMENTAÇÕES */
.bi-eye,
.bi-pencil-square {
    color: currentColor !important;
    opacity: 1 !important;
}

/* ============================================
   CORREÇÃO ESPECÍFICA DE CORES DE ÍCONES
   ============================================ */

/* Garantir que ícones mantenham suas cores específicas */
.text-blue-600 {
    color: #2563eb !important;
}

.text-gray-600 {
    color: #4b5563 !important;
}

.text-cyan-600 {
    color: #0891b2 !important;
}

/* Hover states */
.hover\:text-blue-800:hover {
    color: #1e40af !important;
}

.hover\:text-gray-800:hover {
    color: #1f2937 !important;
}

.hover\:text-cyan-800:hover {
    color: #155e75 !important;
}

/* Garantir que bg-gray-50 em thead funcione */
thead.bg-gray-50 {
    background-color: #f9fafb !important;
}

/* Garantir texto escuro em thead bg-gray-50 */
thead.bg-gray-50 th {
    color: #6b7280 !important;
}

/* ============================================
   CORREÇÃO FINAL - ÍCONES SEMPRE VISÍVEIS
   ============================================ */

/* REMOVER regra que força branco em todos inline-flex */
/* Aplicar branco APENAS em botões, não em links de ação */

/* Botões devem ter texto branco, EXCETO botões transparentes (links) */
button.inline-flex:not(.bg-transparent) {
    color: white !important;
}

/* Links inline-flex devem manter sua cor original */
a.inline-flex {
    color: inherit !important;
}

/* Garantir que ícones em links mantenham cor do pai */
a.inline-flex i {
    color: inherit !important;
}

/* Cores específicas para ícones de ação */
a.text-blue-600,
a.text-blue-600 i {
    color: #2563eb !important;
}

a.text-gray-600,
a.text-gray-600 i {
    color: #4b5563 !important;
}

a.text-cyan-600,
a.text-cyan-600 i {
    color: #0891b2 !important;
}

/* Hover states mantêm cores */
a.hover\:text-blue-800:hover,
a.hover\:text-blue-800:hover i {
    color: #1e40af !important;
}

a.hover\:text-gray-800:hover,
a.hover\:text-gray-800:hover i {
    color: #1f2937 !important;
}

a.hover\:text-cyan-800:hover,
a.hover\:text-cyan-800:hover i {
    color: #155e75 !important;
}

/* Garantir visibilidade em movimentações */
td a.inline-flex i {
    opacity: 1 !important;
    color: inherit !important;
}

/* ============================================
   MODAL INVENTÁRIO MAIS LARGO
   ============================================ */

/* Aumentar largura do modal para evitar quebra de linha */
.modal-xl {
    max-width: 1400px !important;
    /* Era 1140px */
}

/* Garantir que títulos não quebrem */
.modal-header h5,
.modal-body h6 {
    white-space: nowrap !important;
}

/* ============================================
   CORREÇÃO CRÍTICA - BOTÃO "ESQUECEU SUA SENHA?"
   ============================================ */

/* Força cor azul no botão transparente - MÁXIMA ESPECIFICIDADE */
button.text-sm.text-blue-600.bg-transparent,
button.inline-flex.bg-transparent,
button[class*="bg-transparent"][class*="text-blue"] {
    color: #2563eb !important;
    /* Azul do Tailwind text-blue-600 */
}