/* 登录 / 注册占位 / 找回密码（仅 seemb4，与 category_page 的 .cat-page 配套） */

.auth-page .cat-main :not(input) {
    text-transform: none;
}

/* ----- 认证页主区：铺满可视高度（覆盖 category_page 的 min-height: 0 / calc(100vh - 401px)） ----- */
.auth-page .cat-main {
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    width: 100%;
    box-sizing: border-box;
    /* 近似扣除顶栏+页脚，主内容区接近整屏可视高度 */
    min-height: calc(100vh - 96px);
    min-height: calc(100dvh - 96px);
}

.auth-page .auth-page__inner {
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    width: var(--cat-max, 1320px);
    max-width: 100%;
    margin: 0 auto;
    padding: 24px 10px 48px;
    box-sizing: border-box;
    min-height: 0;
}

/* 注册：整块（面包屑+卡片）在竖直方向大致居中 */
.auth-register-page .auth-page__inner {
    justify-content: center;
}

/* 忘记密码：与登录页同套左图右表布局，仅微调副标题与标题间距 */
.auth-forgot-page.auth-login-page .auth-card--login .auth-card__subtitle {
    margin-bottom: 20px;
}

/* ----- 登录页：左插图 + 右表单（bg-login.png） ----- */
.auth-login-page .cat-main {
    background: linear-gradient(180deg, #eef4fc 0%, #f9fbff 45%, #f6f8fc 100%);
}

/* 登录：面包屑单行 + 下方区域占满剩余高度，插图与表单在可视区垂直居中 */
.auth-login-page .auth-page__inner {
    display: grid;
    grid-template-rows: auto 1fr;
    align-items: stretch;
    justify-items: stretch;
    padding-top: 8px;
    padding-bottom: 32px;
}

.auth-login-page .auth-page__breadcrumb {
    flex-shrink: 0;
    margin-bottom: 0;
    padding-bottom: 2px;
}

.auth-login-panel {
    grid-row: 2;
    align-self: center;
    justify-self: center;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 28px 40px;
    max-width: 1040px;
    width: 100%;
    margin: 0 auto;
    padding: 0 0 16px;
    box-sizing: border-box;
    min-height: 0;
    /* 抵消面包屑与顶栏带来的视觉下移，使整块更接近屏幕几何中心 */
    transform: translateY(clamp(-20px, -2.5vh, -8px));
}

.auth-login-panel__visual {
    flex: 1 1 320px;
    max-width: 520px;
    min-width: 260px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.auth-login-panel__img {
    display: block;
    width: 100%;
    height: auto;
    max-width: 520px;
    object-fit: contain;
    pointer-events: none;
    user-select: none;
}

.auth-login-panel__aside {
    flex: 0 1 400px;
    min-width: 280px;
    display: flex;
    justify-content: center;
}

.auth-form__req {
    color: var(--danger-color, #c80000);
    margin-right: 4px;
    font-weight: 600;
}

@media (max-width: 991.98px) {
    .auth-page .cat-main {
        min-height: calc(100vh - 88px);
        min-height: calc(100dvh - 88px);
    }
}

.auth-page__breadcrumb {
    font-size: 13px;
    color: var(--cat-muted, #666);
    margin-bottom: 20px;
}

.auth-page__breadcrumb a {
    color: var(--cat-primary, #4267b2);
}

.auth-page__breadcrumb a:hover {
    text-decoration: underline;
}

.auth-page__breadcrumb-sep {
    margin: 0 6px;
    color: var(--cat-border, #dfe4ed);
}

.auth-card {
    width: 100%;
    max-width: 440px;
    margin: 0 auto;
    padding: 32px 28px 28px;
    background: #fff;
    border: 1px solid var(--cat-border, #dfe4ed);
    box-shadow: 0 10px 40px rgba(66, 103, 178, 0.08);
    border-radius: 12px;
}

.auth-card--login .auth-card__title {
    margin-bottom: 24px;
}

.auth-card__title {
    margin: 0 0 8px;
    font-size: 22px;
    font-weight: 600;
    color: var(--cat-text, #333);
    text-align: center;
}

.auth-card__subtitle {
    margin: 0 0 24px;
    font-size: 14px;
    color: var(--cat-muted, #666);
    text-align: center;
    line-height: 1.5;
}

.auth-card__muted {
    margin: 16px 0 0;
    text-align: center;
    font-size: 14px;
}

.auth-card__muted a {
    color: var(--cat-primary, #4267b2);
}

.auth-card__muted a:hover {
    text-decoration: underline;
}

.auth-card__alert {
    margin: 0 0 16px;
    padding: 10px 12px;
    font-size: 13px;
    line-height: 1.45;
    border-radius: 2px;
    background: #fff5f5;
    border: 1px solid #f0caca;
    color: var(--danger-color, #c80000);
}

.auth-card__alert--ok {
    background: #f4faf4;
    border-color: #c5e0c5;
    color: #2d6a2d;
}

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

.auth-form__label {
    display: block;
    margin-bottom: 6px;
    font-size: 13px;
    font-weight: 500;
    color: var(--cat-text, #333);
}

.auth-form__input {
    display: block;
    width: 100%;
    box-sizing: border-box;
    padding: 10px 12px;
    font-size: 14px;
    border: 1px solid var(--cat-border, #dfe4ed);
    border-radius: 6px;
    background: #fff;
    color: var(--cat-text, #333);
}

.auth-form__input:focus {
    outline: none;
    border-color: var(--cat-primary, #4267b2);
    box-shadow: 0 0 0 2px rgba(66, 103, 178, 0.15);
}

.auth-form__submit {
    display: block;
    width: 100%;
    margin-top: 8px;
    padding: 12px 16px;
    font-size: 15px;
    font-weight: 600;
    color: var(--cat-primary-text, #fff);
    background: var(--cat-primary, #4267b2);
    border: none;
    border-radius: 6px;
    cursor: pointer;
}

.auth-form__submit:hover {
    background: #355899;
}

.auth-form__submit:disabled {
    opacity: 0.65;
    cursor: not-allowed;
}

.auth-form__select,
.auth-form__textarea {
    display: block;
    width: 100%;
    box-sizing: border-box;
    padding: 10px 12px;
    font-size: 14px;
    border: 1px solid var(--cat-border, #dfe4ed);
    border-radius: 6px;
    background: #fff;
    color: var(--cat-text, #333);
    font-family: inherit;
}

.auth-form__textarea {
    min-height: 72px;
    resize: vertical;
}

.auth-form__select:focus,
.auth-form__textarea:focus {
    outline: none;
    border-color: var(--cat-primary, #4267b2);
    box-shadow: 0 0 0 2px rgba(66, 103, 178, 0.15);
}

.auth-form__field--check {
    margin-bottom: 12px;
}

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

.auth-form__check {
    flex-shrink: 0;
    width: 18px;
    height: 18px;
    margin-top: 2px;
    accent-color: var(--cat-primary, #4267b2);
    cursor: pointer;
}

.auth-form__check-label {
    font-size: 13px;
    line-height: 1.45;
    color: var(--cat-text, #333);
    cursor: pointer;
}

.auth-form__inline-link {
    color: var(--cat-primary, #4267b2);
    text-decoration: underline;
}

.auth-form__inline-link:hover {
    color: #355899;
}

/* 注册表单：略加宽；顶部内边距收紧，标题贴近卡片上沿 */
.auth-card--register {
    max-width: 480px;
    padding: 16px 32px 36px;
}

.auth-card--register .auth-card__title {
    margin-top: 0;
    margin-bottom: 20px;
}

/* 注册页主区多留一点竖直空间 */
.auth-register-page.auth-login-page .cat-main {
    min-height: calc(100vh - 72px);
    min-height: calc(100dvh - 72px);
}

/* 账户激活引导页 */
.auth-card--activate {
    max-width: 480px;
    padding: 20px 32px 32px;
}

.auth-activate__lead {
    margin-bottom: 12px;
    line-height: 1.55;
}

.auth-activate__hint {
    margin-top: 0;
    margin-bottom: 22px;
    line-height: 1.55;
}

.auth-login-panel--activate-solo {
    justify-content: center;
    flex-wrap: nowrap;
    max-width: 520px;
    margin: 0 auto;
}

.auth-login-panel--activate-solo .auth-login-panel__aside {
    flex: 1 1 auto;
    width: 100%;
    max-width: 440px;
}

.auth-card--activate-confirm .auth-card__title {
    margin-bottom: 16px;
}

.auth-card__links {
    margin-top: 20px;
    padding-top: 18px;
    border-top: 1px solid var(--cat-border-lighter, #e6ebf5);
    text-align: center;
    font-size: 13px;
    color: var(--cat-muted, #666);
}

.auth-card__links a {
    color: var(--cat-primary, #4267b2);
}

.auth-card__links a:hover {
    text-decoration: underline;
}

.auth-card__links-hint {
    margin-right: 6px;
}

.auth-card__links-sep {
    margin: 0 10px;
    color: var(--cat-border, #dfe4ed);
}

.auth-card__links--split {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 10px 16px;
    text-align: left;
}

.auth-card__links--split .auth-card__links-start a {
    margin-left: 4px;
}

.auth-card__links-end {
    flex-shrink: 0;
}

@media (max-width: 991.98px) {
    .auth-login-panel {
        flex-direction: column;
        padding-top: 0;
    }

    .auth-login-panel__visual {
        max-width: 420px;
        order: 0;
    }

    .auth-login-panel__aside {
        order: 1;
        width: 100%;
    }
}

@media (max-width: 575.98px) {
    .auth-card {
        padding: 24px 18px 22px;
    }

    .auth-card--register {
        padding: 14px 18px 26px;
    }

    .auth-card__links--split {
        flex-direction: column;
        align-items: flex-start;
    }
}
