/* ===== Custom Styles for Tommy's Complete Auto Care ===== */

/* Smooth scrolling */
html {
  scroll-behavior: smooth;
}

/* Custom scrollbar */
::-webkit-scrollbar {
  width: 8px;
}
::-webkit-scrollbar-track {
  background: #F9F0F7;
}
::-webkit-scrollbar-thumb {
  background: #5C3D5E;
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: #6B4A6E;
}

/* Selection */
::selection {
  background: #D4A84B;
  color: #2D1F30;
}

/* Navbar scroll state */
#navbar.scrolled {
  background: rgba(45, 31, 48, 0.95);
  backdrop-filter: blur(12px);
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.2);
}

/* Nav links */
.nav-link {
  position: relative;
}
.nav-link::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: #D4A84B;
  transition: width 0.3s ease;
}
.nav-link:hover::after {
  width: 100%;
}

/* Mobile links */
.mobile-link {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.3s ease, transform 0.3s ease;
}
#mobile-menu.open .mobile-link {
  opacity: 1;
  transform: translateY(0);
}
#mobile-menu.open .mobile-link:nth-child(1) { transition-delay: 0.05s; }
#mobile-menu.open .mobile-link:nth-child(2) { transition-delay: 0.1s; }
#mobile-menu.open .mobile-link:nth-child(3) { transition-delay: 0.15s; }
#mobile-menu.open .mobile-link:nth-child(4) { transition-delay: 0.2s; }
#mobile-menu.open .mobile-link:nth-child(5) { transition-delay: 0.25s; }
#mobile-menu.open .mobile-link:nth-child(6) { transition-delay: 0.3s; }

/* Service cards */
.service-card {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.service-card.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Testimonial cards */
#testimonials .bg-plum-50 {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
#testimonials .bg-plum-50.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Section fade-in */
section > .max-w-7xl > div:first-child > span,
section > .max-w-7xl > div:first-child > h2,
section > .max-w-7xl > div:first-child > p {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
section.visible > .max-w-7xl > div:first-child > span,
section.visible > .max-w-7xl > div:first-child > h2,
section.visible > .max-w-7xl > div:first-child > p {
  opacity: 1;
  transform: translateY(0);
}

/* Hero text animation */
.hero-title {
  opacity: 0;
  transform: translateY(40px);
  animation: heroReveal 1s ease forwards 0.3s;
}
.hero-subtitle {
  opacity: 0;
  transform: translateY(30px);
  animation: heroReveal 1s ease forwards 0.6s;
}
.hero-cta {
  opacity: 0;
  transform: translateY(20px);
  animation: heroReveal 1s ease forwards 0.9s;
}
.hero-badge {
  opacity: 0;
  animation: fadeIn 0.8s ease forwards 0.1s;
}

@keyframes heroReveal {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
@keyframes fadeIn {
  to { opacity: 1; }
}

/* Floating animation for decorative elements */
@keyframes float {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-10px) rotate(2deg); }
}
.absolute.top-40.right-20 {
  animation: float 6s ease-in-out infinite;
}
.absolute.bottom-48.left-20 {
  animation: float 8s ease-in-out infinite reverse;
}

/* Form focus styles */
input:focus,
select:focus,
textarea:focus {
  box-shadow: 0 0 0 3px rgba(212, 168, 75, 0.15);
}

/* Print styles */
@media print {
  #navbar, #mobile-menu, .absolute.top-32, .absolute.bottom-32,
  .absolute.top-40, .absolute.bottom-48, .scroll-indicator {
    display: none !important;
  }
  body {
    background: white !important;
    color: black !important;
  }
}
