/* AG Filter Styler — advanced live search dropdown */

/* Hide Flatsome's own live-search dropdown while ours is active. */
.agfs-live .autocomplete-suggestions,
.agfs-live .live-search-results { display: none !important; }

.agfs-sr {
	position: absolute;
	z-index: 100000;
	box-sizing: border-box;
	max-height: min(70vh, 520px);
	overflow-y: auto;
	padding: 6px;
	border: 1px solid var(--agfs-border, #e5e7eb);
	border-radius: var(--agfs-radius, 10px);
	background: var(--agfs-bg, #fff);
	box-shadow: 0 14px 40px rgba(17, 24, 39, .18);
	color: var(--agfs-text, #2b2b2b);
	text-align: start;
}
.agfs-sr[hidden] { display: none; }

.agfs-sr-item {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 8px;
	border-radius: calc(var(--agfs-radius, 10px) * .7);
	color: inherit;
	text-decoration: none;
	transition: background .12s ease;
}
.agfs-sr-item:hover,
.agfs-sr-item.is-active { background: rgba(0, 0, 0, .05); }
.agfs-sr-item img {
	flex: none;
	width: 52px;
	height: 52px;
	object-fit: cover;
	border-radius: calc(var(--agfs-radius, 10px) * .6);
	background: #f3f4f6;
}
.agfs-sr-t { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.agfs-sr-t strong {
	font-size: 14px;
	font-weight: 600;
	line-height: 1.5;
	overflow: hidden;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
}
.agfs-sr-m {
	align-self: flex-start;
	padding: 1px 8px;
	border-radius: 999px;
	background: var(--agfs-primary, #446084);
	color: #fff;
	font-size: 11px;
	font-style: normal;
	line-height: 1.8;
}
.agfs-sr-m.is-muted { background: rgba(0, 0, 0, .06); color: #6b7280; }
.agfs-sr-p { font-size: 13px; color: var(--agfs-primary, #446084); }
.agfs-sr-p del { opacity: .55; margin-inline-end: 6px; }
.agfs-sr-p ins { text-decoration: none; }

.agfs-sr-empty { padding: 18px 12px; text-align: center; color: #6b7280; font-size: 14px; }
.agfs-sr-all {
	display: block;
	margin-top: 4px;
	padding: 10px;
	border-top: 1px solid var(--agfs-border, #e5e7eb);
	text-align: center;
	color: var(--agfs-primary, #446084);
	font-size: 13px;
	font-weight: 600;
	text-decoration: none;
}

input.agfs-sr-loading {
	background-image: linear-gradient(90deg, transparent, rgba(0, 0, 0, .06), transparent);
	background-size: 200% 100%;
	animation: agfs-sr-load 1s linear infinite;
}
@keyframes agfs-sr-load { from { background-position: 200% 0; } to { background-position: -200% 0; } }
@media (prefers-reduced-motion: reduce) { input.agfs-sr-loading { animation: none; } }
