/* INFOCAP V2.14.0 - Solo integración del carrito en la portada API. */
#featured-catalog .program-card-actions .cart-v211-add {
  flex: 1 1 100%; width: 100%; cursor: pointer;
  border: 1px solid #217251; background: #ecf6f0; color: #103c30;
  border-radius: 9px; padding: 11px 13px; font: inherit;
  font-weight: 700; line-height: 1.35; min-height: 44px;
}
#featured-catalog .program-card-actions .cart-v211-add:hover,
#featured-catalog .program-card-actions .cart-v211-add:focus-visible { background: #dcefe3; }
#featured-catalog .program-card-actions .cart-v211-add.is-added {
  background: #e1f2e7; border-color: #8dbba1;
}
#featured-catalog .program-card-actions .inicio-v214-cart-state {
  display: block; flex: 1 1 100%; color: #1c6647; font-size: .8rem;
}
#featured-catalog .program-card-actions .inicio-v214-cart-state:empty { display: none; }
/* El módulo existente genera el enlace flotante Mi selección. */
body:has(#featured-catalog) .cart-v211-floating {
  position: fixed; right: 18px; bottom: 18px; z-index: 100;
  display: inline-flex; align-items: center; gap: 9px;
  background: #113d30; color: #fff; border: 1px solid #d6eadc;
  border-radius: 999px; box-shadow: 0 8px 25px rgba(0,0,0,.18);
  padding: 12px 17px; text-decoration: none; font-size: .9rem; font-weight: 700;
}
body:has(#featured-catalog) .cart-v211-floating .cart-v211-count {
  background: #e9c78c; color: #143c31; padding: 1px 7px;
  min-width: 25px; text-align: center; border-radius: 999px;
}
@media (max-width: 640px) {
  body:has(#featured-catalog) .cart-v211-floating { right: 12px; bottom: 12px; }
}
@media (prefers-reduced-motion: reduce) { #featured-catalog .cart-v211-add { transition: none; } }

/* V2.14.1: acciones de portada en filas independientes, sin superposicion. */
#featured-catalog .program-card-actions {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) !important;
  grid-auto-rows: auto !important;
  gap: 9px !important;
  align-items: stretch !important;
  height: auto !important;
  min-height: 0 !important;
  overflow: visible !important;
  position: relative;
}
#featured-catalog .program-card-actions > .program-card-primary,
#featured-catalog .program-card-actions > .program-card-secondary {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  position: static !important;
  width: auto !important;
  min-width: 0 !important;
  height: auto !important;
  min-height: 43px;
  margin: 0 !important;
  inset: auto !important;
  transform: none !important;
  text-align: center;
}
#featured-catalog .program-card-actions > .cart-v211-add {
  grid-column: 1 / -1 !important;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  position: static !important;
  width: 100% !important;
  min-width: 0 !important;
  height: auto !important;
  margin: 0 !important;
  inset: auto !important;
  transform: none !important;
  white-space: normal;
  text-align: center;
}
/* La confirmacion sigue accesible a lectores de pantalla, sin ocupar espacio visual. */
#featured-catalog .program-card-actions > .inicio-v214-cart-state {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  border: 0 !important;
  overflow: hidden !important;
  clip-path: inset(50%) !important;
  white-space: nowrap !important;
}
@media (max-width: 360px) {
  #featured-catalog .program-card-actions { grid-template-columns: minmax(0,1fr) !important; }
  #featured-catalog .program-card-actions > .cart-v211-add { grid-column: 1; }
}

/* V2.14.2: confirmacion flotante sin superponer los botones.
   Se mantiene el mismo nombre, mensaje y duracion que el catalogo. */
body:has(#featured-catalog) #cart-v211-toast:not([hidden]) {
  display: block;
  position: fixed;
  z-index: 999;
  left: 50%;
  bottom: 82px;
  transform: translateX(-50%);
  width: max-content;
  max-width: min(92vw, 520px);
  box-sizing: border-box;
  padding: 12px 18px;
  background: #153e32;
  color: #fff;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 10px;
  box-shadow: 0 12px 36px rgba(0,0,0,.2);
  font-size: .87rem;
  line-height: 1.45;
  text-align: center;
  pointer-events: none;
}
body:has(#featured-catalog) #cart-v211-toast.warning:not([hidden]) {
  background: #7d2d2d;
}
body:has(#featured-catalog) #cart-v211-toast[hidden] { display: none !important; }
@media (max-width: 640px) {
  body:has(#featured-catalog) #cart-v211-toast:not([hidden]) {
    bottom: 78px;
    width: max-content;
    max-width: calc(100vw - 28px);
  }
}
