/* == Reviews Section == */

.reviews-section {
  padding: 80px 0;
  background: var(--bg-primary, #f8f9fa);
  color: var(--text-primary, #1a1a1a);
  text-align: center;
  overflow: visible;
}

/* Dark theme support */
[data-theme="dark"] .reviews-section {
  background: #0c1420;
  color: #fff;
}

/* Header */

.reviews-header {
  margin-bottom: 40px;
}

.reviews-header h2 {
  font-size: 2.5rem;
  margin-bottom: 12px;
}

.reviews-header p {
  font-size: 1.1rem;
  color: var(--text-secondary, #666);
  margin-bottom: 30px;
}

[data-theme="dark"] .reviews-header p {
  color: #ccc;
}

.reviews-overview {
  display: inline-block;
}

.reviews-rating {
  font-size: 5rem;
  font-weight: 900;
  color: var(--color-brand-primary, #08222b);
}

.reviews-summary {
  font-size: 1rem;
  color: var(--text-secondary, #666);
  margin: 10px 0;
}

[data-theme="dark"] .reviews-summary {
  color: #aaa;
}

.review-links {
  display: flex;
  gap: 16px;
  justify-content: center;
  margin-top: 16px;
}

.review-links a {
  color: #60a5fa;
  text-decoration: none;
  font-size: 0.95rem;
  transition: color 0.2s;
}

.review-links a:hover {
  color: #93c5fd;
  text-decoration: underline;
}

.reviews-stars-overall {
  color: #ffc107;
  font-size: 2.4rem;
  letter-spacing: 2px;
  margin: 10px 0;
}

.google-meta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 6px;
  color: var(--text-secondary, #666);
}

[data-theme="dark"] .google-meta {
  color: #ccc;
}

.google-icon {
  color: #4285f4;
  font-size: 1.1rem;
}

.refresh-button {
  background: transparent;
  border: none;
  color: var(--text-secondary, #666);
  cursor: pointer;
  font-size: 1.1rem;
  padding: 4px 8px;
  border-radius: 50%;
  transition: 0.2s ease;
}

[data-theme="dark"] .refresh-button {
  color: #ccc;
}

.refresh-button:hover {
  background: rgba(0,0,0,0.05);
  transform: rotate(90deg);
}

[data-theme="dark"] .refresh-button:hover {
  background: rgba(255,255,255,0.07);
}

/* Loader & Empty States */

.reviews-loader,
.reviews-empty {
  text-align: center;
  padding: 60px 20px;
  color: var(--text-secondary, #666);
}

[data-theme="dark"] .reviews-loader,
[data-theme="dark"] .reviews-empty {
  color: #aaa;
}

.reviews-loader .spinner {
  display: inline-block;
  width: 40px;
  height: 40px;
  border: 4px solid rgba(0,0,0,0.1);
  border-top-color: #60a5fa;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin-bottom: 16px;
}

[data-theme="dark"] .reviews-loader .spinner {
  border-color: rgba(255,255,255,0.1);
  border-top-color: #60a5fa;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.reviews-empty p {
  font-size: 1.1rem;
}

[hidden] {
  display: none !important;
}

/* Swiper */

.reviews-carousel {
  width: 100%;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 20px;
  overflow: hidden;
  position: relative;
}

.swiper {
  width: 100%;
  padding: 40px 0;
  overflow: hidden;
}

.swiper-wrapper {
  display: flex;
  align-items: stretch;
  transition-timing-function: ease-out;
}

.swiper-slide {
  display: flex;
  justify-content: center;
  height: auto;
  width: 100%;
  flex-shrink: 0;
}

.review-card {
  background: var(--card-bg, #fff);
  border-radius: 12px;
  padding: 24px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  text-align: left;
  transition: transform 0.3s, box-shadow 0.3s;
  display: flex;
  flex-direction: column;
  height: 380px;
  position: relative;
}

[data-theme="dark"] .review-card {
  background: #111b2a;
  border-color: #2a3544;
  box-shadow: 0 12px 36px rgba(0,0,0,.3);
  color: #fff;
}

.review-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 8px 24px rgba(0,0,0,.12);
}

[data-theme="dark"] .review-card:hover {
  box-shadow: 0 18px 48px rgba(0,0,0,.45);
}

.review-head {
  display: flex;
  align-items: center;
  margin-bottom: 12px;
}

.review-name {
  font-size: 1.05rem;
  font-weight: 600;
  margin: 0;
}

.review-sub {
  font-size: 0.85rem;
  color: var(--text-tertiary, #999);
  margin: 2px 0 0 0;
}

[data-theme="dark"] .review-sub {
  color: #aaa;
}

.review-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  margin-right: 12px;
}

.review-text {
  font-size: 0.95rem;
  line-height: 1.55;
  color: var(--text-primary, #1a1a1a);
  margin: 0;
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  position: relative;
  max-height: 200px;
  padding-right: 8px;
  /* Estilo de scrollbar personalizado */
  scrollbar-width: thin;
  scrollbar-color: rgba(0,0,0,0.2) transparent;
}

.review-text::-webkit-scrollbar {
  width: 6px;
}

.review-text::-webkit-scrollbar-track {
  background: transparent;
}

.review-text::-webkit-scrollbar-thumb {
  background-color: rgba(0,0,0,0.2);
  border-radius: 3px;
}

.review-text::-webkit-scrollbar-thumb:hover {
  background-color: rgba(0,0,0,0.3);
}

[data-theme="dark"] .review-text {
  color: #e5e7eb;
  scrollbar-color: rgba(255,255,255,0.2) transparent;
}

[data-theme="dark"] .review-text::-webkit-scrollbar-thumb {
  background-color: rgba(255,255,255,0.2);
}

[data-theme="dark"] .review-text::-webkit-scrollbar-thumb:hover {
  background-color: rgba(255,255,255,0.3);
}

.review-stars {
  font-size: 1.2rem;
  color: #ffc107;
  margin-bottom: 8px;
}

/* Responsive fix */

@media (max-width: 1024px) {
  .reviews-carousel {
    padding: 0 15px;
  }
}

@media (max-width: 768px) {
  .reviews-section {
    padding: 60px 15px;
  }
  
  .reviews-carousel {
    padding: 0 10px;
  }
  
  .reviews-header h2 {
    font-size: 2rem;
  }
  
  .reviews-rating {
    font-size: 4rem;
  }
  
  .review-card {
    max-width: 100%;
    padding: 20px;
  }
  
  .swiper {
    padding: 30px 0;
  }
}
