#af-scroll-to-top,
#af-scroll-to-top *,
#af-scroll-to-top *::before,
#af-scroll-to-top *::after {
	box-sizing: border-box;
}

#af-scroll-to-top {
	--af-stt-icon-size: 20px;
	--af-stt-padding: 12px;
	--af-stt-icon-color: #ffffff;
	--af-stt-icon-hover: #f4f4f4;
	--af-stt-background: #25d366;
	--af-stt-background-hover: #25d366;
	--af-stt-radius: 50%;
	--af-stt-cta-color: #ffffff;
	--af-stt-cta-bg: #25d366;
	--af-stt-cta-font-size: 14px;
	--af-stt-z-index: 99999999;
	appearance: none;
	-webkit-appearance: none;
	align-items: center;
	background: transparent;
	border: 0;
	bottom: 15px;
	color: inherit;
	cursor: pointer;
	display: inline-flex;
	font: inherit;
	gap: 0;
	left: auto;
	margin: 0;
	outline: none;
	padding: 0;
	position: fixed;
	right: 15px;
	text-align: left;
	text-decoration: none;
	top: auto;
	-webkit-tap-highlight-color: transparent;
	z-index: var(--af-stt-z-index);
}

#af-scroll-to-top[hidden] {
	display: none !important;
}

#af-scroll-to-top.af-stt--left {
	flex-direction: row-reverse;
}

.af-stt__circle {
	align-items: center;
	background-color: var(--af-stt-background);
	border-radius: var(--af-stt-radius);
	color: var(--af-stt-icon-color);
	display: inline-flex;
	flex: 0 0 auto;
	justify-content: center;
	padding: var(--af-stt-padding);
	transition: background-color 120ms ease, color 120ms ease;
}

.af-stt__circle svg {
	display: block;
	height: var(--af-stt-icon-size);
	pointer-events: none;
	width: var(--af-stt-icon-size);
}

.af-stt__circle path {
	fill: currentColor;
}

.af-stt__cta {
	background-color: var(--af-stt-cta-bg);
	border-radius: 10px;
	color: var(--af-stt-cta-color);
	display: none;
	font-family: inherit;
	font-size: var(--af-stt-cta-font-size);
	font-style: normal;
	font-weight: normal;
	line-height: normal;
	margin: 0 10px;
	order: 0;
	padding: 0 16px;
	pointer-events: none;
	white-space: nowrap;
}

.af-stt--left .af-stt__cta {
	order: 1;
}

#af-scroll-to-top:hover .af-stt__circle,
#af-scroll-to-top:focus-visible .af-stt__circle {
	background-color: var(--af-stt-background-hover);
	color: var(--af-stt-icon-hover);
}

#af-scroll-to-top:hover .af-stt__cta,
#af-scroll-to-top:focus-visible .af-stt__cta {
	display: block;
	animation: af-stt-cta-stick 120ms cubic-bezier(.25,.8,.25,1) both;
	transform-origin: right center;
}

.af-stt--left:hover .af-stt__cta,
.af-stt--left:focus-visible .af-stt__cta {
	transform-origin: left center;
}

#af-scroll-to-top:focus-visible {
	border-radius: 999px;
	outline: 2px solid currentColor;
	outline-offset: 3px;
}

#af-scroll-to-top.af-stt--leaving {
	animation: af-stt-exit 140ms ease forwards;
	pointer-events: none;
}

#af-scroll-to-top.af-stt--entry-corner {
	animation: af-stt-corner 400ms cubic-bezier(.25,1,.5,1) both;
	transform-origin: bottom right;
}

#af-scroll-to-top.af-stt--left.af-stt--entry-corner {
	transform-origin: bottom left;
}

#af-scroll-to-top.af-stt--entry-center {
	animation: af-stt-center 250ms ease both;
}

#af-scroll-to-top.af-stt--animation-bounce {
	animation: af-stt-bounce 1s both;
}

#af-scroll-to-top.af-stt--animation-flash {
	animation: af-stt-flash 1s both;
}

#af-scroll-to-top.af-stt--animation-pulse {
	animation: af-stt-pulse 1s ease-in-out both;
}

#af-scroll-to-top.af-stt--animation-heartbeat {
	animation: af-stt-heartbeat 1.3s ease-in-out both;
}

#af-scroll-to-top.af-stt--animation-flip {
	animation: af-stt-flip 1s both;
	backface-visibility: visible;
}

@keyframes af-stt-cta-stick {
	0% {
		opacity: 0;
		transform: translateX(6px) scaleX(.6);
	}
	100% {
		opacity: 1;
		transform: translateX(0) scaleX(1);
	}
}

@keyframes af-stt-corner {
	0% {
		opacity: 0;
		transform: scale(0);
	}
	100% {
		opacity: 1;
		transform: scale(1);
	}
}

@keyframes af-stt-center {
	from {
		opacity: 0;
		transform: scale3d(.3,.3,.3);
	}
	50% {
		opacity: 1;
	}
}

@keyframes af-stt-exit {
	from {
		opacity: 1;
		transform: scale(1);
	}
	to {
		opacity: 0;
		transform: scale(.85);
	}
}

@keyframes af-stt-bounce {
	from,20%,53%,to {
		animation-timing-function: cubic-bezier(.215,.61,.355,1);
		transform: translate3d(0,0,0);
	}
	40%,43% {
		animation-timing-function: cubic-bezier(.755,.05,.855,.06);
		transform: translate3d(0,-30px,0) scaleY(1.1);
	}
	70% {
		animation-timing-function: cubic-bezier(.755,.05,.855,.06);
		transform: translate3d(0,-15px,0) scaleY(1.05);
	}
	80% {
		transform: translate3d(0,0,0) scaleY(.95);
	}
	90% {
		transform: translate3d(0,-4px,0) scaleY(1.02);
	}
}

@keyframes af-stt-flash {
	from,50%,to { opacity: 1; }
	25%,75% { opacity: 0; }
}

@keyframes af-stt-pulse {
	from { transform: scale3d(1,1,1); }
	50% { transform: scale3d(1.05,1.05,1.05); }
	to { transform: scale3d(1,1,1); }
}

@keyframes af-stt-heartbeat {
	0% { transform: scale(1); }
	14% { transform: scale(1.3); }
	28% { transform: scale(1); }
	42% { transform: scale(1.3); }
	70% { transform: scale(1); }
}

@keyframes af-stt-flip {
	from {
		animation-timing-function: ease-out;
		transform: perspective(400px) scale3d(1,1,1) translate3d(0,0,0) rotate3d(0,1,0,-360deg);
	}
	40% {
		animation-timing-function: ease-out;
		transform: perspective(400px) scale3d(1,1,1) translate3d(0,0,150px) rotate3d(0,1,0,-190deg);
	}
	50% {
		animation-timing-function: ease-in;
		transform: perspective(400px) scale3d(1,1,1) translate3d(0,0,150px) rotate3d(0,1,0,-170deg);
	}
	80% {
		animation-timing-function: ease-in;
		transform: perspective(400px) scale3d(.95,.95,.95) translate3d(0,0,0) rotate3d(0,1,0,0);
	}
	to {
		animation-timing-function: ease-in;
		transform: perspective(400px) scale3d(1,1,1) translate3d(0,0,0) rotate3d(0,1,0,0);
	}
}

@media (prefers-reduced-motion: reduce) {
	#af-scroll-to-top,
	#af-scroll-to-top *,
	#af-scroll-to-top *::before,
	#af-scroll-to-top *::after {
		animation-duration: 0.01ms !important;
		animation-iteration-count: 1 !important;
		scroll-behavior: auto !important;
		transition-duration: 0.01ms !important;
	}
}

/* Browser-side mirror of the active WhatsApp style-7 button. */
.af-stt__circle {
	width: var(--af-stt-circle-width, auto);
	height: var(--af-stt-circle-height, auto);
}

.af-stt__cta {
	border-radius: var(--af-stt-cta-radius, 10px);
	font-family: var(--af-stt-cta-font-family, inherit);
	font-weight: var(--af-stt-cta-font-weight, normal);
	line-height: var(--af-stt-cta-line-height, normal);
	padding: var(--af-stt-cta-padding-top, 0) var(--af-stt-cta-padding-right, 16px) var(--af-stt-cta-padding-bottom, 0) var(--af-stt-cta-padding-left, 16px);
}
