/* BD Tools Storefront Fixes — Stage 1 (19 Nov 2026) */

:root {
	--bdt-text: #11202e;
	--bdt-muted: #5a6678;
	--bdt-line: #e6e9ee;
	--bdt-soft: #f5f7fa;
	--bdt-accent: #ffd400;   /* BD Tools yellow, from the logo */
	--bdt-accent-ink: #111111;
	--bdt-radius: 12px;
	--bdt-shadow: 0 1px 3px rgba(13, 27, 42, .06), 0 1px 2px rgba(13, 27, 42, .04);
}

/* 1. Footer service icons rendered as giant stretched images: pin them to a small fixed size. */
.info-box-icon img,
.wd-info-box .info-box-icon img {
	width: 48px !important;
	height: 48px !important;
	max-width: 48px !important;
	object-fit: contain;
}

/* 2. Product card titles: show two full lines (brand + part number) instead of a 3-word cut. */
.wd-product .wd-entities-title,
.product-grid-item .wd-entities-title {
	white-space: normal !important;
	overflow: hidden;
	text-overflow: clip;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	line-height: 1.35;
	min-height: calc(1.35em * 2);
	max-height: none;
}
.bdt-card-mpn {
	margin: 2px 0 6px;
	font-size: 12px;
	color: var(--bdt-muted);
	letter-spacing: .01em;
}
.bdt-card-mpn strong { color: var(--bdt-text); font-weight: 600; }

/* 3. Mobile product page overflow guard (root cause fixed per element below; this stops sideways scrolling). */
@media (max-width: 768px) {
	html, body { overflow-x: hidden; }
	.single-product .summary-inner,
	.single-product .product-image-summary-inner,
	.single-product .woocommerce-product-gallery { max-width: 100%; min-width: 0; }
	.single-product table { width: 100%; table-layout: fixed; }
	.single-product .single_add_to_cart_button,
	.single-product .wd-buy-now-btn { flex: 1 1 auto; }
	.single-product .product_meta { display: flex; flex-wrap: wrap; gap: 4px 12px; }
}

/* 4. Consent banner */
.bdt-consent {
	position: fixed;
	left: 16px; right: 16px; bottom: 16px;
	z-index: 99999;
	max-width: 720px;
	margin: 0 auto;
	padding: 16px 18px;
	background: #fff;
	color: var(--bdt-text);
	border: 1px solid var(--bdt-line);
	border-radius: var(--bdt-radius);
	box-shadow: 0 18px 40px -24px rgba(13, 27, 42, .35), var(--bdt-shadow);
	display: flex; gap: 14px; align-items: center; flex-wrap: wrap;
	font-size: 14px; line-height: 1.5;
}
.bdt-consent[hidden] { display: none; }
.bdt-consent__text { margin: 0; flex: 1 1 320px; }
.bdt-consent__text a { color: var(--bdt-text); text-decoration: underline; text-underline-offset: 2px; }
.bdt-consent__actions { display: flex; gap: 8px; }
.bdt-btn {
	border-radius: 999px; padding: 9px 18px; font-weight: 600; font-size: 14px; cursor: pointer;
	border: 1px solid var(--bdt-line); background: #fff; color: var(--bdt-text);
}
.bdt-btn--primary { background: var(--bdt-accent); border-color: var(--bdt-accent); color: var(--bdt-accent-ink); }
.bdt-btn:focus-visible { outline: 3px solid rgba(17, 32, 46, .35); outline-offset: 2px; }

/* Keep the consent banner above Woodmart's sticky add-to-cart bar on product pages. */
.single-product .bdt-consent { bottom: 84px; }
@media (max-width: 768px) { .bdt-consent { bottom: 72px; } }
/* Beat Woodmart's global button styles inside the banner. */
#bdt-consent .bdt-btn { text-transform: none; letter-spacing: 0; line-height: 1.2; min-height: 0; box-shadow: none; }
#bdt-consent .bdt-btn--primary { background: var(--bdt-accent) !important; border-color: var(--bdt-accent) !important; color: var(--bdt-accent-ink) !important; }
#bdt-consent .bdt-btn--ghost { background: #fff !important; color: var(--bdt-text) !important; }
