.auth-body {
    display: grid;
    min-height: 100vh;
    background:
        radial-gradient(circle at 15% 15%, rgba(17, 107, 98, 0.09), transparent 31rem),
        var(--app-bg);
}

.auth-shell {
    display: grid;
    width: min(1120px, calc(100% - 40px));
    min-height: min(720px, calc(100vh - 64px));
    grid-template-columns: minmax(0, 1.05fr) minmax(390px, 0.95fr);
    margin: auto;
    overflow: hidden;
    background: var(--app-surface);
    border: 1px solid var(--app-border);
    border-radius: 12px;
    box-shadow: 0 24px 70px rgba(23, 33, 38, 0.14);
}

.auth-introduction {
    position: relative;
    display: flex;
    min-width: 0;
    flex-direction: column;
    justify-content: space-between;
    padding: 44px;
    overflow: hidden;
    color: #ffffff;
    background: linear-gradient(145deg, #20292c 0%, #25383a 55%, #116b62 140%);
}

.auth-introduction::before,
.auth-introduction::after {
    position: absolute;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    content: '';
    pointer-events: none;
}

.auth-introduction::before {
    width: 390px;
    height: 390px;
    right: -190px;
    top: -130px;
}

.auth-introduction::after {
    width: 280px;
    height: 280px;
    right: -75px;
    bottom: -185px;
}

.auth-brand {
    position: relative;
    z-index: 1;
    display: inline-flex;
    align-items: center;
    align-self: flex-start;
    color: #ffffff;
    text-decoration: none;
}

.auth-brand:hover {
    color: #ffffff;
}

.auth-brand img {
    display: block;
    width: 204px;
    height: auto;
    filter: invert(1);
}

.auth-introduction-copy {
    position: relative;
    z-index: 1;
    max-width: 520px;
    margin: auto 0;
    padding: 64px 0;
}

.auth-kicker {
    margin: 0 0 10px;
    color: #69c7ba;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.auth-introduction h1 {
    max-width: 520px;
    margin: 0;
    font-size: clamp(34px, 4.6vw, 54px);
    letter-spacing: -0.04em;
    line-height: 1.04;
}

.auth-panel {
    display: flex;
    min-width: 0;
    flex-direction: column;
    justify-content: center;
    padding: 54px clamp(30px, 5vw, 72px) 30px;
}

.auth-card {
    width: 100%;
    max-width: 430px;
    margin: auto;
}

.auth-card-header {
    margin-bottom: 28px;
}

.auth-card-header h2 {
    margin: 0;
    font-size: 30px;
    letter-spacing: -0.025em;
    line-height: 1.15;
}

.auth-description p {
    margin: 11px 0 0;
    color: var(--app-text-muted);
    line-height: 1.6;
}

.auth-messages {
    display: grid;
    gap: 8px;
    margin: 0 0 20px;
}

.auth-message {
    padding: 11px 13px;
    border: 1px solid var(--app-border);
    border-radius: var(--app-radius);
}

.auth-message-info {
    color: var(--app-success-text);
    background: var(--app-success-bg);
    border-color: #b7daca;
}

.auth-message-danger {
    color: var(--app-danger-text);
    background: var(--app-danger-bg);
    border-color: #efc1bc;
}

.auth-form {
    display: grid;
    gap: 18px;
}

.auth-field {
    display: grid;
    gap: 7px;
    color: var(--app-text);
    font-weight: 650;
}

.auth-field input {
    width: 100%;
    min-height: 46px;
    padding: 10px 12px;
    color: var(--app-text);
    background: var(--app-surface);
    border: 1px solid var(--app-border-strong);
    border-radius: var(--app-radius);
    font-weight: 450;
}

.auth-field input:hover {
    border-color: #8d9ba0;
}

.auth-form-actions {
    display: grid;
    gap: 14px;
    margin-top: 4px;
}

.auth-submit {
    width: 100%;
    min-height: 44px;
}

.auth-secondary-link {
    justify-self: center;
    font-weight: 650;
    text-decoration: none;
}

.auth-requirements {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 6px 14px;
    padding: 12px 14px;
    margin: 0;
    color: var(--app-text-muted);
    background: var(--app-surface-subtle);
    border: 1px solid var(--app-border);
    border-radius: var(--app-radius);
    font-size: 12px;
    list-style: none;
}

.auth-requirements li::before {
    display: inline-block;
    width: 16px;
    color: var(--app-border-strong);
    content: '\2022';
    font-weight: 800;
}

.auth-requirements li.is-valid {
    color: var(--app-success-text);
}

.auth-requirements li.is-valid::before {
    color: var(--app-success-text);
    content: '\2713';
}

.auth-feedback {
    min-height: 20px;
    margin: -7px 0 0;
    color: var(--app-text-muted);
    font-size: 12px;
}

.auth-feedback.is-error {
    color: var(--app-danger-text);
}

.auth-footer {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    margin-top: 42px;
    color: var(--app-text-muted);
    font-size: 11px;
}

.auth-footer-divider {
    width: 3px;
    height: 3px;
    background: var(--app-border-strong);
    border-radius: 50%;
}

.auth-footer a {
    color: inherit;
    text-decoration: none;
}

.auth-footer a:hover {
    color: var(--app-text);
    text-decoration: underline;
}

.legal-body {
    display: block;
    min-height: 100vh;
    background: var(--app-bg);
}

.legal-header {
    background: var(--app-surface);
    border-bottom: 1px solid var(--app-border);
}

.legal-header-inner,
.legal-page,
.legal-footer {
    width: min(820px, calc(100% - 40px));
    margin: 0 auto;
}

.legal-header-inner {
    display: flex;
    min-height: 76px;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.legal-brand img {
    display: block;
    width: 174px;
    height: auto;
}

.legal-return {
    color: var(--app-text-muted);
    font-weight: 650;
    text-decoration: none;
}

.legal-return:hover {
    color: var(--app-text);
}

.legal-page {
    padding: 56px 0 72px;
}

.legal-page-header {
    padding-bottom: 28px;
    border-bottom: 1px solid var(--app-border);
}

.legal-page-header h1 {
    margin: 0;
    font-size: clamp(34px, 6vw, 50px);
    letter-spacing: -0.04em;
}

.legal-effective-date {
    margin: 12px 0 0;
    color: var(--app-text-muted);
}

.legal-summary {
    margin: 24px 0 0;
    color: var(--app-text);
    font-size: 17px;
    line-height: 1.65;
}

.legal-content {
    color: var(--app-text);
}

.legal-content section {
    padding-top: 30px;
}

.legal-content h2 {
    margin: 0 0 12px;
    font-size: 21px;
    letter-spacing: -0.015em;
}

.legal-content p,
.legal-content li {
    line-height: 1.7;
}

.legal-content p {
    margin: 0 0 12px;
}

.legal-content ul {
    display: grid;
    gap: 8px;
    padding-left: 22px;
    margin: 0;
}

.legal-content a,
.legal-footer a {
    overflow-wrap: anywhere;
}

.legal-footer {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 18px;
    padding: 24px 0 36px;
    color: var(--app-text-muted);
    border-top: 1px solid var(--app-border);
    font-size: 12px;
}

@media (max-width: 840px) {
    .auth-shell {
        width: min(620px, calc(100% - 24px));
        min-height: auto;
        grid-template-columns: 1fr;
        margin: 12px auto;
    }

    .auth-introduction {
        min-height: 220px;
        padding: 28px;
    }

    .auth-introduction-copy {
        padding: 46px 0 24px;
    }

    .auth-introduction h1 {
        max-width: 470px;
        font-size: clamp(30px, 8vw, 43px);
    }

    .auth-panel {
        padding: 40px 28px 26px;
    }
}

@media (max-width: 480px) {
    .auth-shell {
        width: 100%;
        margin: 0;
        border: 0;
        border-radius: 0;
        box-shadow: none;
    }

    .auth-introduction {
        min-height: 178px;
        padding: 24px;
    }

    .auth-introduction-copy {
        padding: 32px 0 4px;
    }

    .auth-introduction h1 {
        font-size: 30px;
    }

    .auth-panel {
        padding: 34px 22px 24px;
    }

    .auth-card-header h2 {
        font-size: 26px;
    }

    .auth-requirements {
        grid-template-columns: 1fr;
    }

    .legal-header-inner,
    .legal-page,
    .legal-footer {
        width: min(100% - 28px, 820px);
    }

    .legal-header-inner {
        min-height: 68px;
    }

    .legal-brand img {
        width: 150px;
    }

    .legal-page {
        padding: 40px 0 56px;
    }
}
