/* 基础样式 */
* {
	margin: 0;
	padding: 0;
	box-sizing: border-box;
	font-family: 'Inter', system-ui, -apple-system, sans-serif;
}

body {
	background-color: #f9fafb;
	min-height: 100vh;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 16px;
	color: #1D2129;
}

/* 主容器 */
.container {
	width: 100%;
	max-width: 835px;
	display: grid;
	grid-template-columns: 1fr;
	box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
	border-radius: 12px;
	overflow: hidden;
}

@media (min-width: 1024px) {
	.container {
		grid-template-columns: 2fr 3fr;
	}
}

/* 品牌区域 */
.brand-section {
	display: none;
	background: linear-gradient(135deg, #9d16ff 0%, #0E42D2 100%);
	padding: 48px;
	color: white;
	flex-direction: column;
	justify-content: center;
	width: 380px;
}

@media (min-width: 1024px) {
	.brand-section {
		display: flex;
	}
}

.brand-title {
	font-size: clamp(1.8rem, 5vw, 2.5rem);
	font-weight: bold;
	margin-bottom: 8px;
}

.features {
	margin-top: 40px;
	display: flex;
	flex-direction: column;
	gap: 24px;
}

.feature-item {
	display: flex;
	gap: 16px;
}

.feature-icon {
	background-color: rgba(255, 255, 255, 0.2);
	padding: 12px;
	border-radius: 8px;
	margin-top: 4px;
}

.feature-title {
	font-size: 1.25rem;
	font-weight: 600;
	margin-bottom: 4px;
}

.feature-desc {
	color: rgba(255, 255, 255, 0.7);
	line-height: 1.5;
}

.copyright {
	margin-top: auto;
	padding-top: 64px;
	color: rgba(255, 255, 255, 0.6);
	font-size: 0.875rem;
}

/* 登录区域 */
.login-section {
	background-color: white;
	padding: 32px;
	display: flex;
	flex-direction: column;
	height: 588px;
	width: 500px;
}

@media (min-width: 768px) {
	.login-section {
		padding: 48px;
	}
}

.mobile-brand {
	margin-bottom: 32px;
	display: block;
}

@media (min-width: 1024px) {
	.mobile-brand {
		display: none;
	}
}

.mobile-brand-title {
	font-size: clamp(1.5rem, 5vw, 2rem);
	font-weight: bold;
	margin-bottom: 4px;
}

.mobile-brand-desc {
	color: #86909C;
}

.login-header {
	margin-top: 24px;
	margin-bottom: 10px;
}

.login-title {
	font-size: clamp(1.5rem, 3vw, 2rem);
	font-weight: bold;
	margin-bottom: 8px;
}

.login-subtitle {
	color: #86909C;
}

/* 登录标签切换 */
.tabs {
	border-bottom: 1px solid #e5e7eb;
	margin-bottom: 32px;
}

.tabs-container {
	display: flex;
	gap: 32px;
}

.tab {
	padding: 12px 4px;
	border-bottom: 2px solid transparent;
	color: #6b7280;
	font-weight: 500;
	cursor: pointer;
	transition: all 0.3s ease-in-out;
	background: none;
	border: none;
	font-size: 1rem;
}

.tab.active {
	border-bottom-color: #165DFF;
	color: #165DFF;
}

.tab:hover:not(.active) {
	color: #374151;
}

/* 表单样式 - 关键修改：统一表单高度 */
.login-forms {
	flex: 1;
}

.form {
	display: none;
	min-height: 260px;
	width: 350px;
	/* 固定表单最小高度，确保所有表单高度一致 */
}

.form.active {
	display: block;
}

.form-group {
	margin-bottom: 20px;
	display: flex;
	align-items: center;
/* 	gap: 12px; */
}

.form-label {
	font-size: 0.875rem;
	font-weight: 500;
	color: #4b5563;
	min-width: 70px;
	/* 固定标签宽度，确保对齐 */
	white-space: nowrap;
}

.form-control {
	position: relative;
	flex: 1;
	/* 输入框占剩余空间 */
}

.input-icon {
	position: absolute;
	left: 12px;
	top: 50%;
	transform: translateY(-50%);
	color: #9ca3af;
}

.form-input {
	width: 100%;
	padding: 12px 12px 12px 40px;
	border: 1px solid #d1d5db;
	border-radius: 8px;
	font-size: 1rem;
	transition: all 0.3s ease-in-out;
}

.form-input:focus {
	outline: none;
	border-color: #165DFF;
	box-shadow: 0 0 0 3px rgba(22, 93, 255, 0.1);
}

.form-actions {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-bottom: 20px;
	margin-left: 82px;
	/* 与标签+间距宽度保持一致，确保对齐 */
}

.remember-me {
	display: flex;
	align-items: center;
	gap: 8px;
}

.remember-checkbox {
	width: 16px;
	height: 16px;
	color: #165DFF;
	border-color: #d1d5db;
}

.remember-label {
	font-size: 0.875rem;
	color: #4b5563;
}

.forgot-password {
	font-size: 0.875rem;
	color: #165DFF;
	text-decoration: none;
	transition: color 0.3s ease-in-out;
}

.forgot-password:hover {
	color: #0E42D2;
}

.btn {
	width: 100%;
	padding: 12px;
	background-color: #165DFF;
	color: white;
	border: none;
	border-radius: 8px;
	font-size: 1rem;
	font-weight: 500;
	cursor: pointer;
	transition: all 0.3s ease-in-out;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
}

.btn:hover {
	background-color: #0E42D2;
}

/* 短信登录特定样式 */
.code-container {
	position: relative;
}

.send-code-btn {
	position: absolute;
	right: 0;
	top: 0;
	height: 100%;
	padding: 0 12px;
	background: none;
	border: none;
	color: #165DFF;
	font-weight: 500;
	cursor: pointer;
	transition: color 0.3s ease-in-out;
}

.send-code-btn:hover {
	color: #0E42D2;
}

.send-code-btn:disabled {
	color: #9ca3af;
	cursor: not-allowed;
	opacity: 0.7;
}

/* 扫码登录特定样式 - 关键修改：调整二维码大小和位置 */
.qrcode-container {
	display: flex;
	flex-direction: column;
	align-items: center;
}
.qr_code {
	width: 160px;
    height: 160px;
}
.qrcode-wrapper {
	background-color: white;
	border: 2px solid #e5e7eb;
	border-radius: 8px;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
	margin-bottom: 18px;
	/* 减少底部间距 */
}

.qrcode-placeholder {
	width: 160px;
	/* 缩小二维码尺寸 */
	height: 160px;
	background-color: #f3f4f6;
	display: flex;
	align-items: center;
	justify-content: center;
	position: relative;
}

.qrcode-info {
	text-align: center;
	margin-bottom: 18px;
	/* 减少底部间距 */
}

.qrcode-title {
	color: #4b5563;
	font-weight: 500;
	margin-bottom: 6px;
	font-size: 0.95rem;
	/* 略微缩小字体 */
}

.qrcode-desc {
	font-size: 0.825rem;
	/* 略微缩小字体 */
	color: #86909C;
}

.qr-overlay {
    position: absolute;
    width: 160px;
    height: 160px;
    background-color: rgba(0, 0, 0, 0.7);
    /* 半透明黑色覆盖层 */
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    color: white;
    left: 0;
    right: 0;
    top: 0;
    bottom: 0;
    margin: 0 auto;
}

.qr-overlay .text {
    font-size: 12px;
    padding: 0px 16px;
    text-align: center;
}

.refresh-qrcode {
	background: none;
	border: none;
	color: #165DFF;
	font-weight: 500;
	cursor: pointer;
	display: flex;
	align-items: center;
	gap: 4px;
	transition: color 0.3s ease-in-out;
}

.refresh-qrcode:hover {
	color: #0E42D2;
}

/* 移动端版权信息 */
.mobile-copyright {
	margin-top: 48px;
	text-align: center;
	color: #86909C;
	font-size: 0.875rem;
}

@media (min-width: 1024px) {
	.mobile-copyright {
		display: none;
	}
}

/* 密码显示/隐藏按钮 */
.toggle-password {
	position: absolute;
	right: 12px;
	top: 50%;
	transform: translateY(-50%);
	background: none;
	border: none;
	color: #9ca3af;
	cursor: pointer;
}

.toggle-password:hover {
	color: #4b5563;
}

/* 移动端适配：小屏幕下恢复换行显示 */
@media (max-width: 576px) {
	.form {
		min-height: auto;
		/* 移动端不固定高度 */
	}

	.form-group {
		flex-direction: column;
		align-items: flex-start;
		gap: 4px;
	}

	.form-actions {
		margin-left: 0;
	}

	.qrcode-placeholder {
		width: 140px;
		height: 140px;
	}
}

/* 底部链接 */
.login-links {
	display: flex;
	justify-content: center;
	gap: 20px;
	margin-top: 10px;
}

.login-links a {
	color: #165DFF;
	font-size: 14px;
	text-decoration: none;
}

.login-links a:hover {
	text-decoration: underline;
}