:root{
  --panel-w: 420px;
  --radius: 14px;
  --accent: #3E0115;
  --text: #111;
  --muted:#6b7280;
  --bg:   #fff;
}

/* ============ CONTAINER ============ */
#avee-sidecart.is-hidden{ display:none; }
#avee-sidecart{ position:fixed; inset:0; z-index:9999;  }
#avee-sidecart .avee-overlay{ position:absolute; inset:0; background:rgba(0,0,0,.35); opacity:0; transition:opacity .15s; }
#avee-sidecart.is-open .avee-overlay{ opacity:1; }

:root{ --panel-w: 420px; }          /* largeur du drawer */
@media (max-width:480px){ :root{ --panel-w: 100vw; } }

#avee-sidecart .avee-panel{
  position:absolute; top:0; right:0; height:100%;
  width:var(--panel-w);
  background:var(--bg); color:var(--text);
  box-shadow:-12px 0 28px rgba(0,0,0,.18);
  display:flex; flex-direction:column;

  /* slide depuis la droite */
  transform:translate3d(100%,0,0);
  transition:transform .28s cubic-bezier(.22,.61,.36,1);
  will-change:transform;
}
#avee-sidecart.is-open .avee-panel{ transform:translate3d(0,0,0); }


#avee-sidecart .avee-close{
  position:absolute; top:10px; right:10px; width:36px; height:36px;
  border:0; background:#f4f5f7; border-radius:999px; font-size:22px; cursor:pointer;
}

#avee-sidecart .avee-head{ padding:18px 18px 10px; border-bottom:1px solid #eef0f3; }
#avee-sidecart .avee-title{ margin:0 36px 10px 0; font-weight:800; font-size:18px; }

/* ============ FREE SHIPPING BAR ============ */
#avee-sidecart .avee-freebar{ background:#f7f9ff; border:1px solid #e4ecff; border-radius:12px; padding:10px 12px; }
#avee-sidecart .avee-freebar-msg{ font-size:13px; color:#1f2a44; margin-bottom:6px; }
#avee-sidecart .avee-progress{ height:8px; background:#e9eefc; border-radius:999px; overflow:hidden; }
#avee-sidecart .avee-progress-fill{ display:block; height:100%; width:0%; background:linear-gradient(90deg,#3E0115,#A40338); }
#avee-sidecart .avee-freebar-dynamic{ margin-top:6px; font-size:13px; color:#1f2a44; }

/* ============ BODY ============ */
#avee-sidecart .avee-body{ flex:1 1 auto; overflow:auto; padding:14px 18px; }
#avee-sidecart .woocommerce-mini-cart{ margin:0; padding:0; list-style:none; }

/* ITEM : image à gauche, texte à droite */
#avee-sidecart .woocommerce-mini-cart > li{
  display:grid; grid-template-columns: 84px 1fr; gap:12px;
  align-items:center; padding:14px 0; border-bottom:1px solid #f1f2f6;
}

/* image carrée, à gauche */
#avee-sidecart .woocommerce-mini-cart > li img{
  grid-column:1; grid-row:1 / span 3;
  width:84px; height:84px; object-fit:cover; border-radius:10px;
  background:#f6f7fb; border:1px solid #eceff3;
  margin:0 !important;
}

/* titre (1 ligne, pas d’ellipses/clamp) */
#avee-sidecart .mini-title{
  grid-column:2;
  white-space: nowrap; overflow: visible;
  display:flex; align-items:center; gap:8px;
  font-weight:800; line-height:1.25; color:#111;
}

/* pill Pack */
#avee-sidecart .pill{
  padding:4px 8px; font-size:12px; border-radius:999px;
  background:#f2f4ff; border:1px solid #e4e8ff; font-weight:700;
}

/* micro-copy sous le titre */
#avee-sidecart .mini-meta{
  grid-column:2; margin:4px 0 6px; font-size:12px; color:#637085;
  display:flex; gap:10px; align-items:center;
}
#avee-sidecart .dot{ width:6px; height:6px; border-radius:999px; background:#21c55d; display:inline-block; }

/* prix de ligne */
#avee-sidecart .line-price{ grid-column:2; font-weight:800; color:#111; margin:4px 0; }

/* masquer quantité native Woo */
#avee-sidecart .woocommerce-mini-cart > li .quantity{ display:none !important; }

/* cacher la croix native (ajoutée en JS via .is-hidden-visually) */
#avee-sidecart .is-hidden-visually{ display:none !important; }

/* contrôles quantité + Retirer */
#avee-sidecart .mini-row{
  grid-column:2; display:flex; align-items:center; justify-content:space-between; gap:12px;
}
#avee-sidecart .qty-ctrl{
  display:inline-flex; align-items:center; gap:12px; background:#fff;
  border:1px solid #e5e7eb; border-radius:12px; padding:8px 10px;
}
#avee-sidecart .qty-ctrl button{
  width:44px; height:44px; border:0; border-radius:10px;
  background:#f2f3f7; font-weight:800; font-size:18px; cursor:pointer;
}
#avee-sidecart .qty-ctrl button:disabled{ opacity:.4; cursor:not-allowed; }
#avee-sidecart .qty-ctrl .val{ min-width:18px; text-align:center; font-weight:800; }

#avee-sidecart .mini-remove{
  color:#1f2a44; font-weight:700; text-decoration:none;
}
#avee-sidecart .mini-remove:hover{ text-decoration:underline; }

/* badge “G configurée” */
#avee-sidecart .gbp-badge{
  padding:3px 8px; border-radius:999px; font-size:11px; font-weight:700;
  background:#e8f0ff; color:#1f3a8a;
}

/* feedback */
#avee-sidecart li.changed{ animation: aveeFlash .25s ease; }
@keyframes aveeFlash{ from{ background:#f5f9ff; } to{ background:transparent; } }
#avee-sidecart li.shake{ animation: aveeShake .25s; }
@keyframes aveeShake{ 25%{transform:translateX(-2px)} 50%{transform:translateX(2px)} 75%{transform:translateX(-1px)} }

/* ============ TOTALS & BOUTON ============ */
#avee-sidecart .woocommerce-mini-cart__total{ margin-top:10px; font-weight:800; }
#avee-sidecart .woocommerce-mini-cart__buttons{ display:flex; gap:10px; margin-top:12px; }
#avee-sidecart .woocommerce-mini-cart__buttons a.button:not(.checkout){ display:none !important; }
#avee-sidecart .woocommerce-mini-cart__buttons .checkout{
  background:linear-gradient(90deg, #3E0115 0%, #A40338 100%); color:#fff; font-weight:800;
  width:100%; border-radius:12px; padding:12px 14px; text-align:center;
}

/* ============ FOOTER ============ */
#avee-sidecart .avee-foot{ padding:12px 18px 16px; border-top:1px solid #eef0f3; }
#avee-sidecart .avee-badges{ display:flex; flex-wrap:wrap; gap:8px; margin-bottom:10px; }
#avee-sidecart .avee-badges .badge{ background:#f6f7fb; border:1px solid #e8ebf6; padding:6px 10px; border-radius:999px; font-size:12px; }
#avee-sidecart .avee-payments{ display:flex; gap:8px; align-items:center; flex-wrap:wrap; justify-content: center; padding: 12px 0;}
#avee-sidecart .avee-payments img{ height:22px; width:auto; display:block; filter:saturate(1); }

/* ============ RESPONSIVE ============ */

  #avee-sidecart .woocommerce-mini-cart > li{
    grid-template-columns: 72px 1fr;
  }
  #avee-sidecart .woocommerce-mini-cart > li img{
    width:72px; height:72px;
  }
}



/* Onglet flottant (peek) */
.avee-cart-peek{
  position: fixed;
  right: 16px;
  bottom: 16px;
  z-index: 9998;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 999px;
  background: #111;
  color: #fff;
  border: 1px solid rgba(255,255,255,.12);
  box-shadow: 0 8px 24px rgba(0,0,0,.25);
  font-weight: 800;
  cursor: pointer;
}
.avee-cart-peek .peek-count{
  min-width: 28px;
  height: 28px;
  border-radius: 999px;
  background: #2b6cff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
}
.avee-cart-peek .peek-total{
  font-size: 14px;
}
@media (max-width: 480px){
  .avee-cart-peek{ right: 12px; bottom: 12px; padding: 9px 12px; }
  .avee-cart-peek .peek-count{ min-width: 26px; height: 26px; font-size: 12px; }
  .avee-cart-peek .peek-total{ font-size: 13px; }
}

#avee-sidecart .mini-meta {
  flex-wrap: wrap;
  word-break: break-word;
}

.addr-tooltip {
  position: relative;
  display: inline-block;
}

.addr-info {
  font-style: normal;
  cursor: pointer;
  border-bottom: 1px dotted var(--muted);
  color: var(--muted);
}

/* TOOLTIP STYLE (automatique via title) → si besoin de bulle custom : */
.addr-info::after {
  content: attr(title);
  position: absolute;
  left: 0;
  top: 100%;
  background: #fff;
  color: #111;
  padding: 6px 10px;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0,0,0,.12);
  white-space: normal;
  display: none;
  min-width: 200px;
  z-index: 1000;
}

.addr-info:hover::after {
  display: block;
}


/* Optionnel – pour avoir un vrai tooltip stylé */
.gbp-tooltip {
  position: relative;
  display: inline-block;
}



#avee-sidecart{
  position: fixed;
  inset: 0;
  z-index: 9999;
  /* pas de max-width ici */
  overflow-x: hidden; /* pour être sûr */
}



/* indispensable pour que l'ellipsis fonctionne dans un flex */
#avee-sidecart .mini-title{ min-width:0; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }

/* nom de fiche sous le titre */
.gbp-name{
  display:inline-block;
  max-width:65%;          /* ou une valeur en px, ex. 240px */
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
  vertical-align:middle;
  font-size:13px; color:#666; cursor:help;
}

/* petite bulle au hover (adresse ou nom complet) */
.gbp-tooltip{ position:relative; display:inline-block; margin-left:6px; cursor:help; }
.gbp-tooltip:hover::after{
  content:attr(title);
  position:absolute; bottom:120%; left:50%; transform:translateX(-50%);
  background:#222; color:#fff; padding:6px 10px; font-size:12px;
  border-radius:6px; white-space:nowrap; z-index:9999;
}


.avee-payments img.avee-single-payment {
  width: 28px;   /* largeur fixe */
  height: 20px;  /* hauteur fixe */
  object-fit: contain;
  display: block;
}