.group-dropdown-custom {
  width: 100%;
  display: block;
  position: relative;

  *,
  *::before,
  *::after {
    box-sizing: border-box;
  }

  &__select {
    height: 44px;
    box-sizing: border-box;
    border-radius: 0;
    display: block;
    outline-offset: 3px;

    line-height: 24px;
    font-size: 16px;
    width: 100%;
    cursor: pointer;

    background: #fff;
    padding: 9px 34px 9px 16px;

    border: 1px solid #767676;

    &--lg {
      height: 68px;

      .group-dropdown-custom__text {
        text-wrap: balance;
      }
    }
  }

  &__select:hover,
  &__select:focus-within {
    border-color: #000;
  }

  &__select:focus {
    border-color: #000;
  }

  .group-dropdown-custom &__select--invalid {
    border-color: #a8000b;
    background: #f9f2f3;
  }

  .group-dropdown-custom &__select--disabled {
    border-color: #d7d8d6;
    pointer-events: none;

    &,
    group-text {
      color: #d7d8d6;
    }
  }

  &__text {
    width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  &__list {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background-color: #fff;
    z-index: 10;
    max-height: 222px;
    overflow-y: auto;
    border-right: 1px solid #767676;
    border-left: 1px solid #767676;
    border-bottom: 1px solid #767676;

    &::-webkit-scrollbar {
      width: 4px;
    }

    &::-webkit-scrollbar-track {
      background: #ededed;
    }

    &::-webkit-scrollbar-thumb {
      background-color: #767676;
    }

    &--open {
      display: block;
    }
  }

  &__chevron {
    position: absolute;
    right: 16px;
    top: 0;
    height: 100%;
    display: flex;
    align-items: center;
    pointer-events: none;
  }

  &__chevron--disabled {
    color: #d7d8d6;
  }
}

.group-dropdown-option {
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-sizing: border-box;
  padding: 9px 16px 11px;
  position: relative;
  cursor: pointer;

  &:not(:last-of-type)::after {
    content: '';
    width: 100%;
    height: 1px;
    display: block;
    position: absolute;
    z-index: 30;
    left: 0;
    top: 100%;
    background: #ededed;
  }

  width: 100%;

  &:hover,
  &--current {
    background: linear-gradient(0deg, #f3f3f3, #f3f3f3), linear-gradient(0deg, #767676, #767676);
  }

  &__content {
    display: flex;
    flex-direction: column;
  }

  &__subtitle {
    &--multiple {
      margin-left: 32px;
    }
  }

  & &__checkbox {
    padding: 0;
  }

  &__panel {
    width: 100%;
    left: 0;
    top: 0;
    position: absolute;
  }
}
