/* Layout wrapper */
.af-assortiment-wrap{
    margin: 0 auto;
    display: grid;
    grid-template-columns: 320px 1fr;
    gap: 36px;
    padding: 292px 24px 60px;
}


.af-assortiment-main .woocommerce-notices-wrapper {
    display: none !important;
}


.af-acc {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.af-breadcrumbs{
    width: min(1200px, 92%);
    margin: 18px auto 0;
    font-size: 13px;
    opacity: .75;
}

/* Sidebar card */
.af-sidebar-card{
    background: #f3f3f3;
    padding: 24px;
    border-radius: 24px;
}

.af-sidebar-title{
    font-size: 28px;
    font-weight: 800;
    margin-bottom: 24px;
}

.af-assortiment-desc__text em {
    color: #2c57ff;
}

/* Accordion */
.af-acc-item{
    overflow: visible;
    margin: 0;
}

.af-acc-head{
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: center;
    gap: 8px;
    min-height: 24px;
    height: auto;
    margin: 0;
    padding: 0;
}

.af-acc-parent-link{
    display: inline-flex;
    align-items: center;
    min-height: 24px;
    text-decoration: none;
    color: #111;
    font-weight: 400;
    font-size: 14px;
    line-height: 1.25;
}

.af-acc-parent-link:hover,
.af-acc-parent-link.is-active,
.af-acc-parent-link.is-current-path{
    color: #2c57ff;
}

.af-acc-toggle{
    appearance: none;
    border: 0;
    background: transparent;
    cursor: pointer;
    border-radius: 10px;
    padding: 0;
    width: 18px;
    height: 18px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.af-acc-chevron{
    display: inline-block;
    width: 8px;
    height: 8px;
    margin-right: 2px;
    border-right: 2px solid #001989;
    border-bottom: 2px solid #001989;
    transform: rotate(45deg);
    transition: transform .18s ease;
}

.af-acc-item.is-open .af-acc-chevron{
    transform: rotate(225deg);
}

.af-top-controls{
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 24px;
    margin-bottom: 24px;
}

/* View toggle buttons */
.af-view-toggle{
    display: flex;
    gap: 4px;
    margin-right: auto;
}

.af-view-btn{
    appearance: none;
    border: 1.5px solid #d7d7d7;
    background: #fff;
    color: #999;
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: border-color .15s ease, color .15s ease, background .15s ease;
    padding: 0;
}

.af-view-btn:hover{
    border-color: #001989;
    color: #001989;
}

.af-view-btn.is-active{
    border-color: #001989;
    background: #001989;
    color: #fff;
}

.af-woocommerce-ordering{
    width: auto;
    margin: 0;
}

.af-filter-btn{
    display: none;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 14px;
    border: 1px solid #d7d7d7;
    background: #fff;
    color: #001989;
    padding: 0;
    cursor: pointer;
}

.af-filter-ico{
    width: 20px;
    height: 20px;
    fill: currentColor;
}

.af-filter-overlay{
    display: none;
}

.af-filter-overlay-close{
    display: none;
}


/* Accordion panel animation (closed = NO spacing visible) */
.af-acc-panel{
    background: #e9e9e9;
    border-radius: 14px;
    display: grid;
    gap: 0;
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transform: translateY(-4px);
    margin: 0;
    padding: 0;
    transition:
            max-height .28s ease,
            opacity .20s ease,
            transform .20s ease,
            margin .20s ease,
            padding .20s ease;
}

/* Open state: spacing pas tonen wanneer open */
.af-acc-item.is-open > .af-acc-panel{
    opacity: 1;
    transform: translateY(0);
    margin: 8px 0 8px;
    padding: 6px 10px;
}

/* spacing inside panel */
.af-acc-panel > *:first-child{ margin-top: 0; }
.af-acc-panel > *:last-child{ margin-bottom: 0; }

.af-acc-child-link{
    display: inline-flex;
    align-items: center;
    min-height: 24px;
    text-decoration: none;
    color: #111;
    font-weight: 400;
    font-size: 13px;
    line-height: 1.25;
    padding: 2px 0;
}

.af-acc-child-link:hover,
.af-acc-child-link.is-active{
    color: #2c57ff;
}

/* Main */
.af-assortiment-title{
    font-size: 28px;
    font-weight: 800;
    margin: 0 0 8px;
}

.af-assortiment-desc{
    max-width: 100%;
    margin-bottom: 0;
    border-bottom: 2px solid #F6F6F6;
    padding-bottom: 48px;
}

/* Read more */
.af-assortiment-desc__text{
    font-size: 14px;
    line-height: 1.6;
    color: #222;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Paragrafen / breaks binnen de beschrijving */
.af-assortiment-desc__text p{
    margin: 0 0 10px;
}
.af-assortiment-desc__text p:last-child{
    margin-bottom: 0;
}
.af-assortiment-desc__text br{
    display: block;
    content: "";
    margin-top: 6px;
}

/* Links in de categorie-beschrijving */
.af-assortiment-desc__text a,
.af-assortiment-desc__text a:link,
.af-assortiment-desc__text a:visited,
.af-assortiment-desc__text a:hover,
.af-assortiment-desc__text a:focus{
    color: #5470e8;
    text-decoration: none;
}

.af-assortiment-desc.is-open .af-assortiment-desc__text{
    -webkit-line-clamp: initial;
    overflow: visible;
    display: block;
}
.af-assortiment-desc.is-open .af-assortiment-desc__text p{
    margin: 0 0 14px;
}
.af-assortiment-desc.is-open .af-assortiment-desc__text p:last-child{
    margin-bottom: 0;
}

.af-readmore-btn{
    margin-top: 24px;
    border: 0;
    background: transparent;
    color: #ddbe52;
    font-weight: 400;
    cursor: pointer;
    padding: 0;
    font-size: 14px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-style: italic;
}

.af-readmore-caret{
    width: 8px;
    height: 8px;
    border-right: 2px solid #ddbe52;
    border-bottom: 2px solid #ddbe52;
    transform: rotate(45deg);
    transition: transform .18s ease;
}

.af-assortiment-desc.is-open .af-readmore-caret{
    transform: rotate(225deg);
}

/* Grid cards */
.af-cat-grid{
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
    margin-top: 10px;
    width: 100%;
}

a.added_to_cart.wc-forward {
    display: none;
}

.af-cat-card{
    text-decoration: none;
    color: #fff;
    border-radius: 16px;
    border: 2px solid #1e3fff;
    overflow: hidden;
    background: #fff;
    display: grid;
    grid-template-rows: 1fr auto;
    min-height: 0;
}

.af-cat-card__img{
    background: #fff;
    display: grid;
    place-items: center;
    padding: 0;
    height: 200px;
}

.af-cat-card__img img{
    width: 100%;
    height: 100%;
    max-height: 100%;
    object-fit: cover;
}

.af-cat-thumb-placeholder{
    width: 100%;
    height: 120px;
    border-radius: 12px;
    background: linear-gradient(135deg, rgba(30,63,255,.08), rgba(0,0,0,.03));
}

.af-cat-card__label{
    background: #01198a;
    color: #fff;
    font-weight: 800;
    text-align: center;
    padding: 12px 10px;
    font-size: 12px;
}

.af-cat-card:hover {
    border: 2px solid #546fe8;
}

.af-cat-card:hover .af-cat-card__label {
    background: #546fe8;
}

.af-cat-card:hover{
    transition: transform .15s ease;
}

.af-empty{
    margin-top: 20px;
    opacity: .7;
}

.af-sidebar-mobile-head{display:none;}


@media (max-width: 425px){
    .af-cat-card__img {
        height: 120px;
    }
}

/* Responsive */
@media (max-width: 980px){



    .af-assortiment-wrap{
        grid-template-columns: 1fr;

    }
    .af-cat-grid{
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    /* Mobile filter offcanvas (matches PDF design) */
    .af-filter-btn{
        display: inline-flex;
    }

    .af-filter-overlay{
        display: block;
        position: fixed;
        inset: 0;
        background: rgba(0,0,0,.45);
        opacity: 0;
        visibility: hidden;
        transition: opacity .25s ease, visibility .25s ease;
        z-index: 9998;
        backdrop-filter: blur(10px);
    }

    html.af-filter-open .af-filter-overlay{
        opacity: 1;
        visibility: visible;
    }

    /* Close button on overlay (top-right) */
    .af-filter-overlay-close{
        position: fixed;
        top: 16px;
        right: 16px;
        width: 44px;
        height: 44px;
        border-radius: 999px;
        border: 2px solid #001989;
        background: #fff;
        color: #001989;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 28px;
        line-height: 1;
        cursor: pointer;
        z-index: 10000;
        opacity: 0;
        visibility: hidden;
        transition: opacity .25s ease, visibility .25s ease;
        box-shadow: 0 10px 26px rgba(0,0,0,.22);
    }

    html.af-filter-open .af-filter-overlay-close{
        opacity: 1;
        visibility: visible;
    }

    /* Hide the close button inside the sidebar header on mobile (we use overlay close) */
    .af-sidebar-mobile-head .af-filter-close{
        display: none;
    }


    /* Sidebar becomes offcanvas */
    .af-assortiment-sidebar{
        position: fixed;
        top: 0;
        left: 0;
        height: 100vh;
        width: min(86vw, 300px);
        transform: translateX(-105%);
        transition: transform .28s ease;
        z-index: 9999;
        background: #fff;
        overflow: auto;
        padding: 14px 14px 22px;
        padding-right: 0;
        padding-left: 0;
    }

    html.af-filter-open .af-assortiment-sidebar{
        transform: translateX(0);
    }

    .af-sidebar-title{
        display: none;
    }

    .af-sidebar-mobile-head{
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 14px 16px;
        border-bottom: 1px solid #efefef;
    }

    .af-sidebar-mobile-title{
        font-size: 18px;
        font-weight: 700;
    }

    .af-filter-close{
        background: transparent;
        border: 0;
        padding: 6px 10px;
        font-size: 28px;
        line-height: 1;
        color: #001989;
        cursor: pointer;
    }

    body.af-filter-open{
        overflow: hidden;
    }

    .af-acc {
        gap: 0;
        border-top: 1px solid #f0f0f0;
        background: #fff;
    }

    .af-sidebar-card{
        background: #fff;
        border-radius: 0;
        padding: 0;
        overflow: hidden;
    }

    .af-acc-item{
        margin: 0;
        padding: 0;
        border-bottom: 1px solid #f0f0f0;
        background: #fff;
        border-radius: 0;
        overflow: visible;
    }

    .af-acc-head{
        display: grid;
        grid-template-columns: 1fr 52px;
        align-items: stretch;
        gap: 0;
        min-height: 48px;
        height: auto;
        margin: 0;
        padding: 0;
        background: #fff;
        border-bottom: 0;
    }

    .af-acc-parent-link{
        display: flex;
        align-items: center;
        min-height: 48px;
        width: 100%;
        padding: 12px 14px;
        text-decoration: none;
        color: #111;
        font-weight: 400;
        font-size: 15px;
        line-height: 1.3;
        background: #fff;
    }

    .af-acc-parent-link:hover,
    .af-acc-parent-link:focus,
    .af-acc-parent-link.is-active,
    .af-acc-parent-link.is-current-path{
        color: #111;
        text-decoration: none;
    }

    .af-acc-toggle{
        appearance: none;
        border: 0;
        background: transparent;
        cursor: pointer;
        border-radius: 0;
        padding: 0;
        width: 52px;
        min-width: 52px;
        height: auto;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        border-left: 1px solid #efefef;
        color: #111;
    }

    .af-acc-chevron{
        display: inline-block;
        width: 10px;
        height: 10px;
        margin-right: 0;
        border-right: 2px solid #222;
        border-bottom: 2px solid #222;
        transform: rotate(-45deg);
        transition: transform .18s ease;
        opacity: .7;
    }

    .af-acc-item.is-open .af-acc-chevron{
        transform: rotate(45deg);
    }

    .af-acc-panel{
        background: #fff;
        border-radius: 0;
        margin: 0;
        padding: 0;
        transform: none;
        max-height: 0;
        overflow: hidden;
        opacity: 0;
        transition: max-height .28s ease, opacity .28s ease;
    }

    .af-acc-item.is-open > .af-acc-panel{
        max-height: 2000px;
        opacity: 1;
        margin: 0;
        padding: 0;
    }

    .af-acc-panel > *:first-child,
    .af-acc-panel > *:last-child{
        margin: 0;
    }

    .af-acc-child-link{
        display: flex;
        align-items: center;
        width: 100%;
        min-height: 44px;
        padding: 10px 14px 10px 24px;
        text-decoration: none;
        color: #222;
        font-weight: 500;
        font-size: 14px;
        line-height: 1.3;
        border-top: 1px solid #f7f7f7;
        border-bottom: 0;
        background: #fff;
    }

    .af-acc-child-link:hover,
    .af-acc-child-link:focus,
    .af-acc-child-link.is-active{
        color: #222;
        text-decoration: none;
    }
}
@media (max-width: 560px) {
    .af-cat-grid {
        grid-template-columns: 1fr  1fr;
    }

    .af-cat-card {
        min-height: auto;
    }
}


/* ===== Product grid like screenshot ===== */
.woocommerce ul.products{
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 22px;
    margin: 0;
    padding: 0;
}
.woocommerce ul.products::before,
.woocommerce ul.products::after{
    display: none !important;
}

.woocommerce ul.products li.product{
    list-style: none;
    float: none !important;
    width: auto !important;
    margin: 0 !important;
}

/* Card */
.af-product-card{
    border: 2px solid #ddd;
    border-radius: 22px;
    overflow: hidden;
    background: #fff;
    transition: border-color .15s ease, transform .15s ease;
    display: flex;
    flex-direction: column;
    min-height: 420px;
}

.af-product-card:hover{
    border-color: #5470e8;
    transform: translateY(-1px);
}

/* Whole clickable area (except cart button) */
.af-product-link{
    text-decoration: none;
    color: inherit;
    display: block;
    flex: 1;
}

/* Image area */
.af-product-image{
    padding: 24px 24px 10px;
    display: grid;
    place-items: center;
    min-height: 190px;
}
.af-product-thumb{
    width: 100%;
    height: auto;
    max-height: 170px;
    object-fit: contain;
}

/* Body text */
.af-product-body{
    padding: 10px 24px 14px;
}

.af-product-cat{
    color: #2c57ff;
    font-weight: 400;
    font-size: 13px;
    margin-bottom: 10px;
}

.af-product-title{
    margin: 0;
    font-size: 14px;
    font-weight: 500;
    line-height: 1.2;
    color: #0b1b3a;
}

/* Footer */
.af-product-footer{
    padding: 14px 18px 18px;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 14px;
    align-items: center;
}

.af-product-price{
    display: flex;
    gap: 14px;
    align-items: center;
}

/* Woo price */
.af-product-price .price{
    margin: 0 !important;
    font-weight: 900;
    font-size: 26px;
    color: #111;
}
.af-product-price .woocommerce-Price-amount{
    font-weight: 900;
    font-size: 18px;
}
.af-product-price del{
    opacity: .5;
    font-size: 14px;
}
.af-product-price ins{
    text-decoration: none;
}

.af-price-tax{
    font-size: 11px;
    text-decoration: underline;
    color: #757575;
}

/* Green cart button */
.af-add-to-cart{
    width: 56px;
    height: 56px;
    border-radius: 14px;
    background: #11c311;
    display: grid;
    place-items: center;
    padding: 0 !important;
    min-width: 56px;
    box-shadow: none !important;
    border: 0 !important;
}

.af-add-to-cart:hover{
    filter: brightness(.95);
}

.af-cart-ico{
    width: 24px;
    height: 24px;
    fill: #fff;
}

/* Remove Woo default button styles conflicts */
.woocommerce ul.products li.product .button{
    margin-top: 0 !important;
}

/* Responsive */
@media (max-width: 980px){
    .woocommerce ul.products{
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}
@media (max-width: 560px){
    .woocommerce ul.products{
        grid-template-columns: 1fr;
    }
}



/* Zorg dat de sidebar container een vaste hoogte heeft */
@media (max-width: 980px){

    /* Sidebar card wordt wit en strak zoals design */
    .af-sidebar-card{
        background: #fff;
        border-radius: 0;
        padding: 0;
    }

    .af-sidebar-mobile-head{
        padding: 14px 16px;
        border-bottom: 1px solid #efefef;
    }

    .af-acc{
        gap: 0;
    }

    .af-acc-item{
        border-radius: 0;
        overflow: visible;
    }

    .af-acc-head{
        height: auto;
        padding: 0;
        border-bottom: 0;
    }

    .af-acc-panel{
        background: #fff;
        border-radius: 0;
        margin: 0;
        padding: 0;
        transform: none;
    }

    .af-acc-item.is-open > .af-acc-panel{
        margin: 0;
        padding: 0;
    }

    .af-acc-panel > *:first-child,
    .af-acc-panel > *:last-child{
        margin: 0;
    }

    .af-acc-child-link{
        display: flex;
        width: 100%;
        min-height: 44px;
        padding: 10px 14px 10px 24px;
        border-top: 1px solid #f7f7f7;
        border-bottom: 0;
        font-weight: 500;
        align-items: center;
        color: #222;
    }

    .af-acc-child-link.is-active{
        color: #222;
    }
}

ul.products.columns-4 {
    margin-top: 48px;
}


@media (max-width: 980px){

    /* accordion panel animatie via CSS (geen inline px) */
    .af-acc-panel{
        max-height: 0;
        overflow: hidden;
        opacity: 0;
        transition: max-height .28s ease, opacity .28s ease;
    }

    .af-acc-item.is-open > .af-acc-panel{
        max-height: 2000px; /* groot genoeg */
        opacity: 1;
    }

    .af-assortiment-wrap{
        display: flex;
        flex-direction: column;
        flex-wrap: nowrap;
    }

}





































/* Mobile category chips (2 visible + swipe) */
.af-mobile-bar{ display:none; }

@media (max-width: 980px){

    /* bar full width (ook als parent max-width heeft) */
    .af-mobile-bar{
        width: 100vw;
        margin-left: calc(50% - 50vw);
        margin-right: calc(50% - 50vw);
        padding: 0 16px;
        box-sizing: border-box;

        display: flex;
        align-items: center;
        gap: 10px;
        margin-top: 12px;
        padding-left: 24px;
        padding-right: 24px;
    }

    /* tabs: horizontaal swipen */
    .af-mobile-tabs{
        flex: 1 1 auto;
        min-width: 0;

        display: flex !important;
        flex-wrap: nowrap !important;
        gap: 10px;

        overflow-x: auto !important;
        overflow-y: hidden !important;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;

        padding: 0 0 10px 0;
        scroll-snap-type: x mandatory;
        scroll-behavior: smooth;

        position: relative;
    }

    .af-mobile-tabs::-webkit-scrollbar{ display:none; }

    /* ✅ altijd 2 chips tegelijk zichtbaar (werkt voor <a>, <button>, etc.) */
    .af-mobile-tabs > *{
        flex: 0 0 calc((100% - 10px) / 2) !important;
        max-width: calc((100% - 10px) / 2) !important;
        scroll-snap-align: start;
    }

    /* chip styling */
    .af-mobile-tab,
    .af-mobile-tabs > a,
    .af-mobile-tabs > button{
        display: flex;
        align-items: center;
        justify-content: center;

        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;

        padding: 10px 12px;
        border: 1px solid #d9d9d9;
        border-radius: 4px;
        background:#fff;
        font-weight: 600;
        line-height: 1;
        text-decoration:none;
        color:#111;
        box-sizing: border-box;
    }

    .af-mobile-tab.is-active{
        border-color:#001989;
    }

    /* fade rechts zoals design */
    .af-mobile-bar-right:before{
        content: "";
        position: absolute;
        top: 1px;
        left: -50px;
        bottom: 2px;
        width: 48px;
        pointer-events: none;
        background: linear-gradient(to left, #fff 60%, rgba(255, 255, 255, 0));
    }

    /* rechter controls (filter / ordering) */
    .af-mobile-bar-right{
        flex: 0 0 auto;
        display:flex;
        align-items:center;
        gap:10px;
        margin-top: -9px;
        position: relative;
    }

    /* ordering */
    .af-mobile-ordering .woocommerce-ordering{ margin:0; }
    .af-mobile-ordering select{
        height: 38px;
        border-radius: 4px;
    }

    /* filter button */
    .af-mobile-filter-btn{
        width: 40px;
        height: 38px;
        border-radius: 4px;
        border: 1px solid #d9d9d9;
        background:#fff;
        display:flex;
        align-items:center;
        justify-content:center;
        cursor:pointer;
        flex: 0 0 auto;
    }
    .af-mobile-filter-btn svg{
        width: 18px;
        height: 18px;
        fill:#111;
    }

    /* hand/hint uit */
    .af-mobile-tabs-hint{ display:none !important; }
}


@media (max-width: 980px){

    /* chips tekst beter leesbaar */
    .af-mobile-tab{
        font-size: 13px;        /* iets kleiner */
        padding: 10px 10px;     /* iets minder padding */
        font-weight: 600;
        justify-content: flex-start; /* tekst start links, leest beter */
    }

    /* ellipsis werkt alleen als er echte overflow is */
    .af-mobile-tab{
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    /* geef iets meer ruimte door de chip iets breder te maken */
    .af-mobile-tabs > *{
        flex: 0 0 70% !important;     /* i.p.v. exact 50% */
        max-width: 70% !important;
    }
}



.af-assortiment-main {
    display: flex;
    flex-direction: column;
}
/* ===== Nested category tree ===== */
.af-acc-panel .af-acc-item{
    overflow: visible;
}

.af-acc-panel .af-acc{
    gap: 4px;
}


.af-acc-item--level-1 .af-acc-head,
.af-acc-item--level-2 .af-acc-head,
.af-acc-item--level-3 .af-acc-head,
.af-acc-item--level-4 .af-acc-head{
    min-height: 24px;
    height: auto;
}

.af-acc-parent-link--level-1{
    padding-left: 4px;
    font-size: 13px;
}

.af-acc-parent-link--level-2{
    padding-left: 12px;
    font-size: 13px;
}

.af-acc-parent-link--level-3,
.af-acc-parent-link--level-4{
    padding-left: 18px;
    font-size: 13px;
}

.af-acc-panel--level-1,
.af-acc-panel--level-2,
.af-acc-panel--level-3,
.af-acc-panel--level-4{
    margin-left: 4px;
}

.af-acc-item--level-1.is-open > .af-acc-panel,
.af-acc-item--level-2.is-open > .af-acc-panel,
.af-acc-item--level-3.is-open > .af-acc-panel,
.af-acc-item--level-4.is-open > .af-acc-panel{
    margin-top: 4px;
    margin-bottom: 4px;
    padding-top: 4px;
    padding-bottom: 4px;
}

.af-acc-item--level-1 > .af-acc-panel,
.af-acc-item--level-2 > .af-acc-panel,
.af-acc-item--level-3 > .af-acc-panel,
.af-acc-item--level-4 > .af-acc-panel{
    padding-left: 6px;
    padding-right: 6px;
}

.af-acc-item + .af-acc-item{
    margin-top: 2px;
}

@media (max-width: 980px){
    .af-acc-panel--level-1,
    .af-acc-panel--level-2,
    .af-acc-panel--level-3,
    .af-acc-panel--level-4{
        margin-left: 0;
    }

    .af-acc-parent-link--level-1{
        padding-left: 14px;
        font-size: 15px;
    }

    .af-acc-parent-link--level-2{
        padding-left: 24px;
        font-size: 14px;
    }

    .af-acc-parent-link--level-3,
    .af-acc-parent-link--level-4{
        padding-left: 34px;
        font-size: 14px;
    }

    .af-acc-panel .af-acc{
        gap: 0;
    }

    .af-acc-item--level-1 .af-acc-head,
    .af-acc-item--level-2 .af-acc-head,
    .af-acc-item--level-3 .af-acc-head,
    .af-acc-item--level-4 .af-acc-head{
        min-height: 48px;
        height: auto;
    }

    .af-acc-item--level-1.is-open > .af-acc-panel,
    .af-acc-item--level-2.is-open > .af-acc-panel,
    .af-acc-item--level-3.is-open > .af-acc-panel,
    .af-acc-item--level-4.is-open > .af-acc-panel{
        margin-top: 0;
        margin-bottom: 0;
        padding-top: 0;
        padding-bottom: 0;
    }

    .af-acc-item--level-1 > .af-acc-panel,
    .af-acc-item--level-2 > .af-acc-panel,
    .af-acc-item--level-3 > .af-acc-panel,
    .af-acc-item--level-4 > .af-acc-panel{
        padding-left: 0;
        padding-right: 0;
    }

    .af-acc-item + .af-acc-item{
        margin-top: 0;
    }

    .af-acc-item.is-current > .af-acc-head > .af-acc-parent-link,
    .af-acc-item.is-active > .af-acc-head > .af-acc-parent-link,
    .af-acc-parent-link[aria-current="page"]{
        color: #0b2aa5;
        font-weight: 700;
    }
}

@media (max-width: 980px){
    .af-acc-item{
        border-bottom: 0 !important;
    }

    .af-acc-head{
        border-bottom: 1px solid #f0f0f0 !important;
    }

    .af-acc-item.is-open > .af-acc-head{
        border-bottom: 1px solid #f0f0f0 !important;
    }
}


/* ===== LIST VIEW ===== */
.af-view--list ul.products{
    grid-template-columns: 1fr !important;
    gap: 14px !important;
}

.af-view--list .af-product-card{
    flex-direction: row !important;
    min-height: auto !important;
    border-radius: 16px;
    align-items: stretch;
}

.af-view--list .af-product-link{
    display: flex !important;
    flex-direction: row !important;
    flex: 1;
    min-width: 0;
}

.af-view--list .af-product-image{
    flex: 0 0 120px;
    min-height: auto;
    padding: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.af-view--list .af-product-thumb{
    max-height: 90px;
    width: auto;
    max-width: 100%;
}

.af-view--list .af-product-body{
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 14px 10px 14px 0;
    min-width: 0;
}

.af-view--list .af-product-cat{
    margin-bottom: 4px;
}

.af-view--list .af-product-title{
    font-size: 14px;
}

.af-view--list .af-product-footer{
    flex: 0 0 auto;
    flex-direction: row;
    align-items: center;
    gap: 14px;
    padding: 14px 18px;
    border-left: 1px solid #f0f0f0;
    min-width: 200px;
    justify-content: space-between;
}

.af-view--list .af-product-price{
    flex-direction: column;
    gap: 2px;
    align-items: flex-start;
}

.af-view--list .af-add-to-cart{
    width: 48px;
    height: 48px;
    min-width: 48px;
    border-radius: 12px;
}

/* Mobile: always list view */
@media (max-width: 768px){
    .af-view-toggle{
        display: none;
    }

    .af-view--list .af-product-price {
        display: flex !important;
        gap: 10px;
        align-items: center;
        flex-direction: row;
    }

    /* Force single column */
    .woocommerce ul.products{
        grid-template-columns: 1fr !important;
        gap: 10px !important;
    }

    /* Card: grid — image left spanning rows, body + footer right */
    .woocommerce ul.products li.af-product-card,
    .af-view--list .af-product-card,
    .af-product-card{
        display: grid !important;
        grid-template-columns: 80px 1fr !important;
        grid-template-rows: auto auto !important;
        min-height: auto !important;
        border-radius: 14px !important;
        border-width: 1.5px !important;
        padding: 12px !important;
        gap: 0 12px !important;
        flex-direction: unset !important;
    }

    /* Link: display contents so children join the card grid */
    .woocommerce ul.products .af-product-link,
    .af-view--list .af-product-link,
    .af-product-link{
        display: contents !important;
        flex-direction: unset !important;
    }

    /* Image: left column, spans both rows */
    .woocommerce ul.products .af-product-image,
    .af-view--list .af-product-image,
    .af-product-image{
        grid-column: 1 !important;
        grid-row: 1 / 3 !important;
        min-height: auto !important;
        padding: 0 !important;
        display: flex !important;
        align-items: flex-start !important;
        justify-content: center !important;
        padding-top: 2px !important;
    }

    .af-product-thumb{
        max-height: 68px !important;
        width: 76px !important;
        object-fit: contain !important;
    }

    /* Body: top-right cell */
    .woocommerce ul.products .af-product-body,
    .af-view--list .af-product-body,
    .af-product-body{
        grid-column: 2 !important;
        grid-row: 1 !important;
        display: flex !important;
        flex-direction: column !important;
        justify-content: center !important;
        padding: 0 0 8px 0 !important;
        min-width: 0 !important;
    }

    .af-product-cat{
        margin-bottom: 3px;
        font-size: 11px;
    }

    .af-product-title{
        font-size: 13px;
        font-weight: 600;
        line-height: 1.4;
        display: block;
        overflow: visible;
    }

    /* Footer: bottom-right cell — price left, cart right */
    .woocommerce ul.products .af-product-footer,
    .af-view--list .af-product-footer,
    .af-product-footer{
        grid-column: 2 !important;
        grid-row: 2 !important;
        display: flex !important;
        flex-direction: row !important;
        align-items: center !important;
        justify-content: space-between !important;
        gap: 10px !important;
        padding: 8px 0 0 !important;
        border-top: 1px solid #f0f0f0 !important;
        border-left: 0 !important;
        min-width: auto !important;
    }

    .af-product-price{
        flex-direction: row;
        gap: 6px;
        align-items: baseline;
        white-space: nowrap;
    }

    .af-product-price .woocommerce-Price-amount{
        font-size: 16px;
        font-weight: 900;
    }

    .af-price-tax{
        font-size: 10px;
    }

    .af-add-to-cart{
        width: 42px;
        height: 42px;
        min-width: 42px;
        border-radius: 12px;
    }

    .af-cart-ico{
        width: 18px;
        height: 18px;
    }
}
