/* Brentwood Library Search — a GET form that sends the typed query to an
 * external catalogue (EBSCO). Self-contained; accent colour comes from
 * --bw-ls-accent on the wrapper. */

.bw-ls,
.bw-ls * {
	box-sizing: border-box;
}

/* Scoped under .bw-ls to outrank Kadence's ".single-content form" rule
 * (specificity 0,1,1) which otherwise forces margin-bottom: var(--global-md-spacing). */
.bw-ls .bw-ls__form {
	margin: 0 0 10px;
}

/* Input + button on one line; on narrow screens they stack. */
.bw-ls__row {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
	align-items: stretch;
}

.bw-ls--full .bw-ls__row {
	width: 100%;
}

.bw-ls__input {
	flex: 1 1 16rem;
	min-width: 0;
	padding: 0.65rem 0.9rem;
	font-size: 1rem;
	line-height: 1.4;
	color: #1f2937;
	background: #fff;
	border: 1px solid #d1d5db;
	border-radius: 4px;
	-webkit-appearance: none;
	appearance: none;
	transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.bw-ls__input:focus {
	outline: none;
	border-color: var(--bw-ls-accent, #cc0000);
	box-shadow: 0 0 0 2px rgba(204, 0, 0, 0.15);
}

.bw-ls__input::placeholder {
	color: #9ca3af;
}

/* Button — hard resets (!important) so the theme's global button styling can't
 * leak in (same approach as the modal/lightbox buttons in sibling blocks). */
.bw-ls__button {
	flex: 0 0 auto;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	margin: 0;
	padding: 0.65rem 1.4rem !important;
	font-size: 1rem;
	font-weight: 600;
	line-height: 1.4;
	color: #fff !important;
	background: var(--bw-ls-accent, #cc0000) !important;
	border: 0 !important;
	border-radius: 4px !important;
	cursor: pointer;
	-webkit-appearance: none;
	appearance: none;
	transition: filter 0.2s ease;
}

.bw-ls__button:hover,
.bw-ls__button:focus {
	filter: brightness(0.9);
	color: #fff !important;
	outline: none;
}

/* ── secondary links (Advanced Search | Browse Databases) ──────────────────── */
.bw-ls__links {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	margin-top: 0.3rem;
	line-height: 1.2;
}

.bw-ls__link {
	color: var(--bw-ls-accent, #cc0000);
	font-size: 0.9rem;
	font-weight: 400;
	text-decoration: none;
	transition: color 0.2s ease;
}

.bw-ls__link:hover,
.bw-ls__link:focus {
	text-decoration: underline;
	filter: brightness(0.9);
}

/* Pipe separator between adjacent links — matches the live "x | y". */
.bw-ls__link + .bw-ls__link::before {
	content: "|";
	margin: 0 0.55rem;
	color: #b8b8b8;
	font-weight: 400;
	text-decoration: none;
	display: inline-block;
}

.bw-ls__notice {
	margin: 0;
	padding: 0.5rem 0.75rem;
	color: #92400e;
	background: #fef3c7;
	border: 1px solid #fcd34d;
	border-radius: 4px;
	font-size: 0.9rem;
}

@media (max-width: 480px) {
	.bw-ls__input,
	.bw-ls__button {
		flex: 1 1 100%;
	}
}
