/* ========================================
   LOADER COMPLEXE - NOVATECH.RDC
   Design futuriste avec logo centré
   ======================================== */

/* Container principal du loader */
.novatech-loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #0a0a0a 0%, #1a1a2e 50%, #16213e 100%);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    opacity: 1;
    visibility: visible;
    transition: opacity 0.8s ease, visibility 0.8s ease;
}

.novatech-loader.fade-out {
    opacity: 0;
    visibility: hidden;
}

/* Container central du loader */
.loader-container {
    position: relative;
    width: 200px;
    height: 200px;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Logo au centre */
.loader-logo {
    position: absolute;
    width: 80px;
    height: 80px;
    z-index: 10;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    display: flex;
    justify-content: center;
    align-items: center;
    animation: logoFloat 3s ease-in-out infinite;
}

.loader-logo img {
    width: 60px;
    height: 60px;
    object-fit: contain;
    filter: brightness(1.2) contrast(1.1);
}

/* Animation flottante du logo */
@keyframes logoFloat {
    0%, 100% { transform: translateY(0px) scale(1); }
    50% { transform: translateY(-10px) scale(1.05); }
}

/* Cercles orbitaux */
.orbital-ring {
    position: absolute;
    border: 2px solid transparent;
    border-radius: 50%;
    animation: rotate 4s linear infinite;
}

.orbital-ring:nth-child(1) {
    width: 120px;
    height: 120px;
    border-top: 2px solid #00d4ff;
    border-right: 2px solid rgba(0, 212, 255, 0.3);
    animation-duration: 3s;
}

.orbital-ring:nth-child(2) {
    width: 160px;
    height: 160px;
    border-top: 2px solid #ff6b6b;
    border-left: 2px solid rgba(255, 107, 107, 0.3);
    animation-duration: 4s;
    animation-direction: reverse;
}

.orbital-ring:nth-child(3) {
    width: 200px;
    height: 200px;
    border-top: 2px solid #4ecdc4;
    border-bottom: 2px solid rgba(78, 205, 196, 0.3);
    animation-duration: 5s;
}

/* Animation de rotation */
@keyframes rotate {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Particules flottantes */
.particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: #00d4ff;
    border-radius: 50%;
    animation: particleFloat 6s ease-in-out infinite;
}

.particle:nth-child(4) {
    top: 20%;
    left: 20%;
    background: #ff6b6b;
    animation-delay: -1s;
    animation-duration: 4s;
}

.particle:nth-child(5) {
    top: 80%;
    right: 20%;
    background: #4ecdc4;
    animation-delay: -2s;
    animation-duration: 5s;
}

.particle:nth-child(6) {
    bottom: 20%;
    left: 30%;
    background: #ffd93d;
    animation-delay: -3s;
    animation-duration: 7s;
}

.particle:nth-child(7) {
    top: 30%;
    right: 30%;
    background: #6c5ce7;
    animation-delay: -4s;
    animation-duration: 6s;
}

/* Animation des particules */
@keyframes particleFloat {
    0%, 100% { 
        transform: translateY(0px) translateX(0px) scale(1);
        opacity: 0.7;
    }
    25% { 
        transform: translateY(-20px) translateX(10px) scale(1.2);
        opacity: 1;
    }
    50% { 
        transform: translateY(-10px) translateX(-15px) scale(0.8);
        opacity: 0.5;
    }
    75% { 
        transform: translateY(-30px) translateX(5px) scale(1.1);
        opacity: 0.9;
    }
}

/* Effet de pulsation de fond */
.loader-background-pulse {
    position: absolute;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(0, 212, 255, 0.1) 0%, transparent 70%);
    border-radius: 50%;
    animation: backgroundPulse 4s ease-in-out infinite;
}

@keyframes backgroundPulse {
    0%, 100% { 
        transform: scale(1);
        opacity: 0.3;
    }
    50% { 
        transform: scale(1.2);
        opacity: 0.1;
    }
}

/* Lignes énergétiques */
.energy-line {
    position: absolute;
    width: 2px;
    height: 60px;
    background: linear-gradient(to bottom, transparent, #00d4ff, transparent);
    animation: energyFlow 2s ease-in-out infinite;
}

.energy-line:nth-child(8) {
    top: -30px;
    left: 50%;
    transform: translateX(-50%);
    animation-delay: 0s;
}

.energy-line:nth-child(9) {
    bottom: -30px;
    left: 50%;
    transform: translateX(-50%) rotate(180deg);
    animation-delay: -1s;
}

.energy-line:nth-child(10) {
    top: 50%;
    left: -30px;
    transform: translateY(-50%) rotate(90deg);
    animation-delay: -0.5s;
}

.energy-line:nth-child(11) {
    top: 50%;
    right: -30px;
    transform: translateY(-50%) rotate(-90deg);
    animation-delay: -1.5s;
}

@keyframes energyFlow {
    0%, 100% { 
        opacity: 0;
        transform: translateX(-50%) scaleY(0);
    }
    50% { 
        opacity: 1;
        transform: translateX(-50%) scaleY(1);
    }
}

/* Points de connexion */
.connection-dot {
    position: absolute;
    width: 8px;
    height: 8px;
    background: #00d4ff;
    border-radius: 50%;
    animation: dotPulse 2s ease-in-out infinite;
}

.connection-dot:nth-child(12) {
    top: 10%;
    left: 50%;
    transform: translateX(-50%);
    animation-delay: 0s;
}

.connection-dot:nth-child(13) {
    bottom: 10%;
    left: 50%;
    transform: translateX(-50%);
    animation-delay: -0.7s;
}

.connection-dot:nth-child(14) {
    top: 50%;
    left: 10%;
    transform: translateY(-50%);
    animation-delay: -1.4s;
}

.connection-dot:nth-child(15) {
    top: 50%;
    right: 10%;
    transform: translateY(-50%);
    animation-delay: -0.3s;
}

@keyframes dotPulse {
    0%, 100% { 
        transform: scale(1);
        opacity: 0.6;
        box-shadow: 0 0 0 0 rgba(0, 212, 255, 0.7);
    }
    50% { 
        transform: scale(1.5);
        opacity: 1;
        box-shadow: 0 0 0 10px rgba(0, 212, 255, 0);
    }
}

/* Responsive */
@media (max-width: 768px) {
    .loader-container {
        width: 150px;
        height: 150px;
    }
    
    .loader-logo {
        width: 60px;
        height: 60px;
    }
    
    .loader-logo img {
        width: 45px;
        height: 45px;
    }
    
    .orbital-ring:nth-child(1) {
        width: 90px;
        height: 90px;
    }
    
    .orbital-ring:nth-child(2) {
        width: 120px;
        height: 120px;
    }
    
    .orbital-ring:nth-child(3) {
        width: 150px;
        height: 150px;
    }
    
    .loader-background-pulse {
        width: 200px;
        height: 200px;
    }
}

/* Animation d'entrée */
@keyframes loaderFadeIn {
    from {
        opacity: 0;
        transform: scale(0.8);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.novatech-loader {
    animation: loaderFadeIn 0.5s ease-out;
}