/* 1.8.524 — Shop-card Customize + glassware-style Add to cart / Customize.
   Values reused from .idx-eo__face / .idx-eo__name (engrave-options.css):
   navy #0f143a, yellow #F3C91A, 2px navy border, square corners, Oswald
   600 uppercase letter-spacing .06em, padding .7rem .6rem, min-height 4.4rem,
   hover fill-swap. Card buttons use the same language at a smaller size. */

/* --------------------------------------------------------------------------
   1. Shop / category cards: side-by-side actions on designer products only
   -------------------------------------------------------------------------- */
li.product.idx-has-designer .idx-loop-actions {
	--eo-navy: #0f143a;
	--eo-yellow: #F3C91A;
	position: relative;
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
	align-items: stretch;
	margin: 0 1.05rem 1.05rem;
	box-sizing: border-box;
}
/* Woo prints a described-by span after Add to cart; keep it out of the flex row. */
li.product.idx-has-designer .idx-loop-actions > .screen-reader-text {
	position: absolute !important;
	width: 1px !important;
	height: 1px !important;
	margin: 0 !important;
	padding: 0 !important;
	overflow: hidden;
	clip: rect(1px, 1px, 1px, 1px);
	clip-path: inset(50%);
	border: 0 !important;
}
.idx-shop-archive.idx-dense:not(.idx-dense-keep-layout) .idxshop-main ul.products li.product.idx-has-designer .idx-loop-actions {
	margin: 0 0.65rem 0.65rem;
}

/* List view: the action row takes the slot the single button used to occupy. */
html.idx-dense-view-list .idx-shop-archive.idx-dense:not(.idx-dense-keep-layout) .idxshop-main ul.products li.product.idx-has-designer .idx-loop-actions {
	grid-column: 3;
	grid-row: 2;
	align-self: start;
	justify-self: stretch;
	width: 100%;
	min-width: 0;
	margin: 0;
}
@media (max-width: 699.98px) {
	html.idx-dense-view-list .idx-shop-archive.idx-dense:not(.idx-dense-keep-layout) .idxshop-main ul.products li.product.idx-has-designer .idx-loop-actions {
		grid-column: 2;
		grid-row: 4;
		justify-self: stretch;
		margin: 0.35rem 0 0;
	}
}

/* Shared face: same typography language as .idx-eo__face, scaled for cards. */
li.product.idx-has-designer .idx-loop-actions > a.button,
li.product.idx-has-designer .idx-loop-actions > .button,
li.product.idx-has-designer .idx-loop-actions > .idx-loop-customize {
	display: inline-flex !important;
	align-items: center;
	justify-content: center;
	gap: 0.35rem;
	box-sizing: border-box;
	width: 100% !important;
	max-width: none !important;
	min-width: 0 !important;
	min-height: 2.85rem;
	margin: 0 !important;
	padding: 0.45rem 0.4rem !important;
	border: 2px solid var(--eo-navy) !important;
	border-radius: 0 !important;
	font-family: "Oswald", "Montserrat", sans-serif !important;
	font-weight: 600 !important;
	font-size: 0.78rem !important;
	letter-spacing: 0.05em !important;
	line-height: 1.1 !important;
	text-transform: uppercase !important;
	text-align: center;
	text-decoration: none !important;
	white-space: nowrap;
	box-shadow: none !important;
	filter: none !important;
	overflow: hidden;
	cursor: pointer;
	transition: background-size 0.28s ease, color 0.28s ease, background-color 0.28s ease, border-color 0.28s ease !important;
}
li.product.idx-has-designer .idx-loop-actions > a.button::after,
li.product.idx-has-designer .idx-loop-actions > .button::after {
	content: "";
	flex: none;
	width: 14px;
	height: 14px;
	background: currentColor;
	-webkit-mask: url("../images/configurator-icons/cart.svg") center / contain no-repeat;
	mask: url("../images/configurator-icons/cart.svg") center / contain no-repeat;
}

/* Secondary: Add to cart / Select options — white, navy border, navy label.
   Hover swaps to navy fill + yellow text, like an unselected .idx-eo__face. */
li.product.idx-has-designer .idx-loop-actions > a.button,
li.product.idx-has-designer .idx-loop-actions > .button {
	background: #fff linear-gradient(var(--eo-navy), var(--eo-navy)) no-repeat left center / 0% 100% !important;
	color: var(--eo-navy) !important;
	-webkit-text-fill-color: var(--eo-navy);
}
li.product.idx-has-designer .idx-loop-actions > a.button:hover,
li.product.idx-has-designer .idx-loop-actions > a.button:focus-visible,
li.product.idx-has-designer .idx-loop-actions > .button:hover,
li.product.idx-has-designer .idx-loop-actions > .button:focus-visible {
	background-size: 100% 100% !important;
	color: var(--eo-yellow) !important;
	-webkit-text-fill-color: var(--eo-yellow);
	transform: none !important;
}

/* Primary: Customize — navy fill, yellow label. Hover swaps to yellow / navy. */
li.product.idx-has-designer .idx-loop-actions > .idx-loop-customize {
	background: var(--eo-navy) linear-gradient(var(--eo-yellow), var(--eo-yellow)) no-repeat left center / 0% 100% !important;
	color: var(--eo-yellow) !important;
	-webkit-text-fill-color: var(--eo-yellow);
}
li.product.idx-has-designer .idx-loop-actions > .idx-loop-customize:hover,
li.product.idx-has-designer .idx-loop-actions > .idx-loop-customize:focus-visible {
	background-size: 100% 100% !important;
	color: var(--eo-navy) !important;
	-webkit-text-fill-color: var(--eo-navy);
}
li.product.idx-has-designer .idx-loop-actions > a.button:focus-visible,
li.product.idx-has-designer .idx-loop-actions > .idx-loop-customize:focus-visible {
	outline: 3px solid var(--eo-yellow);
	outline-offset: 2px;
}

li.product.idx-has-designer .idx-loop-actions a.added_to_cart {
	flex: 1 0 100%;
	margin: 0;
	padding: 0.15rem 0 0;
	text-align: center;
	color: var(--eo-navy, #0f143a);
	font-weight: 700;
	font-size: 0.82rem;
}

li.product.idx-has-designer .idx-loop-actions > a.button,
li.product.idx-has-designer .idx-loop-actions > .button,
li.product.idx-has-designer .idx-loop-actions > .idx-loop-customize {
	flex: 1 1 calc(50% - 0.25rem);
}
li.product.idx-has-designer .idx-loop-actions > a.added_to_cart {
	flex: 1 0 100%;
}

@media (max-width: 480px) {
	li.product.idx-has-designer .idx-loop-actions > a.button,
	li.product.idx-has-designer .idx-loop-actions > .button,
	li.product.idx-has-designer .idx-loop-actions > .idx-loop-customize,
	html.idx-dense-view-list .idx-shop-archive.idx-dense:not(.idx-dense-keep-layout) .idxshop-main ul.products li.product.idx-has-designer .idx-loop-actions > a.button,
	html.idx-dense-view-list .idx-shop-archive.idx-dense:not(.idx-dense-keep-layout) .idxshop-main ul.products li.product.idx-has-designer .idx-loop-actions > .idx-loop-customize {
		flex: 1 0 100%;
	}
}

@media (prefers-reduced-motion: reduce) {
	li.product.idx-has-designer .idx-loop-actions > a.button,
	li.product.idx-has-designer .idx-loop-actions > .idx-loop-customize {
		transition: none !important;
	}
}

/* --------------------------------------------------------------------------
   2. Single product: equal-size glassware boxes for Add to cart + Customize
   -------------------------------------------------------------------------- */
body.single-product form.cart:has(.idxpd-customize-button),
body.single-product form.cart:has(.idxbvg-cta--idxpd) {
	--eo-navy: #0f143a;
	--eo-yellow: #F3C91A;
}

/* Drop the 473 stacked-gap now that the two buttons sit in one equal row. */
body.single-product:not(.idx-configurator):not(.chamevo-product) form.cart:has(.idxpd-customize-button) .single_add_to_cart_button:has(+ .idxpd-customize-button),
body.single-product:not(.idx-configurator):not(.chamevo-product) form.cart:has(.idxbvg-cta--idxpd) .single_add_to_cart_button {
	margin-bottom: 0 !important;
}

body.single-product form.cart:has(.idxpd-customize-button),
body.single-product form.cart:has(.idxbvg-cta--idxpd),
body.single-product form.cart:has(.idxpd-customize-button) .woocommerce-variation-add-to-cart,
body.single-product form.cart:has(.idxbvg-cta--idxpd) .woocommerce-variation-add-to-cart {
	display: flex !important;
	flex-wrap: wrap;
	align-items: stretch;
	gap: 0.75rem;
}

body.single-product form.cart:has(.idxpd-customize-button) .quantity,
body.single-product form.cart:has(.idxbvg-cta--idxpd) .quantity,
body.single-product form.cart:has(.idxpd-customize-button) .woocommerce-variation-add-to-cart > .quantity,
body.single-product form.cart:has(.idxbvg-cta--idxpd) .woocommerce-variation-add-to-cart > .quantity {
	float: none !important;
	clear: none !important;
	flex: 0 0 auto;
	align-self: stretch;
	margin: 0 !important;
	min-height: 4.4rem;
}

/* Shared face — exact .idx-eo__face metrics. */
body.single-product form.cart:has(.idxpd-customize-button) .single_add_to_cart_button,
body.single-product form.cart:has(.idxbvg-cta--idxpd) .single_add_to_cart_button,
body.single-product form.cart .idxpd-customize-button,
body.single-product form.cart .idxbvg-cta--idxpd,
body.single-product form.cart .idxbvg-cta--idxpd .idxbvg-signin-btn,
body.single-product form.cart .idxbvg-cta--idxpd .button {
	display: inline-flex !important;
	align-items: center;
	justify-content: center;
	gap: 0.45rem;
	box-sizing: border-box;
	float: none !important;
	clear: none !important;
	flex: 1 1 0;
	width: auto !important;
	max-width: none !important;
	min-width: 0;
	min-height: 4.4rem !important;
	height: auto !important;
	margin: 0 !important;
	padding: 0.7rem 0.6rem !important;
	border: 2px solid #0f143a !important;
	border-radius: 0 !important;
	font-family: "Oswald", "Montserrat", sans-serif !important;
	font-weight: 600 !important;
	font-size: 1.1rem !important;
	letter-spacing: 0.06em !important;
	line-height: 1.1 !important;
	text-transform: uppercase !important;
	text-align: center;
	text-decoration: none !important;
	white-space: nowrap;
	box-shadow: none !important;
	filter: none !important;
	overflow: visible;
	cursor: pointer !important;
	transition: background-size 0.28s ease, color 0.28s ease, background-color 0.28s ease !important;
}

/* Guest sign-in CTA fills the Customize slot; long label may wrap. */
body.single-product form.cart .idxbvg-cta--idxpd {
	padding: 0 !important;
	border: 0 !important;
	background: transparent !important;
	min-height: 0 !important;
	display: flex !important;
	align-items: stretch;
}
body.single-product form.cart .idxbvg-cta--idxpd .idxbvg-signin-btn,
body.single-product form.cart .idxbvg-cta--idxpd .button {
	width: 100% !important;
	white-space: normal;
	font-size: 0.95rem !important;
}

/* Secondary: Add to cart — white / navy outline. Keep the cart icon. */
body.single-product form.cart:has(.idxpd-customize-button) .single_add_to_cart_button,
body.single-product form.cart:has(.idxbvg-cta--idxpd) .single_add_to_cart_button,
body.idx-configurator div.product form.cart:has(.idxpd-customize-button) .single_add_to_cart_button,
body.idx-configurator div.product form.cart:has(.idxbvg-cta--idxpd) .single_add_to_cart_button,
body.idx-catalog-product div.product form.cart:has(.idxpd-customize-button) .single_add_to_cart_button,
body.idx-catalog-product div.product form.cart:has(.idxbvg-cta--idxpd) .single_add_to_cart_button {
	background: #fff linear-gradient(#0f143a, #0f143a) no-repeat left center / 0% 100% !important;
	color: #0f143a !important;
	-webkit-text-fill-color: #0f143a;
}
body.single-product form.cart:has(.idxpd-customize-button) .single_add_to_cart_button:hover,
body.single-product form.cart:has(.idxpd-customize-button) .single_add_to_cart_button:focus-visible,
body.single-product form.cart:has(.idxbvg-cta--idxpd) .single_add_to_cart_button:hover,
body.single-product form.cart:has(.idxbvg-cta--idxpd) .single_add_to_cart_button:focus-visible,
body.idx-configurator div.product form.cart:has(.idxpd-customize-button) .single_add_to_cart_button:hover,
body.idx-configurator div.product form.cart:has(.idxpd-customize-button) .single_add_to_cart_button:focus-visible,
body.idx-configurator div.product form.cart:has(.idxbvg-cta--idxpd) .single_add_to_cart_button:hover,
body.idx-configurator div.product form.cart:has(.idxbvg-cta--idxpd) .single_add_to_cart_button:focus-visible,
body.idx-catalog-product div.product form.cart:has(.idxpd-customize-button) .single_add_to_cart_button:hover,
body.idx-catalog-product div.product form.cart:has(.idxpd-customize-button) .single_add_to_cart_button:focus-visible,
body.idx-catalog-product div.product form.cart:has(.idxbvg-cta--idxpd) .single_add_to_cart_button:hover,
body.idx-catalog-product div.product form.cart:has(.idxbvg-cta--idxpd) .single_add_to_cart_button:focus-visible {
	background-size: 100% 100% !important;
	color: #F3C91A !important;
	-webkit-text-fill-color: #F3C91A;
	transform: none !important;
}

/* Keep the existing cart icon, recolored with currentColor. */
body.idx-configurator div.product form.cart:has(.idxpd-customize-button) .single_add_to_cart_button::after,
body.idx-configurator div.product form.cart:has(.idxbvg-cta--idxpd) .single_add_to_cart_button::after,
body.single-product form.cart:has(.idxpd-customize-button) .single_add_to_cart_button::after,
body.single-product form.cart:has(.idxbvg-cta--idxpd) .single_add_to_cart_button::after {
	content: "";
	flex: none;
	width: 16px;
	height: 16px;
	background: currentColor;
	-webkit-mask: url("../images/configurator-icons/cart.svg") center / contain no-repeat;
	mask: url("../images/configurator-icons/cart.svg") center / contain no-repeat;
	transform: none;
}

/* Primary: Customize (and guest sign-in in that slot) — navy / yellow. */
body.single-product form.cart .idxpd-customize-button,
body.single-product form.cart .idxbvg-cta--idxpd .idxbvg-signin-btn,
body.single-product form.cart .idxbvg-cta--idxpd .button {
	background: #0f143a linear-gradient(#F3C91A, #F3C91A) no-repeat left center / 0% 100% !important;
	color: #F3C91A !important;
	-webkit-text-fill-color: #F3C91A;
}
body.single-product form.cart .idxpd-customize-button:hover,
body.single-product form.cart .idxpd-customize-button:focus,
body.single-product form.cart .idxpd-customize-button:focus-visible,
body.single-product form.cart .idxbvg-cta--idxpd .idxbvg-signin-btn:hover,
body.single-product form.cart .idxbvg-cta--idxpd .idxbvg-signin-btn:focus-visible,
body.single-product form.cart .idxbvg-cta--idxpd .button:hover,
body.single-product form.cart .idxbvg-cta--idxpd .button:focus-visible {
	background-size: 100% 100% !important;
	color: #0f143a !important;
	-webkit-text-fill-color: #0f143a;
	outline: 3px solid #F3C91A;
	outline-offset: 2px;
}
body.single-product form.cart:has(.idxpd-customize-button) .single_add_to_cart_button:focus-visible,
body.single-product form.cart:has(.idxbvg-cta--idxpd) .single_add_to_cart_button:focus-visible {
	outline: 3px solid #F3C91A;
	outline-offset: 2px;
}

body.single-product form.cart .idxpd-customize-button.is-locked,
body.single-product form.cart .idxpd-customize-button:disabled {
	opacity: 0.55;
	cursor: not-allowed !important;
	box-shadow: none !important;
}

body.single-product form.cart .idxpd-customize-hint,
body.single-product form.cart [data-idxpd-customize-hint] {
	flex: 1 0 100%;
	width: 100%;
	margin: 0;
}

@media (max-width: 480px) {
	body.single-product form.cart:has(.idxpd-customize-button) .single_add_to_cart_button,
	body.single-product form.cart:has(.idxbvg-cta--idxpd) .single_add_to_cart_button,
	body.single-product form.cart .idxpd-customize-button,
	body.single-product form.cart .idxbvg-cta--idxpd,
	body.single-product form.cart .idxbvg-cta--idxpd .idxbvg-signin-btn,
	body.single-product form.cart .idxbvg-cta--idxpd .button,
	body.idx-catalog-product div.product form.cart .idxpd-customize-button,
	body.idx-catalog-product div.product form.cart .idxbvg-cta,
	body.idx-catalog-product div.product form.cart .woocommerce-variation-add-to-cart > .idxpd-customize-button,
	body.idx-catalog-product div.product form.cart .woocommerce-variation-add-to-cart > .idxbvg-cta {
		flex: 1 0 100% !important;
		width: 100% !important;
		max-width: 100% !important;
	}
	body.single-product form.cart:has(.idxpd-customize-button) .quantity,
	body.single-product form.cart:has(.idxbvg-cta--idxpd) .quantity {
		flex: 1 0 100%;
		width: 100%;
		min-height: 3rem;
	}
}

@media (prefers-reduced-motion: reduce) {
	body.single-product form.cart:has(.idxpd-customize-button) .single_add_to_cart_button,
	body.single-product form.cart .idxpd-customize-button,
	body.single-product form.cart .idxbvg-cta--idxpd .idxbvg-signin-btn {
		transition: none !important;
	}
}
