.filter-group[data-taxonomy="parametr_fizykochemiczny"] {
	display: none;
}

@media (min-width: 781px) {
	.product-list-tree .product-filters-container {
		grid-template-columns: repeat(3, 1fr)!important;
	}

	.product-list-tree .product-filters-container .product-search {
		grid-column: span 3!important;
	}
}


.product-list-category-tree {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(16rem, 100%), 1fr));
    container-type: inline-size;
    gap: 24px;
}

.product-list-tree .initial-message {
	margin-left: 64px;
}

.product-list-tree .product-search {
	display: none!important;
}

/* General layout for columns */
.category-tree {
    display: flex;
    gap: 10px;
    margin-bottom: 24px;
	margin-left: 64px;
}

@media (max-width: 780px) {
	.category-tree {
		margin-left: 0;
	}
	.product-list-tree .initial-message {
		margin-left: 0;
	}
}

/* Columns */
.category-column {
    display: none;
    flex-direction: column;
    gap: 5px;
    border-left: 1px solid #ddd;
    flex-basis: 25%;
    max-height: 200px;
    overflow-y: auto
}

.category-column.level-1 {
    display: flex;
}

/* Category item */
.category-level {
    position: relative;
    padding: 0 12px;
    cursor: pointer;
    color: #333;
    font-size: 14px;
    transition: color 0.3s, font-weight 0.3s;
}

.category-level .category-name {
    border-bottom: 1px solid #ddd;
    width: 100%;
    display: block;
    padding: 2px 17px 2px 0;
}

/* Highlight selected categories */
.category-level.selected {
    color: #d20000;
}

/* Add red line to the left of the first column's selected category */
.category-column.level-1 .category-level.selected {
    border-left: 2px solid #d20000;
}

/* Expand button */
.category-level .expand-btn {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1em;
    color: #333;
    transition: color 0.3s;
}

.category-level .expand-btn:hover {
    color: #d20000;
}

.selected-category-title {
    margin-bottom: 24px;
}

.product-filters-container {
    margin-bottom: 24px;
}

.filter-buttons {
    margin-bottom: 24px!important;
}

#loading-indicator {
    width: 48px;
    height: 48px;
    border: 8px solid #333;
    border-radius: 30px;
    margin: 12px auto;
    position: relative;
}

#loading-indicator::after {
    content: '';
    width: 48px;
    height: 48px;
    border: 8px solid var(--wp--preset--color--red);
    border-top-color: transparent; /* Make the top border transparent */
    border-radius: 50%; /* Use 50% to make a perfect circle */
    display: block;
    position: absolute;
    top: -8px;
    left: -8px;
    animation: spin 1s linear infinite; /* Apply the spinning animation */
    transform-origin: center center; /* Set the pivot point for rotation */
}

@keyframes spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

@media (max-width: 781px)  {
    .category-tree {
        overflow-x: scroll;
        scrollbar-color: #282828 #fff;
    }
    .category-column {
        min-width: 35vw;
    }
}

@media (max-width: 499px)  {
    .category-column {
        min-width: 75vw;
    }
}

/* Styl dla tytułów grup filtrów */
.filter-group-title {
    display: block;
    margin: 4px 0;
    font-weight: 500;
}

/* Zagnieżdżone listy dla hierarchicznych filtrów */
.nested-filter-list {
    list-style: none;
    padding-left: 0;
}

/* Styl dla elementów listy w zagnieżdżonych listach */
.nested-filter-list li {
    margin-bottom: 5px;
}

/* Upewnij się, że zagnieżdżone listy i ich elementy są wyświetlane poprawnie */
.nested-filter-list,
.nested-filter-list li {
    position: static;
    display: block;
}

/* Styl dla checkboxów w zagnieżdżonych filtrach */
.filter-group ul li label {
    display: flex;
    align-items: center;
}

.view-toggle {
  margin-bottom: 1em;
  text-align: right;
}
.view-toggle .view-btn {
  margin-right: .5em;
    padding: 0;
    cursor: pointer;
    border: 0;
    background: none;
}

.view-toggle .view-btn svg path {
    stroke: #282828;
    transition: all .3s ease-in-out;
}

.view-toggle .view-btn:hover svg path {
    stroke: #E62038;
}

.view-toggle .view-btn.active svg path {
    stroke: #E62038;
}

.product-list-table {
    overflow-x: auto;
}

.product-list-table table {
  width: 100%;
  border-collapse: collapse;
  min-width: 1024px;
}

.product-list-table thead tr {
    border: 1px solid #282828;
}

.product-list-table th,
.product-list-table td {
  border: 1px solid #282828;
  padding: .5em;
  text-align: left;
}

.product-list-table td {
    vertical-align: baseline;
}

.product-list-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px,1fr));
  gap: 1em;
}

.show-more-button {
    border-width: 0;
    font-family: var(--wp--preset--font-family--kanit);
    font-size: inherit;
    font-style: normal;
    font-weight: 300;
    padding: calc(0.667em + 2px) calc(1.333em + 2px);
    text-decoration: none;
    background-color: var(--wp--preset--color--base);
    border-radius: 0px;
    color: var(--wp--preset--color--background);
    line-height: 1;
    transition: all .3s ease-in-out;
}

.show-more-button:hover {
    background-color: #444;
    cursor: pointer;
}

.pl-tree-loader {
  text-align: center;
  padding: 1em 0;
}
/* prosta animacja spinnera */
.pl-tree-loader:after {
  content: '';
  display: inline-block;
  width: 24px;
  height: 24px;
  margin: 0 auto;
  border: 3px solid #ddd;
  border-top-color: #E62038; /* czerwony akcent */
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
@keyframes spin {
  to { transform: rotate(360deg); }
}