.bh-smc {
	position: fixed;
	left: 50%;
	right: auto;
	bottom: 0;
	width: 94%;
	max-width: 1180px;
	box-sizing: border-box;
	background: #fff;
	box-shadow: 0 -6px 22px rgba(0, 0, 0, 0.12);
	opacity: 0;
	visibility: hidden;
	transform: translate(-50%, 115%);
	pointer-events: none;
	transition:
		transform var(--bh-smc-speed, 260ms) ease,
		opacity var(--bh-smc-speed, 260ms) ease,
		visibility var(--bh-smc-speed, 260ms) ease;
}

.bh-smc.bh-smc--visible {
	opacity: 1;
	visibility: visible;
	transform: translate(-50%, 0);
	pointer-events: auto;
}

.bh-smc,
.bh-smc * {
	box-sizing: border-box;
}

.bh-smc__inner {
	display: flex;
	align-items: center;
	justify-content: space-between;
	flex-wrap: nowrap;
	width: 100%;
	min-width: 0;
}

.bh-smc__product {
	display: flex;
	align-items: center;
	flex: 1 1 auto;
	min-width: 0;
	overflow: hidden;
}

.bh-smc__image {
	flex: 0 0 auto;
	width: 46px;
	height: 46px;
	overflow: hidden;
	border-radius: 8px;
}

.bh-smc__image img {
	display: block;
	width: 100% !important;
	height: 100% !important;
	max-width: none !important;
	object-fit: cover;
	margin: 0 !important;
}

.bh-smc__info {
	display: flex;
	flex: 1 1 auto;
	flex-direction: column;
	min-width: 0;
	overflow: hidden;
}

.bh-smc__name {
	display: -webkit-box;
	-webkit-box-orient: vertical;
	-webkit-line-clamp: 1;
	overflow: hidden;
	font-weight: 600;
	line-height: 1.18;
	word-break: normal;
}

.bh-smc__variation,
.bh-smc__price {
	display: block;
	min-width: 0;
	font-size: 12px;
	line-height: 1.2;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.bh-smc__variation {
	opacity: .76;
}

.bh-smc__variation:empty {
	display: none;
}

.bh-smc__price {
	margin-top: 2px;
}

.bh-smc__price del,
.bh-smc__price ins {
	display: inline;
}

.bh-smc__actions {
	display: flex;
	align-items: center;
	justify-content: flex-end;
	flex: 0 0 auto;
	flex-wrap: nowrap;
	min-width: 0;
}

.bh-smc--actions-left .bh-smc__inner {
	flex-direction: row-reverse;
}

.bh-smc__qty {
	display: flex;
	align-items: center;
	justify-content: center;
	flex: 0 0 auto;
	width: auto;
	height: auto;
	overflow: visible;
	border: 0;
	background: transparent;
}

.bh-smc__qty button,
.bh-smc__qty input {
	margin: 0;
	box-shadow: none;
	text-align: center;
	font: inherit;
	line-height: 1;
	appearance: none;
	-webkit-appearance: none;
}

.bh-smc__qty button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex: 0 0 auto;
	width: 36px;
	min-width: 36px;
	height: 36px;
	padding: 0;
	border: 0;
	border-radius: 10px;
	background: #111;
	color: #fff;
	cursor: pointer;
	font-size: 17px;
	transition: background-color .2s ease, color .2s ease, transform .15s ease;
}

.bh-smc__qty button:active {
	transform: scale(.96);
}

.bh-smc__qty input {
	flex: 0 0 auto;
	width: 28px;
	min-width: 28px;
	height: 36px;
	padding: 0 2px;
	border: 0;
	background: transparent;
	color: inherit;
	-moz-appearance: textfield;
}

.bh-smc__qty input::-webkit-outer-spin-button,
.bh-smc__qty input::-webkit-inner-spin-button {
	margin: 0;
	-webkit-appearance: none;
}

.bh-smc__button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex: 0 0 auto;
	min-width: 92px;
	min-height: 40px;
	padding: 8px 14px;
	border: 0;
	border-radius: 10px;
	background: #111;
	color: #fff;
	cursor: pointer;
	white-space: nowrap;
	box-sizing: border-box;
	line-height: 1.1;
	transition: background-color .2s ease, color .2s ease, border-color .2s ease, opacity .2s ease, transform .15s ease;
}

.bh-smc__button:active {
	transform: scale(.98);
}

.bh-smc__button:disabled {
	opacity: .5;
	cursor: not-allowed;
}

.bh-smc-editor-notice {
	padding: 12px;
	border: 1px dashed #aaa;
	border-radius: 8px;
	font-size: 13px;
}

.bh-smc.bh-smc--editor-preview {
	position: relative;
	left: auto;
	right: auto;
	bottom: auto !important;
	width: 100%;
	max-width: 100%;
	opacity: 1;
	visibility: visible;
	transform: none;
	pointer-events: auto;
	z-index: auto !important;
}

@media (max-width: 767px) {
	.bh-smc {
		width: 94%;
	}

	.bh-smc__inner {
		flex-wrap: nowrap;
	}

	.bh-smc__product {
		min-width: 0;
	}

	.bh-smc__name {
		font-size: 13px;
	}

	.bh-smc__variation,
	.bh-smc__price {
		font-size: 10px;
	}

	.bh-smc__image {
		width: 40px;
		height: 40px;
	}

	.bh-smc__button {
		min-width: 88px;
		min-height: 38px;
		padding: 7px 10px;
		font-size: 12px;
	}

	.bh-smc__qty button {
		width: 34px;
		min-width: 34px;
		height: 34px;
	}

	.bh-smc__qty input {
		width: 24px;
		min-width: 24px;
		height: 34px;
	}
}

/* On very narrow screens, preserve the single-row layout by trimming secondary info first. */
@media (max-width: 390px) {
	.bh-smc--layout-quantity .bh-smc__image {
		display: none;
	}

	.bh-smc--layout-quantity .bh-smc__variation {
		display: none;
	}

	.bh-smc--layout-quantity .bh-smc__price {
		font-size: 9px;
	}

	.bh-smc--layout-quantity .bh-smc__button {
		min-width: 78px;
		padding-left: 8px;
		padding-right: 8px;
	}

	.bh-smc--layout-quantity .bh-smc__qty button {
		width: 31px;
		min-width: 31px;
		height: 31px;
	}

	.bh-smc--layout-quantity .bh-smc__qty input {
		width: 20px;
		min-width: 20px;
		height: 31px;
	}
}

/* BH global WooCommerce AJAX add-to-cart behavior: no separate View cart link. */
a.added_to_cart.wc-forward {
	display: none !important;
}
