/* 1. IMPORTAÇÃO E VARIÁVEIS */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');

:root {
    --h-brand-purple: #673de6;
    --h-brand-purple-dark: #4e29bb;
    --h-bg-main: #ffffff;
    --h-bg-alt: #f4f5f9; /* Tom cinza suave padrão Hostinger */
    --h-text-main: #2d3143;
    --h-text-muted: #727586;
    --h-border: #e2e5ed;
    --h-radius-md: 12px;
    --h-radius-lg: 24px;
    --h-shadow: 0 4px 14px rgba(0, 0, 0, 0.08);
}

/* 2. RESET E CONFIGURAÇÃO GLOBAL */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', sans-serif;
    -webkit-font-smoothing: antialiased;
}

html { 
    font-size: 62.5%; /* Facilita o uso de REM (1rem = 10px) */
}

body {
    background-color: var(--h-bg-alt);
    color: var(--h-text-main);
    font-size: 1.6rem;
    line-height: 1.5;
}

/* 3. LAYOUT E CONTAINER */
.container-login {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    overflow-x: hidden; /* Evita scroll lateral durante animações */
}

.login-card {
    background: var(--h-bg-main);
    width: 100%;
    max-width: 420px;
    padding: 40px;
    border-radius: var(--h-radius-md);
    box-shadow: var(--h-shadow);
    text-align: center;
}

/* 4. TIPOGRAFIA */
.brand-title {
    color: var(--h-brand-purple);
    font-size: 2.8rem;
    font-weight: 800;
    letter-spacing: -1px;
    margin-bottom: 5px;
}

.slogan {
    color: var(--h-text-muted);
    font-size: 1.4rem;
    margin-bottom: 25px;
}

.description {
    font-size: 1.4rem;
    color: var(--h-text-muted);
    line-height: 1.6;
    margin-bottom: 20px;
}

/* 5. ALERTAS E FEEDBACK */
.alert-error {
    background-color: #fee2e2;
    color: #dc2626;
    padding: 12px;
    border-radius: 8px;
    font-size: 1.3rem;
    margin-bottom: 20px;
    border: 1px solid #fecaca;
    font-weight: 500;
}

/* 6. FORMULÁRIOS */
.campo {
    text-align: left;
    margin-bottom: 18px;
}

.campo-titulo {
    display: block;
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--h-text-main);
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

input {
    width: 100%;
    padding: 14px;
    border: 1px solid var(--h-border);
    border-radius: 8px;
    font-size: 1.5rem;
    transition: all 0.3s ease;
}

input:focus {
    outline: none;
    border-color: var(--h-brand-purple);
    box-shadow: 0 0 0 4px rgba(103, 61, 230, 0.1);
}

/* 7. BOTÕES */
.btn-principal {
    width: 100%;
    padding: 16px;
    background-color: var(--h-brand-purple);
    color: white;
    border: none;
    border-radius: var(--h-radius-lg);
    font-size: 1.6rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    margin-top: 10px;
}

.btn-principal:hover {
    background-color: var(--h-brand-purple-dark);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(103, 61, 230, 0.25);
}

.btn-principal:active {
    transform: translateY(0);
}

/* 8. LINKS E NAVEGAÇÃO */
.link-recuperar {
    text-align: right;
    margin-top: 5px;
}

.link-discreto, .footer-links p {
    margin-top: 20px;
    font-size: 1.3rem;
    color: var(--h-text-muted);
}

.link-discreto a, .footer-links a, .link-recuperar a {
    color: var(--h-brand-purple);
    text-decoration: none;
    font-weight: 700;
    transition: opacity 0.2s;
}

.link-discreto a:hover, .footer-links a:hover, .link-recuperar a:hover {
    opacity: 0.8;
    text-decoration: underline;
}

/* 9. ANIMAÇÕES SWUP JS */
.transition-fade {
   opacity: 1;
   transition: 500ms;
   transform: translateX(0);
   transform-origin: left;
}
html.is-changing body{
    overflow: hidden;
}
/* Quando a página está trocando */
html.is-animating .transition-fade {
    opacity: 0;
    transform: translateX(100%) /* Card sobe levemente enquanto desaparece */
}
html.is-leaving .transition-fade{
    opacity: 0;
    transform: translateX(0);
}

/* 10. RESPONSIVIDADE */

@media (max-width: 480px) {
    .container-login {
        padding: 10px;
    }
    
    .login-card {
        padding: 30px 20px;
        box-shadow: none; /* Simplifica o visual em telas pequenas */
        border: 1px solid var(--h-border);
    }
    
    .brand-title {
        font-size: 2.4rem;
    }
}