/* === IMAGE LIGHTBOX === */

.iai-image-lightbox {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 10001;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s ease-out;
}

.iai-image-lightbox.hidden {
    display: none;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* Overlay */
.iai-lightbox-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(10px);
}

/* Content */
.iai-lightbox-content {
    position: relative;
    z-index: 1;
    max-width: 90vw;
    max-height: 90vh;
    display: flex;
    align-items: center;
    gap: 24px;
}

/* Image */
.iai-lightbox-image {
    max-width: 100%;
    max-height: calc(90vh - 100px);
    object-fit: contain;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    animation: zoomIn 0.3s ease-out;
}

@keyframes zoomIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* Close button */
.iai-lightbox-close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 48px;
    height: 48px;
    border: none;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 50%;
    font-size: 32px;
    color: white;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    z-index: 2;
}

.iai-lightbox-close:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: rotate(90deg);
}

/* Actions */
.iai-lightbox-actions {
    display: flex;
    gap: 16px;
    padding: 16px 24px;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 16px;
}

.iai-lightbox-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    border: none;
    border-radius: 10px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.iai-lightbox-btn svg {
    flex-shrink: 0;
}

.iai-lightbox-download {
    background: linear-gradient(135deg, #4CAF50 0%, #66BB6A 100%);
    color: white;
}

.iai-lightbox-download:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(76, 175, 80, 0.4);
}

.iai-lightbox-delete {
    background: linear-gradient(135deg, #f44336 0%, #e57373 100%);
    color: white;
}

.iai-lightbox-delete:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(244, 67, 54, 0.4);
}

/* Responsive */
@media (max-width: 768px) {
    .iai-lightbox-content {
        max-width: 95vw;
        max-height: 95vh;
    }
    
    .iai-lightbox-image {
        max-height: calc(95vh - 120px);
    }
    
    .iai-lightbox-actions {
        flex-direction: column;
        width: 100%;
        gap: 12px;
    }
    
    .iai-lightbox-btn {
        width: 100%;
        justify-content: center;
    }
    
    .iai-lightbox-close {
        top: 10px;
        right: 10px;
        width: 40px;
        height: 40px;
        font-size: 28px;
    }
}

/* Hover effect sur les images du moodboard */
.iai-moodboard-item {
    position: relative;
    cursor: pointer;
    transition: all 0.3s;
}

.iai-moodboard-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
}

.iai-moodboard-item::after {
    content: '🔍';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 48px;
    opacity: 0;
    transition: opacity 0.3s;
    pointer-events: none;
}

.iai-moodboard-item:hover::after {
    opacity: 0.8;
}
