/* ========== Reviews Block v3 ========== */
/* BEM: .ort-reviews__* */

.ort-reviews {
  display: flex;
  flex-direction: column;
  gap: 24px;
  max-width: 1216px;
  margin: 0 auto;
  width: 100%;
}

/* ── Заголовок ── */
.ort-reviews__title {
  font-family: Manrope, sans-serif;
  font-weight: 800;
  font-size: 32px;
  line-height: 38px;
  color: #0B3847;
  margin: 0;
}

/* ── Плашки площадок ── */
.ort-reviews__platforms {
  display: flex;
  gap: 24px;
  width: 100%;
}

.ort-reviews__platform {
  flex: 1;
  display: flex;
  gap: 20px;
  align-items: flex-start;
  padding: 20px;
  background: #fff;
  border-radius: 20px;
  box-shadow: 0 10px 15px rgba(0,0,0,0.25);
  text-decoration: none;
  color: inherit;
  transition: transform 0.2s, box-shadow 0.2s;
}
.ort-reviews__platform:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 20px rgba(0,0,0,0.3);
}

.ort-reviews__platform-logo {
  width: 47px;
  height: 68px;
  flex-shrink: 0;
  border-radius: 10px;
  object-fit: contain;
}

.ort-reviews__platform-info {
  display: flex;
  flex-direction: column;
  gap: 0.8px;
  flex: 1;
  min-width: 0;
}

.ort-reviews__platform-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.ort-reviews__platform-name,
.ort-reviews__platform-rating {
  font-family: Manrope, sans-serif;
  font-weight: 700;
  font-size: 17px;
  line-height: 21px;
  color: #0B3847;
}

/* Переключение полное/короткое название площадки */
.ort-reviews__name-short {
  display: none;
}

.ort-reviews__platform-stars {
  display: flex;
  gap: 4px;
  padding-bottom: 2px;
}

.ort-reviews__platform-star {
  font-size: 20px;
  line-height: 24px;
  color: #FCA311;
}

.ort-reviews__platform-count {
  font-family: Manrope, sans-serif;
  font-weight: 500;
  font-size: 17px;
  line-height: 21px;
  color: #8E8E8E;
}

/* ── Слайдер отзывов ── */
.ort-reviews__slider-wrap {
  position: relative;
  overflow: hidden;
  /* padding даёт место для теней карточек, overflow:hidden скрывает горизонтальный оверфлоу */
  padding: 12px 0;
}

/* Swiper ставит overflow:clip — оверрайдим на visible, чтобы тени выходили в padding slider-wrap */
.ort-reviews__slider.swiper {
  overflow: visible;
}

.ort-reviews__slider .swiper-slide {
  width: 377px;
  height: auto;
}

/* ── Карточка отзыва ── */
.ort-reviews__card {
  background: #fff;
  border-radius: 20px;
  box-shadow: 0 4px 8px rgba(0,0,0,0.2);
  padding: 15px;
  min-height: 220px;
  display: flex;
  flex-direction: column;
  position: relative;
  text-decoration: none;
  color: inherit;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
}
.ort-reviews__card:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 12px rgba(0,0,0,0.25);
}

.ort-reviews__card-source {
  font-family: Roboto, sans-serif;
  font-size: 11.8px;
  line-height: 21px;
  padding-bottom: 4px;
}
.ort-reviews__card-source-name {
  font-weight: 700;
  color: #0B3847;
}
.ort-reviews__card-source-label {
  font-weight: 400;
  color: #8E8E8E;
}

.ort-reviews__card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  padding-bottom: 8px;
}

.ort-reviews__card-stars {
  display: flex;
  gap: 2px;
}

.ort-reviews__card-star {
  width: 16px;
  height: 16px;
  color: #FCA311;
}
.ort-reviews__card-star svg {
  width: 16px;
  height: 16px;
  fill: #FCA311;
}
.ort-reviews__card-star--empty svg {
  fill: #ddd;
}

.ort-reviews__card-date {
  font-family: Roboto, sans-serif;
  font-weight: 500;
  font-size: 11.8px;
  line-height: 21px;
  color: #0B3847;
  margin-left: auto;
}

.ort-reviews__card-text {
  font-family: Roboto, sans-serif;
  font-weight: 500;
  font-size: 15.6px;
  line-height: 20.8px;
  color: #0B3847;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  max-height: calc(20.8px * 4);
  flex: 1;
}

.ort-reviews__card-more {
  font-family: Roboto, sans-serif;
  font-weight: 300;
  font-size: 12.7px;
  line-height: 21px;
  color: #0B3847;
  margin-top: 10px;
}

/* ── Навигация ── */
.ort-reviews__nav {
  display: flex;
  gap: 16px;
  align-items: center;
}

.ort-reviews__nav-btn {
  width: 40px;
  height: 40px;
  border-radius: 20px;
  background: #fff;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  padding: 0;
  flex-shrink: 0;
  transition: opacity 0.2s;
  -webkit-tap-highlight-color: transparent;
}
.ort-reviews__nav-btn:disabled {
  opacity: 0.5;
  cursor: default;
}
.ort-reviews__nav-btn svg {
  width: 16px;
  height: 16px;
  fill: #212121;
}

.ort-reviews__progress {
  flex: 1;
  display: flex;
  align-items: center;
  padding-top: 20px;
}

.ort-reviews__progress-bar {
  display: flex;
  width: 100%;
  height: 2px;
}

.ort-reviews__progress-seg {
  flex: 1;
  height: 2px;
  background: rgba(0,0,0,0.05);
  transition: background 0.3s;
}
.ort-reviews__progress-seg:first-child {
  border-radius: 1px 0 0 1px;
}
.ort-reviews__progress-seg:last-child {
  border-radius: 0 1px 1px 0;
}
.ort-reviews__progress-seg--active {
  background: #FCA311;
}

/* ── Popup отзыва ── */
.ort-reviews__popup-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.6);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s, visibility 0.3s;
  padding: 20px;
  box-sizing: border-box;
}
.ort-reviews__popup-overlay--active {
  opacity: 1;
  visibility: visible;
}

.ort-reviews__popup {
  background: #fff;
  border-radius: 20px;
  max-width: 560px;
  width: 100%;
  max-height: 80vh;
  overflow-y: auto;
  padding: 32px;
  position: relative;
  box-shadow: 0 20px 40px rgba(0,0,0,0.3);
}

.ort-reviews__popup-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 32px;
  height: 32px;
  border: none;
  background: #f5f5f5;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  color: #333;
  line-height: 1;
  transition: background 0.2s;
}
.ort-reviews__popup-close:hover {
  background: #e0e0e0;
}

.ort-reviews__popup-date {
  font-family: Roboto, sans-serif;
  font-size: 13px;
  color: #8E8E8E;
  margin-bottom: 12px;
}

.ort-reviews__popup-stars {
  display: flex;
  gap: 3px;
  margin-bottom: 16px;
}
.ort-reviews__popup-stars svg {
  width: 20px;
  height: 20px;
  fill: #FCA311;
}

.ort-reviews__popup-text {
  font-family: Roboto, sans-serif;
  font-size: 16px;
  line-height: 24px;
  color: #212121;
  margin-bottom: 20px;
  white-space: pre-line;
}

/* ── Мобилка ── */
@media (max-width: 768px) {
  .ort-reviews {
    gap: 16px;
    padding: 0 16px;
    box-sizing: border-box;
  }
  .ort-reviews__title {
    font-size: 24px;
    line-height: 30px;
  }
  .ort-reviews__platforms {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 12px;
  }
  .ort-reviews__platform {
    padding: 12px;
    gap: 10px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.15);
    min-width: 0;
    overflow: hidden;
  }
  .ort-reviews__platform-logo {
    width: 36px;
    height: 52px;
  }
  .ort-reviews__platform-name,
  .ort-reviews__platform-rating {
    font-size: 14px;
    line-height: 18px;
  }
  .ort-reviews__name-full {
    display: none;
  }
  .ort-reviews__name-short {
    display: inline;
  }
  .ort-reviews__platform-star {
    font-size: 16px;
    line-height: 20px;
  }
  .ort-reviews__platform-count {
    font-size: 13px;
    line-height: 18px;
  }
  /* Слайдер: правый край уходит до края экрана */
  .ort-reviews__slider-wrap {
    margin-right: -16px;
  }
  .ort-reviews__slider .swiper-slide {
    width: 300px;
  }
  .ort-reviews__card {
    min-height: 200px;
  }
  .ort-reviews__card-text {
    font-size: 14px;
    line-height: 19px;
    -webkit-line-clamp: 5;
    max-height: calc(19px * 5); /* ровно 5 строк */
  }
  /* Кнопки навигации скрыты — свайп пальцем */
  .ort-reviews__nav {
    display: none;
  }
}

@media (max-width: 480px) {
  .ort-reviews__slider .swiper-slide {
    width: 280px;
  }
}
