/* ─── Base & Reset ─── */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  overflow-x: hidden;
}

::selection {
  background: #0d9488;
  color: white;
}

/* ─── Scrollbar ─── */
::-webkit-scrollbar {
  width: 8px;
}
::-webkit-scrollbar-track {
  background: #f1f5f9;
}
::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

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

/* ─── Mobile Menu ─── */
.mobile-nav-link {
  position: relative;
}
.mobile-nav-link::after {
  content: '';
  display: block;
  width: 0;
  height: 1px;
  background: #0d9488;
  transition: width 0.3s ease;
  margin: 0 auto;
}
.mobile-nav-link:hover::after {
  width: 60%;
}

/* ─── Service Cards ─── */
.service-card {
  position: relative;
}
.service-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 3px;
  height: 0;
  background: #0d9488;
  transition: height 0.4s ease;
  border-radius: 0 0 2px 2px;
}
.service-card:hover::before {
  height: 100%;
}

/* ─── Work Cards ─── */
.work-card {
  box-shadow: 0 4px 24px rgba(0,0,0,0.08);
}
.work-card:hover {
  box-shadow: 0 12px 40px rgba(0,0,0,0.15);
}

/* ─── Testimonial Cards ─── */
.testimonial-card {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.testimonial-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 40px rgba(0,0,0,0.2);
}

/* ─── Scroll Reveal Animations ─── */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}
.reveal.revealed {
  opacity: 1;
  transform: translateY(0);
}

.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }
.reveal-delay-4 { transition-delay: 0.4s; }
.reveal-delay-5 { transition-delay: 0.5s; }
.reveal-delay-6 { transition-delay: 0.6s; }

/* ─── Reduced Motion ─── */
@media (prefers-reduced-motion: reduce) {
  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
  html {
    scroll-behavior: auto;
  }
  .work-card img {
    transition: none;
  }
  .work-card:hover img {
    transform: none;
  }
}

/* ─── Mobile Menu Animation ─── */
#mobile-menu.open {
  translate: 0 0;
}

.menu-line {
  transition: transform 0.3s ease, opacity 0.3s ease;
}

#menu-btn.active .menu-line:nth-child(1) {
  transform: translateY(6px) rotate(45deg);
}
#menu-btn.active .menu-line:nth-child(2) {
  opacity: 0;
}
#menu-btn.active .menu-line:nth-child(3) {
  transform: translateY(-6px) rotate(-45deg);
}

/* ─── Form Select Arrow ─── */
select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2394a3b8' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  appearance: none;
  -webkit-appearance: none;
}

/* ─── Navbar Scrolled State ─── */
#nav.scrolled {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(12px);
  box-shadow: 0 1px 0 rgba(0,0,0,0.06);
}
#nav[data-bg="transparent"] .nav-link {
  color: #475569;
}
#nav.scrolled .nav-link {
  color: #475569;
}
