/* FlexMart Product Experience — product page styles
 * Migrated from the fmproduct_ snippet (classic WooCommerce markup under
 * Kadence) and extended. Colour/radius/typography come from CSS custom
 * properties injected from the admin settings. Mobile-first throughout.
 * Design rule: no layout shift — media reserves space via aspect-ratio. */

:root {
	--fmpx-bg-light: #F8FAFC;
	--fmpx-text: #111827;
	--fmpx-text-secondary: #6B7280;
	--fmpx-border: #E5E7EB;
	--fmpx-pill: 999px;
	--fmpx-shadow-sm: 0 1px 3px rgba(15, 23, 42, 0.07);
	--fmpx-shadow-md: 0 12px 26px rgba(15, 23, 42, 0.13);
	--fmpx-font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

body.fmpx-on .single-product div.product,
body.fmpx-on.woocommerce div.product { font-family: var(--fmpx-font); }

/* ---------------- Breadcrumbs (migrated) ---------------- */
/* The JS rebuilds the default breadcrumb into rounded chips with SVG
 * chevron separators. Until it runs (or if it can't), the original stays
 * readable with the base styling below. */
body.fmpx-on .woocommerce-breadcrumb {
	font-family: var(--fmpx-font);
	font-size: 0.75rem;
	color: var(--fmpx-text) !important;
	font-weight: 600;
	margin: 0 0 16px;
}
body.fmpx-on .woocommerce-breadcrumb a { color: var(--fmpx-text-secondary) !important; text-decoration: none; }
.fmpx-crumbs {
	display: flex;
	align-items: center;
	flex-wrap: nowrap;
	gap: 4px;
	overflow-x: auto;
	-webkit-overflow-scrolling: touch;
	scrollbar-width: none;
	padding: 2px;
	margin: 0 0 8px;
}
.fmpx-crumbs::-webkit-scrollbar { display: none; }
.fmpx-crumbs__chip {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	flex: 0 0 auto;
	padding: 3px 8px;
	border-radius: 6px;
	background: transparent;
	border: none;
	font-family: var(--fmpx-font);
	font-size: 0.68rem;
	font-weight: 600;
	color: var(--fmpx-text-secondary) !important;
	text-decoration: none !important;
	white-space: nowrap;
	transition: color 0.2s ease;
}
a.fmpx-crumbs__chip:hover { color: var(--fmpx-accent) !important; }
.fmpx-crumbs__chip--current {
	background: transparent;
	border: none;
	color: var(--fmpx-primary) !important;
	font-weight: 700;
	max-width: 160px;
	overflow: hidden;
	text-overflow: ellipsis;
}
.fmpx-crumbs__sep { flex: 0 0 auto; width: 11px; height: 11px; color: #C3C8D0; }
.fmpx-crumbs__chip .fmpx-icon { width: 11px; height: 11px; }

/* ---------------- Gallery — single swipeable image, no thumbnail
   strip. WooCommerce's own flexslider drives the actual swipe/slide
   positioning (its JS sets the wrapper's height and each slide's
   position, so our CSS must not fight that by forcing flex/scroll-
   snap on the wrapper — an earlier attempt to do exactly that
   collapsed the gallery to an empty box). Zoom/lightbox theme
   supports (independent of the slider) still give pinch-zoom and
   tap-for-fullscreen. ---------------- */
body.fmpx-on .woocommerce-product-gallery {
	border-radius: var(--fmpx-radius);
	overflow: hidden;
	background: var(--fmpx-bg-light);
	margin: 0 0 10px !important;
	position: relative;
}
body.fmpx-on .woocommerce-product-gallery .woocommerce-product-gallery__wrapper { aspect-ratio: 1 / 1; }
body.fmpx-on .woocommerce-product-gallery .woocommerce-product-gallery__image,
body.fmpx-on .woocommerce-product-gallery__image a {
	border-radius: var(--fmpx-radius);
	overflow: hidden;
}
body.fmpx-on .woocommerce-product-gallery img {
	border-radius: var(--fmpx-radius);
	width: 100%;
	height: auto;
	object-fit: cover;
}
/* Clear per-slide separation instead of a cross-fade blend — flexslider's
   default "slide" animation (set explicitly in product.php's flexslider
   options filter) already gives this; this transition is only for the
   image's own opacity settle, not the slide-to-slide motion itself. */
body.fmpx-on .woocommerce-product-gallery .woocommerce-product-gallery__image { transition: opacity 0.2s ease; }

/* Thumbnail strip removed entirely — the swipeable main image is the
 * whole gallery now. WooCommerce's flexslider still renders this
 * markup (it drives the thumb-click-to-slide sync internally), so it
 * stays in the DOM but is never shown. */
body.fmpx-on .flex-control-thumbs { display: none !important; }

/* Swipe dot indicators, replacing the thumbnail strip as the position
 * cue. Driven by assets/js/product.js watching WooCommerce's own
 * "flex-active-slide" state — no gallery reimplementation, just a
 * lightweight visual mirror of it. */
body.fmpx-on .fmpx-gallery-dots {
	display: flex;
	justify-content: center;
	align-items: center;
	gap: 6px;
	margin: 10px 0 0;
}
body.fmpx-on .fmpx-gallery-dots__dot {
	width: 6px;
	height: 6px;
	border-radius: 50%;
	background: var(--fmpx-border);
	transition: background 0.25s ease, width 0.25s ease, border-radius 0.25s ease;
	padding: 0;
	border: none;
	cursor: pointer;
}
body.fmpx-on .fmpx-gallery-dots__dot--active {
	width: 18px;
	border-radius: 4px;
	background: var(--fmpx-accent);
}
/* Only one product image → no dots needed at all. */
body.fmpx-on .fmpx-gallery-dots:has(.fmpx-gallery-dots__dot:only-child) { display: none; }

body.fmpx-on .woocommerce-product-gallery > .onsale { position: absolute; top: 14px; left: 14px; z-index: 5; }
body.fmpx-on .woocommerce-product-gallery__trigger { z-index: 6; }

/* ---------------- SVG icons ---------------- */
.fmpx-icon { width: 1em; height: 1em; display: inline-block; vertical-align: -0.12em; flex-shrink: 0; }
.fmpx-stock-dot { width: 9px; height: 9px; }
body.fmpx-on .fmpx-stock-in .fmpx-stock-dot { color: #16A34A; }
body.fmpx-on .fmpx-stock-order .fmpx-stock-dot { color: #D97706; }
body.fmpx-on .fmpx-stock-out .fmpx-stock-dot { color: #DC2626; }
body.fmpx-on .fmshop-stock-in .fmpx-stock-dot { color: #16A34A; }
body.fmpx-on .fmshop-stock-order .fmpx-stock-dot { color: #D97706; }
body.fmpx-on .fmshop-stock-out .fmpx-stock-dot { color: #DC2626; }
.fmpx-spec__icon .fmpx-icon { width: 17px; height: 17px; color: var(--fmpx-accent); }
.fmpx-trust__icon .fmpx-icon { width: 18px; height: 18px; color: var(--fmpx-accent); }

/* ---------------- Info card (migrated) ---------------- */
body.fmpx-on .fmpx-info-card {
	background: #fff;
	border: 1px solid var(--fmpx-border);
	border-radius: var(--fmpx-radius);
	box-shadow: var(--fmpx-shadow-sm);
	padding: 16px;
}
@media (max-width: 480px) {
	body.fmpx-on .fmpx-info-card { padding: 14px; border-radius: var(--fmpx-radius-sm); }
}

/* Shared small heading used above Product Overview and Why Buy From
 * FlexMart — consistent, compact, no big gap underneath. */
body.fmpx-on .fmpx-section-heading {
	font-size: calc(1.08rem * var(--fmpx-scale, 1));
	font-weight: 800;
	color: #111111;
	letter-spacing: -0.01em;
	margin: 18px 0 8px;
	line-height: 1.3;
}
body.fmpx-on .fmpx-info-card > .fmpx-section-heading:first-child,
body.fmpx-on .fmpx-excerpt-wrap .fmpx-section-heading:first-child {
	margin-top: 0;
}

/* Product Information Card rows: icon + label + value. */
body.fmpx-on .fmpx-info-rows {
	display: flex;
	flex-direction: column;
	margin-top: 4px;
}
body.fmpx-on .fmpx-info-row {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 9px 0;
	border-bottom: 1px solid var(--fmpx-border);
	font-size: 0.86rem;
}
body.fmpx-on .fmpx-info-row:last-child { border-bottom: none; padding-bottom: 0; }
body.fmpx-on .fmpx-info-row:first-child { padding-top: 0; }
body.fmpx-on .fmpx-info-row__icon {
	flex-shrink: 0;
	width: 30px;
	height: 30px;
	display: flex;
	align-items: center;
	justify-content: center;
	border-radius: 50%;
	background: var(--fmpx-bg-light);
	color: var(--fmpx-accent);
}
body.fmpx-on .fmpx-info-row__icon .fmpx-icon { width: 15px; height: 15px; color: var(--fmpx-accent); }
body.fmpx-on .fmpx-info-row__label {
	flex-shrink: 0;
	width: 92px;
	color: #333333;
	font-weight: 600;
}
body.fmpx-on .fmpx-info-row__value {
	flex: 1;
	color: var(--fmpx-text);
	font-weight: 700;
	text-align: right;
}

/* ---------------- Title (migrated, scale-aware) ---------------- */
body.fmpx-on.single-product .product_title,
body.fmpx-on.single-product h1.product_title {
	font-size: calc(clamp(1.4rem, 3vw, 2rem) * var(--fmpx-scale, 1)) !important;
	font-weight: 800 !important;
	color: #111111 !important;
	letter-spacing: -0.01em;
	line-height: 1.28;
	margin: 0 0 8px !important;
	padding: 0 !important;
	display: -webkit-box !important;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

/* ---------------- Price (migrated) ---------------- */
body.fmpx-on.single-product .summary .price,
body.fmpx-on.single-product .summary .price * {
	font-family: var(--fmpx-font) !important;
	color: var(--fmpx-accent) !important;
}
body.fmpx-on.single-product .summary .price {
	display: flex !important;
	align-items: center;
	flex-wrap: wrap;
	gap: 10px;
	font-size: calc(1.9rem * var(--fmpx-scale, 1)) !important;
	font-weight: 800 !important;
	line-height: 1.1;
	margin: 0 0 12px !important;
}
body.fmpx-on.single-product .summary .price ins,
body.fmpx-on.single-product .summary .price ins * {
	text-decoration: none !important;
	font-weight: 800 !important;
	color: var(--fmpx-accent) !important;
}
body.fmpx-on.single-product .summary .price ins { order: 1; line-height: 1.1; }
body.fmpx-on.single-product .summary .price del,
body.fmpx-on.single-product .summary .price del * {
	font-weight: 400 !important;
	color: var(--fmpx-text-secondary) !important;
	text-decoration: line-through !important;
	font-size: 0.5em !important;
}
body.fmpx-on.single-product .summary .price del {
	order: 2;
	opacity: 1;
	display: inline-block;
	line-height: 1.3; /* independent of the price's own huge line-height, so the strikethrough sits cleanly instead of clipping/overlapping */
}

body.fmpx-on .onsale.fmpx-sale-badge {
	display: inline-flex !important;
	align-items: center;
	font-size: 0.78rem;
	font-weight: 700;
	padding: 5px 12px;
	border-radius: var(--fmpx-pill);
	background: linear-gradient(135deg, #EF4444, #DC2626);
	color: #fff !important;
	line-height: 1;
	letter-spacing: 0.02em;
	box-shadow: 0 4px 10px rgba(220, 38, 38, 0.3);
}

/* ---------------- Brand line: "Brand: Samsung" — plain text, no card ---------------- */
body.fmpx-on .fmpx-brand-line {
	font-size: 0.86rem;
	color: #444444;
	margin: 0 0 8px !important;
}
body.fmpx-on .fmpx-brand-line a { color: var(--fmpx-accent); text-decoration: none; font-weight: 600; }
body.fmpx-on .fmpx-brand-line a:hover { text-decoration: underline; }

/* ---------------- Price line: current + old + inline percent ---------------- */
body.fmpx-on .fmpx-price-line {
	display: flex !important;
	align-items: center;
	flex-wrap: wrap;
	gap: 10px;
	margin: 0 0 8px !important;
}
body.fmpx-on .fmpx-price-line .woocommerce-Price-amount {
	font-size: calc(1.65rem * var(--fmpx-scale, 1));
	font-weight: 800;
	color: var(--fmpx-accent);
}
body.fmpx-on .fmpx-price-line del {
	font-size: 0.55em !important;
	font-weight: 400 !important;
	color: var(--fmpx-text-secondary) !important;
	text-decoration: line-through !important;
	line-height: 1.3;
}
body.fmpx-on .fmpx-price-line del .woocommerce-Price-amount,
body.fmpx-on .fmpx-price-line del * { font-size: 1em; font-weight: 400 !important; color: var(--fmpx-text-secondary) !important; }
body.fmpx-on .fmpx-price-line__percent {
	font-size: 0.78rem;
	font-weight: 700;
	color: #B45309;
	background: #FEF3C7;
	padding: 3px 9px;
	border-radius: 6px;
	line-height: 1.4;
}

/* ---------------- Stock line: plain coloured text, no badge/pill ---------------- */
body.fmpx-on .fmpx-stock-line {
	font-size: 0.82rem;
	font-weight: 600;
	color: #16A34A;
	margin: 0 0 12px !important;
}
body.fmpx-on .fmpx-stock-line--out { color: #DC2626; }
body.fmpx-on .fmpx-stock-line--order { color: #D97706; }

/* ---------------- Help / order-via-WhatsApp text ---------------- */
body.fmpx-on .fmpx-help-line {
	font-size: 0.82rem;
	color: #444444;
	line-height: 1.6;
	margin: 12px 0 0 !important;
}
body.fmpx-on .fmpx-help-line a {
	color: var(--fmpx-accent);
	font-weight: 700;
	text-decoration: none;
}
body.fmpx-on .fmpx-help-line a:hover { text-decoration: underline; }

/* ---------------- Wishlist & Share row ---------------- */
/* FlexMart Wishlist's own duplicate heart on this page is unhooked in
 * PHP (setup_product_page(), confirmed against that plugin's actual
 * source — see class-fmpx-frontend.php), not hidden via CSS guessing.
 * This button below legitimately carries FlexMart Wishlist's own
 * "fmw-heart" class so its real, already-loaded click handling
 * applies to it directly. */

body.fmpx-on .fmpx-wishlist-share {
	display: flex;
	align-items: center;
	gap: 22px;
	margin: 12px 0 0 !important;
}
body.fmpx-on .fmpx-wishlist-share__btn {
	appearance: none;
	border: none;
	background: none;
	box-shadow: none;
	width: auto;
	height: auto;
	border-radius: 0;
	margin: 0;
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 4px 0;
	font-size: 0.82rem;
	font-weight: 600;
	color: #444444;
	cursor: pointer;
}
body.fmpx-on .fmpx-wishlist-share__btn svg { width: auto; height: auto; } /* overrides FlexMart Wishlist's own 19px svg sizing rule */
body.fmpx-on .fmpx-wishlist-share__btn .fmpx-icon { width: 18px; height: 18px; }
body.fmpx-on #fmpx-wishlist-btn[aria-pressed="true"] { color: #DC2626; }
body.fmpx-on #fmpx-wishlist-btn[aria-pressed="true"] .fmpx-icon { fill: #DC2626; }

/* ---------------- Short description (migrated + collapse) ---------------- */
body.fmpx-on .woocommerce-product-details__short-description {
	color: #444444;
	font-size: calc(0.95rem * var(--fmpx-scale, 1));
	line-height: 1.7;
	margin: 0 0 14px !important;
	padding: 0 !important;
}
body.fmpx-on .woocommerce-product-details__short-description p { margin: 0 0 10px; }
body.fmpx-on .woocommerce-product-details__short-description p:last-child { margin-bottom: 0; }
body.fmpx-on .woocommerce-product-details__short-description ul { margin: 0 0 10px; padding-left: 20px; }
body.fmpx-on .woocommerce-product-details__short-description li { margin-bottom: 4px; }


/* ---------------- Spec summary chips ---------------- */
.fmpx-specs {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 10px;
	margin: 2px 0 16px;
}
@media (min-width: 640px) { .fmpx-specs { grid-template-columns: repeat(4, 1fr); } }
.fmpx-spec {
	display: flex;
	flex-direction: column;
	gap: 2px;
	padding: 10px 12px;
	background: var(--fmpx-bg-light);
	border: 1px solid var(--fmpx-border);
	border-radius: var(--fmpx-radius-sm);
	min-width: 0;
}
.fmpx-spec__icon { font-size: 1rem; line-height: 1; }
.fmpx-spec__label {
	font-size: 0.62rem;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.06em;
	color: var(--fmpx-text-secondary);
}
.fmpx-spec__value {
	font-size: 0.82rem;
	font-weight: 700;
	color: var(--fmpx-primary);
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

/* ---------------- Quantity stepper (migrated) ---------------- */
body.fmpx-on .quantity { display: inline-flex; align-items: center; margin: 0 12px 0 0; }
body.fmpx-on .quantity .qty {
	width: 40px;
	text-align: center;
	border: none;
	background: transparent;
	font-size: 0.88rem;
	font-weight: 700;
	color: var(--fmpx-text);
	padding: 8px 0;
	-moz-appearance: textfield;
}
body.fmpx-on .quantity .qty::-webkit-outer-spin-button,
body.fmpx-on .quantity .qty::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
body.fmpx-on .fmpx-quantity {
	display: inline-flex;
	align-items: center;
	border: 1px solid var(--fmpx-border);
	border-radius: var(--fmpx-pill);
	background: #fff;
	overflow: hidden;
}
body.fmpx-on .fmpx-qty-btn {
	width: 30px;
	height: 30px;
	border: none;
	background: var(--fmpx-bg-light);
	color: var(--fmpx-primary);
	font-size: 0.95rem;
	font-weight: 700;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: background 0.2s ease;
}
body.fmpx-on .fmpx-qty-btn:hover { background: var(--fmpx-border); }

/* ---------------- Actions: ATC + WhatsApp (migrated) ---------------- */
body.fmpx-on.single-product [class*="add_to_cart_button"],
body.fmpx-on.single-product form.cart button[type="submit"],
body.fmpx-on.single-product .fmpx-whatsapp-btn {
	box-sizing: border-box !important;
	display: inline-flex !important;
	align-items: center !important;
	justify-content: center !important;
	gap: 8px !important;
	height: 44px !important;
	min-height: 44px !important;
	max-height: 44px !important;
	line-height: 1 !important;
	width: 100% !important;
	max-width: 100% !important;
	margin: 0 !important;
	text-align: center !important;
	font-family: var(--fmpx-font) !important;
	font-size: 0.86rem !important;
	font-weight: 700 !important;
	border: none !important;
	border-radius: var(--fmpx-pill) !important;
	padding: 0 20px !important;
	cursor: pointer;
	overflow: hidden;
	text-decoration: none !important;
	transition: transform 0.22s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.22s ease !important;
}
body.fmpx-on.single-product [class*="add_to_cart_button"],
body.fmpx-on.single-product form.cart button[type="submit"] {
	color: #fff !important;
	background: linear-gradient(135deg, var(--fmpx-accent), color-mix(in srgb, var(--fmpx-accent) 78%, #000)) !important;
	box-shadow: 0 8px 18px color-mix(in srgb, var(--fmpx-accent) 30%, transparent) !important;
}
body.fmpx-on.single-product .fmpx-whatsapp-btn {
	color: #fff !important;
	background: linear-gradient(135deg, #22C55E, var(--fmpx-success) 70%) !important;
	box-shadow: 0 8px 18px rgba(22, 163, 74, 0.28) !important;
}
body.fmpx-on.single-product [class*="add_to_cart_button"] svg,
body.fmpx-on.single-product [class*="add_to_cart_button"] img,
body.fmpx-on.single-product [class*="add_to_cart_button"] i { display: none !important; }
@media (hover: hover) and (pointer: fine) {
	body.fmpx-on.single-product [class*="add_to_cart_button"]:hover,
	body.fmpx-on.single-product form.cart button[type="submit"]:hover {
		transform: translateY(-2px);
		box-shadow: 0 12px 24px color-mix(in srgb, var(--fmpx-accent) 38%, transparent) !important;
	}
	body.fmpx-on.single-product .fmpx-whatsapp-btn:hover {
		transform: translateY(-2px);
		box-shadow: 0 12px 24px rgba(22, 163, 74, 0.36) !important;
	}
}
body.fmpx-on .fmpx-actions { display: flex; margin-top: 14px; }
body.fmpx-on .fmpx-actions form.cart {
	margin: 0 !important;
	display: flex;
	flex-wrap: nowrap;
	align-items: center;
	gap: 10px;
	width: 100%;
}
body.fmpx-on .fmpx-actions .quantity { flex: 0 0 auto; }
body.fmpx-on .fmpx-actions [class*="add_to_cart_button"],
body.fmpx-on .fmpx-actions form.cart button[type="submit"] { flex: 1 1 auto; }

/* ================================================================
   PLAIN SECTIONS — Product Description & Product Details, printed
   after the summary/actions card. Deliberately NOT styled like the
   rest of the premium card system: simple heading, thin dividers,
   white background, exactly like Jumia — no tab nav, no fancy pill
   heading, no big card shadow.
   ================================================================ */
.fmpx-container { max-width: 720px; margin: 10px auto 0; padding: 0 4px; }
.fmpx-description-card {
	background: #fff;
	border-radius: var(--fmpx-radius);
	box-shadow: var(--fmpx-shadow-sm);
	padding: 16px;
}
.fmpx-plain-section {
	background: #fff;
	border-radius: var(--fmpx-radius-sm);
	padding: 16px 0;
	border-top: 1px solid var(--fmpx-border);
}
.fmpx-plain-heading {
	font-size: 1.05rem;
	font-weight: 800;
	color: #111111;
	letter-spacing: -0.01em;
	margin: 0 0 10px;
}
.fmpx-description-body {
	font-size: 0.88rem;
	line-height: 1.75;
	color: #444444;
	transition: max-height 0.35s ease;
}
.fmpx-description-body p { margin: 0 0 12px; }
.fmpx-description-body p:last-child { margin-bottom: 0; }
.fmpx-description-body.fmpx-collapsed {
	max-height: 6.5em;
	overflow: hidden;
}
.fmpx-readmore {
	appearance: none !important;
	border: 0 !important;
	background: none !important;
	background-color: transparent !important;
	box-shadow: none !important;
	display: flex !important;
	align-items: center;
	gap: 4px;
	width: auto !important;
	padding: 0 !important;
	margin: 10px 0 0 !important;
	color: var(--fmpx-accent) !important;
	font-weight: 700 !important;
	font-size: 0.85rem !important;
	cursor: pointer;
}
.fmpx-details-table { width: 100%; border-collapse: collapse; font-size: 0.86rem; }
.fmpx-details-table tr { border-bottom: 1px solid var(--fmpx-border); }
.fmpx-details-table tr:last-child { border-bottom: none; }
.fmpx-details-table th,
.fmpx-details-table td { padding: 10px 4px; text-align: left; vertical-align: top; }
.fmpx-details-table th { color: #333333; font-weight: 600; width: 40%; }
.fmpx-details-table td { color: #444444; font-weight: 500; }

/* ---------------- Trust cards (upgraded from the trust bar) ---------------- */
.fmpx-trust {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	align-items: stretch;
	gap: 10px;
	list-style: none !important;
	margin: 4px 0 0 !important;
	padding: 0 !important;
}
@media (min-width: 640px) { .fmpx-trust { grid-template-columns: repeat(3, 1fr); } }
.fmpx-trust__item {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 14px;
	background: var(--fmpx-bg-light);
	border: 1px solid var(--fmpx-border);
	border-radius: var(--fmpx-radius-sm);
	box-shadow: var(--fmpx-shadow-sm);
	font-size: 0.78rem;
	font-weight: 600;
	color: var(--fmpx-text);
	list-style: none !important;
	transition: transform 0.2s ease, border-color 0.2s ease;
}
@media (hover: hover) { .fmpx-trust__item:hover { transform: translateY(-2px); border-color: color-mix(in srgb, var(--fmpx-accent) 35%, var(--fmpx-border)); } }
.fmpx-trust__icon { font-size: 1.05rem; line-height: 1; }

/* ---------------- Meta pills (migrated) ---------------- */
body.fmpx-on .product_meta { margin-top: 20px !important; font-size: 0.85rem; }
body.fmpx-on .product_meta > span { display: block; margin-bottom: 8px; }
body.fmpx-on .product_meta a {
	display: inline-flex;
	align-items: center;
	margin: 2px 4px 2px 0;
	padding: 6px 14px;
	border-radius: var(--fmpx-pill);
	background: var(--fmpx-bg-light);
	border: 1px solid var(--fmpx-border);
	color: var(--fmpx-primary) !important;
	font-weight: 600;
	text-decoration: none !important;
	transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease, border-color 0.2s ease;
}
body.fmpx-on .product_meta a:hover {
	background: var(--fmpx-accent);
	border-color: var(--fmpx-accent);
	color: #fff !important;
	transform: translateY(-2px);
}

/* ---------------- Tabs (migrated + animated panels) ---------------- */
body.fmpx-on .woocommerce-tabs.wc-tabs-wrapper,
body.fmpx-on .woocommerce-tabs { margin-top: 36px; }
body.fmpx-tabs ul.tabs.wc-tabs {
	display: flex;
	flex-wrap: nowrap;
	overflow-x: auto;
	scrollbar-width: none;
	gap: 6px;
	list-style: none !important;
	padding: 6px !important;
	margin: 0 0 20px !important;
	background: var(--fmpx-bg-light);
	border: 1px solid var(--fmpx-border);
	border-radius: var(--fmpx-pill);
	width: fit-content;
	max-width: 100%;
}
body.fmpx-tabs ul.tabs.wc-tabs::-webkit-scrollbar { display: none; }
body.fmpx-tabs ul.tabs.wc-tabs li { list-style: none !important; margin: 0 !important; flex: 0 0 auto; }
body.fmpx-tabs ul.tabs.wc-tabs li a {
	display: inline-block;
	padding: 11px 20px;
	font-family: var(--fmpx-font);
	font-size: 0.88rem;
	font-weight: 700;
	color: var(--fmpx-text-secondary) !important;
	text-decoration: none !important;
	border-radius: var(--fmpx-pill);
	transition: color 0.25s ease, background 0.25s ease, box-shadow 0.25s ease;
	white-space: nowrap;
}
body.fmpx-tabs ul.tabs.wc-tabs li:hover a { color: var(--fmpx-primary) !important; }
body.fmpx-tabs ul.tabs.wc-tabs li.active a {
	color: #fff !important;
	background: linear-gradient(135deg, var(--fmpx-accent), color-mix(in srgb, var(--fmpx-accent) 78%, #000));
	box-shadow: 0 6px 14px color-mix(in srgb, var(--fmpx-accent) 34%, transparent);
}
body.fmpx-tabs .woocommerce-Tabs-panel {
	font-family: var(--fmpx-font);
	color: #444444;
	line-height: 1.8;
	font-size: calc(0.96rem * var(--fmpx-scale, 1));
	background: #fff;
	border: 1px solid var(--fmpx-border);
	border-radius: var(--fmpx-radius);
	box-shadow: var(--fmpx-shadow-sm);
	padding: 18px;
}
@media (max-width: 480px) { body.fmpx-tabs .woocommerce-Tabs-panel { padding: 18px; border-radius: var(--fmpx-radius-sm); } }
/* Defensive backup: WooCommerce's own tab function still prints an
   empty <h2></h2> even when the description-heading filter returns ''
   (it filters the text, not whether the tag prints) — hide it so it
   never reserves any space. */
body.fmpx-tabs .woocommerce-Tabs-panel h2:empty { display: none !important; margin: 0 !important; }
body.fmpx-tabs.fmpx-animate .woocommerce-Tabs-panel.fmpx-panel-in { animation: fmpxPanel 0.32s cubic-bezier(0.22, 1, 0.36, 1); }
@keyframes fmpxPanel {
	from { opacity: 0; transform: translateY(8px); }
	to { opacity: 1; transform: translateY(0); }
}
body.fmpx-tabs .woocommerce-Tabs-panel p { margin: 0 0 16px; }
body.fmpx-tabs .woocommerce-Tabs-panel p:last-child { margin-bottom: 0; }
body.fmpx-tabs .woocommerce-Tabs-panel h1, body.fmpx-tabs .woocommerce-Tabs-panel h2,
body.fmpx-tabs .woocommerce-Tabs-panel h3, body.fmpx-tabs .woocommerce-Tabs-panel h4 {
	font-weight: 800; color: #111111; letter-spacing: -0.01em; margin: 26px 0 12px; line-height: 1.3;
}
body.fmpx-tabs .woocommerce-Tabs-panel h1:first-child, body.fmpx-tabs .woocommerce-Tabs-panel h2:first-child,
body.fmpx-tabs .woocommerce-Tabs-panel h3:first-child, body.fmpx-tabs .woocommerce-Tabs-panel h4:first-child { margin-top: 0; }
body.fmpx-tabs .woocommerce-Tabs-panel ul, body.fmpx-tabs .woocommerce-Tabs-panel ol { margin: 0 0 16px; padding-left: 22px; }
body.fmpx-tabs .woocommerce-Tabs-panel li { margin-bottom: 8px; line-height: 1.7; }
body.fmpx-tabs .woocommerce-Tabs-panel li::marker { color: var(--fmpx-accent); }
body.fmpx-tabs .woocommerce-Tabs-panel table.shop_attributes {
	border-collapse: separate;
	border-spacing: 0;
	width: 100%;
	border: 1px solid var(--fmpx-border);
	border-radius: var(--fmpx-radius-sm);
	overflow: hidden;
}
body.fmpx-tabs .woocommerce-Tabs-panel table.shop_attributes th,
body.fmpx-tabs .woocommerce-Tabs-panel table.shop_attributes td { padding: 12px 14px; border-bottom: 1px solid var(--fmpx-border); text-align: left; font-size: 0.88rem; }
body.fmpx-tabs .woocommerce-Tabs-panel table.shop_attributes tr:last-child th,
body.fmpx-tabs .woocommerce-Tabs-panel table.shop_attributes tr:last-child td { border-bottom: none; }
body.fmpx-tabs .woocommerce-Tabs-panel table.shop_attributes tr:nth-child(even) { background: var(--fmpx-bg-light); }
body.fmpx-tabs .woocommerce-Tabs-panel table.shop_attributes th {
	color: #333333;
	font-weight: 700;
	width: 42%;
}
body.fmpx-tabs .woocommerce-Tabs-panel table.shop_attributes td { color: #444444; font-weight: 600; }

/* ---------------- Related products (migrated cards + slider mode) ---------------- */
body.fmpx-on .related.products, body.fmpx-on .upsells.products { margin-top: 14px; position: relative; }
body.fmpx-on .related.products > h2, body.fmpx-on .upsells.products > h2 {
	font-size: clamp(1.3rem, 2.6vw, 1.7rem);
	font-weight: 800;
	color: var(--fmpx-primary);
	margin: 0 0 20px;
	font-family: var(--fmpx-font);
}
/* Grid fallback (slider off) — migrated */
body.fmpx-on .related.products ul.products, body.fmpx-on .upsells.products ul.products {
	display: grid !important;
	grid-template-columns: repeat(2, 1fr) !important;
	gap: 14px !important;
	padding: 0 !important;
	margin: 0 !important;
	list-style: none !important;
}
@media (min-width: 640px) {
	body.fmpx-on .related.products ul.products, body.fmpx-on .upsells.products ul.products { grid-template-columns: repeat(3, 1fr) !important; gap: 20px !important; }
}
@media (min-width: 900px) {
	body.fmpx-on .related.products ul.products, body.fmpx-on .upsells.products ul.products { grid-template-columns: repeat(4, 1fr) !important; }
}
/* Slider mode: one row, scroll-snap, arrows */
body.fmpx-related-slider .related.products ul.products,
body.fmpx-related-slider .upsells.products ul.products {
	display: flex !important;
	overflow-x: auto;
	-webkit-overflow-scrolling: touch;
	scroll-snap-type: x mandatory;
	scrollbar-width: none;
	gap: 14px !important;
	padding: 2px 2px 8px !important;
}
body.fmpx-related-slider .related.products ul.products::-webkit-scrollbar,
body.fmpx-related-slider .upsells.products ul.products::-webkit-scrollbar { display: none; }
body.fmpx-related-slider .related.products ul.products li.product,
body.fmpx-related-slider .upsells.products ul.products li.product {
	flex: 0 0 72%;
	max-width: 260px;
	scroll-snap-align: start;
}
@media (min-width: 640px) {
	body.fmpx-related-slider .related.products ul.products li.product,
	body.fmpx-related-slider .upsells.products ul.products li.product { flex: 0 0 240px; }
}
.fmpx-slider-nav {
	position: absolute;
	top: 2px;
	right: 0;
	display: none;
	gap: 8px;
}
@media (hover: hover) and (pointer: fine) { body.fmpx-related-slider .fmpx-slider-nav { display: flex; } }
.fmpx-slider-nav button {
	width: 36px;
	height: 36px;
	border-radius: 50%;
	border: 1px solid var(--fmpx-border);
	background: #fff;
	color: var(--fmpx-primary);
	font-size: 1rem;
	cursor: pointer;
	box-shadow: var(--fmpx-shadow-sm);
	transition: background 0.2s ease, color 0.2s ease;
}
.fmpx-slider-nav button:hover { background: var(--fmpx-accent); color: #fff; border-color: var(--fmpx-accent); }

body.fmpx-on .related.products ul.products li.product,
body.fmpx-on .upsells.products ul.products li.product { width: auto !important; float: none !important; margin: 0 !important; padding: 0 !important; list-style: none !important; }
body.fmpx-on .fmshop-card {
	display: flex;
	flex-direction: column;
	height: 100%;
	background: #fff;
	border: 1px solid var(--fmpx-border);
	border-radius: var(--fmpx-radius);
	overflow: hidden;
	box-shadow: var(--fmpx-shadow-sm);
	font-family: var(--fmpx-font);
	transition: transform 0.28s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.28s ease, border-color 0.28s ease;
}
body.fmpx-on .fmshop-card:hover { transform: translateY(-5px); box-shadow: var(--fmpx-shadow-md); border-color: color-mix(in srgb, var(--fmpx-accent) 25%, transparent); }
body.fmpx-on .fmshop-card-link { display: block; text-decoration: none !important; color: inherit; box-shadow: none !important; }
body.fmpx-on .fmshop-media { position: relative; aspect-ratio: 1 / 1; overflow: hidden; background: var(--fmpx-bg-light); }
body.fmpx-on .fmshop-img { width: 100% !important; height: 100% !important; object-fit: cover; display: block; margin: 0 !important; transition: transform 0.5s cubic-bezier(0.22, 1, 0.36, 1); }
@media (hover: hover) and (pointer: fine) { body.fmpx-on .fmshop-card:hover .fmshop-img { transform: scale(1.07); } }
body.fmpx-on .fmshop-badges { position: absolute; top: 10px; left: 10px; right: 10px; z-index: 2; display: flex; justify-content: space-between; align-items: flex-start; pointer-events: none; }
body.fmpx-on .fmshop-badge { display: inline-flex; align-items: center; font-size: 0.68rem; font-weight: 700; padding: 4px 9px; border-radius: var(--fmpx-pill); line-height: 1; color: #fff; box-shadow: var(--fmpx-shadow-sm); }
body.fmpx-on .fmshop-badge-sale { background: linear-gradient(135deg, #EF4444, #DC2626); }
body.fmpx-on .fmshop-body { display: flex; flex-direction: column; padding: 12px 14px 14px; flex: 1; }
body.fmpx-on .fmshop-title {
	font-size: 0.92rem; font-weight: 600; color: var(--fmpx-text); margin: 0 0 8px; line-height: 1.35;
	min-height: calc(1.35em * 2);
	display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
body.fmpx-on .fmshop-price { margin: 0 0 10px; display: flex; align-items: baseline; flex-wrap: wrap; gap: 6px; font-size: 1.15rem; font-weight: 800; }
body.fmpx-on .fmshop-price, body.fmpx-on .fmshop-price * { color: var(--fmpx-accent) !important; font-family: var(--fmpx-font) !important; }
body.fmpx-on .fmshop-price ins, body.fmpx-on .fmshop-price ins * { text-decoration: none !important; font-weight: 800 !important; color: var(--fmpx-accent) !important; }
body.fmpx-on .fmshop-price del, body.fmpx-on .fmshop-price del * { color: var(--fmpx-text-secondary) !important; font-size: 0.7em; font-weight: 400; text-decoration: line-through !important; }
body.fmpx-on .fmshop-stock-badge {
	display: inline-flex; align-items: center; gap: 4px; align-self: flex-start; font-size: 0.7rem; font-weight: 600;
	padding: 3px 9px 3px 7px; border-radius: var(--fmpx-pill); background: var(--fmpx-bg-light); border: 1px solid var(--fmpx-border); margin: 0 0 12px;
}
body.fmpx-on .fmshop-stock-in { color: #166534; border-color: rgba(22, 163, 74, 0.35); background: rgba(22, 163, 74, 0.08); }
body.fmpx-on .fmshop-stock-order { color: #92400E; border-color: rgba(217, 119, 6, 0.35); background: rgba(217, 119, 6, 0.08); }
body.fmpx-on .fmshop-stock-out { color: #991B1B; border-color: rgba(220, 38, 38, 0.35); background: rgba(220, 38, 38, 0.08); }
body.fmpx-on .fmshop-cta { margin-top: auto; padding: 0 14px 16px; display: flex; justify-content: center; }
body.fmpx-on .fmshop-cta a {
	display: block; width: 88%; margin: 0 auto; text-align: center; font-weight: 700; font-size: 0.86rem;
	color: #fff !important; background: linear-gradient(135deg, var(--fmpx-accent), color-mix(in srgb, var(--fmpx-accent) 78%, #000));
	border-radius: var(--fmpx-pill); padding: 11px 18px;
	box-shadow: 0 8px 18px color-mix(in srgb, var(--fmpx-accent) 30%, transparent); text-decoration: none !important;
}

/* ---------------- Sticky mobile Add to Cart ---------------- */
.fmpx-sticky {
	position: fixed;
	left: 0;
	right: 0;
	bottom: 0;
	z-index: 99980;
	display: flex;
	align-items: center;
	gap: 10px;
	min-height: 68px;
	padding: 8px 12px calc(8px + env(safe-area-inset-bottom));
	background: rgba(255, 255, 255, 0.95);
	-webkit-backdrop-filter: blur(16px) saturate(170%);
	backdrop-filter: blur(16px) saturate(170%);
	border-top: 1px solid rgba(15, 23, 42, 0.06);
	box-shadow: 0 -10px 30px rgba(15, 23, 42, 0.12), 0 -2px 8px rgba(15, 23, 42, 0.05);
	transform: translateY(110%);
	opacity: 0;
	transition: transform 0.34s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.28s ease;
}
.fmpx-sticky.fmpx-sticky--show { transform: translateY(0); opacity: 1; }
.fmpx-sticky__img { width: 38px !important; height: 38px !important; object-fit: cover; border-radius: 9px; flex-shrink: 0; border: 1px solid var(--fmpx-border); }
.fmpx-sticky__info { display: flex; flex-direction: column; gap: 1px; min-width: 0; flex: 1; }
.fmpx-sticky__name {
	font-family: var(--fmpx-font);
	font-size: 0.74rem;
	font-weight: 600;
	letter-spacing: 0.005em;
	color: var(--fmpx-text);
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
	max-width: 100%;
}
.fmpx-sticky__price, .fmpx-sticky__price * { font-family: var(--fmpx-font); font-size: 0.88rem; font-weight: 800; letter-spacing: -0.01em; color: var(--fmpx-accent) !important; }
.fmpx-sticky__price del, .fmpx-sticky__price del * { display: none; }
.fmpx-sticky__btn {
	flex-shrink: 0;
	border: none;
	border-radius: var(--fmpx-pill);
	padding: 11px 18px;
	font-family: var(--fmpx-font);
	font-size: 0.8rem;
	font-weight: 700;
	letter-spacing: 0.01em;
	color: #fff;
	background: linear-gradient(135deg, var(--fmpx-accent), color-mix(in srgb, var(--fmpx-accent) 78%, #000));
	box-shadow: 0 6px 16px color-mix(in srgb, var(--fmpx-accent) 34%, transparent);
	cursor: pointer;
	transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.fmpx-sticky__btn:active { transform: scale(0.97); }
@media (min-width: 900px) { .fmpx-sticky { display: none; } }

/* ---------------- Auto-formatted description headings ---------------- */
body.fmpx-on .fmpx-desc-heading {
	font-family: var(--fmpx-font);
	font-size: calc(1.18rem * var(--fmpx-scale, 1)) !important;
	font-weight: 800 !important;
	color: #111111 !important;
	letter-spacing: -0.01em;
	line-height: 1.3;
	margin: 30px 0 14px !important;
	padding: 0 0 10px !important;
	position: relative;
}
body.fmpx-on .fmpx-desc-heading:first-child { margin-top: 0 !important; }
body.fmpx-on .fmpx-desc-heading::after {
	content: "";
	position: absolute;
	left: 0;
	bottom: 0;
	width: 44px;
	height: 3px;
	border-radius: 3px;
	background: linear-gradient(90deg, var(--fmpx-accent), color-mix(in srgb, var(--fmpx-accent) 20%, transparent));
}

/* ---------------- Add-to-cart toast ---------------- */
/* The default WooCommerce success notice is replaced by the toast. */
body.fmpx-toast-on.single-product .woocommerce-message { display: none !important; }
.fmpx-toasts {
	position: fixed;
	/* --fmpx-top-offset lets a sticky-header setup push toasts below the
	 * header if desired (set it on :root from the theme/customizer). */
	top: calc(16px + var(--fmpx-top-offset, 0px));
	right: 16px;
	z-index: 999995;
	display: flex;
	flex-direction: column;
	gap: 10px;
	max-width: min(380px, calc(100vw - 32px));
	width: 100%;
	pointer-events: none;
}
.fmpx-toast {
	pointer-events: auto;
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 13px 14px;
	background: rgba(255, 255, 255, 0.96);
	-webkit-backdrop-filter: blur(14px) saturate(160%);
	backdrop-filter: blur(14px) saturate(160%);
	border: 1px solid var(--fmpx-border);
	border-left: 4px solid var(--fmpx-success);
	border-radius: 14px;
	box-shadow: 0 16px 40px rgba(15, 23, 42, 0.18), 0 4px 12px rgba(15, 23, 42, 0.08);
	font-family: var(--fmpx-font);
	transform: translateX(calc(100% + 24px));
	opacity: 0;
	transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.3s ease;
}
.fmpx-toast--in { transform: translateX(0); opacity: 1; }
.fmpx-toast--out { transform: translateX(calc(100% + 24px)); opacity: 0; }
.fmpx-toast__icon { flex-shrink: 0; width: 26px; height: 26px; color: var(--fmpx-success); }
.fmpx-toast__icon .fmpx-icon { width: 100%; height: 100%; }
.fmpx-toast__body { min-width: 0; flex: 1; display: flex; flex-direction: column; gap: 6px; }
.fmpx-toast__title { font-size: 0.72rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; color: var(--fmpx-success); }
.fmpx-toast__name {
	font-size: 0.84rem;
	font-weight: 700;
	color: var(--fmpx-primary);
	overflow: hidden;
	text-overflow: ellipsis;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	line-height: 1.3;
}
.fmpx-toast__actions { display: flex; gap: 8px; }
.fmpx-toast__btn {
	display: inline-flex;
	align-items: center;
	padding: 7px 14px;
	border-radius: var(--fmpx-pill);
	font-size: 0.72rem;
	font-weight: 700;
	text-decoration: none !important;
	transition: filter 0.15s ease, background 0.15s ease;
}
.fmpx-toast__btn--cart { background: var(--fmpx-accent); color: #fff !important; }
.fmpx-toast__btn--cart:hover { filter: brightness(1.08); }
.fmpx-toast__btn--checkout { background: var(--fmpx-bg-light); border: 1px solid var(--fmpx-border); color: var(--fmpx-primary) !important; }
.fmpx-toast__btn--checkout:hover { background: var(--fmpx-border); }
.fmpx-toast__close {
	appearance: none;
	border: 0;
	background: none;
	align-self: flex-start;
	padding: 2px;
	color: var(--fmpx-text-secondary);
	font-size: 15px;
	line-height: 1;
	cursor: pointer;
}
body.admin-bar .fmpx-toasts { top: calc(48px + var(--fmpx-top-offset, 0px)); }
@media (max-width: 520px) {
	.fmpx-toasts { top: calc(12px + var(--fmpx-top-offset, 0px)); right: 12px; left: 12px; max-width: none; }
	.fmpx-toast { transform: translateY(-140%); }
	.fmpx-toast--in { transform: translateY(0); }
	.fmpx-toast--out { transform: translateY(-140%); }
}

/* ---------------- Entrance animations ---------------- */
body.fmpx-animate .fmpx-reveal { opacity: 0; transform: translateY(14px); transition: opacity 0.5s ease, transform 0.5s cubic-bezier(0.22, 1, 0.36, 1); }
/* End state is transform: NONE (not translateY(0)) and the JS strips the
 * classes after the transition — a lingering transform would turn these
 * sections into containing blocks and break any position:sticky element
 * the theme places inside them (e.g. Kadence sticky options). */
body.fmpx-animate .fmpx-reveal.fmpx-reveal--in { opacity: 1; transform: none; }

/* ---------------- Mobile spacing (migrated) ---------------- */
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
	html { scroll-behavior: auto; }
	body.fmpx-animate .fmpx-reveal { opacity: 1; transform: none; transition: none; }
	body.fmpx-tabs.fmpx-animate .woocommerce-Tabs-panel.fmpx-panel-in { animation: none; }
	.fmpx-sticky { transition: none; }
}
@media (max-width: 782px) {
	body.fmpx-on .woocommerce-product-gallery { margin-bottom: 0 !important; }
	body.fmpx-on .fmpx-info-card { margin-bottom: 4px; }
	body.fmpx-on .woocommerce-tabs.wc-tabs-wrapper, body.fmpx-on .woocommerce-tabs { margin-top: 24px; }
	body.fmpx-on .related.products, body.fmpx-on .upsells.products { margin-top: 28px; }
}
@media (pointer: coarse) {
	body.fmpx-on .fmpx-qty-btn { width: 38px; height: 38px; }
	body.fmpx-tabs ul.tabs.wc-tabs li a { padding: 13px 20px; }
	body.fmpx-on .product_meta a { padding: 8px 16px; }
}

/* Brief loading state on Add to Cart while the AJAX request is in
 * flight — no layout change, just a subtle visual cue. */
body.fmpx-on .fmpx-actions button.fmpx-loading { opacity: 0.7; pointer-events: none; }
