/* TLWP Custom Orderby – frontend integration */

/* Generic style for TLWP badges */
.woocommerce .product .tlwp-co-badge {
	display: inline-block;
	padding: 0.2em 0.6em;
	font-size: 0.75em;
	font-weight: 600;
	line-height: 1.4;
	border-radius: 3px;
	text-transform: uppercase;
	letter-spacing: 0.03em;
	vertical-align: middle;
}

/* Coming-soon (Sắp về hàng) badge */
.woocommerce .product .tlwp-co-badge--coming-soon {
	background-color: #f59e0b;
	color: #fff;
}

/* Discontinued badge */
.woocommerce .product .tlwp-co-badge--discontinued {
	background-color: #6b7280;
	color: #fff;
}

/*
 * Flatsome / WooCommerce out-of-stock integration:
 *  - Hide default "Hết hàng / Out of stock" visual elements
 *    only for coming-soon products.
 *  - Scope: any element with .product.tlwp-co-coming-soon-product wrapper
 *    (loops, single, related, upsell, cross-sell, quick view, widgets…).
 */
.product.tlwp-co-coming-soon-product .badge.out-of-stock,
.product.tlwp-co-coming-soon-product .badge.sold-out,
.product.tlwp-co-coming-soon-product .out-of-stock-label,
.product.tlwp-co-coming-soon-product .stock.out-of-stock {
	display: none !important;
}

/* Static label shown before the WooCommerce sorting select. */
.woocommerce .tlwp-co-orderby-static-label {
	display: inline-flex;
	align-items: center;
	margin-right: 0.5em;
	font-size: inherit;
	font-weight: 600;
	color: inherit;
	opacity: 0.75;
	vertical-align: middle;
	pointer-events: none;
}

/* ── 2hand product suggestions ─────────────────────────────────────────── */
.smt-wpc-2h-suggestions {
	margin: 1.25em 0;
	clear: both;
}

.smt-wpc-2h-suggestions__heading {
	margin: 0 0 0.75em;
	font-size: 1.05em;
	font-weight: 600;
}

.smt-wpc-2h-suggestions__list {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-direction: column;
	gap: 0.75em;
}

.smt-wpc-2h-card {
	display: flex;
	align-items: stretch;
	gap: 0.85em;
	margin: 0;
	padding: 0.65em 0;
	border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

.smt-wpc-2h-card.is-hidden,
.smt-wpc-2h-card[hidden] {
	display: none !important;
}

.smt-wpc-2h-card__media {
	flex: 0 0 72px;
	width: 72px;
}

.smt-wpc-2h-card__image-link {
	display: block;
	line-height: 0;
}

.smt-wpc-2h-card__img,
.smt-wpc-2h-card__media img {
	display: block;
	width: 72px;
	height: 72px;
	object-fit: cover;
	border-radius: 2px;
}

.smt-wpc-2h-card__body {
	flex: 1 1 auto;
	min-width: 0;
	display: flex;
	flex-direction: column;
	justify-content: center;
	gap: 0.35em;
}

.smt-wpc-2h-card__row {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: 0.35em 0.75em;
}

.smt-wpc-2h-card__meta-link,
.smt-wpc-2h-card__meta-text {
	font-size: 0.95em;
	font-weight: 600;
	text-decoration: none;
	color: inherit;
}

.smt-wpc-2h-card__meta-link:hover {
	text-decoration: underline;
}

.smt-wpc-2h-card__price {
	font-size: 0.95em;
}

.smt-wpc-2h-card__stock {
	font-size: 0.85em;
	opacity: 0.85;
}

.smt-wpc-2h-suggestions__load-more {
	margin-top: 0.85em;
}

