@import url("../../Styles/fonts.css");
#popup-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.85);
  z-index: 10000;
  justify-content: center;
  align-items: center;
  animation: fadeIn 0.6s ease forwards;
}

#popup-container {
  background: white;
  border-radius: 12px;
  width: 90%;
  max-width: 800px;
  overflow: hidden;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.6);
  position: relative;
  animation: slideUp 0.7s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
  transform: translateY(30px);
  opacity: 0;
}

/* Estilos para la imagen del popup */
.popup-image {
  width: 100%;
  height: 300px;
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
  overflow: hidden;

  /* Evitar que la imagen se arrastre */
  -webkit-user-drag: none;

  /* Prevenir selección de texto/imagen */
  user-select: none;
  -moz-user-select: none;
  -webkit-user-select: none;
  -ms-user-select: none;

  /* Ajuste de imagen al contenedor */
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

/* Si usas etiqueta <img> dentro de .popup-image */
.popup-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;

  /* Prevenir arrastre */
  pointer-events: none;
  -webkit-user-drag: none;
  user-select: none;
}

.popup-content {
  padding: 30px;
  text-align: center;
  position: relative;
}

.popup-title {
  font-family: "Montserrat-Bold";
  font-size: 2rem;
  color: var(--color-principal);
  margin-bottom: 1rem;
}

.popup-text {
  font-family: "Poppins-Regular";
  font-size: 1.2rem;
  line-height: 1.6;
  color: var(--color-texto);
  margin-bottom: 1rem;
}

.popup-close {
  position: absolute;
  top: 20px;
  right: 20px;
  color: white;
  font-size: 32px;
  cursor: pointer;
  width: 45px;
  height: 45px;
  display: flex;
  justify-content: center;
  align-items: center;
  transition: all 0.4s ease;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.3);
  z-index: 10;
  text-shadow: 0 2px 3px rgba(0, 0, 0, 0.3);
}

.popup-close:hover {
  background: rgba(0, 0, 0, 0.6);
  transform: rotate(90deg) scale(1.1);
}

.btn-contactop {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  background: #143da5;
  color: #fefefe;
  font-weight: 400;
  border-radius: 999px;
  text-decoration: none;
  transition: 0.3s ease;
  max-width: 200px;
}

.btn-contactop:hover {
  scale: 1.2;
}

.popup-btn:active {
  transform: translateY(1px);
}

.popup-btn::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    to right,
    rgba(255, 255, 255, 0.3),
    rgba(255, 255, 255, 0)
  );
  opacity: 0;
  transition: opacity 0.3s ease;
}

.popup-btn:hover::before {
  opacity: 1;
}

/* Animaciones */
@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes slideUp {
  from {
    transform: translateY(30px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

@keyframes pulse {
  0% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.05);
  }
  100% {
    transform: scale(1);
  }
}

/* Responsive */
@media (max-width: 600px) {
  #popup-container {
    max-width: 90%;
  }

  .popup-image {
    height: 180px;
  }

  .popup-content {
    padding: 25px 15px;
  }

  .popup-title {
    font-size: 24px;
  }

  .popup-text {
    font-size: 16px;
    margin: 20px 0;
  }

  .popup-btn {
    padding: 14px 35px;
    font-size: 16px;
  }

  .popup-close {
    top: 15px;
    right: 15px;
    width: 38px;
    height: 38px;
    font-size: 28px;
  }
}

@media (max-width: 400px) {
  .popup-image {
    height: 150px;
  }

  .popup-title {
    font-size: 22px;
  }
}
