/* ========== 全局重置 ========== */
.auth-page {
    margin: 0;
    padding: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "PingFang SC", "Microsoft YaHei", sans-serif;
    background: #f0f4f8;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ========== 主容器 ========== */
.auth-wrap {
    width: 100%;
    max-width: 1100px;
    min-height: 600px;
    display: flex;
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.12);
    background: #fff;
    margin: 20px;
}

/* ========== 左侧品牌面板 ========== */
.auth-brand {
    flex: 0 0 45%;
    background: linear-gradient(145deg, #1e293b, #0f172a);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 50px 40px;
    position: relative;
    overflow: hidden;
}
.auth-brand::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -30%;
    width: 400px;
    height: 400px;
    background: rgba(99, 102, 241, 0.08);
    border-radius: 50%;
    pointer-events: none;
}
.auth-brand-inner {
    position: relative;
    z-index: 1;
    width: 100%;
}
.auth-brand-logo {
    font-size: 1.2rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 40px;
    letter-spacing: 0.5px;
}
.auth-brand-logo i {
    font-size: 1.6rem;
    color: #818cf8;
}
.auth-brand-title {
    font-size: 2.4rem;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 16px;
}
.auth-brand-desc {
    font-size: 1rem;
    opacity: 0.7;
    line-height: 1.6;
    max-width: 90%;
}
.auth-brand-notice {
    margin-top: 30px;
    background: rgba(255,255,255,0.06);
    padding: 12px 18px;
    border-radius: 12px;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 10px;
    border-left: 3px solid #6366f1;
}
.auth-brand-copy {
    margin-top: 40px;
    font-size: 0.8rem;
    opacity: 0.4;
}

/* ========== 右侧表单区域 ========== */
.auth-main {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 30px;
    background: #fff;
}
.auth-box {
    width: 100%;
    max-width: 380px;
}
.auth-mbrand {
    display: none;
    text-align: center;
    margin-bottom: 24px;
}
.auth-mbrand-icon {
    font-size: 2rem;
    color: #6366f1;
}
.auth-mbrand-name {
    font-weight: 700;
    font-size: 1.2rem;
    color: #1e293b;
}

.auth-head h2 {
    font-size: 1.8rem;
    font-weight: 700;
    color: #0f172a;
    margin-bottom: 6px;
}
.auth-head p {
    color: #64748b;
    font-size: 0.95rem;
    margin-bottom: 24px;
}

/* ========== 表单元素 ========== */
.auth-row {
    position: relative;
    margin-bottom: 18px;
}
.auth-row .form-control {
    height: 48px;
    border-radius: 12px;
    border: 1.5px solid #e2e8f0;
    padding: 0 16px 0 44px;
    font-size: 0.95rem;
    transition: all 0.2s;
    background: #f8fafc;
}
.auth-row .form-control:focus {
    border-color: #6366f1;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
    background: #fff;
}
.auth-row-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: #94a3b8;
    font-size: 1rem;
    pointer-events: none;
}
.auth-pwd-toggle {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #94a3b8;
    cursor: pointer;
    font-size: 1rem;
    padding: 4px;
}
.auth-pwd-toggle:hover {
    color: #475569;
}

/* ========== 验证码 ========== */
.auth-captcha {
    display: flex;
    gap: 12px;
    align-items: center;
    margin-bottom: 20px;
}
.auth-captcha input {
    flex: 1;
    height: 46px;
    border-radius: 12px;
    border: 1.5px solid #e2e8f0;
    padding: 0 16px;
    font-size: 0.95rem;
    background: #f8fafc;
    transition: all 0.2s;
    text-transform: uppercase;
}
.auth-captcha input:focus {
    border-color: #6366f1;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
    background: #fff;
}
.auth-captcha-code {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 80px;
    height: 46px;
    background: #eef2f6;
    border-radius: 12px;
    font-weight: 700;
    font-size: 1.3rem;
    letter-spacing: 4px;
    color: #1e293b;
    cursor: pointer;
    user-select: none;
    border: 1px dashed #cbd5e1;
    transition: all 0.2s;
}
.auth-captcha-code:hover {
    background: #e2e8f0;
}

/* ========== 选项 ========== */
.auth-opt {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.9rem;
    margin-bottom: 24px;
    color: #475569;
}
.auth-opt a {
    color: #6366f1;
    text-decoration: none;
}
.auth-opt a:hover {
    text-decoration: underline;
}
.auth-opt label {
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
}
.auth-opt input[type="checkbox"] {
    width: 16px;
    height: 16px;
    accent-color: #6366f1;
}

/* ========== 按钮 ========== */
.auth-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    height: 48px;
    border: none;
    border-radius: 12px;
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    color: #fff;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.2s;
    cursor: pointer;
    text-decoration: none;
}
.auth-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(99, 102, 241, 0.3);
    color: #fff;
}
.auth-btn i {
    font-size: 1rem;
}

/* ========== 底部链接 ========== */
.auth-foot {
    text-align: center;
    margin-top: 20px;
    font-size: 0.9rem;
    color: #64748b;
}
.auth-foot a {
    color: #6366f1;
    text-decoration: none;
    font-weight: 500;
}
.auth-foot a:hover {
    text-decoration: underline;
}
.auth-foot span {
    margin: 0 8px;
    color: #cbd5e1;
}

/* ========== 提示信息 ========== */
.auth-alert {
    padding: 12px 16px;
    border-radius: 12px;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 16px;
    position: relative;
}
.auth-alert.err {
    background: #fef2f2;
    color: #b91c1c;
    border-left: 4px solid #ef4444;
}
.auth-alert.ok {
    background: #ecfdf5;
    color: #065f46;
    border-left: 4px solid #10b981;
}
.auth-alert .close-btn {
    background: none;
    border: none;
    font-size: 1.2rem;
    cursor: pointer;
    color: inherit;
    margin-left: auto;
    opacity: 0.6;
    padding: 0 4px;
}
.auth-alert .close-btn:hover {
    opacity: 1;
}

.auth-success {
    margin-top: 12px;
}
.auth-success .auth-btn {
    background: linear-gradient(135deg, #10b981, #34d399);
}
.auth-success .auth-btn:hover {
    box-shadow: 0 8px 24px rgba(16, 185, 129, 0.3);
}

/* ========== 响应式 ========== */
@media (max-width: 768px) {
    .auth-wrap {
        flex-direction: column;
        margin: 12px;
        border-radius: 16px;
        min-height: auto;
    }
    .auth-brand {
        flex: 0 0 auto;
        padding: 30px 24px;
        min-height: 160px;
        display: none;
    }
    .auth-main {
        padding: 24px 20px;
    }
    .auth-mbrand {
        display: block;
    }
    .auth-brand-title {
        font-size: 1.8rem;
    }
    .auth-box {
        max-width: 100%;
    }
    .auth-head h2 {
        font-size: 1.5rem;
    }
    .auth-row .form-control {
        height: 44px;
        font-size: 16px; /* 防止 iOS 缩放 */
    }
    .auth-btn {
        height: 44px;
    }
    .auth-captcha-code {
        width: 70px;
        height: 42px;
        font-size: 1.1rem;
    }
}

@media (max-width: 480px) {
    .auth-wrap {
        margin: 8px;
        border-radius: 12px;
    }
    .auth-main {
        padding: 16px 14px;
    }
    .auth-brand {
        padding: 20px 16px;
    }
    .auth-brand-title {
        font-size: 1.5rem;
    }
}