/* ===== Testimonials Slider ===== */
.ms-testimonials {
  padding: clamp(40px, 8vw, 80px) 16px;
}
.ms-testimonials .ms-title {
  text-align: center;
  margin-bottom: 22px;
}

/* вьюпорт */
.reviews-viewport {
  overflow: hidden;
  border-radius: var(--radius, 14px);
  margin-top: 32px;
}

/* лента */
.reviews-container {
  display: flex;
  will-change: transform;
  touch-action: pan-y;
}

/* обёртка карточки — для отступов */
.review-wrapper {
  padding: 0 10px;
  box-sizing: border-box;
}
.review-card {
  height: 100%;
  padding: 18px;
  background: var(--panel-2, #2d2d2d);
  border: 1px solid var(--border, rgba(255,255,255,.12));
  border-radius: var(--radius, 14px);
  box-shadow: var(--shadow, 0 10px 30px rgba(0,0,0,.35));
  backdrop-filter: blur(8px) saturate(120%);
  display: flex;
  flex-direction: column;
  gap: 10px;
}

/* элементы внутри карточки */
.ms-testi__top {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.ms-badge {
  display: inline-flex;
  padding: 4px 8px;
  border-radius: 999px;
  font-size: .9rem;
  font-weight: 700;
  color: #fff;
  background: color-mix(in oklab, var(--accent) 60%, #000 0%);
  box-shadow: 0 1px 10px color-mix(in oklab, var(--accent) 25%, transparent);
}
.ms-testi__text {
  margin: 4px 0 8px;
  color: var(--text, #fff);
  line-height: 1.55;
}
.ms-testi__author {
  display: flex;
  align-items: center;
  gap: 12px;
}
.ms-testi__name {
  font-weight: 800;
  margin: 0;
}
.ms-testi__meta {
  font-size: .95rem;
  color: var(--muted, #b7bdc6);
  margin: 0;
}

/* аватар */
.ms-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-weight: 800;
  color: #fff;
  background: linear-gradient(135deg, var(--accent), var(--accent-2, #ff3d7c));
  box-shadow: 0 8px 22px color-mix(in oklab, var(--accent) 35%, transparent);
}
.ms-avatar::after {
  content: attr(data-initials);
  font-size: 1rem;
}

/* точки */
.carousel-dots {
  display: flex;
  gap: 8px;
  justify-content: center;
  margin-top: 16px;
}
.carousel-dots .dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(255,255,255,.25);
  transition: transform .18s ease, background .18s ease;
  cursor: pointer;
}
.carousel-dots .dot.active {
  background: color-mix(in oklab, var(--accent) 70%, #000 0%);
  transform: scale(1.15);
}


/* Базовый текст */
.ms-testi__text { position: relative; }

/* Состояние: обрезано */
.review-card:not(.is-expanded) .ms-testi__text.clamped{
  max-height: var(--clamp-max, 0px);
  overflow: hidden;
}

/* Мягкий градиент снизу, когда обрезано */
.review-card:not(.is-expanded) .ms-testi__text.clamped::after{
  content:"";
  position:absolute;
  left:0; right:0; bottom:0;
  height:3rem;
  pointer-events:none;
}

/* Когда раскрыто — ограничений нет */
.review-card.is-expanded .ms-testi__text{
  max-height: none !important;
}

/* Кнопка-ссылка */
.ms-link{
  color: var(--accent);
  background: transparent;
  border: 0;
  padding: 0;
  cursor: pointer;
  font-weight: 600;
}
.ms-link:hover{ text-decoration: underline; }

/* Прятать кнопку, если текста мало */
.review-card:not(.has-more) .ms-link{ display:none; }