:root {
    --login-navy: #0b315e;
    --login-navy-dark: #061d38;
    --login-green: #7eaa3b;
    --login-green-dark: #668d2d;
    --login-text: #18212f;
    --login-muted: #687386;
    --login-border: #dfe5ec;
}

.auth-page,
.auth-page * {
    box-sizing: border-box;
}

.auth-page {
    min-height: 100vh;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px;
    position: relative;
    isolation: isolate;
    overflow: hidden;
    font-family: "Montserrat", "Segoe UI", Arial, sans-serif;
    background:
        linear-gradient(120deg, rgba(6, 29, 56, 0.92), rgba(11, 49, 94, 0.62)),
        url("../img/bg-login.jpg") center / cover no-repeat;
}

.auth-page::before,
.auth-page::after {
    content: "";
    position: absolute;
    z-index: -1;
    border-radius: 50%;
    filter: blur(1px);
}

.auth-page::before {
    width: 440px;
    height: 440px;
    top: -190px;
    right: -90px;
    background: rgba(126, 170, 59, 0.22);
}

.auth-page::after {
    width: 300px;
    height: 300px;
    bottom: -170px;
    left: -90px;
    border: 1px solid rgba(255, 255, 255, 0.22);
}

.auth-shell {
    width: min(1080px, 100%);
    min-height: 660px;
    display: grid;
    grid-template-columns: 1.08fr 0.92fr;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 28px;
    background: rgba(255, 255, 255, 0.1);
    box-shadow: 0 30px 80px rgba(2, 16, 31, 0.36);
}

.auth-shell--register {
    min-height: 720px;
}

.auth-visual {
    min-width: 0;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 56px;
    position: relative;
    color: #fff;
    background:
        linear-gradient(155deg, rgba(6, 29, 56, 0.18), rgba(6, 29, 56, 0.68)),
        url("../img/bg-login.jpg") center / cover no-repeat;
}

.auth-visual::after {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: linear-gradient(180deg, transparent 40%, rgba(6, 29, 56, 0.28));
}

.auth-visual__content,
.auth-visual__footer {
    position: relative;
    z-index: 1;
}

.auth-visual__content {
    margin-top: auto;
    margin-bottom: auto;
}

.auth-visual__eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 24px;
    padding: 9px 14px;
    border: 1px solid rgba(255, 255, 255, 0.26);
    border-radius: 999px;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(8px);
}

.auth-visual h2 {
    max-width: 460px;
    margin: 0 0 18px;
    color: #fff;
    font-size: clamp(38px, 4.2vw, 58px);
    font-weight: 700;
    line-height: 1.05;
    letter-spacing: -0.04em;
    text-shadow: 0 4px 20px rgba(4, 22, 42, 0.25);
}

.auth-visual p {
    max-width: 430px;
    margin: 0;
    color: rgba(255, 255, 255, 0.86);
    font-size: 16px;
    line-height: 1.7;
}

.auth-visual__footer {
    display: flex;
    align-items: center;
    gap: 14px;
    color: rgba(255, 255, 255, 0.82);
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.18em;
    text-transform: uppercase;
}

.auth-visual__line {
    width: 42px;
    height: 2px;
    background: var(--login-green);
}

.auth-panel {
    display: flex;
    align-items: center;
    padding: 52px 58px;
    background: rgba(255, 255, 255, 0.97);
}

.auth-panel__content {
    width: 100%;
    max-width: 370px;
    margin: 0 auto;
}

.auth-logo {
    display: block;
    width: 230px;
    max-width: 76%;
    height: auto;
    margin: 0 0 42px;
}

.auth-logo--register {
    width: 205px;
    margin-bottom: 28px;
}

.auth-heading {
    margin-bottom: 32px;
}

.auth-heading--register {
    margin-bottom: 24px;
}

.auth-heading__eyebrow {
    display: block;
    margin-bottom: 10px;
    color: var(--login-green-dark);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.auth-heading h1 {
    margin: 0 0 10px;
    color: var(--login-text);
    font-size: 36px;
    font-weight: 700;
    line-height: 1.12;
    letter-spacing: -0.035em;
}

.auth-heading p {
    margin: 0;
    color: var(--login-muted);
    font-size: 14px;
    line-height: 1.6;
}

.auth-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.auth-field label {
    display: block;
    margin: 0 0 8px;
    color: #344054;
    font-size: 13px;
    font-weight: 600;
}

.auth-input {
    height: 52px;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 0 16px;
    border: 1px solid var(--login-border);
    border-radius: 12px;
    background: #f9fafb;
    transition: border-color 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.auth-input:focus-within {
    border-color: var(--login-green);
    background: #fff;
    box-shadow: 0 0 0 4px rgba(126, 170, 59, 0.14);
}

.auth-input i {
    flex: 0 0 auto;
    color: #8a94a5;
    font-size: 15px;
    transition: color 160ms ease;
}

.auth-input:focus-within i {
    color: var(--login-green-dark);
}

.auth-input input,
.auth-input input.form-control {
    min-width: 0;
    height: 100%;
    flex: 1;
    margin: 0;
    padding: 0;
    border: 0;
    outline: 0;
    color: var(--login-text);
    font-family: inherit;
    font-size: 14px !important;
    font-style: normal;
    background: transparent;
    box-shadow: none;
}

.auth-input input::placeholder {
    color: #9aa3b2;
    font-style: normal !important;
}

.auth-submit {
    width: 100%;
    height: 54px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-top: 6px;
    border: 0;
    border-radius: 12px;
    color: #fff;
    font-family: inherit;
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 0.02em;
    cursor: pointer;
    background: linear-gradient(135deg, var(--login-green), var(--login-green-dark));
    box-shadow: 0 10px 24px rgba(102, 141, 45, 0.24);
    transition: transform 160ms ease, box-shadow 160ms ease, filter 160ms ease;
}

.auth-submit:hover {
    color: #fff;
    filter: brightness(1.04);
    transform: translateY(-1px);
    box-shadow: 0 14px 28px rgba(102, 141, 45, 0.3);
}

.auth-submit:focus-visible {
    outline: 3px solid rgba(126, 170, 59, 0.35);
    outline-offset: 3px;
}

.auth-submit i {
    font-size: 12px;
    transition: transform 160ms ease;
}

.auth-submit:hover i {
    transform: translateX(3px);
}

.auth-alert {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 10px;
    padding: 12px 14px;
    border: 1px solid;
    border-radius: 10px;
    font-size: 12px;
    line-height: 1.45;
}

.auth-alert--danger {
    border-color: #fecaca;
    color: #991b1b;
    background: #fef2f2;
}

.auth-alert--warning {
    border-color: #fde68a;
    color: #92400e;
    background: #fffbeb;
}

.auth-alert__close {
    padding: 3px;
    border: 0;
    color: inherit;
    cursor: pointer;
    opacity: 0.62;
    background: transparent;
}

.auth-alert__close:hover {
    opacity: 1;
}

.auth-check {
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.auth-check input {
    width: 17px;
    height: 17px;
    flex: 0 0 17px;
    margin: 1px 0 0;
    accent-color: var(--login-green);
    cursor: pointer;
}

.auth-check label {
    margin: 0;
    color: var(--login-muted);
    font-size: 12px;
    line-height: 1.5;
    cursor: pointer;
}

.auth-back {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 24px;
    color: var(--login-navy);
    font-size: 12px;
    font-weight: 600;
    transition: color 160ms ease;
}

.auth-back:hover,
.auth-back:focus {
    color: var(--login-green-dark);
    text-decoration: none;
}

.auth-back i {
    font-size: 10px;
    transition: transform 160ms ease;
}

.auth-back:hover i {
    transform: translateX(-3px);
}

.auth-copyright {
    margin: 36px 0 0;
    color: #98a2b3;
    font-size: 10px;
    line-height: 1.5;
    text-align: center;
}

.auth-copyright--register {
    margin-top: 20px;
}

@media (max-width: 900px) {
    .auth-page {
        padding: 28px;
    }

    .auth-shell {
        width: min(520px, 100%);
        min-height: 0;
        display: block;
        border-radius: 24px;
    }

    .auth-shell--register {
        min-height: 0;
    }

    .auth-visual {
        display: none;
    }

    .auth-panel {
        min-height: min(680px, calc(100vh - 56px));
        padding: 48px;
    }

    .auth-panel--register {
        min-height: min(760px, calc(100vh - 56px));
        padding-top: 38px;
        padding-bottom: 34px;
    }
}

@media (max-width: 520px) {
    .auth-page {
        align-items: flex-start;
        padding: 0;
        background: #fff;
    }

    .auth-page::before,
    .auth-page::after {
        display: none;
    }

    .auth-shell {
        min-height: 100vh;
        border: 0;
        border-radius: 0;
        box-shadow: none;
    }

    .auth-panel {
        min-height: 100vh;
        align-items: flex-start;
        padding: 42px 26px 28px;
    }

    .auth-logo {
        width: 205px;
        margin-bottom: 42px;
    }

    .auth-logo--register {
        width: 190px;
        margin-bottom: 28px;
    }

    .auth-panel--register {
        padding-top: 32px;
        padding-bottom: 24px;
    }

    .auth-heading h1 {
        font-size: 32px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .auth-page *,
    .auth-page *::before,
    .auth-page *::after {
        scroll-behavior: auto !important;
        transition: none !important;
    }
}
