/* Modal Collection Details */
.collection-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    animation: fadeIn 0.3s ease;
}

.collection-modal-overlay.active {
    display: flex;
}

.collection-modal-container {
    background: white;
    border-radius: 16px;
    width: 80%;
    max-width: 1200px;
    max-height: 90vh;
    overflow-y: auto;
    overflow-x: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
    animation: slideUp 0.3s ease;
    box-sizing: border-box;
}

.collection-modal-header {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 24px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.collection-modal-title {
    color: white;
    font-size: 20px;
    font-weight: 600;
}

.collection-modal-close-btn {
    background: rgba(255, 255, 255, 0.5);
    border: 1px solid white;
    border-radius: 8px;
    padding: 6px 12px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    color: white;
    font-weight: 500;
    transition: all 0.3s ease;
}

.collection-modal-close-btn:hover {
    background: rgba(255, 255, 255, 0.7);
}

.collection-modal-body {
    width: 100%;
    display: flex;
    gap: 16px;
    padding: 16px;
    box-sizing: border-box;
}

/* Réinitialiser les styles globaux qui peuvent interférer */
.collection-modal-overlay *,
.collection-modal-overlay *::before,
.collection-modal-overlay *::after {
    box-sizing: border-box;
}

.collection-modal-images-card {
    width: 40%;
    display: flex;
    flex-direction: column;
    gap: 2px;
    box-sizing: border-box;
    flex-shrink: 0;
}

.collection-modal-hero-image {
    width: 100%;
    aspect-ratio: 1.1;
    border-radius: 12px;
    overflow: hidden;
    position: relative;
    background: #f5f5f5;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    box-sizing: border-box;
}

.collection-modal-hero-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    max-width: 100%;
}

/* Badge personnaliser flottant */
.custom-badge-float {
    position: absolute;
    top: 12px;
    left: 12px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background-color: white;
    color: #7c3aed;
    padding: 8px 14px;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 600;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    z-index: 10;
    animation: fadeInOutLoop 5s ease-in-out infinite;
    cursor: pointer;
    transition: transform 0.2s ease;
}

.custom-badge-float:hover {
    transform: scale(1.05);
}

/* Badge rating flottant */
.rating-badge-float-one {
    position: absolute;
    top: 12px;
    right: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    background-color: rgba(245, 158, 11, 0.5);
    color: #f59e0b;
    padding: 2px 4px;
    border: 1px solid #f59e0b;
    border-radius: 12px;
    font-size: 13px;
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    z-index: 10;
    backdrop-filter: blur(4px);
}

.rating-value-one {
    font-weight: 700;
}

.reviews-count-one {
    font-size: 11px;
    font-weight: 500;
    opacity: 0.9;
}

@keyframes fadeInOutLoop {
    0% {
        opacity: 1;
    }
    45% {
        opacity: 1;
    }
    50% {
        opacity: 0;
    }
    95% {
        opacity: 0;
    }
    100% {
        opacity: 1;
    }
}

.collection-modal-thumbnails {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding: 8px 0;
}

.collection-modal-thumbnail {
    width: 80px;
    aspect-ratio: 1.1;
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
    box-sizing: border-box;
    border: 3px solid transparent;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.collection-modal-thumbnail.active {
    border-color: #764ba2;
}

.collection-modal-thumbnail:hover {
    border-color: #667eea;
}

.collection-modal-thumbnail img {
    width: 100%;
    height: 100%;
    display: block;
    max-width: 100%;
    object-fit: cover;
}

.collection-modal-info-card {
    width: 60%;
    display: flex;
    flex-direction: column;
    box-sizing: border-box;
    gap: 12px;
}

#gender-badge-placeholder-one {
    display: inline-flex;
    align-items: center;
    background-color: blueviolet;
    padding: 1px 2px;
    border-radius: 8px;
}

/* Bloc prix infos */
.collection-price-row-infos-one {
	display: flex;
	flex-direction: row;
	align-items: flex-start;
	gap: 4px;
	/* margin: 6px 0 0 0; */
	flex-wrap: wrap;
}

.promo-badge-infos {
    display: inline-flex;
    align-items: center;
    background-color: #fef3c7;
    color: #d97706;
    padding: 4px 8px;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 600;
    border: 1px solid #d97706;
}

.selling-price-infos-one {
	color: blueviolet;
	text-decoration: line-through;
	font-size: 14px;
	font-weight: 600;
	margin-right: 2px;
}

.price-total-infos-one {
	color: #16a34a;
	font-size: 16px;
	font-weight: 700;
	margin-right: 2px;
}

.price-total-infos-one.after {
    font-size: 14px;
    text-decoration: line-through;
    color: #9ca3af;
}

.price-total-infos-one.before {
    color: #dc2626;
    font-size: 18px;
}

.per-set-infos {
    font-size: 12px;
    color: #6b7280;
    font-weight: 500;
    align-self: flex-end;
}

.collection-actions-one {
    display: flex;
    gap: 4px;
    align-items: center;
    justify-content: flex-start;
}

.btn-view-collection-one {
    background-color: blueviolet;
    color: white;
    padding: 8px 16px;
    border: none;
    gap: 4px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: background-color 0.3s ease;
}

.btn-view-collection-one:hover {
    background-color: indigo;
}

.btn-share-collection-one {
    background-color: #f3f4f6;
    color: #374151;
    padding: 8px 16px;
    border: none;
    gap: 4px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: background-color 0.3s ease;
}

.btn-share-collection-one:hover {
    background-color: #e5e7eb;
    border: 1px solid blueviolet;
}

.btn-favorite-collection-one {
    background-color: #f3f4f6;
    color: gray;
    padding: 4px 8px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 18px;
    font-weight: 600;
    transition: background-color 0.3s ease;
}

/* Collection badges list */
.collection-badges-list {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    margin: 8px 0;
}

.collection-badge-item {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    border-radius: 16px;
    font-size: 13px;
    font-weight: 500;
    white-space: nowrap;
}

/* Liste produits de la collection */
.list-best-product-row {
    width: 100%;
    padding: 16px;
    background: #f9fafb;
    border-top: 1px solid #e5e7eb;
}

.products-section-header-one {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

.products-section-title-one {
    font-size: 18px;
    font-weight: 600;
    color: #111827;
    margin: 0;
}

.btn-view-all-products-one {
    background-color: blueviolet;
    color: white;
    padding: 8px 16px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: background-color 0.3s ease;
}

.btn-view-all-products-one:hover {
    background-color: indigo;
}

/* Carte "Voir tous" dans la grille (mobile uniquement) */
.product-card-view-all-one {
    display: none;
    background: linear-gradient(135deg, blueviolet 0%, indigo 100%);
    cursor: pointer;
    align-items: center;
    justify-content: center;
}

.product-card-view-all-content-one {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    color: white;
    text-align: center;
    padding: 20px;
}

.product-card-view-all-content-one i {
    font-size: 32px;
}

.product-card-view-all-content-one span {
    font-size: 14px;
    font-weight: 600;
}

.products-grid-one {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 16px;
}

.product-card-one {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.product-card-one:hover {
    transform: translateY(-4px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
}

.product-card-image-one {
    width: 100%;
    aspect-ratio: 1;
    position: relative;
    overflow: hidden;
    background: #f5f5f5;
}

.product-card-image-one img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    max-width: 100%;
}

.product-out-of-stock-badge-one {
    position: absolute;
    top: 8px;
    right: 8px;
    background: rgba(220, 38, 38, 0.9);
    color: white;
    padding: 4px 8px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 600;
}

.product-card-info-one {
    padding: 12px;
}

.product-card-name-one {
    font-size: 14px;
    font-weight: 600;
    color: #111827;
    margin: 0 0 8px 0;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.product-card-price-one {
    font-size: 16px;
    font-weight: 700;
    color: blueviolet;
    margin: 0;
}

/* Message aucun produit */
.no-products-message-one {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 48px 24px;
    text-align: center;
}

.no-products-icon-one {
    margin-bottom: 16px;
    opacity: 0.5;
}

.no-products-text-one {
    font-size: 16px;
    color: #6b7280;
    margin: 0 0 24px 0;
}

.btn-view-other-collections-one {
    background-color: blueviolet;
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    transition: background-color 0.3s ease;
}

.btn-view-other-collections-one:hover {
    background-color: indigo;
}

/* Loader produits */
.products-loader-one {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 48px 24px;
    gap: 12px;
}

.products-loader-one i {
    font-size: 32px;
    color: blueviolet;
}

.products-loader-one span {
    font-size: 14px;
    color: #6b7280;
}

/* Erreur produits */
.products-error-one {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 48px 24px;
    color: #dc2626;
    font-size: 14px;
}

.products-error-one i {
    font-size: 24px;
}

/* Responsive */
@media (max-width: 768px) {
    .collection-modal-container {
        width: 100%;
        max-width: 100%;
        height: 100vh;
        max-height: 100vh;
        border-radius: 0;
    }

    .collection-modal-body {
        flex-direction: column;
    }

    .collection-modal-images-card,
    .collection-modal-info-card {
        width: 100%;
    }
    
    /* Grid 2 colonnes pour les produits sur mobile */
    .products-grid-one {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }
    
    .products-section-header-one {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    
    /* Masquer le bouton desktop sur mobile */
    .btn-view-all-desktop-one {
        display: none;
    }
    
    /* Afficher la carte "Voir tous" sur mobile */
    .product-card-view-all-one {
        display: flex;
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes slideUp {
    from {
        transform: translateY(50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}