
.searchable-select-wrapper {
    position: relative;
    display: inline-block;
}

.searchable-select-wrapper.disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.searchable-select-display {
    cursor: pointer;
    position: relative;
    padding-right: 2.5rem;
    user-select: none;
}

.searchable-select-display.disabled {
    cursor: not-allowed;
    background-color: #e9ecef;
}


.searchable-select-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    z-index: 1050;
    margin-top: 0.25rem;
    background: white;
    border: 1px solid #dee2e6;
    border-radius: 0.375rem;
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
    max-height: 300px;
    overflow: hidden;
}

.searchable-select-search {
    width: 100%;
    border: none;
    border-bottom: 1px solid #dee2e6;
    border-radius: 0.375rem 0.375rem 0 0;
    padding: 0.5rem 0.75rem;
    outline: none;
}

.searchable-select-search:focus {
    color: var(--bs-body-color);
    background-color: var(--bs-body-bg);
    border-color: #86b7fe;
    outline: 0;
    box-shadow: 0 0 0 .25rem rgba(13, 110, 253, .25);
}

.searchable-select-options {
    max-height: 250px;
    overflow-y: auto;
    overflow-x: hidden;
}

.searchable-select-option {
    padding: 0.5rem 0.75rem;
    cursor: pointer;
    transition: background-color 0.15s;
}

.searchable-select-option:hover:not(.disabled):not(.separator) {
    background-color: #cccccc;
}

.searchable-select-option.selected {
    background-color: var(--main-title-bg);
    color: var(--main-title-txtcolor);
}

.searchable-select-option.disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.searchable-select-option.separator {
    height: 1px;
    padding: 0;
    margin: 0.25rem 0;
    background-color: #cccccc;
    cursor: default;
}

.searchable-select-option.no-results {
    text-align: center;
    font-style: italic;
    color: #6c757d;
}

/* Scrollbar styling */
.searchable-select-options::-webkit-scrollbar {
    width: 8px;
}

.searchable-select-options::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.searchable-select-options::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 4px;
}

.searchable-select-options::-webkit-scrollbar-thumb:hover {
    background: #383838;
}

/* Bootstrap 5 theme adjustments */
.searchable-select-wrapper.theme-bootstrap-5 .searchable-select-display {
    background-color: #fff;
    border: 1px solid #ced4da;
}