.ws-elementor-widget-ws-product-categories {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    gap: 10px;
    align-self: stretch;
}

.ws-elementor-widget-ws-product-categories > a.ws-product-categories--container {
    position: relative;
    display: flex;
    height: 300px;
    align-items: flex-end;
    gap: 10px;
    flex: 0 0 calc((100%/3) - (20px/3));
    text-decoration: none;
}

.ws-elementor-widget-ws-product-categories > a.ws-product-categories--container:nth-child(5n-1), 
.ws-elementor-widget-ws-product-categories > a.ws-product-categories--container:nth-child(5n) {
    flex: 0 0 calc(50% - 5px);
}

.ws-elementor-widget-ws-product-categories:has(> :nth-child(6):nth-last-child(1)) > a.ws-product-categories--container {
  flex: 0 0 calc((100%/3) - (20px/3));
}


.ws-product-categories--image-container {
    position: absolute;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.ws-product-categories--image-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.ws-product-categories--gradient-container {
    position: absolute;
    width: 100%;
    height: 100%;
    background: linear-gradient(180deg, rgba(0, 0, 0, 0.00) 50%, rgba(0, 0, 0, 0.90) 100%);
}

.ws-product-categories--text {
    max-height: 100%;
    padding: 25px;
    display: flex;
    flex-direction: column;
    gap: 5px;
    z-index: 1;
}

.ws-product-categories--title {
    display: flex;
    align-items: center;
    gap: 10px;
}

.ws-product-categories--title > span {
    color: #fff;
}

.ws-product-categories--title > i,
.ws-product-categories--title > svg {
    color: var(--qerys-primary-color);
}

.ws-product-categories--description {
    display: grid;
    grid-template-rows: 0fr;
    color: #fff;
    opacity: 0;
    transition: opacity .2s, grid-template-rows .2s;
}

.ws-product-categories--description > span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ws-product-categories--container:hover .ws-product-categories--description {
    opacity: 1;
    grid-template-rows: 1fr;
}

@media (max-width: 1025px) {
    .ws-elementor-widget-ws-product-categories > a.ws-product-categories--container {
        flex: 0 0 calc(50% - 5px);
    }

    .ws-elementor-widget-ws-product-categories > a.ws-product-categories--container:nth-child(3n+3) {
        flex: 0 0 100%;
    }

    .ws-product-categories--description {
        opacity: 1;
        grid-template-rows: 1fr;
    }
}

@media (max-width: 767px) {
    .ws-elementor-widget-ws-product-categories > a.ws-product-categories--container:nth-child(n) {
        flex: 0 0 100%;
    }

    .ws-product-categories--text {
        padding: 10px;
    }
}