/* --- Configurações Globais --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Retornando às Cores Táticas (Ciano e Magenta) */
    --primary-bg: #02040a;
    --accent-cyan: #17daff; /* Cor principal de HUD/Destaque */
    --accent-magenta: #ff00c1; /* Cor de Foco/Alerta */
    --text-light: #f0f8ff; 
    --font-heading: 'Orbitron', sans-serif;
    --font-body: 'Share Tech Mono', monospace;
}

body {
    font-family: var(--font-body);
    background-color: var(--primary-bg);
    color: var(--text-light);
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    overflow: hidden;
}

/* Fundo com Scanlines (Mantido) */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image:
        linear-gradient(var(--primary-bg) 0%, var(--primary-bg) 100%),
        repeating-linear-gradient(0deg, transparent, transparent 1px, rgba(23, 218, 255, 0.1) 1px, rgba(23, 218, 255, 0.1) 2px);
    z-index: -1;
    animation: scanlines 10s linear infinite;
}

@keyframes scanlines {
    from { background-position: 0 0; }
    to { background-position: 0 100px; }
}

/* --- Container de Login (Janela de Status Tática) --- */
.login-container {
    width: 90%;
    max-width: 500px; 
    background: rgba(13, 31, 41, 0.1); 
    border: 2px solid var(--accent-cyan); 
    padding: 3.5rem 3rem;
    backdrop-filter: blur(8px);
    box-shadow: 0 0 40px rgba(23, 218, 255, 0.2); 
    position: relative;
    
    opacity: 0;
    animation: bootUp 1s ease-out 0.3s forwards;
}

@keyframes bootUp {
    from { opacity: 0; transform: translateY(50px) scale(0.95); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

/* Linhas de Canto de HUD (Estrutura Solo Leveling) */
.login-container::before, .login-container::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    border-color: var(--accent-magenta); /* Usando Magenta para um toque de "alerta" na borda */
    border-style: solid;
    transition: all 0.3s;
}

.login-container::before {
    top: -2px; left: -2px;
    border-width: 2px 0 0 2px;
}

.login-container::after {
    bottom: -2px; right: -2px;
    border-width: 0 2px 2px 0;
}

.subtitle {
    text-align: center;
    color: var(--accent-magenta); /* Magenta como subtítulo de alta prioridade */
    letter-spacing: 4px;
    font-size: 0.9rem;
    margin-bottom: 3rem;
    text-transform: uppercase;
    text-shadow: 0 0 5px rgba(255, 0, 193, 0.5);
}

/* --- Formulário --- */
#login-form {
    display: flex;
    flex-direction: column;
    gap: 2.5rem; 
}

.input-group {
    position: relative;
    display: flex;
    flex-direction: column;
}

.input-group label {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    color: var(--accent-cyan);
    margin-bottom: 0.5rem;
    letter-spacing: 1px;
    transition: all 0.3s ease;
}

/* Barras de Status Acima do Campo (Estrutura Solo Leveling) */
.input-group::before {
    content: 'STATUS: ACTIVE';
    position: absolute;
    top: -20px;
    left: 0;
    font-size: 0.7rem;
    color: var(--accent-cyan); /* Usando Ciano para status "normal" */
    background: rgba(23, 218, 255, 0.1);
    padding: 2px 5px;
    letter-spacing: 2px;
    clip-path: polygon(0 0, 100% 0, 95% 100%, 0% 100%);
    opacity: 0.7;
}

.input-group input {
    background: rgba(255, 255, 255, 0.03); 
    border: none;
    border-left: 5px solid rgba(23, 218, 255, 0.4); 
    color: var(--text-light);
    font-family: var(--font-body);
    font-size: 1.3rem;
    padding: 0.8rem 1rem;
    transition: all 0.3s ease;
    caret-color: var(--accent-magenta);
}

/* Efeito de Foco Cyberpunk/HUD */
.input-group input:focus {
    outline: none;
    border-left-color: var(--accent-magenta); 
    background: rgba(255, 0, 193, 0.05); 
    box-shadow: 0 0 10px rgba(255, 0, 193, 0.5) inset;
}

.input-group:focus-within label {
    color: var(--accent-magenta); 
    text-shadow: 0 0 5px rgba(255, 0, 193, 0.7);
}


/* --- Botão de Conexão (Botão de Comando) --- */
#login-button {
    font-family: var(--font-heading);
    font-size: 1.3em;
    padding: 20px 0;
    color: var(--accent-cyan); /* Cor principal do botão */
    border: 1px solid var(--accent-cyan); 
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 4px;
    margin-top: 2rem;
    background: transparent;
    transition: all 0.2s linear;
    position: relative;
    overflow: hidden;
}

/* Efeito de Preenchimento Rápido */
#login-button:hover {
    background: var(--accent-cyan);
    color: var(--primary-bg);
    box-shadow: 0 0 20px var(--accent-cyan);
    transform: none; 
}

/* Efeito de Linha Dupla ao Clicar (Feedback Tático) */
#login-button:active {
    box-shadow: 0 0 30px var(--accent-cyan), 0 0 5px var(--accent-magenta); 
    transform: scale(0.98);
}

/* --- Efeito Glitch no Título --- */
.glitch-text {
    font-family: var(--font-heading);
    font-size: 3rem;
    color: var(--accent-cyan);
    text-shadow: 0 0 10px var(--accent-cyan), 0 0 20px var(--accent-cyan);
    position: relative;
    user-select: none;
    text-align: center;
    margin-bottom: 0.5rem;
}

/* O Glitch continua rápido e intenso */
.glitch-text::before {
    left: 4px; 
    text-shadow: -4px 0 var(--accent-magenta);
    animation: glitch 0.8s infinite linear alternate-reverse; 
}

.glitch-text::after {
    left: -4px; 
    text-shadow: 4px 0 var(--accent-cyan);
    animation: glitch 1.2s infinite linear alternate; 
}

@keyframes glitch {
    0% { clip-path: inset(10% 0 85% 0); }
    15% { clip-path: inset(75% 0 10% 0); }
    30% { clip-path: inset(5% 0 60% 0); }
    45% { clip-path: inset(50% 0 30% 0); }
    100% { clip-path: inset(45% 0 40% 0); }
}


/* --- Status do Login (Feedback com Cores de Status) --- */
#login-status {
    text-align: center;
    font-size: 1em;
    color: var(--text-light);
    margin-top: 2rem;
    height: 20px; 
    transition: color 0.3s ease;
    letter-spacing: 2px;
}

.status-error {
    color: var(--accent-magenta); /* Falha em MAGENTA */
    text-shadow: 0 0 8px rgba(255, 0, 193, 0.8);
    animation: pulseError 0.5s 2; 
}

.status-success {
    color: #00ff8c; /* Mantém o verde para SUCESSO, pois é universal */
    text-shadow: 0 0 8px rgba(0, 255, 140, 0.8);
}

@keyframes pulseError {
    0% { opacity: 1; }
    50% { opacity: 0.5; }
    100% { opacity: 1; }
}