// vf-chatbot-standalone.scss
.vf-chatbot-standalone-container {
  background-color: var(--vf-color--neutral--0);
}

.vf-chatbot-standalone {
  
  display: flex;
  justify-content: end;
  border-radius: $vf-radius--xs;
  flex-direction: column;
  height: 75vh;

  &__header {
    margin-bottom: 24px;
    color: var(--vf-color--neutral--900);
    display: flex;
    align-items: center;
    justify-content: space-between;

    @media (max-width: 768px) {
      padding: 0 16px;
    }
  }

  &__header-left {
    display: flex;
    align-items: center;
    gap: 12px;
  }

  &__content {
    display: contents;
  }

  &__input-container {
    display: flex;
    flex-direction: column;
    width: 55%;
    margin: 16px auto;
    padding-right: 1rem;
    @media (max-width:$vf-breakpoint--md) {
      padding: 0 0.5rem;
      width: 95%;
    }
    @media (max-width: $vf-breakpoint--sm) {
      // width: 88%;
      padding: 0 0.5rem;
    }

    @media (max-width: 480px) {
      width: 100%;
      padding:0px;
      margin:0px;
      margin-top: 16px;
      border-top: 2px solid var(--vf-color--grey);
    }
  }

  &__input-wrapper {
    display: flex;
    align-items: flex-end;
    label {
      visibility: hidden;
      position: absolute;
      border: 0;
      padding: 0;
      margin: 0;
      height: 1px; 
      width: 1px;
      overflow: hidden;
    }
  }

  &__input {
    @include set-type(text-body--3);
    margin-bottom: 0;
    align-content: center;
    width: 100%;
    line-height: 2.1;
    border: none;
    resize: none;
    background: var(--vf-color--neutral--0);
    box-shadow: none !important;
    // /* When typing (not showing placeholder) */
    &:not(:placeholder-shown) {
      color: var(--vf-color__text--primary); /* Text color when typing */
    }

    // When content exceeds 5 rows, show scrollbar
    &--scrollable {
      overflow-y: auto;
    }
  }

  &__send-button {
    height: 50px;
    background: #3A77BC;
    border: none;
    padding-inline: 0px;
    cursor: pointer;
    img {
      @media (max-width: 480px) {
        height: 45px !important;
        max-width: fit-content !important;
      }
    }
  }

  &__messages {
    margin: 0 auto;
    flex-direction: column;
    overflow-y: auto;
    width: 55%;
    padding-right: 1rem;
    @media (max-width:$vf-breakpoint--md) {
      padding: 0 0.5rem;
      width: 95%;
    }
    @media (max-width: $vf-breakpoint--sm) {
      // width: 88%;
      padding: 0 0.5rem;
    }
  }

  &__messages-no-scrollbar {
    @extend .vf-chatbot-standalone__messages;
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* IE 10+ */
  }

  &__messages-no-scrollbar::-webkit-scrollbar {
    display: none; /* Chrome, Safari, Opera */
  }

  &__disclaimer {
    margin: 0 auto;
    width: 55%;
    padding-right: 1rem;
    button {
      padding: 12px;
    }
    @media (max-width:$vf-breakpoint--md) {
      padding: 0 0.5rem;
      width: 95%;
    }
    @media (max-width: $vf-breakpoint--sm) {
      // width: 88%;
      padding: 0 0.5rem;
    }
  }

  &__footnote {
    @include set-type(text-body--5);
    margin: 0 auto;
    text-align: center;
    padding-right: 1rem;
    @media (max-width:$vf-breakpoint--md) {
      width: 95%;
      padding: 0 0.5rem;
    }
    @media (max-width: $vf-breakpoint--sm) {
      // width: 88%;
      padding: 0 0.5rem;
    }
  }

  @media (max-width:$vf-breakpoint--sm) {
    height: 90vh;
  }
}
