/**
 * Woo Sales Booster Buy Now module.
 */

.wsb-buy-now-control {
	align-items: center !important;
	background: var(--wsb-buy-now-bg, #111827) !important;
	border-color: var(--wsb-buy-now-border, #111827) !important;
	border-radius: var(--wsb-buy-now-radius, 6px) !important;
	border-style: solid !important;
	border-width: var(--wsb-buy-now-border-width, 1px) !important;
	box-shadow: var(--wsb-buy-now-shadow, none) !important;
	box-sizing: border-box;
	color: var(--wsb-buy-now-color, #fff) !important;
	cursor: pointer;
	font-family: var(--wsb-buy-now-font, inherit) !important;
	font-size: var(--wsb-buy-now-font-size, 16px) !important;
	font-weight: var(--wsb-buy-now-font-weight, 600) !important;
	justify-content: center !important;
	letter-spacing: var(--wsb-buy-now-letter-spacing, 0) !important;
	line-height: 1 !important;
	overflow: hidden;
	text-align: center !important;
	text-decoration: none !important;
	text-transform: var(--wsb-buy-now-transform, none) !important;
	transition: background-color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease, opacity 0.2s ease, transform 0.2s ease;
}

.wsb-buy-now-control:hover,
.wsb-buy-now-control:focus {
	background: var(--wsb-buy-now-hover-bg, #000) !important;
	color: var(--wsb-buy-now-hover-color, #fff) !important;
	filter: none;
}

.wsb-buy-now-control--hover-lift:hover,
.wsb-buy-now-control--hover-lift:focus {
	transform: translateY(-1px);
}

.wsb-buy-now-control--hover-scale:hover,
.wsb-buy-now-control--hover-scale:focus {
	transform: scale(1.025);
}

.wsb-buy-now-control--hover-glow:hover,
.wsb-buy-now-control--hover-glow:focus {
	box-shadow: 0 12px 34px rgba(99, 102, 241, 0.48) !important;
}

.wsb-buy-now-control--hover-shine::before {
	background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.38), transparent);
	content: "";
	height: 180%;
	left: -85%;
	pointer-events: none;
	position: absolute;
	top: -40%;
	transform: rotate(18deg);
	transition: left 0.55s ease;
	width: 45%;
	z-index: 1;
}

.wsb-buy-now-control--hover-shine:hover::before,
.wsb-buy-now-control--hover-shine:focus::before {
	left: 140%;
}

.wsb-buy-now-button {
	display: inline-flex !important;
	height: var(--wsb-buy-now-height, auto) !important;
	margin-bottom: 0;
	margin-top: 0;
	min-height: var(--wsb-buy-now-height, auto) !important;
	position: relative;
	vertical-align: top;
	width: var(--wsb-buy-now-width, auto) !important;
}

.wsb-buy-now-button--after {
	margin-left: 8px !important;
	margin-right: 0 !important;
}

.wsb-buy-now-button--before {
	margin-left: 0 !important;
	margin-right: 8px !important;
}

.wsb-buy-now-button--full-width {
	display: flex !important;
	margin: 8px 0 0;
	width: 100% !important;
}

.wsb-buy-now-button--custom-height {
	height: var(--wsb-buy-now-custom-height, 52px) !important;
	min-height: var(--wsb-buy-now-custom-height, 52px) !important;
}

.wsb-buy-now-button__text {
	align-items: center;
	display: inline-flex;
	justify-content: center;
	line-height: 1 !important;
	margin: 0;
	padding: 0;
	text-align: center;
	z-index: 2;
}

.wsb-buy-now-button__icon {
	align-items: center;
	display: inline-flex;
	flex: 0 0 18px;
	height: 18px;
	justify-content: center;
	position: relative;
	width: 18px;
	z-index: 2;
}

.wsb-buy-now-button__icon svg {
	display: block;
	height: 100%;
	width: 100%;
}

.wsb-buy-now-button__icon path {
	fill: none;
	stroke: currentColor;
	stroke-linecap: round;
	stroke-linejoin: round;
	stroke-width: 1.8;
}

.wsb-buy-now-control--icon-left .wsb-buy-now-button__icon {
	margin-right: 9px;
}

.wsb-buy-now-control--icon-right .wsb-buy-now-button__icon {
	margin-left: 9px;
	order: 2;
}

.wsb-buy-now-button__spinner {
	animation: wsb-buy-now-spin 0.7s linear infinite;
	border: 2px solid rgba(255, 255, 255, 0.4);
	border-radius: 50%;
	border-top-color: currentColor;
	display: none;
	flex: 0 0 16px;
	height: 16px;
	margin-left: 8px;
	width: 16px;
	z-index: 2;
}

.wsb-buy-now-control--loading .wsb-buy-now-button__spinner {
	display: inline-block;
}

.wsb-buy-now-control--loading {
	cursor: wait;
	opacity: 0.75;
	pointer-events: none;
}

.wsb-buy-now-sticky-button {
	display: inline-flex;
	max-width: calc(100vw - 32px);
	min-height: 48px;
	min-width: 190px;
	opacity: 0;
	padding: 14px 28px !important;
	pointer-events: none;
	position: fixed;
	z-index: 99998;
}

.wsb-buy-now-sticky-button--bottom {
	bottom: var(--wsb-sticky-offset, 20px);
	transform: translate(var(--wsb-sticky-x, 0), 18px);
}

.wsb-buy-now-sticky-button--top {
	top: var(--wsb-sticky-offset, 20px);
	transform: translate(var(--wsb-sticky-x, 0), -18px);
}

.wsb-buy-now-sticky-button--left {
	left: 16px;
	right: auto;
}

.wsb-buy-now-sticky-button--center {
	--wsb-sticky-x: -50%;
	left: 50%;
	right: auto;
}

.wsb-buy-now-sticky-button--right {
	left: auto;
	right: 16px;
}

.wsb-buy-now-sticky-button--custom {
	--wsb-sticky-x: -50%;
	left: var(--wsb-sticky-custom-left, 50%);
	right: auto;
}

.wsb-buy-now-sticky-button--width-full {
	--wsb-sticky-x: 0;
	left: 16px;
	max-width: none;
	min-width: 0;
	right: 16px;
	width: auto;
}

.wsb-buy-now-sticky-button--width-custom {
	width: min(var(--wsb-sticky-custom-width, 260px), calc(100vw - 32px));
}

.wsb-buy-now-sticky-button--animation-fade.wsb-buy-now-sticky-button--bottom,
.wsb-buy-now-sticky-button--animation-fade.wsb-buy-now-sticky-button--top {
	transform: translate(var(--wsb-sticky-x, 0), 0);
}

.wsb-buy-now-sticky-button--animation-scale.wsb-buy-now-sticky-button--bottom,
.wsb-buy-now-sticky-button--animation-scale.wsb-buy-now-sticky-button--top {
	transform: translate(var(--wsb-sticky-x, 0), 0) scale(0.88);
}

.wsb-buy-now-sticky-button--visible {
	opacity: 1;
	pointer-events: auto;
	transform: translate(var(--wsb-sticky-x, 0), 0);
}

.wsb-buy-now-sticky-button--animation-scale.wsb-buy-now-sticky-button--visible {
	transform: translate(var(--wsb-sticky-x, 0), 0) scale(1);
}

.wsb-buy-now-sticky-button--visible.wsb-buy-now-control--hover-lift:hover,
.wsb-buy-now-sticky-button--visible.wsb-buy-now-control--hover-lift:focus {
	transform: translate(var(--wsb-sticky-x, 0), -1px);
}

.wsb-buy-now-sticky-button--visible.wsb-buy-now-control--hover-scale:hover,
.wsb-buy-now-sticky-button--visible.wsb-buy-now-control--hover-scale:focus {
	transform: translate(var(--wsb-sticky-x, 0), 0) scale(1.025);
}

@keyframes wsb-buy-now-spin {
	to {
		transform: rotate(360deg);
	}
}

@media (min-width: 769px) {
	.wsb-buy-now-button--hide-desktop,
	.wsb-buy-now-sticky-button--device-mobile {
		display: none !important;
	}
}

@media (max-width: 768px) {
	.wsb-buy-now-button--hide-mobile,
	.wsb-buy-now-sticky-button--device-desktop {
		display: none !important;
	}

	/*
	 * Keep the single-product buying controls tidy when Wishlist is placed
	 * after Add to Cart. The quantity, cart and heart controls use the first
	 * row; Buy Now receives its own full-width row instead of wrapping with
	 * the desktop left margin still attached.
	 */
	form.cart .wsb-wishlist-button--single ~ .wsb-buy-now-button--after {
		flex-basis: 100%;
		margin-left: 0 !important;
		margin-top: 10px !important;
		width: 100% !important;
	}
}

@media (prefers-reduced-motion: reduce) {
	.wsb-buy-now-control {
		transition: none;
	}

	.wsb-buy-now-button__spinner {
		animation-duration: 1.4s;
	}
}
