/**
 * Simple Vanilla JavaScript Lightbox Styles
 */

.simple-lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.simple-lightbox--active {
    opacity: 1;
}

.simple-lightbox__overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    cursor: pointer;
}

.simple-lightbox__content {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 60px 20px 100px;
    box-sizing: border-box;
}

.simple-lightbox__close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: rgba(255, 255, 255, 0.9);
    border: none;
    border-radius: 50%;
    width: 48px;
    height: 48px;
    font-size: 32px;
    line-height: 1;
    color: #333;
    cursor: pointer;
    z-index: 10001;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.simple-lightbox__close:hover {
    background: #f44336;
    color: white;
    transform: scale(1.1);
}

.simple-lightbox__prev,
.simple-lightbox__next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.9);
    border: none;
    border-radius: 4px;
    width: 48px;
    height: 64px;
    font-size: 48px;
    line-height: 1;
    color: #333;
    cursor: pointer;
    z-index: 10001;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.simple-lightbox__prev {
    left: 20px;
}

.simple-lightbox__next {
    right: 20px;
}

.simple-lightbox__prev:hover,
.simple-lightbox__next:hover {
    background: white;
    transform: translateY(-50%) scale(1.1);
}

.simple-lightbox__image-wrap {
    position: relative;
    max-width: 90%;
    max-height: 80vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.simple-lightbox__image {
    max-width: 100%;
    max-height: 80vh;
    height: auto;
    width: auto;
    display: block;
    border-radius: 4px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
    transition: opacity 0.3s ease;
}

.simple-lightbox__loader {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 48px;
    height: 48px;
    border: 4px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    display: none;
}

@keyframes spin {
    to {
        transform: translate(-50%, -50%) rotate(360deg);
    }
}

.simple-lightbox__caption {
    position: absolute;
    bottom: 60px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 12px 24px;
    border-radius: 4px;
    font-size: 16px;
    max-width: 80%;
    text-align: center;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.simple-lightbox__counter {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(255, 255, 255, 0.9);
    color: #333;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

/* Responsive Styles */
@media (max-width: 768px) {
    .simple-lightbox__content {
        padding: 80px 10px 120px;
    }
    
    .simple-lightbox__close {
        top: 10px;
        right: 10px;
        width: 40px;
        height: 40px;
        font-size: 28px;
    }
    
    .simple-lightbox__prev,
    .simple-lightbox__next {
        width: 40px;
        height: 56px;
        font-size: 40px;
    }
    
    .simple-lightbox__prev {
        left: 10px;
    }
    
    .simple-lightbox__next {
        right: 10px;
    }
    
    .simple-lightbox__image-wrap {
        max-width: 95%;
    }
    
    .simple-lightbox__caption {
        bottom: 70px;
        font-size: 14px;
        padding: 10px 16px;
        max-width: 90%;
    }
    
    .simple-lightbox__counter {
        bottom: 30px;
        font-size: 12px;
        padding: 6px 12px;
    }
}

/* Prevent body scroll when lightbox is open */
body.simple-lightbox-open {
    overflow: hidden;
}
