.projects-detail-slider {
  position: relative;
  width: 100%;
  margin: 75px auto;

  @include sm {
    margin: 50px auto;
  }

  &__wrapper {
    width: 100%;
    overflow: hidden;
  }

  &__container {
    width: 100%;
    position: relative;
    margin: 0 auto;
    max-width: $max-width;
    padding: 100px 20px 0;

    @include md {
      padding: 70px 20px 0;
    }

    @include sm {
      padding: 50px 20px 0;
    }
  }

  &__background {
    width: 100%;
    height: 100%;
    background-color: $gray-bluish;
    position: absolute;
    top: 0;
    left: 0;
    pointer-events: none;
  }

  &__slider {
    overflow: visible;
    width: 100%;
    opacity: 1;
    transition: 0.3s ease-out;

    @include sm {
      padding: 0 20px;
    }

    &.projects-detail-slider--hide {
      opacity: 0;
    }
  }

  &__slide {
    width: auto !important;
    max-width: 780px;
    display: flex;
    flex-direction: column;
    align-items: center;

    @include md {
      max-width: 100%;
    }
  }

  &__slide-image {
    cursor: pointer;
    position: relative;
    overflow: hidden;
    height: 480px;
    display: flex;
    align-items: center;
    justify-content: center;
    transform: translateY(0px) scale(0.8);
    transition: all 0.3s ease-out;

    @include md {
      height: 270px;
    }

    * {
      pointer-events: none;
    }

    .swiper-slide-active & {
      transform: translateY(-100px) scale(1);

      @include md {
        transform: translateY(-70px) scale(1);
      }

      @include sm {
        transform: translateY(-50px) scale(1);
      }
    }

    picture {
      height: 100%;
    }

    img {
      height: 100%;
      object-fit: contain;
      object-position: bottom;
      display: block;
    }
  }

  &__credits {
    position: absolute;
    bottom: 0;
    right: 0;
    padding: 8px 16px;
    color: $white;
    font-size: 1.4rem;
    line-height: 2.3rem;
    background: rgba(13, 24, 41, 0.4);
    opacity: 0;
    transition: opacity 250ms ease-out;

    .swiper-slide-active & {
      opacity: 1;
    }

    @include sm {
      font-size: 1.2rem;
      line-height: 2.1rem;
    }
  }

  &__caption {
    font-size: 1.6rem;
    line-height: 2rem;
    letter-spacing: 0.02rem;
    color: $primary-color;
    text-align: center;
    max-width: 440px;
    margin: 0 auto;
    opacity: 0;
    transform: translateY(-50px);
    transition: opacity 0.3s ease-out;

    @include md {
      transform: translateY(-40px);
    }

    @include sm {
      transform: translateY(-30px);
      font-size: 1.4rem;
      line-height: 1.8rem;
    }

    .swiper-slide-active & {
      opacity: 1;
    }
  }

  &__prev,
  &__next {
    background-image: none;
    background-color: $white;
    border-radius: 100%;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
  }

  &__prev {
    left: 120px;

    @include md {
      left: 10px;
    }

    @include sm {
      display: none;
    }

    svg {
      transform: rotate(90deg);
      margin-right: 2px;
    }
  }

  &__next {
    right: 120px;

    @include md {
      right: 10px;
    }

    @include sm {
      display: none;
    }

    svg {
      transform: rotate(-90deg);
      margin-left: 2px;
    }
  }

  &__pagination {
    .swiper-pagination-bullet {
      width: 6px;
      height: 6px;
      border-radius: 100%;
      background-color: $gray-border;
      margin: 0 3px !important;
      cursor: pointer;
    }

    .swiper-pagination-bullet-active {
      background-color: $primary-color;
    }
  }

  // Start Lightbox

  &__lightbox {
    overflow: hidden;
    position: fixed;
    background-color: rgba($color: $primary-color, $alpha: 0.9);
    width: 100%;
    height: 100vh;
    top: 0;
    left: 0;
    z-index: $z-header;
    display: flex;
    align-items: center;
    pointer-events: none;
    opacity: 0;
    transition: opacity 250ms ease-out;

    &.projects-detail-slider__lightbox--open {
      opacity: 1;
      pointer-events: all;
    }
  }

  &__lightbox-close {
    position: absolute;
    top: 30px;
    right: 50px;
    cursor: pointer;

    svg {
      width: 20px;
      height: 20px;

      g, path {
        fill: $white;
      }
    }
  }

  &__lightbox-wrapper {
    width: 100%;
    overflow: hidden;
  }

  &__lightbox-container {
    width: 100%;
  }

  &__lightbox-slider {
    overflow: visible;
    width: 100%;

    @include sm {
      padding: 0 20px;
    }
  }

  &__lightbox-slide {
    width: auto !important;
    max-width: 950px;
    display: flex;
    flex-direction: column;
    align-items: center;

    @include md {
      max-width: 100%;
    }
  }

  &__lightbox-slide-image {
    position: relative;
    overflow: hidden;
    height: calc(75vh - 40px);
    padding-bottom: 40px;
    display: flex;
    align-items: center;
    justify-content: center;

    @include md {
      height: calc(50vh - 40px);
    }

    picture {
      height: 100%;
    }

    img {
      height: 100%;
      object-fit: contain;
      object-position: bottom;
      display: block;
    }
  }

  &__lightbox-credits {
    position: absolute;
    bottom: 40px;
    right: 0;
    padding: 8px 16px;
    color: $white;
    font-size: 1.4rem;
    line-height: 2.3rem;
    background: rgba(13, 24, 41, 0.4);
    opacity: 0;
    transition: opacity 250ms ease-out;

    .swiper-slide-active & {
      opacity: 1;
    }

    @include sm {
      font-size: 1.2rem;
      line-height: 2.1rem;
    }
  }

  &__lightbox-caption {
    font-size: 1.6rem;
    line-height: 2rem;
    letter-spacing: 0.02rem;
    color: $white;
    text-align: center;
    max-width: 440px;
    margin: 0 auto;
    opacity: 0;
    transform: translateY(-30px);
    transition: opacity 0.3s ease-out;

    @include sm {
      font-size: 1.4rem;
      line-height: 2rem;
    }

    .swiper-slide-active & {
      opacity: 1;
    }
  }

  &__lightbox-prev,
  &__lightbox-next {
    background-image: none;
    background-color: $white;
    border-radius: 100%;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
  }

  &__lightbox-prev {
    left: 120px;

    @include md {
      left: 20px;
    }

    @include sm {
      display: none;
    }

    svg {
      transform: rotate(90deg);
      margin-right: 2px;
    }
  }

  &__lightbox-next {
    right: 120px;

    @include md {
      right: 20px;
    }

    @include sm {
      display: none;
    }

    svg {
      transform: rotate(-90deg);
      margin-left: 2px;
    }
  }

  &__lightbox-pagination {
    .swiper-pagination-bullet {
      width: 6px;
      height: 6px;
      border-radius: 100%;
      background-color: $gray-border;
      margin: 0 3px !important;
      cursor: pointer;
    }

    .swiper-pagination-bullet-active {
      background-color: $primary-color;
    }
  }

  // End LightBox
}
