/* ============================================
   DULUTH FAMILY PRACTICE — Custom Styles
   ============================================ */

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

body {
  overflow-x: hidden;
}

::selection {
  background: #ccfbf1;
  color: #134e4a;
}

/* Scrollbar */
::-webkit-scrollbar {
  width: 6px;
}
::-webkit-scrollbar-track {
  background: #f8fafc;
}
::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

/* ============================================
   NAVIGATION
   ============================================ */
#navbar {
  backdrop-filter: blur(0px);
  -webkit-backdrop-filter: blur(0px);
}

#navbar.scrolled {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.06);
}

.nav-link {
  position: relative;
}

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

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

/* Mobile menu */
.mobile-link {
  position: relative;
}

/* ============================================
   HERO
   ============================================ */
.hero-content {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.hero-image-wrapper {
  opacity: 1;
  transform: translateX(0);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.hero-stat {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.hero-stat:nth-child(1) { transition-delay: 0.1s; }
.hero-stat:nth-child(2) { transition-delay: 0.2s; }
.hero-stat:nth-child(3) { transition-delay: 0.3s; }

/* ============================================
   SCROLL REVEAL — Progressive Enhancement
   Content is visible by default; JS adds animation
   ============================================ */
.reveal {
  /* Default: visible (no JS) */
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

/* With JS: hidden initially, animated on scroll */
@media (prefers-reduced-motion: no-preference) {
  .reveal {
    opacity: 0;
    transform: translateY(24px);
  }

  .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; }
}

/* ============================================
   SERVICE CARDS
   ============================================ */
.service-card {
  padding: 2rem;
  border-radius: 1rem;
  border: 1px solid #f1f5f9;
  background: white;
  transition: border-color 0.3s ease, box-shadow 0.3s ease, transform 0.3s ease;
}

.service-card:hover {
  border-color: #99f6e4;
  box-shadow: 0 8px 32px rgba(13, 148, 136, 0.08);
  transform: translateY(-2px);
}

/* ============================================
   INSURANCE CARDS
   ============================================ */
.insurance-card {
  transition: border-color 0.3s ease, background 0.3s ease, transform 0.3s ease;
}

.insurance-card:hover {
  transform: translateY(-2px);
}

/* ============================================
   ABOUT IMAGE
   ============================================ */
.about-image {
  opacity: 1;
  transform: translateX(0);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

/* ============================================
   MOBILE MENU
   ============================================ */
#mobile-menu.open {
  opacity: 1;
  pointer-events: all;
}

#mobile-menu.closed {
  opacity: 0;
  pointer-events: none;
}

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

#mobile-menu-btn.active .menu-line:nth-child(1) {
  transform: translateY(4px) rotate(45deg);
}

#mobile-menu-btn.active .menu-line:nth-child(2) {
  opacity: 0;
}

#mobile-menu-btn.active .menu-line:nth-child(3) {
  transform: translateY(-4px) rotate(-45deg);
  width: 1.5rem;
}

/* ============================================
   FORM
   ============================================ */
input:focus,
textarea:focus {
  outline: none;
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 768px) {
  .hero-image-wrapper {
    margin-top: 2rem;
  }

  .hero-image-accent {
    width: 20px !important;
    height: 20px !important;
    bottom: -2px !important;
    left: -2px !important;
  }

  .hero-image-dot {
    width: 12px !important;
    height: 12px !important;
    top: -2px !important;
    right: -2px !important;
  }
}

@media (max-width: 640px) {
  #navbar .max-w-7xl {
    padding-left: 1rem;
    padding-right: 1rem;
  }
}
