/* Gold Pricing – live price box (product page + quick view). Colors follow the specs block variables. */
.gp-live {
	--gp-live-up: #15803d;
	--gp-live-up-bg: #e9f8dc;
	--gp-live-down: #d92d20;
	margin: 10px 0 16px;
	padding: 16px 20px;
	background: var(--gp-surface, #fff);
	border: 1px solid var(--gp-border, #ece2c8);
	border-radius: var(--gp-radius, 16px);
	box-shadow: 0 1px 2px rgba(20, 17, 13, .04);
	color: var(--gp-text, #14110d);
}

/* Explicit Light Mode */
.gp-live.gp-live--light {
	--gp-live-up: #15803d;
	--gp-live-up-bg: #e9f8dc;
	--gp-live-down: #d92d20;
	background: #ffffff;
	border: 1px solid #ece2c8;
	color: #14110d;
}
.gp-live.gp-live--light .gp-live__price { color: #14110d; }
.gp-live.gp-live--light .gp-live__cur { color: #14110d; }
.gp-live.gp-live--light .gp-live__from { color: #8a7f6c; }
.gp-live.gp-live--light .gp-live__sub { color: #8a7f6c; }
.gp-live.gp-live--light .gp-live__sub b { color: #14110d; }

/* Explicit Dark Mode */
.gp-live.gp-live--dark {
	--gp-live-up: #10b981;
	--gp-live-up-bg: rgba(16, 185, 129, 0.16);
	--gp-live-down: #ef4444;
	background: #0f141f;
	border: 1px solid #232d3f;
	box-shadow: 0 4px 16px rgba(0, 0, 0, 0.28);
	color: #f8fafc;
}
.gp-live.gp-live--dark .gp-live__price { color: #ffffff; }
.gp-live.gp-live--dark .gp-live__cur { color: #f2c94c; }
.gp-live.gp-live--dark .gp-live__from { color: #94a3b8; }
.gp-live.gp-live--dark .gp-live__sub { color: #94a3b8; }
.gp-live.gp-live--dark .gp-live__sub b { color: #f8fafc; }
.gp-live.gp-live--dark.is-stale .gp-live__pill { color: #f59e0b; background: rgba(245, 158, 11, 0.18); }
.gp-live.gp-live--dark.is-closed .gp-live__pill { color: #94a3b8; background: rgba(148, 163, 184, 0.15); }
.gp-live.gp-live--dark.is-paused .gp-live__pill { color: #ef4444; background: rgba(239, 68, 68, 0.18); }

.gp-live__row {
	display: flex;
	align-items: center;
	gap: 10px 14px;
}

.gp-live__price {
	font-size: 1.85em;
	font-weight: 800;
	line-height: 1.15;
	letter-spacing: -.01em;
	font-variant-numeric: tabular-nums;
	color: var(--gp-text, #14110d);
	border-radius: 6px;
	transition: color .3s ease;
	white-space: nowrap;
}
.gp-live__cur { font-size: .62em; font-weight: 700; color: var(--gp-text, #14110d); }
.gp-live__from { font-size: .5em; font-weight: 600; color: var(--gp-muted, #8a7f6c); }

/* "Live price" pill with a pulsing dot. */
.gp-live__pill {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 3px 10px;
	border-radius: 99px;
	font-size: .78em;
	font-weight: 700;
	line-height: 1.6;
	white-space: nowrap;
	color: var(--gp-live-up);
	background: var(--gp-live-up-bg);
}
.gp-live__dot {
	width: 7px;
	height: 7px;
	border-radius: 50%;
	background: currentColor;
	box-shadow: 0 0 0 0 currentColor;
	animation: gp-pulse 1.8s ease-out infinite;
}
@keyframes gp-pulse {
	0% { box-shadow: 0 0 0 0 color-mix(in srgb, currentColor 55%, transparent); }
	100% { box-shadow: 0 0 0 7px transparent; }
}
.gp-live.is-stale .gp-live__pill { color: #a15c07; background: #fdf1d8; }
.gp-live.is-closed .gp-live__pill { color: #5f6368; background: #eef0f2; }
.gp-live.is-paused .gp-live__pill { color: var(--gp-live-down); background: #fdecea; }
.gp-live.is-closed .gp-live__dot,
.gp-live.is-paused .gp-live__dot { animation: none; }

/* Change %. */
.gp-live__chg {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	font-size: .9em;
	font-weight: 700;
	font-variant-numeric: tabular-nums;
	color: var(--gp-muted, #8a7f6c);
}
.gp-live__chg[hidden] { display: none; }
.gp-live__arrow { width: 0; height: 0; border-inline: 5px solid transparent; }
.gp-live__chg.is-up { color: var(--gp-live-up); }
.gp-live__chg.is-up .gp-live__arrow { border-bottom: 6px solid currentColor; }
.gp-live__chg.is-down { color: var(--gp-live-down); }
.gp-live__chg.is-down .gp-live__arrow { border-top: 6px solid currentColor; }
.gp-live__chg.is-flat .gp-live__arrow { display: none; }

/* "Sell 41.4599 KWD/g". */
.gp-live__sub {
	margin-top: 6px;
	font-size: .92em;
	color: var(--gp-muted, #8a7f6c);
}
.gp-live__sub b { color: var(--gp-text, #14110d); font-weight: 800; font-variant-numeric: tabular-nums; }

/* Flash when the price moves. */
.gp-live.flash-up .gp-live__price { animation: gp-flash-up 1.2s ease; }
.gp-live.flash-down .gp-live__price { animation: gp-flash-down 1.2s ease; }
@keyframes gp-flash-up { 0%, 40% { color: var(--gp-live-up); background: var(--gp-live-up-bg); } 100% { background: transparent; } }
@keyframes gp-flash-down { 0%, 40% { color: var(--gp-live-down); background: #fdecea; } 100% { background: transparent; } }

/* The live box already shows the selected variation's price. */
.product:has(.gp-live) .woocommerce-variation-price,
.product-lightbox:has(.gp-live) .woocommerce-variation-price { display: none; }

/* Sales paused notice. */
.gp-paused {
	margin: 0 0 14px;
	padding: 10px 14px;
	border-radius: 12px;
	background: #fdecea;
	color: #8a1c13;
	font-size: .92em;
}

@media (max-width: 549px) {
	.gp-live { padding: 14px 16px; }
	.gp-live__price { font-size: 1.6em; }
}

@media (prefers-reduced-motion: reduce) {
	.gp-live__dot, .gp-live.flash-up .gp-live__price, .gp-live.flash-down .gp-live__price { animation: none; }
}
