/* ===== 全局重置 ===== */
* {
	margin: 0;
	padding: 0;
	box-sizing: border-box;
}
body {
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
	background: #f5f7fa;
	color: #1e2a3a;
	line-height: 1.6;
	-webkit-font-smoothing: antialiased;
}
a {
	text-decoration: none;
	color: inherit;
}

/* ===== 顶部导航 ===== */
.top-nav {
	background: #ffffff;
	border-bottom: 1px solid #e8ecf1;
	padding: 14px 32px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	flex-wrap: wrap;
	gap: 12px;
	position: sticky;
	top: 0;
	z-index: 100;
}
.top-nav .logo {
	display: flex;
	align-items: center;
	gap: 10px;
	font-size: 20px;
	font-weight: 700;
	color: #1a2b3c;
}
.top-nav .logo i {
	color: #3b82f6;
	font-size: 24px;
}
.top-nav .nav-links {
	display: flex;
	align-items: center;
	gap: 20px;
	font-size: 14px;
	font-weight: 500;
	color: #4d5e6f;
}
.top-nav .nav-links a {
	transition: color 0.2s;
}
.top-nav .nav-links a:hover {
	color: #3b82f6;
}
.top-nav .nav-links .btn-back {
	background: #eef4ff;
	color: #3b82f6;
	padding: 6px 16px;
	border-radius: 30px;
	font-weight: 600;
	transition: background 0.2s;
}
.top-nav .nav-links .btn-back:hover {
	background: #dbe7fe;
}

/* ===== 移动端顶部 ===== */
.mobile-header {
	display: none;
	background: #ffffff;
	padding: 12px 16px;
	border-bottom: 1px solid #eef1f5;
	align-items: center;
	justify-content: space-between;
	position: sticky;
	top: 0;
	z-index: 100;
}
.mobile-header .logo {
	display: flex;
	align-items: center;
	gap: 8px;
	font-size: 18px;
	font-weight: 700;
	color: #1a2b3c;
}
.mobile-header .logo i {
	color: #3b82f6;
	font-size: 22px;
}
.mobile-header .back-btn {
	background: #eef4ff;
	color: #3b82f6;
	padding: 4px 14px;
	border-radius: 30px;
	font-size: 13px;
	font-weight: 600;
}

/* ===== 主容器 ===== */
.detail-wrapper {
	max-width: 1280px;
	margin: 0 auto;
	padding:25px 20px 0 20px;
}

/* ===== 面包屑 ===== */
.breadcrumb {
	font-size: 13px;
	color: #7b8a9b;
	margin-bottom: 24px;
}
.breadcrumb a {
	color: #3b82f6;
}
.breadcrumb a:hover {
	text-decoration: underline;
}
.breadcrumb span {
	margin: 0 6px;
	color: #c5cdd8;
}

/* ===== 详情头部 ===== */
.detail-header {
	background: #ffffff;
	border-radius: 16px;
	padding: 32px 36px;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
	border: 1px solid #eef1f5;
	margin-bottom: 28px;
	display: flex;
	flex-wrap: wrap;
	gap: 28px;
	align-items: flex-start;
}
.detail-header .icon-wrapper {
	flex-shrink: 0;
	width: 72px;
	height: 72px;
	background: #eef4ff;
	border-radius: 16px;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 36px;
	color: #3b82f6;
}
.detail-header .info {
	flex: 1;
	min-width: 200px;
}
.detail-header .info .name {
	font-size: 28px;
	font-weight: 700;
	color: #0b1c2e;
	display: flex;
	align-items: center;
	gap: 12px;
	flex-wrap: wrap;
}
.detail-header .info .name .tag {
	font-size: 12px;
	font-weight: 600;
	background: #f43f5e;
	color: #fff;
	padding: 0 14px;
	border-radius: 30px;
	line-height: 26px;
}
.detail-header .info .subtitle {
	font-size: 15px;
	color: #6b7c8d;
	margin-top: 6px;
}
.detail-header .info .desc {
	font-size: 15px;
	color: #1e2a3a;
	margin-top: 12px;
	line-height: 1.8;
}
.detail-header .info .meta {
	display: flex;
	flex-wrap: wrap;
	gap: 16px 24px;
	margin-top: 16px;
	font-size: 14px;
	color: #6b7c8d;
}
.detail-header .info .meta i {
	margin-right: 6px;
	color: #3b82f6;
	width: 18px;
}
.detail-header .actions {
	flex-shrink: 0;
	display: flex;
	gap: 12px;
	align-items: center;
	flex-wrap: wrap;
	margin-top: 4px;
}
.detail-header .actions .btn-primary {
	background: #3b82f6;
	color: #fff;
	padding: 10px 28px;
	border-radius: 30px;
	font-weight: 600;
	font-size: 15px;
	transition: background 0.2s;
	border: none;
	cursor: pointer;
}
.detail-header .actions .btn-primary:hover {
	background: #2563eb;
}
.detail-header .actions .btn-outline {
	background: transparent;
	color: #3b82f6;
	padding: 10px 24px;
	border-radius: 30px;
	font-weight: 600;
	font-size: 15px;
	border: 1.5px solid #3b82f6;
	transition: all 0.2s;
	cursor: pointer;
}
.detail-header .actions .btn-outline:hover {
	background: #eef4ff;
}

/* ===== TABLE 样式 ===== */
.entry-content table,.content-detail table{
	width: 100%;
	border-collapse: collapse;
	margin: 1.5em 0;
	font-size: 15px;
	overflow: hidden;
}
.entry-content table thead,.content-detail table thead{
	background:#1a5cff;
	color: #fff;
}
.entry-content table th,.content-detail table th{
	padding: 12px 16px;
	text-align: left;
	font-weight: 600;
}
.entry-content table td,.content-detail table td{
	padding: 10px 16px;
	border-bottom: 1px solid var(--border-light);
}
.entry-content table td p,.content-detail table td p{
    margin-bottom:0px;
}
.entry-content table tbody tr,.content-detail table tbody tr{
	background: var(--bg-white);
	transition: background 0.15s;
}
.entry-content table tbody tr:nth-child(even),.content-detail table tbody tr:nth-child(even){
	background: var(--bg-body);
}
.entry-content table tbody tr:hover,.content-detail table tbody tr:hover{
	background: var(--primary-light);
}
.entry-content table tbody tr:last-child td,.content-detail table tbody tr:last-child td{
	border-bottom: none;
}

/* ===== PRE / CODE 样式 ===== */
.entry-content pre {
	background: #1e1e2a;
	color: #e4e4e4;
	padding: 20px 24px;
	border-radius: var(--radius-sm);
	overflow-x: auto;
	font-family: 'JetBrains Mono', 'Fira Code', 'Courier New', monospace;
	font-size: 14px;
	line-height: 1.7;
	margin: 1.5em 0;
	position: relative;
	box-shadow: var(--shadow-sm);
}
.entry-content pre code {
	background: transparent;
	padding: 0;
	font-family: inherit;
	color: inherit;
	font-size: inherit;
}
.entry-content code {
	background: var(--bg-body);
	padding: 0.2em 0.4em;
	border-radius: 4px;
	font-family: 'JetBrains Mono', 'Fira Code', 'Courier New', monospace;
	font-size: 0.9em;
	color: var(--primary-dark);
}
/* 代码块语言标签（纯装饰） */
.entry-content pre::before {
	content: attr(data-lang) ' 代码';
	position: absolute;
	top: 8px;
	right: 16px;
	font-size: 11px;
	color: rgba(255,255,255,0.3);
	font-family: var(--font);
	letter-spacing: 0.5px;
	text-transform: uppercase;
}

.entry-content ul,
.entry-content ol {
    margin-bottom: 1.2em;
}

/* 分隔线 */
.detail-divider {
	border: none;
	border-top: 2px solid #eef1f5;
	margin: 28px 0 24px 0;
}

/* 版权申明 */
.copyright-notice {
	background: #f8fafc;
	border-radius: 8px;
	padding: 16px 20px;
	font-size: 13px;
	color: #6b7c8d;
	border-left: 4px solid #3b82f6;
	margin-bottom: 24px;
}
.copyright-notice i {
	color: #3b82f6;
	margin-right: 8px;
}

/* 上一篇 / 下一篇 */
.post-nav {
	display: flex;
	justify-content: space-between;
	gap: 20px;
	margin-bottom: 24px;
	flex-wrap: wrap;
}
.post-nav .nav-item {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 10px 18px;
	border-radius: 8px;
	border: 1px solid #eef1f5;
	transition: all 0.2s;
	font-size: 14px;
	color: #3d4e5f;
	flex: 1;
	min-width: 120px;
	background: #f8fafc;
}
.post-nav .nav-item.prev {
	justify-content: flex-start;
}
.post-nav .nav-item.next {
	justify-content: flex-end;
	text-align: right;
}
.post-nav .nav-item .label {
	font-size: 12px;
	color: #9aa9b9;
	display: block;
}
.post-nav .nav-item .title {
	font-weight: 500;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
	max-width: 160px;
}
.post-nav .nav-item i {
	font-size: 14px;
	color: #7b8a9b;
	flex-shrink: 0;
}

/* 可点击状态 */
.post-nav .nav-item.clickable {
	background: #f8fafc;
	border-color: #eef1f5;
	cursor: pointer;
}
.post-nav .nav-item.clickable:hover {
	background: #eef4ff;
	border-color: #3b82f6;
	color: #3b82f6;
}
.post-nav .nav-item.clickable:hover i {
	color: #3b82f6;
}

/* 禁用状态（暂无下一篇） */
.post-nav .nav-item.disabled {
	background: #f5f6f8;
	border-color: #e8ecf1;
	color: #b0b8c4;
	cursor: default;
	opacity: 0.7;
}
.post-nav .nav-item.disabled i {
	color: #c5cdd8;
}
.post-nav .nav-item.disabled .label {
	color: #b0b8c4;
}
.post-nav .nav-item.disabled .title {
	color: #b0b8c4;
}

/* 标签云 */
.tag-cloud {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px 12px;
	margin-bottom: 28px;
	padding: 12px 0;
	border-top: 1px solid #eef1f5;
	border-bottom: 1px solid #eef1f5;
}
.tag-cloud .tag-label {
	font-size: 13px;
	font-weight: 600;
	color: #7b8a9b;
	margin-right: 4px;
}
.tag-cloud a {
	font-size: 13px;
	color: #4d5e6f;
	background: #f0f4f9;
	padding: 2px 14px;
	border-radius: 30px;
	line-height: 28px;
	transition: all 0.2s;
}
.tag-cloud a:hover {
	background: #3b82f6;
	color: #fff;
}

/* ===== 留言板块 ===== */
.comment-section {
	margin-top: 8px;
}
.comment-section h4 {
	font-size: 17px;
	font-weight: 700;
	color: #0b1c2e;
	margin-bottom: 16px;
	display: flex;
	align-items: center;
	gap: 8px;
}
.comment-section h4 i {
	color: #3b82f6;
}

/* ===== 详情主体 ===== */
.detail-body {
	display: grid;
	grid-template-columns: 2fr 1fr;
	gap: 28px;
	margin-bottom: 40px;
	align-items: flex-start;
}

/* 左列：内容详情 */
.content-detail {
	background: #ffffff;
	border-radius: 12px;
	padding: 28px 32px;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
	border: 1px solid #eef1f5;
}
.content-detail h2 {
	font-size: 20px;
	font-weight: 700;
	color: #0b1c2e;
	margin-bottom: 16px;
	display: flex;
	align-items: center;
	gap: 8px;
}
.content-detail h2 i {
	color: #3b82f6;
}
.content-detail p {
	font-size: 15px;
	color: #3d4e5f;
	line-height: 1.9;
	margin-bottom: 16px;
}
.content-detail p:last-child {
	margin-bottom: 0;
}
.content-detail h3 {
	font-size: 17px;
	font-weight: 600;
	color: #0b1c2e;
	margin-top: 20px;
	margin-bottom: 10px;
}
.content-detail ul {
	list-style: none;
	padding: 0;
	margin-bottom: 16px;
}
.content-detail ul li {
	padding: 6px 0;
	padding-left: 24px;
	position: relative;
	font-size: 15px;
	color: #3d4e5f;
	line-height: 1.7;
}
.content-detail ul li::before {
	content: "▸";
	position: absolute;
	left: 4px;
	color: #3b82f6;
	font-weight: 700;
}

/* ===== 右列：最新 + 热门（粘性定位） ===== */
.side-col {
	display: flex;
	flex-direction: column;
	gap: 24px;
	position: sticky;
	top: 80px;
	align-self: flex-start;
}

.side-block {
	background: #ffffff;
	border-radius: 12px;
	padding: 20px 22px;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
	border: 1px solid #eef1f5;
}
.side-block h4 {
	font-size: 16px;
	font-weight: 700;
	color: #0b1c2e;
	margin-bottom: 14px;
	display: flex;
	align-items: center;
	gap: 8px;
}
.side-block h4 i {
	color: #3b82f6;
}
.side-block .item-list {
	list-style: none;
}
.side-block .item-list a {
	padding: 10px 0;
	border-bottom: 1px solid #f0f4f9;
	display: flex;
	gap: 12px;
	align-items: flex-start;
}
.side-block .item-list a:last-child {
	border-bottom: none;
}
.side-block .item-list a .icon {
	flex-shrink: 0;
	width: 32px;
	height: 32px;
	background: #eef4ff;
	border-radius: 8px;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 14px;
	color: #3b82f6;
	margin-top: 2px;
}
.side-block .item-list a .info {
	flex: 1;
	min-width: 0;
}
.side-block .item-list a .info .name {
	font-size: 14px;
	font-weight: 600;
	color: #0b1c2e;
	line-height: 1.3;
}
.side-block .item-list a .info .desc {
	font-size: 12px;
	color: #6b7c8d;
	line-height: 1.4;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}
.side-block .item-list a .info .badge {
	font-size: 10px;
	font-weight: 600;
	background: #f43f5e;
	color: #fff;
	padding: 0 8px;
	border-radius: 30px;
	line-height: 18px;
	display: inline-block;
	margin-top: 2px;
}
.side-block .more-link {
	display: block;
	text-align: right;
	font-size: 13px;
	color: #3b82f6;
	font-weight: 500;
	margin-top: 10px;
}
.side-block .more-link i {
	margin-left: 4px;
	transition: transform 0.2s;
}
.side-block .more-link:hover i {
	transform: translateX(4px);
}

/* 热门工具特殊标记 */
.side-block.hot .item-list li .info .badge-hot {
	background: #f97316;
}

/* ===== 相似站点 ===== */
.similar-section {
	margin-top: 12px;
}
.similar-section .section-title {
	display: flex;
	align-items: center;
	justify-content: space-between;
	margin-bottom: 18px;
	flex-wrap: wrap;
	gap: 8px;
}
.similar-section .section-title h2 {
	font-size: 22px;
	font-weight: 700;
	color: #0b1c2e;
	display: flex;
	align-items: center;
	gap: 10px;
}
.similar-section .section-title h2 i {
	color: #3b82f6;
}
.similar-section .section-title .more-link {
	font-size: 14px;
	color: #3b82f6;
	font-weight: 500;
}
.similar-section .section-title .more-link i {
	margin-left: 4px;
	transition: transform 0.2s;
}
.similar-section .section-title .more-link:hover i {
	transform: translateX(4px);
}

.similar-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
	gap: 16px;
}

.similar-card {
	background: #ffffff;
	border-radius: 12px;
	padding: 18px 18px 14px 18px;
	border: 1px solid #eef1f5;
	transition: all 0.25s ease;
	cursor: default;
	display: flex;
	flex-direction: column;
}
.similar-card:hover {
	box-shadow: 0 8px 24px rgba(0, 0, 0, 0.07);
	transform: translateY(-3px);
	border-color: #dce3ec;
}
.similar-card .card-head {
	display: flex;
	gap: 12px;
	align-items: center;
	margin-bottom: 6px;
}
.similar-card .card-head .icon {
	flex-shrink: 0;
	width: 36px;
	height: 36px;
	background: #eef4ff;
	border-radius: 10px;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 18px;
	color: #3b82f6;
}
.similar-card .card-head .name {
	font-size: 15px;
	font-weight: 600;
	color: #0b1c2e;
	line-height: 1.3;
}
.similar-card .desc {
	font-size: 13px;
	color: #6b7c8d;
	line-height: 1.5;
	margin-top: 2px;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
	flex: 1;
}
.similar-card .footer {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-top: 10px;
	padding-top: 8px;
	border-top: 1px solid #f0f4f9;
}
.similar-card .footer .tag {
	font-size: 11px;
	font-weight: 500;
	color: #7b8a9b;
	background: #f0f4f9;
	padding: 0 10px;
	border-radius: 30px;
	line-height: 22px;
}
.similar-card .footer .link {
	font-size: 12px;
	color: #3b82f6;
	font-weight: 500;
}
.similar-card .footer .link i {
	font-size: 11px;
	transition: transform 0.2s;
}
.similar-card:hover .footer .link i {
	transform: translateX(4px);
}

/* ===== 响应式 ===== */
@media (max-width: 992px) {
	.detail-body {
		grid-template-columns: 1fr;
	}
	.detail-wrapper {
		padding: 20px 20px 40px 20px;
	}
	.top-nav {
		padding: 12px 20px;
	}
	.side-col {
		display: grid;
		grid-template-columns: 1fr 1fr;
		gap: 16px;
		position: static;
		align-self: auto;
	}
}

@media (max-width: 768px) {
	.top-nav {
		display: none;
	}
	.mobile-header {
		display: flex;
	}
	.detail-wrapper {
		padding: 16px 14px 32px 14px;
	}
	.detail-header {
		padding: 20px 18px;
		flex-direction: column;
		align-items: flex-start;
		gap: 16px;
	}
	.detail-header .icon-wrapper {
		width: 56px;
		height: 56px;
		font-size: 28px;
	}
	.detail-header .info .name {
		font-size: 22px;
	}
	.detail-header .info .desc {
		font-size: 14px;
	}
	.detail-header .actions {
		width: 100%;
	}
	.detail-header .actions .btn-primary,
	.detail-header .actions .btn-outline {
		flex: 1;
		text-align: center;
		padding: 10px 16px;
		font-size: 14px;
	}
	.content-detail {
		padding: 20px 18px;
	}
	.content-detail h2 {
		font-size: 18px;
	}
	.content-detail p,
	.content-detail ul li {
		font-size: 14px;
	}
	.side-col {
		grid-template-columns: 1fr;
		gap: 16px;
		position: static;
		align-self: auto;
	}
	.similar-grid {
		grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
		gap: 12px;
	}
	.similar-card {
		padding: 14px 14px 12px 14px;
	}
	.similar-card .card-head .name {
		font-size: 14px;
	}
	.similar-card .desc {
		font-size: 12px;
		-webkit-line-clamp: 2;
	}
	.similar-section .section-title h2 {
		font-size: 19px;
	}
	.breadcrumb {
		font-size: 12px;
		margin-bottom: 16px;
	}
	.post-nav {
		flex-direction: column;
	}
	.post-nav .nav-item {
		justify-content: flex-start !important;
		text-align: left !important;
	}
	.post-nav .nav-item .title {
		max-width: 180px;
	}
}

@media (max-width: 480px) {
	.detail-header .info .name {
		font-size: 19px;
	}
	.detail-header .info .name .tag {
		font-size: 10px;
		line-height: 22px;
		padding: 0 10px;
	}
	.detail-header .info .meta {
		font-size: 13px;
		gap: 10px 16px;
	}
	.similar-grid {
		grid-template-columns: 1fr 1fr;
		gap: 10px;
	}
	.similar-card .card-head .icon {
		width: 30px;
		height: 30px;
		font-size: 14px;
	}
	.similar-card .card-head .name {
		font-size: 13px;
	}
	.similar-card .desc {
		font-size: 11px;
		-webkit-line-clamp: 2;
	}
	.similar-card .footer .tag {
		font-size: 10px;
		line-height: 20px;
		padding: 0 8px;
	}
	.similar-card .footer .link {
		font-size: 11px;
	}
	.mobile-header .logo {
		font-size: 16px;
	}
	.mobile-header .logo i {
		font-size: 20px;
	}
	.content-detail {
		padding: 16px 14px;
	}
	.content-detail h2 {
		font-size: 17px;
	}
	.side-block {
		padding: 16px 16px;
	}
	.side-block .item-list a .info .name {
		font-size: 13px;
	}
}