/* ===== RESET E CONFIGURAÇÕES GLOBAIS ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-green: #05ff00;
    --background-black: #000000;
    --text-white: #ffffff;
    --shadow-black: rgba(0, 0, 0, 0.8);
    --card-bg: rgba(255, 255, 255, 0.1);
    --input-bg: rgba(255, 255, 255, 0.05);
    --border-radius: 20px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: var(--background-black);
    background: #000000;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    position: relative;
}

/* ===== EFEITO DE FUNDO ANIMADO ===== */
body::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 20% 80%, rgba(5, 255, 0, 0.1) 0%, transparent 50%),
                radial-gradient(circle at 80% 20%, rgba(5, 255, 0, 0.05) 0%, transparent 50%);
    animation: backgroundPulse 4s ease-in-out infinite alternate;
    z-index: -1;
}

@keyframes backgroundPulse {
    0% { opacity: 0.3; }
    100% { opacity: 0.7; }
}

/* ===== CONTAINER PRINCIPAL ===== */
.login-container {
    width: 100%;
    max-width: 400px;
    padding: 20px;
    z-index: 1;
}

/* ===== CARD DE LOGIN ===== */
.login-card {
    background: linear-gradient(145deg, 
        rgba(255, 255, 255, 0.15) 0%, 
        rgba(255, 255, 255, 0.05) 100%);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: var(--border-radius);
    padding: 40px 30px;
    box-shadow: 
        0 20px 40px rgba(0, 0, 0, 0.4),
        0 0 0 1px rgba(5, 255, 0, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    animation: cardFloat 6s ease-in-out infinite;
    position: relative;
    overflow: hidden;
}

.login-card::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: conic-gradient(from 0deg, transparent, rgba(5, 255, 0, 0.1), transparent);
    animation: rotate 10s linear infinite;
    z-index: -1;
}

@keyframes cardFloat {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-5px); }
}

@keyframes rotate {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* ===== AVATAR ===== */
.avatar-container {
    display: flex;
    justify-content: center;
    margin-bottom: 30px;
}

.avatar {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, var(--primary-green), #00cc00);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 
        0 10px 30px rgba(5, 255, 0, 0.3),
        0 0 0 3px rgba(5, 255, 0, 0.2);
    animation: avatarGlow 2s ease-in-out infinite alternate;
}

.avatar-icon {
    width: 40px;
    height: 40px;
    color: var(--background-black);
}

@keyframes avatarGlow {
    0% { box-shadow: 0 10px 30px rgba(5, 255, 0, 0.3), 0 0 0 3px rgba(5, 255, 0, 0.2); }
    100% { box-shadow: 0 15px 40px rgba(5, 255, 0, 0.5), 0 0 0 5px rgba(5, 255, 0, 0.3); }
}

/* ===== FORMULÁRIO ===== */
.login-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* ===== GRUPOS DE INPUT ===== */
.input-group {
    position: relative;
}

.input-container {
    position: relative;
    display: flex;
    align-items: center;
}

.input-icon {
    position: absolute;
    left: 15px;
    width: 20px;
    height: 20px;
    color: rgba(255, 255, 255, 0.6);
    z-index: 2;
    transition: var(--transition);
}

.input-container input {
    width: 100%;
    padding: 15px 15px 15px 50px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    color: var(--text-white);
    font-size: 16px;
    font-weight: 300;
    text-shadow: 0 1px 2px var(--shadow-black);
    transition: var(--transition);
    backdrop-filter: blur(10px);
}

/* Botão de mostrar/ocultar senha */
.toggle-password {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    background: transparent;
    color: rgba(255, 255, 255, 0.6);
    cursor: pointer;
    z-index: 10;
    padding: 0;
    transition: color 0.2s ease, opacity 0.2s ease;
}

.toggle-password:hover {
    color: var(--primary-green);
}

.toggle-password svg {
    width: 20px;
    height: 20px;
    pointer-events: none;
}

/* Dar espaço extra para o ícone de olho no campo de senha */
#password {
    padding-right: 48px !important;
}

.input-container input::placeholder {
    color: rgba(255, 255, 255, 0.5);
    text-shadow: none;
}

.input-container input:focus {
    outline: none;
    border-color: var(--primary-green);
    background: rgba(255, 255, 255, 0.08);
    box-shadow: 
        0 0 0 2px rgba(5, 255, 0, 0.2),
        0 5px 15px rgba(0, 0, 0, 0.3);
    transform: translateY(-1px);
}

.input-container input:focus + .input-icon,
.input-container input:focus ~ .input-icon {
    color: var(--primary-green);
}

/* ===== OPÇÕES DO FORMULÁRIO ===== */
.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 10px 0;
}

.remember-me {
    display: flex;
    align-items: center;
    cursor: pointer;
    color: var(--text-white);
    font-size: 14px;
    text-shadow: 0 1px 2px var(--shadow-black);
    user-select: none;
}

.remember-me input[type="checkbox"] {
    display: none;
}

.checkmark {
    width: 18px;
    height: 18px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 4px;
    margin-right: 8px;
    position: relative;
    transition: var(--transition);
}

.checkmark::after {
    content: '';
    position: absolute;
    left: 5px;
    top: 2px;
    width: 4px;
    height: 8px;
    border: solid var(--background-black);
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
    opacity: 0;
    transition: var(--transition);
}

.remember-me input[type="checkbox"]:checked + .checkmark {
    background: var(--primary-green);
    border-color: var(--primary-green);
}

.remember-me input[type="checkbox"]:checked + .checkmark::after {
    opacity: 1;
}

.forgot-password {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    font-size: 14px;
    text-shadow: 0 1px 2px var(--shadow-black);
    transition: var(--transition);
}

.forgot-password:hover {
    color: var(--primary-green);
    text-shadow: 0 0 8px rgba(5, 255, 0, 0.5);
}

/* ===== BOTÃO DE LOGIN ===== */
.login-btn {
    width: 100%;
    padding: 15px;
    background: linear-gradient(135deg, var(--primary-green), #00cc00);
    border: none;
    border-radius: 12px;
    color: var(--background-black);
    font-size: 16px;
    font-weight: 600;
    letter-spacing: 1px;
    cursor: pointer;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
    margin-top: 10px;
    box-shadow: 
        0 8px 25px rgba(5, 255, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    text-decoration: none;
}

.login-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: var(--transition);
}

.login-btn:hover {
    transform: translateY(-2px);
    box-shadow: 
        0 12px 35px rgba(5, 255, 0, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.login-btn:hover::before {
    left: 100%;
}

.login-btn:active {
    transform: translateY(0);
    box-shadow: 
        0 5px 15px rgba(5, 255, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.login-btn span {
    position: relative;
    z-index: 1;
}

/* ===== ESQUECEU SENHA ===== */
.forgot-password {
    text-align: center;
    margin-top: 1.5rem;
}

.forgot-password a {
    color: var(--primary-green);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: var(--transition);
    text-shadow: 0 1px 2px var(--shadow-black);
}

.forgot-password a:hover {
    color: #00cc00;
    text-shadow: 0 0 8px rgba(5, 255, 0, 0.5);
}

/* ===== LINKS ADICIONAIS ===== */
.additional-links {
    text-align: center;
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.additional-links p {
    color: rgba(255, 255, 255, 0.7);
    margin: 0;
    text-shadow: 0 1px 2px var(--shadow-black);
}

.additional-links a {
    color: var(--primary-green);
    text-decoration: none;
    font-weight: 500;
    transition: var(--transition);
}

.additional-links a:hover {
    color: #00cc00;
    text-shadow: 0 0 8px rgba(5, 255, 0, 0.5);
}

/* ===== RESPONSIVIDADE ===== */
@media (max-width: 480px) {
    .login-container {
        padding: 15px;
        max-width: 350px;
    }
    
    .login-card {
        padding: 30px 20px;
    }
    
    .avatar {
        width: 70px;
        height: 70px;
    }
    
    .avatar-icon {
        width: 35px;
        height: 35px;
    }
    
    .input-container input {
        padding: 12px 12px 12px 45px;
        font-size: 15px;
    }
    
    .input-icon {
        left: 12px;
        width: 18px;
        height: 18px;
    }
    
    .login-btn {
        padding: 12px;
        font-size: 15px;
    }
}

@media (max-width: 320px) {
    .form-options {
        flex-direction: column;
        gap: 10px;
        align-items: flex-start;
    }
    
    .forgot-password {
        align-self: flex-end;
    }
}

/* ===== ANIMAÇÕES DE ENTRADA ===== */
.login-card {
    animation: slideInUp 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes slideInUp {
    0% {
        opacity: 0;
        transform: translateY(50px) scale(0.9);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.input-group {
    animation: fadeInLeft 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    animation-fill-mode: both;
}

.input-group:nth-child(1) { animation-delay: 0.1s; }
.input-group:nth-child(2) { animation-delay: 0.2s; }
.form-options { animation: fadeInLeft 0.6s cubic-bezier(0.4, 0, 0.2, 1) 0.3s both; }
.login-btn { animation: fadeInLeft 0.6s cubic-bezier(0.4, 0, 0.2, 1) 0.4s both; }

@keyframes fadeInLeft {
    0% {
        opacity: 0;
        transform: translateX(-20px);
    }
    100% {
        opacity: 1;
        transform: translateX(0);
    }
}