/**
 * PlayTap Lite – front-end styles (bugs + motion).
 */

/* Auto-injected (404 footer) */
.playtap-lite-auto-wrap--404 {
	padding: 1.5rem 1rem 2.5rem;
	max-width: 480px;
	margin-left: auto;
	margin-right: auto;
	clear: both;
}

.playtap-lite-root {
	box-sizing: border-box;
	max-width: 420px;
	margin: 1.5rem auto;
	font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
	border-radius: 12px;
	overflow: hidden;
	box-shadow: 0 8px 30px rgba(15, 23, 42, 0.12);
	background: #fff;
}

.playtap-lite-root *,
.playtap-lite-root *::before,
.playtap-lite-root *::after {
	box-sizing: border-box;
}

.playtap-lite-header {
	padding: 1rem 1.25rem;
	color: #fff;
	text-align: center;
}

.playtap-lite-header h2 {
	margin: 0 0 0.35rem;
	font-size: 1.35rem;
	line-height: 1.2;
}

.playtap-lite-header p {
	margin: 0;
	font-size: 0.9rem;
	opacity: 0.95;
}

.playtap-lite-hud {
	display: flex;
	flex-wrap: wrap;
	gap: 0.35rem 1rem;
	justify-content: space-between;
	align-items: center;
	padding: 0.5rem 1rem;
	background: #f8fafc;
	border-bottom: 1px solid #e2e8f0;
	font-size: 0.9rem;
	font-weight: 600;
	color: #334155;
}

.playtap-lite-hud-best {
	font-weight: 700;
	color: #0f766e;
}

.playtap-lite-stage-wrap {
	position: relative;
	width: 100%;
	aspect-ratio: 4 / 5;
	background: linear-gradient(180deg, #ecfdf5 0%, #d1fae5 45%, #a7f3d0 100%);
	touch-action: manipulation;
}

.playtap-lite-stage {
	position: absolute;
	inset: 0;
	overflow: hidden;
	cursor: pointer;
}

.playtap-lite-target {
	--playtap-ring: #f97316;
	position: absolute;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	background: rgba(255, 255, 255, 0.92);
	border: 3px solid var(--playtap-ring);
	box-shadow: 0 4px 16px rgba(15, 23, 42, 0.18);
	user-select: none;
	-webkit-tap-highlight-color: transparent;
	will-change: left, top;
}

.playtap-lite-target-inner {
	width: 100%;
	height: 100%;
	display: flex;
	align-items: center;
	justify-content: center;
	animation: playtap-pop-inner 0.28s ease-out;
	transition: transform 0.08s ease;
}

.playtap-lite-target:active .playtap-lite-target-inner {
	transform: scale(0.9);
}

.playtap-lite-bug {
	width: 70%;
	height: 70%;
	object-fit: contain;
	pointer-events: none;
	-webkit-user-drag: none;
}

@keyframes playtap-pop-inner {
	from {
		transform: scale(0.35) rotate(-12deg);
		opacity: 0;
	}
	to {
		transform: scale(1) rotate(0deg);
		opacity: 1;
	}
}

.playtap-lite-overlay {
	position: absolute;
	inset: 0;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	background: rgba(15, 23, 42, 0.58);
	color: #fff;
	text-align: center;
	padding: 1.5rem;
	z-index: 5;
}

.playtap-lite-overlay h3 {
	margin: 0 0 0.5rem;
	font-size: 1.25rem;
}

.playtap-lite-overlay .playtap-lite-final-score {
	margin: 0 0 0.35rem;
	font-size: 1.65rem;
	font-weight: 800;
}

.playtap-lite-record-msg {
	margin: 0 0 1rem;
	font-size: 1rem;
	font-weight: 700;
	color: #fde047;
}

.playtap-lite-btn {
	appearance: none;
	border: none;
	border-radius: 999px;
	padding: 0.65rem 1.5rem;
	font-size: 1rem;
	font-weight: 700;
	cursor: pointer;
	background: #fff;
	color: #0f172a;
	box-shadow: 0 4px 14px rgba(0, 0, 0, 0.15);
	transition: transform 0.1s ease;
}

.playtap-lite-btn:hover,
.playtap-lite-btn:focus-visible {
	transform: translateY(-1px);
	outline: 2px solid #fff;
	outline-offset: 2px;
}

.playtap-lite-btn:active {
	transform: translateY(0);
}

.playtap-lite-hidden {
	display: none !important;
}

@media (prefers-reduced-motion: reduce) {
	.playtap-lite-target-inner {
		animation: none;
	}
}
