/*!
 * tecnico app.css — 由 tools/build-css.py 生成，请勿直接编辑
 * 源文件：assets/css/src/*.css（按顺序合并）
 * 注意：不使用 @layer —— 未分层样式（父主题 Blocksy）会压过分层样式，
 *       这里用普通层叠顺序（后文件覆盖前文件）即可。
 */


/* ===== home (40-home.css) ===== */
/* ==========================================================================
   tecnico 标杆首页模板（front-page.php 专用）
   作用域：.tk-home；与主题其它页面样式隔离
   ========================================================================== */

.tk-home,
.tk-home *,
.tk-home *::before,
.tk-home *::after {
	box-sizing: border-box;
}

.tk-home {
	max-width: 1180px;
	width: 100%;
	margin: 0 auto;
	padding: 28px 24px 72px;
	color: #334155;
}

/* ---------- Hero ---------- */
.tk-home__hero {
	position: relative;
	overflow: hidden;
	padding: 56px 56px 44px;
	margin-bottom: 26px;
	border-radius: 26px;
	border: 1px solid rgba(15, 23, 42, 0.08);
	background: linear-gradient(160deg, #ffffff 0%, #eef3ff 56%, #f7f2ff 100%);
	box-shadow: 0 40px 90px -60px rgba(37, 99, 235, 0.55);
}

.tk-home__hero-glow {
	position: absolute;
	inset: -40% -10% 20%;
	background:
		radial-gradient(420px 260px at 18% 26%, rgba(37, 99, 235, 0.16), transparent 70%),
		radial-gradient(360px 240px at 88% 8%, rgba(8, 145, 178, 0.14), transparent 70%),
		radial-gradient(320px 200px at 70% 90%, rgba(124, 58, 237, 0.12), transparent 70%);
	pointer-events: none;
}

.tk-home__hero > *:not(.tk-home__hero-glow) {
	position: relative;
}

.tk-home__eyebrow {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	margin: 0 0 14px;
	font-size: 12px;
	font-weight: 700;
	letter-spacing: 0.18em;
	text-transform: uppercase;
	color: #2563eb;
}

.tk-home__eyebrow::before {
	content: "";
	width: 8px;
	height: 8px;
	border-radius: 50%;
	background: linear-gradient(120deg, #2563eb, #0891b2);
	box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12);
}

.tk-home__title {
	margin: 0 0 14px;
	font-size: clamp(32px, 3.8vw, 52px);
	line-height: 1.06;
	letter-spacing: -0.035em;
	font-weight: 800;
	color: #0f172a;
}

.tk-home__title em {
	font-style: normal;
	background: linear-gradient(120deg, #2563eb, #7c3aed 55%, #0891b2);
	-webkit-background-clip: text;
	background-clip: text;
	-webkit-text-fill-color: transparent;
}

.tk-home__sub {
	max-width: 540px;
	margin: 0;
	font-size: 16px;
	line-height: 1.7;
	color: #5a6b85;
}

.tk-home__search {
	width: 100%;
	max-width: 560px;
	display: flex;
	align-items: center;
	gap: 8px;
	max-width: 560px;
	margin-top: 26px;
	padding: 8px 8px 8px 18px;
	border-radius: 16px;
	background: rgba(255, 255, 255, 0.92);
	border: 1px solid rgba(15, 23, 42, 0.1);
	box-shadow: 0 22px 50px -34px rgba(37, 99, 235, 0.6);
}

.tk-home__search input {
	flex: 1;
	min-width: 0;
	padding: 8px 0;
	border: 0;
	background: transparent;
	outline: none;
	font-size: 15px;
	color: #0f172a;
}

.tk-home__search input::placeholder {
	color: #8593a8;
}

.tk-home__search button {
	padding: 11px 22px;
	border: 0;
	border-radius: 12px;
	font-size: 14px;
	font-weight: 600;
	color: #ffffff;
	cursor: pointer;
	background: linear-gradient(120deg, #2563eb 0%, #7c3aed 55%, #0891b2 100%);
	box-shadow: 0 14px 30px -16px rgba(37, 99, 235, 0.9);
	transition: filter 0.15s ease, transform 0.15s ease;
}

.tk-home__search button:hover {
	filter: brightness(1.06);
	transform: translateY(-1px);
}

.tk-home__stats {
	display: flex;
	gap: 40px;
	margin-top: 30px;
}

.tk-home__stats strong {
	display: block;
	font-size: 24px;
	font-weight: 800;
	letter-spacing: -0.02em;
	color: #0f172a;
	font-variant-numeric: tabular-nums;
}

.tk-home__stats span {
	font-size: 12px;
	color: #5a6b85;
}

/* ---------- 分类胶囊 ---------- */
.tk-home__cats {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-bottom: 30px;
}

.tk-home__cat {
	display: inline-flex;
	align-items: center;
	padding: 7px 15px;
	border-radius: 999px;
	border: 1px solid rgba(15, 23, 42, 0.1);
	background: rgba(255, 255, 255, 0.72);
	font-size: 13px;
	color: #5a6b85;
	text-decoration: none;
	transition: all 0.15s ease;
}

.tk-home__cat:hover {
	color: #0f172a;
	border-color: rgba(37, 99, 235, 0.45);
	background: #ffffff;
	transform: translateY(-1px);
}

.tk-home__cat.is-active {
	color: #ffffff;
	border-color: transparent;
	background: linear-gradient(120deg, #2563eb, #0891b2);
	box-shadow: 0 10px 24px -14px rgba(37, 99, 235, 0.8);
}

/* ---------- 精选：1 大 2 小 ---------- */
.tk-home__featured {
	display: grid;
	grid-template-columns: minmax(0, 1.35fr) minmax(0, 0.65fr);
	gap: 22px;
	margin-bottom: 44px;
}

.tk-home__lead {
	position: relative;
	background: linear-gradient(135deg, #2563eb, #7c3aed);
	display: flex;
	align-items: flex-end;
	min-height: 440px;
	border-radius: 22px;
	overflow: hidden;
	background: #0b1220 center/cover no-repeat;
	box-shadow: 0 30px 70px -40px rgba(15, 23, 42, 0.65);
}

.tk-home__lead::after {
	content: "";
	position: absolute;
	inset: 0;
	background: linear-gradient(180deg, rgba(8, 12, 24, 0.05) 0%, rgba(8, 12, 24, 0.72) 62%, rgba(8, 12, 24, 0.95) 100%);
}

.tk-home__lead-body {
	position: relative;
	z-index: 2;
	padding: 30px 34px 32px;
}

.tk-home__badge {
	display: inline-flex;
	align-self: flex-start;
	align-items: center;
	padding: 5px 12px;
	margin-bottom: 12px;
	border-radius: 999px;
	font-size: 11.5px;
	font-weight: 700;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: #ffffff;
	text-decoration: none;
	background: rgba(37, 99, 235, 0.85);
	backdrop-filter: blur(6px);
}

.tk-home__badge--sm {
	padding: 3px 9px;
	margin-bottom: 8px;
	font-size: 10.5px;
	color: #2563eb;
	background: rgba(37, 99, 235, 0.1);
}

.tk-home__lead-title {
	margin: 0 0 10px;
	font-size: clamp(22px, 2.4vw, 32px);
	line-height: 1.28;
	font-weight: 800;
	letter-spacing: -0.02em;
}

.tk-home__lead-title a {
	color: #ffffff;
	text-decoration: none;
}

.tk-home__lead-title a:hover {
	text-decoration: underline;
	text-underline-offset: 4px;
}

.tk-home__lead-excerpt {
	margin: 0 0 14px;
	max-width: 560px;
	font-size: 14.5px;
	line-height: 1.7;
	color: rgba(255, 255, 255, 0.82);
}

.tk-home__meta {
	display: flex;
	align-items: center;
	gap: 8px;
	font-size: 12.5px;
	color: #64748b;
}

.tk-home__lead .tk-home__meta,
.tk-home__lead .tk-home__meta time {
	color: rgba(255, 255, 255, 0.72);
}

.tk-home__side {
	display: grid;
	gap: 16px;
	grid-auto-rows: auto;
	align-content: start;
}

.tk-home__mini {
	align-content: center;
}

.tk-home__mini {
	display: grid;
	grid-template-columns: 104px minmax(0, 1fr);
	align-items: center;
	gap: 14px;
	padding: 12px;
	border-radius: 18px;
	background: rgba(255, 255, 255, 0.78);
	border: 1px solid rgba(15, 23, 42, 0.08);
	transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.tk-home__mini:hover {
	transform: translateY(-3px);
	background: #ffffff;
	box-shadow: 0 24px 50px -34px rgba(15, 23, 42, 0.45);
}

.tk-home__mini.no-thumb {
	grid-template-columns: minmax(0, 1fr);
}

.tk-home__mini-thumb {
	display: block;
	width: 104px;
	height: 104px;
	aspect-ratio: 1 / 1;
	overflow: hidden;
	border-radius: 12px;
	background: #eef2f9;
	align-self: center;
}

.tk-home__mini-thumb img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.tk-home__mini-title {
	margin: 0 0 8px;
	font-size: 15px;
	line-height: 1.45;
	font-weight: 700;
}

.tk-home__mini-title a {
	color: #0f172a;
	text-decoration: none;
}

.tk-home__mini-title a:hover {
	color: #2563eb;
}

/* ---------- 最新文章 ---------- */
.tk-home__section-head {
	display: flex;
	align-items: center;
	gap: 16px;
	margin-bottom: 20px;
}

.tk-home__section-head h2 {
	margin: 0;
	font-size: 20px;
	font-weight: 800;
	letter-spacing: -0.02em;
	color: #0f172a;
	white-space: nowrap;
}

.tk-home__section-line {
	flex: 1;
	height: 1px;
	background: linear-gradient(90deg, rgba(15, 23, 42, 0.12), transparent);
}

.tk-home__grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 22px;
}

.tk-home__card {
	display: flex;
	flex-direction: column;
	background: rgba(255, 255, 255, 0.8);
	border: 1px solid rgba(15, 23, 42, 0.08);
	border-radius: 18px;
	overflow: hidden;
	transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.tk-home__card:hover {
	transform: translateY(-4px);
	border-color: rgba(37, 99, 235, 0.3);
	box-shadow: 0 30px 60px -40px rgba(37, 99, 235, 0.55);
}

.tk-home__card-thumb {
	display: block;
	aspect-ratio: 16 / 10;
	overflow: hidden;
	background: linear-gradient(135deg, #e8eeff, #f3e9ff);
}

.tk-home__card-thumb img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 0.5s cubic-bezier(0.2, 0.7, 0.2, 1);
}

.tk-home__card:hover .tk-home__card-thumb img {
	transform: scale(1.05);
}

.tk-home__card-body {
	display: flex;
	flex-direction: column;
	flex: 1;
	padding: 18px 20px 20px;
}

.tk-home__card-title {
	margin: 0 0 8px;
	font-size: 17px;
	line-height: 1.45;
	font-weight: 700;
}

.tk-home__card-title a {
	color: #0f172a;
	text-decoration: none;
}

.tk-home__card-title a:hover {
	color: #2563eb;
}

.tk-home__card-excerpt {
	margin: 0 0 14px;
	font-size: 13.5px;
	line-height: 1.65;
	color: #5a6b85;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.tk-home__card .tk-home__meta {
	margin-top: auto;
}

/* ---------- 分页 ---------- */
.tk-home__pager {
	display: flex;
	justify-content: space-between;
	gap: 12px;
	margin-top: 34px;
}

.tk-home__pager a,
.tk-home__pager span {
	padding: 10px 18px;
	border-radius: 12px;
	border: 1px solid rgba(15, 23, 42, 0.1);
	background: #ffffff;
	font-size: 13.5px;
	color: #334155;
	text-decoration: none;
}

.tk-home__pager a:hover {
	border-color: rgba(37, 99, 235, 0.45);
	color: #2563eb;
}

.tk-home__pager .is-disabled {
	opacity: 0.45;
}

.tk-home__empty {
	color: #5a6b85;
}

/* ---------- 响应式 ---------- */
@media (max-width: 1024px) {
	.tk-home__featured {
		grid-template-columns: 1fr;
	}

	.tk-home__lead {
		min-height: 380px;
	}

	.tk-home__side {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.tk-home__grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

@media (max-width: 767px) {
	.tk-home {
		width: auto !important;
		max-width: 100% !important;
		overflow-x: hidden;
		padding: 16px 16px 56px;
	}

	.tk-home__hero {
		padding: 26px 18px 24px;
		border-radius: 20px;
	}

	.tk-home__title {
		font-size: 28px;
	}

	.tk-home__search {
		padding: 6px 6px 6px 14px;
	}

	.tk-home__search input {
		font-size: 14px;
	}

	.tk-home__search button {
		padding: 9px 14px;
		font-size: 13px;
	}

	.tk-home__stats {
		gap: 24px;
	}

	.tk-home__cats {
		flex-wrap: nowrap;
		overflow-x: auto;
		padding-bottom: 4px;
		-webkit-overflow-scrolling: touch;
	}

	.tk-home__cat {
		white-space: nowrap;
	}

	.tk-home__lead {
		min-height: 340px;
	}

	.tk-home__lead-body {
		padding: 22px;
	}

	.tk-home__side {
		grid-template-columns: 1fr;
	}

	.tk-home__grid {
		grid-template-columns: 1fr;
		gap: 18px;
	}
}

/* ---------- 移动端：强制内容不超出容器 ---------- */
@media (max-width: 767px) {
	.tk-home {
		width: 100% !important;
		max-width: 100% !important;
		min-width: 0 !important;
		overflow-x: hidden;
	}

	.tk-home__hero,
	.tk-home__cats,
	.tk-home__featured,
	.tk-home__side,
	.tk-home__section,
	.tk-home__grid {
		width: 100% !important;
		max-width: 100% !important;
		min-width: 0 !important;
	}

	.tk-home__title,
	.tk-home__sub,
	.tk-home__lead-title,
	.tk-home__lead-excerpt,
	.tk-home__card-title,
	.tk-home__card-excerpt {
		max-width: 100%;
		overflow-wrap: anywhere;
		word-break: break-word;
	}

	.tk-home__search {
		width: 100% !important;
		max-width: 100% !important;
	}

	.tk-home__search input {
		min-width: 0 !important;
		flex: 1 1 auto !important;
	}

	.tk-home__search button {
		flex: 0 0 auto;
	}

	.tk-home__cats {
		overflow-x: auto;
		-webkit-overflow-scrolling: touch;
	}
}
