/**
 * Custom Login Styles - Elements Security Plugin
 * Tela de login personalizada e elegante
 * 
 * COMO USAR:
 * 1. Ative a opção "Custom Login" no painel do Elements Security
 * 2. Personalize URL e título nas configurações
 * 3. Use a cor principal #4aaeac (pode ser alterada facilmente)
 * 
 * CORES PRINCIPAIS:
 * - Primária: #4aaeac
 * - Secundária: #3a8e8c
 * - Escura: #2a6e6c
 * 
 * ESTRUTURA HTML NECESSÁRIA:
 * - .login-container (container principal)
 * - .login-form-side (lado do formulário)
 * - .login-title (título e descrição)
 * - .login-form (formulário de login)
 */

/* Reset e configurações básicas */
body.login {
    background: #0a0a0a;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    margin: 0;
    padding: 0;
    min-height: 100vh;
    overflow-x: hidden;
}

/* Container principal */
#login {
    position: relative;
    z-index: 2;
    display: flex;
    min-height: 100vh;
    align-items: center;
    justify-content: center;
    padding: 20px;
    margin: 0;
    width: 100%;
}

/* Container do login */
.login-container {
    display: flex;
    width: 100%;
    max-width: 320px;
    background: rgba(10, 10, 10, 0.9);
    border-radius: 16px;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.3);
    overflow: hidden;
    min-height: 380px;
    position: relative;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(74, 174, 172, 0.2);
}



/* Lado do formulário */
.login-form-side {
    flex: 1;
    padding: 35px 30px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    position: relative;
    background: transparent;
    color: white;
    text-align: center;
    width: 100%;
}



/* Lado da imagem - agora é o fundo da página */
body.login::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('https://images.unsplash.com/photo-1506905925346-21bda4d32df4?ixlib=rb-4.0.3&auto=format&fit=crop&w=2070&q=80');
    background-size: cover;
    background-position: center;
    opacity: 0.8;
    z-index: 1;
}



/* Lado da imagem - apenas imagem de fundo decorativa */

/* Título do login */
.login-title {
    text-align: center;
    margin-bottom: 30px;
    width: 100%;
}

.login-title h1 {
    font-size: 1.6rem;
    font-weight: 700;
    color: white;
    margin: 0 0 6px 0;
    letter-spacing: -0.5px;
}

.login-title h1::after {
    content: '';
    display: inline-block;
    width: 8px;
    height: 8px;
    background: #4aaeac;
    border-radius: 50%;
    margin-left: 8px;
    vertical-align: middle;
}

.login-title p {
    color: #9ca3af;
    font-size: 1rem;
    margin: 0;
    font-weight: 500;
}

/* Formulário */
#loginform {
    background: transparent;
    border: none;
    box-shadow: none;
    padding: 0;
    margin: 0;
}

.login form {
    margin: 0;
}

.user-pass-wrap {
    margin-bottom: 16px;
}

.user-pass-wrap label {
    display: block;
    font-weight: 600;
    color: white;
    margin-bottom: 6px;
    font-size: 0.85rem;
    letter-spacing: 0.025em;
    text-align: left;
}

.input {
    width: 100%;
    padding: 12px 14px;
    border: 2px solid transparent;
    border-radius: 8px;
    font-size: 0.9rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    background: #1a1a1a;
    color: white;
    font-weight: 500;
    background-image: linear-gradient(#1a1a1a, #1a1a1a), linear-gradient(90deg, #4aaeac 0%, #ff6b35 100%);
    background-origin: border-box;
    background-clip: padding-box, border-box;
}

.input:focus {
    outline: none;
    background-image: linear-gradient(#1a1a1a, #1a1a1a), linear-gradient(90deg, #4aaeac 0%, #ff6b35 100%);
    transform: translateY(-1px);
    box-shadow: 0 8px 25px rgba(74, 174, 172, 0.2);
}

.input::placeholder {
    color: #6b7280;
    font-size: 0.8rem;
}

/* Checkbox */
.forgetmenot {
    margin: 16px 0;
}

.forgetmenot label {
    display: flex;
    align-items: center;
    font-size: 0.8rem;
    color: #6b7280;
    cursor: pointer;
    font-weight: 500;
}

.forgetmenot input[type="checkbox"] {
    margin-right: 10px;
    width: 18px;
    height: 18px;
    accent-color: #4aaeac;
    border-radius: 4px;
}

/* Botão submit */
.submit {
    margin-top: 20px;
}

.submit input {
    width: 100%;
    background: #4aaeac;
    border: none;
    color: white;
    padding: 12px 18px;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    position: relative;
    overflow: hidden;
}

.submit input::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: left 0.5s;
}

.submit input:hover::before {
    left: 100%;
}

.submit input:hover {
    background: #3a8e8c;
    transform: translateY(-2px);
    box-shadow: 0 12px 30px rgba(74, 174, 172, 0.3);
}

.submit input:focus {
    background: #3a8e8c;
    transform: translateY(-1px);
    box-shadow: 0 8px 20px rgba(74, 174, 172, 0.4);
}

.submit input:active {
    transform: translateY(0);
}

/* Links */
#nav {
    text-align: center;
    margin-top: 20px;
    padding: 0;
}

#nav a {
    color: #4aaeac;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    font-size: 0.85rem;
}

#nav a:hover {
    color: #3a8e8c;
    text-decoration: underline;
    text-decoration-thickness: 2px;
    text-underline-offset: 4px;
}

#backtoblog {
    text-align: center;
    margin-top: 16px;
    padding: 0;
}

#backtoblog a {
    color: #9ca3af;
    text-decoration: none;
    font-size: 0.8rem;
    transition: all 0.3s ease;
    font-weight: 500;
}

#backtoblog a:hover {
    color: #4aaeac;
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 2px;
}

/* Mensagens de erro e sucesso */
.login #login_error,
.login .message {
    background: #fef2f2;
    border-left: 4px solid #ef4444;
    color: #dc2626;
    padding: 16px 20px;
    margin-bottom: 25px;
    border-radius: 12px;
    font-size: 0.9rem;
    font-weight: 500;
    box-shadow: 0 2px 8px rgba(239, 68, 68, 0.1);
}

.login .message {
    background: #f0fdf4;
    border-left-color: #4aaeac;
    color: #3a8e8c;
    box-shadow: 0 2px 8px rgba(74, 174, 172, 0.1);
}

/* Animações */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(40px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}



.login-form-side {
    animation: fadeInUp 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.login-image-side {
    animation: fadeInRight 1s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Loading state */
.submit input:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}

/* Focus styles para acessibilidade */
.input:focus,
.submit input:focus {
    outline: 2px solid #4aaeac;
    outline-offset: 2px;
}

/* Responsividade */
@media (max-width: 1024px) {
    .login-container {
        max-width: 900px;
    }
    
    .login-form-side {
        padding: 60px 40px;
    }
    
    .login-image-content {
        padding: 40px 30px;
    }
    
    .login-image-content h2 {
        font-size: 2.4rem;
    }
}

@media (max-width: 768px) {
    .login-container {
        max-width: 300px;
        min-height: 350px;
    }

    .login-form-side {
        padding: 30px 25px;
    }

    .login-title h1 {
        font-size: 1.5rem;
    }
}

@media (max-width: 480px) {
    #login {
        padding: 15px;
    }
    
    .login-form-side {
        padding: 40px 25px;
    }
    
    .login-logo h1 {
        font-size: 1.6rem;
    }
    
    .input {
        padding: 14px 16px;
    }
    
    .submit input {
        padding: 14px 20px;
    }
}



/* Melhorias de performance */
.login-container {
    will-change: transform;
    backface-visibility: hidden;
}

.input,
.submit input {
    will-change: transform, box-shadow;
}
