/*
Theme Name: VinFast Child
Theme URI: https://vinfast.test
Description: Child theme for the VinFast WordPress implementation.
Author: VinFast Project
Version: 1.1.0
Template: wp_base
Text Domain: vezaconslt
*/

/* WordPress shell integration layered after the compiled design system. */
body.admin-bar #masthead {
	top: 2rem;
}

.page-template-elementor-full-width main {
	padding-bottom: 0;
}

.vinfast-content-area {
	min-height: 40vh;
}

/* Canonical news card shared by homepage sliders, archives and related posts. */
.vinfast-news-card {
	display: flex;
	height: 100%;
	flex-direction: column;
	overflow: hidden;
	border: 0.0625rem solid #e5e7eb;
	border-radius: 0.25rem;
	background: #fff;
	box-shadow: none;
	transition: border-color 0.3s ease, box-shadow 0.3s ease, transform 0.3s ease;
}

.vinfast-news-card__image {
	display: block;
	overflow: hidden;
	aspect-ratio: 338 / 190;
	background: #f6f8fb;
}

.vinfast-news-card__image img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 0.3s ease;
}

.vinfast-news-card__body {
	display: flex;
	min-height: 9.0625rem;
	flex: 1;
	flex-direction: column;
	padding: 0.9375rem;
}

.vinfast-news-card__meta {
	display: none;
}

.vinfast-news-card h2,
.vinfast-news-card h3 {
	margin: 0.125rem 0;
	font-size: 1.25rem;
	font-weight: 600;
	line-height: 1.25;
}

.vinfast-news-card h2 a,
.vinfast-news-card h3 a {
	color: inherit;
	text-decoration: none;
}

.vinfast-news-card p {
	flex: 1;
	margin: 0.125rem 0;
	color: #000;
	font-size: 1rem;
	font-weight: 400;
	line-height: 1.5;
}

.vinfast-news-card__more {
	min-height: 0;
	margin-top: 0.1875rem;
	padding: 0;
	color: #1464f4;
	font-size: 1rem;
	font-weight: 700;
	text-decoration: none;
	text-transform: uppercase;
}

.vinfast-news-card:hover,
.vinfast-news-card:focus-within {
	border-color: #1464f4;
	box-shadow: 0 0.625rem 1.5rem rgba(20, 100, 244, 0.18);
}

.vinfast-news-card:hover .vinfast-news-card__image img,
.vinfast-news-card:focus-within .vinfast-news-card__image img {
	transform: scale(1.04);
}

.vinfast-news-card:hover h2 a,
.vinfast-news-card:focus-within h2 a,
.vinfast-news-card:hover h3 a,
.vinfast-news-card:focus-within h3 a {
	color: #1464f4;
}

/* Canonical product-card interaction must stay identical outside Elementor layers. */
.vinfast-site .vinfast-home-product-card:hover,
.vinfast-site .vinfast-home-product-card:focus-within {
	border-color: #1464f4 !important;
	box-shadow: 0 0.625rem 1.5rem rgba(20, 100, 244, 0.18) !important;
}

#vinfast-primary-menu .sub-menu {
	pointer-events: none;
}

@media (min-width: 53.125rem) {
	#masthead nav[aria-label="Menu chính"] { margin-left: auto; }
	#masthead > div > .flex.items-center { margin-left: 0.625rem; }
}

#vinfast-primary-menu .menu-item-has-children:hover > .sub-menu,
#vinfast-primary-menu .menu-item-has-children:focus-within > .sub-menu {
	visibility: visible;
	opacity: 1;
	pointer-events: auto;
}

#vinfast-primary-menu .vinfast-menu-item-active > a,
#vinfast-primary-menu .vinfast-menu-item-active > a:hover,
#vinfast-primary-menu .vinfast-menu-item-active > a:focus-visible {
	position: relative;
	color: #1464f4;
}

#vinfast-primary-menu > .vinfast-menu-item-active > a::after {
	content: "";
	position: absolute;
	right: 0;
	bottom: 0.125rem;
	left: 0;
	height: 0.125rem;
	border-radius: 9999px;
	background: #1464f4;
}

#vinfast-primary-menu .sub-menu .vinfast-menu-item-active > a {
	background: #f2f2f2;
	color: #1464f4;
}

#vinfast-mobile-menu-list .vinfast-menu-item-active > a,
#vinfast-mobile-menu-list .vinfast-menu-item-active > a:hover,
#vinfast-mobile-menu-list .vinfast-menu-item-active > a:focus-visible {
	color: #1464f4;
	font-weight: 700;
}

#vinfast-mobile-menu-list .sub-menu .vinfast-menu-item-active > a {
	background: #fff;
}

#vinfast-mobile-menu-list .sub-menu {
	display: none;
}

#vinfast-mobile-menu-list .sub-menu.is-open {
	display: block;
}

#vinfast-mobile-menu-list .vinfast-mobile-submenu-toggle svg {
	transition: transform 0.2s ease;
}

#vinfast-mobile-menu-list .vinfast-mobile-submenu-toggle[aria-expanded="true"] svg {
	transform: rotate(180deg);
}

body.vinfast-scroll-locked {
	overscroll-behavior: none;
	touch-action: none;
}

body.vinfast-scroll-locked [data-overlay-scroll] {
	overscroll-behavior: contain;
	touch-action: pan-y;
}

#mobile-menu {
	pointer-events: none;
}

#mobile-menu.is-open {
	pointer-events: auto;
}

.vinfast-mobile-menu__backdrop {
	opacity: 0;
	transition: opacity 0.3s ease;
}

.vinfast-mobile-menu__panel {
	transform: translateX(-100%);
	transition: transform 0.3s ease;
	will-change: transform;
}

#mobile-menu.is-open .vinfast-mobile-menu__backdrop {
	opacity: 1;
}

#mobile-menu.is-open .vinfast-mobile-menu__panel {
	transform: translateX(0);
}

@media (prefers-reduced-motion: reduce) {
	.vinfast-mobile-menu__backdrop,
	.vinfast-mobile-menu__panel {
		transition: none;
	}
}

.vinfast-site .custom-logo-link {
	display: block;
}

.vinfast-shell-form .wpcf7-form p,
.vinfast-shell-form .wpcf7-response-output {
	margin: 0;
}

.vinfast-shell-form .wpcf7-spinner {
	margin: 0.5rem;
}

.vinfast-cf7 label {
	display: block;
	font-weight: 600;
}

.vinfast-cf7 input:not([type="submit"]),
.vinfast-cf7 select,
.vinfast-cf7 textarea {
	display: block;
	width: 100%;
	margin-top: 0.4375rem;
	background: #fff;
	color: #20242b;
}

.vinfast-cf7--popup {
	display: grid;
	gap: 1.125rem;
}

.vinfast-cf7--popup label {
	color: #20242b;
	font-size: 0.75rem;
	text-transform: uppercase;
}

.vinfast-cf7--popup input:not([type="submit"]),
.vinfast-cf7--popup select,
.vinfast-cf7--popup textarea {
	padding: 0.5625rem 0;
	border: 0;
	border-bottom: 0.0625rem solid #888;
	outline: none;
	font-family: inherit;
	font-size: 1rem;
	font-weight: 500;
	line-height: 1.5;
}

.vinfast-cf7--popup input::placeholder,
.vinfast-cf7--popup textarea::placeholder {
	color: #6b7280;
	font: inherit;
	opacity: 1;
}

.vinfast-cf7--popup textarea {
	min-height: 5.25rem;
	max-height: 11.25rem;
	resize: vertical;
}

.vinfast-cf7--popup input:focus,
.vinfast-cf7--popup select:focus,
.vinfast-cf7--popup textarea:focus {
	border-color: #1464f4;
}

.vinfast-cf7__submit {
	text-align: center;
}

.vinfast-cf7__submit input[type="submit"] {
	padding: 0.625rem 1.5rem;
	border: 0;
	border-radius: 62.4375rem;
	background: #1464f4;
	color: #fff;
	font-weight: 700;
	cursor: pointer;
}

.vinfast-shell-form--footer {
	max-width: 45rem;
	margin-bottom: 1.25rem;
}

.vinfast-cf7--footer {
	display: flex;
	flex-wrap: wrap;
}

.vinfast-cf7--footer label {
	min-width: 0;
	flex: 1;
}

.vinfast-cf7--footer input:not([type="submit"]) {
	height: 3.125rem;
	margin: 0;
	padding: 0 1rem;
	border: 0;
}

.vinfast-cf7--footer input[type="submit"] {
	height: 3.125rem;
	padding: 0 1.5rem;
	border: 0;
	border-radius: 0.25rem;
	background: #222;
	color: #fff;
	font-weight: 600;
	cursor: pointer;
}

.vinfast-cf7--footer input[type="submit"]:hover,
.vinfast-cf7--footer input[type="submit"]:focus-visible {
	background: #0d4fc8;
	color: #fff;
}

.vinfast-form-fallback {
	display: inline-flex;
	padding: 0.625rem 1.125rem;
	background: #1464f4;
	color: #fff;
	font-weight: 700;
}

.wpcf7 form .wpcf7-response-output {
	clear: both;
	padding: 0.625rem 0.75rem;
}

@media (prefers-reduced-motion: reduce) {
	html:focus-within {
		scroll-behavior: auto;
	}
}

@media screen and (max-width: 48.875rem) {
	body.admin-bar #masthead {
		top: 2.875rem;
	}
}

@media screen and (max-width: 37.5rem) {
	body.admin-bar #masthead {
		top: 0;
	}

	.vinfast-cf7--footer > p {
		position: relative;
	}

	.vinfast-cf7--footer .wpcf7-spinner {
		position: absolute;
		right: 0.75rem;
		bottom: 0.8125rem;
		margin: 0;
	}

	.vinfast-cf7--footer > p {
		display: flex;
		flex-wrap: nowrap;
		align-items: stretch;
	}

	.vinfast-cf7--footer > p > label {
		width: auto;
		min-width: 0;
		flex: 1 1 auto;
		flex-basis: auto;
	}

	.vinfast-cf7--footer > p > input[type="submit"] {
		width: auto;
		min-width: 7.5rem;
		flex: 0 0 auto;
		flex-basis: auto;
	}
}
