/* MedOrbit Select2 — load AFTER select2.min.css */

/* ========== Multi-select field (City, skills, etc.) ========== */
.select2-container--default .select2-selection--multiple,
.select2-container--default .select2-selection--multiple.mo-select2-multi {
    min-height: 48px !important;
    height: auto !important;
    border: 1px solid #d5dee8 !important;
    border-radius: 10px !important;
    background-color: #fff !important;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%234A5B70' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: right 0.85rem center !important;
    background-size: 16px !important;
    padding: 0.45rem 2.25rem 0.45rem 0.55rem !important;
    cursor: pointer !important;
    box-shadow: none !important;
    outline: none !important;
}

.select2-container--default.select2-container--focus .select2-selection--multiple,
.select2-container--default.select2-container--open .select2-selection--multiple,
.select2-container--default.select2-container--focus .select2-selection--multiple.mo-select2-multi,
.select2-container--default.select2-container--open .select2-selection--multiple.mo-select2-multi {
    border-color: #00a8a8 !important;
    box-shadow: 0 0 0 3px rgba(0, 168, 168, 0.16) !important;
}

.select2-container--default .select2-selection--multiple .select2-selection__rendered {
    display: flex !important;
    flex-wrap: wrap !important;
    align-items: center !important;
    gap: 0.4rem !important;
    padding: 0 !important;
    margin: 0 !important;
    list-style: none !important;
    width: 100% !important;
    box-sizing: border-box !important;
}

/* Teal pills — override Select2 default grey boxes */
.select2-container--default .select2-selection--multiple .select2-selection__choice {
    display: inline-flex !important;
    flex-direction: row !important;
    align-items: center !important;
    gap: 0.35rem !important;
    background: #dff5f3 !important;
    background-color: #dff5f3 !important;
    border: 1px solid rgba(0, 168, 168, 0.45) !important;
    border-radius: 999px !important;
    color: #0b1f3a !important;
    font-size: 0.84rem !important;
    font-weight: 600 !important;
    line-height: 1.25 !important;
    padding: 0.32rem 0.55rem !important;
    margin: 0 !important;
    box-shadow: none !important;
    max-width: 100%;
}

.select2-container--default .select2-selection--multiple .select2-selection__choice__display {
    order: 1 !important;
    padding: 0 !important;
    margin: 0 !important;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 12rem;
    color: #0b1f3a !important;
}

/* × on the right of the city name */
.select2-container--default .select2-selection--multiple .select2-selection__choice__remove {
    order: 2 !important;
    position: static !important;
    left: auto !important;
    top: auto !important;
    width: auto !important;
    height: auto !important;
    padding: 0 0.1rem !important;
    margin: 0 !important;
    border: none !important;
    border-right: none !important;
    border-radius: 999px !important;
    background: transparent !important;
    color: #00a8a8 !important;
    font-size: 1.05rem !important;
    font-weight: 700 !important;
    line-height: 1 !important;
    cursor: pointer !important;
}

.select2-container--default .select2-selection--multiple .select2-selection__choice__remove:hover,
.select2-container--default .select2-selection--multiple .select2-selection__choice__remove:focus {
    background: rgba(0, 168, 168, 0.2) !important;
    color: #0b1f3a !important;
    outline: none !important;
}

.select2-container--default .select2-selection--multiple .select2-selection__clear {
    display: none !important;
}

.select2-container--default .select2-selection--multiple .select2-search--inline {
    float: none !important;
    flex: 1 1 auto;
    margin: 0 !important;
    padding: 0 !important;
    width: auto !important;
    max-width: 100%;
}

.select2-container--default .select2-selection--multiple .select2-search--inline .select2-search__field {
    margin: 0 !important;
    padding: 0.25rem 0.1rem !important;
    height: auto !important;
    min-height: 28px !important;
    border: 0 !important;
    outline: none !important;
    box-shadow: none !important;
    background: transparent !important;
    font-family: inherit !important;
    font-size: 0.92rem !important;
    color: #0b1f3a !important;
}

.select2-container--default .select2-selection--multiple .select2-search--inline .select2-search__field::placeholder {
    color: #9AA8BC !important;
    opacity: 1 !important;
}

/* When cities selected: hide the leftover search placeholder row */
.select2-container.mo-multi-filled .select2-selection--multiple .select2-search--inline,
.select2-container--default .select2-selection--multiple.mo-multi-filled .select2-search--inline {
    flex: 0 0 auto !important;
    width: 0 !important;
    min-width: 0 !important;
    max-width: 0 !important;
    overflow: hidden !important;
    margin: 0 !important;
    padding: 0 !important;
}

.select2-container.mo-multi-filled .select2-selection--multiple .select2-search--inline .select2-search__field,
.select2-container--default .select2-selection--multiple.mo-multi-filled .select2-search--inline .select2-search__field {
    width: 0 !important;
    min-width: 0 !important;
    padding: 0 !important;
    opacity: 0 !important;
}

.select2-container--open.mo-multi-filled .select2-selection--multiple .select2-search--inline,
.select2-container--open .select2-selection--multiple.mo-multi-filled .select2-search--inline {
    flex: 1 1 8rem !important;
    width: auto !important;
    min-width: 8rem !important;
    max-width: 100% !important;
    overflow: visible !important;
}

.select2-container--open.mo-multi-filled .select2-selection--multiple .select2-search--inline .select2-search__field,
.select2-container--open .select2-selection--multiple.mo-multi-filled .select2-search--inline .select2-search__field {
    width: 100% !important;
    min-width: 8rem !important;
    opacity: 1 !important;
    padding: 0.25rem 0.1rem !important;
}

/* ========== Dropdown panel ========== */
.mo-select2-dropdown.select2-dropdown {
    border: 1px solid rgba(11, 31, 58, 0.1) !important;
    border-radius: 14px !important;
    box-shadow: 0 18px 48px rgba(11, 31, 58, 0.16) !important;
    overflow: hidden !important;
    padding: 8px !important;
    margin-top: 8px;
    margin-bottom: 0;
    background: #fff;
    box-sizing: border-box;
    z-index: 4000 !important;
}

/* When Select2 flips upward, margin-top would shove the panel into the field. */
.mo-select2-dropdown.select2-dropdown--above {
    margin-top: 0 !important;
    margin-bottom: 8px !important;
}

.mo-select2-dropdown .select2-search--dropdown {
    padding: 0 0 8px !important;
    position: relative;
}

.mo-select2-dropdown .select2-search--dropdown .select2-search__field {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    height: 42px !important;
    border: 1px solid rgba(11, 31, 58, 0.12) !important;
    border-radius: 10px !important;
    padding: 0 12px 0 38px !important;
    margin: 0 !important;
    background-color: #f4f7fb !important;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' stroke='%2364748b' stroke-width='2'%3E%3Ccircle cx='7' cy='7' r='5'/%3E%3Cpath d='m15 15-3.2-3.2'/%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: 12px 50% !important;
    background-size: 15px !important;
    font-size: 0.9rem !important;
    color: #0b1f3a !important;
    outline: none !important;
    box-shadow: none !important;
}

.mo-select2-dropdown .select2-search--dropdown .select2-search__field::placeholder {
    color: #94a3b8;
}

.mo-select2-dropdown .select2-search--dropdown .select2-search__field:focus {
    border-color: #00a8a8 !important;
    background-color: #fff !important;
    box-shadow: 0 0 0 3px rgba(0, 168, 168, 0.16) !important;
}

.mo-select2-dropdown .select2-results {
    padding: 0 !important;
    overflow-x: hidden !important;
}

.mo-select2-dropdown .select2-results__options {
    max-height: 240px !important;
    overflow-x: hidden !important;
    overflow-y: auto !important;
    padding: 0 !important;
    margin: 0 !important;
    scrollbar-width: thin;
    scrollbar-color: rgba(11, 31, 58, 0.28) transparent;
}

.mo-select2-dropdown .select2-results__options::-webkit-scrollbar {
    width: 6px;
    height: 0;
}

.mo-select2-dropdown .select2-results__options::-webkit-scrollbar-track {
    background: transparent;
}

.mo-select2-dropdown .select2-results__options::-webkit-scrollbar-thumb {
    background: rgba(11, 31, 58, 0.22);
    border-radius: 99px;
}

.mo-select2-dropdown .select2-results__option {
    padding: 10px 12px !important;
    margin: 0 0 2px !important;
    border-radius: 10px !important;
    font-size: 0.9rem !important;
    line-height: 1.4 !important;
    white-space: normal !important;
    word-break: break-word !important;
    color: #0b1f3a !important;
    background: transparent !important;
}

.mo-select2-dropdown .select2-results__option--selectable {
    cursor: pointer;
}

.mo-select2-dropdown .select2-results__option--highlighted.select2-results__option--selectable {
    background: #0b1f3a !important;
    color: #fff !important;
}

.mo-select2-dropdown .select2-results__option--selected {
    background: rgba(0, 168, 168, 0.12) !important;
    color: #0b1f3a !important;
    font-weight: 600;
}

.mo-select2-dropdown .select2-results__option--selected.select2-results__option--highlighted {
    background: #0b1f3a !important;
    color: #fff !important;
}

.mo-select2-dropdown .select2-results__option[aria-disabled="true"] {
    color: #94a3b8 !important;
    cursor: default;
}

.mo-select2-dropdown .select2-results__message {
    padding: 14px 10px !important;
    color: #64748b !important;
    text-align: center;
    font-size: 0.88rem;
}
