/* auth.css - Páginas de autenticação do Portal Core */

:root {
    --auth-navy:   #0D1F3C;
    --auth-blue:   #1E5FC2;
    --auth-gold:   #C5A059;
    --auth-light:  #F8FAFC;
    --auth-text:   #1E293B;
    --auth-muted:  #64748B;
    --auth-border: #E2E8F0;
}

/* Reset do body para auth */
body {
    background: var(--auth-navy);
    font-family: 'Inter', sans-serif;
    margin: 0;
    padding: 0;
    min-height: 100vh;
}

/* Layout split tela cheia */
.auth-split {
    display: flex;
    min-height: 100vh;
}

/* ── Painel esquerdo (branding) ── */
.auth-brand-panel {
    flex: 0 0 44%;
    background: var(--auth-navy);
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 48px 40px;
}

/* Decoração geométrica — círculo superior direito */
.auth-brand-panel::before {
    content: '';
    position: absolute;
    top: -100px;
    right: -100px;
    width: 420px;
    height: 420px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(30,95,194,0.25) 0%, transparent 70%);
    pointer-events: none;
}

/* Decoração geométrica — círculo inferior esquerdo */
.auth-brand-panel::after {
    content: '';
    position: absolute;
    bottom: -80px;
    left: -80px;
    width: 340px;
    height: 340px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(197,160,89,0.15) 0%, transparent 70%);
    pointer-events: none;
}

/* Grade de pontos decorativa */
.auth-brand-dots {
    position: absolute;
    inset: 0;
    background-image: radial-gradient(rgba(255,255,255,0.06) 1px, transparent 1px);
    background-size: 28px 28px;
    pointer-events: none;
}

.auth-brand-inner {
    position: relative;
    z-index: 2;
    text-align: center;
    color: #fff;
    max-width: 340px;
    width: 100%;
}

/* Marca */
.auth-logo-mark {
    width: 68px;
    height: 68px;
    background: var(--auth-blue);
    border-radius: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
    font-weight: 800;
    color: #fff;
    margin: 0 auto 14px;
    box-shadow: 0 10px 30px rgba(30,95,194,0.45);
    letter-spacing: -0.5px;
}

.auth-brand-name {
    font-size: 1.9rem;
    font-weight: 700;
    color: #fff;
    letter-spacing: -0.5px;
    margin: 0 0 4px;
    line-height: 1;
}

.auth-brand-name span {
    color: var(--auth-gold);
}

.auth-brand-divider {
    width: 36px;
    height: 3px;
    background: var(--auth-gold);
    border-radius: 2px;
    margin: 14px auto 16px;
}

.auth-brand-tagline {
    font-size: 0.875rem;
    color: rgba(255,255,255,0.52);
    line-height: 1.65;
    margin: 0;
}

/* Lista de features */
.auth-features {
    list-style: none;
    padding: 0;
    margin: 28px 0 0;
    text-align: left;
}

.auth-features li {
    display: flex;
    align-items: center;
    gap: 12px;
    color: rgba(255,255,255,0.68);
    font-size: 0.84rem;
    padding: 9px 0;
    border-bottom: 1px solid rgba(255,255,255,0.07);
}

.auth-features li:last-child {
    border-bottom: none;
}

.auth-features li i {
    color: var(--auth-gold);
    width: 15px;
    flex-shrink: 0;
    font-size: 0.8rem;
}

/* ── Painel direito (formulário) ── */
.auth-form-panel {
    flex: 1;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 48px 40px;
}

.auth-form-box {
    width: 100%;
    max-width: 390px;
}

/* Logo mobile (visível apenas em telas pequenas) */
.auth-mobile-brand {
    display: none;
    align-items: center;
    gap: 10px;
    margin-bottom: 28px;
}

.auth-mobile-logo {
    width: 40px;
    height: 40px;
    background: var(--auth-blue);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    font-weight: 800;
    color: #fff;
}

.auth-mobile-brand-name {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--auth-text);
}

.auth-mobile-brand-name span {
    color: var(--auth-gold);
}

/* Cabeçalho do formulário */
.auth-form-title {
    font-size: 1.45rem;
    font-weight: 700;
    color: var(--auth-text);
    margin: 0 0 4px;
    letter-spacing: -0.3px;
}

.auth-form-subtitle {
    font-size: 0.855rem;
    color: var(--auth-muted);
    margin: 0 0 28px;
}

/* Flash messages */
.flash {
    border-radius: 10px;
    padding: 11px 14px;
    margin-bottom: 20px;
    font-size: 0.855rem;
    display: flex;
    align-items: flex-start;
    gap: 10px;
    line-height: 1.45;
}

.flash i {
    margin-top: 1px;
    flex-shrink: 0;
}

.flash.success {
    background: #ECFDF5;
    border: 1px solid #A7F3D0;
    color: #065F46;
}

.flash.error {
    background: #FEF2F2;
    border: 1px solid #FECACA;
    color: #991B1B;
}

/* Campos */
.auth-field {
    margin-bottom: 16px;
}

.auth-label {
    display: block;
    font-size: 0.79rem;
    font-weight: 600;
    color: var(--auth-text);
    margin-bottom: 6px;
    letter-spacing: 0.1px;
}

.auth-input {
    width: 100%;
    padding: 0.74rem 1rem;
    border: 1.5px solid var(--auth-border);
    border-radius: 10px;
    font-size: 0.9rem;
    font-family: 'Inter', sans-serif;
    color: var(--auth-text);
    background: #fff;
    transition: border-color 0.18s, box-shadow 0.18s;
    box-sizing: border-box;
    appearance: none;
}

.auth-input:focus {
    outline: none;
    border-color: var(--auth-blue);
    box-shadow: 0 0 0 3px rgba(30,95,194,0.1);
}

.auth-input::placeholder {
    color: #94A3B8;
}

/* Wrapper senha com toggle */
.auth-pw-wrap {
    position: relative;
}

.auth-pw-wrap .auth-input {
    padding-right: 2.8rem;
}

.auth-pw-toggle {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--auth-muted);
    cursor: pointer;
    padding: 4px;
    display: flex;
    align-items: center;
    font-size: 0.88rem;
    transition: color 0.18s;
    line-height: 1;
}

.auth-pw-toggle:hover {
    color: var(--auth-blue);
}

/* Botão principal */
.auth-btn {
    width: 100%;
    padding: 0.8rem;
    background: var(--auth-blue);
    color: #fff;
    border: none;
    border-radius: 10px;
    font-size: 0.93rem;
    font-weight: 600;
    font-family: 'Inter', sans-serif;
    cursor: pointer;
    margin-top: 8px;
    transition: background 0.18s, box-shadow 0.18s, transform 0.1s;
    box-shadow: 0 4px 16px rgba(30,95,194,0.28);
    letter-spacing: 0.1px;
}

.auth-btn:hover {
    background: #1751A8;
    box-shadow: 0 6px 22px rgba(30,95,194,0.38);
}

.auth-btn:active {
    transform: scale(0.99);
}

/* Links rodapé */
.auth-links {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 20px;
}

.auth-link {
    font-size: 0.815rem;
    font-weight: 500;
    color: var(--auth-blue);
    text-decoration: none;
    transition: color 0.18s;
}

.auth-link:hover {
    color: #1751A8;
    text-decoration: underline;
}

.auth-link-muted {
    font-size: 0.815rem;
    color: var(--auth-muted);
    text-decoration: none;
    transition: color 0.18s;
}

.auth-link-muted:hover {
    color: var(--auth-text);
}

/* ── Responsivo ── */
@media (max-width: 768px) {
    .auth-split {
        flex-direction: column;
    }

    .auth-brand-panel {
        display: none;
    }

    .auth-form-panel {
        background: var(--auth-light);
        padding: 36px 24px;
        min-height: 100vh;
        align-items: flex-start;
        padding-top: 48px;
    }

    .auth-form-box {
        max-width: 100%;
    }

    .auth-mobile-brand {
        display: flex;
    }
}
