/* ========== RESET & FUENTE ========== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
  font-family: 'Montserrat', sans-serif;
}

/* ========== EFECTO MÁQUINA DE ESCRIBIR ========== */
.typewriter {
  overflow: hidden;
  border-right: 0.15em solid #fff;
  white-space: nowrap;
  animation: typing 3s steps(30, end), blink-caret 0.7s step-end infinite;
  opacity: 0;
  transition: opacity 0.4s ease-in-out;
}
.typewriter-visible {
  opacity: 1;
}
#typewriter::after {
  content: '|';
  animation: blink 1s infinite;
  margin-left: 4px;
  color: white;
}
@keyframes typing {
  from { width: 0; }
  to { width: 100%; }
}
@keyframes blink-caret {
  from, to { border-color: transparent; }
  50% { border-color: #fff; }
}
@keyframes blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

/* ========== EFECTOS TARJETAS ========== */
.tarjeta-hover {
  transition: transform 0.4s ease, box-shadow 0.4s ease;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.7);
  will-change: transform, box-shadow;
}
.tarjeta-hover:hover,
.tarjeta-hover:active {
  transform: translateY(-12px);
  box-shadow: 0 16px 30px rgba(0, 0, 0, 0.8);
}

/* ========== EFECTO FLOTANTE ========== */
@keyframes flotarSuave {
  0% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
  100% { transform: translateY(0); }
}
.img-flotante {
  animation: flotarSuave 6s ease-in-out infinite;
  will-change: transform;
}

/* ========== ANIMACIONES EN SCROLL ========== */
.animate-up, .titulo-ubicacion {
  opacity: 0;
  transform: translateY(40px);
  transition: all 0.8s ease-out;
}
.animate-up.show, .titulo-ubicacion.mostrar {
  opacity: 1;
  transform: translateY(0);
}

/* ========== MODAL ========== */
#modalImagen,
#modalCarrusel {
  backdrop-filter: blur(4px);
  animation: fadeIn 0.3s ease-out;
}
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: scale(0.95);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* ========== CARRUSEL CARDS ========= */
.cardSwiper .swiper-slide {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  border-radius: 1rem;
}
.cardSwiper .swiper-slide:hover {
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
  transform: translateY(-4px);
}

/* ========== FLECHAS PERSONALIZADAS ========== */
.custom-swiper-prev, .custom-swiper-next,
.multi-prev, .multi-next {
  width: 40px;
  height: 40px;
  background-image: url('./flecha_carrusel.png');
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 50;
  cursor: pointer;
  pointer-events: all;
}
.custom-swiper-prev, .multi-prev {
  left: 0;
  transform: translateY(-50%) scaleX(-1);
}
.custom-swiper-next, .multi-next {
  right: 0;
}

/* ========== BOTÓN CTA ========== */
.cta-button::after {
  content: "";
  position: absolute;
  top: 50%;
  right: 1.25rem;
  transform: translateY(-50%);
  width: 20px;
  height: 20px;
  background-image: url('./flecha_carrusel.png');
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  transition: transform 0.3s ease, filter 0.3s ease;
}
.cta-button:hover::after {
  transform: translateY(-50%) translateX(4px);
  filter: brightness(0) invert(1);
}

/* ========== FORMULARIO FLOTANTE ========== */
.formulario-flotante {
  background-color: #f9f9f9;
  border-radius: 1rem;
  padding: 2rem;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
  border: 1px solid #e0e0e0;
  font-family: 'Montserrat', sans-serif;
}
.input-block {
  margin-bottom: 1.5rem;
}
.input-block label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 600;
  color: #559F2C;
}
.input-block input,
.input-block select {
  width: 100%;
  padding: 0.75rem;
  border: 1px solid #ccc;
  border-radius: 0.75rem;
  font-size: 1rem;
  transition: border-color 0.3s ease;
}
.input-block input:focus,
.input-block select:focus {
  border-color: #559F2C;
  outline: none;
}
.checkbox-block {
  margin-top: 1.25rem;
}
.checkbox-label {
  display: flex;
  align-items: flex-start;
  font-size: 0.9rem;
  color: #333;
}
.checkbox-label input[type="checkbox"] {
  margin-right: 0.5rem;
  margin-top: 3px;
}
.checkbox-label a {
  color: #559F2C;
  text-decoration: underline;
}
.submit-btn {
  width: 100%;
  background-color: #559F2C;
  color: white;
  font-weight: 700;
  padding: 0.75rem;
  border: none;
  border-radius: 9999px;
  font-size: 1rem;
  cursor: pointer;
  transition: background-color 0.3s ease;
}
.submit-btn:hover {
  background-color: #3f7e22;
}
.confirmation-message {
  text-align: center;
  padding: 1.5rem;
  background-color: #e6f9ed;
  border: 1px solid #b2e2c1;
  border-radius: 0.75rem;
  color: #559F2C;
}

/* ========== FOOTER ========== */
.footer {
  background-color: #559F2C;
  color: #eee;
  padding: 60px 40px 30px;
  font-family: 'Poppins', sans-serif;
}
.footer-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 40px;
  max-width: 1200px;
  margin: 0 auto;
}
.footer-logo img {
  width: 140px;
  margin-bottom: 15px;
}
.footer-logo p,
.footer-section p,
.footer-section li {
  font-size: 0.9rem;
  color: #f4f4f4;
  margin-bottom: 8px;
}
.footer-title {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 15px;
  color: #f4f4f4;
}
.footer-section ul {
  list-style: none;
  padding: 0;
  margin: 0;
}
.footer-section ul li a {
  text-decoration: none;
  color: #f4f4f4;
  transition: color 0.3s ease;
}
.footer-section ul li a:hover {
  color: #000;
}
.footer-socials {
  display: flex;
  gap: 12px;
  margin-top: 10px;
}
.footer-socials a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #559F2C;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  color: #fff;
  font-size: 1rem;
  transition: background 0.3s ease, color 0.3s ease;
}
.footer-socials a:hover {
  background: #000;
  color: #fff;
}
.footer-bottom {
  text-align: center;
  margin-top: 40px;
  border-top: 1px solid #333;
  padding-top: 20px;
  font-size: 0.85rem;
  color: #f4f4f4;
}
.footer-bottom a {
  color: #f4f4f4;
  text-decoration: none;
  margin: 0 8px;
  transition: color 0.3s ease;
}
.footer-bottom a:hover {
  color: #000;
}

/* ========== RESPONSIVE ========== */
@media (max-width: 768px) {
  .cta-button {
    font-size: 0.9rem;
    padding: 0.6rem 1rem;
  }
  .formulario-flotante {
    padding: 1.5rem;
  }
  .footer {
    padding: 40px 20px 20px;
  }
  .footer-container {
    gap: 20px;
  }
  .footer-section,
  .footer-logo {
    text-align: center;
  }
  .footer-socials {
    justify-content: center;
  }
}
@media (max-width: 480px) {
  .cardSwiper .swiper-slide {
    height: 280px;
  }
  .swiper-slide img {
    height: 200px !important;
  }
  .footer-logo img {
    width: 120px;
  }
}

/* FORMULARIO RESPONSIVE PARA MOBILE */
@media (max-width: 1024px) {
  #sticky {
    position: static !important;
    margin-top: 2rem;
    width: 100% !important;
  }
  #sticky .formulario-flotante {
    padding: 1.5rem;
    border-radius: 1rem;
  }
  #sticky .input-block input,
  #sticky .input-block select {
    font-size: 0.95rem;
  }
}
@media (max-width: 640px) {
  .formulario-flotante {
    padding: 1rem;
  }
  .submit-btn {
    font-size: 0.9rem;
    padding: 0.6rem 1.2rem;
  }
  .checkbox-label {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* ========== LIBRO DE RECLAMACIONES ========== */
.footer .libro-reclamaciones {
  height: 40px;
  margin-top: 15px;
  margin-bottom: 5px;
  display: block;
  margin-left: auto;
  margin-right: auto;
  transition: transform 0.3s ease;
}
.footer .libro-reclamaciones:hover {
  transform: scale(1.05);
}
