:root {
    color-scheme: light;
}

html[data-bs-theme="dark"] {
    color-scheme: dark;
}

.theme-mode-toggle {
    display: inline-flex;
    width: 36px;
    height: 36px;
    flex: 0 0 36px;
    align-items: center;
    justify-content: center;
    padding: 0;
    border: 1px solid rgba(7, 20, 55, 0.12);
    border-radius: 7px;
    background: #f4f4f4;
    color: #181c32;
    cursor: pointer;
    transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.theme-mode-toggle:hover {
    background: #e9e9ed;
    transform: translateY(-1px);
}

.theme-mode-toggle:focus-visible {
    outline: 3px solid rgba(27, 132, 255, 0.32);
    outline-offset: 2px;
}

.theme-mode-toggle__icon {
    width: 19px;
    height: 19px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.7;
}

.theme-mode-toggle__icon--moon {
    fill: currentColor;
    stroke: none;
}

html[data-bs-theme="light"] .theme-mode-toggle__icon--sun,
html[data-bs-theme="dark"] .theme-mode-toggle__icon--moon {
    display: none;
}

html[data-bs-theme="dark"] .theme-mode-toggle {
    border-color: rgba(255, 255, 255, 0.12);
    background: #2b2b32;
    color: #f5f5f5;
}

html[data-bs-theme="dark"] .theme-mode-toggle:hover {
    background: #383840;
}

.theme-logo--dark {
    display: none !important;
}

html[data-bs-theme="dark"] .theme-logo--light {
    display: none !important;
}

html[data-bs-theme="dark"] .theme-logo--dark {
    display: inline-block !important;
}

html[data-bs-theme="dark"] body#kt_app_body .bg-white,
html[data-bs-theme="dark"] body#kt_app_body .car-item,
html[data-bs-theme="dark"] body#kt_app_body .car-sort {
    background-color: var(--bs-body-bg) !important;
}

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

html[data-bs-theme="dark"] body#kt_app_body .border-black,
html[data-bs-theme="dark"] body#kt_app_body .border-dark {
    border-color: var(--bs-gray-400) !important;
}

html[data-bs-theme="dark"] body#kt_app_body .skeleton-rect,
html[data-bs-theme="dark"] body#kt_app_body .skeleton-circle {
    background: var(--bs-gray-300);
}

html[data-bs-theme="dark"] body#kt_app_body .vs__dropdown-toggle {
    border-color: var(--bs-gray-300) !important;
    background: var(--bs-body-bg) !important;
    color: var(--bs-gray-900);
}

html[data-bs-theme="dark"] body#kt_app_body .vs__selected {
    border-color: var(--bs-gray-300) !important;
    background: var(--bs-gray-200) !important;
    color: var(--bs-gray-900);
}

html[data-bs-theme="dark"] {
    --vs-controls-color: #9a9cae;
    --vs-border-color: #363843;
    --vs-dropdown-bg: #1c1d22;
    --vs-dropdown-color: #f5f5f5;
    --vs-dropdown-option-color: #f5f5f5;
    --vs-dropdown-option--active-bg: #006ae6;
    --vs-dropdown-option--active-color: #ffffff;
    --vs-selected-bg: #26272f;
    --vs-selected-color: #f5f5f5;
    --vs-search-input-color: #f5f5f5;
}

html[data-bs-theme="dark"] .vs__dropdown-menu,
html[data-bs-theme="dark"] .vs__search,
html[data-bs-theme="dark"] .vs__search::placeholder {
    color: var(--vs-dropdown-color);
}

html[data-bs-theme="dark"] .select2-container .select2-selection,
html[data-bs-theme="dark"] .select2-container .select2-dropdown,
html[data-bs-theme="dark"] .select2-container .select2-search__field {
    border-color: #363843 !important;
    background: #1c1d22 !important;
    color: #f5f5f5 !important;
}

html[data-bs-theme="dark"] .select2-container .select2-selection__rendered,
html[data-bs-theme="dark"] .select2-container .select2-selection__placeholder,
html[data-bs-theme="dark"] .select2-container .select2-results__option,
html[data-bs-theme="dark"] .select2-container .select2-selection__choice {
    color: #f5f5f5 !important;
}

html[data-bs-theme="dark"] .select2-container .select2-results__option--highlighted,
html[data-bs-theme="dark"] .select2-container .select2-results__option[aria-selected="true"] {
    background: #006ae6 !important;
    color: #ffffff !important;
}

html[data-bs-theme="dark"] .swal-modal,
html[data-bs-theme="dark"] .swal-content__input,
html[data-bs-theme="dark"] .swal-content__textarea {
    border-color: #363843;
    background: #1c1d22;
    color: #f5f5f5;
}

html[data-bs-theme="dark"] .swal-title,
html[data-bs-theme="dark"] .swal-text {
    color: #f5f5f5;
}

html[data-bs-theme="dark"] .apexcharts-tooltip,
html[data-bs-theme="dark"] .apexcharts-tooltip-title,
html[data-bs-theme="dark"] .apexcharts-xaxistooltip,
html[data-bs-theme="dark"] .apexcharts-yaxistooltip {
    border-color: #363843 !important;
    background: #1c1d22 !important;
    color: #f5f5f5 !important;
}

html[data-bs-theme="dark"] .apexcharts-xaxis text,
html[data-bs-theme="dark"] .apexcharts-yaxis text,
html[data-bs-theme="dark"] .apexcharts-legend-text {
    fill: #b5b7c8 !important;
    color: #b5b7c8 !important;
}

html[data-bs-theme="dark"] body.main-body {
    background: #151521;
    color: #c5c5d7;
}

html[data-bs-theme="dark"] body.main-body .tabs-style-1 .main-nav-line .nav-link.active,
html[data-bs-theme="dark"] body.main-body td.readonly {
    border-color: #3b3b52;
    background: #29293d;
    color: #f1f1f4;
}

html[data-bs-theme="dark"] body.main-body td.is-reso {
    background: #4a421d;
    color: #fff4b8;
}

html[data-bs-theme="dark"] body.main-body .col-left-border,
html[data-bs-theme="dark"] body.main-body .col-right-border,
html[data-bs-theme="dark"] body.main-body .col-x-border {
    border-color: #8e8ea0 !important;
}

html[data-bs-theme="dark"] body.main-body .nav.nav-tabs.tab-style-1 {
    background: #29293d;
}

html[data-bs-theme="dark"] {
    --theme-bg-light: #171722;
    --body-text-color: #b5b5c3;
    --box-shadow: 0 0 40px 5px rgba(0, 0, 0, 0.24);
    --box-shadow2: 0 0 15px rgba(0, 0, 0, 0.45);
    --border-info-color: rgba(255, 255, 255, 0.14);
    --border-info-color2: rgba(255, 255, 255, 0.09);
}

html[data-bs-theme="dark"] body.front-body {
    background: #151521;
    color: var(--body-text-color);
}

html[data-bs-theme="dark"] body.front-body h1,
html[data-bs-theme="dark"] body.front-body h2,
html[data-bs-theme="dark"] body.front-body h3,
html[data-bs-theme="dark"] body.front-body h4,
html[data-bs-theme="dark"] body.front-body h5,
html[data-bs-theme="dark"] body.front-body h6,
html[data-bs-theme="dark"] body.front-body .car-price,
html[data-bs-theme="dark"] body.front-body .navbar .nav-link {
    color: #f5f8fa;
}

html[data-bs-theme="dark"] body.front-body .navbar,
html[data-bs-theme="dark"] body.front-body .navbar.fixed-top,
html[data-bs-theme="dark"] body.front-body .navbar-collapse,
html[data-bs-theme="dark"] body.front-body .car-sort,
html[data-bs-theme="dark"] body.front-body .table-ads,
html[data-bs-theme="dark"] body.front-body .login-form,
html[data-bs-theme="dark"] body.front-body .modal-content,
html[data-bs-theme="dark"] body.front-body .dropdown-menu,
html[data-bs-theme="dark"] body.front-body .car-item,
html[data-bs-theme="dark"] body.front-body .car-widget,
html[data-bs-theme="dark"] body.front-body .car-single-widget,
html[data-bs-theme="dark"] body.front-body .find-car-form,
html[data-bs-theme="dark"] body.front-body .user-profile-card,
html[data-bs-theme="dark"] body.front-body .user-profile-sidebar,
html[data-bs-theme="dark"] body.front-body .card,
html[data-bs-theme="dark"] body.front-body .accordion-item {
    border-color: #323248;
    background: #1e1e2d;
    color: #f5f8fa;
}

html[data-bs-theme="dark"] body.front-body .form-control,
html[data-bs-theme="dark"] body.front-body .form-select,
html[data-bs-theme="dark"] body.front-body .input-group-text,
html[data-bs-theme="dark"] body.front-body .select2-container--bootstrap-5 .select2-selection {
    border-color: #3b3b52;
    background: #151521;
    color: #f5f8fa;
}

html[data-bs-theme="dark"] body.front-body .table {
    --bs-table-bg: transparent;
    --bs-table-color: #f5f8fa;
    --bs-table-border-color: #3b3b52;
    color: #f5f8fa;
}

html[data-bs-theme="dark"] body.front-body .text-dark,
html[data-bs-theme="dark"] body.front-body .text-black,
html[data-bs-theme="dark"] body.front-body .dropdown-menu a.dropdown-item {
    color: #f5f8fa !important;
}

html[data-bs-theme="dark"] body.front-body .text-muted,
html[data-bs-theme="dark"] body.front-body .form-text {
    color: #aeb4c3 !important;
}

html[data-bs-theme="dark"] body.front-body .dropdown-menu .dropdown-item:hover,
html[data-bs-theme="dark"] body.front-body .dropdown-menu .dropdown-item:focus,
html[data-bs-theme="dark"] body.front-body .dropdown-menu .dropdown-item.active {
    background: #29293d;
    color: #ffffff !important;
}

html[data-bs-theme="dark"] body.front-body .form-control::placeholder {
    color: #aeb4c3;
    opacity: 1;
}

html[data-bs-theme="dark"] body.front-body .btn-close {
    filter: invert(1) grayscale(100%) brightness(180%);
}

html[data-bs-theme="dark"] body.login-body {
    background: #15171c;
    color: #f5f5f5;
}

html[data-bs-theme="dark"] body.login-body .login-bg-image::before {
    background: rgba(15, 17, 22, 0.74);
}

html[data-bs-theme="dark"] body.login-body .form-control {
    border-color: #363843;
    color: #f5f5f5;
}

html[data-bs-theme="dark"] body.login-body .theme-login-copy,
html[data-bs-theme="dark"] body.login-body .theme-login-copy h1 {
    color: #ffffff;
}

.theme-mode-toggle--fixed {
    position: fixed;
    z-index: 1055;
    top: 18px;
    right: 18px;
}

@media (max-width: 575.98px) {
    .theme-mode-toggle {
        width: 34px;
        height: 34px;
        flex-basis: 34px;
    }

    .theme-mode-toggle--fixed {
        top: 12px;
        right: 12px;
    }
}
