/*
 * Bloc WooCommerce "CONTACT & DEVIS"
 */
:root {
	--rah-box-bg: #fff;
	--rah-box-border: #e5e7eb;
	--rah-box-shadow: none;
	--rah-box-title: #121212;
	--rah-box-text: #1e4e82;
	--rah-btn-primary: #ffffff;
	--rah-btn-primary-hover: #f8fafc;
	--rah-btn-secondary: #ffffff;
	--rah-btn-secondary-border: #cbd5e1;
	--rah-btn-secondary-hover: #f8fafc;
	--rah-box-radius: 5px;
}

/* Compatibilité Blocksy/CT : layout dans .product-entry-wrapper */
.single-product .product,
.single-product .product .product-entry-wrapper {
	overflow: visible;
}

.single-product .product .product-entry-wrapper {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-start;
	gap: 1.5rem;
}

.single-product .product .summary.entry-summary,
.single-product .product .summary.entry-summary.entry-summary-items {
	flex: 1 1 420px;
	min-width: 0;
	margin-left: 0;
}

.single-product .rah-product-contact-box {
	box-sizing: border-box;
	flex: 0 0 min(419.34px, 100%);
	max-width: 419.34px;
	background: var(--rah-box-bg);
	border: 1px solid var(--rah-box-border);
	border-radius: var(--rah-box-radius);
	box-shadow: var(--rah-box-shadow);
	padding: 1.25rem;
	padding-top: 0;
	color: var(--rah-box-text);
	position: sticky;
	top: 100px;
	height: fit-content;
	z-index: 2;
}


.rah-product-contact-box__title {
	margin: 0 -1.25rem 0.85rem;
	padding: 0.75rem 1rem;
	font-size: 16px;
	font-weight: 700;
	text-transform: uppercase;
	background: #f4b53f;
	letter-spacing: 0.5px;
}
.rah-product-contact-box__actions { display: grid; gap: 0.6rem; }
.rah-product-contact-box__btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 0.75rem;
	width: 100%;
	padding: 0.75rem 1rem;
	border-radius: 0;
	font-weight: 800;
	font-size: 14px;
	text-transform: uppercase;
	text-decoration: none;
	background: #fff;
	color: var(--rah-box-text);
	border: 2px solid var(--rah-btn-secondary-border);
}
.rah-product-contact-box__btn:hover { background: var(--rah-btn-secondary-hover); }
.rah-product-contact-box__icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 1.25rem;
	height: 1.25rem;
	line-height: 1;
}
.rah-product-contact-box__icon svg {
	width: 100%;
	height: 100%;
	fill: currentColor;
}

@media (max-width: 1024px) {
	.single-product .product .product-entry-wrapper { gap: 1rem; }
	.single-product .rah-product-contact-box {
		position: static;
		flex: 1 1 100%;
		max-width: 100%;
		order: 99;
	}
}

.rah-callback-popup {
	position: fixed;
	inset: 0;
	z-index: 9999;
	pointer-events: none;
	opacity: 0;
	transition: opacity 0.2s ease;
}

.rah-callback-popup__backdrop {
	position: absolute;
	inset: 0;
	background: rgba(18, 18, 18, 0.45);
}

.rah-callback-popup__panel {
	position: absolute;
	top: 0;
	left: 0;
	max-width: 420px;
	width: min(100%, 420px);
	height: 100%;
	background: #1e4e82;
	padding: 1.2rem;
	transform: translateX(-100%);
	transition: transform 0.25s ease;
	display: flex;
	flex-direction: column;
	gap: 1rem;
}

.rah-callback-popup.is-open {
	pointer-events: auto;
	opacity: 1;
}

.rah-callback-popup.is-open .rah-callback-popup__panel {
	transform: translateX(0);
}

.rah-callback-popup.is-open .rah-callback-popup__backdrop {
	opacity: 1;
}

.rah-callback-popup__header {
	display: flex;
	justify-content: space-between;
	align-items: flex-start;
	gap: 1rem;
	color: #ffffff;
}

.rah-callback-popup__header h3 {
	margin: 0;
	margin-top: 0.35rem;
	color: #ffffff;
	font-size: 1.1rem;
	line-height: 1.3;
}

.rah-callback-popup__close {
	border: 0;
	background: transparent;
	font-size: 26px;
	line-height: 1;
	cursor: pointer;
	color: #ffffff;
	padding: 0;
	margin-top: -0.25rem;
}

.rah-callback-popup__form {
	display: grid;
	gap: 0.85rem;
}

.rah-callback-popup__form label {
	display: grid;
	gap: 0.35rem;
	font-weight: 600;
	color: #ffffff;
}

.rah-callback-popup__name-row {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 0.75rem;
	align-items: start;
}

.rah-callback-popup__name-row label {
	margin: 0;
}

.rah-callback-popup__form input {
	padding: 0.62rem 0.75rem;
	border: 1px solid #d1d5db;
	border-radius: 4px;
	background-color: #ffffff !important;
	color: #111827;
}

.rah-callback-popup__form input:focus,
.rah-callback-popup__form input:not(:placeholder-shown) {
	background-color: #ffffff !important;
}

.rah-callback-popup__submit {
	background: #f4b53f !important;
	border: 0;
	padding: 0.75rem;
	font-weight: 700;
	cursor: pointer;
	color: #111827;
}

.rah-callback-popup__submit:hover,
.rah-callback-popup__submit:focus {
	background: #f4b53f !important;
}

.rah-callback-popup__message {
	margin: 0;
	font-size: 0.95rem;
	color: #065f46;
}

.rah-callback-popup__message.is-error {
	color: #b91c1c;
}

.rah-callback-popup__submit.is-loading {
	position: relative;
	color: transparent;
	pointer-events: none;
}

.rah-callback-popup__submit.is-loading::after {
	content: "";
	position: absolute;
	top: 50%;
	left: 50%;
	width: 1rem;
	height: 1rem;
	margin: -0.5rem 0 0 -0.5rem;
	border: 2px solid rgba(17, 24, 39, 0.35);
	border-top-color: #111827;
	border-radius: 50%;
	animation: rah-callback-spin 0.7s linear infinite;
}

@keyframes rah-callback-spin {
	to {
		transform: rotate(360deg);
	}
}

.rah-callback-fab {
	position: fixed;
	right: 20px;
	bottom: 20px;
	z-index: 9998;
	width: 56px;
	height: 56px;
	border: 0;
	border-radius: 999px;
	background: #1e4e82;
	color: #ffffff;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	box-shadow: 0 10px 25px rgba(0, 0, 0, 0.25);
	cursor: pointer;
}

.rah-callback-fab svg {
	width: 24px;
	height: 24px;
	fill: currentColor;
}

.rah-callback-fab:hover,
.rah-callback-fab:focus {
	background: #163b63;
}