@import "../../variables.scss";

.swap {
  @extend %col-nowrap;
  height: 100%;
  background-color: $white;

  &--inactive {
    opacity: .5;
  }

  &__content {
    padding: 1rem .75rem;
    flex: 1 1 auto;
    height: 0;
    overflow-y: auto;
  }

  &__down-arrow {
    width: .625rem;
    height: .625rem;
    position: relative;
    z-index: 200;
    padding: .875rem;
  }

  &__down-arrow-background {
    @extend %row-nowrap;
    justify-content: center;
    align-items: center;
  }

  &__exchange-rate-wrapper {
    @extend %row-nowrap;
    align-items: center;
    color: $dove-gray;
    font-size: .75rem;
    padding: .5rem 1rem;
  }

  &__exchange-rate {
    flex: 1 1 auto;
    width: 0;
    color: $chalice-gray;
  }

  &__summary-wrapper {
    background-color: $concrete-gray;
    border-top-left-radius: 1rem;
    border-top-right-radius: 1rem;
    padding: 1rem;
    color: #737373;
    font-size: .75rem;
    text-align: center;
    cursor: pointer;
  }

  &__summary-modal {
    background-color: $white;
    position: relative;
    bottom: 12rem;
    min-height: 12rem;
    max-height: 12rem;
    z-index: 2000;
    padding: 1rem;
    border-top-left-radius: 1rem;
    border-top-right-radius: 1rem;
    transition: 250ms ease-in-out;

    @media only screen and (min-device-width : 768px) {
      max-width: 560px;
      position: absolute;
      margin-left: auto;
      margin-right: auto;
      border-radius: 1rem;
      padding-bottom: 1rem;
      left: 0;
      right: 0;
      bottom: 0;
      top: 0;
      margin-top: 4rem;
    }

    .swap__open-details-container {
      padding: 0.5rem 0;
      margin-bottom: 1rem;
      cursor: pointer;
    }
  }

  &__open-details-container {
    @extend %row-nowrap;
    align-items: center;
    justify-content: space-between;
    font-size: .75rem;
    color: $royal-blue;

    img {
      height: .75rem;
      width: .75rem;
    }
  }

  &__highlight-text {
    color: $royal-blue;
  }

  &__cta-container {
    display: flex;
    margin-top: 1.5rem;
  }

  &__cta-btn {
    @extend %primary-button;
    margin: 1rem auto;
  }

  &__sub-icon {
    margin-right: 5px;
  }

  &__sub-text {
    margin-top: 5px;
  }
}

.summary-modal-appear {
  bottom: 0;
}

.summary-modal-appear.modal-container-appear-active {
  bottom: 0;
}
