:root {
	--bg: #f4f7fb;
	--surface: #ffffff;
	--surface-soft: #f8fafc;
	--text: #0f172a;
	--muted: #4b5563;
	--line: #dbe3ef;
	--brand: #0ea5a4;
	--brand-deep: #0b6f7a;
	--shadow: 0 16px 44px rgba(15, 23, 42, 0.12);
	--radius-lg: 22px;
	--radius-md: 14px;
}

* {
	box-sizing: border-box;
}

[hidden] {
	display: none !important;
}

html,
body {
	margin: 0;
	padding: 0;
	min-height: 100%;
}

body {
	font-family: "Manrope", sans-serif;
	color: var(--text);
	background:
		radial-gradient(60rem 30rem at 5% -5%, rgba(14, 165, 164, 0.18), transparent 55%),
		radial-gradient(50rem 26rem at 95% 0%, rgba(245, 158, 11, 0.16), transparent 52%),
		linear-gradient(180deg, #f8fbff 0%, var(--bg) 48%, #ecf2f8 100%);
	overflow-x: hidden;
}

.bg-shape {
	position: fixed;
	pointer-events: none;
	border-radius: 999px;
	filter: blur(8px);
	opacity: 0.55;
	z-index: 0;
}

.bg-shape-one {
	width: 260px;
	height: 260px;
	background: #b9f3f1;
	top: 15%;
	left: -110px;
}

.bg-shape-two {
	width: 300px;
	height: 300px;
	background: #fde2a8;
	right: -100px;
	top: 58%;
}

.checkout-shell,
.success-shell {
	position: relative;
	z-index: 1;
	max-width: 980px;
	margin: 0 auto;
	padding: 36px 18px 72px;
}

.checkout-shell {
	display: grid;
	gap: 22px;
}

.intro-card,
.panel,
.success-card {
	background: var(--surface);
	border: 1px solid rgba(219, 227, 239, 0.95);
	border-radius: var(--radius-lg);
	box-shadow: var(--shadow);
}

.intro-card {
	text-align: center;
	padding: 32px 24px;
}

.brand-logo {
	width: 130px;
	max-width: 45vw;
	height: auto;
	margin-bottom: 10px;
}

.eyebrow {
	margin: 0;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	font-size: 0.75rem;
	color: var(--brand-deep);
	font-weight: 700;
}

h1,
h2,
h3 {
	margin: 0;
	font-family: "Sora", sans-serif;
}

h1 {
	margin-top: 10px;
	font-size: clamp(1.8rem, 3.7vw, 2.7rem);
	line-height: 1.15;
}

.subtitle {
	margin: 10px auto 0;
	color: var(--muted);
	max-width: 620px;
}

.offer-pill {
	margin: 20px auto 0;
	display: inline-block;
	background: linear-gradient(90deg, #daf5f4, #fff2d6);
	border: 1px solid #d5e6e5;
	color: #0f3b47;
	border-radius: 999px;
	padding: 10px 16px;
	font-weight: 700;
	font-size: 0.95rem;
}

.panel {
	padding: 24px;
}

.panel h2 {
	font-size: clamp(1.15rem, 2vw, 1.45rem);
	margin-bottom: 16px;
}

.form-grid {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 14px;
}

.label-full {
	grid-column: 1 / -1;
}

label {
	display: grid;
	gap: 6px;
	font-weight: 600;
	color: #23303f;
	font-size: 0.94rem;
}

.field-help {
	margin-top: 2px;
	font-size: 0.82rem;
	font-weight: 500;
	color: #5b6d82;
}

.field-error {
	min-height: 1.1em;
	font-size: 0.83rem;
	font-weight: 700;
	color: #b91c1c;
}

input,
textarea {
	width: 100%;
	border-radius: var(--radius-md);
	border: 1px solid var(--line);
	padding: 12px 13px;
	font-size: 0.95rem;
	font-family: inherit;
	background: var(--surface-soft);
	transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

input:focus,
textarea:focus {
	outline: none;
	border-color: var(--brand);
	box-shadow: 0 0 0 3px rgba(14, 165, 164, 0.2);
}

.siret-field input.is-invalid {
	border-color: #dc2626;
	box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.15);
}

.contract-box {
	background: #f9fbfe;
	border: 1px solid var(--line);
	border-radius: var(--radius-md);
	padding: 14px;
	max-height: 280px;
	overflow: auto;
	line-height: 1.5;
}

.contract-box h3 {
	margin-bottom: 10px;
	font-size: 1rem;
}

.contract-box ul {
	margin: 10px 0;
	padding-left: 20px;
}

.consent-row {
	margin-top: 14px;
	display: flex;
	align-items: flex-start;
	gap: 10px;
	font-weight: 600;
}

.consent-row input {
	width: 18px;
	height: 18px;
	margin-top: 1px;
}

.signature-visual {
	min-height: 74px;
	border-radius: var(--radius-md);
	border: 2px dashed #9fb5cd;
	background: #f9fbfe;
	display: flex;
	align-items: center;
	justify-content: center;
	text-align: center;
	padding: 12px;
	color: #5b6d82;
	font-size: 1.1rem;
}

.signature-visual.signed {
	font-family: "Caveat", cursive;
	font-size: clamp(2rem, 5vw, 2.8rem);
	color: #0f293f;
	letter-spacing: 0.02em;
	border-style: solid;
	border-color: #95b2cf;
}

.signature-help {
	margin: 10px 0 8px;
	color: var(--muted);
}

.slider-label {
	margin-bottom: 8px;
}

#signatureSlider {
	-webkit-appearance: none;
	appearance: none;
	width: 100%;
	height: 14px;
	border-radius: 999px;
	border: 1px solid #d5dfec;
	background: linear-gradient(90deg, #daf5f4, #fff2d6);
	padding: 0;
}

#signatureSlider::-webkit-slider-thumb {
	-webkit-appearance: none;
	appearance: none;
	width: 34px;
	height: 34px;
	border-radius: 50%;
	border: 2px solid #ffffff;
	background: linear-gradient(145deg, #0ea5a4, #0b6f7a);
	box-shadow: 0 8px 16px rgba(15, 23, 42, 0.22);
	cursor: grab;
}

#signatureSlider::-moz-range-thumb {
	width: 34px;
	height: 34px;
	border-radius: 50%;
	border: 2px solid #ffffff;
	background: linear-gradient(145deg, #0ea5a4, #0b6f7a);
	box-shadow: 0 8px 16px rgba(15, 23, 42, 0.22);
	cursor: grab;
}

.signature-status {
	margin: 10px 0 0;
	font-weight: 700;
	color: #9f3a24;
}

.signature-status.valid {
	color: #0f7a57;
}

.signature-timestamp {
	margin: 6px 0 0;
	color: var(--muted);
}

.payment-panel {
	text-align: center;
}

.btn-pay {
	width: min(460px, 100%);
	border: none;
	border-radius: 999px;
	padding: 14px 20px;
	color: #ffffff;
	background: linear-gradient(90deg, #0f172a, #1f2937);
	font-size: 1rem;
	font-weight: 700;
	cursor: pointer;
	transition: transform 0.16s ease, box-shadow 0.2s ease, opacity 0.2s ease;
}

.btn-pay:hover:not(:disabled) {
	transform: translateY(-1px);
	box-shadow: 0 12px 24px rgba(31, 41, 55, 0.26);
}

.btn-pay:disabled {
	opacity: 0.48;
	cursor: not-allowed;
}

.reassurance,
.automation-note {
	margin: 12px 0 0;
	color: var(--muted);
}

.reassurance {
	font-weight: 700;
	color: #124f68;
}

.success-shell {
	display: grid;
	place-items: center;
	min-height: calc(100vh - 120px);
}

.success-card {
	width: min(680px, 100%);
	text-align: center;
	padding: 34px 22px;
	animation: fadeUp 0.6s ease;
}

.success-card p {
	margin: 14px 0 0;
	color: var(--muted);
	line-height: 1.55;
}

.badge {
	display: inline-block;
	margin-top: 20px;
	background: #dff7f3;
	color: #0f7a57;
	border: 1px solid #c5ece3;
	border-radius: 999px;
	padding: 9px 14px;
	font-weight: 800;
	letter-spacing: 0.01em;
}

.reveal {
	opacity: 0;
	transform: translateY(16px);
	animation: riseIn 0.65s ease forwards;
}

.reveal:nth-child(2) {
	animation-delay: 0.06s;
}

.reveal:nth-child(3) {
	animation-delay: 0.12s;
}

.reveal:nth-child(4) {
	animation-delay: 0.18s;
}

.reveal:nth-child(5) {
	animation-delay: 0.24s;
}

@keyframes riseIn {
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

@keyframes fadeUp {
	from {
		opacity: 0;
		transform: translateY(10px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}
