/* ===== Overlay do pop-up (SEM ALTERAÇÕES) ===== */
#promo-popup-overlay {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: rgba(0,0,0,.65);
  z-index: 9999;
}
#promo-popup-overlay.show { display: flex; }

/* ===== Card do pop-up (SEM ALTERAÇÕES) ===== */
.promo-popup-card {
  position: relative;
  width: min(92vw, 560px);
  max-height: 100%;
  border-radius: 18px;
  border: 1px solid rgba(255,255,255,.18);
  background: linear-gradient(180deg, rgba(255,255,255,.06) 0%, rgba(255,255,255,.02) 100%);
  box-shadow: 0 18px 60px rgba(0,0,0,.45);
  overflow: hidden;
}

/* ===== Botão X (SEM ALTERAÇÕES) ===== */
.promo-popup-close {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,.35);
  background: rgba(0,0,0,.85);
  color: #fff;
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
  z-index: 3; /* acima de tudo */
}

/* ===== Conteúdo (MANTIDO RESPIRO) ===== */
.promo-popup-content {
  padding: 14px; /* Respiro de 14px ao redor do conteúdo */
}

.promo-popup-image-wrapper {
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  background: rgba(0,0,0,.35);
  /* REAJUSTE: Remove min-height fixo para permitir o ajuste vertical, */
  /* mas garante uma proporção inicial usando padding-bottom para a imagem que é quase quadrada (1:1.04). */
  min-height: 0;
  padding-bottom: 104%; /* 781/750 ≈ 1.04. Isso força a altura a ser proporcional à largura. */
  box-sizing: border-box;
}

.promo-popup-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  background: #F4A261;
  color: #000;
  font-weight: 800;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid #3F6C3A;
  z-index: 2;
}

.promo-popup-image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  /* AJUSTE CRUCIAL: Mudar de 'cover' para 'contain' */
  object-fit: contain; /* Garante que a imagem inteira caiba, sem cortes */
}

/* ===== CTA sobre a imagem (MANTIDO) ===== */
.promo-popup-footer {
  position: absolute;
  left: 50%;
  bottom: 16px;
  transform: translateX(-50%);
  z-index: 2;
}

.promo-popup-btn {
  display: inline-block;
  padding: 12px 18px;
  border-radius: 12px;
  background: #F4A261;
  color: #000;
  font-weight: 800;
  text-decoration: none;
  box-shadow: 0 10px 24px rgba(0,0,0,.25);
  border: 1px solid #3F6C3A;
  cursor: pointer;
}

/* ===== Breakpoints (Ajuste o padding em telas maiores) ===== */
@media (min-width: 640px){
  .promo-popup-card { width: min(92vw, 720px); }
  .promo-popup-content {
    padding: 24px; /* Mais respiro em telas maiores */
  }
  .promo-popup-image-wrapper {
    padding-bottom: 104%; /* Mantém a proporção da imagem */
  }
}
@media (min-width: 1024px){
  .promo-popup-content {
    padding: 24px; /* Mantém o respiro grande */
  }
  .promo-popup-image-wrapper {
    /* Em telas maiores, podemos definir uma altura máxima para limitar o tamanho */
    max-height: 60vh;
    padding-bottom: 0; /* Remove padding-bottom (proporção) quando max-height está ativo */
  }
  .promo-popup-btn {
    z-index: 2;
  }
  .promo-popup-close{
    z-index: 3;
  }
  .promo-popup-card { width: min(86vw, 980px); }
}
@media (min-width: 1440px){
  .promo-popup-card { width: min(70vw, 1100px); }
}