/* ARIAN v16 — precision cleanup after v15
 * Mobile cards are rebuilt as equal fixed geometry.
 * v14/v15 mobile styles are dequeued by functions.php.
 */

/* RAW MATERIALS — all widths: full v11 artwork, larger, no clipping. */
#products-raw-materials .apm-raw-media {
  position: relative !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 164px !important;
  height: 108px !important;
  flex: 0 0 108px !important;
  max-width: 78% !important;
  margin: 0 auto !important;
  padding: 0 !important;
  overflow: visible !important;
}

#products-raw-materials .apm-raw-media::before,
#products-raw-materials .apm-raw-media::after {
  content: none !important;
  display: none !important;
}

#products-raw-materials .apm-raw-media .df-img,
#products-raw-materials .apm-raw-media .on-hover {
  inset: auto !important;
  width: 100% !important;
  height: 100% !important;
  max-width: 100% !important;
  max-height: 100% !important;
  margin: 0 !important;
  padding: 0 !important;
  object-fit: contain !important;
  object-position: center center !important;
  background: transparent !important;
}

@media (max-width: 767px) {
  .c-section--products .o-section__wrapper {
    padding-left: 14px !important;
    padding-right: 14px !important;
  }

  /* ---------- STRUCTURE: exactly 2 equal columns ---------- */
  #products-structure .tabs-content {
    width: 100% !important;
    height: auto !important;
    aspect-ratio: auto !important;
    padding: 0 !important;
  }

  #products-structure .tabs {
    display: grid !important;
    grid-template-columns: repeat(2, 160px) !important;
    justify-content: center !important;
    align-items: start !important;
    gap: 22px 12px !important;
    width: 100% !important;
    height: auto !important;
    margin: 0 !important;
    padding: 0 !important;
  }

  #products-structure .tabs .tab,
  #products-structure .tabs .tab:nth-child(1),
  #products-structure .tabs .tab:nth-child(2),
  #products-structure .tabs .tab:nth-child(3),
  #products-structure .tabs .tab:nth-child(4),
  #products-structure .tabs .tab:nth-child(5) {
    display: block !important;
    width: 160px !important;
    min-width: 160px !important;
    max-width: 160px !important;
    height: 176px !important;
    min-height: 176px !important;
    max-height: 176px !important;
    margin: 0 !important;
    padding: 0 !important;
    transform: none !important;
    justify-self: center !important;
  }

  #products-structure .tab .home-services__item {
    width: 160px !important;
    min-width: 160px !important;
    max-width: 160px !important;
    height: 176px !important;
    min-height: 176px !important;
    max-height: 176px !important;
    margin: 0 !important;
    padding: 0 !important;
    aspect-ratio: auto !important;
    overflow: visible !important;
  }

  #products-structure .home-services__item > div {
    position: relative !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: flex-start !important;
    width: 100% !important;
    height: 100% !important;
    min-height: 176px !important;
    box-sizing: border-box !important;
    padding: 15px 8px 12px !important;
    gap: 5px !important;
    overflow: visible !important;
  }

  #products-structure .home-services__item > div::before {
    top: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    left: 0 !important;
    background-size: 100% 100% !important;
    background-position: center !important;
    background-repeat: no-repeat !important;
  }

  #products-structure .tabs .tab img {
    display: block !important;
    position: static !important;
    width: 78px !important;
    height: 58px !important;
    min-width: 0 !important;
    max-width: 78px !important;
    max-height: 58px !important;
    margin: 0 auto !important;
    padding: 0 !important;
    object-fit: contain !important;
    object-position: center !important;
    opacity: 1 !important;
    transform: none !important;
  }

  /* ---------- USAGE + RAW: exactly 2 equal columns ---------- */
  #products-usage .c-products-usage-content > ul,
  #products-raw-materials .c-products-usage-content > ul {
    display: grid !important;
    grid-template-columns: repeat(2, 160px) !important;
    justify-content: center !important;
    align-items: start !important;
    gap: 22px 12px !important;
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
  }

  #products-usage .home-services__item,
  #products-raw-materials .home-services__item {
    width: 160px !important;
    min-width: 160px !important;
    max-width: 160px !important;
    height: 176px !important;
    min-height: 176px !important;
    max-height: 176px !important;
    margin: 0 !important;
    padding: 0 !important;
    aspect-ratio: auto !important;
    overflow: visible !important;
    background-size: 100% 100% !important;
    background-position: center !important;
    background-repeat: no-repeat !important;
  }

  #products-usage .home-services__item > a,
  #products-raw-materials .home-services__item > a {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: flex-start !important;
    width: 100% !important;
    height: 100% !important;
    min-height: 176px !important;
    box-sizing: border-box !important;
    padding: 16px 8px 12px !important;
    gap: 5px !important;
    overflow: visible !important;
  }

  #products-usage .home-services__item .on-hover,
  #products-raw-materials .home-services__item .on-hover {
    display: none !important;
  }

  #products-usage .home-services__item .df-img {
    display: block !important;
    position: static !important;
    width: 82px !important;
    height: 68px !important;
    min-width: 0 !important;
    max-width: 82px !important;
    max-height: 68px !important;
    margin: 0 auto !important;
    padding: 0 !important;
    object-fit: contain !important;
    object-position: center !important;
    opacity: 1 !important;
    transform: none !important;
    filter: none !important;
  }

  #products-raw-materials .apm-raw-media {
    width: 108px !important;
    height: 68px !important;
    flex: 0 0 68px !important;
    max-width: 108px !important;
    margin: 0 auto !important;
    overflow: visible !important;
  }

  #products-raw-materials .apm-raw-media .df-img {
    display: block !important;
    position: static !important;
    width: 108px !important;
    height: 68px !important;
    max-width: 108px !important;
    max-height: 68px !important;
    margin: 0 auto !important;
    object-fit: contain !important;
    object-position: center center !important;
    opacity: 1 !important;
    transform: none !important;
    filter: none !important;
  }

  /* ---------- TITLES: line in normal flow below text ---------- */
  #products-structure .home-services__item h2,
  #products-usage .home-services__item h2,
  #products-raw-materials .home-services__item h2 {
    position: static !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: flex-start !important;
    width: 100% !important;
    max-width: 130px !important;
    min-height: 0 !important;
    margin: 0 auto !important;
    padding: 0 !important;
    font-size: 10.5px !important;
    line-height: 1.38 !important;
    text-align: center !important;
    white-space: normal !important;
    word-break: normal !important;
    overflow-wrap: anywhere !important;
  }

  #products-structure .home-services__item h2::before,
  #products-usage .home-services__item h2::before,
  #products-raw-materials .home-services__item h2::before {
    content: none !important;
    display: none !important;
  }

  #products-structure .home-services__item h2::after,
  #products-usage .home-services__item h2::after,
  #products-raw-materials .home-services__item h2::after {
    content: "" !important;
    position: static !important;
    display: block !important;
    width: 30px !important;
    min-width: 30px !important;
    max-width: 30px !important;
    height: 2px !important;
    flex: 0 0 2px !important;
    margin: 6px auto 0 !important;
    padding: 0 !important;
    background: #FFD400 !important;
    border: 0 !important;
    border-radius: 2px !important;
    transform: none !important;
    left: auto !important;
    right: auto !important;
    top: auto !important;
    bottom: auto !important;
    box-shadow: none !important;
  }

  #products-structure .panes {
    margin-top: 24px !important;
    width: 100% !important;
  }
}

@media (max-width: 370px) {
  #products-structure .tabs,
  #products-usage .c-products-usage-content > ul,
  #products-raw-materials .c-products-usage-content > ul {
    grid-template-columns: repeat(2, 146px) !important;
    gap: 20px 8px !important;
  }

  #products-structure .tabs .tab,
  #products-structure .tabs .tab:nth-child(1),
  #products-structure .tabs .tab:nth-child(2),
  #products-structure .tabs .tab:nth-child(3),
  #products-structure .tabs .tab:nth-child(4),
  #products-structure .tabs .tab:nth-child(5),
  #products-structure .tab .home-services__item,
  #products-usage .home-services__item,
  #products-raw-materials .home-services__item {
    width: 146px !important;
    min-width: 146px !important;
    max-width: 146px !important;
    height: 161px !important;
    min-height: 161px !important;
    max-height: 161px !important;
  }

  #products-structure .home-services__item > div,
  #products-usage .home-services__item > a,
  #products-raw-materials .home-services__item > a {
    min-height: 161px !important;
    padding-left: 6px !important;
    padding-right: 6px !important;
  }

  #products-structure .home-services__item h2,
  #products-usage .home-services__item h2,
  #products-raw-materials .home-services__item h2 {
    max-width: 120px !important;
    font-size: 10px !important;
  }
}
