/*! PROPRIETARY — © 2026 Online Mega Stores Zbigniew Orlowski. Not GPL. Redistribution prohibited — see LICENSE.txt. */
/**
 * Public styles for Lifetime Popups.
 * Uses same classes as editor preview for visual consistency.
 *
 * @package Lifetime_Popups
 * @author  Zbigniew Orlowski
 */

/* ==========================================================================
   CSS Variables
   ========================================================================== */
:root {
	--lftpop-z-index: 999999;
	--lftpop-transition: 0.3s ease;
	--lftpop-shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
	--lftpop-shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
	--lftpop-shadow-lg: 0 4px 20px rgba(0, 0, 0, 0.15);
	--lftpop-radius-sm: 6px;
	--lftpop-radius-md: 12px;
	--lftpop-slate-50: #f8fafc;
	--lftpop-slate-100: #f1f5f9;
	--lftpop-slate-200: #e2e8f0;
	--lftpop-slate-300: #cbd5e1;
	--lftpop-slate-400: #94a3b8;
	--lftpop-slate-600: #475569;
	--lftpop-slate-700: #334155;
	--lftpop-slate-800: #1e293b;
	--lftpop-slate-900: #0f172a;
}

/* ==========================================================================
   Overlay (wrapper) — scrim for modal/fullscreen, transparent hit-through
   wrapper for slide_in / floating_box
   ========================================================================== */
.lftpop-overlay {
	position: fixed;
	inset: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 24px;
	box-sizing: border-box;
	opacity: 0;
	transition: opacity 0.25s ease;
}

.lftpop-overlay.lftpop-open {
	opacity: 1;
}

.lftpop-overlay *,
.lftpop-overlay *::before,
.lftpop-overlay *::after {
	box-sizing: border-box;
}

/* ULTRA: frosted backdrop */
.lftpop-overlay-blur {
	backdrop-filter: blur(6px);
	-webkit-backdrop-filter: blur(6px);
}

/* Non-invasive popups: no scrim, the page stays fully interactive. */
.lftpop-overlay.lftpop-no-overlay {
	background: none !important;
	pointer-events: none;
}

.lftpop-overlay.lftpop-no-overlay .lftpop-popup {
	pointer-events: auto;
}

/* ==========================================================================
   Positions (corner placement for slide_in / floating_box)
   ========================================================================== */
.lftpop-pos-center { align-items: center; justify-content: center; }
.lftpop-pos-bottom_left { align-items: flex-end; justify-content: flex-start; }
.lftpop-pos-bottom_right { align-items: flex-end; justify-content: flex-end; }
.lftpop-pos-top_left { align-items: flex-start; justify-content: flex-start; }
.lftpop-pos-top_right { align-items: flex-start; justify-content: flex-end; }

/* WP admin bar never overlaps top-corner popups. */
body.admin-bar .lftpop-pos-top_left,
body.admin-bar .lftpop-pos-top_right {
	padding-top: 56px;
}

@media screen and (max-width: 782px) {
	body.admin-bar .lftpop-pos-top_left,
	body.admin-bar .lftpop-pos-top_right {
		padding-top: 62px;
	}
}

/* ==========================================================================
   Popup Card
   ========================================================================== */
.lftpop-popup {
	position: relative;
	width: 100%;
	max-width: 560px;
	max-height: calc(100vh - 48px);
	max-height: calc(100dvh - 48px);
	overflow-x: hidden;
	overflow-y: auto;
	background: #ffffff;
}

/* Sizes */
.lftpop-size-small { max-width: 400px; }
.lftpop-size-medium { max-width: 560px; }
.lftpop-size-large { max-width: 720px; }

/* Corner cards (slide-in / floating) read narrower than centered modals. */
.lftpop-type-slide_in .lftpop-popup.lftpop-size-small,
.lftpop-type-floating_box .lftpop-popup.lftpop-size-small { max-width: 300px; }
.lftpop-type-slide_in .lftpop-popup.lftpop-size-medium,
.lftpop-type-floating_box .lftpop-popup.lftpop-size-medium { max-width: 380px; }
.lftpop-type-slide_in .lftpop-popup.lftpop-size-large,
.lftpop-type-floating_box .lftpop-popup.lftpop-size-large { max-width: 460px; }
.lftpop-size-custom { max-width: 92vw; }

/* Fullscreen (welcome mat) */
.lftpop-type-fullscreen {
	padding: 0;
}

.lftpop-type-fullscreen .lftpop-popup {
	width: 100%;
	height: 100%;
	max-width: none;
	max-height: none;
	border-radius: 0 !important;
	display: flex;
	align-items: center;
	justify-content: center;
}

.lftpop-type-fullscreen .lftpop-popup-inner {
	width: 100%;
	max-width: 820px;
}

.lftpop-type-fullscreen .lftpop-popup-body {
	padding: 48px 32px;
}

/* ==========================================================================
   Inner Layout & Image
   ========================================================================== */
.lftpop-popup-inner {
	position: relative;
	z-index: 2;
	display: flex;
	flex-direction: column;
}

.lftpop-popup-body {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 18px;
	width: 100%;
	padding: 36px 32px;
}

.lftpop-popup-image {
	display: block;
	max-width: 100%;
}

.lftpop-layout-top .lftpop-popup-image {
	width: 100%;
	max-height: 240px;
	object-fit: cover;
}

.lftpop-layout-left .lftpop-popup-inner {
	flex-direction: row;
	align-items: stretch;
}

.lftpop-layout-right .lftpop-popup-inner {
	flex-direction: row-reverse;
	align-items: stretch;
}

.lftpop-layout-left .lftpop-popup-image,
.lftpop-layout-right .lftpop-popup-image {
	width: 45%;
	max-height: none;
	object-fit: cover;
}

.lftpop-layout-left .lftpop-popup-body,
.lftpop-layout-right .lftpop-popup-body {
	width: 55%;
	justify-content: center;
}

/* ==========================================================================
   Offer Panel — a solid-color block with a giant headline in place of a photo
   ========================================================================== */
.lftpop-layout-panel_left .lftpop-popup-inner {
	flex-direction: row;
	align-items: stretch;
}

.lftpop-layout-panel_right .lftpop-popup-inner {
	flex-direction: row-reverse;
	align-items: stretch;
}

.lftpop-layout-panel_left .lftpop-popup-panel,
.lftpop-layout-panel_right .lftpop-popup-panel {
	width: 45%;
	flex: 0 0 45%;
}

.lftpop-layout-panel_left .lftpop-popup-body,
.lftpop-layout-panel_right .lftpop-popup-body {
	width: 55%;
	justify-content: center;
}

.lftpop-popup-panel {
	position: relative;
	display: flex;
	flex-direction: column;
	min-height: 340px;
	padding: 34px 34px 30px;
	overflow: hidden;
	isolation: isolate;
}

.lftpop-panel-eyebrow {
	position: relative;
	z-index: 1;
	font-size: 11px;
	font-weight: 800;
	letter-spacing: 0.14em;
	text-transform: uppercase;
}

.lftpop-panel-headline {
	position: relative;
	z-index: 1;
	margin-top: auto;
	font-family: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
	font-size: clamp(52px, 8vw, 100px);
	font-weight: 800;
	line-height: 0.86;
	letter-spacing: -0.05em;
	text-transform: uppercase;
	overflow-wrap: break-word;
}

/* Number + unit split (e.g. big "20" with a small "%" beside it). */
.lftpop-panel-hero {
	position: relative;
	z-index: 1;
	margin-top: auto;
	display: flex;
	align-items: flex-start;
	gap: 6px;
}

.lftpop-panel-number {
	font-family: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
	font-size: clamp(78px, 12vw, 142px);
	font-weight: 800;
	line-height: 0.8;
	letter-spacing: -0.06em;
	white-space: nowrap;
}

.lftpop-panel-unit {
	font-family: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
	font-size: clamp(34px, 4.5vw, 56px);
	font-weight: 800;
	line-height: 1;
	margin-top: 0.12em;
}

.lftpop-panel-caption {
	position: relative;
	z-index: 1;
	margin-top: 22px;
	max-width: 280px;
	font-family: "Playfair Display", Georgia, "Times New Roman", serif;
	font-size: 27px;
	line-height: 1.06;
	letter-spacing: -0.02em;
}

.lftpop-popup-panel[data-watermark]::after {
	content: attr(data-watermark);
	position: absolute;
	z-index: 0;
	left: -14px;
	bottom: -28px;
	color: inherit;
	-webkit-text-fill-color: transparent;
	-webkit-text-stroke: 1.5px currentColor;
	opacity: 0.22;
	font-family: "Inter", ui-sans-serif, system-ui, sans-serif;
	font-size: 138px;
	font-weight: 900;
	line-height: 1;
	letter-spacing: -0.09em;
	white-space: nowrap;
	transform: rotate(-90deg) translateX(10px);
	transform-origin: left bottom;
	pointer-events: none;
}

/* Background image layout: full-card photo + readable scrim + card height. */
.lftpop-popup.lftpop-layout-background {
	min-height: 360px;
	display: flex;
	align-items: center;
}

.lftpop-popup.lftpop-layout-background::before {
	content: "";
	position: absolute;
	inset: 0;
	background: linear-gradient(to top, rgba(9, 11, 18, 0.86) 0%, rgba(9, 11, 18, 0.55) 52%, rgba(9, 11, 18, 0.42) 100%);
	z-index: 1;
	pointer-events: none;
}

.lftpop-popup.lftpop-layout-background .lftpop-popup-inner {
	position: relative;
	z-index: 2;
	width: 100%;
}

/* ULTRA glass: content sits on a frosted panel over the photo. */
.lftpop-popup.lftpop-layout-background.lftpop-glass-effect .lftpop-popup-body {
	margin: 20px;
	padding: 26px 24px;
	background: rgba(255, 255, 255, 0.1);
	backdrop-filter: blur(9px);
	-webkit-backdrop-filter: blur(9px);
	border: 1px solid rgba(255, 255, 255, 0.22);
	border-radius: 16px;
	box-shadow: 0 8px 30px rgba(0, 0, 0, 0.25);
}

/* ==========================================================================
   Content Elements
   ========================================================================== */
.lftpop-popup-heading {
	margin: 0;
	width: 100%;
	font-weight: 800;
	line-height: 1.2;
}

.lftpop-popup-message {
	margin: 0;
	width: 100%;
	line-height: 1.55;
	opacity: 0.9;
}

/* Text Alignment Classes */
.lftpop-text-left { text-align: left; }
.lftpop-text-center { text-align: center; }
.lftpop-text-right { text-align: right; }

/* ==========================================================================
   Close Button
   ========================================================================== */
.lftpop-popup-close {
	position: absolute;
	top: 12px;
	right: 12px;
	z-index: 30;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	padding: 0;
	background: rgba(0, 0, 0, 0.08);
	border: none;
	border-radius: 50%;
	cursor: pointer;
	color: inherit;
	opacity: 0.75;
	transition: opacity 0.2s ease, background 0.2s ease;
}

.lftpop-popup-close:hover {
	opacity: 1;
	background: rgba(0, 0, 0, 0.16);
}

.lftpop-popup-close:focus-visible {
	outline: 2px solid #6366f1;
	outline-offset: 2px;
	opacity: 1;
}

/* close_delay: the X stays invisible until JS reveals it. */
.lftpop-popup-close.lftpop-close-waiting {
	opacity: 0;
	pointer-events: none;
}

/* ==========================================================================
   Lead Form Layout (input/button visuals come from shared styles below)
   ========================================================================== */
.lftpop-popup-lead-form {
	display: flex;
	flex-direction: column;
	gap: 12px;
	width: 100%;
	max-width: 360px;
	margin: 0;
	padding: 0;
}

.lftpop-popup-lead-form .lftpop-popup-input {
	width: 100%;
}

.lftpop-popup-gdpr {
	display: flex;
	align-items: flex-start;
	gap: 8px;
	font-size: 12px;
	line-height: 1.4;
	text-align: left;
	opacity: 0.8;
	cursor: pointer;
}

.lftpop-popup-gdpr input {
	margin-top: 2px;
	flex-shrink: 0;
}

.lftpop-success-message {
	font-weight: 700;
}

/* ==========================================================================
   Magic Border (ULTRA) — animated gradient FRAME around the card
   ========================================================================== */
.lftpop-magic-border {
	position: absolute;
	inset: 0;
	z-index: 25;
	pointer-events: none;
	border-radius: inherit;
	padding: 3px;
	-webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
	mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
	-webkit-mask-composite: xor;
	mask-composite: exclude;
	background-size: 200% 100%;
}

.lftpop-magic-flow {
	animation: lftpopMagicFlow 3s linear infinite;
}

@keyframes lftpopMagicFlow {
	0% { background-position: 0% 50%; }
	100% { background-position: 200% 50%; }
}


/* ==========================================================================
   Teaser Chip (reopens a closed popup)
   ========================================================================== */
.lftpop-teaser {
	position: fixed;
	bottom: 24px;
	display: inline-flex;
	align-items: center;
	gap: 2px;
	padding: 0 6px 0 0;
	border-radius: 999px;
	box-shadow: 0 8px 24px rgba(0, 0, 0, 0.22);
	font-size: 14px;
	font-weight: 700;
	animation: lftpopTeaserIn 0.35s ease;
}

.lftpop-teaser-right { right: 24px; }
.lftpop-teaser-left { left: 24px; }

.lftpop-teaser-hidden {
	display: none !important;
}

.lftpop-teaser button {
	display: inline-flex;
	align-items: center;
	background: none;
	border: none;
	color: inherit;
	font: inherit;
	cursor: pointer;
	padding: 0;
}

.lftpop-teaser-open {
	padding: 12px 4px 12px 18px !important;
	white-space: nowrap;
}

.lftpop-teaser-close {
	padding: 8px !important;
	border-radius: 50%;
	opacity: 0.7;
}

.lftpop-teaser-close:hover {
	opacity: 1;
}

@keyframes lftpopTeaserIn {
	from { opacity: 0; transform: translateY(12px); }
	to { opacity: 1; transform: none; }
}

@media (max-width: 768px) {
	.lftpop-teaser { bottom: 16px; }
	.lftpop-teaser-right { right: 16px; }
	.lftpop-teaser-left { left: 16px; }
}

/* Google-compliant mode: the teaser chip stretched into a discreet bottom
   banner (well under 25% of the viewport); tapping opens the full popup. */
.lftpop-compliant-banner {
	left: 12px;
	right: 12px;
	bottom: 12px;
	justify-content: space-between;
	background: #0f172a;
	color: #ffffff;
	box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

.lftpop-compliant-banner .lftpop-teaser-open {
	flex: 1 1 auto;
	justify-content: flex-start;
	text-align: left;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

/* Countdown timer centered inside the popup body. */
.lftpop-popup-body .lftpop-popup-countdown {
	justify-content: center;
}

/* ==========================================================================
   Gamification — shared (M3)
   ========================================================================== */
.lftpop-game {
	width: 100%;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 18px;
}

.lftpop-game-form {
	display: flex;
	flex-direction: column;
	gap: 12px;
	width: 100%;
	max-width: 320px;
	margin: 0;
	padding: 0;
}

.lftpop-game-form .lftpop-popup-input {
	width: 100%;
}

.lftpop-game-result {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 14px;
	width: 100%;
}

.lftpop-game-result-msg {
	font-size: 17px;
	font-weight: 800;
	line-height: 1.4;
	text-align: center;
}

.lftpop-game-result .lftpop-popup-coupon {
	height: 44px;
	padding: 0 28px;
	font-weight: 700;
	border: 2px dashed currentColor;
	border-radius: 10px;
	background: transparent;
	color: inherit;
	cursor: pointer;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	transition: all 0.2s ease;
}

/* One-shot confetti burst */
.lftpop-confetti {
	position: absolute;
	inset: 0;
	overflow: hidden;
	pointer-events: none;
	z-index: 40;
}

.lftpop-confetti span {
	position: absolute;
	top: -14px;
	width: 7px;
	height: 11px;
	border-radius: 2px;
	opacity: 0.95;
	animation: lftpopConfettiFall 1.6s ease-in forwards;
}

@keyframes lftpopConfettiFall {
	0% { transform: translateY(0) rotate(0deg); opacity: 1; }
	100% { transform: translateY(115vh) rotate(540deg); opacity: 0; }
}

/* ==========================================================================
   Spin-to-Win Wheel
   ========================================================================== */
.lftpop-game-wheel {
	flex-direction: row;
	align-items: center;
	justify-content: center;
	gap: 28px;
	text-align: left;
}

.lftpop-game-wheel .lftpop-game-side {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 16px;
	flex: 1 1 220px;
	min-width: 0;
}

.lftpop-wheel-wrap {
	position: relative;
	flex: 0 0 auto;
	width: 250px;
	height: 250px;
}

.lftpop-wheel {
	width: 100%;
	height: 100%;
	display: block;
	filter: drop-shadow(0 8px 24px rgba(0, 0, 0, 0.25));
}

.lftpop-wheel-rotor {
	transform-origin: 150px 150px;
	transform-box: view-box;
	will-change: transform;
}

.lftpop-wheel-pointer {
	transform-origin: 150px 12px;
	transform-box: view-box;
	filter: drop-shadow(0 2px 3px rgba(0, 0, 0, 0.3));
}

/* Marquee bulbs on the ring — alternating flicker. */
@keyframes lftpopWheelBulb {
	0%, 100% { opacity: 1; }
	50% { opacity: 0.35; }
}

.lftpop-wheel-bulb {
	animation: lftpopWheelBulb 1.2s ease-in-out infinite;
}

.lftpop-wheel-bulb-alt {
	animation: lftpopWheelBulb 1.2s ease-in-out infinite;
	animation-delay: 0.6s;
}

/* Pointer wobble only while the wheel is spinning. */
@keyframes lftpopWheelWobble {
	0%, 100% { transform: rotate(0deg); }
	25% { transform: rotate(-7deg); }
	75% { transform: rotate(7deg); }
}

.lftpop-wheel-spinning .lftpop-wheel-pointer {
	animation: lftpopWheelWobble 0.3s ease-in-out infinite;
}

@media (prefers-reduced-motion: reduce) {
	.lftpop-wheel-bulb,
	.lftpop-wheel-bulb-alt,
	.lftpop-wheel-spinning .lftpop-wheel-pointer {
		animation: none;
	}
}

/* ==========================================================================
   Gift Boxes
   ========================================================================== */
.lftpop-gift-grid {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 18px;
}

.lftpop-gift {
	position: relative;
	width: 86px;
	height: 86px;
	padding: 0;
	border: none;
	background: none;
	cursor: pointer;
	transition: transform 0.2s ease;
}

.lftpop-gift:hover {
	animation: lftpopGiftBounce 0.5s ease;
}

.lftpop-gift:focus-visible {
	outline: 2px solid #6366f1;
	outline-offset: 3px;
	border-radius: 10px;
}

.lftpop-gift-body {
	position: absolute;
	left: 8%;
	right: 8%;
	bottom: 0;
	height: 58%;
	background: linear-gradient(180deg, #ef4444, #b91c1c);
	border-radius: 0 0 8px 8px;
}

.lftpop-gift-lid {
	position: absolute;
	left: 0;
	right: 0;
	top: 16%;
	height: 22%;
	background: linear-gradient(180deg, #f87171, #dc2626);
	border-radius: 5px;
	box-shadow: 0 2px 4px rgba(0, 0, 0, 0.18);
	transition: transform 0.4s ease, opacity 0.4s ease;
}

.lftpop-gift-bow {
	position: absolute;
	left: 50%;
	top: 2%;
	width: 26%;
	height: 100%;
	transform: translateX(-50%);
	pointer-events: none;
}

.lftpop-gift-bow::before {
	content: "";
	position: absolute;
	inset: 14% 32% 0 32%;
	background: #fbbf24;
}

.lftpop-gift-bow::after {
	content: "";
	position: absolute;
	top: 0;
	left: 50%;
	transform: translateX(-50%);
	width: 20px;
	height: 12px;
	border: 4px solid #fbbf24;
	border-radius: 50% 50% 0 0 / 100% 100% 0 0;
	border-bottom: none;
}

@keyframes lftpopGiftBounce {
	0%, 100% { transform: translateY(0); }
	40% { transform: translateY(-8px); }
	70% { transform: translateY(-3px); }
}

.lftpop-gift-opening {
	animation: lftpopGiftShake 0.6s ease-in-out;
}

@keyframes lftpopGiftShake {
	0%, 100% { transform: rotate(0deg); }
	20%, 60% { transform: rotate(-7deg); }
	40%, 80% { transform: rotate(7deg); }
}

.lftpop-gift-open .lftpop-gift-lid {
	transform: translateY(-26px) rotate(-14deg);
	opacity: 0;
}

.lftpop-gift-open .lftpop-gift-bow::after {
	opacity: 0;
}

.lftpop-gift-faded {
	opacity: 0.25;
	pointer-events: none;
	transition: opacity 0.4s ease;
}

/* ==========================================================================
   Scratch Card
   ========================================================================== */
.lftpop-scratch-wrap {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 12px;
	width: 100%;
}

.lftpop-scratch-off-container {
	position: relative;
	width: 300px;
	max-width: 100%;
	height: 170px;
	border-radius: 14px;
	overflow: hidden;
	box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1), 0 6px 18px rgba(0, 0, 0, 0.12);
}

.lftpop-scratch-code {
	position: absolute;
	inset: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	background: #ffffff;
	color: #1e293b;
	font-family: monospace;
	font-weight: bold;
	font-size: 24px;
	letter-spacing: 3px;
	user-select: none;
	z-index: 10;
}

.lftpop-scratch-canvas {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	cursor: crosshair;
	touch-action: none;
	z-index: 20;
}

.lftpop-scratch-gate {
	position: absolute;
	inset: 0;
	z-index: 30;
	display: flex;
	align-items: center;
	justify-content: center;
	background: rgba(15, 23, 42, 0.78);
	backdrop-filter: blur(2px);
	padding: 14px;
}

.lftpop-scratch-gate-form {
	display: flex;
	flex-direction: column;
	gap: 8px;
	width: 100%;
	max-width: 240px;
	margin: 0;
}

.lftpop-scratch-gate-form .lftpop-popup-input {
	width: 100%;
	height: 38px;
}

.lftpop-scratch-gate .lftpop-popup-gdpr {
	color: #e2e8f0;
}

.lftpop-scratch-hint {
	font-size: 13px;
	font-weight: 600;
	opacity: 0.75;
}

/* ==========================================================================
   Multi-step (Yes/No)
   ========================================================================== */
.lftpop-steps {
	width: 100%;
	overflow: hidden;
}

.lftpop-step {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 18px;
	width: 100%;
}

.lftpop-step-question {
	font-size: 17px;
	line-height: 1.5;
	width: 100%;
}

.lftpop-step-buttons {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 12px;
	width: 100%;
}

.lftpop-step-no {
	background: transparent;
	border: 2px solid currentColor;
	color: inherit;
	opacity: 0.65;
}

.lftpop-step-no:hover {
	opacity: 1;
}

.lftpop-step-out {
	animation: lftpopStepOut 0.25s ease forwards;
}

.lftpop-step-in {
	animation: lftpopStepIn 0.35s ease;
}

@keyframes lftpopStepOut {
	to { transform: translateX(-40px); opacity: 0; }
}

@keyframes lftpopStepIn {
	from { transform: translateX(40px); opacity: 0; }
	to { transform: none; opacity: 1; }
}

/* ==========================================================================
   Video Popup
   ========================================================================== */
.lftpop-video-wrap {
	position: relative;
	width: 100%;
	aspect-ratio: 16 / 9;
	border-radius: 10px;
	overflow: hidden;
	background: #000;
}

.lftpop-video-wrap iframe,
.lftpop-video-wrap video {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	border: 0;
}

/* ==========================================================================
   Gamification — mobile
   ========================================================================== */
@media (max-width: 768px) {
	.lftpop-game-wheel {
		flex-direction: column;
		gap: 18px;
	}

	.lftpop-wheel-wrap {
		width: 240px;
		height: 240px;
	}

	.lftpop-gift {
		width: 72px;
		height: 72px;
	}

	.lftpop-scratch-off-container {
		width: 280px;
		height: 160px;
	}
}

/* ==========================================================================
   Visibility States (JS-controlled) & Exit Animations
   ========================================================================== */
.lftpop-overlay.lftpop-hidden,
.lftpop-overlay.lftpop-pending {
	display: none !important;
}

.lftpop-overlay.lftpop-closing {
	opacity: 0;
}

.lftpop-exit-fade_out { animation: lftpopExitFade 0.3s ease forwards; }
.lftpop-exit-zoom_out { animation: lftpopExitZoom 0.3s ease forwards; }
.lftpop-exit-slide_down { animation: lftpopExitSlideDown 0.3s ease forwards; }
.lftpop-exit-slide_up { animation: lftpopExitSlideUp 0.3s ease forwards; }

@keyframes lftpopExitFade {
	to { opacity: 0; }
}

@keyframes lftpopExitZoom {
	to { opacity: 0; transform: scale(0.85); }
}

@keyframes lftpopExitSlideDown {
	to { opacity: 0; transform: translateY(40px); }
}

@keyframes lftpopExitSlideUp {
	to { opacity: 0; transform: translateY(-40px); }
}

/* Scroll lock while a modal/fullscreen popup is open (padding-right is set
   by JS to compensate for the scrollbar so the page doesn't jump). */
html.lftpop-scroll-lock {
	overflow: hidden !important;
}

/* ==========================================================================
   Reduced Motion
   ========================================================================== */
.lftpop-reduced-motion .lftpop-popup,
.lftpop-reduced-motion .lftpop-popup * {
	animation: none !important;
}

@media (prefers-reduced-motion: reduce) {
	.lftpop-overlay .lftpop-popup,
	.lftpop-overlay .lftpop-popup * {
		animation: none !important;
	}
}

/* ==========================================================================
   Device Targeting — enforced with media queries (768px breakpoint)
   ========================================================================== */
@media screen and (max-width: 768px) {
	.lftpop-overlay.lftpop-devices-desktop {
		display: none !important;
	}
}

@media screen and (min-width: 769px) {
	.lftpop-overlay.lftpop-devices-mobile {
		display: none !important;
	}
}

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 768px) {
	.lftpop-overlay {
		padding: 16px;
	}

	.lftpop-popup {
		max-width: 100% !important;
	}

	.lftpop-layout-left .lftpop-popup-inner,
	.lftpop-layout-right .lftpop-popup-inner,
	.lftpop-layout-panel_left .lftpop-popup-inner,
	.lftpop-layout-panel_right .lftpop-popup-inner {
		flex-direction: column;
	}

	.lftpop-layout-left .lftpop-popup-image,
	.lftpop-layout-right .lftpop-popup-image {
		width: 100%;
		max-height: 180px;
	}

	.lftpop-layout-left .lftpop-popup-body,
	.lftpop-layout-right .lftpop-popup-body,
	.lftpop-layout-panel_left .lftpop-popup-panel,
	.lftpop-layout-panel_right .lftpop-popup-panel,
	.lftpop-layout-panel_left .lftpop-popup-body,
	.lftpop-layout-panel_right .lftpop-popup-body {
		width: 100%;
		flex-basis: auto;
	}

	.lftpop-popup-panel {
		min-height: 200px;
		padding: 24px 25px 22px;
	}

	.lftpop-panel-headline {
		font-size: 62px;
	}

	.lftpop-panel-number {
		font-size: 96px;
	}

	.lftpop-panel-unit {
		font-size: 40px;
	}

	.lftpop-panel-caption {
		font-size: 22px;
	}

	.lftpop-popup-body {
		padding: 28px 20px;
	}

	.lftpop-popup-close {
		width: 44px;
		height: 44px;
	}

	.lftpop-type-slide_in .lftpop-popup,
	.lftpop-type-floating_box .lftpop-popup {
		width: 100%;
	}

	.lftpop-type-fullscreen .lftpop-popup-body {
		padding: 32px 20px calc(32px + env(safe-area-inset-bottom));
	}
}

/* ==========================================================================
   Buttons
   ========================================================================== */
.lftpop-popup-button {
	font-size: 14px;
	font-weight: 700;
	height: 36px;
	padding: 0 24px;
	border-radius: 999px;
	border: none;
	cursor: pointer;
	transition: all 0.2s ease;
	white-space: nowrap;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	text-decoration: none;
}

.lftpop-popup-button:hover {
	opacity: 0.9;
	transform: scale(1.02);
}


/* ==========================================================================
   Coupon Element
   ========================================================================== */
.lftpop-popup-coupon {
	display: inline-flex;
	align-items: center;
	gap: 8px;
}

.lftpop-popup-coupon-code {
	padding: 8px 16px;
	font-family: ui-monospace, monospace;
	font-weight: 700;
	transition: all 0.3s ease;
	display: inline-flex;
	align-items: center;
}

.lftpop-popup-coupon-btn {
	font-size: 14px;
	font-weight: 700;
	height: 36px;
	padding: 0 16px;
	border: none;
	cursor: pointer;
	transition: all 0.2s ease;
	white-space: nowrap;
	display: inline-flex;
	align-items: center;
	justify-content: center;
}

.lftpop-popup-coupon-btn:hover {
	opacity: 0.9;
}

/* Coupon hidden state - only show button */
.lftpop-popup-coupon.lftpop-coupon-hidden .lftpop-popup-coupon-code {
	display: none;
}

/* Coupon revealed state - hide button, show code */
.lftpop-popup-coupon.lftpop-coupon-revealed .lftpop-popup-coupon-btn {
	display: none;
}


/* ==========================================================================
   Coupon Styles
   ========================================================================== */
.lftpop-popup-coupon-dashed {
	border: 2px dashed currentColor;
	background: transparent;
}

.lftpop-popup-coupon-solid {
	border: none;
}

.lftpop-popup-coupon-outline {
	border: 2px solid currentColor;
	background: transparent;
}


/* ==========================================================================
   Lead Form
   ========================================================================== */
.lftpop-popup-form {
	display: flex;
	align-items: center;
	gap: 8px;
}

.lftpop-popup-input {
	padding: 8px 16px;
	font-size: 14px;
	border: none;
	border-radius: var(--lftpop-radius-sm);
	background: rgba(255, 255, 255, 0.9);
	color: var(--lftpop-slate-900);
	outline: none;
}

.lftpop-popup-input::placeholder {
	color: var(--lftpop-slate-400);
}

.lftpop-popup-input:focus {
	background: #fff;
}


/* ==========================================================================
   Countdown Timer
   ========================================================================== */
.lftpop-popup-countdown {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	font-family: ui-monospace, monospace;
	font-weight: 700;
	font-size: 14px;
}

.lftpop-countdown-unit,
.lftpop-popup-countdown-unit {
	background: rgba(0, 0, 0, 0.2);
	padding: 4px 8px;
	border-radius: 4px;
	min-width: 28px;
	text-align: center;
}

.lftpop-countdown-sep {
	opacity: 0.7;
}

.lftpop-countdown-value {
	font-family: ui-monospace, monospace;
}

/* ==========================================================================
   Timer Design Variants (matching admin preview)
   ========================================================================== */

/* Plain Timer */
.lftpop-timer-plain {
	font-family: ui-monospace, monospace;
	font-weight: 700;
	letter-spacing: 0.1em;
}


/* Classic Timer (default) */
.lftpop-timer-classic .lftpop-timer-unit {
	background: rgba(0, 0, 0, 0.2);
	padding: 4px 6px;
	border-radius: 4px;
	min-width: 28px;
	text-align: center;
}

/* Solid Timer */
.lftpop-timer-solid {
	color: #000;
}

.lftpop-timer-solid .lftpop-timer-unit {
	background: #fff;
	padding: 4px 6px;
	border-radius: 6px;
	min-width: 28px;
	text-align: center;
	box-shadow: var(--lftpop-shadow-sm);
}

/* Outline Timer */
.lftpop-timer-outline .lftpop-timer-unit {
	border: 1px solid currentColor;
	padding: 4px 6px;
	border-radius: 4px;
	min-width: 28px;
	text-align: center;
}

/* Circle Timer */
.lftpop-timer-circle {
	gap: 6px;
	font-size: 12px;
}

.lftpop-timer-circle .lftpop-timer-unit {
	width: 32px;
	height: 32px;
	border: 2px solid currentColor;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
}

/* Pill Timer */
.lftpop-timer-pill {
	background: rgba(0, 0, 0, 0.2);
	border-radius: 999px;
	padding: 4px 12px;
	letter-spacing: 0.1em;
	border: 1px solid rgba(255, 255, 255, 0.1);
	box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* Split Timer */
.lftpop-timer-split {
	background: #fff;
	color: #000;
	border-radius: 8px;
	overflow: hidden;
	box-shadow: var(--lftpop-shadow-sm);
	border: 1px solid var(--lftpop-slate-200);
}

.lftpop-timer-split .lftpop-timer-unit {
	padding: 4px 8px;
	background: var(--lftpop-slate-50);
}

.lftpop-timer-split .lftpop-timer-divider {
	width: 1px;
	height: 16px;
	background: var(--lftpop-slate-300);
}

/* Digital Timer */
.lftpop-timer-digital {
	background: rgba(0, 0, 0, 0.8);
	color: #34d399;
	padding: 4px 12px;
	border-radius: 4px;
	border: 1px solid #065f46;
	box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.3);
	text-shadow: 0 0 5px rgba(52, 211, 153, 0.5);
}

/* Cards Timer */
.lftpop-timer-cards {
	color: var(--lftpop-slate-800);
}

.lftpop-timer-cards .lftpop-timer-unit {
	background: #fff;
	padding: 4px 6px;
	border-radius: 4px;
	min-width: 28px;
	text-align: center;
	box-shadow: var(--lftpop-shadow-md);
	border-bottom: 2px solid var(--lftpop-slate-200);
}

/* Neon Timer */
.lftpop-timer-neon {
	border: 2px solid currentColor;
	border-radius: 8px;
	padding: 2px 12px;
	text-shadow: 0 0 10px currentColor;
	box-shadow: inset 0 0 10px currentColor;
}

/* Bubbles Timer */
.lftpop-timer-bubbles {
	gap: 6px;
	font-size: 12px;
	color: #fff;
}

.lftpop-timer-bubbles .lftpop-timer-unit {
	width: 32px;
	height: 32px;
	background: rgba(0, 0, 0, 0.3);
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	backdrop-filter: blur(4px);
	box-shadow: var(--lftpop-shadow-sm);
}

/* Blocks Timer */
.lftpop-timer-blocks {
	gap: 2px;
	color: #fff;
}

.lftpop-timer-blocks .lftpop-timer-unit {
	background: var(--lftpop-slate-900);
	padding: 4px 6px;
	min-width: 28px;
	text-align: center;
}

/* Sketch Timer */
.lftpop-timer-sketch .lftpop-timer-unit {
	border: 2px dashed currentColor;
	padding: 4px 6px;
	border-radius: 8px;
	min-width: 28px;
	text-align: center;
}

/* Flip Timer */
.lftpop-timer-flip {
	color: #fff;
}

.lftpop-timer-flip .lftpop-timer-unit {
	background: linear-gradient(to bottom, var(--lftpop-slate-700), var(--lftpop-slate-800));
	padding: 4px 6px;
	border-radius: 4px;
	min-width: 28px;
	text-align: center;
	border-bottom: 2px solid rgba(0, 0, 0, 0.2);
	box-shadow: var(--lftpop-shadow-sm);
}

/* Cyber Timer */
.lftpop-timer-cyber {
	border-left: 2px solid currentColor;
	border-right: 2px solid currentColor;
	padding: 4px 12px;
	gap: 8px;
}

.lftpop-timer-cyber .lftpop-timer-divider {
	opacity: 0.5;
}

/* Elegant Timer */
.lftpop-timer-elegant {
	font-family: Georgia, serif;
	font-style: italic;
	font-weight: 700;
	letter-spacing: 0.05em;
	font-size: 16px;
	border-bottom: 1px solid currentColor;
	padding-bottom: 2px;
}

.lftpop-timer-elegant .lftpop-timer-label {
	font-size: 10px;
	font-style: normal;
	opacity: 0.7;
	margin-left: 2px;
}

/* Paper Timer */
.lftpop-timer-paper {
	gap: 8px;
	color: var(--lftpop-slate-800);
	transform: rotate(-1deg);
}

.lftpop-timer-paper .lftpop-timer-unit {
	background: #fef3c7;
	padding: 4px 6px;
	box-shadow: var(--lftpop-shadow-sm);
	border: 1px solid #fde68a;
}

.lftpop-timer-paper .lftpop-timer-unit:nth-child(1) {
	transform: rotate(2deg);
}

.lftpop-timer-paper .lftpop-timer-unit:nth-child(2) {
	transform: rotate(-1deg);
}

.lftpop-timer-paper .lftpop-timer-unit:nth-child(3) {
	transform: rotate(1deg);
}

/* Underline Timer */
.lftpop-timer-underline {
	gap: 8px;
}

.lftpop-timer-underline .lftpop-timer-unit {
	display: flex;
	flex-direction: column;
	align-items: center;
}

.lftpop-timer-underline .lftpop-timer-line {
	width: 100%;
	height: 2px;
	background: currentColor;
	opacity: 0.5;
	margin-top: 2px;
}

/* Thick Timer */
.lftpop-timer-thick {
	border: 4px solid currentColor;
	padding: 2px 8px;
	font-weight: 900;
	letter-spacing: -0.05em;
}

/* LCD Timer */
.lftpop-timer-lcd {
	background: #000;
	color: #84cc16;
	padding: 2px 8px;
	border: 2px solid #3f6212;
	border-radius: 2px;
	box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.3);
}

.lftpop-timer-lcd .lftpop-timer-unit {
	opacity: 0.8;
}

@keyframes lftpop-blink {
	0%, 100% {
		opacity: 1;
	}
	50% {
		opacity: 0.3;
	}
}

.lftpop-timer-lcd .lftpop-timer-colon {
	animation: lftpop-blink 1s ease-in-out infinite;
}


/* ==========================================================================
   Atmosphere Particles
   ========================================================================== */
.lftpop-atmosphere-container {
	position: absolute;
	inset: 0;
	overflow: hidden;
	pointer-events: none;
}

.lftpop-atmosphere-particle {
	position: absolute;
	border-radius: 50%;
}

.lftpop-atm-snow {
	background: #fff;
	animation: lftpopParticleFall 3s linear infinite;
}

.lftpop-atm-sparkle {
	background: #ffd700;
	box-shadow: 0 0 6px #ffd700;
	animation: lftpopParticleFloat 3s ease-in-out infinite;
}

.lftpop-atm-hearts {
	background: #ff6b6b;
	clip-path: polygon(50% 0%, 61% 35%, 98% 35%, 68% 57%, 79% 91%, 50% 70%, 21% 91%, 32% 57%, 2% 35%, 39% 35%);
	border-radius: 0;
	animation: lftpopParticleFloat 3s ease-in-out infinite;
}

.lftpop-atm-confetti {
	border-radius: 2px;
	animation: lftpopParticleFall 3s linear infinite;
}

.lftpop-atm-confetti:nth-child(odd) {
	background: #ff6b6b;
}
.lftpop-atm-confetti:nth-child(even) {
	background: #4ecdc4;
}
.lftpop-atm-confetti:nth-child(3n) {
	background: #ffe66d;
}

.lftpop-atm-money {
	background: #22c55e;
	border-radius: 2px;
	animation: lftpopParticleFall 3s linear infinite;
}

/* Particle Animation Keyframes */
@keyframes lftpopParticleFall {
	0% { transform: translateY(-20px) rotate(0deg); opacity: 1; }
	100% { transform: translateY(100px) rotate(360deg); opacity: 0; }
}

@keyframes lftpopParticleFallVertical {
	0% { transform: translateY(-20px) rotate(0deg); opacity: 1; }
	100% { transform: translateY(100vh) rotate(360deg); opacity: 0; }
}

@keyframes lftpopParticleRain {
	0% { transform: translateY(-20px); opacity: 1; }
	100% { transform: translateY(100px); opacity: 0.3; }
}

@keyframes lftpopParticleRainVertical {
	0% { transform: translateY(-20px); opacity: 1; }
	100% { transform: translateY(100vh); opacity: 0.3; }
}

@keyframes lftpopParticleFloat {
	0% { transform: translateY(0); opacity: 0; }
	10% { opacity: 1; }
	100% { transform: translateY(-100px); opacity: 0; }
}

@keyframes lftpopParticleFloatVertical {
	0% { transform: translateY(0); opacity: 0; }
	10% { opacity: 1; }
	100% { transform: translateY(-100vh); opacity: 0; }
}

@keyframes lftpopParticleFire {
	0% { transform: translateY(0) scale(1); opacity: 0.6; }
	50% { transform: translateY(-30px) scale(1.2); opacity: 0.8; }
	100% { transform: translateY(-60px) scale(0.5); opacity: 0; }
}

@keyframes lftpopParticleFireVertical {
	0% { transform: translateY(0) scale(1); opacity: 0.6; }
	50% { transform: translateY(-50vh) scale(1.2); opacity: 0.8; }
	100% { transform: translateY(-100vh) scale(0.5); opacity: 0; }
}

@keyframes lftpopBirdFly {
	0% { transform: translateY(0) translateX(0); opacity: 0; }
	10% { opacity: 1; }
	25% { transform: translateY(-30px) translateX(15px); }
	50% { transform: translateY(-50px) translateX(-10px); }
	75% { transform: translateY(-80px) translateX(20px); }
	100% { transform: translateY(-120px) translateX(0); opacity: 0; }
}

@keyframes lftpopBirdFlyVertical {
	0% { transform: translateY(0) translateX(0); opacity: 0; }
	10% { opacity: 1; }
	25% { transform: translateY(-25vh) translateX(15px); }
	50% { transform: translateY(-50vh) translateX(-10px); }
	75% { transform: translateY(-75vh) translateX(20px); }
	100% { transform: translateY(-100vh) translateX(0); opacity: 0; }
}


/* ==========================================================================
   Button Effects
   ========================================================================== */
@keyframes lftpop-pulse {
	0%, 100% { opacity: 1; }
	50% { opacity: 0.7; }
}

@keyframes lftpop-bounce {
	0%, 100% { transform: translateY(0); }
	50% { transform: translateY(-4px); }
}

@keyframes lftpop-shake {
	0%, 100% { transform: translateX(0); }
	10%, 30%, 50%, 70%, 90% { transform: translateX(-2px); }
	20%, 40%, 60%, 80% { transform: translateX(2px); }
}

@keyframes lftpop-glow {
	0%, 100% { box-shadow: 0 0 10px rgba(255, 255, 255, 0.7); }
	50% { box-shadow: 0 0 20px rgba(255, 255, 255, 0.9); }
}

.lftpop-effect-pulse {
	animation: lftpop-pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

.lftpop-effect-bounce {
	animation: lftpop-bounce 1s ease-in-out infinite;
}

.lftpop-effect-shake {
	animation: lftpop-shake 0.6s cubic-bezier(0.36, 0.07, 0.19, 0.97) both infinite;
	animation-delay: 2s;
}

.lftpop-effect-glow {
	animation: lftpop-glow 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}


/* ==========================================================================
   Attention Seekers
   ========================================================================== */
@keyframes lftpop-attention-pulse {
	0%, 100% { transform: scale(1); }
	50% { transform: scale(1.05); }
}

@keyframes lftpop-attention-bounce {
	0%, 100% { transform: translateY(0); }
	50% { transform: translateY(-8px); }
}

@keyframes lftpop-attention-shake {
	0%, 100% { transform: translateX(0); }
	25% { transform: translateX(-5px); }
	75% { transform: translateX(5px); }
}

.lftpop-attention-pulse {
	animation: lftpop-attention-pulse 2s ease-in-out infinite;
}

.lftpop-attention-bounce {
	animation: lftpop-attention-bounce 1s ease-in-out infinite;
}

.lftpop-attention-shake {
	animation: lftpop-attention-shake 0.5s ease-in-out infinite;
}

.lftpop-attention-jello {
	animation: lftpopJello 2s infinite;
}

@keyframes lftpopJello {
	from, 11.1%, to { transform: translate3d(0, 0, 0); }
	22.2% { transform: skewX(-12.5deg) skewY(-12.5deg); }
	33.3% { transform: skewX(6.25deg) skewY(6.25deg); }
	44.4% { transform: skewX(-3.125deg) skewY(-3.125deg); }
	55.5% { transform: skewX(1.5625deg) skewY(1.5625deg); }
	66.6% { transform: skewX(-0.78125deg) skewY(-0.78125deg); }
	77.7% { transform: skewX(0.390625deg) skewY(0.390625deg); }
	88.8% { transform: skewX(-0.1953125deg) skewY(-0.1953125deg); }
}

.lftpop-attention-rubberBand {
	animation: lftpopRubberBand 2s infinite;
}

@keyframes lftpopRubberBand {
	from { transform: scale3d(1, 1, 1); }
	30% { transform: scale3d(1.25, 0.75, 1); }
	40% { transform: scale3d(0.75, 1.25, 1); }
	50% { transform: scale3d(1.15, 0.85, 1); }
	65% { transform: scale3d(0.95, 1.05, 1); }
	75% { transform: scale3d(1.05, 0.95, 1); }
	to { transform: scale3d(1, 1, 1); }
}

.lftpop-attention-tada {
	animation: lftpopTada 2s infinite;
}

@keyframes lftpopTada {
	from { transform: scale3d(1, 1, 1); }
	10%, 20% { transform: scale3d(0.9, 0.9, 0.9) rotate3d(0, 0, 1, -3deg); }
	30%, 50%, 70%, 90% { transform: scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, 3deg); }
	40%, 60%, 80% { transform: scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, -3deg); }
	to { transform: scale3d(1, 1, 1); }
}


/* ==========================================================================
   Attention seekers missing on the frontend (previously admin-only) +
   class alias for the editor value `rubber_band`.
   ========================================================================== */
.lftpop-attention-wiggle {
	animation: lftpopWiggle 2s ease-in-out infinite;
}
@keyframes lftpopWiggle {
	0%, 50%, 100% { transform: rotate(0deg); }
	5%, 15% { transform: rotate(-3deg); }
	10%, 20% { transform: rotate(3deg); }
	25% { transform: rotate(0deg); }
}

.lftpop-attention-pulse {
	animation: lftpopPulseScale 2s infinite;
}
@keyframes lftpopPulseScale {
	0% { transform: scale(1); }
	50% { transform: scale(1.05); }
	100% { transform: scale(1); }
}

.lftpop-attention-shake {
	animation: lftpopShake 3s cubic-bezier(.36,.07,.19,.97) infinite;
	transform: translate3d(0, 0, 0);
}
@keyframes lftpopShake {
	0%, 50%, 100% { transform: translate3d(0, 0, 0); }
	5%, 15%, 25%, 35%, 45% { transform: translate3d(-1px, 0, 0); }
	10%, 20%, 30%, 40% { transform: translate3d(1px, 0, 0); }
}

.lftpop-attention-heartbeat {
	animation: lftpopHeartbeat 2s ease-in-out infinite;
}
@keyframes lftpopHeartbeat {
	from { transform: scale(1); transform-origin: center center; animation-timing-function: ease-out; }
	10% { transform: scale(0.91); animation-timing-function: ease-in; }
	17% { transform: scale(0.98); animation-timing-function: ease-out; }
	33% { transform: scale(0.87); animation-timing-function: ease-in; }
	45% { transform: scale(1); animation-timing-function: ease-out; }
}

.lftpop-attention-wobble {
	animation: lftpopWobble 2s infinite;
}
@keyframes lftpopWobble {
	0%, 100% { transform: translateX(0%); }
	15% { transform: translateX(-25%) rotate(-5deg); }
	30% { transform: translateX(20%) rotate(3deg); }
	45% { transform: translateX(-15%) rotate(-3deg); }
	60% { transform: translateX(10%) rotate(2deg); }
	75% { transform: translateX(-5%) rotate(-1deg); }
}

.lftpop-attention-flash {
	animation: lftpopFlash 3s infinite;
}
@keyframes lftpopFlash {
	0%, 50%, 100% { opacity: 1; }
	25%, 75% { opacity: 0; }
}

.lftpop-attention-jello {
	animation: lftpopJello 2s infinite;
	transform-origin: center;
}
@keyframes lftpopJello {
	from, 11.1%, to { transform: translate3d(0, 0, 0); }
	22.2% { transform: skewX(-12.5deg) skewY(-12.5deg); }
	33.3% { transform: skewX(6.25deg) skewY(6.25deg); }
}
/* Editor stores `rubber_band`; keep the original camelCase class too. */
.lftpop-attention-rubber_band {
	animation: lftpopRubberBand 2s infinite;
}

/* ==========================================================================
   Glass Effect
   ========================================================================== */
.lftpop-glass-effect {
	backdrop-filter: blur(12px);
	-webkit-backdrop-filter: blur(12px);
	border: 1px solid rgba(255, 255, 255, 0.2);
}

.lftpop-glass-effect .lftpop-bar-background {
	opacity: 0.5;
}


/* ==========================================================================
   Entrance Animations
   ========================================================================== */

.lftpop-entrance-slide_down {
	animation: lftpopSlideDown 0.6s ease-out forwards;
}
@keyframes lftpopSlideDown {
	from { transform: translateY(-100%); opacity: 0; }
	to { transform: translateY(0); opacity: 1; }
}

.lftpop-entrance-slide_up {
	animation: lftpopSlideUp 0.6s ease-out forwards;
}
@keyframes lftpopSlideUp {
	from { transform: translateY(100%); opacity: 0; }
	to { transform: translateY(0); opacity: 1; }
}

.lftpop-entrance-slide_left {
	animation: lftpopSlideLeft 0.6s ease-out forwards;
}
@keyframes lftpopSlideLeft {
	from { transform: translateX(-100%); opacity: 0; }
	to { transform: translateX(0); opacity: 1; }
}

.lftpop-entrance-slide_right {
	animation: lftpopSlideRight 0.6s ease-out forwards;
}
@keyframes lftpopSlideRight {
	from { transform: translateX(100%); opacity: 0; }
	to { transform: translateX(0); opacity: 1; }
}

.lftpop-entrance-fade_in {
	animation: lftpopFadeIn 0.8s ease-out forwards;
}
@keyframes lftpopFadeIn {
	from { opacity: 0; }
	to { opacity: 1; }
}

.lftpop-entrance-zoom_in {
	animation: lftpopZoomIn 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}
@keyframes lftpopZoomIn {
	from { transform: scale(0.8); opacity: 0; }
	to { transform: scale(1); opacity: 1; }
}

.lftpop-entrance-bounce_in {
	animation: lftpopBounceIn 0.8s cubic-bezier(0.215, 0.610, 0.355, 1.000) forwards;
}
@keyframes lftpopBounceIn {
	0% { opacity: 0; transform: scale3d(.3, .3, .3); }
	20% { transform: scale3d(1.1, 1.1, 1.1); }
	40% { transform: scale3d(.9, .9, .9); }
	60% { opacity: 1; transform: scale3d(1.03, 1.03, 1.03); }
	80% { transform: scale3d(.97, .97, .97); }
	100% { opacity: 1; transform: scale3d(1, 1, 1); }
}

.lftpop-entrance-swing {
	transform-origin: top center;
	animation: lftpopSwing 1s forwards;
}
@keyframes lftpopSwing {
	20% { transform: rotate3d(0, 0, 1, 15deg); }
	40% { transform: rotate3d(0, 0, 1, -10deg); }
	60% { transform: rotate3d(0, 0, 1, 5deg); }
	80% { transform: rotate3d(0, 0, 1, -5deg); }
	100% { transform: rotate3d(0, 0, 1, 0deg); }
}

.lftpop-entrance-flip_x {
	backface-visibility: visible !important;
	animation: lftpopFlipInX 1s forwards;
}
@keyframes lftpopFlipInX {
	from { transform: perspective(400px) rotate3d(1, 0, 0, 90deg); animation-timing-function: ease-in; opacity: 0; }
	40% { transform: perspective(400px) rotate3d(1, 0, 0, -20deg); animation-timing-function: ease-in; }
	60% { transform: perspective(400px) rotate3d(1, 0, 0, 10deg); opacity: 1; }
	80% { transform: perspective(400px) rotate3d(1, 0, 0, -5deg); }
	to { transform: perspective(400px); }
}


/* ==========================================================================
   Animated Backgrounds Keyframes
   ========================================================================== */
@keyframes lftpopAnimGradient {
	0% { background-position: 0% 50%; }
	50% { background-position: 100% 50%; }
	100% { background-position: 0% 50%; }
}

@keyframes lftpopAnimScroll {
	0% { background-position: 0 0; }
	100% { background-position: 100px 100px; }
}

@keyframes lftpopAnimPulseColor {
	0%, 100% { background-color: #000; box-shadow: 0 0 10px #6366f1; }
	50% { background-color: #1e1b4b; box-shadow: 0 0 30px #6366f1, 0 0 60px #8b5cf6; }
}

@keyframes lftpopAnimSnow {
	0% { background-position: 0 0, 25px 25px; }
	100% { background-position: 50px 100px, 75px 125px; }
}

@keyframes lftpopAnimShine {
	0% { background-position: 200% 0; }
	100% { background-position: -200% 0; }
}

@keyframes lftpopAnimMatrix {
	0% { background-position: 0 0; }
	100% { background-position: 50px 50px; }
}

@keyframes lftpopAnimPulseScale {
	0%, 100% { background-size: 100% 100%; }
	50% { background-size: 150% 150%; }
}

@keyframes lftpopAnimUp {
	0% { background-position: 0 0; }
	100% { background-position: 0 -100px; }
}

@keyframes lftpopAnimShift {
	0% { background-position: 50% 0%; }
	100% { background-position: 60% 60%; }
}

/* Legacy animation name (keep for backwards compatibility) */
@keyframes lftpop-gradient-shift {
	0% { background-position: 0% 50%; }
	50% { background-position: 100% 50%; }
	100% { background-position: 0% 50%; }
}

/* ============================================================
 * Canvas builder popups (editor_mode = canvas): absolutely
 * positioned elements inside a per-breakpoint viewport box.
 * ============================================================ */
.lftpop-popup.lftpop-canvas {
	padding: 0;
	overflow: hidden;
	position: relative;
	/* Size to the canvas viewport, not the classic size preset (which caps at
	 * 560px and would clip a wider design). */
	width: fit-content;
	max-width: 100%;
}
.lftpop-canvas .lftpop-canvas-viewport,
.lftpop-canvas .lftpop-el,
.lftpop-canvas .lftpop-el-content {
	box-sizing: border-box;
}
.lftpop-canvas .lftpop-el-content {
	width: 100%;
	height: 100%;
	display: block;
}
.lftpop-canvas .lftpop-el-content.lftpop-el-text {
	display: flex;
	flex-direction: column;
	justify-content: center;
	word-break: break-word;
}
.lftpop-canvas .lftpop-el-content.lftpop-el-button {
	display: flex;
	align-items: center;
	justify-content: center;
	text-decoration: none;
	cursor: pointer;
	border: 0;
	line-height: 1.2;
}
.lftpop-canvas .lftpop-el-content.lftpop-el-image {
	overflow: hidden;
}
.lftpop-canvas .lftpop-el-content.lftpop-el-image img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}
.lftpop-canvas .lftpop-el-content.lftpop-el-coupon {
	display: flex;
	align-items: center;
	justify-content: center;
	font-weight: 700;
	letter-spacing: 1px;
}
.lftpop-canvas .lftpop-el-content.lftpop-el-video {
	overflow: hidden;
	padding: 0;
}
.lftpop-canvas .lftpop-el-content.lftpop-el-video iframe,
.lftpop-canvas .lftpop-el-content.lftpop-el-video video {
	width: 100%;
	height: 100%;
	border: 0;
	display: block;
}
/* Lead form element: neutral inputs + full-width submit; the element's own
 * style (bg / color / radius / padding) paints the surrounding box. */
.lftpop-canvas .lftpop-el-content.lftpop-el-form {
	display: flex;
	flex-direction: column;
	justify-content: center;
	gap: 10px;
	max-width: none;
	margin: 0;
	overflow: hidden;
}
.lftpop-canvas .lftpop-el-form .lftpop-form-input {
	display: block;
	width: 100%;
	box-sizing: border-box;
	margin: 0;
	padding: 10px 14px;
	border: 1px solid #d1d5db;
	border-radius: 8px;
	background: #ffffff;
	color: #111827;
	font: inherit;
	font-size: 15px;
	line-height: 1.3;
	outline: none;
	flex-shrink: 0;
}
.lftpop-canvas .lftpop-el-form .lftpop-form-input::placeholder {
	color: #9ca3af;
}
.lftpop-canvas .lftpop-el-form .lftpop-form-input:focus {
	border-color: #6366f1;
	box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.2);
}
.lftpop-canvas .lftpop-el-form .lftpop-form-consent {
	display: flex;
	align-items: flex-start;
	gap: 8px;
	margin: 0;
	font-size: 13px;
	font-weight: 400;
	line-height: 1.4;
	text-align: left;
	cursor: pointer;
}
.lftpop-canvas .lftpop-el-form .lftpop-form-consent input {
	width: auto;
	margin: 2px 0 0;
	flex-shrink: 0;
}
.lftpop-canvas .lftpop-el-form .lftpop-form-submit {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: auto;
	box-sizing: border-box;
	margin: 0;
	padding: 12px 16px;
	border: 0;
	border-radius: 8px;
	background: #6366f1;
	color: #ffffff;
	font: inherit;
	font-weight: 700;
	line-height: 1.2;
	cursor: pointer;
	flex-shrink: 0;
}
.lftpop-canvas .lftpop-el-form .lftpop-form-submit:hover {
	filter: brightness(1.08);
}
.lftpop-canvas .lftpop-el-form .lftpop-success-message {
	display: block;
	text-align: center;
}
/* Multi-step: only the active step panel is shown; next_step reveals the next. */
.lftpop-canvas .lftpop-canvas-step[hidden] {
	display: none;
}

/* Breakpoint swap: desktop tree by default; swap to mobile below 768px ONLY
 * when a dedicated mobile layout exists (otherwise desktop stays visible). */
.lftpop-canvas .lftpop-canvas-mobile {
	display: none;
}
@media (max-width: 768px) {
	.lftpop-canvas.lftpop-has-mobile .lftpop-canvas-desktop {
		display: none;
	}
	.lftpop-canvas.lftpop-has-mobile .lftpop-canvas-mobile {
		display: block;
	}
}

