/* ── Reserve widths so dropdowns/pills don't cause layout jitter ──
   Toolbar grid cells have fixed widths via grid-template-columns, but
   interactive children (custom dropdown triggers, native selects, the
   active filters block) used `width: auto` so they sized to their
   text content. Switching dropdown value from "Sve cijene" to a longer
   "1500-2500€" caused the button to grow — neighbouring elements
   shifted. Forcing 100%-of-cell width + box-sizing keeps every control
   the same width regardless of selected text. */
.as-toolbar .aeres-toolbar__dropdown,
.as-toolbar .aeres-toolbar__group,
.as-toolbar select,
.as-toolbar .as-toolbar-capacity-select,
.as-toolbar .as-toolbar-surface-select,
.as-toolbar .as-facet-price-range,
.as-toolbar .ais-Menu,
.as-toolbar .ais-Menu-list,
.as-toolbar .ais-SortBy-select {
    width: 100%;
    box-sizing: border-box;
}
/* Custom dropdown trigger buttons — clip overflowing text to ellipsis
   instead of growing the button. */
.as-toolbar .aeres-toolbar__dropdown-trigger,
.as-toolbar .aeres-toolbar__dropdown button {
    width: 100%;
    min-width: 0;
    box-sizing: border-box;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
/* Active filter pills: cap individual pill width so a long value
   (e.g. brand "Mitsubishi Electric") can't push neighbouring pills
   out of frame. Combined with the existing flex-wrap, layout is
   stable as filters change. */
.as-active-filters-block .as-active-filters__pill {
    max-width: 100%;
    min-width: 0;
    box-sizing: border-box;
}

/* ── Active filters block in the toolbar Col 5 ─────────────
   Repurposes the cell that used to host the in-toolbar search field.
   Layout: header (title left, count right) + pills body that wraps.
   Width/height matches the cell's grid slot so no toolbar resize.
   Selectors are deliberately specific (.as-active-filters-block
   prefix on every body rule) to override legacy .as-active-filters
   and global .ais-Stats { display: none } rules elsewhere in this
   file without depending on cascade order. */
.as-toolbar-cell--filters {
    display: flex;
    align-items: stretch;
    justify-content: flex-end;    /* push block to the right edge of cell */
}
.as-active-filters-block {
    display: flex;
    flex-direction: column;
    width: 100%;
    max-width: 280px;             /* narrower so dropdown columns get more room */
    min-height: 0;            /* allow inner scroll */
    background: #f8fafc;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    padding: 8px 10px;
    gap: 6px;
    overflow: hidden;
}
.as-active-filters-block__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    flex: 0 0 auto;
}
.as-active-filters-block__title {
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.04em;
    color: #475569;
    text-transform: uppercase;
}
/* Result counter — wins over the global .ais-Stats{display:none} */
.as-active-filters-block__count,
.as-active-filters-block .ais-Stats {
    display: block !important;
    font-size: 12px;
    font-weight: 600;
    color: #0f172a;
    white-space: nowrap;
}
.as-active-filters-block .ais-Stats-text {
    font-size: 12px;
    font-weight: 600;
    color: #0f172a;
    white-space: nowrap;
}

/* Body — pills wrap, max 3 rows (enforced via JS row-counting in
   applyPillOverflow()). Block height is bounded by the grid cell, so
   `overflow: hidden` clips anything that escapes. No max-height —
   trust the JS overflow detector to insert the "+N" badge before
   any pill reaches the 4th row. Heavy-handed display rule wins
   over .as-active-filters:empty{display:none} and [hidden]{display:none}
   via the more specific compound selector. */
.as-active-filters-block .as-active-filters-block__body,
.as-active-filters-block .as-active-filters-block__body:empty,
.as-active-filters-block .as-active-filters-block__body[hidden] {
    flex: 1 1 auto;
    min-height: 0;
    overflow: hidden;
    display: block !important;
    padding: 0;
    margin: 0;
}
/* Empty-state hint */
.as-active-filters-block .as-active-filters-block__body:empty::before {
    content: 'Nema aktivnih filtera';
    display: block;
    color: #94a3b8;
    font-size: 12px;
    font-style: italic;
    padding: 2px 0;
}
/* Hide redundant inner label / clear-all rendered by renderPills() */
.as-active-filters-block .as-active-filters__label,
.as-active-filters-block .as-active-filters__clear-all {
    display: none !important;
}
/* Pills layout — wrap, tight gap so more fit. Smaller pill sizing
   (smaller text, less padding) increases pill density inside the
   narrow 220px column. */
.as-active-filters-block .as-active-filters__list {
    display: flex !important;
    flex-wrap: wrap;
    gap: 4px;
    padding: 0;
    margin: 0;
    list-style: none;
}
.as-active-filters-block .as-active-filters__pill {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 11px;
    line-height: 1.2;
    padding: 2px 6px 2px 8px;
    border-radius: 12px;
    background: #fff;
    border: 1px solid #d1d5db;
    max-width: 100%;
}
.as-active-filters-block .as-active-filters__pill-key {
    color: #64748b;
    font-weight: 500;
}
.as-active-filters-block .as-active-filters__pill-val {
    color: #0f172a;
    font-weight: 600;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.as-active-filters-block .as-active-filters__remove {
    background: transparent;
    border: 0;
    color: #94a3b8;
    cursor: pointer;
    font-size: 14px;
    line-height: 1;
    padding: 0 2px;
    margin-left: 2px;
}
.as-active-filters-block .as-active-filters__remove:hover {
    color: #475569 !important;
    background: transparent !important;        /* override legacy red hover bg */
}
/* Overflow indicator "+N" badge — small pill at the end of the visible row.
   Uses the same text color as regular pills (legibility) with a slightly
   gray background so it visually reads as "additional content" without
   shouting. Tap/keyboard-accessible; opens the overflow popup. */
.as-active-filters-block .as-active-filters__pill--overflow {
    background: #e2e8f0;
    color: #0f172a;
    border-color: #cbd5e1;
    font-weight: 700;
    cursor: pointer;
    padding: 2px 8px;
    user-select: none;
}
.as-active-filters-block .as-active-filters__pill--overflow:hover,
.as-active-filters-block .as-active-filters__pill--overflow:focus-visible {
    background: #cbd5e1;
    outline: none;
}

/* Overflow popup — appears anchored to the +N badge, lists all hidden
   pills with working remove buttons. Same pill styling as the in-toolbar
   pills (cloned DOM, plus the .--in-popup modifier in case we want to
   differentiate later). Floating panel with shadow + above-toolbar z. */
.as-active-filters__overflow-popup {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    box-shadow: 0 10px 25px -5px rgba(15, 23, 42, 0.18),
                0 4px 10px -2px rgba(15, 23, 42, 0.08);
    padding: 10px 12px;
    min-width: 220px;
    max-width: 320px;
    max-height: 280px;
    overflow-y: auto;
    z-index: 100002;        /* above the toolbar block + header */
}
.as-active-filters__overflow-list {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    padding: 0;
    margin: 0;
    list-style: none;
}
.as-active-filters__overflow-list .as-active-filters__pill {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 11px;
    line-height: 1.2;
    padding: 2px 6px 2px 8px;
    border-radius: 12px;
    background: #f8fafc;
    border: 1px solid #d1d5db;
    max-width: 100%;
}
.as-active-filters__overflow-list .as-active-filters__pill-key {
    color: #64748b;
    font-weight: 500;
}
.as-active-filters__overflow-list .as-active-filters__pill-val {
    color: #0f172a;
    font-weight: 600;
}
.as-active-filters__overflow-list .as-active-filters__remove {
    background: transparent;
    border: 0;
    color: #94a3b8;
    cursor: pointer;
    font-size: 14px;
    line-height: 1;
    padding: 0 2px;
    margin-left: 2px;
}
.as-active-filters__overflow-list .as-active-filters__remove:hover {
    color: #475569 !important;
    background: transparent !important;
}

/* Hide the InstantSearch searchBox stub — it's there only so the
   widget can wire up the query state. Search field lives in the header now. */
#searchbox {
    display: none !important;
}

/* Hide the filter-page search field and its stats counter.
   Two search UIs (header + filter page toolbar) was confusing; per user request
   the header search takes over filter-page text search. The InstantSearch
   `searchBox` widget is still attached programmatically — q parameter from
   URL still drives the helper — but the toolbar cell is hidden visually so
   only the header field is visible. The "Pretraga: '…' ✕" active-filter pill
   still appears when a query is active, giving users a way to clear it. */
.as-toolbar-cell--search {
    display: none !important;
}

/* Zaglavlje mora nadjačati ploče filter stranice — rubnu traku (9999), list
   sortiranja (10000), izbornik stupaca (10002) — jer bi inače padajući popis
   tražilice nestao ispod njih. Tema zaglavlju daje `position: relative;
   z-index: 1`, pa je to vlastiti sloj slaganja i unutarnji z-index popisa tu
   ne pomaže; dizati se mora sam sloj.

   Ali SAMO dok je popis otvoren. Dok je ovo stajalo bezuvjetno, zaglavlje je
   nadjačavalo i ono što ga MORA prekriti: ladicu košarice (9999), "Moje
   postavke prostora" (2200) i svaki drugi modal — svi se otvaraju iz <body>,
   pa su na /pretraga izlazili ISPOD logotipa, tražilice i ikona. Otvoren popis
   i otvoren modal ne postoje istovremeno, pa jedan uvjet rješava oboje.

   Uvjet gleda atribut `hidden`, kojim tražilica i inače otvara i zatvara popis
   (openDropdown/closeDropdown u modern-search.js) — ne treba nova klasa ni
   redak JavaScripta. */
.header-block-2:has(.ams-dropdown:not([hidden])) {
    z-index: 100000 !important;
}
.header-block-2:has(.ams-dropdown:not([hidden])) .ams-modern-search,
.header-block-2:has(.ams-dropdown:not([hidden])) .ams-dropdown {
    z-index: 100001 !important;
}
.as-price-range-header{
    font-size: 15px;
    font-weight: 500;
    line-height: 30px;
    margin-bottom: 30px;
    padding: 5px;
}

.as-price-range-reset{
    margin-top: 20px;
    padding: 5px;
    border: 0;
    background: none;
    font-size: .85rem;
    color: #1a578c;
    cursor: pointer;
}

.as-price-range-reset:hover{
    text-decoration: underline;
}

.rheostat-marker{
    display: none;
}

.as-mode-spec{
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin: 10px 0 6px;
}

.as-mode-card{
    position: relative;
    overflow: hidden;
    border-radius: 6px;
    padding: 10px 12px;
    min-height: 74px;
    gap: 10px;
    display: flex;
    flex-direction: column;
    align-items: center;
    z-index: 0;
}

.as-mode-card--heat{
    background: rgba(255,80,80,.06);
}

.as-mode-card--cool{
    background: rgba(0,120,240,.06);
}

.as-mode-card::before{
    content: "";
    position: absolute;
    inset: -2px;
    background-repeat: no-repeat;
    background-position: center;
    background-size: 140% 140%;
    opacity: .04;
    pointer-events: none;
    filter: grayscale(1);
}

.as-mode-card__title{
    position: relative;
    z-index: 1;
    font-weight: 700;
    font-size: 13px;
    line-height: 1.1;
    color: rgba(0,0,0,.78);
}

.as-mode-card__kw{
    position: relative;
    z-index: 1;
    font-weight: 800;
    font-size: 16px;
    line-height: 1.1;
    letter-spacing: -.01em;
    color: rgba(0,0,0,.90);
}

.as-mode-card__class{
    position: relative;
    font-weight: 800;
    font-size: 13px;
    line-height: 1.1;
    color: rgba(0,0,0,.70);
    z-index: 0;
}

.my-trash-icon{
    -webkit-mask: url("data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A//www.w3.org/2000/svg%22%20viewBox%3D%220%200%20512%20512%22%3E%3Cpath%20d%3D%22m62.205%20150%2026.569%20320.735C90.678%20493.865%20110.38%20512%20133.598%20512h244.805c23.218%200%2042.92-18.135%2044.824-41.265L449.795%20150H62.205zm118.781%20302c-7.852%200-14.458-6.108-14.956-14.063l-15-242c-.513-8.276%205.771-15.395%2014.033-15.908%208.569-.601%2015.381%205.757%2015.908%2014.033l15%20242c.531%208.57-6.25%2015.938-14.985%2015.938zM271%20437c0%208.291-6.709%2015-15%2015s-15-6.709-15-15V195c0-8.291%206.709-15%2015-15s15%206.709%2015%2015v242zm89.97-241.062-15%20242c-.493%207.874-7.056%2014.436-15.908%2014.033-8.262-.513-14.546-7.632-14.033-15.908l15-242c.513-8.276%207.764-14.297%2015.908-14.033%208.262.513%2014.546%207.632%2014.033%2015.908zM451%2060h-90V45c0-24.814-20.186-45-45-45H196c-24.814%200-45%2020.186-45%2045v15H61c-16.569%200-30%2013.431-30%2030%200%2016.567%2013.431%2030%2030%2030h390c16.569%200%2030-13.433%2030-30%200-16.569-13.431-30-30-30zm-120%200H181V45c0-8.276%206.724-15%2015-15h120c8.276%200%2015%206.724%2015%2015v15z%22/%3E%3C/svg%3E") no-repeat center/contain;
    mask: url("data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A//www.w3.org/2000/svg%22%20viewBox%3D%220%200%20512%20512%22%3E%3Cpath%20d%3D%22m62.205%20150%2026.569%20320.735C90.678%20493.865%20110.38%20512%20133.598%20512h244.805c23.218%200%2042.92-18.135%2044.824-41.265L449.795%20150H62.205zm118.781%20302c-7.852%200-14.458-6.108-14.956-14.063l-15-242c-.513-8.276%205.771-15.395%2014.033-15.908%208.569-.601%2015.381%205.757%2015.908%2014.033l15%20242c.531%208.57-6.25%2015.938-14.985%2015.938zM271%20437c0%208.291-6.709%2015-15%2015s-15-6.709-15-15V195c0-8.291%206.709-15%2015-15s15%206.709%2015%2015v242zm89.97-241.062-15%20242c-.493%207.874-7.056%2014.436-15.908%2014.033-8.262-.513-14.546-7.632-14.033-15.908l15-242c.513-8.276%207.764-14.297%2015.908-14.033%208.262.513%2014.546%207.632%2014.033%2015.908zM451%2060h-90V45c0-24.814-20.186-45-45-45H196c-24.814%200-45%2020.186-45%2045v15H61c-16.569%200-30%2013.431-30%2030%200%2016.567%2013.431%2030%2030%2030h390c16.569%200%2030-13.433%2030-30%200-16.569-13.431-30-30-30zm-120%200H181V45c0-8.276%206.724-15%2015-15h120c8.276%200%2015%206.724%2015%2015v15z%22/%3E%3C/svg%3E") no-repeat center/contain;
    background: #fff;
}

.aeres-search{
    margin: 0 auto;
    box-sizing: border-box;
    transform: none !important;
    filter: none !important;
}

.as-toast{
    position: fixed;
    left: 50%;
    bottom: 18px;
    transform: translateX(-50%);
    z-index: 99999;
    background: rgba(0,0,0,.86);
    color: #fff;
    padding: 10px 12px;
    border-radius: 12px;
    font-size: 13px;
    max-width: min(680px,calc(100vw - 24px));
    box-shadow: 0 10px 30px rgba(0,0,0,.25);
    display: none;
}

.as-toast.is-show{
    display: block;
}

.as-sidebar .as-sidebar-sticky{
    display: none;
}

.as-sidebar-sticky .as-sidebar-sticky__left{
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
}

.as-sidebar-sticky__title{
    font-size: 16px;
    font-weight: 800;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.as-sidebar-sticky__actions{
    display: flex;
    gap: 8px;
    align-items: center;
}

.as-sidebar-sticky__btn{
    border: 1px solid rgba(0,0,0,.12);
    background: #fff;
    border-radius: 10px;
    padding: 6px 10px;
    font-size: 13px;
    cursor: pointer;
}

.as-sidebar-sticky__btn:hover{
    filter: brightness(.98);
}

.as-toolbar{
    display: flex;
    align-items: center;
    gap: 16px;
    margin: 0 0 5px 0;
    flex-wrap: wrap;
    border-bottom: 1px solid #ccc;
    box-shadow: 0 4px 20px #5f5f5f;
    min-height: 64px;
    max-width: 100%;
}

.as-toolbar *{
    box-sizing: border-box;
    max-width: 100%;
}

.as-toolbar-left, .as-toolbar-right{
    display: flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
    padding: 0 0 0 1rem;
    max-width: 100%;
    min-height: 40px;
}

.as-toolbar-center{
    flex: 1 1 auto;
    min-width: 240px;
}

.as-toolbar-center #searchbox{
    max-width: 480px;
    margin: 0 auto;
}

.as-toolbar-availability-group, .as-toolbar-sort-group, .as-toolbar-price-group{
    display: flex;
    align-items: center;
    gap: 6px;
    min-height: 40px;

    /* No opacity transition — instant show/hide based on active index.
       The previous `transition: opacity 150ms ease` combined with the
       hidden/visible state toggle caused the in-stock toggle to fade in
       on every page load (visible "bljesak"). min-height reserves layout
       space so the appearance is silent. Non-active groups go fully
       hidden with display:none below — they don't even occupy DOM space. */
    visibility: hidden;
    opacity: 0;
    pointer-events: none;
}

.as-toolbar-availability, .as-toolbar-price, .as-toolbar-sort{
    min-height: 40px;
}

.as-toolbar-price, .as-toolbar-sort{
    min-height: 36px;
    display: flex;
    align-items: center;
}

.as-toolbar-price-group, .as-toolbar-sort-group{
    min-height: 32px;
}

.as-toolbar-price-group select, .as-toolbar-sort-group select{
    min-width: 170px;
}

.as-layout{
    display: grid;
    grid-template-columns: 310px minmax(0,1fr);
    gap: 5px;
}

.as-sidebar-title{
    font-size: .9rem;
    font-weight: 600;
}

.aeres-search .as-hit-title{
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 4;
    overflow: hidden;
    line-height: 1.3;
    min-height: calc(1.3em * 4);
    text-align: center;
}

.aeres-search .as-hit-price .cijena-label{
    margin-right: 5px;
}

.as-toolbar-availability-group[data-index="products_split"], .as-toolbar-sort-group[data-index="products_split"], .as-toolbar-price-group[data-index="products_split"]{
    visibility: visible;
    opacity: 1;
    pointer-events: auto;
}

.as-module-trash{
    position: absolute;
    right: 30px;
    top: 50%;
    transform: translateY(-50%);
    width: 28px;
    height: 28px;
    border: 0;
    background: transparent;
    cursor: pointer;
    opacity: .75;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.as-module-trash:hover{
    opacity: 1;
}

.as-module-trash svg{
    width: 18px;
    height: 18px;
    display: block;
}

.as-brand-widget:not([data-has-active="1"]) .as-module-trash{
    display: none;
}

.as-active-filters{
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 10px 0 6px 0;
    margin: 0 0 10px 0;
}

.as-active-filters:empty{
    display: none;
}

.as-chip{
    display: inline-flex;
    align-items: center;
    gap: 8px;
    border: 1px solid rgba(0,0,0,.12);
    background: #185284;
    border-radius: 999px;
    padding: 6px 10px;
    font-size: 13px;
    line-height: 1;
    cursor: pointer;
    user-select: none;
    color: #fff;
}

.as-chip:hover{
    filter: brightness(.98);
}

.as-chip__x{
    display: inline-flex;
    width: 18px;
    height: 18px;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    border: 1px solid rgba(0,0,0,.12);
    font-weight: 700;
    line-height: 1;
}

.as-chip--clear{
    border-style: dashed;
    opacity: .9;
}

.as-brand-widget .as-brand-list{
    overflow: hidden;
    max-height: 2000px;
    transition: max-height .25s ease;
    margin-top: .5rem;
    display: block;
}

.as-brand-widget.collapsed .as-brand-list{
    max-height: 0;
    display: none;
}

.as-brand-widget.as-module-loading > .as-brand-toggle::after{
    content: "";
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    margin-left: 10px;
    vertical-align: middle;
    background: currentColor;
    opacity: .35;
    animation: aeresPulse .9s ease-in-out infinite;
}

.as-facet-group{
    margin-bottom: 24px;
    min-height: 220px;
}

.as-facet-group[data-index="products_split"]{
    display: block;
}

.as-checkbox-item{
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: .85rem;
    margin-bottom: 4px;
}

.as-checkbox-item input[type="checkbox"]{
    margin: 0;
}

.as-checkbox-count{
    color: #9ca3af;
    font-size: .8rem;
}

.as-facet-group .as-empty-clear{
    gap: 6px;
    padding: 1em 1.7em;
    border-radius: 4px;
    border: none;
    font-size: .82em;
    color: #2d4156;
    background: #eaeff2;
    user-select: none;
    touch-action: manipulation;
    font-weight: 600;
    box-shadow: rgba(0,0,0,.12) 0 1px 3px,rgba(0,0,0,.24) 0 1px 2px;
    display: block;
    margin: 1rem auto 1rem;
    text-align: center;
}

.as-facet-price-range{
    margin-bottom: 10px;
    font-size: 10px;
    position: relative;
    z-index: 0;
    padding: 5px;
}

.as-facet-label{
    font-size: 11px;
    color: #606060;
    margin-bottom: .25rem;
    line-height: 30px;
}

.as-facet-price-range .ais-RangeSlider{
    padding: 0;
}

.as-facet-price-range .ais-RangeSlider__root{
    padding: .4rem 0 .1rem;
}

.as-facet-price-range .rheostat-background, .as-facet-price-range .rheostat-progress{
    position: absolute;
    left: 0;
    right: 0;
    height: 5px;
    top: 50%;
    margin-top: -3px;
    border-radius: 999px;
    pointer-events: none;
}

.as-facet-price-range .rheostat-background{
    background: #d0d5dd;
    z-index: 0;
}

.as-facet-price-range .rheostat-progress{
    background: #1a578c;
    z-index: 1;
}

.as-facet-price-range .rheostat-handle{
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: #fff;
    border: 8px solid #1a578c;
    box-shadow: 0 0 0 4px rgba(26,87,140,.25);
    top: 50%;
    transform: translate(-50%,-50%);
    margin-top: 0;
    z-index: 2;
}

.as-facet-price-range .rheostat-handle:hover{
    cursor: pointer;
}

.as-facet-price-range .rheostat-handle:focus{
    outline: none;
    box-shadow: 0 0 0 5px rgba(26,87,140,.35);
}

.as-facet-price-range .ais-RangeSlider .rheostat{
    margin: 8px 15px;
    overflow: visible;
}

.as-facet-price-range .ais-RangeSlider-tooltip{
    display: none;
}

.as-brand-widget{
    padding: 5px;
}

.as-brand-toggle{
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: .45rem 2.2rem .45rem .75rem;
    position: relative;
    border: 1px solid rgba(255,255,255,.12);
    background: #1a578c;
    color: #fff;
    font-size: 12px;
    text-align: left;
    cursor: pointer;
    border-radius: 4px;
    font-weight: 500;
    text-transform: uppercase;
    transition: background-color .2s cubic-bezier(.3,0,.5,1);
}

.as-brand-toggle:hover{
    background: #164773;
}

.as-brand-toggle::after{
    content: "▾";
    position: absolute;
    right: .75rem;
    top: 50%;
    transform: translateY(-50%) rotate(0deg);
    transform-origin: center;
    font-size: 1.8rem;
    line-height: 1;
    transition: transform .2s ease;
    color: #fff;
}

.as-brand-widget.collapsed .as-brand-toggle::after{
    transform: translateY(-50%) rotate(-90deg);
}

/* ─────────────────────────────────────────────────────────────
   BRAND FACET — logo + count layout
   Row: [checkbox] [logo OR text label] [count badge]
   ─────────────────────────────────────────────────────────── */
.as-brand-item{
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 11px;
    text-transform: uppercase;
    margin: 3px 4px;
    padding: 6px 8px;
    border-radius: 6px;
    border: 1px solid transparent;
    cursor: pointer;
    transition: background 120ms ease, border-color 120ms ease;
    min-height: 36px;
}

.as-brand-item:hover{
    background: #f8fafc;
    border-color: #e2e8f0;
}

.as-brand-item.is-refined{
    background: #eef5fc;
    border-color: rgba(26,87,140,.35);
}

.as-brand-item input[type="checkbox"]{
    margin: 0;
    width: 18px;
    height: 18px;
    flex: 0 0 18px;
    cursor: pointer;
    accent-color: #1a578c;
}

/* Logo wrap — fiksna visina, proporcionalna širina (contain). */
.as-brand-item .as-brand-logo{
    flex: 1 1 auto;
    display: inline-flex;
    align-items: center;
    height: 28px;
    max-width: 100%;
    overflow: hidden;
}

.as-brand-item .as-brand-logo img{
    max-height: 100%;
    max-width: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    object-position: left center;
    display: block;
}

/* Text-only fallback (brand bez logo URL-a u mapi) */
.as-brand-item:not(.has-logo) .as-brand-label{
    flex: 1 1 auto;
    font-weight: 700;
    letter-spacing: 0.02em;
    color: #0f172a;
}

/* Screen-reader-only label kad imamo logo (čuvamo naziv za a11y) */
.as-brand-label--sr{
    position: absolute !important;
    width: 1px; height: 1px;
    padding: 0; margin: -1px;
    overflow: hidden;
    clip: rect(0,0,0,0);
    white-space: nowrap;
    border: 0;
}

/* Count badge — desni rub reda */
.as-brand-item .as-brand-count{
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 26px;
    height: 20px;
    padding: 0 7px;
    border-radius: 999px;
    background: #f1f5f9;
    color: #64748b;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0;
    text-transform: none;
    line-height: 1;
}

.as-brand-item.is-refined .as-brand-count{
    background: #1a578c;
    color: #fff;
}

.as-brand-item:hover .as-brand-count{
    background: #e2e8f0;
}

.as-brand-item.is-refined:hover .as-brand-count{
    background: #134a78;
}


.as-hits.as-hits--loading{
    display: none !important;
}

.as-results{
    min-height: 600px;
}

.as-results-header .as-h1-query{
    font-weight: 700;
}

.dostupnost-i-dostava-vertikalno-filter{
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
}

.as-results-group, .as-facet-group{
    display: none;
    background: #fff;
    box-shadow: 0 2px 12px rgba(0,0,0,.06);
    width: 100%;
    overflow-x: hidden;
    padding: .1rem;
    border-radius: 15px;
}

.as-results-group[data-index="products_split"]{
    display: block;
}

.as-pagination{
    display: flex;
    justify-content: center;
    margin: 24px 0;
}

.as-pagination .ais-Pagination{
    display: inline-flex;
    align-items: center;
    gap: 2px;
    padding: 4px 8px;
    border-radius: 8px;
    border: 1px solid #ddd;
    background: #fff;
    font-size: .9rem;
}

.as-pagination .ais-Pagination-list{
    display: inline-flex;
    align-items: center;
    margin: 0;
    padding: 0;
    list-style: none;
}

.as-pagination .ais-Pagination-item{
    margin: 0;
}

.as-pagination .ais-Pagination-link{
    display: block;
    padding: 6px 15px;
    border-radius: 4px;
    text-decoration: none;
    color: #111;
    border: 1px solid transparent;
    white-space: nowrap;
}

.as-pagination .ais-Pagination-item--selected .ais-Pagination-link{
    border-color: #111;
    font-weight: 600;
}

.as-pagination .ais-Pagination-item--disabled .ais-Pagination-link{
    opacity: .4;
    cursor: default;
    background: #f8f8f8;
    color: #a2a6ac;
}

.as-pagination .ais-Pagination-item:not(.ais-Pagination-item--disabled) .ais-Pagination-link:hover{
    background: #f3f3f3;
}

.as-pagination .ais-Pagination-item--ellipsis span{
    padding: 6px 8px;
    color: #666;
}

.as-related-wrapper{
    margin-top: 24px;
    min-height: 140px;
    display: block;
}

.as-related-box{
    border-radius: 8px;
    margin-top: 10px;
    margin-bottom: 10px;
}

.as-related-title{
    font-size: 1.25rem;
    font-weight: 600;
    margin: 0 0 12px;
}

.as-related-empty{
    margin: 8px 0 0;
    font-size: .9rem;
    color: #666;
}

.as-related-list{
    display: grid;
    grid-template-columns: repeat(auto-fit,minmax(260px,1fr));
    gap: 12px;
}

.as-related-chip{
    width: 100%;
    display: flex;
    align-items: center;
    padding: 5px 10px;
    border-radius: 8px;
    border: 1px solid #e3e6e8;
    background: #fff;
    font-size: .95rem;
    text-align: left;
    cursor: pointer;
    box-shadow: 0 1px 3px rgba(0,0,0,.06);
    transition: box-shadow .15s ease,transform .15s ease,border-color .15s ease,background-color .15s ease;
}

.as-related-chip:hover{
    border-color: #c8d0da;
    box-shadow: 0 4px 10px rgba(0,0,0,.08);
    transform: translateY(-1px);
    background-color: #f9fafb;
}

.as-related-chip:focus-visible{
    outline: 2px solid #0077ff;
    outline-offset: 2px;
}

/* Live count badge — pokazuje broj rezultata u trenutnom kontekstu.
   Ide na kraj chip-a, prigušene boje pa ne ometa label. */
.as-related-count {
    margin-left: auto;
    padding: 2px 8px;
    font-size: 11px;
    font-weight: 600;
    color: #6b7280;
    background: #f3f4f6;
    border-radius: 10px;
    font-variant-numeric: tabular-nums;
    line-height: 1.4;
    flex-shrink: 0;
}
.as-related-chip:hover .as-related-count {
    background: #fff;
    color: #374151;
}


/* Toast — kratka obavijest kad se filtri uklone zbog nekompatibilnosti
   s odabranim suggestion query-em. Fade-in odozdo, auto-skrije se. */
.as-related-toast {
    position: fixed;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%) translateY(8px);
    z-index: 100000;
    padding: 12px 20px;
    background: rgba(17, 24, 39, 0.92);
    color: #fff;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 500;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
    max-width: 90vw;
    opacity: 0;
    animation: aeresRelatedToastIn 0.25s ease-out forwards;
    pointer-events: none;
}
.as-related-toast.is-out {
    animation: aeresRelatedToastOut 0.35s ease-in forwards;
}
@keyframes aeresRelatedToastIn {
    to { opacity: 1; transform: translateX(-50%) translateY(0); }
}
@keyframes aeresRelatedToastOut {
    to { opacity: 0; transform: translateX(-50%) translateY(8px); }
}

.as-related-icon{
    flex: 0 0 auto;
    width: 32px;
    height: 32px;
    border-radius: 999px;
    border: 1px solid #d1d5db;
    background: #f3f4f6;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-right: 12px;
    font-size: 16px;
}

.as-related-label{
    flex: 1 1 auto;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.as-empty{
    padding: 24px;
    text-align: left;
}

.as-empty-title{
    font-size: 1.2rem;
    margin: 0 0 8px;
}

.as-empty-subtitle{
    margin: 0 0 8px;
    font-size: .95rem;
    color: #555;
}

.as-empty-tips{
    margin: 0 0 16px 18px;
    padding: 0;
    font-size: .9rem;
    color: #444;
}

.as-empty-tips li{
    margin-bottom: 4px;
}

.as-empty-actions{
    margin-bottom: 16px;
}

.as-empty-clear{
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    border-radius: 999px;
    border: 1px solid #1a578c;
    background: #1a578c;
    color: #fff;
    font-size: .9rem;
    cursor: pointer;
    transition: background .15s ease,box-shadow .15s ease,transform .05s ease;
}

.as-empty-clear:hover{
    background: #164671;
    box-shadow: 0 2px 6px rgba(0,0,0,.18);
    transform: translateY(-1px);
}

.as-empty-cats h3{
    font-size: 1rem;
    margin: 0 0 8px;
}

.as-empty-cats-list{
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 12px;
}

.as-empty-cat-link{
    padding: 6px 12px;
    border-radius: 999px;
    border: 1px solid #d1d5db;
    background: #f9fafb;
    font-size: .85rem;
    text-decoration: none;
    color: #111827;
    transition: background .15s ease,border-color .15s ease;
}

.as-empty-cat-link:hover{
    background: #eef2ff;
    border-color: #1a578c;
}

.as-empty-note{
    font-size: .85rem;
    color: #6b7280;
}

.as-results-loading, .as-hits.as-results-loading{
    opacity: .25;
    filter: blur(2px);
    transition: opacity 200ms ease,filter 200ms ease;
    pointer-events: none;
}

.as-results-loaded, .as-hits.as-results-loaded{
    opacity: 1;
    filter: blur(0);
    transition: opacity 200ms ease,filter 200ms ease;
}

.ams-price-actions{
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 5px;
    flex-wrap: nowrap;
    margin-top: 2px;
}

.ams-cart-note{
    position: absolute !important;
    left: 50% !important;
    bottom: 100% !important;
    transform: translateX(-50%) translateY(-8px) !important;
    padding: 6px 10px !important;
    border-radius: 999px !important;
    background: #ffd814 !important;
    color: #000 !important;
    font-size: 1rem !important;
    line-height: 1.3 !important;
    white-space: nowrap !important;
    box-shadow: 0 6px 16px rgba(0,0,0,.25) !important;
    opacity: 0 !important;
    pointer-events: none !important;
    transition: opacity .18s ease-out,transform .18s ease-out !important;
    z-index: 5 !important;
}

.ams-cart-note.is-visible{
    opacity: 1 !important;
    pointer-events: auto !important;
    transform: translateX(-50%) translateY(0) !important;
}

.ams-cart-note-spinner{
    width: 10px;
    height: 10px;
    border-radius: 999px;
    border: 2px solid currentColor;
    border-top-color: transparent;
    display: none;
}

.ams-cart-note.is-loading .ams-cart-note-spinner{
    display: inline-block;
    animation: ams-spin .8s linear infinite;
}

/* Uklonjeno: font-size .8rem, padding, width:auto i gap. To je bio stil za
   redak rezultata stare Algolia pretrage, koje vise nema. Jedini nositelji tih
   razreda na ovoj stranici su sada kartice filtera, a one moraju izgledati kao
   gumbi na kategorijama — ovo ih je smanjivalo na 12px. Mjere dolaze iz
   .aeres-btn u template.css. */

button.ams-add-to-cart img {
    width: 20px;
    height: 20px;
}

button.ams-buy-now .ams-buy-now__icon {
    width: 20px;
    height: 20px;
}

.as-sale-badge{
    position: absolute;
    top: -2px;
    right: 135px;
    width: 65px;
    height: 65px;
    z-index: 0;
    pointer-events: none;
}

.as-sale-badge svg{
    width: 100%;
    height: 100%;
    display: block;
}

.as-sale-badge .as-sale-badge__shape{
    fill: #e53935;
}

.as-sale-badge .as-sale-badge__text{
    fill: #fff;
    font-family: system-ui,-apple-system,Segoe UI,Roboto,Arial,sans-serif;
    font-weight: 800;
    letter-spacing: .5px;
}

.ais-Stats{
    display: none;
}

.ais-RefinementList-count{
    display: none;
}

[class^=ais-]{
    box-sizing: border-box;
}

.ais-Breadcrumb-list, .ais-Carousel-list, .ais-CurrentRefinements-list, .ais-HierarchicalMenu-list, .ais-Hits-list, .ais-FrequentlyBoughtTogether-list, .ais-LookingSimilar-list, .ais-RelatedProducts-list, .ais-TrendingItems-list, .ais-Results-list, .ais-InfiniteHits-list, .ais-InfiniteResults-list, .ais-Menu-list, .ais-NumericMenu-list, .ais-Pagination-list, .ais-RatingMenu-list, .ais-RefinementList-list, .ais-ToggleRefinement-list{
    margin: 0;
    padding: 0;
    list-style: none;
}

.ais-Carousel-navigation, .ais-ClearRefinements-button, .ais-CurrentRefinements-delete, .ais-CurrentRefinements-reset, .ais-GeoSearch-redo, .ais-GeoSearch-reset, .ais-HierarchicalMenu-showMore, .ais-InfiniteHits-loadPrevious, .ais-InfiniteHits-loadMore, .ais-InfiniteResults-loadMore, .ais-Menu-showMore, .ais-RangeInput-submit, .ais-RefinementList-showMore, .ais-SearchBox-submit, .ais-SearchBox-reset, .ais-VoiceSearch-button{
    padding: 0;
    overflow: visible;
    font: inherit;
    line-height: normal;
    color: inherit;
    background: none;
    border: 0;
    cursor: pointer;
    user-select: none;
}

.ais-Carousel-navigation::-moz-focus-inner, .ais-ClearRefinements-button::-moz-focus-inner, .ais-CurrentRefinements-delete::-moz-focus-inner, .ais-CurrentRefinements-reset::-moz-focus-inner, .ais-GeoSearch-redo::-moz-focus-inner, .ais-GeoSearch-reset::-moz-focus-inner, .ais-HierarchicalMenu-showMore::-moz-focus-inner, .ais-InfiniteHits-loadPrevious::-moz-focus-inner, .ais-InfiniteHits-loadMore::-moz-focus-inner, .ais-InfiniteResults-loadMore::-moz-focus-inner, .ais-Menu-showMore::-moz-focus-inner, .ais-RangeInput-submit::-moz-focus-inner, .ais-RefinementList-showMore::-moz-focus-inner, .ais-SearchBox-submit::-moz-focus-inner, .ais-SearchBox-reset::-moz-focus-inner, .ais-VoiceSearch-button::-moz-focus-inner{
    padding: 0;
    border: 0;
}

.ais-Carousel-navigation[disabled], .ais-ClearRefinements-button[disabled], .ais-CurrentRefinements-delete[disabled], .ais-CurrentRefinements-reset[disabled], .ais-GeoSearch-redo[disabled], .ais-GeoSearch-reset[disabled], .ais-HierarchicalMenu-showMore[disabled], .ais-InfiniteHits-loadPrevious[disabled], .ais-InfiniteHits-loadMore[disabled], .ais-InfiniteResults-loadMore[disabled], .ais-Menu-showMore[disabled], .ais-RangeInput-submit[disabled], .ais-RefinementList-showMore[disabled], .ais-SearchBox-submit[disabled], .ais-SearchBox-reset[disabled], .ais-VoiceSearch-button[disabled]{
    cursor: default;
}

.ais-InfiniteHits-loadPrevious, .ais-InfiniteHits-loadMore, .ais-HierarchicalMenu-showMore, .ais-Menu-showMore, .ais-RefinementList-showMore{
    overflow-anchor: none;
}

.ais-Breadcrumb-list, .ais-Breadcrumb-item, .ais-Pagination-list, .ais-RangeInput-form, .ais-RatingMenu-link, .ais-PoweredBy{
    display: flex;
    align-items: center;
}

.ais-GeoSearch, .ais-GeoSearch-map{
    height: 100%;
}

.ais-HierarchicalMenu-list .ais-HierarchicalMenu-list{
    margin-left: 1em;
}

.ais-PoweredBy-logo{
    display: block;
    height: 1.2em;
    width: auto;
}

.ais-PoweredBy-text{
    margin-right: .3rem;
}

.ais-RatingMenu-starIcon{
    display: block;
    width: 20px;
    height: 20px;
}

.ais-SearchBox-input::-ms-clear, .ais-SearchBox-input::-ms-reveal{
    display: none;
    width: 0;
    height: 0;
}

.ais-SearchBox-input::-webkit-search-decoration, .ais-SearchBox-input::-webkit-search-cancel-button, .ais-SearchBox-input::-webkit-search-results-button, .ais-SearchBox-input::-webkit-search-results-decoration{
    display: none;
}

.as-brand-widget{
    padding: 6px;
}

.as-brand-widget .as-brand-toggle{
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: .45rem 2.2rem .45rem .75rem;
    position: relative;
    border: 1px solid rgba(255,255,255,.12);
    background: #1a578c;
    color: #fff;
    font-size: 12px;
    text-align: left;
    cursor: pointer;
    border-radius: 4px;
    font-weight: 500;
    text-transform: uppercase;
}

.as-brand-widget .as-brand-toggle::after{
    content: "▾";
    position: absolute;
    right: .75rem;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.8rem;
    line-height: 1;
    color: #fff;
}

.as-brand-widget.collapsed .as-brand-list{
    display: none;
}

.as-brand-widget .as-energy-list{
    display: flex;
    flex-direction: column;
    gap: 18px;
    padding: 6px 2px;
}

.as-energy-head{
    display: flex;
    align-items: center;
    gap: 10px;
}

.as-energy-checkbox{
    width: 18px;
    height: 18px;
    flex: 0 0 auto;
}

.as-energy-title{
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .04em;
    text-transform: uppercase;
    color: #111;
}

.as-energy-desc{
    font-size: 12px;
    line-height: 1.4;
    color: #555;
    margin: 4px 0 0 28px;
}

.as-brand-widget .as-brand-toggle:hover{
    background: #164773;
}

.as-brand-widget.collapsed .as-brand-toggle::after{
    transform: translateY(-50%) rotate(-90deg);
}

.as-brand-widget{
    padding: 6px;
}

.as-brand-widget .as-brand-toggle{
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: .45rem 2.2rem .45rem .75rem;
    position: relative;
    border: 1px solid rgba(255,255,255,.12);
    background: #1a578c;
    color: #fff;
    font-size: 12px;
    text-align: left;
    cursor: pointer;
    border-radius: 4px;
    font-weight: 500;
    text-transform: uppercase;
}

.as-brand-widget .as-brand-toggle::after{
    content: "▾";
    position: absolute;
    right: .75rem;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.8rem;
    line-height: 1;
    color: #fff;
}

.as-brand-widget.collapsed .as-brand-list{
    display: none;
}

.as-brand-widget .as-health-list{
    display: flex;
    flex-direction: column;
    gap: 18px;
    padding: 6px 2px;
}

.as-health-head{
    display: flex;
    align-items: center;
    gap: 10px;
}

.as-health-checkbox{
    width: 18px;
    height: 18px;
    flex: 0 0 auto;
}

.as-health-title{
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .04em;
    text-transform: uppercase;
    color: #111;
}

.as-health-desc{
    font-size: 12px;
    line-height: 1.4;
    color: #555;
    margin: 4px 0 0 28px;
}

.as-brand-widget .as-brand-toggle:hover{
    background: #164773;
}

.as-brand-widget.collapsed .as-brand-toggle::after{
    transform: translateY(-50%) rotate(-90deg);
}

:root{
    --as-overlay: rgba(0,0,0,.55);
    --as-panel-w: min(92vw,360px);
    --as-bottombar-h: 58px;
    --as-radius: 16px;
}

body.as-lock-scroll{
    overflow: hidden !important;
    height: 100vh;
    touch-action: none !important;
}

.as-mobile-overlay{
    position: fixed;
    inset: 0;
    background: var(--as-overlay);
    opacity: 0;
    pointer-events: none;
    transition: opacity 180ms ease;
    z-index: 9998;
}

.as-mobile-bar{
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    height: var(--as-bottombar-h);
    display: none;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    background: #fff;
    border-top: 1px solid #e5e7eb;
    box-shadow: 0 -6px 18px rgba(0,0,0,.10);
    z-index: 9997;
}

.as-mobile-btn{
    flex: 1 1 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 44px;
    border-radius: 10px;
    border: 1px solid #d1d5db;
    background: #fff;
    color: #111;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
}

.as-mobile-btn--primary{
    border-color: #1a578c;
    background: #1a578c;
    color: #fff;
}

.as-mobile-btn:active{
    transform: translateY(1px);
}

.as-sort-sheet{
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    background: #fff;
    border-top-left-radius: var(--as-radius);
    border-top-right-radius: var(--as-radius);
    box-shadow: 0 -10px 28px rgba(0,0,0,.18);
    padding: 12px 12px 18px;
    z-index: 10000;
    transform: translateY(110%);
    transition: transform 220ms ease;
    max-height: 70vh;
    overflow: auto;
}

.as-sort-sheet__head{
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 8px;
}

.as-sort-sheet__title{
    font-weight: 800;
    font-size: 1rem;
    margin: 0;
}

.as-sort-sheet__close{
    width: 36px;
    height: 36px;
    border-radius: 10px;
    border: 1px solid #e5e7eb;
    background: #fff;
    cursor: pointer;
}

.as-sort-sheet__close:active{
    transform: translateY(1px);
}

body.as-sort-open .as-mobile-overlay, body.as-filters-open .as-mobile-overlay{
    opacity: 1;
    pointer-events: auto;
}

body.as-sort-open .as-sort-sheet{
    transform: translateY(0);
}

.as-sidebar-close{
    display: none;
}

@media (min-width: 992px){
    .as-toolbar{
        /* position: sticky; */
        top: 0;
        z-index: 50;
        background: #fff;
    }

    .as-filters-sticky .as-filters-close{
        display: none !important;
    }
}

@media (max-width: 768px){
    .aeres-search{
        padding-bottom: 0;
    }

    .as-toolbar{
        display: none !important;
    }

    .as-layout{
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .as-sidebar{
        position: fixed;
        top: 0;
        bottom: 0;
        left: 0;
        width: var(--as-panel-w);
        max-width: var(--as-panel-w);
        background: #fff;
        transform: translateX(-105%);
        transition: transform 220ms ease;
        z-index: 9999;
        overflow-y: auto;
        overflow-x: hidden;
        padding: 12px 10px 18px;
        box-shadow: 10px 0 28px rgba(0,0,0,.18);
    }

    body.as-filters-open .as-sidebar{
        transform: translateX(0);
    }

    .as-sidebar-title{
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 10px;
        margin: 0 0 10px;
        padding: 10px 8px;
        border-bottom: 1px solid #e5e7eb;
    }

    .as-sidebar-title::before{
        content: "Filteri";
        font-size: 1rem;
        font-weight: 800;
    }

    .as-sidebar-close{
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 36px;
        height: 36px;
        border-radius: 10px;
        border: 1px solid #e5e7eb;
        background: #fff;
        cursor: pointer;
    }

    .as-sidebar .as-sidebar-sticky{
        display: flex;
        position: sticky;
        top: 0;
        z-index: 10;
        background: #fff;
        padding: 10px 0 8px 0;
        margin: 0 0 8px 0;
        border-bottom: 1px solid rgba(0,0,0,.08);
        align-items: center;
        justify-content: space-between;
        gap: 10px;
    }

    .as-mobile-bar{
        display: flex;
    }

    .as-sidebar *, .as-sort-sheet *, #searchbox *{
        box-sizing: border-box;
        max-width: 100%;
    }

    select{
        width: 100%;
        min-height: 44px;
        font-size: 16px;
        padding: 10px 12px;
    }

    .ais-SearchBox-form{
        width: 100%;
    }

    .ais-SearchBox-input{
        width: 100%;
        min-height: 44px;
        font-size: 16px;
        padding: 10px 12px;
    }

    .as-brand-item, .ais-ToggleRefinement-label{
        display: flex;
        align-items: center;
        gap: 10px;
        padding: 10px 0;
        font-size: 16px;
    }

    .as-brand-item input[type="checkbox"], .ais-ToggleRefinement-checkbox{
        width: 30px;
        height: 30px;
        min-height: 30px;
    }

    /* Sirinu 100% ionako daje .aeres-btn; pravilo je ostalo od stare pretrage. */

    .as-health-checkbox{
        width: 24px;
        height: 24px;
    }

    .as-health-desc{
        margin-left: 34px;
        font-size: 14px;
    }

    .as-energy-checkbox{
        width: 24px;
        height: 24px;
    }

    .as-energy-desc{
        margin-left: 34px;
        font-size: 14px;
    }
}

@media (max-width: 767.98px){
    .as-related-list{
        grid-template-columns: 1fr;
    }
}

@media (max-width: 420px){
    .as-mode-spec{
        gap: 8px;
    }

    .as-mode-card::before{
        background-size: 72px 72px;
        opacity: .05;
    }
}

@media (max-width: 380px){
}

.as-toolbar{
    background:#fff;
    padding: 8px 10px;
    box-shadow: 0 2px 12px rgba(0,0,0,.06);
    border: 1px solid rgba(0,0,0,.08);
}
.as-toolbar-search{
    flex: 1 1 auto;
    min-width: 220px;
}
.as-toolbar .ais-SearchBox-form{
    display:flex;
    gap: 8px;
    align-items:center;
}
.as-toolbar .ais-SearchBox-input{
    appearance: none;
    border: 1px solid rgba(0, 0, 0, .12);
    background: #fff;
    border-radius: 10px;
    padding: 8px 34px 8px 12px;
    font-size: 14px;
    line-height: 1.2;
    min-height: 40px;
    cursor: pointer;
}
.as-toolbar .ais-SearchBox-input:focus{
    outline:none;
    box-shadow: 0 0 0 4px rgba(26,87,140,.18);
    border-color: rgba(26,87,140,.45);
}
.as-toolbar .ais-SearchBox-submit,
.as-toolbar .ais-SearchBox-reset{
    width: 40px;
    height: 40px;
    border-radius: 999px;
    border: 1px solid rgba(0,0,0,.12);
    background:#fff;
}
.as-toolbar .ais-SearchBox-submit:hover,
.as-toolbar .ais-SearchBox-reset:hover{
    filter: brightness(.98);
}

.as-toolbar .ais-ToggleRefinement-label{
    display:flex;
    align-items:center;
    gap: 10px;
    padding: 0;
    font-size: 14px;
    cursor: pointer;
    user-select: none;
}
.as-toolbar .ais-ToggleRefinement-checkbox{
    width: 20px;
    height: 20px;
    margin: 0;
}

.as-toolbar-price-group{
    gap: 10px;
}
.as-toolbar-price-group .ais-RangeInput,
.as-toolbar-price-group .ais-RangeInput-form{
    display:flex;
    gap: 8px;
    align-items:center;
}
.as-toolbar-price-group input{
    min-height: 40px;
    border-radius: 10px;
    border: 1px solid rgba(0,0,0,.12);
    padding: 8px 10px;
    font-size: 14px;
    width: 110px;
}
.as-toolbar-price-group input:focus{
    outline:none;
    box-shadow: 0 0 0 4px rgba(26,87,140,.18);
    border-color: rgba(26,87,140,.45);
}

.as-toolbar-mobile{
    display:none;
    padding: 8px 6px 14px;
    border-bottom: 1px solid rgba(0,0,0,.08);
    margin: 0 0 12px 0;
}
.as-toolbar-mobile__inner{
    display:flex;
    flex-direction:column;
    gap: 12px;
}
.as-toolbar-mobile__row{
    display:flex;
    flex-direction:column;
    gap: 6px;
}
.as-toolbar-mobile__label{
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .02em;
    text-transform: uppercase;
    color: rgba(0,0,0,.75);
}
.as-toolbar-mobile select,
.as-toolbar-mobile .ais-SortBy-select,
.as-toolbar-mobile .ais-SearchBox-input,
.as-toolbar-mobile input{
    width:100%;
    max-width:100%;
}
@media (max-width: 768px){
    .as-toolbar-mobile{display:block;}
    .as-toolbar-mobile .ais-SearchBox-submit,
    .as-toolbar-mobile .ais-SearchBox-reset{
        width: 44px;
        height: 44px;
    }
    .as-toolbar-mobile .ais-ToggleRefinement-label{
        padding: 8px 0;
        font-size: 16px;
    }
    .as-toolbar-mobile .ais-ToggleRefinement-checkbox{
        width: 30px;
        height: 30px;
    }
}

/* Stretched link — overlay počinje nakon image kolone (80px) da ne blokira imgpop hover */
.as-hit-row .btn-glavni::after{
    content: '';
    position: absolute;
    inset: 0 0 0 var(--as-col-img, 80px);
    z-index: 1;
}

/* Elementi koji trebaju ostati iznad overlaya */
.as-hit-row .as-col-config-trigger{
    position: relative;
    z-index: 2;
}

.najniza-cijena-prekrizeno{
    text-decoration: line-through;
    opacity: .75;
    font-weight: 700;
    font-size: 0.80rem;
    white-space: nowrap;
}

@media (max-width: 768px){

}

.as-hits-head{
    display: block;
    margin-top: 16px;
    background: #f3f4f6;
    border-bottom: 1px solid #e5e7eb;
}
.as-hits-head .as-hit-row{
    display: grid;
    align-items: end;
    gap: 16px;
    padding-top: 0.25rem;
    padding-bottom: 0.25rem;
    background: #fff;
    font-size: 0.7rem;
}

@media (max-width: 768px){
    .as-hits-head .as-hit-row{
        padding: 9px 10px;
    }
}

.as-hit-col--price.is-oos .ams-add-to-cart,
.ams-add-to-cart[disabled],
.ams-add-to-cart.is-disabled{
    opacity: .55;
    cursor: not-allowed;
    pointer-events: none;
    filter: grayscale(1);
}

@media (max-width: 768px){
}

@media (max-width: 768px){
}

:root{
    --as-col-img: 80px;
    --as-col-model: auto;
    --as-col-indoor: 200px;
    --as-col-outdoor: 200px;
    --as-col-heat: 80px;
    --as-col-cool: 80px;
    --as-col-price: 70px;
    --as-col-actions: 120px;
}

.as-hits-head--minimal .as-hit-col{
    display: flex;
    align-items: flex-start;
    justify-content: flex-start;
}

@media (max-width: 768px){
    :root{
        --as-col-img: 64px;
        --as-col-model: 280px;
        --as-col-indoor: 160px;
        --as-col-outdoor: 160px;
        --as-col-heat: 120px;
        --as-col-cool: 120px;
        --as-col-price: 120px;
        --as-col-actions: 140px;
    }
}

.as-unit-line{
    font-size: 12px;
    line-height: 1.25;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
    font-weight: 400;
}

.as-col-config-trigger{
    cursor: pointer;
    user-select: none;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}
.as-col-config-trigger:hover{
    text-decoration: underline;
}

.as-colmenu{
    position: fixed;
    z-index: 10002;
    width: 240px;
    max-width: calc(100vw - 16px);
    background: #fff;
    border: 1px solid rgba(0,0,0,.12);
    border-radius: 12px;
    padding: 10px 12px;
    box-shadow: 0 12px 30px rgba(0,0,0,.18);
}
.as-colmenu__title{
    font-weight: 800;
    font-size: 12px;
    letter-spacing: .03em;
    text-transform: uppercase;
    margin: 0 0 8px 0;
    color: rgba(0,0,0,.75);
}
.as-colmenu__item{
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 13px;
    padding: 6px 0;
    cursor: pointer;
}
.as-colmenu__item input{
    width: 18px;
    height: 18px;
    margin: 0;
}
.as-colmenu__note{
    margin-top: 8px;
    font-size: 12px;
    color: rgba(0,0,0,.55);
    line-height: 1.35;
}

/* ============================================================
   MOBILE CARD LAYOUT — ispod 768px tablični red postaje kartica
   ============================================================ */
@media (max-width: 768px) {

    /* Sakrij header tablice */
    .as-hits-head--minimal {
        display: none !important;
    }

    /* Card wrapper */
    .as-hits.as-hits--table .ais-Hits-item {
        margin: 0 0 8px 0;
        border-radius: 10px;
        border: 1px solid #e5e7eb;
        background: #fff;
    }

    .as-hits.as-hits--table .ais-Hits-item + .ais-Hits-item {
        border-top: 1px solid #e5e7eb;
    }

    /* Reset grid na 2-stupčani layout: thumb | sadržaj */
    .as-hit-row--minimal,
    .as-hits.as-hits--table .as-hit-row--minimal,
    .as-hits-head--minimal .as-hit-row--minimal {
        display: grid !important;
        grid-template-columns: 80px 1fr !important;
        width: 100% !important;
        box-sizing: border-box;
        gap: 0 12px !important;
        padding: 12px !important;
        align-items: start;
        transform: none !important;
    }

    /* Slika — lijevi stupac, proteže se kroz sve redove */
    .as-hit-col--image {
        grid-column: 1 !important;
        grid-row: 1 / span 3 !important;
        width: 80px !important;
        height: 80px !important;
        align-self: start;
    }

    /* Model — desni stupac, prvi red */
    .as-hit-col--model {
        grid-column: 2 !important;
        grid-row: 1 !important;
        width: auto !important;
        min-width: 0 !important;
    }

    .as-hit-col--model .as-hit-model {
        font-size: 13px;
        line-height: 1.35;
        -webkit-line-clamp: 3;
        min-height: unset;
    }

    .as-hit-col--model .climate-result {
        margin-top: 4px;
    }

    /* Indoor/outdoor sakrij — previše podataka za mob */
    .as-hit-col--indoor,
    .as-hit-col--outdoor {
        display: none !important;
    }

    /* Heat + cool — desni stupac, drugi red, jedan pored drugog */
    .as-hit-col--heat {
        grid-column: 2 !important;
        grid-row: 2 !important;
        width: auto !important;
        min-width: 0 !important;
        flex-direction: row !important;
        flex-wrap: wrap;
        gap: 4px 10px;
        padding-top: 6px;
        align-items: center;
    }

    .as-hit-col--cool {
        display: none !important;
    }

    .as-hit-hc-kw {
        font-size: 13px;
        font-weight: 600;
    }

    .as-hit-hc-class svg {
        width: 44px;
        height: 15px;
    }

    .as-hit-hc-rad {
        font-size: 11px;
        color: #666;
    }

    /* Cijena — puna širina, treći red */
    .as-hit-col--price {
        grid-column: 2 !important;
        grid-row: 3 !important;
        width: auto !important;
        min-width: 0 !important;
        display: flex !important;
        flex-direction: row !important;
        align-items: center;
        justify-content: flex-start;
        gap: 8px;
        padding-top: 6px;
        margin-top: 0;
    }

    .as-hit-price-min {
        font-size: 17px;
        font-weight: 700;
    }

    .as-hit-price-old {
        font-size: 11px;
    }

    /* Akcije — sakrij Detalji button, stretched link pokriva cijelu karticu */
    .as-hit-col--actions {
        grid-column: 1 / -1 !important;
        grid-row: 4 !important;
        width: auto !important;
        min-width: 0 !important;
        display: flex !important;
        flex-direction: row !important;
        align-items: center;
        justify-content: flex-end;
        gap: 8px;
        padding-top: 6px;
    }

    .as-hit-col--actions .btn-glavni {
        display: none;
    }

    .as-hit-col--actions .in-stock {
        font-size: 12px;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        max-width: 120px;
    }

    /* ClimateMatch badge — kompaktniji na mobitelu */
    .as-hit-col--model .climate-result .aeres-button {
        font-size: 11px;
        padding: 4px 8px;
        gap: 4px;
    }

    .as-hit-col--model .climate-result .aeres-button img {
        width: 14px;
        height: 14px;
    }

    /* Stretched link — pokrij cijelu karticu */
    .as-hit-row .btn-glavni::after {
        inset: 0 !important;
    }

    /* Sale badge */
    .as-hits.as-hits--table .as-hit-col--image .as-sale-badge {
        top: -8px;
        right: -8px;
        width: 44px;
        height: 44px;
    }

    /* Hover efekti — nema smisla na touchu */
    .as-hit-row:hover {
        transform: none !important;
        cursor: default;
    }

    .as-hits.as-hits--table .ais-Hits-item:hover {
        box-shadow: none;
    }

    /* imgpop — sakrij na mobitelu (vec ga ima u CSS-u ali dodat i ovdje za sigurnost) */
    .as-hit-imgpop {
        display: none !important;
    }
}



/* ============================================================
   AERES REDESIGN v6 — Table-style filter results
   - Persistent left sidebar (drawer on mobile)
   - Results as a tabular grid; header + rows share column template
   - Reuses existing .as-hit-col--* class names
   ============================================================ */

:root {
    --aer-bg: #ffffff;
    --aer-surface: #f7f8fa;
    --aer-border: #e4e7ec;
    --aer-text: #0f172a;
    --aer-text-muted: #64748b;
    --aer-text-subtle: #94a3b8;
    --aer-primary: #1a578c;
    --aer-success: #16a34a;
    --aer-danger: #dc2626;
    --sp-2: 8px;
    --sp-3: 10px;
    --sp-4: 10px;
    --sp-5: 20px;
    --r-sm: 4px;
    --r-md: 8px;
    --aer-sidebar-w: 380px;
    /* Shared 8-column template — header rows AND each <li> use this */
    --aer-cols: 70px minmax(220px, 1.6fr) minmax(120px, 1fr) minmax(120px, 1fr) 100px 100px 110px 90px;
}

/* ===== LAYOUT ===== */
.as-layout {
    display: grid !important;
    grid-template-columns: var(--aer-sidebar-w) 1fr !important;
    gap: var(--sp-5) !important;
    padding: var(--sp-5) !important;
    max-width: none !important;
    margin: 0 !important;
    align-items: start;
}
.as-layout > .as-results,
.as-layout > main.as-results {
    width: 100% !important;
    max-width: none !important;
    min-width: 0;
    padding: 0 !important;
}

/* ===== SIDEBAR — persistent ===== */
.as-sidebar {
    position: sticky !important;
    top: var(--sp-3) !important;
    right: auto !important;
    left: auto !important;
    bottom: auto !important;
    width: auto !important;
    max-width: none !important;
    transform: none !important;
    transition: none !important;
    /* Reserve final height. Without this, the sidebar starts at ~221px
       (just the header) and grows to ~612px once 14 facet blocks finish
       mounting asynchronously from aeres-dynamic-facets.js — pushing the
       rest of the page (and visually the facet "dropdowns") around as
       they appear. Setting min-height to the typical final value locks
       the layout from t=0. Pages with fewer facets keep a small neutral
       empty area at the bottom — far better than a visible 391px shift. */
    min-height: 620px;
    /* Subtle off-white tint distinguishes the filter panel from the white
       results area on its right. Combined with a soft shadow it reads as a
       clearly defined "tools" panel without being heavy. */
    background: #f6f8fb !important;
    border: 1px solid #d8dee6 !important;
    border-radius: var(--r-md);
    box-shadow:
        0 1px 2px rgba(15, 23, 42, 0.04),
        0 4px 12px rgba(15, 23, 42, 0.06) !important;
    padding: 0 !important;
    z-index: auto !important;
    max-height: calc(100vh - 32px);
    overflow-y: auto;
    overflow-x: hidden;
}
.as-mobile-overlay { display: none !important; }
.as-toolbar-filter-btn { display: none !important; }
.as-sidebar-sticky {
    position: sticky;
    top: 0;
    background: #fff;
    padding: var(--sp-3) var(--sp-4);
    border-bottom: 1px solid var(--aer-border);
    display: flex;
    align-items: center;
    justify-content: space-between;
    z-index: 1;
}
.as-sidebar-sticky__title {
    font-size: 16px;
    font-weight: 700;
    color: var(--aer-text);
}
.as-sidebar-sticky__btn {
    padding: 4px 10px;
    font-size: 12px;
    font-weight: 500;
    background: transparent;
    border: 1px solid var(--aer-border);
    border-radius: var(--r-sm);
    color: var(--aer-text-muted);
    cursor: pointer;
}
.as-sidebar-sticky__btn:hover { background: var(--aer-surface); }
.as-sidebar-sticky__btn[data-as-close-filters] { display: none; }
.as-sidebar-title { display: none !important; }
.as-sidebar > *:not(.as-sidebar-sticky):not(.as-sidebar-title) {
    padding: 0 var(--sp-4);
}
.as-sidebar .as-facet-group {
    padding: var(--sp-3) var(--sp-4) !important;
    margin: 0;
    border-bottom: 1px solid var(--aer-border);
}

/* ===== H1 ===== */
.as-results-header h1 {
    font-size: 28px;
    font-weight: 700;
    letter-spacing: -0.5px;
    line-height: 1.15;
    color: var(--aer-text);
    margin: 0 0 var(--sp-4);
}

/* Tekst uz naslov (.aeres-opis) se NE stilizira ovdje. Stranica /pretraga ima
   tamnu podlogu, a njome upravlja aeres-filter-ui.css — pravilo u ovoj datoteci
   napisano za svijetlu temu prelilo je tamne brojke preko tamne pozadine. */

/* ===== TOOLBAR ===== */
.as-toolbar {
    background: var(--aer-surface);
    border: 1px solid var(--aer-border);
    border-radius: var(--r-md);
    padding: var(--sp-2) var(--sp-3);
    margin-bottom: var(--sp-4);
    box-shadow: none !important;
}

/* Override legacy visibility:hidden default — JS controls show/hide via display */
.as-toolbar-availability-group,
.as-toolbar-sort-group,
.as-toolbar-price-group {
    visibility: visible !important;
    opacity: 1 !important;
    pointer-events: auto !important;
    transition: none !important;
}

/* Hide native <select>s — they're shimmed by .aeres-toolbar__dropdown */
.as-toolbar select[hidden],
.as-toolbar div[hidden] {
    display: none !important;
}

/* ============================================================
   TOOLBAR DROPDOWNS — sizing tweaks for the filter page
   We have 4 dropdowns side by side (Vrsta / Kataloška snaga / Cijena / Sortiraj)
   so we override template.css's min-width: 240px (made for ONE big sort dd in
   products.php) with something more compact.

   Crucially, we let the OPEN MENU grow with content and not be clamped to
   the trigger width — otherwise short triggers like "Sve" produce a 74px
   menu that overflows option labels.
   ============================================================ */

/* Stacking — toolbar must sit above the table+sidebar so dropdown shadow
   isn't clipped or covered. */
.as-toolbar {
    position: relative;
    z-index: 60;
}
.aeres-toolbar__dropdown.is-open { z-index: 100; }

/* Trigger: lock to parent cell width — never grow beyond it. Without
   width:100%, the trigger grew to fit its text content ("Single split
   klima uređaji" = ~244px), overflowing its 170px cell by ~74px and
   visually crashing into the next column. Hard-pegging to 100% with
   the existing white-space:nowrap + overflow:hidden + text-overflow:
   ellipsis keeps the button at exactly cell width and truncates the
   label if it's too long. */
.as-toolbar .aeres-toolbar__trigger {
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
    box-sizing: border-box;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    /* Compact height — original padding gave ~49px tall buttons, this brings
       them to 36px so the toolbar is overall shorter while keeping them
       comfortably tappable. */
    height: 36px;
    min-height: 0;
    padding-top: 4px;
    padding-bottom: 4px;
}

/* Open menu: clamp to trigger/cell width too. Previously had
   `width: max-content; max-width: 360px` which let the panel grow to
   the widest option (e.g. "Multi split unutarnje jedinice" → 242px),
   spilling 72px into the neighbour cell on every open. Now width
   matches the trigger; long option labels truncate with ellipsis. */
.as-toolbar .aeres-toolbar__menu {
    right: auto !important;          /* template.css sets right:0 → clamps to trigger */
    width: 100% !important;
    min-width: 100%;
    max-width: 100% !important;
    box-sizing: border-box;
}
.as-toolbar .aeres-toolbar__menu li,
.as-toolbar .aeres-toolbar__menu button,
.as-toolbar .aeres-toolbar__menu a {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
    box-sizing: border-box;
}

/* Disabled states — when there are no real options or no items can match */
.as-toolbar .aeres-toolbar__trigger:disabled,
.as-toolbar .aeres-toolbar__dropdown.is-disabled .aeres-toolbar__trigger {
    opacity: 0.45;
    cursor: not-allowed;
    pointer-events: none;
}
.as-toolbar .aeres-toolbar__dropdown.is-disabled .aeres-toolbar__menu {
    display: none !important;
}
.as-toolbar .aeres-cm-toggle.is-disabled {
    opacity: 0.45;
    cursor: not-allowed;
    pointer-events: none;
}

/* Climate Match — when "unset" the LABEL stays fully interactive (klik
   na bilo koji dio otvara popup), only the checkbox visual reflects the
   not-yet-configured state via dimmed appearance + dot indicator. The
   text muted color comes from existing rules tied to data-aeres-cm-state. */
.as-toolbar .aeres-cm-toggle[data-aeres-cm-state="unset"] {
    opacity: 1 !important;
    cursor: pointer !important;
    pointer-events: auto !important;
}
.as-toolbar .aeres-cm-toggle[data-aeres-cm-state="unset"] .aeres-cm-toggle__visual {
    opacity: 0.55;            /* checkbox visually dimmed = signals "unset" */
}
.as-toolbar .aeres-cm-toggle[data-aeres-cm-state="unset"] .aeres-cm-toggle__main,
.as-toolbar .aeres-cm-toggle[data-aeres-cm-state="unset"] .aeres-cm-toggle__sub {
    pointer-events: auto;
    cursor: pointer;
}
.as-toolbar .aeres-cm-toggle[data-aeres-cm-state="unset"] .aeres-cm-toggle__input {
    cursor: pointer !important;
    pointer-events: auto !important;
}

/* ===== FILTER CHIPS ===== */
.as-chip {
    background: #e8f0f7 !important;
    color: #134268 !important;
    border: 0 !important;
    border-radius: 999px !important;
    padding: 4px 10px !important;
    font-size: 12px !important;
    font-weight: 500 !important;
}
.as-chip:hover { background: #d4e2f0 !important; }
.as-chip--clear { background: transparent !important; color: var(--aer-text-muted) !important; }

/* ============================================================
   TABLE — header + rows share grid columns
   ============================================================ */
.as-hits-head.as-hits-head--minimal {
    display: block !important;
    background: var(--aer-surface);
    border: 1px solid var(--aer-border);
    border-bottom: 0;
    border-radius: var(--r-md) var(--r-md) 0 0;
    margin: 0;
    padding: 0;
}
.as-hit-head-row.as-hit-row.as-hit-row--minimal {
    display: grid !important;
    grid-template-columns: var(--aer-cols) !important;
    gap: var(--sp-3);
    align-items: center;
    padding: var(--sp-3) var(--sp-4);
    background: transparent;
    margin: 0;
    box-shadow: none !important;
    border: 0 !important;
    min-height: 0 !important;
}
.as-hit-head-label {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.4px;
    color: var(--aer-text-muted);
}

/* Hits container becomes the table body */
.as-hits.as-hits--table {
    background: #fff !important;
    border: 1px solid var(--aer-border) !important;
    border-radius: 0 0 var(--r-md) var(--r-md) !important;
    padding: 0 !important;
    margin: 0 !important;
}
.as-hits.as-hits--table .ais-Hits-list {
    display: block !important;
    list-style: none !important;
    margin: 0 !important;
    padding: 0 !important;
}
.as-hits.as-hits--table .ais-Hits-item {
    display: grid !important;
    grid-template-columns: var(--aer-cols) !important;
    gap: var(--sp-3);
    align-items: center;
    padding: var(--sp-3) var(--sp-4) !important;
    border-bottom: 1px solid var(--aer-border);
    list-style: none;
    margin: 0;
    transition: background 0.15s;
    width: auto !important;
}
.as-hits.as-hits--table .ais-Hits-item:last-child { border-bottom: 0; }
.as-hits.as-hits--table .ais-Hits-item:hover { background: #fafbfc; }

/* ===== CELL STYLING ===== */
.as-hits.as-hits--table .as-hit-col {
    min-width: 0;
}

/* IMAGE */
.as-hits.as-hits--table .as-hit-col--image {
    display: flex;
    justify-content: center;
}
.as-hit-imglink { display: block; line-height: 0; }
.as-hit-img {
    width: 60px;
    height: 60px;
    object-fit: contain;
    background: #fff;
}

/* MODEL — brand logo + title + meta */
.as-hit-col--model { line-height: 1.3; }
.as-hit-model-logo {
    height: 14px;
    width: auto;
    max-width: 80px;
    object-fit: contain;
    object-position: left center;
    display: block;
    margin-bottom: 2px;
}
.as-hit-model-brand {
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.6px;
    text-transform: uppercase;
    color: var(--aer-text-muted);
    margin-bottom: 2px;
}
.as-hit-model-title {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: var(--aer-text);
    text-decoration: none;
    margin-bottom: 2px;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}
.as-hit-model-title:hover { color: var(--aer-primary); }
.as-hit-model-meta {
    font-size: 11px;
    color: var(--aer-text-subtle);
}

/* INDOOR / OUTDOOR / HEAT / COOL — value + class badge */
.as-hit-cell-value {
    font-size: 13px;
    font-weight: 500;
    color: var(--aer-text);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.as-hit-cell-class {
    display: inline-block;
    margin-top: 2px;
    padding: 1px 6px;
    background: #16a34a;
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    border-radius: var(--r-sm);
    line-height: 1.4;
}

/* PRICE */
.as-hit-col--price { text-align: right; }
.as-hit-price-main {
    font-size: 16px;
    font-weight: 700;
    color: var(--aer-text);
    line-height: 1.1;
}
.as-hit-price-main.is-sale { color: var(--aer-danger); }
.as-hit-price-old {
    font-size: 12px;
    color: var(--aer-text-subtle);
    text-decoration: line-through;
    margin-top: 2px;
}
.as-hit-stock-badge.is-out {
    display: inline-block;
    margin-top: 4px;
    padding: 1px 6px;
    background: #fee2e2;
    color: var(--aer-danger);
    font-size: 10px;
    font-weight: 600;
    border-radius: var(--r-sm);
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

/* ACTION button */
.as-hit-col--action { text-align: right; }
.as-hit-action-btn {
    display: inline-block;
    padding: 6px 14px;
    background: var(--aer-text);
    color: #fff !important;
    border-radius: var(--r-sm);
    font-size: 12px;
    font-weight: 600;
    text-decoration: none !important;
    transition: background 0.15s;
}
.as-hit-action-btn:hover { background: var(--aer-primary); }

/* ===== PAGINATION ===== */
.as-pagination {
    margin-top: var(--sp-5);
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 4px;
}

/* ===== MOBILE: drawer fallback ===== */
@media (max-width: 900px) {
    .as-layout {
        grid-template-columns: 1fr !important;
        padding: var(--sp-3) !important;
    }
    .as-sidebar {
        position: fixed !important;
        top: 0 !important;
        right: 0 !important;
        bottom: 0 !important;
        width: 320px !important;
        max-width: 92vw !important;
        transform: translateX(105%) !important;
        transition: transform 280ms cubic-bezier(.4,0,.2,1) !important;
        z-index: 9999 !important;
        max-height: none;
        border: 0 !important;
        border-left: 1px solid var(--aer-border) !important;
        border-radius: 0;
        box-shadow: -10px 0 40px rgba(15,23,42,0.18) !important;
    }
    body.as-filters-open .as-sidebar { transform: translateX(0) !important; }
    .as-mobile-overlay {
        display: block !important;
        position: fixed;
        inset: 0;
        background: rgba(15,23,42,0.45);
        opacity: 0;
        visibility: hidden;
        transition: opacity 280ms, visibility 0s 280ms;
        z-index: 9998;
    }
    body.as-filters-open .as-mobile-overlay {
        opacity: 1 !important;
        visibility: visible !important;
        transition: opacity 280ms, visibility 0s !important;
    }
    .as-toolbar-filter-btn {
        display: inline-flex !important;
        gap: 8px;
        align-items: center;
        padding: 6px 12px;
        background: var(--aer-text);
        color: #fff;
        border: 0;
        border-radius: var(--r-sm);
        font-size: 13px;
        font-weight: 600;
        cursor: pointer;
    }
    .as-sidebar-sticky__btn[data-as-close-filters] { display: inline-flex !important; }
    body.as-lock-scroll { overflow: hidden !important; }

    /* Collapse columns: show only image | model | price | action */
    :root {
        --aer-cols: 50px minmax(140px, 1fr) 90px 80px;
    }
    .as-hit-col--indoor,
    .as-hit-col--outdoor,
    .as-hit-col--heat,
    .as-hit-col--cool {
        display: none !important;
    }
    .as-hit-img { width: 44px; height: 44px; }
}


/* ============================================================
   DYNAMIC FACETS — sidebar refinementList widgets
   Built at runtime by aeres-dynamic-facets.js. Minimum baseline
   styling; user will hand-pick / polish later.
   ============================================================ */

.aeres-dyn-facets {
    display: flex;
    flex-direction: column;
}

.aeres-facet-block {
    padding: var(--sp-3) var(--sp-4);
    border-bottom: 1px solid var(--aer-border);
}

/* Model cascade UI — Option B: list hidden until a manufacturer is
   chosen, with a hint appended INTO the section title so it reads
   "MODEL — Odaberi proizvođača za pregled modela" when locked.
   Connector widget in aeres-dynamic-facets.js toggles .is-cascade-locked
   on the block based on cf_manufacturer refinement state. */
.aeres-facet-block--model.is-cascade-locked .aeres-facet-block__list {
    display: none;
}
/* Inline hint is hidden by default; only shown when the cascade is locked. */
.aeres-facet-block__cascade-hint-inline {
    display: none;
}
.aeres-facet-block--model.is-cascade-locked .aeres-facet-block__cascade-hint-inline {
    display: inline;
    font-size: 0.85em;
    font-weight: 400;
    color: var(--aer-text-muted, #6b7280);
    font-style: italic;
    text-transform: none;
    letter-spacing: 0;
}
.aeres-facet-block:last-child { border-bottom: 0; }

.aeres-facet-block__title {
    font-size: 13px;
    font-weight: 700;
    color: var(--aer-text);
    margin: 0 0 var(--sp-2);
    text-transform: capitalize;
}

.aeres-facet-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.aeres-facet-item {
    margin: 0;
}

.aeres-facet-item .aeres-facet-label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: var(--aer-text);
    cursor: pointer;
    padding: 2px 0;
}
.aeres-facet-item .aeres-facet-label:hover {
    color: var(--aer-primary);
}

.aeres-facet-item .aeres-facet-checkbox {
    width: 14px;
    height: 14px;
    margin: 0;
    cursor: pointer;
    flex-shrink: 0;
}

.aeres-facet-item .aeres-facet-text {
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Boja swatch — mala slika prikazana ispred labela u Boja filteru
   (i bilo gdje gdje admin override-i u Extractoru sadrže image_url). */
.aeres-color-swatch {
    display: inline-block;
    width: 20px;
    height: 20px;
    border-radius: 3px;
    vertical-align: middle;
    margin-right: 8px;
    border: 1px solid rgba(0, 0, 0, 0.1);
    object-fit: cover;
    flex-shrink: 0;
}

/* Hover zoom popup — fixed positioned na body (izbjegava
   overflow:hidden clipping). Pokazuje 100×100 verziju swatcha.
   Pozicioniranje (left/top) handla JS u aeres-dynamic-facets.js. */
#aeres-swatch-popup {
    position: fixed;
    display: none;
    width: 100px;
    height: 100px;
    background: #fff;
    border: 1px solid rgba(0, 0, 0, 0.15);
    border-radius: 6px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.18);
    padding: 4px;
    z-index: 99999;
    pointer-events: none;
}
#aeres-swatch-popup img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 3px;
}

/* ────────────────────────────────────────────────────────────
   Dimensions range filter widget.
   Renderira se unutar Dimenzije sekcije, ima dva podnaslova
   (unutarnja / vanjska jedinica), pod svakim 3 input polja
   za max visinu/širinu/dubinu (mm).
   ──────────────────────────────────────────────────────────── */
.aeres-dim-range {
    padding: 4px 0;
}
.aeres-dim-range__group + .aeres-dim-range__group {
    margin-top: 16px;
    padding-top: 12px;
    border-top: 1px solid var(--aer-border, rgba(0, 0, 0, 0.08));
}
.aeres-dim-range__heading {
    font-size: 12px;
    font-weight: 600;
    color: var(--aer-text, #222);
    text-transform: uppercase;
    letter-spacing: 0.02em;
    margin-bottom: 2px;
}
.aeres-dim-range__hint {
    font-size: 11px;
    color: var(--aer-text-muted, #888);
    margin-bottom: 8px;
}
.aeres-dim-range__inputs {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
}
.aeres-dim-range__field {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin: 0;
    cursor: text;
}
.aeres-dim-range__label {
    font-size: 11px;
    color: var(--aer-text-muted, #666);
}
.aeres-dim-range__input {
    width: 100%;
    padding: 6px 8px;
    font-size: 13px;
    line-height: 1.3;
    border: 1px solid var(--aer-border, rgba(0, 0, 0, 0.15));
    border-radius: 4px;
    background: #fff;
    color: var(--aer-text, #222);
    font-variant-numeric: tabular-nums;
    -webkit-appearance: none;
    -moz-appearance: textfield;
    appearance: textfield;
    box-sizing: border-box;
    outline: none;
    transition: border-color 0.1s ease;
}
.aeres-dim-range__input::-webkit-outer-spin-button,
.aeres-dim-range__input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}
.aeres-dim-range__input:focus {
    border-color: var(--aer-primary, #2a5db0);
    box-shadow: 0 0 0 2px rgba(42, 93, 176, 0.15);
}
.aeres-dim-range__input:placeholder-shown {
    color: #888;
}

.aeres-facet-item .aeres-facet-count {
    color: var(--aer-text-muted);
    font-size: 11px;
    font-variant-numeric: tabular-nums;
}

.aeres-facet-item--selected .aeres-facet-label,
.ais-RefinementList-item--selected .aeres-facet-label {
    color: var(--aer-primary);
    font-weight: 600;
}

.aeres-facet-showmore {
    background: transparent;
    border: 0;
    padding: 4px 0;
    font-size: 12px;
    color: var(--aer-primary);
    cursor: pointer;
    margin-top: 4px;
}
.aeres-facet-showmore:hover { text-decoration: underline; }
.aeres-facet-showmore--disabled {
    display: none;
}

/* Boolean facets — single labeled checkbox (no 0/1 list) */
.aeres-facet-block--toggle {
    padding: 6px var(--sp-4);
    border-bottom: 0;     /* tighter row spacing */
}
.aeres-facet-block--toggle + .aeres-facet-block--toggle {
    padding-top: 0;
}
/* Restore separator after the last toggle in a run */
.aeres-facet-block--toggle:has(+ .aeres-facet-block:not(.aeres-facet-block--toggle)) {
    padding-bottom: var(--sp-3);
    border-bottom: 1px solid var(--aer-border);
}

.aeres-facet-toggle {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    user-select: none;
    padding: 2px 0;
}
.aeres-facet-toggle:hover .aeres-facet-toggle__label {
    color: var(--aer-primary);
}

.aeres-facet-toggle__input {
    width: 14px;
    height: 14px;
    margin: 0;
    cursor: pointer;
    flex-shrink: 0;
}

.aeres-facet-toggle__label {
    font-size: 13px;
    color: var(--aer-text);
    line-height: 1.3;
}

.aeres-facet-toggle.is-disabled {
    opacity: 0.45;
    cursor: not-allowed;
}
.aeres-facet-toggle.is-disabled .aeres-facet-toggle__input {
    cursor: not-allowed;
}

/* ============================================================
   PRICE RANGE — editable inputs + dual-handle live slider
   ============================================================ */

.as-facet-price-range {
    padding: var(--sp-3) var(--sp-4);
    border-bottom: 1px solid var(--aer-border);
}

.aeres-price-range {
    display: flex;
    flex-direction: column;
    gap: var(--sp-3);
}

/* Inputs row */
.aeres-price-inputs {
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.aeres-price-input-row {
    display: flex;
    align-items: center;
    gap: 6px;
}
.aeres-price-row-label {
    width: 22px;
    flex-shrink: 0;
    font-size: 11px;
    font-weight: 600;
    color: var(--aer-text-muted);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}
.aeres-price-input-group {
    flex: 1;
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 4px;
    background: #fff;
    border: 1px solid var(--aer-border);
    border-radius: var(--r-sm);
    padding: 3px 4px;
    transition: border-color 0.15s, box-shadow 0.15s;
}
.aeres-price-input-group:focus-within {
    border-color: var(--aer-primary);
    box-shadow: 0 0 0 3px rgba(26, 87, 140, 0.12);
}
.aeres-price-input {
    flex: 1;
    min-width: 0;
    border: 0;
    outline: none;
    font-size: 14px;
    font-weight: 600;
    color: var(--aer-text);
    background: transparent;
    text-align: center;
    padding: 2px 4px;
    /* Hide spinner on number input */
    -moz-appearance: textfield;
}
.aeres-price-input::-webkit-outer-spin-button,
.aeres-price-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}
.aeres-price-cur {
    font-size: 12px;
    color: var(--aer-text-muted);
    flex-shrink: 0;
}
.aeres-price-sep {
    color: var(--aer-text-subtle);
    font-size: 13px;
}

/* Slider — two overlapping <input type=range> with a fill bar */
.aeres-price-slider {
    position: relative;
    height: 24px;
    margin: 0 6px;
}
.aeres-price-slider-track {
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--aer-border);
    border-radius: 2px;
    transform: translateY(-50%);
    pointer-events: none;
}
.aeres-price-slider-fill {
    position: absolute;
    top: 50%;
    height: 4px;
    background: var(--aer-primary);
    border-radius: 2px;
    transform: translateY(-50%);
    pointer-events: none;
}
.aeres-price-handle {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 24px;
    background: transparent;
    pointer-events: none;
    -webkit-appearance: none;
    appearance: none;
    margin: 0;
    padding: 0;
}
.aeres-price-handle::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    pointer-events: auto;
    /* Longer + thicker handle (oval/pill) for easier grabbing */
    width: 24px;
    height: 22px;
    border-radius: 6px;
    background: #fff;
    border: 2px solid var(--aer-primary);
    box-shadow: 0 2px 6px rgba(15, 23, 42, 0.22);
    cursor: grab;
    transition: transform 0.1s, box-shadow 0.1s;
}
.aeres-price-handle::-webkit-slider-thumb:hover {
    transform: scale(1.08);
    box-shadow: 0 3px 8px rgba(15, 23, 42, 0.28);
}
.aeres-price-handle::-webkit-slider-thumb:active {
    cursor: grabbing;
}
.aeres-price-handle::-moz-range-thumb {
    pointer-events: auto;
    width: 24px;
    height: 22px;
    border-radius: 6px;
    background: #fff;
    border: 2px solid var(--aer-primary);
    box-shadow: 0 2px 6px rgba(15, 23, 42, 0.22);
    cursor: grab;
}
.aeres-price-handle::-webkit-slider-runnable-track,
.aeres-price-handle::-moz-range-track {
    background: transparent;
    height: 4px;
    border: 0;
}
/* Top handle slightly above so both can be grabbed */
.aeres-price-handle-min { z-index: 1; }
.aeres-price-handle-max { z-index: 2; }

/* Action buttons */
.aeres-price-actions {
    display: flex;
    flex-direction: row;
    gap: 8px;
}
.as-price-range-reset {
    flex: 1;
    margin-top: 0;
    background: #fff;
    border: 1px solid var(--aer-border);
    border-radius: var(--r-sm);
    padding: 8px 10px;
    font-size: 12px;
    font-weight: 500;
    color: var(--aer-text);
    cursor: pointer;
    text-align: center;
    line-height: 1.25;
    text-decoration: none;
    transition: background 0.12s, border-color 0.12s, color 0.12s;
}
.as-price-range-reset:hover {
    background: var(--aer-surface);
    border-color: var(--aer-text-muted);
}
.as-reset-all-filters {
    background: var(--aer-danger);
    border-color: var(--aer-danger);
    color: #fff;
    font-weight: 600;
}
.as-reset-all-filters:hover {
    background: #b91c1c;
    border-color: #b91c1c;
    color: #fff;
}

/* Stepper buttons inside input group */
.aeres-price-step {
    flex-shrink: 0;
    width: 22px;
    height: 22px;
    padding: 0;
    border: 1px solid var(--aer-border);
    background: var(--aer-surface);
    border-radius: 4px;
    color: var(--aer-text-muted);
    font-size: 14px;
    font-weight: 700;
    line-height: 1;
    cursor: pointer;
    user-select: none;
    transition: background 0.12s, color 0.12s, border-color 0.12s;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
.aeres-price-step:hover {
    background: var(--aer-primary);
    border-color: var(--aer-primary);
    color: #fff;
}
.aeres-price-step:active {
    transform: translateY(1px);
}
/* Slightly tighter input group to fit steppers + input + € on one line */
.aeres-price-input-group {
    padding: 3px 4px;
    gap: 3px;
}
/* Allow handle area to grow now that thumb is larger */
.aeres-price-slider {
    height: 28px;
}
.aeres-price-handle {
    height: 28px;
}

/* ============================================================
   IMAGE HOVER-ZOOM POPUP
   Floating preview that follows the cursor area when hovering
   over product thumbnails in the results grid.
   ============================================================ */
.aeres-img-zoom-popup {
    position: fixed;
    z-index: 10000;
    width: 280px;
    height: 280px;
    background: #fff;
    border: 1px solid var(--aer-border, #e5e7eb);
    border-radius: 8px;
    box-shadow: 0 12px 32px rgba(15, 23, 42, 0.18), 0 4px 12px rgba(15, 23, 42, 0.08);
    padding: 8px;
    pointer-events: none;
    opacity: 0;
    transform: scale(0.96);
    transition: opacity 0.15s ease, transform 0.15s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}
.aeres-img-zoom-popup.is-visible {
    opacity: 1;
    transform: scale(1);
}
.aeres-img-zoom-popup img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    display: block;
}

/* Touch fallback — phones don't have hover */
@media (hover: none) {
    .aeres-img-zoom-popup { display: none !important; }
}

/* ============================================================
   PCPartPicker-style table headers + cell borders + click-sort
   ============================================================ */

/* Header row — emphasized like PCPartPicker */
.as-hits-head--minimal {
    background: #f4f4f6;
    border-top: 1px solid var(--aer-border, #d4d8dd);
    border-bottom: 2px solid var(--aer-border, #d4d8dd);
    border-left: 1px solid var(--aer-border, #d4d8dd);
    border-right: 1px solid var(--aer-border, #d4d8dd);
}
.as-hits-head--minimal .as-hit-row--minimal {
    /* keep existing grid template from --aer-cols */
}
.as-hits-head--minimal .as-hit-col {
    padding: 10px 8px;
    border-right: 1px solid var(--aer-border, #d4d8dd);
    display: flex;
    align-items: center;
}
.as-hits-head--minimal .as-hit-col:last-child {
    border-right: 0;
}
.as-hits-head--minimal .as-hit-head-label {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #1f2937;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Vertical column borders on each hit row */
.as-hits--table .ais-Hits-item {
    border-bottom: 1px solid var(--aer-border, #e5e7eb);
    border-left: 1px solid var(--aer-border, #e5e7eb);
    border-right: 1px solid var(--aer-border, #e5e7eb);
}
.as-hits--table .ais-Hits-item:hover {
    background: #fafbfc;
}
.as-hits--table .ais-Hits-item .as-hit-col {
    border-right: 1px solid var(--aer-border, #eef0f2);
    padding: 8px;
    display: flex;
    align-items: center;
}
.as-hits--table .ais-Hits-item .as-hit-col:last-child {
    border-right: 0;
}

/* Sortable header label — clickable + hover state + sort arrows */
.as-hits-head--minimal .as-hit-head-label.is-sortable {
    cursor: pointer;
    user-select: none;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 2px 4px;
    margin: -2px -4px;
    border-radius: 3px;
    transition: background-color 0.12s, color 0.12s;
}
.as-hits-head--minimal .as-hit-head-label.is-sortable:hover {
    background: #e6e8ec;
    color: #0f172a;
}
.as-hits-head--minimal .as-hit-head-label.is-sortable.is-sorted-asc,
.as-hits-head--minimal .as-hit-head-label.is-sortable.is-sorted-desc {
    color: var(--aer-primary, #1a578c);
}

/* Sort arrow icon — up/down chevrons drawn with CSS */
.as-hit-head-sort-icon {
    display: inline-flex;
    flex-direction: column;
    line-height: 0;
    margin-left: 2px;
    opacity: 0.45;
}
.as-hit-head-sort-icon::before,
.as-hit-head-sort-icon::after {
    content: '';
    display: block;
    width: 0;
    height: 0;
    border-left: 4px solid transparent;
    border-right: 4px solid transparent;
}
.as-hit-head-sort-icon::before {
    border-bottom: 5px solid currentColor;
    margin-bottom: 2px;
}
.as-hit-head-sort-icon::after {
    border-top: 5px solid currentColor;
}
/* Active states — show only the relevant arrow at full opacity */
.is-sorted-asc .as-hit-head-sort-icon { opacity: 1; }
.is-sorted-asc .as-hit-head-sort-icon::after { opacity: 0.2; }
.is-sorted-desc .as-hit-head-sort-icon { opacity: 1; }
.is-sorted-desc .as-hit-head-sort-icon::before { opacity: 0.2; }

/* ============================================================
   COLLAPSIBLE FACET BLOCK + 2-COL BRAND GRID
   ============================================================ */

/* Collapsible header — full-width button row */
.aeres-facet-block__toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    background: transparent;
    border: 0;
    padding: 0;
    margin: 0 0 var(--sp-2);
    cursor: pointer;
    color: var(--aer-text);
    font: inherit;
    text-align: left;
    transition: color 0.12s;
}
.aeres-facet-block__toggle:hover {
    color: var(--aer-primary);
}
.aeres-facet-block__toggle .aeres-facet-block__title {
    margin: 0;          /* override default h4-style title margin */
    font-size: 13px;
    font-weight: 700;
    text-transform: capitalize;
    color: inherit;
}

/* Brand-specific header — distinctly clickable, uppercase, with background */
.aeres-facet-block--brand .aeres-facet-block__toggle {
    padding: 12px 14px;
    margin: 0;
    background: linear-gradient(180deg, #f8fafc 0%, #eef1f5 100%);
    border: 1px solid #cbd2dc;
    border-radius: 6px;
    box-shadow: 0 1px 0 rgba(15, 23, 42, 0.04), inset 0 1px 0 rgba(255, 255, 255, 0.6);
    color: #0f172a;
    transition: background 0.15s, border-color 0.15s, color 0.15s, box-shadow 0.15s, transform 0.08s;
}
.aeres-facet-block--brand .aeres-facet-block__toggle:hover {
    background: linear-gradient(180deg, #eaf1f9 0%, #d9e6f4 100%);
    border-color: var(--aer-primary, #1a578c);
    color: var(--aer-primary, #1a578c);
    box-shadow: 0 2px 6px rgba(26, 87, 140, 0.18), inset 0 1px 0 rgba(255, 255, 255, 0.6);
}
.aeres-facet-block--brand .aeres-facet-block__toggle:active {
    transform: translateY(1px);
    box-shadow: 0 1px 2px rgba(26, 87, 140, 0.2), inset 0 1px 2px rgba(15, 23, 42, 0.08);
}
.aeres-facet-block--brand .aeres-facet-block__toggle .aeres-facet-block__title {
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}
/* Brand chevron — subtle visual cue */
.aeres-facet-block--brand .aeres-facet-block__toggle .aeres-facet-block__chev {
    width: 14px;
    height: 14px;
    color: #64748b;
}
.aeres-facet-block--brand .aeres-facet-block__toggle:hover .aeres-facet-block__chev {
    color: var(--aer-primary, #1a578c);
}
/* When expanded, give the title bar a clear "active" tint */
.aeres-facet-block--brand:not(.is-collapsed) .aeres-facet-block__toggle {
    background: linear-gradient(180deg, #1a578c 0%, #134a78 100%);
    border-color: #0f3b62;
    color: #fff;
    box-shadow: 0 2px 4px rgba(15, 23, 42, 0.15), inset 0 1px 0 rgba(255, 255, 255, 0.18);
}
.aeres-facet-block--brand:not(.is-collapsed) .aeres-facet-block__toggle:hover {
    background: linear-gradient(180deg, #195486 0%, #103e66 100%);
    color: #fff;
}
.aeres-facet-block--brand:not(.is-collapsed) .aeres-facet-block__toggle .aeres-facet-block__chev {
    color: rgba(255, 255, 255, 0.8);
}
.aeres-facet-block--brand:not(.is-collapsed) .aeres-facet-block__toggle:hover .aeres-facet-block__chev {
    color: #fff;
}
/* Add a little space between header and the 2-col grid when expanded */
.aeres-facet-block--brand:not(.is-collapsed) .aeres-facet-list {
    margin-top: var(--sp-3);
}
.aeres-facet-block__chev {
    flex-shrink: 0;
    color: var(--aer-text-muted);
    transition: transform 0.18s ease;
}
.aeres-facet-block--collapsible .aeres-facet-block__toggle .aeres-facet-block__chev {
    transform: rotate(-90deg);  /* collapsed: chevron points right */
}
.aeres-facet-block--collapsible:not(.is-collapsed) .aeres-facet-block__toggle .aeres-facet-block__chev {
    transform: rotate(0);       /* expanded: chevron points down */
}
/* Hide list when collapsed */
.aeres-facet-block--collapsible.is-collapsed .aeres-facet-block__list {
    display: none;
}
/* Tighten margin when collapsed (no list visible underneath) */
.aeres-facet-block--collapsible.is-collapsed .aeres-facet-block__toggle {
    margin-bottom: 0;
}

/* Brand-specific: 2-column grid of checkbox items */
.aeres-facet-block--brand .aeres-facet-list {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4px 12px;
    align-items: start;
}

/* Installation override: single column so longer labels (e.g. "Zidne kazetne",
   "Parapetne podne") fit without wrapping or truncating. Inherits everything
   else from the brand block — header, hover, checkbox style. */
.aeres-facet-block--installation .aeres-facet-list,
.aeres-facet-block--wifi .aeres-facet-list {
    grid-template-columns: 1fr;
}
.aeres-facet-block--installation .aeres-facet-item .aeres-facet-text,
.aeres-facet-block--wifi .aeres-facet-item .aeres-facet-text {
    white-space: normal;        /* allow wrapping to a 2nd line if very long */
    overflow: visible;
    text-overflow: clip;
    line-height: 1.35;
}
/* WiFi values can be very long (full sentences) — keep label items
   well-spaced for readability */
.aeres-facet-block--wifi .aeres-facet-item .aeres-facet-label {
    align-items: flex-start;
    padding: 6px 6px;
}
.aeres-facet-block--wifi .aeres-facet-item .aeres-facet-checkbox {
    margin-top: 2px;            /* nudge checkbox down to align with first text line */
}
/* Each item — clickable label, full row hover, modern checkbox */
.aeres-facet-block--brand .aeres-facet-item {
    margin: 0;
}
.aeres-facet-block--brand .aeres-facet-item .aeres-facet-label {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 5px 6px;
    margin: 0 -6px;          /* hover stretches a bit beyond the cell */
    border-radius: 4px;
    font-size: 12.5px;
    line-height: 1.2;
    color: var(--aer-text);
    cursor: pointer;
    transition: background-color 0.12s;
    min-width: 0;             /* allow text to shrink in narrow cells */
}
.aeres-facet-block--brand .aeres-facet-item .aeres-facet-label:hover {
    background: rgba(26, 87, 140, 0.06);
    color: var(--aer-text);
}
.aeres-facet-block--brand .aeres-facet-item--selected .aeres-facet-label,
.aeres-facet-block--brand .ais-RefinementList-item--selected .aeres-facet-label {
    color: var(--aer-primary);
    font-weight: 600;
    background: rgba(26, 87, 140, 0.08);
}

/* ─────────────────────────────────────────────────────────────
   BRAND LOGO DECORATOR — injected by installBrandLogoDecorator()
   <span class="aeres-facet-text">
     <img class="aeres-brand-facet-logo">
     <span class="aeres-sr-only">Daikin</span>
   </span>
   ─────────────────────────────────────────────────────────── */

/* Brand logo — svi SVG-i imaju identičan viewBox="0 0 240 80" s normaliziranim
   content-om centriranim i scale-anim na 84% canvas-a. Zato CSS je jednostavan:
   width 100%, height auto (visina se računa iz aspect ratio-a — pošto su svi
   SVG-i normalizirani na isti ratio, svi imaju identičnu visinu). */
.aeres-brand-facet-logo {
    display: block;
    width: 100%;
    max-width: 160px;
    height: auto;
    /* Soft grayscale tretman — desaturira boje, blago smanji brightness i
       povećava contrast. Razlika u odnosu na brightness(0): zadržava se detail
       i forma logotipa (ne postaju solid crne siluete), pa negative-space
       brendovi (AUX, Maxon) izgledaju jednako dobro kao i svi ostali. */
    filter: grayscale(1) saturate(0) brightness(.88) contrast(1.05);
    opacity: .86;
    transition: filter .18s ease, opacity .18s ease, transform .18s ease;
    will-change: filter, opacity, transform;
    object-fit: contain;
    flex-shrink: 0;
}

/* Hover / selected — pun color, full opacity (recognition + commitment signal) */
.aeres-facet-item:hover .aeres-brand-facet-logo,
.aeres-facet-item--selected .aeres-brand-facet-logo,
.ais-RefinementList-item--selected .aeres-brand-facet-logo {
    filter: none;
    opacity: 1;
}

/* Items WITH a logo: tighten the gap, hide the count overlap, align right */
.aeres-facet-item--has-logo .aeres-facet-label {
    gap: 8px;
}
.aeres-facet-item--has-logo .aeres-facet-text {
    display: inline-flex;
    align-items: center;
    flex: 1 1 auto;
    min-width: 0;
    /* Brutalno skrij sve text node-ove i child elemente uz logo —
       <img> ostaje vidljiv jer ima fiksne dimenzije, sve drugo postaje 0px font. */
    font-size: 0;
    line-height: 0;
    color: transparent;
}
/* Hide raw count next to logo's name — count is at far right anyway */
.aeres-facet-item--has-logo .aeres-facet-count {
    margin-left: auto;
}

/* Screen-reader-only utility */
.aeres-sr-only {
    position: absolute !important;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0,0,0,0);
    white-space: nowrap;
    border: 0;
}

/* Modern checkbox — consistent visual look across browsers */
.aeres-facet-block--brand .aeres-facet-item .aeres-facet-checkbox {
    -webkit-appearance: none;
    appearance: none;
    width: 14px;
    height: 14px;
    border: 1.5px solid var(--aer-border);
    border-radius: 3px;
    background: #fff;
    cursor: pointer;
    flex-shrink: 0;
    margin: 0;
    position: relative;
    transition: border-color 0.12s, background-color 0.12s;
}
.aeres-facet-block--brand .aeres-facet-item .aeres-facet-label:hover .aeres-facet-checkbox {
    border-color: var(--aer-primary);
}
.aeres-facet-block--brand .aeres-facet-item .aeres-facet-checkbox:checked {
    background: var(--aer-primary);
    border-color: var(--aer-primary);
}
.aeres-facet-block--brand .aeres-facet-item .aeres-facet-checkbox:checked::after {
    content: '';
    position: absolute;
    left: 3px;
    top: 0px;
    width: 4px;
    height: 8px;
    border: solid #fff;
    border-width: 0 1.6px 1.6px 0;
    transform: rotate(45deg);
}
/* Brand name text — truncate to one line; show full on hover via title attr */
.aeres-facet-block--brand .aeres-facet-item .aeres-facet-text {
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    min-width: 0;
}
.aeres-facet-block--brand .aeres-facet-item .aeres-facet-count {
    font-size: 10.5px;
    color: var(--aer-text-muted);
    font-variant-numeric: tabular-nums;
    flex-shrink: 0;
}

/* When list is empty / refinement returns nothing */
.aeres-facet-block--brand .aeres-facet-list:empty::after {
    content: 'Nema dostupnih proizvođača';
    grid-column: 1 / -1;
    font-size: 12px;
    color: var(--aer-text-muted);
    font-style: italic;
    padding: 4px 0;
}

/* ============================================================
   CATEGORY INTRO (description above results) + FAQ accordion
   Server-rendered for SEO (Google reads without executing JS).
   ============================================================ */

.as-category-intro {
    margin: 0 0 var(--sp-4);
    padding: var(--sp-4) var(--sp-5);
    background: #fafbfc;
    border: 1px solid var(--aer-border, #e5e7eb);
    border-radius: 8px;
    line-height: 1.55;
    color: #1f2937;
    font-size: 14px;
}
.as-category-intro p {
    margin: 0 0 var(--sp-3);
}
.as-category-intro p:last-child { margin-bottom: 0; }
.as-category-intro strong {
    color: #0f172a;
    font-weight: 600;
}

/* FAQ block at the bottom of the results column */
.as-category-faq {
    margin: var(--sp-6) 0 var(--sp-5);
    padding: var(--sp-5);
    background: #fff;
    border: 1px solid var(--aer-border, #e5e7eb);
    border-radius: 8px;
}
.as-category-faq__title {
    margin: 0 0 var(--sp-4);
    font-size: 18px;
    font-weight: 700;
    color: #0f172a;
}
.as-faq-list {
    display: flex;
    flex-direction: column;
    gap: 0;
}
.as-faq-item {
    border-bottom: 1px solid var(--aer-border, #e5e7eb);
    padding: 0;
}
.as-faq-item:last-child { border-bottom: 0; }
.as-faq-q {
    cursor: pointer;
    list-style: none;          /* remove default disclosure triangle */
    padding: var(--sp-3) 0;
    padding-right: 28px;
    position: relative;
    font-weight: 600;
    color: #1f2937;
    font-size: 14px;
    line-height: 1.45;
    user-select: none;
    transition: color 0.12s;
}
.as-faq-q::-webkit-details-marker { display: none; }
.as-faq-q:hover { color: var(--aer-primary, #1a578c); }
.as-faq-q::after {
    content: '';
    position: absolute;
    right: 6px;
    top: 50%;
    width: 8px;
    height: 8px;
    border-right: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: translateY(-65%) rotate(45deg);
    transition: transform 0.18s;
}
.as-faq-item[open] .as-faq-q::after {
    transform: translateY(-25%) rotate(-135deg);
}
.as-faq-a {
    padding: 0 0 var(--sp-4);
    color: #475569;
    line-height: 1.55;
    font-size: 13.5px;
}

/* On mobile, intro/FAQ keep modest padding */
@media (max-width: 900px) {
    .as-category-intro {
        padding: var(--sp-3) var(--sp-4);
        font-size: 13.5px;
    }
}

/* ============================================================
   TOOLBAR DROPDOWN — active-value tint (subtle green)
   Applied via .is-active on the dropdown container when the
   backing <select> has a non-empty value.
   ============================================================ */
.aeres-toolbar__dropdown.is-active .aeres-toolbar__trigger {
    background: #ecfdf5 !important;        /* very light green */
    border-color: #10b981 !important;      /* emerald-500 */
    color: #065f46 !important;             /* emerald-800 */
}
.aeres-toolbar__dropdown.is-active .aeres-toolbar__trigger:hover {
    background: #d1fae5 !important;        /* slightly deeper green on hover */
    border-color: #059669 !important;
}
.aeres-toolbar__dropdown.is-active .aeres-toolbar__trigger .aeres-toolbar__caret {
    color: #10b981 !important;
}

/* Field icons from com_aeresextractor metadata */
.aeres-facet-block__icon {
    display: inline-block;
    width: 16px;
    height: 16px;
    object-fit: contain;
    flex-shrink: 0;
    vertical-align: middle;
    opacity: 0.85;
}
.aeres-facet-block__title .aeres-facet-block__icon {
    margin-right: 6px;
}
.aeres-facet-block__toggle {
    gap: 8px;
}
/* In the brand/installation pinned header, push title to the left of chevron */
.aeres-facet-block--brand .aeres-facet-block__toggle .aeres-facet-block__title {
    margin-right: auto;
}

/* ============================================================
   Povezivost (virtual WiFi facet) — single checkbox under
   pinned header, same look as brand/installation blocks.
   ============================================================ */
.aeres-facet-block--povezivost .aeres-facet-block__list {
    /* override brand grid — single column */
    display: block;
    margin-top: var(--sp-3);
}
.aeres-facet-block--povezivost .aeres-facet-toggle {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 8px;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.12s;
}
.aeres-facet-block--povezivost .aeres-facet-toggle:hover {
    background: rgba(26, 87, 140, 0.06);
}
.aeres-facet-block--povezivost .aeres-facet-toggle__input {
    -webkit-appearance: none;
    appearance: none;
    width: 14px;
    height: 14px;
    border: 1.5px solid var(--aer-border);
    border-radius: 3px;
    background: #fff;
    cursor: pointer;
    flex-shrink: 0;
    margin: 0;
    position: relative;
    transition: border-color 0.12s, background-color 0.12s;
}
.aeres-facet-block--povezivost .aeres-facet-toggle:hover .aeres-facet-toggle__input {
    border-color: var(--aer-primary);
}
.aeres-facet-block--povezivost .aeres-facet-toggle__input:checked {
    background: var(--aer-primary);
    border-color: var(--aer-primary);
}
.aeres-facet-block--povezivost .aeres-facet-toggle__input:checked::after {
    content: '';
    position: absolute;
    left: 3px;
    top: 0px;
    width: 4px;
    height: 8px;
    border: solid #fff;
    border-width: 0 1.6px 1.6px 0;
    transform: rotate(45deg);
}
.aeres-facet-block--povezivost .aeres-facet-toggle__label {
    font-size: 13px;
    color: var(--aer-text);
    user-select: none;
}

/* Multi-field section internal layout — group several attribute filters
   under a single section header (e.g. "Strujanje zraka" with 4 facets). */
.aeres-facet-section-body {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: var(--sp-3) var(--sp-3) var(--sp-3) var(--sp-3);
}
.aeres-facet-section-subitem {
    border-top: 1px solid var(--aer-border, #e5e7eb);
    padding-top: 6px;
}
.aeres-facet-section-subitem:first-child {
    border-top: 0;
    padding-top: 0;
}
.aeres-facet-section-sublabel {
    font-size: 12px;
    font-weight: 600;
    color: #475569;
    margin-bottom: 4px;
    text-transform: none;
}
.aeres-facet-block.is-collapsed .aeres-facet-section-body { display: none; }

/* ──────────────────────────────────────────────────────────────
   Active filters bar (chips with X buttons + "Clear all")
   Sits above .as-layout, between the toolbar and the results.
   Always reflects uiState — never disappears even when nbHits=0.
   ────────────────────────────────────────────────────────────── */
.as-active-filters {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    padding: 10px 12px;
    margin: 8px 0 10px;
    background: #f8fafc;
    border: 1px solid var(--aer-border, #e5e7eb);
    border-radius: var(--r-md, 8px);
}
.as-active-filters[hidden] { display: none; }
.as-active-filters__label {
    font-size: 12px;
    font-weight: 600;
    color: #475569;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    margin-right: 4px;
}
.as-active-filters__list {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    list-style: none;
    margin: 0;
    padding: 0;
    flex: 1 1 auto;
}
.as-active-filters__pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #fff;
    border: 1px solid var(--aer-border, #d4d4d8);
    border-radius: 999px;
    padding: 4px 4px 4px 10px;
    font-size: 13px;
    line-height: 1.3;
    color: var(--aer-text, #1f2937);
    transition: border-color 0.12s, background 0.12s;
}
.as-active-filters__pill:hover {
    border-color: var(--aer-text-muted, #94a3b8);
}
.as-active-filters__pill-key {
    font-weight: 600;
    color: var(--aer-text-muted, #475569);
    font-size: 12px;
}
.as-active-filters__pill-val {
    font-weight: 500;
}
.as-active-filters__remove {
    background: #f1f5f9;
    border: 0;
    border-radius: 999px;
    width: 20px;
    height: 20px;
    line-height: 1;
    font-size: 16px;
    color: #475569;
    cursor: pointer;
    padding: 0;
    margin: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: background 0.12s, color 0.12s;
}
.as-active-filters__remove:hover {
    background: var(--aer-danger, #dc2626);
    color: #fff;
}
.as-active-filters__clear-all {
    background: transparent;
    border: 1px solid var(--aer-danger, #dc2626);
    color: var(--aer-danger, #dc2626);
    border-radius: var(--r-sm, 4px);
    padding: 4px 10px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    margin-left: auto;
    transition: background 0.12s, color 0.12s;
}
.as-active-filters__clear-all:hover {
    background: var(--aer-danger, #dc2626);
    color: #fff;
}

@media (max-width: 768px) {
    .as-active-filters {
        padding: 8px;
        margin: 6px 0 8px;
    }
    .as-active-filters__label { display: none; }
    .as-active-filters__clear-all { margin-left: 0; }
}

/* ============================================================
   ════════ UNIFIED FILTER DESIGN SYSTEM ════════
   Tokeni i konzistentne stylinge za sve filter površine:
   sidebar checkboxes, toolbar dropdowns, active-filter pills,
   reset buttons, toggles. Stanja: inactive, hover, active,
   disabled, focus.
   ============================================================ */

:root {
    /* Tipografija */
    --filter-font-size:        13px;
    --filter-font-weight:      500;
    --filter-font-weight-active: 600;

    /* Dimenzije */
    --filter-radius:           6px;
    --filter-pad-x:            12px;
    --filter-check-size:       18px;
    --filter-check-radius:     4px;

    /* Boje — neutralne */
    --filter-bg:               #fff;
    --filter-bg-hover:         #f1f5f9;
    --filter-bg-active:        #eff6ff;
    --filter-bg-disabled:      #f8fafc;
    --filter-border:           #d1d5db;
    --filter-border-hover:     #94a3b8;
    --filter-text:             #1f2937;
    --filter-text-muted:       #64748b;
    --filter-text-disabled:    #cbd5e1;

    /* Boje — accent (selected/active) */
    --filter-accent:           var(--aer-primary, #1a578c);
    --filter-accent-bg-hover:  #dbeafe;
    --filter-accent-fg:        #fff;
    --filter-accent-hover:     #134970;

    /* Boje — danger (clear-all) */
    --filter-danger:           var(--aer-danger, #dc2626);
    --filter-danger-hover:     #b91c1c;
}

/* ── Sidebar checkbox — styled, replaces native HTML look ── */
.aeres-facet-item .aeres-facet-checkbox,
.as-toolbar-availability input[type="checkbox"]:not(.aeres-cm-toggle__input),
.aeres-checkbox {
    appearance: none;
    -webkit-appearance: none;
    width: var(--filter-check-size);
    height: var(--filter-check-size);
    margin: 0;
    flex-shrink: 0;
    border: 1.5px solid var(--filter-border);
    border-radius: var(--filter-check-radius);
    background: var(--filter-bg);
    position: relative;
    cursor: pointer;
    transition: background 0.12s, border-color 0.12s, box-shadow 0.12s;
    box-sizing: border-box;
    display: inline-block;
    vertical-align: middle;
}
.aeres-facet-item .aeres-facet-checkbox:hover,
.as-toolbar-availability input[type="checkbox"]:not(.aeres-cm-toggle__input):hover,
.aeres-checkbox:hover {
    border-color: var(--filter-accent);
}
.aeres-facet-item .aeres-facet-checkbox:checked,
.as-toolbar-availability input[type="checkbox"]:not(.aeres-cm-toggle__input):checked,
.aeres-checkbox:checked {
    background: var(--filter-accent);
    border-color: var(--filter-accent);
}
.aeres-facet-item .aeres-facet-checkbox:checked::after,
.as-toolbar-availability input[type="checkbox"]:not(.aeres-cm-toggle__input):checked::after,
.aeres-checkbox:checked::after {
    content: '';
    position: absolute;
    left: 5px;
    top: 1px;
    width: 5px;
    height: 10px;
    border: solid var(--filter-accent-fg);
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
    pointer-events: none;
}
.aeres-facet-item .aeres-facet-checkbox:disabled,
.aeres-checkbox:disabled {
    background: var(--filter-bg-disabled);
    border-color: var(--filter-border);
    cursor: not-allowed;
    opacity: 0.55;
}
.aeres-facet-item .aeres-facet-checkbox:focus-visible,
.as-toolbar-availability input[type="checkbox"]:not(.aeres-cm-toggle__input):focus-visible,
.aeres-checkbox:focus-visible {
    outline: 2px solid var(--filter-accent);
    outline-offset: 2px;
}

/* Disabled facet item (count=0) — siva, ne-klikabilna */
.aeres-facet-item.is-disabled .aeres-facet-label,
.aeres-facet-toggle.is-disabled,
.aeres-facet-item--disabled .aeres-facet-label {
    color: var(--filter-text-disabled);
    cursor: not-allowed;
    pointer-events: none;
}
.aeres-facet-item.is-disabled .aeres-facet-count,
.aeres-facet-item--disabled .aeres-facet-count {
    color: var(--filter-text-disabled);
}

/* ── Sidebar facet section header — has-selected indicator ── */
/* Plain (non-brand) blocks → tint title in accent when has selected.
   Brand block is special-cased below — when collapsed it gets the
   light-blue tint, when expanded the existing dark-blue gradient
   already provides contrast (white text). */
.aeres-facet-block.is-has-selected:not(.aeres-facet-block--brand) .aeres-facet-block__title {
    color: var(--filter-accent);
}
.aeres-facet-block--brand.is-collapsed.is-has-selected .aeres-facet-block__toggle .aeres-facet-block__title {
    color: var(--filter-accent);
}
/* Count badge — JS ga inseta kao .aeres-facet-block__badge sibling
   pored title-a unutar toggle button-a */
.aeres-facet-block__badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--filter-accent);
    color: var(--filter-accent-fg);
    font-size: 11px;
    font-weight: 700;
    line-height: 1;
    min-width: 18px;
    height: 18px;
    padding: 0 6px;
    border-radius: 9px;
    margin-left: 8px;
    box-sizing: border-box;
    vertical-align: middle;
}
/* In the brand block (white text on blue gradient when expanded) the
   badge needs to flip colors so it remains visible */
.aeres-facet-block--brand:not(.is-collapsed) .aeres-facet-block__badge {
    background: var(--filter-accent-fg);
    color: var(--filter-accent);
}
/* Brand block, collapsed + has selected → tint border accent */
.aeres-facet-block--brand.is-collapsed.is-has-selected .aeres-facet-block__toggle {
    border-color: var(--filter-accent) !important;
    background: linear-gradient(180deg, var(--filter-bg-active) 0%, #dbeafe 100%) !important;
    color: var(--filter-accent) !important;
}
.aeres-facet-block--brand.is-collapsed.is-has-selected .aeres-facet-block__toggle .aeres-facet-block__chev {
    color: var(--filter-accent) !important;
}

/* ── Toolbar dropdown — active state PLAVA (ne više zelena) ── */
.aeres-toolbar__dropdown.is-active .aeres-toolbar__trigger {
    background: var(--filter-bg-active) !important;
    border-color: var(--filter-accent) !important;
    color: var(--filter-accent) !important;
}
.aeres-toolbar__dropdown.is-active .aeres-toolbar__trigger:hover {
    background: var(--filter-accent-bg-hover) !important;
    border-color: var(--filter-accent-hover) !important;
}
.aeres-toolbar__dropdown.is-active .aeres-toolbar__trigger .aeres-toolbar__caret {
    color: var(--filter-accent) !important;
}
/* Bilo koji dropdown na default vrijednosti — NEMA active styling. To
   pokriva sort, price ("Sve"), surface itd. is-default-value klasu
   postavlja aeresUpdateFilterSelectedStates() na svaki render. */
.aeres-toolbar__dropdown.is-active.is-default-value .aeres-toolbar__trigger {
    background: var(--filter-bg) !important;
    border-color: var(--filter-border) !important;
    color: var(--filter-text) !important;
}
.aeres-toolbar__dropdown.is-active.is-default-value .aeres-toolbar__trigger:hover {
    background: var(--filter-bg-hover) !important;
    border-color: var(--filter-border-hover) !important;
}
.aeres-toolbar__dropdown.is-active.is-default-value .aeres-toolbar__trigger .aeres-toolbar__caret {
    color: var(--filter-text-muted) !important;
}

/* ── Active-filter pills — accent border, accent label ── */
.as-active-filters__pill {
    border-color: var(--filter-accent) !important;
    background: var(--filter-bg-active) !important;
}
.as-active-filters__pill:hover {
    border-color: var(--filter-accent-hover) !important;
    background: var(--filter-accent-bg-hover) !important;
}
.as-active-filters__pill-key {
    color: var(--filter-accent) !important;
    font-weight: var(--filter-font-weight-active) !important;
}
.as-active-filters__pill-val {
    color: var(--filter-text) !important;
    font-weight: var(--filter-font-weight-active) !important;
}

/* ── Reset buttons — uniformno: OUTLINED crveni za "obriši sve" ── */
.as-reset-all-filters {
    background: transparent !important;
    border: 1px solid var(--filter-danger) !important;
    color: var(--filter-danger) !important;
    font-weight: var(--filter-font-weight-active) !important;
    transition: background 0.12s, color 0.12s, border-color 0.12s !important;
}
.as-reset-all-filters:hover {
    background: var(--filter-danger) !important;
    color: var(--filter-accent-fg) !important;
    border-color: var(--filter-danger) !important;
}

/* ============================================================
   ════════ NEW TOOLBAR — 2-row grid layout ════════
   Column 1 (rowspan 2): Cijena slider (OD/DO + range handles)
   Column 2: Vrsta (top) / Cijena range dropdown (bottom)
   Column 3: Snaga (top) / Površina (bottom)
   Column 4: ClimateMatch (top) / Prikaži raspoloživo (bottom)
   Column 5 (rowspan 2): Search box
   ============================================================ */
@media (min-width: 992px) {
    .as-toolbar {
        display: grid !important;
        grid-template-columns:
            320px        /* col 1 — cijena slider */
            220px        /* col 2 — vrsta / cijena range (fits "Single split klima uređaji") */
            240px        /* col 3 — snaga / površina (fits "Za površine prostora (m²)") */
            220px        /* col 4 — CM / dostupno */
            1fr;         /* col 5 — active filters cell (block inside is capped at 280px) */
        /* Explicit row heights reserve the final layout from t=0. Without
           this, the rows default to `auto` and shrink while their content
           (dropdown triggers, toggles) is still being mounted by JS — the
           toolbar then jumps from ~133px to ~165px once widgets render,
           pushing everything below down by 32px. Fixed values lock the
           layout before content arrives. */
        grid-template-rows: 76px 56px;
        gap: 8px 14px;
        align-items: center;
        padding: 12px 16px;
        min-height: 165px;       /* belt-and-suspenders against the same shift */
        box-sizing: border-box;
    }
    /* Make search input fill its cell (otherwise the cell expands as 1fr but
       the input keeps its default width, leaving slack on the right) */
    .as-toolbar > .as-toolbar-cell--search { width: 100%; }
    .as-toolbar > .as-toolbar-cell--search #searchbox,
    .as-toolbar > .as-toolbar-cell--search .ais-SearchBox,
    .as-toolbar > .as-toolbar-cell--search .ais-SearchBox-form,
    .as-toolbar > .as-toolbar-cell--search .ais-SearchBox-input { width: 100%; }

    /* Hide mobile filter button on desktop (was inline-only before) */
    .as-toolbar > .as-toolbar-filter-btn { display: none !important; }

    /* Cell positioning */
    .as-toolbar > .as-toolbar-cell--cijena-slider {
        grid-column: 1; grid-row: 1 / span 2;
        align-self: stretch;
    }
    .as-toolbar > .as-toolbar-cell--vrsta        { grid-column: 2; grid-row: 1; }
    .as-toolbar > .as-toolbar-cell--cijena-rang  { grid-column: 2; grid-row: 2; }
    .as-toolbar > .as-toolbar-cell--snaga        { grid-column: 3; grid-row: 1; }
    .as-toolbar > .as-toolbar-cell--povrsina     { grid-column: 3; grid-row: 2; }
    .as-toolbar > .as-toolbar-cell--cm           { grid-column: 4; grid-row: 1; }
    .as-toolbar > .as-toolbar-cell--dostupno     { grid-column: 4; grid-row: 2; }
    .as-toolbar > .as-toolbar-cell--search {
        grid-column: 5; grid-row: 1 / span 2;
        align-self: center;
    }
    /* New active filters block — sits in Col 5 where the search box used
       to be. Spans both rows; align stretch (not center) so the block
       fills the full vertical height of Col 5 like the cijena slider
       block fills Col 1. */
    .as-toolbar > .as-toolbar-cell--filters {
        grid-column: 5; grid-row: 1 / span 2;
        align-self: stretch;
    }

    /* Per-cell internal layout — make dropdowns fill width of cell so the
       2-row column reads as one visual block rather than detached pills. */
    .as-toolbar > .as-toolbar-cell--vrsta,
    .as-toolbar > .as-toolbar-cell--cijena-rang,
    .as-toolbar > .as-toolbar-cell--snaga,
    .as-toolbar > .as-toolbar-cell--povrsina {
        align-self: stretch;
        display: flex;
    }
    .as-toolbar .as-toolbar-cell--vrsta > .aeres-toolbar__dropdown,
    .as-toolbar .as-toolbar-cell--cijena-rang .aeres-toolbar__dropdown,
    .as-toolbar .as-toolbar-cell--snaga > .aeres-toolbar__dropdown,
    .as-toolbar .as-toolbar-cell--povrsina > .aeres-toolbar__dropdown {
        width: 100%;
    }
}

/* ── Cijena slider in toolbar (compact vertical form) ──
   Per-index visibility: only active index's <div id="facet-X-price-range">
   is displayed. Other 9 are hidden (otherwise they stack and balloon
   the toolbar grid rows). JS sets `is-active` class in activateIndex(). */
.as-toolbar-cell--cijena-slider > .as-facet-price-range {
    display: none;
}
.as-toolbar-cell--cijena-slider > .as-facet-price-range.is-active {
    display: block;
}
   The widget's existing structure is OD/DO inputs (block) + range slider +
   2 reset buttons. We compact spacing and shrink fonts so it sits cleanly
   in the column-1 slot without towering above the other 2 rows. */
.as-toolbar-cell--cijena-slider .aeres-price-range {
    display: flex;
    flex-direction: column;
    gap: 4px;                   /* was 6px — tighter vertical rhythm */
    padding: 4px 8px;           /* was 8px 10px — saves 8px of vertical space
                                   while keeping comfortable side breathing room */
    background: var(--filter-bg, #fff);
    border: 1px solid var(--filter-border, #d1d5db);
    border-radius: var(--filter-radius, 6px);
    height: 100%;
    box-sizing: border-box;
    justify-content: center;
}
.as-toolbar-cell--cijena-slider .aeres-price-inputs {
    display: flex;
    flex-direction: row;        /* OD and DO side-by-side instead of stacked,
                                   saves ~37px of vertical space in the toolbar
                                   while still showing both labels, steppers,
                                   currency symbol, and the typed value. */
    gap: 8px;
    align-items: stretch;
}
.as-toolbar-cell--cijena-slider .aeres-price-input-row {
    display: flex;
    align-items: center;
    gap: 4px;
    flex: 1 1 0;                /* each row takes half of the available width */
    min-width: 0;
    width: auto;
}
.as-toolbar-cell--cijena-slider .aeres-price-row-label {
    font-size: 11px;
    font-weight: 600;
    color: var(--filter-text-muted, #64748b);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    flex: 0 0 auto;
    padding: 0;
}
.as-toolbar-cell--cijena-slider .aeres-price-input-group {
    display: flex;
    align-items: center;
    flex: 1 1 auto;
    min-width: 0;
    width: auto;
    padding: 1px 4px;
    gap: 1px;
    min-height: 42px;           /* +15px taller than the prior compact form,
                                   matches visual weight of adjacent toolbar
                                   dropdowns and gives the input a generous tap target */
}
.as-toolbar-cell--cijena-slider .aeres-price-input {
    flex: 1 1 auto;
    min-width: 0;
    width: 100%;
    border: 1px solid var(--filter-border, #d1d5db);
    border-radius: var(--filter-radius, 6px);
    padding: 8px 0;             /* matches min-height growth */
    font-size: 14px;
    font-variant-numeric: tabular-nums;
    text-align: center;
}
.as-toolbar-cell--cijena-slider .aeres-price-step {
    background: transparent;
    border: 0;
    width: 16px;                /* was 18px — 4px total saved gives input more digit room */
    min-width: 16px;
    height: 39px;
    cursor: pointer;
    color: var(--filter-text-muted, #64748b);
    font-size: 13px;            /* was 14px — proportional to narrower button */
    line-height: 1;
    padding: 0;
    flex: 0 0 auto;
}
.as-toolbar-cell--cijena-slider .aeres-price-step:hover { color: var(--filter-accent, #1a578c); }
.as-toolbar-cell--cijena-slider .aeres-price-cur {
    font-size: 11px;
    color: var(--filter-text-muted, #64748b);
    padding: 0 1px;
    flex: 0 0 auto;
}
.as-toolbar-cell--cijena-slider .aeres-price-slider {
    position: relative;
    height: 18px;
    margin: 0 6px;             /* was 2px 6px 0 — gap above is now controlled by aeres-price-range gap */
}
.as-toolbar-cell--cijena-slider .aeres-price-actions {
    display: flex;
    gap: 6px;
    margin-top: 8px;            /* was 2px — extra space prevents slider handles
                                   (28px tall, vire 5px below the 18px container)
                                   from overlapping the reset button row */
}
.as-toolbar-cell--cijena-slider .aeres-price-actions .as-price-range-reset {
    flex: 1 1 0;
    font-size: 11px;
    padding: 3px 8px;           /* was 4px 6px — slightly tighter vertically */
    line-height: 1.2;
    min-height: 0;
    height: auto;
}

/* ── ClimateMatch + In-stock toggle compactness in toolbar ── */
.as-toolbar-cell--cm .aeres-cm-toggle {
    margin: 0;
    padding: 4px 0;
}
/* Match the in-stock ("Prikaži samo raspoloživo") toggle to the same
   padding so its checkbox lines up vertically with the Climate Match
   checkbox. Base theme rule is `padding: 6px 12px` — the 12px left
   pushed the checkbox 12px to the right relative to Climate Match.
   Both .aeres-cm-toggle--compact and the .as-toolbar-availability-group
   wrapper covered defensively in case the modifier class moves later. */
.aeres-cm-toggle--compact,
.as-toolbar-availability-group .aeres-cm-toggle {
    margin: 0;
    padding: 4px 0;
}
.as-toolbar-cell--dostupno .as-toolbar-availability {
    padding: 0;
    display: flex;
    align-items: center;
}
.as-toolbar-cell--dostupno .as-toolbar-availability-group {
    width: 100%;
    min-height: 28px;          /* reserve real toggle height */
}
/* Reserve space for the toggle container so the real toggle (mounted by
   connectToggleRefinement on first InstantSearch render) drops into a
   pre-sized slot — no skeleton needed, no flash, no jump. */
.as-toolbar-cell--dostupno [id^="facet-"][id$="-availability"] {
    min-height: 28px;
}

/* ============================================================
   ClimateMatch "not set" popup modal
   Triggered from the toolbar CM toggle when state="unset" and
   user clicks the checkbox/label. Centered card, click-outside
   or Esc closes. Single primary CTA → /izracun-potrebnog-kapaciteta.
   ============================================================ */
.aeres-cm-modal {
    position: fixed;
    inset: 0;
    z-index: 99999;
    display: none;
    align-items: center;
    justify-content: center;
}
.aeres-cm-modal.is-open {
    display: flex;
}
.aeres-cm-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.55);
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
}
.aeres-cm-modal__dialog {
    position: relative;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 20px 48px rgba(0, 0, 0, 0.25);
    padding: 28px 28px 24px;
    max-width: 440px;
    width: calc(100% - 32px);
    z-index: 1;
    animation: aeres-cm-modal-in 180ms ease-out;
}
@keyframes aeres-cm-modal-in {
    from { transform: translateY(8px); opacity: 0; }
    to   { transform: translateY(0);   opacity: 1; }
}
.aeres-cm-modal__close {
    position: absolute;
    top: 8px;
    right: 12px;
    background: transparent;
    border: 0;
    font-size: 24px;
    line-height: 1;
    color: #94a3b8;
    cursor: pointer;
    padding: 4px 8px;
    border-radius: 6px;
}
.aeres-cm-modal__close:hover { background: #f1f5f9; color: #475569; }
.aeres-cm-modal__title {
    margin: 0 0 12px;
    font-size: 18px;
    font-weight: 600;
    color: #0f172a;
    line-height: 1.3;
}
.aeres-cm-modal__body {
    margin: 0 0 20px;
    font-size: 14px;
    line-height: 1.55;
    color: #475569;
}
.aeres-cm-modal__actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    flex-wrap: wrap;
}
.aeres-cm-modal__btn {
    padding: 9px 18px;
    border-radius: 8px;
    border: 0;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    line-height: 1.2;
    transition: background 120ms ease, color 120ms ease;
}
.aeres-cm-modal__btn--secondary {
    background: #f1f5f9;
    color: #475569;
}
.aeres-cm-modal__btn--secondary:hover { background: #e2e8f0; color: #1e293b; }
.aeres-cm-modal__btn--primary {
    background: var(--filter-accent, #1a578c);
    color: #fff;
}
.aeres-cm-modal__btn--primary:hover { background: #134268; color: #fff; }


/* ═══════════════════════════════════════════════════════════════════════
   AERES MOBILE FILTER & SORT CHROME — LIGHT THEME
   Migrated from templates/ja_atoms/css/template.css.
   Original was dark navy (#081a3f / #0b1d40 / #11305e), converted to
   white/slate-50 with slate-900 text and amber CTA accent.
   
   Bottom-sheet drawer pattern. Active only at viewports ≤ 768px.
   On desktop these rules don't trigger and the regular toolbar +
   sidebar handle filtering. On mobile the desktop toolbar + sidebar
   are hidden; a fixed bottom action bar shows Filteri + Sortiraj,
   each opening a sheet that slides up from the bottom.
   ═══════════════════════════════════════════════════════════════════════ */
/* ─────────────────────────────────────────────────────────────────────
   AERES MOBILE FILTER & SORT CHROME
   Bottom-sheet drawer pattern. Active only at viewports ≤ 768px.
   On desktop these rules don't trigger and the regular toolbar +
   sidebar handle filtering. On mobile the desktop toolbar + sidebar
   are hidden; a fixed bottom action bar shows Filteri + Sortiraj,
   each opening a sheet that slides up from the bottom.
   ─────────────────────────────────────────────────────────────────── */

/* Body scroll lock while a sheet is open. Doubled on html element
   so position:fixed bodies don't lose scroll positioning. */
html.aeres-m-no-scroll,
body.aeres-m-no-scroll {
    overflow: hidden !important;
    touch-action: none;
}

@media (max-width: 768px) {

    /* Hide desktop chrome that gets docked into the sheet. The chrome
       JS moves these nodes into the sheet body when opened; while
       they're in their original (desktop) position they should be
       invisible. We use visibility:hidden + height:0 rather than
       display:none so widget intersection observers and other code
       reading bounding boxes don't think the elements disappeared. */
    .as-toolbar,
    .as-sidebar {
        position: absolute !important;
        left: -99999px;
        top: 0;
        width: 1px;
        height: 1px;
        overflow: hidden;
        pointer-events: none;
    }

    /* When the toolbar / sidebar is docked into a sheet body, restore
       full layout for them inside the sheet. */
    .aeres-m-sheet__body .as-toolbar,
    .aeres-m-sheet__body .as-sidebar {
        position: static !important;
        left: auto;
        top: auto;
        width: auto;
        height: auto;
        overflow: visible;
        pointer-events: auto;
        /* Override pre-existing filter.css mobile transforms
           (translateX(-105%) at ≤768, translateX(105%) at ≤900) that
           were shifting the sidebar off-screen inside the sheet. */
        transform: none !important;
    }

    /* Hide the legacy mobile-drawer header that lives inside .as-sidebar
       — it carries its own "Filteri" title and "Očisti sve" / "Zatvori"
       buttons. Our sheet has its own header so this would duplicate. */
    .aeres-m-sheet__body .as-sidebar-sticky {
        display: none !important;
    }

    /* When the desktop toolbar lives inside the sheet, collapse its
       grid template into a single column of stacked rows for thumb-
       friendly scrolling. */
    .aeres-m-sheet__body .as-toolbar {
        display: flex !important;
        flex-direction: column !important;
        grid-template-columns: none !important;
        grid-template-rows: none !important;
        gap: 12px !important;
        padding: 4px 0 !important;
        min-height: 0 !important;
        background: transparent !important;
        border: 0 !important;
    }
    .aeres-m-sheet__body .as-toolbar-cell {
        width: 100% !important;
        min-width: 0 !important;
        max-width: none !important;
    }
    /* The "Filteri" trigger button inside the desktop toolbar (now
       inside the sheet body) is redundant when the sheet is already
       open — hide it. */
    .aeres-m-sheet__body .as-toolbar-filter-btn,
    /* "Aktivni filteri" header block is also covered by the badge in
       the action bar; keep filters list but drop its header chrome
       to save space. */
    .aeres-m-sheet__body .as-active-filters-block__header {
        display: none !important;
    }
    .aeres-m-sheet__body #stats {
        display: none !important;
    }

    /* The legacy "Obriši sve filtre" reset button styling is handled
       by the .aeres-price-actions button rules further down; we don't
       blanket-style every button inside the price range, because that
       was forcing the round − / + step buttons to full width and
       crushing the price input to 8px. */

    /* ── Action bar at the bottom of the viewport ───────────────── */
    .aeres-m-actionbar {
        position: fixed;
        left: 0;
        right: 0;
        bottom: 0;
        z-index: 200001;
        display: flex;
        align-items: stretch;
        background: rgba(255,255,255,.96);
        backdrop-filter: blur(8px);
        -webkit-backdrop-filter: blur(8px);
        border-top: 1px solid rgba(15,23,42,.08);
        box-shadow: 0 -8px 24px rgba(0,0,0,.25);
        padding-bottom: env(safe-area-inset-bottom, 0);
        font-family: inherit;
    }
    .aeres-m-actionbar__divider {
        width: 1px;
        background: rgba(15,23,42,.08);
        margin: 12px 0;
    }
    .aeres-m-actionbtn {
        flex: 1 1 50%;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        gap: 8px;
        padding: 16px 12px;
        min-height: 56px;
        background: transparent;
        border: 0;
        color: #0f172a;
        font-size: 15px;
        font-weight: 600;
        cursor: pointer;
        position: relative;
        transition: background-color .12s ease;
    }
    .aeres-m-actionbtn:active { background: rgba(15,23,42,.08); }
    .aeres-m-actionbtn__label { line-height: 1; }
    .aeres-m-actionbtn__badge {
        position: absolute;
        top: 6px;
        right: calc(50% - 38px);
        min-width: 18px;
        height: 18px;
        padding: 0 5px;
        border-radius: 9px;
        background: #ffc107;
        color: #0f172a;
        font-size: 11px;
        font-weight: 800;
        line-height: 18px;
        text-align: center;
    }

    /* Pad page content so the action bar doesn't cover results. */
    .as-results,
    main.as-results {
        padding-bottom: 72px !important;
    }

    /* ── Sheet (Filteri / Sortiraj) ─────────────────────────────── */
    .aeres-m-sheet {
        position: fixed;
        inset: 0;
        z-index: 200002;
        display: flex;
        align-items: flex-end;
        justify-content: stretch;
        pointer-events: auto;
        font-family: inherit;
    }
    .aeres-m-sheet[hidden] { display: none; }

    .aeres-m-sheet__backdrop {
        position: absolute;
        inset: 0;
        background: rgba(0,0,0,.5);
        opacity: 0;
        transition: opacity .28s ease;
    }
    .aeres-m-sheet.is-open .aeres-m-sheet__backdrop { opacity: 1; }

    .aeres-m-sheet__panel {
        position: relative;
        width: 100%;
        height: 100vh;
        max-height: 100vh;
        background: #ffffff;
        color: #0f172a;
        display: flex;
        flex-direction: column;
        transform: translateY(100%);
        transition: transform .28s cubic-bezier(.2,.8,.2,1);
        box-shadow: 0 -16px 48px rgba(0,0,0,.4);
        overflow: hidden;
    }
    .aeres-m-sheet.is-open .aeres-m-sheet__panel {
        transform: translateY(0);
    }
    /* Sort sheet keeps the bottom-sheet style (rounded top, partial height). */
    .aeres-m-sheet__panel--compact {
        height: auto;
        max-height: 75vh;
        border-top-left-radius: 18px;
        border-top-right-radius: 18px;
    }
    /* Filters sheet has no top radius because it's full-screen — radius
       on a full-bleed surface looks like a rendering bug. */

    .aeres-m-sheet__grabber {
        width: 36px;
        height: 4px;
        margin: 10px auto 4px;
        border-radius: 2px;
        background: rgba(15,23,42,.25);
        flex-shrink: 0;
    }

    .aeres-m-sheet__header {
        display: grid;
        grid-template-columns: 80px 1fr 56px;
        align-items: center;
        padding: 8px 12px 14px;
        gap: 8px;
        border-bottom: 1px solid rgba(15,23,42,.08);
        flex-shrink: 0;
    }
    .aeres-m-sheet__title {
        margin: 0;
        font-size: 17px;
        font-weight: 700;
        text-align: center;
        color: #0f172a;
        line-height: 1.2;
    }
    .aeres-m-sheet__reset {
        background: transparent;
        border: 0;
        color: #ffc107;
        font-size: 14px;
        font-weight: 600;
        padding: 8px 0;
        cursor: pointer;
        text-align: left;
    }
    .aeres-m-sheet__reset:active { opacity: .7; }
    .aeres-m-sheet__close {
        width: 44px;
        height: 44px;
        background: transparent;
        border: 0;
        color: #0f172a;
        justify-self: end;
        cursor: pointer;
        border-radius: 50%;
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }
    .aeres-m-sheet__close:active { background: rgba(15,23,42,.1); }

    .aeres-m-sheet__body {
        flex: 1 1 auto;
        overflow-y: auto;
        overflow-x: hidden;
        -webkit-overflow-scrolling: touch;
        padding: 12px 16px 16px;
        scrollbar-width: thin;
        scrollbar-color: rgba(15,23,42,.2) transparent;
    }
    .aeres-m-sheet__body::-webkit-scrollbar { width: 6px; }
    .aeres-m-sheet__body::-webkit-scrollbar-thumb {
        background: rgba(15,23,42,.2);
        border-radius: 3px;
    }

    .aeres-m-sheet__footer {
        flex-shrink: 0;
        padding: 12px 16px calc(12px + env(safe-area-inset-bottom, 0));
        border-top: 1px solid rgba(15,23,42,.08);
        background: rgba(255,255,255,.6);
    }
    .aeres-m-sheet__apply {
        width: 100%;
        min-height: 52px;
        padding: 14px 16px;
        background: #ffc107;
        color: #0f172a;
        border: 0;
        border-radius: 12px;
        font-size: 15px;
        font-weight: 700;
        cursor: pointer;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        gap: 6px;
        letter-spacing: .01em;
    }
    .aeres-m-sheet__apply strong {
        font-size: 17px;
        font-weight: 800;
    }
    .aeres-m-sheet__apply:active { transform: scale(.985); }

    /* ── Sort sheet — radio list ────────────────────────────────── */
    .aeres-m-sheet__body--sort {
        padding: 8px 0 16px;
    }
    .aeres-m-sort__list {
        display: flex;
        flex-direction: column;
    }
    .aeres-m-sort__option {
        display: grid;
        grid-template-columns: 1fr auto;
        align-items: center;
        gap: 12px;
        padding: 16px 20px;
        cursor: pointer;
        border-bottom: 1px solid rgba(15,23,42,.06);
        position: relative;
        font-size: 15px;
        color: #cbd5e1;
    }
    .aeres-m-sort__option:active { background: rgba(15,23,42,.05); }
    .aeres-m-sort__option input[type="radio"] {
        position: absolute;
        opacity: 0;
        pointer-events: none;
    }
    .aeres-m-sort__option-label {
        line-height: 1.3;
    }
    .aeres-m-sort__option-mark {
        width: 22px;
        height: 22px;
        border-radius: 50%;
        border: 2px solid rgba(15,23,42,.3);
        flex-shrink: 0;
        position: relative;
        transition: border-color .15s ease;
    }
    .aeres-m-sort__option.is-active .aeres-m-sort__option-mark,
    .aeres-m-sort__option input:checked ~ .aeres-m-sort__option-mark {
        border-color: #ffc107;
    }
    .aeres-m-sort__option.is-active .aeres-m-sort__option-mark::after,
    .aeres-m-sort__option input:checked ~ .aeres-m-sort__option-mark::after {
        content: '';
        position: absolute;
        inset: 4px;
        border-radius: 50%;
        background: #ffc107;
    }
    .aeres-m-sort__option.is-active,
    .aeres-m-sort__option input:checked ~ .aeres-m-sort__option-label {
        color: #0f172a;
        font-weight: 600;
    }
    .aeres-m-sort__empty {
        padding: 32px 20px;
        text-align: center;
        color: rgba(15,23,42,.6);
        font-size: 14px;
    }

    /* ── Facet block tweaks inside the sheet ─────────────────────
       The dynamic facet sections in the sidebar already have their
       own collapsible chrome (.aeres-facet-block--collapsible). When
       they live in the sheet body, neutralise any container effects
       (sticky positioning, max-height, scroll) the sidebar imposed. */
    .aeres-m-sheet__body .as-facet-group {
        margin-bottom: 8px;
        padding: 0 !important;
    }
    .aeres-m-sheet__body .as-toolbar-mobile,
    .aeres-m-sheet__body .as-sidebar-title,
    .aeres-m-sheet__body #searchbox,
    .aeres-m-sheet__body [id^="sort-"][hidden] {
        display: none !important;
    }

    /* ── Sheet panel: deeper gradient ─────────────────────────────── */
    .aeres-m-sheet--filters .aeres-m-sheet__panel,
    .aeres-m-sheet--sort .aeres-m-sheet__panel {
        background: linear-gradient(180deg, #f8fafc 0%, #ffffff 100%) !important;
    }
    .aeres-m-sheet__header {
        background: rgba(0,0,0,.18);
        backdrop-filter: blur(6px);
    }

    /* ── Toolbar cells become titled cards ────────────────────────── */
    .aeres-m-sheet__body .as-toolbar {
        gap: 14px !important;
        padding: 0 !important;
    }
    .aeres-m-sheet__body .as-toolbar-cell {
        background: rgba(15,23,42,.04);
        border: 1px solid rgba(15,23,42,.07);
        border-radius: 16px;
        padding: 16px 14px;
        margin: 0;
        min-width: 0;
        max-width: none;
        width: 100%;
        position: relative;
        box-shadow: 0 2px 8px rgba(0,0,0,.08);
    }
    .aeres-m-sheet__body .as-toolbar-cell::before {
        display: block;
        font-size: 11px;
        line-height: 1;
        text-transform: uppercase;
        letter-spacing: .12em;
        color: rgba(15,23,42,.5);
        margin-bottom: 12px;
        font-weight: 700;
    }
    .aeres-m-sheet__body .as-toolbar-cell--cijena-slider::before { content: 'Cijena'; }
    .aeres-m-sheet__body .as-toolbar-cell--vrsta::before { content: 'Vrsta uređaja'; }
    .aeres-m-sheet__body .as-toolbar-cell--cijena-rang::before { content: 'Cjenovni rang'; }
    .aeres-m-sheet__body .as-toolbar-cell--snaga::before { content: 'Kataloška snaga'; }
    .aeres-m-sheet__body .as-toolbar-cell--povrsina::before { content: 'Površina prostora'; }
    .aeres-m-sheet__body .as-toolbar-cell--cm::before { content: 'Personalizacija'; }
    .aeres-m-sheet__body .as-toolbar-cell--dostupno::before { content: 'Dostupnost'; }
    .aeres-m-sheet__body .as-toolbar-cell--filters::before { content: 'Aktivni filteri'; }

    /* ── Price inputs: critical fix (was width:1px) + premium look ── */
    .aeres-m-sheet__body .aeres-price-inputs {
        flex-direction: column !important;
        gap: 10px !important;
        width: 100% !important;
    }
    .aeres-m-sheet__body .aeres-price-input-row {
        display: flex !important;
        align-items: center !important;
        gap: 10px !important;
        width: 100% !important;
        margin-bottom: 0 !important;
    }
    .aeres-m-sheet__body .aeres-price-row-label {
        width: 30px;
        font-size: 12px;
        font-weight: 700;
        text-transform: uppercase;
        letter-spacing: .06em;
        color: rgba(15,23,42,.55);
        flex-shrink: 0;
    }
    .aeres-m-sheet__body .aeres-price-input-group {
        flex: 1;
        display: flex;
        align-items: center;
        gap: 6px;
        background: rgba(15,23,42,.06);
        border: 1px solid rgba(15,23,42,.12);
        border-radius: 12px;
        padding: 4px;
        transition: border-color .15s ease;
    }
    .aeres-m-sheet__body .aeres-price-input-group:focus-within {
        border-color: #ffc107;
        background: rgba(255,193,7,.05);
    }
    .aeres-m-sheet__body .aeres-price-input {
        flex: 1 1 0 !important;
        width: auto !important;
        min-width: 0 !important;
        height: 40px !important;
        background: transparent !important;
        border: 0 !important;
        color: #0f172a !important;
        font-size: 17px !important;
        font-weight: 700 !important;
        text-align: center !important;
        padding: 0 4px !important;
        outline: none !important;
        font-family: inherit !important;
    }
    .aeres-m-sheet__body .aeres-price-input::placeholder {
        color: rgba(15,23,42,.4);
        font-weight: 500;
    }
    .aeres-m-sheet__body .aeres-price-cur {
        color: rgba(15,23,42,.65);
        font-weight: 700;
        font-size: 15px;
        padding-right: 6px;
    }
    .aeres-m-sheet__body .aeres-price-step {
        width: 36px !important;
        height: 36px !important;
        min-width: 36px !important;
        max-width: 36px !important;
        flex: 0 0 36px !important;
        border-radius: 50%;
        background: rgba(15,23,42,.08);
        border: 0;
        color: #0f172a;
        font-size: 20px;
        font-weight: 400;
        cursor: pointer;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        line-height: 1;
        padding: 0;
        transition: background-color .15s;
    }
    .aeres-m-sheet__body .aeres-price-step:active {
        background: rgba(255,193,7,.25);
    }
    .aeres-m-sheet__body .aeres-price-slider {
        margin-top: 8px;
        margin-bottom: 14px;
    }
    .aeres-m-sheet__body .aeres-price-actions {
        display: flex;
        gap: 10px;
        margin-top: 14px;
    }
    .aeres-m-sheet__body .aeres-price-actions button {
        flex: 1;
        height: 42px;
        border-radius: 10px;
        font-size: 13px;
        font-weight: 600;
        border: 1px solid rgba(15,23,42,.15);
        background: rgba(15,23,42,.04);
        color: #0f172a;
        cursor: pointer;
    }
    /* The legacy "Obriši sve filtre" button is redundant inside the
       sheet (we have global Resetiraj in the header). Hide it. */
    .aeres-m-sheet__body .as-price-range-reset.as-reset-all-filters,
    .aeres-m-sheet__body button.as-reset-all-filters {
        display: none !important;
    }

    /* ── Dropdowns (Vrsta, Cjenovni rang, Snaga, Površina) ────────── */
    .aeres-m-sheet__body .aeres-toolbar__dropdown {
        min-height: 52px;
        background: rgba(15,23,42,.06);
        border: 1px solid rgba(15,23,42,.12);
        border-radius: 12px;
        padding: 10px 16px;
        font-size: 15px;
        font-weight: 600;
        color: #0f172a;
        display: flex;
        align-items: center;
        cursor: pointer;
    }
    .aeres-m-sheet__body .aeres-toolbar__dropdown:active {
        background: rgba(15,23,42,.1);
    }

    /* ── Climate Match toggle (full-width premium card) ───────────── */
    .aeres-m-sheet__body .aeres-cm-toggle {
        width: 100%;
        padding: 4px;
        background: linear-gradient(135deg, rgba(255,193,7,.06), rgba(255,193,7,.02));
        border-radius: 12px;
        border: 1px solid rgba(255,193,7,.15);
        cursor: pointer;
    }
    .aeres-m-sheet__body .aeres-cm-toggle__text {
        font-size: 14px;
        line-height: 1.4;
    }
    .aeres-m-sheet__body .aeres-cm-toggle__main {
        color: #0f172a;
        font-weight: 600;
    }
    .aeres-m-sheet__body .aeres-cm-toggle__sub {
        color: rgba(15,23,42,.55);
        font-size: 12px;
    }
    .aeres-m-sheet__body .aeres-cm-toggle__link {
        color: #ffc107;
        font-weight: 700;
    }

    /* ── Availability toggle ──────────────────────────────────────── */
    .aeres-m-sheet__body .as-toolbar-availability,
    .aeres-m-sheet__body .as-toolbar-availability label {
        color: #0f172a;
        font-size: 15px;
        font-weight: 500;
    }

    /* ── Active filters block ─────────────────────────────────────── */
    .aeres-m-sheet__body .as-active-filters-block {
        width: 100%;
    }
    .aeres-m-sheet__body .as-active-filters {
        background: rgba(0,0,0,.18);
        border-radius: 10px;
        padding: 14px;
        min-height: 44px;
        color: rgba(15,23,42,.55);
        font-size: 13px;
        font-style: italic;
        text-align: center;
    }
    .aeres-m-sheet__body .as-active-filters:empty::before {
        content: 'Još niste odabrali nijedan filter';
    }

    /* ── Facet blocks (Proizvođač, Vremensko programiranje, …) ─────
       Solid bg required: a translucent rgba on the panel gradient
       sometimes renders as near-white in some browsers/screenshots,
       making white toggle text disappear. Solid #ffffff gives the
       cards reliable contrast against the panel background. */
    .aeres-m-sheet__body .aeres-facet-block {
        background: #ffffff !important;
        border: 1px solid rgba(15,23,42,.1);
        border-radius: 16px;
        margin: 0 0 12px 0;
        overflow: hidden;
        box-shadow: 0 2px 8px rgba(0,0,0,.08);
    }
    .aeres-m-sheet__body .aeres-facet-block__toggle {
        width: 100%;
        padding: 18px 16px;
        font-size: 14px;
        font-weight: 700;
        letter-spacing: .02em;
        color: #0f172a !important;
        background: transparent;
        border: 0;
        display: flex;
        align-items: center;
        gap: 12px;
        cursor: pointer;
        text-align: left;
        line-height: 1.2;
    }
    .aeres-m-sheet__body .aeres-facet-block__toggle:active {
        background: rgba(15,23,42,.04);
    }
    .aeres-m-sheet__body .aeres-facet-block__icon {
        width: 20px !important;
        height: 20px !important;
        opacity: .85;
        flex-shrink: 0;
    }
    .aeres-m-sheet__body .aeres-facet-block__title {
        flex: 1;
        font-size: 14px !important;
        font-weight: 700 !important;
        letter-spacing: .02em !important;
        color: #0f172a !important;
        text-transform: uppercase !important;
        text-align: left;
    }
    .aeres-m-sheet__body .aeres-facet-block__chev,
    .aeres-m-sheet__body .aeres-facet-block__toggle svg {
        width: 16px;
        height: 16px;
        margin-left: auto;
        color: rgba(15,23,42,.5);
        flex-shrink: 0;
    }
    .aeres-m-sheet__body .aeres-facet-block__body {
        padding: 0 14px 14px;
    }

    /* ── Apply CTA: premium gradient + glow ───────────────────────── */
    .aeres-m-sheet__footer {
        background: linear-gradient(180deg, transparent 0%, rgba(0,0,0,.18) 100%);
        border-top: 1px solid rgba(15,23,42,.06);
        padding: 14px 16px calc(14px + env(safe-area-inset-bottom, 0));
    }
    .aeres-m-sheet__apply {
        background: linear-gradient(135deg, #ffd54a 0%, #ffc107 50%, #ffa000 100%) !important;
        border: 0;
        color: #0f172a;
        box-shadow:
            0 10px 28px -8px rgba(255, 193, 7, .5),
            0 0 0 1px rgba(15,23,42,.15) inset;
        font-size: 16px !important;
        font-weight: 800 !important;
        letter-spacing: -.005em;
        min-height: 54px;
        border-radius: 14px;
    }
    .aeres-m-sheet__apply strong {
        font-size: 18px !important;
    }
    .aeres-m-sheet__apply:active {
        transform: scale(.98);
        box-shadow: 0 4px 12px -4px rgba(255,193,7,.4);
    }

    /* ── Bottom action bar: glass premium ─────────────────────────── */
    .aeres-m-actionbar {
        background: linear-gradient(180deg, rgba(255,255,255,.7) 0%, rgba(255,255,255,.96) 60%) !important;
        backdrop-filter: blur(20px) saturate(180%) !important;
        -webkit-backdrop-filter: blur(20px) saturate(180%) !important;
        border-top: 1px solid rgba(15,23,42,.08);
    }
    .aeres-m-actionbtn {
        font-size: 15px;
        font-weight: 700;
        letter-spacing: -.005em;
        min-height: 60px;
    }
    .aeres-m-actionbtn svg { opacity: .9; }
    .aeres-m-actionbtn__badge {
        background: linear-gradient(135deg, #ffd54a, #ffa000) !important;
        color: #0f172a;
        box-shadow: 0 2px 6px rgba(255,193,7,.4);
    }

    /* ── Sort sheet polish ────────────────────────────────────────── */
    .aeres-m-sort__option {
        padding: 18px 22px;
    }
    .aeres-m-sort__option-label {
        font-size: 15px;
    }
}

/* Above the mobile breakpoint, ensure the action bar (if for some
   reason it lingers from a resize transition) is hidden. */
@media (min-width: 769px) {
    .aeres-m-actionbar,
    .aeres-m-sheet { display: none !important; }
}


.aeres-search .as-hit-title,
.as-hit-col--model .as-hit-model,
.as-hit-model-title {
    display: block;
    -webkit-line-clamp: none;
    -webkit-box-orient: initial;
    overflow: visible;
    text-overflow: clip;
    height: auto;
    max-height: none;
}

.as-results-header .as-ispravak{
    margin: 6px 0 0;
    font-size: 14px;
    line-height: 1.4;
    color: #4b5563;
}

.as-results-header .as-ispravak strong{
    color: #1e293b;
}

.as-results-header .as-ispravak a{
    color: #1d4ed8;
    text-decoration: underline;
}
