/* Tema Escuro - Tauri Contabil */
body.dark-theme {
    background-color: #1a1a2e;
    color: #e4e4e7;
}

/* Sidebar Dark */
body.dark-theme aside {
    background: linear-gradient(195deg, #16213e 0%, #0f1419 100%);
}

/* Cards Dark */
body.dark-theme .card {
    background-color: #16213e;
    border-color: #2d3748;
    color: #e4e4e7;
}

body.dark-theme .card-header {
    background-color: #1e2a3a;
    border-bottom-color: #2d3748;
    color: #e4e4e7;
}

/* Forms Dark */
body.dark-theme .form-control,
body.dark-theme .form-select {
    background-color: #1e2a3a;
    border-color: #2d3748;
    color: #e4e4e7;
}

body.dark-theme .form-control:focus,
body.dark-theme .form-select:focus {
    background-color: #1e2a3a;
    border-color: #b39c7c;
    color: #e4e4e7;
}

body.dark-theme .form-control::placeholder {
    color: #718096;
}

/* Buttons Dark */
body.dark-theme .btn-outline-secondary {
    color: #e4e4e7;
    border-color: #4a5568;
}

body.dark-theme .btn-outline-secondary:hover {
    background-color: #2d3748;
    border-color: #4a5568;
    color: #e4e4e7;
}

/* Tables Dark */
body.dark-theme .table {
    color: #e4e4e7;
}

body.dark-theme .table-hover tbody tr:hover {
    background-color: #1e2a3a;
}

body.dark-theme .table thead th {
    border-bottom-color: #2d3748;
}

body.dark-theme .table tbody td {
    border-bottom-color: #2d3748;
}

/* Nav Tabs Dark */
body.dark-theme .nav-tabs {
    border-bottom-color: #2d3748;
}

body.dark-theme .nav-tabs .nav-link {
    color: #a0aec0;
}

body.dark-theme .nav-tabs .nav-link.active {
    background-color: #16213e;
    border-color: #2d3748 #2d3748 #16213e;
    color: #b39c7c;
}

body.dark-theme .nav-tabs .nav-link:hover {
    border-color: #2d3748;
    color: #b39c7c;
}

/* Badges Dark */
body.dark-theme .badge.bg-primary {
    background-color: #b39c7c !important;
}

body.dark-theme .badge.bg-secondary {
    background-color: #4a5568 !important;
}

/* Alerts Dark */
body.dark-theme .alert-info {
    background-color: #1e3a5f;
    border-color: #2563eb;
    color: #93c5fd;
}

body.dark-theme .alert-warning {
    background-color: #451a03;
    border-color: #f59e0b;
    color: #fbbf24;
}

body.dark-theme .alert-danger {
    background-color: #450a0a;
    border-color: #dc2626;
    color: #fca5a5;
}

/* Text Colors Dark */
body.dark-theme .text-muted {
    color: #718096 !important;
}

body.dark-theme .text-secondary {
    color: #b39c7c !important;
}

/* Dropdowns Dark */
body.dark-theme .dropdown-menu {
    background-color: #16213e;
    border-color: #2d3748;
}

body.dark-theme .dropdown-item {
    color: #e4e4e7;
}

body.dark-theme .dropdown-item:hover {
    background-color: #1e2a3a;
    color: #b39c7c;
}

/* Modal Dark */
body.dark-theme .modal-content {
    background-color: #16213e;
    color: #e4e4e7;
}

body.dark-theme .modal-header {
    border-bottom-color: #2d3748;
}

body.dark-theme .modal-footer {
    border-top-color: #2d3748;
}

body.dark-theme .btn-close {
    filter: invert(1);
}

/* Form Check/Switch Dark */
body.dark-theme .form-check-input {
    background-color: #1e2a3a;
    border-color: #4a5568;
}

body.dark-theme .form-check-input:checked {
    background-color: #b39c7c;
    border-color: #b39c7c;
}

/* Charts Dark Mode Support */
body.dark-theme canvas {
    filter: brightness(0.95);
}

/* Scrollbar Dark */
body.dark-theme ::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

body.dark-theme ::-webkit-scrollbar-track {
    background: #1a1a2e;
}

body.dark-theme ::-webkit-scrollbar-thumb {
    background: #4a5568;
    border-radius: 4px;
}

body.dark-theme ::-webkit-scrollbar-thumb:hover {
    background: #718096;
}

/* Transitions */
body,
.card,
.form-control,
.form-select,
.btn,
.nav-link,
.dropdown-menu,
.modal-content {
    transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}

/* Border colors for dark cards */
body.dark-theme .card.border-primary {
    border-color: #3b82f6 !important;
}

body.dark-theme .card.border-success {
    border-color: #22c55e !important;
}

body.dark-theme .card.border-danger {
    border-color: #ef4444 !important;
}

body.dark-theme .card.border-info {
    border-color: #3b82f6 !important;
}

body.dark-theme .card.border-secondary {
    border-color: #4a5568 !important;
}

/* Links */
body.dark-theme a {
    color: #b39c7c;
}

body.dark-theme a:hover {
    color: #d4c4a8;
}

/* Inputs desabilitados */
body.dark-theme .form-control:disabled,
body.dark-theme .form-select:disabled {
    background-color: #0f1419;
    color: #4a5568;
}
