/* Animations et Micro-interactions */

/* Flash Promo Animation */
@keyframes flashPromo {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

.flash-promo {
    animation: flashPromo 2s infinite;
    background: linear-gradient(45deg, #FFD700, #FFA500);
    color: #003366;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    font-weight: bold;
    display: inline-block;
}

/* Bannière "Ouvert toute l'année" */
.open-banner {
    background: #28a745;
    color: white;
    text-align: center;
    padding: 0.5rem;
    position: relative;
    overflow: hidden;
}

.open-banner::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    animation: shine 3s infinite;
}

@keyframes shine {
    to { left: 100%; }
}

/* ============================================
   RESPONSIVE MICRO-INTERACTIONS
   ============================================ */

/* Touch-friendly hover effects for mobile */
@media (hover: none) and (pointer: coarse) {
    .product-card:hover,
    .feature-card:hover,
    .activity-card:hover {
        transform: none;
    }
    
    .product-card:active,
    .feature-card:active,
    .activity-card:active {
        transform: scale(0.98);
        transition: transform 0.1s ease;
    }
}

/* Enhanced mobile interactions */
@media (max-width: 768px) {
    /* Larger touch targets */
    button, .btn, .cta-button {
        min-height: 44px;
        padding: 12px 20px;
        font-size: 16px; /* Prevent zoom on iOS */
    }
    
    /* Improved form inputs */
    input, select, textarea {
        min-height: 44px;
        padding: 12px 15px;
        font-size: 16px; /* Prevent zoom on iOS */
        border-radius: 8px;
    }
    
    /* Mobile-friendly dropdowns */
    .dropdown-menu {
        border-radius: 12px;
        padding: 15px 0;
        box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    }
    
    .dropdown-menu li a {
        padding: 15px 20px;
        font-size: 16px;
    }
    
    /* Swipe indicators for carousels */
    .carousel-container {
        position: relative;
    }
    
    .carousel-container::after {
        content: "← Glissez →";
        position: absolute;
        bottom: -30px;
        left: 50%;
        transform: translateX(-50%);
        font-size: 12px;
        color: var(--gris);
        opacity: 0.7;
    }
    
    /* Mobile sticky elements */
    .cart-sticky {
        right: 1rem;
        bottom: 1rem;
        width: 60px;
        height: 60px;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        box-shadow: 0 4px 20px rgba(0,0,0,0.3);
    }
    
    /* Loading states for mobile */
    .loading-button {
        position: relative;
        color: transparent;
    }
    
    .loading-button::after {
        content: "";
        position: absolute;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        width: 20px;
        height: 20px;
        border: 2px solid transparent;
        border-top: 2px solid currentColor;
        border-radius: 50%;
        animation: spin 1s linear infinite;
    }
}

/* Tablet-specific interactions */
@media (min-width: 768px) and (max-width: 1024px) {
    /* Hover effects for tablets with mouse */
    @media (hover: hover) {
        .product-card:hover {
            transform: translateY(-8px);
            box-shadow: 0 8px 25px rgba(0,0,0,0.15);
        }
        
        .feature-card:hover {
            transform: translateY(-5px);
            box-shadow: 0 5px 20px rgba(0,0,0,0.12);
        }
    }
    
    /* Touch interactions for touch tablets */
    @media (hover: none) {
        .product-card:active {
            transform: scale(0.98);
        }
        
        .feature-card:active {
            transform: scale(0.98);
        }
    }
    
    .cart-sticky {
        right: 1.5rem;
        bottom: 1.5rem;
        width: 65px;
        height: 65px;
    }
}

/* Desktop interactions */
@media (min-width: 1025px) {
    /* Enhanced hover effects */
    .product-card:hover {
        transform: translateY(-10px);
        box-shadow: 0 15px 40px rgba(0,0,0,0.15);
        transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    }
    
    .feature-card:hover {
        transform: translateY(-8px);
        box-shadow: 0 12px 35px rgba(0,0,0,0.12);
        transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    }
    
    /* Smooth parallax effect */
    .hero {
        background-attachment: fixed;
        background-size: cover;
        background-position: center;
    }
    
    /* Advanced button interactions */
    .cta-button:hover {
        transform: translateY(-3px);
        box-shadow: 0 10px 25px rgba(0,51,102,0.3);
    }
    
    .cta-button:active {
        transform: translateY(-1px);
        box-shadow: 0 5px 15px rgba(0,51,102,0.3);
    }
}

/* Sticky Cart Button */
.cart-sticky {
    position: fixed;
    right: 2rem;
    bottom: 2rem;
    background: #003366;
    color: white;
    padding: 1rem;
    border-radius: 50%;
    box-shadow: 0 2px 10px rgba(0,0,0,0.2);
    cursor: pointer;
    z-index: 1000;
    transition: transform 0.3s;
}

.cart-sticky:hover {
    transform: scale(1.1);
}

/* Cart Slide Panel */
.cart-panel {
    position: fixed;
    right: -400px;
    top: 0;
    width: 400px;
    height: 100vh;
    background: white;
    box-shadow: -2px 0 10px rgba(0,0,0,0.1);
    transition: right 0.3s ease;
    z-index: 1001;
    overflow-y: auto;
}

.cart-panel.open {
    right: 0;
}

/* Overlay pour le panier */
.cart-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0,0,0,0.5);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
    z-index: 1000;
}

.cart-overlay.visible {
    opacity: 1;
    visibility: visible;
}

/* Disponibilité Indicators */
.availability-indicator {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    display: inline-block;
    margin-right: 0.5rem;
}

.availability-high {
    background-color: #28a745;
}

.availability-medium {
    background-color: #ffc107;
}

.availability-low {
    background-color: #dc3545;
}

/* Carrousel Touch-friendly */
.carousel {
    position: relative;
    overflow: hidden;
    touch-action: pan-x;
}

.carousel-inner {
    display: flex;
    transition: transform 0.3s ease-in-out;
}

.carousel-item {
    flex: 0 0 100%;
    padding: 1rem;
}

.carousel-controls {
    position: absolute;
    bottom: 1rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 0.5rem;
}

.carousel-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255,255,255,0.5);
    cursor: pointer;
    transition: background-color 0.3s;
}

.carousel-dot.active {
    background: white;
}

/* Modal de Confirmation */
.modal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.9);
    background: white;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.2);
    z-index: 1002;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
    max-width: 90%;
    width: 500px;
}

.modal.visible {
    opacity: 1;
    visibility: visible;
    transform: translate(-50%, -50%) scale(1);
}

/* Hébergement Carrousel */
.accommodation-carousel {
    margin: 2rem 0;
}

.accommodation-carousel .carousel-item img {
    width: 100%;
    height: 300px;
    object-fit: cover;
    border-radius: 8px;
}

/* Blog Carrousel */
.blog-carousel {
    margin: 2rem 0;
}

.blog-carousel .carousel-item {
    padding: 1rem;
}

.blog-card {
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.blog-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.blog-content {
    padding: 1rem;
}

/* Menu Mobile */
.mobile-menu {
    position: fixed;
    top: 0;
    left: -300px;
    width: 300px;
    height: 100vh;
    background: white;
    z-index: 1001;
    transition: left 0.3s ease;
    box-shadow: 2px 0 10px rgba(0,0,0,0.1);
}

.mobile-menu.open {
    left: 0;
}

.mobile-menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0,0,0,0.5);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
    z-index: 1000;
}

.mobile-menu-overlay.visible {
    opacity: 1;
    visibility: visible;
}

/* Hero CTA */
.hero-cta {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-top: 2rem;
}

.cta-primary {
    background: #FFD700;
    color: #003366;
    padding: 1rem 2rem;
    border-radius: 30px;
    font-weight: bold;
    text-decoration: none;
    transition: transform 0.3s, box-shadow 0.3s;
}

.cta-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

.cta-secondary {
    background: transparent;
    color: white;
    padding: 1rem 2rem;
    border-radius: 30px;
    font-weight: bold;
    text-decoration: none;
    border: 2px solid white;
    transition: background-color 0.3s;
}

.cta-secondary:hover {
    background: rgba(255,255,255,0.1);
}

/* Cart Micro-interactions */
.add-to-cart-btn {
    background-color: var(--bleu-marine);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.add-to-cart-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}

.add-to-cart-btn.in-cart {
    background-color: #4CAF50;
}

.cart-count {
    position: absolute;
    top: -8px;
    right: -8px;
    background: #dc3545;
    color: white;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    transition: transform 0.3s;
}

.cart-count.bump {
    animation: bump 0.3s ease-out;
}

@keyframes bump {
    0% { transform: scale(1); }
    50% { transform: scale(1.2); }
    100% { transform: scale(1); }
}

.cart-item {
    display: flex;
    justify-content: space-between;
    padding: 0.5rem;
    border-bottom: 1px solid #eee;
}

.cart-summary {
    background: white;
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 1rem;
    position: fixed;
    right: 2rem;
    top: 4rem;
    width: 300px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    z-index: 1000;
    display: none;
}

/* Media Queries */
@media (max-width: 768px) {
    .cart-panel {
        width: 100%;
        right: -100%;
    }
    
    .modal {
        width: 95%;
    }
    
    .hero-cta {
        flex-direction: column;
        align-items: center;
    }
    
    .carousel-controls {
        bottom: 0.5rem;
    }
}