/* loading.css - Versão Final Corrigida */

:root {
    --primary: #ff6b35; /* Laranja da marca */
    --light: #ffffff;
    --bg-color: #0b0b0b; /* Preto profundo igual da Home */
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body, html {
    height: 100%;
    overflow: hidden;
    background-color: var(--bg-color);
    font-family: 'Roboto Mono', monospace;
}

/* Camada 1: Fundo Partículas (DNA) */
#particles-js {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    z-index: 1; /* Fica no fundo */
    opacity: 0.8; /* Levemente visível */
}

/* Camada 2: Vinheta (Sombra nas bordas) */
body::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    /* Gradiente para escurecer as bordas e destacar o centro */
    background: radial-gradient(circle at center, transparent 0%, rgba(0, 0, 0, 0.9) 100%);
    z-index: 2;
    pointer-events: none;
}

/* Camada 3: Conteúdo Central */
#loading-screen {
    position: relative;
    width: 100%;
    height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 10;
}

/* Logo */
#brain-logo {
    position: relative;
    opacity: 0;
    transform: scale(0.5);
    animation: fadeInScaleUp 2s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

#brain-logo img {
    width: 220px;
    height: auto;
    /* Glow laranja */
    filter: drop-shadow(0 0 30px rgba(255, 107, 53, 0.6));
    position: relative;
    z-index: 10;
}

/* Texto de Instruções */
#instrucoes {
    margin-top: 40px;
    text-align: center;
    
    /* Tipografia Branca Forte */
    color: #ffffff;
    font-weight: 700;
    font-size: 1.1rem;
    letter-spacing: 3px;
    text-transform: uppercase;
    
    /* Sombra para leitura */
    text-shadow: 0 2px 4px rgba(0,0,0,1);
    
    opacity: 0; /* JS controla o aparecimento */
    position: relative;
    z-index: 20; /* Garante que fique acima de tudo */
    
    transition: color 0.3s ease;
}

#instrucoes::before {
    content: '> ';
    color: var(--primary);
    animation: blink 1s infinite;
}

/* Animações */
@keyframes blink { 0%, 100% { opacity: 1; } 50% { opacity: 0.3; } }
@keyframes fadeInScaleUp { 0% { opacity: 0; transform: scale(0.5); } 100% { opacity: 1; transform: scale(1); } }
@keyframes fadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }

@keyframes tremer {
    0% { transform: translate(1px, 1px) rotate(0deg); }
    10% { transform: translate(-1px, -2px) rotate(-1deg); }
    20% { transform: translate(-3px, 0px) rotate(1deg); }
    30% { transform: translate(3px, 2px) rotate(0deg); }
    40% { transform: translate(1px, -1px) rotate(1deg); }
    50% { transform: translate(-1px, 2px) rotate(-1deg); }
    60% { transform: translate(-3px, 1px) rotate(0deg); }
    70% { transform: translate(3px, 1px) rotate(-1deg); }
    80% { transform: translate(-1px, -1px) rotate(1deg); }
    90% { transform: translate(1px, 2px) rotate(0deg); }
    100% { transform: translate(1px, -2px) rotate(-1deg); }
}
.animacao-tremor { animation: tremer 0.1s infinite; }

@keyframes mergulharNoCerebro {
    0% { transform: scale(1); opacity: 1; }
    40% { transform: scale(0.8); opacity: 1; }
    100% { transform: scale(60); opacity: 0; filter: blur(8px); }
}
.animacao-mergulhar {
    will-change: transform, opacity;
    animation: mergulharNoCerebro 1.2s cubic-bezier(0.7, 0, 0.3, 1) forwards;
}

@media (max-width: 768px) {
    #brain-logo img { width: 160px; }
    #instrucoes { font-size: 0.85rem; width: 90%; }
}