/* Trang chủ mới (templates/home-page-modern.php) — không phụ thuộc WPBakery / CSS WooCommerce */

.edg-home {
	--edg-primary: var(--thim-body-primary-color, #ff8200);
	--edg-primary-hover: #e67500;
	--edg-navy: var(--thim-body-primary-second-color, #1e3155);
	--edg-ink: #202121;
	--edg-muted: #5f6673;
	--edg-line: #e6e8ee;
	--edg-soft: #f6f7fa;
	--edg-radius: 12px;
}

/* Typography riêng cho các phần của trang chủ (không áp lên thẻ sản phẩm) */
.edg-home > section:not(.edg-games),
.edg-games .edg-section__head,
.edg-games .edg-section__foot {
	color: var(--edg-ink);
	font-size: 16px;
	line-height: 1.6;
}

/* Reset chỉ cho phần tử của trang chủ; thẻ sản phẩm (.woocommerce) giữ nguyên style như /cua-hang/ */
.edg-home *,
.edg-home *::before,
.edg-home *::after {
	box-sizing: border-box;
}

.edg-home :is(h1, h2, h3, p, ul, dl, dd):not(.woocommerce, .woocommerce *) {
	margin: 0;
	padding: 0;
}

.edg-home ul:not(.woocommerce *) {
	list-style: none;
}

.edg-wrap {
	max-width: 1180px;
	margin: 0 auto;
	padding: 0 16px;
}

/* ---------- Buttons ---------- */
.edg-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	min-height: 44px;
	padding: 10px 22px;
	border: 2px solid transparent;
	border-radius: 999px;
	font-weight: 600;
	font-size: 15px;
	line-height: 1.2;
	text-decoration: none;
	transition: background-color .2s, border-color .2s, color .2s;
}

.edg-btn--lg {
	min-height: 52px;
	padding: 14px 30px;
	font-size: 16px;
}

.edg-btn--xl {
	min-width: 280px;
	min-height: 64px;
	padding: 18px 48px;
	font-size: 20px;
	font-weight: 700;
	box-shadow: 0 10px 30px rgba(255, 136, 0, .35);
}

.edg-home .edg-btn--primary {
	background: var(--edg-primary);
	color: #fff;
}

.edg-home .edg-btn--primary:hover,
.edg-home .edg-btn--primary:focus-visible {
	background: var(--edg-primary-hover);
	color: #fff;
}

.edg-home .edg-btn--ghost {
	border-color: rgba(255, 255, 255, .7);
	color: #fff;
}

.edg-home .edg-btn--ghost:hover,
.edg-home .edg-btn--ghost:focus-visible {
	background: rgba(255, 255, 255, .12);
	border-color: #fff;
	color: #fff;
}

.edg-home .edg-btn--outline {
	border-color: var(--edg-line);
	color: var(--edg-ink);
	background: #fff;
}

.edg-home .edg-btn--outline:hover,
.edg-home .edg-btn--outline:focus-visible {
	border-color: var(--edg-primary);
	color: var(--edg-primary);
}

.edg-home .edg-btn--dark {
	background: var(--edg-navy);
	color: #fff;
}

.edg-home .edg-btn--dark:hover,
.edg-home .edg-btn--dark:focus-visible {
	background: #16243f;
	color: #fff;
}

.edg-home .edg-link {
	color: var(--edg-muted);
	font-weight: 600;
	text-decoration: none;
}

.edg-home .edg-link:hover {
	color: var(--edg-primary);
}

.edg-home a:focus-visible {
	outline: 3px solid rgba(255, 130, 0, .45);
	outline-offset: 2px;
}

/* ---------- 1. Hero ---------- */
.edg-hero {
	position: relative;
	display: flex;
	align-items: center;
	min-height: min(88vh, 760px);
	padding: 140px 0 80px; /* chừa chỗ cho header overlay */
	background: linear-gradient(180deg, rgba(14, 24, 44, .78), rgba(14, 24, 44, .62)), var(--edg-hero-bg) center / cover no-repeat, var(--edg-navy);
	color: #fff;
	text-align: center;
}

.edg-hero__inner {
	max-width: 820px;
}

.edg-home .edg-hero__title {
	color: #fff;
	font-size: clamp(30px, 5vw, 52px);
	font-weight: 700;
	line-height: 1.15;
	letter-spacing: -.01em;
}

.edg-hero__lead {
	max-width: 640px;
	margin: 20px auto 0 !important;
	color: rgba(255, 255, 255, .88);
	font-size: clamp(16px, 2vw, 19px);
}

.edg-hero__actions {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 12px;
	margin-top: 36px;
}

.edg-hero__note {
	margin-top: 16px !important;
	color: rgba(255, 255, 255, .72);
	font-size: 14px;
}

.edg-hero__note a {
	color: #fff;
	font-weight: 600;
	text-decoration: underline;
}

/* ---------- 2. Values ---------- */
.edg-values {
	border-bottom: 1px solid var(--edg-line);
	background: #fff;
}

.edg-values__grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 32px;
	padding-top: 48px;
	padding-bottom: 48px;
}

.edg-value__icon {
	width: 28px;
	height: 28px;
	margin-bottom: 12px;
	fill: none;
	stroke: var(--edg-primary);
	stroke-width: 2;
	stroke-linecap: round;
	stroke-linejoin: round;
}

.edg-home .edg-value__title {
	margin-bottom: 6px;
	color: var(--edg-ink);
	font-size: 18px;
	font-weight: 700;
	line-height: 1.3;
}

.edg-value p {
	color: var(--edg-muted);
	font-size: 15px;
}

/* ---------- Section chung ---------- */
.edg-section {
	padding: 80px 0;
}

.edg-section__head {
	max-width: 640px;
	margin: 0 auto 40px;
	text-align: center;
}

.edg-home .edg-section__title {
	color: var(--edg-ink);
	font-size: clamp(26px, 3.4vw, 36px);
	font-weight: 700;
	line-height: 1.2;
}

.edg-section__lead {
	margin-top: 12px !important;
	color: var(--edg-muted);
	font-size: 17px;
}

.edg-section__foot {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: center;
	gap: 16px 28px;
	margin-top: 40px;
}

/* ---------- 3. Games: thẻ sản phẩm dùng chung style /cua-hang/ ---------- */
/* Theme cha ép 3 cột ≤880px cho body.woocommerce-shop; áp dụng tương tự ở đây */
@media (max-width: 880px) {
	.edg-games ul.product-grid li.product {
		flex: 0 0 33.33% !important;
		max-width: 33.33% !important;
	}
}

/* ---------- 4. AI ---------- */
.edg-ai {
	background: var(--edg-soft);
}

.edg-ai__grid {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 56px;
	align-items: center;
}

.edg-ai__points {
	margin: 24px 0 32px !important;
}

.edg-ai__points li {
	position: relative;
	padding-left: 28px;
	color: var(--edg-ink);
}

.edg-ai__points li + li {
	margin-top: 10px;
}

.edg-ai__points li::before {
	content: "";
	position: absolute;
	top: .5em;
	left: 4px;
	width: 12px;
	height: 7px;
	border-bottom: 2px solid var(--edg-primary);
	border-left: 2px solid var(--edg-primary);
	transform: rotate(-45deg);
}

.edg-ai__list {
	border: 1px solid var(--edg-line);
	border-radius: var(--edg-radius);
	background: #fff;
}

.edg-ai__list li + li {
	border-top: 1px solid var(--edg-line);
}

.edg-home .edg-ai__item {
	display: flex;
	align-items: center;
	gap: 16px;
	padding: 14px 18px;
	color: var(--edg-ink);
	text-decoration: none;
}

.edg-ai__item img {
	flex: none;
	width: 56px;
	height: 56px;
	border-radius: 8px;
	object-fit: cover;
}

.edg-ai__name {
	flex: 1;
	font-weight: 600;
	line-height: 1.35;
}

.edg-ai__arrow {
	color: var(--edg-muted);
	transition: transform .2s, color .2s;
}

.edg-home .edg-ai__item:hover .edg-ai__name,
.edg-home .edg-ai__item:hover .edg-ai__arrow {
	color: var(--edg-primary);
}

.edg-ai__item:hover .edg-ai__arrow {
	transform: translateX(3px);
}

/* ---------- 5+6. Số liệu + CTA cuối ---------- */
.edg-final {
	padding: 80px 0;
	background: var(--edg-navy);
	color: #fff;
	text-align: center;
}

.edg-stats {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 16px 64px;
	margin-bottom: 48px !important;
	padding-bottom: 40px;
	border-bottom: 1px solid rgba(255, 255, 255, .14);
}

.edg-stats dt {
	color: #fff;
	font-size: clamp(28px, 4vw, 40px);
	font-weight: 700;
	line-height: 1.1;
}

.edg-stats dd {
	margin-top: 4px;
	color: rgba(255, 255, 255, .72);
	font-size: 15px;
}

.edg-home .edg-final__title {
	color: #fff;
	font-size: clamp(26px, 3.4vw, 36px);
	font-weight: 700;
	line-height: 1.2;
}

.edg-final__lead {
	margin: 12px auto 32px !important;
	color: rgba(255, 255, 255, .8);
	font-size: 17px;
}

/* ---------- Responsive ---------- */
@media (max-width: 991px) {
	.edg-ai__grid {
		grid-template-columns: 1fr;
		gap: 40px;
	}
}

@media (max-width: 767px) {
	.edg-hero {
		min-height: 0;
		padding: 120px 0 64px;
	}

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

	.edg-values__grid {
		grid-template-columns: 1fr;
		gap: 24px;
		padding-top: 40px;
		padding-bottom: 40px;
	}

	.edg-section,
	.edg-final {
		padding: 56px 0;
	}

	.edg-section__head {
		margin-bottom: 28px;
	}

	.edg-stats {
		gap: 20px 32px;
	}
}

@media (prefers-reduced-motion: reduce) {
	.edg-ai__arrow,
	.edg-btn {
		transition: none;
	}
}
