.lightbox {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    z-index: 9999;
    backdrop-filter: blur(20px);
    justify-content: center;
    align-items: center;
}

.lightbox img {
    max-width: 80%;
    max-height: 80%;
    margin: 0 auto;
    display: block;
    pointer-events: none; 
    transition: filter 0.3s ease;
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
}

.lightbox-image:active {
    filter: brightness(0%);
}

.close {
    position: absolute;
    top: 20px;
    right: 20px;
    font-size: 70px;
    color: #fff;
    cursor: pointer;
    transition: 0.5s;
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
}

@media (max-width: 768px) {
    .close {
        font-size: 50px;
        top: 10px;
        right: 10px;
    }
}

.close:hover, .close:focus {
    transform: rotate(180deg);
    text-decoration: none;
    cursor: pointer;
}

.no-scroll {
    overflow: hidden;
}


/* New Lightbox */

.new-lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(10px);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    box-sizing: border-box;
    opacity: 0;
    animation: fadeIn 0.3s forwards;
}

@keyframes fadeIn {
    to { opacity: 1; }
}

.new-lightbox-content {
    position: relative;
    max-width: 90%;
    max-height: 90%;
    background: white;
    border-radius: 15px;
    padding: 10px;
    box-shadow: 0 5px 25px rgba(0, 0, 0, 0.5);
}

.new-lightbox-image {
    max-width: 100%;
    max-height: 70vh;
    display: block;
    margin: 0 auto;
    border-radius: 10px;
}

.new-lightbox-close {
    position: absolute;
    top: -15px;
    right: -15px;
    color: white;
    font-size: 30px;
    font-weight: bold;
    cursor: pointer;
    background: #000;
    width: 40px;
    height: 38px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid white;
    transition: all 0.3s ease;
    padding-top: 2px;
}

.new-lightbox-close:hover {
    background: white;
    color: black;
}

.new-lightbox-caption {
    color: black;
    text-align: center;
    padding: 15px 0 5px 0;
    font-size: 16px;
}

.no-scroll {
    overflow: hidden;
}

@media (max-width: 768px) {
    .new-lightbox-image {
        max-height: 60vh;
    }
    
    .new-lightbox-close {
        top: -10px;
        right: -10px;
        font-size: 25px;
        width: 35px;
        height: 35px;
    }
    
    .new-lightbox-caption {
        font-size: 14px;
        padding: 10px 0 0;
    }
}