/* WooCommerce notices: subtle, on-family feedback instead of the default bright banners. */
.woocommerce-notices-wrapper {
	margin-block: 0 1.2rem;
}

.single-product .woocommerce-notices-wrapper,
.woocommerce-cart .woocommerce-notices-wrapper {
	display: block;
	left: auto;
	margin: 0;
	max-width: calc(100vw - 2rem);
	pointer-events: none;
	position: fixed;
	right: 1rem;
	top: 8rem;
	width: min(31rem, calc(100vw - 2rem));
	z-index: 9999;
}

.woocommerce-message,
.woocommerce-info,
.woocommerce-error,
.woocommerce .woocommerce-message,
.woocommerce .woocommerce-info,
.woocommerce .woocommerce-error,
.woocommerce-page .woocommerce-message,
.woocommerce-page .woocommerce-info,
.woocommerce-page .woocommerce-error,
.single-product .woocommerce-notices-wrapper .woocommerce-message,
.woocommerce-cart .woocommerce-notices-wrapper .woocommerce-message {
	background: var(--sf-off-white, #fcfcfa);
	border: 1px solid rgba(31, 32, 35, 0.12);
	border-left: 0.35rem solid var(--sf-brand-red, #b4232f);
	border-radius: 0.4rem;
	box-shadow: 0 0.45rem 1.1rem rgba(31, 32, 35, 0.08);
	color: var(--sf-text-primary, #1f2023);
	font-size: 1rem;
	line-height: 1.45;
	margin: 0 0 1.2rem;
	padding: 1rem 1.2rem 1rem 3rem;
}

.single-product .woocommerce-notices-wrapper .woocommerce-message,
.woocommerce-cart .woocommerce-notices-wrapper .woocommerce-message {
	background: var(--sf-off-white, #fcfcfa) !important;
	color: var(--sf-text-primary, #1f2023) !important;
	margin: 0;
	pointer-events: auto;
}

.woocommerce-info,
.woocommerce .woocommerce-info,
.woocommerce-page .woocommerce-info {
	border-left-color: var(--sf-charcoal, #242428);
}

.woocommerce-error,
.woocommerce .woocommerce-error,
.woocommerce-page .woocommerce-error {
	border-left-color: var(--sf-brand-red, #b4232f);
}

.woocommerce-message::before,
.woocommerce-info::before,
.woocommerce-error::before,
.woocommerce .woocommerce-message::before,
.woocommerce .woocommerce-info::before,
.woocommerce .woocommerce-error::before,
.woocommerce-page .woocommerce-message::before,
.woocommerce-page .woocommerce-info::before,
.woocommerce-page .woocommerce-error::before,
.single-product .woocommerce-notices-wrapper .woocommerce-message::before,
.woocommerce-cart .woocommerce-notices-wrapper .woocommerce-message::before {
	color: currentColor;
	left: 1.05rem;
	top: 1rem;
}

.single-product .woocommerce-notices-wrapper .hide-notice,
.woocommerce-cart .woocommerce-notices-wrapper .hide-notice {
	background: transparent !important;
	color: var(--sf-text-primary, #1f2023) !important;
	height: 2.2rem;
	margin: 0;
	opacity: 0.7;
	padding: 0;
	position: absolute;
	right: 0.45rem;
	top: 0.45rem;
	width: 2.2rem;
}

.woocommerce-message .button,
.woocommerce-info .button,
.woocommerce-error .button,
.woocommerce .woocommerce-message .button,
.woocommerce .woocommerce-info .button,
.woocommerce .woocommerce-error .button,
.woocommerce-page .woocommerce-message .button,
.woocommerce-page .woocommerce-info .button,
.woocommerce-page .woocommerce-error .button {
	background: var(--sf-brand-red, #b4232f);
	border: 1px solid var(--sf-brand-red, #b4232f);
	border-radius: 0.35rem;
	color: var(--sf-text-on-dark, #fcfcfa);
	font-size: 0.95rem;
	font-weight: 700;
	line-height: 1.2;
	padding: 0.65rem 1rem;
	transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.woocommerce-message .button:hover,
.woocommerce-info .button:hover,
.woocommerce-error .button:hover,
.woocommerce .woocommerce-message .button:hover,
.woocommerce .woocommerce-info .button:hover,
.woocommerce .woocommerce-error .button:hover,
.woocommerce-page .woocommerce-message .button:hover,
.woocommerce-page .woocommerce-info .button:hover,
.woocommerce-page .woocommerce-error .button:hover {
	background: var(--sf-red-hover, #98202a);
	border-color: var(--sf-red-hover, #98202a);
	color: var(--sf-text-on-dark, #ffffff);
}

/* Cart auto-update: keep Woo's submit button available for scripts but out of the UI. */
.woocommerce-cart-form button[name="update_cart"] {
	clip: rect(0 0 0 0);
	clip-path: inset(50%);
	height: 1px;
	overflow: hidden;
	position: absolute;
	white-space: nowrap;
	width: 1px;
}

.woocommerce-cart .sf-cart-suggestion-link {
	background: var(--sf-charcoal, #242428);
	border-radius: 0.35rem;
	color: var(--sf-text-on-dark, #fcfcfa);
	font-weight: 700;
}

.woocommerce-cart .sf-cart-suggestion-link:hover {
	background: var(--sf-brand-red, #b4232f);
	color: var(--sf-text-on-dark, #ffffff);
}

/* Product quantity policy: configurable racks are single-quantity; accessories/simple products are not. */
.single-product.sfst-product-quantity-hidden .product form.cart .quantity {
	display: none !important;
}

.single-product.sfst-product-quantity-visible .product form.cart .quantity {
	display: inline-flex !important;
}

@media (max-width: 640px) {
	.woocommerce-message,
	.woocommerce-info,
	.woocommerce-error,
	.woocommerce .woocommerce-message,
	.woocommerce .woocommerce-info,
	.woocommerce .woocommerce-error,
	.woocommerce-page .woocommerce-message,
	.woocommerce-page .woocommerce-info,
	.woocommerce-page .woocommerce-error,
	.single-product .woocommerce-notices-wrapper .woocommerce-message,
	.woocommerce-cart .woocommerce-notices-wrapper .woocommerce-message {
		padding: 0.9rem 1rem 0.9rem 2.7rem;
	}

	.single-product .woocommerce-notices-wrapper,
	.woocommerce-cart .woocommerce-notices-wrapper {
		left: 0.8rem;
		right: 0.8rem;
		top: 5.5rem;
		width: auto;
	}

	.woocommerce-message .button,
	.woocommerce-info .button,
	.woocommerce-error .button,
	.woocommerce .woocommerce-message .button,
	.woocommerce .woocommerce-info .button,
	.woocommerce .woocommerce-error .button,
	.woocommerce-page .woocommerce-message .button,
	.woocommerce-page .woocommerce-info .button,
	.woocommerce-page .woocommerce-error .button {
		float: none;
		margin: 0.75rem 0 0;
		width: 100%;
	}
}
