/* Sitewide header search (Theme Builder) */
.iace-header-search {
	display: flex;
	align-items: center;
	margin-left: 0.75rem;
	position: relative;
	z-index: 20;
}

.iace-header-search__toggle {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 2.25rem;
	height: 2.25rem;
	padding: 0;
	border: 0;
	background: transparent;
	cursor: pointer;
	color: inherit;
}

.iace-header-search__icon {
	display: block;
	width: 1.05rem;
	height: 1.05rem;
	border: 2px solid currentColor;
	border-radius: 50%;
	position: relative;
	box-sizing: border-box;
}

.iace-header-search__icon::after {
	content: "";
	position: absolute;
	width: 0.45rem;
	height: 2px;
	background: currentColor;
	right: -0.35rem;
	bottom: -0.15rem;
	transform: rotate(45deg);
	border-radius: 1px;
}

.iace-header-search__form {
	display: flex;
	align-items: center;
	gap: 0.35rem;
	position: absolute;
	right: 0;
	top: calc(100% + 0.4rem);
	min-width: min(22rem, 80vw);
	padding: 0.5rem;
	background: #fff;
	border: 1px solid rgba(0, 0, 0, 0.12);
	box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

.iace-header-search__form[hidden] {
	display: none !important;
}

.iace-header-search__field {
	flex: 1 1 auto;
	min-width: 0;
	border: 1px solid rgba(0, 0, 0, 0.2);
	padding: 0.45rem 0.6rem;
	font-size: 0.95rem;
	line-height: 1.3;
	color: #222;
	background: #fff;
}

.iace-header-search__submit {
	border: 0;
	background: #1b3664;
	color: #fff;
	padding: 0.45rem 0.75rem;
	cursor: pointer;
	font-size: 0.85rem;
}

.iace-header-search__close {
	border: 0;
	background: transparent;
	color: #333;
	font-size: 1.35rem;
	line-height: 1;
	cursor: pointer;
	padding: 0 0.25rem;
}

@media (max-width: 980px) {
	.iace-header-search {
		margin-left: 0.35rem;
	}

	.iace-header-search__form {
		right: 0;
		min-width: min(18rem, 85vw);
	}
}
