/**
 * Homepage baseline restore — system-main front page only.
 * Presentation layer: spacing, grids, equal heights, alignment.
 */

body.home {
	--vn-home-section-y: clamp(36px, 4vw, 52px);
	--vn-home-grid-gap: 20px;
}

/* ── Page shell — full width, centered sections ── */
body.home #main-content {
	width: 100%;
	margin-inline: auto;
	overflow-x: clip;
}

/* ── Unified container — uses global layout-container.css tokens ── */
body.home .vn-hero-content {
	max-width: var(--vn-container-max);
	margin-inline: auto;
	padding-inline: var(--vn-container-gutter);
	box-sizing: border-box;
}

/* ── Section rhythm — single source, no stacked padding ── */
body.home #main-content > .vn-section {
	padding-top: var(--vn-home-section-y) !important;
	padding-bottom: var(--vn-home-section-y) !important;
}

body.home #main-content > .vn-section.vn-categories {
	padding-block: var(--vn-home-section-y) !important;
}

body.home #main-content > #danh-muc {
	padding-top: clamp(28px, 3.5vw, 40px) !important;
}

body.home #hero.vn-hero {
	margin-bottom: 0 !important;
}

body.home #main-content .vn-section__header,
body.home #main-content .vn-clean-header {
	margin-top: 0 !important;
	margin-bottom: clamp(18px, 2.5vw, 28px) !important;
	text-align: center;
}

body.home #main-content .vn-section__eyebrow {
	color: #78bd43;
	font-size: 18px;
	font-weight: 700;
	letter-spacing: 0.22em;
	text-transform: uppercase;
	margin-bottom: 10px;
	display: inline-block;
}

body.home #main-content .vn-section__title {
	font-size: clamp(28px, 3.2vw, 40px);
	line-height: 1.15;
	margin: 0 0 12px;
	font-weight: bold;

}

body.home #main-content .vn-section__subtitle {
	font-size: 15px;
	line-height: 1.7;
	max-width: 620px;
	margin-inline: auto;
	color: #6b7280;
}

body.home .vn-meta-stats {
	justify-content: center !important;
	margin-top: 14px !important;
	margin-bottom: 0 !important;
	font-size: 13px !important;
}

/* ── Categories — row slider (Swiper), single line ── */
body.home #danh-muc .vn-home-row-slider {
	margin-top: 24px;
}

body.home #danh-muc .vn-cat-grid--home.swiper-wrapper {
	display: flex;
}

body.home #danh-muc .vn-cat-grid--home .vn-cat-card {
	flex: unset;
	min-width: 0;
	width: 100%;
	display: flex;
	flex-direction: column;
	align-items: center;
	padding: 28px 14px 24px;
	border-radius: 16px;
	border: 1px solid #ececec;
	box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
	overflow: hidden;
	text-decoration: none;
}

body.home #danh-muc .vn-cat-grid--home .vn-cat-card__thumb {
	width: 88px;
	height: 88px;
	margin-bottom: 14px;
	border-radius: 50%;
	overflow: hidden;
	flex-shrink: 0;
	background: #f5f5f5;
}

body.home #danh-muc .vn-cat-grid--home .vn-cat-card__thumb img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: center;
}

body.home #danh-muc .vn-cat-grid--home .vn-cat-card__name {
	font-size: 14px;
	font-weight: 600;
	line-height: 1.35;
	text-align: center;
}

body.home #danh-muc .vn-cat-grid--home .vn-cat-card__count {
	font-size: 12px;
	color: #888;
	text-align: center;
}

body.home #danh-muc .vn-cat-grid--empty {
	margin-top: 32px;
	text-align: center;
	color: #666;
	font-size: 15px;
}

/* ── Featured products — 3-col, equal-height cards ── */
body.home #san-pham-noi-bat .vn-filter-bar,
body.home .vn-featured-products .vn-filter-bar {
	justify-content: center;
	flex-wrap: wrap;
	gap: 10px;
	margin-bottom: 24px;
}

body.home #san-pham-noi-bat .vn-filter-btn,
body.home .vn-featured-products .vn-filter-btn {
	padding: 9px 22px;
	font-size: 13px;
	border-radius: 999px;
}

body.home #san-pham-noi-bat .vn-filter-btn.is-active,
body.home .vn-featured-products .vn-filter-btn.is-active {
	background: #23652d;
	border-color: #23652d;
	color: #fff;
}

body.home #san-pham-noi-bat .vn-product-grid,
body.home .vn-featured-products .vn-product-grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 24px 20px;
	align-items: stretch;
	width: 100%;
}

body.home #san-pham-noi-bat .vn-product-card,
body.home .vn-featured-products .vn-product-card {
	display: flex;
	flex-direction: column;
	height: 100%;
	border: 1px solid #ececec;
	border-radius: 12px;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
	background: #fff;
	overflow: hidden;
}

body.home #san-pham-noi-bat .vn-product-card__img-wrap,
body.home .vn-featured-products .vn-product-card__img-wrap {
	position: relative;
	border-radius: 0;
	aspect-ratio: 1 / 1;
	background: #fafafa;
}

body.home #san-pham-noi-bat .vn-product-card__badges,
body.home .vn-featured-products .vn-product-card__badges {
	position: absolute;
	top: 10px;
	left: 10px;
	display: flex;
	flex-direction: column;
	gap: 6px;
	z-index: 2;
}

body.home #san-pham-noi-bat .vn-badge,
body.home .vn-featured-products .vn-badge {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 34px;
	min-height: 34px;
	padding: 0 6px;
	border-radius: 50%;
	font-size: 10px;
	font-weight: 700;
	line-height: 1;
	text-transform: uppercase;
	color: #fff;
}

body.home #san-pham-noi-bat .vn-badge--sale,
body.home .vn-featured-products .vn-badge--sale {
	background: #e53935;
}

body.home #san-pham-noi-bat .vn-badge--new,
body.home .vn-featured-products .vn-badge--new {
	background: #245824;
}

body.home #san-pham-noi-bat .vn-badge--stock,
body.home .vn-featured-products .vn-badge--stock {
	background: #888;
}

body.home #san-pham-noi-bat .vn-product-card__body,
body.home .vn-featured-products .vn-product-card__body {
	display: flex;
	flex-direction: column;
	flex: 1;
	padding: 16px 16px 18px;
	gap: 0;
}

body.home #san-pham-noi-bat .vn-product-card__rating,
body.home .vn-featured-products .vn-product-card__rating,
body.home #san-pham-noi-bat .vn-product-rating-summary,
body.home .vn-featured-products .vn-product-rating-summary {
	margin-bottom: 8px;
}

body.home #san-pham-noi-bat .vn-product-card__title,
body.home .vn-featured-products .vn-product-card__title {
	font-size: 14px;
	line-height: 1.45;
	margin: 0 0 10px;
	min-height: 2.9em;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
	flex: 1;
}

body.home #san-pham-noi-bat .vn-product-card__price,
body.home .vn-featured-products .vn-product-card__price {
	display: flex;
	align-items: baseline;
	flex-wrap: nowrap;
	gap: 8px;
	margin-top: auto;
	padding-top: 4px;
}

body.home #san-pham-noi-bat .vn-price-sale,
body.home .vn-featured-products .vn-price-sale {
	font-size: 16px;
	font-weight: 700;
	color: #e53935;
	white-space: nowrap;
	line-height: 1.2;
}

body.home #san-pham-noi-bat .vn-price-regular,
body.home .vn-featured-products .vn-price-regular {
	font-size: 13px;
	font-weight: 400;
	color: #999;
	text-decoration: line-through;
	white-space: nowrap;
	line-height: 1.2;
}

body.home #san-pham-noi-bat .vn-price-off,
body.home .vn-featured-products .vn-price-off {
	font-size: 13px;
	font-weight: 400;
	color: #999;
	white-space: nowrap;
	line-height: 1.2;
}

body.home #san-pham-noi-bat .vn-price-only,
body.home .vn-featured-products .vn-price-only {
	font-size: 16px;
	font-weight: 700;
	color: #111;
	white-space: nowrap;
	line-height: 1.2;
}

body.home #san-pham-noi-bat .vn-price-contact,
body.home .vn-featured-products .vn-price-contact {
	font-size: 13px;
	color: #666;
	line-height: 1.2;
}

body.home #san-pham-noi-bat .vn-products__more,
body.home .vn-featured-products .vn-products__more {
	margin-top: 32px;
	text-align: center;
}

body.home #san-pham-noi-bat .vn-products__more .btn-outline,
body.home .vn-featured-products .vn-products__more .btn-outline,
body.home #tin-tuc .vn-section__cta-wrap .btn-outline {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	min-height: 46px;
	padding: 0 28px;
	font-size: 14px;
	font-weight: 600;
	border-radius: 8px;
}

/* Commitments directly after products — tight seam */
body.home #san-pham-noi-bat,
body.home .vn-featured-products {
	padding-bottom: var(--vn-home-section-y) !important;
}

/* Commitments — compact baseline cards (icon + title inline) */
body.home #cam-ket.vn-value-commitments {
	margin-top: 0;
	padding-block: clamp(26px, 3vw, 36px) !important;
}

body.home #cam-ket .vn-value-commitments__grid {
	gap: 14px;
}

body.home #cam-ket .vn-feature-item,
body.home #cam-ket .vn-value-card {
	padding: 14px 12px;
}

/* ── News — 4 equal-height cards ── */
body.home #tin-tuc .vn-blog-grid {
	display: grid !important;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 20px;
	align-items: stretch;
	width: 100%;
}

body.home #tin-tuc .vn-blog-card {
	display: flex;
	flex-direction: column;
	height: 100%;
	min-width: 0;
	border: 1px solid #ececec;
	border-radius: 12px;
	overflow: hidden;
	background: #fff;
	box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04);
}

body.home #tin-tuc .vn-blog-card__thumb-link {
	display: block;
	position: relative;
	width: 100%;
	aspect-ratio: 400 / 280;
	overflow: hidden;
	flex-shrink: 0;
	background: #f3f4f6;
}

body.home #tin-tuc .vn-blog-card__thumb-link img.vn-blog-card__thumb,
body.home #tin-tuc .vn-blog-card__thumb {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	max-width: none;
	object-fit: cover;
	object-position: center;
	display: block;
}

body.home #tin-tuc .vn-blog-card__thumb--placeholder {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	display: flex;
	align-items: center;
	justify-content: center;
	background: #f3f4f6;
}

body.home #tin-tuc .vn-blog-card__thumb--placeholder svg {
	width: 100%;
	height: 100%;
}

body.home #tin-tuc .vn-blog-card:hover .vn-blog-card__thumb {
	transform: scale(1.04);
	transition: transform 0.45s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

body.home #tin-tuc .vn-blog-card__body {
	display: flex;
	flex-direction: column;
	flex: 1;
	padding: 18px 18px 20px;
}

body.home #tin-tuc .vn-blog-card__cat {
	display: inline-block;
	font-size: 10px;
	font-weight: 700;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: #4d7c0f;
	background: rgba(132, 204, 22, 0.14);
	padding: 3px 10px;
	border-radius: 999px;
	margin-bottom: 8px !important;
}

body.home #tin-tuc .vn-blog-card__cat a {
	color: inherit;
	text-decoration: none;
}

body.home #tin-tuc .vn-blog-card__meta {
	margin-bottom: 0;
}

body.home #tin-tuc .vn-blog-card__meta--date {
	margin: 0 0 10px;
}

body.home #tin-tuc .vn-blog-card__title {
	font-size: 15px;
	line-height: 1.4;
	margin: 0 0 6px;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
	min-height: 2.8em;
	flex: 0 0 auto;
}

body.home #tin-tuc .vn-blog-card__date {
	font-size: 12px;
	color: #9ca3af;
}

body.home #tin-tuc .vn-blog-card__excerpt {
	font-size: 13px;
	line-height: 1.6;
	color: #6b7280;
	margin: 10px 0 0;
	flex: 1;
	display: -webkit-box;
	-webkit-line-clamp: 3;
	-webkit-box-orient: vertical;
	overflow: hidden;
	min-height: 4.8em;
}

body.home #tin-tuc .vn-blog-card__read-more {
	margin-top: auto;
	padding-top: 14px;
	font-size: 13px;
	font-weight: 600;
}

body.home #tin-tuc .vn-section__cta-wrap {
	margin-top: 32px;
	text-align: center;
}

/* ── Partner logos — same system as about page ── */
body.home .vn-brand-partners {
	padding-block: var(--vn-home-section-y) !important;
	background: #ffffff !important;
}

body.home .vn-brand-partners__header {
	margin-bottom: clamp(24px, 3vw, 36px) !important;
}

/* ── Lead form — compact, bright CTA row ── */
body.home #dang-ky.vn-newsletter {
	padding-block: clamp(26px, 3vw, 36px) !important;
}

body.home #dang-ky .vn-newsletter__inner {
	max-width: 920px;
	margin-inline: auto;
	gap: 8px;
}

body.home #dang-ky .vn-newsletter__title-row {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 12px;
}

body.home #dang-ky .vn-newsletter__icon {
	width: 44px !important;
	height: 44px !important;
	margin: 0 !important;
}

body.home #dang-ky .vn-newsletter__form.vn-lead-form {
	margin-top: 12px;
}

body.home #dang-ky .vn-lead-form__row {
	display: grid;
	grid-template-columns: 1fr 1fr 1fr minmax(130px, 160px);
	gap: 10px;
	max-width: 100%;
	margin-inline: auto;
	width: 100%;
}

body.home #dang-ky .vn-lead-form input[type="text"],
body.home #dang-ky .vn-lead-form input[type="tel"],
body.home #dang-ky .vn-lead-form input[type="email"] {
	min-height: 46px;
	height: 46px;
	border-radius: 8px;
	font-size: 14px;
}

body.home #dang-ky .vn-lead-form button,
body.home #dang-ky .vn-lead-form .vn-newsletter__btn {
	min-height: 46px;
	height: 46px;
	padding: 0 18px;
	font-size: 14px;
	font-weight: 700;
	border-radius: 8px;
	white-space: nowrap;
}

body.home #dang-ky .vn-newsletter__privacy {
	font-size: 12px;
	margin-top: 8px;
}

/* ── Footer ── */
body.home .vn-site-footer {
	padding-top: clamp(60px, 6vw, 84px);
}

body.home .vn-site-footer__grid {
	gap: clamp(24px, 3vw, 48px);
}

body.home .vn-site-footer li {
	margin-bottom: 12px;
	line-height: 1.6;
	font-size: 14px;
}

body.home .vn-site-footer__col h3 {
	margin-bottom: 18px;
	font-size: 15px;
}

body.home .vn-site-footer__bottom {
	padding-block: 18px;
	font-size: 13px;
}

/* ── Responsive ── */
@media (max-width: 1199px) {
	body.home #tin-tuc .vn-blog-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	body.home #san-pham-noi-bat .vn-product-grid , body.home .vn-featured-products .vn-product-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 22px 18px;
	}

	body.home #cam-ket .vn-value-commitments__grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

@media (max-width: 767px) {
	body.home #main-content > .vn-section {
		padding-top: 36px !important;
		padding-bottom: 36px !important;
	}

	body.home #main-content > #danh-muc {
		padding-top: 24px !important;
	}

	body.home #tin-tuc .vn-blog-grid {
		grid-template-columns: 1fr;
	}

	body.home #san-pham-noi-bat .vn-product-grid , body.home .vn-featured-products .vn-product-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 14px 10px;
	}

	body.home #cam-ket .vn-value-commitments__grid {
		grid-template-columns: 1fr;
	}

	body.home #dang-ky .vn-lead-form__row {
		grid-template-columns: 1fr;
		max-width: 400px;
	}
}

@media (max-width: 479px) {
	body.home #san-pham-noi-bat .vn-product-grid , body.home .vn-featured-products .vn-product-grid {
		grid-template-columns: 1fr;
	}
}
