/**
 * bar-sidecart-lead-capture — CSS V1
 * Scoping : .bar-sclc (injecté avant le bouton « Commander » du side cart FunnelKit)
 */

.bar-sclc {
	box-sizing: border-box;
	margin: 12px 12px;
	padding: 12px 14px;
	border: 1px solid rgba(0, 0, 0, 0.08);
	border-radius: 10px;
	background: #f5f0e3;
	font-size: 14px;
	line-height: 1.4;
}

.bar-sclc *,
.bar-sclc *::before,
.bar-sclc *::after {
	box-sizing: border-box;
}

.bar-sclc-panel-toggle {
	all: unset;
	box-sizing: border-box;
	display: flex;
	align-items: center;
	justify-content: space-between;
	width: 100%;
	padding: 10px 12px;
	border-radius: 8px;
	background: #eee6d4;
	cursor: pointer;
	transition: background-color 180ms ease, transform 180ms ease;
}

.bar-sclc[data-panel-open="1"] .bar-sclc-panel-toggle {
	margin-bottom: 8px;
}

.bar-sclc-panel-toggle:active {
	opacity: 0.75;
}

.bar-sclc-panel-toggle__title {
	color: #222;
	font-size: 16px;
	font-weight: 700;
	line-height: 1.2;
}

.bar-sclc-panel-toggle__chevron::before {
	content: "▾";
	color: #555;
	font-size: 22px;
	line-height: 1;
	display: inline-block;
	transform: rotate(0deg);
	transition: transform 180ms ease;
}

.bar-sclc[data-panel-open="0"] .bar-sclc-panel-toggle__chevron::before {
	transform: rotate(-90deg);
}

.bar-sclc__summary {
	margin: 6px 0 2px;
	padding: 0 12px;
	font-size: 12px;
}

.bar-sclc [data-panel-content],
.bar-sclc .bar-sclc__phone-wrap {
	overflow: hidden;
}

.bar-sclc__row {
	margin-bottom: 8px;
}

.bar-sclc__label {
	display: block;
	margin-bottom: 4px;
	font-size: 12px;
	color: #555;
}

.bar-sclc__field {
	position: relative;
	display: flex;
	flex-direction: column;
	gap: 4px;
}

.bar-sclc__input {
	width: 100%;
	min-height: 40px;
	padding: 8px 12px;
	font-size: 14px;
	line-height: 1.2;
	border: 1px solid #d0d5dd;
	border-radius: 8px;
	background: #fff;
	color: #111;
	transition: border-color 0.15s ease;
}

.bar-sclc__input:focus {
	outline: none;
	border-color: #111;
}

.bar-sclc__input[data-pending-validation="1"] {
	border-color: #e49b0f;
	background: #fff8ec;
}

.bar-sclc__input[aria-invalid="true"] {
	border-color: #c0392b;
	background: #fff1f0;
}

.bar-sclc__feedback {
	min-height: 16px;
	font-size: 12px;
	color: #666;
}

.bar-sclc__feedback-saved {
	color: #1f8a3b;
}

.bar-sclc__feedback-pending {
	color: #a86b00;
	display: none;
}

.bar-sclc__feedback-saving {
	color: #555;
}

.bar-sclc__feedback-error {
	color: #c0392b;
	cursor: pointer;
	text-decoration: underline;
}

.bar-sclc__toggle-phone {
	display: inline-block;
	margin: 6px 0 4px;
	padding: 0;
	background: none;
	border: 0;
	color: #555;
	font-size: 12px;
	cursor: pointer;
	text-decoration: underline;
}

.bar-sclc__toggle-phone:hover,
.bar-sclc__toggle-phone:active,
.bar-sclc__toggle-phone:focus,
.bar-sclc__toggle-phone:focus-visible,
.bar-sclc__toggle-phone[aria-expanded="true"] {
	color: #555;
	background: none;
	background-color: transparent;
	box-shadow: none;
}

.bar-sclc__phone-wrap[hidden] {
	display: none;
}

.bar-sclc__consent {
	display: flex;
	align-items: center;
	gap: 8px;
	margin-top: 6px;
	font-size: 12px;
	color: #444;
	cursor: pointer;
}

.bar-sclc__checkbox {
	width: 16px;
	height: 16px;
	margin: 0;
	cursor: pointer;
	accent-color: #e30f73;
}

.bar-sclc__checkbox:disabled {
	cursor: not-allowed;
	opacity: 0.5;
}

@media (max-width: 480px) {
	.bar-sclc {
		margin: 8px 10px;
		padding: 8px 10px;
		font-size: 13px;
		line-height: 1.3;
	}

	.bar-sclc__row {
		margin-bottom: 6px;
	}

	.bar-sclc__label {
		margin-bottom: 3px;
	}

	.bar-sclc-panel-toggle {
		padding: 8px 10px;
	}

	.bar-sclc-panel-toggle__title {
		font-size: 15px;
	}

	.bar-sclc-panel-toggle__chevron::before {
		font-size: 20px;
	}

	.bar-sclc__input {
		min-height: 38px;
		padding: 7px 10px;
	}

	.bar-sclc__feedback {
		min-height: 14px;
	}

	.bar-sclc__consent {
		margin-top: 4px;
		gap: 6px;
	}
}
