/**
 * TP Countdown widget (Pure Core)
 *
 * Loaded by Elementor only when the "Countdown" widget is on the page (see
 * get_style_depends() in widgets/countdown.php).
 *
 * 1. Shared structure
 * 2. Layout 1 - Minimal (SaaS)   .tp-countdown-widget--minimal   (default)
 * 3. Layout 2 - Dark             .tp-countdown-widget--dark
 *
 * Each layout is scoped under its modifier class so it can never leak into
 * other countdowns on the page (e.g. the static one in the theme header).
 * Every value here is a default that the widget's Style controls override.
 */

/* ---------------------------------------------------------------------------
 * 1. Shared structure
 * ------------------------------------------------------------------------ */

.tp-countdown-widget {
	box-sizing: border-box;
	display: flex;
	justify-content: center; /* "Alignment" control */
}

.tp-countdown {
	box-sizing: border-box;
	display: flex;
	flex-wrap: wrap;
	max-width: 100%;
}

.tp-countdown-item {
	box-sizing: border-box;
	text-align: center;
}

.tp-countdown-number {
	display: block;
	line-height: 1.3;
	font-variant-numeric: tabular-nums;
}

.tp-countdown-label {
	display: block;
	line-height: 1.3;
}

/* Shown instead of the boxes once the time is up ("When Expired" => message). */
.tp-countdown-message {
	display: none;
	width: 100%;
	text-align: center;
}

.tp-countdown.is-expired .tp-countdown-number {
	opacity: 0.5;
}

.tp-countdown.is-expired .tp-countdown-message {
	display: block;
}

.tp-countdown.is-expired[data-tp-countdown-expire="message"] .tp-countdown-item {
	display: none;
}

/* ---------------------------------------------------------------------------
 * 2. Layout 1 - Minimal (SaaS)
 *    One clean card, four segments split by hairline dividers. Light, no
 *    background of its own, so it sits on a normal white page.
 * ------------------------------------------------------------------------ */

.tp-countdown-widget--minimal .tp-countdown {
	flex-wrap: nowrap;
	gap: 0;
	background-color: #fff;
	border: 1px solid #e5e7eb;
	border-radius: 12px;
	box-shadow: 0 1px 2px rgba(16, 24, 40, 0.05), 0 1px 3px rgba(16, 24, 40, 0.04);
}

.tp-countdown-widget--minimal .tp-countdown-item {
	flex: 0 1 auto;
	min-width: 72px;
	padding: 12px 16px 11px;
}

.tp-countdown-widget--minimal .tp-countdown-item + .tp-countdown-item {
	border-left: 1px solid #eef0f3;
}

.tp-countdown-widget--minimal .tp-countdown-number {
	font-size: 26px;
	font-weight: 600;
	letter-spacing: -0.02em;
	color: #0f172a;
}

.tp-countdown-widget--minimal .tp-countdown-label {
	margin-top: 2px;
	font-size: 12px;
	font-weight: 500;
	letter-spacing: 0.01em;
	color: #64748b;
}

.tp-countdown-widget--minimal .tp-countdown-message {
	padding: 12px 20px;
	font-size: 14px;
	font-weight: 500;
	color: #0f172a;
}

/* Phones: let the four segments share the width instead of wrapping. */
@media (max-width: 480px) {
	.tp-countdown-widget--minimal .tp-countdown {
		width: 100%;
	}

	.tp-countdown-widget--minimal .tp-countdown-item {
		flex: 1 1 0;
		min-width: 0;
		padding: 10px 6px 9px;
	}

	.tp-countdown-widget--minimal .tp-countdown-number {
		font-size: 20px;
	}
}

/* ---------------------------------------------------------------------------
 * 3. Layout 2 - Dark
 *    Four separate translucent tiles on an indigo band.
 * ------------------------------------------------------------------------ */

.tp-countdown-widget--dark {
	padding: 28px 20px;
	background-color: #1a0b86;
}

.tp-countdown-widget--dark .tp-countdown {
	gap: 6px;
}

.tp-countdown-widget--dark .tp-countdown-item {
	min-width: 40px;
	padding: 4px 5px;
	background-color: rgba(255, 255, 255, 0.08);
	border: 1px solid rgba(255, 255, 255, 0.12);
	border-radius: 8px;
}

.tp-countdown-widget--dark .tp-countdown-number {
	font-size: 20px;
	font-weight: 600;
	color: #fff;
}

.tp-countdown-widget--dark .tp-countdown-label {
	font-size: 10px;
	font-weight: 400;
	text-transform: uppercase;
	color: rgba(255, 255, 255, 0.55);
}

.tp-countdown-widget--dark .tp-countdown-message {
	color: #fff;
}
