/* Bought Together: Hide mobile-only by default */
.bought-together-mobile {
	display: none;
}

/* Thumbnails Wrapper */
.fbt-thumbnails-wrapper {
	display: flex;
	flex-wrap: nowrap;
	gap: 3px;
	overflow-x: auto;
	padding-bottom: 10px;
	align-items: center;
	justify-content: center;
	max-width: 100%;
	scrollbar-width: none;
	-ms-overflow-style: none;
}

.fbt-thumbnails-wrapper::-webkit-scrollbar {
	display: none;
}

/* Individual Thumbnail Item */
.fbt-thumbnail-item {
	flex-shrink: 0;
	width: 29%;
	max-width: 100px;
	text-align: center;
	border-radius: 5px;
	background: #f7f8f8;
	padding-top: 1em;
	padding-bottom: 1em;
}

/* Thumbnail Images */
.fbt-thumbnail-item img {
	max-width: 60%;
	height: auto;
	margin-left: auto;
	margin-right: auto;
	mix-blend-mode: multiply;
}

.fbt-trigger-mobile {
	width: 100%;
	position: relative;
	text-align: center;
}

#boughtTogetherTrigger {
	border: 1px solid #d5d9d9;
	width: 96%;
	border-radius: 10rem;
	background: #FFF;
	height: 46px;
	padding-top: 0;
	padding-bottom: 0;
	font-weight: normal;
	font-size: 14px;
	position: relative;
}

#boughtTogetherTrigger:focus {
	outline-color: #2162a1;
	outline-offset: .2rem;
	outline-width: .3rem;
	outline-style: solid;
	box-shadow: none;
	border-color: #888c8c;
}
#boughtTogetherTrigger i {
	position: absolute;
	right: 1em;
	top: 50%;
	transform: translateY(-50%);
	color: #d5d9d9;
}

.frequently-bought-together {
	margin: 20px 0 30px 0;
	padding: 20px;
	border-radius: 5px;
}

.fbt-section-title {
	font-weight: bold;
	font-size: 1.618em;
	font-family: "Roboto", Helvetica, Arial, sans-serif;
	line-height: 1.2;
}

.frequently-bought-together h3 {
	font-size: 20px;
	margin-bottom: 15px;
	width: 100%;
	color: #333;
}

.fbt-container {
	display: flex;
	gap: 20px;
	width: 100%;
}

#fbt-form {
	margin-bottom: 0;
}

.fbt-products-wrapper {
	display: flex;
	max-width: 75%;
	align-items: center;
	gap: 20px;
	overflow-x: auto;
	padding-bottom: 10px;
	scrollbar-width: none;
	-ms-overflow-style: none;
}

.fbt-products-wrapper::-webkit-scrollbar {
	display: none;
}

.fbt-products {
	display: flex;
	gap: 5px;
}

.fbt-product {
	display: flex;
	flex-direction: column;
	align-items: center;
	text-align: center;
	width: 25%;
	max-width: 190px;
	flex-shrink: 0;
	border-radius: 5px;
}

.fbt-image-container {
	background: #f7f8f8;
	border-radius: 5px;
	position: relative;
}

.fbt-product img {
	max-width: 80%;
	height: auto;
	margin: 20px auto 20px auto;
	mix-blend-mode: multiply;
}

.fbt-product-details {
	font-size: 12px;
	line-height: 1.2;
	margin-top: 1em;
}

.fbt-product-details a {
	color: #1b334b;
	font-size: 100%;
	overflow: hidden;
	text-overflow: ellipsis;
	display: -webkit-box;
	-webkit-line-clamp: 3;
	-webkit-box-orient: vertical;
}

#fbt-form .fbt-products-wrapper > div > div:nth-child(1) .fbt-product-details > span:nth-child(1) {
	overflow: hidden;
	text-overflow: ellipsis;
	display: -webkit-box;
	-webkit-line-clamp: 3;
	-webkit-box-orient: vertical;
}

.fbt-product-details a:hover {
	color: #C60;
}

.fbt-product .price {
	display: block;
	margin-top: 5px;
	font-size: 14px;
	color: #000;
}

/* Hide the native checkbox */
.fbt-checkbox {
	position: absolute;
	opacity: 0;
	pointer-events: none;
}

/* Custom checkbox container */
.fbt-checkbox + label {
	display: inline-block;
	width: 20px;
	height: 20px;
	border: 2px solid #007185; /* Border color */
	border-radius: 5px; /* Rounded corners */
	background-color: #fff; /* Background color */
	cursor: pointer;
	position: absolute;
	min-width: 20px;
	top: 2px;
	right: 2px;
	z-index: 1;
}

/* Checked state */
.fbt-checkbox:checked + label {
	background-color: #007185; /* Fill color when checked */
	border-color: #007185; /* Border color when checked */
}

/* Disabled state */
.fbt-checkbox:disabled + label {
	background-color: #1b334b;
	border-color: #ccc;
	cursor: not-allowed;
	opacity: 0.6;
}

/* Optional: Add a tick or icon when checked */
.fbt-checkbox:checked + label::after {
	content: "\f00c";
	font-family: "Font Awesome 5 Free";
	font-size: 12px;
	color: #fff;
	position: absolute;
	top: 50%;
	left: 50%;
	transform: translate(-50%, -50%);
}


/* Add All to Cart Section */
.fbt-summary-wrapper {
	width: auto;
	display: flex;
	flex-direction: column;
	justify-content: flex-start;
	align-items: flex-start;
	gap: 15px;
	align-self: center;
}

.fbt-summary {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	text-align: left;
}

.fbt-total {
	font-size: 12px;
	margin-bottom: 2px;
}

#fbt-add-all-to-cart {
	border-radius: 100px;
	font-size: 12px;
	cursor: pointer;
	transition: background 0.3s ease;
	width: 100%;
	background: #ffd814;
	border-color: #ffd814;
	font-weight: normal;
	padding-top: 3px;
	padding-bottom: 3px;
}

/* Plus Sign */
.fbt-plus-sign {
	line-height: 1.2;
	display: flex;
	align-items: center;
	color: #333;
	align-self: center;
	margin: 0;
	flex-shrink: 0;
	font-size: 12px;
}

/* Mobile-specific styles for list view */
@media (max-width: 580px) {
	.bought-together-mobile {
		display: block;
	}
	#boughtTogetherOffcanvas {
		max-height: 380px;
	}
	#boughtTogetherOffcanvas .offcanvas-content {
		padding: 0;
	}
	#boughtTogetherOffcanvas .modal-header-section h4 {
		margin-left: 1em;
	}
	#boughtTogetherOffcanvas .close-btn {
		margin-right: 1em;
	}
	.fbt-container {
		flex-direction: column;
		gap: 10px;
	}

	.fbt-products-wrapper {
		max-width: 100%;
		overflow-x: unset;
		padding-bottom: 0;
	}

	.fbt-products {
		display: flex;
		flex-direction: column;
		gap: 15px;
		width: 100%;
	}

	.fbt-product {
		display: flex;
		flex-direction: row;
		align-items: center;
		justify-content: flex-start;
		width: 100%;
		text-align: left;
		gap: 15px;
		max-width: none;
	}

	.fbt-image-container {
		background: transparent;
		display: contents;
	}
	.fbt-image-wrapper {
		background: #f7f8f8;
		border-radius: 5px;
		padding: .5em;
	}

	.fbt-product img {
		max-width: 80px;
		height: auto;
		margin: 0;
	}

	.fbt-summary-wrapper {
		width: 100%;
		align-items: center;
		text-align: center;
		position: sticky;
		bottom: 0;
		background: #fafafa;
		border-top: 1px solid #d1d3d4;
		box-shadow: 0 0.0125em 0.125em rgb(39 43 55 / 25%);
	}

	.fbt-summary {
		width: 100%;
		align-items: center;
		text-align: center;
		margin-top: 14px;
		margin-bottom: 20px;
		padding: 0 16px;
	}
	.frequently-bought-together {
		padding: 0;
		margin-bottom: 0;
		border: none;
	}
	.fbt-products-wrapper {
		padding: 0 8px;
	}
	.fbt-products-wrapper .fbt-plus-sign {
		display: none;
	}
	#fbt-add-all-to-cart {
		border-radius: 8px;
		padding: 8px;
	}
	.fbt-checkbox + label {
		position: relative;
		z-index: unset;
	}
}

.fbt-ajax_add_to_cart.loading {
	outline-color: #2162a1;
	outline-offset: .2rem;
	outline-width: .2rem;
	outline-style: solid;
	box-shadow: none;
	border-color: #888c8c;
	color: transparent;
	text-shadow: none;
}