:root {
    --auth-navy: #172a55;
    --auth-dark: #0f172a;
    --auth-blue: #0b84d8;
    --auth-cyan: #12b8e8;
    --auth-purple: #6e4bf2;
    --auth-bg: #f6f8fc;
    --auth-muted: #64748b;
    --auth-border: rgba(15, 23, 42, .1);
    --auth-shadow: 0 34px 90px rgba(15, 23, 42, .12);
}

.auth-page {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 100svh;
    padding: 56px 24px 24px;
    overflow: hidden;
    background:
        radial-gradient(circle at 8% 8%, rgba(18, 184, 232, .16), transparent 31%),
        radial-gradient(circle at 94% 12%, rgba(110, 75, 242, .17), transparent 34%),
        linear-gradient(180deg, #fff 0%, var(--auth-bg) 100%);
}

.auth-page::before,
.auth-page::after {
    position: fixed;
    border: 1px solid rgba(11, 132, 216, .09);
    border-radius: 50%;
    content: "";
    pointer-events: none;
}

.auth-page::before {
    right: -280px;
    bottom: -320px;
    width: min(620px, 68vw);
    height: min(620px, 68vw);
}

.auth-page::after {
    top: -220px;
    left: -210px;
    width: 410px;
    height: 410px;
}

.auth-site-link {
    position: absolute;
    z-index: 2;
    top: 20px;
    left: max(24px, calc((100vw - 1080px) / 2));
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--auth-muted);
    font-size: 14px;
    font-weight: 700;
}

.auth-site-link--label {
    cursor: default;
}

#authContainer.auth-card,
.auth-card {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: minmax(320px, .92fr) minmax(410px, 1fr);
    width: min(1080px, 100%);
    min-height: 700px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, .86);
    border-radius: 34px;
    background: #fff;
    box-shadow: var(--auth-shadow);
}

.auth-card--compact {
    width: min(980px, 100%);
    min-height: 620px;
    grid-template-columns: minmax(300px, .86fr) minmax(400px, 1fr);
}

.auth-brand-panel {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 42px;
    overflow: hidden;
    padding: 38px;
    color: #fff;
    background:
        radial-gradient(circle at 12% 10%, rgba(18, 184, 232, .47), transparent 38%),
        radial-gradient(circle at 92% 92%, rgba(110, 75, 242, .6), transparent 40%),
        linear-gradient(145deg, #13264d, #113b77 58%, #26175d);
}

.auth-brand-panel::before,
.auth-brand-panel::after {
    position: absolute;
    border: 1px solid rgba(255, 255, 255, .16);
    border-radius: 50%;
    content: "";
}

.auth-brand-panel::before {
    top: 150px;
    left: -148px;
    width: 450px;
    height: 280px;
    transform: rotate(-21deg);
}

.auth-brand-panel::after {
    right: -265px;
    bottom: -148px;
    width: 520px;
    height: 330px;
    transform: rotate(30deg);
}

.auth-orbit-dot {
    position: absolute;
    z-index: 1;
    top: 43%;
    left: 24%;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #5de0ff;
    box-shadow: 0 0 0 7px rgba(93, 224, 255, .13), 0 0 24px rgba(93, 224, 255, .65);
}

.auth-orbit-dot--secondary {
    top: auto;
    right: 21%;
    bottom: 24%;
    left: auto;
    width: 8px;
    height: 8px;
    background: #9f83ff;
}

.auth-panel-top,
.auth-panel-copy,
.auth-panel-features {
    position: relative;
    z-index: 1;
}

.auth-panel-top {
    display: flex;
    align-items: center;
    gap: 12px;
}

.auth-panel-logo {
    display: grid;
    place-items: center;
    width: 52px;
    height: 52px;
    padding: 7px;
    border-radius: 16px;
    background: rgba(255, 255, 255, .96);
}

.auth-panel-logo img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.auth-panel-name {
    font-size: 23px;
    font-weight: 800;
    letter-spacing: -.035em;
}

.auth-panel-eyebrow,
.auth-eyebrow {
    display: inline-flex;
    margin-bottom: 14px;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .13em;
    text-transform: uppercase;
}

.auth-panel-eyebrow {
    color: rgba(193, 233, 255, .9);
}

.auth-panel-copy h2 {
    max-width: 390px;
    margin: 0 0 16px;
    color: #fff;
    font-size: clamp(2rem, 3vw, 2.55rem);
    line-height: 1.13;
    letter-spacing: -.06em;
}

.auth-panel-copy p {
    max-width: 382px;
    margin: 0;
    color: rgba(255, 255, 255, .73);
    font-size: 15px;
    line-height: 1.72;
}

.auth-panel-features {
    display: grid;
    gap: 12px;
}

.auth-panel-features div {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 13px 15px;
    border: 1px solid rgba(255, 255, 255, .13);
    border-radius: 16px;
    background: rgba(255, 255, 255, .07);
    color: rgba(255, 255, 255, .9);
    font-size: 13px;
    font-weight: 700;
}

.auth-panel-features i {
    color: #80dfff;
    font-size: 18px;
}

.auth-form-stage {
    position: relative;
    min-height: 700px;
    overflow: hidden;
}

.auth-pane,
.auth-form-static {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: clamp(32px, 4vw, 52px);
    background: var(--bs-paper-bg, #fff);
}

.auth-pane {
    position: absolute;
    inset: 0;
    width: auto;
    height: auto;
    overflow-y: auto;
    transition: opacity .34s ease, transform .46s cubic-bezier(.2, .72, .2, 1);
}

.auth-login {
    opacity: 1;
    transform: translateX(0);
    pointer-events: auto;
}

.auth-forgot {
    opacity: 0;
    transform: translateX(36px);
    pointer-events: none;
}

.auth-card.is-recovery .auth-login {
    opacity: 0;
    transform: translateX(-36px);
    pointer-events: none;
}

.auth-card.is-recovery .auth-forgot {
    opacity: 1;
    transform: translateX(0);
    pointer-events: auto;
}

.auth-form-brand {
    display: none;
    margin-bottom: 30px;
}

.auth-form-brand img {
    max-width: 190px;
    height: auto;
}

.auth-eyebrow {
    color: var(--auth-blue);
}

.auth-pane h1,
.auth-form-static h1 {
    margin: 0 0 12px;
    color: var(--auth-dark);
    font-size: clamp(1.95rem, 3.4vw, 2.35rem);
    font-weight: 800;
    line-height: 1.18;
    letter-spacing: -.055em;
}

.auth-subtitle {
    margin: 0 0 26px;
    color: var(--auth-muted);
    font-size: 15px;
    line-height: 1.65;
}

.auth-field {
    margin-bottom: 19px;
}

.auth-field .form-label {
    margin-bottom: 8px;
    color: #334155;
    font-size: 13px;
    font-weight: 750;
}

.auth-field .form-control,
.auth-field .input-group-text {
    min-height: 51px;
    border-color: var(--auth-border);
    background: var(--bs-paper-bg, #fff);
}

.auth-field .form-control {
    border-radius: 14px;
}

.auth-field .input-group .form-control {
    border-radius: 14px 0 0 14px;
}

.auth-field .input-group-text {
    border-radius: 0 14px 14px 0;
    color: var(--auth-muted);
}

.auth-field .form-control:focus {
    border-color: rgba(11, 132, 216, .52);
    box-shadow: 0 0 0 .22rem rgba(11, 132, 216, .12);
}

.auth-options {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin: 6px 0 20px;
}

.auth-check {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--auth-muted);
    font-size: 13px;
    font-weight: 600;
}

.auth-text-button,
.auth-return {
    border: 0;
    padding: 0;
    color: var(--auth-blue);
    background: transparent;
    font-size: 13px;
    font-weight: 750;
}

.auth-security {
    display: grid;
    justify-content: center;
    min-height: 68px;
    margin: 4px 0 20px;
}

#btn-autenticar.auth-submit,
#btn-forgot.auth-submit,
.auth-submit {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 52px;
    border: 0;
    border-radius: 999px;
    color: #fff;
    background: linear-gradient(130deg, var(--auth-blue), var(--auth-purple)) !important;
    box-shadow: 0 15px 34px rgba(11, 132, 216, .25);
    font-size: 14px;
    font-weight: 750;
}

.auth-submit:hover:not(:disabled) {
    color: #fff;
    transform: translateY(-2px);
}

.auth-return {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    width: 100%;
    margin-top: 23px;
}

.auth-hint {
    display: block;
    margin-top: 22px;
    color: var(--auth-muted);
    text-align: center;
}

.auth-alert {
    margin: 0 0 20px;
    padding: 12px 14px;
    border: 1px solid rgba(var(--bs-warning-rgb), .25);
    border-radius: 14px;
    color: var(--bs-warning-text-emphasis);
    background: var(--bs-warning-bg-subtle);
    font-size: 13px;
    line-height: 1.55;
}

.auth-password-rule,
.auth-invite-summary {
    margin: 4px 0 24px;
    padding: 13px 14px;
    border: 1px solid rgba(11, 132, 216, .12);
    border-radius: 14px;
    color: var(--auth-muted);
    background: rgba(11, 132, 216, .06);
    font-size: 13px;
}

.auth-invite-summary {
    display: grid;
    gap: 4px;
}

.auth-invite-summary strong {
    color: var(--bs-heading-color, var(--auth-dark));
}

.auth-message-icon {
    display: grid;
    place-items: center;
    width: 54px;
    height: 54px;
    margin-bottom: 23px;
    border-radius: 18px;
    color: var(--auth-blue);
    background: rgba(11, 132, 216, .09);
    font-size: 27px;
}

.auth-install {
    z-index: 1;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 20px;
    padding: 10px 17px;
    border: 1px solid rgba(11, 132, 216, .2);
    border-radius: 999px;
    color: var(--auth-blue);
    background: rgba(255, 255, 255, .74);
    font-size: 13px;
    font-weight: 750;
}

.auth-footer {
    z-index: 1;
    margin: 22px 0 0;
    color: var(--auth-muted);
    font-size: 13px;
}

.auth-toast-container {
    z-index: 1090;
}

[data-bs-theme="dark"] .auth-page {
    background:
        radial-gradient(circle at 8% 8%, rgba(18, 184, 232, .12), transparent 31%),
        radial-gradient(circle at 94% 12%, rgba(110, 75, 242, .15), transparent 34%),
        #101624;
}

[data-bs-theme="dark"] #authContainer.auth-card,
[data-bs-theme="dark"] .auth-card,
[data-bs-theme="dark"] .auth-pane,
[data-bs-theme="dark"] .auth-form-static {
    border-color: rgba(255, 255, 255, .08);
    background: var(--bs-paper-bg);
}

[data-bs-theme="dark"] .auth-pane h1,
[data-bs-theme="dark"] .auth-form-static h1 {
    color: var(--bs-heading-color);
}

[data-bs-theme="dark"] .auth-field .form-label {
    color: var(--bs-body-color);
}

[data-bs-theme="dark"] .auth-install {
    background: rgba(255, 255, 255, .04);
}

@media (max-width: 880px) {
    .auth-page {
        justify-content: flex-start;
        padding: 66px 16px 28px;
        overflow: visible;
    }

    #authContainer.auth-card,
    .auth-card {
        display: block;
        max-width: 530px;
        min-height: 0;
        border-radius: 27px;
    }

    .auth-brand-panel {
        min-height: 205px;
        gap: 22px;
        padding: 26px;
    }

    .auth-panel-copy h2 {
        margin-bottom: 8px;
        font-size: clamp(1.55rem, 6vw, 1.88rem);
    }

    .auth-panel-copy p,
    .auth-panel-features {
        display: none;
    }

    .auth-form-stage {
        min-height: 680px;
    }

    .auth-pane,
    .auth-form-static {
        padding: 30px 25px 33px;
    }
}

@media (max-width: 480px) {
    .auth-page {
        padding-inline: 12px;
    }

    .auth-brand-panel {
        min-height: 178px;
        padding: 22px;
    }

    .auth-panel-name {
        font-size: 21px;
    }

    .auth-options {
        align-items: flex-start;
        flex-direction: column;
        gap: 12px;
    }

    .auth-security {
        justify-content: stretch;
    }
}

@media (prefers-reduced-motion: reduce) {
    .auth-pane,
    .auth-submit {
        transition: none !important;
    }
}
