.reviews-section {
  font-size: 16px;
  line-height: 1.2;
  color: var(--text-color);
}
.reviews-section__title {
  font-size: 36px;
  font-weight: 700;
  line-height: 1;
  text-align: center;
  margin-bottom: 50px;
}
.reviews-section__container {
  position: relative;
  padding-left: 32px;
  padding-right: 32px;
}
.reviews-section__content {
  max-width: 1376px;
  margin: 0 auto;
}
.reviews-section__all-link {
  margin-top: 30px;
  opacity: 0.6;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}
.reviews-section_colored .reviews-section__container {
  padding-top: 50px;
  padding-bottom: 30px;
}
.reviews-section_last .reviews-section__container {
  padding-bottom: 70px;
}
.reviews-section_colored_orange .reviews-section__container {
  background: #FF790033;
}
.reviews-section_colored_blue .reviews-section__container {
  background: #0177CC33;
}
.reviews-section_colored .reviews-section__all-link {
  justify-content: flex-end;
  padding-right: 84px;
}
.reviews-section .scroll-block {
  display: flex;
  align-items: center;
  gap: 30px;
}
.reviews-section .scroll-wrapper {
  gap: 46px;
}
.reviews-section .scroll-item {
  padding: 0;
  width: calc((100% - 92px) / 3);
}
.reviews-section .scroll-control {
  position: relative;
  transform: unset;
  width: 54px;
  height: 54px;
  flex-shrink: 0;
}

@media (max-width: 991px) {
  .reviews-section {
    font-size: 14px;
  }
  .reviews-section__title {
    font-size: 20px;
    margin-bottom: 30px;
  }
  .reviews-section__container {
    padding-left: 40px;
    padding-right: unset;
  }
  .reviews-section__content {
    max-width: unset;
  }
  .reviews-section__all-link {
    gap: 5px;
  }
  .reviews-section__all-link svg {
    width: 15px;
  }
  .reviews-section_colored .reviews-section__container {
    padding-top: 40px;
    padding-bottom: 33px;
  }
  .reviews-section_last .reviews-section__container {
    padding-bottom: 50px;
  }
  .reviews-section_colored .reviews-section__title {
    margin-bottom: 40px;
  }
  .reviews-section_colored .reviews-section__all-link {
    justify-content: center;
    padding-right: unset;
  }
  .reviews-section .scroll-wrapper {
    gap: 30px;
    padding-right: 40px;
  }
  .reviews-section .scroll-control {
    display: none;
  }
  .reviews-section .scroll-item {
    width: 100%;
  }
}


/* Стили для модального окна */
.testimonial-modal {
  display: none;
  position: fixed;
  z-index: 9999;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(2px);
}

.testimonial-modal-content {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  max-width: 600px;
  width: 90%;
  max-height: 80vh;
  overflow: visible;
  animation: modalFadeIn 0.3s ease-out;
}

.testimonial-modal .testimonial-card {
  position: relative;
  margin: 0;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
  border: none;
  min-height: auto;
  transition: opacity 0.3s ease-in-out;
}

.testimonial-modal-close {
  position: absolute;
  top: 15px;
  right: 20px;
  background: none;
  border: none;
  font-size: 24px;
  font-weight: bold;
  color: #999;
  cursor: pointer;
  z-index: 3;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: all 0.2s ease;
}

.testimonial-modal-close:hover {
  color: #000;
  background-color: #f0f0f0;
}

.testimonial-card {
  background: #fff;
  padding: 15px 28px;
  border-radius: 10px;
  height: 100%;
}

.testimonial-card-clickable {
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.testimonial-card-clickable:hover {
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.testimonial-modal .testimonial-text {
  white-space: pre-wrap;
  word-wrap: break-word;
}

/* Стрелки навигации снаружи карточки отзыва */
.testimonial-modal-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background-color: #FAFAFA;
  border: none;
  width: 52px;
  height: 60px;
  z-index: 2;
  cursor: pointer;
  background-repeat: no-repeat;
  background-position: 8px center;
  transition: all 0.2s ease;
}

.testimonial-modal-nav:hover {
  transform: translateY(-50%) scale(1.1);
  filter: brightness(1.2);
}

.testimonial-modal-nav:disabled {
  opacity: 0.3;
  cursor: not-allowed;
  transform: translateY(-50%);
}

.testimonial-modal-nav:disabled:hover {
  transform: translateY(-50%);
  filter: none;
}

.testimonial-modal-prev {
  left: -52px;
  border-radius: 50% 0 0 50%;
  background-image: url('/new-design/landing/slider-arrow-left.svg');
}

.testimonial-modal-next {
  right: -52px;
  border-radius: 0 50% 50% 0;
  background-image: url('/new-design/landing/slider-arrow-right.svg');
}

/* Индикатор текущего отзыва */
.testimonial-modal-counter {
  position: absolute;
  bottom: -40px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(0, 0, 0, 0.7);
  color: white;
  padding: 5px 15px;
  border-radius: 15px;
  font-size: 12px;
  font-weight: 500;
  display: none;
}

/* Анимация перехода между отзывами */
.testimonial-modal .testimonial-card.transitioning {
  opacity: 0.3;
}

@keyframes modalFadeIn {
  from {
    opacity: 0;
    transform: translate(-50%, -60%);
  }
  to {
    opacity: 1;
    transform: translate(-50%, -50%);
  }
}

/* Адаптивность для мобильных устройств */
@media (max-width: 768px) {
  .testimonial-modal-content {
    width: 95%;
    max-height: 90vh;
  }
  
  .testimonial-modal .testimonial-card {
    padding: 20px;
  }

  .testimonial-modal-prev {
    left: -50px;
  }

  .testimonial-modal-next {
    right: -50px;
  }

  .testimonial-modal-nav {
    width: 35px;
    height: 35px;
  }
}

@media (max-width: 480px) {
  .testimonial-modal-prev {
    left: -40px;
  }

  .testimonial-modal-next {
    right: -40px;
  }

  .testimonial-modal-nav {
    width: 30px;
    height: 30px;
  }
}

@media (max-width: 400px) {
  .testimonial-modal-prev {
    left: -30px;
  }

  .testimonial-modal-next {
    right: -30px;
  }

  .testimonial-modal-nav {
    width: 25px;
    height: 25px;
  }
}
