/* ═══════════════════════════════════════════════════════════════
   Frequently Bought Together Module
   All visual properties driven by --wfbt-* CSS custom variables
   ═══════════════════════════════════════════════════════════════ */


.wraith-fbt-thumb {
	width: 100px;
	max-width: 100%;
	height: 100px;
	aspect-ratio: 1 / 1;
	margin-bottom: 8px;
	display: flex;
	align-items: center;
	justify-content: center;
	overflow: hidden;
	box-sizing: border-box;
	border-radius: var(--wfbt-img-radius, 6px);
	background: var(--wfbt-img-bg, transparent);
	border: var(--wfbt-img-border, none);
}

.wraith-fbt-thumb img {
	width: 100%;
	height: 100%;
	object-fit: var(--wfbt-img-fit, contain);
}

.wraith-fbt-module {
	margin: var(--wfbt-margin, 30px 0);
	padding: var(--wfbt-padding, 24px);
	background: var(--wfbt-bg, #f8fafc);
	border: var(--wfbt-border-width, 1px) var(--wfbt-border-style, solid) var(--wfbt-border-color, #e2e8f0);
	border-radius: var(--wfbt-radius, 12px);
	box-shadow: var(--wfbt-shadow, none);
	max-width: var(--wfbt-max-width, 100%);
	box-sizing: border-box;
}

.wraith-fbt-header {
	margin-bottom: var(--wfbt-heading-gap, 16px);
	text-align: var(--wfbt-heading-align, left);
}

.wraith-fbt-title {
	font-size: var(--wfbt-heading-size, 20px);
	font-weight: var(--wfbt-heading-weight, 700);
	font-family: var(--wfbt-heading-font, inherit);
	line-height: var(--wfbt-heading-lh, 1.3);
	color: var(--wfbt-heading-color, #0f172a);
	margin: 0 0 4px 0;
}

.wraith-fbt-subtitle {
	font-size: var(--wfbt-subheading-size, 14px);
	color: var(--wfbt-subheading-color, #64748b);
	font-family: var(--wfbt-subheading-font, inherit);
	margin: 0;
}

.wraith-fbt-body {
	display: flex;
	flex-direction: column;
	gap: var(--wfbt-panel-gap, 16px);
}

@media (min-width: 768px) {
	.wraith-fbt-body {
		flex-direction: row;
		align-items: flex-start;
		justify-content: flex-start;
	}
}

.wraith-fbt-cards {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: var(--wfbt-card-gap, 12px);
}

.wraith-fbt-plus-separator {
	font-size: var(--wfbt-sep-size, 18px);
	font-weight: 700;
	color: var(--wfbt-sep-color, #94a3b8);
	user-select: none;
}

@media (max-width: 600px) {
	.wraith-fbt-plus-separator.wgb-sep-hide-mobile {
		display: none;
	}
}

.wraith-fbt-card {
	display: flex;
	flex-direction: column;
	align-items: center;
	background: var(--wfbt-card-bg, #ffffff);
	border: var(--wfbt-card-border-width, 1px) var(--wfbt-card-border-style, solid) var(--wfbt-card-border-color, #cbd5e1);
	border-radius: var(--wfbt-card-radius, 10px);
	padding: var(--wfbt-card-padding, 12px);
	box-shadow: var(--wfbt-card-shadow, none);
	width: 140px;
	box-sizing: border-box;
	position: relative;
	transition: all 0.2s ease;
}

.wraith-fbt-card.is-selected {
	border-color: var(--wfbt-card-sel-border, #0284c7);
	background: var(--wfbt-card-sel-bg, #ffffff);
	box-shadow: var(--wfbt-card-sel-shadow, 0 4px 12px rgba(2, 132, 199, 0.12));
}

.wraith-fbt-card.is-disabled {
	opacity: 0.5;
	pointer-events: none;
}

.wraith-fbt-checkbox-wrap {
	position: absolute;
	top: 8px;
	right: 8px;
	z-index: 2;
}

.wraith-fbt-check {
	width: 18px;
	height: 18px;
	cursor: pointer;
	accent-color: var(--wfbt-check-color, #0284c7);
}

.wraith-fbt-card-info {
	width: 100%;
	text-align: center;
}

.wraith-fbt-card-title {
	font-size: var(--wfbt-title-size, 12px);
	font-weight: var(--wfbt-title-weight, 600);
	font-family: var(--wfbt-title-font, inherit);
	color: var(--wfbt-title-color, #1e293b);
	text-decoration: none;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
	line-height: 1.3;
	margin-bottom: 4px;
	transition: color 0.15s ease;
}

.wraith-fbt-card-title:hover {
	color: var(--wfbt-title-hover, #0284c7);
}

.wraith-fbt-card-price {
	font-size: var(--wfbt-price-size, 13px);
	font-weight: var(--wfbt-price-weight, 700);
	color: var(--wfbt-price-color, #0284c7);
}

.wraith-fbt-card-price del {
	color: var(--wfbt-del-price-color, #94a3b8);
	font-size: 0.9em;
}

.wraith-fbt-card-price ins {
	text-decoration: none;
	color: var(--wfbt-sale-price-color, #0284c7);
}

.wraith-fbt-card,
.wraith-fbt-total-panel {
	color: var(--wfbt-text-color, #0f172a);
}

.wraith-fbt-thumb,
.wraith-fbt-thumb img {
	width: 100px !important;
	height: 100px !important;
	max-width: 100px !important;
	max-height: 100px !important;
	box-sizing: border-box;
}

.wraith-fbt-thumb img {
	object-fit: var(--wfbt-img-fit, contain);
}

.wraith-fbt-var-select {
	width: 100%;
	font-size: 11px;
	padding: 4px;
	margin-top: 4px;
	border-radius: 4px;
	border: 1px solid #cbd5e1;
	background: #ffffff;
	color: #0f172a;
}

.wraith-fbt-total-panel {
	min-width: 200px;
	background: var(--wfbt-total-bg, #ffffff);
	border: var(--wfbt-total-border-width, 1px) var(--wfbt-total-border-style, solid) var(--wfbt-total-border-color, #e2e8f0);
	border-radius: var(--wfbt-total-radius, 10px);
	padding: var(--wfbt-total-padding, 16px);
	box-shadow: var(--wfbt-total-shadow, 0 2px 8px rgba(0, 0, 0, 0.04));
	text-align: center;
	box-sizing: border-box;
	margin: 0;
	flex: 0 0 auto;
}

.wraith-fbt-total-label {
	font-size: var(--wfbt-total-lbl-size, 12px);
	font-weight: var(--wfbt-total-lbl-weight, 600);
	color: var(--wfbt-total-lbl-color, #64748b);
	text-transform: uppercase;
	letter-spacing: 0.05em;
	margin-bottom: 4px;
}

.wraith-fbt-total-amount {
	font-size: var(--wfbt-total-amt-size, 22px);
	font-weight: var(--wfbt-total-amt-weight, 800);
	color: var(--wfbt-total-amt-color, #0f172a);
}

.wraith-fbt-regular-amount {
	font-size: 13px;
	color: var(--wfbt-del-price-color, #94a3b8);
	margin-left: 6px;
}

.wraith-fbt-savings {
	font-size: var(--wfbt-savings-size, 13px);
	font-weight: var(--wfbt-savings-weight, 700);
	color: var(--wfbt-savings-color, #16a34a);
	margin-top: 4px;
	margin-bottom: 12px;
}

.wraith-fbt-cta-btn {
	width: var(--wfbt-cta-width, 100%);
	padding: 12px 16px;
	font-size: var(--wfbt-cta-size, 14px);
	font-weight: var(--wfbt-cta-weight, 700);
	font-family: var(--wfbt-cta-font, inherit);
	text-transform: var(--wfbt-cta-transform, none);
	border-radius: var(--wfbt-cta-radius, 8px);
	cursor: pointer;
	background-color: var(--wfbt-cta-bg, #0284c7) !important;
	color: var(--wfbt-cta-color, #ffffff) !important;
	border: var(--wfbt-cta-border, none) !important;
	box-shadow: var(--wfbt-cta-shadow, none);
	transition: all 0.2s ease;
}

.wraith-fbt-cta-btn:hover {
	background-color: var(--wfbt-cta-hover-bg, #0369a1) !important;
	color: var(--wfbt-cta-hover-color, #ffffff) !important;
}

.wraith-fbt-cta-btn:disabled,
.wraith-fbt-cta-btn.loading {
	opacity: 0.6;
	cursor: not-allowed;
}

/* Keep bundle cards and the purchase summary as one compact group. */
@media (min-width: 768px) {
	.wraith-fbt-body {
		justify-content: flex-start;
		column-gap: var(--wfbt-panel-gap, 16px);
	}

	.wraith-fbt-cards {
		flex: 0 1 auto;
	}
}

.wraith-fbt-status-msg {
	font-size: 12px;
	font-weight: 600;
}
