/* Popups flotantes — sitio público */
.site-popup {
  position: fixed;
  inset: 0;
  z-index: 99990;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 1rem;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.28s ease;
}

.site-popup--visible {
  opacity: 1;
  pointer-events: auto;
}

.site-popup--closing {
  opacity: 0;
  pointer-events: none;
}

.site-popup__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.45);
  backdrop-filter: blur(2px);
}

.site-popup__card {
  position: relative;
  width: min(100%, 22rem);
  margin: 0 auto;
  padding: 1.35rem 1.25rem 1.15rem;
  border-radius: 1.25rem;
  background: #fff;
  box-shadow: 0 24px 48px -12px rgba(15, 23, 42, 0.28), 0 0 0 1px rgba(15, 23, 42, 0.06);
  transform: translateY(1.25rem) scale(0.97);
  transition: transform 0.32s cubic-bezier(0.22, 1, 0.36, 1);
}

.site-popup--visible .site-popup__card {
  transform: translateY(0) scale(1);
}

.site-popup--closing .site-popup__card {
  transform: translateY(0.75rem) scale(0.98);
}

.site-popup__close {
  position: absolute;
  top: 0.65rem;
  right: 0.65rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  border: none;
  border-radius: 9999px;
  background: #f1f5f9;
  color: #64748b;
  font-size: 0.875rem;
  cursor: pointer;
}

.site-popup__close:hover {
  background: #e2e8f0;
  color: #334155;
}

.site-popup__badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 3rem;
  height: 3rem;
  margin-bottom: 0.85rem;
  border-radius: 9999px;
  font-size: 1.35rem;
  line-height: 1;
}

.site-popup__badge--wa {
  background: linear-gradient(145deg, #22c55e 0%, #16a34a 100%);
  color: #fff;
  box-shadow: 0 8px 20px -6px rgba(22, 163, 74, 0.55);
}

.site-popup__badge--ad {
  background: linear-gradient(145deg, #818cf8 0%, #6366f1 100%);
  color: #fff;
  box-shadow: 0 8px 20px -6px rgba(99, 102, 241, 0.45);
}

.site-popup__badge--default {
  background: #f1f5f9;
  color: #475569;
}

.site-popup__img-link {
  display: block;
  margin: -0.25rem -0.25rem 0.85rem;
  border-radius: 0.85rem;
  overflow: hidden;
}

.site-popup__img {
  display: block;
  width: 100%;
  height: auto;
  max-height: 14rem;
  object-fit: cover;
}

.site-popup__kicker {
  margin: 0;
  font-size: 0.6875rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #64748b;
}

.site-popup--whatsapp .site-popup__kicker {
  color: #059669;
}

.site-popup--publicidad .site-popup__kicker {
  color: #4f46e5;
}

.site-popup__title {
  margin: 0.35rem 0 0;
  font-size: 1.25rem;
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -0.02em;
  color: #0f172a;
}

.site-popup__text {
  margin: 0.65rem 0 0;
  font-size: 0.875rem;
  line-height: 1.55;
  color: #475569;
}

.site-popup__text strong {
  font-weight: 700;
  color: #1e293b;
}

.site-popup__actions {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin-top: 1.1rem;
}

.site-popup__cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.75rem;
  padding: 0 1rem;
  border: none;
  border-radius: 0.75rem;
  background: #0f172a;
  color: #fff;
  font-size: 0.9375rem;
  font-weight: 800;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.15s ease, transform 0.15s ease;
}

.site-popup--whatsapp .site-popup__cta {
  background: #16a34a;
  box-shadow: 0 10px 24px -10px rgba(22, 163, 74, 0.65);
}

.site-popup--publicidad .site-popup__cta {
  background: #4f46e5;
  box-shadow: 0 10px 24px -10px rgba(79, 70, 229, 0.55);
}

.site-popup__cta:hover {
  transform: translateY(-1px);
  filter: brightness(1.05);
}

.site-popup__later {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.25rem;
  border: none;
  border-radius: 0.65rem;
  background: transparent;
  color: #64748b;
  font-size: 0.8125rem;
  font-weight: 600;
  cursor: pointer;
}

.site-popup__later:hover {
  color: #334155;
  background: #f8fafc;
}

@media (min-width: 640px) {
  .site-popup {
    align-items: center;
    padding: 1.5rem;
  }

  .site-popup__card {
    width: min(100%, 24rem);
    padding: 1.5rem 1.35rem 1.25rem;
  }

  .site-popup__title {
    font-size: 1.375rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .site-popup,
  .site-popup__card {
    transition: none;
  }
}
