/**
 * Footer 新版（4栏布局）
 * 包含深色/浅色模式适配
 *
 * @package pcgamehome
 */

/* ===========================================================================
   Footer New - 基础变量与容器（浅色模式优先）
   ========================================================================*/
:root {
	/* 默认浅色模式变量 */
	--pcgh-footer-new-bg: #ffffff;
	--pcgh-footer-new-surface: #f8fafc;
	--pcgh-footer-new-border: #e2e8f0;
	--pcgh-footer-new-text: #1a1a1a;
	--pcgh-footer-new-text-2: #475569;
	--pcgh-footer-new-text-3: #1a1a1a;
	/* 使用后台主题强调色 */
	--pcgh-footer-new-primary: var(--pcgh-primary, #6366f1);
	--pcgh-footer-new-primary-hover: var(--pcgh-primary, #4f46e5);
	--pcgh-footer-new-primary-soft: color-mix(in srgb, var(--pcgh-footer-new-primary) 10%, transparent);
	--pcgh-footer-new-accent: #f59e0b;
	--pcgh-footer-new-shadow: 0 2px 12px color-mix(in srgb, var(--pcgh-footer-new-primary) 8%, transparent);
	--pcgh-footer-new-shadow-hover: 0 4px 16px color-mix(in srgb, var(--pcgh-footer-new-primary) 15%, transparent);
	--pcgh-footer-new-radius: 12px;
	--pcgh-footer-new-radius-sm: 8px;
}

/* ===========================================================================
   Footer New - 深色模式变量
   ========================================================================*/
html[data-pcgh-theme-resolved="dark"] {
	--pcgh-footer-new-bg: #0f172a;
	--pcgh-footer-new-surface: #1e293b;
	--pcgh-footer-new-border: #334155;
	--pcgh-footer-new-text: #f8fafc;
	--pcgh-footer-new-text-2: #cbd5e1;
	--pcgh-footer-new-text-3: #94a3b8;
	--pcgh-footer-new-primary: var(--pcgh-primary, #818cf8);
	--pcgh-footer-new-primary-hover: var(--pcgh-primary, #a5b4fc);
	--pcgh-footer-new-primary-soft: color-mix(in srgb, var(--pcgh-footer-new-primary) 15%, transparent);
	--pcgh-footer-new-accent: #fbbf24;
	--pcgh-footer-new-shadow: 0 2px 12px rgba(0, 0, 0, 0.3);
	--pcgh-footer-new-shadow-hover: 0 4px 16px rgba(0, 0, 0, 0.4);
}

/* ===========================================================================
   Footer New - 主容器
   ========================================================================*/
.pcgh-footer-new {
	margin-top: clamp(32px, 5vw, 72px);
	background: var(--pcgh-footer-new-bg);
	padding: clamp(32px, 4vw, 48px) 0 clamp(16px, 2vw, 24px);
}

/*.pcgh-footer-new .pcgh-container {*/
/*	max-width: 1200px;*/
/*	margin: 0 auto;*/
/*	padding: 0 clamp(16px, 3vw, 32px);*/
/*}*/

/* ===========================================================================
   Footer New - 4栏网格布局
   ========================================================================*/
.pcgh-footer-new__grid {
	display: grid;
	grid-template-columns: 1.2fr 1fr 1fr 0.8fr;
	gap: clamp(24px, 3vw, 48px);
	margin-bottom: clamp(24px, 3vw, 32px);
}

/* ===========================================================================
   Footer New - 第1栏：品牌信息
   ========================================================================*/
.pcgh-footer-new__brand {
	display: flex;
	flex-direction: column;
	gap: 14px;
}

/* Logo */
.pcgh-footer-new__logo {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	text-decoration: none;
	color: var(--pcgh-footer-new-text);
	transition: opacity 0.2s ease;
	flex-shrink: 0;
}

.pcgh-footer-new__logo:hover {
	opacity: 0.8;
	color: var(--pcgh-footer-new-text);
}

.pcgh-footer-new__logo img {
	height: 32px;
	width: auto;
	display: block;
}

.pcgh-footer-new__logo strong {
	font-size: 18px;
	font-weight: 700;
	letter-spacing: -0.02em;
}

.pcgh-footer-new__logo-icon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 32px;
	height: 32px;
	background: linear-gradient(135deg, var(--pcgh-footer-new-primary), #8b5cf6);
	border-radius: var(--pcgh-footer-new-radius-sm);
	color: #fff;
}

.pcgh-footer-new__logo-icon i,
.pcgh-footer-new__logo-icon svg {
	width: 18px;
	height: 18px;
}

/* 品牌描述 */
.pcgh-footer-new__desc {
	font-size: 13px;
	line-height: 1.7;
	color: var(--pcgh-footer-new-text-3);
	margin: 0;
	max-width: 260px;
}

/* 社交图标（无背景，仅图标） */
.pcgh-footer-new__social {
	display: flex;
	gap: 12px;
	flex-wrap: wrap;
}

.pcgh-footer-new__social a {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 40px;
	height: 40px;
	background: transparent;
	border: none;
	border-radius: 50%;
	color: var(--pcgh-footer-new-text-2);
	transition: all 0.2s ease;
}

.pcgh-footer-new__social a:hover {
	color: var(--pcgh-footer-new-primary);
	transform: scale(1.1);
}

.pcgh-footer-new__social a i,
.pcgh-footer-new__social a svg {
	width: 22px;
	height: 22px;
}

/* ===========================================================================
   Footer New - 第2栏：网站导航（两列三行）
   ========================================================================*/
.pcgh-footer-new__nav {
	display: flex;
	flex-direction: column;
	gap: 12px;
}

.pcgh-footer-new__title {
	font-size: 15px;
	font-weight: 600;
	color: var(--pcgh-footer-new-text);
	margin: 0;
	letter-spacing: -0.01em;
	padding-bottom: 8px;
	border-bottom: 1px solid var(--pcgh-footer-new-border);
}

.pcgh-footer-new__nav-grid {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 0 20px;
}

.pcgh-footer-new__nav-col {
	list-style: none;
	padding: 0;
	margin: 0;
	display: flex;
	flex-direction: column;
	gap: 10px;
}

.pcgh-footer-new__nav-col li {
	margin: 0;
}

.pcgh-footer-new__nav-col a {
	font-size: 13px;
	color: var(--pcgh-footer-new-text-3);
	text-decoration: none;
	transition: color 0.2s ease;
	display: inline-flex;
	align-items: center;
	gap: 6px;
}

.pcgh-footer-new__nav-col a::before {
	content: '';
	width: 4px;
	height: 4px;
	background: var(--pcgh-footer-new-primary);
	border-radius: 50%;
	opacity: 0;
	transform: scale(0);
	transition: all 0.2s ease;
}

.pcgh-footer-new__nav-col a:hover {
	color: var(--pcgh-footer-new-primary);
}

.pcgh-footer-new__nav-col a:hover::before {
	opacity: 1;
	transform: scale(1);
}

/* ===========================================================================
   Footer New - 第3栏：联系合作（横向一行布局：图标+合作+邮箱，完全还原图片样式）
   ========================================================================*/
.pcgh-footer-new__contact {
	display: flex;
	flex-direction: column;
	gap: 12px;
}

.pcgh-footer-new__contact-list {
	display: flex;
	flex-direction: column;
	gap: 10px;
}

.pcgh-footer-new__contact-item {
	display: flex;
	align-items: center;
	gap: 8px;
	padding: 6px 0;
}

.pcgh-footer-new__contact-icon {
	display: flex;
	align-items: center;
	justify-content: center;
	color: var(--pcgh-footer-new-text-3);
	flex-shrink: 0;
}

.pcgh-footer-new__contact-icon i,
.pcgh-footer-new__contact-icon svg {
	width: 16px;
	height: 16px;
}

.pcgh-footer-new__contact-label {
	font-size: 12px;
	color: var(--pcgh-footer-new-text-3);
	white-space: nowrap;
}

.pcgh-footer-new__contact-value {
	font-size: 12px;
	color: var(--pcgh-footer-new-text);
	font-weight: 500;
}

/* ===========================================================================
   Footer New - 第4栏：二维码（大卡片左图右字，完全还原图片样式）
   ========================================================================*/
.pcgh-footer-new__qr {
	display: flex;
	flex-direction: column;
	gap: 12px;
}

.pcgh-footer-new__qr-card {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 14px;
	background: var(--pcgh-footer-new-surface);
	border: 1px solid var(--pcgh-footer-new-border);
	border-radius: 10px;
	transition: all 0.2s ease;
}

.pcgh-footer-new__qr-card:hover {
	border-color: var(--pcgh-footer-new-primary);
	box-shadow: var(--pcgh-footer-new-shadow);
}

.pcgh-footer-new__qr-img {
	flex-shrink: 0;
	width: 90px;
	height: 90px;
	border-radius: 8px;
	overflow: hidden;
	background: var(--pcgh-footer-new-bg);
	display: flex;
	align-items: center;
	justify-content: center;
	border: 1px solid var(--pcgh-footer-new-border);
	padding: 6px;
	box-sizing: border-box;
}

.pcgh-footer-new__qr-img img {
	width: 100%;
	height: 100%;
	object-fit: contain;
}

.pcgh-footer-new__qr-placeholder {
	width: 100%;
	height: 100%;
	display: flex;
	align-items: center;
	justify-content: center;
	color: var(--pcgh-footer-new-text-3);
}

.pcgh-footer-new__qr-placeholder i,
.pcgh-footer-new__qr-placeholder svg {
	width: 36px;
	height: 36px;
}

.pcgh-footer-new__qr-info {
	flex: 1;
	min-width: 0;
	display: flex;
	flex-direction: column;
	justify-content: center;
	gap: 4px;
}

.pcgh-footer-new__qr-tip {
	font-size: 14px;
	font-weight: 600;
	color: var(--pcgh-footer-new-text);
	margin: 0;
	line-height: 1.4;
}

.pcgh-footer-new__qr-account {
	font-size: 12px;
	color: var(--pcgh-footer-new-text-2);
	margin: 0;
	line-height: 1.4;
}

.pcgh-footer-new__qr-tag {
	display: inline-block;
	padding: 3px 10px;
	font-size: 11px;
	font-weight: 500;
	color: var(--pcgh-footer-new-primary);
	background: var(--pcgh-footer-new-primary-soft);
	border-radius: 4px;
	margin-top: 2px;
	width: fit-content;
}

a.pcgh-footer-new__qr-tag {
	cursor: pointer;
	text-decoration: none;
	transition: opacity .15s;
}

a.pcgh-footer-new__qr-tag:hover {
	opacity: .8;
}

/* ===========================================================================
   Footer New - 底部信息（三列一行：版权 | 安全标语 | 备案）
   ========================================================================*/
.pcgh-footer-new__bottom {
	padding-top: 0;
}

.pcgh-footer-new__bottom-row {
	display: flex;
	align-items: center;
	justify-content: space-between;
	flex-wrap: wrap;
	gap: 8px 16px;
}

.pcgh-footer-new__copyright {
	font-size: 12px;
	color: var(--pcgh-footer-new-text);
	flex: 1;
	min-width: 0;
}

.pcgh-footer-new__security {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	font-size: 12px;
	color: var(--pcgh-footer-new-text);
	font-weight: 500;
	flex: 1;
	min-width: 0;
}

.pcgh-footer-new__security img {
	height: 18px;
	width: auto;
	display: inline-block;
	vertical-align: middle;
}

.pcgh-footer-new__icp {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	font-size: 12px;
	color: var(--pcgh-footer-new-text);
	flex: 1;
	min-width: 0;
	justify-content: flex-end;
}

.pcgh-footer-new__icp a {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	color: var(--pcgh-footer-new-text);
	text-decoration: none;
	transition: color 0.2s ease;
}

.pcgh-footer-new__icp a:hover {
	color: var(--pcgh-footer-new-primary);
}

.pcgh-footer-new__icp i,
.pcgh-footer-new__icp svg {
	width: 14px;
	height: 14px;
}

/* ===========================================================================
   Footer New - 响应式布局
   ========================================================================*/

/* 平板端（< 1024px）：保持4栏 */
@media (max-width: 1024px) {
	.pcgh-footer-new__grid {
		grid-template-columns: 1fr 1fr 1fr 1fr;
	}
}

/* 小平板（< 768px）：2栏布局 */
@media (max-width: 768px) {
	.pcgh-footer-new {
		padding: 32px 0 24px;
	}

	.pcgh-footer-new__grid {
		grid-template-columns: 1fr 1fr;
		gap: 24px;
		margin-bottom: 24px;
		padding-bottom: 24px;
	}

	.pcgh-footer-new__brand {
		grid-column: 1 / -1;
	}

	.pcgh-footer-new__nav {
		grid-column: 1 / -1;
	}

	.pcgh-footer-new__qr {
		grid-column: 1 / -1;
	}

	.pcgh-footer-new__qr-card {
		max-width: 400px;
		margin: 0 auto;
	}
}

/* 手机端（< 480px）：单列布局 */
@media (max-width: 480px) {
	.pcgh-footer-new {
		padding: 24px 0 16px;
	}

	.pcgh-footer-new .pcgh-container {
		padding: 0 16px;
	}

	.pcgh-footer-new__grid {
		grid-template-columns: 1fr;
		gap: 20px;
		margin-bottom: 16px;
	}

	.pcgh-footer-new__brand {
		align-items: center;
		text-align: center;
	}

	/* 移动端隐藏：网站导航、联系合作、二维码、底部信息 */
	.pcgh-footer-new__hide-mobile {
		display: none !important;
	}

	.pcgh-footer-new__desc {
		max-width: 100%;
		text-align: center;
	}

	.pcgh-footer-new__social {
		justify-content: center;
	}

	.pcgh-footer-new__nav {
		text-align: center;
	}

	.pcgh-footer-new__nav-grid {
		justify-content: center;
	}

	.pcgh-footer-new__contact {
		align-items: center;
	}

	.pcgh-footer-new__contact-cards {
		width: 100%;
		max-width: 320px;
		margin: 0 auto;
	}

	.pcgh-footer-new__contact-card {
		text-align: left;
	}

	.pcgh-footer-new__qr {
		align-items: center;
	}

	.pcgh-footer-new__qr-card {
		flex-direction: column;
		text-align: center;
		max-width: 100%;
	}

	.pcgh-footer-new__qr-img {
		width: 80px;
		height: 80px;
	}

	/* 底部一行：移动端垂直堆叠 */
	.pcgh-footer-new__bottom {
		padding-top: 0;
		gap: 6px;
	}

	.pcgh-footer-new__bottom-row {
		flex-direction: column;
		align-items: center;
		gap: 6px;
		text-align: center;
	}

	.pcgh-footer-new__copyright {
		order: 2;
		font-size: 11px;
		justify-content: center;
	}

	.pcgh-footer-new__security {
		order: 1;
		font-size: 12px;
		justify-content: center;
	}

	.pcgh-footer-new__icp {
		order: 3;
		font-size: 11px;
		justify-content: center;
		flex-wrap: wrap;
	}
}

/* ===========================================================================
   Footer New - 特殊页面适配
   ========================================================================*/
.pcgh-main:has(.pcgh-specials-page) + .pcgh-footer-new,
.pcgh-main:has(.pcgh-special-detail-page) + .pcgh-footer-new,
.pcgh-main:has(.pcgh-special-tax-page) + .pcgh-footer-new {
	margin-top: 24px;
}

/* ===========================================================================
   Footer New - 返回顶部按钮（新版页脚配套）
   ========================================================================*/
.pcgh-footer-new ~ .pcgh-back-to-top {
	bottom: calc(var(--pcgh-mobile-tabbar-height, 0px) + 16px);
}

@media (max-width: 768px) {
	.pcgh-footer-new ~ .pcgh-back-to-top {
		bottom: calc(var(--pcgh-mobile-tabbar-height, 60px) + 16px);
	}
}
