.custom-popup-container {
    display: none; /* hidden by default */
    position: fixed;
    left: 50%;
    background: #fff;
    z-index: 9999;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 5px 30px rgba(0,0,0,0.5);
    width: 90vw;
    max-width: 600px;
    max-height: 90vh;       /* limit height to viewport */
    overflow-y: auto;       /* scroll if content is taller */
    box-sizing: border-box;
}

/* Popup header and close button */
.custom-popup-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}
.custom-popup-close {
    cursor: pointer;
    font-size: 22px;
    font-weight: bold;
}

/* Overlay */
#custom-popup-overlay {
    display: none;
    position: fixed;
    top: 0; left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    z-index: 9998;
}
.custom-popup-btn {
    display: inline-block;
    background: #0073e6; /* default */
    color: #fff;
    border: none;
    border-radius: 5px;
    padding: 10px 20px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.custom-popup-btn:hover {
    opacity: 0.9;
}


/* Animations */
.custom-popup-container.fade { opacity:0; transition: opacity 0.3s ease;}
.custom-popup-container.fade.show { opacity:1; }
.custom-popup-container.slide { transform: translateY(-20px); transition: all 0.3s ease;}
.custom-popup-container.slide.show { transform: translateY(0);}
.custom-popup-container.zoom { transform: scale(0); transition: all 0.3s ease;}
.custom-popup-container.zoom.show { transform: scale(1); }

/* Mobile */
@media (max-width:768px){
    .custom-popup-container {
        width: 90% !important;
        max-height: 80vh !important;
        overflow-y: auto;
    }
}
