/* assets/css/dark-mode.css */

[data-bs-theme="dark"] {
    --bg-color: #0f1318;
    --surface-color: #161c24;
    --surface-soft: #1d2530;
    --surface-strong: #202a36;
    --text-color: #e7edf5;
    --text-muted: #a7b3c2;
    --border-color: #2b3644;
    --input-bg: #18212b;
    --hover-bg: rgba(255, 107, 53, 0.12);
    --shadow-color: rgba(0, 0, 0, 0.32);
}

[data-bs-theme="dark"] html,
[data-bs-theme="dark"] body {
    background-color: var(--bg-color);
    color: var(--text-color);
}

[data-bs-theme="dark"] body,
[data-bs-theme="dark"] main,
[data-bs-theme="dark"] section,
[data-bs-theme="dark"] .container,
[data-bs-theme="dark"] .container-fluid {
    color: var(--text-color);
}

[data-bs-theme="dark"] a:not(.btn):not(.nav-link):not(.dropdown-item) {
    color: #ff9b73;
}

[data-bs-theme="dark"] a:not(.btn):not(.nav-link):not(.dropdown-item):hover {
    color: #ffb493;
}

[data-bs-theme="dark"] .bg-white,
[data-bs-theme="dark"] .bg-light,
[data-bs-theme="dark"] .bg-body,
[data-bs-theme="dark"] .bg-light-green,
[data-bs-theme="dark"] .bg-light-orange {
    background-color: var(--surface-color) !important;
    color: var(--text-color) !important;
}

[data-bs-theme="dark"] .text-dark,
[data-bs-theme="dark"] .text-body,
[data-bs-theme="dark"] .text-black {
    color: var(--text-color) !important;
}

[data-bs-theme="dark"] .text-muted,
[data-bs-theme="dark"] .text-secondary,
[data-bs-theme="dark"] .small.text-muted,
[data-bs-theme="dark"] .form-text {
    color: var(--text-muted) !important;
}

[data-bs-theme="dark"] .card,
[data-bs-theme="dark"] .modal-content,
[data-bs-theme="dark"] .offcanvas,
[data-bs-theme="dark"] .accordion-item,
[data-bs-theme="dark"] .list-group-item,
[data-bs-theme="dark"] .dropdown-menu,
[data-bs-theme="dark"] .search-results,
[data-bs-theme="dark"] .toast,
[data-bs-theme="dark"] .popover {
    background-color: var(--surface-color);
    color: var(--text-color);
    border-color: var(--border-color);
    box-shadow: 0 12px 30px var(--shadow-color);
}

[data-bs-theme="dark"] .card-header,
[data-bs-theme="dark"] .card-footer,
[data-bs-theme="dark"] .modal-header,
[data-bs-theme="dark"] .modal-footer,
[data-bs-theme="dark"] .offcanvas-header,
[data-bs-theme="dark"] .accordion-button:not(.collapsed) {
    background-color: var(--surface-soft);
    color: var(--text-color);
    border-color: var(--border-color);
}

[data-bs-theme="dark"] .accordion-button,
[data-bs-theme="dark"] .accordion-button.collapsed {
    background-color: var(--surface-color);
    color: var(--text-color);
}

[data-bs-theme="dark"] .accordion-button::after,
[data-bs-theme="dark"] .navbar-toggler {
    filter: invert(1) grayscale(1);
}

[data-bs-theme="dark"] .table {
    --bs-table-bg: var(--surface-color);
    --bs-table-color: var(--text-color);
    --bs-table-border-color: var(--border-color);
    --bs-table-striped-bg: rgba(255, 255, 255, 0.03);
    --bs-table-hover-bg: rgba(255, 107, 53, 0.08);
    color: var(--text-color);
    border-color: var(--border-color);
}

[data-bs-theme="dark"] .table-light,
[data-bs-theme="dark"] .thead-light {
    --bs-table-bg: var(--surface-soft);
    --bs-table-color: var(--text-color);
}

[data-bs-theme="dark"] .form-control,
[data-bs-theme="dark"] .form-select,
[data-bs-theme="dark"] .input-group-text {
    background-color: var(--input-bg);
    border-color: var(--border-color);
    color: var(--text-color);
}

[data-bs-theme="dark"] .form-control:focus,
[data-bs-theme="dark"] .form-select:focus {
    background-color: var(--input-bg);
    color: var(--text-color);
    border-color: rgba(255, 107, 53, 0.65);
    box-shadow: 0 0 0 0.25rem rgba(255, 107, 53, 0.18);
}

[data-bs-theme="dark"] .form-control::placeholder,
[data-bs-theme="dark"] input::placeholder,
[data-bs-theme="dark"] textarea::placeholder {
    color: #8e9aac;
}

[data-bs-theme="dark"] .btn-close {
    filter: invert(1) grayscale(1);
}

[data-bs-theme="dark"] .dropdown-item,
[data-bs-theme="dark"] .list-group-item-action,
[data-bs-theme="dark"] .page-link,
[data-bs-theme="dark"] .nav-tabs .nav-link,
[data-bs-theme="dark"] .nav-pills .nav-link,
[data-bs-theme="dark"] .breadcrumb-item a {
    color: var(--text-color);
}

[data-bs-theme="dark"] .dropdown-item:hover,
[data-bs-theme="dark"] .dropdown-item:focus,
[data-bs-theme="dark"] .list-group-item-action:hover,
[data-bs-theme="dark"] .list-group-item-action:focus,
[data-bs-theme="dark"] .page-link:hover,
[data-bs-theme="dark"] .search-result-item:hover {
    background-color: var(--hover-bg);
    color: var(--text-color);
}

[data-bs-theme="dark"] .nav-tabs,
[data-bs-theme="dark"] .nav-tabs .nav-link,
[data-bs-theme="dark"] .page-link,
[data-bs-theme="dark"] .pagination,
[data-bs-theme="dark"] .breadcrumb,
[data-bs-theme="dark"] hr {
    border-color: var(--border-color);
}

[data-bs-theme="dark"] .nav-tabs .nav-link.active,
[data-bs-theme="dark"] .nav-pills .nav-link.active,
[data-bs-theme="dark"] .page-item.active .page-link {
    background-color: #ff6b35;
    border-color: #ff6b35;
    color: #ffffff !important;
}

[data-bs-theme="dark"] .page-item.disabled .page-link {
    background-color: var(--surface-color);
    border-color: var(--border-color);
    color: #738195;
}

[data-bs-theme="dark"] .alert {
    border-color: transparent;
    box-shadow: 0 10px 24px var(--shadow-color);
}

[data-bs-theme="dark"] .alert-light,
[data-bs-theme="dark"] .alert-secondary,
[data-bs-theme="dark"] .badge.bg-light,
[data-bs-theme="dark"] .bg-light.text-dark,
[data-bs-theme="dark"] .bg-white.text-dark {
    background-color: var(--surface-soft) !important;
    color: var(--text-color) !important;
    border-color: var(--border-color) !important;
}

[data-bs-theme="dark"] .badge.text-dark,
[data-bs-theme="dark"] .badge.bg-warning.text-dark {
    color: #101418 !important;
}

[data-bs-theme="dark"] .navbar:not(.site-header),
[data-bs-theme="dark"] footer,
[data-bs-theme="dark"] .footer,
[data-bs-theme="dark"] .site-footer {
    background-color: #0b1015 !important;
    color: var(--text-color);
}

[data-bs-theme="dark"] .navbar:not(.site-header) .nav-link,
[data-bs-theme="dark"] footer a,
[data-bs-theme="dark"] .footer a,
[data-bs-theme="dark"] .site-footer a {
    color: var(--text-color);
}

[data-bs-theme="dark"] .header-search-group {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(255, 255, 255, 0.08);
}

[data-bs-theme="dark"] .header-search-input,
[data-bs-theme="dark"] .header-search-input:focus {
    background: transparent;
    color: #ffffff;
}

[data-bs-theme="dark"] .header-search-input::placeholder {
    color: rgba(255, 255, 255, 0.68);
}

[data-bs-theme="dark"] .header-search-btn,
[data-bs-theme="dark"] .header-icon-btn {
    border-color: rgba(255, 255, 255, 0.18) !important;
}

[data-bs-theme="dark"] .header-icon-btn:hover,
[data-bs-theme="dark"] .header-search-btn:hover {
    background: rgba(255, 255, 255, 0.08);
}

[data-bs-theme="dark"] .search-result-item,
[data-bs-theme="dark"] .dropdown-divider,
[data-bs-theme="dark"] .list-group-item,
[data-bs-theme="dark"] .card,
[data-bs-theme="dark"] .card-header,
[data-bs-theme="dark"] .card-footer {
    border-color: var(--border-color);
}

[data-bs-theme="dark"] .shadow,
[data-bs-theme="dark"] .shadow-sm,
[data-bs-theme="dark"] .shadow-lg {
    box-shadow: 0 12px 30px var(--shadow-color) !important;
}

[data-bs-theme="dark"] img {
    opacity: 0.98;
}

[data-bs-theme="dark"] .table-responsive,
[data-bs-theme="dark"] pre,
[data-bs-theme="dark"] code {
    color: var(--text-color);
}
