/* =========================================================
   Clínica Santa Cruz — Estilos personalizados
   (Tailwind se carga vía CDN; aquí solo lo que Tailwind no cubre)
   ========================================================= */

/* Scroll suave + respeto a accesibilidad de movimiento */
html { scroll-behavior: smooth; scroll-padding-top: 96px; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}

/* Iconos Material Symbols */
.material-symbols-outlined {
  font-variation-settings: 'FILL' 0, 'wght' 400, 'GRAD' 0, 'opsz' 24;
}

/* Sombras premium (tonal layering del design system) */
.premium-shadow { box-shadow: 0px 10px 30px rgba(30, 41, 59, 0.04); }
.premium-shadow:hover { box-shadow: 0px 20px 50px rgba(30, 41, 59, 0.08); }

/* Máscara del hero para legibilidad sobre el carrusel */
.mask-overlay {
  background: linear-gradient(to right, rgba(255, 255, 255, 1) 35%, rgba(255, 255, 255, 0.2) 100%);
}
@media (max-width: 768px) {
  .mask-overlay {
    background: linear-gradient(to bottom, rgba(255, 255, 255, 0.95) 50%, rgba(255, 255, 255, 0.4) 100%);
  }
}

/* Carrusel */
.carousel-container {
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  -ms-overflow-style: none;
}
.carousel-container::-webkit-scrollbar { display: none; }
.carousel-item { scroll-snap-align: center; }

/* Estado del header al hacer scroll (manejado por JS con la clase .is-scrolled) */
header.is-scrolled {
  background: #ffffff;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

/* Foco visible para navegación por teclado (a11y) */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
summary:focus-visible {
  outline: 3px solid #2563eb;
  outline-offset: 2px;
  border-radius: 2px;
}

/* Skip link */
.skip-link {
  position: absolute;
  left: 8px;
  top: -64px;
  z-index: 100;
  background: #2d8a56;
  color: #fff;
  padding: 10px 16px;
  border-radius: 8px;
  font-weight: 600;
  transition: top 0.2s ease;
}
.skip-link:focus { top: 8px; }

/* Botón flotante de WhatsApp con pulso */
@keyframes pulse-wa {
  0%   { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.5); }
  70%  { box-shadow: 0 0 0 16px rgba(37, 211, 102, 0); }
  100% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0); }
}
.whatsapp-float { animation: pulse-wa 2.5s infinite; }
@media (prefers-reduced-motion: reduce) { .whatsapp-float { animation: none; } }

/* Revelado progresivo al hacer scroll (solo si JS está activo) */
.js [data-reveal] {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.js [data-reveal].revealed { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .js [data-reveal] { opacity: 1; transform: none; }
}

/* FAQ nativo con <details> */
details > summary { list-style: none; cursor: pointer; }
details > summary::-webkit-details-marker { display: none; }
details[open] .faq-icon { transform: rotate(180deg); }
.faq-icon { transition: transform 0.3s ease; }
