/* Compliance values intentionally use the theme's normal text color instead of
 * inheriting the visual emphasis of the main WooCommerce price. */
.wm-price-compliance {
	color: inherit;
}

.wm-price-compliance .woocommerce-Price-amount,
.wm-price-compliance .amount,
.wm-price-compliance .woocommerce-Price-currencySymbol {
	color: inherit !important;
}

/* Catalog/shop: WooCommerce renders this immediately after the main price. */
.wm-price-compliance.wm-loop {
	display: block;
	font-size: 0.7em;
	line-height: 1.4;
	margin-top: 0.35em;
	font-weight: 400;
}

.wm-price-compliance.wm-loop .wm-lowest-slot,
.wm-price-compliance.wm-loop .wm-anchor-slot,
.wm-price-compliance.wm-loop .wm-lowest-price,
.wm-price-compliance.wm-loop .wm-reference-price {
	display: block;
}

/* Prevent themes from re-applying the main price typography to nested amounts. */
.wm-price-compliance.wm-loop .woocommerce-Price-amount,
.wm-price-compliance.wm-loop .amount {
	font-size: inherit !important;
	line-height: inherit;
}

/* Tooltip shown on hover/focus of the whole compliance block (no icon). */
.wm-price-compliance.wm-has-tooltip {
	position: relative;
	cursor: help;
}

.wm-price-compliance .wm-tooltip {
	position: absolute;
	left: 0;
	bottom: 100%;
	z-index: 20;
	display: block;
	visibility: hidden;
	opacity: 0;
	transition: opacity 0.12s ease-in-out;
	max-width: 320px;
	width: max-content;
	margin-bottom: 6px;
	padding: 8px 10px;
	border-radius: 6px;
	background: #20252c;
	color: #fff;
	font-size: 12px;
	line-height: 1.4;
	font-weight: 400;
	box-shadow: 0 4px 14px rgba(0, 0, 0, 0.18);
	pointer-events: none;
	white-space: normal;
}

.wm-price-compliance.wm-has-tooltip:hover .wm-tooltip,
.wm-price-compliance.wm-has-tooltip:focus .wm-tooltip,
.wm-price-compliance.wm-has-tooltip:focus-within .wm-tooltip {
	visibility: visible;
	opacity: 1;
}

@media (max-width: 782px) {
	.wm-price-compliance .wm-tooltip {
		max-width: 240px;
	}
}
