.multi-select {
    display: none !important;
}

.multi-select-input-wrapper {
    position: relative;
}

.multi-select-input-wrapper > .form-control {
    cursor: pointer !important;
    padding-right: 2.25rem;
}

.multi-select-input-wrapper::after {
    content: "\f078";
    font-family: "Font Awesome 6 Free", sans-serif;
    font-weight: 900;
    position: absolute;
    right: 0.75rem;
    top: 50%;
    translate: 0 -50%;
    display: flex;
    justify-content: center;
    align-items: center;
    width: 1rem;
    height: 1rem;
    font-size: 0.75rem;
    pointer-events: none;
}

.multi-select-dropdown {
    display: block;
    position: absolute;
    top: 100%;
    left: 0;
    list-style: none;
    margin: 0.25rem 0 0 0;
    padding: 0.5rem;
    width: 100%;
    z-index: 50;
    max-height: min(400px, 90vh);
    overflow-y: auto;
    background: #fff;
    border: 1px solid var(--bs-border-color);
    border-radius: 0.375rem;
    opacity: 0;
    visibility: hidden;
    box-shadow: 0 .5rem 1rem rgba(var(--bs-body-color-rgb),.15);
    transform-origin: top;
    transform: scale(0.95);
    transition-property: transform, opacity;
    transition-duration: 0.2s;
    transition-timing-function: cubic-bezier(.4,0,.2,1);
}

.multi-select-dropdown.show:not(:empty) {
    opacity: 1;
    transform: scale(1);
    visibility: visible;
}

.multi-select-dropdown > li:not(:last-child) {
    margin-bottom: 0.25rem;
}

.multi-select-dropdown > li.option > button {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 0.75rem;
    width: 100%;
    background-color: var(--bs-light-bg-subtle);
    border: 1px solid var(--bs-light-border-subtle);
    color: var(--bs-dark);
    text-align: left;
    border-radius: 0.375rem;
    transition: color .2s ease, background-color .2s ease, border-color .2s ease;
}

.multi-select-dropdown > li.option > button.selected {
    background-color: var(--bs-primary-bg-subtle);
    border-color: var(--bs-primary-border-subtle);;
    color: var(--bs-primary);
}

.multi-select-dropdown > li.option > button:hover,
.multi-select-dropdown > li.option > button:focus {
    background-color: var(--bs-light);
}

.multi-select-dropdown > li.option > button.selected:hover,
.multi-select-dropdown > li.option > button.selected:focus {
    background-color: var(--bs-primary-bg-subtle);
}

.multi-select-dropdown > li.option > button::after {
    content: "\f00c";
    color: var(--bs-primary);
    font-weight: 900;
    font-size: 1.25rem;
    display: flex;
    width: 1rem;
    height: 1rem;
    justify-content: center;
    align-items: center;
    font-family: "Font Awesome 6 Free", sans-serif;
    opacity: 0;
    transform: scale(0.8);
    transition: opacity .2s ease, transform .2s ease;
}

.multi-select-dropdown > li.option > button.selected::after {
    opacity: 1;
    transform: scale(1);
}
