/* PDL Mobile API - popup "compre na app" (site e pre-visualizacao do backoffice) */
.pdl-promo { --pdl-promo-primary:#69206f; --pdl-promo-accent:#b969d4; --pdl-promo-text:#423a51; --pdl-promo-surface:#fff; --pdl-promo-btn-text:#fff; }
.pdl-promo-backdrop { position: fixed; inset: 0; z-index: 100000; display: flex; align-items: center; justify-content: center; padding: 16px; background: rgba(28, 12, 32, .55); opacity: 0; transition: opacity .25s ease; }
.pdl-promo-backdrop.is-open { opacity: 1; }
.pdl-promo__box { position: relative; width: 100%; max-width: 420px; margin-top: 44px; padding: 56px 28px 24px; border: 2px solid var(--pdl-promo-accent); border-radius: 28px; background: var(--pdl-promo-surface); color: var(--pdl-promo-text); text-align: center; font-family: inherit; box-shadow: 0 24px 65px rgba(59, 20, 70, .3); transform: translateY(16px) scale(.97); transition: transform .3s cubic-bezier(.22, 1.2, .55, 1); }
.pdl-promo-backdrop.is-open .pdl-promo__box { transform: none; }
.pdl-promo__icon { position: absolute; top: -44px; left: 50%; width: 88px; height: 88px; padding: 6px; transform: translateX(-50%); border: 2px solid var(--pdl-promo-accent); border-radius: 24px; background: var(--pdl-promo-surface); box-shadow: 0 9px 24px rgba(75, 28, 95, .2); }
.pdl-promo__icon img { display: block; width: 100%; height: 100%; object-fit: cover; border-radius: 18px; }
.pdl-promo__close { position: absolute; top: 12px; right: 14px; width: 34px; height: 34px; padding: 0; border: 0; background: transparent; color: var(--pdl-promo-primary); font-family: Arial, sans-serif; font-size: 28px; font-weight: 300; line-height: 34px; cursor: pointer; transition: transform .2s ease, color .2s ease; }
.pdl-promo__close:hover { color: var(--pdl-promo-accent); transform: rotate(90deg); }
.pdl-promo__badge { display: inline-block; margin: 0 0 12px; padding: 6px 18px; border-radius: 999px; background: linear-gradient(115deg, var(--pdl-promo-primary), var(--pdl-promo-accent)); color: var(--pdl-promo-btn-text); font-size: 1.6rem; font-weight: 800; line-height: 1.1; letter-spacing: -.01em; box-shadow: 0 8px 18px rgba(80, 22, 91, .25); }
.pdl-promo-backdrop.is-open .pdl-promo__badge, .pdl-promo--preview .pdl-promo__badge { animation: pdl-promo-pop .6s .25s cubic-bezier(.22, 1.4, .55, 1) both; }
.pdl-promo__title { margin: 0 0 10px; color: var(--pdl-promo-primary); font-family: Georgia, 'Times New Roman', serif; font-size: clamp(1.35rem, 1.1rem + 1.2vw, 1.8rem); font-weight: 500; line-height: 1.2; letter-spacing: -.01em; }
.pdl-promo__message { max-width: 340px; margin: 0 auto 16px; color: var(--pdl-promo-text); font-size: .98rem; line-height: 1.45; white-space: pre-line; }
.pdl-promo__coupon { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 8px; margin: 0 auto 16px; font-size: .9rem; }
.pdl-promo__code { padding: 6px 14px; border: 2px dashed var(--pdl-promo-accent); border-radius: 10px; background: transparent; color: var(--pdl-promo-primary); font-family: inherit; font-size: 1rem; font-weight: 700; letter-spacing: .08em; cursor: pointer; }
.pdl-promo__qr { display: inline-block; min-width: 140px; min-height: 140px; margin: 0 0 8px; padding: 8px; border: 1px solid color-mix(in srgb, var(--pdl-promo-accent) 45%, transparent); border-radius: 12px; background: #fff; }
.pdl-promo__qr img, .pdl-promo__qr canvas { display: block; }
.pdl-promo__hint { margin: 0 auto 14px; max-width: 300px; font-size: .85rem; line-height: 1.4; opacity: .85; }
.pdl-promo__stores { display: flex; gap: 10px; margin-bottom: 4px; }
.pdl-promo__store, .pdl-promo__cta { display: flex; align-items: center; justify-content: center; border: 0; border-radius: 999px; background: linear-gradient(115deg, var(--pdl-promo-primary), var(--pdl-promo-accent) 53%, var(--pdl-promo-primary)); color: var(--pdl-promo-btn-text) !important; font-family: inherit; font-weight: 700; text-decoration: none !important; cursor: pointer; box-shadow: 0 10px 22px rgba(80, 22, 91, .25); transition: transform .2s ease, box-shadow .2s ease; }
.pdl-promo__store { flex: 1; min-height: 44px; padding: 10px 12px; font-size: .92rem; }
.pdl-promo__cta { position: relative; overflow: hidden; width: 100%; min-height: 50px; padding: 12px 24px; font-size: 1.05rem; }
.pdl-promo-backdrop.is-open .pdl-promo__cta, .pdl-promo--preview .pdl-promo__cta { animation: pdl-promo-breathe 2.5s ease-in-out infinite; }
.pdl-promo__cta::after { position: absolute; top: 0; left: -55%; width: 35%; height: 100%; background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .32), transparent); content: ''; transform: skewX(-24deg); animation: pdl-promo-shine 3.3s ease-in-out infinite; }
.pdl-promo__store:hover, .pdl-promo__cta:hover, .pdl-promo__store:focus, .pdl-promo__cta:focus { transform: translateY(-2px); box-shadow: 0 14px 28px rgba(80, 22, 91, .34); }
.pdl-promo__dismiss { display: inline-block; margin-top: 12px; padding: 6px 10px; border: 0; background: transparent; color: var(--pdl-promo-text); font-family: inherit; font-size: .88rem; text-decoration: underline; opacity: .75; cursor: pointer; }
.pdl-promo__dismiss:hover { opacity: 1; }
.pdl-promo__note { margin: 8px 0 0; font-size: .78rem; opacity: .7; }
@keyframes pdl-promo-pop { 0% { opacity: 0; transform: scale(.4) rotate(-8deg); } 60% { opacity: 1; transform: scale(1.12) rotate(3deg); } 100% { opacity: 1; transform: none; } }
@keyframes pdl-promo-breathe { 50% { box-shadow: 0 13px 30px rgba(110, 33, 119, .42); } }
@keyframes pdl-promo-shine { 0%, 58% { left: -55%; } 87%, 100% { left: 125%; } }

/* Telemovel: popup centrado, mais compacto */
@media (max-width: 575px) {
    .pdl-promo-backdrop { padding: 16px; }
    .pdl-promo__box { margin-top: 38px; padding: 58px 20px 18px; border-radius: 26px; }
    .pdl-promo__icon { top: -38px; width: 76px; height: 76px; border-radius: 20px; }
    .pdl-promo__icon img { border-radius: 15px; }
    .pdl-promo__badge { font-size: 1.4rem; }
    .pdl-promo__title { font-size: 1.3rem; }
    .pdl-promo__message { margin-bottom: 12px; font-size: .92rem; }
    .pdl-promo__coupon { margin-bottom: 14px; }
}

/* Ecras baixos (portateis pequenos): popup mais compacto */
@media (max-height: 720px) and (min-width: 576px) {
    .pdl-promo__box { margin-top: 36px; padding: 46px 24px 16px; }
    .pdl-promo__icon { top: -36px; width: 72px; height: 72px; border-radius: 20px; }
    .pdl-promo__badge { margin-bottom: 8px; font-size: 1.35rem; }
    .pdl-promo__title { margin-bottom: 6px; font-size: 1.35rem; }
    .pdl-promo__message, .pdl-promo__coupon { margin-bottom: 10px; }
    .pdl-promo__hint { margin-bottom: 10px; }
    .pdl-promo__note { display: none; }
    .pdl-promo__dismiss { margin-top: 6px; }
}

/* Pre-visualizacao no backoffice */
.pdl-promo--preview { position: relative; inset: auto; z-index: 1; opacity: 1; padding: 56px 16px 20px; background: #f4edf6; border-radius: 8px; }
.pdl-promo--preview .pdl-promo__box { transform: none; }
.pdl-promo--preview.is-mobile { align-items: center; }
.pdl-promo--preview.is-mobile .pdl-promo__box { max-width: 343px; padding: 58px 20px 18px; border-radius: 26px; }
.pdl-promo--preview .pdl-promo__close, .pdl-promo--preview .pdl-promo__cta, .pdl-promo--preview .pdl-promo__store, .pdl-promo--preview .pdl-promo__dismiss { pointer-events: none; }

@media (prefers-reduced-motion: reduce) {
    .pdl-promo-backdrop, .pdl-promo-backdrop *, .pdl-promo-backdrop *::after, .pdl-promo--preview * { animation: none !important; transition: none !important; }
}
