/*
 * assets/css/style_Login.css
 * Folha de estilo exclusiva para a página de login.
 * Mantém o layout limpo e separado do CSS global.
 */

/* --- 1. Reset Básico --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: Arial, sans-serif;
}

/* --- 2. Body Específico do Login --- */
body.login-body {
    background-color: #e5e5e5;
    color: #333;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    height: auto;
    padding: 20px;
}

/* --- 3. Container Principal --- */
.login-container {
    display: flex;
    flex-direction: row;
    width: 900px;
    max-width: 100%;
    height: auto;
    min-height: 450px;
    box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.2);
    background-color: #ffffff;
    border-radius: 8px;
    overflow: hidden;
}

/* --- 4. Painel Esquerdo (Logo) --- */
.login-container .left-side {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background-color: #f9f9f9;
    border-right: 1px solid #ddd;
    padding: 20px;
    text-align: center;
}

.login-container .left-side img {
    width: 250px;
    max-width: 100%;
    margin-bottom: 10px;
}

.login-container .left-side p {
    font-size: 1.1em;
    color: #666;
    margin-top: 10px;
    line-height: 1.5;
}

.login-container .left-side p span {
    color: #946e10;
    font-weight: bold;
}

/* --- 5. Painel Direito (Formulário) --- */
.login-container .right-side {
    flex: 1;
    padding: 30px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    background: #ffffff;
}

/* --- 6. Grupos de Formulário --- */
.login-container .form-group {
    width: 100%;
    margin-bottom: 18px;
}

/* CORREÇÃO: Estilo dos campos de input */
.login-container .form-group input[type="email"],
.login-container .form-group input[type="password"] {
    width: 100%;
    padding: 12px 15px;
    font-size: 1em;
    border-radius: 8px;
    border: 1px solid #ddd;
    background-color: #f5f5f5;
    transition: all 0.3s ease;
}

.login-container .form-group input[type="email"]:focus,
.login-container .form-group input[type="password"]:focus {
    border-color: #946e10;
    background-color: #fff;
    outline: none;
    box-shadow: 0 0 0 2px rgba(148, 110, 16, 0.1);
}

.login-container .form-group input[type="email"]::placeholder,
.login-container .form-group input[type="password"]::placeholder {
    color: #999;
}

/* Checkbox - Mantém inline com o label */
.login-container .checkbox-group {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 20px;
}

.login-container .checkbox-group input[type="checkbox"] {
    width: 16px;
    height: 16px;
    margin: 0;
    cursor: pointer;
    accent-color: #946e10;
}

.login-container .checkbox-group label {
    margin: 0;
    font-size: 0.85em;
    color: #555;
    cursor: pointer;
}

/* Link "Esqueci minha senha" */
.forgot-link {
    display: inline-block;
    margin-top: 8px;
    font-size: 0.8em;
    color: #946e10;
    text-decoration: none;
}

.forgot-link:hover {
    text-decoration: underline;
    color: #6b4f0c;
}

/* --- 7. Botão de Login --- */
.login-container .login-button {
    width: 100%;
    padding: 12px;
    background-color: #946e10;
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 1em;
    font-weight: bold;
    cursor: pointer;
    transition: background-color 0.3s;
}

.login-container .login-button:hover {
    background-color: #7a5a0e;
}

/* --- 8. Links de Navegação (Cadastro) --- */
.login-container .signup-link {
    margin-top: 20px;
    font-size: 0.9em;
    text-align: center;
    color: #666;
}

.login-container .signup-link a {
    color: #946e10;
    text-decoration: none;
    font-weight: bold;
}

.login-container .signup-link a:hover {
    text-decoration: underline;
}

/* --- 9. Mensagens de Feedback (Erro/Sucesso) --- */
.login-feedback-message {
    padding: 12px 15px;
    margin-bottom: 20px;
    border-radius: 8px;
    text-align: left;
    font-weight: 600;
    font-size: 0.95em;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
}

/* Ícone antes da mensagem */
.login-feedback-message::before {
    font-size: 1.2em;
}

/* Estilo para mensagens de erro */
.login-feedback-message.error {
    background-color: #fee2e2;
    color: #991b1b;
    border: 1px solid #f87171;
    border-left: 5px solid #dc2626;
}

.login-feedback-message.error::before {
    content: '⚠️';
}

/* Estilo para mensagens de sucesso */
.login-feedback-message.success {
    background-color: #dcfce7;
    color: #166534;
    border: 1px solid #86efac;
    border-left: 5px solid #22c55e;
}

.login-feedback-message.success::before {
    content: '✅';
}

/* --- 10. Animação de Shake para Erro --- */
@keyframes shake {
    0% { transform: translateX(0); }
    25% { transform: translateX(-5px); }
    50% { transform: translateX(5px); }
    75% { transform: translateX(-5px); }
    100% { transform: translateX(0); }
}

/* --- 11. Responsividade Mobile --- */
@media (max-width: 768px) {
    body.login-body {
        padding: 15px;
    }
    
    .login-container {
        flex-direction: column;
        width: 100%;
        max-width: 400px;
        height: auto;
        min-height: auto;
        border-radius: 12px;
    }

    .login-container .left-side {
        padding: 25px 20px;
        border-right: none;
        border-bottom: 1px solid #ddd;
    }

    .login-container .left-side img {
        width: 180px;
    }

    .login-container .left-side p {
        font-size: 0.9em;
    }

    .login-container .right-side {
        padding: 25px 20px;
    }
    
    .login-feedback-message {
        font-size: 0.85em;
        padding: 10px 12px;
    }
}

/* --- 12. Dispositivos Muito Pequenos (<= 480px) --- */
@media (max-width: 480px) {
    .login-container .left-side img {
        width: 150px;
    }
    
    .login-container .left-side p {
        font-size: 0.8em;
    }
    
    .login-container .right-side {
        padding: 20px 15px;
    }
    
    .login-container .form-group input[type="email"],
    .login-container .form-group input[type="password"] {
        padding: 10px 12px;
    }
    
    .login-button {
        padding: 10px;
    }
}

/* ============================================
   CORREÇÃO DO FOOTER NA PÁGINA DE LOGIN
   ============================================ */

/* Remove o footer padrão escuro e aplica estilo dourado */
body.login-body footer {
    background: transparent !important;
    border-top: 1px solid rgba(148, 110, 16, 0.3) !important;
    color: #946e10 !important;
    position: relative;
    margin-top: 30px;
    padding: 15px !important;
}

body.login-body footer span {
    color: #946e10 !important;
}

body.login-body footer span:first-child {
    color: #d4a11e !important;
    font-weight: bold;
}

/* Garante que o container de login não seja afetado */
body.login-body {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.login-container {
    flex-shrink: 0;
}