/* Styles pour le préchargeur moderne */
#preloader {
    position: fixed;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 0.4s ease-out;
}

.preloader-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 25px;
}

.preloader-logo {
    width: 130px;
    height: auto;
    animation: fadeInScale 0.6s ease-out;
    filter: drop-shadow(0 10px 30px rgba(255, 255, 255, 0.3));
}

@keyframes fadeInScale {
    0% { transform: scale(0.5); opacity: 0; }
    100% { transform: scale(1); opacity: 1; }
}

/* Spinner moderne avec barres */
.spinner-container {
    display: flex;
    gap: 8px;
    align-items: flex-end;
}

.spinner-bar {
    width: 8px;
    height: 40px;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 4px;
    animation: barBounce 1s ease-in-out infinite;
}

.spinner-bar:nth-child(1) { animation-delay: 0s; }
.spinner-bar:nth-child(2) { animation-delay: 0.1s; }
.spinner-bar:nth-child(3) { animation-delay: 0.2s; }
.spinner-bar:nth-child(4) { animation-delay: 0.3s; }
.spinner-bar:nth-child(5) { animation-delay: 0.4s; }

@keyframes barBounce {
    0%, 100% { height: 20px; opacity: 0.5; }
    50% { height: 45px; opacity: 1; }
}

/* Texte de chargement */
.loading-text {
    color: white;
    font-size: 1.1rem;
    font-weight: 600;
    letter-spacing: 2px;
    animation: textPulse 2s ease-in-out infinite;
}

@keyframes textPulse {
    0%, 100% { opacity: 0.6; }
    50% { opacity: 1; }
}

/* Media queries pour rendre le preloader responsive */
@media (max-width: 768px) {
    .preloader-logo {
        width: 110px;
    }
    
    .spinner-bar {
        width: 6px;
        height: 35px;
    }
    
    .loading-text {
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .preloader-logo {
        width: 90px;
    }
    
    .spinner-bar {
        width: 5px;
        height: 30px;
    }
    
    .loading-text {
        font-size: 0.9rem;
    }
}
