/* ==========================================================================
   V课程 · 默认模板皮肤（Premium）
   --------------------------------------------------------------------------
   设计语言：
   - 深海军蓝 → 靛蓝渐变，金色点缀，冷色底 + 暖色高光
   - 玻璃质感卡片、超大字号、克制的动效
   - 纯手写、无框架、无图片背景（只有少量 SVG banner），整包 < 20KB
   只做「观感层」覆盖：结构、交互、无障碍都在主题 css/style.css 里。
   ========================================================================== */

.vk-body,
body {
	--tpl-ink: #0d1226;
	--tpl-muted: #5b6478;
	--tpl-line: rgba(13, 18, 38, 0.08);
	--tpl-navy: #0a0f22;
	--tpl-indigo: #3b5bfd;
	--tpl-violet: #7c4dff;
	--tpl-gold: #f5b544;
	--tpl-teal: #0f766e;
	--tpl-radius: 20px;
	--tpl-shadow-sm: 0 2px 10px rgba(13, 18, 38, 0.05);
	--tpl-shadow-md: 0 14px 40px rgba(13, 18, 38, 0.1);
	--tpl-shadow-lg: 0 30px 80px rgba(10, 15, 34, 0.22);
	--tpl-grad-hero: linear-gradient(135deg, #0a0f22 0%, #16225a 45%, #2b3ad6 100%);
	--tpl-grad-gold: linear-gradient(135deg, #f5b544 0%, #ffd88a 100%);
	--tpl-grad-text: linear-gradient(100deg, #ffffff 0%, #c9d4ff 55%, #f5b544 100%);
	--tpl-font-display: "PingFang SC", "Microsoft YaHei", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

/* --------------------------------------------------------------------------
   1. 首页 Hero
   -------------------------------------------------------------------------- */

.hero {
	position: relative;
	isolation: isolate;
	overflow: hidden;
	overflow-x: clip;
	background: var(--tpl-grad-hero);
	background-size: cover;
	background-position: center;
	background-repeat: no-repeat;
	color: #fff;
	min-height: clamp(460px, 62vh, 640px);
	display: flex;
	align-items: center;
	padding: clamp(56px, 8vw, 104px) 0;
}

.hero::before {
	content: "";
	position: absolute;
	inset: 0 0 auto 0;
	height: 78%;
	background:
		radial-gradient(42% 60% at 78% 22%, rgba(245, 181, 68, 0.42) 0%, rgba(245, 181, 68, 0) 62%),
		radial-gradient(38% 55% at 22% 8%, rgba(124, 77, 255, 0.42) 0%, rgba(124, 77, 255, 0) 60%);
	filter: blur(6px);
	z-index: -1;
}

.hero::after {
	content: "";
	position: absolute;
	inset: 0;
	background-image:
		linear-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px),
		linear-gradient(90deg, rgba(255, 255, 255, 0.05) 1px, transparent 1px);
	background-size: 56px 56px;
	mask-image: radial-gradient(70% 70% at 50% 40%, #000 0%, transparent 78%);
	opacity: 0.7;
	z-index: -1;
	pointer-events: none;
}

.hero__bg {
	position: absolute;
	inset: 0;
	z-index: -2;
	opacity: 0.9;
}

.hero__bg img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	transform: scale(1.04);
}

.hero__overlay {
	display: none;
}

.hero__inner {
	position: relative;
	display: grid;
	gap: clamp(32px, 5vw, 64px);
	align-items: center;
	width: 100%;
}

.hero--center .hero__inner {
	grid-template-columns: minmax(0, 1fr);
	justify-items: center;
	text-align: center;
}

.hero__eyebrow,
.hero .hero__eyebrow {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 7px 16px;
	border-radius: 999px;
	background: rgba(255, 255, 255, 0.12);
	border: 1px solid rgba(255, 255, 255, 0.26);
	backdrop-filter: blur(10px);
	font-size: 12px;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: #fff;
	margin-bottom: 18px;
}

.hero__title {
	font-family: var(--tpl-font-display);
	font-size: clamp(34px, 5.2vw, 62px);
	line-height: 1.1;
	letter-spacing: -0.02em;
	font-weight: 800;
	margin: 0 0 18px;
	background: var(--tpl-grad-text);
	-webkit-background-clip: text;
	background-clip: text;
	color: transparent;
	text-wrap: balance;
}

.hero__sub {
	font-size: clamp(15px, 1.5vw, 19px);
	line-height: 1.75;
	color: rgba(255, 255, 255, 0.78);
	max-width: 40em;
	margin: 0 0 30px;
}

.hero__actions {
	display: flex;
	flex-wrap: wrap;
	gap: 12px;
	align-items: center;
}

.hero .btn,
.hero .btn-primary,
.hero .btn-ghost {
	padding: 14px 28px;
	border-radius: 999px;
	font-size: 15px;
	font-weight: 700;
	border: 1px solid transparent;
	transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.hero .btn-primary {
	background: #fff;
	color: var(--tpl-navy);
	box-shadow: 0 14px 34px rgba(255, 255, 255, 0.18);
}

.hero .btn-primary:hover {
	transform: translateY(-2px);
	box-shadow: 0 20px 44px rgba(255, 255, 255, 0.26);
}

.hero .btn:not(.btn-primary) {
	background: rgba(255, 255, 255, 0.1);
	color: #fff;
	border-color: rgba(255, 255, 255, 0.3);
	backdrop-filter: blur(8px);
}

.hero .btn:not(.btn-primary):hover {
	background: rgba(255, 255, 255, 0.18);
	transform: translateY(-2px);
}

/* --------------------------------------------------------------------------
   2. 区块节奏与标题
   -------------------------------------------------------------------------- */

.section {
	padding: clamp(52px, 7vw, 92px) 0;
}

.section.section--gray {
	background: linear-gradient(180deg, #f7f9ff 0%, #ffffff 100%);
}

.sec-title {
	font-family: var(--tpl-font-display);
	font-size: clamp(24px, 3vw, 36px);
	line-height: 1.25;
	letter-spacing: -0.01em;
	font-weight: 800;
	color: var(--tpl-ink);
	margin: 0 0 10px;
}

.sec-sub {
	font-size: 15px;
	color: var(--tpl-muted);
	margin: 0 0 28px;
	max-width: 46em;
}

.section--dark {
	background: var(--tpl-grad-hero);
	color: #fff;
}

.section--dark .sec-title {
	background: var(--tpl-grad-text);
	-webkit-background-clip: text;
	background-clip: text;
	color: transparent;
}

.section--dark .sec-sub {
	color: rgba(255, 255, 255, 0.72);
}

/* --------------------------------------------------------------------------
   3. 卡片：课程 / 游戏 / 资源
   -------------------------------------------------------------------------- */

.course-card,
.game-card,
.resource-card {
	position: relative;
	background: #fff;
	border: 1px solid var(--tpl-line);
	border-radius: var(--tpl-radius);
	box-shadow: var(--tpl-shadow-sm);
	overflow: hidden;
	transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}

.course-card:hover,
.game-card:hover,
.resource-card:hover {
	transform: translateY(-6px);
	box-shadow: var(--tpl-shadow-md);
	border-color: rgba(59, 91, 253, 0.28);
}

.course-card__thumb,
.game-card__thumb,
.resource-card__thumb,
.course-card img {
	transition: transform 0.45s cubic-bezier(0.22, 0.61, 0.36, 1);
}

.course-card:hover .course-card__thumb img,
.game-card:hover .game-card__thumb img,
.resource-card:hover .resource-card__thumb img,
.course-card:hover img {
	transform: scale(1.06);
}

.course-card__title,
.game-card__title,
.resource-card__title {
	font-size: 16px;
	font-weight: 700;
	color: var(--tpl-ink);
	line-height: 1.45;
}

.course-card__price,
.game-card__price {
	color: #b45309;
	font-weight: 800;
}

.course-card__badge,
.vk-badge {
	border-radius: 999px;
}

/* --------------------------------------------------------------------------
   4. 数据条 / 特性 / 流程 / CTA
   -------------------------------------------------------------------------- */

.section.stats-band {
	position: relative;
	background: var(--tpl-grad-hero);
	color: #fff;
	padding: clamp(40px, 6vw, 64px) 0;
}

.stats-band__grid {
	display: grid;
	gap: 16px;
	grid-template-columns: repeat(var(--vk-cols, 4), minmax(0, 1fr));
}

.stats-band__item {
	background: rgba(255, 255, 255, 0.1);
	border: 1px solid rgba(255, 255, 255, 0.18);
	backdrop-filter: blur(10px);
	border-radius: 18px;
	padding: 22px 20px;
	text-align: center;
}

.stats-band__value {
	display: block;
	color: #fff !important;
	-webkit-text-fill-color: #fff;
	background: none;
	font-family: var(--tpl-font-display);
	font-size: clamp(28px, 3.2vw, 40px);
	font-weight: 800;
	line-height: 1.15;
	margin-bottom: 4px;
}

.stats-band__label {
	display: block;
	color: rgba(255, 255, 255, 0.72);
	font-size: 13px;
	letter-spacing: 0.02em;
}

.feature-card {
	background: #fff;
	border: 1px solid var(--tpl-line);
	border-radius: 20px;
	padding: 28px 24px;
	box-shadow: var(--tpl-shadow-sm);
	transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.feature-card:hover {
	transform: translateY(-5px);
	box-shadow: var(--tpl-shadow-md);
	border-color: rgba(59, 91, 253, 0.24);
}

.feature-card__icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 48px;
	height: 48px;
	border-radius: 15px;
	background: linear-gradient(135deg, rgba(59, 91, 253, 0.14), rgba(124, 77, 255, 0.16));
	color: var(--tpl-indigo);
	font-size: 21px;
	margin-bottom: 16px;
}

.feature-card__title {
	font-size: 17px;
	font-weight: 700;
	color: var(--tpl-ink);
	margin: 0 0 8px;
}

.process__list {
	list-style: none;
	margin: 0;
	padding: 0;
	display: grid;
	gap: 18px;
	grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
	counter-reset: step;
}

.process__item {
	position: relative;
	background: #fff;
	border: 1px solid var(--tpl-line);
	border-radius: 18px;
	padding: 24px 22px 22px;
	box-shadow: var(--tpl-shadow-sm);
}

.process__no {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 38px;
	height: 38px;
	border-radius: 50%;
	background: var(--tpl-grad-gold);
	color: #3a2500;
	font-weight: 800;
	margin-bottom: 12px;
}

.process__title {
	font-size: 16px;
	font-weight: 700;
	color: var(--tpl-ink);
	margin: 0 0 6px;
}

.section.cta {
	position: relative;
	overflow: hidden;
	background: var(--tpl-grad-hero);
	color: #fff;
	border-radius: 24px;
	padding: clamp(40px, 6vw, 72px);
	margin: clamp(40px, 6vw, 72px) auto;
	max-width: var(--theme-container-width, 1200px);
}

.section.cta::after {
	content: "";
	position: absolute;
	inset: auto -10% -40% auto;
	width: 460px;
	height: 460px;
	border-radius: 50%;
	background: radial-gradient(circle, rgba(245, 181, 68, 0.42) 0%, rgba(245, 181, 68, 0) 70%);
}

.section.cta .sec-title {
	position: relative;
	color: #fff;
	background: none;
	-webkit-text-fill-color: #fff;
	font-size: clamp(26px, 3.4vw, 40px);
}

.section.cta .sec-sub {
	position: relative;
	color: rgba(255, 255, 255, 0.78);
}

.section.cta .btn,
.section.cta .btn-primary {
	position: relative;
	background: #fff;
	color: var(--tpl-navy);
	border-radius: 999px;
	padding: 13px 26px;
	font-weight: 700;
}

/* --------------------------------------------------------------------------
   5. 内页头图（课程 / 游戏 / 积分 / 工作台…）
   -------------------------------------------------------------------------- */

.page-hero {
	position: relative;
	isolation: isolate;
	overflow: hidden;
	overflow-x: clip;
	min-height: clamp(220px, 26vw, 320px);
	display: flex;
	align-items: center;
	padding: clamp(40px, 6vw, 72px) 0;
	color: #fff;
	background: var(--tpl-grad-hero);
	background-size: cover;
	background-position: center right;
	background-repeat: no-repeat;
}

.page-hero::before {
	content: "";
	position: absolute;
	inset: 0;
	z-index: -1;
	background: linear-gradient(100deg, rgba(6,10,24,0.82) 0%, rgba(6,10,24,0.62) 42%, rgba(6,10,24,0.12) 78%);
}

.page-hero::after {
	content: "";
	position: absolute;
	inset: 0;
	z-index: -1;
	background:
		radial-gradient(40% 60% at 85% 15%, rgba(245, 181, 68, 0.34), transparent 65%),
		radial-gradient(36% 60% at 12% 85%, rgba(124, 77, 255, 0.34), transparent 62%);
}

.page-hero.page-hero--image {
	/* 插画铺满整块，主体落在垂直居中带，裁切不伤画面 */
	background-size: cover;
	background-position: center right;
}

@media (max-width: 900px) {
	.page-hero.page-hero--image {
		background-size: cover;
		background-position: 78% center;
	}
}

.page-hero__bg,
.page-hero__image,
.page-hero img.page-hero__img {
	position: absolute;
	inset: 0;
	z-index: -2;
	width: 100%;
	height: 100%;
	object-fit: cover;
	opacity: 0.45;
}

.page-hero__title,
.page-hero h1 {
	font-family: var(--tpl-font-display);
	font-size: clamp(26px, 3.6vw, 44px);
	font-weight: 800;
	line-height: 1.2;
	margin: 0 0 10px;
	color: #fff;
}

.page-hero__sub,
.page-hero p {
	color: rgba(255, 255, 255, 0.78);
	font-size: 15px;
	max-width: 46em;
	margin: 0;
}

/* --------------------------------------------------------------------------
   6. 组件微调：按钮 / 分页 / 空状态 / 表单
   -------------------------------------------------------------------------- */

.btn,
.btn-primary,
button[type="submit"].btn {
	border-radius: 999px;
	font-weight: 600;
	transition: transform 0.16s ease, box-shadow 0.16s ease, background 0.16s ease;
}

.btn-primary {
	background: linear-gradient(135deg, var(--tpl-indigo), var(--tpl-violet));
	border-color: transparent;
	box-shadow: 0 10px 26px rgba(59, 91, 253, 0.28);
}

.btn-primary:hover {
	transform: translateY(-2px);
	box-shadow: 0 16px 34px rgba(59, 91, 253, 0.34);
}

.pagination a,
.page-numbers {
	border-radius: 12px;
}

.vk-block-placeholder,
.vk-empty {
	border: 1px dashed var(--tpl-line);
	border-radius: 16px;
	padding: 28px;
	color: var(--tpl-muted);
	background: #fafbff;
}

/* 模板附加组件（供自制模板复用） */
.vk-tpl-hero {
	position: relative;
	border-radius: 24px;
	overflow: hidden;
	background: var(--tpl-grad-hero);
	color: #fff;
	padding: clamp(32px, 5vw, 64px);
}

.vk-tpl-badge {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 6px 14px;
	border-radius: 999px;
	background: rgba(255, 255, 255, 0.14);
	border: 1px solid rgba(255, 255, 255, 0.24);
	font-size: 12px;
	letter-spacing: 0.06em;
	text-transform: uppercase;
}

.vk-tpl-stat {
	display: flex;
	flex-direction: column;
	gap: 4px;
	padding: 20px 22px;
	border-radius: 18px;
	background: #fff;
	border: 1px solid var(--tpl-line);
	box-shadow: var(--tpl-shadow-sm);
}

.vk-tpl-stat b {
	font-size: 28px;
	line-height: 1.15;
	background: linear-gradient(135deg, var(--tpl-indigo), var(--tpl-violet));
	-webkit-background-clip: text;
	background-clip: text;
	color: transparent;
}

.vk-tpl-stat span {
	font-size: 12px;
	color: var(--tpl-muted);
}

.vk-tpl-section {
	margin: clamp(40px, 6vw, 72px) 0;
}

/* --------------------------------------------------------------------------
   7. 动效与降级
   -------------------------------------------------------------------------- */

@keyframes tpl-float {
	0%, 100% { transform: translate3d(0, 0, 0); }
	50%      { transform: translate3d(0, -12px, 0); }
}

.hero__blob {
	animation: tpl-float 9s ease-in-out infinite;
	will-change: transform;
}

.hero__blob--2 {
	animation-delay: -4.5s;
}

@media (prefers-reduced-motion: reduce) {
	.hero__blob,
	.course-card,
	.game-card,
	.resource-card,
	.btn-primary {
		animation: none;
		transition: none;
	}

	.course-card:hover,
	.game-card:hover,
	.resource-card:hover,
	.btn-primary:hover {
		transform: none;
	}
}

/* --------------------------------------------------------------------------
   8. 响应式
   -------------------------------------------------------------------------- */

@media (max-width: 1024px) {
	.hero::after {
		background-size: 44px 44px;
	}
}

@media (max-width: 900px) {
	.vk-body,
	body {
		overflow-x: hidden;
	}

	/* style.css 里对移动端已有 !important 的列数规则，这里用更高特异性覆盖，
	   保证手机上是干净的两列、不横向溢出。 */
	.section.stats-band .stats-band__grid {
		grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
		gap: 10px !important;
	}

	.section.stats-band .stats-band__item {
		padding: 14px 12px;
	}

	.section.stats-band .stats-band__value {
		font-size: 26px;
	}

	.hero {
		min-height: auto;
		padding: 56px 0 64px;
	}

	.hero__title {
		font-size: clamp(30px, 8vw, 40px);
	}

	.hero__actions .btn {
		flex: 1 1 100%;
		justify-content: center;
	}

	.section {
		padding: 48px 0;
	}

	.section.cta {
		border-radius: 18px;
		margin: 32px 14px;
	}

	.page-hero {
		min-height: 200px;
	}
}

/* --------------------------------------------------------------------------
   9. 防溢出兜底（模板层，避免任何区块把页面撑出横向滚动）
   -------------------------------------------------------------------------- */

.hero,
.hero__inner,
.hero__content,
.hero__actions,
.section,
.section > .container,
.stats-band__grid,
.stats-band__item,
.cta,
.cta__inner {
	max-width: 100%;
	min-width: 0;
	box-sizing: border-box;
}

.hero .btn,
.hero .btn-primary,
.section.cta .btn {
	max-width: 100%;
	white-space: normal;
	text-align: center;
}

.hero__title,
.page-hero__title,
.sec-title {
	overflow-wrap: break-word;
}

@media (max-width: 900px) {
	.hero__actions {
		width: 100%;
	}

	.hero__actions .btn {
		flex: 1 1 100%;
	}
}
