/**
 * Homepage callback forms — inline thank-you state (#leo-hero-form, #leo-questions-form).
 */

#leo-hero-form input[type='submit'].leocar-hero-callback-submit,
#leo-hero-form button.leocar-hero-callback-submit,
#leo-questions-form input[type='submit'].leocar-hero-callback-submit,
#leo-questions-form button.leocar-hero-callback-submit {
	cursor: pointer;
}

#leo-hero-form.leocar-hero-form--thank-you,
#leo-questions-form.leocar-hero-form--thank-you {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	height: var(--leocar-form-lock-h, auto);
	min-height: var(--leocar-form-lock-h, 280px);
	max-height: var(--leocar-form-lock-h, none);
	overflow: hidden;
	box-sizing: border-box;
}

#leo-hero-form .leocar-flow-thank-you,
#leo-questions-form .leocar-flow-thank-you {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 100%;
	min-height: 0;
	padding: 1.5rem 1.25rem;
	text-align: center;
	box-sizing: border-box;
	animation: leocar-flow-thank-you-enter 0.45s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.leocar-flow-thank-you__icon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 3.5rem;
	height: 3.5rem;
	margin: 0 0 1rem;
	border-radius: 999px;
	background: rgb(39 172 91 / 0.16);
	color: #27ac5b;
	animation: leocar-flow-thank-you-icon 0.55s cubic-bezier(0.34, 1.4, 0.64, 1) 0.08s both;
}

.leocar-flow-thank-you__icon svg {
	display: block;
	width: 1.75rem;
	height: 1.75rem;
}

.leocar-flow-thank-you__title {
	margin: 0 0 0.75rem;
	font-size: clamp(1.125rem, 2.5vw, 1.5rem);
	font-weight: 700;
	line-height: 1.35;
	color: #fafafa;
	opacity: 0;
	animation: leocar-flow-thank-you-line 0.5s cubic-bezier(0.22, 1, 0.36, 1) 0.18s both;
}

.leocar-flow-thank-you__text {
	margin: 0 0 0.5rem;
	font-size: clamp(0.875rem, 2vw, 1rem);
	line-height: 1.5;
	color: rgba(250 250 250 / 0.88);
	opacity: 0;
	animation: leocar-flow-thank-you-line 0.5s cubic-bezier(0.22, 1, 0.36, 1) 0.3s both;
}

.leocar-flow-thank-you__note {
	margin: 0.5rem 0 0;
	font-size: 0.8125rem;
	line-height: 1.45;
	color: rgba(250 250 250 / 0.55);
	opacity: 0;
	animation: leocar-flow-thank-you-line 0.5s cubic-bezier(0.22, 1, 0.36, 1) 0.42s both;
}

@keyframes leocar-flow-thank-you-enter {
	from {
		opacity: 0;
		transform: scale(0.97);
	}

	to {
		opacity: 1;
		transform: scale(1);
	}
}

@keyframes leocar-flow-thank-you-icon {
	from {
		opacity: 0;
		transform: scale(0.55);
	}

	to {
		opacity: 1;
		transform: scale(1);
	}
}

@keyframes leocar-flow-thank-you-line {
	from {
		opacity: 0;
		transform: translate3d(0, 14px, 0);
	}

	to {
		opacity: 1;
		transform: translate3d(0, 0, 0);
	}
}

@media (prefers-reduced-motion: reduce) {
	#leo-hero-form .leocar-flow-thank-you,
	#leo-questions-form .leocar-flow-thank-you,
	.leocar-flow-thank-you__icon,
	.leocar-flow-thank-you__title,
	.leocar-flow-thank-you__text,
	.leocar-flow-thank-you__note {
		animation: none;
		opacity: 1;
		transform: none;
	}
}

@media (min-width: 768px) {
	#leo-hero-form .leocar-flow-thank-you,
	#leo-questions-form .leocar-flow-thank-you {
		padding: 2rem 1.5rem;
	}
}
