/* Fiche produit — simulateur (maquette Bag X Pro) */

:root {
	--bagxpro-sim-gold: #eab933;
	--bagxpro-sim-gold-hover: #d9a82a;
	--bagxpro-sim-bg: #f2f2f2;
	--bagxpro-sim-text: #000;
	--bagxpro-sim-muted: #6b6b6b;
	--bagxpro-sim-line: #d0d0d0;
	/* Offset sous le header fixe — ajuster si besoin */
	--bagxpro-sticky-top: 100px;
}

.bagxpro-single-produit {
	padding: 220px 0 64px;
	background: var(--bagxpro-sim-bg);
	min-height: 60vh;
}

.bagxpro-single-produit__breadcrumb {
	margin-bottom: 1.5rem;
	margin-top: 0;
}

.bagxpro-single-produit__row {
	display: flex;
	flex-wrap: wrap;
	align-items: stretch;
	gap: 2rem 0;
}

/* Colonne gauche : même hauteur que le formulaire pour le sticky */
.bagxpro-preview-col {
	display: flex;
	flex-direction: column;
}

/* Colonne visuel (sticky desktop : reste visible tant qu’on fait défiler le formulaire) */
.bagxpro-preview-column {
	width: 100%;
	/*max-width: 640px;*/
	margin: 0 auto;
}

@media (min-width: 768px) {
	.bagxpro-preview-column {
		position: sticky;
		top: 20px;
		align-self: flex-start;
	}
}

.bagxpro-bag-preview-container {
	background: #fff;
	border-radius: 60px 0 0 0;
	overflow: hidden;
	box-shadow: 0 1px 0 rgba(0, 0, 0, 0.04);
}

.bagxpro-bag-preview {
	position: relative;
	display: block;
	width: 100%;
}

/* Empilement : toutes les images chargées dans le DOM, superposées (z-index) */
.bagxpro-bag-preview__stack {
	position: relative;
	display: block;
	width: 100%;
}

/* Référence de cadrage : occupe le flux, invisible mais garde le ratio */
.bagxpro-bag-preview__size-ref {
	display: block;
	width: 100%;
	height: auto;
	visibility: hidden;
	pointer-events: none;
}

.bagxpro-bag-layer {
	position: absolute;
	left: 0;
	top: 0;
	width: 100%;
	height: auto;
	display: block;
	object-fit: contain;
	object-position: center top;
	opacity: 0;
	pointer-events: none;
	transition: none;
	z-index: 1;
}

/* Image affichée au repos : pas de transition (l’ancien reste net jusqu’à la fin du fondu du nouveau) */
.bagxpro-bag-layer.is-visible {
	opacity: 1;
	z-index: 2;
}

/* Nouveau visuel au-dessus : part de transparent, seul ce calque est animé */
.bagxpro-bag-layer.is-fading-in {
	opacity: 0;
	z-index: 5;
	transition: opacity 0.45s ease;
	will-change: opacity;
}

.bagxpro-bag-layer.is-fading-in.is-fading-in--show {
	opacity: 1;
}

.bagxpro-bag-preview__accent-line {
	height: 4px;
	width: 100%;
	background: var(--bagxpro-sim-gold);
	margin: 0;
}

.bagxpro-bag-preview__legal {
	margin: 12px 0 0;
	font-size: 11px;
	letter-spacing: 0.02em;
	color: var(--bagxpro-sim-muted);
	text-align: left;
	line-height: 1.4;
}

/* Zone logo */
.bagxpro-logo-zone {
	position: relative;
	margin-bottom: 32px;
	min-height: 180px;
	border: 2px dashed var(--bagxpro-sim-gold);
	border-radius: 8px;
	background: rgba(255, 255, 255, 0.6);
	transition: background 0.2s, border-color 0.2s;
}

.bagxpro-logo-zone.is-dragover {
	background: rgba(234, 185, 51, 0.12);
	border-color: var(--bagxpro-sim-gold-hover);
}

.bagxpro-logo-zone.has-logo {
	border-style: solid;
	border-color: rgba(234, 185, 51, 0.65);
	background: rgba(255, 255, 255, 0.85);
}

.bagxpro-logo-zone__input {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	opacity: 0;
	cursor: pointer;
	z-index: 2;
	font-size: 0;
}

.bagxpro-logo-zone__visual {
	position: relative;
	z-index: 1;
	pointer-events: none;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	padding: 28px 20px 32px;
	min-height: 180px;
	text-align: center;
}

.bagxpro-logo-zone__title {
	margin: 0 0 8px;
	font-size: 15px;
	font-weight: 700;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	color: var(--bagxpro-sim-text);
}

.bagxpro-logo-zone__hint {
	margin: 0 0 20px;
	font-size: 14px;
	color: var(--bagxpro-sim-muted);
}

.bagxpro-logo-zone__cta {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 10px;
	padding: 12px 28px;
	border-radius: 4px;
	background: var(--bagxpro-sim-gold);
	color: #fff;
	font-size: 13px;
	font-weight: 600;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	box-shadow: 0 2px 8px rgba(234, 185, 51, 0.35);
}

.bagxpro-logo-zone__cta-icon {
	flex-shrink: 0;
	color: #fff;
}

.bagxpro-logo-clear {
	display: inline-block;
	margin: -16px 0 24px;
	padding: 0;
	border: 0;
	background: none;
	color: var(--bagxpro-sim-muted);
	font-size: 14px;
	text-decoration: underline;
	cursor: pointer;
}

.bagxpro-logo-clear:hover {
	color: var(--bagxpro-sim-text);
}

.bagxpro-logo-clear[hidden] {
	display: none;
}

/* Zone logo superposée au clic : file input reste au-dessus */

/* Panneau droit */
.bagxpro-produit-panel {
	padding-top: 8px;
	max-width: 100%;
	margin-left: 0;
	padding-bottom: 60px;
	margin-right: auto;
}

.bagxpro-notice {
	margin: 0 0 1.25rem;
	padding: 14px 16px;
	border-radius: 8px;
	font-size: 14px;
	line-height: 1.45;
}

.bagxpro-notice--success {
	background: rgba(22, 163, 74, 0.12);
	border: 1px solid rgba(22, 163, 74, 0.45);
	color: #166534;
}

.bagxpro-notice--error {
	background: rgba(220, 38, 38, 0.1);
	border: 1px solid rgba(220, 38, 38, 0.35);
	color: #991b1b;
}

.bagxpro-produit-panel__header {
	margin-bottom: 28px;
}

.bagxpro-produit-panel__title {
	margin: 0 0 10px;
	font-size: clamp(1.75rem, 3.5vw, 2.25rem);
	font-weight: 700;
	line-height: 1.15;
	color: var(--bagxpro-sim-text);
}

.bagxpro-produit-panel__specs {
	margin: 0;
	font-size: 14px;
	font-weight: 500;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	color: var(--bagxpro-sim-muted);
	line-height: 1.4;
}

/* Pastilles sangles */
.bagxpro-field {
	margin-bottom: 12px;
}

.bagxpro-field--straps .bagxpro-field__label {
	display: block;
	margin-bottom: 14px;
	font-weight: 600;
	font-size: 15px;
	color: var(--bagxpro-sim-text);
}

.bagxpro-swatches {
	display: flex;
	flex-wrap: wrap;
	gap: 14px;
	align-items: center;
}

.bagxpro-swatch {
	width: 40px;
	height: 40px;
	padding: 0;
	border: 2px solid transparent;
	border-radius: 50%;
	cursor: pointer;
	box-sizing: border-box;
	transition: box-shadow 0.2s, transform 0.15s;
}

.bagxpro-swatch:hover {
	transform: scale(1.05);
}

.bagxpro-swatch.is-selected {
	border-color: #9ca3af;
	box-shadow: 0 0 0 1px #fff inset;
}

.bagxpro-swatch--black {
	background: #1a1a1a;
}

.bagxpro-swatch--blue {
	background: #2563eb;
}

.bagxpro-swatch--red {
	background: #dc2626;
}

.bagxpro-swatch--green {
	background: #16a34a;
}

/* Select quantité */
.bagxpro-field--quantity .bagxpro-field__label {
	display: block;
	margin-bottom: 10px;
	font-weight: 600;
	font-size: 15px;
	color: var(--bagxpro-sim-text);
}

.bagxpro-select-wrap {
	position: relative;
}

.bagxpro-select-wrap::after {
	content: "";
	position: absolute;
	right: 16px;
	top: 50%;
	width: 0;
	height: 0;
	margin-top: -3px;
	border-left: 5px solid transparent;
	border-right: 5px solid transparent;
	border-top: 6px solid #1a1a1a;
	pointer-events: none;
}

.bagxpro-select {
	appearance: none;
	width: 100%;
	padding: 14px 44px 14px 16px;
	font-family: inherit;
	font-size: 15px;
	line-height: 1.35;
	color: var(--bagxpro-sim-text);
	background: #fff;
	border: 1px solid var(--bagxpro-sim-line);
	border-radius: 6px;
	cursor: pointer;
	transition: border-color 0.2s, box-shadow 0.2s;
}

.bagxpro-select:focus {
	outline: none;
	border-color: var(--bagxpro-sim-gold);
	box-shadow: 0 0 0 3px rgba(234, 185, 51, 0.25);
}

/* Contact (nom, prénom, e-mail, téléphone) */
.bagxpro-produit-panel__contact {
	margin-top: 8px;
	margin-bottom: 24px;
}

.bagxpro-produit-panel__contact .bagxpro-field {
	margin-bottom: 20px;
}

.bagxpro-produit-panel__contact .bagxpro-field:last-child {
	margin-bottom: 0;
}

.bagxpro-produit-panel__contact .bagxpro-field__label {
	display: block;
	margin-bottom: 10px;
	font-weight: 600;
	font-size: 15px;
	color: var(--bagxpro-sim-text);
}

/* Information RGPD + consentement */
.bagxpro-rgpd {
	margin-top: 8px;
	margin-bottom: 24px;
	padding: 16px 18px;
	background: rgba(0, 0, 0, 0.03);
	border: 1px solid var(--bagxpro-sim-line);
	border-radius: 8px;
}

.bagxpro-rgpd__text {
	margin: 0 0 12px;
	font-size: 13px;
	line-height: 1.55;
	color: var(--bagxpro-sim-muted, #666);
}

.bagxpro-rgpd__privacy {
	margin: 0 0 14px;
	font-size: 13px;
}

.bagxpro-rgpd__privacy-link {
	color: var(--bagxpro-sim-gold, #c9a227);
	text-decoration: underline;
	text-underline-offset: 2px;
}

.bagxpro-rgpd__privacy-link:hover {
	opacity: 0.9;
}

.bagxpro-rgpd__consent {
	display: flex;
	align-items: flex-start;
	gap: 10px;
	margin: 0;
	cursor: pointer;
	font-size: 14px;
	line-height: 1.45;
	color: var(--bagxpro-sim-text);
}

.bagxpro-rgpd__checkbox {
	flex-shrink: 0;
	width: 18px;
	height: 18px;
	margin-top: 2px;
	accent-color: var(--bagxpro-sim-gold, #c9a227);
}

.bagxpro-rgpd__consent-text {
	flex: 1;
}

.bagxpro-input {
	display: block;
	box-sizing: border-box;
	width: 100%;
	padding: 14px 16px;
	font-family: inherit;
	font-size: 15px;
	line-height: 1.35;
	color: var(--bagxpro-sim-text);
	background: #fff;
	border: 1px solid var(--bagxpro-sim-line);
	border-radius: 6px;
	transition: border-color 0.2s, box-shadow 0.2s;
}

.bagxpro-input::placeholder {
	color: #9ca3af;
}

.bagxpro-input:focus {
	outline: none;
	border-color: var(--bagxpro-sim-gold);
	box-shadow: 0 0 0 3px rgba(234, 185, 51, 0.25);
}

/* Prix dans les options : accent partiel impossible en natif — chaîne unique */

.bagxpro-btn-order {
	display: block;
	width: 100%;
	margin-top: 0;
	margin-bottom: 0;
	padding: 18px 24px;
	border: none;
	border-radius: 6px;
	background: var(--bagxpro-sim-gold);
	color: #fff;
	font-family: inherit;
	font-size: 15px;
	font-weight: 700;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	cursor: pointer;
	box-shadow: 0 4px 14px rgba(234, 185, 51, 0.4);
	transition: background 0.2s, transform 0.15s;
}

.bagxpro-btn-order:hover {
	background: var(--bagxpro-sim-gold-hover);
}

.bagxpro-btn-order:active {
	transform: translateY(1px);
}

/* Logo sur le sac (au-dessus des calques) */
.bagxpro-bag-preview__logo {
	position: absolute;
	left: 50%;
	top: 50%;
	transform: translate(-50%, -50%) perspective(420px) rotateX(4deg);
	width: 30%;
	height: 42%;
	pointer-events: none;
	display: flex;
	align-items: center;
	justify-content: center;
	box-sizing: border-box;
	padding: 4%;
	z-index: 5;
}

.bagxpro-bag-preview__logo[hidden] {
	display: none !important;
}

.bagxpro-bag-preview__logo img {
	max-width: 100%;
	max-height: 100%;
	width: auto;
	height: auto;
	object-fit: contain;
	mix-blend-mode: multiply;
	opacity: 0.78;
	filter: contrast(0.88) brightness(1.14) saturate(0.92);
}

.bagxpro-produit-panel__content {
	margin-top: 40px;
	padding-top: 32px;
	border-top: 1px solid var(--bagxpro-sim-line);
	font-size: 15px;
	line-height: 1.6;
}

.description-produit {
	list-style: none;
	padding: 0;
	margin: 0;
}

.description-produit li {
	margin-bottom: 0px;
	font-size: 15px;
	line-height: 1.6;
	color: var(--bagxpro-sim-text);

	&:before{
		content: '• ';
	}
}

.bagxpro-visually-hidden {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

@media (max-width: 767px) {
	.bagxpro-single-produit {
		padding: 120px 0 48px;
	}

	.bagxpro-preview-column {
		position: static;
	}

	.bagxpro-produit-panel {
		max-width: none;
	}
}
