/* Bulk Quotation - frontend styles */

.bq-add-form {
	display: flex;
	align-items: center;
	gap: 8px;
	margin: 10px 0;
	flex-wrap: wrap;
}

.bq-qty-input {
	width: 64px;
	padding: 6px 8px;
	border: 1px solid #ccc;
	border-radius: 4px;
	box-sizing: border-box;
}

.bq-add-btn {
	background: var(--bq-button-bg, #2271b1);
	color: var(--bq-button-text, #ffffff);
	border: none;
	padding: 10px 18px;
	border-radius: 4px;
	cursor: pointer;
	font-size: 14px;
	font-weight: 600;
}

.bq-add-btn:hover {
	opacity: 0.9;
}

.bq-add-feedback {
	font-size: 13px;
}

.bq-add-feedback.bq-success {
	color: #1a7f37;
}

.bq-add-feedback.bq-error {
	color: var(--bq-accent, #d63638);
}

/* Floating toggle */
.bq-floating-toggle {
	position: fixed;
	right: 24px;
	bottom: 24px;
	background: var(--bq-floating-bg, #2271b1);
	color: var(--bq-floating-text, #ffffff);
	width: 56px;
	height: 56px;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	box-shadow: 0 4px 14px rgba(0, 0, 0, 0.25);
	z-index: 99998;
	font-size: 22px;
}

.bq-floating-count {
	position: absolute;
	top: -4px;
	right: -4px;
	background: var(--bq-accent, #d63638);
	color: #fff;
	font-size: 11px;
	font-weight: 700;
	min-width: 18px;
	height: 18px;
	border-radius: 9px;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 0 4px;
}

/* Overlay */
.bq-overlay {
	position: fixed;
	inset: 0;
	background: rgba(0, 0, 0, 0.4);
	z-index: 99997;
	display: none;
}

.bq-overlay.bq-open {
	display: block;
}

/* Floating panel */
.bq-floating-panel {
	position: fixed;
	top: 0;
	right: -420px;
	width: 380px;
	max-width: 90vw;
	height: 100%;
	background: #fff;
	box-shadow: -4px 0 20px rgba(0, 0, 0, 0.2);
	z-index: 99999;
	transition: right 0.25s ease;
	display: flex;
	flex-direction: column;
}

.bq-floating-panel.bq-open {
	right: 0;
}

.bq-panel-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 16px;
	border-bottom: 1px solid #eee;
	background: var(--bq-panel-header-bg, #ffffff);
	color: var(--bq-panel-header-text, #1d2327);
}

.bq-panel-header h3 {
	margin: 0;
	font-size: 16px;
	color: inherit;
}

.bq-panel-close {
	background: none;
	border: none;
	font-size: 24px;
	line-height: 1;
	cursor: pointer;
	color: inherit;
}

.bq-panel-body {
	padding: 16px;
	overflow-y: auto;
	flex: 1;
}

/* Inline (page shortcode) panel */
.bq-inline-panel {
	border: 1px solid #eee;
	border-radius: 8px;
	max-width: 520px;
}

.bq-inline-panel .bq-panel-body {
	overflow: visible;
}

/* Items list */
.bq-items-list {
	display: flex;
	flex-direction: column;
	gap: 10px;
	margin-bottom: 16px;
}

/*
 * Item row: force explicit flex sizing on every child with !important.
 * Many themes apply their own generic "input { width: 100%; flex: 1 }"
 * style rules inside flex containers, which was making the quantity box
 * balloon and squeeze the product title. These overrides make sure the
 * title takes the available space and the quantity box always stays small,
 * regardless of theme styles.
 */
.bq-item-row {
	display: flex !important;
	align-items: center !important;
	gap: 8px !important;
	padding-bottom: 10px;
	border-bottom: 1px solid #f0f0f0;
	width: 100%;
}

.bq-item-title {
	flex: 1 1 auto !important;
	min-width: 0;
	font-size: 14px;
	line-height: 1.4;
	word-break: break-word;
}

.bq-item-qty {
	flex: 0 0 52px !important;
	width: 52px !important;
	max-width: 52px !important;
	min-width: 52px !important;
	padding: 4px 6px !important;
	border: 1px solid #ccc;
	border-radius: 4px;
	box-sizing: border-box !important;
	font-size: 13px;
	text-align: center;
}

.bq-item-remove {
	flex: 0 0 auto !important;
	background: none;
	border: none;
	color: var(--bq-accent, #d63638);
	font-size: 18px;
	cursor: pointer;
	line-height: 1;
	padding: 0 2px;
}

.bq-step-cart .bq-next-btn {
	margin-top: 4px;
}

.bq-empty-msg {
	color: #777;
	font-size: 14px;
}

/* Form */
.bq-step h4 {
	margin: 0 0 10px;
	font-size: 14px;
}

.bq-step-hint {
	font-size: 13px;
	color: #666;
	margin: 0 0 12px;
}

.bq-input {
	width: 100%;
	padding: 10px;
	margin-bottom: 10px;
	border: 1px solid #ccc;
	border-radius: 4px;
	box-sizing: border-box;
}

.bq-next-btn,
.bq-send-otp-btn,
.bq-verify-otp-btn,
.bq-submit-btn {
	width: 100%;
	background: var(--bq-button-bg, #2271b1);
	color: var(--bq-button-text, #ffffff);
	border: none;
	padding: 12px;
	border-radius: 4px;
	cursor: pointer;
	font-weight: 600;
}

.bq-next-btn:hover,
.bq-send-otp-btn:hover,
.bq-verify-otp-btn:hover,
.bq-submit-btn:hover {
	opacity: 0.9;
}

.bq-submit-btn:disabled,
.bq-send-otp-btn:disabled,
.bq-verify-otp-btn:disabled,
.bq-resend-otp-btn:disabled {
	opacity: 0.6;
	cursor: not-allowed;
}

/* OTP row */
.bq-otp-row {
	display: flex;
	gap: 8px;
	margin-top: 10px;
	flex-wrap: wrap;
	align-items: center;
}

.bq-otp-row .bq-otp-input {
	flex: 1 1 120px;
	margin-bottom: 0;
	letter-spacing: 2px;
	text-align: center;
}

.bq-otp-row .bq-verify-otp-btn {
	flex: 0 0 auto;
	width: auto;
	padding: 10px 16px;
}

.bq-otp-row .bq-resend-otp-btn {
	flex: 0 0 auto;
	width: auto;
	background: none;
	border: 1px solid #ccc;
	color: #444;
	padding: 10px 14px;
	border-radius: 4px;
	cursor: pointer;
	font-size: 13px;
}

.bq-link-btn {
	display: inline-block;
	background: none;
	border: none;
	color: var(--bq-button-bg, #2271b1);
	cursor: pointer;
	font-size: 13px;
	margin-top: 14px;
	padding: 0;
	text-decoration: underline;
}

.bq-verified-email-display {
	font-size: 13px;
	background: #f0f6fc;
	border: 1px solid #c5d9ed;
	color: #1d2327;
	padding: 8px 10px;
	border-radius: 4px;
	margin: 0 0 12px;
	word-break: break-word;
}

.bq-form-msg,
.bq-verify-msg {
	font-size: 13px;
	margin: 10px 0;
	min-height: 16px;
}

.bq-form-msg.bq-success,
.bq-verify-msg.bq-success {
	color: #1a7f37;
}

.bq-form-msg.bq-error,
.bq-verify-msg.bq-error {
	color: var(--bq-accent, #d63638);
}
