/* Filtri del catalogo. Desktop: colonna. Tablet/mobile (≤1024): pannello laterale aperto dal pulsante "Filtri". */
.ev-filters__panel { border: 1px solid var(--ev-color-border); border-radius: var(--ev-radius-lg); background: #fff; }
.ev-filters__head, .ev-filters__foot, .ev-filters__overlay { display: none; }
.ev-filters__body { padding: 0 var(--ev-space-4); }

.ev-filter { border-bottom: 1px solid var(--ev-color-border); }
.ev-filter:last-child { border-bottom: 0; }
.ev-filter__title { display: flex; align-items: center; justify-content: space-between; gap: var(--ev-space-2); padding: var(--ev-space-4) 0; cursor: pointer; list-style: none; font-size: var(--ev-text-sm); font-weight: var(--ev-font-weight-bold); color: var(--ev-color-text); }
.ev-filter__title::-webkit-details-marker { display: none; }
.ev-filter__title:focus-visible { outline: 2px solid var(--ev-color-focus); outline-offset: 2px; }
.ev-filter__caret { width: 16px; height: 16px; color: var(--ev-color-text-muted); transition: transform var(--ev-duration) var(--ev-ease); }
.ev-filter[open] .ev-filter__caret { transform: rotate(180deg); }
.ev-filter__list { display: grid; gap: 2px; margin: 0 0 var(--ev-space-3); padding: 0; list-style: none; }
.ev-filter__list > li[hidden] { display: none; }
.ev-filter__opt { display: flex; align-items: center; gap: var(--ev-space-2); padding: 6px var(--ev-space-1); border-radius: var(--ev-radius-sm); color: var(--ev-color-text); font-size: var(--ev-text-sm); text-decoration: none; }
.ev-filter__opt:hover { background: var(--ev-color-surface); }
.ev-filter__opt:focus-visible { outline: 2px solid var(--ev-color-focus); outline-offset: 0; }
.ev-filter__box { display: grid; place-items: center; width: 18px; height: 18px; flex: none; border: 1.5px solid var(--ev-color-border-strong); border-radius: 4px; background: #fff; color: #fff; }
.ev-filter__box .ev-icon { width: 13px; height: 13px; stroke-width: 3; opacity: 0; }
.ev-filter__opt[aria-checked="true"] .ev-filter__box { background: var(--ev-color-brand); border-color: var(--ev-color-brand); }
.ev-filter__opt[aria-checked="true"] .ev-filter__box .ev-icon { opacity: 1; }
.ev-filter__opt[aria-checked="true"] .ev-filter__name { font-weight: var(--ev-font-weight-semibold); }
.ev-filter__name { flex: 1; min-width: 0; }
.ev-filter__count { font-size: var(--ev-text-xs); color: var(--ev-color-text-muted); }
.ev-filter__toggle { margin: 0 0 var(--ev-space-3); padding: 0; border: 0; background: none; font: inherit; font-size: var(--ev-text-sm); font-weight: var(--ev-font-weight-semibold); color: var(--ev-color-brand); cursor: pointer; }
.ev-filter__price { display: grid; gap: var(--ev-space-3); margin-bottom: var(--ev-space-4); }
.ev-filter__range { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: var(--ev-space-2); color: var(--ev-color-text-muted); }
.ev-filter__range .ev-input { min-height: 40px; }

/* Caricamento: la griglia si attenua mentre arrivano i risultati. */
.ev-filters-loading [data-ev-region="grid"] { opacity: 0.45; pointer-events: none; transition: opacity var(--ev-duration) var(--ev-ease); }

@media (max-width: 1024px) {
	.ev-filters { position: fixed; inset: 0; z-index: var(--ev-z-drawer); visibility: hidden; pointer-events: none; }
	.ev-filters.is-open { visibility: visible; pointer-events: auto; }
	.ev-filters__overlay { display: block; position: absolute; inset: 0; background: rgb(22 26 34 / 0.5); opacity: 0; transition: opacity var(--ev-duration) var(--ev-ease); }
	.ev-filters.is-open .ev-filters__overlay { opacity: 1; }
	.ev-filters__panel { position: absolute; inset: 0 auto 0 0; display: flex; flex-direction: column; width: min(380px, 90vw); border: 0; border-radius: 0; box-shadow: var(--ev-shadow-lg); transform: translateX(-100%); transition: transform var(--ev-duration) var(--ev-ease); }
	.ev-filters.is-open .ev-filters__panel { transform: none; }
	.ev-filters__head { display: flex; align-items: center; justify-content: space-between; padding: var(--ev-space-4); border-bottom: 1px solid var(--ev-color-border); font-size: var(--ev-text-lg); }
	.ev-filters__close { display: grid; place-items: center; width: 40px; height: 40px; border: 0; background: none; color: var(--ev-color-text); cursor: pointer; }
	.ev-filters__close .ev-icon { width: 22px; height: 22px; }
	.ev-filters__body { flex: 1; overflow-y: auto; }
	.ev-filters__foot { display: flex; align-items: center; gap: var(--ev-space-4); padding: var(--ev-space-4); border-top: 1px solid var(--ev-color-border); }
	.ev-filters__foot .ev-btn { flex: 1; }
	html.ev-filters-open { overflow: hidden; }
}
