/* ========== 登录页样式 ========== */
:root {
    --primary: #4A90D9;
    --primary-light: #6BA3E0;
    --accent: #6C5CE7;
    --text-primary: #2D3436;
    --text-secondary: #636E72;
    --text-muted: #B2BEC3;
    --border-color: #E9ECEF;
    --font-family: -apple-system, BlinkMacSystemFont, "Microsoft YaHei", "Segoe UI", Roboto, sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: var(--font-family);
    background: #F0F2F5;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.login-container {
    display: flex;
    width: 900px;
    max-width: 95vw;
    min-height: 520px;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 4px 32px rgba(0, 0, 0, 0.08);
    overflow: hidden;
}

.login-left {
    flex: 1;
    background: linear-gradient(135deg, var(--primary), var(--accent));
    padding: 48px 40px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    color: #fff;
}

.brand-icon { width: 64px; height: 64px; margin-bottom: 16px; object-fit: contain; filter: brightness(0) invert(1); }
.login-brand h1 { font-size: 28px; font-weight: 700; margin-bottom: 8px; }
.login-brand p { font-size: 15px; opacity: 0.85; margin-bottom: 40px; }

.login-features { display: flex; flex-direction: column; gap: 16px; }
.feature-item {
    display: flex; align-items: center; gap: 12px;
    font-size: 15px; opacity: 0.9;
}
.feature-item i { font-size: 20px; }

.login-right {
    flex: 1;
    padding: 48px 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.login-form-wrapper { width: 100%; max-width: 340px; }
.form-title { font-size: 24px; font-weight: 600; color: var(--text-primary); margin-bottom: 6px; }
.form-subtitle { font-size: 14px; color: var(--text-secondary); margin-bottom: 32px; }

.form-group { margin-bottom: 20px; }
.form-group label {
    display: block; font-size: 13px; font-weight: 500;
    color: var(--text-secondary); margin-bottom: 6px;
}

.input-wrapper {
    display: flex; align-items: center; gap: 10px;
    border: 1px solid var(--border-color); border-radius: 10px;
    padding: 0 14px; height: 44px;
    transition: border-color 0.2s;
}
.input-wrapper:focus-within { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(74, 144, 217, 0.1); }
.input-wrapper i { color: var(--text-muted); font-size: 16px; }
.input-wrapper input {
    flex: 1; border: none; outline: none; font-size: 14px;
    color: var(--text-primary); background: transparent;
}
.input-wrapper input::placeholder { color: var(--text-muted); }

.form-group-inline {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.remember-label {
    display: flex !important;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    font-size: 13px;
    color: var(--text-secondary);
    margin-bottom: 0 !important;
}

.remember-label input[type="checkbox"] {
    width: 16px;
    height: 16px;
    accent-color: var(--primary);
    cursor: pointer;
}

.remember-select {
    height: 32px;
    padding: 0 8px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-size: 13px;
    color: var(--text-secondary);
    background: #fff;
    outline: none;
    cursor: pointer;
    transition: border-color 0.2s;
}

.remember-select:focus {
    border-color: var(--primary);
}

.remember-select:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.btn-login {
    width: 100%; height: 44px; border: none; border-radius: 10px;
    background: linear-gradient(135deg, var(--primary), var(--accent));
    color: #fff; font-size: 15px; font-weight: 500;
    cursor: pointer; transition: opacity 0.2s, transform 0.1s;
    margin-top: 8px;
}
.btn-login:hover { opacity: 0.9; }
.btn-login:active { transform: scale(0.98); }

.btn-home {
    width: 100%;
    height: 44px;
    border: 1px solid var(--border-color);
    border-radius: 10px;
    background: #fff;
    color: var(--text-secondary);
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    margin-top: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
}

.btn-home:hover {
    border-color: var(--primary);
    color: var(--primary);
    text-decoration: none;
}

.form-footer {
    text-align: center; margin-top: 24px;
    font-size: 13px; color: var(--text-secondary);
}
.form-footer a { color: var(--primary); text-decoration: none; font-weight: 500; }
.form-footer a:hover { text-decoration: underline; }
.footer-divider { margin: 0 8px; color: var(--border-color); }

/* Toast通知 */
.alert-toast {
    position: fixed; top: 24px; right: 24px;
    padding: 12px 24px; border-radius: 10px;
    font-size: 14px; color: #fff; z-index: 9999;
    transform: translateX(120%); transition: transform 0.3s ease;
    box-shadow: 0 4px 16px rgba(0,0,0,0.15);
}
.alert-toast.show { transform: translateX(0); }
.alert-toast-success { background: #00B894; }
.alert-toast-error { background: #E17055; }
.alert-toast-warning { background: #FDCB6E; color: #2D3436; }
.alert-toast-info { background: #4A90D9; }

@media (max-width: 768px) {
    .login-container { flex-direction: column; }
    .login-left { padding: 32px 24px; }
    .login-right { padding: 32px 24px; }
}


/* 短信验证码输入框 */
.sms-input-wrapper {
    display: flex;
    gap: 8px;
    align-items: center;
}

.btn-sms {
    height: 44px;
    padding: 0 16px;
    border: 1px solid var(--border-color);
    border-radius: 10px;
    background: #fff;
    color: var(--primary);
    font-size: 13px;
    font-weight: 500;
    white-space: nowrap;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-sms:hover:not(:disabled) {
    border-color: var(--primary);
    background: var(--primary);
    color: #fff;
}

.btn-sms:disabled {
    cursor: not-allowed;
    opacity: 0.6;
    color: var(--text-muted);
}


/* 必填标记 */
.required {
    color: #E17055;
    margin-left: 2px;
}

/* 输入框错误状态 */
.input-wrapper.error {
    border-color: #E17055;
    box-shadow: 0 0 0 3px rgba(225, 112, 85, 0.1);
}

.input-wrapper.error input {
    color: #E17055;
}
