/* MFY quiz - shared helpers.
   Loaded on the Soil Profile Builder wizard and, for now, on the turf match tool pages. */

/* Entrance animation for main step transitions */
.quiz-entrance {
	animation: mfySlideUp 0.6s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

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

/* Slide-to-focus animation for revealed sections */
@keyframes mfyFadeSlideIn {
	0%   { opacity: 0; transform: translateY(30px); }
	100% { opacity: 1; transform: translateY(0); }
}

.is-visible {
	display: block !important;
	animation: mfyFadeSlideIn 0.7s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

/* Loading state and spinner */
.is-calculating {
	pointer-events: none;
	opacity: 0.8;
}

.loader-container {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 12px;
}

.loading-circle {
	width: 20px;
	height: 20px;
	border: 3px solid rgba(92, 128, 1, 0.2);
	border-top: 3px solid #5c8001;
	border-radius: 50%;
	flex-shrink: 0; /* keeps the circle round in flex layouts on mobile */
	box-sizing: border-box;
	animation: spin 1s linear infinite;
}

@keyframes spin {
	0%   { transform: rotate(0deg); }
	100% { transform: rotate(360deg); }
}

@media (prefers-reduced-motion: reduce) {
	.quiz-entrance,
	.is-visible {
		animation: none;
	}
}
