@import '../helpers/helpers';
@import '../partials/header_checkout';
@import '../partials/footer_checkout';
@import 'checkout-sign-in';
@import 'checkout_delivery-details';
@import 'checkout_delivery-address';
@import 'checkout_delivery-address-asm';
@import 'checkout_your-details';
@import 'checkout-confirmation';
@import 'checkout-widget';
@import 'checkout_edit-delivery-address';
@import 'checkout_terms-and-conditions';
@import 'checkout_merge-basket';
@import 'page_checkout-payment-details';
@import 'checkout-tradepro';
@import 'page_split-orders';
@import '../components/payments-checkout';

//  ---- Fix for https://wickesit.atlassian.net/browse/ED-10053 ----
html {
  height: 100%;
}

body {
  &.page_checkout {
    height: 100%;

    main {
      min-height: calc(100% - 160px);
    }
  }
}
//  --------

.checkout-heading {
  @include make-col-ready;
  @include make-col(12);
  margin-bottom: 30px;

  h3 {
    margin-bottom: 0;
  }

  &__info-block {
    @include make-row;
    margin-top: 10px;
    margin-bottom: 10px;
  }

  &__descr {
    @include make-col-ready;
  }

  &__paragraph {
    margin-bottom: 0;
  }

  &__notify {
    @include make-col-ready;
    margin-top: 15px;
    margin-bottom: -20px;
  }
}

.checkout__text-highlighted {
  color: $warm-grey;
}

.supply-info {
  &__header-remark {
    color: $warm-grey;
  }

  &__info-block {
    @include make-row;
    margin-top: 30px;
    margin-bottom: 10px;
  }

  &__time {
    @include make-col(4);
    @include make-col-ready;
  }

  &__time-inner {
    padding: 10px 50px;
    background: $gray-bg;
    text-align: center;
  }

  &__descr {
    @include make-col-ready;
    @include make-col(8);
  }

  .supplier-delivery-heading {

    .supply-info {
      &__time {
        display: none;
      }

      &__descr {
        @include make-col(12);
      }
    }
  }

  &__paragraph {
    margin-bottom: 0;
  }

  &__remark {
    @include info-text;
    color: $warm-grey;
    margin-top: 5px;

    &_mobile {
      padding-left: 15px;
      padding-right: 15px;
      line-height: 1.25rem;
    }
  }
}

.checkout-address-time {
  display: flex;
  flex-wrap: wrap;
  align-items: center;

  &__address-wrap {
    border-left: 1px solid $gray;
    height: 100%;
    width: 50%;
    padding: 0 30px;
  }

  &__address {
    font-size: .875rem;
    line-height: 1.375rem;
  }
}

.checkout-address-time__time-wrap {
  font-weight: bold;
  width: 50%;
  color: $warm-grey;
  text-align: center;
}

.checkout-address-time__time-regular {
  font-size: 1.125rem;
  line-height: 1.5rem;
  font-weight: 700;
  text-transform: uppercase;
}

.checkout-address-time__time-primary {
  font-size: 2.875rem;
  line-height: 2.875rem;
  font-weight: 700;
}

.checkout-address-time__time-additional {
  font-weight: 700;
}

.checkout-address-time__undefined-time {
  color: $gray;
  font-weight: 500;
  line-height: 1.375rem;
  padding: 0 15px;
}

.checkout-address-time_sidebar {
  width: 100%;

  .checkout-address-time__time-regular {
    @include heading-4;
  }

  .checkout-address-time__time-primary {
    font-size: 2.875rem;
    line-height: 2.875rem;
  }

  .checkout-address-time__time-additional {
    font-size: .625rem;
    line-height: 1rem;
  }

  .checkout-address-time__address-wrap {
    padding: 0 5px 0 15px;
  }

  .checkout-address-time__address {
    font-size: .875rem;
    line-height: 1.375rem;
  }
}

.checkout-continue-shopping_mobile {
  width: 100%;
}

.order-line__img-link,
.order-line__title_link {
  // sass-lint:disable no-important
  display: none !important;
}

.order-line__img-static,
.order-line__title_static {
  // sass-lint:disable no-important
  display: block !important;
}

.address-list-wrap {
  height: 180px;
  border: 1px solid $gray;
  border-radius: 3px;
  background: $white;
  overflow-y: scroll;
  padding: 2px 5px;
  margin-bottom: 20px;
}

.address-list-item {
  &:hover {
    background: $blue;
    color: $white;
    cursor: pointer;
  }
}

.checkout-address-select {
  display: none;
}

.notification {
  &_reminder {
    margin: 0 15px 1.5rem;
  }
}

@include media-breakpoint-up(lg) {
  .supply-info {
    &__remark {
      &_mobile {
        display: none;
      }
    }
  }
}

@include media-breakpoint-only(lg) {
  .supply-info {
    &__time-inner {
      padding: 10px 25px;
    }
  }
}

@include media-breakpoint-down(lg) {
  .checkout-address-time {
    &__address-wrap {
      padding: 0 20px;
      width: 55%;
    }
  }

  .checkout-address-time__time-wrap {
    width: 45%;
  }
}

@include media-breakpoint-up(md) {
  .checkout-continue-shopping_mobile {
    display: none;
  }

  .content .checkout-widget.delivery-widget {
    display: none;
  }
}

@include media-breakpoint-only(md) {
  .supply-info {
    &__info-block {
      margin-bottom: 20px;
    }

    &__time {
      @include make-col(6);
    }

    &__time-inner {
      padding: 20px 25px;
    }

    &__descr {
      @include make-col(6);
    }
  }

  .checkout-address-time_sidebar {
    .checkout-address-time__address {
      font-size: .75rem;
      line-height: 1.25rem;
    }
  }
}

@include media-breakpoint-down(md) {
  .checkout-heading {
    margin-bottom: 20px;

    &__notify {
      margin-bottom: 0;
    }
  }

  .supply-info {
    &__remark {
      &_desktop {
        display: none;
      }
    }
  }
}

@include media-breakpoint-down(sm) {
  .checkout-heading {
    &__info-block {
      margin-bottom: 0;
    }
  }

  .checkout__text-highlighted {
    display: block;
  }

  .supply-info {
    &__info-block {
      margin-top: 20px;
      margin-bottom: 0;
    }

    &__time {
      @include make-col(12);
      margin-bottom: 10px;
    }

    &__time-inner {
      padding: 10px 65px;
    }

    &__descr {
      @include make-col(12);
    }
  }

  .checkout-continue-shopping {
    display: none;
  }

  aside .checkout-widget.delivery-widget {
    display: none;
  }
}
