:root {
    --primary: #4318ff;
    --navy: #1b2559;
    --bg: #f4f7fe;
    --text-muted: #a3aed0;
}

body {
    background: var(--bg);
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Public Sans', sans-serif;
    margin: 0;
}

/* Card principal */
.login-card {
    background: white;
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0px 18px 40px rgba(112, 144, 176, 0.12);
    width: 100%;
    max-width: 400px;
    text-align: center;
}

/* Imagem */
.image-container {
    width: 100%;
    height: 140px;
    margin-bottom: 20px;
    padding: 0 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.image-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Título */
.brand-logo {
    color: var(--navy);
    font-weight: 800;
    font-size: 24px;
    margin-bottom: 20px;
}

/* --- AJUSTE PARA O OLHINHO DA SENHA --- */
.password-wrapper {
    position: relative;
    width: 100%;
}

.toggle-password {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
    color: var(--text-muted);
    font-size: 1.2rem;
    z-index: 10;
    transition: color 0.2s;
}

.toggle-password:hover {
    color: var(--primary);
}

/* Campos */
.form-control {
    border-radius: 12px;
    padding: 12px;
    border: 1px solid #d1d9e6;
    background-color: #f4f7fe;
    width: 100%;
    transition: all 0.2s;
}

.form-control:focus {
    background-color: white;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(67, 24, 255, 0.1);
    outline: none;
}

/* Espaço extra no input de senha para o ícone não sobrepor o texto */
input[type="password"], 
input[type="text"]#passwordField {
    padding-right: 45px;
}

/* Botão principal */
.btn-login {
    background: var(--primary);
    color: white;
    border-radius: 12px;
    padding: 12px;
    font-weight: 700;
    border: none;
    width: 100%;
    margin-top: 20px;
    transition: all 0.3s;
    cursor: pointer;
}

.btn-login:hover {
    background: #3311cc;
    transform: translateY(-2px);
}

/* Links e checkbox */
.form-check-label, a {
    font-size: 0.85rem;
}

.form-check-input {
    cursor: pointer;
}

a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
}

a:hover {
    text-decoration: underline;
}

/* Estilos de erro (Django) */
.alert-danger {
    background-color: #fdd8d5;
    color: #b31d13;
    border: none;
    border-left: 4px solid #e02b20;
    padding: 12px 14px;
    border-radius: 12px;
    font-size: 0.9rem;
    font-weight: 700;
}