@use '@inside-library/styles/mixins/partials/common-mixin' as *;

.custom-field-search--main {
  input {
    line-height: 1;
    color: var(--color-primary-600);
    border: 0;

    @include input-placeholder {
      color: var(--color-primary-600);
    }
  }

  .custom-field-search__input {
    position: relative;

    input {
      height: 58px;
      font-weight: var(--font-weight-bold);
      border-bottom: 1px solid var(--color-primary);

      @include transition(border-color 0.4s);

      &:focus {
        border-color: var(--color-secondary);
      }
    }

    .search-icon {
      color: var(--color-primary);
      font-size: 25px;
    }
  }
}

.custom-field-search {
  width: 80%;
  max-width: 428px;
  margin: 0 auto;

  input {
    width: 100%;
    height: 51px;
    padding: 1.6rem;
    padding-right: 5rem;
    border: 0;
    color: var(--color-primary-600);
    font-size: var(--font-size-h5);
    outline: none;

    @include transition(box-shadow 0.4s);
  }

  .search-icon {
    position: absolute;
    top: 50%;
    right: 15px;
    color: var(--color-primary-600);
    font-size: var(--font-size-h3);
    transform: translateY(-50%);
  }

  &__input {
    position: relative;
    width: 100%;
  }

  &__dropdown {
    z-index: 8;
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    transform: translateY(100%);
    background-color: var(--color-light);

    @include box-shadow(0, 0, 1px, rgba(var(--color-dark-rgb), 0.4));

    &__loading {
      padding: var(--spacing-s) var(--spacing-m);

      .loader-ui {
        padding-top: var(--spacing-l);
        width: 25px;
        margin-right: var(--spacing-s);

        + p {
          margin: 0;
        }
      }
    }

    li {
      cursor: pointer;
      padding: 1.2rem 1.6rem;
      color: var(--color-primary-600);
      border-bottom: 0.1rem solid var(--color-grey-100);
      font-size: var(--font-size-h5);
      font-weight: var(--font-weight-bold);

      transition: all 0.3s ease;

      &:hover {
        border-color: var(--color-primary);
      }
    }

    & > div > li {
      color: var(--color-primary);
      border: none;
    }

    .no-pointer {
      cursor: inherit;
    }
  }
}
