/* GJR — telas públicas da área restrita (login, recuperar e redefinir senha) */
html:has(body.gjr-auth), body.gjr-auth { background: #f3f5f8 !important; margin: 0; }
body.gjr-auth { color: #1d2736; font-size: 16px; line-height: 1.55; }
.gjr-auth *, .gjr-auth *::before { box-sizing: border-box; }

.auth { min-height: 100vh; display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); }

/* Painel lateral */
.auth-aside { background: #1d2736; color: #fff; position: relative; overflow: hidden; display: flex; align-items: center; justify-content: center; padding: 48px; }
.auth-aside::before { content: ""; position: absolute; inset: 0; background: radial-gradient(70% 60% at 30% 30%, rgba(0, 113, 188, .45), transparent 70%), radial-gradient(50% 40% at 90% 100%, rgba(232, 73, 29, .18), transparent 70%); }
.auth-aside-inner { position: relative; max-width: 360px; }
.auth-art { width: 220px; height: 220px; display: block; margin-bottom: 28px; }
.auth-aside h2 { font-family: Manrope, Inter, sans-serif; font-weight: 800; font-size: 40px; line-height: 1.05; margin: 0 0 12px; color: #fff !important; }
.auth-aside p { color: #b9c5d6; font-size: 17px; margin: 0; }

/* Área do formulário */
.auth-main { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 40px 24px 24px; }
.auth-box { width: 100%; max-width: 420px; background: #fff; border: 1px solid #e1e6ee; border-radius: 18px; padding: 40px 36px; box-shadow: 0 20px 50px -28px rgba(29, 39, 54, .35); }
.auth-logo { display: inline-block; margin-bottom: 28px; }
.auth-logo img { height: 52px; width: auto; display: block; }
.auth-box h1 { font-family: Manrope, Inter, sans-serif; font-weight: 800; font-size: 28px; line-height: 1.15; margin: 0 0 8px; color: #1d2736; letter-spacing: -.01em; }
.auth-sub { color: #5b6678; margin: 0 0 28px; font-size: 15px; }
.auth-rodape { color: #8792a3; font-size: 13px; margin: 24px 0 0; }

/* Campos */
.auth-field { margin-bottom: 18px; }
.auth-field label { display: block; font-weight: 600; font-size: 14px; margin-bottom: 6px; color: #1d2736; }
.auth-input { position: relative; display: flex; align-items: center; }
.auth-input > i { position: absolute; left: 14px; color: #8792a3; font-size: 17px; pointer-events: none; }
.auth-input input { width: 100%; height: 50px; padding: 0 48px 0 44px; border: 1.5px solid #d6dde7; border-radius: 12px; font: inherit; font-size: 16px; color: #1d2736; background: #fbfcfd; transition: border-color .15s, box-shadow .15s, background .15s; }
.auth-input input:focus { outline: none; border-color: #0071bc; background: #fff; box-shadow: 0 0 0 4px rgba(0, 113, 188, .14); }
.auth-input input[aria-invalid="true"] { border-color: #c0392b; }
.auth-olho { position: absolute; right: 4px; width: 42px; height: 42px; border: 0; background: none; color: #5b6678; border-radius: 10px; cursor: pointer; font-size: 18px; }
.auth-olho:hover { background: #eef2f7; color: #1d2736; }
.auth-olho:focus-visible, .auth-btn:focus-visible, .auth-links a:focus-visible { outline: 3px solid #0071bc; outline-offset: 2px; }

/* Botões */
.auth-btn { width: 100%; height: 52px; border: 0; border-radius: 12px; background: #1d2736; color: #fff !important; font: 600 16px/1 Inter, sans-serif; display: inline-flex; align-items: center; justify-content: center; gap: 8px; cursor: pointer; text-decoration: none; margin-top: 6px; transition: background .15s; }
.auth-btn:hover { background: #0071bc; }
.auth-btn:disabled { opacity: .7; cursor: default; }
.auth-btn.sec { background: #fff; color: #1d2736 !important; border: 1.5px solid #d6dde7; }
.auth-btn.sec:hover { background: #f3f5f8; }
.auth-spin { width: 16px; height: 16px; border: 2px solid rgba(255, 255, 255, .4); border-top-color: #fff; border-radius: 50%; animation: auth-gira .7s linear infinite; }
@keyframes auth-gira { to { transform: rotate(360deg); } }

.auth-links { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; margin-top: 22px; font-size: 14px; }
.auth-links a { color: #0071bc; text-decoration: none; font-weight: 500; }
.auth-links a:hover { text-decoration: underline; }
.auth-links.centro { justify-content: center; }

/* Mensagens */
.auth-alert { display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; border-radius: 12px; margin-bottom: 22px; font-size: 15px; }
.auth-alert > i { font-size: 19px; line-height: 1.3; }
.auth-alert ul { margin: 4px 0 0; padding-left: 18px; }
.auth-alert.erro { background: #fdecea; color: #8c2318; }
.auth-alert.ok { background: #e6f5ee; color: #155f3c; }
.auth-alert.aviso { background: #fff4e0; color: #7a4a00; }
.auth-alert.info { background: #e6f1fa; color: #0b4a78; }

/* Requisitos da senha */
.auth-req { list-style: none; margin: -4px 0 20px; padding: 14px 16px; background: #f6f8fb; border-radius: 12px; display: grid; grid-template-columns: 1fr 1fr; gap: 6px 12px; font-size: 13.5px; color: #5b6678; }
.auth-req li { display: flex; gap: 7px; align-items: center; }
.auth-req li i { font-size: 15px; color: #a9b3c2; }
.auth-req li.ok { color: #155f3c; }
.auth-req li.ok i { color: #1e8e5a; }
.auth-forca { height: 6px; border-radius: 3px; background: #e6eaf0; margin: -8px 0 16px; overflow: hidden; }
.auth-forca span { display: block; height: 100%; width: 0; border-radius: 3px; background: #c0392b; transition: width .2s, background .2s; }
.auth-confere { font-size: 13px; margin: -10px 0 16px; min-height: 18px; }
.auth-confere.ok { color: #1e8e5a; }
.auth-confere.nao { color: #c0392b; }
.auth-icone-topo { width: 56px; height: 56px; border-radius: 16px; display: grid; place-items: center; font-size: 26px; margin-bottom: 18px; }
.auth-icone-topo.ok { background: #e6f5ee; color: #1e8e5a; }
.auth-icone-topo.aviso { background: #fff4e0; color: #d98e04; }
.auth-icone-topo.erro { background: #fdecea; color: #c0392b; }

@media (max-width: 900px) {
    .auth { grid-template-columns: 1fr; }
    .auth-aside { display: none; }
    body.gjr-auth { background: linear-gradient(180deg, #1d2736 0 180px, #f3f5f8 180px) !important; }
    .auth-main { justify-content: flex-start; padding-top: 48px; }
}
@media (max-width: 480px) {
    .auth-box { padding: 30px 22px; border-radius: 16px; }
    .auth-req { grid-template-columns: 1fr; }
    .auth-box h1 { font-size: 25px; }
}
@media (prefers-reduced-motion: reduce) { .auth-spin { animation: none; } }
