/* =========================================================
   ZONAS – Product subcategories
   ========================================================= */

.wp-block-zonas-product-subcategories,
.zn-product-subcategories {
    display: block !important;
    width: 100% !important;
    max-width: none;
    box-sizing: border-box;

    font-family: "Inter", sans-serif;
}


.zn-product-subcategories__navigation {
    display: block;
    width: 100%;
    margin-bottom: 14px;
}

.zn-product-subcategories__back {
    display: inline-flex;
    align-items: center;
    gap: 7px;

    color: var(--wp--preset--color--heading, #002261);
    text-decoration: none;

    font-family: "Inter", sans-serif;
    font-size: 13px;
    font-weight: 600;
    line-height: 1.3;

    transition: color 0.2s ease;
}

.zn-product-subcategories__back:hover {
    color: var(--wp--preset--color--primary, #e91e63);
}

.zn-product-subcategories__back-icon {
    font-size: 1.15em;
    line-height: 1;
}


.zn-product-subcategories__grid {
    display: grid !important;

    width: 100%;
    min-width: 0;

    /* DESKTOP = 5 */
    grid-template-columns:
        repeat(
            var(--zn-subcategory-columns, 5),
            minmax(0, 1fr)
        );

    gap: 10px;

    align-items: stretch;
}

.zn-product-subcategory {
    position: relative;
    display: flex;
    flex-direction: row;
    align-items: center;
    width: 100%;
    min-width: 0;
    /* VÝŠKA KARTY */
    min-height: 78px;
    padding: 10px 34px 10px 12px;
    overflow: hidden;
    box-sizing: border-box;
    background: var(--wp--preset--color--surface, #fff);
    border: 1px solid #EAECF0;
    border-radius: 8px;
    box-shadow: 0 1px 2px rgb(16 24 40 / 4%);

    color: var(--wp--preset--color--text, #3a2b35);
    text-decoration: none;

    font-family: "Inter", sans-serif;
}

.zn-product-subcategory:hover {
    border-color: var(--wp--preset--color--primary, #e91e63);
    box-shadow: 0 4px 12px rgb(16 24 40 / 7%);
}


.zn-product-subcategory__image {
    display: flex;
    align-items: center;
    justify-content: center;

    /* BOX PRE IKONU */
    width: 48px;
    height: 48px;
    min-width: 48px;

    flex: 0 0 48px;

    margin-right: 10px;
    padding: 0;

    box-sizing: border-box;
}



.zn-product-subcategory__image img {
    display: block;

    /* VEĽKOSŤ IKONY */
    width: 40px;
    height: 40px;

    max-width: 40px;
    max-height: 40px;

    object-fit: contain;
}


.zn-product-subcategory__content {
    display: flex;
    flex-direction: column;
    justify-content: center;

    flex: 1 1 auto;

    width: auto;
    min-width: 0;

    padding: 0;

    box-sizing: border-box;

    font-family: "Inter", sans-serif;
}


.zn-product-subcategory__name {
    display: block;

    margin: 0;

    color: #101828;

    font-family: "Inter", sans-serif;

    /* VEĽKOSŤ NÁZVU KATEGÓRIE */
    font-size: 12px;

    font-weight: 600;
    line-height: 1.25;

    overflow-wrap: anywhere;
}

.zn-product-subcategory__count {
    display: block;

    margin-top: 3px;

    color: #98A2B3;

    font-family: "Inter", sans-serif;

    /* VEĽKOSŤ POČTU PRODUKTOV */
    font-size: 10px;

    font-weight: 400;
    line-height: 1.2;

    opacity: 1;
}

.zn-product-subcategory::after {
    content: "›";

    position: absolute;

    right: 11px;
    top: 50%;

    transform: translateY(-50%);

    color: var(--wp--preset--color--primary, #e91e63);

    font-family: Arial, sans-serif;
    font-size: 19px;
    font-weight: 400;
    line-height: 1;

    pointer-events: none;

    transition: transform 0.2s ease;
}

.zn-product-subcategory:hover::after {
    transform: translate(2px, -50%);
}


/* =========================================================
   TABLET
   ========================================================= */

@media (max-width: 900px) {

    .zn-product-subcategories__grid {
        grid-template-columns:
            repeat(3, minmax(0, 1fr));

        gap: 8px;
    }

    .zn-product-subcategory {
        min-height: 72px;
    }
}


/* =========================================================
   MOBILE
   ========================================================= */

@media (max-width: 600px) {

    .zn-product-subcategories__grid {
        grid-template-columns:
            repeat(2, minmax(0, 1fr));

        gap: 7px;
    }


    /* VÝŠKA KARTY NA MOBILE */
    .zn-product-subcategory {
        min-height: 64px;

        padding: 8px 27px 8px 9px;
    }


    /* BOX PRE IKONU NA MOBILE */
    .zn-product-subcategory__image {
        width: 28px;
        height: 28px;
        min-width: 28px;

        flex: 0 0 28px;

        margin-right: 7px;
        padding: 0;
    }


    /* VEĽKOSŤ IKONY NA MOBILE */
    .zn-product-subcategory__image img {
        width: 24px;
        height: 24px;

        max-width: 24px;
        max-height: 24px;
    }


    /* VEĽKOSŤ NÁZVU NA MOBILE */
    .zn-product-subcategory__name {
        font-size: 10.5px;
        line-height: 1.25;
    }


    /* VEĽKOSŤ POČTU NA MOBILE */
    .zn-product-subcategory__count {
        margin-top: 2px;
        font-size: 9px;
    }


    /* ŠÍPKA NA MOBILE */
    .zn-product-subcategory::after {
        right: 8px;
        font-size: 17px;
    }
}