/* The page tree is generated by the product block; leave its hierarchy intact. */
.berner-products-list-with-sidenav:not(:has(.desktop-category-tree .page_item)) .panel-sub-filters,
.berner-products-list-with-sidenav:not(:has(.desktop-category-tree .page_item)) .products-list-header {
    display: none !important;
}

.block.berner-products-list-with-sidenav {
    --product-card-title-color: var(--text-color, #262626);
    --product-card-category-color: var(--text-color, #046a38);
    --product-card-variation-color: var(--color-text-subtle, #737373);
    --product-card-tag-color: #046a38;
    --product-card-tag-bg: #fff;
    --pagination-item-color: var(--text-color, #262626);
    --pagination-accent: var(--text-color, #046a38);
    --pagination-border: var(--color-text-subtle, #e5e5e5);
    --sub-menu-lvl-1-link-color: var(--text-color, #262626);
    --sub-menu-default-link-color: var(--text-color, #262626);
    --sub-menu-expanded-color: var(--text-color, #046a38);
    --category-tree-border-color: var(--color-text-subtle, #e5e5e5);
}

.berner-products-list-with-sidenav .product-card {
    display: block;
    text-decoration: none;
}

.berner-products-list-with-sidenav .product-card .image-wrapper {
    border-radius: 8px;
    background: #f5f5f5;
}

.berner-products-list-with-sidenav .product-card .tags {
    width: auto;
    max-width: calc(100% - 16px);
}

.berner-products-list-with-sidenav .product-card .tag {
    border: 1px solid #f5f5f5;
}

.berner-products-list-with-sidenav .product-card .card-content {
    padding-top: 12px;
}

.berner-products-list-with-sidenav .product-card .post-title {
    margin: 0 0 8px;
    font-size: 16px;
    line-height: 1.35;
}

.berner-products-list-with-sidenav .product-category-tree ul,
.berner-products-list-with-sidenav .VuePagination__pagination,
body > .panel-sub-filters-mobile .product-category-tree ul {
    margin: 0;
    list-style: none;
}

.berner-products-list-with-sidenav .product-category-tree .page-tree,
.berner-products-list-with-sidenav .VuePagination__pagination,
body > .panel-sub-filters-mobile .product-category-tree .page-tree {
    padding: 0;
}

.berner-products-list-with-sidenav .VuePagination button:focus-visible {
    outline: 2px solid var(--pagination-item-color);
    outline-offset: 2px;
}

.berner-products-list-with-sidenav .VuePagination button:disabled {
    opacity: 0.5;
}

/* The mobile panel is teleported outside the block and has a white background. */
body > .panel-sub-filters-mobile:has(.mobile-category-tree) {
    --sub-menu-lvl-1-link-color: #262626;
    --sub-menu-default-link-color: #262626;
    --sub-menu-expanded-color: #046a38;
    color: #262626;
}
