/* YooFilter - wyglad z UIkit/YOOtheme, tu tylko uzupelnienia */
:root { --yf-accent: currentColor; }
.yf-el, .yf-offcanvas { --yf-track: rgba(128, 128, 128, .3); }

.yf-loading { opacity: .45; transition: opacity .15s; pointer-events: none; }
html.yf-busy { cursor: progress; }

.yf-num { opacity: .6; font-size: .85em; font-variant-numeric: tabular-nums; }
.yf-active-count.uk-badge { margin-left: 6px; min-width: 18px; height: 18px; font-size: 11px; padding: 0 5px; }
sup.yf-active-count { margin-left: 2px; }

/* listy opcji */
.yf-list > li > label { cursor: pointer; gap: 0; padding: 2px 0; }
.yf-list > li > label > a { color: inherit; }
.yf-dropdown { min-width: 260px; }
.yf-dropdown .yf-list { max-height: 320px; overflow-y: auto; padding-right: 4px; }
.yf-dropdown .uk-select { min-width: 220px; }
.yf-offcanvas .yf-list { max-height: none; }

/* przyciski */
.yf-buttons { gap: 6px; }
.yf-buttons .yf-num { margin-left: 4px; }
.yf-nav .uk-button.uk-active, .yf-nav > li.uk-active > a.uk-button { border-color: currentColor; }
.yf-chips { gap: 6px; margin-left: 0; }
.yf-chips > li { padding-left: 0; }
.yf-chip { display: inline-flex; align-items: center; }

/* suwak zakresu (dwa input[type=range] na jednym torze) */
.yf-slider { position: relative; height: 28px; margin: 0 9px 6px; }
.yf-slider-track { position: absolute; left: 0; right: 0; top: 13px; height: 3px; border-radius: 3px; background: var(--yf-track); }
.yf-slider-fill { position: absolute; top: 0; bottom: 0; background: var(--yf-accent); border-radius: 3px; }
.yf-slider input[type=range] {
    position: absolute; left: -9px; width: calc(100% + 18px); top: 4px; height: 20px; margin: 0;
    background: none; pointer-events: none; -webkit-appearance: none; appearance: none;
}
.yf-slider input[type=range]::-webkit-slider-runnable-track { background: none; height: 20px; }
.yf-slider input[type=range]::-moz-range-track { background: none; }
.yf-slider input[type=range]::-webkit-slider-thumb {
    -webkit-appearance: none; pointer-events: auto; width: 18px; height: 18px; margin-top: 1px; border-radius: 50%;
    background: #fff; border: 2px solid var(--yf-accent); box-shadow: 0 1px 3px rgba(0, 0, 0, .25); cursor: grab;
}
.yf-slider input[type=range]::-moz-range-thumb {
    pointer-events: auto; width: 14px; height: 14px; border-radius: 50%;
    background: #fff; border: 2px solid var(--yf-accent); box-shadow: 0 1px 3px rgba(0, 0, 0, .25); cursor: grab;
}
.yf-range .uk-form-label { display: block; margin-bottom: 2px; }

/* panel wysuwany */
.yf-offcanvas .uk-offcanvas-bar { width: min(380px, 90vw); }
.yf-oc-foot { position: sticky; bottom: 0; padding-top: 12px; background: inherit; }
.yf-accordion > li > .uk-accordion-title { font-size: 1rem; }
.yf-accordion > :nth-child(n+2) { margin-top: 22px; }
.uk-button.yf-on, .uk-button.yf-on:hover, .uk-button.yf-on:focus { background: var(--yf-accent) !important; border-color: var(--yf-accent) !important; color: #fff !important; }
.yf-on .yf-num { opacity: .85; }
.yf-more { margin-top: 6px; }
.yf-count { white-space: nowrap; }
.yf-accordion .uk-accordion-content { margin-top: 12px; }

/* przycisk plywajacy */
/* nad mapami (Leaflet/Google maja wlasne warstwy z-index), pod otwartym panelem (offcanvas = 1000) */
.yf-floating { position: fixed; z-index: 990; }

@media (prefers-reduced-motion: reduce) {
    .yf-loading { transition: none; }
}

/* okienka filtrow - wyrazne odciecie od tla niezaleznie od stylu motywu */
.yf-dropdown.uk-dropdown { box-shadow: 0 8px 28px rgba(0, 0, 0, .12); border-radius: 8px; -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); }
.yf-el .yf-chips { margin-left: 0; }
.yf-el .yf-chips > li { padding-left: 0; }
.yf-oc-foot { padding-bottom: 6px; }

/* szukanie w liscie: pokaz tylko trafienia (takze schowane pod "Pokaz wiecej") */
.yf-list.yf-searching > li { display: none !important; }
.yf-list.yf-searching > li.yf-hit { display: list-item !important; }
/* kolumna bywa przyklejona - dluga lista przewija sie wewnatrz, zeby dalo sie dojsc do kolejnych filtrow */
.yf-mode-sidebar .yf-list { max-height: 300px; overflow-y: auto; overscroll-behavior: contain; padding-right: 4px; }

/* resetowanie */
.yf-clear { display: inline-flex; align-items: center; }
.yf-reset-one { margin: -4px 0 6px; }
.yf-reset-one a { display: inline-flex; align-items: center; gap: 2px; }
/* plywajacy przycisk: pelny kolor marki - czytelny na zdjeciach i mapach */
.yf-floating .uk-button,
.yf-floating .uk-button:hover { background: var(--yf-accent, #77533a) !important; border-color: var(--yf-accent, #77533a) !important; color: #fff !important; box-shadow: 0 6px 20px rgba(0, 0, 0, .25); }
.yf-floating .uk-button .uk-badge { background: #fff !important; color: var(--yf-accent, #77533a) !important; }
/* pokazywany dopiero, gdy zwykly przycisk "Filtruj" zniknie z ekranu */
.yf-floating { transition: opacity .2s, transform .2s; }
.yf-floating.yf-float-off { opacity: 0; transform: translate(-50%, 20px) !important; pointer-events: none; }
