﻿/* =========================
   Popup + blur (blur ONLY page content, not popup)
   ========================= */

.cn-popBlur .cn-shell {
    filter: blur(4px);
    transform: scale(.995);
    transition: filter .25s ease, transform .25s ease;
}

/* Keep popup crisp */
.cn-pop {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: none;
}

    .cn-pop.is-open {
        display: block;
    }

.cn-pop__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,.38);
    backdrop-filter: blur(2px);
}

/* Fun entrance animation */
@keyframes cnPopIn {
    0% {
        opacity: 0;
        transform: translate(-50%, -46%) scale(.88) rotate(-1deg);
    }

    60% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1.03) rotate(.6deg);
    }

    100% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1) rotate(0deg);
    }
}

.cn-pop__panel {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: min(520px, calc(100% - 28px));
    border-radius: 20px;
    padding: 18px 16px 14px;
    background: radial-gradient(circle at 20% 0%, rgba(243,178,51,.25), transparent 55%), radial-gradient(circle at 100% 30%, rgba(149,31,31,.10), transparent 52%), #fff;
    border: 1px solid rgba(149,31,31,.18);
    box-shadow: 0 30px 90px rgba(0,0,0,.22);
    color: #951f1f;
    animation: cnPopIn .38s cubic-bezier(.2,.9,.25,1.2);
}

/* Professional black X */
.cn-pop__close {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 38px;
    height: 38px;
    border-radius: 12px;
    border: 1px solid rgba(0,0,0,.12);
    background: rgba(255,255,255,.9);
    cursor: pointer;
    color: #111;
    font-weight: 900;
    display: grid;
    place-items: center;
}

    .cn-pop__close:hover {
        background: #fff;
    }

/* Cute emoji badge */
.cn-pop__emoji {
    width: 44px;
    height: 44px;
    border-radius: 14px;
    display: grid;
    place-items: center;
    border: 1px solid rgba(149,31,31,.14);
    background: rgba(149,31,31,.03);
    margin: 2px 0 10px 4px;
    font-size: 22px;
}

.cn-pop__title {
    font-weight: 950;
    font-size: 18px;
    margin: 0 46px 8px 4px;
}

.cn-pop__body {
    opacity: .9;
    font-weight: 750;
    line-height: 1.5;
    margin: 0 4px 14px;
}

/* CTA */
.cn-pop__actions {
    display: flex;
    justify-content: flex-end;
    padding: 0 2px;
}

.cn-pop__cta {
    text-decoration: none;
    border-radius: 12px;
    padding: 10px 14px;
    background: #951f1f;
    color: #fff;
    font-weight: 950;
    border: 1px solid rgba(149,31,31,.18);
}

    .cn-pop__cta:hover {
        filter: brightness(.95);
    }

@media (max-width: 520px) {
    .cn-pop__panel {
        border-radius: 18px;
    }
}

/* Respect reduced motion */
@media (prefers-reduced-motion: reduce) {
    .cn-pop__panel {
        animation: none;
    }

    .cn-popBlur .cn-shell {
        transition: none;
    }
}
