/* ============================================================================
   门禁页（登录 / 注册 / 渠道注册）· 墨绿品牌门面
   2026-11

   为什么用墨绿而不是官网的科技蓝：
   - 官网是「对外展示」，蓝紫渐变合适；
   - 登录注册是「进入工作区」的第一步，往后就是墨绿的推广中心/员工台，
     用同一套墨绿能让人感觉「进门了」，而不是在官网里又看到一个弹窗表单。
   - 访客/学员登录后去学习、推广员登录后去后台，都从这扇墨绿的门进。

   布局：桌面左右分屏（左品牌 46% / 右表单 54%），手机收成单列（顶部品牌条 + 表单）。
   ========================================================================== */

/* ---------------------------------------------------------------------------
   0. 基础
   --------------------------------------------------------------------------- */
.auth-body {
	margin: 0;
	min-height: 100vh;
	background:
		radial-gradient(900px 620px at 16% 6%, rgba(110, 231, 183, .18), transparent 62%),
		radial-gradient(680px 520px at 88% 92%, rgba(15, 118, 110, .3), transparent 60%),
		linear-gradient(142deg, #06110D 0%, #0B1F1A 52%, #0A2B25 100%);
	color: #EAF6F2;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB",
		"Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
	-webkit-font-smoothing: antialiased;
	-webkit-text-size-adjust: 100%;
}

.auth-body *, .auth-body *::before, .auth-body *::after { box-sizing: border-box; }

.auth {
	display: grid;
	grid-template-columns: minmax(0, 1fr) minmax(0, 1.06fr);
	min-height: 100vh;
}

/* ---------------------------------------------------------------------------
   1. 左侧品牌区
   --------------------------------------------------------------------------- */
.auth-brand {
	position: relative;
	display: flex;
	flex-direction: column;
	padding: 54px 58px 42px;
	overflow: hidden;
}

/* 极淡的网格纹，避免大面积纯色发闷 */
.auth-brand::after {
	content: "";
	position: absolute;
	inset: 0;
	background-image:
		linear-gradient(rgba(255, 255, 255, .04) 1px, transparent 1px),
		linear-gradient(90deg, rgba(255, 255, 255, .04) 1px, transparent 1px);
	background-size: 30px 30px;
	mask-image: radial-gradient(80% 90% at 12% 8%, #000, transparent 76%);
	-webkit-mask-image: radial-gradient(80% 90% at 12% 8%, #000, transparent 76%);
	pointer-events: none;
}

.auth-brand > * { position: relative; z-index: 1; }

/* 品牌行 */
.auth-logo {
	display: flex;
	align-items: center;
	gap: 12px;
	text-decoration: none;
}

.auth-logo .m {
	width: 40px;
	height: 40px;
	flex: none;
	border-radius: 12px;
	display: grid;
	place-items: center;
	background: linear-gradient(140deg, #6EE7B7, #0F766E);
	color: #06231C;
	font-size: 17px;
	font-weight: 800;
	letter-spacing: -.5px;
	box-shadow: 0 12px 26px -14px rgba(110, 231, 183, .85);
}

.auth-logo b {
	display: block;
	color: #fff;
	font-size: 15.5px;
	font-weight: 600;
	letter-spacing: .4px;
	line-height: 1.2;
}

.auth-logo i {
	display: block;
	margin-top: 3px;
	font-style: normal;
	font-size: 9.5px;
	letter-spacing: 2.4px;
	color: rgba(234, 246, 242, .36);
}

/* 主张 */
.auth-title {
	margin: auto 0 0;
	font-size: 38px;
	line-height: 1.32;
	letter-spacing: -1.4px;
	color: #fff;
	font-weight: 700;
}

.auth-title em {
	font-style: normal;
	color: #6EE7B7;
}

.auth-sub {
	margin: 16px 0 0;
	max-width: 430px;
	font-size: 13.5px;
	line-height: 1.95;
	color: rgba(234, 246, 242, .58);
}

/* 三个卖点 */
.auth-points {
	list-style: none;
	margin: 34px 0 auto;
	padding: 0;
	display: flex;
	flex-direction: column;
	gap: 14px;
	max-width: 430px;
}

.auth-points li {
	display: flex;
	align-items: flex-start;
	gap: 10px;
	font-size: 13px;
	line-height: 1.7;
	color: rgba(234, 246, 242, .74);
}

.auth-points li b {
	flex: none;
	width: 22px;
	height: 22px;
	margin-top: 1px;
	border-radius: 7px;
	display: grid;
	place-items: center;
	font-size: 11px;
	font-weight: 700;
	color: #06231C;
	background: rgba(110, 231, 183, .9);
}

.auth-points li span { min-width: 0; }
.auth-points li em { font-style: normal; color: #fff; font-weight: 600; }

/* 底部备案 */
.auth-copy {
	margin-top: 30px;
	font-size: 11.5px;
	line-height: 1.8;
	color: rgba(234, 246, 242, .3);
}

.auth-copy a { color: rgba(234, 246, 242, .3); text-decoration: none; }
.auth-copy a:hover { color: rgba(234, 246, 242, .55); }

/* ---------------------------------------------------------------------------
   2. 右侧表单区
   --------------------------------------------------------------------------- */
.auth-main {
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 48px 40px;
}

.auth-card {
	width: 100%;
	max-width: 396px;
	padding: 32px 32px 28px;
	background: #F5F3EE;
	border-radius: 22px;
	box-shadow: 0 40px 80px -46px rgba(0, 0, 0, .85), 0 2px 6px rgba(0, 0, 0, .12);
}

.auth-hd { margin-bottom: 22px; }

.auth-hd h2 {
	margin: 0;
	font-size: 23px;
	font-weight: 700;
	letter-spacing: -.6px;
	color: #16211D;
}

.auth-hd p {
	margin: 8px 0 0;
	font-size: 12.5px;
	line-height: 1.7;
	color: #5B6B65;
}

/* 表单 */
.auth-card .lg-form-item { margin-bottom: 12px; }

.auth-card .lg-input {
	width: 100%;
	height: 46px;
	padding: 0 14px;
	font-family: inherit;
	font-size: 14px;
	color: #16211D;
	background: #fff;
	border: 1px solid #E1DED4;
	border-radius: 12px;
	outline: none;
	transition: border-color .16s ease, box-shadow .16s ease;
}

.auth-card .lg-input::placeholder { color: #9AA79F; }

.auth-card .lg-input:focus {
	border-color: #0F766E;
	box-shadow: 0 0 0 3px rgba(15, 118, 110, .12);
}

/* 验证码行 */
.auth-card .lg-form-item[data-captcha],
.auth-card .lg-captcha-row {
	display: grid;
	grid-template-columns: minmax(0, 1fr) 130px;
	gap: 10px;
}

.auth-card .lg-captcha { min-width: 0; }

.auth-card .lg-captcha-img {
	display: flex;
	align-items: center;
	gap: 8px;
	height: 46px;
}

.auth-card .lg-captcha-img img {
	/* 验证码原图是 250×62，硬拉成 116×46 会变形，用 contain 保住字不变形 */
	width: 130px;
	height: 46px;
	object-fit: contain;
	border-radius: 12px;
	border: 1px solid #E1DED4;
	background: #fff;
	cursor: pointer;
	display: block;
}

/* 提交按钮：白卡上用墨绿实心，薄荷留在深色背景里 */
.auth-card .lg-btn {
	width: 100%;
	height: 48px;
	margin-top: 6px;
	border: 0;
	border-radius: 12px;
	font-family: inherit;
	font-size: 15px;
	font-weight: 700;
	letter-spacing: .5px;
	color: #fff;
	background: linear-gradient(135deg, #0F766E, #12A08F);
	cursor: pointer;
	box-shadow: 0 14px 28px -16px rgba(15, 118, 110, .95);
	transition: filter .16s ease, transform .1s ease;
}

.auth-card .lg-btn:hover { filter: brightness(1.05); }
.auth-card .lg-btn:active { transform: translateY(1px); }

/* 辅助链接 */
.auth-card .lg-ops {
	margin-top: 18px;
	padding-top: 16px;
	border-top: 1px dashed #DED9CD;
	text-align: center;
}

.auth-card .lg-ops p {
	margin: 0 0 8px;
	font-size: 12.5px;
	color: #5B6B65;
}

.auth-card .lg-ops p:last-child { margin-bottom: 0; }

.auth-card .lg-ops a {
	color: #0F766E;
	font-weight: 600;
	text-decoration: none;
	cursor: pointer;
}

.auth-card .lg-ops a:hover { color: #0B5F57; text-decoration: underline; }

.auth-card .lg-tip {
	margin-top: 10px;
	font-size: 11.5px;
	color: #8D9A94;
	line-height: 1.7;
}

/* 旧版 .lg-way / .lg-logo 结构（保留兼容，但门禁页已改用 auth-hd） */
.auth-card .lg-way { display: none; }
.auth-card .lg-logo { display: none; }

/* 页脚（登录/注册页原来那行 copyright） */
.auth-foot {
	margin-top: 18px;
	text-align: center;
	font-size: 11px;
	color: rgba(234, 246, 242, .28);
}

/* ---------------------------------------------------------------------------
   3. 注册页：两列表单
   --------------------------------------------------------------------------- */
.auth-card .lg-form-row {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 12px;
}

/* ---------------------------------------------------------------------------
   4. 手机 / 窄屏
   --------------------------------------------------------------------------- */
@media (max-width: 980px) {
	/* 单列时两行都按内容排：不写 rows 的话，auto 行会被 100vh 的多余空间拉开，
	   顶部品牌区会莫名多出 150px 空白 */
	.auth {
		grid-template-columns: 1fr;
		grid-template-rows: auto 1fr;
		align-content: start;
	}

	.auth-brand {
		padding: 26px 22px 22px;
		flex-direction: row;
		align-items: center;
		gap: 12px;
	}

	.auth-brand::after { display: none; }

	/* 手机上只留品牌行，主张与卖点收起来，把首屏让给表单 */
	.auth-title, .auth-sub, .auth-points, .auth-copy { display: none; }

	.auth-main {
		align-items: flex-start;
		padding: 8px 16px calc(28px + env(safe-area-inset-bottom));
	}

	.auth-card {
		max-width: 460px;
		padding: 24px 20px 22px;
		border-radius: 18px;
		box-shadow: 0 24px 50px -34px rgba(0, 0, 0, .9);
	}

	.auth-hd h2 { font-size: 21px; }
	.auth-foot { margin-top: 14px; }
}

/* 手机：注册页的两列字段合成一列，170px 宽输入框太难填 */
@media (max-width: 560px) {
	.auth-card .lg-form-row { grid-template-columns: 1fr; }
}

@media (max-width: 420px) {
	.auth-card .lg-form-item[data-captcha],
	.auth-card .lg-captcha-row { grid-template-columns: minmax(0, 1fr) 118px; }
	.auth-card .lg-captcha-img img { width: 118px; }
}

/* ---------------------------------------------------------------------------
   5. 渠道注册（/home/promoter/reg）：字段更多，卡片加宽
   --------------------------------------------------------------------------- */
.auth-card.is-wide { max-width: 520px; }

.auth-card .auth-sec {
	margin: 4px 0 14px;
	padding-top: 14px;
	border-top: 1px dashed #DED9CD;
	font-size: 12px;
	color: #8D9A94;
	letter-spacing: .3px;
}

/* 渠道注册沿用的 .pm-fld 结构，在浅色卡里重新上色 */
.auth-card .pm-fld { display: grid; gap: 6px; margin-bottom: 12px; }

.auth-card .pm-fld label {
	font-size: 12.5px;
	color: #5B6B65;
}

.auth-card .pm-fld input,
.auth-card .pm-fld select {
	width: 100%;
	height: 46px;
	padding: 0 14px;
	font-family: inherit;
	font-size: 14px;
	color: #16211D;
	background: #fff;
	border: 1px solid #E1DED4;
	border-radius: 12px;
	outline: none;
	box-sizing: border-box;
}

.auth-card .pm-fld input:focus,
.auth-card .pm-fld select:focus {
	border-color: #0F766E;
	box-shadow: 0 0 0 3px rgba(15, 118, 110, .12);
}

.auth-card .pm-fld input::placeholder { color: #9AA79F; }

.auth-card .pm-fld select {
	appearance: none;
	-webkit-appearance: none;
	background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%235B6B65' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 14px center;
	padding-right: 38px;
	cursor: pointer;
}

.auth-card .pm-req { color: #C2402F; font-style: normal; }

.auth-card .pm-reg-agree {
	display: flex;
	align-items: flex-start;
	gap: 8px;
	margin: 6px 0 14px;
	font-size: 12px;
	line-height: 1.7;
	color: #5B6B65;
	cursor: pointer;
}

.auth-card .pm-reg-agree input { margin-top: 2px; accent-color: #0F766E; }

.auth-card .pm-hint {
	font-size: 12px;
	line-height: 1.8;
	color: #8D9A94;
	margin-bottom: 12px;
}

/* 渠道注册页顶部那句「推荐人」 */
.auth-card .pm-reg-ref {
	display: inline-block;
	margin-top: 8px;
	padding: 3px 10px;
	border-radius: 999px;
	font-size: 11.5px;
	color: #0B5F57;
	background: #EAF6F2;
	border: 1px solid rgba(15, 118, 110, .22);
}

/* 渠道注册的表单按钮（原 .pm-btn.pri 是紫渐变，浅色卡里要换墨绿） */
.auth-card .pm-btn {
	background: #fff;
	border: 1px solid #DED9CD;
	color: #16211D;
	border-radius: 12px;
	min-height: 44px;
	font-family: inherit;
	font-size: 14px;
}

.auth-card .pm-btn.pri {
	background: linear-gradient(135deg, #0F766E, #12A08F);
	border-color: transparent;
	color: #fff;
	font-weight: 700;
	min-height: 48px;
	font-size: 15px;
	letter-spacing: .4px;
	box-shadow: 0 14px 28px -16px rgba(15, 118, 110, .95);
}

.auth-card .pm-btn.pri:hover { filter: brightness(1.05); }
.auth-card .pm-btn.block { width: 100%; }

/* 渠道注册页的「推荐码」只读框 */
.auth-card .pm-fld input[readonly] { background: #F1F5F2; color: #5B6B65; }
