.popup {
    width: 100%;
    height: 100%;
    position: fixed;
    background: rgba(0, 0, 0, 0.5);
    top: 0;
    left: 0;
    pointer-events: none;
    opacity: 0;
    z-index: -100;
    transition: all 0.2s linear;
}

.popup.active {
    pointer-events: auto;
    opacity: 1;
    z-index: 10;
}

:root {
    --box-color: #c6efce;
    --box-font-color: #006100;
}

/* Popup content container */
.content {
    width: 80%;              /* shrink to fit smaller screens */
    max-width: 528px;        /* keep original max size */
    height: auto;            /* let height adjust */
    max-height: 90vh;        /* prevent overflow vertically */
    background-color: #f5f5f5;
    border-radius: 6px;
    overflow: hidden;

    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.content i {
    position: absolute;
    right: 2%;
    top: 2%;
    padding: 5px 8px;
    cursor: pointer;
    color: var(--box-font-color);
    z-index: 20;
}

/* Image inside popup */
.core-content img {
    width: 100%;
    height: 100%;
    object-fit: contain; /* maintain original ratio */
}


/* Close button inside content */
.pop-close-Btn {
    position: absolute;
    top: 10px;               /* fixed pixel spacing works better */
    right: 10px;
    padding: 8px 12px;
    background-color: #fff;
    cursor: pointer;
    box-shadow: -1px 0px 16px 4px rgba(0,0,0,0.45);
    border-radius: 4px;
    z-index: 20;
}


.pop-close-Btn.hide {
    display: none;
}

.pop-close-Btn i {
    font-size: 20px;
    color: #000;
}
