/* Toast notification for the AJAX add-to-cart confirmation. */

.btllc-toast {
	position: fixed;
	bottom: 24px;
	left: 50%;
	display: flex;
	align-items: center;
	gap: 12px;
	max-width: calc(100vw - 32px);
	padding: 12px 20px;
	background: #1a1a1a;
	color: #fff;
	border-radius: 6px;
	box-shadow: 0 6px 24px rgba(0, 0, 0, 0.25);
	font-size: 14px;
	line-height: 1.4;
	z-index: 10001;
	opacity: 0;
	transform: translateX(-50%) translateY(12px);
	transition: opacity 200ms ease, transform 200ms ease;
	pointer-events: auto;
}

.btllc-toast--in {
	opacity: 1;
	transform: translateX(-50%) translateY(0);
}

.btllc-toast--out {
	opacity: 0;
	transform: translateX(-50%) translateY(8px);
}

.btllc-toast__icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 22px;
	height: 22px;
	background: #1f7a35;
	border-radius: 50%;
	color: #fff;
	font-size: 13px;
	font-weight: 700;
	flex: 0 0 auto;
}

.btllc-toast__text {
	font-weight: 500;
}

.btllc-toast__link {
	color: #ffc107;
	text-decoration: underline;
	font-weight: 600;
	margin-left: 4px;
}

.btllc-toast__link:hover,
.btllc-toast__link:focus {
	color: #ffd966;
}

/* Loading spinner on the Add to Cart button while the AJAX call is in flight. */
.single_add_to_cart_button.loading {
	position: relative;
	color: transparent !important;
	pointer-events: none;
}

.single_add_to_cart_button.loading::after {
	content: "";
	position: absolute;
	top: 50%;
	left: 50%;
	width: 16px;
	height: 16px;
	margin: -8px 0 0 -8px;
	border: 2px solid currentColor;
	border-top-color: transparent;
	border-radius: 50%;
	animation: btllc-spin 0.7s linear infinite;
	color: #fff;
}

@keyframes btllc-spin {
	to { transform: rotate(360deg); }
}

@media (max-width: 480px) {
	.btllc-toast {
		bottom: 80px; /* clear bottom mobile nav */
		font-size: 13px;
		padding: 10px 16px;
	}
}
