/*!
 * BC Popin — Kit 4 indispensables (Spring)
 * Styles only. À charger avec <link rel="stylesheet" href=".../kit4-popin.css">
 * Voir kit4-popin.js pour le markup + la logique.
 */
#bc-upsell-overlay {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 999999;
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
  align-items: flex-end;
  justify-content: center;
  padding: 0;
  font-family: 'Poppins', sans-serif;
}
#bc-upsell-overlay.bc-open {
  display: flex;
}
@media (min-width: 480px) {
  #bc-upsell-overlay {
    align-items: center;
    padding: 1rem;
  }
}

#bc-upsell-card {
  background: #fff;
  border-radius: 20px 20px 0 0;
  max-width: 820px;
  width: 100%;
  padding: 1.75rem 2.25rem 1.5rem;
  position: relative;
  box-shadow: 0 -8px 40px rgba(0, 0, 0, 0.18);
  animation: bc-slide-up 0.28s cubic-bezier(0.34, 1.4, 0.64, 1);
  text-align: center;
}
@media (min-width: 480px) {
  #bc-upsell-card {
    border-radius: 20px;
    box-shadow: 0 24px 64px rgba(0, 0, 0, 0.2);
    animation: bc-pop-in 0.28s cubic-bezier(0.34, 1.4, 0.64, 1);
  }
}
@keyframes bc-slide-up {
  from { transform: translateY(100%); }
  to   { transform: translateY(0); }
}
@keyframes bc-pop-in {
  from { transform: scale(0.88); opacity: 0; }
  to   { transform: scale(1);    opacity: 1; }
}
@keyframes bc-bounce-badge {
  0%   { transform: translateX(-50%) scale(0.7); opacity: 0; }
  65%  { transform: translateX(-50%) scale(1.18); opacity: 1; }
  82%  { transform: translateX(-50%) scale(0.94); }
  100% { transform: translateX(-50%) scale(1); }
}
@keyframes bc-pulse-eco {
  0%, 100% { transform: scale(1);    box-shadow: 0 0 0 0 rgba(42,178,166,0.35); }
  50%       { transform: scale(1.05); box-shadow: 0 0 0 7px rgba(42,178,166,0); }
}

/* Cursor hint desktop — apparaît quand on survole l'overlay */
#bc-cursor-hint {
  display: none;
  position: fixed;
  pointer-events: none;
  z-index: 9999999;
  align-items: center;
  gap: 8px;
  background: rgba(20,20,20,0.8);
  color: #fff;
  padding: 7px 14px 7px 10px;
  border-radius: 24px;
  font-size: 12px;
  font-weight: 500;
  font-family: 'Poppins', sans-serif;
  white-space: nowrap;
  transform: translate(-50%, calc(-100% - 14px));
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}
#bc-cursor-hint.bc-hint-visible {
  display: flex;
}
.bc-hint-x {
  width: 20px;
  height: 20px;
  background: rgba(255,255,255,0.18);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  flex-shrink: 0;
}
@media (min-width: 480px) {
  #bc-upsell-overlay { cursor: none; }
  #bc-upsell-card    { cursor: auto; }
}

/* ✓ Confirmation row */
.bc-popin-confirm {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-bottom: 16px;
}
.bc-popin-confirm-icon {
  width: 20px;
  height: 20px;
  background: #2AB2A6;
  border-radius: 50%;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 800;
  flex-shrink: 0;
}
.bc-popin-confirm-text {
  font-size: 13px;
  font-weight: 600;
  color: #555;
}

/* Headline */
.bc-popin-headline {
  font-size: 32px;
  font-weight: 700;
  color: #1a1a1a;
  line-height: 1.18;
  margin: 0 0 14px;
}
.bc-popin-headline .bc-price-teal {
  color: #3A8DFF;
}

/* Savings tag */
.bc-popin-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #eef4ff;
  border: 1.5px solid rgba(58,141,255,0.3);
  font-size: 13px;
  padding: 8px 18px;
  border-radius: 20px;
  margin-bottom: 20px;
}
.bc-popin-tag-icon {
  color: #3A8DFF;
  flex-shrink: 0;
}
.bc-popin-tag-title {
  color: #1a1a1a;
  font-weight: 400;
}
.bc-popin-tag-sep {
  color: #aac8ff;
}
.bc-popin-tag-savings {
  font-weight: 800;
  color: #3A8DFF;
}

/* ── Carte offre unifiée (produits + prix) ── */
.bc-popin-offer-card {
  background: #fff;
  border-radius: 16px;
  margin-bottom: 14px;
  overflow: hidden;
  border: 1px solid rgba(0,0,0,0.07);
  box-shadow: 0 2px 12px rgba(0,0,0,0.05);
}

/* ── Products row ── */
.bc-popin-products {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 2px;
  padding: 12px 10px 14px;
}
.bc-popin-product {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  flex: 1;
  min-width: 0;
  padding-top: 14px; /* espace pour badge au-dessus */
}
.bc-popin-product-img-wrap {
  position: relative;
  width: 110px;
  height: 110px;
  flex-shrink: 0;
}
.bc-popin-product-img {
  width: 110px;
  height: 110px;
  border-radius: 50%;
  object-fit: cover;
  background: #f0f0f0;
  border: 3px solid #fff;
  box-shadow: 0 2px 12px rgba(0,0,0,0.14);
  display: block;
}
.bc-popin-product-img--yours {
  border-color: #2AB2A6;
  box-shadow: 0 0 0 3px rgba(42,178,166,0.18), 0 2px 12px rgba(0,0,0,0.14);
}
.bc-popin-product-img--contain {
  object-fit: cover;
  object-position: center 200%;
  background: #fff;
  border: none;
  box-shadow: none;
  border-radius: 0;
  transform: scale(1.4);
  transform-origin: center;
  clip-path: circle(35.71%); /* 50%/1.4 — compense le scale, cercle identique aux autres */
}
.bc-popin-product-img--contain-1-8 {
  object-fit: cover;
  object-position: center;
  background: #fff;
  border: none;
  box-shadow: none;
  border-radius: 0;
  transform: scale(1.8);
  transform-origin: center;
  clip-path: circle(27.78%); /* 50%/1.8 — compense le scale, cercle identique aux autres */
}
/* Recrée la bordure blanche + shadow sur le wrapper (clip-path coupe ceux de l'img) */
.bc-popin-product-img-wrap:has(.bc-popin-product-img--contain-1-8)::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 3px solid #fff;
  box-shadow: 0 2px 12px rgba(0,0,0,0.14);
  pointer-events: none;
  z-index: 1;
}
/* Recrée la bordure blanche + shadow sur le wrapper (clip-path coupe ceux de l'img) */
.bc-popin-product-img-wrap:has(.bc-popin-product-img--contain)::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 3px solid #fff;
  box-shadow: 0 2px 12px rgba(0,0,0,0.14);
  pointer-events: none;
  z-index: 1;
}
.bc-popin-badge {
  position: absolute;
  top: -11px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 12px;
  font-weight: 700;
  padding: 4px 11px;
  border-radius: 20px;
  white-space: nowrap;
  line-height: 1.2;
  letter-spacing: 0.02em;
  box-shadow: 0 1px 5px rgba(0,0,0,0.18);
  z-index: 2;
}
.bc-popin-badge--offert {
  background: #3A8DFF;
  color: #fff;
  animation: bc-bounce-badge 0.55s cubic-bezier(0.34, 1.4, 0.64, 1) 0.5s both;
}
.bc-popin-badge--green {
  background: #2AB2A6;
  color: #fff;
}
.bc-popin-badge--yours {
  background: #fff;
  color: #2AB2A6;
  border: 1.5px solid #2AB2A6;
  font-weight: 700;
}
.bc-popin-product-label {
  font-size: 12px;
  font-weight: 600;
  color: #333;
  text-align: center;
  line-height: 1.3;
  word-break: break-word;
  width: 100%;
}
.bc-popin-product-sublabel {
  font-size: 11px;
  color: #aaa;
  text-align: center;
  font-style: italic;
  line-height: 1.2;
  margin-top: -3px;
}
.bc-popin-product-oldprice {
  font-size: 10px;
  color: #c0c0c0;
  text-decoration: line-through;
  text-align: center;
  font-weight: 500;
  margin-top: -2px;
  line-height: 1.2;
}
.bc-popin-plus {
  display: none;
}

@media (max-width: 540px) {
  #bc-upsell-card {
    padding: 1rem 0.85rem 1rem;
  }
  .bc-popin-confirm {
    margin-bottom: 10px;
  }
  .bc-popin-headline {
    font-size: 22px;
    margin-bottom: 10px;
  }
  .bc-popin-stars {
    font-size: 11px;
    gap: 4px;
    margin: -4px 0 10px;
  }
  .bc-popin-stars-icons svg {
    width: 14px;
    height: 14px;
    flex-shrink: 0;
  }
  .bc-popin-tag {
    font-size: 11px;
    padding: 6px 12px;
    flex-wrap: wrap;
    justify-content: center;
    gap: 4px;
    margin-bottom: 14px;
  }
  /* Sur mobile : cacher les "+" et fixer la base à 25% pour forcer 4 sur une ligne */
  .bc-popin-plus {
    display: none;
  }
  .bc-popin-products {
    padding: 10px 4px 10px;
    gap: 0;
  }
  .bc-popin-product {
    flex: 1 1 25%;
    max-width: 25%;
    padding-top: 10px;
  }
  .bc-popin-product-img-wrap {
    width: 54px;
    height: 54px;
  }
  .bc-popin-product-img {
    width: 54px;
    height: 54px;
  }
  .bc-popin-badge {
    font-size: 9px;
    padding: 2px 5px;
    top: -8px;
  }
  .bc-popin-product-label {
    font-size: 9.5px;
  }
  .bc-popin-product-sublabel {
    font-size: 8.5px;
  }
  .bc-popin-offer-card {
    margin-bottom: 10px;
  }
  .bc-popin-price-bar {
    padding: 8px 10px 12px;
    gap: 4px;
  }
  .bc-popin-price-old {
    font-size: 13px;
  }
  .bc-popin-price-new {
    font-size: 24px;
  }
  .bc-popin-price-eco-badge {
    font-size: 10px;
    padding: 3px 10px 3px 7px;
  }
  .bc-popin-product-oldprice {
    font-size: 8px;
  }
  .bc-popin-delivery {
    margin-bottom: 10px;
    padding: 8px 0;
  }
}

/* Stars */
.bc-popin-stars {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin: -6px 0 14px;
  font-size: 13px;
  color: #666;
}
.bc-popin-stars-icons {
  display: inline-flex;
  gap: 2px;
  align-items: center;
  vertical-align: middle;
}
.bc-popin-stars-score {
  font-weight: 700;
  color: #333;
}
.bc-popin-stars-sep {
  color: #ddd;
}

/* ── Prix résumé ── */
.bc-popin-price-bar {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 7px;
  background: transparent;
  padding: 10px 16px 16px;
  border-top: 1px solid rgba(0,0,0,0.07);
  margin-top: 2px;
}
.bc-popin-price-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}
.bc-popin-price-old {
  font-size: 16px;
  color: #bbb;
  text-decoration: line-through;
  font-weight: 500;
}
.bc-popin-price-arrow {
  font-size: 14px;
  color: #ccc;
  font-weight: 400;
  line-height: 1;
  flex-shrink: 0;
}
.bc-popin-price-new {
  font-size: 30px;
  font-weight: 800;
  color: #333;
  line-height: 1;
}
.bc-popin-price-eco-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: #2AB2A6;
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  padding: 4px 12px 4px 9px;
  border-radius: 20px;
  letter-spacing: 0.01em;
  animation: bc-pulse-eco 2.4s ease-in-out 1.2s infinite;
}
.bc-popin-price-eco-badge svg {
  flex-shrink: 0;
}

/* Delivery */
.bc-popin-delivery {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  font-size: 12px;
  font-weight: 500;
  color: #888;
  margin-bottom: 14px;
  padding: 2px 0;
}
.bc-popin-delivery svg {
  color: #2AB2A6;
  flex-shrink: 0;
}
.bc-popin-delivery-label {
  color: #555;
}
.bc-popin-delivery-highlight {
  font-weight: 700;
  color: #2AB2A6;
}

/* CTA */
.bc-popin-cta {
  display: block;
  width: 100%;
  box-sizing: border-box;
  background: #FCEA54;
  color: #1a1a1a;
  font-weight: 700;
  font-size: 14px;
  text-align: center;
  padding: 16px 16px;
  border-radius: 10px;
  text-decoration: none;
  border: none;
  cursor: pointer;
  font-family: 'Poppins', sans-serif;
  margin-bottom: 10px;
  transition: opacity 0.15s, transform 0.1s;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}
.bc-popin-cta:hover { opacity: 0.9; transform: translateY(-1px); }
.bc-popin-cta:active { transform: translateY(0); }

/* Skip */
.bc-popin-skip {
  display: block;
  width: 100%;
  text-align: center;
  font-size: 12px;
  color: #999;
  background: none;
  border: none;
  cursor: pointer;
  text-decoration: underline;
  font-family: 'Poppins', sans-serif;
  padding: 6px 0 2px;
  transition: color 0.15s;
}
.bc-popin-skip:hover { color: #555; }
