.where-buy-layout {
    display: grid;
    grid-template-columns: minmax(270px, 320px) minmax(0, 1fr);
    gap: 32px;
    align-items: start;
}

.where-buy-layout__results {
    min-width: 0;
}

.where-buy-filter {
    position: sticky;
    top: 96px;
    overflow: visible;
    border: 1px solid #e7e8ed;
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 10px 35px rgba(20, 26, 38, 0.06);
}

.where-buy-filter__heading {
    padding: 24px 24px 20px;
    border-bottom: 1px solid #eceef2;
}

.where-buy-filter__eyebrow {
    margin-bottom: 7px;
    color: var(--theme-base-color, #356df3);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.where-buy-filter__title {
    margin: 0;
    color: #20232a;
    font-size: 21px;
    line-height: 1.25;
}

.where-buy-filter__description {
    margin: 8px 0 0;
    color: #747983;
    font-size: 14px;
    line-height: 1.5;
}

.where-buy-filter__admin-warning {
    margin: 18px 20px 0;
    padding: 12px 14px;
    border: 1px solid #efb3b3;
    border-radius: 10px;
    background: #fff5f5;
    color: #8b2323;
    font-size: 13px;
    line-height: 1.45;
}

.where-buy-filter__admin-warning code {
    overflow-wrap: anywhere;
}

.where-buy-filter__form {
    padding: 4px 20px 22px;
}

.where-buy-filter__group {
    border-bottom: 1px solid #eceef2;
}

.where-buy-filter__group[open] {
    padding-bottom: 18px;
}

.where-buy-filter__summary {
    position: relative;
    display: flex;
    align-items: center;
    min-height: 54px;
    padding-right: 24px;
    color: #23262d;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    list-style: none;
}

.where-buy-filter__summary::-webkit-details-marker {
    display: none;
}

.where-buy-filter__summary::after {
    content: "";
    position: absolute;
    right: 4px;
    width: 8px;
    height: 8px;
    border-right: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: rotate(45deg) translateY(-2px);
    transition: transform 0.18s ease;
}

.where-buy-filter__group[open] > .where-buy-filter__summary::after {
    transform: rotate(225deg) translate(-2px, -2px);
}

.where-buy-filter__search-label {
    display: block;
    margin-bottom: 7px;
    color: #737985;
    font-size: 12px;
}

.where-buy-filter__search-control {
    position: relative;
}

.where-buy-filter__search-icon {
    position: absolute;
    z-index: 1;
    top: 50%;
    left: 13px;
    color: #8a909b;
    transform: translateY(-50%);
    pointer-events: none;
}

.where-buy-filter__search-input {
    width: 100%;
    height: 44px;
    padding: 0 40px 0 40px;
    border: 1px solid #dfe2e8;
    border-radius: 10px;
    outline: none;
    background: #f7f8fa;
    color: #22262e;
    font: inherit;
    transition: border-color 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}

.where-buy-filter__search-input:focus {
    border-color: var(--theme-base-color, #356df3);
    background: #fff;
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--theme-base-color, #356df3) 14%, transparent);
}

.where-buy-filter__city-clear {
    position: absolute;
    top: 50%;
    right: 7px;
    width: 30px;
    height: 30px;
    padding: 0;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: #737985;
    font-size: 22px;
    line-height: 1;
    cursor: pointer;
    transform: translateY(-50%);
}

.where-buy-filter__city-clear:hover {
    background: #e9ebef;
    color: #252932;
}

.where-buy-filter__city {
    position: relative;
}

.where-buy-filter__suggestions {
    position: absolute;
    z-index: 30;
    top: calc(100% + 6px);
    right: 0;
    left: 0;
    max-height: 280px;
    overflow-y: auto;
    padding: 6px;
    border: 1px solid #dfe2e8;
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 14px 35px rgba(20, 26, 38, 0.14);
}

.where-buy-filter__suggestion,
.where-buy-filter__suggestion-empty {
    display: block;
    width: 100%;
    padding: 10px 11px;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: #262a31;
    font: inherit;
    font-size: 14px;
    text-align: left;
}

.where-buy-filter__suggestion {
    cursor: pointer;
}

.where-buy-filter__suggestion:hover,
.where-buy-filter__suggestion.is-active {
    background: #f0f3f8;
}

.where-buy-filter__suggestion-empty {
    color: #8a909b;
}

.where-buy-filter__city-note,
.where-buy-filter__city-error {
    margin-top: 8px;
    font-size: 12px;
    line-height: 1.4;
}

.where-buy-filter__city-note {
    color: #747983;
}

.where-buy-filter__city-error {
    color: #bd2d2d;
}

.where-buy-filter__options {
    display: grid;
    gap: 8px;
}

.where-buy-filter__option {
    position: relative;
    display: grid;
    grid-template-columns: 22px minmax(0, 1fr) auto;
    gap: 10px;
    align-items: center;
    min-height: 38px;
    padding: 5px 7px;
    border-radius: 9px;
    cursor: pointer;
    transition: background 0.15s ease;
}

.where-buy-filter__option:hover {
    background: #f6f7f9;
}

.where-buy-filter__checkbox {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    clip-path: inset(50%);
    white-space: nowrap;
}

.where-buy-filter__checkmark {
    position: relative;
    width: 22px;
    height: 22px;
    border: 1px solid #d5d9e1;
    border-radius: 6px;
    background: #f8f9fb;
    transition: border-color 0.15s ease, background 0.15s ease;
}

.where-buy-filter__checkbox:checked + .where-buy-filter__checkmark {
    border-color: var(--theme-base-color, #356df3);
    background: var(--theme-base-color, #356df3);
}

.where-buy-filter__checkbox:checked + .where-buy-filter__checkmark::after {
    content: "";
    position: absolute;
    top: 4px;
    left: 7px;
    width: 6px;
    height: 10px;
    border-right: 2px solid #fff;
    border-bottom: 2px solid #fff;
    transform: rotate(45deg);
}

.where-buy-filter__checkbox:focus-visible + .where-buy-filter__checkmark {
    outline: 3px solid color-mix(in srgb, var(--theme-base-color, #356df3) 18%, transparent);
    outline-offset: 2px;
}

.where-buy-filter__option-name {
    overflow: hidden;
    color: #333842;
    font-size: 14px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.where-buy-filter__count {
    color: #8b919c;
    font-size: 13px;
}

.where-buy-filter__actions {
    display: grid;
    gap: 10px;
    padding-top: 20px;
}

.where-buy-filter__submit {
    min-height: 46px;
    padding: 11px 18px;
    border: 0;
    border-radius: 10px;
    background: var(--theme-base-color, #356df3);
    color: #fff;
    font: inherit;
    font-weight: 700;
    cursor: pointer;
    transition: filter 0.15s ease, transform 0.15s ease;
}

.where-buy-filter__submit:hover {
    filter: brightness(0.94);
}

.where-buy-filter__submit:active {
    transform: translateY(1px);
}

.where-buy-filter__reset {
    display: inline-flex;
    justify-content: center;
    padding: 7px 10px;
    color: #6f7580;
    font-size: 13px;
    text-decoration: none;
}

.where-buy-filter__reset:hover {
    color: #242830;
}

@media (max-width: 991px) {
    .where-buy-layout {
        grid-template-columns: minmax(0, 1fr);
        gap: 24px;
    }

    .where-buy-filter {
        position: static;
    }
}

@media (max-width: 575px) {
    .where-buy-filter {
        border-radius: 14px;
    }

    .where-buy-filter__heading {
        padding: 20px 18px 16px;
    }

    .where-buy-filter__form {
        padding: 2px 16px 18px;
    }
}

.where-buy-filter__admin-warning a {
    color: inherit;
    font-weight: 700;
    text-decoration: underline;
}

.where-buy-filter__admin-warning--success {
    border-color: #b8dec2;
    background: #f1faf3;
    color: #236333;
}
