:root {
    /* Fallbacks caso o theme.js demore (opcional, pois global.css já define) */
    --primary: #0d6efd;
}

body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-color: var(--bg-body);
    color: var(--text-main);
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
}

.login-container {
    background: var(--bg-card);
    padding: 40px;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    width: 100%;
    max-width: 380px;
    text-align: center;
}

.logo-area { margin-bottom: 30px; }
.logo-area img { max-height: 60px; max-width: 100%; }
.logo-area h2 { margin: 10px 0 0; color: var(--primary); font-size: 1.5rem; }

.input-group { margin-bottom: 20px; text-align: left; color: var(--text-main); }
.input-group label { display: block; font-size: 0.9rem; color: var(--text-muted); margin-bottom: 5px; font-weight: 500; }

.input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.input-wrapper i {
    position: absolute;
    left: 12px;
    color: var(--text-muted);
    opacity: 0.7;
}

.input-wrapper input {
    width: 100%;
    padding: 12px 12px 12px 35px; /* Espaço para o ícone */
    border: 1px solid var(--border-color);
    background-color: var(--bg-card);
    color: var(--text-main);
    border-radius: 8px;
    font-size: 1rem;
    outline: none;
    transition: border-color 0.2s;
    box-sizing: border-box;
}

.input-wrapper input:focus { border-color: var(--primary); }

.toggle-pass {
    left: auto !important;
    right: 12px;
    cursor: pointer;
}

.actions {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 25px;
    font-size: 0.9rem;
}
.actions a { color: var(--text-muted); text-decoration: none; }
.actions a:hover { color: var(--primary); text-decoration: underline; }

button {
    width: 100%;
    padding: 12px;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: opacity 0.2s;
    margin-bottom: 10px;
}

.btn-primary { background-color: var(--primary); color: #fff; }
.btn-primary:hover { opacity: 0.9; }

.btn-secondary { background-color: rgba(0,0,0,0.05); color: var(--text-main); }
.btn-secondary:hover { background-color: rgba(0,0,0,0.1); }

.msg-erro {
    margin-top: 15px;
    padding: 10px;
    border-radius: 6px;
    background-color: #fdecea;
    color: #dc3545;
    font-size: 0.9rem;
    border: 1px solid #f5c6cb;
}

/* Lista de Perfis */
.profile-list { display: flex; flex-direction: column; gap: 10px; margin-bottom: 20px; }
.profile-btn {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    color: var(--text-main);
    padding: 15px;
    border-radius: 8px;
    text-align: left;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: all 0.2s;
}
.profile-btn:hover { border-color: var(--primary); background-color: rgba(var(--primary-rgb), 0.05); }
.profile-btn i { color: var(--primary); font-size: 1.2rem; }

.alert-box {
    background: #fff3cd;
    color: #856404;
    padding: 10px;
    border-radius: 6px;
    margin-bottom: 20px;
    font-size: 0.9rem;
}

.hidden { display: none !important; }
.fade-in { animation: fadeIn 0.3s ease-in; }
@keyframes fadeIn { from { opacity:0; } to { opacity:1; } }