/**
 * Sticky mobile bottom navigation.
 * Standalone file so it works without rebuilding the theme assets.
 * Typography aligned with Figma (Satoshi Medium 12/18); icons are SVG, not Material Symbols.
 *
 * Note: Figma exports a Google Fonts link for "Satoshi Variable" — that family is NOT on
 * Google Fonts. Font files live in the theme (assets/webfonts/Satoshi-Variable.*).
 */

/* Figma name + theme name, same local variable font files */
@font-face {
	font-family: "Satoshi Variable";
	src: url("../webfonts/Satoshi-Variable.woff2") format("woff2-variations"),
		url("../webfonts/Satoshi-Variable.woff2") format("woff2"),
		url("../webfonts/Satoshi-Variable.woff") format("woff"),
		url("../webfonts/Satoshi-Variable.ttf") format("truetype");
	font-weight: 300 900;
	font-style: normal;
	font-display: swap;
}

@font-face {
	font-family: "Satoshi";
	src: url("../webfonts/Satoshi-Variable.woff2") format("woff2-variations"),
		url("../webfonts/Satoshi-Variable.woff2") format("woff2"),
		url("../webfonts/Satoshi-Variable.woff") format("woff"),
		url("../webfonts/Satoshi-Variable.ttf") format("truetype");
	font-weight: 300 900;
	font-style: normal;
	font-display: swap;
}

.mobile-sticky-menu {
	width: 100%;
	position: fixed;
	bottom: 0;
	left: 0;
	right: 0;
	z-index: 9998;
	background-color: #fff;
	border-top: 1px solid #e7e7e7;
	box-sizing: border-box;
	padding: 12px 0;
	/* Stay glued to visual bottom with iOS home indicator */
	padding-bottom: calc(12px + env(safe-area-inset-bottom, 0px));
	text-align: center;
	font-size: 20px;
	color: #3d3d3d;
	font-family: "Satoshi Variable", "Satoshi", sans-serif;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
}

.mobile-sticky-menu__container {
	width: 100%;
	max-width: 100%;
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 0 16px;
	box-sizing: border-box;
	gap: 0;
}

/* Figma: .buttonsbutton-parent */
.mobile-sticky-menu__item {
	flex: 1;
	width: 100%;
	position: relative;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	padding: 4px;
	box-sizing: border-box;
	text-decoration: none;
	text-align: center;
	font-size: 20px;
	color: #3d3d3d;
	font-family: "Satoshi Variable", "Satoshi", sans-serif;
	isolation: isolate;
	border-radius: 2px;
	/* overflow visible so cart badge can sit slightly above the item */
	overflow: visible;
	transition: background-color 0.15s ease;
}

.mobile-sticky-menu__item.is-active,
.mobile-sticky-menu__item:active {
	background-color: #f6f6f6;
}

/* Figma: .iconsgoolge-font / .icon-font (20×20, weight 500) */
.mobile-sticky-menu__icon {
	position: relative;
	width: 20px;
	height: 20px;
	line-height: 20px;
	font-weight: 500;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
	overflow: hidden;
}

.mobile-sticky-menu__icon svg {
	width: 20px;
	height: 20px;
	display: block;
}

/* Figma: .text — 12px / 18px Medium; use wght axis so variable font renders thicker */
.mobile-sticky-menu__text {
	position: relative;
	font-size: 12px;
	line-height: 18px;
	font-weight: 600;
	font-variation-settings: "wght" 600;
	font-family: "Satoshi Variable", "Satoshi", sans-serif;
	white-space: nowrap;
	color: #3d3d3d;
}

.mobile-sticky-menu__badge {
	min-width: 16px;
	height: 16px;
	position: absolute;
	/* Higher and a bit left of previous (was top: 2px; margin-left: 6px) */
	top: -2px;
	left: 50%;
	margin-left: 2px;
	border-radius: 9999px;
	background-color: #c72c2e;
	display: inline-flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	padding: 0 4px 1px;
	box-sizing: border-box;
	z-index: 2;
	flex-shrink: 0;
	text-align: center;
	font-size: 10px;
	line-height: 16px;
	font-weight: 600;
	font-variation-settings: "wght" 600;
	color: #fff;
	font-family: "Satoshi Variable", "Satoshi", sans-serif;
}

/* Make room for the sticky bar on mobile; keep top header visible. */
@media (max-width: 767px) {
	body {
		padding-bottom: 72px;
	}

	/* Bottom sticky bar not needed while the menu overlay is open */
	body.mobile-nav-open .mobile-sticky-menu {
		visibility: hidden;
		pointer-events: none;
	}

	/*
	 * DJ Accessibility sits bottom-left with z-index 99999 and covers the sticky nav.
	 * Lift it above the bar (~72px) so both remain usable.
	 */
	.djacc.djacc--sticky.djacc--bottom-left,
	.djacc.djacc--sticky.djacc--bottom-center,
	.djacc.djacc--sticky.djacc--bottom-right {
		bottom: 80px;
	}
}

/* Hide on desktop */
@media (min-width: 768px) {
	.mobile-sticky-menu {
		display: none;
	}

	body {
		padding-bottom: 0;
	}
}
