/* LTDC Attaches médaillon : panneau d'option sur fiche produit */

.ltdc-att {
	font-family: 'Quicksand', var(--font-sans, sans-serif);
	color: var(--color-text, #1c1512);
	--ltdc-att-color: #E8DBB7;
}
.ltdc-att__toggle { display: none; }

/* Panneau */
.ltdc-att__panel[hidden] { display: none; }
.ltdc-att__block[hidden] { display: none; }

.ltdc-att__intro,
.ltdc-att__reco {
	margin: 0 0 14px;
	font-size: .84rem;
	line-height: 1.5;
}
.ltdc-att__intro { color: var(--color-text-muted, #7a5c4a); }
.ltdc-att__reco {
	padding: 10px 12px;
	background: var(--color-bg, #fcf6ee);
	border-radius: 6px;
}

.ltdc-att__block { margin-bottom: 16px; }
.ltdc-att__block-head {
	display: flex;
	justify-content: space-between;
	align-items: baseline;
	gap: 10px;
	margin-bottom: 8px;
}
.ltdc-att__label {
	font-weight: 700;
	font-size: .78rem;
	text-transform: uppercase;
	letter-spacing: .06em;
}
.ltdc-att__remaining,
.ltdc-att__color-name {
	font-size: .78rem;
	font-weight: 600;
	color: var(--color-text-muted, #7a5c4a);
	text-align: right;
	transition: transform .2s;
}
.ltdc-att__remaining.is-done,
.ltdc-att__color-name.is-done { color: #16a34a; }
.ltdc-att__remaining.is-pulse { transform: scale(1.08); color: #c53030; }

/* Pose (tresse) : boutons segmentés dans le style des pastilles de taille */
.ltdc-att__seg { display: flex; flex-wrap: wrap; gap: 6px; }
.ltdc-att__seg-btn {
	display: inline-flex;
	align-items: center;
	padding: .5em .9em;
	font-family: inherit;
	font-size: .8rem;
	font-weight: 500;
	border: 1.5px solid var(--color-border, rgba(28, 21, 18, .1));
	border-radius: var(--radius-full, 999px);
	background: #fff;
	color: var(--color-text, #1c1512);
	cursor: pointer;
	transition: all .25s;
	white-space: nowrap;
}
.ltdc-att__seg-btn:hover { border-color: var(--color-text, #1c1512); background: var(--color-bg-3, #f0dcc7); }
.ltdc-att__seg-btn.is-active {
	background: var(--color-text, #1c1512);
	color: var(--color-bg, #fcf6ee);
	border-color: var(--color-text, #1c1512);
}

/* Sélecteurs lit / pose (tresse) */
.ltdc-att__selects { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.ltdc-att__select {
	width: 100%;
	padding: 9px 34px 9px 12px;
	border: 1.5px solid var(--color-border, rgba(28, 21, 18, .1));
	border-radius: 8px;
	background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231c1512' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E") no-repeat right 10px center / 14px;
	font-family: inherit;
	font-size: .85rem;
	font-weight: 600;
	color: var(--color-text, #1c1512);
	appearance: none;
	-webkit-appearance: none;
	cursor: pointer;
}
.ltdc-att__select:focus { outline: none; border-color: var(--color-text, #1c1512); }
.ltdc-att__select[hidden] { display: none; }
@media (max-width: 480px) { .ltdc-att__selects { grid-template-columns: 1fr; } }

/* Mention brevet en tête du panneau */
.ltdc-att__patent {
	display: flex;
	align-items: center;
	gap: 10px;
	margin: 0 0 14px;
	padding: 10px 12px;
	border: 1px solid var(--color-border, rgba(28, 21, 18, .1));
	border-radius: 8px;
	background: var(--color-bg, #fcf6ee);
	font-size: .8rem;
	line-height: 1.4;
	color: var(--color-text-muted, #7a5c4a);
}
.ltdc-att__patent svg { flex-shrink: 0; width: 22px; height: 22px; color: var(--color-warm, #b87a4b); }
.ltdc-att__patent strong { color: var(--color-text, #1c1512); }

/* Fiche kit : longueur saisie */
.ltdc-att__length { display: flex; align-items: center; gap: 8px; }
.ltdc-att__length-input {
	width: 130px;
	padding: 9px 12px;
	border: 1.5px solid var(--color-border, rgba(28, 21, 18, .1));
	border-radius: 8px;
	font-family: inherit;
	font-size: .95rem;
	font-weight: 600;
}
.ltdc-att__length-input:focus { outline: none; border-color: var(--color-text, #1c1512); }
.ltdc-att__length-unit { font-weight: 600; color: var(--color-text-muted, #7a5c4a); }
.ltdc-att--standalone .ltdc-att__panel { margin-top: 0; }
.ltdc-att__from { font-size: .9rem; font-weight: 500; color: var(--color-text-muted, #7a5c4a); }

/* Compteurs (tresse) */
.ltdc-att__counters { margin-bottom: 16px; }
.ltdc-att__counter {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	padding: 8px 0;
	border-bottom: 1px dashed var(--color-border, rgba(28, 21, 18, .1));
}
.ltdc-att__counter:last-child { border-bottom: 0; }
.ltdc-att__counter-img {
	flex-shrink: 0;
	width: 52px;
	height: 52px;
	border-radius: 9px;
	object-fit: cover;
	border: 1.5px solid var(--color-border, rgba(28, 21, 18, .1));
}
.ltdc-att__counter-label { flex: 1; min-width: 0; font-size: .88rem; font-weight: 600; line-height: 1.3; }
.ltdc-att__counter-label em {
	display: block;
	margin-top: 2px;
	font-style: normal;
	font-size: .74rem;
	font-weight: 500;
	color: var(--color-text-muted, #7a5c4a);
}
.ltdc-att__stepper {
	display: inline-flex;
	align-items: center;
	flex-shrink: 0;
	border: 1.5px solid var(--color-border, rgba(28, 21, 18, .1));
	border-radius: var(--radius-full, 999px);
	overflow: hidden;
	background: #fff;
}
.ltdc-att__stepper button {
	width: 34px;
	height: 34px;
	border: 0;
	background: transparent;
	font-size: 1.15rem;
	line-height: 1;
	color: var(--color-text, #1c1512);
	cursor: pointer;
	transition: background .2s;
}
.ltdc-att__stepper button:hover { background: var(--color-bg-3, #f0dcc7); }
.ltdc-att__stepper button:disabled { opacity: .3; cursor: not-allowed; background: transparent; }
.ltdc-att__stepper output {
	min-width: 30px;
	text-align: center;
	font-weight: 700;
	font-size: .95rem;
}

.ltdc-att__split { display: block; margin-top: 2px; font-size: .76rem; font-weight: 700; color: var(--color-text, #1c1512); }

/* Formes */
.ltdc-att__shapes {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 10px;
	padding-top: 6px;
}
.ltdc-att__shape {
	position: relative;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 6px;
	padding: 6px 6px 8px;
	border: 1.5px solid var(--color-border, rgba(28, 21, 18, .1));
	border-radius: 10px;
	background: #fff;
	font-family: inherit;
	cursor: pointer;
	transition: border-color .2s, background .2s, transform .2s;
}
.ltdc-att__shape:hover { border-color: var(--color-text, #1c1512); background: var(--color-bg, #fcf6ee); }
.ltdc-att__shape.is-selected {
	border-color: var(--color-warm, #b87a4b);
	background: var(--color-bg-2, #fde8df);
}
.ltdc-att__shape.is-full:not(.is-selected) { opacity: .55; }
.ltdc-att__shape-img {
	display: block;
	width: 100%;
	height: auto;
	aspect-ratio: 1 / 1;
	object-fit: cover;
	border-radius: 7px;
}

/* Aperçu photo (ciel) */
.ltdc-att__preview {
	margin: 0 0 14px;
	padding: 0;
}
.ltdc-att__preview img {
	display: block;
	width: 100%;
	height: auto;
	aspect-ratio: 4 / 3;
	object-fit: cover;
	border-radius: 10px;
}
.ltdc-att__preview figcaption {
	margin-top: 6px;
	font-size: .74rem;
	line-height: 1.4;
	color: var(--color-text-muted, #7a5c4a);
}
.ltdc-att__shape-name {
	font-size: .72rem;
	font-weight: 600;
	color: var(--color-text, #1c1512);
}
.ltdc-att__shape-count,
.ltdc-att__shape-minus {
	position: absolute;
	top: -8px;
	display: none;
	align-items: center;
	justify-content: center;
	height: 22px;
	min-width: 22px;
	border-radius: 11px;
	font-size: .74rem;
	font-weight: 700;
	line-height: 1;
}
.ltdc-att__shape-count {
	right: -8px;
	padding: 0 6px;
	background: var(--color-text, #1c1512);
	color: #fff;
}
.ltdc-att__shape-minus {
	left: -8px;
	width: 22px;
	background: #fff;
	border: 1.5px solid var(--color-border, rgba(28, 21, 18, .1));
	color: var(--color-text, #1c1512);
	cursor: pointer;
}
.ltdc-att__shape-minus:hover { border-color: var(--color-text, #1c1512); }
.ltdc-att--multi .ltdc-att__shape.is-selected .ltdc-att__shape-count,
.ltdc-att--multi .ltdc-att__shape.is-selected .ltdc-att__shape-minus { display: inline-flex; }

/* Couleurs */
.ltdc-att__colors { display: flex; flex-wrap: wrap; gap: 8px 6px; }
.ltdc-att__swatch {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 5px;
	width: 62px;
	padding: 4px 0;
	border: 0;
	background: none;
	font-family: inherit;
	cursor: pointer;
}
.ltdc-att__swatch-dot {
	width: 32px;
	height: 32px;
	border-radius: 50%;
	border: 2px solid #fff;
	box-shadow: 0 0 0 1.5px var(--color-border, rgba(28, 21, 18, .15));
	transition: box-shadow .2s, transform .2s;
}
.ltdc-att__swatch:hover .ltdc-att__swatch-dot { transform: scale(1.08); }
.ltdc-att__swatch.is-selected .ltdc-att__swatch-dot { box-shadow: 0 0 0 2px var(--color-text, #1c1512); }
.ltdc-att__swatch-name {
	font-size: .66rem;
	font-weight: 600;
	line-height: 1.2;
	text-align: center;
	color: var(--color-text-muted, #7a5c4a);
}
.ltdc-att__swatch.is-selected .ltdc-att__swatch-name { color: var(--color-text, #1c1512); }

/* Total */
.ltdc-att__total {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-top: 4px;
	padding-top: 12px;
	border-top: 1px solid var(--color-border, rgba(28, 21, 18, .1));
	font-size: .9rem;
	font-weight: 600;
}
.ltdc-att__total-amount {
	font-size: 1.05rem;
	font-weight: 700;
	color: var(--color-warm, #b87a4b);
}
.ltdc-att__total-qty {
	display: block;
	font-size: .72rem;
	font-weight: 500;
	color: var(--color-text-muted, #7a5c4a);
}

/* Explication repliée */
.ltdc-att__more {
	margin: 12px 0 0;
	font-size: .78rem;
	line-height: 1.5;
	color: var(--color-text-muted, #7a5c4a);
}
.ltdc-att__more summary {
	cursor: pointer;
	font-weight: 600;
	color: var(--color-warm, #b87a4b);
	list-style: none;
}
.ltdc-att__more summary::-webkit-details-marker { display: none; }
.ltdc-att__more summary::before { content: '+ '; }
.ltdc-att__more[open] summary::before { content: '− '; }
.ltdc-att__more p { margin: 8px 0 0; }

/* Message d'erreur (même style que le plugin d'options, au cas où il n'est pas chargé) */
.ltdc-opts-error {
	display: none;
	align-items: flex-start;
	gap: 8px;
	margin-top: 10px;
	padding: 10px 14px;
	background: #fff3f3;
	border: 1.5px solid #e53e3e;
	border-radius: 6px;
	font-family: 'Quicksand', var(--font-sans, sans-serif);
	font-size: .85rem;
	font-weight: 500;
	color: #c53030;
	line-height: 1.45;
	text-transform: none;
	letter-spacing: 0;
}
.ltdc-opts-error.is-visible { display: flex; }
.ltdc-opts-error__icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
	width: 18px;
	height: 18px;
	margin-top: 1px;
	background: #e53e3e;
	color: #fff;
	border-radius: 50%;
	font-size: .7rem;
	font-weight: 800;
	line-height: 1;
}

@media (max-width: 480px) {
	.ltdc-att__shapes { gap: 8px; }
	.ltdc-att__shape { padding: 4px 4px 6px; }
	.ltdc-att__swatch { width: 52px; }
	.ltdc-att__counter-img { width: 44px; height: 44px; }
	.ltdc-att__counter { gap: 8px; }
	.ltdc-att__swatch-dot { width: 28px; height: 28px; }
}
