/* =========================================================
   BIA WooCommerce — personalización de colores
   Footer y botones en verde institucional #628C5B
   ========================================================= */

/* ─── Footer ─── */
.site-primary-footer-wrap[data-section="section-primary-footer-builder"],
.site-below-footer-wrap[data-section="section-below-footer-builder"] {
  background-color: #628C5B !important;
  background-image: none !important;
}

.site-primary-footer-wrap[data-section="section-primary-footer-builder"] {
  border-top: none !important;
}

.site-below-footer-wrap[data-section="section-below-footer-builder"] {
  border-top-color: rgba(255, 255, 255, .15) !important;
}

/* Texto del footer */
.site-footer .widget-title,
.site-footer h1,
.site-footer h2,
.site-footer h3,
.site-footer h4,
.site-footer h5,
.site-footer h6,
.ast-footer-copyright {
  color: #ffffff !important;
}

.site-footer a {
  color: #ffffff !important;
}

/* ─── Botones WooCommerce ─── */
.woocommerce-js a.button,
.woocommerce button.button,
.woocommerce .woocommerce-message a.button,
.woocommerce #respond input#submit.alt,
.woocommerce input.button.alt,
.woocommerce input.button,
.woocommerce input.button:disabled,
.woocommerce input.button:disabled[disabled],
.woocommerce input.button:disabled:hover,
.woocommerce input.button:disabled[disabled]:hover,
.woocommerce #respond input#submit,
.woocommerce button.button.alt.disabled,
.woocommerce button.button.alt.disabled.wc-variation-selection-needed,
.wc-block-grid__products .wc-block-grid__product .wp-block-button__link,
[CLASS*="wc-block"] button,
[CLASS*="wc-block"] .wc-block-components-button,
.wc-block-grid__product-onsale,
.woocommerce-js .astra-cart-drawer .astra-cart-drawer-content .woocommerce-mini-cart__buttons .button:not(.checkout):not(.ast-continue-shopping),
.woocommerce-js .astra-cart-drawer .astra-cart-drawer-content .woocommerce-mini-cart__buttons a.checkout {
  background-color: #628C5B !important;
  border-color: #628C5B !important;
  color: #ffffff !important;
}

/* Hover */
.woocommerce-js a.button:hover,
.woocommerce button.button:hover,
.woocommerce .woocommerce-message a.button:hover,
.woocommerce #respond input#submit:hover,
.woocommerce #respond input#submit.alt:hover,
.woocommerce input.button.alt:hover,
.woocommerce input.button:hover,
.woocommerce button.button.alt.disabled:hover,
.wc-block-grid__products .wc-block-grid__product .wp-block-button__link:hover,
[CLASS*="wc-block"] button:hover,
[CLASS*="wc-block"] .wc-block-components-button:hover,
[CLASS*="wc-block"] .wc-block-components-button:focus,
.woocommerce-js .astra-cart-drawer .astra-cart-drawer-content .woocommerce-mini-cart__buttons .button:not(.checkout):not(.ast-continue-shopping):hover,
.woocommerce-js .astra-cart-drawer .astra-cart-drawer-content .woocommerce-mini-cart__buttons a.checkout:hover {
  background-color: #4F7248 !important;
  border-color: #4F7248 !important;
  color: #ffffff !important;
}

/* Enlaces "Añadir al carrito" en productos (variantes de botón) */
.woocommerce ul.products li.product .button,
.woocommerce a.added_to_cart {
  background-color: #628C5B !important;
  color: #ffffff !important;
}

.woocommerce ul.products li.product .button:hover,
.woocommerce a.added_to_cart:hover {
  background-color: #4F7248 !important;
  color: #ffffff !important;
}

/* Precio / descuento y "sale" */
.woocommerce span.onsale {
  background-color: #628C5B !important;
  color: #ffffff !important;
}

/* =========================================================
   BIA — Carrusel de productos relacionados en el carrito
   ========================================================= */
.bia-cart-related {
  margin: 48px 0 8px;
  padding: 28px 0 8px;
  border-top: 1px solid rgba(0, 0, 0, .08);
}

.bia-cart-related__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.bia-cart-related__title {
  font-family: 'Outfit', sans-serif;
  font-size: 24px;
  font-weight: 600;
  color: #243446;
  margin: 0;
  line-height: 1.2;
}

.bia-cart-related__nav {
  display: flex;
  gap: 8px;
}

.bia-cart-related__btn {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 1px solid rgba(0, 0, 0, .12);
  background: #ffffff;
  color: #243446;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background-color .2s ease, color .2s ease, border-color .2s ease;
}

.bia-cart-related__btn:hover {
  background: #628C5B;
  border-color: #628C5B;
  color: #ffffff;
}

/* Pista con scroll horizontal */
.bia-cart-related__track {
  overflow-x: auto;
  overflow-y: hidden;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
  padding-bottom: 12px;
}

.bia-cart-related__track::-webkit-scrollbar {
  height: 8px;
}

.bia-cart-related__track::-webkit-scrollbar-thumb {
  background: rgba(0, 0, 0, .18);
  border-radius: 8px;
}

/* El grid de WooCommerce se convierte en fila de tarjetas */
.bia-cart-related__grid.woocommerce ul.products,
.bia-cart-related .woocommerce ul.products {
  display: flex !important;
  flex-wrap: nowrap !important;
  gap: 18px;
  margin: 0 !important;
  padding: 0 !important;
}

.bia-cart-related__grid.woocommerce ul.products::before,
.bia-cart-related__grid.woocommerce ul.products::after {
  display: none !important;
}

.bia-cart-related__grid.woocommerce ul.products li.product,
.bia-cart-related .woocommerce ul.products li.product {
  flex: 0 0 260px !important;
  width: 260px !important;
  max-width: 260px !important;
  margin: 0 !important;
  float: none !important;
  clear: none !important;
}

/* Ajuste en carrito vacío para separar del mensaje */
.bia-cart-related--empty {
  margin-top: 36px;
}

@media (max-width: 768px) {
  .bia-cart-related__grid.woocommerce ul.products li.product,
  .bia-cart-related .woocommerce ul.products li.product {
    flex-basis: 200px !important;
    width: 200px !important;
    max-width: 200px !important;
  }
  .bia-cart-related__title {
    font-size: 20px;
  }
}
