/* === WCMC product layouts v2.6.4 (cards-only targeting) === */

/* UL.products support (ако се ползва Woo списък) */
.wcmc-style-two ul.products{ display:grid !important; grid-template-columns: repeat(2, minmax(0,1fr)) !important; gap: var(--wcmc-gap, 24px) !important; }
.wcmc-style-one ul.products{ display:grid !important; grid-template-columns: 1fr !important; gap: var(--wcmc-gap, 20px) !important; }
.wcmc-style-one ul.products > li.product,
.wcmc-style-two ul.products > li.product{ width:auto !important; float:none !important; margin:0 !important; clear:none !important; }
ul.products[data-wcmc-layout="two"]{ display:grid !important; grid-template-columns: repeat(2, minmax(0,1fr)) !important; gap: var(--wcmc-gap, 24px) !important; }
ul.products[data-wcmc-layout="one"]{ display:grid !important; grid-template-columns: 1fr !important; gap: var(--wcmc-gap, 20px) !important; }

/* ---- Cards mode: работим само с контейнери, които съдържат .wcmc-card ---- */
[data-wcmc-cards][data-wcmc-layout="two"]{
  display:grid !important;
  grid-template-columns: repeat(2, minmax(0,1fr)) !important;
  gap: var(--wcmc-gap, 24px) !important;
}
[data-wcmc-cards][data-wcmc-layout="one"]{
  display:grid !important;
  grid-template-columns: 1fr !important;
  gap: var(--wcmc-gap, 20px) !important;
}

/* Картите да запълват колоната */
[data-wcmc-cards] > .wcmc-card{ width:100% !important; }


/* --- Button bottom-right on product card --- */
/* Картата е колона и заема цялата височина */
.wcmc-card{
  display:flex;
  flex-direction:column;
  height:100%;
}
.wcmc-card .wcmc-info{
  display:flex;
  flex-direction:column;
  gap:10px;
  flex:1 1 auto; /* избутва actions надолу */
}
.wcmc-card .wcmc-actions{
  margin-top:auto;            /* долу */
  display:flex;
  gap:12px;
  align-items:center;
  justify-content:flex-end;   /* вдясно */
  padding: 7px;
}
.wcmc-card .wcmc-actions .add_to_cart_button{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:40px; height:40px;
  padding:0;
}
.wcmc-card .wcmc-actions .add_to_cart_button img{
  display:block;
  max-width:100%;
  max-height:100%;
}
/* Когато има зададено изображение (клас се добавя в body), бутонът е само икона */
.wcmc-has-addimg .wcmc-card .add_to_cart_button,
.wcmc-has-addimg .wcmc-card .button.add_to_cart_button{
  padding:0 !important;
  width:40px; height:40px;
  background: var(--wcmc-addimg-url) no-repeat center / contain !important;
  color:transparent !important;
  border:none !important;
  line-height:0 !important;
  text-indent:-9999px;
  overflow:hidden;
  display:inline-flex;
  justify-content:center;
  align-items:center;
}
/* Премахва съобщение Добавено в количката */
.woocommerce-notices-wrapper .woocommerce-message { display:none !important; }
a.added_to_cart.wc-forward { display:none !important; }
/* Стил алергени */
.wcmc-card .wcmc-allergens{
  margin-top:6px;
  font-size: var(--wcmc-excerpt,14px);
  opacity: .85;
}
.wcmc-card .wcmc-allergens strong{
  font-weight: 600;
  margin-right: 4px;
}
