/* ==========================================================================
   Telas de autenticação administrativa (login, esqueci-senha, registro).
   Layout de 2 colunas: hero administrativo (esquerda) + card (direita).
   Fonte única do visual; o hero vem do fragment fragments/auth-admin-hero.html.
   ========================================================================== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
:root {
    --primary: #0D9488;
    --primary-600: #0F766E;
    --deep: #115E59;
    --teal-300: #5EEAD4;
    --light: #CCFBF1;
    --slate-900: #0F172A;
    --slate-800: #1E293B;
    --slate-700: #334155;
    --slate-400: #94A3B8;
    --slate-300: #CBD5E1;
    --slate-100: #F1F5F9;
    --bg: #F8FAFC;
    --white: #FFFFFF;
}
html, body { height: 100%; }
body { font-family: 'Inter', sans-serif; color: var(--slate-900); background: var(--bg); }

.split { display: grid; grid-template-columns: 1.05fr 1fr; min-height: 100vh; }

/* ---------- HERO administrativo (coluna esquerda) ---------- */
.hero {
    position: relative; overflow: hidden; color: #fff;
    /* Imagem de fundo (ondas verde-teal) sob overlay leve — a imagem ja e escura e no tom
       da marca, entao o overlay so tonaliza e garante contraste do texto branco (levemente
       mais forte a esquerda, onde fica o texto). Vale para login, registro e recuperacao
       (fragment 'hero'); a tela de selecao usa .hero--selecao.
       Imagem: Unsplash (unsplash.com/photos/V558Lx_ji6I) — licenca Unsplash (uso livre). */
    background:
        radial-gradient(1200px 600px at 15% -10%, rgba(13,148,136,.28) 0%, rgba(13,148,136,0) 60%),
        linear-gradient(105deg, rgba(2,6,23,.72) 0%, rgba(15,23,42,.55) 42%, rgba(19,78,74,.40) 100%),
        url('../img/hero-login.jpg');
    background-size: cover, cover, cover;
    background-position: center, center, center;
    background-repeat: no-repeat, no-repeat, no-repeat;
    display: flex; flex-direction: column; justify-content: space-between; padding: 56px 56px 40px;
}
.hero::after {
    content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .5;
    background-image:
        linear-gradient(rgba(255,255,255,.035) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,.035) 1px, transparent 1px);
    background-size: 44px 44px;
    mask-image: radial-gradient(900px 500px at 20% 20%, #000 0%, transparent 75%);
}
.hero .glow {
    position: absolute; width: 520px; height: 520px; border-radius: 50%;
    background: radial-gradient(circle, rgba(94,234,212,.22) 0%, rgba(94,234,212,0) 70%);
    top: -150px; right: -130px; pointer-events: none; animation: float 16s ease-in-out infinite;
}
@keyframes float { 0%,100% { transform: translateY(0) } 50% { transform: translateY(26px) } }

/* Modificador só da tela "Selecionar empresa": imagem de fundo (rede de conexões)
   sob um overlay escuro que preserva o contraste do texto branco. Não altera o .hero
   base (compartilhado com login/registro/recuperação).
   Imagem: Max Petrunin / Unsplash (unsplash.com/photos/KKx5r-w1dPo) — licença Unsplash
   (uso comercial livre, sem atribuição obrigatória). */
.hero--selecao {
    background:
        linear-gradient(150deg, rgba(19,78,74,.42) 0%, rgba(15,23,42,.55) 55%, rgba(2,6,23,.66) 100%),
        url('../img/hero-selecao.jpg');
    background-size: cover, cover;
    background-position: center, center;
    background-repeat: no-repeat, no-repeat;
}

.hero-top { position: relative; display: flex; align-items: center; gap: 16px; }
.hero-top .admin-badge {
    display: inline-flex; align-items: center; gap: 10px; font-size: 1rem; font-weight: 800;
    letter-spacing: 1px; text-transform: uppercase; color: var(--teal-300);
    background: rgba(94,234,212,.12); border: 1px solid rgba(94,234,212,.30);
    padding: 12px 22px; border-radius: 999px;
}
.hero-top .admin-badge i { font-size: 1.1rem; }

.hero-mid { position: relative; }
.hero-mid .eyebrow {
    display: inline-block; font-size: .72rem; font-weight: 700; letter-spacing: 1.5px;
    text-transform: uppercase; color: var(--teal-300); margin-bottom: 18px;
}
.hero-mid h1 {
    font-size: 2.5rem; line-height: 1.14; font-weight: 800; letter-spacing: -1px;
    max-width: 20ch; color: #fff;
}
.hero-mid p.lead {
    margin-top: 16px; font-size: 1.02rem; color: #DDEDEA; max-width: 46ch; line-height: 1.55;
}
.hero-list { list-style: none; margin-top: 30px; display: flex; flex-direction: column; gap: 14px; }
.hero-list li { display: flex; align-items: center; gap: 12px; font-size: .98rem; color: #EAF4F2; }
.hero-list li i {
    display: grid; place-items: center; width: 26px; height: 26px; border-radius: 8px; flex: 0 0 26px;
    background: rgba(94,234,212,.16); color: var(--teal-300); font-size: .8rem;
}
.hero-foot { position: relative; display: flex; flex-wrap: wrap; gap: 10px; }
.trust {
    display: inline-flex; align-items: center; gap: 7px; font-size: .74rem; font-weight: 600;
    color: var(--slate-300); background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.10);
    padding: 7px 12px; border-radius: 999px;
}
.trust i { color: var(--teal-300); }

/* ---------- FORM / CARD (coluna direita) ---------- */
.panel { display: flex; align-items: center; justify-content: center; padding: 40px 24px; }
.card {
    width: 100%; max-width: 440px; background: var(--white); border-radius: 18px;
    border: 1px solid var(--slate-100); padding: 40px 36px;
    box-shadow: 0 18px 50px rgba(15,23,42,.10);
    animation: rise .5s cubic-bezier(.16,1,.3,1) both;
}
@keyframes rise { from { opacity: 0; transform: translateY(14px) } to { opacity: 1; transform: none } }
.card-logo { display: flex; justify-content: center; margin-bottom: 22px; }
.card-logo img { width: 92%; max-width: 340px; height: auto; display: block; }
.card h2 { font-size: 1.5rem; font-weight: 800; letter-spacing: -.5px; color: var(--slate-900); }
.card .subtitle { color: var(--slate-700); font-size: .92rem; margin: 6px 0 26px; }

.form-group { margin-bottom: 18px; }
.form-group label { display: block; font-size: .82rem; font-weight: 600; color: var(--slate-700); margin-bottom: 7px; }
.input-wrapper { position: relative; }
.form-group input {
    width: 100%; padding: 13px 16px; border-radius: 11px; border: 1.5px solid #E2E8F0;
    font-family: inherit; font-size: .96rem; color: var(--slate-900); background: #F8FAFC;
    outline: none; transition: border-color .18s, box-shadow .18s, background .18s;
}
.input-wrapper input { padding-right: 44px; }
.form-group input:focus { border-color: var(--primary); background: #fff; box-shadow: 0 0 0 4px rgba(13,148,136,.12); }
.input-wrapper .toggle-pass {
    position: absolute; right: 12px; top: 50%; transform: translateY(-50%);
    background: none; border: none; color: var(--slate-400); cursor: pointer; font-size: 1rem; padding: 4px;
}
.input-wrapper .toggle-pass:hover { color: var(--slate-700); }

/* linha de 2 campos lado a lado (ex.: email+telefone, senha+confirmar) */
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
@media (max-width: 480px) { .form-row { grid-template-columns: 1fr; } }

.form-row-between { display: flex; align-items: center; justify-content: space-between; margin: 22px 0; }
.checkbox-group { display: flex; align-items: center; gap: 8px; }
.checkbox-group input[type="checkbox"] { width: 16px; height: 16px; accent-color: var(--primary); }
.checkbox-group label { font-size: .85rem; color: var(--slate-700); font-weight: 500; cursor: pointer; }
.forgot-link { font-size: .85rem; color: var(--primary); font-weight: 600; text-decoration: none; }
.forgot-link:hover { text-decoration: underline; }
.btn-submit {
    width: 100%; padding: 14px; border-radius: 11px; border: none;
    background: var(--primary); color: var(--white); font-family: inherit;
    font-size: 1rem; font-weight: 700; cursor: pointer;
    transition: background .18s, transform .06s, box-shadow .18s;
    box-shadow: 0 8px 20px rgba(13,148,136,.28);
}
.btn-submit:hover { background: var(--primary-600); box-shadow: 0 10px 26px rgba(13,148,136,.34); }
.btn-submit:active { transform: translateY(1px); }

.auth-footer { text-align: center; margin-top: 22px; }
.auth-footer p { color: var(--slate-400); font-size: .85rem; }
.auth-footer a { color: var(--primary); font-weight: 600; text-decoration: none; }
.auth-footer a:hover { text-decoration: underline; }
.powered { text-align: center; margin-top: 26px; color: var(--slate-400); font-size: .75rem; }
.powered a { color: var(--primary); text-decoration: none; }
.powered .app-version { display: block; margin-top: 4px; font-family: 'SFMono-Regular', Consolas, monospace; opacity: .8; }

.alert, output.alert {
    padding: 12px 14px; border-radius: 11px; font-size: .86rem; font-weight: 500;
    margin-bottom: 18px; display: flex; align-items: center; gap: 8px;
}
.alert-danger { background: #FEF2F2; color: #B91C1C; border-left: 3px solid #DC2626; }
.alert-warning { background: #FEF3C7; color: #92400E; border-left: 3px solid #B45309; }
.alert-success { background: #F0FDF4; color: #166534; border-left: 3px solid #16A34A; }
.alert-info { background: #ECFEFF; color: #155E75; border-left: 3px solid #0891B2; }

a:focus-visible, button:focus-visible, input:focus-visible {
    outline: 2px solid var(--primary); outline-offset: 3px; border-radius: 4px;
}

@media (max-width: 860px) {
    .split { grid-template-columns: 1fr; }
    .hero { padding: 34px 28px; min-height: auto; }
    .hero-mid h1 { font-size: 1.9rem; }
    .hero-mid p.lead, .hero-list { display: none; }
    .hero-foot { margin-top: 20px; }
    .panel { padding: 28px 20px 44px; }
    .card { box-shadow: 0 10px 30px rgba(15,23,42,.12); }
}
