/* Finder components intentionally override shared controls. */
/* stylelint-disable no-descending-specificity */
.bbn-finder {
	--bbn-navy: #08152f;
	--bbn-panel: #102345;
	--bbn-panel-soft: #172a4c;
	--bbn-white: #fff;
	--bbn-ink: #0a1730;
	--bbn-muted-dark: #bdc8de;
	--bbn-muted: #61708d;
	--bbn-cyan: #67e3db;
	--bbn-teal: #1fc5ba;
	--bbn-blue: #4b67f2;
	--bbn-border-dark: rgb(190 208 239 / 22%);
	--bbn-border: #d8deea;
	--bbn-amber: #fff2d8;
	position: relative;
	box-sizing: border-box;
	max-width: 1220px;
	margin-inline: auto;
	padding: clamp(1.25rem, 4vw, 3.5rem);
	overflow: hidden;
	border: 1px solid var(--bbn-border-dark);
	border-radius: 28px;
	background:
		radial-gradient(circle at 90% 4%, rgb(38 200 192 / 18%), transparent 23rem),
		var(--bbn-navy);
	color: var(--bbn-white);
}

.bbn-finder *,
.bbn-finder *::before,
.bbn-finder *::after {
	box-sizing: border-box;
}

.bbn-finder [hidden] {
	display: none !important;
}

.bbn-finder__header {
	max-width: 760px;
}

.bbn-finder__eyebrow {
	display: inline-flex;
	align-items: center;
	gap: 0.45rem;
	margin: 0 0 1rem;
	padding: 0.42rem 0.72rem;
	border: 1px solid rgb(103 227 219 / 35%);
	border-radius: 999px;
	background: rgb(103 227 219 / 9%);
	color: var(--bbn-cyan);
	font-size: 0.75rem;
	font-weight: 800;
	letter-spacing: 0.06em;
	text-transform: uppercase;
}

.bbn-finder__eyebrow::before {
	width: 0.55rem;
	height: 0.55rem;
	border-radius: 50%;
	background: var(--bbn-teal);
	box-shadow: 0 0 0 0.25rem rgb(31 197 186 / 12%);
	content: "";
}

.bbn-finder h2,
.bbn-finder h3,
.bbn-finder h4,
.bbn-finder label,
.bbn-finder dt {
	color: inherit;
}

.bbn-finder__header h2 {
	margin: 0;
	font-size: clamp(2.1rem, 5vw, 4.5rem);
	line-height: 0.98;
	letter-spacing: -0.045em;
}

.bbn-finder__header > p:last-child {
	max-width: 690px;
	margin: 1rem 0 0;
	color: var(--bbn-muted-dark);
	font-size: clamp(1rem, 2vw, 1.2rem);
	line-height: 1.7;
}

.bbn-finder__form {
	margin-top: clamp(1.5rem, 3vw, 2.5rem);
}

.bbn-finder__search-shell {
	display: flex;
	align-items: center;
	gap: 0.65rem;
	max-width: 900px;
	padding: 0.6rem;
	border: 1px solid var(--bbn-border-dark);
	border-radius: 20px;
	background: rgb(255 255 255 / 10%);
}

.bbn-finder__search-icon {
	flex: 0 0 auto;
	margin-left: 0.55rem;
	color: var(--bbn-blue);
	font-size: 1.5rem;
	line-height: 1;
}

.bbn-finder textarea,
.bbn-finder select,
.bbn-finder input {
	width: 100%;
	min-height: 44px;
	border: 1px solid var(--bbn-border);
	border-radius: 9px;
	background: var(--bbn-white);
	color: var(--bbn-ink);
	font: inherit;
}

.bbn-finder__search-shell textarea {
	min-width: 0;
	min-height: 48px;
	max-height: 8rem;
	padding: 0.75rem 0.25rem;
	resize: vertical;
	border: 0;
	border-radius: 10px;
	box-shadow: none;
	line-height: 1.45;
}

.bbn-finder__search-shell textarea::placeholder {
	color: #7785a1;
}

.bbn-finder button,
.bbn-finder a {
	-webkit-tap-highlight-color: transparent;
}

.bbn-finder button,
.bbn-result-card__affiliate,
.bbn-result-card__details {
	display: inline-flex;
	min-height: 44px;
	align-items: center;
	justify-content: center;
	border-radius: 10px;
	padding: 0.68rem 1rem;
	font: inherit;
	font-weight: 700;
	text-align: center;
	text-decoration: none;
	cursor: pointer;
}

.bbn-finder button {
	border: 1px solid rgb(103 227 219 / 35%);
	background: transparent;
	color: var(--bbn-cyan);
}

.bbn-finder__submit,
.bbn-result-card__affiliate {
	border: 1px solid var(--bbn-blue) !important;
	background: var(--bbn-blue) !important;
	color: var(--bbn-white) !important;
}

.bbn-finder__submit {
	flex: 0 0 auto;
	min-height: 52px !important;
	padding-inline: 1.3rem !important;
}

.bbn-finder button:hover,
.bbn-finder a:hover {
	filter: brightness(1.08);
}

.bbn-finder button:focus-visible,
.bbn-finder a:focus-visible,
.bbn-finder textarea:focus-visible,
.bbn-finder select:focus-visible,
.bbn-finder input:focus-visible,
.bbn-finder summary:focus-visible {
	outline: 3px solid var(--bbn-cyan);
	outline-offset: 3px;
}

.bbn-finder button:disabled {
	cursor: wait;
	opacity: 0.65;
}

.bbn-finder__examples {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0.5rem;
	margin-top: 1rem;
	color: var(--bbn-muted-dark);
	font-size: 0.875rem;
}

.bbn-finder__examples > span {
	font-weight: 700;
}

.bbn-finder__examples button {
	min-height: 38px;
	padding: 0.45rem 0.75rem;
	border-color: var(--bbn-border-dark);
	border-radius: 999px;
	color: var(--bbn-muted-dark);
	font-size: 0.82rem;
}

.bbn-finder__help,
.bbn-finder__disclosure,
.bbn-finder__status,
.bbn-result-card__disclosure {
	color: var(--bbn-muted-dark);
	font-size: 0.875rem;
}

.bbn-finder__disclosure {
	max-width: 860px;
	margin: 1rem 0 0;
}

.bbn-finder__status {
	min-height: 1.5em;
	margin-top: 1rem;
}

.bbn-finder.is-loading .bbn-finder__status::before {
	display: inline-block;
	width: 0.8rem;
	height: 0.8rem;
	margin-right: 0.5rem;
	border: 2px solid rgb(103 227 219 / 28%);
	border-top-color: var(--bbn-cyan);
	border-radius: 50%;
	animation: bbn-spin 0.8s linear infinite;
	content: "";
}

@keyframes bbn-spin {

	to {
		transform: rotate(360deg);
	}
}

.bbn-finder__refine,
.bbn-finder__intent,
.bbn-finder__empty,
.bbn-finder__error {
	margin-top: 1.25rem;
	padding: 1rem;
	border: 1px solid var(--bbn-border-dark);
	border-radius: 16px;
	background: rgb(255 255 255 / 6%);
}

.bbn-finder__refine summary {
	min-height: 44px;
	cursor: pointer;
	color: var(--bbn-white);
	font-weight: 800;
	line-height: 44px;
}

.bbn-finder__filters {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 1rem;
	margin-top: 1rem;
}

.bbn-finder__filter label {
	display: block;
	margin-bottom: 0.35rem;
	font-weight: 700;
}

.bbn-finder__filter input,
.bbn-finder__filter select {
	padding: 0.65rem;
}

.bbn-finder__refine-apply {
	margin-top: 1rem;
	border-color: var(--bbn-blue) !important;
	background: var(--bbn-blue) !important;
	color: var(--bbn-white) !important;
}

.bbn-finder__result-heading {
	margin: 2.25rem 0 0.35rem;
	font-size: clamp(1.55rem, 3vw, 2.25rem);
}

.bbn-finder__count {
	margin: 0;
	color: var(--bbn-muted-dark);
}

.bbn-finder__intent-heading {
	margin: 0 0 0.75rem;
	font-size: 1rem;
}

.bbn-finder__category-pill,
.bbn-finder__requirement-pill {
	display: inline-flex;
	align-items: center;
	min-height: 32px;
	margin: 0.2rem 0.25rem 0.2rem 0;
	padding: 0.34rem 0.62rem;
	border: 1px solid rgb(103 227 219 / 30%);
	border-radius: 999px;
	background: rgb(103 227 219 / 9%);
	color: var(--bbn-cyan);
	font-size: 0.82rem;
	font-weight: 700;
}

.bbn-finder__category-alternatives {
	margin: 0.75rem 0 0;
	color: var(--bbn-muted-dark);
}

.bbn-finder__category-suggestions {
	display: flex;
	flex-wrap: wrap;
	gap: 0.6rem;
	margin-top: 1rem;
}

.bbn-finder__cards {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 1rem;
	margin-top: 1.25rem;
}

.bbn-result-card {
	display: flex;
	min-width: 0;
	flex-direction: column;
	overflow: hidden;
	border: 1px solid rgb(255 255 255 / 65%);
	border-radius: 22px;
	background: var(--bbn-white);
	box-shadow: 0 18px 50px rgb(0 0 0 / 18%);
	color: var(--bbn-ink);
}

.bbn-result-card__top {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1rem;
	padding: 1rem 1.1rem 0;
}

.bbn-result-card__label {
	display: inline-flex;
	align-items: center;
	min-height: 32px;
	padding: 0.35rem 0.7rem;
	border-radius: 999px;
	background: #dff8f5;
	color: #087c73;
	font-size: 0.75rem;
	font-weight: 850;
	letter-spacing: 0.02em;
	text-transform: uppercase;
}

.bbn-result-card__match {
	display: grid;
	flex: 0 0 72px;
	width: 72px;
	height: 72px;
	place-content: center;
	border-radius: 50%;
	background:
		radial-gradient(circle, var(--bbn-white) 56%, transparent 58%),
		conic-gradient(var(--bbn-blue) calc(var(--bbn-match, 0) * 1%), #e7ebf3 0);
	text-align: center;
}

.bbn-result-card__match strong {
	display: block;
	font-size: 1.05rem;
	line-height: 1;
}

.bbn-result-card__match span {
	color: var(--bbn-muted);
	font-size: 0.58rem;
	font-weight: 800;
	letter-spacing: 0.06em;
	text-transform: uppercase;
}

.bbn-result-card__match--requirements {
	flex-basis: 110px;
	width: 110px;
	border: 1px solid #cfd7ef;
	border-radius: 14px;
	background: #f5f7ff;
}

.bbn-result-card__match--requirements strong {
	font-size: 1rem;
}

.bbn-result-card__match--requirements span {
	max-width: none;
	margin-top: 0.25rem;
	font-size: 0.52rem;
	letter-spacing: 0.04em;
	line-height: 1.2;
	white-space: nowrap;
}

.bbn-result-card__body {
	display: grid;
	grid-template-columns: minmax(140px, 185px) minmax(0, 1fr);
	gap: 1rem;
	padding: 0.7rem 1.1rem 0.85rem;
}

.bbn-result-card__media {
	display: flex;
	min-height: 170px;
	align-items: center;
	justify-content: center;
	overflow: hidden;
	border: 1px solid #e2e6ef;
	border-radius: 14px;
	background: #fff;
}

.bbn-result-card__image {
	display: block;
	width: 100%;
	height: 100%;
	max-height: 200px;
	padding: 0.35rem;
	object-fit: contain;
}

.bbn-result-card__media:not(:has(img))::before {
	display: grid;
	width: 72px;
	height: 72px;
	place-content: center;
	border-radius: 18px;
	background: #e7ebf3;
	color: #71809b;
	font-size: 2rem;
	content: "◇";
}

.bbn-result-card__content h3 {
	margin: 0;
	color: var(--bbn-ink);
	font-size: clamp(1.08rem, 1.7vw, 1.4rem);
	line-height: 1.25;
	overflow-wrap: anywhere;
}

.bbn-result-card__metadata,
.bbn-result-card__explanation {
	color: var(--bbn-muted);
}

.bbn-result-card__metadata {
	margin: 0.3rem 0 0;
	font-size: 0.86rem;
}

.bbn-result-card__explanation {
	margin: 0.65rem 0;
	line-height: 1.6;
}

.bbn-result-card__matches {
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	gap: 0.38rem;
	margin: 0.55rem 0 0;
	padding: 0;
	list-style: none;
}

.bbn-result-card__matches li {
	position: relative;
	padding-left: 1.35rem;
	font-size: 0.9rem;
	font-weight: 650;
}

.bbn-result-card__matches li::before {
	position: absolute;
	left: 0;
	color: #099b83;
	font-weight: 900;
	content: "✓";
}

.bbn-result-card__tradeoff,
.bbn-result-card__warning {
	margin: 0.65rem 0;
	padding: 0.75rem 0.9rem;
	border-radius: 10px;
	font-size: 0.88rem;
}

.bbn-result-card__tradeoff {
	display: grid;
	gap: 0.18rem;
	border: 1px solid #efd39c;
	background: var(--bbn-amber);
	color: #6d4b0c;
}

.bbn-result-card__warning {
	border: 1px solid #e9c4bc;
	background: #fff5f2;
	color: #843d30;
}

.bbn-result-card__evidence {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1rem;
	margin-top: 0.65rem;
	padding: 0.7rem 0;
	border-top: 1px solid #e7ebf2;
	border-bottom: 1px solid #e7ebf2;
	color: #415170;
	font-size: 0.82rem;
	font-weight: 750;
}

.bbn-result-card__evidence p {
	display: flex;
	gap: 0.45rem;
	margin: 0;
}

.bbn-result-card__segments {
	display: flex;
	gap: 0.3rem;
}

.bbn-result-card__segments span,
.bbn-result-card__segments i {
	display: block;
	width: 24px;
	height: 5px;
	border-radius: 99px;
	background: #e3e8f0;
}

.bbn-result-card__segments span[data-active="true"],
.bbn-result-card__segments i[data-active="true"] {
	background: var(--bbn-teal);
}

.bbn-result-card__score-details {
	margin: 0 1.1rem 1rem;
	border-top: 1px solid #e7ebf2;
}

.bbn-result-card__score-details summary {
	min-height: 44px;
	cursor: pointer;
	color: #344360;
	font-weight: 700;
	line-height: 44px;
}

.bbn-result-card__scores {
	display: grid;
	gap: 0.35rem;
	margin: 0;
}

.bbn-result-card__scores div {
	display: flex;
	justify-content: space-between;
	gap: 1rem;
	padding-block: 0.25rem;
	border-bottom: 1px solid #e7ebf2;
}

.bbn-result-card__scores dd {
	margin: 0;
	font-weight: 750;
}

.bbn-result-card__actions {
	display: flex;
	flex-wrap: wrap;
	gap: 0.65rem;
	margin: 0.8rem 1.1rem;
}

.bbn-result-card > .bbn-result-card__tradeoff,
.bbn-result-card > .bbn-result-card__warning,
.bbn-result-card > .bbn-result-card__evidence {
	margin-inline: 1.1rem;
}

.bbn-result-card__details {
	border: 1px solid var(--bbn-blue);
	color: var(--bbn-blue);
}

.bbn-result-card__actions button {
	border-color: #cfd6e4;
	color: #344360;
}

.bbn-result-card__disclosure {
	width: 100%;
	margin: 0;
	color: var(--bbn-muted);
}

.bbn-finder__empty,
.bbn-finder__error {
	color: var(--bbn-white);
}

.bbn-finder__error {
	border-color: rgb(255 154 136 / 55%);
	background: rgb(129 37 31 / 25%);
}

.bbn-finder__edit {
	margin-top: 1rem;
}

.bbn-finder__noscript {
	margin-top: 1rem;
	color: var(--bbn-muted-dark);
}

.bbn-finder__editor-input {
	min-height: 52px;
	margin-block: 0.5rem;
	padding: 0.75rem;
	border: 1px solid #949494;
	color: #666;
}

@media (max-width: 1080px) {

	.bbn-finder__cards {
		grid-template-columns: minmax(0, 1fr);
	}
}

@media (max-width: 720px) {

	.bbn-finder {
		padding: 1.25rem;
		border-radius: 20px;
	}

	.bbn-finder__search-shell {
		align-items: stretch;
		flex-wrap: wrap;
		background: var(--bbn-white);
	}

	.bbn-finder__search-icon {
		align-self: center;
	}

	.bbn-finder__search-shell textarea {
		width: calc(100% - 3rem);
	}

	.bbn-finder__submit {
		width: 100%;
	}

	.bbn-finder__filters,
	.bbn-result-card__body,
	.bbn-result-card__matches {
		grid-template-columns: minmax(0, 1fr);
	}

	.bbn-result-card__body {
		padding-top: 1rem;
	}

	.bbn-result-card__media {
		min-height: 150px;
	}

	.bbn-result-card__top,
	.bbn-result-card__evidence {
		align-items: flex-start;
	}

	.bbn-result-card__top {
		gap: 0.65rem;
	}

	.bbn-result-card__match {
		flex-basis: auto;
		width: auto;
		height: auto;
		min-height: 44px;
		padding: 0.45rem 0.7rem;
		border: 1px solid #cfd7ef;
		border-radius: 999px;
		background: #f5f7ff;
	}

	.bbn-result-card__match strong,
	.bbn-result-card__match span {
		display: inline;
	}

	.bbn-result-card__match span {
		margin-left: 0.3rem;
	}

	.bbn-result-card__evidence {
		flex-direction: column;
	}

	.bbn-result-card__score-details {
		width: 100%;
		margin-inline: 0;
		padding-inline: 1.1rem;
	}

	.bbn-result-card__actions > * {
		width: 100%;
	}
}

@media (prefers-reduced-motion: reduce) {

	.bbn-finder *,
	.bbn-finder *::before,
	.bbn-finder *::after {
		scroll-behavior: auto !important;
		transition-duration: 0.01ms !important;
		animation-duration: 0.01ms !important;
		animation-iteration-count: 1 !important;
	}
}
