/* Select2 hierarchy option spacing (organization dropdown only) */
.organization-select2-dropdown .select2-results__option {
    padding: 6px 12px;
    font-size: 14px;
    line-height: 1.5;
    transition: background-color 0.15s ease;
}

/* --------------------------------------------------------------------------
   Header organization Select2 — prevent flex collapse (topbar min-w-0 + width 100%)
   -------------------------------------------------------------------------- */
.fi-topbar .fi-topbar-org,
.fi-topbar-org {
    flex-shrink: 0;
    min-width: 12rem;
}

.fi-topbar .fi-topbar-org .select2-container,
.fi-topbar .fi-topbar-org #select2-headerOrganizationSelector-container,
.fi-topbar-org .select2-container,
.fi-topbar-org #select2-headerOrganizationSelector-container {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 12rem !important;
}

/* Mobile sidebar organization switcher — same width shell as .fi-sidebar-nav-search-ctn */
.fi-sidebar-nav > .fi-sidebar-org {
    /* Do not set width:100% here: with -mx-2 it shrinks vs the search sibling. */
    align-self: stretch;
    position: relative;
    min-width: 0;
    box-sizing: border-box;
}

.fi-sidebar .fi-sidebar-org .fi-sidebar-org-field,
.fi-sidebar-org .fi-sidebar-org-field,
.fi-sidebar .fi-sidebar-org [wire\:id],
.fi-sidebar-org [wire\:id],
.fi-sidebar .fi-sidebar-org .block,
.fi-sidebar-org .block {
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    box-sizing: border-box !important;
}

.fi-sidebar .fi-sidebar-org .select2-container,
.fi-sidebar .fi-sidebar-org #select2-sidebarOrganizationSelector-container,
.fi-sidebar-org .select2-container,
.fi-sidebar-org #select2-sidebarOrganizationSelector-container {
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    box-sizing: border-box !important;
}

.fi-sidebar .fi-sidebar-org .select2-dropdown,
.fi-sidebar-org .select2-dropdown,
.fi-sidebar .fi-sidebar-org .organization-select2-dropdown {
    z-index: 50 !important;
}

.fi-sidebar .fi-sidebar-org .select2-container--default .select2-selection--single,
.fi-sidebar-org .select2-container--default .select2-selection--single,
#select2-sidebarOrganizationSelector-container.select2-container--default .select2-selection--single {
    display: flex !important;
    align-items: center !important;
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    min-height: 2.25rem !important; /* min-h-9 — same as Filament input */
    height: auto !important;
    border-radius: 0.5rem !important; /* rounded-lg */
    border: none !important;
    background-color: rgb(255 255 255) !important; /* bg-white */
    box-shadow: 0 0 0 1px var(--performerp-ring-subtle-light, rgb(0 0 0 / 0.1)) !important;
    transition: box-shadow 0.075s ease !important;
}

.fi-sidebar .fi-sidebar-org .select2-container--default.select2-container--focus .select2-selection--single,
.fi-sidebar .fi-sidebar-org .select2-container--default.select2-container--open .select2-selection--single,
.fi-sidebar-org .select2-container--default.select2-container--focus .select2-selection--single,
.fi-sidebar-org .select2-container--default.select2-container--open .select2-selection--single,
#select2-sidebarOrganizationSelector-container.select2-container--default.select2-container--focus .select2-selection--single,
#select2-sidebarOrganizationSelector-container.select2-container--default.select2-container--open .select2-selection--single {
    outline: none !important;
    box-shadow: 0 0 0 1px var(--performerp-ring-subtle-light, rgb(0 0 0 / 0.1)) !important;
}

.dark .fi-sidebar .fi-sidebar-org .select2-container--default .select2-selection--single,
.dark .fi-sidebar-org .select2-container--default .select2-selection--single,
.dark #select2-sidebarOrganizationSelector-container.select2-container--default .select2-selection--single {
    background-color: rgb(255 255 255 / 0.05) !important; /* dark:bg-white/5 */
    box-shadow: 0 0 0 1px var(--performerp-ring-subtle-dark, rgb(255 255 255 / 0.2)) !important;
}

.dark .fi-sidebar .fi-sidebar-org .select2-container--default.select2-container--focus .select2-selection--single,
.dark .fi-sidebar .fi-sidebar-org .select2-container--default.select2-container--open .select2-selection--single,
.dark .fi-sidebar-org .select2-container--default.select2-container--focus .select2-selection--single,
.dark .fi-sidebar-org .select2-container--default.select2-container--open .select2-selection--single,
.dark #select2-sidebarOrganizationSelector-container.select2-container--default.select2-container--focus .select2-selection--single,
.dark #select2-sidebarOrganizationSelector-container.select2-container--default.select2-container--open .select2-selection--single {
    box-shadow: 0 0 0 1px var(--performerp-ring-subtle-dark, rgb(255 255 255 / 0.2)) !important;
}

.fi-sidebar .fi-sidebar-org .select2-container--default .select2-selection--single .select2-selection__rendered,
.fi-sidebar-org .select2-container--default .select2-selection--single .select2-selection__rendered,
.fi-sidebar .fi-sidebar-org #select2-sidebarOrganizationSelector-container .select2-selection__rendered,
#select2-sidebarOrganizationSelector-container .select2-selection__rendered {
    display: block !important;
    flex: 1 1 auto !important;
    min-width: 0 !important;
    line-height: 1.5rem !important; /* leading-6 */
    padding: 0.375rem 2rem 0.375rem 0.75rem !important; /* py-1.5 ps-3 pe-8 */
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
    color: rgb(3 7 18) !important; /* text-gray-950 */
    font-size: 0.875rem !important; /* text-sm */
    font-weight: 400 !important;
}

.dark .fi-sidebar .fi-sidebar-org .select2-container--default .select2-selection--single .select2-selection__rendered,
.dark .fi-sidebar-org .select2-container--default .select2-selection--single .select2-selection__rendered,
.dark .fi-sidebar .fi-sidebar-org #select2-sidebarOrganizationSelector-container .select2-selection__rendered,
.dark #select2-sidebarOrganizationSelector-container .select2-selection__rendered {
    color: rgb(255 255 255) !important;
}

.fi-sidebar .fi-sidebar-org .select2-container--default .select2-selection--single .select2-selection__arrow,
.fi-sidebar-org .select2-container--default .select2-selection--single .select2-selection__arrow,
#select2-sidebarOrganizationSelector-container .select2-selection__arrow {
    position: absolute !important;
    top: 0 !important;
    right: 0.5rem !important;
    height: 100% !important;
    width: 1.25rem !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}

.fi-sidebar .fi-sidebar-org .select2-container--default .select2-selection--single .select2-selection__arrow b,
.fi-sidebar-org .select2-container--default .select2-selection--single .select2-selection__arrow b,
#select2-sidebarOrganizationSelector-container .select2-selection__arrow b {
    border-color: rgb(156 163 175) transparent transparent transparent !important; /* gray-400 */
}

.dark .fi-sidebar .fi-sidebar-org .select2-container--default .select2-selection--single .select2-selection__arrow b,
.dark .fi-sidebar-org .select2-container--default .select2-selection--single .select2-selection__arrow b,
.dark #select2-sidebarOrganizationSelector-container .select2-selection__arrow b {
    border-color: rgb(107 114 128) transparent transparent transparent !important; /* gray-500 */
}

/* --------------------------------------------------------------------------
   Header organization Select2 — layout + fallbacks (no org theme / no vars)
   -------------------------------------------------------------------------- */
#select2-headerOrganizationSelector-container.select2-container--default .select2-selection--single,
.organization-select2.select2-container--default .select2-selection--single,
.select2-container--default.organization-select2 .select2-selection--single,
.fi-topbar #select2-headerOrganizationSelector-container.select2-container--default .select2-selection--single,
.fi-topbar .organization-select2.select2-container--default .select2-selection--single,
.fi-topbar .select2-container--default.organization-select2 .select2-selection--single {
    height: 36px !important;
    border-radius: 0.5rem !important;
    border: 1px solid rgb(209 213 219) !important;
    background-color: transparent !important;
    transition: border-color 0.15s ease, box-shadow 0.15s ease !important;
    box-shadow: none !important;
}

#select2-headerOrganizationSelector-container.select2-container--default.select2-container--focus .select2-selection--single,
#select2-headerOrganizationSelector-container.select2-container--default.select2-container--open .select2-selection--single,
.organization-select2.select2-container--default.select2-container--focus .select2-selection--single,
.organization-select2.select2-container--default.select2-container--open .select2-selection--single,
.select2-container--default.organization-select2.select2-container--focus .select2-selection--single,
.select2-container--default.organization-select2.select2-container--open .select2-selection--single,
.fi-topbar #select2-headerOrganizationSelector-container.select2-container--default.select2-container--focus .select2-selection--single,
.fi-topbar #select2-headerOrganizationSelector-container.select2-container--default.select2-container--open .select2-selection--single,
.fi-topbar .organization-select2.select2-container--default.select2-container--focus .select2-selection--single,
.fi-topbar .organization-select2.select2-container--default.select2-container--open .select2-selection--single,
.fi-topbar .select2-container--default.organization-select2.select2-container--focus .select2-selection--single,
.fi-topbar .select2-container--default.organization-select2.select2-container--open .select2-selection--single {
    outline: none !important;
}

#select2-headerOrganizationSelector-container.select2-container--default .select2-selection--single .select2-selection__rendered,
.organization-select2.select2-container--default .select2-selection--single .select2-selection__rendered,
.select2-container--default.organization-select2 .select2-selection--single .select2-selection__rendered,
.fi-topbar #select2-headerOrganizationSelector-container.select2-container--default .select2-selection--single .select2-selection__rendered,
.fi-topbar .organization-select2.select2-container--default .select2-selection--single .select2-selection__rendered,
.fi-topbar .select2-container--default.organization-select2 .select2-selection--single .select2-selection__rendered {
    line-height: 34px !important;
    padding-left: 12px !important;
    color: rgb(17 24 39) !important;
    font-weight: 500 !important;
}

#select2-headerOrganizationSelector-container.select2-container--default .select2-selection--single .select2-selection__arrow,
.organization-select2.select2-container--default .select2-selection--single .select2-selection__arrow,
.select2-container--default.organization-select2 .select2-selection--single .select2-selection__arrow,
.fi-topbar #select2-headerOrganizationSelector-container.select2-container--default .select2-selection--single .select2-selection__arrow,
.fi-topbar .organization-select2.select2-container--default .select2-selection--single .select2-selection__arrow,
.fi-topbar .select2-container--default.organization-select2 .select2-selection--single .select2-selection__arrow {
    height: 34px !important;
}

/* --------------------------------------------------------------------------
   Branded topbar: transparent surface; label/chevron use org foreground tokens.
   -------------------------------------------------------------------------- */
.fi-topbar.organization-theme #select2-headerOrganizationSelector-container.select2-container--default .select2-selection--single,
.fi-topbar.organization-theme .organization-select2.select2-container--default .select2-selection--single,
.fi-topbar.organization-theme .select2-container--default.organization-select2 .select2-selection--single {
    background-color: transparent !important;
    border-color: rgb(var(--primary-800)) !important;
}

.fi-topbar.organization-theme
    #select2-headerOrganizationSelector-container.select2-container--default:hover
    .select2-selection--single,
.fi-topbar.organization-theme
    .organization-select2.select2-container--default:hover
    .select2-selection--single,
.fi-topbar.organization-theme
    .select2-container--default.organization-select2:hover
    .select2-selection--single {
    border-color: rgb(var(--primary-900)) !important;
}

.fi-topbar.organization-theme #select2-headerOrganizationSelector-container.select2-container--default.select2-container--focus .select2-selection--single,
.fi-topbar.organization-theme #select2-headerOrganizationSelector-container.select2-container--default.select2-container--open .select2-selection--single,
.fi-topbar.organization-theme .organization-select2.select2-container--default.select2-container--focus .select2-selection--single,
.fi-topbar.organization-theme .organization-select2.select2-container--default.select2-container--open .select2-selection--single,
.fi-topbar.organization-theme .select2-container--default.organization-select2.select2-container--focus .select2-selection--single,
.fi-topbar.organization-theme .select2-container--default.organization-select2.select2-container--open .select2-selection--single {
    border-color: rgb(var(--primary-500)) !important;
    box-shadow: 0 0 0 3px var(--org-focus-ring) !important;
}

/* Topbar surface is primary-600; Select2 selection is transparent, so use on-600 (not on-700). */
.fi-topbar.organization-theme #select2-headerOrganizationSelector-container.select2-container--default .select2-selection--single .select2-selection__rendered,
.fi-topbar.organization-theme .organization-select2.select2-container--default .select2-selection--single .select2-selection__rendered,
.fi-topbar.organization-theme .select2-container--default.organization-select2 .select2-selection--single .select2-selection__rendered {
    color: rgb(var(--org-on-600, 15, 23, 42)) !important;
}

.fi-topbar.organization-theme #select2-headerOrganizationSelector-container.select2-container--default .select2-selection--single .select2-selection__arrow b,
.fi-topbar.organization-theme .organization-select2.select2-container--default .select2-selection--single .select2-selection__arrow b,
.fi-topbar.organization-theme .select2-container--default.organization-select2 .select2-selection--single .select2-selection__arrow b {
    border-color: rgb(var(--org-on-600, 15, 23, 42)) transparent transparent transparent !important;
}

/* Dropdown shell (org selector): layout + default neutrals */
.organization-select2 ~ .select2-dropdown,
.organization-select2 + .select2-dropdown,
.select2-container.organization-select2 ~ .select2-dropdown,
.select2-container.organization-select2 + .select2-dropdown,
.fi-topbar .organization-select2 ~ .select2-dropdown,
.fi-topbar .select2-container.organization-select2 ~ .select2-dropdown {
    border-radius: 0.5rem !important;
    border: 1px solid rgb(209 213 219) !important;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05) !important;

.organization-select2-dropdown.select2-dropdown {
    border-radius: 0.5rem !important;
    border: 1px solid rgb(var(--primary-300)) !important;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05) !important;
    background-color: rgb(255 255 255) !important;
}

.organization-select2-dropdown .select2-search--dropdown {
    padding: 8px;
}

.organization-select2-dropdown .select2-search--dropdown .select2-search__field {
    border-radius: 0.375rem;
    border: 1px solid rgb(var(--primary-300));
    padding: 8px 12px;
    font-size: 14px;
    transition: border-color 0.15s ease;
}

.organization-select2-dropdown .select2-search--dropdown .select2-search__field:focus {
    outline: none !important;
    border-color: rgb(var(--primary-500)) !important;
    box-shadow: 0 0 0 3px var(--org-focus-ring) !important;
}

.organization-select2-dropdown .select2-results__option--highlighted[aria-selected] {
    background-color: rgb(var(--primary-600)) !important;
    color: rgb(var(--org-on-600)) !important;
}

.organization-select2-dropdown .select2-results__option[aria-selected="true"] {
    background-color: rgb(var(--primary-100)) !important;
    color: rgb(var(--primary-900)) !important;
    font-weight: 500;
}

/* Dark: org dropdown only (do not target every Select2 on the page) */
.dark .organization-select2-dropdown.select2-dropdown {
    background-color: rgb(31 41 55) !important;
    border-color: rgb(var(--primary-700)) !important;
}

.dark .organization-select2-dropdown .select2-results__option {
    color: rgb(243 244 246);
}

.dark .organization-select2-dropdown .select2-results__option--highlighted[aria-selected] {
    background-color: rgb(var(--primary-600)) !important;
    color: rgb(var(--org-on-600)) !important;
}

.dark .organization-select2-dropdown .select2-results__option[aria-selected="true"] {
    background-color: rgb(55 65 81) !important;
    color: rgb(var(--primary-200)) !important;
}

.dark .organization-select2-dropdown .select2-search--dropdown .select2-search__field {
    background-color: rgb(55 65 81);
    border-color: rgb(75 85 99);
    color: rgb(243 244 246);
}

.dark .organization-select2-dropdown .select2-search--dropdown .select2-search__field:focus {
    border-color: rgb(var(--primary-500)) !important;
    box-shadow: 0 0 0 3px var(--org-focus-ring) !important;
}

.dark .organization-select2-dropdown .select2-search--dropdown .select2-search__field::placeholder {
    color: rgb(156 163 175);
}

/* Legacy: search field focus when dropdown has no custom class (input id match) */
body > .select2-dropdown:has(.select2-search--dropdown input[data-select2-id*="headerOrganizationSelector"]) .select2-search--dropdown .select2-search__field:focus,
#select2-headerOrganizationSelector-container ~ .select2-dropdown .select2-search--dropdown .select2-search__field:focus,
.organization-select2 ~ .select2-dropdown .select2-search--dropdown .select2-search__field:focus,
.select2-container.organization-select2 ~ .select2-dropdown .select2-search--dropdown .select2-search__field:focus,
.fi-topbar #select2-headerOrganizationSelector-container ~ .select2-dropdown .select2-search--dropdown .select2-search__field:focus,
.fi-topbar .organization-select2 ~ .select2-dropdown .select2-search--dropdown .select2-search__field:focus,
.fi-topbar .select2-container.organization-select2 ~ .select2-dropdown .select2-search--dropdown .select2-search__field:focus {
    outline: none !important;
    border-color: rgb(var(--primary-500)) !important;
    box-shadow: 0 0 0 3px var(--org-focus-ring) !important;
}


html:not(.dark) .organization-select2 ~ .select2-dropdown .select2-results__option--highlighted[aria-selected],
html:not(.dark) .select2-container.organization-select2 ~ .select2-dropdown .select2-results__option--highlighted[aria-selected],
html:not(.dark) #select2-headerOrganizationSelector-container ~ .select2-dropdown .select2-results__option--highlighted[aria-selected],
html:not(.dark) .fi-topbar .organization-select2 ~ .select2-dropdown .select2-results__option--highlighted[aria-selected],
html:not(.dark) .fi-topbar .select2-container.organization-select2 ~ .select2-dropdown .select2-results__option--highlighted[aria-selected] {
    background-color: rgb(79 70 229) !important;
    color: #ffffff !important;
}

.organization-select2 ~ .select2-dropdown .select2-results__option[aria-selected='true'],
.select2-container.organization-select2 ~ .select2-dropdown .select2-results__option[aria-selected='true'],
#select2-headerOrganizationSelector-container ~ .select2-dropdown .select2-results__option[aria-selected='true'],
.fi-topbar .organization-select2 ~ .select2-dropdown .select2-results__option[aria-selected='true'],
.fi-topbar .select2-container.organization-select2 ~ .select2-dropdown .select2-results__option[aria-selected='true'] {
    background-color: rgb(238 242 255);
    color: #a25a73;
    font-weight: 500;
}

/* Style pour le mode sombre */
.dark #select2-headerOrganizationSelector-container.select2-container--default .select2-selection--single,
.dark .organization-select2.select2-container--default .select2-selection--single,
.dark .select2-container--default.organization-select2 .select2-selection--single,
.dark .fi-topbar #select2-headerOrganizationSelector-container.select2-container--default .select2-selection--single,
.dark .fi-topbar .organization-select2.select2-container--default .select2-selection--single,
.dark .fi-topbar .select2-container--default.organization-select2 .select2-selection--single {
    background-color: rgb(55 65 81) !important;
    border-color: rgb(75 85 99) !important;
    box-shadow: none !important;
}

/* Note: Dark mode hover state for organization selector uses Select2 default styles */
/* No custom hover rules - keeping Select2 default behavior */

.dark #select2-headerOrganizationSelector-container.select2-container--default.select2-container--focus .select2-selection--single,
.dark #select2-headerOrganizationSelector-container.select2-container--default.select2-container--open .select2-selection--single,
.dark .organization-select2.select2-container--default.select2-container--focus .select2-selection--single,
.dark .organization-select2.select2-container--default.select2-container--open .select2-selection--single,
.dark .select2-container--default.organization-select2.select2-container--focus .select2-selection--single,
.dark .select2-container--default.organization-select2.select2-container--open .select2-selection--single,
.dark .fi-topbar #select2-headerOrganizationSelector-container.select2-container--default.select2-container--focus .select2-selection--single,
.dark .fi-topbar #select2-headerOrganizationSelector-container.select2-container--default.select2-container--open .select2-selection--single,
.dark .fi-topbar .organization-select2.select2-container--default.select2-container--focus .select2-selection--single,
.dark .fi-topbar .organization-select2.select2-container--default.select2-container--open .select2-selection--single,
.dark .fi-topbar .select2-container--default.organization-select2.select2-container--focus .select2-selection--single,
.dark .fi-topbar .select2-container--default.organization-select2.select2-container--open .select2-selection--single {
    border-color: #16A34A !important;
    outline: none !important;
    box-shadow: 0 0 0 1px #16A34A !important;
}

.dark #select2-headerOrganizationSelector-container.select2-container--default .select2-selection--single .select2-selection__rendered,
.dark .organization-select2.select2-container--default .select2-selection--single .select2-selection__rendered,
.dark .select2-container--default.organization-select2 .select2-selection--single .select2-selection__rendered,
.dark .fi-topbar #select2-headerOrganizationSelector-container.select2-container--default .select2-selection--single .select2-selection__rendered,
.dark .fi-topbar .organization-select2.select2-container--default .select2-selection--single .select2-selection__rendered,
.dark .fi-topbar .select2-container--default.organization-select2 .select2-selection--single .select2-selection__rendered {
    color: white !important;
}

.dark #select2-headerOrganizationSelector-container.select2-container--default .select2-selection--single .select2-selection__arrow b,
.dark .organization-select2.select2-container--default .select2-selection--single .select2-selection__arrow b,
.dark .select2-container--default.organization-select2 .select2-selection--single .select2-selection__arrow b,
.dark .fi-topbar #select2-headerOrganizationSelector-container.select2-container--default .select2-selection--single .select2-selection__arrow b,
.dark .fi-topbar .organization-select2.select2-container--default .select2-selection--single .select2-selection__arrow b,
.dark .fi-topbar .select2-container--default.organization-select2 .select2-selection--single .select2-selection__arrow b {
    border-color: white transparent transparent transparent !important;
}

/* Organization dropdown only — do not use .dark .select2-dropdown alone (it hijacked every Select2 list) */
.dark .organization-select2 ~ .select2-dropdown,
.dark .select2-container.organization-select2 ~ .select2-dropdown,
.dark #select2-headerOrganizationSelector-container ~ .select2-dropdown,
.dark .fi-topbar .organization-select2 ~ .select2-dropdown,
.dark .fi-topbar .select2-container.organization-select2 ~ .select2-dropdown {
    background-color: rgb(55 65 81) !important;
    border-color: rgb(75 85 99) !important;
}

.dark .organization-select2 ~ .select2-dropdown .select2-results__option,
.dark .select2-container.organization-select2 ~ .select2-dropdown .select2-results__option,
.dark #select2-headerOrganizationSelector-container ~ .select2-dropdown .select2-results__option,
.dark .fi-topbar .organization-select2 ~ .select2-dropdown .select2-results__option,
.dark .fi-topbar .select2-container.organization-select2 ~ .select2-dropdown .select2-results__option {
    color: white;
}

.dark .organization-select2 ~ .select2-dropdown .select2-results__option--highlighted[aria-selected],
.dark .select2-container.organization-select2 ~ .select2-dropdown .select2-results__option--highlighted[aria-selected],
.dark #select2-headerOrganizationSelector-container ~ .select2-dropdown .select2-results__option--highlighted[aria-selected],
.dark .fi-topbar .organization-select2 ~ .select2-dropdown .select2-results__option--highlighted[aria-selected],
.dark .fi-topbar .select2-container.organization-select2 ~ .select2-dropdown .select2-results__option--highlighted[aria-selected] {
    background-color: rgb(99 102 241);
    color: white;
}

.dark .organization-select2 ~ .select2-dropdown .select2-results__option[aria-selected='true'],
.dark .select2-container.organization-select2 ~ .select2-dropdown .select2-results__option[aria-selected='true'],
.dark #select2-headerOrganizationSelector-container ~ .select2-dropdown .select2-results__option[aria-selected='true'],
.dark .fi-topbar .organization-select2 ~ .select2-dropdown .select2-results__option[aria-selected='true'],
.dark .fi-topbar .select2-container.organization-select2 ~ .select2-dropdown .select2-results__option[aria-selected='true'] {
    background-color: rgb(75 85 99);
    color: rgb(167 139 250);
}

.dark .organization-select2 ~ .select2-dropdown .select2-search--dropdown .select2-search__field,
.dark .select2-container.organization-select2 ~ .select2-dropdown .select2-search--dropdown .select2-search__field,
.dark #select2-headerOrganizationSelector-container ~ .select2-dropdown .select2-search--dropdown .select2-search__field,
.dark .fi-topbar .organization-select2 ~ .select2-dropdown .select2-search--dropdown .select2-search__field,
.dark .fi-topbar .select2-container.organization-select2 ~ .select2-dropdown .select2-search--dropdown .select2-search__field {
    background-color: rgb(75 85 99);
    border-color: rgb(107 114 128);
    color: white;
}

/* Dark mode - Focus state for organization selector dropdown search field - Filament color */
.dark body > .select2-dropdown:has(.select2-search--dropdown input[data-select2-id*="headerOrganizationSelector"]) .select2-search--dropdown .select2-search__field:focus,
.dark #select2-headerOrganizationSelector-container ~ .select2-dropdown .select2-search--dropdown .select2-search__field:focus,
.dark .organization-select2 ~ .select2-dropdown .select2-search--dropdown .select2-search__field:focus,
.dark .select2-container.organization-select2 ~ .select2-dropdown .select2-search--dropdown .select2-search__field:focus,
.dark .fi-topbar #select2-headerOrganizationSelector-container ~ .select2-dropdown .select2-search--dropdown .select2-search__field:focus,
.dark .fi-topbar .organization-select2 ~ .select2-dropdown .select2-search--dropdown .select2-search__field:focus,
.dark .fi-topbar .select2-container.organization-select2 ~ .select2-dropdown .select2-search--dropdown .select2-search__field:focus {
    border-color: #16A34A !important;
    box-shadow: 0 0 0 1px #16A34A !important;
}

.dark .organization-select2 ~ .select2-dropdown .select2-search--dropdown .select2-search__field::placeholder,
.dark .select2-container.organization-select2 ~ .select2-dropdown .select2-search--dropdown .select2-search__field::placeholder,
.dark #select2-headerOrganizationSelector-container ~ .select2-dropdown .select2-search--dropdown .select2-search__field::placeholder,
.dark .fi-topbar .organization-select2 ~ .select2-dropdown .select2-search--dropdown .select2-search__field::placeholder,
.dark .fi-topbar .select2-container.organization-select2 ~ .select2-dropdown .select2-search--dropdown .select2-search__field::placeholder {
    color: rgb(156 163 175);
}

#select2-headerOrganizationSelector-container,
.organization-select2.select2-container,
.select2-container.organization-select2,
.fi-topbar #select2-headerOrganizationSelector-container,
.fi-topbar .organization-select2.select2-container,
.fi-topbar .select2-container.organization-select2 {
    z-index: 40 !important;
}

#select2-headerOrganizationSelector-container.select2-container--open,
.organization-select2.select2-container--open,
.select2-container--open.organization-select2,
.fi-topbar #select2-headerOrganizationSelector-container.select2-container--open,
.fi-topbar .organization-select2.select2-container--open,
.fi-topbar .select2-container--open.organization-select2 {
    z-index: 50 !important;
}

html body > .select2-container .organization-select2-dropdown,
html body > .select2-container.select2-container--open .organization-select2-dropdown,
#select2-headerOrganizationSelector-container.select2-container--open .select2-dropdown,
.organization-select2.select2-container--open .select2-dropdown,
.select2-container--open.organization-select2 .select2-dropdown,
.fi-topbar #select2-headerOrganizationSelector-container.select2-container--open .select2-dropdown,
.fi-topbar .organization-select2.select2-container--open .select2-dropdown,
.fi-topbar .select2-container--open.organization-select2 .select2-dropdown {
}
}
