/**
 * Revita: WooCommerce global layer (owner D).
 *
 * Enqueued on every front-end page and in the editor by inc/woocommerce.php.
 * Maps WooCommerce variables to theme tokens and styles pieces shared by
 * several shop views: bands, kicker, trust row, prices, sale badge, component
 * buttons, fields, chips, quantity stepper and notices. The block files in
 * assets/css/blocks/woocommerce-*.css rely on the variables defined here.
 *
 * @package Revita
 */

/* Token bridge */
body {
	--wc-primary: var(--wp--preset--color--primary);
	--wc-primary-text: var(--wp--preset--color--base);
	--wc-secondary: var(--wp--preset--color--lavender);
	--wc-secondary-text: var(--wp--preset--color--primary-deep);
	--wc-green: var(--wp--preset--color--success);
	--wc-red: var(--wp--preset--color--rose);
	--wc-subtext: var(--wp--preset--color--muted);
	--wc-form-border-color: var(--revita-wc-field);
	--wc-form-border-radius: var(--wp--custom--radius--sm);
	--wc-form-border-width: 1.5px;
	--wc-card-border-radius: var(--wp--custom--radius--lg);
	--wc-separator-color: var(--wp--preset--color--border);
	/* Field outline, 3.2:1 on white (WCAG 1.4.11). */
	--revita-wc-field: color-mix(in srgb, var(--wp--preset--color--primary) 70%, var(--wp--preset--color--base));
	/* Light-surface focus ring, kept for older rules and child themes. Shop controls use the
	 * theme ring instead (the Focus section below), which follows the surface. */
	--revita-wc-focus: 2px solid var(--wp--preset--color--primary-deep);
	--revita-wc-hex: url(../images/hexagon.svg) center / contain no-repeat;
}

/* Bands (shop archive, cart) */
.revita-wc-band {
	position: relative;
	overflow: hidden;
	isolation: isolate;
	border-end-start-radius: var(--wp--custom--radius--xl);
	border-end-end-radius: var(--wp--custom--radius--xl);
}

.revita-wc-band::after {
	content: "";
	position: absolute;
	inset-block-start: 50%;
	inset-inline-end: 3%;
	width: clamp(140px, 20vw, 280px);
	aspect-ratio: 100 / 86.6;
	background: var(--wp--preset--gradient--honey);
	-webkit-mask: var(--revita-wc-hex);
	mask: var(--revita-wc-hex);
	opacity: 0.2;
	transform: translateY(-50%) rotate(-8deg);
	pointer-events: none;
}

.revita-wc-band__inner { position: relative; z-index: 1; gap: var(--wp--preset--spacing--30); }
.revita-wc-band__inner > *, .revita-wc-band__heading > * { margin-block: 0; }
.revita-wc-band__inner.is-layout-flow > * + *, .revita-wc-band__heading > * + * { margin-block-start: var(--wp--preset--spacing--20); }
.revita-wc-band__title { font-size: var(--wp--preset--font-size--xx-large); line-height: 1.05; letter-spacing: -0.02em; }
.revita-wc-band--compact .revita-wc-band__title { font-size: var(--wp--preset--font-size--x-large); }
.revita-wc-band__lead { max-width: 62ch; color: var(--wp--preset--color--muted); }

.revita-wc-kicker {
	display: inline-flex;
	align-items: center;
	gap: 0.55em;
	color: var(--wp--preset--color--primary);
	font: 600 var(--wp--preset--font-size--x-small) / 1.4 var(--wp--preset--font-family--heading);
	letter-spacing: 0.14em;
	text-transform: uppercase;
}

.revita-wc-kicker::before {
	content: "";
	width: 1em;
	aspect-ratio: 100 / 86.6;
	background: var(--wp--preset--color--accent-deep);
	-webkit-mask: var(--revita-wc-hex);
	mask: var(--revita-wc-hex);
}

/* Trust row (pattern revita/product-trust-row) */
.revita-trust-row {
	display: flex;
	flex-wrap: wrap;
	gap: var(--wp--preset--spacing--20);
	margin: 0;
	padding: 0;
	list-style: none;
	font-size: var(--wp--preset--font-size--small);
	line-height: 1.3;
}

.revita-trust-row__item {
	--revita-icon-mask: url(../images/icons/truck.svg);
	position: relative;
	display: inline-flex;
	align-items: center;
	gap: 0.6em;
	margin: 0;
	padding: 0.35em 1em 0.35em 0.4em;
	border: 1px solid var(--wp--preset--color--border);
	border-radius: var(--wp--custom--radius--pill);
	background: var(--wp--preset--color--base);
	color: var(--wp--preset--color--primary-deep);
	font-weight: 600;
}

.revita-trust-row__item::before { content: ""; width: 2em; height: 2em; border-radius: 50%; background: var(--wp--preset--color--lavender); }

.revita-trust-row__item::after {
	content: "";
	position: absolute;
	inset-block-start: calc(50% - 0.55em);
	inset-inline-start: 0.85em;
	width: 1.1em;
	height: 1.1em;
	background: var(--wp--preset--color--primary);
	-webkit-mask: var(--revita-icon-mask) center / contain no-repeat;
	mask: var(--revita-icon-mask) center / contain no-repeat;
}

.revita-trust-row__item--cash { --revita-icon-mask: url(../images/icons/cash.svg); }
.revita-trust-row__item--leaf { --revita-icon-mask: url(../images/icons/leaf.svg); }
/* Product claims in the descriptions (cutover step 40): the "free from" claims get a shield, "Природна арома" keeps the leaf. Two classes, so it wins in any order. */
.revita-trust-row__item.revita-trust-row__item--free { --revita-icon-mask: url(../images/icons/shield-check.svg); }

/* Product page: health articles (pattern revita/hidden-product-articles). The section matches
 * "You may also like" above it; the cards are the article pages' cards (parts/post-card.css). */
.wp-block-group.revita-product-articles { margin-block-start: var(--wp--preset--spacing--70); }
.revita-product-articles .revita-product-articles__title { margin-block: 0 var(--wp--preset--spacing--40); font-size: var(--wp--preset--font-size--x-large); }
.revita-product-articles .wp-block-query { margin-block: 0; }

/* Never two cards over one (the core grid gives two columns from 600 to 1023px): large phones,
 * small tablets and phones held sideways keep the phones' compact rows (post-card.css), one card
 * per row with a larger hexagon, and every card fits a short screen; tablets show three across. */
@media (min-width: 600px) and (max-width: 767.98px), (min-width: 600px) and (max-width: 1023.98px) and (max-height: 500px) {
	.revita-product-articles .revita-product-articles__grid.wp-block-post-template { grid-template-columns: minmax(0, 1fr); }

	.revita-product-articles .revita-product-articles__grid .revita-service-card {
		display: grid;
		grid-template-columns: 7.5rem minmax(0, 1fr);
		grid-template-areas:
			"media title"
			"media excerpt"
			"media more";
		align-content: center;
		align-items: center;
		column-gap: var(--wp--preset--spacing--40);
		row-gap: var(--wp--preset--spacing--10);
		padding: var(--wp--preset--spacing--30) var(--wp--preset--spacing--40);
		text-align: start;
	}

	.revita-product-articles .revita-product-articles__grid .revita-service-card .revita-service-card__media { grid-area: media; align-self: center; inline-size: 7.5rem; margin: 0; }
	.revita-product-articles .revita-product-articles__grid .revita-service-card .revita-service-card__title { grid-area: title; text-align: start; }
	.revita-product-articles .revita-product-articles__grid .revita-service-card .revita-service-card__excerpt { grid-area: excerpt; text-align: start; }
	.revita-product-articles .revita-product-articles__grid .revita-service-card .revita-service-card__excerpt p { display: -webkit-box; overflow: hidden; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2; }
	.revita-product-articles .revita-product-articles__grid .revita-service-card .revita-service-card__more { grid-area: more; justify-self: start; min-block-size: 2.75rem; padding-block-start: 0; }
}

@media (min-width: 768px) and (max-width: 1023.98px) and (min-height: 500.02px) {
	.revita-product-articles .revita-product-articles__grid.wp-block-post-template { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

/* Prices, sale badge, rating */
body .wc-block-components-product-price { color: var(--wp--preset--color--primary); font-family: var(--wp--preset--font-family--heading); font-weight: 700; font-variant-numeric: tabular-nums; }
body .wc-block-components-product-price :is(del, .wc-block-components-product-price__regular) { color: var(--wp--preset--color--muted); font-size: 0.72em; font-weight: 500; }
body .wc-block-components-product-price :is(ins, .is-discounted) { color: var(--wp--preset--color--rose); text-decoration: none; }
.wc-block-components-product-rating__stars { color: var(--wp--preset--color--accent-deep); }

body .wc-block-components-product-sale-badge,
body.woocommerce span.onsale {
	padding: 0.4em 0.9em;
	border: 0;
	border-radius: var(--wp--custom--radius--pill);
	background: var(--wp--preset--color--rose);
	color: var(--wp--preset--color--base);
	font: 700 var(--wp--preset--font-size--x-small) / 1.2 var(--wp--preset--font-family--heading);
	letter-spacing: 0.06em;
	text-transform: uppercase;
	box-shadow: 0 8px 18px -8px var(--wp--preset--color--rose);
}

/* Component buttons (cart, checkout, mini-cart); fill colours come from the button element. */
body .wc-block-components-button:not(.is-link) { border-radius: var(--wp--custom--radius--pill); font-family: var(--wp--preset--font-family--heading); font-weight: 600; }
body .wc-block-components-button:not(.is-link):focus { box-shadow: none; }
body .wc-block-components-button:not(.is-link):is(.outlined, .is-style-outline) { background: transparent; color: var(--wp--preset--color--primary-deep); box-shadow: inset 0 0 0 2px currentColor; }
body .wc-block-components-button:not(.is-link):is(.outlined, .is-style-outline):hover { background: var(--wp--preset--color--lavender); }

/* WooCommerce fills outline buttons ("View cart" in the mini-cart) near-black (#1e1e1e) on hover,
 * focus and press, with a more specific rule. They keep the theme look instead: their 1px border,
 * lavender on hover and press, unchanged with focus (keyboard focus adds the ring, see Focus). */
body .wc-block-components-button:not(.is-link):is(.outlined, .is-style-outline):not(:disabled):not([aria-disabled="true"]):is(:focus, :hover, :active) {
	background-color: transparent;
	color: var(--wp--preset--color--primary-deep);
	box-shadow: inset 0 0 0 1px currentColor;
}

body .wc-block-components-button:not(.is-link):is(.outlined, .is-style-outline):not(:disabled):not([aria-disabled="true"]):is(:hover, :active) { background-color: var(--wp--preset--color--lavender); }

/* Fields (block cart and checkout) */
body .wc-block-components-text-input.wc-block-components-text-input input:is([type="text"], [type="email"], [type="tel"], [type="url"], [type="number"], [type="password"]),
body .wc-block-components-textarea.wc-block-components-textarea,
body .wc-blocks-components-select .wc-blocks-components-select__select.wc-blocks-components-select__select {
	border: 1.5px solid var(--revita-wc-field);
	border-radius: var(--wp--custom--radius--sm);
	background-color: var(--wp--preset--color--base);
	color: var(--wp--preset--color--contrast);
}

/* A focused field: the theme ring (see Focus below) around a Deep Purple border. Also the classic
 * forms (My account: login, register, addresses, account details). */
body .wc-block-components-text-input.wc-block-components-text-input input:is([type="text"], [type="email"], [type="tel"], [type="url"], [type="number"], [type="password"]):focus,
body .wc-block-components-textarea.wc-block-components-textarea:focus,
body .wc-blocks-components-select .wc-blocks-components-select__select.wc-blocks-components-select__select:focus,
:root :is(.woocommerce, .woocommerce-page) form .form-row :is(input.input-text, textarea.input-text, select):focus {
	border-color: var(--wp--preset--color--primary-deep);
	outline: 2px solid var(--revita-focus, var(--wp--preset--color--primary-deep));
	outline-offset: 3px;
	box-shadow: 0 0 0 3px var(--revita-focus-ring, var(--wp--preset--color--base));
}

/* Floating labels (checkout, the cart's coupon and shipping forms): WooCommerce shrinks the label
 * of a filled, focused or autofilled field to 82% (13.1px) and sets the country label at 13px, both
 * under the 14px minimum for readable text. They float at 14px (16px x 0.875) and 1px higher, so
 * their descenders keep 3-4px from the value typed below them in the 50px field. */
body .wc-block-components-text-input.wc-block-components-text-input.is-active label,
body .wc-block-components-text-input.wc-block-components-text-input input:-webkit-autofill + label {
	inset-block-start: 5px;
	transform: scale(0.875);
}

body .wc-blocks-components-select .wc-blocks-components-select__label.wc-blocks-components-select__label {
	inset-block-start: 5px;
	font-size: 0.875rem;
}

body .wc-block-components-checkbox .wc-block-components-checkbox__input[type="checkbox"],
body .wc-block-components-radio-control .wc-block-components-radio-control__input { border: 1.5px solid var(--revita-wc-field); }
body .wc-block-components-checkbox .wc-block-components-checkbox__input[type="checkbox"] { border-radius: var(--wp--custom--radius--xs); }
body .wc-block-components-checkbox .wc-block-components-checkbox__input[type="checkbox"]:checked { border-color: var(--wp--preset--color--primary); background: var(--wp--preset--color--primary); }
body .wc-block-components-checkbox .wc-block-components-checkbox__mark { fill: var(--wp--preset--color--base); }
body .wc-block-components-radio-control .wc-block-components-radio-control__input:checked { border-color: var(--wp--preset--color--primary); }
body .wc-block-components-radio-control .wc-block-components-radio-control__input:checked::before { background: var(--wp--preset--color--primary); }

/* Chips (variation selector and chip-style filters) */
.wp-block-woocommerce-product-filter-chips {
	--wc-product-filter-chips-selected-background: var(--wp--preset--color--primary);
	--wc-product-filter-chips-selected-border: var(--wp--preset--color--primary);
	--wc-product-filter-chips-selected-text: var(--wp--preset--color--base);
	font-size: var(--wp--preset--font-size--small);
}

.wp-block-woocommerce-product-filter-chips .wc-block-product-filter-chips__items { gap: 0.5rem; }

.wp-block-woocommerce-product-filter-chips:not(.is-style-swatch) .wc-block-product-filter-chips__item {
	min-height: 2.5rem;
	padding: 0.5em 1.15em;
	border: 1.5px solid var(--wp--preset--color--lavender-strong);
	border-radius: var(--wp--custom--radius--pill);
	background: var(--wp--preset--color--base);
	color: var(--wp--preset--color--primary-deep);
	font-weight: 600;
}

.wp-block-woocommerce-product-filter-chips:not(.is-style-swatch) .wc-block-product-filter-chips__item[aria-checked="true"] {
	border-color: var(--wp--preset--color--primary);
	background: var(--wp--preset--color--primary);
	color: var(--wp--preset--color--base);
	box-shadow: 0 6px 16px -8px var(--wp--preset--color--primary);
}

/* Hover only where a real pointer hovers: touch browsers keep :hover on the last tapped chip,
 * and a lavender hover under the selected chip's white text was unreadable. */
@media (hover: hover) {
	.wp-block-woocommerce-product-filter-chips:not(.is-style-swatch) .wc-block-product-filter-chips__item:hover:not(:disabled):not([aria-checked="true"]) { border-color: var(--wp--preset--color--primary); background: var(--wp--preset--color--lavender); }
	.wp-block-woocommerce-product-filter-chips:not(.is-style-swatch) .wc-block-product-filter-chips__item[aria-checked="true"]:hover { border-color: var(--wp--preset--color--primary-deep); background: var(--wp--preset--color--primary-deep); }
}

.wp-block-woocommerce-product-filter-chips .wc-block-product-filter-chips__item:focus { outline: 0; }

/* Quantity stepper (product page, cart, mini-cart) */
body .wc-block-components-quantity-selector:has(input:not([type="hidden"])) {
	display: inline-flex;
	align-items: center;
	gap: 0.25rem;
	width: auto;
	min-width: 0;
	padding: 0.25rem;
	border: 1.5px solid var(--revita-wc-field);
	border-radius: var(--wp--custom--radius--pill);
	background: var(--wp--preset--color--base);
}

/* Typing a quantity rings the whole stepper (the number field has no border of its own); − and +
 * ring themselves (Focus below). The selector repeats the one above, so it wins over it. */
body .wc-block-components-quantity-selector:has(input:not([type="hidden"])):has(input:focus) {
	border-color: var(--wp--preset--color--primary-deep);
	outline: 2px solid var(--revita-focus, var(--wp--preset--color--primary-deep));
	outline-offset: 3px;
	box-shadow: 0 0 0 3px var(--revita-focus-ring, var(--wp--preset--color--base));
}

body .wc-block-components-quantity-selector .wc-block-components-quantity-selector__button {
	display: grid;
	place-items: center;
	width: 2.25rem;
	min-width: 0;
	height: 2.25rem;
	padding: 0;
	border-radius: 50%;
	background: var(--wp--preset--color--lavender);
	color: var(--wp--preset--color--primary-deep);
	font-size: 1.15rem;
	font-weight: 600;
	opacity: 1;
}

body .wc-block-components-quantity-selector .wc-block-components-quantity-selector__button:hover:not(:disabled) { background: var(--wp--preset--color--primary); color: var(--wp--preset--color--base); }
body .wc-block-components-quantity-selector .wc-block-components-quantity-selector__button:disabled { opacity: 0.45; }
body .wc-block-components-quantity-selector :is(.wc-block-components-quantity-selector__button, input):focus { box-shadow: none; }
/* At least 16px, so iOS Safari does not zoom the page when the field gets focus. */
body .wc-block-components-quantity-selector input.wc-block-components-quantity-selector__input { flex: 0 1 2.75rem; width: 2.75rem; min-width: 2rem; height: 2.25rem; padding: 0; color: var(--wp--preset--color--primary-deep); font-size: max(1rem, 1em); font-weight: 700; }

/* Touch: 44px steppers and chips, and 44px rows for the one-line text controls of the cart and
 * checkout ("Add coupons", "+ Add apartment, suite…", "Log in"), which were 20px tall. */
@media (max-width: 781px), (pointer: coarse) {
	.wp-block-woocommerce-product-filter-chips:not(.is-style-swatch) .wc-block-product-filter-chips__item { min-height: 2.75rem; }
	body .wc-block-components-quantity-selector:has(input:not([type="hidden"])) { padding: 0.125rem; }
	body .wc-block-components-quantity-selector .wc-block-components-quantity-selector__button { width: 2.75rem; height: 2.75rem; }
	body .wc-block-components-quantity-selector input.wc-block-components-quantity-selector__input { height: 2.75rem; }
	body .wc-block-components-totals-coupon .wc-block-components-panel__button { display: flex; align-items: center; min-block-size: 2.75rem; }
	body :is(.wc-block-components-address-form__address_2-toggle, .wc-block-checkout__login-prompt) { display: inline-flex; align-items: center; min-block-size: 2.75rem; }
}

/* My account and other classic WooCommerce forms (login, register, lost password). */
body .woocommerce :is(form.login, form.register, form.lost_reset_password) {
	margin-block: var(--wp--preset--spacing--40) 0;
	padding: var(--wp--preset--spacing--50);
	border: 1px solid var(--wp--preset--color--border);
	border-radius: var(--wp--custom--radius--lg);
	background: var(--wp--preset--color--base);
	box-shadow: var(--wp--preset--shadow--soft);
}

/* The privacy link inside the registration note: a little room before it, so its focus ring does
 * not run into the word before it (a full stop follows it). */
body .woocommerce .woocommerce-privacy-policy-text a { margin-inline-start: 0.15em; }

/* 16px text entry everywhere (WooCommerce's block-theme CSS sets the small size; iOS zooms under 16px). */
:root :is(.woocommerce, .woocommerce-page) form .form-row :is(input.input-text, textarea.input-text, select) { font-size: max(1rem, 1em); }

/* "Show password": a 44px target at the end of the field, instead of a 22px icon inside it. */
body .woocommerce form .password-input input.input-text { padding-inline-end: 3rem; }

body .woocommerce form .show-password-input {
	display: grid;
	place-items: center;
	inset-inline-end: 0.125rem;
	inline-size: 2.75rem;
	block-size: 2.75rem;
	border-radius: var(--wp--custom--radius--sm);
}

/* Inside the field (white), so the ring is drawn inside the button. */
body .woocommerce form .show-password-input:focus-visible { outline: 2px solid var(--revita-focus, var(--wp--preset--color--primary-deep)); outline-offset: -4px; box-shadow: none; }

/* Shared checkbox (account "Remember me", Contact Form 7 consent): the theme look used by the shop
 * filters, 24px (WCAG 2.5.8). */
:is(.woocommerce-form__input-checkbox, .wpcf7-acceptance input, .wpcf7-checkbox input)[type="checkbox"] {
	display: inline-grid;
	place-content: center;
	flex: none;
	inline-size: 1.5rem;
	block-size: 1.5rem;
	margin-block: 0;
	margin-inline: 0 0.5em;
	border: 1.5px solid var(--revita-wc-field);
	border-radius: var(--wp--custom--radius--xs);
	background: var(--wp--preset--color--base);
	vertical-align: -0.25em;
	cursor: pointer;
	-webkit-appearance: none;
	appearance: none;
}

:is(.woocommerce-form__input-checkbox, .wpcf7-acceptance input, .wpcf7-checkbox input)[type="checkbox"]::before {
	content: "";
	inline-size: 1rem;
	block-size: 1rem;
	background: var(--wp--preset--color--base);
	-webkit-mask: url(../images/icons/check.svg) center / contain no-repeat;
	mask: url(../images/icons/check.svg) center / contain no-repeat;
	transform: scale(0);
}

:is(.woocommerce-form__input-checkbox, .wpcf7-acceptance input, .wpcf7-checkbox input)[type="checkbox"]:checked { border-color: var(--wp--preset--color--primary); background: var(--wp--preset--color--primary); }
:is(.woocommerce-form__input-checkbox, .wpcf7-acceptance input, .wpcf7-checkbox input)[type="checkbox"]:checked::before { transform: scale(1); }
:is(.woocommerce-form__input-checkbox, .wpcf7-acceptance input, .wpcf7-checkbox input)[type="checkbox"]:focus-visible {
	outline: 2px solid var(--revita-focus, var(--wp--preset--color--primary-deep));
	outline-offset: 3px;
	box-shadow: 0 0 0 3px var(--revita-focus-ring, var(--wp--preset--color--base));
}

/* "Remember me" (My account login): the box and its words centred on one line beside "Log in", as
 * tall as the button, so the whole label is a 44px target (it ticks the box too). */
body .woocommerce form.login .woocommerce-form-login__rememberme {
	display: inline-flex;
	align-items: center;
	min-block-size: 2.75rem;
	vertical-align: middle;
	cursor: pointer;
}

/* Notices */
body .wc-block-components-notice-banner {
	--revita-notice: var(--wp--preset--color--primary);
	gap: 0.85rem;
	padding: 0.9rem 1.1rem !important;
	border: 1px solid color-mix(in srgb, var(--revita-notice) 30%, var(--wp--preset--color--base));
	border-inline-start: 4px solid var(--revita-notice);
	border-radius: var(--wp--custom--radius--md);
	background: color-mix(in srgb, var(--revita-notice) 7%, var(--wp--preset--color--base));
	color: var(--wp--preset--color--contrast);
	font-size: var(--wp--preset--font-size--small);
	box-shadow: var(--wp--preset--shadow--soft);
}

body .wc-block-components-notice-banner > svg { background-color: var(--revita-notice); }
body .wc-block-components-notice-banner.is-success { --revita-notice: var(--wp--preset--color--success); }
body .wc-block-components-notice-banner.is-error { --revita-notice: var(--wp--preset--color--rose); }
body .wc-block-components-notice-banner.is-warning { --revita-notice: var(--wp--preset--color--accent-deep); }
body .wc-block-components-notice-banner > .wc-block-components-notice-banner__content .wc-forward { color: var(--wp--preset--color--primary-deep) !important; font-weight: 600; opacity: 1; }

/* The notice's link ("View cart" after adding a product through a link): 24px tall (WCAG 2.5.8).
 * On touch screens it is a 44px target on its own line under the message, at the end, instead of
 * floating beside the message's last line, where its focus ring ran into the line above. */
body .wc-block-components-notice-banner > .wc-block-components-notice-banner__content .wc-forward { display: inline-flex; align-items: center; min-block-size: 1.5rem; }

@media (max-width: 781px), (pointer: coarse) {
	body .wc-block-components-notice-banner > .wc-block-components-notice-banner__content .wc-forward {
		display: flex;
		float: none;
		inline-size: fit-content;
		min-block-size: 2.75rem;
		margin-block: 0.25rem 0;
		margin-inline: auto 0;
	}
}

/* Focus: the theme ring (global.css, section 4) on every WooCommerce control. A 2px ring 3px out,
 * with a 3px band of the surface's contrasting colour (white on light surfaces) between ring and
 * control, so the ring stands out from both by 3:1 or more. WooCommerce's own focus rules are more
 * specific (its checkbox and radio also set a 1-1.5px outline and offset), hence !important. The
 * mini-cart's close button draws its ring inside itself (woocommerce-mini-cart.css). */
body .wc-block-components-button:not(.is-link):not(.wc-block-components-drawer__close):focus-visible,
body .wc-block-components-checkbox .wc-block-components-checkbox__input[type="checkbox"]:focus-visible,
body .wc-block-components-radio-control .wc-block-components-radio-control__input:focus-visible,
body .wc-block-components-quantity-selector .wc-block-components-quantity-selector__button:focus-visible,
body .wc-block-product-filter-chips .wc-block-product-filter-chips__item:focus-visible,
body .wc-block-components-notice-banner :is(a, button):focus-visible {
	outline: 2px solid var(--revita-focus, var(--wp--preset--color--primary-deep)) !important;
	outline-offset: 3px !important;
	box-shadow: 0 0 0 3px var(--revita-focus-ring, var(--wp--preset--color--base)) !important;
}

/* Outline buttons ("View cart") draw their border with an inset shadow, which stays under the band. */
body .wc-block-components-button:not(.is-link):not(.wc-block-components-drawer__close):is(.outlined, .is-style-outline):focus-visible {
	box-shadow: inset 0 0 0 1px currentColor, 0 0 0 3px var(--revita-focus-ring, var(--wp--preset--color--base)) !important;
}

/* Motion */
@keyframes revita-wc-drift {
	to { transform: translateY(-58%) rotate(-2deg); }
}

@media (prefers-reduced-motion: no-preference) {
	body:not(.revita-motion-off):not(.revita-motion-subtle) .revita-wc-band::after { animation: revita-wc-drift 9s var(--wp--custom--motion--easing--honey) infinite alternate; }
	body:not(.revita-motion-off) .wc-block-components-button:not(.is-link):not(:disabled) { transition: transform var(--wp--custom--motion--duration--fast) var(--wp--custom--motion--easing--honey); }
	body:not(.revita-motion-off) .wc-block-components-button:not(.is-link):not(:disabled):hover { transform: translateY(-1px); }
	body:not(.revita-motion-off) :is(.woocommerce-form__input-checkbox, .wpcf7-acceptance input, .wpcf7-checkbox input)[type="checkbox"]::before { transition: transform var(--wp--custom--motion--duration--fast) var(--wp--custom--motion--easing--bounce); }
}
