/* 登录页面通用样式 - 参考 Maison Lumière 设计 */
[v-cloak] { display: none; }

:root {
    --plum-900: #2E0F29;
    --plum-800: #3A1434;
    --plum-700: #4A1942;
    --plum-600: #5D2552;
    --rose-gold: #D4A574;
    --rose-gold-light: #E8C9A0;
    --rose-gold-dark: #B8895A;
    --ivory: #FAF7F2;
    --ivory-2: #F3EEE6;
    --ivory-3: #E5DDD0;
    --text-dark: #2A1A27;
    --text-muted: #8A7A85;
    --error: #C6384F;
    --success: #4A9D6E;
}

html, body { height: 100%; }
body {
    margin: 0;
    padding: 0;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: var(--ivory);
    color: var(--text-dark);
    -webkit-font-smoothing: antialiased;
}

/* ---------- 页面容器 ---------- */
.page {
    display: flex;
    height: 100vh;
    width: 100%;
    animation: fadeIn 0.8s ease-out;
    overflow: hidden;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(8px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ---------- 左侧：品牌展示区 ---------- */
.brand-side {
    flex: 0 0 50%;
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 100vh;
    padding: 56px 64px;
    overflow: hidden;
    color: #fff;
    background:
        linear-gradient(180deg, rgba(46,15,41,0.55) 0%, rgba(74,25,66,0.75) 60%, rgba(46,15,41,0.92) 100%),
        url('../images/static_bg.png') center/cover no-repeat,
        var(--plum-800);
}

.brand-hero {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.brand-side::before {
    content: '';
    position: absolute;
    top: -20%;
    right: -30%;
    width: 80%;
    height: 80%;
    background: radial-gradient(ellipse at center, rgba(212,165,116,0.18) 0%, transparent 60%);
    pointer-events: none;
}

.brand-side::after {
    content: '';
    position: absolute;
    bottom: -10%;
    left: -15%;
    width: 60%;
    height: 50%;
    background: radial-gradient(ellipse at center, rgba(212,165,116,0.1) 0%, transparent 65%);
    pointer-events: none;
}

.brand-logo {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.brand-logo-mark {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 4px;
}

.brand-logo-icon {
    width: 44px;
    height: 44px;
    border: 1.5px solid var(--rose-gold);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.brand-logo-icon img {
    height: 56px;
    margin-left: 90px;
}

.brand-logo-name {
    font-size: 26px;
    font-weight: 500;
    letter-spacing: 0.5px;
}

.brand-logo-tag {
    font-size: 11px;
    letter-spacing: 4px;
    text-transform: uppercase;
    color: var(--rose-gold-light);
    padding-left: 56px;
}

.brand-hero {
    position: relative;
    z-index: 2;
    max-width: 460px;
}

.brand-eyebrow {
    font-size: 12px;
    letter-spacing: 5px;
    text-transform: uppercase;
    color: var(--rose-gold);
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    gap: 14px;
}

.brand-eyebrow::before {
    content: '';
    display: inline-block;
    width: 32px;
    height: 1px;
    background: var(--rose-gold);
}

.brand-title {
    font-size: 42px;
    font-weight: 400;
    line-height: 1.2;
    margin-bottom: 24px;
}

.brand-title em {
    font-style: italic;
    color: var(--rose-gold-light);
    font-weight: 400;
}

.brand-subtitle {
    font-size: 16px;
    line-height: 1.75;
    color: rgba(255,255,255,0.72);
    max-width: 400px;
    font-weight: 400;
}

.brand-footer {
    position: relative;
    z-index: 2;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
    color: rgba(255,255,255,0.5);
    letter-spacing: 0.3px;
    margin-bottom: 12px;
}

.brand-footer-links {
    display: flex;
    gap: 28px;
}

.brand-footer-links a {
    color: rgba(255,255,255,0.5);
    text-decoration: none;
    transition: color 0.2s;
}

.brand-footer-links a:hover {
    color: var(--rose-gold-light);
}

/* ---------- 右侧：表单区 ---------- */
.form-side {
    flex: 1 1 50%;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding: 40px 48px;
    height: 100vh;
    overflow-y: auto;
    background: var(--ivory);
    position: relative;
}

.form-side::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--plum-700), var(--rose-gold), var(--plum-700));
    opacity: 0.6;
}

.form-container {
    width: 100%;
    max-width: 420px;
    animation: slideUp 0.7s ease-out 0.2s both;
    margin: auto 0;
    padding: 40px 0;
}

@keyframes slideUp {
    from { opacity: 0; transform: translateY(20px); }
    to   { opacity: 1; transform: translateY(0); }
}

.form-header {
    margin-bottom: 36px;
}

.form-title {
    font-size: 32px;
    font-weight: 500;
    color: var(--text-dark);
    margin-bottom: 10px;
    line-height: 1.2;
}

.form-subtitle {
    font-size: 15px;
    color: var(--text-muted);
    line-height: 1.6;
}

/* ---------- 表单字段 ---------- */
.form-field {
    margin-bottom: 20px;
}

.form-label {
    display: block;
    font-size: 13px;
    font-weight: 500;
    color: var(--text-dark);
    margin-bottom: 8px;
    letter-spacing: 0.2px;
}

.input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.input-icon {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    display: flex;
    align-items: center;
    transition: color 0.25s;
    pointer-events: none;
}

.input-wrapper:focus-within .input-icon {
    color: var(--plum-700);
}

.form-input {
    width: 100%;
    height: 50px;
    padding: 0 16px 0 48px;
    border: 1.5px solid var(--ivory-3);
    border-radius: 10px;
    background: #fff;
    font-family: inherit;
    font-size: 15px;
    color: var(--text-dark);
    transition: border-color 0.25s, box-shadow 0.25s, background 0.25s;
    outline: none;
}

.form-input::placeholder {
    color: #B8AEB5;
}

.form-input:hover {
    border-color: #CFC4CC;
}

.form-input:focus {
    border-color: var(--plum-700);
    box-shadow: 0 0 0 4px rgba(74,25,66,0.08);
    background: #fff;
}

.form-input.has-error {
    border-color: var(--error);
    background: #FDF4F5;
}

.form-input.has-error:focus {
    box-shadow: 0 0 0 4px rgba(198,56,79,0.1);
}

/* 密码强度指示器 */
.password-strength {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 16px;
    font-size: 12px;
    color: var(--text-muted);
    padding-left: 4px;
}

.strength-item {
    padding: 2px 8px;
    border-radius: 4px;
    background: var(--ivory-2);
    color: #c0c4cc;
    transition: all 0.2s;
}

.strength-item.weak {
    background: #FDF4F5;
    color: var(--error);
}

.strength-item.medium {
    background: #FDF6EC;
    color: #E6A23C;
}

.strength-item.strong {
    background: #F0F9EB;
    color: var(--success);
}

/* ---------- 表单选项行 ---------- */
.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 28px;
    margin-top: -4px;
}

.link-text {
    font-size: 13.5px;
    color: var(--plum-700);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s;
    cursor: pointer;
    background: none;
    border: none;
    padding: 0;
    font-family: inherit;
}

.link-text:hover {
    color: var(--plum-900);
    text-decoration: underline;
}

/* ---------- 提交按钮 ---------- */
.btn-primary {
    width: 100%;
    height: 52px;
    border: none;
    border-radius: 10px;
    background: var(--plum-700);
    color: #fff;
    font-family: inherit;
    font-size: 15px;
    font-weight: 500;
    letter-spacing: 0.3px;
    cursor: pointer;
    transition: background 0.25s, transform 0.15s, box-shadow 0.25s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    position: relative;
    overflow: hidden;
}

.btn-primary:hover:not(:disabled) {
    background: var(--plum-800);
    box-shadow: 0 6px 20px rgba(74,25,66,0.25);
    transform: translateY(-1px);
}

.btn-primary:active:not(:disabled) {
    transform: translateY(0);
}

.btn-primary:disabled {
    cursor: not-allowed;
    opacity: 0.85;
}

.btn-spinner {
    width: 18px;
    height: 18px;
    border: 2px solid rgba(255,255,255,0.3);
    border-top-color: #fff;
    border-radius: 50%;
    animation: spin 0.7s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ---------- 分隔线 ---------- */
.divider {
    display: flex;
    align-items: center;
    gap: 16px;
    margin: 28px 0;
    color: var(--text-muted);
    font-size: 13px;
}

.divider::before,
.divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--ivory-3);
}

/* ---------- 社交登录 ---------- */
.social-login {
    display: flex;
    gap: 12px;
    justify-content: center;
    margin-bottom: 24px;
}

.social-btn {
    width: 52px;
    height: 52px;
    border: 1.5px solid var(--ivory-3);
    border-radius: 10px;
    background: #fff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.25s;
    color: var(--text-muted);
}

.social-btn:hover {
    border-color: var(--plum-600);
    color: var(--plum-700);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(74,25,66,0.1);
}

.social-btn.wechat:hover { border-color: #07C160; color: #07C160; }

.social-btn svg {
    width: 22px;
    height: 22px;
}

/* ---------- 底部链接 ---------- */
.form-footer {
    text-align: center;
    font-size: 14px;
    color: var(--text-muted);
    margin-top: 12px;
}

.form-footer a {
    color: var(--plum-700);
    font-weight: 600;
    text-decoration: none;
    margin-left: 4px;
    transition: color 0.2s;
}

.form-footer a:hover {
    color: var(--plum-900);
    text-decoration: underline;
}

/* ---------- 验证码输入 ---------- */
.code-input {
    display: flex;
    gap: 12px;
    align-items: center;
}

.code-input .form-input {
    flex: 1;
}

.code-img {
    height: 50px;
    width: 120px;
    cursor: pointer;
    border-radius: 10px;
    border: 1.5px solid var(--ivory-3);
    object-fit: cover;
    transition: border-color 0.2s;
}

.code-img:hover {
    border-color: var(--plum-600);
}

/* ---------- 底部版权 ---------- */
.login-footer {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    text-align: center;
    padding: 16px;
    color: var(--text-muted);
    font-size: 13px;
    background: rgba(250, 247, 242, 0.9);
    backdrop-filter: blur(10px);
    z-index: 10;
}

.login-footer a {
    color: var(--plum-700);
    text-decoration: none;
    transition: color 0.2s;
}

.login-footer a:hover {
    color: var(--plum-900);
}

/* ---------- 微信登录容器 ---------- */
#login_container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 300px;
}

/* ---------- 响应式 ---------- */
@media (max-height: 820px) and (min-width: 961px) {
    .brand-side { padding: 36px 64px; }
    .brand-title { font-size: 38px; margin-bottom: 18px; }
    .brand-eyebrow { margin-bottom: 18px; }
    .brand-subtitle { margin-top: 8px; }
    .brand-footer { padding-top: 14px; }
}

@media (max-height: 660px) and (min-width: 961px) {
    .brand-side { padding: 22px 64px; }
    .brand-title { font-size: 30px; margin-bottom: 12px; }
    .brand-eyebrow { margin-bottom: 14px; }
    .brand-subtitle { display: none; }
    .brand-footer { padding-top: 10px; font-size: 11px; }
}

@media (max-width: 960px) {
    .page {
        flex-direction: column;
        height: auto;
        min-height: 100vh;
    }
    .brand-side {
        flex: none;
        height: auto;
        min-height: 280px;
        padding: 40px 32px;
    }
    .brand-title { font-size: 32px; }
    .brand-hero { max-width: 100%; }
    .brand-subtitle { max-width: 100%; }
    .form-side {
        flex: 1;
        height: auto;
        min-height: calc(100vh - 280px);
        padding: 40px 28px;
    }
    .form-container {
        margin: 0 auto;
    }
    .brand-footer {
        padding: 24px 0 0 0;
    }
}

@media (max-width: 480px) {
    .brand-side { min-height: 240px; padding: 32px 24px; }
    .brand-title { font-size: 26px; margin-bottom: 16px; }
    .brand-eyebrow { font-size: 10px; letter-spacing: 3px; margin-bottom: 16px; }
    .brand-logo-name { font-size: 22px; }
    .brand-logo-icon { width: 38px; height: 38px; }
    .form-side { padding: 32px 20px; }
    .form-title { font-size: 26px; }
    .form-header { margin-bottom: 28px; }
}
