/* RAÍZ – Tienda y fichas de producto: margen entre el encabezado y el contenido */
@media (min-width: 922px) {
  .ast-theme-transparent-header.single-product #content,
  .ast-theme-transparent-header.woocommerce-shop #content,
  .ast-theme-transparent-header.tax-product_cat #content,
  .ast-theme-transparent-header.tax-product_tag #content { padding-top: 120px; }
  .woocommerce-shop #primary, .tax-product_cat #primary, .tax-product_tag #primary, .single-product #primary { margin-top: 80px; }
  .woocommerce-shop #secondary, .tax-product_cat #secondary, .tax-product_tag #secondary { margin-top: 80px; }
}

/* RAÍZ – Footer: contacto e información legal */
.site-footer .raiz-footer-title { color: #F8F5EE; font-size: 1rem; letter-spacing: .04em; text-transform: uppercase; margin: 0 0 14px; }
.site-footer .raiz-footer-list { list-style: none; margin: 0; padding: 0; }
.site-footer .raiz-footer-list li { margin: 0 0 8px; line-height: 1.5; color: #E8DDC9; font-size: .95rem; }
.site-footer .raiz-footer-list a { color: #E8DDC9; text-decoration: none; }
.site-footer .raiz-footer-list a:hover, .site-footer .raiz-footer-list a:focus { color: #FFFFFF; text-decoration: underline; }
@media (max-width: 921px) { .site-footer .raiz-footer-title { margin-top: 24px; } }

/* RAÍZ – Cotizador: botón para volver al inicio */
.raiz-volver-home { margin: 0 0 24px; }
.raiz-volver-home a { display: inline-flex; align-items: center; gap: 6px; padding: 10px 18px; border: 1px solid #59624A; border-radius: 4px; color: #59624A; font-weight: 600; text-decoration: none; }
.raiz-volver-home a:hover, .raiz-volver-home a:focus { background: #59624A; color: #FFFFFF; }

/* RAÍZ – Formulario de cotización (SureForms): mismo fondo que la web */
.srfm-form-container, .srfm-form-container.srfm-bg-color { background-color: #F8F5EE !important; box-shadow: none !important; }
body.single-sureforms_form, body.single-sureforms_form > div:not([class]) { background-color: #F8F5EE !important; }
.srfm-page-banner { background-color: #59624A !important; }
.srfm-form-container .srfm-input-common { background-color: #FFFFFF !important; border-color: #CFC6B4 !important; }
.srfm-form-container .srfm-input-common:focus, .srfm-form-container .srfm-input-common:focus-within { border-color: #59624A !important; box-shadow: 0 0 0 3px rgba(89, 98, 74, .18) !important; }
.srfm-form-container .srfm-submit-button { background-color: #A65F43 !important; border-color: #A65F43 !important; color: #FFFFFF !important; border-radius: 5px !important; }
.srfm-form-container .srfm-submit-button:hover, .srfm-form-container .srfm-submit-button:focus { background-color: #8E4F37 !important; border-color: #8E4F37 !important; }

/* RAÍZ – Home: encabezado legible sobre el hero a pantalla completa */
.home.ast-theme-transparent-header #masthead { background: linear-gradient(180deg, rgba(41, 40, 36, .55) 0%, rgba(41, 40, 36, 0) 100%); }
.home.ast-theme-transparent-header #masthead .main-header-menu > .menu-item > .menu-link,
.home.ast-theme-transparent-header #masthead .ast-site-header-cart .cart-container,
.home.ast-theme-transparent-header #masthead .ast-site-header-cart .ast-woo-header-cart-info-wrap,
.home.ast-theme-transparent-header #masthead .ast-header-account-link { color: #F8F5EE !important; }
.home.ast-theme-transparent-header #masthead .ast-site-header-cart svg,
.home.ast-theme-transparent-header #masthead .ast-header-account svg,
.home.ast-theme-transparent-header #masthead .ast-header-account-link svg { fill: #F8F5EE !important; color: #F8F5EE !important; }
.home.ast-theme-transparent-header #masthead .main-header-menu > .menu-item > .menu-link:hover,
.home.ast-theme-transparent-header #masthead .main-header-menu > .menu-item > .menu-link:focus { color: #E8DDC9 !important; text-decoration: underline; text-underline-offset: 6px; }
.srfm-form-container .srfm-submit-button { padding: 17px 34px !important; font-size: 14px !important; font-weight: 600 !important; letter-spacing: .5px; }
.raiz-volver-home:last-child { margin-top: 40px; }
.raiz-volver-home a + a { margin-left: 8px; }

/* RAÍZ – Encabezado fijo: visible al hacer scroll en todo el sitio */
#masthead { position: sticky; top: 0; z-index: 999; transition: background-color .25s ease, box-shadow .25s ease; }
.ast-theme-transparent-header #masthead { position: fixed; top: 0; left: 0; right: 0; }
.admin-bar #masthead { top: 32px; }
@media (max-width: 782px) { .admin-bar #masthead { top: 46px; } }
@media (max-width: 600px) { .admin-bar #masthead { top: 0; } }
body.raiz-scrolled #masthead { box-shadow: 0 2px 14px rgba(41, 40, 36, .10); }
body.raiz-scrolled.ast-theme-transparent-header #masthead,
body.raiz-scrolled.ast-theme-transparent-header #masthead .main-header-bar { background: #F8F5EE !important; }
body.home.raiz-scrolled.ast-theme-transparent-header #masthead .main-header-menu > .menu-item > .menu-link { color: #292824 !important; }
body.home.raiz-scrolled.ast-theme-transparent-header #masthead .main-header-menu > .menu-item > .menu-link:hover,
body.home.raiz-scrolled.ast-theme-transparent-header #masthead .main-header-menu > .menu-item > .menu-link:focus { color: #59624A !important; }
body.home.raiz-scrolled.ast-theme-transparent-header #masthead .ast-site-header-cart .cart-container,
body.home.raiz-scrolled.ast-theme-transparent-header #masthead .ast-site-header-cart .ast-woo-header-cart-info-wrap,
body.home.raiz-scrolled.ast-theme-transparent-header #masthead .ast-header-account-link { color: #59624A !important; }
body.home.raiz-scrolled.ast-theme-transparent-header #masthead .ast-site-header-cart svg,
body.home.raiz-scrolled.ast-theme-transparent-header #masthead .ast-header-account svg,
body.home.raiz-scrolled.ast-theme-transparent-header #masthead .ast-header-account-link svg { fill: #59624A !important; color: #59624A !important; }

/* ===== RAÍZ – Ajustes de auditoría visual (nov 2026) ===== */

/* Fondo crema global: elimina las franjas blancas antes del footer */
body:not(.cartflows_step-template) { background-color: #F8F5EE !important; }

/* Carrito y Mi cuenta: el título quedaba tapado por el encabezado fijo */
.woocommerce-cart.ast-theme-transparent-header #primary,
.woocommerce-account.ast-theme-transparent-header #primary { margin-top: 150px; }
@media (max-width: 921px) {
  .woocommerce-cart.ast-theme-transparent-header #primary,
  .woocommerce-account.ast-theme-transparent-header #primary { margin-top: 110px; }
}

/* Home – tarjetas de categorías: la imagen ya no tapa el texto y los botones quedan alineados */
.elementor-element-016cbfd::before,
.elementor-element-6cb5657::before,
.elementor-element-620b583::before {
  -webkit-mask-image: linear-gradient(to bottom, transparent 30%, #000 65%);
  mask-image: linear-gradient(to bottom, transparent 30%, #000 65%);
  opacity: .6 !important;
}
.elementor-element-d349891 .elementor-image-box-title { margin-bottom: 8px !important; }
.elementor-element-d349891 .elementor-widget-image-box > .elementor-widget-container { padding-top: 0 !important; }
@media (min-width: 1025px) {
  .elementor-element-d349891 .elementor-widget-image-box { min-height: 100px; }
}
@media (max-width: 1024px) {
  .elementor-element-d349891, .elementor-element-d349891 > .e-con-inner { row-gap: 20px; }
}

/* Productos en grilla de 2 columnas en mobile (home y tienda) */
@media (max-width: 544px) {
  .woocommerce ul.products, .woocommerce-page ul.products,
  .woocommerce ul.products[class*="columns-"], .woocommerce-page ul.products[class*="columns-"] {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    column-gap: 14px !important; row-gap: 28px !important;
  }
  .woocommerce ul.products li.product, .woocommerce-page ul.products li.product { width: 100% !important; margin: 0 !important; }
  .woocommerce ul.products li.product .woocommerce-loop-product__title { font-size: 15px; line-height: 1.3; }
  .woocommerce ul.products li.product .ast-woo-product-category { font-size: 11px; }
}

/* Logos de productores: 3 por fila en mobile */
@media (max-width: 767px) {
  .elementor-element-5f11061 .gallery { display: grid !important; grid-template-columns: repeat(3, 1fr); gap: 18px 12px; align-items: center; }
  .elementor-element-5f11061 .gallery-item { width: auto !important; max-width: none !important; margin: 0 !important; padding: 0 !important; }
  .elementor-element-5f11061 .gallery-item img { max-height: 70px; width: auto; margin: 0 auto; }
}

/* Preguntas frecuentes: interlineado legible */
.elementor-toggle .elementor-toggle-title { line-height: 1.45 !important; }

/* Footer: botón de arrepentimiento centrado en mobile */
@media (max-width: 921px) { .site-footer .wp-block-buttons { justify-content: center; } }

/* Ficha de producto: ocultar "Relacionado" de Jetpack (ya está "Productos relacionados") */
.single-product #jp-relatedposts { display: none !important; }

/* Tienda: montos del filtro de precio completos */
#secondary .wc-block-components-price-slider__amount { width: 100px !important; max-width: 100px !important; font-size: 14px !important; }

/* Checkout (CartFlows): colores de marca en lugar del verde */
.wcf-embed-checkout-form { --wcf-primary-color: #A65F43 !important; --wcf-btn-bg-color: #A65F43 !important; }
body.cartflows_step-template #place_order,
body.cartflows_step-template .wcf-submit-coupon,
body.cartflows_step-template .instant-checkout-batch { background-color: #A65F43 !important; border-color: #A65F43 !important; }
body.cartflows_step-template #place_order:hover,
body.cartflows_step-template .wcf-submit-coupon:hover { background-color: #8E4F37 !important; border-color: #8E4F37 !important; }
body.cartflows_step-template .payment_box { border-color: #A65F43 !important; }
body.cartflows_step-template input[type="radio"]:checked { background-color: #A65F43 !important; accent-color: #A65F43; }


/* Checkout: ocultar casilla de newsletter de MailPoet (MailPoet no está configurado y el texto sale en inglés) */
label:has(> #mailpoet_woocommerce_checkout_optin), #mailpoet_woocommerce_checkout_optin_field { display: none !important; }


/* Footer: fondo marrón oscuro de la paleta en lugar de negro puro */
.site-footer .site-primary-footer-wrap,
.site-footer .site-below-footer-wrap { background-color: #292824 !important; }
.site-footer .site-below-footer-wrap { border-top: 1px solid rgba(232, 221, 201, .15); }
.site-footer .widget_nav_menu .menu { list-style: none; margin: 0; padding: 0; }
.site-footer .widget_nav_menu .menu li { margin: 0 0 8px; }

/* Tienda en mobile: buscador y categorías justo debajo del título "Productos"; el resto de la barra lateral va debajo de los productos */
@media (max-width: 921px) {
  .woocommerce-shop #content > .ast-container, .tax-product_cat #content > .ast-container, .tax-product_tag #content > .ast-container { display: flex !important; flex-direction: column; }
  .woocommerce-shop #primary, .tax-product_cat #primary, .tax-product_tag #primary, .woocommerce-shop #primary > .site-main, .tax-product_cat #primary > .site-main, .tax-product_tag #primary > .site-main, .woocommerce-shop .ast-woocommerce-container, .tax-product_cat .ast-woocommerce-container, .tax-product_tag .ast-woocommerce-container,
  .woocommerce-shop #secondary, .tax-product_cat #secondary, .tax-product_tag #secondary, .woocommerce-shop #secondary .sidebar-main, .tax-product_cat #secondary .sidebar-main, .tax-product_tag #secondary .sidebar-main, .woocommerce-shop #secondary .sidebar-main > div, .tax-product_cat #secondary .sidebar-main > div, .tax-product_tag #secondary .sidebar-main > div { display: contents; }
  .woocommerce-shop .ast-woocommerce-container > *, .tax-product_cat .ast-woocommerce-container > *, .tax-product_tag .ast-woocommerce-container > * { order: 5; }
  .woocommerce-shop .woocommerce-breadcrumb, .tax-product_cat .woocommerce-breadcrumb, .tax-product_tag .woocommerce-breadcrumb { order: 1; margin-top: 40px; }
  .woocommerce-shop .woocommerce-products-header, .tax-product_cat .woocommerce-products-header, .tax-product_tag .woocommerce-products-header { order: 2; }
  .woocommerce-shop #secondary .widget, .tax-product_cat #secondary .widget, .tax-product_tag #secondary .widget { order: 6; width: 100%; }
  .woocommerce-shop #secondary .widget_search, .tax-product_cat #secondary .widget_search, .tax-product_tag #secondary .widget_search { order: 3; margin: 0 0 24px; }
  #secondary .widget_search .wp-block-search__label { display: none; }
  #secondary .widget_search .wp-block-search__input { flex: 1; min-width: 0; }
  .woocommerce-shop #secondary .widget:has(.wc-block-product-categories), .tax-product_cat #secondary .widget:has(.wc-block-product-categories), .tax-product_tag #secondary .widget:has(.wc-block-product-categories) { order: 4; margin: 0 0 24px; }
  #secondary .wc-block-product-categories-list { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 !important; padding: 0 !important; list-style: none; }
  #secondary .wc-block-product-categories-list > li { margin: 0 !important; padding: 0 !important; }
  #secondary .wc-block-product-categories-list > li > a { display: inline-block; padding: 6px 12px; border: 1px solid #59624A; border-radius: 999px; color: #59624A; font-size: 14px; line-height: 1.3; text-decoration: none; }
  #secondary .wc-block-product-categories-list .wc-block-product-categories-list-item-count { display: none; }
}


/* Checkout: títulos en tipo oración ("Detalles de facturación", no "Detalles De Facturación") */
body.cartflows_step-template .wcf-embed-checkout-form h3 { text-transform: none !important; }

/* Footer: título "Navegación" alineado con las otras columnas */
.site-footer #block-22 { margin-bottom: 0; }
