/* Werksmans Portal Bridge — bio cards + search box (front-end). All scoped
   under .werksmans-* with wpb- prefix to survive Avada utility CSS. */

/* ── Bio card ───────────────────────────────────────────────── */
.werksmans-bio.wpb-bio {
	display: flex;
	gap: 20px;
	align-items: flex-start;
	padding: 20px;
	background: #fff;
	border: 1px solid #e8e8e8;
	border-radius: 4px;
	margin: 16px 0;
	font-family: inherit;
	color: #1a1a1a;
}
.werksmans-bio .wpb-bio-image {
	flex-shrink: 0;
	width: 140px;
}
.werksmans-bio .wpb-bio-image img {
	width: 100%;
	height: auto;
	display: block;
	border-radius: 2px;
}
.werksmans-bio .wpb-bio-body { flex: 1; min-width: 0; }
.werksmans-bio .wpb-bio-name {
	margin: 0 0 4px 0;
	font-size: 1.3em;
	line-height: 1.2;
	color: #1a1a1a;
}
.werksmans-bio .wpb-bio-designation {
	margin: 0 0 2px 0;
	font-weight: 600;
	color: #c9a96e;
	font-size: 0.95em;
}
.werksmans-bio .wpb-bio-location {
	margin: 0 0 12px 0;
	color: #777;
	font-size: 0.9em;
}
.werksmans-bio .wpb-bio-practice {
	margin: 0 0 12px 0;
	padding: 0;
	list-style: none;
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
}
.werksmans-bio .wpb-bio-practice li {
	background: #f5f1e8;
	color: #6b5b35;
	padding: 3px 10px;
	border-radius: 10px;
	font-size: 0.8em;
}
.werksmans-bio .wpb-bio-excerpt {
	margin: 0 0 14px 0;
	color: #444;
	font-size: 0.95em;
	line-height: 1.5;
}
.werksmans-bio .wpb-bio-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
}
.werksmans-bio .wpb-bio-link,
.werksmans-bio .wpb-bio-pdf {
	display: inline-block;
	padding: 8px 16px;
	text-decoration: none;
	font-size: 0.9em;
	font-weight: 600;
	border-radius: 2px;
	transition: background 200ms ease, color 200ms ease;
}
.werksmans-bio .wpb-bio-link { background: #1a1a1a; color: #fff; }
.werksmans-bio .wpb-bio-link:hover { background: #333; color: #fff; }
.werksmans-bio .wpb-bio-pdf { background: #c9a96e; color: #1a1a1a; }
.werksmans-bio .wpb-bio-pdf:hover { background: #e0c089; }

/* Compact variant */
.werksmans-bio.wpb-bio--compact { padding: 12px 16px; }
.werksmans-bio.wpb-bio--compact .wpb-bio-image { width: 70px; }
.werksmans-bio.wpb-bio--compact .wpb-bio-name { font-size: 1.05em; }

@media (max-width: 600px) {
	.werksmans-bio.wpb-bio {
		flex-direction: column;
		gap: 12px;
	}
	.werksmans-bio .wpb-bio-image { width: 100%; max-width: 220px; }
}

.wpb-bio-error {
	background: #fff5f5;
	border: 1px dashed #e2a8a8;
	padding: 12px 16px;
	border-radius: 3px;
	color: #8b3a3a;
}

/* ── Search box ─────────────────────────────────────────────── */
/* Brand greens: Disruptor #1ce5be, Shadow #18b294, Light tint #a8f0e0. */
.werksmans-search.wpb-search {
	margin: 16px 0;
	font-family: inherit;
	width: 100%;
	box-sizing: border-box;
	position: relative;
}
/* Horizontal padding presets — applied to the OUTER so the inner row
   keeps the input + dropdown overlay aligned to the same width.
   clamp() shrinks the strong presets on narrow viewports. */
.werksmans-search.wpb-search--pad-none   { padding-left: 0; padding-right: 0; }
.werksmans-search.wpb-search--pad-mild   {
	padding-left:  clamp(12px,  6vw,  120px);
	padding-right: clamp(12px,  6vw,  120px);
}
.werksmans-search.wpb-search--pad-strong {
	padding-left:  clamp(20px, 14vw, 280px);
	padding-right: clamp(20px, 14vw, 280px);
}

/* Inner wrapper holds the search row. The dropdown is anchored to
   .wpb-search-field (the input-only wrapper) so its width matches the
   input itself — not input + submit button. */
.werksmans-search .wpb-search-inner { position: static; }

.werksmans-search .wpb-search-form {
	display: flex;
	gap: 8px;
}
.werksmans-search .wpb-search-field {
	flex: 1;
	position: relative;
	min-width: 0;
}
.werksmans-search .wpb-search-input {
	width: 100%;
	box-sizing: border-box;
	padding: 10px 14px;
	border: 1px solid #a8f0e0;
	border-radius: 2px;
	font-size: 1em;
	background: #fff;
	transition: border-color 200ms ease, box-shadow 200ms ease;
}
.werksmans-search .wpb-search-input:focus {
	outline: none;
	border-color: #1ce5be;
	box-shadow: 0 0 0 2px rgba(28, 229, 190, 0.35);
}

/* ── Collapsible search: a search icon that expands to the input ───
   Collapsed, only .wpb-search-toggle shows; clicking it adds .is-open,
   which animates .wpb-search-field open. The input width follows the
   field width, so no overflow clipping of the results dropdown. */
.werksmans-search .wpb-search-toggle {
	flex: 0 0 auto;
	width: 46px;
	height: 46px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 0;
	/* Bare icon — no box: sits in the dark Avada header next to 'Contact' */
	border: none;
	border-radius: 0;
	background: transparent;
	color: #fff;
	cursor: pointer;
	transition: color 200ms ease;
}
.werksmans-search .wpb-search-toggle:hover,
.werksmans-search .wpb-search-toggle:focus-visible {
	color: #1ce5be;
	outline: none;
}
.werksmans-search .wpb-search-toggle svg {
	width: 22px;
	height: 22px;
	fill: currentColor;
	display: block;
}
.werksmans-search.wpb-search--collapsible .wpb-search-form {
	justify-content: center;
	align-items: center;
	gap: 0;
}
.werksmans-search.wpb-search--collapsible .wpb-search-field {
	max-width: 0;
	opacity: 0;
	margin-left: 0;
	transition: max-width 400ms cubic-bezier(0.4, 0, 0.2, 1),
	            opacity 260ms ease,
	            margin-left 400ms cubic-bezier(0.4, 0, 0.2, 1);
}
.werksmans-search.wpb-search--collapsible .wpb-search-input {
	min-width: 0; /* let the input shrink to 0 with the field */
}
.werksmans-search.wpb-search--collapsible.is-open .wpb-search-field {
	max-width: 720px;
	opacity: 1;
	margin-left: 10px;
}
.werksmans-search.wpb-search--collapsible.is-open .wpb-search-toggle {
	color: #1ce5be;
}
@media (prefers-reduced-motion: reduce) {
	.werksmans-search.wpb-search--collapsible .wpb-search-field {
		transition: opacity 200ms ease;
	}
}
/* Results panel — overlays whatever sits below the input (e.g. the
   carousel) instead of pushing it down. Dark, mostly-opaque background.
   Anchored to the .wpb-search-field so its width matches the input. */
.werksmans-search .wpb-search-results {
	position: absolute;
	top: calc(100% + 8px);
	left: 0;
	right: 0;
	z-index: 100;
	background: rgba(10, 10, 10, 0.85);
	border: 1px solid rgba(168, 240, 224, 0.35);
	border-radius: 2px;
	box-shadow: 0 14px 36px rgba(0, 0, 0, 0.45);
	max-height: 70vh;
	overflow-y: auto;
	color: #e6e9ee;
	-webkit-backdrop-filter: blur(10px);
	backdrop-filter: blur(10px);
}
.werksmans-search .wpb-search-results:empty { display: none; }

.werksmans-search .wpb-search-loading,
.werksmans-search .wpb-search-empty,
.werksmans-search .wpb-search-error,
.werksmans-search .wpb-search-total {
	color: #b8bec7;
	font-size: 0.9em;
	margin: 0;
	padding: 12px 16px;
}
.werksmans-search .wpb-search-error { color: #ff8a7a; }
.werksmans-search .wpb-search-total {
	border-top: 1px solid rgba(255, 255, 255, 0.08);
	background: rgba(255, 255, 255, 0.03);
}

.werksmans-search .wpb-search-list {
	list-style: none;
	margin: 0;
	padding: 0;
}
.werksmans-search .wpb-search-item {
	position: relative;
	display: flex;
	align-items: center;
	gap: 16px;
	padding: 14px 20px 14px 40px;
	border-bottom: 1px solid rgba(255, 255, 255, 0.07);
	cursor: pointer;
	transition: background 150ms ease;
}
/* Thin coral accent rule on the left of each result row. */
.werksmans-search .wpb-search-item::before {
	content: '';
	position: absolute;
	top: 50%;
	left: 20px;
	transform: translateY(-50%);
	width: 2px;
	height: 48px;
	background: #ff4400;
	border-radius: 2px;
}
.werksmans-search .wpb-search-item:last-child { border-bottom: 0; }
.werksmans-search .wpb-search-item:hover,
.werksmans-search .wpb-search-item:focus-within {
	background: rgba(28, 229, 190, 0.10);
}

.werksmans-search .wpb-search-text { flex: 1; min-width: 0; padding-left: 4px; }
.werksmans-search .wpb-search-title {
	display: block;
	font-weight: 600;
	color: #ffffff;
	text-decoration: none;
	margin-bottom: 4px;
	text-transform: uppercase;
	letter-spacing: 0.06em;
}
.werksmans-search .wpb-search-title:hover { color: #1ce5be; }
.werksmans-search .wpb-search-meta {
	font-size: 0.72em;
	color: #ff4400;
	text-transform: uppercase;
	letter-spacing: 0.12em;
	font-weight: 700;
	margin-bottom: 6px;
}
.werksmans-search .wpb-search-snippet {
	font-size: 0.9em;
	color: #cbd5e1;
	line-height: 1.4;
}
.werksmans-search .wpb-search-snippet mark {
	background: rgba(28, 229, 190, 0.22);
	color: #ecfaf5;
	padding: 1px 3px;
	border-radius: 2px;
}

/* ── Search — hidden on mobile/narrow viewports ─────────────── */
/* The search UX isn't responsive enough below tablet width yet, so the
   whole component is hidden there. (The former ≤640px refinements were
   removed with it — see git history to restore them.) */
@media (max-width: 640px) {
	.werksmans-search.wpb-search { display: none; }
}
