
/* ===== Overlay (Background Mask) ===== */
#mask {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    z-index: 1000;
    display: none;
}

/* ===== Modal Wrapper ===== */
#boxes .window {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    
    z-index: 1001;
    background: #fff;
    border-radius: 15px;
    padding: 20px;
    text-align: center;

    width: 95%;          /* mobile full width */
    max-width: 1000px;   /* desktop large size */

    max-height: 90vh;    /* scroll control */
    overflow-y: auto;

    box-shadow: 0 10px 40px rgba(0,0,0,0.3);
}

/* ===== Dialog Box ===== */
#boxes #dialog {
    width: 100%;
    height: auto;
    font-family: 'Segoe UI', sans-serif;
}

/* ===== Close Button ===== */
.close-btn {
    position: absolute;
    top: 10px;
    right: 15px;
    font-size: 28px;
    font-weight: bold;
    color: #333;
    cursor: pointer;
}

.close-btn:hover {
    color: red;
}

/* ===== Content ===== */
.modal-cs h6 {
    margin-bottom: 20px;
    font-size: 32px;
    text-align: center;
}

#lorem {

    text-align: left;
}

/* ===== Images Responsive ===== */
.modal-cs img {
    width: 100%;
    height: auto;
    font-size:32px;
    border-radius: 10px;
}

/* ===== Tablet ===== */
@media (max-width: 768px) {
    #boxes .window {
        width: 95%;
        padding: 15px;
    }

    .modal-cs h6 {
        font-size: 22px;
    }
}

/* ===== Mobile ===== */
@media (max-width: 480px) {
    #boxes .window {
        width: 95%;
        padding: 10px;
        border-radius: 10px;
    }

    .modal-cs h6 {
        font-size: 16px;
    }

    #lorem {
        font-size: 13px;
    }

    .close-btn {
        font-size: 24px;
        top: 5px;
        right: 10px;
    }
}