.wscm-countdown {
	position: relative;
	overflow: hidden;
	clear: both;
	margin: 0 0 1.15rem;
	padding: 1rem;
	border: 1px solid #fed7aa;
	border-radius: 8px;
	background: #fff7ed;
	box-shadow: 0 12px 24px rgba(17, 24, 39, .08);
	color: #111827;
}

.wscm-countdown::before {
	content: "";
	position: absolute;
	inset: 0;
	pointer-events: none;
	background: linear-gradient(90deg, rgba(220, 38, 38, .08), rgba(22, 163, 74, .08));
}

.wscm-countdown::after {
	content: "";
	position: absolute;
	inset: 0;
	pointer-events: none;
}

.wscm-countdown__top,
.wscm-countdown__save,
.wscm-countdown__demand,
.wscm-countdown__timer {
	position: relative;
	z-index: 1;
}

.wscm-countdown__top {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: .55rem;
	margin-bottom: .55rem;
}

.wscm-countdown__top strong {
	font-size: 1rem;
	line-height: 1.2;
}

.wscm-countdown__badge {
	display: inline-flex;
	align-items: center;
	min-height: 1.6rem;
	padding: .2rem .55rem;
	border-radius: 999px;
	background: #b91c1c;
	color: #fff;
	font-size: .78rem;
	font-weight: 800;
	text-transform: uppercase;
}

.wscm-countdown__save {
	margin-bottom: .55rem;
	color: #374151;
	font-weight: 700;
}

.wscm-countdown__save .woocommerce-Price-amount {
	color: #047857;
}

.wscm-countdown__demand {
	display: inline-flex;
	flex-wrap: wrap;
	gap: .3rem;
	align-items: center;
	margin-bottom: .85rem;
	padding: .45rem .65rem;
	border: 1px solid rgba(37, 99, 235, .18);
	border-radius: 7px;
	background: #eff6ff;
	color: #1f2937;
	font-weight: 700;
}

.wscm-countdown__demand strong {
	color: #1d4ed8;
	font-size: 1.05rem;
	font-variant-numeric: tabular-nums;
}

.wscm-countdown__timer {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: .45rem;
}

.wscm-countdown__timer span {
	display: grid;
	place-items: center;
	min-width: 0;
	padding: .55rem .35rem;
	border: 1px solid rgba(17, 24, 39, .09);
	border-radius: 7px;
	background: #fff;
}

.wscm-countdown__timer b {
	font-size: clamp(1rem, 2vw, 1.45rem);
	line-height: 1;
	font-variant-numeric: tabular-nums;
	letter-spacing: 0;
	color: #111827;
}

.wscm-countdown__timer small {
	margin-top: .25rem;
	font-size: .67rem;
	font-weight: 800;
	line-height: 1;
	text-transform: uppercase;
	color: #6b7280;
}

.wscm-countdown__spark {
	display: none;
	position: absolute;
	pointer-events: none;
	z-index: 0;
}

.wscm-countdown.is-expired {
	border-color: #d1d5db;
	background: #f9fafb;
}

.wscm-theme-american {
	border-color: rgba(37, 99, 235, .45);
	background:
		linear-gradient(115deg, rgba(185, 28, 28, .96), rgba(29, 78, 216, .96)),
		#1d4ed8;
	box-shadow: 0 16px 34px rgba(30, 64, 175, .24);
	color: #ffffff;
}

.wscm-theme-american::before {
	background:
		radial-gradient(circle at 9% 22%, rgba(255, 255, 255, .92) 0 2px, transparent 3px),
		radial-gradient(circle at 16% 52%, rgba(255, 255, 255, .75) 0 2px, transparent 3px),
		radial-gradient(circle at 26% 34%, rgba(255, 255, 255, .88) 0 2px, transparent 3px),
		linear-gradient(105deg, transparent 0 26%, rgba(255, 255, 255, .2) 26% 32%, transparent 32% 38%, rgba(255, 255, 255, .18) 38% 44%, transparent 44% 100%);
	background-size: 120px 90px, 150px 120px, 180px 110px, 260% 100%;
	animation: wscm-american-shine 7s linear infinite;
	opacity: .88;
}

.wscm-theme-american::after {
	background: repeating-linear-gradient(0deg, rgba(255, 255, 255, .16) 0 8px, transparent 8px 18px);
	mix-blend-mode: screen;
	opacity: .55;
}

.wscm-theme-american .wscm-countdown__badge {
	background: #ffffff;
	color: #b91c1c;
	box-shadow: 0 0 0 2px rgba(255, 255, 255, .2);
}

.wscm-theme-american .wscm-countdown__save,
.wscm-theme-american .wscm-countdown__top strong {
	color: #ffffff;
}

.wscm-theme-american .wscm-countdown__save .woocommerce-Price-amount {
	color: #fef3c7;
}

.wscm-theme-american .wscm-countdown__demand,
.wscm-theme-american .wscm-countdown__timer span {
	border-color: rgba(255, 255, 255, .25);
	background: rgba(255, 255, 255, .92);
}

.wscm-theme-fireworks {
	border-color: rgba(250, 204, 21, .42);
	background:
		radial-gradient(circle at 50% 120%, rgba(30, 64, 175, .92), transparent 54%),
		linear-gradient(135deg, #111827, #312e81 48%, #581c87);
	box-shadow: 0 18px 38px rgba(49, 46, 129, .3);
	color: #ffffff;
}

.wscm-theme-fireworks::before,
.wscm-theme-fireworks::after {
	background:
		radial-gradient(circle, rgba(255, 255, 255, .95) 0 2px, transparent 3px),
		radial-gradient(circle, rgba(250, 204, 21, .9) 0 2px, transparent 3px),
		radial-gradient(circle, rgba(34, 211, 238, .8) 0 2px, transparent 3px),
		radial-gradient(circle, rgba(244, 114, 182, .78) 0 2px, transparent 3px);
	background-position: 14% 28%, 76% 22%, 52% 62%, 88% 72%;
	background-size: 130px 130px, 170px 170px, 150px 150px, 120px 120px;
	background-repeat: no-repeat;
	animation: wscm-fireworks-burst 2.6s ease-in-out infinite;
	opacity: .86;
}

.wscm-theme-fireworks::after {
	animation-delay: 1.25s;
	transform: rotate(16deg);
}

.wscm-theme-fireworks .wscm-countdown__spark {
	display: block;
	width: 8.5rem;
	height: 8.5rem;
	border-radius: 50%;
	background:
		repeating-conic-gradient(from 12deg, rgba(250, 204, 21, .96) 0 7deg, transparent 7deg 16deg),
		radial-gradient(circle, rgba(255, 255, 255, .9) 0 5%, transparent 6% 100%);
	filter: drop-shadow(0 0 18px rgba(250, 204, 21, .6));
	opacity: .42;
	animation: wscm-firework-ring 2.8s ease-in-out infinite;
}

.wscm-theme-fireworks .wscm-countdown__spark-one {
	right: -1.7rem;
	top: -2rem;
}

.wscm-theme-fireworks .wscm-countdown__spark-two {
	left: -2rem;
	bottom: -2.4rem;
	animation-delay: 1.1s;
	background:
		repeating-conic-gradient(from 32deg, rgba(34, 211, 238, .95) 0 7deg, transparent 7deg 16deg),
		radial-gradient(circle, rgba(255, 255, 255, .9) 0 5%, transparent 6% 100%);
}

.wscm-theme-fireworks .wscm-countdown__badge {
	background: #facc15;
	color: #111827;
}

.wscm-theme-fireworks .wscm-countdown__save,
.wscm-theme-fireworks .wscm-countdown__top strong {
	color: #ffffff;
}

.wscm-theme-fireworks .wscm-countdown__save .woocommerce-Price-amount {
	color: #fef08a;
}

.wscm-theme-fireworks .wscm-countdown__demand,
.wscm-theme-fireworks .wscm-countdown__timer span {
	border-color: rgba(255, 255, 255, .18);
	background: rgba(255, 255, 255, .94);
}

.wscm-theme-party {
	border-color: rgba(20, 184, 166, .38);
	background:
		linear-gradient(135deg, #ecfeff, #fff7ed 46%, #fdf2f8),
		#ffffff;
	box-shadow: 0 18px 34px rgba(236, 72, 153, .16);
	color: #111827;
}

.wscm-theme-party::before {
	background:
		linear-gradient(45deg, #f43f5e 0 8px, transparent 8px),
		linear-gradient(-35deg, #0ea5e9 0 8px, transparent 8px),
		radial-gradient(circle, #22c55e 0 4px, transparent 5px),
		radial-gradient(circle, #facc15 0 4px, transparent 5px);
	background-position: 8% 20%, 34% 12%, 62% 22%, 88% 18%;
	background-size: 110px 90px, 130px 100px, 120px 110px, 140px 120px;
	animation: wscm-party-confetti 8s linear infinite;
	opacity: .36;
}

.wscm-theme-party::after {
	background: linear-gradient(100deg, transparent, rgba(255, 255, 255, .78), transparent);
	transform: translateX(-120%);
	animation: wscm-party-sweep 4.5s ease-in-out infinite;
}

.wscm-theme-party .wscm-countdown__badge {
	background: linear-gradient(135deg, #f43f5e, #f59e0b);
	color: #ffffff;
}

.wscm-theme-party .wscm-countdown__demand {
	border-color: rgba(20, 184, 166, .28);
	background: #ecfeff;
}

.wscm-theme-party .wscm-countdown__timer span {
	border-color: rgba(236, 72, 153, .16);
	background: rgba(255, 255, 255, .9);
	box-shadow: inset 0 -3px 0 rgba(20, 184, 166, .11);
}

@media (max-width: 520px) {
	.wscm-countdown {
		padding: .85rem;
	}

	.wscm-countdown__timer {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

@keyframes wscm-american-shine {
	0% {
		background-position: 14% 20%, 22% 62%, 28% 38%, -120% 0;
	}

	100% {
		background-position: 14% 20%, 22% 62%, 28% 38%, 120% 0;
	}
}

@keyframes wscm-fireworks-burst {
	0%,
	100% {
		opacity: .24;
		transform: scale(.78);
	}

	42% {
		opacity: .95;
		transform: scale(1.06);
	}

	70% {
		opacity: .42;
		transform: scale(1.22);
	}
}

@keyframes wscm-firework-ring {
	0%,
	100% {
		opacity: .18;
		transform: scale(.64) rotate(0deg);
	}

	48% {
		opacity: .5;
		transform: scale(1.04) rotate(24deg);
	}
}

@keyframes wscm-party-confetti {
	0% {
		background-position: 8% -20%, 34% -28%, 62% -18%, 88% -30%;
	}

	100% {
		background-position: 8% 120%, 34% 132%, 62% 124%, 88% 138%;
	}
}

@keyframes wscm-party-sweep {
	0%,
	42% {
		transform: translateX(-120%);
	}

	72%,
	100% {
		transform: translateX(120%);
	}
}

@media (prefers-reduced-motion: reduce) {
	.wscm-countdown::before,
	.wscm-countdown::after,
	.wscm-countdown__spark {
		animation: none !important;
	}
}
