/* =========================================
   MARRYCENE PROMO POPUP
========================================= */

#imageModal {
    padding-right: 0 !important;
}

/* Kotak popup */
#imageModal .promo-modal-dialog {
    width: auto;
    max-width: 620px;

    margin: 1.5rem auto;
    padding: 0 15px;
}

/* Isi popup */
#imageModal .promo-modal-content {
    position: relative;
    isolation: isolate;

    background: #ffffff;

    border: none;
    border-radius: 16px;

    overflow: visible;

    box-shadow:
        0 20px 60px rgba(0, 0, 0, 0.25);
}

/* Area gambar */
#imageModal .promo-modal-body {
    position: relative;
    z-index: 1;

    padding: 28px;

    text-align: center;
}

/* Gambar promo */
#imageModal .promo-image {
    display: block;

    width: 100%;
    max-width: 470px;

    height: auto;
    max-height: 78vh;

    margin: 0 auto;

    object-fit: contain;

    /*
     * Gambar tidak menangkap klik/tap.
     * Jadi tombol X lebih mudah ditekan.
     */
    pointer-events: none;

    user-select: none;
    -webkit-user-select: none;
    -webkit-user-drag: none;
}


/* =========================================
   TOMBOL CLOSE
========================================= */

#imageModal .promo-close {
    position: absolute;

    top: 10px;
    right: 10px;

    width: 48px;
    height: 48px;

    display: flex;
    align-items: center;
    justify-content: center;

    /* Pastikan selalu di atas gambar */
    z-index: 20000;

    padding: 0;

    border: none;
    border-radius: 50%;

    background: rgba(255, 255, 255, 0.96);

    color: #555;

    box-shadow:
        0 3px 12px rgba(0, 0, 0, 0.16);

    font-size: 30px;
    font-weight: 400;
    line-height: 1;

    cursor: pointer;

    pointer-events: auto !important;
    touch-action: manipulation;

    user-select: none;
    -webkit-user-select: none;
    -webkit-tap-highlight-color: transparent;

    transition:
        background 0.2s ease,
        color 0.2s ease,
        transform 0.2s ease,
        box-shadow 0.2s ease;
}


/* Simbol X */
#imageModal .promo-close span {
    display: block;

    line-height: 1;

    pointer-events: none;
}


/* Hover desktop */
#imageModal .promo-close:hover {
    background: #f5f5f5;

    color: #111;

    transform: scale(1.05);

    box-shadow:
        0 4px 14px rgba(0, 0, 0, 0.2);
}


/* Focus */
#imageModal .promo-close:focus {
    background: #ffffff;

    color: #111;

    outline: none;
}


/* Saat ditekan */
#imageModal .promo-close:active {
    transform: scale(0.96);
}


/* =========================================
   BACKDROP
========================================= */

.modal-backdrop.show {
    opacity: 0.7;
}


/* =========================================
   MOBILE
========================================= */

@media (max-width: 600px) {

    #imageModal .promo-modal-dialog {
        width: 100%;
        max-width: none;

        margin: 0 auto;

        padding: 12px;
    }


    #imageModal .promo-modal-content {
        border-radius: 14px;
    }


    #imageModal .promo-modal-body {
        padding:
            18px
            10px
            12px;
    }


    #imageModal .promo-image {
        width: 100%;
        max-width: 100%;

        max-height: 82vh;
    }


    /*
     * Bulatan tetap terlihat normal,
     * tapi area sentuh diperbesar.
     */
    #imageModal .promo-close {
        top: 4px;
        right: 4px;

        width: 56px;
        height: 56px;

        z-index: 20000;

        font-size: 32px;

        pointer-events: auto !important;
        touch-action: manipulation;
    }
}


/* =========================================
   HP KECIL
========================================= */

@media (max-width: 380px) {

    #imageModal .promo-modal-dialog {
        padding: 8px;
    }


    #imageModal .promo-modal-body {
        padding:
            16px
            7px
            10px;
    }


    #imageModal .promo-close {
        top: 3px;
        right: 3px;

        width: 54px;
        height: 54px;

        font-size: 31px;
    }
}