/* ============================================================
   bcs-customizer-frontend.css — B.EASE Club Shops v6.1
   Module personnalisation produit — zone picker par image
   ============================================================ */

/* CTA « Personnaliser ce produit » sur la fiche produit (v8.0.6).
 * Aligné visuellement sur le bouton "Ajouter au panier" WooCommerce :
 * pleine largeur, coins légèrement arrondis, même hauteur et
 * typographie, couleur orange B.EASE. */
.bcs-customizer-cta {
    margin: 12px 0;
    width: 100%;
}
.bcs-btn-personnaliser {
    display: block;
    width: 100%;
    box-sizing: border-box;
    padding: 15px 30px;
    background: #E8593C;
    color: #fff !important;
    font-weight: 700;
    font-size: 16px;
    line-height: 1;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: .5px;
    border: none;
    border-radius: 4px;
    text-decoration: none;
    cursor: pointer;
    transition: background .2s;
}
.bcs-btn-personnaliser:hover,
.bcs-btn-personnaliser:focus {
    background: #c94a30;
    color: #fff !important;
    text-decoration: none;
}
.bcs-btn-equipe {
    display: block;
    width: 100%;
    box-sizing: border-box;
    padding: 13px 30px;
    margin-top: 8px;
    background: #fff;
    color: #E8593C !important;
    font-weight: 700;
    font-size: 16px;
    line-height: 1;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: .5px;
    border: 2px solid #E8593C;
    border-radius: 4px;
    text-decoration: none;
    cursor: pointer;
    transition: background .2s, color .2s;
}
.bcs-btn-equipe:hover,
.bcs-btn-equipe:focus {
    background: #E8593C;
    color: #fff !important;
    text-decoration: none;
}


/* ── Panneau principal ─────────────────────────────────────── */
.bcs-customizer-panel {
  border: 2px solid #E8001C;
  border-radius: 12px;
  margin: 20px 0;
  overflow: hidden;
  font-family: 'Barlow', 'DM Sans', system-ui, sans-serif;
  font-size: 14px;
}

/* ── Header accordéon ──────────────────────────────────────── */
.bcs-cust-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 18px; background: #fff; cursor: pointer;
  user-select: none; transition: background .15s;
}
.bcs-cust-header:hover { background: #fff5f5; }
.bcs-cust-header-left { display: flex; align-items: center; gap: 12px; }
.bcs-cust-icon { font-size: 22px; }
.bcs-cust-header-left strong { display: block; font-size: 15px; font-weight: 700; color: #111; }
.bcs-cust-subtitle { display: block; font-size: 12px; color: #666; margin-top: 1px; }
.bcs-cust-arrow { font-size: 11px; color: #aaa; transition: transform .2s; }

/* ── Corps ─────────────────────────────────────────────────── */
.bcs-cust-body {
  padding: 18px; border-top: 1px solid #f0f0f0; background: #fafafa;
}

/* ── Section générique ─────────────────────────────────────── */
.bcs-cust-section {
  background: #fff; border: 1px solid #e5e7eb;
  border-radius: 10px; padding: 14px 16px; margin-bottom: 14px;
}
.bcs-cust-section-title {
  font-weight: 700; font-size: 13px; color: #111;
  margin-bottom: 12px; display: flex; align-items: center; gap: 8px;
}
.bcs-text-price-badge {
  font-size: 11px; background: #E8001C; color: #fff;
  padding: 1px 8px; border-radius: 10px; font-weight: 600; margin-left: auto;
}

/* ── Zone picker ───────────────────────────────────────────── */
.bcs-zone-section {
  background: #fff; border: 1px solid #e5e7eb;
  border-radius: 10px; padding: 14px 16px; margin-bottom: 14px;
}
.bcs-zone-picker-title {
  font-weight: 700; font-size: 13px; color: #111; margin-bottom: 12px;
}
.bcs-zone-picker {
  display: flex; gap: 10px; overflow-x: auto;
  padding-bottom: 4px; scroll-snap-type: x mandatory;
}
.bcs-zone-picker::-webkit-scrollbar { height: 4px; }
.bcs-zone-picker::-webkit-scrollbar-thumb { background: #ddd; border-radius: 2px; }

.bcs-zone-card {
  flex: 0 0 auto; width: 110px; cursor: pointer;
  border: 2px solid #e5e7eb; border-radius: 8px;
  overflow: hidden; transition: border-color .15s, box-shadow .15s;
  scroll-snap-align: start;
  background: #fff;
}
.bcs-zone-card:hover { border-color: #f87171; }
.bcs-zone-card.active {
  border-color: #E8001C;
  box-shadow: 0 0 0 3px rgba(232, 0, 28, .12);
}
.bcs-zone-card-img {
  position: relative; width: 100%; aspect-ratio: 3/4;
  overflow: hidden; background: #f5f5f5;
}
.bcs-zone-card-img img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform .2s;
}
.bcs-zone-card:hover .bcs-zone-card-img img { transform: scale(1.04); }
.bcs-zone-check-mark {
  position: absolute; top: 5px; right: 5px;
  width: 22px; height: 22px; background: #E8001C;
  color: #fff; border-radius: 50%; font-size: 12px; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
}
.bcs-zone-card-info {
  padding: 6px 8px; text-align: center;
}
.bcs-zone-card-info strong {
  display: block; font-size: 11px; font-weight: 700;
  color: #111; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.bcs-zone-card-info span {
  display: block; font-size: 10px; color: #888; margin-top: 1px;
}

/* Récap zone -->
.bcs-zone-recap {
  margin-top: 12px; padding: 10px 14px;
  background: linear-gradient(90deg, #fff5f5, #fff);
  border: 1px solid #fecaca; border-radius: 8px;
  display: flex; align-items: center; justify-content: space-between;
  flex-wrap: wrap; gap: 8px;
}
.bcs-zone-recap-dims {
  display: flex; align-items: center; gap: 6px;
  font-size: 13px; color: #333; font-weight: 600; flex-wrap: wrap;
}
.bcs-recap-sep { color: #ccc; }
.bcs-zone-recap-price {
  display: flex; align-items: center; gap: 5px;
  font-size: 13px; color: #555;
}
.bcs-zone-recap-price strong {
  font-size: 16px; font-weight: 800; color: #E8001C;
}

/* ── Drop zone logo ────────────────────────────────────────── */
.bcs-logo-dropzone {
  border: 2px dashed #ddd; border-radius: 10px; background: #fff;
  transition: border-color .15s, background .15s; overflow: hidden;
}
.bcs-logo-dropzone:hover,
.bcs-logo-dropzone.drag-over { border-color: #E8001C; background: #fff5f5; }

.bcs-logo-placeholder {
  display: flex; flex-direction: column; align-items: center; gap: 6px;
  padding: 22px 16px; text-align: center; cursor: pointer;
}
.bcs-drop-icon { font-size: 26px; color: #ccc; }
.bcs-logo-placeholder > span { font-size: 13px; color: #444; line-height: 1.5; }
.bcs-formats { font-size: 11px; color: #999; }
.bcs-svg-highlight { color: #16a34a; }
.bcs-browse-btn {
  background: none; border: none; color: #E8001C; font-weight: 700;
  cursor: pointer; padding: 0; font-size: 13px; text-decoration: underline;
}

.bcs-logo-preview {
  display: flex; align-items: center; gap: 14px;
  padding: 14px 16px; position: relative;
}
.bcs-logo-preview img {
  max-width: 80px; max-height: 64px; object-fit: contain;
  border: 1px solid #eee; border-radius: 6px; background: #fff; padding: 4px;
}
.bcs-logo-preview > div { flex: 1; font-size: 11px; }
.bcs-logo-remove {
  position: absolute; top: 8px; right: 8px;
  background: #fee2e2; border: none; color: #ef4444;
  width: 22px; height: 22px; border-radius: 50%; cursor: pointer;
  font-size: 11px; font-weight: 700; display: flex; align-items: center; justify-content: center;
}
.bcs-logo-remove:hover { background: #fca5a5; }

.bcs-upload-progress {
  padding: 14px 16px; text-align: center; font-size: 12px; color: #666;
}
.bcs-progress-bar {
  height: 5px; background: #f0f0f0; border-radius: 3px; overflow: hidden; margin-bottom: 6px;
}
.bcs-progress-fill {
  height: 100%; width: 0%; background: linear-gradient(90deg, #E8001C, #ff5c5c);
  border-radius: 3px; transition: width .3s;
}
.bcs-upload-error {
  padding: 8px 12px; font-size: 12px; color: #ef4444;
  background: #fff5f5; border-top: 1px solid #fecaca;
}

/* Badge SVG / bitmap */
.bcs-svg-badge {
  display: inline-block; background: #f0fdf4; color: #16a34a;
  font-size: 10px; font-weight: 700; padding: 1px 7px;
  border-radius: 10px; border: 1px solid #bbf7d0;
}
.bcs-bitmap-badge {
  display: inline-block; background: #fffbeb; color: #f59e0b;
  font-size: 10px; font-weight: 700; padding: 1px 7px;
  border-radius: 10px; border: 1px solid #fde68a;
}

/* Info vectorisation */
.bcs-bitmap-warning {
  margin-top: 8px; padding: 9px 12px; font-size: 12px;
  background: #fffbeb; border: 1px solid #fde68a;
  border-radius: 8px; color: #92400e; line-height: 1.5;
}

/* ── Saisie texte ──────────────────────────────────────────── */
.bcs-text-row {
  position: relative; display: flex; align-items: center; margin-bottom: 10px;
}
.bcs-text-input {
  width: 100%; padding: 10px 56px 10px 13px;
  border: 2px solid #e5e7eb; border-radius: 8px;
  font-size: 14px; color: #111; outline: none;
  box-sizing: border-box; transition: border-color .15s;
}
.bcs-text-input:focus { border-color: #E8001C; }
.bcs-char-count {
  position: absolute; right: 12px; font-size: 11px; color: #bbb; font-weight: 600;
}
.bcs-text-style-row {
  display: flex; gap: 14px; flex-wrap: wrap;
}
.bcs-style-group { flex: 1; min-width: 130px; }
.bcs-style-label {
  display: block; font-size: 11px; font-weight: 600; color: #666;
  text-transform: uppercase; letter-spacing: .4px; margin-bottom: 5px;
}
.bcs-color-row { display: flex; align-items: center; gap: 6px; }
.bcs-color-pick {
  width: 32px; height: 30px; border: 2px solid #e5e7eb;
  border-radius: 6px; padding: 0; cursor: pointer; background: none;
}
.bcs-swatches { display: flex; gap: 5px; flex-wrap: wrap; }
.bcs-swatch {
  width: 20px; height: 20px; border-radius: 50%; padding: 0;
  border: 2px solid #fff; box-shadow: 0 0 0 1px #ddd;
  cursor: pointer; transition: transform .15s, box-shadow .15s;
}
.bcs-swatch:hover, .bcs-swatch.active {
  transform: scale(1.2); box-shadow: 0 0 0 2px #E8001C;
}
.bcs-font-select {
  width: 100%; padding: 6px 10px; border: 1.5px solid #e5e7eb;
  border-radius: 8px; font-size: 12px; color: #333; outline: none; background: #fff;
}
.bcs-font-select:focus { border-color: #E8001C; }

.bcs-text-preview {
  margin-top: 10px; padding: 10px 14px;
  background: #f9fafb; border: 1px solid #e5e7eb; border-radius: 8px;
}
.bcs-text-preview-lbl { font-size: 10px; color: #aaa; text-transform: uppercase; margin-bottom: 4px; }
.bcs-text-preview-val { font-size: 18px; font-weight: 700; min-height: 28px; }

/* ── Total recap ───────────────────────────────────────────── */
.bcs-total-recap {
  display: flex; align-items: center; gap: 8px;
  padding: 10px 14px; background: #fff5f5;
  border: 1px solid #fecaca; border-radius: 8px;
  margin-bottom: 12px; font-size: 13px; color: #555;
}
.bcs-total-recap strong { font-size: 15px; font-weight: 800; color: #E8001C; }
.bcs-ht-tag { font-size: 11px; color: #aaa; }

/* ── Note ──────────────────────────────────────────────────── */
.bcs-cust-note {
  font-size: 11px; color: #999; line-height: 1.5;
  padding-top: 2px;
}

/* ── Responsive ────────────────────────────────────────────── */
@media (max-width: 480px) {
  .bcs-cust-header { padding: 12px 14px; }
  .bcs-cust-body   { padding: 13px; }
  .bcs-zone-card   { width: 90px; }
  .bcs-text-style-row { flex-direction: column; gap: 10px; }
}

/* Boutons customizer — full-width sous "Ajouter au panier" Blocksy.
 * Couleur : noir B.EASE (#1a1a1a) pour distinguer du CTA principal corail
 * sans en faire un doublon visuel. !important nécessaire pour battre la
 * spécificité égale de .button.alt du thème Blocksy. */
.bcs-customizer-buttons {
    display: flex;
    gap: 10px;
    margin-top: 8px;
    margin-bottom: 12px;
    width: 100%;
}
.bcs-customizer-buttons .bcs-btn-personnaliser,
.bcs-customizer-buttons .bcs-btn-equipe {
    flex: 1 1 50%;
    box-sizing: border-box;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    height: auto !important;
    padding: 0.8em 1.5em !important;
    margin: 0 !important;
    background: #1a1a1a !important;
    color: #fff !important;
    font-weight: 700;
    font-size: 1em !important;
    line-height: 1.5 !important;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: .5px;
    border: 1px solid #1a1a1a !important;
    border-radius: 4px;
    text-decoration: none;
    cursor: pointer;
    vertical-align: middle !important;
    transition: background .2s, border-color .2s;
}
.bcs-customizer-buttons .bcs-btn-personnaliser:hover,
.bcs-customizer-buttons .bcs-btn-personnaliser:focus,
.bcs-customizer-buttons .bcs-btn-equipe:hover,
.bcs-customizer-buttons .bcs-btn-equipe:focus {
    background: #333 !important;
    border-color: #333 !important;
    color: #fff !important;
    text-decoration: none;
}
.bcs-customizer-buttons--solo .bcs-btn-personnaliser,
.bcs-customizer-buttons--solo .bcs-btn-equipe {
    flex: 1 1 100%;
}
