/* ==========================================================
   CONFIGURAÇÃO GERAL
   ========================================================== */

:root {
    --primary: #172033;
    --primary-dark: #0f172a;
    --text: #1f2937;
    --text-muted: #64748b;
    --border: #e5e7eb;
    --background: #f6f8fb;
    --white: #ffffff;
}

* {
    box-sizing: border-box;
}

html,
body {
    min-height: 100%;
}

body {
    margin: 0;
    background: var(--background);
    color: var(--text);
}


/* ==========================================================
   SIDEBAR
   ========================================================== */

.sidebar {
    width: 250px;
    min-height: 100vh;
    background: #111827;
    color: #fff;
    flex-shrink: 0;
}

.brand {
    font-size: 1.25rem;
    font-weight: 700;
    letter-spacing: -.3px;
}

.sidebar .nav-link {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #cbd5e1;
    border-radius: 8px;
    padding: 9px 12px;
    transition:
        background-color .15s ease,
        color .15s ease;
}

.sidebar .nav-link:hover {
    background: #1f2937;
    color: #fff;
}

.sidebar .nav-link.active {
    background: #334155;
    color: #fff;
}

.sidebar .nav-link i {
    width: 20px;
    text-align: center;
    font-size: 1rem;
}


/* ==========================================================
   TOPO
   ========================================================== */

.topbar {
    min-height: 64px;
    background: #fff;
    border-bottom: 1px solid var(--border);
}

.topbar strong {
    color: #172033;
    font-weight: 650;
}


/* ==========================================================
   CONTEÚDO
   ========================================================== */

.card {
    border: 0;
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(15, 23, 42, .05);
}

.stat {
    font-size: 1.8rem;
    font-weight: 700;
}

.table td,
.table th {
    vertical-align: middle;
}


/* ==========================================================
   BOTÕES
   ========================================================== */

.btn {
    border-radius: 8px;
}

.btn-dark {
    background: var(--primary);
    border-color: var(--primary);
}

.btn-dark:hover {
    background: var(--primary-dark);
    border-color: var(--primary-dark);
}


/* ==========================================================
   FORMULÁRIOS
   ========================================================== */

.form-control,
.form-select {
    border-radius: 8px;
    border-color: #d9e0e8;
}

.form-control:focus,
.form-select:focus {
    border-color: #64748b;
    box-shadow: 0 0 0 3px rgba(100, 116, 139, .10);
}


/* ==========================================================
   LOGIN
   ========================================================== */

.login-page {
    min-height: 100vh;
    background: #f7f9fc;
}


/* ==========================================================
   ESTRUTURA DO LOGIN
   ========================================================== */

.login-shell {
    min-height: 100vh;
    display: flex;
    background: #f7f9fc;
}


/* ==========================================================
   PAINEL ESQUERDO
   ========================================================== */

.login-brand-panel {
    width: 42%;
    min-height: 100vh;
    position: relative;
    overflow: hidden;

    background:
        radial-gradient(
            circle at 80% 20%,
            rgba(59, 130, 246, .20),
            transparent 35%
        ),
        linear-gradient(
            145deg,
            #0f172a 0%,
            #172554 55%,
            #1e3a5f 100%
        );

    color: #fff;
}


/* Elementos decorativos */

.login-brand-panel::before {
    content: "";
    position: absolute;

    width: 520px;
    height: 520px;

    right: -260px;
    bottom: -280px;

    border: 1px solid rgba(255, 255, 255, .08);
    border-radius: 50%;
}

.login-brand-panel::after {
    content: "";
    position: absolute;

    width: 360px;
    height: 360px;

    right: -180px;
    bottom: -190px;

    border: 1px solid rgba(255, 255, 255, .06);
    border-radius: 50%;
}


/* ==========================================================
   CONTEÚDO DO PAINEL ESQUERDO
   ========================================================== */

.login-brand-content {
    position: relative;
    z-index: 2;

    width: min(500px, 80%);

    margin: 0 auto;

    padding: 80px 0 50px;
}


/* Logo */

.login-brand-icon {
    width: 72px;
    height: 72px;

    display: flex;
    align-items: center;
    justify-content: center;

    margin-bottom: 28px;

    border-radius: 18px;

    background: rgba(255, 255, 255, .10);
    border: 1px solid rgba(255, 255, 255, .12);

    box-shadow: 0 15px 35px rgba(0, 0, 0, .18);

    font-size: 32px;
}


/* Título */

.login-brand-content h1 {
    margin: 0;

    color: #fff;

    font-size: clamp(2.4rem, 4vw, 3.5rem);
    line-height: 1.05;

    font-weight: 750;

    letter-spacing: -1.5px;
}


/* Descrição */

.login-brand-description {
    margin: 24px 0 50px;

    color: #cbd5e1;

    font-size: 1.2rem;
    line-height: 1.55;
}


/* ==========================================================
   RECURSOS DO SISTEMA
   ========================================================== */

.login-features {
    display: flex;
    flex-direction: column;
    gap: 28px;
}

.login-feature {
    display: flex;
    align-items: center;
    gap: 18px;
}

.login-feature-icon {
    width: 56px;
    height: 56px;

    min-width: 56px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 50%;

    background: rgba(255, 255, 255, .12);
    border: 1px solid rgba(255, 255, 255, .08);

    color: #fff;

    font-size: 21px;
}

.login-feature strong {
    display: block;

    margin-bottom: 4px;

    color: #fff;

    font-size: 1rem;
    font-weight: 650;
}

.login-feature span {
    display: block;

    color: #cbd5e1;

    font-size: .92rem;
}


/* ==========================================================
   RODAPÉ DO PAINEL
   ========================================================== */

.login-brand-footer {
    margin-top: 70px;

    display: flex;
    flex-direction: column;
    gap: 5px;

    color: #94a3b8;

    letter-spacing: 2px;
}

.login-brand-footer span {
    display: block;

    width: 68px;
    height: 2px;

    margin-bottom: 12px;

    background: rgba(255, 255, 255, .45);
}

.login-brand-footer small {
    font-size: .72rem;
}


/* ==========================================================
   ÁREA DO FORMULÁRIO
   ========================================================== */

.login-form-panel {
    width: 58%;
    min-height: 100vh;

    display: flex;
    align-items: center;
    justify-content: center;

    padding: 50px;

    background:
        radial-gradient(
            circle at 20% 15%,
            rgba(59, 130, 246, .05),
            transparent 30%
        ),
        #f7f9fc;
}


/* ==========================================================
   CARTÃO DO LOGIN
   ========================================================== */

.login-form-card {
    width: min(570px, 100%);

    padding: 48px 52px;

    background: #fff;

    border: 1px solid #e8edf4;
    border-radius: 22px;

    box-shadow:
        0 25px 70px rgba(15, 23, 42, .10),
        0 5px 20px rgba(15, 23, 42, .04);
}


/* ==========================================================
   CABEÇALHO DO LOGIN
   ========================================================== */

.login-form-header {
    text-align: center;

    margin-bottom: 36px;
}

.login-form-icon {
    width: 62px;
    height: 62px;

    display: flex;
    align-items: center;
    justify-content: center;

    margin: 0 auto 18px;

    border-radius: 16px;

    background: #172033;

    color: #fff;

    font-size: 27px;

    box-shadow:
        0 10px 25px rgba(15, 23, 42, .16);
}

.login-form-header h2 {
    margin: 0;

    color: #172033;

    font-size: 2rem;
    font-weight: 750;

    letter-spacing: -.7px;
}

.login-form-header p {
    margin: 8px 0 0;

    color: #718096;

    font-size: 1rem;
}


/* ==========================================================
   CAMPOS DO LOGIN
   ========================================================== */

.login-form .form-label {
    color: #172033;

    font-weight: 500;

    margin-bottom: 8px;
}

.login-input-group {
    display: flex;
    align-items: stretch;

    overflow: hidden;

    border: 1px solid #d9e0e8;
    border-radius: 10px;

    background: #fff;

    transition:
        border-color .2s ease,
        box-shadow .2s ease;
}

.login-input-group:focus-within {
    border-color: #64748b;

    box-shadow:
        0 0 0 3px rgba(100, 116, 139, .10);
}

.login-input-icon {
    width: 52px;
    min-width: 52px;

    display: flex;
    align-items: center;
    justify-content: center;

    color: #334155;

    background: #f8fafc;

    border-right: 1px solid #e2e8f0;

    font-size: 18px;
}

.login-input-group .form-control {
    height: 52px;

    border: 0;

    box-shadow: none !important;

    padding-left: 15px;
    padding-right: 15px;
}

.login-input-group .form-control::placeholder {
    color: #94a3b8;
}


/* ==========================================================
   BOTÃO MOSTRAR SENHA
   ========================================================== */

.login-password-toggle {
    width: 52px;
    min-width: 52px;

    border: 0;

    background: #fff;

    color: #64748b;

    font-size: 18px;

    transition: color .15s ease;
}

.login-password-toggle:hover {
    color: #172033;
}


/* ==========================================================
   BOTÃO ENTRAR
   ========================================================== */

.login-submit {
    height: 54px;

    border: 0;
    border-radius: 10px;

    background: #172033;

    color: #fff;

    font-size: 1.05rem;
    font-weight: 600;

    transition:
        transform .15s ease,
        box-shadow .15s ease,
        background-color .15s ease;
}

.login-submit:hover {
    background: #0f172a;

    color: #fff;

    transform: translateY(-1px);

    box-shadow:
        0 10px 25px rgba(15, 23, 42, .18);
}

.login-submit:active {
    transform: translateY(0);
}


/* ==========================================================
   ALERTA DE LOGIN
   ========================================================== */

.login-alert {
    border-radius: 10px;

    margin-bottom: 22px;
}


/* ==========================================================
   DIVISOR
   ========================================================== */

.login-divider {
    display: flex;
    align-items: center;

    gap: 15px;

    margin: 30px 0 22px;

    color: #94a3b8;

    font-size: .85rem;
}

.login-divider::before,
.login-divider::after {
    content: "";

    height: 1px;

    flex: 1;

    background: #e2e8f0;
}


/* ==========================================================
   COPYRIGHT
   ========================================================== */

.login-copyright {
    text-align: center;

    color: #475569;

    font-size: .88rem;
    line-height: 1.7;
}

.login-copyright span {
    color: #94a3b8;
}


/* ==========================================================
   RESPONSIVIDADE
   ========================================================== */

@media (max-width: 991.98px) {

    .login-brand-panel {
        width: 38%;
    }

    .login-form-panel {
        width: 62%;
        padding: 30px;
    }

    .login-form-card {
        padding: 38px 32px;
    }

    .login-brand-content {
        width: 82%;
    }

    .login-brand-content h1 {
        font-size: 2.35rem;
    }
}


@media (max-width: 767.98px) {

    .login-shell {
        display: block;
    }

    .login-brand-panel {
        width: 100%;
        min-height: auto;
    }

    .login-brand-content {
        width: 90%;
        padding: 38px 0;
    }

    .login-brand-content h1 {
        font-size: 2.2rem;
    }

    .login-brand-description {
        margin-bottom: 30px;
        font-size: 1rem;
    }

    .login-features {
        display: none;
    }

    .login-brand-footer {
        display: none;
    }

    .login-brand-icon {
        width: 58px;
        height: 58px;

        font-size: 25px;

        margin-bottom: 18px;
    }

    .login-form-panel {
        width: 100%;
        min-height: auto;

        padding: 25px 18px 40px;
    }

    .login-form-card {
        padding: 32px 22px;

        border-radius: 18px;
    }

    .login-form-header h2 {
        font-size: 1.65rem;
    }
}


@media (max-width: 480px) {

    .login-brand-content {
        padding: 30px 0;
    }

    .login-form-panel {
        padding: 18px 12px 30px;
    }

    .login-form-card {
        padding: 28px 18px;
        border-radius: 16px;
    }

    .login-form-header {
        margin-bottom: 28px;
    }

    .login-form-header h2 {
        font-size: 1.5rem;
    }

    .login-input-icon {
        width: 46px;
        min-width: 46px;
    }

    .login-password-toggle {
        width: 46px;
        min-width: 46px;
    }
}