/* 灯箱基础样式 */
.lightbox-image {
    cursor: pointer;
    transition: opacity 0.3s ease;
}

.lightbox-image:hover {
    opacity: 0.9;
}

/* 灯箱遮罩层 */
.lightbox-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

/* 灯箱内容容器 */
.lightbox-content {
    position: relative;
    max-width: 90%;
    max-height: 90%;
}

/* 灯箱图片 */
.lightbox-img {
    max-width: 100%;
    max-height: 80vh;
    object-fit: contain;
    border-radius: 4px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

/* 关闭按钮 */
.lightbox-close {
    position: absolute;
    top: -40px;
    right: 0;
    color: white;
    font-size: 30px;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.3s ease;
    background: none;
    border: none;
    outline: none;
}

.lightbox-close:hover {
    color: #ccc;
}

/* 上一张/下一张按钮 */
.lightbox-prev,
.lightbox-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    color: white;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.3s ease;
    background: none;
    border: none;
    outline: none;
    padding: 10px 15px;
    z-index: 10;
}

.lightbox-prev {
    left: -50px;
}

.lightbox-next {
    right: -50px;
}

.lightbox-prev:hover,
.lightbox-next:hover {
    color: #ccc;
}

/* 图片计数器 */
.lightbox-counter {
    position: absolute;
    bottom: -30px;
    left: 0;
    color: white;
    font-size: 14px;
}

/* 动画效果 */
@keyframes lightboxFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.lightbox-overlay.active {
    display: flex;
    animation: lightboxFadeIn 0.3s ease;
}

/* 响应式设计 */
@media screen and (max-width: 768px) {
    .lightbox-prev {
        left: 10px;
    }
    
    .lightbox-next {
        right: 10px;
    }
    
    .lightbox-close {
        top: 10px;
        right: 10px;
    }
    
    .lightbox-counter {
        bottom: 10px;
        left: 10px;
    }
}