/* ============================================================
   Vua Mắm — Components dùng chung mọi trang
   ============================================================ */

/* ---------- Buttons ---------- */
.vm-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	height: 46px;
	padding: 0 24px;
	border-radius: var(--vm-r-btn);
	font-weight: 600;
	font-size: 14px;
	line-height: 1;
	transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease, transform 0.15s ease, box-shadow 0.2s ease;
	white-space: nowrap;
}

.vm-btn--primary { background: var(--vm-red); color: #fff; }
.vm-btn--primary:hover { background: var(--vm-red-hover); }

.vm-btn--outline { background: #fff; color: var(--vm-red); border: 1.5px solid var(--vm-red); }
.vm-btn--outline:hover { background: var(--vm-cream); }

.vm-btn--soft { background: var(--vm-cream); color: var(--vm-ink); border: 1px solid var(--vm-line-2); }
.vm-btn--soft:hover { background: var(--vm-line); }

.vm-btn--sm { height: 38px; padding: 0 16px; font-size: 13px; border-radius: 10px; }
.vm-btn--lg { height: 52px; padding: 0 30px; font-size: 15px; }
.vm-btn--block { width: 100%; }

.vm-btn:disabled { opacity: 0.55; }

/* ---------- Placeholder ảnh (hũ mắm trên nền kem) ---------- */
.vm-ph {
	display: flex;
	align-items: center;
	justify-content: center;
	background: var(--vm-cream);
	color: var(--vm-gold);
	width: 100%;
	height: 100%;
	min-height: 120px;
}

.vm-ph--fill { position: absolute; inset: 0; min-height: 0; }

/* ---------- Sao đánh giá (partial fill) ---------- */
.vm-stars {
	position: relative;
	display: inline-flex;
	line-height: 0;
	vertical-align: middle;
}

.vm-stars__bg, .vm-stars__fill { display: inline-flex; gap: 2px; }
.vm-stars__bg svg { fill: #e7d9bf; }
.vm-stars__fill {
	position: absolute;
	inset: 0;
	overflow: hidden;
	white-space: nowrap;
}
.vm-stars__fill svg { fill: var(--vm-gold-2); flex: 0 0 auto; }

/* ---------- Toast (custom — thay thông báo mặc định) ---------- */
.vm-toast {
	position: fixed;
	left: 50%;
	bottom: 28px;
	transform: translate(-50%, 16px);
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 10px;
	background: var(--vm-ink);
	color: #fff;
	font-size: 14px;
	font-weight: 600;
	line-height: 1.4;
	padding: 13px 20px;
	border-radius: 14px;
	box-shadow: var(--vm-shadow-lg);
	opacity: 0;
	pointer-events: none;
	transition: opacity 0.25s ease, transform 0.25s ease;
	z-index: 9999;
	width: max-content;
	max-width: min(88vw, 420px);
	text-align: center;
}

.vm-toast.is-show { opacity: 1; transform: translate(-50%, 0); }
.vm-toast--success { background: var(--vm-green); }
.vm-toast--error { background: var(--vm-error); }

/* Icon tròn (✓ thành công / ! lỗi) — data-URI SVG, tránh hook chặn innerHTML */
.vm-toast--success::before,
.vm-toast--error::before {
	content: '';
	flex: none;
	width: 20px;
	height: 20px;
	background: center / contain no-repeat;
}
.vm-toast--success::before {
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E");
}
.vm-toast--error::before {
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='9'/%3E%3Cpath d='M12 7.5v5.5M12 16h.01'/%3E%3C/svg%3E");
}

/* ---------- Form fields (label trên, focus đỏ) ---------- */
.vm-field { display: flex; flex-direction: column; gap: 7px; }

.vm-field__label {
	font-size: 13px;
	font-weight: 600;
	color: var(--vm-ink-2);
}

.vm-field__label .req { color: var(--vm-red); }

.vm-input, .vm-textarea {
	width: 100%;
	min-width: 0;
	height: 48px;
	padding: 0 15px;
	border: 1px solid var(--vm-line-2);
	border-radius: var(--vm-r-input);
	background: #fff;
	font-size: 14px;
	color: var(--vm-ink);
	outline: none;
	transition: border-color 0.2s ease, box-shadow 0.2s ease;
	appearance: none;
}

.vm-textarea { height: auto; min-height: 110px; padding: 12px 15px; resize: vertical; line-height: 1.55; }

.vm-input::placeholder, .vm-textarea::placeholder { color: var(--vm-ink-5); }

.vm-input:focus, .vm-textarea:focus {
	border-color: var(--vm-red);
	box-shadow: 0 0 0 3px rgba(138, 30, 27, 0.09);
}

/* Inline error — YÊU CẦU CỨNG: không dùng bubble mặc định trình duyệt */
.vm-input.is-invalid, .vm-textarea.is-invalid, .vm-select.is-invalid .vm-select__btn {
	border-color: var(--vm-error);
	background: var(--vm-error-bg);
}

.vm-field__error {
	display: none;
	font-size: 12.5px;
	font-weight: 500;
	color: var(--vm-error);
	line-height: 1.4;
	align-items: flex-start;
	gap: 5px;
}

.vm-field__error::before {
	content: '';
	flex: 0 0 14px;
	width: 14px;
	height: 14px;
	margin-top: 1px;
	background: currentColor;
	-webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.4' stroke-linecap='round'%3E%3Ccircle cx='12' cy='12' r='9.5'/%3E%3Cpath d='M12 7.5v5.2'/%3E%3Ccircle cx='12' cy='16.4' r='.4' fill='black'/%3E%3C/svg%3E") center/contain no-repeat;
	mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.4' stroke-linecap='round'%3E%3Ccircle cx='12' cy='12' r='9.5'/%3E%3Cpath d='M12 7.5v5.2'/%3E%3Ccircle cx='12' cy='16.4' r='.4' fill='black'/%3E%3C/svg%3E") center/contain no-repeat;
}

.vm-field.has-error .vm-field__error,
.form-row.has-error .vm-field__error { display: flex; margin-top: 7px; }

/* ---------- Custom select (YÊU CẦU CỨNG: không dùng select native) ---------- */
.vm-select { position: relative; min-width: 0; }

.vm-select select {
	position: absolute !important;
	width: 1px; height: 1px;
	margin: -1px; padding: 0;
	overflow: hidden;
	clip: rect(0 0 0 0);
	border: 0;
}

.vm-select__btn {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 10px;
	width: 100%;
	height: 48px;
	padding: 0 15px;
	border: 1px solid var(--vm-line-2);
	border-radius: var(--vm-r-input);
	background: #fff;
	font-size: 14px;
	color: var(--vm-ink);
	text-align: left;
	transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.vm-select__btn .vm-select__value { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.vm-select__btn.is-placeholder .vm-select__value { color: var(--vm-ink-5); }

.vm-select__btn::after {
	content: '';
	flex: 0 0 11px;
	width: 11px;
	height: 11px;
	background: var(--vm-ink-3);
	-webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m5 9 7 7 7-7'/%3E%3C/svg%3E") center/contain no-repeat;
	mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m5 9 7 7 7-7'/%3E%3C/svg%3E") center/contain no-repeat;
	transition: transform 0.2s ease;
}

.vm-select.is-open .vm-select__btn { border-color: var(--vm-red); box-shadow: 0 0 0 3px rgba(138, 30, 27, 0.09); }
.vm-select.is-open .vm-select__btn::after { transform: rotate(180deg); }

.vm-select__panel {
	position: absolute;
	top: calc(100% + 6px);
	left: 0;
	right: 0;
	background: #fff;
	border: 1px solid var(--vm-line-2);
	border-radius: 13px;
	box-shadow: var(--vm-shadow-lg);
	padding: 6px;
	max-height: 264px;
	overflow: auto;
	z-index: 60;
	display: none;
}

.vm-select.is-open .vm-select__panel { display: block; }
.vm-select.drop-up .vm-select__panel { top: auto; bottom: calc(100% + 6px); }

.vm-select__opt {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 8px;
	width: 100%;
	padding: 10px 12px;
	border-radius: 9px;
	font-size: 14px;
	color: var(--vm-ink);
	text-align: left;
	transition: background 0.15s ease;
}

.vm-select__opt:hover, .vm-select__opt.is-focus { background: var(--vm-cream); }

.vm-select__opt.is-selected {
	background: var(--vm-red);
	color: #fff;
	font-weight: 600;
}

.vm-select__opt.is-selected::after {
	content: '';
	flex: 0 0 13px;
	width: 13px;
	height: 13px;
	background: #fff;
	-webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='3.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E") center/contain no-repeat;
	mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='3.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E") center/contain no-repeat;
}

.vm-select__search {
	position: sticky;
	top: 0;
	background: #fff;
	padding: 2px 2px 8px;
}

.vm-select__search .vm-input { height: 40px; border-radius: 9px; font-size: 13.5px; }

.vm-select__empty { padding: 12px; font-size: 13px; color: var(--vm-ink-4); text-align: center; }

/* ---------- Checkbox / Radio custom ---------- */
.vm-check {
	display: inline-flex;
	align-items: center;
	gap: 9px;
	cursor: pointer;
	font-size: 13.5px;
	color: var(--vm-ink-2);
	user-select: none;
}

.vm-check input {
	position: absolute;
	opacity: 0;
	width: 1px;
	height: 1px;
}

.vm-check__box {
	flex: 0 0 19px;
	width: 19px;
	height: 19px;
	border: 1.5px solid var(--vm-line-2);
	border-radius: 6px;
	background: #fff;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	transition: background 0.15s ease, border-color 0.15s ease;
}

.vm-check__box::after {
	content: '';
	width: 11px;
	height: 11px;
	background: #fff;
	-webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='3.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E") center/contain no-repeat;
	mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='3.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E") center/contain no-repeat;
	transform: scale(0);
	transition: transform 0.15s ease;
}

.vm-check input:checked + .vm-check__box { background: var(--vm-red); border-color: var(--vm-red); }
.vm-check input:checked + .vm-check__box::after { transform: scale(1); }
.vm-check input:focus-visible + .vm-check__box { box-shadow: 0 0 0 3px rgba(138, 30, 27, 0.15); }

/* ---------- Section heading dùng chung ---------- */
.vm-sec-head { text-align: center; margin-bottom: 34px; }

.vm-sec-head__script {
	font-family: var(--vm-font-script);
	font-size: 24px;
	color: var(--vm-orange);
	display: block;
	margin-bottom: 4px;
}

.vm-sec-head__title {
	font-family: var(--vm-font-head);
	font-size: 34px;
	font-weight: 800;
	color: var(--vm-ink);
}

.vm-sec-head__desc {
	max-width: 560px;
	margin: 12px auto 0;
	color: var(--vm-ink-3);
	font-size: 14.5px;
}

/* ---------- Badge nhãn đỏ trên card (label-shape.png) ---------- */
.vm-tier {
	position: absolute;
	top: 12px;
	left: -6px;
	z-index: 2;
	min-width: 86px;
	height: 30px;
	padding: 0 14px 2px 10px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	background: url('../images/label-shape.png') left center / 100% 100% no-repeat;
	color: #fff;
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 0.4px;
}

/* ---------- Hero strip đầu trang (breadcrumb + H1) — dùng chung mọi trang ---------- */
.vm-pagehero {
	background: linear-gradient(180deg, #f3e7d0, #fbf6ec);
	border-bottom: 1px solid var(--vm-line);
}

.vm-pagehero > .vm-container { padding-top: 34px; padding-bottom: 30px; }

.vm-pagehero .vm-crumb { margin-bottom: 10px; }

.vm-pagehero h1 {
	font-family: var(--vm-font-head);
	font-weight: 800;
	font-size: 38px;
	color: var(--vm-ink);
	letter-spacing: 0.4px;
}

.vm-pagehero p { font-size: 15px; color: var(--vm-ink-3); margin-top: 8px; }

@media (max-width: 640px) {
	.vm-pagehero h1 { font-size: 30px; }
}

/* ---------- Breadcrumb ---------- */
.vm-crumb {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 8px;
	font-size: 13px;
	color: var(--vm-ink-4);
}

.vm-crumb a { color: var(--vm-ink-3); transition: color 0.15s ease; }
.vm-crumb a:hover { color: var(--vm-red); }
.vm-crumb .sep { color: var(--vm-ink-5); }
.vm-crumb .cur { color: var(--vm-red); font-weight: 600; }

/* Field WC gắn class vm-hidden (country, last_name...) — ẩn ở MỌI trang */
.form-row.vm-hidden { display: none !important; }

/* ---------- Notice WC được style lại (fallback khi còn render) ---------- */
.woocommerce-notices-wrapper:empty { display: none; }

.woocommerce-message, .woocommerce-info, .woocommerce-error {
	list-style: none;
	margin: 0 0 18px;
	padding: 13px 17px;
	border-radius: 12px;
	font-size: 14px;
	border: 1px solid var(--vm-line-2);
	background: var(--vm-cream);
	color: var(--vm-ink-2);
}

.woocommerce-error { border-color: #efc4bd; background: var(--vm-error-bg); color: var(--vm-error); }
.woocommerce-message { border-color: #cfe3cd; background: var(--vm-green-bg); color: var(--vm-green); }
/* Bỏ vòng outline vàng khi WC tự focus vào notice (là alert, không cần ring) */
.woocommerce-error:focus, .woocommerce-message:focus, .woocommerce-info:focus { outline: none; }

/* Icon cho notice — trông "custom" hơn thay vì hộp WC trơn (data-URI, tránh hook chặn SVG) */
.woocommerce-error li,
.woocommerce-message,
.woocommerce-info { display: flex; align-items: flex-start; gap: 10px; line-height: 1.5; }
.woocommerce-error li::before,
.woocommerce-message::before,
.woocommerce-info::before {
	content: '';
	flex: none;
	width: 20px;
	height: 20px;
	margin-top: 1px;
	background: center / contain no-repeat;
}
.woocommerce-error li::before {
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23c0392b' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='9'/%3E%3Cpath d='M12 7.5v5.5M12 16h.01'/%3E%3C/svg%3E");
}
.woocommerce-message::before {
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%233f7d3b' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='9'/%3E%3Cpath d='M8.5 12.5l2.5 2.5 4.5-5'/%3E%3C/svg%3E");
}
.woocommerce-info::before {
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%235a4a3f' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='9'/%3E%3Cpath d='M12 11v5M12 8h.01'/%3E%3C/svg%3E");
}

/* ---------- Pagination ---------- */
.vm-paging { display: flex; justify-content: center; gap: 8px; margin-top: 38px; }

.vm-paging .page-numbers {
	min-width: 42px;
	height: 42px;
	padding: 0 10px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	border-radius: 11px;
	border: 1px solid var(--vm-line-2);
	background: #fff;
	font-size: 14px;
	font-weight: 600;
	color: var(--vm-ink-2);
	transition: all 0.15s ease;
}

.vm-paging .page-numbers:hover { border-color: var(--vm-red); color: var(--vm-red); }
.vm-paging .page-numbers.current { background: var(--vm-red); border-color: var(--vm-red); color: #fff; }
.vm-paging .page-numbers.dots { border: 0; background: none; }

/* ============================================================
   Promo bar
   ============================================================ */
.vm-promobar { background: var(--vm-promo); color: #f2d6c6; overflow: hidden; }

.vm-promobar__track {
	display: flex;
	justify-content: center;
	height: 44px;
	font-size: 13px;
	font-weight: 500;
}

.vm-promobar__group {
	display: flex;
	align-items: center;
	gap: 30px;
	flex: none;
}

/* Desktop: chỉ 1 nhóm tĩnh căn giữa — ẩn nhóm nhân đôi + dấu • thừa ở cuối */
.vm-promobar__group[aria-hidden] { display: none; }
.vm-promobar__group > .vm-promobar__sep:last-child { display: none; }

.vm-promobar__item { display: flex; align-items: center; gap: 8px; white-space: nowrap; }
.vm-promobar__sep { opacity: 0.4; }

/* Mobile: chạy marquee sang trái — nhân đôi nhóm để loop liền mạch (translateX -50%) */
@media (max-width: 640px) {
	.vm-promobar__track {
		justify-content: flex-start;
		width: max-content;
		animation: vm-promo-marquee 18s linear infinite;
	}
	.vm-promobar__group[aria-hidden] { display: flex; }
	.vm-promobar__group { padding-right: 30px; }
	.vm-promobar__group > .vm-promobar__sep:last-child { display: flex; }
	.vm-promobar:active .vm-promobar__track { animation-play-state: paused; }
}

@keyframes vm-promo-marquee {
	from { transform: translateX(0); }
	to { transform: translateX(-50%); }
}

/* Tôn trọng người dùng tắt hiệu ứng chuyển động */
@media (prefers-reduced-motion: reduce) {
	.vm-promobar__track { animation: none; }
}

/* ============================================================
   Header
   ============================================================ */
.vm-header {
	position: sticky;
	top: 0;
	z-index: 200;
	background: #fff;
	box-shadow: 0 2px 16px rgba(74, 16, 14, 0.07);
	border-bottom: 1px solid var(--vm-line);
}

.vm-header__in {
	height: var(--vm-header-h);
	display: flex;
	align-items: center;
	gap: 30px;
	padding: 0 28px;
}

.vm-header__logo { display: flex; align-items: center; flex: none; }
.vm-header__logo img { height: 74px; width: auto; }

/* Logo tròn (thay wordmark tạm) — footer nền tối + mobile nav */
.vm-footer__logo { display: inline-flex; }
.vm-footer__logo img { height: 82px; width: auto; display: block; }
.vm-mnav__logo { display: inline-flex; }
.vm-mnav__logo img { height: 46px; width: auto; display: block; }

.vm-header__nav {
	flex: 1;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 4px;
}

.vm-header__nav a {
	padding: 10px 15px;
	border-radius: 10px;
	color: #3a2c25;
	font-weight: 600;
	font-size: 15px;
	white-space: nowrap;
	transition: background 0.18s, color 0.18s;
}

.vm-header__nav a:hover, .vm-header__nav a.is-active { background: var(--vm-cream); color: var(--vm-red); }

.vm-header__acts { display: flex; align-items: center; gap: 6px; flex: none; }

.vm-hbtn {
	position: relative;
	width: 46px;
	height: 46px;
	border-radius: 50%;
	color: #3a2c25;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: background 0.18s, color 0.18s;
}

.vm-hbtn:hover { background: var(--vm-cream); color: var(--vm-red); }

.vm-cart-badge {
	position: absolute;
	top: -2px;
	right: -2px;
	min-width: 19px;
	height: 19px;
	padding: 0 5px;
	background: var(--vm-red);
	color: #fff;
	font-size: 11px;
	font-weight: 700;
	border-radius: 10px;
	display: flex;
	align-items: center;
	justify-content: center;
	border: 2px solid #fff;
}

.vm-burger { display: none; }

@media (max-width: 880px) {
	.vm-header__nav { display: none; }
	.vm-header__in { justify-content: space-between; gap: 14px; }
	.vm-burger { display: flex; }
}

@media (max-width: 560px) {
	.vm-header__in { height: 74px; padding: 0 16px; }
	.vm-header__logo img { height: 60px; }
	.vm-hbtn--account { display: none; }
}

/* ============================================================
   Overlay + drawers chung
   ============================================================ */
@keyframes vmfade { from { opacity: 0; } to { opacity: 1; } }
@keyframes vmpop { from { opacity: 0; transform: scale(0.94); } to { opacity: 1; transform: scale(1); } }
@keyframes vmnav { from { transform: translateX(-100%); } to { transform: translateX(0); } }
@keyframes vmcart { from { transform: translateX(100%); } to { transform: translateX(0); } }

.vm-overlay {
	position: fixed;
	inset: 0;
	z-index: 300;
	background: rgba(30, 12, 10, 0.5);
	backdrop-filter: blur(2px);
	animation: vmfade 0.3s ease;
}

.vm-overlay[hidden] { display: none; }

body.vm-locked { overflow: hidden; }

.vm-xbtn {
	width: 40px;
	height: 40px;
	border-radius: 50%;
	background: var(--vm-cream);
	color: var(--vm-red);
	display: flex;
	align-items: center;
	justify-content: center;
	flex: none;
	transition: background 0.18s;
}

.vm-xbtn:hover { background: #efe2c8; }
.vm-xbtn--sm { width: 34px; height: 34px; }

/* Wordmark (bowl + chữ vuamam) */
.vm-wordmark { display: inline-flex; align-items: center; gap: 8px; }

.vm-wordmark span {
	font-family: var(--vm-font-logo);
	font-weight: 800;
	font-size: 24px;
	color: var(--vm-red);
	letter-spacing: -0.5px;
	line-height: 1;
}

/* ============================================================
   Mobile nav drawer (trái)
   ============================================================ */
.vm-mnav {
	position: fixed;
	top: 0;
	left: 0;
	bottom: 0;
	width: min(332px, 88vw);
	z-index: 320;
	background: #fff;
	box-shadow: 12px 0 44px rgba(0, 0, 0, 0.2);
	display: flex;
	flex-direction: column;
	animation: vmnav 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

.vm-mnav[hidden] { display: none; }

.vm-mnav__head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 20px 22px;
	border-bottom: 1px solid var(--vm-line);
}

.vm-mnav__links { padding: 12px; display: flex; flex-direction: column; gap: 2px; overflow-y: auto; }

.vm-mnav__links a {
	display: flex;
	align-items: center;
	gap: 13px;
	padding: 14px;
	border-radius: 12px;
	color: var(--vm-ink);
	font-weight: 600;
	font-size: 15.5px;
	transition: background 0.18s, color 0.18s;
}

.vm-mnav__links a:hover { background: var(--vm-cream); color: var(--vm-red); }

.vm-mnav__foot {
	margin-top: auto;
	padding: 20px 22px;
	border-top: 1px solid var(--vm-line);
	display: flex;
	align-items: center;
	gap: 10px;
	font-size: 13.5px;
	color: #8a7a6c;
}

/* ============================================================
   Search modal
   ============================================================ */
.vm-search {
	position: fixed;
	inset: 0;
	z-index: 340;
	display: flex;
	align-items: flex-start;
	justify-content: center;
	padding: 108px 24px 24px;
	background: rgba(30, 16, 12, 0.5);
	backdrop-filter: blur(3px);
	animation: vmfade 0.26s ease;
}

.vm-search[hidden] { display: none; }

.vm-search__panel {
	width: min(560px, 94vw);
	background: #fff;
	border-radius: 18px;
	box-shadow: 0 30px 70px rgba(0, 0, 0, 0.32);
	padding: 22px;
	animation: vmpop 0.3s cubic-bezier(0.2, 0.8, 0.2, 1);
	position: relative;
}

.vm-search__form {
	display: flex;
	align-items: center;
	gap: 12px;
	border: 2px solid var(--vm-red);
	border-radius: 14px;
	padding: 0 16px;
	height: 56px;
}

.vm-search__ic { color: var(--vm-red); display: flex; }

.vm-search__form input[type="search"] {
	flex: 1;
	min-width: 0;
	border: 0;
	outline: none;
	font-size: 16px;
	background: none;
	color: var(--vm-ink);
}

.vm-search__pop {
	display: flex;
	align-items: center;
	gap: 10px;
	margin-top: 16px;
	flex-wrap: wrap;
}

.vm-search__pop span { font-size: 13px; color: var(--vm-ink-4); }

.vm-search__pop a {
	background: var(--vm-cream);
	color: var(--vm-red);
	border-radius: 20px;
	padding: 8px 16px;
	font-size: 13.5px;
	font-weight: 600;
	transition: background 0.18s;
}

.vm-search__pop a:hover { background: #efe2c8; }

/* Suggest dropdown */
.vm-suggest {
	margin-top: 10px;
	border: 1px solid var(--vm-line);
	border-radius: 14px;
	overflow: hidden;
	background: #fff;
}

.vm-suggest[hidden] { display: none; }

.vm-suggest__item {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 10px 14px;
	transition: background 0.15s;
}

.vm-suggest__item:hover { background: var(--vm-cream); }

.vm-suggest__item img, .vm-suggest__item .vm-ph {
	width: 44px;
	height: 44px;
	border-radius: 9px;
	object-fit: cover;
	flex: none;
	min-height: 0;
}

.vm-suggest__name { font-size: 14px; font-weight: 600; color: var(--vm-ink); }
.vm-suggest__price { font-size: 13px; color: var(--vm-red); font-weight: 700; }
.vm-suggest__more { display: block; padding: 11px 14px; text-align: center; font-size: 13px; font-weight: 600; color: var(--vm-red); background: var(--vm-cream); }

/* ============================================================
   Cart drawer (phải)
   ============================================================ */
.vm-drawer {
	position: fixed;
	top: 0;
	right: 0;
	bottom: 0;
	width: min(408px, 92vw);
	z-index: 320;
	background: var(--vm-bg);
	box-shadow: -12px 0 44px rgba(0, 0, 0, 0.2);
	display: flex;
	flex-direction: column;
	animation: vmcart 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

.vm-drawer[hidden] { display: none; }

.vm-drawer__head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 20px 22px;
	border-bottom: 1px solid var(--vm-line);
	background: #fff;
	flex: none;
}

.vm-drawer__title {
	display: flex;
	align-items: center;
	gap: 10px;
	font-weight: 700;
	font-size: 17px;
	color: var(--vm-ink);
}

.vm-drawer__count { color: var(--vm-red); }

/* Wrapper AJAX phải flex column + min-height:0 (trap: mất scroll che nút) */
#vm-drawer-body {
	flex: 1;
	min-height: 0;
	display: flex;
	flex-direction: column;
}

.vm-drawer__scroll { flex: 1; min-height: 0; overflow-y: auto; padding: 8px 22px; }

.vm-drawer__empty {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 14px;
	padding: 60px 20px;
	text-align: center;
	color: var(--vm-ink-4);
	font-size: 15px;
}

.vm-ditem {
	display: flex;
	gap: 14px;
	padding: 16px 0;
	border-bottom: 1px solid var(--vm-line);
}

.vm-ditem__thumb {
	width: 72px;
	height: 72px;
	flex: none;
	border-radius: 10px;
	overflow: hidden;
	position: relative;
	background: var(--vm-cream);
}

.vm-ditem__thumb img { width: 100%; height: 100%; object-fit: cover; }

.vm-ditem__info { flex: 1; min-width: 0; }

.vm-ditem__top { display: flex; justify-content: space-between; gap: 8px; }

.vm-ditem__name { font-weight: 600; font-size: 14.5px; color: var(--vm-ink); }
.vm-ditem__name:hover { color: var(--vm-red); }

.vm-ditem__remove { color: var(--vm-ink-5); flex: none; padding: 0; transition: color 0.15s; }
.vm-ditem__remove:hover { color: var(--vm-red); }

.vm-ditem__weight { font-size: 12.5px; color: var(--vm-ink-4); margin-top: 2px; }

.vm-ditem__row {
	display: flex;
	align-items: center;
	justify-content: space-between;
	margin-top: 12px;
}

.vm-ditem__line { font-weight: 800; color: var(--vm-red); font-size: 15px; }

/* Qty stepper */
.vm-qty {
	display: flex;
	align-items: center;
	border: 1px solid var(--vm-line-2);
	border-radius: 9px;
	overflow: hidden;
	background: #fff;
}

.vm-qty button {
	width: 34px;
	height: 34px;
	color: var(--vm-red);
	font-size: 17px;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: background 0.15s;
}

.vm-qty button:hover { background: var(--vm-cream); }
.vm-qty span, .vm-qty input { width: 38px; text-align: center; font-weight: 600; font-size: 14px; border: 0; outline: none; background: none; -moz-appearance: textfield; }
.vm-qty input::-webkit-outer-spin-button, .vm-qty input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.vm-qty--sm button { width: 30px; height: 30px; }
.vm-qty--sm span { width: 34px; }

.vm-drawer__foot {
	border-top: 1px solid var(--vm-line);
	padding: 18px 22px;
	background: #fff;
	flex: none;
	display: flex;
	flex-direction: column;
	gap: 10px;
}

.vm-drawer__subrow {
	display: flex;
	justify-content: space-between;
	align-items: baseline;
	margin-bottom: 4px;
}

.vm-drawer__subrow span:first-child { font-size: 14px; color: var(--vm-ink-2); }
.vm-drawer__subtotal { font-weight: 800; font-size: 23px; color: var(--vm-red); }

.vm-drawer__checkout { height: 52px; text-transform: uppercase; letter-spacing: 0.5px; font-weight: 700; font-size: 15px; }

/* ============================================================
   Footer
   ============================================================ */
.vm-footer { background: var(--vm-footer); color: #e0b6aa; }

.vm-footer__grid {
	padding: 58px 28px 30px;
	display: grid;
	grid-template-columns: 1.5fr 1fr 1fr 1fr 1.25fr;
	gap: 38px;
}

.vm-wordmark--footer span { color: #fff; font-size: 27px; letter-spacing: -0.6px; }

.vm-footer__brand p {
	font-size: 13.5px;
	line-height: 1.7;
	color: #cf9d92;
	margin: 16px 0 18px;
	max-width: 260px;
}

.vm-footer__socials { display: flex; gap: 10px; }

.vm-footer__socials a {
	width: 38px;
	height: 38px;
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.1);
	color: #fff;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: background 0.18s, color 0.18s;
}

.vm-footer__socials a:hover { background: var(--vm-gold-2); color: var(--vm-footer); }

.vm-footer__head { color: #fff; font-weight: 700; font-size: 15px; margin-bottom: 16px; }

.vm-footer__links { display: flex; flex-direction: column; gap: 11px; }

.vm-footer__links a { color: #cf9d92; font-size: 13.5px; transition: color 0.15s; }
.vm-footer__links a:hover { color: #fff; }

.vm-footer__contact { display: flex; flex-direction: column; gap: 13px; font-size: 13.5px; color: #cf9d92; }
.vm-footer__contact span { display: flex; gap: 10px; align-items: center; }
.vm-footer__contact span.is-top { align-items: flex-start; }
.vm-footer__contact svg { flex: none; margin-top: 1px; }

.vm-footer__bar { border-top: 1px solid rgba(255, 255, 255, 0.1); }

.vm-footer__bar-in {
	padding: 18px 28px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	flex-wrap: wrap;
	gap: 12px;
}

.vm-footer__copy { font-size: 12.5px; color: #b78a80; }

.vm-footer__pays { display: flex; gap: 8px; align-items: center; }

.vm-footer__pays .pay-visa { background: #fff; border-radius: 5px; padding: 5px 9px; font-weight: 800; font-style: italic; color: #1a1f71; font-size: 12px; }
.vm-footer__pays .pay-mc { background: #fff; border-radius: 5px; padding: 6px 9px; display: flex; align-items: center; }
.vm-footer__pays .pay-mc i { width: 15px; height: 15px; border-radius: 50%; background: #eb001b; display: inline-block; }
.vm-footer__pays .pay-mc i + i { background: #f79e1b; margin-left: -6px; mix-blend-mode: multiply; }
.vm-footer__pays .pay-momo { background: #a50064; border-radius: 5px; padding: 5px 9px; font-weight: 800; color: #fff; font-size: 12px; }
.vm-footer__pays .pay-zalo { background: #0068ff; border-radius: 5px; padding: 5px 9px; font-weight: 700; color: #fff; font-size: 12px; }

@media (max-width: 1024px) {
	.vm-footer__grid { grid-template-columns: repeat(3, 1fr); gap: 30px; }
}

@media (max-width: 640px) {
	.vm-footer__grid { grid-template-columns: repeat(2, 1fr); gap: 26px; padding: 44px 20px 26px; }
	.vm-footer__brand { grid-column: 1 / -1; }
}

/* ============================================================
   Product card (trang chủ / shop / liên quan)
   ============================================================ */
.vm-pgrid { display: grid; gap: 18px; }
.vm-pgrid--4 { grid-template-columns: repeat(4, 1fr); }
.vm-pgrid--3 { grid-template-columns: repeat(3, 1fr); }

.vm-pcard {
	position: relative;
	background: #fff;
	border: 1px solid var(--vm-line);
	border-radius: var(--vm-r-card);
	padding: 18px;
	display: flex;
	flex-direction: column;
	transition: transform 0.25s, box-shadow 0.25s;
}

.vm-pcard:hover { transform: translateY(-6px); box-shadow: 0 22px 44px rgba(74, 16, 14, 0.13); }

.vm-pcard__tier {
	position: absolute;
	top: 5px;
	left: 5px;
	z-index: 3;
	min-width: 78px;
	width: auto;
	padding: 0 14px;
	height: 30px;
	display: flex;
	align-items: center;
	justify-content: center;
	background: url('../images/label-shape.png') center / 100% 100% no-repeat;
	color: #fff;
	font-size: 11px;
	font-weight: 800;
	letter-spacing: 0.5px;
	text-transform: uppercase;
	line-height: 1;
	white-space: nowrap;
	filter: drop-shadow(0 3px 5px rgba(74, 16, 14, 0.28));
}

/* Badge giảm giá (chỉ hiện khi có giá sale thật) — pill đỏ-cam nổi bật */
.vm-pcard__tier--sale {
	min-width: 0;
	padding: 0 12px;
	background: linear-gradient(135deg, #ef5b2b, #c0392b);
	border-radius: 8px;
	font-size: 12.5px;
	filter: drop-shadow(0 3px 6px rgba(192, 57, 43, 0.32));
}

.vm-pcard__img {
	display: block;
	position: relative;
	width: 100%;
	height: 188px;
	border-radius: 12px;
	overflow: hidden;
	background: var(--vm-cream);
}

.vm-pcard__img img { width: 100%; height: 100%; object-fit: cover; }

.vm-pcard__name {
	font-weight: 700;
	font-size: 16.5px;
	color: var(--vm-ink);
	margin-top: 16px;
	transition: color 0.15s;
}

.vm-pcard__name:hover { color: var(--vm-red); }

.vm-pcard__weight { font-size: 13px; color: var(--vm-ink-4); margin-top: 3px; }

.vm-pcard__rate { display: flex; align-items: center; gap: 8px; margin-top: 11px; }
.vm-pcard__rcount { font-size: 12.5px; color: var(--vm-ink-4); }

.vm-pcard__foot {
	display: flex;
	align-items: flex-end;
	justify-content: space-between;
	margin-top: 14px;
	padding-top: 0;
	margin-top: auto;
	padding-top: 14px;
}

.vm-pcard__price { font-weight: 800; font-size: 22px; color: var(--vm-red); display: flex; flex-direction: column; line-height: 1.15; }
.vm-pcard__price-old { font-size: 12.5px; color: var(--vm-ink-4); font-weight: 600; text-decoration: line-through; }

.vm-pcard__add {
	width: 46px;
	height: 46px;
	border-radius: 50%;
	background: var(--vm-red);
	color: #fff;
	display: flex;
	align-items: center;
	justify-content: center;
	box-shadow: 0 8px 18px rgba(138, 30, 27, 0.32);
	transition: background 0.2s, transform 0.2s;
	flex: none;
}

.vm-pcard__add:hover { background: var(--vm-red-hover); transform: scale(1.06); }
.vm-pcard__add.loading { opacity: 0.6; pointer-events: none; }

/* Ẩn link "View cart" WC tự chèn sau khi add */
.vm-pcard .added_to_cart { display: none; }

/* Chip chuyên mục bài viết */
.vm-catchip {
	position: absolute;
	top: 14px;
	left: 14px;
	color: #fff;
	font-size: 11px;
	font-weight: 700;
	padding: 5px 11px;
	border-radius: 7px;
	letter-spacing: 0.5px;
	z-index: 2;
}

/* Heading ornament (line ◆ TITLE ◆ line) */
.vm-orna-head {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 18px;
	text-align: center;
}

.vm-orna-head h2 {
	font-family: var(--vm-font-head);
	font-weight: 800;
	font-size: 32px;
	color: var(--vm-ink);
	letter-spacing: 0.8px;
	text-transform: uppercase;
}

.vm-orna-head__gem { color: var(--vm-gold); font-size: 11px; flex: none; }
.vm-orna-head__line { height: 1px; width: 60px; flex: none; }
.vm-orna-head__line.is-left { background: linear-gradient(90deg, transparent, #d8b98a); }
.vm-orna-head__line.is-right { background: linear-gradient(270deg, transparent, #d8b98a); }

.vm-empty {
	text-align: center;
	color: var(--vm-ink-3);
	padding: 40px 20px;
	background: #fff;
	border: 1px dashed var(--vm-line-2);
	border-radius: 16px;
	margin-top: 30px;
}

@media (max-width: 1024px) {
	.vm-pgrid--4 { grid-template-columns: repeat(3, 1fr); }
	.vm-orna-head h2 { font-size: 27px; }
}

@media (max-width: 640px) {
	.vm-pgrid--4, .vm-pgrid--3 { grid-template-columns: repeat(2, 1fr); gap: 12px; }
	.vm-pcard { padding: 12px; }
	.vm-pcard__img { height: 150px; }
	.vm-pcard__name { font-size: 14.5px; margin-top: 12px; }
	.vm-pcard__price { font-size: 18px; }
	.vm-pcard__add { width: 40px; height: 40px; }
	.vm-orna-head { gap: 10px; }
	.vm-orna-head h2 { font-size: 21px; }
	.vm-orna-head__line { width: 34px; }
}
