/* Modal Liste de Souhaits - Styles */

.wishlist-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.wishlist-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
}

.wishlist-modal-content {
    position: relative;
    background: white;
    border-radius: 20px;
    width: 95%;
    max-width: 1200px;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: slideUp 0.3s ease;
    overflow: hidden;
}

@keyframes slideUp {
    from {
        transform: translateY(50px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Header avec titre et bouton fermer */
.wishlist-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.5em 2em;
    background: linear-gradient(135deg, #764ba2 0%, #667eea 100%);
    color: white;
    border-bottom: none;
}

.wishlist-title {
    margin: 0;
    font-size: 1.5em;
    font-weight: 700;
}

.wishlist-close-btn {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    border-radius: 10px;
    padding: 0.6em 1.2em;
    display: flex;
    align-items: center;
    gap: 0.5em;
    cursor: pointer;
    transition: all 0.3s ease;
    color: white;
    font-size: 0.95em;
    font-weight: 600;
}

.wishlist-close-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
}

.wishlist-close-btn svg {
    width: 18px;
    height: 18px;
}

/* Barre de filtres et tri */
.wishlist-filters-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1em 2em;
    background: #f9f9f9;
    border-bottom: 2px solid #e0e0e0;
    gap: 1em;
    flex-wrap: wrap;
}

.wishlist-filters {
    display: flex;
    gap: 0.5em;
    flex-wrap: wrap;
}

.wishlist-filter-btn {
    background: white;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    padding: 0.6em 1.2em;
    display: flex;
    align-items: center;
    gap: 0.5em;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.95em;
    font-weight: 600;
    color: #666;
}

.wishlist-filter-btn svg {
    width: 18px;
    height: 18px;
    fill: #666;
}

.wishlist-filter-btn:hover {
    border-color: #764ba2;
    color: #764ba2;
}

.wishlist-filter-btn:hover svg {
    fill: #764ba2;
}

.wishlist-filter-btn.active {
    background: linear-gradient(135deg, #764ba2 0%, #667eea 100%);
    border-color: transparent;
    color: white;
    border-bottom: 3px solid #4a2870;
}

.wishlist-filter-btn.active svg {
    fill: white;
}

.wishlist-sort-select {
    padding: 0.6em 1em;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    background: white;
    font-size: 0.95em;
    font-weight: 600;
    color: #666;
    cursor: pointer;
    transition: all 0.3s ease;
}

.wishlist-sort-select:hover {
    border-color: #764ba2;
}

.wishlist-sort-select:focus {
    outline: none;
    border-color: #764ba2;
    box-shadow: 0 0 0 3px rgba(118, 75, 162, 0.1);
}

.wishlist-modal-body {
    flex: 1;
    overflow-y: auto;
    padding: 1.5em;
}

.wishlist-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 3em;
    gap: 1em;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #764ba2;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

.wishlist-loading p {
    color: #666;
    font-size: 1em;
}

.wishlist-items {
    display: flex;
    flex-direction: column;
    gap: 1em;
}

/* Format bannière paysage */
.wishlist-item-banner {
    display: flex;
    gap: 1em;
    padding: 1em;
    background: white;
    border: 2px solid #f0f0f0;
    border-radius: 15px;
    transition: all 0.3s ease;
    position: relative;
    min-height: 150px;
}

.wishlist-item-banner:hover {
    border-color: #764ba2;
    box-shadow: 0 5px 20px rgba(118, 75, 162, 0.15);
    transform: translateX(5px);
}

/* Image de la bannière */
.wishlist-banner-image {
    position: relative;
    width: 200px;
    height: 150px;
    flex-shrink: 0;
    border-radius: 12px;
    overflow: hidden;
    background: #f9f9f9;
}

.wishlist-banner-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.wishlist-type-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    color: white;
    padding: 0.4em 0.8em;
    border-radius: 8px;
    font-size: 0.75em;
    font-weight: 700;
    text-transform: uppercase;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

/* Contenu de la bannière */
.wishlist-banner-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.8em;
    justify-content: space-between;
}

.wishlist-banner-header {
    display: flex;
    flex-direction: column;
    gap: 0.3em;
}

.wishlist-banner-title {
    margin: 0;
    font-size: 1.2em;
    font-weight: 700;
    color: #333;
    line-height: 1.3;
}

.wishlist-banner-date {
    margin: 0;
    font-size: 0.85em;
    color: #999;
}

.wishlist-banner-description {
    margin: 0;
    font-size: 0.95em;
    color: #666;
    line-height: 1.5;
}

/* Prix et infos */
.wishlist-banner-price,
.wishlist-banner-promo,
.wishlist-banner-collection {
    display: flex;
    align-items: center;
    gap: 0.8em;
    flex-wrap: wrap;
}

.price-original {
    font-size: 0.95em;
    color: blueviolet;
    text-decoration: line-through;
}

.price-current {
    font-size: 1.4em;
    font-weight: 700;
    color: green;
}

.price-current.off {
    font-size: 1em;
}

.price-current.one {
    color: red;
}

.price-text-current {
    font-size: 1.2em;
    font-weight: 600;
    color: gray;
}

.discount-badge {
    background: linear-gradient(135deg, #ff9800, #ff6f00);
    color: white;
    padding: 0.3em 0.6em;
    border-radius: 6px;
    font-size: 0.85em;
    font-weight: 700;
}

.badge-dis-freecount {
    display: flex;
    align-items: center;
    gap: 0.5em;
    flex-direction: row;
    justify-content: flex-start;
}

.wishlist-promo-badge {
    display: flex;
    align-items: center;
    justify-content: center;
    background: red;
    color: white;
    padding: 0.2em 0.4em;
    border-radius: 8px;
    font-size: 0.9em;
    font-weight: 700;
}

.wishlist-free-delivery-badge {
    display: flex;
    justify-content: center;
    border: 1.5px solid green;
    color: green;
    padding: 0.2em 0.4em;
    align-items: center;
    border-radius: 16px;
    font-size: 0.85em;
    font-weight: 600;
    gap: 0.4em;
}

.wishlist-stock-badge {
    padding: 0.2em 0.4em;
    border-radius: 16px;
    display: flex;
    align-items: center;
    gap: 0.4em;
}

.items-count {
    background: #f0f0f0;
    color: #666;
    padding: 0.3em 0.6em;
    border-radius: 6px;
    font-size: 0.85em;
    font-weight: 600;
}

/* Actions de la bannière */
.wishlist-banner-actions {
    display: flex;
    flex-direction: column;
    gap: 0.5em;
    justify-content: center;
    align-items: flex-end;
}

.wishlist-action-btn {
    border: none;
    background: #f5f5f5;
    padding: 0.6em 1em;
    border-radius: 10px;
    display: flex;
    align-items: center;
    gap: 0.5em;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.9em;
    font-weight: 600;
    color: #666;
    min-width: 110px;
}

.wishlist-action-btn svg {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
}

.wishlist-action-btn.view-btn {
    color: #667eea;
    border: 2px solid #667eea;
    background: white;
}

.wishlist-action-btn.view-btn:hover {
    background: #667eea;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.wishlist-action-btn.remove-btn {
    color: #ff6b6b;
    border: 2px solid #ff6b6b;
    background: white;
}

.wishlist-action-btn.remove-btn:hover {
    background: #ff6b6b;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(255, 107, 107, 0.3);
}

.wishlist-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 4em 2em;
    text-align: center;
}

.wishlist-empty svg {
    margin-bottom: 1em;
    opacity: 0.3;
}

.wishlist-empty h3 {
    margin: 0 0 0.5em;
    font-size: 1.3em;
    color: #333;
}

.wishlist-empty p {
    margin: 0;
    color: #999;
    max-width: 400px;
}

.wishlist-error {
    text-align: center;
    padding: 3em;
}

.wishlist-error p {
    color: #ff6b6b;
    font-size: 1.1em;
    margin-bottom: 1em;
}

.wishlist-error button {
    background: linear-gradient(135deg, #764ba2, #667eea);
    color: white;
    border: none;
    padding: 0.8em 2em;
    border-radius: 12px;
    font-size: 1em;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.wishlist-error button:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(118, 75, 162, 0.3);
}

/* Notifications */
.wishlist-notification {
    position: fixed;
    bottom: 2em;
    right: 2em;
    background: white;
    padding: 1em 1.5em;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    z-index: 10001;
    transform: translateY(100px);
    opacity: 0;
    transition: all 0.3s ease;
    font-weight: 600;
    max-width: 350px;
}

.wishlist-notification.show {
    transform: translateY(0);
    opacity: 1;
}

.wishlist-notification-success {
    border-left: 4px solid #4caf50;
}

.wishlist-notification-error {
    border-left: 4px solid #ff6b6b;
}

.wishlist-notification-info {
    border-left: 4px solid #667eea;
}

/* Responsive */
@media (max-width: 768px) {
    .wishlist-modal-content {
        width: 98%;
        max-height: 95vh;
        border-radius: 15px;
    }

    .wishlist-modal-header {
        padding: 1em 1.5em;
    }

    .wishlist-title {
        font-size: 1.2em;
    }

    .wishlist-close-btn {
        padding: 0.5em 0.8em;
        font-size: 0.85em;
    }

    .wishlist-filters-row {
        padding: 0.8em 1em;
        flex-direction: column;
        align-items: stretch;
    }

    .wishlist-filters {
        width: 100%;
        justify-content: space-between;
    }

    .wishlist-filter-btn {
        flex: 1;
        justify-content: center;
        padding: 0.5em 0.6em;
        font-size: 0.85em;
    }

    .wishlist-filter-btn span {
        display: none;
    }

    .wishlist-sort-select {
        width: 100%;
    }

    .wishlist-modal-body {
        padding: 1em;
    }

    .wishlist-item-banner {
        flex-direction: column;
        gap: 1em;
        padding: 1em;
    }

    .wishlist-banner-image {
        width: 100%;
        height: 180px;
    }

    .wishlist-banner-actions {
        flex-direction: row;
        width: 100%;
        justify-content: space-between;
    }

    .wishlist-action-btn {
        flex: 1;
        justify-content: center;
    }

    .wishlist-notification {
        bottom: 1em;
        right: 1em;
        left: 1em;
        max-width: none;
    }
}

@media (max-width: 480px) {
    .wishlist-title {
        font-size: 1em;
    }

    .wishlist-close-btn svg {
        width: 16px;
        height: 16px;
    }

    .wishlist-filter-btn svg {
        width: 20px;
        height: 20px;
    }

    .wishlist-item-banner {
        padding: 0.8em;
    }

    .wishlist-banner-title {
        font-size: 1em;
    }

    .wishlist-banner-image {
        height: 150px;
    }

    .wishlist-banner-description {
        font-size: 0.85em;
    }

    .wishlist-action-btn {
        padding: 0.5em 0.8em;
        font-size: 0.85em;
    }

    .wishlist-action-btn span {
        display: none;
    }
}

/* Scrollbar personnalisée */
.wishlist-modal-body::-webkit-scrollbar {
    width: 8px;
}

.wishlist-modal-body::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

.wishlist-modal-body::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #764ba2, #667eea);
    border-radius: 10px;
}

.wishlist-modal-body::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, #667eea, #764ba2);
}