/* Popup d'image pour les produits */
.image-popup {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    cursor: pointer;
    padding: 20px;
    box-sizing: border-box;
}

.image-popup.active {
    display: flex;
}

.image-popup-content {
    position: relative;
    max-width: 95%;
    max-height: 95%;
    width: auto;
    height: auto;
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: popupFadeIn 0.3s ease-out;
}

.image-popup-content img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
    max-height: 80vh;
}

.image-popup-close {
    position: absolute;
    top: 15px;
    right: 15px;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.9);
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: #333;
    transition: all 0.3s ease;
    z-index: 1;
}

.image-popup-close:hover {
    background: white;
    transform: scale(1.1);
}

.image-popup-info {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.8), transparent);
    color: white;
    padding: 20px;
    text-align: center;
}

.image-popup-title {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 5px;
    font-family: 'Playfair Display', serif;
}

.image-popup-category {
    font-size: 14px;
    opacity: 0.9;
    font-family: 'Lato', sans-serif;
}

@keyframes popupFadeIn {
    from {
        opacity: 0;
        transform: scale(0.8);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* Responsive design */
@media (max-width: 768px) {
    .image-popup {
        padding: 10px;
    }
    
    .image-popup-content {
        max-width: 98%;
        max-height: 98%;
        border-radius: 10px;
    }
    
    .image-popup-content img {
        max-height: 70vh;
    }
    
    .image-popup-close {
        width: 35px;
        height: 35px;
        top: 10px;
        right: 10px;
        font-size: 16px;
    }
    
    .image-popup-info {
        padding: 15px;
    }
    
    .image-popup-title {
        font-size: 16px;
    }
    
    .image-popup-category {
        font-size: 12px;
    }
}

@media (max-width: 480px) {
    .image-popup {
        padding: 5px;
    }
    
    .image-popup-content {
        max-width: 100%;
        max-height: 100%;
        border-radius: 8px;
    }
    
    .image-popup-content img {
        max-height: 65vh;
    }
    
    .image-popup-close {
        width: 30px;
        height: 30px;
        top: 8px;
        right: 8px;
        font-size: 14px;
    }
    
    .image-popup-info {
        padding: 10px;
    }
    
    .image-popup-title {
        font-size: 14px;
        margin-bottom: 3px;
    }
    
    .image-popup-category {
        font-size: 11px;
    }
}

/* Effet de zoom sur les images des produits */
.product-image {
    position: relative;
    overflow: hidden;
    cursor: pointer;
}

.product-image::before {
    content: '🔍';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 30px;
    color: white;
    background: rgba(0, 0, 0, 0.7);
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: all 0.3s ease;
    z-index: 2;
}

/* Masquer la loupe de zoom */
.product-image::before {
    display: none;
}

.product-image:hover img {
    transform: scale(1.1);
    transition: transform 0.3s ease;
}

.product-image img {
    transition: transform 0.3s ease;
}
