/* ============================================
   TESTIMONIALS SECTION
   Цвета как в блоке с формой обратной связи, 6 отзывов
   ============================================ */

.testimonials {
  position: relative;
  width: 100%;
  max-width: 1920px;
  margin: clamp(160px, 12vw, 220px) auto clamp(160px, 12vw, 220px);
  padding: 0 clamp(1.5rem, 5vw, 268px);
  box-sizing: border-box;
}

/* Как контакт-блок: фон #0D0E0F, градиент как у формы */
.testimonials__container {
  position: relative;
  width: 100%;
  max-width: 1384px;
  margin: 0 auto;
  padding: clamp(48px, 6vw, 72px) clamp(24px, 4vw, 50px);
  background: linear-gradient(180deg, rgba(13, 14, 15, 0.88) 0%, rgba(13, 14, 15, 1) 100%);
  border-radius: 40px;
  overflow: hidden;
  border: 1px solid rgba(245, 247, 251, 0.05);
  box-shadow: 0px 2px 8px rgba(0, 0, 0, 0.15),
              0px 16px 61px rgba(0, 0, 0, 0.2);
}

.testimonials__title {
  font-family: var(--font-primary);
  font-weight: 600;
  font-size: clamp(2.5rem, 5vw, 72px);
  line-height: 0.85em;
  letter-spacing: -0.04em;
  color: #EAEAEA;
  margin: 0 0 clamp(40px, 5vw, 56px);
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.testimonials__title-line {
  display: block;
}

.testimonials__title-word--serif {
  font-family: 'Nyght Serif', serif;
  font-weight: 500;
  font-style: italic;
  color: #EAEAEA;
}

/* --- Сетка: 6 отзывов, 3 колонки --- */
.testimonials__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(20px, 2.5vw, 32px);
}

/* Карточки как поля формы: фон и бордер из contact */
.testimonials__card {
  background: rgba(245, 247, 251, 0.05);
  border: 1px solid rgba(245, 247, 251, 0.05);
  border-radius: 24px;
  padding: clamp(24px, 3vw, 32px);
  display: flex;
  flex-direction: column;
  gap: 24px;
  position: relative;
  overflow: hidden;
  transition: border-color var(--transition-base), background var(--transition-base), box-shadow var(--transition-base);
}

/* Красная полоска как кнопка отправки формы (градиент из contact__submit-btn) */
.testimonials__card::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  border-radius: 4px 0 0 4px;
  background: radial-gradient(circle at 11% 5%, rgba(255, 77, 77, 0) 52%, rgba(255, 77, 77, 1) 100%),
              radial-gradient(circle at 32% 0%, rgba(228, 41, 41, 0) 38%, rgba(228, 41, 41, 1) 100%),
              #FF4545;
}

.testimonials__card:hover {
  border-color: rgba(245, 247, 251, 0.1);
  background: rgba(245, 247, 251, 0.08);
  box-shadow: 0px 8px 24px rgba(255, 77, 77, 0.15);
}

.testimonials__quote {
  margin: 0;
  padding: 0 0 0 8px;
  flex: 1;
}

.testimonials__text {
  font-family: var(--font-slim);
  font-weight: 400;
  font-size: clamp(0.9375rem, 1.1vw, 17px);
  line-height: 1.4;
  color: rgba(245, 247, 251, 0.8);
  margin: 0;
}

.testimonials__author {
  display: flex;
  align-items: center;
  gap: 16px;
}

/* Аватар в стиле кнопки формы: красный градиент */
.testimonials__avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-family: var(--font-primary);
  font-weight: 600;
  font-size: 14px;
  letter-spacing: -0.02em;
  color: #FFFFFF;
  border: none;
  background: radial-gradient(circle at 11% 5%, rgba(255, 77, 77, 0) 52%, rgba(255, 77, 77, 1) 100%),
              radial-gradient(circle at 32% 0%, rgba(228, 41, 41, 0) 38%, rgba(228, 41, 41, 1) 100%),
              #FF4545;
  transition: box-shadow var(--transition-base);
}

.testimonials__card:hover .testimonials__avatar {
  box-shadow: 0px 8px 24px rgba(255, 77, 77, 0.3);
}

.testimonials__author-info {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.testimonials__name {
  font-family: var(--font-primary);
  font-weight: 600;
  font-size: 16px;
  font-style: normal;
  color: #EAEAEA;
  margin: 0;
}

.testimonials__role {
  font-family: var(--font-slim);
  font-weight: 400;
  font-size: 14px;
  color: #898989;
  margin: 0;
}

/* Responsive: 6 отзывов — на планшете 2 колонки, на мобиле 1 */
@media (max-width: 1024px) {
  .testimonials {
    margin-top: clamp(120px, 10vw, 160px);
    margin-bottom: clamp(120px, 10vw, 160px);
    padding-left: 1.5rem;
    padding-right: 1.5rem;
  }

  .testimonials__container {
    border-radius: 24px;
    padding: 40px 24px;
  }

  .testimonials__grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }

  .testimonials__title {
    font-size: clamp(2rem, 6vw, 48px);
    margin-bottom: 36px;
  }
}

@media (max-width: 768px) {
  .testimonials {
    margin-top: 100px;
    margin-bottom: 100px;
    padding-left: 1rem;
    padding-right: 1rem;
  }

  .testimonials__container {
    border-radius: 20px;
    padding: 32px 16px;
  }

  .testimonials__grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .testimonials__title {
    font-size: clamp(1.75rem, 7vw, 36px);
    margin-bottom: 28px;
  }

  .testimonials__card {
    padding: 24px 20px;
    gap: 20px;
  }

  .testimonials__card::before {
    width: 3px;
  }

  .testimonials__text {
    font-size: 16px;
  }

  .testimonials__avatar {
    width: 44px;
    height: 44px;
    font-size: 13px;
  }
}

@media (max-width: 480px) {
  .testimonials {
    margin-top: 80px;
    margin-bottom: 80px;
  }

  .testimonials__container {
    padding: 24px 16px;
  }

  .testimonials__card {
    padding: 20px 16px;
  }
}
