/* Ürün listesi — filtre sidebar (Arı / süt ürünleri) */

.shop-sidebar-panel {
    --sf-accent: var(--accent, #2e7d32);
    --sf-accent-dark: var(--accent-dark, #1b5e20);
    --sf-accent-soft: color-mix(in srgb, var(--accent, #2e7d32) 12%, #fff);
    --sf-accent-mid: color-mix(in srgb, var(--accent, #2e7d32) 22%, #fff);
    --sf-border: #e8ece9;
    --sf-text: #1f2937;
    --sf-muted: #6b7280;
    background: #fff;
    border: 1px solid var(--sf-border);
    border-radius: 16px;
    padding: 14px 14px 10px;
    box-shadow: 0 8px 28px rgba(27, 94, 32, 0.06);
}

.shop-sidebar-panel__head {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0 0 12px;
    padding: 4px 4px 12px;
    border-bottom: 1px solid var(--sf-border);
}

.shop-sidebar-panel__icon {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--sf-accent-soft);
    color: var(--sf-accent-dark);
    flex-shrink: 0;
}

.shop-sidebar-panel__icon i {
    font-size: 18px;
}

.shop-sidebar-panel__title {
    margin: 0;
    font-size: 15px;
    font-weight: 800;
    letter-spacing: -0.02em;
    color: var(--sf-text);
}

.shop-sidebar-panel__hint {
    margin: 0 0 12px;
    padding: 10px 12px;
    border-radius: 10px;
    background: #f8faf8;
    border: 1px dashed color-mix(in srgb, var(--sf-accent) 28%, #d1d5db);
    font-size: 12px;
    color: var(--sf-muted);
    line-height: 1.4;
}

.shop-sidebar-panel__hint strong {
    color: var(--sf-accent-dark);
}

.shop-cat-nav {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.shop-filter-section {
    border: 1px solid var(--sf-border);
    border-radius: 12px;
    background: #fbfcfb;
    overflow: hidden;
}

.shop-filter-section:first-child {
    border-top: 1px solid var(--sf-border);
}

.shop-filter-section__toggle {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 12px 12px;
    border: none;
    background: transparent;
    cursor: pointer;
    font-family: inherit;
    font-size: 13px;
    font-weight: 800;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    color: var(--sf-text);
    text-align: left;
}

.shop-filter-section__toggle-left {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
}

.shop-filter-section__toggle-left > i:first-child {
    font-size: 16px;
    color: var(--sf-accent-dark);
    flex-shrink: 0;
}

.shop-filter-section__toggle > i:last-child {
    font-size: 18px;
    color: var(--sf-muted);
    transition: transform .2s ease;
    flex-shrink: 0;
}

.shop-filter-section:not(.is-open) .shop-filter-section__toggle > i:last-child {
    transform: rotate(180deg);
}

.shop-filter-section__body {
    display: none;
    padding: 0 10px 12px;
}

.shop-filter-section.is-open .shop-filter-section__body {
    display: block;
}

.shop-cat-check-list {
    list-style: none;
    margin: 0;
    padding: 0;
    max-height: min(480px, calc(100vh - 260px));
    overflow-y: auto;
}

.shop-cat-check-list::-webkit-scrollbar {
    width: 5px;
}

.shop-cat-check-list::-webkit-scrollbar-thumb {
    background: color-mix(in srgb, var(--sf-accent) 35%, #d1d5db);
    border-radius: 4px;
}

.shop-cat-check {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 10px;
    text-decoration: none;
    color: #4b5563;
    font-size: 13.5px;
    font-weight: 500;
    line-height: 1.35;
    border-radius: 10px;
    transition: color .15s ease, background .15s ease;
    cursor: pointer;
}

.shop-cat-check:hover {
    color: var(--sf-accent-dark);
    background: #fff;
}

.shop-cat-check.is-active {
    color: var(--sf-accent-dark);
    font-weight: 700;
    background: var(--sf-accent-soft);
}

.shop-cat-check__box {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
    border: 1.5px solid #cfd8d3;
    border-radius: 5px;
    background: #fff;
    position: relative;
    transition: border-color .15s ease, background .15s ease, box-shadow .15s ease;
}

.shop-cat-check:hover .shop-cat-check__box {
    border-color: color-mix(in srgb, var(--sf-accent) 55%, #cfd8d3);
}

.shop-cat-check.is-active .shop-cat-check__box {
    background: var(--sf-accent);
    border-color: var(--sf-accent);
    box-shadow: 0 0 0 3px var(--sf-accent-soft);
}

.shop-cat-check.is-active .shop-cat-check__box::after {
    content: '';
    position: absolute;
    top: 3px;
    left: 6px;
    width: 4px;
    height: 8px;
    border: solid #fff;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

.shop-cat-check__label {
    flex: 1;
    min-width: 0;
}

.shop-cat-group__row {
    display: flex;
    align-items: center;
    gap: 2px;
}

.shop-cat-group__row .shop-cat-check {
    flex: 1;
    min-width: 0;
}

.shop-cat-group__expand {
    width: 36px;
    height: 36px;
    flex-shrink: 0;
    border: none;
    background: transparent;
    color: #9ca3af;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    font-size: 18px;
    padding: 0;
}

.shop-cat-group__expand:hover {
    color: var(--sf-accent-dark);
    background: #fff;
}

.shop-cat-group__expand i {
    transition: transform .2s ease;
}

.shop-cat-group.is-expanded .shop-cat-group__expand i {
    transform: rotate(180deg);
}

.shop-cat-group__children {
    list-style: none;
    margin: 0;
    padding: 0 0 4px 14px;
    display: none;
    border-left: 2px solid var(--sf-accent-mid);
    margin-left: 18px;
}

.shop-cat-group.is-expanded .shop-cat-group__children {
    display: block;
}

.shop-cat-check--child {
    font-size: 13px;
    padding: 8px 10px;
}

/* Ağırlık / çeşit chip’leri */
.shop-filter-chips {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
}

.shop-filter-chips--colors {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.shop-filter-chip {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    padding: 8px 8px;
    border: 1px solid #dfe5e1;
    border-radius: 10px;
    background: #fff;
    color: #374151;
    font-family: inherit;
    font-size: 12.5px;
    font-weight: 650;
    line-height: 1.2;
    cursor: pointer;
    transition: border-color .15s ease, background .15s ease, color .15s ease, box-shadow .15s ease, transform .12s ease;
    text-align: center;
    word-break: break-word;
}

.shop-filter-chip:hover {
    border-color: color-mix(in srgb, var(--sf-accent) 45%, #dfe5e1);
    color: var(--sf-accent-dark);
    background: var(--sf-accent-soft);
}

.shop-filter-chip.is-active {
    border-color: var(--sf-accent);
    background: var(--sf-accent);
    color: #fff;
    box-shadow: 0 6px 14px color-mix(in srgb, var(--sf-accent) 28%, transparent);
}

.shop-filter-chip--color {
    font-size: 12px;
    font-weight: 600;
    min-height: 40px;
    padding: 8px 10px;
}

.shop-filter-chip:focus-visible {
    outline: none;
    box-shadow: 0 0 0 3px var(--sf-accent-soft);
}

.shop-filter-chip:active {
    transform: translateY(1px);
}

/* AJAX yükleme */
#shopCatalogMain {
    position: relative;
    transition: opacity 0.2s ease;
}

#shopCatalogMain.is-loading {
    opacity: 0.5;
    pointer-events: none;
}

#shopCatalogMain.is-loading::before {
    content: '';
    position: absolute;
    inset: 0;
    z-index: 5;
    background: rgba(255, 255, 255, 0.35);
}

#shopCatalogMain.is-loading::after {
    content: '';
    position: absolute;
    top: 120px;
    left: 50%;
    z-index: 6;
    width: 36px;
    height: 36px;
    margin-left: -18px;
    border: 3px solid #e5e7eb;
    border-top-color: var(--accent, #2e7d32);
    border-radius: 50%;
    animation: shopCatalogSpin 0.7s linear infinite;
}

@keyframes shopCatalogSpin {
    to { transform: rotate(360deg); }
}

@media (max-width: 768px) {
    .shop-sidebar-panel {
        padding: 12px;
        border-radius: 14px;
        margin-bottom: 8px;
    }

    .shop-cat-check-list {
        max-height: none;
    }

    .shop-filter-chips {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 6px;
    }

    .shop-filter-chips--colors {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .shop-filter-chip {
        min-height: 40px;
        font-size: 12px;
    }

    .shop-cat-check,
    .shop-filter-section__toggle {
        min-height: 44px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .shop-filter-section__toggle > i:last-child,
    .shop-cat-group__expand i,
    .shop-filter-chip,
    #shopCatalogMain {
        transition: none;
    }
}
