/**
 * Back to Top Button Styles
 *
 * @package FoodOrd
 * @since   1.0
 */

/* Back to Top Button */
:root {
    --background-color: #f7f7f7;
    --primary-color: #c9386f;
    --primary-hover: #b92a61;
    --text-color: #323232;
    --text-hover: #313131;
    --secondary-text: #6b6b6b;
    --button-bg: #c9386f;
    --button-text-color: #ffffff;
    --button-on-hover: #b92a61;
    --header-bg: #ffffff;
    --footer-bg: #ffffff;
    --footer-bottom-bg: #ffffff;
    --border-color: #f4f4f4;
	--btt-color: #ffffff;
	--btt-hover-color: #f5f5f5;
	--btt-icon-color: #000000;
}
.back-to-top-button {
	position: fixed;
	bottom: 2rem;
	right: 2rem;
	width: 3.25rem;
	height: 3.25rem;
	border: none;
	border-radius: 50%;
	box-shadow: 0 2px 6px rgba(0, 0, 0, 0.12);
	background-color: var(--btt-color);
	cursor: pointer;
	z-index: 9999;
	opacity: 0;
	visibility: hidden;
	transition: opacity 0.3s ease, visibility 0.3s ease;
	display: flex;
	align-items: center;
	justify-content: center;
	outline: none;
}


/* Hover effects */
.back-to-top-button:hover {
	background-color: var(--btt-hover-color);
}

/* Icon styling */
.back-to-top-icon {
	display: block;
	width: 1.75rem;
	height: 1.75rem;
	color: var(--btt-icon-color);
	pointer-events: none;
	flex-shrink: 0;
}

/* Visible state */
.back-to-top-button.is-visible {
	opacity: 1;
	visibility: visible;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
	.back-to-top-button {
		border: 2px solid currentColor;
	}
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
	.back-to-top-button {
		transition: none;
	}
}

/* Mobile screens: position above mobile cart */
@media (max-width: 1024px) {
	.back-to-top-button {
		bottom: 80px; /* Mobile cart height (~60px) + extra space */
	}
}

/* Products context: align button just left of FoodOrd sidebar on >=1025px */
@media (min-width: 1025px) {
	body.foodord-products-context .back-to-top-button,
	body.foodord-checkout-context .back-to-top-button {
		right: calc(var(--foodord-sidebar-w) + 5px);
		left: auto;
	}
}