.auth-shell-page {
    min-width: 320px;
    background: #fbfcfb;
}

.auth-shell-page .site-shell {
    min-height: 100vh;
}

.auth-shell {
    min-height: 100vh;
    display: grid;
    grid-template-columns: minmax(420px, 42%) minmax(0, 1fr);
    background: #fbfcfb;
}

.auth-visual {
    min-height: 100vh;
    padding: clamp(44px, 5vw, 82px);
    position: sticky;
    top: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    color: #ffffff;
    background:
        radial-gradient(circle at 26% 18%, rgba(74, 151, 119, 0.24), transparent 34%),
        linear-gradient(145deg, #176149 0%, #0b4937 62%, #073d2e 100%);
}

.auth-brand {
    position: relative;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    gap: 16px;
    justify-self: start;
    font-family: var(--font-display);
    font-size: clamp(28px, 2.4vw, 40px);
    line-height: 1;
    letter-spacing: -0.035em;
}

.auth-brand img {
    width: 44px;
    height: 44px;
    object-fit: contain;
    flex: 0 0 44px;
}

.auth-visual-copy {
    margin-top: clamp(120px, 17vh, 210px);
    position: relative;
    z-index: 2;
}

.auth-visual-copy p {
    max-width: 520px;
    margin: 0;
    font-family: var(--font-display);
    font-size: clamp(54px, 5.4vw, 86px);
    line-height: 0.98;
    letter-spacing: -0.045em;
}

.auth-visual-copy > span {
    width: 78px;
    height: 3px;
    margin-top: 52px;
    display: block;
    background: #7bc0a4;
}

.auth-visual::before,
.auth-visual::after,
.auth-visual-orbit {
    position: absolute;
    pointer-events: none;
    border: 1px solid rgba(211, 236, 226, 0.38);
}

.auth-visual::before,
.auth-visual::after {
    content: "";
}

.auth-visual::before {
    width: 74%;
    height: 1px;
    left: 0;
    top: 58%;
    border-width: 1px 0 0;
}

.auth-visual::after {
    width: 1px;
    height: 58%;
    right: 20%;
    top: 0;
    border-width: 0 0 0 1px;
}

.auth-visual-orbit {
    border-radius: 50%;
}

.auth-visual-orbit--one {
    width: 92%;
    aspect-ratio: 1;
    right: -25%;
    top: -25%;
}

.auth-visual-orbit--two {
    width: 72%;
    aspect-ratio: 1;
    left: 19%;
    bottom: -40%;
}

.auth-visual-orbit--three {
    width: 82%;
    aspect-ratio: 1;
    left: -37%;
    bottom: -49%;
}

.auth-panel {
    min-width: 0;
    min-height: 100vh;
    padding: clamp(24px, 3vh, 40px) clamp(48px, 7vw, 112px);
    display: flex;
    align-items: center;
    justify-content: center;
    background:
        radial-gradient(circle at 80% 18%, rgba(31, 95, 74, 0.035), transparent 28%),
        #fbfcfb;
}

.auth-panel-inner {
    width: 100%;
    max-width: 520px;
}

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

.auth-shell .auth-page {
    max-width: none;
    margin: 0;
}

.auth-shell .auth-header h1,
.auth-shell .auth-page > h1 {
    margin: 0;
    color: #0e1713;
    font-family: var(--font-display);
    font-size: clamp(46px, 4.6vw, 68px);
    font-weight: 400;
    line-height: 1.02;
    letter-spacing: -0.045em;
    text-wrap: balance;
}

.auth-shell .auth-header p,
.auth-shell .auth-page > p,
.auth-shell .auth-page section p,
.auth-shell .auth-page form > p {
    color: #4f5d56;
}

.auth-shell .auth-header p {
    margin-top: 18px;
    font-size: 17px;
    line-height: 1.6;
}

.auth-shell .auth-header + .button {
    margin-top: 28px;
}

.auth-shell .auth-social-form,
.auth-shell .auth-form {
    margin-top: 30px;
}

.auth-shell .auth-field {
    margin-bottom: 22px;
}

.auth-shell .auth-field label,
.auth-shell .auth-page form label {
    margin-bottom: 9px;
    color: #29362f;
    font-family: var(--font-sans);
    font-size: 15px;
    font-weight: 400;
}

.auth-shell .auth-field input,
.auth-shell .auth-field textarea,
.auth-shell .auth-field select,
.auth-shell .auth-page form input:not([type="hidden"]):not([type="checkbox"]),
.auth-shell .auth-page form textarea {
    min-height: 58px;
    padding: 15px 17px;
    border: 1px solid rgba(23, 33, 28, 0.18);
    border-radius: 10px;
    background: #ffffff;
    box-shadow: none;
    transition:
        border-color var(--motion-standard),
        box-shadow var(--motion-standard),
        background var(--motion-standard);
}

.auth-shell .auth-field input:focus,
.auth-shell .auth-field textarea:focus,
.auth-shell .auth-field select:focus,
.auth-shell .auth-page form input:focus,
.auth-shell .auth-page form textarea:focus {
    outline: 0;
    border-color: #28775d;
    box-shadow: 0 0 0 4px rgba(40, 119, 93, 0.14);
}

.auth-shell .auth-page .button,
.auth-shell .auth-page form button,
.auth-shell .auth-page section li > a {
    width: 100%;
    min-height: 58px;
    padding: 14px 20px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    font-family: var(--font-sans);
    font-size: 16px;
    transition:
        color var(--motion-standard),
        border-color var(--motion-standard),
        background var(--motion-standard),
        transform var(--motion-standard),
        box-shadow var(--motion-standard);
}

.auth-shell .auth-page .button:not(.button-secondary),
.auth-shell .auth-page form button:not(.button-secondary),
.auth-shell .auth-page section li > a {
    background: linear-gradient(135deg, #176149, #0f503b);
    box-shadow: 0 12px 28px rgba(15, 80, 59, 0.18);
}

.auth-shell .auth-page .button-secondary {
    border-color: rgba(23, 33, 28, 0.18);
    background: #ffffff;
    color: #17211c;
    gap: 12px;
}

.auth-google-mark {
    width: 21px;
    height: 21px;
    flex: 0 0 21px;
}

.auth-shell .auth-page .button:hover,
.auth-shell .auth-page form button:hover,
.auth-shell .auth-page section li > a:hover {
    transform: translateY(-2px);
}

.auth-shell .auth-page .button-secondary:hover {
    border-color: rgba(31, 95, 74, 0.35);
    background: #f7faf8;
}

.auth-shell a:focus-visible,
.auth-shell button:focus-visible {
    outline: 3px solid rgba(31, 95, 74, 0.28);
    outline-offset: 3px;
}

.auth-brand--light:focus-visible {
    outline-color: rgba(220, 244, 234, 0.82);
}

.auth-shell .auth-divider {
    margin: 24px 0;
}

.auth-shell .auth-field-help {
    margin-top: 14px;
    font-size: 14px;
    line-height: 1.6;
}

.auth-shell .auth-legal {
    margin: 22px 0 0;
    padding-top: 18px;
    border-top: 1px solid rgba(23, 33, 28, 0.12);
    color: #65736c;
    font-size: 13px;
    line-height: 1.55;
}

.auth-shell .auth-legal a {
    color: #155943;
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 3px;
}

@media (min-width: 901px) {
    .auth-page--mfa-setup .auth-header h1 {
        font-size: clamp(46px, 3.8vw, 52px);
    }

    .auth-page--mfa-setup .auth-header p {
        margin-top: 8px;
        line-height: 1.45;
    }

    .auth-page--mfa-setup .auth-form {
        margin-top: 12px;
    }

    .auth-shell .auth-page--mfa-setup .auth-mfa-qr {
        width: 160px;
        margin-bottom: 14px;
    }

    .auth-page--mfa-setup .auth-field {
        margin-bottom: 12px;
    }

    .auth-page--mfa-setup .auth-field input {
        min-height: 48px;
        padding-block: 10px;
    }

    .auth-page--signup .auth-header h1 {
        font-size: clamp(48px, 4vw, 56px);
    }

    .auth-page--signup .auth-header p {
        margin-top: 12px;
        line-height: 1.45;
    }

    .auth-page--signup .auth-social-form,
    .auth-page--signup .auth-form {
        margin-top: 18px;
    }

    .auth-page--signup .auth-divider {
        margin: 12px 0;
    }

    .auth-page--signup .auth-field {
        margin-bottom: 10px;
    }

    .auth-page--signup .auth-field label {
        margin-bottom: 6px;
    }

    .auth-page--signup .auth-field input {
        min-height: 54px;
        padding-block: 13px;
    }

    .auth-page--signup .auth-field-help ul {
        columns: 2;
        column-gap: 30px;
        margin: 0;
        padding-left: 20px;
    }

    .auth-page--signup .auth-field .auth-field-help {
        margin-top: 8px;
        font-size: 13px;
        line-height: 1.45;
    }

    .auth-page--signup .auth-field-help li {
        break-inside: avoid;
    }

    .auth-page--signup .button {
        min-height: 52px;
    }

    .auth-page--signup > .auth-field-help {
        margin-top: 10px;
    }

    .auth-page--signup .auth-legal {
        margin-top: 12px;
        padding-top: 10px;
        font-size: 12.5px;
    }
}

.auth-shell .auth-field-help a,
.auth-shell .auth-page > a:not(.button),
.auth-shell .back-link {
    color: #155943;
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 3px;
}

.auth-shell .auth-form-error,
.auth-shell .auth-field-error {
    padding: 10px 12px;
    border: 1px solid var(--danger-border);
    border-radius: 8px;
    background: var(--danger-bg);
}

.auth-shell .auth-messages {
    margin: 0 0 22px;
}

.auth-shell .auth-page section {
    background: #ffffff;
}

.auth-shell .auth-page img {
    width: min(230px, 100%);
}

.auth-shell .auth-page--mfa > p {
    margin: 18px 0 0;
    font-size: 17px;
    line-height: 1.6;
}

.auth-shell .auth-page--mfa form {
    margin-top: 28px;
}

.auth-shell .auth-page--mfa .auth-cancel-form {
    margin-top: 12px;
}

.auth-shell .auth-page--mfa .auth-mfa-card {
    margin-top: 28px;
    padding: 24px;
    border: 1px solid rgba(23, 33, 28, 0.12);
    border-radius: 12px;
    background: #ffffff;
}

.auth-shell .auth-page--mfa .auth-mfa-card h2 {
    margin: 0;
    font-family: var(--font-display);
    font-size: 30px;
    line-height: 1.1;
}

.auth-shell .auth-page--mfa .auth-mfa-card p {
    margin: 12px 0 20px;
    color: #4f5d56;
    line-height: 1.6;
}

.auth-shell .auth-page--mfa .auth-mfa-qr {
    margin: 0 auto 28px;
    display: block;
}

.auth-shell .auth-page--mfa .button-danger {
    border-color: #9f3232;
    background: #9f3232;
    box-shadow: 0 12px 28px rgba(159, 50, 50, 0.16);
}

.auth-shell .auth-page--mfa .button-danger:hover {
    background: #862929;
}

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

    .auth-visual {
        display: none;
    }

    .auth-panel {
        min-height: 100vh;
        padding: 28px clamp(20px, 7vw, 56px) 54px;
        display: block;
    }

    .auth-brand--mobile {
        margin-bottom: 64px;
        display: inline-flex;
        color: var(--text);
        font-size: 29px;
    }

    .auth-brand--mobile img {
        width: 36px;
        height: 36px;
        flex-basis: 36px;
    }

    .auth-panel-inner {
        margin: 0 auto;
    }

    .auth-shell .auth-header h1,
    .auth-shell .auth-page > h1 {
        font-size: clamp(42px, 10vw, 56px);
    }
}

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

    .auth-brand--mobile {
        margin-bottom: 48px;
        font-size: 26px;
    }

    .auth-shell .auth-header p {
        font-size: 16px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .auth-shell *,
    .auth-shell *::before,
    .auth-shell *::after {
        scroll-behavior: auto !important;
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
    }
}
