/* Global Futuristic Loader Styles */
.global-loader-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #000000;
    z-index: 99999;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.global-loader-overlay.show {
    opacity: 1;
    visibility: visible;
}

/* Effet de grille en arrière-plan */
.global-loader-overlay::before {
    content: '';
    position: absolute;
    width: 200%;
    height: 200%;
    background-image: 
        linear-gradient(rgba(255, 165, 0, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 165, 0, 0.03) 1px, transparent 1px);
    background-size: 50px 50px;
    animation: moveGrid 20s linear infinite;
    top: -50%;
    left: -50%;
    z-index: 0;
}

@keyframes moveGrid {
    0% { transform: translate(0, 0); }
    100% { transform: translate(50px, 50px); }
}

.global-loader-container {
    text-align: center;
    background: transparent;
    padding: 3rem 2rem;
    position: relative;
    z-index: 1;
    animation: fadeIn 0.8s ease-out;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Container principal du loader */
.futuristic-loader {
    position: relative;
    width: 300px;
    height: 300px;
    margin: 0 auto 3rem;
}

/* Anneau externe avec marqueurs */
.loader-ring-outer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    border: 3px solid rgba(255, 165, 0, 0.5);
    border-top-color: rgba(255, 165, 0, 1);
    border-right-color: rgba(255, 140, 0, 0.8);
    animation: rotateOuter 3s linear infinite;
    z-index: 1;
}

.loader-ring-outer::before {
    content: '';
    position: absolute;
    top: -3px;
    left: -3px;
    right: -3px;
    bottom: -3px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.4);
    border-style: dashed;
}

@keyframes rotateOuter {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Deuxième anneau orange épais */
.loader-ring-orange-1 {
    position: absolute;
    top: 20px;
    left: 20px;
    width: calc(100% - 40px);
    height: calc(100% - 40px);
    border-radius: 50%;
    border: 10px solid transparent;
    border-top-color: #FF8C00;
    border-right-color: #FF7F00;
    animation: rotateOrange1 2s linear infinite;
    box-shadow: 0 0 25px rgba(255, 140, 0, 0.8);
    z-index: 2;
}

@keyframes rotateOrange1 {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Anneau avec marqueurs */
.loader-ring-markers {
    position: absolute;
    top: 50px;
    left: 50px;
    width: calc(100% - 100px);
    height: calc(100% - 100px);
    border-radius: 50%;
    border: 3px solid #8B4513;
    border-style: dashed;
    animation: rotateMarkers 4s linear infinite reverse;
    z-index: 3;
}

.loader-ring-markers::before,
.loader-ring-markers::after {
    content: '';
    position: absolute;
    width: 4px;
    height: 12px;
    background: rgba(255, 255, 255, 0.8);
    top: -6px;
}

.loader-ring-markers::before {
    left: 50%;
    transform: translateX(-50%);
}

.loader-ring-markers::after {
    right: 50%;
    transform: translateX(50%);
}

@keyframes rotateMarkers {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Troisième anneau orange */
.loader-ring-orange-2 {
    position: absolute;
    top: 70px;
    left: 70px;
    width: calc(100% - 140px);
    height: calc(100% - 140px);
    border-radius: 50%;
    border: 8px solid transparent;
    border-bottom-color: #FF8C00;
    border-left-color: #FF7F00;
    animation: rotateOrange2 1.5s linear infinite reverse;
    box-shadow: 0 0 20px rgba(255, 140, 0, 0.7);
    z-index: 4;
}

@keyframes rotateOrange2 {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Conteneur du logo au centre */
.loader-logo-container {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 120px;
    height: 120px;
    border-radius: 20px;
    background: rgba(0, 0, 0, 0.8);
    border: 2px solid rgba(255, 165, 0, 0.4);
    box-shadow: 
        0 0 30px rgba(255, 140, 0, 0.6),
        inset 0 0 20px rgba(255, 165, 0, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 15px;
    z-index: 10;
    animation: logoPulse 2s ease-in-out infinite;
}

@keyframes logoPulse {
    0%, 100% {
        transform: translate(-50%, -50%) scale(1);
        box-shadow: 0 0 30px rgba(255, 140, 0, 0.6),
                    inset 0 0 20px rgba(255, 165, 0, 0.1);
    }
    50% {
        transform: translate(-50%, -50%) scale(1.05);
        box-shadow: 0 0 40px rgba(255, 140, 0, 0.8),
                    inset 0 0 25px rgba(255, 165, 0, 0.2);
    }
}

.loader-logo-img {
    width: 90px;
    height: auto;
    max-width: 100%;
    max-height: 90px;
    object-fit: contain;
    border-radius: 15px;
    display: block;
    filter: drop-shadow(0 0 10px rgba(255, 165, 0, 0.5));
    animation: logoGlow 2s ease-in-out infinite;
}

@keyframes logoGlow {
    0%, 100% {
        filter: drop-shadow(0 0 10px rgba(255, 165, 0, 0.5));
    }
    50% {
        filter: drop-shadow(0 0 20px rgba(255, 165, 0, 0.8));
    }
}

/* Marqueurs de coin (corners) */
.loader-corner {
    position: absolute;
    width: 35px;
    height: 35px;
    border: 3px solid rgba(255, 255, 255, 1);
    z-index: 6;
}

.loader-corner-top {
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    border-bottom: none;
    border-left: none;
    border-right: none;
}

.loader-corner-bottom {
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    border-top: none;
    border-left: none;
    border-right: none;
}

.loader-corner-left {
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    border-right: none;
    border-top: none;
    border-bottom: none;
}

.loader-corner-right {
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    border-left: none;
    border-top: none;
    border-bottom: none;
}

/* Marqueurs diagonaux */
.loader-marker {
    position: absolute;
    width: 0;
    height: 0;
    border-style: solid;
    z-index: 6;
}

.loader-marker-top-left {
    top: 15px;
    left: 15px;
    border-width: 0 10px 10px 0;
    border-color: transparent rgba(255, 255, 255, 1) transparent transparent;
}

.loader-marker-top-right {
    top: 15px;
    right: 15px;
    border-width: 0 0 10px 10px;
    border-color: transparent transparent rgba(255, 255, 255, 1) transparent;
}

.loader-marker-bottom-left {
    bottom: 15px;
    left: 15px;
    border-width: 10px 10px 0 0;
    border-color: rgba(255, 255, 255, 1) transparent transparent transparent;
}

.loader-marker-bottom-right {
    bottom: 15px;
    right: 15px;
    border-width: 10px 0 0 10px;
    border-color: transparent transparent transparent rgba(255, 255, 255, 1);
}

/* Texte Loading */
.loading-text {
    color: #FFFFFF;
    font-size: 1.5rem;
    font-weight: 300;
    letter-spacing: 4px;
    text-transform: uppercase;
    margin-top: 2rem;
    text-shadow: 
        0 0 10px rgba(255, 165, 0, 0.8),
        0 0 20px rgba(255, 165, 0, 0.5),
        0 0 30px rgba(255, 165, 0, 0.3);
    animation: textPulse 2s ease-in-out infinite;
}

@keyframes textPulse {
    0%, 100% {
        opacity: 0.8;
        text-shadow: 
            0 0 10px rgba(255, 165, 0, 0.8),
            0 0 20px rgba(255, 165, 0, 0.5),
            0 0 30px rgba(255, 165, 0, 0.3);
    }
    50% {
        opacity: 1;
        text-shadow: 
            0 0 15px rgba(255, 165, 0, 1),
            0 0 30px rgba(255, 165, 0, 0.7),
            0 0 45px rgba(255, 165, 0, 0.5);
    }
}

/* Responsive */
@media (max-width: 576px) {
    .futuristic-loader {
        width: 250px;
        height: 250px;
    }
    
    .loader-logo-container {
        width: 100px;
        height: 100px;
    }
    
    .loader-logo-img {
        width: 75px;
    }
    
    .loading-text {
        font-size: 1.2rem;
    }
}

