/* PMV - Policlinica de Lordelo — custom styles (complements Tailwind CDN utility classes) */

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
}

body {
  font-family: 'DM Sans', sans-serif;
  overflow-x: hidden;
}

/* Offset for the fixed header so anchor links land below it */
main, section[id] {
  scroll-margin-top: 96px;
}

/* Nav link underline effect */
.nav-link {
  position: relative;
  color: #374151; /* gray-700 */
  font-weight: 500;
  transition: color 0.2s ease;
}
.nav-link::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: -6px;
  width: 0;
  height: 2px;
  background-color: #2563eb; /* blue-600 */
  transition: width 0.2s ease;
}
.nav-link:hover {
  color: #1d4ed8; /* blue-700 */
}
.nav-link:hover::after {
  width: 100%;
}
.nav-link-active {
  color: #1d4ed8;
  font-weight: 600;
}
.nav-link-active::after {
  width: 100%;
}

.header-phone-link {
  color: #1d4ed8;
}
.header-phone-link:hover {
  color: #1e40af;
}
.header-hamburger-btn {
  color: #374151;
}
.header-hamburger-btn:hover {
  background-color: #eff6ff;
}

/* Full-viewport homepage hero */
#hero {
  min-height: 100vh;
  min-height: 100dvh;
}

/* Transparent hero header — turns solid once the visitor scrolls past the hero */
.header-hero {
  background-color: transparent;
  border-bottom: 1px solid transparent;
  transition: background-color 0.35s ease, border-color 0.35s ease, backdrop-filter 0.35s ease;
}
.header-hero .nav-link {
  color: rgba(255, 255, 255, 0.94);
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.45);
}
.header-hero .nav-link:hover {
  color: #dbeafe; /* blue-100 */
}
.header-hero .nav-link-active {
  color: #bfdbfe; /* blue-200 */
}
.header-hero .nav-link-active::after {
  background-color: #bfdbfe;
}
.header-hero .header-phone-link {
  color: #ffffff;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.45);
}
.header-hero .header-phone-link:hover {
  color: #dbeafe;
}
.header-hero .header-hamburger-btn {
  color: #ffffff;
}
.header-hero .header-hamburger-btn:hover {
  background-color: rgba(255, 255, 255, 0.14);
}
.header-hero .header-logo-link img {
  filter: drop-shadow(0 1px 4px rgba(0, 0, 0, 0.55));
  transition: filter 0.35s ease;
}

.header-hero.header-scrolled {
  background-color: rgba(255, 255, 255, 0.95);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  border-bottom-color: #dbeafe;
}
.header-hero.header-scrolled .nav-link {
  color: #374151;
  text-shadow: none;
}
.header-hero.header-scrolled .nav-link:hover {
  color: #1d4ed8;
}
.header-hero.header-scrolled .nav-link-active {
  color: #1d4ed8;
}
.header-hero.header-scrolled .nav-link-active::after {
  background-color: #2563eb;
}
.header-hero.header-scrolled .header-phone-link {
  color: #1d4ed8;
  text-shadow: none;
}
.header-hero.header-scrolled .header-phone-link:hover {
  color: #1e40af;
}
.header-hero.header-scrolled .header-hamburger-btn {
  color: #374151;
}
.header-hero.header-scrolled .header-hamburger-btn:hover {
  background-color: #eff6ff;
}
.header-hero.header-scrolled .header-logo-link img {
  filter: none;
}

/* Mobile nav */
.nav-link-mobile {
  color: #1f2937;
  font-weight: 500;
  padding: 0.85rem 0;
  border-bottom: 1px solid #dbeafe;
}
.nav-link-mobile-active {
  color: #1d4ed8;
  font-weight: 700;
}

.mobile-menu-panel {
  transition: max-height 0.3s ease, opacity 0.25s ease;
  max-height: 0;
  opacity: 0;
  overflow: hidden;
}
.mobile-menu-panel.open {
  max-height: 32rem;
  opacity: 1;
}

/* Site notice banner (cookie consent) */
#site-notice {
  box-shadow: 0 -6px 24px rgba(0, 0, 0, 0.25);
}
body.has-site-notice {
  padding-bottom: 92px;
}
@media (max-width: 640px) {
  body.has-site-notice {
    padding-bottom: 150px;
  }
}

/* Floating WhatsApp action button */
#whatsapp-fab {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  z-index: 40;
  background-color: #25D366;
  transition: bottom 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}
body.has-site-notice #whatsapp-fab {
  bottom: 92px;
}
@media (max-width: 640px) {
  body.has-site-notice #whatsapp-fab {
    bottom: 150px;
  }
}
#whatsapp-fab::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 9999px;
  background-color: #25D366;
  z-index: -1;
  pointer-events: none;
}
@media (prefers-reduced-motion: no-preference) {
  #whatsapp-fab::before {
    animation: whatsappPulse 2.6s ease-out infinite;
  }
}
@media (prefers-reduced-motion: reduce) {
  #whatsapp-fab::before {
    animation: none;
  }
}
@keyframes whatsappPulse {
  0% { transform: scale(1); opacity: 0.55; }
  100% { transform: scale(1.9); opacity: 0; }
}

/* Hero scroll indicator */
@keyframes scrollDot {
  0% { transform: translateY(0); opacity: 1; }
  70% { opacity: 0.4; }
  100% { transform: translateY(12px); opacity: 0; }
}
.scroll-dot {
  animation: scrollDot 1.8s ease-in-out infinite;
}

/* Form fields (marcacao.html) */
.form-input,
.form-select,
.form-textarea {
  width: 100%;
  border: 1px solid #e5e7eb; /* gray-200 */
  background-color: #ffffff;
  border-radius: 0.5rem;
  padding: 0.75rem 1rem;
  font-size: 0.95rem;
  color: #1f2937;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.form-input:focus,
.form-select:focus,
.form-textarea:focus {
  outline: none;
  border-color: #2563eb;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.18);
}
label.form-label {
  display: block;
  font-size: 0.875rem;
  font-weight: 600;
  color: #374151;
  margin-bottom: 0.35rem;
}

/* Decorative blurred blob shapes (no images used) */
.blob {
  position: absolute;
  border-radius: 9999px;
  filter: blur(70px);
  pointer-events: none;
  z-index: 0;
}

::selection {
  background-color: #bfdbfe;
  color: #1e3a8a;
}
