.main-slider {
  // height: 640px;
  // margin-bottom: 100px;

  &__top {
    display: flex;
    height: 100%;

    &__txt {
      background-color: $gray-500;
      position: relative;
      // max-width: 715px;
      max-width: 39vw;
      min-width: 520px;
      padding-top: 24px;
      padding-bottom: 70px;
      transition: background-color 3s ease-in;

      &:before {
        position: absolute;
        content: '';
        height: 100%;
        clip-path: polygon(0 0, 0% 100%, 100% 0);
        background-color: $gray-500;
        width: 20%;
        top: 0;
        left: 99%;
        transition: all 3s ease-in;
      }
      .btn{
        opacity: 0;
        transform: translateY(5px);
        transition: all 0.4s ease-in;
      }
      &__h{
        color:$gray-100;
      }
      &__desc{
        transform: translateY(-5px);
        opacity: 0;
        transition: all 0.3s ease-in;
      }
    }

    &__img {
      flex-grow: 1;
      height: auto;
      position: relative;
      z-index: -1;
      overflow: hidden;

      img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        position: absolute;
        transition: all 3s ease;
        transform: scale(1.05); 
      }
    }
  }

  &__thumbs {
    display: flex;
    justify-content: space-between;
    transform: translateY(-45px);

    .splide__list {
      width: 100%;
    }
  }
}

.splide__track>.splide__list>.splide__slide.is-active {
  .main-slider__top__img img{
    transform: scale(1); 
  }
  .main-slider__top__txt{
    background-color: $barn-light;
    &:before{
      background-color: $barn-light; 
    }
    .btn{
      transform: translateY(0);
      opacity: 1; 
    }
    &__desc{
      transform: translateY(0);
      opacity: 1; 
    }
  }
}

 
.slider-thumb {
  display: flex;
  box-shadow: 0px 3px 5px rgba(0, 0, 0, 0.05), 0px 1px 18px rgba(0, 0, 0, 0.03),
    0px 6px 10px rgba(0, 0, 0, 0.04);
  max-width: 400px;
  margin-right: 2px;
  flex: 1;
  cursor: pointer;

  &__img {
    min-height: 124px;
    width: 124px;
    background-color: $primary-color-alt;

    img {
      object-fit: cover;
      width: 100%;
      height: 100%;
    }
  }

  &__txt {
    background-color: #fff;
    padding: 8px 6%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    width: calc(100% - 124px);
  }
}

.main-slider {
  .splide--nav>.splide__track>.splide__list>.splide__slide.is-active {
    border-color: $primary-color;
  }

  .splide__arrow {
    background: #fff;
    width: 80px;
    height: 80px;
    top: 40%;

    svg {
      width: 20%;
      height: 20%;
    }

    &--prev {
      transform: translateX(4vw);
    }

    &--next {
      transform: translateX(-4vw);
    }
  }

  .splide--nav>.splide__track>.splide__list>.splide__slide {
    border: 3px solid #00000005;
  }
}

.slider-multiple {
  .splide__pagination {
    bottom: -36px;

    &__page {
      border: 1px solid $barn-black;
      background: transparent;
      width: 10px;
      height: 10px;

      &.is-active {
        transform: scale(1.1);
        background: #272724;
      }
    }
  }

  .splide__arrow {
    background: transparent;
    width: 50px;
    height: 50px;

    svg {
      width: 100%;
      height: 100%;
    }

    &--prev {
      transform: translateX(-6vw);
    }

    &--next {
      transform: translateX(6vw);
    }
  }
}

.arrow-hide {
  .splide__arrow {
    display: none;
  }

  .splide__pagination {
    display: none;
  }
}

.product__slider {
  &__top {
    height: 450px;
    margin-bottom: 2%;
    padding-bottom: 4px;
  }

  &__thumbs {
    height: 115px;

    .splide__slide {
      cursor: pointer;
    }
  }

  .splide__slide {
    border: 1px solid $gray-500;
  }

  .splide__track,
  .splide__list,
  .splide__slide {
    height: 100%;
  }

  .splide__slide img {
    height: 100%;
    width: 100%;
    object-fit: contain;
  }

  .splide--nav>.splide__track>.splide__list>.splide__slide {
    border: 1px solid $gray-400;
  }

  .splide__arrow {
    background: transparent;
    width: 16px;
    height: 16px;
    top: 45%;

    svg {
      width: 100%;
      height: 100%;
    }

    &--prev {
      transform: translateX(-50px);
    }

    &--next {
      transform: translateX(50px);
    }
  }

  .splide--nav>.splide__track>.splide__list>.splide__slide.is-active {
    border-color: $primary-color;
  }
}

.splide {
  .product-box__checkbox {
    display: none;
  }
}

.splide__progress__bar {
  height: 3px;
  background: red;
  z-index: 50;
}

@media (max-width: 1700px) {
  .main-slider {
    .splide__arrow {
      background: #fff;
      width: 40px;
      height: 40px;
      top: 40%;

      svg {
        width: 40%;
        height: 40%;
      }

      &--prev {
        transform: translateX(-10px);
      }

      &--next {
        transform: translateX(10px);
      }
    }
  }
}

@media(max-width:1450px) {
  .slider-multiple {
    .splide__arrow--next {
      right: 32px;
    }

    .splide__arrow--prev {
      left: 32px;
    }
  }
}

@media (max-width: 1200px) {
  .main-slider {
    max-height: 800px;

    .splide__list {
      height: 100%;
    }
  }

  .main-slider__thumbs {
    transform: translateY(-20px);
  }

  .product__slider {
    .splide__arrow {
      width: 30px;
      height: 30px;
      background: #fcb33b;
      opacity: 0.9;
      padding: 8px;
    }

    .splide__arrow--next {
      right: 55px;
      top: 36%;
    }

    .splide__arrow--prev {
      left: 55px;
      top: 36%;
    }
  }
  .product__slider__top {
    height: 32vw;
  }
  .product__slider__thumbs {
    height: 9vw;
  }
}

@media (max-width: 900px){ 
  .main-slider__top__txt { 
    min-width: 400px; 
      &:before {
        width: 20%;
      }
  }
}
 

@media (max-width: 700px) {
  .main-slider {
    height: 100%;
    margin-bottom: 40px;

    &__thumbs {
      display: none;
    }
  }

  .main-slider__top {
    .splide__slide {
      flex-direction: column-reverse;
      justify-content: flex-end;
      height: 100%;
    }

    &__txt {
      padding: 20px 16px 8px 16px;
      width: 100%;
      min-width: 100%;
    }

    &__img {
      width: 100%;
      height: 200px;
    }
  }

  .product__slider {
    .splide__arrow--next {
      right: 42px;
      top: 28%;
    }

    .splide__arrow--prev {
      left: 42px;
      top: 28%;
    }
  }

  .product__slider__top {
    height: 60vw;
  }
  .product__slider__thumbs {
    height: 16vw;
  }

  .main-slider__top__txt:before {
    display: none;
  }

}

@media (max-width: 500px) {
  .main-slider {
    height: unset;
  }

  .slider-multiple {
    .splide__arrow {
      display: none;
    }
  }

  .related-products {
    .arrow-hide .splide__pagination {
      display: inline-flex;
    }
  }

}