.rsbx-precontrat {
	--rsbx-text: #4f5d64;
	--rsbx-dark: #000;
	--rsbx-border: #4f5d64;
	--rsbx-yellow: #ffcc00;
	--rsbx-red: #d0021b;
	max-width: 860px;
	font-family: 'Ubuntu', Helvetica, Arial, sans-serif;
	color: var(--rsbx-dark);
	scroll-margin-top: 140px;
}

.rsbx-precontrat *,
.rsbx-precontrat *::before,
.rsbx-precontrat *::after {
	box-sizing: border-box;
}

.rsbx-precontrat [hidden] {
	display: none !important;
}

.rsbx-hp {
	position: absolute;
	left: -9999px;
	width: 1px;
	height: 1px;
	overflow: hidden;
}

/* Particulier / Société */
.rsbx-types {
	display: flex;
	flex-wrap: wrap;
	gap: 16px 0;
	margin: 0 0 50px;
	padding: 0;
	border: 0;
}

.rsbx-type {
	position: relative;
	display: inline-flex;
	align-items: center;
	width: 295px;
	margin: 0;
	cursor: pointer;
}

.rsbx-type input {
	position: absolute;
	opacity: 0;
	width: 29px;
	height: 29px;
	margin: 0;
}

.rsbx-type__box {
	position: relative;
	flex: none;
	width: 29px;
	height: 29px;
	margin-right: 15px;
	border: 1px solid var(--rsbx-dark);
	background: #fff;
}

.rsbx-type input:checked + .rsbx-type__box::after {
	content: '';
	position: absolute;
	left: 9px;
	top: 3px;
	width: 9px;
	height: 16px;
	border: solid var(--rsbx-dark);
	border-width: 0 3px 3px 0;
	transform: rotate(45deg);
}

.rsbx-type input:focus-visible + .rsbx-type__box {
	outline: 2px solid var(--rsbx-yellow);
	outline-offset: 2px;
}

.rsbx-type__label {
	font-size: 24px;
	line-height: 1.2;
}

.rsbx-types .rsbx-error {
	flex-basis: 100%;
}

/* Grilles */
.rsbx-grid {
	display: grid;
	grid-template-columns: minmax(0, 540fr) minmax(0, 306fr);
	gap: 19px 14px;
	margin-bottom: 19px;
	align-items: start;
}

.rsbx-grid--half {
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 19px 11px;
}

.rsbx-col-full {
	grid-column: 1 / -1;
}

/* Champs */
.rsbx-field {
	position: relative;
	min-width: 0;
}

.rsbx-precontrat .rsbx-field input[type='text'],
.rsbx-precontrat .rsbx-field input[type='email'],
.rsbx-precontrat .rsbx-field input[type='tel'],
.rsbx-precontrat .rsbx-field input[type='date'],
.rsbx-precontrat .rsbx-field select,
.rsbx-file__button {
	display: block;
	width: 100%;
	height: 47px;
	margin: 0;
	padding: 0 13px;
	border: 1px solid var(--rsbx-border);
	border-radius: 0;
	background: #fff;
	color: var(--rsbx-dark);
	font-family: inherit;
	font-size: 15px;
	line-height: 45px;
	box-shadow: none;
	-webkit-appearance: none;
	appearance: none;
}

.rsbx-precontrat .rsbx-field input::placeholder {
	color: var(--rsbx-text);
	opacity: 1;
}

.rsbx-precontrat .rsbx-field input:focus,
.rsbx-precontrat .rsbx-field select:focus,
.rsbx-file input:focus-visible + .rsbx-file__button,
.rsbx-file:focus-within .rsbx-file__button {
	outline: none;
	border-color: var(--rsbx-dark);
	box-shadow: 0 0 0 1px var(--rsbx-dark);
}

.rsbx-field.has-error input,
.rsbx-field.has-error select,
.rsbx-field.has-error .rsbx-file__button {
	border-color: var(--rsbx-red) !important;
}

.rsbx-error {
	display: block;
	margin-top: 4px;
	color: var(--rsbx-red);
	font-size: 13px;
	line-height: 1.3;
}

/* Liste déroulante */
.rsbx-precontrat .rsbx-select select {
	color: var(--rsbx-text);
	cursor: pointer;
}

.rsbx-precontrat .rsbx-select select:has(option:checked:not([value=''])) {
	color: var(--rsbx-dark);
}

/* Fichiers */
.rsbx-file input[type='file'] {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 47px;
	opacity: 0;
	cursor: pointer;
}

.rsbx-file__button {
	color: var(--rsbx-text);
	cursor: pointer;
}

.rsbx-file__name {
	align-self: center;
	height: 47px;
	padding-left: 14px;
	color: var(--rsbx-red);
	font-size: 15px;
	line-height: 47px;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.rsbx-file__name.has-file {
	color: var(--rsbx-text);
}

/* Textes */
.rsbx-precontrat .rsbx-section-title {
	margin: 0 0 18px;
	padding: 0 2px;
	color: var(--rsbx-dark);
	font-size: 17px;
	line-height: 1.4;
}

.rsbx-grid + .rsbx-section-title {
	margin-top: 30px;
}

.rsbx-precontrat .rsbx-step-title {
	margin: 0 0 50px;
	padding: 0 2px;
	font-size: 24px;
	line-height: 1.2;
	color: var(--rsbx-dark);
}

.rsbx-separator {
	height: 0;
	margin: 32px 0 25px;
	border: 0;
	border-top: 1px solid var(--rsbx-dark);
	background: none;
}

.rsbx-precontrat .rsbx-required-note {
	margin: 0;
	padding: 0;
	color: var(--rsbx-text);
	font-size: 15px;
}

/* Actions */
.rsbx-actions {
	display: flex;
	justify-content: space-between;
	align-items: flex-start;
	gap: 20px;
	margin-top: 55px;
}

.rsbx-actions--final {
	margin-top: 40px;
	margin-bottom: 26px;
}

.rsbx-consent {
	margin-top: 12px;
	max-width: 400px;
}

.rsbx-consent label {
	display: flex;
	gap: 5px;
	font-size: 11px;
	line-height: 1.35;
	color: var(--rsbx-text);
	cursor: pointer;
}

.rsbx-consent input {
	flex: none;
	width: 11px;
	height: 11px;
	margin: 2px 0 0;
}

.rsbx-consent a {
	color: inherit;
	text-decoration: underline;
}

.rsbx-precontrat .rsbx-button {
	flex: none;
	display: inline-block;
	min-width: 223px;
	margin: 0;
	padding: 0 30px;
	border: 1px solid transparent;
	border-radius: 0;
	font-family: inherit;
	text-transform: uppercase;
	cursor: pointer;
	transition: background-color 0.2s, color 0.2s;
}

.rsbx-precontrat .rsbx-button--primary {
	height: 75px;
	border-color: var(--rsbx-yellow);
	background: var(--rsbx-yellow);
	color: var(--rsbx-text);
	font-size: 24px;
	font-weight: 700;
	letter-spacing: 0.5px;
}

.rsbx-precontrat .rsbx-button--primary:hover,
.rsbx-precontrat .rsbx-button--primary:focus-visible {
	background: var(--rsbx-text);
	border-color: var(--rsbx-text);
	color: #fff;
}

.rsbx-precontrat .rsbx-button--outline {
	height: 77px;
	border-color: var(--rsbx-dark);
	background: #fff;
	color: var(--rsbx-text);
	font-size: 16px;
}

.rsbx-precontrat .rsbx-button--outline:hover,
.rsbx-precontrat .rsbx-button--outline:focus-visible {
	background: var(--rsbx-text);
	color: #fff;
}

.rsbx-precontrat .rsbx-button--block {
	display: block;
	width: calc(100% - 2px);
	margin-left: 2px;
}

.rsbx-precontrat .rsbx-button:disabled {
	opacity: 0.6;
	cursor: wait;
}

/* Messages */
.rsbx-message {
	margin-top: 20px;
	padding: 14px 18px;
	border-left: 4px solid var(--rsbx-red);
	background: #fdf0f1;
	color: var(--rsbx-red);
	font-size: 15px;
}

.rsbx-success {
	padding: 30px 32px;
	border-left: 6px solid var(--rsbx-yellow);
	background: #f5f6f7;
	color: var(--rsbx-dark);
	font-size: 20px;
	line-height: 1.5;
	outline: none;
}

/* Lignes de contact sous le formulaire */
.rsbx-contact-lines p {
	display: flex;
	align-items: center;
	gap: 9px;
	margin: 0 0 12px;
	padding: 0;
	font-size: 17px;
	line-height: 1.3;
	color: var(--rsbx-dark, #000);
}

.rsbx-contact-lines svg {
	flex: none;
	width: 29px;
	height: 29px;
}

.rsbx-contact-lines a {
	color: #0096d6;
}

@media (max-width: 767px) {
	.rsbx-types {
		margin-bottom: 36px;
	}

	.rsbx-type {
		width: 100%;
	}

	.rsbx-type__label,
	.rsbx-precontrat .rsbx-step-title {
		font-size: 20px;
	}

	.rsbx-grid,
	.rsbx-grid--half {
		grid-template-columns: minmax(0, 1fr);
		gap: 14px;
		margin-bottom: 14px;
	}

	.rsbx-file__name {
		height: auto;
		margin-top: -6px;
		padding-left: 2px;
		line-height: 1.4;
	}

	.rsbx-actions {
		flex-direction: column;
		align-items: stretch;
		margin-top: 36px;
	}

	.rsbx-actions--final {
		flex-direction: column-reverse;
	}

	.rsbx-precontrat .rsbx-button {
		width: 100%;
		height: 60px;
	}

	.rsbx-precontrat .rsbx-button--block {
		width: 100%;
		margin-left: 0;
	}

	.rsbx-contact-lines p {
		font-size: 15px;
	}
}

.rsbx-contact-lines a[href^="tel:"] {
	white-space: nowrap;
}
