/* Smart News Search — kept minimal so it inherits the theme's fonts and colours. */
.sns-toolbar {
	box-sizing: border-box;
	width: 100%;
	max-width: 100%;
	flex: 0 0 100%;       /* if it ever sits inside a flex row */
	grid-column: 1 / -1;  /* or a grid */
	margin: 0 0 1.5em;
	padding: 0 0 1em;
	border-bottom: 1px solid rgba(0, 0, 0, .12);
	font-size: .95em;
}
.sns-count { margin-bottom: .6em; }
.sns-controls { display: flex; flex-wrap: wrap; gap: .5em 1.25em; }
.sns-group { display: inline-flex; flex-wrap: wrap; gap: .35em; }
.sns-chip {
	display: inline-block;
	padding: .25em .75em;
	border: 1px solid rgba(0, 0, 0, .2);
	border-radius: 999px;
	text-decoration: none !important;
	color: inherit;
	line-height: 1.5;
	font-size: .9em;
}
.sns-chip:hover { border-color: currentColor; }
.sns-chip.is-active,
.sns-chip.is-active:hover { background: var(--sns-accent, #111); border-color: var(--sns-accent, #111); color: #fff !important; }
.sns-chip:focus-visible { outline: 2px solid var(--sns-accent, #111); outline-offset: 2px; }

/* Until the script places the bar above the results, keep it hidden (no jump). */
.sns-js .sns-toolbar:not(.is-placed):not(.sns-fixed) { display: none; }
.sns-note { margin-top: .75em; font-size: .9em; opacity: .85; }
.sns-note a { margin-left: .35em; }

mark.sns-hl {
	background: var(--sns-mark, #fff3a3);
	color: inherit;
	box-decoration-break: clone;
	-webkit-box-decoration-break: clone;
	padding: 0 .1em;
	border-radius: 2px;
}

.sns-form { margin: 0 0 1.5em; }
.sns-form-row { display: flex; gap: .5em; flex-wrap: wrap; }
.sns-form-row + .sns-form-row { margin-top: .5em; }
.sns-form input[type="search"] { flex: 1 1 240px; min-width: 0; padding: .5em .75em; }
.sns-form button { padding: .5em 1.25em; cursor: pointer; }
.sns-form select { padding: .35em .5em; max-width: 100%; }

@media (max-width: 600px) {
	.sns-controls { flex-direction: column; gap: .5em; }
	.sns-group { flex-wrap: nowrap; overflow-x: auto; -webkit-overflow-scrolling: touch; padding-bottom: 2px; }
	.sns-chip { white-space: nowrap; }
}

@media (prefers-color-scheme: dark) {
	.sns-toolbar { border-bottom-color: rgba(255, 255, 255, .15); }
	.sns-chip { border-color: rgba(255, 255, 255, .3); }
}
