/* Accaven — carte produit (spec §5, §9 ; maquettes Main.dc.html, Mobile.dc.html, CarteTailles.dc.html). */

.acc-card {
  position: relative; display: flex; flex-direction: column; min-width: 0;
  border: 1px solid var(--acc-border); border-radius: var(--acc-radius-card); overflow: hidden; background: var(--acc-white);
  font-family: var(--acc-font-body); color: var(--acc-navy); line-height: 1.4;
}
.acc-card * { box-sizing: border-box; }
.acc-card a { color: var(--acc-navy); text-decoration: none; }
.acc-card :focus-visible { outline: 2px solid var(--acc-navy); outline-offset: 2px; }

/* Image 3:4 */
.acc-card__media { position: relative; aspect-ratio: 3 / 4; background: var(--acc-surface); }
.acc-card__img-link { position: absolute; inset: 0; display: block; }
.acc-card .acc-card__img { position: absolute; inset: 0; width: 100%; height: 100%; max-width: none; object-fit: cover; display: block; }
.acc-card .acc-card__img--alt { opacity: 0; transition: opacity var(--acc-ease); }
@media (hover: hover) {
  .acc-card:hover .acc-card__img--alt { opacity: 1; }
}

.acc-badge {
  position: absolute; top: 8px; left: 8px; z-index: 1; height: 24px; padding: 0 10px;
  display: flex; align-items: center; border-radius: 4px;
  font-family: var(--acc-font-head); font-weight: 700; font-size: 12px; line-height: 1;
}
.acc-badge--promo { background: var(--acc-red); color: var(--acc-white); }
.acc-badge--new { background: var(--acc-lime); color: var(--acc-navy); }

.acc-card .acc-card__wish {
  position: absolute; top: 0; right: 0; z-index: 1; width: 44px; height: 44px; padding: 0; margin: 0;
  display: flex; align-items: center; justify-content: center;
  border: 0; border-radius: var(--acc-radius-chip); background: transparent; box-shadow: none; color: var(--acc-navy); cursor: pointer;
}
.acc-card__wish-dot { width: 34px; height: 34px; border-radius: var(--acc-radius-chip); background: var(--acc-white); display: flex; align-items: center; justify-content: center; }
.acc-card__wish[aria-pressed="true"] svg { fill: currentColor; }

/* Texte */
.acc-card__body { display: flex; flex-direction: column; flex-grow: 1; padding: 10px; }
.acc-card .acc-card__name {
  margin: 0; padding: 0; min-height: 38px;
  font-family: var(--acc-font-body); font-weight: 400; font-size: 14px; line-height: 19px; letter-spacing: 0; text-transform: none; color: var(--acc-navy);
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.acc-card__row { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 6px; }
.acc-card__price { display: flex; align-items: baseline; flex-wrap: wrap; column-gap: 8px; min-width: 0; font-size: 16px; font-weight: 600; }
.acc-card__price del { font-size: 14px; font-weight: 400; color: var(--acc-muted); }
.acc-card__price ins { text-decoration: none; font-size: 16px; font-weight: 600; color: var(--acc-red); background: none; }
.acc-card .screen-reader-text { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Bouton panier rond + infobulle */
.acc-cart { position: relative; flex-shrink: 0; display: flex; }
.acc-card .acc-card__cart {
  flex-shrink: 0; width: 44px; height: 44px; padding: 0; margin: 0;
  display: flex; align-items: center; justify-content: center;
  border: 1px solid var(--acc-navy); border-radius: var(--acc-radius-chip); background: var(--acc-white); color: var(--acc-navy);
  box-shadow: none; cursor: pointer; line-height: 1;
}
.acc-card .acc-card__cart.is-ready { border-color: var(--acc-navy); background: var(--acc-navy); color: var(--acc-white); }
.acc-card .acc-card__cart.is-busy { opacity: .6; pointer-events: none; }
.acc-tip {
  position: absolute; z-index: 3; bottom: calc(100% + 9px); right: 0; white-space: nowrap; padding: 7px 10px;
  border-radius: 6px; background: var(--acc-navy); color: var(--acc-white);
  font-family: var(--acc-font-head); font-weight: 600; font-size: 11px; line-height: 14px;
  box-shadow: 0 6px 16px rgba(60, 57, 80, .22);
  opacity: 0; transform: translateY(4px); transition: opacity 150ms ease, transform 150ms ease; pointer-events: none;
}
.acc-tip::after { content: ""; position: absolute; right: 15px; bottom: -4px; width: 9px; height: 9px; background: var(--acc-navy); transform: rotate(45deg); }
.acc-cart:active .acc-tip, .acc-tip.is-on { opacity: 1; transform: none; }
@media (hover: hover) {
  .acc-cart:hover .acc-tip, .acc-cart:focus-within .acc-tip { opacity: 1; transform: none; }
}

/* Tailles */
.acc-card__sizes { display: flex; gap: 4px; margin-top: 8px; overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.acc-card__sizes::-webkit-scrollbar { display: none; }
.acc-card .acc-size {
  flex-shrink: 0; min-width: 44px; height: 44px; padding: 0 8px; margin: 0;
  border: 1px solid var(--acc-control); border-radius: 6px; background: var(--acc-white); box-shadow: none;
  color: var(--acc-navy); font-family: var(--acc-font-body); font-weight: 400; font-size: 13px; line-height: 1; letter-spacing: 0; text-transform: none; cursor: pointer;
  transition: transform 150ms ease;
}
.acc-card .acc-size.is-on, .acc-card .acc-size[aria-pressed="true"] { background: var(--acc-lime); border-color: var(--acc-navy); }
.acc-card .acc-size--more { background: var(--acc-surface); border-color: var(--acc-navy); font-family: var(--acc-font-head); font-weight: 600; font-size: 12px; }
.acc-card .acc-size--more[hidden] { display: none; }
.acc-card.is-flash .acc-card__sizes .acc-size:not(.acc-size--more) { border-color: var(--acc-navy); transform: translateY(-2px); }
.acc-card__unique { min-height: 44px; margin-top: 8px; display: flex; align-items: center; font-size: 13px; color: var(--acc-muted); }

/* Panneau « +N » */
.acc-card__panel {
  position: absolute; left: 8px; right: 8px; bottom: 8px; z-index: 4; padding: 10px;
  border: 1px solid var(--acc-border); border-radius: 8px; background: var(--acc-white); box-shadow: 0 10px 28px rgba(60, 57, 80, .2);
  display: flex; flex-direction: column; gap: 8px;
}
.acc-card__panel[hidden] { display: none; }
.acc-card__panel-head { display: flex; align-items: center; justify-content: space-between; font-family: var(--acc-font-head); font-weight: 600; font-size: 12px; }
.acc-card .acc-card__panel-close { width: 28px; height: 28px; margin: -4px -4px -4px 0; padding: 0; border: 0; background: transparent; color: var(--acc-navy); display: flex; align-items: center; justify-content: center; cursor: pointer; box-shadow: none; }
.acc-card__panel-sizes { display: flex; flex-wrap: wrap; gap: 4px; }
.acc-card .acc-card__panel-sizes .acc-size { min-width: 0; height: 30px; padding: 0 6px; font-size: 12px; }

/* Desktop */
@media (min-width: 768px) {
  .acc-badge { top: 10px; left: 10px; }
  .acc-card .acc-card__wish { top: 6px; right: 6px; width: 40px; height: 40px; background: var(--acc-white); }
  .acc-card__wish-dot { width: auto; height: auto; background: none; }
  .acc-card__body { padding: 12px; }
  .acc-card .acc-card__name { min-height: 40px; line-height: 20px; }
  .acc-card .acc-card__cart { width: 40px; height: 40px; }
  .acc-card__sizes { overflow: hidden; height: 30px; }
  .acc-card .acc-size { min-width: 0; height: 30px; padding: 0 6px; font-size: 12px; }
  .acc-card .acc-size--more { min-width: 30px; }
  .acc-card__unique { min-height: 30px; }
}

/* Grilles de cartes */
.acc-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px 12px; margin: 0; padding: 0; list-style: none; }
@media (min-width: 768px) { .acc-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px 16px; } }
@media (min-width: 1200px) { .acc-grid { grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 24px 20px; } }

/* Lien « Voir le panier » ajouté par WooCommerce après un ajout : jamais affiché dans la refonte. */
.acc-card .added_to_cart, .acc-pp .added_to_cart, .acc-buybar .added_to_cart { display: none !important; }
