/* Base Popup Styles */
.popup {
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100vh;
    background: rgba(255, 255, 255, 0.041);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999999;
}

/* Box Container */
.popup-box {
    position: relative;
    /* width: min(600px, 92vw);*/
    background: rgba(255, 255, 255, 0.582);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.308);
    overflow: hidden;
    padding: 5px;
    text-align: center;
}

/* Close Button */
.popup-close {
    position: absolute;
    top: 15px;
    right: 15px;
    cursor: pointer;
    font-weight: bold;
    font-size: 24px;
    color: #f7f7f7;
    z-index: 2;
    width: 55px;
    height: 40px;
    background: rgb(255 143 0 / 97%);
    border: none;
    border-radius: 10px 100px / 120px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}
.popup-close:hover {
    transform: translateY(-2px);
    background: rgba(0, 0, 0, 0.5);
}

/* Content Layout (tek-tek, no gaps if section missing) */
.popup-content {
    display: flex;
    flex-direction: column;
    gap: 14px; /* spacing only between existing blocks */
    align-items: center;
}

/* Image Area: min + max size, no stretch */
.popup-img-area {
    width: 100%;
    display: flex;
    justify-content: center;
}
.popup-img-area img {
    border-radius: 10px;

    /* enforce min + max image size */
    width: auto;
    height: auto;
    max-width: 100%;
    max-height: 500px;   /* max */
    min-height: 300px;   /* min */

    /* keep image nice without distortion */
    object-fit: contain; /* show full image */
    display: block;
}

/* Text Area */
.popup-text-area {
    width: 100%;
    padding: 0 10px;
    text-align: center;
}
.popup-text-area h2 {
    font-size: 24px;
    color: #7b5000;
    margin: 0 0 10px 0;
}
.popup-text {
    font-size: 16px;
    color: #555;
    margin: 0 0 14px 0;
}

/* Link reset (button only if URL exists) */
.popup-link {
    display: inline-block;
    text-decoration: none;
}

/* Button */
.cta-button {
    padding: 12px 30px;
    background: #242424;
    color: white;
    border: none;
    border-radius: 25px;
    cursor: pointer;
    font-size: 16px;
    transition: all 0.3s ease;
    width: fit-content;
}
.cta-button:hover {
    background: #2e89ad;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

/* Responsive */
@media (max-width: 768px) {
    .popup-text-area h2 { font-size: 20px; }
    .popup-text { font-size: 14px; }
    .popup-img-area img {
        max-height: 400px;
        min-height: 100px;
    }
}
