/* ==========================================================================
   量体邦官网 移动端兼容 / 响应式补丁
   说明：本文件在 main.css、banner.css 之后加载，用于覆盖站点中写死的
        1200px 固定宽度、修正横向滚动、并提供移动端导航（汉堡菜单）。
   断点：>1024 桌面，768~1024 平板，<=768 手机。
   ========================================================================== */

/* ---------- 全局基础：消除横向滚动、图片自适应 ---------- */
html {
	overflow-x: hidden;            /* 覆盖 main.css 的 overflow-x:scroll */
}
html,
body {
	max-width: 100%;
}
* {
	-webkit-box-sizing: border-box;
	-moz-box-sizing: border-box;
	box-sizing: border-box;
}
img {
	max-width: 100%;               /* 图片不再撑破容器 */
}

/* 视觉隐藏但保留给搜索引擎/读屏器（用于 SEO 的 H1 等） */
.sr-only {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

/* ---------- 汉堡菜单按钮（默认桌面隐藏） ---------- */
.nav-toggle {
	display: none;
	position: absolute;
	top: 50%;
	right: 16px;
	transform: translateY(-50%);
	width: 44px;
	height: 44px;
	padding: 10px;
	background: transparent;
	border: 0;
	cursor: pointer;
	z-index: 1001;
}
.nav-toggle span {
	display: block;
	width: 100%;
	height: 2px;
	margin: 5px 0;
	background: rgb(116, 52, 129);
	border-radius: 2px;
	transition: transform .3s ease, opacity .3s ease;
}
.nav-toggle.is-active span:nth-child(1) {
	transform: translateY(7px) rotate(45deg);
}
.nav-toggle.is-active span:nth-child(2) {
	opacity: 0;
}
.nav-toggle.is-active span:nth-child(3) {
	transform: translateY(-7px) rotate(-45deg);
}

/* ---------- 通用：取消写死的最小/固定宽度 ---------- */
.header .content,
footer {
	min-width: 0;                  /* 覆盖 1200px 强制宽度 */
}
.swrap {
	min-width: 0 !important;       /* 覆盖 banner.css 的 min-width:1200px */
}
/* 关于我们页 H1（沿用原 h2 视觉） */
.contact-hero .container .wording h1 {
	font-size: 22px;
	padding: 0;
	margin: 0 0 10px;
	color: #fff;
}
.flow_pic > img {
	min-width: 0;
	width: 100%;
	height: auto;
}

/* 首页主图：轮播已停用，单图改为常规流式排版（覆盖 banner.css 的绝对定位/固定高度） */
.home-hero,
.home-hero .pic,
.home-hero .pic .img {
	position: static;
	height: auto;
	max-height: none;
}
.home-hero .pic .img > img {
	display: block;
	width: 100%;
	height: auto;
}

/* ==========================================================================
   平板：768px ~ 1024px
   ========================================================================== */
@media screen and (max-width: 1024px) {
	.cooperate,
	.massing,
	.feature_list_title {
		width: 100%;
		max-width: 1200px;
		margin: 40px auto;
		padding: 0 16px;
	}
	.cont {
		width: 100% !important;
		padding: 20px 16px !important;
	}
}

/* ==========================================================================
   手机：<= 768px
   ========================================================================== */
@media screen and (max-width: 768px) {

	/* ----- 顶部导航 ----- */
	.header .content {
		width: 100%;
		height: 60px;
		padding: 0 16px;
		position: relative;
	}
	.header .content .logo-link {
		display: inline-block;
	}
	.header .content .logo {
		line-height: 60px !important;
		font-size: 22px !important;
	}
	.nav-toggle {
		display: block;
	}
	.header .nav {
		float: none;
		position: absolute;
		top: 60px;
		left: 0;
		right: 0;
		background: #fff;
		box-shadow: 0 6px 12px rgba(0, 0, 0, .12);
		max-height: 0;
		overflow: hidden;
		transition: max-height .3s ease;
		z-index: 1000;
	}
	.header .nav.nav-open {
		max-height: 320px;
	}
	.header .nav ul {
		margin: 0;
		padding: 0;
	}
	.header .nav ul li {
		display: block;
		margin: 0;
		line-height: 1;
		border-top: 1px solid #f0eef2;
	}
	.header .nav ul li a {
		display: block;
		padding: 16px 20px;
		letter-spacing: 1px;
		font-size: 16px;
	}

	/* ----- 首页轮播 / 主图 ----- */
	.swrap {
		height: auto !important;
	}
	.swrap .pic,
	.swrap .pic .img {
		position: static !important;
		height: auto !important;
		max-height: none !important;
	}
	.swrap .pic .img > img {
		width: 100%;
		height: auto;
	}

	/* ----- 首页服务模块 ----- */
	.massing,
	.cooperate,
	.feature_list_title {
		width: 100%;
		margin: 30px auto;
		padding: 0 16px;
	}
	.massing_title,
	.cooperate_title,
	.feature_list_title {
		margin: 30px auto;
		font-size: 22px;
		background-size: contain;
	}
	.mode ul {
		padding: 0;
		margin: 0;
	}
	.mode_item,
	.mode_item_mid {
		width: 100%;
		float: none;
		margin: 16px 0;
	}
	.mode_pic {
		height: auto;
	}
	.mode_pic > img {
		height: auto;
	}
	.mode_word {
		height: auto;
	}

	/* ----- 关于我们 / 联系我们 ----- */
	.contact-hero {
		height: auto;
	}
	.contact-hero .container {
		padding: 0;
	}
	.aboutus_words {
		position: static;
		top: 0;
	}
	.contact-hero .container .wording {
		position: static;
		padding: 16px;
	}
	.contact-hero .container .wording p {
		width: auto;
		max-width: 100%;
	}
	.contact-wrapper {
		padding: 0 16px;
	}
	.contact-wrapper h2 {
		font-size: 22px;
	}

	/* ----- 内容文档页（服务条款 / 隐私条款） ----- */
	.container {
		width: 100%;
		padding: 0 16px;
	}
	.word,
	.files.word {
		font-size: 15px;
		margin-bottom: 30px;
	}

	/* ----- 紫雷链页 ----- */
	.cont {
		width: 100% !important;
		padding: 20px 16px !important;
	}
	.solution_li_con,
	.solution_li2_con {
		padding: 30px 0;
	}
	.solution_content,
	.solution_img,
	.solution_con {
		width: 100% !important;
		float: none !important;
		margin: 0 auto !important;
		position: static !important;
		left: auto !important;
		top: auto !important;
	}
	.solution_con {
		margin-top: 20px !important;
	}
	.box-l,
	.box-r,
	.box-l2,
	.box-r2 {
		position: static !important;
		left: auto !important;
		top: auto !important;
	}
	.solution_title {
		font-size: 22px;
		text-align: center;
	}
	.solution_int {
		font-size: 16px;
		text-align: center;
	}

	/* ----- 页脚 ----- */
	footer {
		padding: 16px;
	}
	footer .copyright {
		line-height: 1.8;
	}
	footer .copyright span {
		margin-left: 0 !important;
		display: block;
	}
}

/* ==========================================================================
   城市上门量体 SEO 落地页
   ========================================================================== */
.city-page { padding: 24px 16px 40px; color: #444; line-height: 1.8; }
.city-page .crumb { font-size: 13px; color: #999; margin-bottom: 18px; }
.city-page .crumb a { color: var(--cwb-primary); text-decoration: none; }
.city-page .crumb span { color: #666; }
.city-hero { text-align: center; padding: 34px 20px; margin-bottom: 28px; background: linear-gradient(135deg, #f4ecf8 0%, #fbf8fd 100%); border: 1px solid #efe6f4; border-radius: 14px; }
.city-hero h1 { font-size: 28px; color: #584f60; margin: 0 0 10px; }
.city-sub { color: #8a8a8a; font-size: 15px; margin: 0; }
.city-page section { margin: 30px 0; }
.city-page h2 { font-size: 21px; color: #584f60; margin: 0 0 16px; }
.city-page h3 { font-size: 17px; color: var(--cwb-primary); margin: 0 0 6px; }
.city-intro p, .city-flow p { font-size: 15px; }
.feat-list { list-style: none; margin: 0; padding: 0; display: flex; gap: 16px; flex-wrap: wrap; }
.feat-list li { flex: 1 1 220px; background: #faf8fb; border: 1px solid #efe9f1; border-radius: 8px; padding: 18px; }
.feat-list li p { margin: 0; font-size: 14px; color: #777; }
.district-list { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 10px; }
.district-list li { background: #f5f2f7; color: #5a5266; border-radius: 4px; padding: 7px 12px; font-size: 14px; }
.city-cta { text-align: center; margin: 36px 0; }
.btn-primary, .btn-ghost { display: inline-block; padding: 13px 32px; border-radius: 26px; text-decoration: none; font-size: 16px; margin: 6px; transition: transform .2s ease, box-shadow .2s ease, filter .2s ease, background .2s ease, color .2s ease; }
.btn-primary { background: linear-gradient(135deg, var(--cwb-gradient-start) 0%, var(--cwb-primary) 100%); color: #fff; box-shadow: 0 8px 22px rgba(184,72,222,.38); }
.btn-primary:hover { transform: translateY(-2px); filter: brightness(1.06); box-shadow: 0 12px 28px rgba(184,72,222,.5); }
.btn-ghost { border: 1.5px solid var(--cwb-primary); color: var(--cwb-primary); }
.btn-ghost:hover { background: var(--cwb-primary); color: #fff; transform: translateY(-2px); }
.city-group { margin-bottom: 24px; }
.city-group h2 { font-size: 17px; border-left: 4px solid var(--cwb-primary); padding-left: 10px; margin-bottom: 12px; }
.city-links, .related-cities { display: flex; flex-wrap: wrap; gap: 12px; }
.city-links a, .related-cities a {
	display: inline-block; color: var(--cwb-primary); background: #f6f1f8; border: 1px solid #e7d9ef;
	border-radius: 20px; padding: 8px 17px; text-decoration: none; font-size: 14px; transition: all .2s ease;
}
.city-links a:hover, .related-cities a:hover { background: var(--cwb-primary); color: #fff; border-color: var(--cwb-primary); box-shadow: 0 3px 10px rgba(116,52,129,.25); }
.related-cities { padding-top: 6px; }
.related-cities a:last-child { background: transparent; border-color: transparent; color: var(--cwb-primary); font-weight: bold; }
.related-cities a:last-child:hover { background: transparent; color: #50205c; box-shadow: none; }
@media screen and (max-width: 768px) {
	.city-hero h1 { font-size: 22px; }
	.city-page h2 { font-size: 18px; }
	.feat-list { gap: 12px; }
	.feat-list li { flex: 1 1 100%; }
	.btn-primary, .btn-ghost { display: block; margin: 10px 0; }
}

/* ==========================================================================
   页眉视觉分隔（吸顶 + 阴影 + 描边，避免与下方内容混在一起） + 页脚热门城市
   ========================================================================== */
.header.colorize {
	background: #fff;
	border-bottom: 1px solid #ececec;
	box-shadow: 0 2px 12px rgba(0, 0, 0, .07);
	position: sticky;
	top: 0;
	z-index: 50;
}
.header .nav ul li a:hover { color: var(--cwb-primary); }

/* 页脚热门城市入口 */
.footer-cities {
	max-width: 1000px;
	margin: 0 auto 18px;
	padding: 0 16px 16px;
	border-bottom: 1px solid rgba(255, 255, 255, .12);
	text-align: center;
	line-height: 2.2;
}
.footer-cities .fc-label { color: rgba(255, 255, 255, 0.78); font-size: 13px; margin-right: 4px; }
.footer-cities a {
	color: rgba(255, 255, 255, 0.95); text-decoration: none; font-size: 13px;
	padding: 2px 10px; margin: 2px; display: inline-block;
}
.footer-cities a:hover { color: #fff; text-decoration: underline; }
.footer-cities .fc-more { font-weight: bold; color: #fff; }
@media screen and (max-width: 768px) {
	.footer-cities { line-height: 2.4; }
}

/* ==========================================================================
   回到顶部按钮（T字形图标） + 移动端页脚 + 首页流程/模式 + logo 误触修复
   ========================================================================== */
.back-to-top {
	position: fixed; right: 20px; bottom: 26px;
	width: 46px; height: 46px; border: 0; border-radius: 50%;
	background: linear-gradient(135deg, var(--cwb-gradient-start) 0%, var(--cwb-primary) 100%); color: #fff; cursor: pointer;
	display: flex; align-items: center; justify-content: center;
	box-shadow: 0 6px 18px rgba(var(--cwb-primary-rgb), .35);
	opacity: 0; visibility: hidden; transform: translateY(10px);
	transition: opacity .3s ease, visibility .3s ease, transform .3s ease, box-shadow .2s ease, filter .2s ease;
	z-index: 99;
}
.back-to-top.show { opacity: 1; visibility: visible; transform: translateY(0); }
.back-to-top:hover { filter: brightness(1.1); box-shadow: 0 8px 22px rgba(var(--cwb-primary-rgb), .45); }

@media screen and (max-width: 768px) {
	.back-to-top { right: 14px; bottom: 16px; width: 42px; height: 42px; }

	/* ① 页脚链接：横排，分割线用与字号等高的细竖线 */
	footer .links ul { display: block; text-align: center; }
	footer .links ul li {
		display: inline-block; float: none; position: relative;
		padding: 4px 16px; line-height: 1.5; border-right: 0;
	}
	footer .links ul li:not(:last-child)::after {
		content: ""; position: absolute; right: 0; top: 50%;
		transform: translateY(-50%); width: 1px; height: 13px;
		background: rgba(255, 255, 255, .35);
	}

	/* ② 首页：服务流程/服务范围 大图满屏铺满（更大更清晰）；服务模式卡片缩小 */
	.massing .flow .flow_pic { margin: 0 -16px; }
	.massing .flow .flow_pic > img { width: 100%; }
	.mode_item, .mode_item_mid { padding: 8px; margin: 12px 0; }
	.mode_pic { height: auto; width: auto; text-align: center; }
	.mode_pic > img { width: auto; max-width: 150px; height: auto; margin: 0 auto; }
	.mode_title { font-size: 18px; }
	.mode_word { font-size: 14px; }

	/* ③ logo 点击区限制在 header 内，避免溢出误触下方面包屑 */
	.header .content .logo-link { display: inline-flex; align-items: center; height: 60px; overflow: hidden; vertical-align: top; }
	.header .content .cwb-logo-img { height: 56px !important; width: auto !important; max-width: 220px; }
	.header .content .logo { height: 60px !important; width: auto !important; line-height: 60px !important; }
	/* 面包屑/城市页内容与吸顶 header 拉开间距 */
	.city-page { padding-top: 18px; }
	.city-page .crumb { padding: 4px 0; }
}

/* 联系方式：客服电话/微信 按钮 + 公众号二维码 */
.contact-line { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; }
.contact-line .contact-val { font-weight: 600; color: var(--cwb-primary); }
.contact-btn {
	display: inline-block; padding: 5px 16px; border-radius: 18px; font-size: 13px; line-height: 1.6;
	background: linear-gradient(135deg, var(--cwb-gradient-start) 0%, var(--cwb-primary) 100%); color: #fff; border: 0; cursor: pointer;
	text-decoration: none; box-shadow: 0 4px 12px rgba(184,72,222,.3); transition: filter .2s ease, box-shadow .2s ease, background .2s ease;
}
.contact-btn:hover { filter: brightness(1.07); box-shadow: 0 6px 16px rgba(184,72,222,.42); }
.contact-btn.copied { background: #2e9e5b; box-shadow: 0 4px 12px rgba(46,158,91,.3); }
.qr-box { margin-top: 22px; }
.qr-box img { width: 150px; height: 150px; border: 1px solid #eee; border-radius: 8px; padding: 6px; background: #fff; }
.qr-box span { display: block; margin-top: 8px; color: #8a8a8a; font-size: 13px; }

/* ==========================================================================
   顶部导航：当前页选中态
   ========================================================================== */
/* 未选中：中性灰，让选中项更突出 */
.header .nav ul li a { color: #5b5663; transition: color .2s ease; }
.header .nav ul li a:hover { color: var(--cwb-primary); }
/* 选中：亮紫 + 加粗 + 文字正下方下划线 */
.header .nav ul li.active a { color: var(--cwb-primary); font-weight: bold; }
@media screen and (min-width: 769px) {
	.header .nav ul li.active a { border-bottom: 3px solid var(--cwb-primary); padding-bottom: 4px; }
}
@media screen and (max-width: 768px) {
	/* 移动端下拉：左侧紫条 + 淡紫底 */
	.header .nav ul li.active { background: #f7eefb; box-shadow: inset 4px 0 0 var(--cwb-primary); }
}
