/* 共享认证页样式 — 极简风格 */
* { box-sizing: border-box; }
html, body {
    margin: 0; padding: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
    background: #fafafa;
    color: #111827;
    line-height: 1.6; font-size: 14px;
    min-height: 100vh;
}
body {
    display: flex; align-items: center; justify-content: center;
    padding: 24px 16px;
}

/* 卡片 */
.auth-card {
    width: 100%;
    max-width: 420px;
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 14px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
    padding: 32px 32px 28px;
}

/* 品牌头 */
.brand {
    text-align: center;
    margin-bottom: 24px;
}
.brand-mark {
    width: 56px; height: 56px;
    border-radius: 14px;
    margin: 0 auto 12px;
    background: transparent;
    display: flex; align-items: center; justify-content: center;
    overflow: hidden;
}
.brand-title {
    font-size: 19px; font-weight: 600;
    color: #111827;
    margin-bottom: 4px;
}
.brand-subtitle {
    font-size: 11px;
    color: #9ca3af;
    letter-spacing: 0.5px;
}

/* 表单 */
.form-title {
    font-size: 14px;
    font-weight: 600;
    color: #111827;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid #e5e7eb;
}
.form-group { margin-bottom: 14px; }
.form-label {
    display: block;
    font-size: 12px;
    color: #4b5563;
    margin-bottom: 6px;
    font-weight: 500;
}
.form-input {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    background: #ffffff;
    font-family: inherit;
    font-size: 14px;
    color: #111827;
    transition: all 0.15s;
    outline: none;
}
.form-input:focus {
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}
.form-input::placeholder { color: #9ca3af; }
.form-input.error {
    border-color: #dc2626;
    box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.08);
}
.form-hint {
    font-size: 11px;
    color: #9ca3af;
    margin-top: 5px;
}

/* 提示 */
.alert {
    padding: 10px 14px;
    border-radius: 8px;
    font-size: 12.5px;
    margin-bottom: 14px;
    display: none;
    border: 1px solid transparent;
}
.alert.show { display: block; }
.alert-error {
    background: #fef2f2;
    border-color: #fecaca;
    color: #dc2626;
}
.alert-success {
    background: #f0fdf4;
    border-color: #bbf7d0;
    color: #059669;
}

/* 按钮 */
.btn {
    width: 100%;
    padding: 11px 20px;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.15s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}
.btn-primary {
    background: #2563eb;
    color: white;
}
.btn-primary:hover {
    background: #1d4ed8;
}
.btn-primary:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* 切换链接 */
.switch-link {
    text-align: center;
    margin-top: 18px;
    padding-top: 18px;
    border-top: 1px solid #e5e7eb;
    font-size: 13px;
    color: #6b7280;
}
.switch-link a {
    color: #2563eb;
    text-decoration: none;
    font-weight: 500;
    margin-left: 4px;
}
.switch-link a:hover {
    color: #1d4ed8;
    text-decoration: underline;
}

/* 密码强度 */
.pwd-strength {
    height: 3px;
    background: #e5e7eb;
    border-radius: 2px;
    margin-top: 6px;
    overflow: hidden;
}
.pwd-strength-bar {
    height: 100%;
    width: 0;
    transition: all 0.2s;
}
.pwd-strength-bar.weak { width: 33%; background: #fca5a5; }
.pwd-strength-bar.medium { width: 66%; background: #60a5fa; }
.pwd-strength-bar.strong { width: 100%; background: #059669; }

/* Loading */
.spinner {
    display: inline-block;
    width: 14px; height: 14px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* 底部 */
.footer {
    text-align: center;
    margin-top: 20px;
    font-size: 11px;
    color: #9ca3af;
}
.footer a { color: #2563eb; text-decoration: none; }
.footer a:hover { text-decoration: underline; }

@media (max-width: 480px) {
    .auth-card { padding: 24px 20px; }
    .brand-title { font-size: 18px; }
}
