/* IMPORTATION DES DIFFERENTS STYLES */

/* 1. COMPOSANTS DE BASES */
@import url('styles/barre.css');
@import url('styles/footer.css');
@import url('styles/succes.css');
@import url('styles/command.css');
@import url('styles/card.css');
@import url('styles/board.css');
@import url('styles/stats.css');
@import url('styles/updates.css');



/* 2. SYSTEME ET UI */
@import url('styles/log.css');
@import url('styles/streak.css');
@import url('styles/header.css');
@import url('styles/barre_search.css');
@import url('styles/lvl_up.css');
@import url('styles/combo.css');
@import url('styles/talents.css');
@import url('styles/guide.css');

/* 3. TRIGGERS ET EFFETS */
@import url('styles/effet_flamme.css');
@import url('styles/effet_foudre.css');
@import url('styles/effet_matrix_gold.css');



:root
{
    --bg: #0b0c15; --card: #141522; --text: #cdd6f4;
    --green: #a6e3a1; --red: #ff5555; --blue: #89b4fa;
    --gold: #f9e2af; --purple: #cba6f7; --border: #2a2b3d;
    --glass: rgba(20, 21, 34, 0.8);
    --bronze: #cd7f32;
    --silver: #c0c0c0;
    --gold-ach: #ffd700;
    --platine: #e5e4e2;
}


body {
    background-color: var(--bg); color: var(--text);
    font-family: 'Rajdhani', sans-serif;
    margin: 0; padding: 0; display: flex; flex-direction: column; align-items: center;
    min-height: 100vh; overflow-x: hidden; padding-bottom: 100px;
    }


/* Scanlines */
        body::after {
            content: " "; display: block; position: fixed; top: 0; left: 0; bottom: 0; right: 0;
            background: linear-gradient(rgba(18, 16, 16, 0) 50%, rgba(0, 0, 0, 0.05) 50%), linear-gradient(90deg, rgba(255, 0, 0, 0.03), rgba(0, 255, 0, 0.01), rgba(0, 0, 255, 0.03));
            z-index: 900; background-size: 100% 2px, 3px 100%; pointer-events: none;
        }


        /* BOARD */

        @keyframes slideInLeft {
            from { opacity: 0; transform: translateX(-100px); }
            to { opacity: 1; transform: translateX(0); }
        }
        @keyframes fadeOut {
            from { opacity: 1; }
            to { opacity: 0; }
        }

        
        .modal-overlay { display: none; position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.8); backdrop-filter: blur(5px); z-index: 2000; justify-content: center; align-items: center; }
        .modal-box { background: #111; border: 1px solid var(--blue); width: 95%; max-width: 700px; height: 85vh; padding: 20px; border-radius: 12px; overflow-y: auto; position: relative; display: flex; flex-direction: column; }
        .close-btn { position: absolute; top: 15px; right: 15px; font-size: 1.5rem; color: #fff; cursor: pointer; z-index: 10;}
        .tab-nav { display: flex; gap: 10px; margin-bottom: 20px; border-bottom: 1px solid #333; flex-shrink: 0; }
        .tab-btn { background: none; border: none; padding: 12px 15px; color: #666; font-family: 'Press Start 2P'; font-size: 0.6rem; cursor: pointer; transition: 0.3s; }
        .tab-btn.active { color: var(--blue); border-bottom: 3px solid var(--blue); }
        .tab-content { flex-grow: 1; overflow-y: auto; padding-right: 5px; }

        #setup-overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: #000; z-index: 5000; display: flex; flex-direction: column; justify-content: center; align-items: center; text-align: center; }
        .btn-start { margin-top: 20px; background: var(--blue); color: #000; border: none; padding: 15px 40px; font-family: 'Press Start 2P'; cursor: pointer; border-radius: 4px; box-shadow: 0 0 20px var(--blue); animation: pulse 2s infinite; }

        #toast-container { position: fixed; bottom: 90px; left: 50%; transform: translateX(-50%); z-index: 3000; display: flex; flex-direction: column; gap: 10px; pointer-events: none; }
        .toast { background: rgba(13, 14, 21, 0.95); border: 1px solid var(--blue); padding: 10px 20px; border-radius: 30px; color: #fff; font-family: 'Rajdhani', sans-serif; font-weight: bold; box-shadow: 0 5px 15px rgba(0,0,0,0.5); animation: slideUp 0.3s ease-out; display: flex; align-items: center; gap: 10px; }
        
        


/* =========================================
   SETUP OVERLAY (ÉCRAN D'ACCUEIL)
   ========================================= */

#setup-overlay {
    position: fixed;
    top: 0; left: 0;
    width: 100vw; height: 100vh;
    background: #050505;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    /* Fond quadrillé style "Blueprint" */
    background-image: 
        linear-gradient(rgba(0, 210, 255, 0.05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 210, 255, 0.05) 1px, transparent 1px);
    background-size: 30px 30px;
    backdrop-filter: blur(5px);
}

.setup-box {
    background: rgba(15, 15, 25, 0.95);
    border: 1px solid rgba(0, 210, 255, 0.3);
    padding: 40px;
    border-radius: 16px;
    box-shadow: 0 0 50px rgba(0, 0, 0, 0.8), 0 0 15px rgba(0, 210, 255, 0.1);
    width: 90%;
    max-width: 480px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

/* Petite barre néon en haut */
.setup-box::before {
    content: '';
    position: absolute;
    top: 0; left: 0; width: 100%; height: 4px;
    background: linear-gradient(90deg, var(--blue), var(--purple));
}

/* HEADER */
.setup-header {
    margin-bottom: 30px;
}

.logo-icon {
    font-size: 3rem;
    color: var(--blue);
    margin-bottom: 15px;
    filter: drop-shadow(0 0 10px var(--blue));
    animation: float 3s ease-in-out infinite;
}

.game-title {
    font-family: 'Press Start 2P', cursive;
    color: #fff;
    font-size: 1.8rem;
    margin: 0;
    text-shadow: 2px 2px 0px #000;
}

.game-title .highlight {
    color: var(--blue);
}

.version-tag {
    font-family: 'Rajdhani', sans-serif;
    font-size: 0.8rem;
    color: #555;
    letter-spacing: 2px;
    margin-top: 5px;
    font-weight: 700;
}

/* MISSION BRIEFING (LE TEXTE) */
.mission-briefing {
    background: rgba(255, 255, 255, 0.03);
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 30px;
    text-align: left;
    border-left: 3px solid var(--purple);
}

.mission-briefing h3 {
    color: var(--purple);
    font-family: 'Rajdhani', sans-serif;
    font-size: 1.1rem;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.mission-briefing p {
    font-size: 0.9rem;
    color: #ccc;
    line-height: 1.5;
    margin-bottom: 8px;
}

.mission-briefing p:last-child { margin-bottom: 0; }

/* INPUT & BUTTON */
.input-wrapper {
    position: relative;
    margin-bottom: 20px;
}

.input-wrapper i {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #666;
    transition: 0.3s;
}

#username-input {
    width: 100%;
    padding: 15px 15px 15px 45px;
    background: #0a0a0a;
    border: 1px solid #333;
    border-radius: 8px;
    color: #fff;
    font-family: 'Rajdhani', sans-serif;
    font-size: 1.1rem;
    outline: none;
    transition: 0.3s;
}

#username-input:focus {
    border-color: var(--blue);
    box-shadow: 0 0 10px rgba(0, 210, 255, 0.2);
}

#username-input:focus + i { color: var(--blue); } /* Astuce CSS */

.btn-start {
    width: 100%;
    padding: 15px;
    background: var(--blue);
    color: #000;
    font-family: 'Press Start 2P';
    font-size: 0.8rem;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: 0.2s;
    box-shadow: 0 5px 15px rgba(0, 210, 255, 0.3);
}

.btn-start:hover {
    background: #fff;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(255, 255, 255, 0.4);
}

/* FOOTER */
.setup-footer {
    margin-top: 20px;
    font-size: 0.8rem;
    color: #666;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}


/* Elles doivent être AU-DESSUS de l'écran d'accueil */
#info-modal, .modal-overlay, .modal {
    z-index: 99999 !important;
