/* Base & Utilities */
html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
}

body {
  overflow-x: hidden;
}

::selection {
  background-color: #86efac;
  color: #0D1B2A;
}

/* Scrollbar */
::-webkit-scrollbar {
  width: 8px;
}
::-webkit-scrollbar-track {
  background: #fefdf8;
}
::-webkit-scrollbar-thumb {
  background: #d0d9e8;
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: #a3b5cc;
}

/* Scroll indicator animation */
@keyframes scrollIndicator {
  0% { top: -16px; opacity: 0; }
  20% { opacity: 1; }
  80% { opacity: 1; }
  100% { top: 48px; opacity: 0; }
}

.animate-scroll-indicator {
  animation: scrollIndicator 1.5s ease-in-out infinite;
}

/* Navigation */
.nav-link {
  position: relative;
}

/* Service cards */
.service-card {
  position: relative;
  overflow: hidden;
}

.service-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, #86efac, #4ade80);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.service-card:hover::before {
  transform: scaleX(1);
}

/* Fade-in animations */
.fade-in {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1), transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

.fade-in-delay-1 { transition-delay: 0.1s; }
.fade-in-delay-2 { transition-delay: 0.2s; }
.fade-in-delay-3 { transition-delay: 0.3s; }
.fade-in-delay-4 { transition-delay: 0.4s; }

/* Hero image hover */
#hero .rounded-2xl img {
  transition: transform 0.7s cubic-bezier(0.4, 0, 0.2, 1);
}

#hero .rounded-2xl:hover img {
  transform: scale(1.03);
}

/* Floating card animation */
@keyframes float {
  0%, 100% { transform: translate(-50%, -50%) translateY(0); }
  50% { transform: translate(-50%, -50%) translateY(-8px); }
}

/* Mobile menu */
.mobile-link {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.4s ease, transform 0.4s ease, color 0.3s ease;
}

#mobile-menu.open .mobile-link {
  opacity: 1;
  transform: translateY(0);
}

#mobile-menu.open .mobile-link:nth-child(1) { transition-delay: 0.1s; }
#mobile-menu.open .mobile-link:nth-child(2) { transition-delay: 0.15s; }
#mobile-menu.open .mobile-link:nth-child(3) { transition-delay: 0.2s; }
#mobile-menu.open .mobile-link:nth-child(4) { transition-delay: 0.25s; }
#mobile-menu.open .mobile-link:nth-child(5) { transition-delay: 0.3s; }

/* Testimonial cards hover */
#testimonials .bg-white {
  transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

#testimonials .bg-white:hover {
  transform: translateY(-4px);
}

/* Form inputs */
input:focus, select:focus, textarea:focus {
  border-color: #86efac !important;
  box-shadow: 0 0 0 3px rgba(134, 239, 172, 0.2) !important;
}

/* Smooth transitions for all interactive elements */
a, button {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Navbar scrolled state */
#navbar.scrolled {
  background-color: rgba(254, 253, 248, 0.92);
  backdrop-filter: blur(20px);
  box-shadow: 0 1px 0 rgba(13, 27, 42, 0.06), 0 4px 20px rgba(13, 27, 42, 0.04);
}

/* Image gallery hover */
.rounded-2xl.overflow-hidden {
  overflow: hidden;
}

.rounded-2xl.overflow-hidden img {
  transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.rounded-2xl.overflow-hidden:hover img {
  transform: scale(1.05);
}

/* Responsive adjustments */
@media (max-width: 768px) {
  html {
    scroll-padding-top: 70px;
  }
}
