@charset "utf-8";
/* ============================================================================
   auth.css — 登录 / 注册 / 找回密码 等认证页统一版式
   作用域：.au-page（挂在视图最外层），所有规则都带前缀，不碰其它页面
   色板：全部取自 theme.css 的 :root，不新造颜色
   加载：视图里 registerCssFile('@web/css/auth.css', ['depends' => [AppAsset::class]])
         —— 必须 depends AppAsset，且视图比布局后注册，才能压在 theme.css 之后
   ============================================================================ */

/* ------------------------------------------------------------------ 页面壳 */
.au-page {
    padding: 28px 0 56px;
}

/* 卡片：单栏（注册 / 找回密码）与双栏（登录）共用 */
.au-page .au-card {
    max-width: 460px;
    margin: 0 auto;
    padding: 32px 34px 28px;
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: 4px;
}
.au-page .au-card-wide {
    max-width: 780px;
}
/* 双栏：左侧品牌区 + 右侧表单，padding 交给两侧各自控制 */
.au-page .au-card-split {
    display: grid;
    grid-template-columns: 268px minmax(0, 1fr);
    max-width: 720px;
    padding: 0;
    overflow: hidden;
}

/* ------------------------------------------------------ 左栏（仅登录页） */
.au-aside {
    display: flex;
    flex-direction: column;
    padding: 30px 26px 26px;
    background: var(--brand);
    color: #fff;
}
.au-aside-brand {
    display: flex;
    align-items: center;
    gap: 9px;
    font-size: 14px;
    font-weight: 600;
    letter-spacing: .2px;
    color: #fff;
}
/* 方块字标，跟导航栏 .navbar-brand::before 保持同一套语言 */
.au-aside-brand .au-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 26px;
    height: 26px;
    border-radius: 3px;
    background: rgba(255, 255, 255, .18);
    font-size: 14px;
    font-weight: 500;
    line-height: 1;
    flex: none;
}
.au-aside-title {
    margin: 26px 0 0;
    font-size: 18px;
    font-weight: 600;
    line-height: 1.4;
    color: #fff;
    letter-spacing: .2px;
}
.au-aside-desc {
    margin: 8px 0 0;
    font-size: 12.5px;
    line-height: 1.7;
    color: rgba(255, 255, 255, .72);
}
.au-points {
    margin: 20px 0 0;
    padding: 0;
    list-style: none;
}
.au-points > li {
    position: relative;
    padding-left: 14px;
    margin-bottom: 8px;
    font-size: 12.5px;
    line-height: 1.65;
    color: rgba(255, 255, 255, .8);
}
.au-points > li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 8px;
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: rgba(255, 255, 255, .5);
}
/* 沉到左栏底部：右侧表单比左栏内容高，不补这一行左栏底下会空一大块 */
.au-aside-foot {
    margin-top: auto;
    padding-top: 22px;
    font-size: 11.5px;
    line-height: 1.7;
    color: rgba(255, 255, 255, .55);
}
.au-aside-foot a {
    color: rgba(255, 255, 255, .82);
    text-decoration: underline;
    text-decoration-color: rgba(255, 255, 255, .35);
    text-underline-offset: 2px;
}
.au-aside-foot a:hover {
    color: #fff;
}

/* ------------------------------------------------------------ 右栏 / 表单 */
.au-form {
    padding: 32px 34px 26px;
}

.au-page .au-title {
    margin: 0;
    font-size: 21px;
    font-weight: 600;
    line-height: 1.35;
    color: var(--ink);
    letter-spacing: .2px;
}
.au-page .au-sub {
    margin: 7px 0 22px;
    font-size: 12.5px;
    line-height: 1.7;
    color: var(--muted);
}

/* 说明条（注册页的实名要求） */
.au-page .au-note {
    margin: 0 0 22px;
    padding: 11px 14px;
    background: var(--page);
    border-left: 2px solid var(--brand);
    border-radius: 0 3px 3px 0;
    font-size: 12px;
    line-height: 1.7;
    color: var(--ink-3);
}

/* 双列字段栅格：窄屏自动落回单列 */
.au-page .au-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    column-gap: 18px;
}
.au-page .au-grid > .au-span {
    grid-column: 1 / -1;
}

/* ---------------------------------------------------------------- 表单元素 */
.au-page .form-group {
    margin-bottom: 15px;
}
.au-page .control-label {
    margin-bottom: 6px;
    font-size: 12.5px;
    font-weight: 500;
    color: var(--ink-2);
}
.au-page .form-control {
    height: 38px;
    padding: 6px 11px;
    font-size: 13.5px;
    color: var(--ink);
    background-color: #fff;
    border: 1px solid var(--line);
    border-radius: 3px;
    box-shadow: none;
    transition: border-color .15s ease, box-shadow .15s ease;
}
.au-page .form-control:focus {
    border-color: var(--brand);
    box-shadow: 0 0 0 3px var(--brand-soft);
    outline: none;
}
.au-page .form-control::placeholder {
    color: #A8B1AD;
}
.au-page select.form-control {
    height: 38px;
    padding-top: 0;
    padding-bottom: 0;
}

/* 带前置图标的输入框：图标绝对定位，input 让出 34px 左内边距 */
.au-page .au-input {
    position: relative;
}
.au-page .au-input .au-ico {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    width: 15px;
    height: 15px;
    color: var(--muted);
    pointer-events: none;
    transition: color .15s ease;
}
.au-page .au-input .form-control {
    padding-left: 35px;
}
.au-page .au-input:focus-within .au-ico {
    color: var(--brand);
}

/* 错误态：bootstrap 默认的 #a94442 + inset 投影太重，压成细边框 */
.au-page .has-error .form-control,
.au-page .has-error .form-control:focus {
    border-color: #C9A2A2;
    box-shadow: none;
}
.au-page .has-error .form-control:focus {
    border-color: var(--danger);
    box-shadow: 0 0 0 3px #FBEFEF;
}
.au-page .help-block {
    margin: 5px 0 0;
    font-size: 12px;
    line-height: 1.6;
    color: var(--danger);
}
.au-page .help-block:empty {
    display: none;
}
.au-page .hint-block {
    margin-top: 5px;
    font-size: 12px;
    line-height: 1.6;
    color: var(--muted);
}
.au-page .hint-block.au-hint-warn {
    color: var(--warn);
}
.au-page .help-block.au-hint-warn {
    color: var(--warn);
}

/* 记住我 */
.au-page .checkbox {
    margin: 2px 0 20px;
    padding-left: 0;
}
.au-page .checkbox > label {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding-left: 0;
    font-size: 12.5px;
    color: var(--ink-2);
    cursor: pointer;
}
.au-page .checkbox > label > input[type="checkbox"] {
    position: static;
    margin: 0;
    flex: none;
    accent-color: var(--brand);
}

/* 验证码：左图右框。整行占用时不让输入框拉满，否则一行只有两个字的框 */
.au-page .au-captcha {
    display: flex;
    align-items: center;
    gap: 10px;
    max-width: 330px;
}
.au-page .au-captcha .au-captcha-img {
    height: 38px;
    width: auto;
    flex: none;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 3px;
    cursor: pointer;
}
.au-page .au-captcha .form-control {
    flex: 1 1 auto;
    min-width: 0;
}

/* -------------------------------------------------------------------- 按钮 */
.au-page .btn-primary {
    width: 100%;
    height: 38px;
    padding: 0 16px;
    font-size: 14px;
    font-weight: 500;
    letter-spacing: .3px;
    color: #fff;
    background-color: var(--brand);
    background-image: none;
    border: 1px solid var(--brand);
    border-radius: 3px;
    box-shadow: none;
    transition: background-color .15s ease, border-color .15s ease;
}
.au-page .btn-primary:hover,
.au-page .btn-primary:focus {
    color: #fff;
    background-color: var(--brand-dark);
    background-image: none;
    border-color: var(--brand-dark);
    outline: none;
}
.au-page .btn-primary:active,
.au-page .btn-primary:active:focus,
.au-page .btn-primary:active:hover {
    color: #fff;
    background-color: var(--brand-dark);
    background-image: none;
    border-color: var(--brand-dark);
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, .08);
}
.au-page .btn-primary.disabled,
.au-page .btn-primary[disabled] {
    background-color: #8FA9AE;
    border-color: #8FA9AE;
    opacity: 1;
}
/* 键盘聚焦也要看得见：bootstrap 默认只有 :focus 的浅 outline */
.au-page .btn-primary:focus-visible {
    outline: 2px solid var(--brand-soft);
    outline-offset: 2px;
}

/* ------------------------------------------------------------ 底部切换链接 */
.au-page .au-foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid var(--line-soft);
    font-size: 12.5px;
    color: var(--muted);
}
.au-page .au-foot a {
    color: var(--brand);
}
.au-page .au-foot a:hover {
    color: var(--brand-dark);
}

/* -------------------------------------------------------------------- 提示条 */
/* flash 提示由布局里的 AlertWidget 渲染，落在 .au-page 之前，容器宽 1240。
   认证页内容只有一个窄卡片，满宽的提示条横在上面很突兀，按卡片同宽居中。 */
body.site-login .wrap > .container > .alert,
body.site-signup .wrap > .container > .alert {
    max-width: 720px;
    margin: 0 auto 16px;
}
body.site-request-password-reset .wrap > .container > .alert,
body.site-reset-password .wrap > .container > .alert,
body.site-resend-verification-email .wrap > .container > .alert {
    max-width: 460px;
    margin: 0 auto 16px;
}

/* ------------------------------------------------------------------ 响应式 */
@media (max-width: 767px) {
    .au-page {
        padding: 18px 0 36px;
    }
    .au-page .au-card {
        padding: 24px 20px 22px;
    }
    /* 窄屏把左栏压成顶部一条品牌带，标题与要点收起，避免占据整屏。
       必须显式写回 padding: 0 —— 上面 .au-card 的 padding 会把双栏卡片的
       内边距一起改掉，色带就缩在白色衬底里，做不出通栏效果。 */
    .au-page .au-card-split {
        grid-template-columns: 1fr;
        max-width: 460px;
        padding: 0;
    }
    .au-aside {
        padding: 14px 20px;
    }
    .au-aside-title,
    .au-aside-desc,
    .au-points,
    .au-aside-foot {
        display: none;
    }
    .au-form {
        padding: 24px 20px 22px;
    }
    body.site-login .wrap > .container > .alert,
    body.site-signup .wrap > .container > .alert {
        max-width: 460px;
    }
}

@media (max-width: 560px) {
    .au-page .au-grid {
        grid-template-columns: 1fr;
    }
    .au-page .au-grid > .au-span {
        grid-column: auto;
    }
    .au-page .au-title {
        font-size: 19px;
    }
}
