/* ===========================
   HAPPY WAY MEDICAL CENTER
   Custom Styles
   =========================== */

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

/* ===========================
   Fade-in Animation
   =========================== */
.fade-in {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.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; }
.fade-in-delay-5 { transition-delay: 0.5s; }

/* ===========================
   Lightbox Styles
   =========================== */
#lightbox-overlay {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(0, 0, 0, 0.92);
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

#lightbox-overlay.active {
  display: flex;
}

#lightbox-img {
  max-width: 90vw;
  max-height: 88vh;
  object-fit: contain;
  border-radius: 0.5rem;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.7);
  animation: lightbox-zoom 0.25s ease-out;
}

@keyframes lightbox-zoom {
  from {
    opacity: 0;
    transform: scale(0.92);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

#lightbox-close {
  position: fixed;
  top: 1.25rem;
  right: 1.5rem;
  background: rgba(255, 255, 255, 0.15);
  border: none;
  color: #fff;
  font-size: 1.75rem;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s;
  z-index: 10000;
}

#lightbox-close:hover {
  background: rgba(255, 255, 255, 0.3);
}

/* ===========================
   Floating Google Maps Button (Mobile)
   =========================== */
.floating-maps-btn {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  z-index: 1000;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: #0369a1;
  color: #fff;
  padding: 0.75rem 1.25rem;
  border-radius: 9999px;
  font-size: 0.875rem;
  font-weight: 600;
  text-decoration: none;
  box-shadow: 0 4px 20px rgba(3, 105, 161, 0.45);
  transition: background 0.2s, transform 0.2s, box-shadow 0.2s;
}

.floating-maps-btn:hover {
  background: #0284c7;
  transform: translateY(-2px);
  box-shadow: 0 6px 24px rgba(3, 105, 161, 0.55);
}

/* Hide floating button on larger screens */
@media (min-width: 768px) {
  .floating-maps-btn {
    display: none;
  }
}

/* ===========================
   Navigation
   =========================== */
.nav-link {
  position: relative;
  font-weight: 500;
  color: #374151;
  text-decoration: none;
  transition: color 0.2s;
}

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

.nav-link:hover {
  color: #0369a1;
}

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

.nav-link.active {
  color: #0369a1;
  font-weight: 600;
}

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

/* Mobile menu */
#mobile-menu {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s ease;
}

#mobile-menu.open {
  max-height: 400px;
}

/* ===========================
   Hero
   =========================== */
.hero-overlay {
  background: linear-gradient(
    135deg,
    rgba(3, 105, 161, 0.78) 0%,
    rgba(7, 89, 133, 0.65) 50%,
    rgba(0, 0, 0, 0.45) 100%
  );
}

/* ===========================
   Star Ratings
   =========================== */
.star-filled {
  color: #f59e0b;
  fill: #f59e0b;
}

.star-half {
  color: #f59e0b;
  fill: url(#half-fill);
}

.star-empty {
  color: #d1d5db;
  fill: #d1d5db;
}

/* ===========================
   Cards
   =========================== */
.service-card {
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.service-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(3, 105, 161, 0.15);
}

.review-card {
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.review-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
}

/* Gallery image hover */
.gallery-item {
  overflow: hidden;
  cursor: pointer;
  border-radius: 0.75rem;
  transition: box-shadow 0.25s ease;
}

.gallery-item img {
  transition: transform 0.35s ease;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.gallery-item:hover img {
  transform: scale(1.06);
}

.gallery-item:hover {
  box-shadow: 0 10px 30px rgba(3, 105, 161, 0.25);
}

/* ===========================
   Utility
   =========================== */
.section-badge {
  display: inline-block;
  background: #e0f2fe;
  color: #0369a1;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.3rem 0.9rem;
  border-radius: 9999px;
  margin-bottom: 0.75rem;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: #0369a1;
  color: #fff;
  padding: 0.75rem 1.75rem;
  border-radius: 9999px;
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  transition: background 0.2s, transform 0.2s, box-shadow 0.2s;
  box-shadow: 0 4px 14px rgba(3, 105, 161, 0.35);
}

.btn-primary:hover {
  background: #0284c7;
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(3, 105, 161, 0.45);
}

.btn-outline {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: transparent;
  color: #0369a1;
  border: 2px solid #0369a1;
  padding: 0.7rem 1.6rem;
  border-radius: 9999px;
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  transition: all 0.2s;
}

.btn-outline:hover {
  background: #0369a1;
  color: #fff;
}

.btn-white {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: #fff;
  color: #0369a1;
  padding: 0.75rem 1.75rem;
  border-radius: 9999px;
  font-weight: 700;
  font-size: 0.95rem;
  text-decoration: none;
  transition: background 0.2s, transform 0.2s;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.15);
}

.btn-white:hover {
  background: #f0f9ff;
  transform: translateY(-1px);
}

/* Doctor card */
.doctor-card {
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.doctor-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(3, 105, 161, 0.15);
}

/* ===========================
   Footer
   =========================== */
footer a:hover {
  color: #7dd3fc;
}

/* ===========================
   Responsive helpers
   =========================== */
@media (max-width: 640px) {
  .hero-title {
    font-size: 2rem;
  }
}
