/* Template "bde" — fiche produit. RESKIN du squelette standard : les ids et
   classes fonctionnels (pd-*, .color, .pl-row, .size-qty, .thumb...) sont ceux
   que pilote standard/_product_configurator.html.twig — ne pas les renommer. */

.bde-crumb { max-width: 1220px; margin: 0 auto; padding: 20px clamp(18px, 5vw, 56px) 0; font-size: 13.5px; color: var(--bde-muted); display: flex; gap: 8px; flex-wrap: wrap; }
.bde-crumb a { color: var(--bde-muted); }
.bde-crumb b { color: var(--bde-ink); font-weight: 600; }

.bde-pd .bde-wrap { padding-top: 24px; padding-bottom: clamp(48px, 7vw, 80px); }
.bde-pd-grid { display: flex; gap: clamp(28px, 5vw, 60px); flex-wrap: wrap; align-items: flex-start; }

/* ---- Galerie ---- */
.bde-gallery { flex: 1 1 420px; min-width: 300px; position: sticky; top: 90px; }
.bde-gallery .stage {
    position: relative; border-radius: calc(var(--bde-radius) + 8px); overflow: hidden;
    background: repeating-linear-gradient(135deg, #efeae6 0 14px, #e7e1dc 14px 28px);
    aspect-ratio: 1 / 1.05; display: grid; place-items: center; border: 1px solid var(--bde-line-strong);
}
/* object-fit CONTAIN obligatoire : la geometrie du zoom (imageRect du
   configurateur) suppose une image non recadree dans le stage. */
.bde-gallery .stage img { width: 100%; height: 100%; object-fit: contain; }
.bde-gallery .thumbs { display: flex; gap: 12px; margin-top: 14px; flex-wrap: wrap; }
.bde-gallery .thumbs .thumb {
    flex: 1 1 70px; max-width: 96px; aspect-ratio: 1 / 1; border-radius: 12px; overflow: hidden;
    background: #efeae6; border: 2px solid transparent; cursor: pointer; padding: 0; transition: border-color .15s;
}
.bde-gallery .thumbs .thumb img { width: 100%; height: 100%; object-fit: cover; }
.bde-gallery .thumbs .thumb.active { border-color: var(--bde-primary); }
/* Zoom du configurateur : conserve, discret. La lentille est deplacee par
   transform: translate(x, y) depuis le COIN du stage -> top/left 0 obligatoires. */
.pd-zoom-lens { position: absolute; top: 0; left: 0; display: none; border: 1.5px solid var(--bde-primary); background: rgba(255,255,255,.25); pointer-events: none; }
.stage.is-zooming .pd-zoom-lens { display: block; }
.pd-zoom-pane {
    display: none; position: fixed; z-index: 60; width: 420px; height: 420px;
    border-radius: var(--bde-radius); border: 1px solid var(--bde-line); background: #fff no-repeat;
    box-shadow: 0 24px 48px -18px rgba(0,0,0,.25);
}
.pd-zoom-pane.is-on { display: block; }
/* HD en cours de chargement : spinner au centre du panneau. */
.pd-zoom-pane.is-loading::after {
    content: ''; position: absolute; inset: 0; margin: auto; width: 42px; height: 42px;
    border-radius: 999px; border: 3px solid var(--bde-line);
    border-top-color: var(--bde-primary); animation: bde-spin .8s linear infinite;
}
@keyframes bde-spin { to { transform: rotate(360deg); } }
@media (max-width: 980px) { .pd-zoom-lens, .pd-zoom-pane { display: none; } }

/* ---- Buybox ---- */
.bde-buybox { flex: 1 1 380px; min-width: 300px; }
.bde-buybox h1 {
    margin: 10px 0 0; font-family: var(--bde-font-display); font-weight: 900;
    font-size: clamp(38px, 5vw, 58px); line-height: .95; text-transform: uppercase; letter-spacing: -.5px;
}
.bde-pd-price { display: flex; align-items: baseline; gap: 14px; margin-top: 14px; flex-wrap: wrap; }
.bde-pd-price .now { font-family: var(--bde-font-display); font-weight: 900; font-size: 46px; line-height: 1; color: var(--bde-primary); }
.bde-pd-price .was { font-size: 18px; color: var(--bde-muted); }
.bde-pd-price .unit { font-size: 13.5px; color: var(--bde-muted); font-weight: 600; }
.bde-free-pill {
    display: inline-flex; align-items: center; gap: 7px;
    background: color-mix(in srgb, var(--bde-primary) 8%, transparent); color: var(--bde-primary);
    font-weight: 700; font-size: 13px; padding: 6px 12px; border-radius: 999px;
}
.bde-pd-bullets { margin: 14px 0 0; padding: 0; list-style: none; font-size: 15px; line-height: 1.6; color: var(--bde-body); }
.bde-pd-bullets li { display: flex; gap: 8px; align-items: flex-start; }
.bde-pd-bullets .pd-bullet-ic { flex: none; width: 17px; height: 17px; color: var(--bde-primary); margin-top: 3px; }

/* ---- Options (titres communs) ---- */
.bde-opt { margin-top: 28px; }
.bde-opt .opt-head { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; margin-bottom: 12px; }
.bde-opt .opt-head h2 { margin: 0; font-weight: 700; font-size: 14px; text-transform: uppercase; letter-spacing: 1px; }
.bde-opt .opt-head .pick { font-size: 13.5px; color: var(--bde-muted); font-weight: 600; }
.bde-opt .opt-head .pick b { color: var(--bde-ink); }

/* ---- Coloris (squelette standard : .colors > .color > .color-band) ---- */
.colors { display: flex; gap: 12px; flex-wrap: wrap; }
.colors .color {
    width: 46px; height: 46px; border-radius: 12px; overflow: hidden; display: flex;
    padding: 0; cursor: pointer; border: 3px solid #fff;
    box-shadow: 0 0 0 1.5px var(--bde-line-strong); transition: box-shadow .15s;
}
.colors .color .color-band { flex: 1; }
.colors .color.active { border-color: #fff; box-shadow: 0 0 0 2.5px var(--bde-primary); }
.colors-toggle, .see-more { display: none; }
.color-compo { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 12px; font-size: 13px; color: var(--bde-muted); }
.color-compo .ca { display: inline-flex; align-items: center; gap: 6px; background: #fff; border: 1px solid var(--bde-line); border-radius: 999px; padding: 4px 10px; }
.color-compo .ca i { width: 12px; height: 12px; border-radius: 999px; display: inline-block; }
.color-compo .ca b { color: var(--bde-ink); }

/* ---- Emplacements du logo : lignes standard restylees en CARTES ---- */
.placements { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 10px; }
.pl-row { display: contents; }
.pl-toggle {
    display: flex; flex-direction: column; align-items: center; text-align: center; gap: 3px;
    padding: 14px 8px 12px; cursor: pointer; border-radius: var(--bde-radius); background: #fff;
    border: 2px solid var(--bde-line-strong); transition: border-color .15s, box-shadow .15s;
    font-family: var(--bde-font-body);
}
.pl-row.is-active .pl-toggle { border-color: var(--bde-primary); box-shadow: 0 0 0 3px color-mix(in srgb, var(--bde-primary) 10%, transparent); }
.pl-row.is-unavailable .pl-toggle { opacity: .38; cursor: not-allowed; }
.pl-toggle .pl-check { display: none; }
.pl-toggle .pl-vis { width: 44px; height: 48px; border-radius: 8px; background: #e7e1dc; position: relative; }
.pl-toggle .pl-vis::after { content: ''; position: absolute; width: 9px; height: 9px; border-radius: 999px; background: var(--bde-primary); top: 10px; left: 9px; }
.pl-toggle .pl-vis.placement-vis--dos::after { width: 15px; height: 15px; top: 16px; left: 14px; }
.pl-toggle .pl-label { font-size: 13.5px; font-weight: 700; margin-top: 4px; color: var(--bde-ink); }
.pl-toggle .pl-hint { font-size: 11.5px; color: var(--bde-muted); }
.pl-logos { grid-column: 1 / -1; background: #fff; border: 1px solid var(--bde-line); border-radius: 12px; padding: 12px 14px; }
.pl-logos-label { display: block; font-size: 12.5px; font-weight: 700; color: var(--bde-muted); margin-bottom: 8px; }
.pl-logos-list { display: flex; gap: 8px; flex-wrap: wrap; }
.logo-chip { position: relative; width: 52px; height: 52px; border-radius: 10px; overflow: hidden; border: 2px solid var(--bde-line-strong); background: #fff; cursor: pointer; padding: 0; }
.logo-chip img { width: 100%; height: 100%; object-fit: contain; }
.logo-chip.is-active { border-color: var(--bde-primary); }
.logo-chip.is-unavailable { opacity: .35; }
.logo-chip .logo-chip-check { display: none; }
.logo-chip-ph { font-weight: 800; color: var(--bde-muted); }

/* ---- Grille tarifaire ---- */
.bde-grid-wrap { overflow-x: auto; border: 1px solid var(--bde-line); border-radius: 14px; background: #fff; }
#pd-grid { width: 100%; border-collapse: collapse; font-size: 13.5px; }
#pd-grid td { padding: 10px 12px; text-align: center; white-space: nowrap; border-bottom: 1px solid var(--bde-line); }
#pd-grid tr:last-child td { border-bottom: none; }
#pd-grid td:first-child { text-align: left; font-weight: 700; }
#pd-grid .gt-remise td { color: var(--bde-primary); }
#pd-grid td.is-current { background: color-mix(in srgb, var(--bde-secondary) 10%, transparent); font-weight: 700; }

/* ---- Quantites par taille ---- */
#pd-sizes { display: grid; grid-template-columns: repeat(auto-fit, minmax(76px, 1fr)); gap: 10px; }
.size-qty { display: flex; flex-direction: column; align-items: center; gap: 5px; background: #fff; border: 1.5px solid var(--bde-line-strong); border-radius: 11px; padding: 10px 6px; }
.size-qty label { font-family: var(--bde-font-display); font-weight: 800; font-size: 17px; }
.size-qty-input { width: 100%; height: 40px; text-align: center; border: 1.5px solid var(--bde-line-strong); border-radius: 9px; font-size: 15px; font-weight: 700; font-family: var(--bde-font-body); background: var(--bde-paper); }
.size-qty-input:focus { outline: none; border-color: var(--bde-primary); }
.size-qty-price { font-size: 12px; color: var(--bde-muted); min-height: 15px; }
.size-qty-badge { display: inline-block; width: 100%; text-align: center; padding: 1px 6px; border-radius: 999px; background: var(--bde-secondary); color: #fff; font-size: 11px; font-weight: 700; }

/* ---- Mode « une taille + une quantite » (affichage.selection_taille = unique) ---- */
.bde-size-chips { display: flex; gap: 10px; flex-wrap: wrap; }
.bde-size-chip {
    min-width: 52px; height: 48px; padding: 0 12px; display: inline-flex; align-items: center; justify-content: center;
    border-radius: 11px; cursor: pointer; font-size: 15px; font-weight: 700; font-family: var(--bde-font-body);
    background: #fff; color: var(--bde-ink); border: 1.5px solid var(--bde-line-strong); transition: background .15s, color .15s;
}
.bde-size-chip.is-active { background: var(--bde-primary); color: #fff; border-color: var(--bde-primary); }
.bde-qty-stepper {
    display: inline-flex; align-items: center; border: 1.5px solid var(--bde-line-strong);
    border-radius: var(--bde-radius); overflow: hidden; background: #fff; flex: none;
}
.bde-qty-stepper button { width: 46px; height: 56px; border: none; background: #fff; font-size: 22px; color: var(--bde-ink); cursor: pointer; }
.bde-qty-stepper [data-qty-val] { width: 42px; text-align: center; font-weight: 700; font-size: 17px; }

/* ---- Logo perso (contexte super uniquement) ---- */
.bde-perso { margin-top: 26px; background: #fff; border: 1px solid var(--bde-line); border-radius: var(--bde-radius); padding: 16px 18px; }
.bde-perso h2 { margin: 0; font-size: 15px; font-weight: 700; }
.bde-perso p { margin: 3px 0 10px; font-size: 13px; color: var(--bde-muted); }
.bde-perso .hint { display: block; margin-top: 6px; font-size: 12px; color: var(--bde-muted); }

/* ---- CTA ---- */
.bde-buy { display: flex; gap: 12px; align-items: stretch; margin-top: 28px; flex-wrap: wrap; }
.bde-buy .bde-cta { flex: 1 1 240px; height: 56px; padding: 0 26px; font-size: 16.5px; justify-content: center; border: none; cursor: pointer; }
.bde-buy .bde-cta[disabled] { opacity: .5; cursor: not-allowed; transform: none; }

/* ---- Reassurance ---- */
.bde-pd-reassure { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 14px; margin-top: 26px; padding-top: 24px; border-top: 1px solid var(--bde-line); }
.bde-pd-reassure .re { display: flex; gap: 10px; align-items: flex-start; }
.bde-pd-reassure .re svg, .bde-pd-reassure .re img { width: 20px; height: 20px; color: var(--bde-primary); flex: none; margin-top: 2px; }
.bde-pd-reassure .re b { display: block; font-weight: 700; font-size: 13.5px; }
.bde-pd-reassure .re span { display: block; margin-top: 2px; font-size: 12.5px; color: var(--bde-muted); }

/* ---- Note campagne ---- */
.bde-pd-note { margin-top: 22px; background: #fff; border: 1px solid var(--bde-line); border-radius: var(--bde-radius); padding: 16px 18px; font-size: 13.5px; color: var(--bde-body); line-height: 1.5; }
.bde-pd-note strong { color: var(--bde-ink); }

/* ---- Description ---- */
.bde-pd-desc .bde-wrap { padding-bottom: clamp(40px, 6vw, 64px); }
.bde-pd-desc h2 { margin: 0 0 10px; font-family: var(--bde-font-display); font-weight: 800; font-size: clamp(24px, 3vw, 36px); text-transform: uppercase; }
.bde-pd-desc p { margin: 0; font-size: 15.5px; line-height: 1.6; color: var(--bde-body); max-width: 60em; }

/* ---- Modal « ajouté » (partial standard _added_modal) ---- */
.da-modal { margin: auto; inset: 0; position: fixed; border: none; border-radius: calc(var(--bde-radius) + 4px); padding: 0; max-width: 420px; width: calc(100vw - 40px); box-shadow: 0 30px 70px -20px rgba(0,0,0,.35); }
.da-modal::backdrop { background: rgba(26, 20, 23, .45); backdrop-filter: blur(2px); }
.da-card { padding: 30px 26px 24px; text-align: center; font-family: var(--bde-font-body); }
.da-ic { width: 52px; height: 52px; margin: 0 auto; border-radius: 999px; background: color-mix(in srgb, var(--bde-secondary) 14%, transparent); color: var(--bde-secondary-ink); display: grid; place-items: center; }
.da-ic svg { width: 26px; height: 26px; }
.da-card h2 { margin: 14px 0 0; font-family: var(--bde-font-display); font-weight: 800; font-size: 26px; text-transform: uppercase; }
.da-card p { margin: 8px 0 0; font-size: 14.5px; color: var(--bde-body); line-height: 1.5; }
.da-actions { display: flex; gap: 10px; margin-top: 20px; flex-wrap: wrap; }
.da-actions .btn { flex: 1 1 140px; display: inline-flex; align-items: center; justify-content: center; padding: 13px 16px; border-radius: calc(var(--bde-radius) - 4px); font-weight: 700; font-size: 14.5px; cursor: pointer; }
.da-actions .btn-primary { background: var(--bde-primary); color: #fff; border: none; }
.da-actions .btn-ghost { background: #fff; color: var(--bde-ink); border: 1.5px solid var(--bde-line-strong); }
