@import url("/static/css/base.css");
@import url("/static/css/components.css");
@import url("/static/css/layout.css");
@import url("/static/css/navbar.css");
@import url("/static/css/animations.css");
@import url("/static/css/sections.css");

.testimonials-page {
  min-height: 100vh;
  background: var(--bg-primary);
  padding-top: 80px;
}

html {
  scroll-behavior: auto !important;
}

.testimonials-header {
  text-align: center;
  padding: var(--space-4xl) 0;
  background: var(--gradient-bg);
  position: relative;
  overflow: hidden;
}

.testimonials-header::before {
  content: "";
  position: absolute;
  top: -50%;
  right: -50%;
  width: 100%;
  height: 200%;
  background: radial-gradient(
    circle,
    rgba(79, 130, 246, 0.15) 0%,
    rgba(0, 0, 0, 0) 70%
  );
  z-index: 0;
  animation: pulse 15s infinite alternate;
}

.testimonials-header h1 {
  position: relative;
  z-index: 2;
}

.testimonials-header p {
  font-size: 1.375rem;
  color: var(--text-secondary);
  max-width: 600px;
  margin: 0 auto;
  position: relative;
  z-index: 2;
  line-height: 1.6;
}

.google-review-frame {
  margin: var(--space-3xl) auto 0;
  width: 100%;
  max-width: 680px;
  border-radius: var(--radius-2xl);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: var(--shadow-xl), 0 8px 30px rgba(0, 0, 0, 0.12);
  overflow: hidden;
  background: rgba(30, 41, 59, 0.7);
  backdrop-filter: blur(20px);
  font-family: var(--font-body);
  transition: all 0.4s ease;
  position: relative;
  z-index: 2;
}

.google-review-frame::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    135deg,
    rgba(79, 130, 246, 0.1) 0%,
    rgba(99, 102, 241, 0.05) 100%
  );
  opacity: 0;
  transition: opacity 0.4s ease;
  z-index: 0;
}

.google-review-frame:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-2xl), 0 12px 40px rgba(0, 0, 0, 0.15);
  border-color: rgba(79, 130, 246, 0.3);
}

.google-review-frame:hover::before {
  opacity: 1;
}

.google-review-header {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  padding: var(--space-lg) var(--space-xl);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  position: relative;
  z-index: 1;
  justify-content: center;
}

.google-review-header img {
  width: 32px;
  height: 32px;
  display: block;
  object-fit: contain;
  background: transparent;
}

.google-review-header span {
  font-weight: 600;
  font-size: 1.0625rem;
  color: var(--text-primary);
}

.google-review-body {
  padding: var(--space-2xl);
  text-align: center;
  position: relative;
  z-index: 1;
}

.google-review-link {
  display: inline-flex;
  align-items: center;
  gap: var(--space-md);
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: var(--radius-full);
  padding: 1rem 2rem;
  text-decoration: none;
  font-size: 1.0625rem;
  color: var(--text-primary);
  font-weight: 600;
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  backdrop-filter: blur(5px);
  position: relative;
  overflow: hidden;
  cursor: pointer;
}

.google-review-link::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.2),
    transparent
  );
  transition: left 0.7s ease;
}

.google-review-link:hover {
  background: rgba(255, 255, 255, 0.15);
  box-shadow: var(--shadow-lg);
  transform: translateY(-3px);
  border-color: rgba(79, 130, 246, 0.4);
}

.google-review-link:hover::before {
  left: 100%;
}

.carousel-section {
  padding: var(--space-5xl) 0 var(--space-4xl) 0;
  background: var(--bg-primary);
  position: relative;
  text-align: center;
}

.carousel-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--space-xl);
  position: relative;
}

.carousel-title {
  text-align: center;
  margin-bottom: var(--space-3xl);
  margin-top: var(--space-3xl);
  font-size: 2.5rem;
  color: var(--text-primary);
  position: relative;
  display: inline-block;
  z-index: 1;
}

.carousel-title::after {
  content: "";
  position: absolute;
  bottom: -10px;
  left: 50%;
  transform: translateX(-50%);
  width: 80px;
  height: 4px;
  background: var(--gradient-primary);
  border-radius: var(--radius-sm);
}

/* Carousel Card Wrapper */
.carousel-card {
  background: linear-gradient(
    135deg,
    rgba(19, 24, 55, 0.8) 0%,
    rgba(30, 39, 73, 0.6) 100%
  );
  backdrop-filter: blur(20px);
  border-radius: var(--radius-2xl);
  padding: var(--space-4xl) var(--space-4xl);
  box-shadow: var(--shadow-xl);
  border: 1px solid var(--border-medium);
  margin: 0 auto var(--space-2xl);
  max-width: 1100px;
  min-height: 600px;
  position: relative;
  overflow: visible;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.carousel-card::before {
  content: "";
  position: absolute;
  top: -50%;
  right: -50%;
  width: 100%;
  height: 200%;
  background: radial-gradient(
    circle,
    rgba(79, 70, 229, 0.1) 0%,
    transparent 70%
  );
  opacity: 0;
  transition: opacity var(--transition-slow);
  pointer-events: none;
  animation: rotate 20s linear infinite;
}

.carousel-card:hover::before {
  opacity: 1;
}

#carousel {
  perspective: 1200px;
  background: transparent;
  padding-top: 5%;
  font-size: 0;
  margin-bottom: var(--space-2xl);
  overflow: hidden;
  position: relative;
  width: 100%;
}

figure#spinner {
  transform-style: preserve-3d;
  height: 400px;
  transform-origin: 50% 50% -500px;
  transition: transform 1s cubic-bezier(0.23, 1, 0.32, 1);
}

figure#spinner img {
  width: 40%;
  max-width: 425px;
  position: absolute;
  left: 30%;
  transform-origin: 50% 50% -500px;
  outline: 1px solid transparent;
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-xl);
  transition: all 0.3s ease;
  filter: brightness(0.9);
}

figure#spinner img:hover {
  filter: brightness(1.05);
  box-shadow: var(--shadow-2xl), 0 0 20px rgba(79, 130, 246, 0.3);
}

figure#spinner img:nth-child(1) {
  transform: rotateY(0deg);
}
figure#spinner img:nth-child(2) {
  transform: rotateY(-45deg);
}
figure#spinner img:nth-child(3) {
  transform: rotateY(-90deg);
}
figure#spinner img:nth-child(4) {
  transform: rotateY(-135deg);
}
figure#spinner img:nth-child(5) {
  transform: rotateY(-180deg);
}
figure#spinner img:nth-child(6) {
  transform: rotateY(-225deg);
}
figure#spinner img:nth-child(7) {
  transform: rotateY(-270deg);
}
figure#spinner img:nth-child(8) {
  transform: rotateY(-315deg);
}

.carousel-nav {
  color: var(--primary);
  margin: 5%;
  display: inline-block;
  text-decoration: none;
  font-size: 2.5rem;
  transition: all 0.3s ease;
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 10;
  background: rgba(15, 23, 42, 0.8);
  backdrop-filter: blur(10px);
  width: 60px;
  height: 60px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-lg);
  cursor: pointer;
}

.carousel-nav:hover {
  color: var(--primary-light);
  background: rgba(79, 130, 246, 0.2);
  transform: translateY(-50%) scale(1.1);
  box-shadow: var(--shadow-xl), 0 0 15px rgba(79, 130, 246, 0.4);
}

.carousel-nav.prev {
  left: var(--space-xl);
}
.carousel-nav.next {
  right: var(--space-xl);
}

@media (max-width: 768px) {
  .testimonials-header h1 {
    font-size: 2.5rem;
  }

  .testimonials-header p {
    font-size: 1.125rem;
  }

  .carousel-card {
    padding: var(--space-2xl) var(--space-xl);
    max-width: 100%;
  }

  #carousel {
    padding-top: 10%;
  }

  figure#spinner {
    height: 300px;
  }

  .carousel-nav {
    width: 50px;
    height: 50px;
    font-size: 2rem;
  }

  .carousel-nav.prev {
    left: var(--space-sm);
  }
  .carousel-nav.next {
    right: var(--space-sm);
  }
}

@media (max-width: 480px) {
  .carousel-card {
    padding: var(--space-xl) var(--space-md);
  }

  figure#spinner {
    height: 250px;
  }

  figure#spinner img {
    width: 50%;
  }
}