/* V15 — popup de campanha */
body.campaign-popup-open {
    overflow: hidden;
    overscroll-behavior: none;
}

.campaign-popup[hidden] {
    display: none !important;
}

.campaign-popup {
    position: fixed;
    inset: 0;
    z-index: 12000;
    display: grid;
    place-items: center;
    padding: clamp(12px, 3vw, 34px);
    opacity: 0;
    visibility: hidden;
    transition: opacity .24s ease, visibility .24s ease;
}

.campaign-popup.is-visible {
    opacity: 1;
    visibility: visible;
}

.campaign-popup-backdrop {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
    background:
        radial-gradient(circle at 50% 38%, rgba(22, 112, 210, .24), transparent 42%),
        rgba(2, 18, 38, .82);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    cursor: pointer;
}

.campaign-popup-card {
    position: relative;
    z-index: 1;
    width: min(610px, 100%);
    max-height: calc(100svh - 24px);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, .72);
    border-radius: 26px;
    background: #fff;
    box-shadow: 0 34px 90px rgba(0, 20, 48, .42);
    transform: translateY(20px) scale(.97);
    transition: transform .28s cubic-bezier(.2, .75, .2, 1);
}

.campaign-popup.is-visible .campaign-popup-card {
    transform: translateY(0) scale(1);
}

.campaign-popup-head {
    min-height: 70px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 14px 16px 13px 22px;
    color: #fff;
    background: linear-gradient(135deg, #064fa2, #07396f 70%, #052b55);
}

.campaign-popup-kicker {
    display: block;
    margin-bottom: 2px;
    color: #8ee99e;
    font-size: 10px;
    font-weight: 900;
    letter-spacing: .12em;
    text-transform: uppercase;
}

.campaign-popup-head h2 {
    margin: 0;
    color: #fff;
    font-size: clamp(17px, 2.1vw, 22px);
    line-height: 1.15;
    letter-spacing: -.025em;
}

.campaign-popup-close {
    flex: 0 0 auto;
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    border: 1px solid rgba(255,255,255,.42);
    border-radius: 50%;
    color: #fff;
    background: rgba(255,255,255,.12);
    font-size: 27px;
    line-height: 1;
    cursor: pointer;
    transition: background .2s ease, transform .2s ease;
}

.campaign-popup-close:hover {
    background: rgba(255,255,255,.22);
    transform: rotate(6deg);
}

.campaign-popup-media {
    position: relative;
    min-height: 0;
    display: grid;
    place-items: center;
    overflow: hidden;
    background:
        linear-gradient(135deg, rgba(7,57,111,.08), rgba(59,174,87,.08)),
        #f5f8fb;
}

.campaign-popup-media picture {
    width: 100%;
    min-height: 0;
    display: grid;
    place-items: center;
}

.campaign-popup-media img {
    width: 100%;
    height: auto;
    max-height: calc(100svh - 178px);
    display: block;
    object-fit: contain;
    object-position: center;
    background: #fff;
}

.campaign-popup-media-hint {
    position: absolute;
    right: 14px;
    bottom: 13px;
    min-height: 31px;
    display: inline-flex;
    align-items: center;
    padding: 0 12px;
    border: 1px solid rgba(255,255,255,.58);
    border-radius: 999px;
    color: #fff;
    background: rgba(3, 41, 80, .76);
    box-shadow: 0 8px 24px rgba(0,0,0,.18);
    backdrop-filter: blur(8px);
    font-size: 11px;
    font-weight: 800;
    pointer-events: none;
}

.campaign-popup-actions {
    min-height: 68px;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
    padding: 11px 15px;
    border-top: 1px solid #e3ebf3;
    background: #fff;
}

.campaign-popup-secondary,
.campaign-popup-primary {
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    padding: 0 18px;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 900;
    cursor: pointer;
}

.campaign-popup-secondary {
    border: 1px solid #cad9e8;
    color: #52677e;
    background: #fff;
}

.campaign-popup-primary {
    border: 1px solid #159744;
    color: #fff;
    background: linear-gradient(135deg, #25b95d, #168f45);
    box-shadow: 0 10px 24px rgba(24, 151, 70, .23);
    transition: transform .2s ease, box-shadow .2s ease;
}

.campaign-popup-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 28px rgba(24, 151, 70, .3);
}

.campaign-popup-primary .social-svg,
.campaign-popup-primary svg {
    width: 19px;
    height: 19px;
    fill: none;
    stroke: currentColor;
}

@media (max-width: 640px) {
    .campaign-popup {
        padding: 10px;
        align-items: center;
    }

    .campaign-popup-card {
        width: min(100%, 470px);
        max-height: calc(100svh - 20px);
        border-radius: 20px;
    }

    .campaign-popup-head {
        min-height: 61px;
        padding: 11px 11px 10px 16px;
    }

    .campaign-popup-close {
        width: 38px;
        height: 38px;
    }

    .campaign-popup-media img {
        max-height: calc(100svh - 155px);
    }

    .campaign-popup-media-hint {
        display: none;
    }

    .campaign-popup-actions {
        min-height: 64px;
        padding: 9px;
    }

    .campaign-popup-secondary,
    .campaign-popup-primary {
        min-height: 44px;
        padding-inline: 13px;
    }

    .campaign-popup-primary {
        flex: 1;
    }
}

@media (max-width: 380px), (max-height: 650px) {
    .campaign-popup-head {
        display: none;
    }

    .campaign-popup-card {
        max-height: calc(100svh - 14px);
    }

    .campaign-popup-media img {
        max-height: calc(100svh - 72px);
    }

    .campaign-popup-close {
        position: absolute;
        z-index: 4;
        top: 9px;
        right: 9px;
        color: #07396f;
        border-color: rgba(7,57,111,.18);
        background: rgba(255,255,255,.92);
        box-shadow: 0 8px 20px rgba(0,0,0,.15);
    }
}

@media (prefers-reduced-motion: reduce) {
    .campaign-popup,
    .campaign-popup-card,
    .campaign-popup-close,
    .campaign-popup-primary {
        transition: none !important;
    }
}
