/* ============================================
   PREMIUM ENHANCEMENTS
   ============================================ */

/* Scroll Progress Bar */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  width: 0%;
  height: 3px;
  background: var(--gradient-gold);
  z-index: 9999;
  transition: width 0.1s linear;
}

/* Back to Top */
.back-to-top {
  position: fixed;
  bottom: 32px;
  right: 32px;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  color: var(--accent-gold);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 900;
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: var(--shadow-md);
}

.back-to-top.visible {
  opacity: 1;
  transform: translateY(0);
}

.back-to-top:hover {
  background: var(--accent-gold);
  color: #0a0a0f;
  border-color: var(--accent-gold);
  transform: translateY(-4px);
  box-shadow: var(--shadow-gold);
}

/* Cursor Glow */
.cursor-glow {
  position: fixed;
  width: 300px;
  height: 300px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(144, 172, 50, 0.04) 0%, transparent 70%);
  pointer-events: none;
  z-index: 0;
  transform: translate(-50%, -50%);
  transition: opacity 0.3s;
}

[data-theme="light"] .cursor-glow {
  background: radial-gradient(circle, rgba(156, 124, 42, 0.03) 0%, transparent 70%);
}

/* 3D Card Tilt */
.car-card {
  transform-style: preserve-3d;
  perspective: 1000px;
}

.car-card .car-card-body {
  transform: translateZ(20px);
}

.car-card:hover {
  transform: translateY(-8px);
}

/* Gradient Mesh Hero Background */
.hero-mesh {
  position: absolute;
  inset: 0;
  overflow: hidden;
  z-index: 0;
}

.mesh-blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.4;
  animation: meshFloat 20s ease-in-out infinite;
}

.mesh-blob-1 {
  width: 500px;
  height: 500px;
  background: rgba(144, 172, 50, 0.08);
  top: -10%;
  right: -5%;
  animation-delay: 0s;
}

.mesh-blob-2 {
  width: 400px;
  height: 400px;
  background: rgba(144, 172, 50, 0.05);
  bottom: -10%;
  left: -5%;
  animation-delay: -7s;
}

.mesh-blob-3 {
  width: 300px;
  height: 300px;
  background: rgba(144, 172, 50, 0.06);
  top: 40%;
  left: 30%;
  animation-delay: -14s;
}

@keyframes meshFloat {
  0%, 100% { transform: translate(0, 0) scale(1); }
  25% { transform: translate(30px, -20px) scale(1.05); }
  50% { transform: translate(-20px, 30px) scale(0.95); }
  75% { transform: translate(20px, 20px) scale(1.02); }
}

[data-theme="light"] .mesh-blob-1 { background: rgba(156, 124, 42, 0.06); }
[data-theme="light"] .mesh-blob-2 { background: rgba(156, 124, 42, 0.04); }
[data-theme="light"] .mesh-blob-3 { background: rgba(156, 124, 42, 0.05); }

/* Testimonials */
.testimonials {
  background: var(--bg-secondary);
  overflow: hidden;
}

.testimonials-wrapper {
  position: relative;
}

.testimonials-track {
  display: flex;
  gap: 24px;
  transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.testimonial-card {
  min-width: calc(33.333% - 16px);
  padding: 32px;
  border-radius: var(--radius-lg);
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  flex-shrink: 0;
}

.testimonial-stars {
  display: flex;
  gap: 2px;
  margin-bottom: 16px;
}

.testimonial-stars svg {
  width: 16px;
  height: 16px;
  fill: var(--accent-gold);
  stroke: none;
}

.testimonial-text {
  font-size: 0.9375rem;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 20px;
  font-style: italic;
}

.testimonial-author {
  display: flex;
  align-items: center;
  gap: 12px;
}

.testimonial-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--gradient-gold);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.875rem;
  color: #0a0a0f;
}

.testimonial-name {
  font-weight: 600;
  font-size: 0.875rem;
}

.testimonial-role {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.testimonials-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: 32px;
}

.testimonials-nav button {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
}

.testimonials-nav button:hover {
  border-color: var(--accent-gold);
  color: var(--accent-gold);
}

.testimonials-dots {
  display: flex;
  gap: 8px;
}

.testimonials-dots .dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--border-hover);
  transition: all 0.3s;
  cursor: pointer;
}

.testimonials-dots .dot.active {
  background: var(--accent-gold);
  width: 24px;
  border-radius: 4px;
}

/* FAQ Accordion */
.faq-list {
  max-width: 800px;
  margin: 0 auto;
}

.faq-item {
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  margin-bottom: 12px;
  overflow: hidden;
  transition: border-color 0.3s;
}

.faq-item:hover,
.faq-item.active {
  border-color: rgba(144, 172, 50, 0.3);
}

.faq-question {
  width: 100%;
  padding: 20px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--bg-card);
  border: none;
  color: var(--text-primary);
  font-size: 1rem;
  font-weight: 600;
  font-family: var(--font-sans);
  cursor: pointer;
  text-align: left;
  transition: background 0.2s;
}

.faq-question:hover {
  background: var(--bg-card-hover);
}

.faq-icon {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: rgba(144, 172, 50, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.3s, background 0.3s;
  flex-shrink: 0;
  margin-left: 16px;
}

.faq-icon svg {
  width: 12px;
  height: 12px;
  stroke: var(--accent-gold);
  transition: transform 0.3s;
}

.faq-item.active .faq-icon {
  background: var(--accent-gold);
}

.faq-item.active .faq-icon svg {
  stroke: #0a0a0f;
  transform: rotate(180deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s cubic-bezier(0.16, 1, 0.3, 1), padding 0.3s;
}

.faq-answer-inner {
  padding: 0 24px 20px;
  font-size: 0.9375rem;
  color: var(--text-secondary);
  line-height: 1.7;
}

.faq-item.active .faq-answer {
  max-height: 300px;
}

/* Mobile Menu Overlay */
.mobile-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
  z-index: 998;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s;
}

.mobile-overlay.active {
  opacity: 1;
  visibility: visible;
}

/* Improved mobile nav */
@media (max-width: 768px) {
  .nav-links.active {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    width: 280px;
    background: var(--bg-secondary);
    flex-direction: column;
    padding: 80px 24px 24px;
    gap: 8px;
    z-index: 999;
    transform: translateX(0);
    animation: slideInMenu 0.3s ease forwards;
    border-left: 1px solid var(--border-color);
  }
  
  .nav-links {
    transform: translateX(100%);
  }
  
  .nav-links .nav-link {
    font-size: 1.125rem;
    padding: 12px 16px;
    border-radius: var(--radius-sm);
  }
  
  .nav-links .nav-link:hover,
  .nav-links .nav-link.active {
    background: rgba(144, 172, 50, 0.08);
  }
  
  .testimonial-card {
    min-width: calc(100% - 0px);
  }
}

@keyframes slideInMenu {
  from { transform: translateX(100%); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}

/* Nav toggle animation */
.nav-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.nav-toggle.active span:nth-child(2) {
  opacity: 0;
  transform: translateX(-10px);
}

.nav-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

/* Smooth image loading */
.car-card-image img {
  opacity: 0;
  transition: opacity 0.5s ease, transform 0.6s ease;
}

.car-card-image img.loaded {
  opacity: 1;
}

/* Button press effect */
.btn:active {
  transform: scale(0.97) !important;
}

/* Input focus glow */
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  box-shadow: 0 0 0 3px rgba(144, 172, 50, 0.1);
}

/* Glassmorphism cards on hover */
.step-card:hover,
.advantage-card:hover,
.service-card:hover {
  background: var(--gradient-card);
  box-shadow: var(--shadow-md);
}

/* Smooth link transitions */
.footer-links a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.footer-links a::before {
  content: '';
  width: 0;
  height: 1px;
  background: var(--accent-gold);
  transition: width 0.3s;
}

.footer-links a:hover::before {
  width: 12px;
}

/* Stats counter animation pulse */
.stat-number {
  position: relative;
}

/* Car card MSRP strikethrough */
.car-card-msrp {
  font-size: 0.75rem;
  color: var(--text-muted);
  text-decoration: line-through;
  margin-left: 8px;
}

/* Responsive testimonials */
@media (max-width: 1024px) {
  .testimonial-card {
    min-width: calc(50% - 12px);
  }
}

@media (max-width: 768px) {
  .testimonial-card {
    min-width: 100%;
  }
  
  .back-to-top {
    bottom: 20px;
    right: 20px;
    width: 42px;
    height: 42px;
  }
}
