/* ===== Base & Typography ===== */
html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

::selection {
  background: rgba(94, 234, 212, 0.3);
  color: #f0fdfa;
}

/* ===== Scroll Reveal ===== */
.reveal {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal[data-revealed="false"] {
  opacity: 0;
  transform: translateY(32px);
}

/* ===== Navbar ===== */
#navbar {
  background: transparent;
}

#navbar.scrolled {
  background: rgba(3, 8, 16, 0.92);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.nav-link {
  position: relative;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 1px;
  background: #5eead4;
  transition: width 0.3s ease;
}

.nav-link:hover::after {
  width: 100%;
}

.nav-link:hover {
  color: #5eead4 !important;
}

/* ===== Mobile Menu ===== */
#mobileMenu.open {
  opacity: 1;
  pointer-events: all;
}

#mobileMenu .mobile-link {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.3s ease, transform 0.3s ease, color 0.3s ease;
}

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

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

/* ===== Hamburger Animation ===== */
#menuBtn.active #bar1 {
  transform: translateY(4px) rotate(45deg);
}

#menuBtn.active #bar2 {
  opacity: 0;
  transform: scaleX(0);
}

#menuBtn.active #bar3 {
  transform: translateY(-4px) rotate(-45deg);
  width: 100%;
}

/* ===== Service Cards ===== */
.service-card {
  perspective: 1000px;
}

.service-card .service-card-inner {
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

/* ===== Buttons ===== */
a, button {
  -webkit-tap-highlight-color: transparent;
}

/* ===== Custom Scrollbar ===== */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: #030810;
}

::-webkit-scrollbar-thumb {
  background: rgba(94, 234, 212, 0.2);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: rgba(94, 234, 212, 0.4);
}

/* ===== Form Styles ===== */
select option {
  background: #0a1628;
  color: #fff;
}

/* ===== Reduced Motion ===== */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .reveal {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }

  .service-card img {
    transition: none !important;
  }
}

/* ===== Responsive ===== */
@media (max-width: 767px) {
  .font-serif {
    line-height: 1.05;
  }
}
