/*
 * css/styles.css
 * HealthLink Hub (Proyecto Nexus)
 * Versión Consolidada 10.49 - Shine Intenso
 * Descripción: Hoja de estilos principal, organizada y limpia.
 */

/* ---------------------------------- */
/*           ESTILOS BASE             */
/* ---------------------------------- */
body {
  font-family: 'Inter', sans-serif;
  background-color: #F2F3F4;
  color: #374151;
}
.font-body { font-family: 'Lato', sans-serif; }
.hero-gradient { background: linear-gradient(to right, #2563EB, #60A5FA); }
.nexus-gradient { background: linear-gradient(120deg, #2563EB 0%, #10B981 100%); }
.form-page-bg {
  background: linear-gradient(135deg, #e0f2fe, #f0f9ff, #eef2ff);
  background-size: 400% 400%;
  animation: gradient-animation 15s ease infinite;
}
@keyframes gradient-animation {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

/* ---------------------------------- */
/*        HEADER Y NAVEGACIÓN         */
/* ---------------------------------- */
header.header-scrolled { 
  background-color: rgba(255, 255, 255, 0.85); 
  backdrop-filter: blur(10px); 
  -webkit-backdrop-filter: blur(10px); 
  box-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1); 
}
.nav-link { 
  position: relative; 
  padding: 0.5rem 0; 
  transition: color 0.2s ease; 
}
.nav-link::after { 
  content: ''; 
  position: absolute; 
  bottom: 0; 
  left: 0; 
  width: 0; 
  height: 2px; 
  background-color: #2563EB; 
  transition: width 0.3s ease; 
}
.nav-link:hover::after, .nav-link.active::after { 
  width: 100%; 
}
.nav-link.active { 
  color: #2563EB; 
  font-weight: 700; 
}
.nav-link-mobile i {
  color: #2563EB;
  transition: color 0.2s ease;
}
.nav-link-mobile.active i {
  color: #10B981;
}
.nav-link-mobile.active span {
  color: #10B981;
  font-weight: 600;
}
.language-switcher .lang-button { 
  display: inline-flex; 
  align-items: center; 
  gap: 0.5rem; 
  padding: 0.5rem 0.75rem; 
  border-radius: 0.5rem; 
  transition: background-color 0.2s ease, color 0.2s ease; 
  font-weight: 500; 
  border: 1px solid transparent; 
  text-decoration: none;
}
.language-switcher .lang-button:hover { 
  background-color: #eef2ff; 
}
.language-switcher .lang-button.active { 
  background-color: #2563EB; 
  color: white; 
  border-color: #2563EB; 
}
.flag-icon { 
  display: inline-block;
  width: 1.5em; 
  height: 1.5em; 
  border-radius: 50%; 
  background-size: cover; 
  background-position: center; 
  box-shadow: 0 0 3px rgba(0,0,0,0.4);
}
.flag-es { background-image: url('https://flagcdn.com/w40/es.png'); }
.flag-en { background-image: url('https://flagcdn.com/w40/gb.png'); }
.flag-fr { background-image: url('https://flagcdn.com/w40/fr.png'); }
.flag-de { background-image: url('https://flagcdn.com/w40/de.png'); }
.flag-nl { background-image: url('https://flagcdn.com/w40/nl.png'); }

@keyframes pulse-heart-smooth {
  0% { transform: scale(1); color: #2563EB; }
  10% { transform: scale(1.15); color: #EF4444; }
  20% { transform: scale(1); color: #2563EB; }
  30% { transform: scale(1.1); color: #EF4444; }
  40% { transform: scale(1); color: #2563EB; }
  100% { transform: scale(1); color: #2563EB; }
}
.pulsing-heart {
  animation: pulse-heart-smooth 4s infinite ease-in-out;
}

/* ---------------------------------- */
/*           FORMULARIOS              */
/* ---------------------------------- */
.form-input, textarea.form-input, select.form-input { 
  width: 100%; 
  padding: 0.75rem 1rem; 
  border: 1px solid #e5e7eb; 
  border-radius: 0.5rem; 
  background-color: #f9fafb; 
  color: #1f2937; 
  font-family: 'Lato', sans-serif; 
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease; 
  -webkit-appearance: none; 
  -moz-appearance: none; 
  appearance: none; 
}
.form-input:focus, textarea.form-input:focus, select.form-input:focus { 
  outline: none; 
  border-color: #2563EB; 
  background-color: #fff; 
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.2), 0 1px 2px 0 rgba(0, 0, 0, 0.05) inset;
}
select.form-input { 
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%232563eb' stroke-width='2.5' 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 1rem center; 
  background-size: 1em; 
  padding-right: 2.5rem; 
}
.is-invalid .form-input { 
  border-color: #ef4444 !important; 
  background-color: #fee2e2; 
}
.is-invalid .form-input:focus { 
  box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.2) !important; 
}
.is-valid .form-input { 
  border-color: #10B981 !important; 
  background-color: #d1fae5; 
}
.is-valid .form-input:focus { 
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.2) !important; 
}
.validation-icon { 
  position: absolute; 
  top: 50%; 
  right: 1rem; 
  transform: translateY(-50%); 
  opacity: 0; 
  transition: opacity 0.3s ease; 
  pointer-events: none; 
}
select ~ .validation-icon { 
  right: 2.5rem; 
}
.is-valid .validation-icon::before { 
  content: '\f00c'; 
  font-family: 'Font Awesome 6 Free'; 
  font-weight: 900; 
  color: #10B981; 
}
.is-invalid .validation-icon::before { 
  content: '\f00d'; 
  font-family: 'Font Awesome 6 Free'; 
  font-weight: 900; 
  color: #ef4444; 
}
.is-valid .validation-icon, .is-invalid .validation-icon { 
  opacity: 1; 
}
.error-message { 
  color: #ef4444; 
  font-size: 0.875rem; 
  margin-top: 0.25rem; 
  min-height: 1.25rem; 
  transition: opacity 0.3s ease; 
}
.btn-submit { 
  width: 100%; 
  background-color: #10B981; 
  color: white; 
  padding: 0.875rem 1rem; 
  border-radius: 0.5rem; 
  font-weight: 700; 
  text-transform: uppercase; 
  letter-spacing: 0.05em; 
  display: flex; 
  justify-content: center; 
  align-items: center; 
  min-height: 52px; 
  box-shadow: 0 4px 6px -1px rgba(16, 185, 129, 0.2), 0 2px 4px -2px rgba(16, 185, 129, 0.1); 
  transition: all 0.3s ease;
}
.btn-submit:hover { 
  background-color: #059669; 
  box-shadow: 0 10px 15px -3px rgba(16, 185, 129, 0.2), 0 4px 6px -4px rgba(16, 185, 129, 0.1); 
  transform: translateY(-2px); 
}
.btn-submit .spinner-light { 
  border: 3px solid rgba(255, 255, 255, 0.3); 
  width: 24px; 
  height: 24px; 
  border-radius: 50%; 
  border-left-color: #fff; 
  animation: spin 1s ease infinite; 
}
#busqueda-form {
  background: linear-gradient(120deg, #2563EB 0%, #10B981 100%);
  padding: 1.5rem;
  position: relative;
  overflow: hidden;
}
#busqueda-form::before {
  content: '';
  position: absolute;
  top: 0;
  left: -150%;
  width: 100%;
  height: 100%;
  background: linear-gradient(to right, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.5) 50%, rgba(255, 255, 255, 0) 100%);
  transform: skewX(-25deg);
  animation: shine-effect 7s infinite;
}
#busqueda-form .form-input { 
  background-color: rgba(255, 255, 255, 0.9); 
}
#busqueda-form .form-input::placeholder { 
  color: #6b7280; 
}

/* ---------------------------------- */
/*      DISEÑO WOW FORMULARIOS        */
/* ---------------------------------- */
.textured-bg {
  background-color: #f0f9ff;
  background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23dbeafe' fill-opacity='0.4'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}
.page-container-wow {
  background: transparent;
  border-radius: 1.5rem;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  overflow: hidden;
  display: grid;
}
.wow-panel-left {
  padding: 3rem;
  background: linear-gradient(135deg, #2563EB 0%, #3B82F6 100%);
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.wow-panel-right {
  padding: 3rem;
  background: white;
}
.wow-icon-wrapper {
  flex-shrink: 0;
  width: 2.5rem;
  height: 2.5rem;
  background-color: rgba(255, 255, 255, 0.15);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 1rem;
  color: #fff;
}
@media (max-width: 1023px) {
  .wow-panel-left, .wow-panel-right {
    padding: 2rem;
  }
}

/* ---------------------------------- */
/*              MODAL                 */
/* ---------------------------------- */
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes fadeOut { from { opacity: 1; } to { opacity: 0; } }
@keyframes scaleIn { from { transform: scale(0.95); } to { transform: scale(1); } }
@keyframes scaleOut { from { transform: scale(1); } to { transform: scale(0.95); } }
#detailsModal, #feedbackModal, #modal-especialidades { 
  animation-duration: 0.3s; 
  animation-timing-function: ease-out; 
  z-index: 1100;
}
#detailsModal.is-opening, #feedbackModal.is-opening, #modal-especialidades.is-opening { 
  animation-name: fadeIn; 
}
#detailsModal.is-closing, #feedbackModal.is-closing, #modal-especialidades.is-closing { 
  animation-name: fadeOut; 
}
#detailsModal .modal-content, #feedbackModal .modal-content, #modal-especialidades .specialties-modal-content { 
  animation-duration: 0.3s; 
  animation-timing-function: ease-out; 
}
#detailsModal.is-opening .modal-content, #feedbackModal.is-opening .modal-content, #modal-especialidades.is-opening .specialties-modal-content { 
  animation-name: scaleIn; 
}
#detailsModal.is-closing .modal-content, #feedbackModal.is-closing .modal-content, #modal-especialidades.is-closing .specialties-modal-content { 
  animation-name: scaleOut; 
}
#modalContent {
  padding-bottom: 80px;
}

.specialties-modal-content {
  background-color: #fff; 
}
.specialties-modal-content h2 {
  color: #2563EB; 
}
.specialties-modal-content #cerrar-modal-especialidades {
  color: #6b7280; 
}
.specialties-modal-content #cerrar-modal-especialidades:hover {
  color: #1f2937;
}
.specialties-modal-content #filtro-especialidades {
  background-color: #f9fafb; 
  border: 1px solid #e5e7eb;
}
.specialties-modal-content #filtro-especialidades:focus {
  border-color: #2563EB; 
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.2);
}
.specialties-modal-content #todas-especialidades-container a {
  background: linear-gradient(120deg, #2563EB 0%, #10B981 100%); 
  color: white; 
  transition: filter 0.3s ease, transform 0.3s ease; 
  box-shadow: 0 4px 15px -3px rgba(0, 0, 0, 0.1);
}
.specialties-modal-content #todas-especialidades-container a:hover {
  filter: brightness(1.1); 
  transform: translateY(-4px); 
  box-shadow: 0 10px 20px -5px rgba(37, 99, 235, 0.2);
}
.specialties-modal-content #todas-especialidades-container a i {
  color: white;
}

/* ---------------------------------- */
/*      SECCIÓN DE EMERGENCIAS        */
/* ---------------------------------- */
.emergency-section {
  background-color: #111827;
  overflow: hidden;
}
.emergency-card {
  background-color: #1f2937;
  border-radius: 0.75rem;
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  border: 1px solid #374151;
  transition: all 0.3s ease-in-out;
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  position: relative;
  overflow: hidden;
}
.emergency-card:hover {
  transform: translateY(-8px);
  border-color: #60A5FA;
  box-shadow: 0 20px 25px -5px rgba(96, 165, 250, 0.1), 0 10px 10px -5px rgba(96, 165, 250, 0.04);
}
.emergency-card.is-urgent:hover {
  border-color: #EF4444;
  box-shadow: 0 20px 25px -5px rgba(239, 68, 68, 0.1), 0 10px 10px -5px rgba(239, 68, 68, 0.04);
}
@keyframes light-pulse {
  0% { transform: translateX(-100%) skewX(-20deg); opacity: 0.1; }
  50% { transform: translateX(100%) skewX(-20deg); opacity: 0.2; }
  100% { transform: translateX(200%) skewX(-20deg); opacity: 0.1; }
}
.emergency-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 50%;
  height: 100%;
  background: linear-gradient(to right, transparent 0%, rgba(255, 255, 255, 0.8) 50%, transparent 100%);
  animation: light-pulse 5s infinite linear;
  animation-delay: calc(var(--i, 0) * 0.5s);
}
.emergency-card.is-urgent::before {
  background: linear-gradient(to right, transparent 0%, rgba(239, 68, 68, 0.8) 50%, transparent 100%);
}
.emergency-logo-wrapper {
  background-color: #fff;
  border-radius: 50%;
  width: 80px;
  height: 80px;
  display: flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 1rem;
  padding: 0.75rem;
  box-shadow: 0 0 15px rgba(255, 255, 255, 0.1);
}
.emergency-logo-wrapper img {
  max-height: 100%;
  max-width: 100%;
  object-fit: contain;
}
.emergency-details {
  flex-grow: 1;
}
.emergency-cta {
  margin-top: 1.5rem;
  width: 100%;
  background-color: #2563EB;
  color: white;
  font-weight: 700;
  padding: 0.75rem 1rem;
  border-radius: 0.5rem;
  transition: background-color 0.2s ease, transform 0.2s ease;
  display: inline-block;
}
.emergency-card.is-urgent .emergency-cta {
  background-color: #DC2626;
}
.emergency-cta:hover {
  filter: brightness(1.1);
  transform: scale(1.05);
}

/* ---------------------------------- */
/*      BARRA RESUMEN BÚSQUEDA        */
/* ---------------------------------- */
.results-summary-bar {
  padding: 0.75rem 1.5rem;
  margin-bottom: 2rem; 
  background-color: #eef2ff;
  border-left: 4px solid #2563EB;
  border-radius: 0.5rem;
  color: #374151;
  font-size: 1rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  transition: opacity 0.3s ease, transform 0.3s ease;
  opacity: 1;
  transform: translateY(0);
}
.results-summary-bar.hidden {
  opacity: 0;
  transform: translateY(-10px);
  display: none;
}
.results-summary-bar i {
  color: #2563EB;
}
.results-summary-bar strong {
  color: #1e40af;
  font-weight: 600;
}

/* ---------------------------------- */
/*      DISEÑO WOW BLOG               */
/* ---------------------------------- */
.featured-article-card {
  position: relative;
  border-radius: 1rem;
  overflow: hidden;
  color: white;
  display: block;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.2), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
  transition: transform 0.4s ease, box-shadow 0.4s ease;
}
.featured-article-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 20px 30px -10px rgba(0, 0, 0, 0.3);
}
.featured-article-card .image-container {
  height: 400px;
}
.featured-article-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}
.featured-article-card:hover img {
  transform: scale(1.05);
}
.featured-article-card .overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.8) 0%, rgba(0, 0, 0, 0) 60%);
}
.featured-article-card .content {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 2rem;
}
.blog-card {
  background-color: white;
  border-radius: 1rem;
  overflow: hidden;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.06);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
}
.blog-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}
.blog-card .image-container {
  height: 200px;
  overflow: hidden;
}
.blog-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}
.blog-card:hover img {
  transform: scale(1.1);
}
.blog-card .content {
  padding: 1.5rem;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
}
.blog-card .category-pill {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
  background-color: #e0f2fe;
  color: #0c4a6e;
}
.blog-card .date-info {
  display: flex;
  align-items: center;
  color: #6b7280;
  font-size: 0.875rem;
}
.blog-card .date-info i {
  margin-right: 0.5rem;
}
.blog-card .tags-container {
  margin-top: auto;
  padding-top: 1rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}
.blog-card .tag {
  background-color: #f3f4f6;
  color: #4b5563;
  padding: 0.25rem 0.75rem;
  border-radius: 0.25rem;
  font-size: 0.75rem;
}

/* ---------------------------------- */
/*      RESTO DE ESTILOS              */
/* ---------------------------------- */
.how-it-works-step { 
  background-color: rgba(13, 107, 214, 0.212); 
  backdrop-filter: blur(10px); 
  -webkit-backdrop-filter: blur(10px); 
  border: 1px solid rgba(255, 255, 255, 0.2); 
  border-radius: 0.75rem; 
  padding: 1.5rem; 
  display: flex; 
  align-items: center; 
  text-align: left; 
  gap: 1rem; 
  transition: all 0.3s ease; 
}
.how-it-works-step:hover { 
  background-color: rgba(255, 255, 255, 0.2); 
  transform: translateY(-5px); 
}
.how-it-works-step .step-icon { 
  background-color: #10B981; 
  color: white; 
  min-width: 50px; 
  height: 50px; 
  border-radius: 50%; 
  display: flex; 
  align-items: center; 
  justify-content: center; 
  font-size: 1.5rem; 
}
.how-it-works-step h3 { 
  font-weight: 700; 
  color: white; 
  font-size: 1.1rem; 
}
.how-it-works-step p { 
  font-size: 0.9rem; 
  color: #e0e7ff; 
}
.card-interaction { 
  transition: transform 0.3s ease, box-shadow 0.3s ease; 
}
.card-interaction:hover { 
  transform: translateY(-8px); 
  box-shadow: 0 10px 20px rgba(37, 99, 235, 0.1), 0 3px 6px rgba(37, 99, 235, 0.08); 
}
.btn-interaction { 
  transition: transform 0.2s ease, background-color 0.2s ease; 
}
.btn-interaction:active { 
  transform: scale(0.97); 
}
.featured-ribbon { 
  position: absolute; 
  top: -5px; 
  right: -5px; 
  width: 110px; 
  height: 110px; 
  overflow: hidden; 
  z-index: 10; 
}
.featured-ribbon span { 
  position: absolute; 
  display: block; 
  width: 150px; 
  padding: 8px 0; 
  background-color: #facc15; 
  box-shadow: 0 5px 10px rgba(0,0,0,0.1); 
  color: #422006; 
  font-size: 0.8rem; 
  font-weight: bold; 
  text-shadow: 0 1px 1px rgba(0,0,0,0.2); 
  text-align: center; 
  right: -30px; 
  top: 25px; 
  transform: rotate(45deg); 
}
.carousel-wrapper { 
  overflow: hidden; 
  padding-bottom: 20px; /* MODIFICACIÓN: Espacio para la sombra */
}
#destacados-carousel { 
  display: flex; 
  width: max-content; 
}
#destacados-carousel.scrolling { 
  animation-name: scroll-left; 
  animation-timing-function: linear; 
  animation-iteration-count: infinite; 
}
.carousel-card { 
  width: 280px; 
  flex-shrink: 0; 
  padding: 0.5rem; 
}
.carousel-card img { 
  width: 100%; 
  aspect-ratio: 1 / 1; 
  object-fit: cover; 
  object-position: center; 
}
.carousel-arrow { 
  position: absolute; 
  top: 50%; 
  transform: translateY(-50%); 
  z-index: 20; 
  background-color: rgba(255, 255, 255, 0.95); 
  backdrop-filter: blur(4px); 
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15); 
  width: 44px; 
  height: 44px; 
  display: flex; 
  align-items: center; 
  justify-content: center; 
  border-radius: 9999px; 
  cursor: pointer; 
  transition: transform 0.2s ease, background-color 0.2s ease; 
}
.carousel-arrow:hover { 
  background-color: white; 
  transform: translateY(-50%) scale(1.1); 
}
.carousel-arrow i { 
  font-size: 1.25rem; 
  color: #2563EB; 
  pointer-events: none; 
}
@keyframes scroll-left { 
  from { transform: translateX(0); } 
  to { transform: translateX(-50%); } 
}
#preloader { 
  position: fixed; 
  top: 0; 
  left: 0; 
  right: 0; 
  bottom: 0; 
  background-color: #fff; 
  z-index: 9999; 
  display: flex; 
  justify-content: center; 
  align-items: center; 
  transition: opacity 0.5s ease-out; 
}
.spinner { 
  border: 4px solid rgba(0, 0, 0, 0.1); 
  width: 36px; 
  height: 36px; 
  border-radius: 50%; 
  border-left-color: #2563EB; 
  animation: spin 1s ease infinite; 
}
@keyframes spin { 
  from { transform: rotate(0deg); } 
  to { transform: rotate(360deg); } 
}
#main-content { 
  transition: opacity 0.2s ease-in-out; 
}
#main-content.fade-out { 
  opacity: 0; 
}
.listing-image { 
  width: 100%; 
  aspect-ratio: 1 / 1; 
  object-fit: cover; 
  object-position: center; 
  background-color: #f3f4f6; 
}

.footer-credit-link { 
  display: inline-block; 
  margin-top: 0.25rem; 
  padding: 0.25rem 0.75rem; 
  background-color: rgba(37, 99, 235, 0.1); 
  color: #60A5FA; 
  font-weight: 700; 
  border-radius: 0.5rem; 
  transition: all 0.3s ease; 
  border: 1px solid rgba(37, 99, 235, 0.2); 
}
.footer-credit-link:hover { 
  color: white; 
  background-color: #2563EB; 
  transform: translateY(-2px); 
  box-shadow: 0 4px 10px rgba(37, 99, 235, 0.3); 
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes pulse-effect {
  0%, 100% {
    transform: scale(1) translateY(0);
    box-shadow: none;
  }
  5% {
    transform: scale(1.03) translateY(-5px);
    box-shadow: 0 10px 25px rgba(16, 185, 129, 0.4);
  }
  15% {
    transform: scale(1) translateY(0);
    box-shadow: none;
  }
}

.animate-on-scroll {
  opacity: 0;
}

.is-visible {
  animation-name: fadeInUp, pulse-effect;
  animation-duration: 0.6s, 7s;
  animation-timing-function: ease-out, ease-in-out;
  animation-fill-mode: forwards, none;
  animation-iteration-count: 1, infinite;
}

.how-it-works-step.is-visible:nth-child(1) {
  animation-delay: 0s, 2s;
}
.how-it-works-step.is-visible:nth-child(2) {
  animation-delay: 0.2s, 2.2s;
}
.how-it-works-step.is-visible:nth-child(3) {
  animation-delay: 0.4s, 2.4s;
}

.mobile-fixed-footer {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 1000;
}

@media (max-width: 1279px) { /* xl breakpoint */
  body {
    padding-bottom: 64px; /* Altura del footer móvil (h-16) */
  }
}

@keyframes shine-effect {
  0% {
    transform: translateX(-150%) skewX(-25deg);
  }
  100% {
    transform: translateX(250%) skewX(-25deg);
  }
}

.text-danger {
  color: #EF4444;
}

.video-background-container {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  z-index: -1;
}

.video-background {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
}

/* ---------------------------------- */
/*      POP-UP BIENVENIDA IDIOMAS     */
/* ---------------------------------- */
@keyframes slideInUp {
  from {
    opacity: 0;
    transform: translateY(25px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeOutDown {
  from {
    opacity: 1;
    transform: translateY(0);
  }
  to {
    opacity: 0;
    transform: translateY(25px);
  }
}

#language-welcome-popup {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  width: 320px;
  background-color: white;
  border-radius: 0.75rem;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
  padding: 1.5rem;
  z-index: 1050;
  border: 1px solid #e5e7eb;
  font-family: 'Inter', sans-serif;
}

#language-welcome-popup.popup-entering {
  animation: slideInUp 0.5s ease-out forwards;
}

#language-welcome-popup.popup-exiting {
  animation: fadeOutDown 0.5s ease-in forwards;
}

.close-popup-btn {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  background: none;
  border: none;
  cursor: pointer;
  color: #9ca3af;
  font-size: 1.25rem;
  line-height: 1;
  transition: color 0.2s ease;
}
.close-popup-btn:hover {
  color: #1f2937;
}

.popup-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1rem;
}
.popup-header .icon {
  font-size: 1.5rem;
  color: #2563EB;
}
.popup-header .title {
  font-size: 1.125rem;
  font-weight: 700;
  color: #1f2937;
}

.popup-lang-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}
.popup-lang-list li {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.95rem;
  color: #374151;
}
.popup-lang-list .flag-icon {
  width: 1.75em;
  height: 1.75em;
}

.popup-hint {
  margin-top: 1.25rem;
  padding-top: 0.75rem;
  border-top: 1px solid #f3f4f6;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.8rem;
  color: #6b7280;
}

/* ---------------------------------- */
/* MODIFICACIÓN: SELECTOR IDIOMA DESKTOP */
/* ---------------------------------- */
header nav .language-switcher .lang-button {
  display: none; /* Ocultar todos los botones por defecto */
}
header nav .language-switcher .lang-button.active {
  display: inline-flex; /* Mostrar solo el botón activo */
  cursor: pointer;
}

/* ---------------------------------- */
/* MODIFICACIÓN: BLOG PREVIEW (INDEX) */
/* ---------------------------------- */
.blog-preview-card {
  background-color: white;
  border-radius: 1rem;
  overflow: hidden;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.06);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
  text-decoration: none;
}
.blog-preview-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 10px 15px -3px rgba(37, 99, 235, 0.1), 0 4px 6px -2px rgba(37, 99, 235, 0.05);
}
.blog-preview-card .image-container {
  height: 200px;
  overflow: hidden;
}
.blog-preview-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}
.blog-preview-card:hover img {
  transform: scale(1.05);
}
.blog-preview-card .content {
  padding: 1.5rem;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
}
.blog-preview-card .category-pill {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
  background-color: #e0f2fe;
  color: #0c4a6e;
}
.blog-preview-card .title {
  font-size: 1.125rem;
  font-weight: 700;
  color: #1f2937;
  line-height: 1.4;
  margin-bottom: 0.75rem;
  flex-grow: 1;
}
.blog-preview-card .date-info {
  display: flex;
  align-items: center;
  color: #6b7280;
  font-size: 0.875rem;
  margin-top: auto;
  padding-top: 1rem;
  border-top: 1px solid #f3f4f6;
}
.blog-preview-card .date-info i {
  margin-right: 0.5rem;
  color: #9ca3af;
}
/* ---------------------------------- */
/* MODIFICACIÓN: HERO CTA BUTTON WOW  */
/* ---------------------------------- */
@keyframes pulse-glow-accent {
  0%, 100% {
    transform: scale(1.05);
    box-shadow: 0 0 20px rgba(16, 185, 129, 0.4);
  }
  50% {
    transform: scale(1.1);
    box-shadow: 0 0 35px rgba(16, 185, 129, 0.7);
  }
}

.cta-hero-wow {
  animation: pulse-glow-accent 3s infinite ease-in-out;
}