/*
 * Deliberately mirrors the SBU Frequently Bought Together plugin's visual
 * language (assets/css/frontend.css there) — same card/checkbox-overlay/
 * sidebar/gradient-button shapes and colors — so the two bundling features
 * read as one consistent design on the product page. Everything here is
 * under its own `smc-` prefix; nothing is shared with or overridden by
 * sbu-fbt's stylesheet.
 */

.smc-wrap {
	margin: 32px auto;
	padding: 20px;
	background: #fff;
	border: 1px solid #e8e8ef;
	border-radius: 20px;
	box-shadow: 0 8px 30px rgba(25, 25, 45, 0.08);
	overflow: hidden;
}

.smc-wrap__header {
	border-bottom: 1px solid #ececf2;
	padding-bottom: 22px;
	margin-bottom: 24px;
}

.smc-wrap__title {
	font-size: 28px;
	line-height: 1.2;
	font-weight: 700;
	margin: 0;
	color: #171820;
	letter-spacing: -0.5px;
}

.smc-tabs {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin-bottom: 24px;
}

.smc-tab {
	padding: 10px 20px;
	border-radius: 999px;
	border: 1px solid #e2e3ea;
	background: #fff;
	color: #4b4c56;
	font-size: 14px;
	font-weight: 600;
	cursor: pointer;
	transition: all 0.2s ease;
	white-space: nowrap;
}

.smc-tab:hover:not(.is-active) {
	border-color: #c9cbd2;
	background: #f8f8fb;
}

.smc-tab.is-active {
	background: linear-gradient(90deg, #2271b1, #6a3fbf);
	border-color: transparent;
	color: #fff;
	box-shadow: 0 4px 12px rgba(82, 36, 202, 0.25);
}

.smc-panel[hidden] {
	display: none;
}

.smc-body-row {
	display: grid;
	grid-template-columns: minmax(0, 1fr) 330px;
	align-items: stretch;
	gap: 34px;
}

.smc-items {
	display: flex;
	align-items: stretch;
	flex-wrap: wrap;
	gap: 14px 8px;
	min-width: 0;
}

.smc-card {
	position: relative;
	flex: 0 1 29%;
	width: 29%;
	min-width: 0;
	display: flex;
	flex-direction: column;
	gap: 14px;
	padding: 5px;
	border: 1px solid #e4e5eb;
	border-radius: 16px;
	background: #fff;
	transition: all 0.2s ease;
}

.smc-card:hover {
	border-color: #d6d7df;
	box-shadow: 0 7px 24px rgba(25, 25, 45, 0.07);
	transform: translateY(-2px);
}

.smc-plus {
	display: flex;
	align-items: center;
	justify-content: center;
	align-self: center;
}

.smc-plus::before {
	content: '+';
	width: 34px;
	height: 33px;
	border-radius: 50%;
	color: #fff;
	border: 1px solid #e2e3e8;
	font-size: 38px;
	line-height: 1;
	font-weight: 500;
	display: grid;
	align-items: self-end;
	justify-content: center;
	box-shadow: 0 3px 10px rgba(0, 0, 0, 0.08);
	background: linear-gradient(90deg, #2271b1, #6a3fbf);
}

.smc-img-wrap {
	position: relative;
	width: 100%;
	height: 230px;
	background: #f7f6f2;
	border-radius: 12px;
	display: flex;
	align-items: center;
	justify-content: center;
	overflow: hidden;
}

.smc-img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 0.35s ease;
}

.smc-card:hover .smc-img {
	transform: scale(1.025);
}

.smc-meta {
	display: flex;
	flex-direction: column;
	gap: 8px;
	flex: 1;
}

.smc-label,
.smc-label strong,
span.smc-label {
	font-size: 16px;
	font-weight: 400;
	color: #202129 !important;
	line-height: 1.45;
}

.smc-label {
	display: block;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

a.smc-label--link {
	color: #202129 !important;
	text-decoration: none;
}

a.smc-label--link:hover {
	color: #1577c3 !important;
}

.smc-qty {
	color: #666;
	font-size: 12px;
}

.smc-price {
	margin-top: auto;
	font-size: 18px;
	font-weight: 700;
	color: #be2929;
	line-height: 1.35;
	display: flex;
	align-items: center;
	gap: 20px;
}

.smc-price .woocommerce-Price-amount {
	color: #be2929;
}

.smc-item-you-save {
	margin-top: 4px;
	color: #07934a;
	font-size: 12px;
	font-weight: 600;
}

.smc-item-swatches {
	display: flex;
	gap: 6px;
	margin-top: 4px;
}

.smc-swatch {
	display: block;
	width: 26px;
	height: 26px;
	border-radius: 6px;
	overflow: hidden;
	cursor: pointer;
	border: 2px solid transparent;
	box-sizing: border-box;
	flex-shrink: 0;
}

.smc-swatch img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.smc-swatch:hover {
	border-color: #c9cbd2;
}

.smc-swatch.is-active {
	border-color: #6a3fbf;
}

.smc-price del {
	display: block;
	font-weight: 400;
	color: #9699a3;
	margin: 0;
	font-size: 18px;
}

.smc-price del .woocommerce-Price-amount {
	color: #9699a3;
}

.smc-price ins {
	text-decoration: none;
	color: #be2929;
}

.smc-price ins .woocommerce-Price-amount {
	color: #be2929;
	font-size: 20px;
}

.smc-variation-form .variations {
	display: flex;
	flex-direction: column;
	gap: 6px;
	margin-bottom: 6px;
}

.smc-variation-attribute select {
	width: 100%;
	max-width: 140px;
	font-size: 12px;
}

.smc-variation-price {
	font-size: 13px !important;
	color: #666 !important;
	font-weight: 400 !important;
}

.smc-summary {
	display: flex;
	flex-direction: column;
	align-items: stretch;
	justify-content: center;
	gap: 10px;
	padding: 24px 26px;
	border-radius: 18px;
	background: #f9f9fb;
	min-width: 0;
}

.smc-summary-row {
	display: flex;
	justify-content: space-between;
	font-size: 13px;
	color: #4b4c56;
}

.smc-summary-row strike {
	color: #9699a3;
}

.smc-summary-discount span:last-child {
	color: #be2929;
}

.smc-total {
	align-items: center;
	font-size: 16px;
	color: #171820;
	line-height: 1.4;
	display: flex;
	justify-content: space-between;
	border-top: 1px dashed #ddd;
	padding-top: 10px;
	margin-top: 2px;
}

.smc-bank-offer {
	margin: 6px 0 0;
	padding: 8px 10px;
	color: #6e3fc8;
	font-size: 12px;
	font-weight: 600;
	background: #f6f2ff;
	border: 1px solid #e3d9fb;
	border-radius: 8px;
}

.smc-total-amount {
	display: block;
	font-weight: 700;
	font-size: 24px;
	line-height: 1.15;
	color: #171820;
	letter-spacing: -0.5px;
}

.smc-add-btn {
	display: block;
	width: 100%;
	min-height: 46px;
	padding: 10px 25px;
	background: linear-gradient(90deg, #2271b1, #6a3fbf);
	color: #fff;
	border: none;
	border-radius: 999px;
	font-size: 16px;
	font-weight: 600;
	cursor: pointer;
	box-shadow: 0 7px 18px rgba(82, 36, 202, 0.23);
	transition: all 0.2s ease;
	white-space: nowrap;
}

.smc-add-btn:hover:not(:disabled) {
	background: linear-gradient(90deg, #1a5a8f 0%, #57339c 100%);
	box-shadow: 0 9px 22px rgba(82, 36, 202, 0.3);
	transform: translateY(-1px);
}

.smc-add-btn:disabled {
	background: #e7e7eb73;
	color: #999ba4;
	cursor: not-allowed;
	box-shadow: none;
}

/* TABLET */
@media (max-width: 1199px) {
	.smc-body-row {
		grid-template-columns: 1fr;
	}
	.smc-img-wrap {
		height: 200px;
	}
}

/* MOBILE — stacked rows instead of the desktop card grid */
@media (max-width: 767px) {
	.smc-wrap {
		margin: 24px 0;
		padding: 16px 0 0;
		border-radius: 0;
		border-left: none;
		border-right: none;
		box-shadow: none;
	}

	.smc-wrap__header {
		padding: 0 16px 14px;
		margin-bottom: 14px;
	}

	.smc-wrap__title {
		font-size: 19px;
	}

	.smc-tabs {
		padding: 0;
		margin: 0 16px 16px;
		gap: 6px;
		flex-wrap: nowrap;
		overflow-x: auto;
	}

	.smc-tab {
		padding: 8px 14px;
		font-size: 12px;
		white-space: nowrap;
	}

	.smc-body-row {
		display: flex;
		flex-direction: column;
		gap: 0;
		margin: 0 16px;
		border: 1px solid #eee;
		border-radius: 10px;
		overflow: hidden;
	}

	.smc-items {
		flex-direction: column;
		flex-wrap: nowrap;
		gap: 0;
	}

	.smc-plus {
		display: none;
	}

	.smc-card {
		flex-direction: row;
		align-items: center;
		width: 100%;
		gap: 12px;
		padding: 12px 16px;
		border: none;
		border-bottom: 1px solid #f0f0f4;
		border-radius: 0;
	}

	.smc-card:last-child {
		border-bottom: none;
	}

	.smc-card:hover {
		transform: none;
		box-shadow: none;
	}

	.smc-card:first-child {
		background: #f4f4f7;
	}

	.smc-img-wrap {
		width: 56px;
		height: 56px;
		border-radius: 6px;
		flex-shrink: 0;
	}

	.smc-meta {
		flex: 1;
		min-width: 0;
		gap: 4px;
	}

	.smc-label,
	.smc-label strong {
		font-size: 13px;
	}

	.smc-price {
		font-size: 13px;
		gap: 8px;
	}

	.smc-price del {
		font-size: 12px;
	}

	.smc-price ins .woocommerce-Price-amount {
		font-size: 13px;
	}

	.smc-summary {
		padding: 14px 16px 20px;
		border-radius: 0;
	}

	.smc-add-btn {
		min-height: 50px;
		font-size: 15px;
		border-radius: 8px;
	}
}
