/* =====================================================
   COVER SLIDER - Frontend Styles
   Version optimisée pour la performance
   ===================================================== */

/* Variables CSS */
:root {
    --cs-primary: #e91e63;
    --cs-secondary: #00bcd4;
    --cs-dark: #0d0d12;
    --cs-light: #ffffff;
    --cs-transition: cubic-bezier(0.4, 0, 0.2, 1);
}

/* Reset */
#cover-slider-overlay *,
#cover-slider-modal * {
    box-sizing: border-box;
}

/* Assurer que le modal prend tout l'écran */
body.cover-slider-modal-open {
    overflow: hidden !important;
    margin: 0 !important;
    padding: 0 !important;
}

html.cover-slider-modal-open {
    overflow: hidden !important;
    margin: 0 !important;
    padding: 0 !important;
}

/* =====================================================
   OVERLAY / COUVERTURE - Optimisé
   ===================================================== */

#cover-slider-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: var(--bg-color, #0d0d12);
    z-index: 999998;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

/* Fond statique avec dégradés (pas d'animation) */
#cover-slider-overlay::before {
    content: '';
    position: absolute;
    inset: 0;
    background: 
        radial-gradient(ellipse at 20% 80%, rgba(233, 30, 99, 0.12) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 20%, rgba(0, 188, 212, 0.1) 0%, transparent 50%);
    pointer-events: none;
}

/* Particules simples - seulement 3 pour la performance */
.particles {
    position: absolute;
    inset: 0;
    pointer-events: none;
    overflow: hidden;
}

.particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: rgba(255, 255, 255, 0.4);
    border-radius: 50%;
    opacity: 0.3;
}

.particle:nth-child(1) { left: 15%; top: 25%; }
.particle:nth-child(2) { left: 80%; top: 20%; }
.particle:nth-child(3) { left: 60%; top: 75%; }
.particle:nth-child(4) { display: none; }
.particle:nth-child(5) { display: none; }

/* Lignes décoratives - statiques */
.decorative-lines { display: none; }

/* Contenu principal - animation simple au chargement */
.cover-slider-content {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 40px;
    padding: 20px;
    animation: fadeIn 0.8s ease-out forwards;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* =====================================================
   LOGO CONTAINER - Optimisé
   ===================================================== */

.cover-logo-container {
    position: relative;
    cursor: pointer;
    transition: transform 0.3s ease;
    z-index: 10;
}

.cover-logo-container:hover {
    transform: scale(1.05);
}

.cover-logo-container:active {
    transform: scale(0.98);
}

.cover-logo {
    display: block;
    max-width: 400px;
    max-height: 60vh;
    width: auto;
    height: auto;
    border-radius: 24px;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5);
    transition: box-shadow 0.3s ease, transform 0.3s ease;
}

.cover-logo-container:hover .cover-logo {
    box-shadow: 
        0 35px 70px rgba(0, 0, 0, 0.6),
        0 0 40px rgba(233, 30, 99, 0.15);
}

/* Glow - simplifié */
.logo-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 100%;
    height: 100%;
    transform: translate(-50%, -50%);
    background: radial-gradient(ellipse at center, rgba(233, 30, 99, 0.2) 0%, transparent 70%);
    filter: blur(40px);
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
    z-index: -1;
}

.cover-logo-container:hover .logo-glow {
    opacity: 1;
}

/* Indicateur de clic - simplifié */
.click-indicator {
    position: absolute;
    bottom: -60px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    background: rgba(233, 30, 99, 0.15);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 50px;
    color: rgba(255, 255, 255, 0.9);
    font-family: 'Outfit', sans-serif;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 2px;
    text-transform: uppercase;
    transition: all 0.3s ease;
}

.click-indicator svg {
    transition: transform 0.3s ease;
}

.cover-logo-container:hover .click-indicator {
    background: rgba(233, 30, 99, 0.25);
    border-color: rgba(233, 30, 99, 0.3);
}

.cover-logo-container:hover .click-indicator svg {
    transform: translateX(4px);
}

/* =====================================================
   ICÔNES RÉSEAUX SOCIAUX - Optimisé
   ===================================================== */

.social-icons {
    display: flex;
    gap: 14px;
    padding: 20px;
    margin-top: 20px;
}

.social-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 52px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: transform 0.25s ease, background 0.25s ease, box-shadow 0.25s ease;
    position: relative;
    overflow: hidden;
}

.social-icon::before {
    content: '';
    position: absolute;
    inset: 0;
    background: var(--icon-bg, linear-gradient(135deg, #e91e63, #00bcd4));
    opacity: 0;
    transition: opacity 0.25s ease;
}

.social-icon svg {
    width: 24px;
    height: 24px;
    position: relative;
    z-index: 1;
    transition: transform 0.25s ease;
}

.social-icon:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 24px var(--icon-shadow, rgba(0, 0, 0, 0.3));
}

.social-icon:hover::before {
    opacity: 1;
}

.social-icon:hover svg {
    transform: scale(1.1);
    color: white;
}

/* Couleurs par réseau */
.social-icon.instagram {
    --icon-bg: linear-gradient(135deg, #f09433, #dc2743);
    --icon-shadow: rgba(220, 39, 67, 0.35);
}

.social-icon.facebook {
    --icon-bg: linear-gradient(135deg, #1877f2, #0d65d9);
    --icon-shadow: rgba(24, 119, 242, 0.35);
}

.social-icon.tiktok {
    --icon-bg: linear-gradient(135deg, #00f2ea, #ff0050);
    --icon-shadow: rgba(255, 0, 80, 0.35);
}

.social-icon.whatsapp {
    --icon-bg: linear-gradient(135deg, #25d366, #128c7e);
    --icon-shadow: rgba(37, 211, 102, 0.35);
}

.social-icon.twitter {
    --icon-bg: linear-gradient(135deg, #1a1a1a, #333);
    --icon-shadow: rgba(0, 0, 0, 0.4);
}

/* =====================================================
   SLIDER MODAL
   ===================================================== */

.cover-slider-modal {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    background: rgba(10, 10, 15, 0.98);
    z-index: 999999 !important;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.5s var(--cs-transition);
}

.cover-slider-modal.active {
    opacity: 1;
    visibility: visible;
}

/* Bouton fermer */
.slider-close {
    position: fixed;
    top: 20px;
    right: 20px;
    width: 50px;
    height: 50px;
    background: rgba(0, 0, 0, 0.8);
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    z-index: 10002;
}

.slider-close:hover {
    background: rgba(255, 59, 59, 0.9);
    border-color: rgba(255, 59, 59, 0.9);
    transform: rotate(90deg) scale(1.1);
}

.slider-close svg {
    width: 26px;
    height: 26px;
    stroke: white;
    fill: none;
}

/* Container du slider */
.slider-container {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.slider-track {
    display: flex;
    width: 100%;
    height: 100%;
    transition: transform 0.5s var(--cs-transition);
    will-change: transform;
}

.slider-slide {
    flex: 0 0 100%;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px;
}

.slider-slide img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    user-select: none;
    -webkit-user-drag: none;
    transition: transform 0.2s ease-out;
    cursor: grab;
    border-radius: 8px;
    transform-origin: center center;
}

.slider-slide img:active {
    cursor: grabbing;
}

.slider-slide img.zoomed {
    cursor: move;
}

/* Navigation arrows */
.slider-nav {
    position: fixed;
    top: 50%;
    transform: translateY(-50%);
    width: 50px;
    height: 50px;
    background: rgba(0, 0, 0, 0.8);
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    z-index: 10001;
}

.slider-nav svg {
    stroke: white;
    fill: none;
    stroke-width: 2.5;
}

.slider-prev { left: 20px; }
.slider-next { right: 20px; }

.slider-nav:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-50%) scale(1.1);
    border-color: rgba(255, 255, 255, 0.5);
}

/* Dots / Indicateurs */
.slider-dots {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
    padding: 12px 20px;
    background: rgba(0, 0, 0, 0.7);
    border-radius: 50px;
    z-index: 10001;
}

.slider-dot {
    width: 10px;
    height: 10px;
    background: rgba(255, 255, 255, 0.3);
    border: none;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
    padding: 0;
}

.slider-dot:hover {
    background: rgba(255, 255, 255, 0.6);
    transform: scale(1.3);
}

.slider-dot.active {
    background: var(--cs-primary);
    transform: scale(1.4);
    box-shadow: 0 0 15px rgba(233, 30, 99, 0.6);
}

/* Compteur */
.slider-counter {
    position: fixed;
    top: 20px;
    left: 20px;
    padding: 12px 20px;
    background: rgba(0, 0, 0, 0.7);
    border-radius: 50px;
    color: white;
    font-family: 'Outfit', sans-serif;
    font-size: 14px;
    font-weight: 500;
    letter-spacing: 1px;
    z-index: 10001;
}

/* Boutons de zoom */
.zoom-controls {
    position: fixed;
    top: 20px;
    right: 90px;
    display: flex;
    gap: 8px;
    z-index: 10001;
}

.zoom-btn {
    width: 44px;
    height: 44px;
    background: rgba(0, 0, 0, 0.8);
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    font-size: 22px;
    font-weight: bold;
}

.zoom-btn svg {
    stroke: white;
    fill: white;
    width: 20px;
    height: 20px;
}

.zoom-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: scale(1.1);
    border-color: rgba(255, 255, 255, 0.5);
}

.zoom-btn.disabled {
    opacity: 0.3;
    cursor: not-allowed;
    pointer-events: none;
}

.zoom-btn.active {
    background: var(--cs-primary);
    border-color: var(--cs-primary);
}

/* Mode plein écran */
.cover-slider-modal:fullscreen {
    background: rgba(0, 0, 0, 1);
}

.cover-slider-modal:-webkit-full-screen {
    background: rgba(0, 0, 0, 1);
}

.cover-slider-modal:-moz-full-screen {
    background: rgba(0, 0, 0, 1);
}

.cover-slider-modal:-ms-fullscreen {
    background: rgba(0, 0, 0, 1);
}

/* Ajustements en mode plein écran */
.cover-slider-modal:fullscreen .slider-slide img,
.cover-slider-modal:-webkit-full-screen .slider-slide img,
.cover-slider-modal:-moz-full-screen .slider-slide img {
    max-width: 100vw !important;
    max-height: 100vh !important;
}

/* =====================================================
   NOTICE
   ===================================================== */

.cover-slider-notice {
    padding: 24px 32px;
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
    border: 2px solid #f59e0b;
    border-radius: 16px;
    color: #92400e;
    text-align: center;
    font-family: 'Outfit', sans-serif;
    font-weight: 600;
    font-size: 16px;
    margin: 20px;
    box-shadow: 0 10px 40px rgba(245, 158, 11, 0.2);
}

/* =====================================================
   RESPONSIVE
   ===================================================== */

@media (max-width: 768px) {
    .cover-logo {
        max-width: 85vw;
        max-height: 50vh;
        border-radius: 20px;
    }
    
    .click-indicator {
        bottom: -50px;
        padding: 10px 20px;
        font-size: 12px;
    }
    
    .social-icons {
        gap: 14px;
    }
    
    .social-icon {
        width: 46px;
        height: 46px;
        border-radius: 14px;
    }
    
    .social-icon svg {
        width: 20px;
        height: 20px;
    }
    
    .slider-close {
        width: 48px;
        height: 48px;
    }
    
    .slider-nav {
        width: 46px;
        height: 46px;
    }
    
    .slider-prev { left: 15px; }
    .slider-next { right: 15px; }
    
    .slider-slide {
        padding: 60px 20px;
    }
    
    .slider-dots {
        bottom: 25px;
        gap: 8px;
        padding: 10px 16px;
    }
    
    .slider-dot {
        width: 8px;
        height: 8px;
    }
    
    .slider-counter {
        padding: 10px 16px;
        font-size: 13px;
    }
    
    .zoom-controls {
        right: 78px;
        gap: 6px;
    }
    
    .zoom-btn {
        width: 40px;
        height: 40px;
        font-size: 20px;
    }
}

@media (max-width: 480px) {
    .cover-slider-content {
        gap: 30px;
    }
    
    .cover-logo {
        max-width: 90vw;
        max-height: 45vh;
        border-radius: 16px;
    }
    
    .social-icons {
        gap: 12px;
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .social-icon {
        width: 44px;
        height: 44px;
    }
    
    .slider-nav {
        width: 44px;
        height: 44px;
    }
    
    .slider-prev {
        left: 10px;
    }
    
    .slider-next {
        right: 10px;
    }
    
    .slider-slide {
        padding: 50px 15px;
    }
}

/* Paysage mobile */
@media (orientation: landscape) and (max-height: 500px) {
    .cover-logo {
        max-height: 70vh;
    }
    
    .click-indicator {
        display: none;
    }
    
    .social-icons {
        position: absolute;
        bottom: 20px;
        right: 20px;
        flex-direction: column;
        gap: 10px;
    }
    
    .social-icon {
        width: 40px;
        height: 40px;
    }
}

/* Animation d'entrée du slider */
.cover-slider-modal.active .slider-slide img {
    animation: slideImageFadeIn 0.4s ease-out both;
}

@keyframes slideImageFadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

