/* Styles pour les médias des produits */

/* Styles pour les cartes de produits avec images */
.product-card {
    display: flex;
    flex-direction: column;
}

.product-image {
    position: relative;
    overflow: hidden;
    border-radius: 8px;
    margin-bottom: 1rem;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    height: 200px;
}

.product-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: all 0.4s ease;
}

.product-card:hover .product-img {
    transform: scale(1.08);
}

.product-photo {
    width: 100%;
    height: auto;
    border-radius: 8px;
    transition: all 0.4s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    border: 2px solid transparent;
}

.product-card:hover .product-photo {
    transform: scale(1.1);
    box-shadow: 0 12px 30px rgba(212, 175, 55, 0.5);
    border: 2px solid #d4af37;
}

.product-icon {
    position: relative;
    overflow: hidden;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.product-icon::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, rgba(212, 175, 55, 0.4), transparent);
    opacity: 0;
    transition: opacity 0.4s ease;
}

.product-card:hover .product-icon::after {
    opacity: 1;
}

@keyframes pulse-gold {
    0% { box-shadow: 0 0 0 0 rgba(212, 175, 55, 0.4); }
    70% { box-shadow: 0 0 0 10px rgba(212, 175, 55, 0); }
    100% { box-shadow: 0 0 0 0 rgba(212, 175, 55, 0); }
}

.product-card:hover .product-image {
    animation: pulse-gold 1.5s infinite;
}

.product-card {
    transition: all 0.3s ease;
    margin-bottom: 30px;
    position: relative;
    transform: translateY(0);
}

.product-card:hover {
    transform: translateY(-10px);
}

.product-card::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 3px;
    background: linear-gradient(90deg, transparent, #d4af37, transparent);
    transition: width 0.4s ease;
}

.product-card:hover::after {
    width: 100%;
    box-shadow: 0 0 10px rgba(212, 175, 55, 0.7);
}

.fallback-img {
    padding: 2rem;
    background-color: var(--bg-secondary);
}

/* Bouton "Voir plus d'images" */
.view-more-btn {
    display: inline-block;
    margin-top: 0.75rem;
    padding: 0.5rem 1rem;
    background-color: var(--primary-color);
    color: white;
    text-decoration: none;
    border-radius: 4px;
    font-size: 0.875rem;
    font-weight: 500;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
}

.view-more-btn:hover {
    background-color: var(--primary-hover);
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(212, 175, 55, 0.3);
}

/* Styles pour les vidéos */
.video-container {
    margin: 2rem auto;
    max-width: 800px;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

.product-video {
    width: 100%;
    display: block;
}

.video-caption {
    text-align: center;
    margin-top: 1rem;
    font-style: italic;
    color: var(--text-secondary);
}

/* Galerie d'images */
.product-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1rem;
    margin: 2rem 0;
}

.gallery-item {
    border-radius: 6px;
    overflow: hidden;
    height: 200px;
    cursor: pointer;
}

.gallery-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.gallery-img:hover {
    transform: scale(1.05);
}

/* Modal pour les galeries d'images */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    z-index: 1000;
    overflow: auto;
}

.modal-content {
    position: relative;
    margin: 5% auto;
    padding: 20px;
    width: 80%;
    max-width: 900px;
    background-color: var(--bg-primary);
    border-radius: 8px;
}

/* Bouton de fermeture des modales */
.close {
    position: absolute;
    top: 15px;
    right: 25px;
    font-size: 28px;
    font-weight: bold;
    color: var(--text-secondary);
    cursor: pointer;
    background: none;
    border: none;
    padding: 0;
    line-height: 1;
    transition: color 0.3s ease;
}

.close:hover,
.close:focus {
    color: var(--primary-color);
    text-decoration: none;
}

.modal-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1rem;
    margin-top: 2rem;
    padding: 0 1rem;
}

.modal-gallery img {
    width: 100%;
    height: 150px;
    object-fit: cover;
    border-radius: 6px;
    transition: transform 0.3s ease;
    cursor: pointer;
}

.modal-gallery img:hover {
    transform: scale(1.02);
}

.modal-gallery svg {
    width: 100%;
    height: 150px;
    border-radius: 6px;
}

/* Section vidéo */
.video-section {
    padding: 3rem 0;
    background: var(--bg-secondary);
}

/* Responsive */
@media (max-width: 768px) {
    .product-image {
        height: 180px;
    }
    
    .video-container {
        margin: 1.5rem auto;
    }
    
    .modal-content {
        width: 95%;
        margin: 10% auto;
        padding: 15px;
    }
    
    .modal-gallery {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
        padding: 0 0.5rem;
        margin-top: 1.5rem;
    }
    
    .modal-gallery img,
    .modal-gallery svg {
        height: 120px;
    }
    
    .view-more-btn {
        font-size: 0.8rem;
        padding: 0.4rem 0.8rem;
        margin-top: 0.5rem;
    }
    
    .close {
        top: 10px;
        right: 15px;
        font-size: 24px;
    }
}