/* Mainplus authentication v0.7.1 - balanced brand ecosystem. */

@font-face {
    font-family: "Aeonik";
    src: url("../fonts/aeonik/aeonik-light.woff2") format("woff2");
    font-style: normal;
    font-weight: 300;
    font-display: swap;
}

@font-face {
    font-family: "Aeonik";
    src: url("../fonts/aeonik/aeonik-regular.woff2") format("woff2");
    font-style: normal;
    font-weight: 400;
    font-display: swap;
}

@font-face {
    font-family: "Aeonik";
    src: url("../fonts/aeonik/aeonik-medium.woff2") format("woff2");
    font-style: normal;
    font-weight: 500;
    font-display: swap;
}

@font-face {
    font-family: "Aeonik";
    src: url("../fonts/aeonik/aeonik-semibold.woff2") format("woff2");
    font-style: normal;
    font-weight: 600;
    font-display: swap;
}

@font-face {
    font-family: "Aeonik";
    src: url("../fonts/aeonik/aeonik-bold.woff2") format("woff2");
    font-style: normal;
    font-weight: 700;
    font-display: swap;
}

:root {
    --auth-background: #f6f7fb;
    --auth-surface: #ffffff;
    --auth-text: #1f2430;
    --auth-secondary: #667085;
    --auth-border: #e4e7ec;
    --auth-violet: #6c3bff;
    --auth-violet-dark: #572bd9;
    --auth-violet-soft: #f0edff;
    --auth-maintech: #027bff;
    --auth-maintech-dark: #0067d8;
    --auth-mainbrand: #ff0154;
    --auth-panel: #171522;
    --auth-panel-muted: #c8c6d4;
    --auth-success: #16845b;
    --auth-success-soft: #ecfdf5;
    --auth-error: #d92d20;
    --auth-error-soft: #fff3f2;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html,
body {
    min-height: 100%;
}

body.auth-page {
    margin: 0;
    background: var(--auth-background);
    color: var(--auth-text);
    font-family: "Aeonik", Arial, sans-serif;
    font-size: 16px;
    font-weight: 400;
    line-height: 1.45;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

.auth-page a {
    color: var(--auth-violet);
    font-weight: 600;
    text-decoration: none;
}

.auth-page a:hover {
    color: var(--auth-violet-dark);
    text-decoration: underline;
}

.auth-page button,
.auth-page input {
    font: inherit;
}

.auth-shell {
    display: grid;
    grid-template-columns: minmax(390px, 36%) minmax(0, 64%);
    min-height: 100vh;
    overflow: hidden;
}

.auth-brand-panel {
    position: relative;
    display: flex;
    align-items: center;
    min-height: 100vh;
    overflow: hidden;
    padding: 72px 64px;
    isolation: isolate;
    color: #ffffff;
    background:
        radial-gradient(circle at 88% 82%, rgba(108, 59, 255, .22), rgba(108, 59, 255, 0) 34%),
        radial-gradient(circle at 8% 5%, rgba(56, 92, 190, .10), rgba(56, 92, 190, 0) 30%),
        linear-gradient(145deg, #0f1428 0%, #171522 62%, #11101c 100%);
}

.auth-brand-content {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: 430px;
}

.auth-slogan {
    margin: 0;
    color: #ffffff;
    font-size: 52px;
    font-weight: 600;
    letter-spacing: -.045em;
    line-height: 1.08;
}

.auth-slogan span {
    display: block;
}

.auth-brand-statement {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    margin-top: 25px;
}

.auth-brand-pulse {
    position: relative;
    flex: 0 0 8px;
    width: 8px;
    height: 8px;
    margin-top: 10px;
    background: #7c3aed;
    border-radius: 50%;
    box-shadow: 0 0 10px rgba(124, 58, 237, .48);
}

.auth-brand-pulse::before {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 24px;
    height: 24px;
    content: "";
    background: rgba(124, 58, 237, .18);
    border: 1px solid rgba(164, 120, 255, .20);
    border-radius: 50%;
    transform: translate(-50%, -50%) scale(.70);
    animation: auth-brand-pulse 2.4s ease-out infinite;
}

@keyframes auth-brand-pulse {
    0% {
        opacity: .82;
        transform: translate(-50%, -50%) scale(.70);
    }

    72%,
    100% {
        opacity: 0;
        transform: translate(-50%, -50%) scale(1.55);
    }
}

.auth-brand-description {
    margin: 0;
    color: var(--auth-panel-muted);
    font-size: 18px;
    font-weight: 300;
    line-height: 1.5;
}

.auth-main {
    position: relative;
    display: grid;
    grid-template-rows: minmax(0, 1fr) auto;
    min-height: 100vh;
    background:
        radial-gradient(circle at 86% 12%, rgba(108, 59, 255, .035), rgba(108, 59, 255, 0) 28%),
        var(--auth-background);
}

.auth-main-content {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 50px 72px 28px;
}

.auth-card {
    width: 100%;
    max-width: 535px;
}

.auth-logo {
    display: block;
    width: 200px;
    max-width: 100%;
    margin-bottom: 24px;
    line-height: 0;
}

.auth-logo:hover {
    text-decoration: none;
}

.auth-logo-image {
    display: block;
    width: 100%;
    height: auto;
}

.auth-eyebrow {
    margin-bottom: 8px;
    color: var(--auth-violet);
    font-size: 13px;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.auth-title {
    margin: 0;
    color: var(--auth-text);
    font-size: 28px;
    font-weight: 600;
    letter-spacing: -.035em;
    line-height: 1.12;
}

.auth-logo + .auth-title {
    margin-top: 16px;
}

.auth-subtitle {
    max-width: 490px;
    margin: 8px 0 34px;
    color: var(--auth-secondary);
    font-size: 17px;
    font-weight: 400;
    line-height: 1.5;
}

.auth-form {
    margin: 0;
}

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

.auth-field > label {
    display: block;
    margin-bottom: 8px;
    color: var(--auth-text);
    font-size: 15px;
    font-weight: 600;
}

.auth-input-wrap {
    position: relative;
}

.auth-input-wrap input {
    display: block;
    width: 100%;
    height: 54px;
    margin: 0;
    padding: 0 50px 0 48px;
    color: var(--auth-text);
    font-size: 16px;
    font-weight: 400;
    outline: none;
    background: var(--auth-surface);
    border: 1px solid var(--auth-border);
    border-radius: 10px;
    box-shadow: 0 1px 2px rgba(16, 24, 40, .02);
    transition: border-color .16s ease, box-shadow .16s ease, background-color .16s ease;
}

.auth-input-wrap input::placeholder {
    color: #98a2b3;
    opacity: 1;
}

.auth-input-wrap input:hover {
    border-color: #cfd4dc;
}

.auth-input-wrap input:focus {
    border-color: var(--auth-violet);
    box-shadow: 0 0 0 3px rgba(108, 59, 255, .08);
}

.auth-input-wrap input:-webkit-autofill,
.auth-input-wrap input:-webkit-autofill:hover,
.auth-input-wrap input:-webkit-autofill:focus {
    -webkit-text-fill-color: var(--auth-text);
    box-shadow: 0 0 0 1000px #ffffff inset, 0 0 0 3px rgba(108, 59, 255, .07);
}

.auth-input-icon {
    position: absolute;
    top: 50%;
    left: 16px;
    z-index: 2;
    width: 21px;
    height: 21px;
    fill: none;
    stroke: #77829a;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.65;
    transform: translateY(-50%);
    pointer-events: none;
}

.auth-password-toggle {
    position: absolute;
    top: 50%;
    right: 7px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    padding: 0;
    color: #667085;
    cursor: pointer;
    background: transparent;
    border: 0;
    border-radius: 8px;
    transform: translateY(-50%);
}

.auth-password-toggle:hover {
    color: var(--auth-violet);
    background: var(--auth-violet-soft);
}

.auth-password-toggle:focus {
    outline: 2px solid var(--auth-violet);
    outline-offset: 1px;
}

.auth-password-toggle svg {
    width: 21px;
    height: 21px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.7;
}

.auth-field-action {
    display: flex;
    justify-content: flex-end;
    margin-top: 8px;
}

.auth-field-action a {
    font-size: 14px;
}

.auth-help {
    margin: 8px 0 0;
    color: var(--auth-secondary);
    font-size: 13px;
    line-height: 1.45;
}

.auth-check {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin: 3px 0 22px;
    color: var(--auth-text);
    cursor: pointer;
    font-size: 14px;
    line-height: 1.45;
}

.auth-check input {
    flex: 0 0 auto;
    width: 18px;
    height: 18px;
    margin: 1px 0 0;
    cursor: pointer;
    accent-color: var(--auth-violet);
}

.auth-check input:focus {
    outline: 2px solid var(--auth-violet);
    outline-offset: 2px;
}

.auth-submit {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 52px;
    padding: 13px 22px;
    color: #ffffff;
    cursor: pointer;
    background: var(--auth-violet);
    border: 1px solid var(--auth-violet);
    border-radius: 10px;
    box-shadow: 0 7px 18px rgba(108, 59, 255, .18);
    font-size: 16px;
    font-weight: 600;
    line-height: 1.25;
    text-align: center;
    transition: background-color .16s ease, border-color .16s ease, box-shadow .16s ease, transform .16s ease;
}

.auth-submit:hover {
    color: #ffffff;
    text-decoration: none;
    background: var(--auth-violet-dark);
    border-color: var(--auth-violet-dark);
    box-shadow: 0 10px 22px rgba(108, 59, 255, .23);
    transform: translateY(-1px);
}

.auth-submit:focus {
    outline: 3px solid rgba(108, 59, 255, .22);
    outline-offset: 2px;
}

.auth-submit:disabled,
.auth-submit.is-loading {
    cursor: wait;
    opacity: .76;
    transform: none;
}

.auth-submit-link {
    margin-top: 24px;
}

.auth-support,
.auth-back {
    margin: 22px 0 0;
    color: var(--auth-secondary);
    font-size: 14px;
    text-align: center;
}

.auth-support a {
    color: var(--auth-maintech);
}

.auth-support a:hover,
.auth-support a:focus {
    color: var(--auth-maintech-dark);
}

.auth-back a {
    display: inline-flex;
    align-items: center;
    gap: 7px;
}

.auth-alert {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin: 0 0 22px;
    padding: 13px 14px;
    border: 1px solid;
    border-radius: 10px;
    font-size: 14px;
    line-height: 1.45;
}

.auth-alert svg {
    flex: 0 0 auto;
    width: 20px;
    height: 20px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.8;
}

.auth-alert-success {
    color: #08734f;
    background: var(--auth-success-soft);
    border-color: #a6f4d0;
}

.auth-alert-error {
    color: #b42318;
    background: var(--auth-error-soft);
    border-color: #fecdca;
}

.auth-state-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 68px;
    height: 68px;
    margin: 28px auto 0;
    color: var(--auth-error);
    background: var(--auth-error-soft);
    border-radius: 50%;
}

.auth-state-icon svg {
    width: 34px;
    height: 34px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.6;
}

.auth-footer {
    position: relative;
    z-index: 2;
    padding: 14px 72px 30px;
    color: var(--auth-secondary);
    font-size: 12px;
    text-align: center;
}

.auth-footer::after {
    display: block;
    width: 92px;
    height: 2px;
    margin: 13px auto 0;
    content: "";
    opacity: .58;
    border-radius: 99px;
    background: linear-gradient(90deg,
        var(--auth-violet) 0%,
        var(--auth-violet) 38%,
        var(--auth-maintech) 38%,
        var(--auth-maintech) 70%,
        var(--auth-mainbrand) 70%,
        var(--auth-mainbrand) 100%);
}

.auth-footer p {
    margin: 5px 0 0;
}

.auth-footer a {
    color: var(--auth-maintech);
    font-weight: 600;
}

.auth-footer a:hover,
.auth-footer a:focus {
    color: var(--auth-maintech-dark);
}

.auth-secure {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: #59657b;
    font-size: 13px;
    font-weight: 500;
}

.auth-secure svg {
    width: 19px;
    height: 19px;
    fill: none;
    stroke: var(--auth-maintech);
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.6;
}

@media (max-width: 1180px) {
    .auth-shell {
        grid-template-columns: minmax(340px, 36%) minmax(0, 64%);
    }

    .auth-brand-panel {
        padding: 62px 46px;
    }

    .auth-slogan {
        font-size: 48px;
    }

    .auth-brand-description {
        font-size: 17px;
    }

    .auth-main-content {
        padding-right: 54px;
        padding-left: 54px;
    }
}

@media (max-width: 900px) {
    .auth-shell {
        grid-template-columns: minmax(300px, 35%) minmax(0, 65%);
    }

    .auth-brand-panel {
        padding: 48px 34px;
    }

    .auth-slogan {
        font-size: 42px;
    }

    .auth-brand-description {
        font-size: 17px;
    }

    .auth-main-content {
        padding-right: 38px;
        padding-left: 38px;
    }

    .auth-title {
        font-size: 30px;
    }
}

@media (max-width: 760px) {
    .auth-shell {
        display: block;
        overflow: visible;
    }

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

    .auth-main {
        min-height: 100vh;
    }

    .auth-main-content {
        align-items: center;
        padding: 28px;
    }

    .auth-card {
        max-width: 560px;
    }

    .auth-footer {
        padding: 18px 28px 28px;
    }
}

@media (max-width: 520px) {
    .auth-main-content {
        padding: 24px 20px;
    }

    .auth-logo {
        width: 170px;
        margin-bottom: 22px;
    }

    .auth-title {
        font-size: 27px;
    }

    .auth-subtitle {
        margin-bottom: 25px;
        font-size: 15px;
    }

    .auth-input-wrap input {
        height: 52px;
        font-size: 15px;
    }

    .auth-check {
        font-size: 13px;
    }

    .auth-submit {
        min-height: 52px;
    }

    .auth-footer {
        padding: 18px 20px 24px;
        text-align: center;
    }
}

@media (max-width: 760px) and (max-height: 740px) {
    .auth-main-content {
        align-items: flex-start;
        padding-top: 28px;
    }
}

@media (max-height: 760px) and (min-width: 761px) {
    .auth-main-content {
        align-items: flex-start;
        padding-top: 34px;
    }

    .auth-logo {
        margin-bottom: 20px;
    }

    .auth-subtitle {
        margin-bottom: 22px;
    }

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

    .auth-footer {
        padding-bottom: 18px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .auth-brand-pulse::before {
        opacity: .35;
        transform: translate(-50%, -50%) scale(1);
        animation: none;
    }

    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        transition-duration: .01ms !important;
        animation-duration: .01ms !important;
        animation-iteration-count: 1 !important;
    }
}
