/* B2B Inquiry Mode — floating quote popup (bottom-right) + side contact bar */

/* ---------- Floating button ---------- */
.b2bq-fab {
	position: fixed;
	right: 22px;
	bottom: 76px; /* 让开 Blocksy 返回顶部按钮(右下角约 25-65px) */
	z-index: 99940;
	display: flex;
	align-items: center;
	gap: 8px;
	background: #1a6dc9;
	color: #fff;
	border: 0;
	border-radius: 999px;
	padding: 8px 14px;
	font-size: 13px;
	font-weight: 600;
	line-height: 1;
	box-shadow: 0 6px 18px rgba(26, 109, 201, 0.45);
	cursor: pointer;
	transition: background 0.2s ease, transform 0.2s ease;
}

.b2bq-fab:hover {
	background: #155ba8;
	transform: translateY(-1px);
}

.b2bq-fab svg {
	width: 15px;
	height: 15px;
	fill: #fff;
	flex: none;
}

/* ---------- Quote popup ---------- */
.b2bq-modal {
	position: fixed;
	inset: 0;
	z-index: 99990;
	display: none;
}

.b2bq-modal.is-open {
	display: block;
}

.b2bq-modal__overlay {
	position: absolute;
	inset: 0;
	background: rgba(0, 0, 0, 0.45);
}

.b2bq-card {
	position: absolute;
	right: 22px;
	bottom: 120px; /* 位于缩小后的询盘按钮上方 */
	width: 372px;
	max-width: calc(100vw - 24px);
	background: #fff;
	border-radius: 8px;
	overflow: hidden;
	box-shadow: 0 16px 48px rgba(0, 0, 0, 0.28);
}

.b2bq-head {
	display: flex;
	align-items: center;
	gap: 10px;
	background: #1a6dc9;
	color: #fff;
	padding: 13px 14px;
}

.b2bq-head svg {
	width: 26px;
	height: 26px;
	fill: #fff;
	flex: none;
}

.b2bq-head strong {
	flex: 1;
	font-size: 15px;
	line-height: 1.3;
}

.b2bq-x {
	background: none;
	border: 0;
	color: #fff;
	font-size: 26px;
	line-height: 1;
	padding: 0 2px;
	cursor: pointer;
}

.b2bq-body {
	padding: 18px 16px 20px;
}

.b2bq-body .b2bq-field {
	position: relative;
	margin: 0 0 14px;
}

.b2bq-body .b2bq-field input[type="text"],
.b2bq-body .b2bq-field input[type="email"],
.b2bq-body .b2bq-field textarea {
	width: 100%;
	box-sizing: border-box;
	border: 1px solid #d9d9d9;
	border-radius: 4px;
	background: #fff;
	padding: 12px 40px 12px 12px;
	font-size: 14px;
	color: #333;
}

.b2bq-body .b2bq-field textarea {
	min-height: 112px;
	resize: vertical;
}

.b2bq-body .b2bq-field input:focus,
.b2bq-body .b2bq-field textarea:focus {
	outline: none;
	border-color: #1a6dc9;
}

.b2bq-body .b2bq-field::after {
	content: "";
	position: absolute;
	right: 12px;
	top: 13px;
	width: 18px;
	height: 18px;
	opacity: 0.45;
	pointer-events: none;
	background: center / contain no-repeat;
}

.b2bq-field--name::after {
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23888' d='M12 12a4 4 0 100-8 4 4 0 000 8zm0 2c-3.33 0-10 1.67-10 5v3h20v-3c0-3.33-6.67-5-10-5z'/%3E%3C/svg%3E");
}

.b2bq-field--tel::after {
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23888' d='M6.62 10.79a15.05 15.05 0 006.59 6.59l2.2-2.2a1 1 0 011.01-.24 11.36 11.36 0 003.58.57 1 1 0 011 1V20a1 1 0 01-1 1A17 17 0 013 4a1 1 0 011-1h3.5a1 1 0 011 1 11.36 11.36 0 00.57 3.58 1 1 0 01-.25 1.01l-2.2 2.2z'/%3E%3C/svg%3E");
}

.b2bq-field--email::after {
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23888' d='M20 4H4a2 2 0 00-2 2v12a2 2 0 002 2h16a2 2 0 002-2V6a2 2 0 00-2-2zm0 4l-8 5-8-5V6l8 5 8-5v2z'/%3E%3C/svg%3E");
}

.b2bq-field--msg::after {
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23888' d='M3 3h18v18H3V3zm2 4v2h14V7H5zm0 4v2h10v-2H5z'/%3E%3C/svg%3E");
}

.b2bq-submit .wpcf7-submit {
	background: #1a6dc9;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23ffffff' d='M2.01 21L23 12 2.01 3 2 10l15 2-15 2z'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 14px center;
	background-size: 16px 16px;
	color: #fff;
	border: 0;
	border-radius: 4px;
	padding: 12px 42px 12px 26px;
	font-size: 15px;
	font-weight: 600;
	cursor: pointer;
}

.b2bq-submit .wpcf7-submit:hover {
	background-color: #155ba8;
}

/* ---------- Side contact bar ---------- */
.b2bc-bar {
	position: fixed;
	right: 0;
	top: 50%;
	transform: translateY(-50%);
	z-index: 99930;
}

.b2bc-tabs {
	display: flex;
	flex-direction: column;
}

.b2bc-tab {
	width: 46px;
	height: 46px;
	background: #1d3e6e;
	border: 0;
	border-bottom: 1px solid rgba(255, 255, 255, 0.18);
	color: #fff;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 0;
}

.b2bc-tab:last-child {
	border-bottom: 0;
}

.b2bc-tab svg {
	width: 20px;
	height: 20px;
	fill: #fff;
}

.b2bc-tab:hover {
	background: #16325c;
}

.b2bc-panel {
	display: none;
	position: absolute;
	right: 46px;
	top: 0;
	min-width: 252px;
	background: #1d3e6e;
	box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.b2bc-panel.is-open {
	display: block;
}

.b2bc-row {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 13px 14px;
	border-bottom: 1px solid rgba(255, 255, 255, 0.15);
	color: #fff;
	text-decoration: none;
	font-size: 14px;
	line-height: 1.4;
	word-break: break-all;
}

.b2bc-row svg {
	width: 18px;
	height: 18px;
	fill: #fff;
	flex: none;
}

a.b2bc-row:hover {
	background: #16325c;
	color: #fff;
}

.b2bc-qrwrap {
	padding: 12px 14px 14px;
	border-bottom: 1px solid rgba(255, 255, 255, 0.15);
}

.b2bc-qrlabel {
	font-size: 14px;
	color: #fff;
	margin-bottom: 8px;
}

.b2bc-qrcode img,
.b2bc-qrcode canvas,
.b2bc-qrcode table {
	background: #fff;
	padding: 5px;
	border-radius: 4px;
	display: block;
}

/* ---------- 移动端/平板底部导航条 ---------- */
.b2bc-bottombar {
	display: none;
}

@media (max-width: 1024px) {
	.b2bq-fab {
		display: none; /* INQUIRY 已在底部导航条,悬浮按钮不再需要 */
	}

	body {
		padding-bottom: 58px; /* 给底部导航条让位 */
	}

	.b2bc-bottombar {
		display: flex;
		position: fixed;
		left: 0;
		right: 0;
		bottom: 0;
		z-index: 99930;
		background: #fff;
		border-top: 1px solid #e8e8e8;
		box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.06);
	}

	.b2bc-bottombar a,
	.b2bc-bottombar button {
		flex: 1;
		display: flex;
		flex-direction: column;
		align-items: center;
		justify-content: center;
		gap: 3px;
		padding: 8px 0 7px;
		background: none;
		border: 0;
		cursor: pointer;
		color: #333;
		font-size: 11px;
		font-weight: 600;
		line-height: 1;
		text-decoration: none;
		text-transform: uppercase;
		font-family: inherit;
	}

	.b2bc-bottombar svg {
		width: 22px;
		height: 22px;
		fill: #333;
	}

	.b2bc-bottombar a:hover,
	.b2bc-bottombar a:active,
	.b2bc-bottombar button:hover,
	.b2bc-bottombar button:active {
		color: #1a6dc9;
	}

	.b2bc-bottombar a:hover svg,
	.b2bc-bottombar button:hover svg {
		fill: #1a6dc9;
	}

	.b2bq-card {
		bottom: 66px;
	}
}

/* ---------- Mobile ---------- */
@media (max-width: 640px) {
	.b2bq-card {
		right: 12px;
	}

	.b2bc-tab {
		width: 40px;
		height: 40px;
	}

	.b2bc-panel {
		right: 40px;
		min-width: 232px;
	}
}

/* Products for Quote 行 (悬浮弹窗, 仅产品页显示) */
.b2bq-pfq {
	margin: 0 0 12px;
	font-size: 13.5px;
	color: #333;
}

.b2bq-pfq a {
	color: #1a6dc9;
	font-weight: 600;
	text-decoration: underline;
	text-underline-offset: 2px;
}

.b2bq-pfq a:hover {
	color: #155ba8;
}
