#productList {
    margin:40px;
    padding-bottom: 30px;
}

h2 {
    font-weight: normal;
}

/* Product grid container */
.categoryDiv {
    display: grid;
    gap: 20px;
    margin: 20px 0;
}

/* Responsive grid columns */
@media (max-width: 599px) {
    .categoryDiv {
        grid-template-columns: 1fr;
    }
}

@media (min-width: 600px) and (max-width: 799px) {
    .categoryDiv {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 800px) and (max-width: 999px) {
    .categoryDiv {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1000px) {
    .categoryDiv {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* Product card styling */
.product-card {
    display: flex;
    flex-direction: column;
    background: #000000;
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.2s ease;
    height: 100%;
}

.product-card:hover {
    transform: translateY(-2px);
}

.product-card a img {
    width: 100%;
    height: auto;
}

.product-card div.name {
    font-size: 1em;
    padding: 10px;
    color: #fff;
    font-weight: bold;
}

.product-card div.tagline {
    color: #777;
    font-size: 1em;
    padding: 0 10px 10px 10px;
    line-height: 1.4;
}

div.product-card.discontinued a img {
    filter: brightness(40%);
}

/* products/sorting-grouping */
#groupByContainer {
    color:#fff;
    max-width: 1024px;
    width:100%;
    position: absolute;
    margin-top: -28px;
}
#groupByContainer input[type="radio"] {
    display: none;
}

#groupBy {
    position: absolute;
    right: 0;
    margin-right:20px;
    display: inline-flex;
    border: 1px solid #555555;
    border-radius: 8px;
    overflow: hidden;
}
#highlight {
    position: absolute;
    top: 0;
    bottom: 0;
    width: 50%;
    background-color: #555555;
    border-radius: 7px;
    transition: transform 0.4s ease;
    z-index: 0;
}
#family:checked ~ #groupBy #highlight {
    transform: translateX(0%);
}
#category:checked ~ #groupBy #highlight {
    transform: translateX(100%);
}
#groupBy label{
    flex: 1;
    padding: 2px 15px;
    text-align: center;
    cursor: pointer;
    z-index: 1;
    color: #444444;
    transition: color 0.4s;
    user-select: none;
}
#family:checked ~ #groupBy label[for="family"],
#category:checked ~ #groupBy label[for="category"] {
    color: #111111;
}
