/*------------------------------------------------------------
SLIDER
====================================*/

// slide
.slick-slide {
  div {
    display: block !important;
  }
}

// arrow
.slick-arrow {
  display: flex;
  align-items: center;
  justify-content: center;
  position: absolute;
  z-index: 1;
  top: 50%;
  width: $slider-arrow-width;
  height: $slider-arrow-height;
  margin-top: -($slider-arrow-height*0.5);
  background: $slider-arrow-bg;
  border: 0;
  opacity: 1;
  transition: 0.3s;
  &:before {
    content: '';
    display: block;
    width: $slider-arrow-icon-width;
    height: $slider-arrow-icon-height;
    background: {
      image: $slider-arrow-icon;
      size: contain;
    }
  }

  &:focus {
    outline: 0;
  }

  &:hover {
    opacity: 0.6;
  }
}
.slick-prev {
  left: 1.5rem;
  transform: rotate(180deg);
}
.slick-next {
  right: 1.5rem;
}

// dots
.slick-dots {
  display: flex;
  justify-content: center;
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0.5rem;
  z-index: 1;
  margin: 0;
  list-style: none;
  button {
    display: block;
    width: $slider-dot-size;
    height: $slider-dot-size;
    padding: 0;
    margin: 0.6rem;
    font-size: 0;
    background: $slider-dot-color;
    border: 0;
    border-radius: 100%;
    &:hover {
      background: $slider-dot-hover-color;
    }
    &:focus {
      outline: 0;
    }
  }

  .slick-active {
    button {
      background: $slider-dot-active-color;
    }
  }
}
.slick-thumbnails-dots {
  .slick-dot {
    cursor: pointer;
    img {
      border: 0.1rem solid transparent;
    }
    &.slick-active img {
      border-color: $slider-dot-active-color;
    }
  }
}

// cross-selling slider
.cross-slider {
  margin: 0 -0.7rem;

  .product-box-container {
    margin-bottom: 0;
    width: 100%;
    height: 100%;
  }

  &:not(.slick-initialized) {
    display: flex;
    overflow-x: hidden;
    .item {
      display: flex;
      flex: 0 0 50%;
    }
  }

  .slick-track {
    display: flex;
  }
  .slick-prev {
    left: -6.5rem;
  }
  .slick-next {
    right: -6.5rem;
  }

  /* Hack slick */
  .slick-slide {
    display: flex;
    height: auto;
    & > div, .product-box-container, .product-box-text-wrapper {
      display: flex !important;
      width: 100%;
    }
    .item {
      display: flex !important;
      height: 100%;
    }
  }
}
.cross-slider-dots {
  margin-top: 1.5rem;
  .slick-dots {
    position: static;
  }
}

// product visual
.product-show-images-thumbnail {
  display: none;
}


/* RESPONSIVE */
/***************************************/
@include media-breakpoint-down(md) {
  // dots
  .slick-dots {
    bottom: 1rem;
  }
}
@include media-breakpoint-up(md) {
  // cross-selling slider
  .cross-slider {
    position: static;
    margin: 0 -1.5rem;

    &.slick-dotted {
      .slick-arrow {
        margin-top: -5rem;
      }
    }

    &:not(.slick-initialized) {
      .item {
        flex: 0 0 33%;
      }
    }
  }
  .cross-slider-dots {
    margin-top: 2.5rem;
  }

  // product visual
  .product-show-images-thumbnail {
    display: block;
    margin-top: 2rem;
    .slick-list {
      margin: 0 -1.5rem;
    }
    .slick-slide {
      margin: 0 1.5rem;
    }
  }
}
@include media-breakpoint-up(lg) {
  // cross-selling slider
  .cross-slider {
    &:not(.slick-initialized) {
      .item {
        flex: 0 0 25%;
      }
    }
  }

  // product visual
  .product-show-images-thumbnail {
    .slick-list {
      margin: 0 -3rem;
    }
    .slick-slide {
      margin: 0 3rem;
    }
  }
}
