/* Mobile refinements for the existing Elementor/Astra layout. */
@media (max-width: 767px) {
  body.home.home.home .mf367-hero-title {
    font-size: clamp(28px, 8vw, 34px) !important;
    line-height: 1.08 !important;
    letter-spacing: -.6px !important;
    margin: 0 !important;
    overflow-wrap: normal !important;
  }
  body.home.home.home .mf367-subtitle {
    font-size: 16px !important;
    line-height: 1.35 !important;
    margin: 0 !important;
  }
  body.home.home .mf367-heading-widget {
    margin-top: 8px !important;
    margin-bottom: 10px !important;
    padding-top: 0 !important;
    padding-bottom: 0 !important;
  }
  body.home.home .maldiagro-hero-v18 p {
    font-size: 16px !important;
    line-height: 1.5 !important;
    margin-bottom: 12px !important;
  }
  body.home.home .maldiagro-hero-v18 .elementor-widget-button {
    margin-top: 12px !important;
    margin-bottom: 8px !important;
    padding-top: 0 !important;
    padding-bottom: 0 !important;
  }
  body.home.home .maldiagro-hero-v18 .elementor-button {
    min-height: 44px !important;
    padding: 14px 24px !important;
    font-size: 15px !important;
  }
  body.home.home .mf367-recommended-title {
    font-size: clamp(25px, 7vw, 30px) !important;
    line-height: 1.2 !important;
    margin: 0 !important;
  }
  body.home.home .maldiagro-recommended-v29[data-v341="1"] {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    align-items: stretch !important;
    gap: 12px !important;
    padding: 0 12px !important;
    margin-top: 8px !important;
  }
  body.home.home .maldiagro-recommended-v29[data-v341="1"] .maldiagro-rec-card-v29 {
    height: 100% !important;
    min-width: 0 !important;
    padding: 6px !important;
    box-sizing: border-box !important;
    transform: none !important;
  }
  body.home.home .maldiagro-recommended-v29[data-v341="1"] .maldiagro-rec-card-v29 a {
    min-width: 0 !important;
    flex: 1 !important;
  }
  body.home.home .maldiagro-recommended-v29[data-v341="1"] .maldiagro-rec-card-v29 img,
  body.home.home .maldiagro-recommended-v29[data-v341="1"] .maldiagro-rec-card-v29:hover img {
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
    aspect-ratio: 1 / 1 !important;
    object-fit: contain !important;
    object-position: center !important;
    transform: none !important;
    padding: 0 !important;
    margin: 0 0 10px !important;
    background: #fff !important;
    border-radius: 6px !important;
  }
  body.home.home .maldiagro-recommended-v29[data-v341="1"] .maldiagro-rec-title-v29 {
    font-size: 15px !important;
    line-height: 1.3 !important;
    min-height: 59px !important;
    margin: 0 !important;
    padding: 0 2px 6px !important;
    box-sizing: border-box !important;
    overflow-wrap: anywhere !important;
    align-items: flex-start !important;
  }
  body.home.home .maldiagro-rec-arrow-v340 {
    width: 44px !important;
    height: 44px !important;
  }
  body.home.home .maldiagro-rec-nav-v340 {
    margin: 12px auto !important;
  }
  body.home.home .maldiagro-rec-all-v338 {
    max-width: calc(100% - 32px) !important;
    box-sizing: border-box !important;
    min-height: 44px !important;
    font-size: 15px !important;
    padding: 14px 20px !important;
    margin: 12px auto 20px !important;
  }
  body.home.home .maldiagro-mobile-footer-v312 h3,
  body.home.home .maldiagro-footer-v22 h2,
  body.home.home .maldiagro-footer-v22 h3 {
    font-size: 24px !important;
    line-height: 1.2 !important;
    margin: 12px 0 8px !important;
  }
  body.home.home .maldiagro-mobile-footer-v312 .mf312-slogan,
  body.home.home .maldiagro-footer-slogan-v23 {
    font-size: 15px !important;
    line-height: 1.4 !important;
    max-width: 300px !important;
    margin: 8px auto 14px !important;
  }
  body.home.home .maldiagro-mobile-footer-v312 .mf312-nav a {
    padding: 10px 0 !important;
    line-height: 1.5 !important;
  }
}

/* v3.68: refinements grounded in the installed v3.67 screenshots. */
@media (max-width: 767px) {
  body.home.home .maldiagro-recommended-v29[data-v341="1"] .maldiagro-rec-card-v29 a {
    width: 100% !important;
    max-width: none !important;
    align-self: stretch !important;
    margin: 0 !important;
    padding: 0 !important;
    box-sizing: border-box !important;
  }
  body.home.home .maldiagro-recommended-v29[data-v341="1"] .maldiagro-rec-card-v29 img {
    align-self: center !important;
    margin-left: auto !important;
    margin-right: auto !important;
  }
  body.home.home .mf368-hero .elementor-widget-spacer {
    display: none !important;
  }
  body.home.home .mf368-button-path {
    min-height: 0 !important;
    height: auto !important;
    margin-top: 0 !important;
    margin-bottom: 0 !important;
    padding-top: 0 !important;
    padding-bottom: 0 !important;
    --min-height: 0px !important;
    --gap: 0px !important;
    row-gap: 0 !important;
  }
  body.home.home .mf368-hero .elementor-widget-button.mf368-button-path {
    margin-top: 16px !important;
    margin-bottom: 12px !important;
  }
  body.woocommerce-shop.woocommerce-shop #primary,
  body.tax-product_cat.tax-product_cat #primary {
    margin-top: 18px !important;
    padding-top: 0 !important;
  }
  body.woocommerce-shop.woocommerce-shop .site-content,
  body.tax-product_cat.tax-product_cat .site-content,
  body.woocommerce-shop.woocommerce-shop .ast-woocommerce-container,
  body.tax-product_cat.tax-product_cat .ast-woocommerce-container {
    padding-top: 0 !important;
  }
  body.woocommerce-shop.woocommerce-shop .woocommerce-breadcrumb,
  body.tax-product_cat.tax-product_cat .woocommerce-breadcrumb {
    margin: 0 0 12px !important;
    font-size: 13px !important;
    line-height: 1.4 !important;
  }
  body.woocommerce-shop.woocommerce-shop .woocommerce-products-header,
  body.tax-product_cat.tax-product_cat .woocommerce-products-header {
    margin: 0 0 18px !important;
    padding: 0 !important;
  }
  body.woocommerce-shop.woocommerce-shop .woocommerce-products-header__title,
  body.tax-product_cat.tax-product_cat .woocommerce-products-header__title {
    font-size: 30px !important;
    line-height: 1.15 !important;
    margin: 0 !important;
  }
  body.single-product.single-product div.product .summary .product_title {
    font-size: 28px !important;
    line-height: 1.15 !important;
    letter-spacing: -.3px !important;
    margin: 0 0 12px !important;
  }
  body.single-product.single-product .summary .woocommerce-breadcrumb {
    font-size: 13px !important;
    line-height: 1.4 !important;
    margin-bottom: 12px !important;
  }
  body.single-product.single-product .woocommerce-product-details__short-description p {
    font-size: 16px !important;
    line-height: 1.5 !important;
  }
  body .mf368-footer-heading.mf368-footer-heading {
    font-size: 24px !important;
    line-height: 1.2 !important;
    margin: 8px 0 !important;
  }
  body .mf368-footer-widget.mf368-footer-widget {
    margin-top: 0 !important;
    margin-bottom: 8px !important;
    padding-top: 0 !important;
    padding-bottom: 0 !important;
  }
}

/* v3.69: neutralize legacy horizontal cards and contact-link display rules. */
@media (max-width: 767px) {
  body.home.home .maldiagro-recommended-v29[data-v341="1"] .maldiagro-rec-card-v29 {
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    grid-template-columns: none !important;
    gap: 0 !important;
  }
  body .maldiagro-mobile-footer-v312 .mf312-contact .mf312-social a {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    flex: 0 0 40px !important;
    width: 40px !important;
    height: 40px !important;
    margin: 0 !important;
    padding: 0 !important;
    box-sizing: border-box !important;
    line-height: 1 !important;
  }
  body .maldiagro-mobile-footer-v312 .mf312-contact .mf312-social a svg {
    display: block !important;
    position: static !important;
    width: 18px !important;
    height: 18px !important;
    margin: 0 !important;
    flex: none !important;
  }
}

/* v3.70: stronger contrast for mobile navigation. */
@media (max-width: 921px) {
  body .ast-mobile-popup-drawer .main-header-menu .menu-item > a,
  body .ast-mobile-popup-drawer .ast-nav-menu .menu-item > a,
  body .ast-builder-menu-mobile .main-header-menu .menu-item > a {
    color: #356b24 !important;
  }
  body .ast-mobile-popup-drawer .main-header-menu .menu-item > a:hover,
  body .ast-builder-menu-mobile .main-header-menu .menu-item > a:hover {
    color: #244d18 !important;
  }
}
