/*
 * WooCommerce FOMO & Wishlist - base styles
 * Dynamic colors, font sizes, and animation selection are injected inline
 * (see wcfw_build_dynamic_css()) so they can be controlled from
 * WooCommerce > FOMO Settings without editing this file.
 */

/* ---------------------------------------------------------------
 * 1. Flash sale ticker - full-width scrolling bar at the top of the
 *    product page. Heading animates (independently of the scroll);
 *    sub heading never animates.
 * --------------------------------------------------------------- */
.wcfw-ticker-wrap {
	position: relative;
	left: 50%;
	right: 50%;
	width: 100vw;
	margin-left: -50vw;
	margin-right: -50vw;
	overflow: hidden;
	white-space: nowrap;
	padding: 10px 0;
}

.wcfw-ticker-track {
	display: inline-flex;
	animation: wcfwTickerScroll 22s linear infinite !important;
	will-change: transform;
}

.wcfw-ticker-item {
	display: inline-flex;
	align-items: baseline;
	padding: 0 36px;
	flex-shrink: 0;
}

.wcfw-ticker-heading {
	display: inline-block;
	font-weight: 700;
	letter-spacing: 0.02em;
	white-space: nowrap;
}

.wcfw-ticker-subheading {
	display: inline-block;
	font-size: 0.8em;
	font-weight: 500;
	opacity: 0.92;
	margin-left: 8px;
	white-space: nowrap;
}

@keyframes wcfwTickerScroll {
	from {
		transform: translateX(0);
	}
	to {
		transform: translateX(-50%);
	}
}

@keyframes fomoPulseLoop {
	0%,
	100% {
		opacity: 1;
	}
	50% {
		opacity: 0.55;
	}
}

@keyframes fomoGlowLoop {
	0%,
	100% {
		box-shadow: 0 0 4px rgba(255, 255, 255, 0.25);
	}
	50% {
		box-shadow: 0 0 14px rgba(255, 255, 255, 0.85);
	}
}

/* ---------------------------------------------------------------
 * 2. Countdown timer - unit label sits inline with its number
 * --------------------------------------------------------------- */
.wcfw-countdown {
	margin: 4px 0 16px;
}

.wcfw-countdown-label {
	display: block;
	font-weight: 600;
	margin-bottom: 6px;
	font-size: 13px;
	text-transform: uppercase;
	letter-spacing: 0.04em;
}

.wcfw-countdown-timer {
	display: flex;
	gap: 10px;
}

.wcfw-countdown-block {
	display: inline-flex;
	flex-direction: row;
	align-items: baseline;
	gap: 5px;
	padding: 8px 12px;
	border-radius: 6px;
	color: #ffffff;
}

.wcfw-countdown-value {
	font-size: 18px;
	font-weight: 700;
	line-height: 1;
	font-variant-numeric: tabular-nums;
}

.wcfw-countdown-unit {
	font-size: 11px;
	text-transform: uppercase;
	opacity: 0.85;
	line-height: 1;
}

/* ---------------------------------------------------------------
 * 3. Low stock alert (uses real stock data; color/size/animation dynamic)
 * --------------------------------------------------------------- */
.wcfw-low-stock {
	font-weight: 600;
	margin: 0 0 14px;
	display: inline-block;
}

/* ---------------------------------------------------------------
 * 4. Wishlist button placement helpers
 * --------------------------------------------------------------- */
.add_to_wishlist {
	margin-left: 10px;
	vertical-align: middle;
}

li.product .add_to_wishlist {
	margin: 8px 0 0;
}

.wcfw-processing {
	opacity: 0.6;
	pointer-events: none;
}

/* ---------------------------------------------------------------
 * 5. [fomo_products] shortcode grid
 * --------------------------------------------------------------- */
.wc-fomo-products ul.products {
	display: grid;
	grid-template-columns: repeat(var(--wcfw-columns, 4), 1fr);
	gap: 20px;
	list-style: none;
	padding: 0;
	margin: 0;
}

.wc-fomo-products ul.products li.product {
	width: 100% !important;
	margin: 0 !important;
	float: none !important;
}

@media (max-width: 782px) {
	.wc-fomo-products ul.products {
		grid-template-columns: repeat(2, 1fr);
	}
}

@media (max-width: 480px) {
	.wc-fomo-products ul.products {
		grid-template-columns: 1fr;
	}
}

.wc-fomo-no-products {
	text-align: center;
	opacity: 0.7;
}
