/* ==========================================================================
 * SEARCH (Relevanssi)  —  styling for the [live_search] shortcode.
 *
 * Migrated from the theme's custom.css. The search field's appearance
 * (background, text, placeholder, border colour/width, corner radius, font)
 * is driven by CSS variables set from the module settings, with the original
 * values as fallbacks. The live-results dropdown keeps fixed structural styling.
 * ========================================================================== */

.bc-search-wrap {
	position: relative;
	width: 100%;
}

.bc-search-wrap .relevanssi-search-form {
	position: relative;
	width: 100%;
	z-index: 20;
}

.bc-search-wrap .relevanssi-search-form input[type="search"] {
	width: 100%;
	padding: 10px 15px;
	box-sizing: border-box;
	background-color: var(--bc-search-bg, #fff);
	color: var(--bc-search-text, #000);
	border: var(--bc-search-border-width, 3px) solid var(--bc-search-border-color, #f08e35);
	border-radius: var(--bc-search-radius, 45px);
	font-family: var(--bc-search-font, inherit);
	font-size: 16px;
}

.bc-search-wrap .relevanssi-search-form input[type="search"]::placeholder               { color: var(--bc-search-placeholder, #000); }
.bc-search-wrap .relevanssi-search-form input[type="search"]::-webkit-input-placeholder { color: var(--bc-search-placeholder, #000); }
.bc-search-wrap .relevanssi-search-form input[type="search"]::-moz-placeholder          { color: var(--bc-search-placeholder, #000); opacity: 1; }
.bc-search-wrap .relevanssi-search-form input[type="search"]:-ms-input-placeholder      { color: var(--bc-search-placeholder, #000); }

/* Live results dropdown */
#rlv-live-results {
	position: absolute;
	top: calc(100% + 8px);
	left: 0;
	width: 100%;
	z-index: 99999;
}

#rlv-live-results .relevanssi-live-search-results {
	position: static !important;
	top: auto !important;
	left: auto !important;
	width: 100% !important;
	margin: 0;
	background: #fff;
	border: 1px solid #ddd;
	border-radius: 16px;
	box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
	overflow: hidden;
}

#rlv-live-results .ajax-results {
	max-height: 420px;
	overflow-y: auto;
}

#rlv-live-results .relevanssi-live-search-result-count {
	margin: 0;
	padding: 12px 16px;
	background: #fff;
	border-bottom: 1px solid #eee;
}

#rlv-live-results .ajax-results a {
	display: block;
	padding: 12px 16px;
	text-decoration: none;
}

#rlv-live-results .ajax-results a:hover {
	background: #f9f9f9;
}
