/* ============ TESTIMONIALS SECTION ============ */
.testimonials {
  position: relative;
  padding: 120px 0;
  background: var(--dark-bg);
  overflow: hidden;
}

/* Background Effects */
.testimonials-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.testimonials-orb-1 {
  position: absolute;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(124, 92, 252, 0.15), transparent);
  top: -200px;
  right: -200px;
  border-radius: 50%;
  filter: blur(60px);
  animation: orbFloat 10s ease-in-out infinite;
}

.testimonials-orb-2 {
  position: absolute;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(0, 212, 255, 0.1), transparent);
  bottom: -150px;
  left: -150px;
  border-radius: 50%;
  filter: blur(60px);
  animation: orbFloat 8s ease-in-out infinite reverse;
}

.grid-pattern {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image:
    linear-gradient(rgba(124, 92, 252, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(124, 92, 252, 0.03) 1px, transparent 1px);
  background-size: 50px 50px;
}

.testimonials-container {
  position: relative;
  z-index: 2;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 60px;
}

/* Section Header */
.section-header {
  text-align: center;
  margin-bottom: 60px;
}

.section-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(124, 92, 252, 0.1);
  border: 1px solid rgba(124, 92, 252, 0.3);
  padding: 8px 20px;
  border-radius: 50px;
  font-size: 13px;
  font-weight: 600;
  color: var(--primary);
  margin-bottom: 20px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.section-badge i {
  color: var(--accent);
  animation: starPulse 2s ease-in-out infinite;
}

.section-title {
  font-size: 48px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 20px;
  line-height: 1.2;
}

.gradient-text {
  background: var(--gradient-1);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.section-description {
  font-size: 18px;
  color: var(--text-secondary);
  max-width: 600px;
  margin: 0 auto;
  line-height: 1.6;
}

/* Auto-scrolling Carousel Wrapper */
.testimonial-carousel-wrapper {
  position: relative;
  width: 100%;
  overflow: hidden;
  mask-image: linear-gradient(to right,
      transparent,
      black 10%,
      black 90%,
      transparent);
  -webkit-mask-image: linear-gradient(to right,
      transparent,
      black 10%,
      black 90%,
      transparent);
}

.carousel-track {
  display: flex;
  gap: 30px;
  animation: scrollCarousel 40s linear infinite;
  width: fit-content;
}

.carousel-track:hover {
  animation-play-state: paused;
}

/* Testimonial Card */
.testimonial-card {
  min-width: 380px;
  max-width: 380px;
  background: var(--dark-card);
  border: 1px solid rgba(124, 92, 252, 0.15);
  border-radius: 24px;
  padding: 30px;
  position: relative;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  cursor: pointer;
  overflow: hidden;
  flex-shrink: 0;
}

.testimonial-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--gradient-1);
  transform: scaleX(0);
  transition: transform 0.4s ease;
  transform-origin: left;
}

.testimonial-card:hover {
  transform: translateY(-10px);
  border-color: var(--primary);
  box-shadow: 0 20px 40px rgba(124, 92, 252, 0.2);
}

.testimonial-card:hover::before {
  transform: scaleX(1);
}

.card-glow {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: radial-gradient(circle at 50% 0%, rgba(124, 92, 252, 0.1), transparent 70%);
  opacity: 0;
  transition: opacity 0.4s ease;
  pointer-events: none;
}

.testimonial-card:hover .card-glow {
  opacity: 1;
}

/* User Profile */
.user-profile {
  display: flex;
  align-items: center;
  gap: 15px;
  margin-bottom: 15px;
  position: relative;
  z-index: 1;
}

.user-image {
  position: relative;
  width: 60px;
  height: 60px;
  flex-shrink: 0;
}

.user-image img {
  width: 100%;
  height: 100%;
  border-radius: 16px;
  object-fit: cover;
  border: 2px solid rgba(124, 92, 252, 0.3);
  transition: all 0.3s ease;
}

.testimonial-card:hover .user-image img {
  border-color: var(--primary);
  box-shadow: 0 0 20px rgba(124, 92, 252, 0.3);
}

.verified-badge {
  position: absolute;
  bottom: -4px;
  right: -4px;
  width: 24px;
  height: 24px;
  background: var(--success);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 3px solid var(--dark-card);
  animation: verifiedPulse 3s ease-in-out infinite;
}

.verified-badge i {
  font-size: 10px;
  color: white;
}

.user-details h4 {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.user-details span {
  font-size: 13px;
  color: var(--text-muted);
}

/* Rating */
.rating {
  display: flex;
  gap: 4px;
  margin-bottom: 15px;
  position: relative;
  z-index: 1;
}

.rating i {
  color: var(--accent);
  font-size: 14px;
  animation: starShine 2s ease-in-out infinite;
}

.rating i:nth-child(1) {
  animation-delay: 0s;
}

.rating i:nth-child(2) {
  animation-delay: 0.2s;
}

.rating i:nth-child(3) {
  animation-delay: 0.4s;
}

.rating i:nth-child(4) {
  animation-delay: 0.6s;
}

.rating i:nth-child(5) {
  animation-delay: 0.8s;
}

/* Testimonial Text */
.testimonial-text {
  color: var(--text-secondary);
  font-size: 14px;
  line-height: 1.7;
  margin-bottom: 20px;
  font-style: italic;
  position: relative;
  z-index: 1;
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Investment Returns */
.investment-returns {
  display: flex;
  gap: 10px;
  position: relative;
  z-index: 1;
}

.return-badge {
  background: rgba(0, 214, 143, 0.1);
  border: 1px solid rgba(0, 214, 143, 0.3);
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 600;
  color: var(--success);
}

.period-badge {
  background: rgba(124, 92, 252, 0.1);
  border: 1px solid rgba(124, 92, 252, 0.3);
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 13px;
  color: var(--primary);
}

/* Navigation Controls */
.carousel-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  margin-top: 40px;
}

.control-btn {
  width: 50px;
  height: 50px;
  background: var(--dark-card);
  border: 2px solid rgba(124, 92, 252, 0.3);
  border-radius: 50%;
  color: var(--text-primary);
  font-size: 18px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
}

.control-btn:hover {
  background: var(--primary);
  border-color: var(--primary);
  transform: scale(1.1);
  box-shadow: 0 10px 30px rgba(124, 92, 252, 0.4);
}

.progress-indicator {
  width: 200px;
  height: 4px;
  background: rgba(124, 92, 252, 0.1);
  border-radius: 2px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: var(--gradient-1);
  border-radius: 2px;
  width: 0%;
  animation: progressAnimation 40s linear infinite;
}

.carousel-track:hover~.carousel-controls .progress-fill,
.carousel-controls:hover .progress-fill {
  animation-play-state: paused;
}

/* ============ ANIMATIONS ============ */
@keyframes scrollCarousel {
  0% {
    transform: translateX(0);
  }

  100% {
    transform: translateX(-50%);
  }
}

@keyframes orbFloat {

  0%,
  100% {
    transform: translate(0, 0) scale(1);
  }

  33% {
    transform: translate(30px, -30px) scale(1.1);
  }

  66% {
    transform: translate(-20px, 20px) scale(0.9);
  }
}

@keyframes starPulse {

  0%,
  100% {
    transform: scale(1);
  }

  50% {
    transform: scale(1.2) rotate(10deg);
  }
}

@keyframes starShine {

  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }

  50% {
    opacity: 0.7;
    transform: scale(0.9);
  }
}

@keyframes verifiedPulse {

  0%,
  100% {
    box-shadow: 0 0 0 0 rgba(0, 214, 143, 0.4);
  }

  50% {
    box-shadow: 0 0 0 8px rgba(0, 214, 143, 0);
  }
}

@keyframes progressAnimation {
  0% {
    width: 0%;
  }

  100% {
    width: 100%;
  }
}

/* ============ RESPONSIVE ============ */
@media (max-width: 1200px) {
  .testimonial-card {
    min-width: 350px;
    max-width: 350px;
  }

  .section-title {
    font-size: 40px;
  }
}

@media (max-width: 768px) {
  .testimonials {
    padding: 80px 0;
  }

  .testimonials-container {
    padding: 0 30px;
  }

  .section-title {
    font-size: 32px;
  }

  .section-description {
    font-size: 16px;
  }

  .testimonial-card {
    min-width: 300px;
    max-width: 300px;
    padding: 25px;
  }

  .carousel-track {
    gap: 20px;
  }

  .progress-indicator {
    width: 150px;
  }
}

@media (max-width: 480px) {
  .testimonial-card {
    min-width: 280px;
    max-width: 280px;
    padding: 20px;
  }

  .user-image {
    width: 50px;
    height: 50px;
  }

  .testimonial-text {
    font-size: 13px;
  }
}