/* =========================================================
   内页 · 详情页（产品 / 技术文章 / 案例 / 百科）
   依赖 archive.css 提供的内页头、侧栏、Box 等通用件
   ========================================================= */

/* ---------- 详情页内页头（较矮，标题为主） ---------- */
.zg-pagehead-single { padding: 38px 0 34px; }
.zg-pagehead-single .zg-pagehead-title {
	max-width: 900px;
	margin-top: 12px;
	font-size: 28px;
	line-height: 1.45;
}
.zg-pagehead-single .zg-pagehead-meta { margin-top: 16px; }
.zg-pagehead-meta .zg-channel {
	background: var(--zg-grad);
	border-color: transparent;
	font-weight: 600;
}

/* ---------- 主体 ---------- */
.zg-doc { padding: 34px 0 64px; }

.zg-doc-hero {
	margin: 0 0 26px;
	border-radius: 14px;
	overflow: hidden;
	box-shadow: 0 14px 34px rgba(10, 29, 51, 0.14);
	background: linear-gradient(135deg, #eaf2fb, #dbe9f8);
}
.zg-doc-hero img {
	display: block;
	width: 100%;
	height: auto;
	aspect-ratio: 16 / 9;
	object-fit: cover;
}

/* 产品关键信息条 */
.zg-keyfacts {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 1px;
	margin: 0 0 26px;
	background: var(--zg-line);
	border: 1px solid var(--zg-line);
	border-radius: 12px;
	overflow: hidden;
}
.zg-keyfacts div {
	background: #fff;
	padding: 16px 18px;
}
.zg-keyfacts dt {
	margin: 0 0 6px;
	font-size: 12px;
	color: var(--zg-muted);
	letter-spacing: 0.3px;
}
.zg-keyfacts dd {
	margin: 0;
	font-size: 15px;
	font-weight: 700;
	color: var(--zg-navy);
}
.zg-keyfacts dd em { font-style: normal; color: var(--zg-blue); }

/* 文章信息卡（作者 / 日期 / 阅读时长） */
.zg-metabar {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 14px;
	margin: 0 0 24px;
	padding: 14px 18px;
	background: #fff;
	border: 1px solid var(--zg-line);
	border-radius: 12px;
	font-size: 13px;
	color: var(--zg-muted);
	box-shadow: var(--zg-shadow);
}
.zg-metabar .zg-avatar {
	width: 34px;
	height: 34px;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 13px;
	font-weight: 800;
	color: #fff;
	background: var(--zg-grad);
}
.zg-metabar strong { color: var(--zg-navy); }
.zg-metabar .zg-dot { width: 4px; height: 4px; border-radius: 50%; background: #cbd8e5; }

/* ---------- 目录 TOC ---------- */
.zg-toc {
	margin: 0 0 28px;
	padding: 18px 22px;
	background: #f7fbff;
	border: 1px solid #d9e8fa;
	border-radius: 12px;
}
.zg-toc-tit {
	display: flex;
	align-items: center;
	gap: 8px;
	margin: 0 0 12px;
	font-size: 14px;
	font-weight: 700;
	color: var(--zg-navy);
}
.zg-toc-tit::before {
	content: "";
	width: 4px;
	height: 14px;
	border-radius: 2px;
	background: var(--zg-grad);
}
.zg-toc ol { margin: 0; padding: 0 0 0 4px; list-style: none; counter-reset: zgtoc; }
.zg-toc li { margin: 0; }
.zg-toc li::before {
	counter-increment: zgtoc;
	content: counter(zgtoc, decimal-leading-zero);
	margin-right: 10px;
	font-size: 12px;
	font-weight: 700;
	color: var(--zg-cyan);
}
.zg-toc a { display: inline-block; padding: 5px 0; font-size: 14px; color: var(--zg-ink); text-decoration: none; }
.zg-toc a:hover { color: var(--zg-blue); }
.zg-toc a.is-current { color: var(--zg-blue); font-weight: 700; }
.zg-toc li.zg-toc-sub { padding-left: 26px; }
.zg-toc li.zg-toc-sub::before { content: "·"; color: #9ab7d8; }
.zg-toc li.zg-toc-sub a { font-size: 13.5px; color: var(--zg-muted); }

/* ---------- 正文排版 ---------- */
.zg-content {
	background: #fff;
	border: 1px solid var(--zg-line);
	border-radius: 14px;
	padding: 34px 38px 38px;
	box-shadow: var(--zg-shadow);
	font-size: 16px;
	line-height: 1.95;
	color: #2b3a48;
	overflow-wrap: break-word;
}
.zg-content > *:first-child { margin-top: 0; }
.zg-content > *:last-child { margin-bottom: 0; }

.zg-content p { margin: 0 0 20px; }
.zg-content strong { color: var(--zg-navy); font-weight: 700; }
.zg-content a { color: var(--zg-blue); text-decoration: underline; text-underline-offset: 3px; }
.zg-content a:hover { color: var(--zg-blue-d); }

.zg-content h2 {
	position: relative;
	margin: 42px 0 18px;
	padding: 4px 0 4px 16px;
	font-size: 22px;
	line-height: 1.5;
	color: var(--zg-navy);
	border-left: 5px solid transparent;
	border-image: var(--zg-grad) 1;
	scroll-margin-top: 90px;
}
.zg-content h3 {
	position: relative;
	margin: 30px 0 14px;
	padding-left: 20px;
	font-size: 18px;
	color: var(--zg-navy);
	scroll-margin-top: 90px;
}
.zg-content h3::before {
	content: "";
	position: absolute;
	left: 0;
	top: 8px;
	width: 10px;
	height: 10px;
	border-radius: 3px;
	background: var(--zg-cyan);
}
.zg-content h4 { margin: 24px 0 12px; font-size: 16px; color: var(--zg-navy); }

.zg-content ul,
.zg-content ol { margin: 0 0 20px; padding-left: 24px; }
.zg-content li { margin-bottom: 10px; }
.zg-content ul li::marker { color: var(--zg-blue); }
.zg-content ol li::marker { color: var(--zg-blue); font-weight: 700; }

.zg-content blockquote {
	margin: 24px 0;
	padding: 18px 22px;
	background: #f3f8ff;
	border-radius: 10px;
	border-left: 4px solid var(--zg-blue);
	color: #33465a;
	font-size: 15px;
	line-height: 1.85;
}
.zg-content blockquote p:last-child { margin-bottom: 0; }

.zg-content img {
	max-width: 100%;
	height: auto;
	border-radius: 10px;
	box-shadow: 0 6px 18px rgba(10, 29, 51, 0.1);
}
.zg-content figure { margin: 26px 0; }
.zg-content figcaption {
	margin-top: 10px;
	font-size: 13px;
	color: var(--zg-muted);
	text-align: center;
}

.zg-content table {
	width: 100%;
	margin: 24px 0;
	border-collapse: separate;
	border-spacing: 0;
	border: 1px solid var(--zg-line);
	border-radius: 10px;
	overflow: hidden;
	font-size: 14px;
}
.zg-content thead th {
	background: var(--zg-navy);
	color: #fff;
	font-weight: 600;
	padding: 13px 16px;
	text-align: left;
}
.zg-content tbody td { padding: 12px 16px; border-top: 1px solid var(--zg-line); }
.zg-content tbody tr:nth-child(even) td { background: #f8fbfe; }
.zg-content tbody tr:hover td { background: #f1f7ff; }

.zg-content code {
	padding: 2px 6px;
	border-radius: 5px;
	background: #eef4fb;
	color: var(--zg-blue-d);
	font-size: 14px;
}
.zg-content pre {
	margin: 22px 0;
	padding: 18px 20px;
	background: var(--zg-navy);
	color: #dbe9f8;
	border-radius: 10px;
	overflow-x: auto;
	font-size: 14px;
	line-height: 1.7;
}
.zg-content pre code { background: none; color: inherit; padding: 0; }
.zg-content hr { margin: 34px 0; border: 0; border-top: 1px dashed var(--zg-line); }

/* GEO 可抽取事实块：直答段 */
.zg-fact {
	margin: 26px 0;
	padding: 20px 24px;
	background: #f1fbf6;
	border: 1px solid #c9ecd9;
	border-left: 4px solid #1fae6e;
	border-radius: 12px;
}
.zg-fact-tit {
	display: block;
	margin-bottom: 8px;
	font-size: 13px;
	font-weight: 700;
	letter-spacing: 0.4px;
	color: #14764a;
	text-transform: uppercase;
}
.zg-fact p { margin: 0; font-size: 15.5px; line-height: 1.85; color: #22473a; }

/* 要点速览 */
.zg-keypoints {
	margin: 26px 0;
	padding: 20px 24px;
	background: #f7fbff;
	border: 1px solid #d9e8fa;
	border-radius: 12px;
}
.zg-keypoints h3 { margin: 0 0 12px; padding: 0; font-size: 16px; color: var(--zg-navy); }
.zg-keypoints h3::before { display: none; }
.zg-keypoints ul { margin: 0; padding-left: 20px; }
.zg-keypoints li { margin-bottom: 8px; font-size: 15px; }

/* ---------- 标签 ---------- */
.zg-tags {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px;
	margin: 26px 0 0;
}
.zg-tags-label { font-size: 13px; color: var(--zg-muted); margin-right: 4px; }
.zg-tags a {
	padding: 6px 14px;
	border-radius: 999px;
	font-size: 13px;
	color: var(--zg-muted);
	background: #fff;
	border: 1px solid var(--zg-line);
	text-decoration: none;
	transition: all 0.16s ease;
}
.zg-tags a:hover { color: var(--zg-blue); border-color: #bcd4f6; background: #f3f8ff; }

/* ---------- 上下篇 ---------- */
.zg-prevnext {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 16px;
	margin: 28px 0 0;
}
.zg-prevnext a {
	display: block;
	padding: 16px 20px;
	background: #fff;
	border: 1px solid var(--zg-line);
	border-radius: 12px;
	text-decoration: none;
	transition: all 0.18s ease;
}
.zg-prevnext a:hover { border-color: #c8ddfa; box-shadow: var(--zg-shadow-hover); transform: translateY(-2px); }
.zg-prevnext span { display: block; font-size: 12px; color: var(--zg-muted); margin-bottom: 6px; }
.zg-prevnext strong { font-size: 15px; font-weight: 600; color: var(--zg-ink); line-height: 1.6; }
.zg-prevnext a:hover strong { color: var(--zg-blue); }
.zg-prevnext .zg-pn-next { text-align: right; }

/* ---------- 底部 CTA ---------- */
.zg-end-cta {
	position: relative;
	overflow: hidden;
	margin: 30px 0 0;
	padding: 28px 32px;
	border-radius: 14px;
	color: #fff;
	background: linear-gradient(120deg, var(--zg-navy), #12456f);
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 20px;
	flex-wrap: wrap;
	box-shadow: 0 14px 32px rgba(10, 29, 51, 0.22);
}
.zg-end-cta::after {
	content: "";
	position: absolute;
	right: -80px;
	top: -90px;
	width: 260px;
	height: 260px;
	border-radius: 50%;
	background: radial-gradient(circle, rgba(0, 183, 212, 0.38), transparent 68%);
}
.zg-end-cta > * { position: relative; z-index: 2; }
.zg-end-cta strong { display: block; font-size: 19px; font-weight: 800; }
.zg-end-cta p { margin: 8px 0 0; font-size: 13.5px; color: rgba(255, 255, 255, 0.75); }
.zg-end-cta-actions { display: flex; gap: 12px; flex-wrap: wrap; }

/* ---------- 相关推荐 ---------- */
.zg-related { margin: 44px 0 0; }
.zg-related-head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	margin-bottom: 20px;
}
.zg-related-head h2 {
	position: relative;
	margin: 0;
	padding: 0 0 0 14px;
	font-size: 20px;
	color: var(--zg-navy);
	border: 0;
}
.zg-related-head h2::before {
	content: "";
	position: absolute;
	left: 0;
	top: 5px;
	width: 5px;
	height: 18px;
	border-radius: 3px;
	background: var(--zg-grad);
}
.zg-related-head a { font-size: 14px; color: var(--zg-blue); text-decoration: none; font-weight: 600; }

/* ---------- 阅读进度条 ---------- */
.zg-progress {
	position: fixed;
	left: 0;
	top: 0;
	z-index: 999;
	width: 100%;
	height: 3px;
	background: var(--zg-grad);
	transform: scaleX(0);
	transform-origin: 0 50%;
	transition: transform 0.08s linear;
	pointer-events: none;
}

/* ---------- 侧栏：咨询卡 & 目录 ---------- */
.zg-side-sticky { position: sticky; top: 90px; display: grid; gap: 20px; }
.zg-side-contact { list-style: none; margin: 0; padding: 0; }
.zg-side-contact li {
	display: flex;
	align-items: flex-start;
	gap: 10px;
	padding: 9px 0;
	font-size: 13.5px;
	line-height: 1.6;
	color: var(--zg-muted);
	border-bottom: 1px dashed var(--zg-line);
}
.zg-side-contact li:last-child { border-bottom: 0; }
.zg-side-contact li strong { color: var(--zg-navy); font-weight: 600; }

/* ---------- 响应式 ---------- */
@media (max-width: 1024px) {
	.zg-keyfacts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 680px) {
	.zg-pagehead-single { padding: 30px 0 26px; }
	.zg-pagehead-single .zg-pagehead-title { font-size: 21px; }
	.zg-content { padding: 22px 20px 26px; font-size: 15.5px; }
	.zg-content h2 { font-size: 19px; margin-top: 32px; }
	.zg-content h3 { font-size: 16.5px; }
	.zg-prevnext { grid-template-columns: 1fr; }
	.zg-prevnext .zg-pn-next { text-align: left; }
	.zg-end-cta { padding: 22px 20px; }
	.zg-end-cta strong { font-size: 17px; }
}
