/* WRAPING responsive layout alignment. Applied only after a genuine left category tree is found. */
@media (min-width: 1025px) {
  body.wrp-tree-layout-active .wrp-tree-wide-shell {
    box-sizing: border-box !important;
    width: calc(100% - 40px) !important;
    max-width: 2040px !important;
    margin-left: auto !important;
    margin-right: auto !important;
  }
  body.wrp-tree-layout-active .wrp-tree-unlock-width {
    box-sizing: border-box !important;
    max-width: none !important;
    min-width: 0 !important;
    width: 100% !important;
  }
  body.wrp-tree-layout-active .wrp-tree-row {
    box-sizing: border-box !important;
    max-width: 100% !important;
    width: 100% !important;
    min-width: 0 !important;
    column-gap: clamp(18px, 1.6vw, 32px);
  }
  body.wrp-tree-layout-active .wrp-tree-sidebar {
    box-sizing: border-box !important;
    min-width: 190px !important;
    max-width: 255px !important;
  }
  body.wrp-tree-layout-active .wrp-tree-content {
    box-sizing: border-box !important;
    max-width: 100% !important;
    min-width: 0 !important;
    flex: 1 1 auto !important;
  }
  body.wrp-tree-layout-active .wrp-tree-content .products,
  body.wrp-tree-layout-active .wrp-tree-content .product-grid,
  body.wrp-tree-layout-active .wrp-tree-content .category-grid,
  body.wrp-tree-layout-active .wrp-tree-content .collection-grid,
  body.wrp-tree-layout-active .wrp-tree-content .subcategory-grid,
  body.wrp-tree-layout-active .wrp-tree-content .category-cards,
  body.wrp-tree-layout-active .wrp-tree-content .product-cards {
    max-width: 100% !important;
    min-width: 0 !important;
  }
  body.wrp-tree-layout-active .wrp-tree-content .products > *,
  body.wrp-tree-layout-active .wrp-tree-content .product-grid > *,
  body.wrp-tree-layout-active .wrp-tree-content .category-grid > *,
  body.wrp-tree-layout-active .wrp-tree-content .collection-grid > *,
  body.wrp-tree-layout-active .wrp-tree-content .subcategory-grid > *,
  body.wrp-tree-layout-active .wrp-tree-content .category-cards > * {
    box-sizing: border-box;
    min-width: 0;
    max-width: 100%;
  }
}

/* Let the theme handle the stacked / drawer sidebar on smaller screens. */
@media (max-width: 1024px) {
  body.wrp-tree-layout-active .wrp-tree-wide-shell,
  body.wrp-tree-layout-active .wrp-tree-unlock-width,
  body.wrp-tree-layout-active .wrp-tree-row,
  body.wrp-tree-layout-active .wrp-tree-sidebar,
  body.wrp-tree-layout-active .wrp-tree-content {
    width: revert-layer;
    max-width: revert-layer;
    min-width: revert-layer;
    flex: revert-layer;
  }
}
