/*
 * SPDX-FileCopyrightText: 2023 Siemens AG
 *
 * SPDX-License-Identifier: MIT
 *
 * This source code is licensed under the MIT license found in the
 * LICENSE file in the root directory of this source tree.
 */
/*
* SPDX-FileCopyrightText: 2024 Siemens AG
*
* SPDX-License-Identifier: MIT
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
/*
* SPDX-FileCopyrightText: 2024 Siemens AG
*
* SPDX-License-Identifier: MIT
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
/*
* SPDX-FileCopyrightText: 2024 Siemens AG
*
* SPDX-License-Identifier: MIT
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
:host {
  --ix-dropdown-item-checked-color: var(--theme-color-primary);
  display: flex;
  flex-direction: row;
  position: relative;
  height: 2.5rem;
  width: auto;
  overflow: hidden;
  cursor: pointer;
}
:host *,
:host *::after,
:host *::before {
  box-sizing: border-box;
}
:host ::-webkit-scrollbar-button {
  display: none;
}
@-moz-document url-prefix() {
  :host * {
    scrollbar-color: var(--theme-scrollbar-thumb--background) var(--theme-scrollbar-track--background);
    scrollbar-width: thin;
  }
}
:host {
  /* width */
}
:host ::-webkit-scrollbar {
  width: 0.5rem;
  height: 0.5rem;
}
:host {
  /* Track */
}
:host ::-webkit-scrollbar-track {
  border-radius: 5px;
  background: var(--theme-scrollbar-track--background);
}
:host ::-webkit-scrollbar-track:hover {
  background: var(--theme-scrollbar-track--background--hover);
}
:host {
  /* Handle */
}
:host ::-webkit-scrollbar-thumb {
  border-radius: 5px;
  background: var(--theme-scrollbar-thumb--background);
}
:host {
  /* Handle on hover */
}
:host ::-webkit-scrollbar-thumb:hover {
  background: var(--theme-scrollbar-thumb--background--hover);
}
:host ::-webkit-scrollbar-corner {
  display: none;
}
:host .dropdown-item {
  all: unset;
  display: flex;
  flex-direction: row;
  align-items: center;
  position: relative;
  height: calc(100% - 2px);
  border: 0.0625rem solid transparent;
  white-space: nowrap;
  width: calc(100% - 0.5rem - 1.5rem);
  padding: 0 0.5rem;
  padding-right: 1.5rem;
}
:host .dropdown-item.no-checked-field {
  width: calc(100% - 1rem - 1.5rem);
  padding: 0 1rem;
  padding-right: 1.5rem;
}
:host .dropdown-item:focus-visible {
  border-color: var(--theme-color-focus-bdr);
}
:host .dropdown-item-checked {
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  height: 100%;
  width: 1rem;
  min-width: 1rem;
  margin-right: 0.5rem;
  color: var(--ix-dropdown-item-checked-color);
}
:host .dropdown-item-icon {
  margin-right: 0.5rem;
  color: var(--theme-color-std-text);
}
:host .dropdown-item-text {
  display: block;
  position: relative;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: pre;
}
:host .submenu-icon {
  margin-left: auto;
}

:host(.icon-only) .dropdown-item-icon {
  margin-right: 0px;
}
:host(.icon-only) .dropdown-item-checked {
  display: none;
}
:host(.icon-only) .dropdown-item {
  width: calc(100% - 0.5rem - 0.5rem);
  padding: 0 0.5rem;
  padding-right: 0.5rem;
}

:host(.submenu) .dropdown-item {
  width: calc(100% - 0.5rem - 0.5rem);
  padding: 0 0.5rem;
  padding-right: 0.5rem;
}

:host(:not(.disabled):not(:disabled).hover),
:host(:not(.disabled):not(:disabled):hover) {
  background-color: var(--theme-ghost--background--hover);
}

:host(:not(.disabled):not(:disabled).active),
:host(:not(.disabled):not(:disabled):active) {
  background-color: var(--theme-ghost--background--active);
}

:host(.disabled) {
  pointer-events: none;
  color: var(--theme-color-weak-text) !important;
}
:host(.disabled) .dropdown-item-icon {
  color: var(--theme-color-weak-text) !important;
}