/* Bollaert Cart to Quote — button + modal (theme-matched: brand turquoise,
 * pill buttons, soft shadows, focus rings) */

/* --- "Demander un devis" button: clear SECONDARY action under the green
 * checkout button — white pill with a brand border that fills on hover. --- */
.bw-ctq-open {
	margin-top: 10px;
	width: 100%;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 0.5em;
	padding: 0.85em 1.6em;
	border: 2px solid var(--wp--preset--color--brand, #39c);
	border-radius: 999px;
	background: var(--wp--preset--color--white, #fff);
	color: var(--wp--preset--color--brand-dark, #1d6e96);
	font-weight: 700;
	font-size: var(--wp--preset--font-size--md, 1rem);
	line-height: 1.2;
	cursor: pointer;
	text-decoration: none;
	transition: background-color 0.15s ease, color 0.15s ease, transform 0.15s ease, box-shadow 0.15s ease;
}
.bw-ctq-open::before {
	content: "";
	width: 18px;
	height: 18px;
	flex: 0 0 auto;
	background: currentColor;
	-webkit-mask: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="black" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z"/><polyline points="14 2 14 8 20 8"/><line x1="16" y1="13" x2="8" y2="13"/><line x1="16" y1="17" x2="8" y2="17"/></svg>') center / contain no-repeat;
	mask: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="black" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z"/><polyline points="14 2 14 8 20 8"/><line x1="16" y1="13" x2="8" y2="13"/><line x1="16" y1="17" x2="8" y2="17"/></svg>') center / contain no-repeat;
}
.bw-ctq-open:hover {
	background: var(--wp--preset--color--brand, #39c);
	color: #fff;
	transform: translateY(-1px);
	box-shadow: 0 12px 26px -14px rgba(51, 153, 204, 0.85);
}
.bw-ctq-open:focus-visible {
	outline: none;
	box-shadow: 0 0 0 3px rgba(51, 153, 204, 0.35);
}

.bw-ctq-cta { max-width: 480px; margin: 16px auto 0; padding: 0 16px; box-sizing: border-box; }
.bw-ctq-cta .bw-ctq-open { width: 100%; margin-top: 0; }

/* --- Modal --- */
.bw-ctq-modal { position: fixed; inset: 0; z-index: 99999; display: none; }
.bw-ctq-modal.is-open { display: block; }
.bw-ctq-backdrop {
	position: absolute;
	inset: 0;
	background: rgba(2, 6, 23, 0.6);
	backdrop-filter: blur(3px);
	-webkit-backdrop-filter: blur(3px);
}

.bw-ctq-dialog {
	position: relative;
	max-width: 500px;
	margin: 6vh auto;
	background: #fff;
	border-radius: 18px;
	padding: 0 0 20px;
	box-shadow: 0 30px 80px -20px rgba(2, 6, 23, 0.55);
	max-height: 88vh;
	overflow: auto;
	animation: bwCtqIn 0.18s ease-out;
}
@keyframes bwCtqIn {
	from { opacity: 0; transform: translateY(10px) scale(0.985); }
	to   { opacity: 1; transform: none; }
}

/* Brand header band: title + subtitle live on a turquoise gradient */
.bw-ctq-dialog h3 {
	margin: 0;
	padding: 22px 56px 6px 26px;
	background: linear-gradient(120deg, var(--wp--preset--color--brand-dark, #1d6e96), var(--wp--preset--color--brand, #39c));
	color: #fff;
	font-size: 1.3rem;
	font-weight: 800;
	letter-spacing: -0.01em;
	border-radius: 18px 18px 0 0;
}
.bw-ctq-sub {
	margin: 0 0 18px;
	padding: 0 26px 16px;
	background: linear-gradient(120deg, var(--wp--preset--color--brand-dark, #1d6e96), var(--wp--preset--color--brand, #39c));
	color: rgba(255, 255, 255, 0.92);
	font-size: 14px;
	line-height: 1.45;
}
.bw-ctq-x {
	position: absolute; top: 12px; right: 14px;
	width: 34px; height: 34px;
	display: flex; align-items: center; justify-content: center;
	border: 0; border-radius: 50%;
	background: rgba(255, 255, 255, 0.18);
	font-size: 24px; line-height: 1;
	cursor: pointer; color: #fff;
	transition: background-color 0.15s ease;
}
.bw-ctq-x:hover { background: rgba(255, 255, 255, 0.32); }

/* --- Form --- */
.bw-ctq-form { padding: 0 26px; }
.bw-ctq-form label {
	display: block;
	margin: 0 0 12px;
	font-size: 13px;
	color: #334155;
	font-weight: 600;
}
.bw-ctq-form input, .bw-ctq-form textarea {
	width: 100%;
	margin-top: 5px;
	padding: 10px 12px;
	border: 1px solid var(--wp--preset--color--border, #cbd5e1);
	border-radius: 10px;
	font: inherit;
	font-weight: 400;
	font-size: 15px;
	box-sizing: border-box;
	background: #fff;
	transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.bw-ctq-form input:focus, .bw-ctq-form textarea:focus {
	outline: none;
	border-color: var(--wp--preset--color--brand, #39c);
	box-shadow: 0 0 0 3px rgba(51, 153, 204, 0.2);
}
.bw-ctq-row { display: flex; gap: 12px; }
.bw-ctq-row label { flex: 1; }
.bw-ctq-hp { position: absolute !important; left: -9999px !important; height: 0; width: 0; opacity: 0; }

.bw-ctq-actions { margin-top: 12px; }
.bw-ctq-submit {
	width: 100%;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 0.9em 1.6em;
	border: 0;
	border-radius: 999px;
	background: var(--wp--preset--color--brand, #39c);
	color: #fff;
	font-weight: 700;
	font-size: var(--wp--preset--font-size--md, 1rem);
	cursor: pointer;
	box-shadow: 0 14px 30px -16px rgba(51, 153, 204, 0.9);
	transition: filter 0.15s ease, transform 0.15s ease;
}
.bw-ctq-submit:hover { filter: brightness(0.93); transform: translateY(-1px); }
.bw-ctq-submit[disabled] {
	background: #cbd5e1;
	color: #64748b;
	box-shadow: none;
	cursor: not-allowed;
	transform: none;
	filter: none;
}
.bw-ctq-msg { margin: 10px 0 0; min-height: 18px; font-size: 13px; color: var(--wp--preset--color--brand-dark, #1d6e96); }

@media (max-width: 540px) {
	.bw-ctq-row { flex-direction: column; gap: 0; }
	.bw-ctq-dialog { margin: 0; border-radius: 0; min-height: 100vh; }
	.bw-ctq-dialog h3 { border-radius: 0; }
}
