/* Mobile add-to-cart bar. Hidden on larger screens and while a designer modal is open. */
.mf-sticky-atc {
	display: none;
}

@media (max-width: 800px) {
	body.mf-sticky-atc-active {
		padding-bottom: calc(56px + env(safe-area-inset-bottom));
	}

	.mf-sticky-atc {
		position: fixed;
		right: 0;
		bottom: 0;
		left: 0;
		z-index: 8000;
		display: flex;
		align-items: center;
		gap: 8px;
		box-sizing: border-box;
		min-height: 56px;
		padding: 6px 10px calc(6px + env(safe-area-inset-bottom));
		background: #fff;
		box-shadow: 0 -1px 6px rgba(0, 0, 0, 0.15);
		visibility: hidden;
		opacity: 0;
		transform: translateY(100%);
		transition: transform 0.2s ease, opacity 0.2s ease, visibility 0s linear 0.2s;
	}

	.mf-sticky-atc--visible {
		visibility: visible;
		opacity: 1;
		transform: none;
		transition-delay: 0s;
	}

	body.fpd-overflow-hidden .mf-sticky-atc,
	body.fpd-modal-designer-visible .mf-sticky-atc {
		display: none;
	}

	.mf-sticky-atc__qty {
		display: flex;
		flex: none;
		align-items: center;
	}

	.mf-sticky-atc__qty[hidden] {
		display: none;
	}

	.mf-sticky-atc .mf-sticky-atc__step {
		display: flex;
		align-items: center;
		justify-content: center;
		width: 36px;
		height: 44px;
		margin: 0;
		padding: 0;
		border: 0;
		border-radius: 0;
		background: transparent;
		color: #000;
		font-size: 16px;
		line-height: 1;
	}

	.mf-sticky-atc .mf-sticky-atc__step .spk-icon {
		display: block;
		line-height: 1;
	}

	/* The theme defines these glyphs only inside its own quantity markup. */
	.mf-sticky-atc .spk-icon-minus::before {
		content: "\e913";
	}

	.mf-sticky-atc .spk-icon-plus::before {
		content: "\e912";
	}

	.mf-sticky-atc .mf-sticky-atc__step:disabled {
		opacity: 0.3;
	}

	.mf-sticky-atc__value {
		min-width: 28px;
		font-size: 15px;
		line-height: 1;
		text-align: center;
	}

	/*
	 * The theme's .button forces padding: 18px 1rem 15px !important, which pushes the text down.
	 * This font's capitals sit high in their line box, so 3px on top centers them in the button.
	 */
	.mf-sticky-atc .mf-sticky-atc__action {
		flex: 1;
		min-width: 0;
		height: 44px;
		margin: 0;
		padding: 3px 10px 0 !important;
		overflow: hidden;
		font-size: 13px;
		white-space: nowrap;
		text-overflow: ellipsis;
	}

	.mf-sticky-atc .mf-sticky-atc__action:disabled {
		opacity: 0.6;
	}
}

@media (prefers-reduced-motion: reduce) {
	.mf-sticky-atc,
	.mf-sticky-atc--visible {
		transition: none;
	}
}
