/* =============================================================
   Landing-page proposal forms (assets/js/nx-proposal-form.js):
   custom dropdowns like the proposal request page, and the
   homepage-style business name suggestions.
   ============================================================= */

/* ---------- Custom dropdown ---------- */
.nxp-dd {
	position: relative;
}

.nxp-dd select.nxp-dd-native {
	position: absolute !important;
	left: 0;
	bottom: 0;
	width: 100% !important;
	height: 1px !important;
	opacity: 0 !important;
	pointer-events: none;
	padding: 0 !important;
	border: 0 !important;
	margin: 0 !important;
}

.nxp-dd-btn {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 10px;
	width: 100%;
	min-height: 44px;
	padding: 10px 14px;
	margin: 0;
	font: inherit;
	font-size: 14px;
	line-height: 1.4;
	text-align: left;
	color: #1d2b45;
	background: #fff;
	border: 1.5px solid #dde3ec;
	border-radius: 8px;
	cursor: pointer;
	box-shadow: none;
	text-transform: none;
	letter-spacing: normal;
	transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.nxp-dd-btn:hover {
	border-color: #b9c4d6;
}

.nxp-dd-btn:focus,
.nxp-dd.open .nxp-dd-btn {
	outline: none;
	border-color: #357de6;
	box-shadow: 0 0 0 3px rgba(53, 125, 230, 0.14);
}

.nxp-dd-val {
	flex: 1;
	min-width: 0;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.nxp-dd-chev {
	flex: 0 0 16px;
	width: 16px;
	height: 16px;
	color: #6b7a90;
	transition: transform 0.2s ease, color 0.2s ease;
}

.nxp-dd.open .nxp-dd-chev {
	transform: rotate(180deg);
	color: #357de6;
}

.nxp-dd-list {
	position: absolute;
	z-index: 60;
	left: 0;
	right: 0;
	top: calc(100% + 6px);
	margin: 0;
	padding: 6px;
	list-style: none;
	background: #fff;
	border: 1px solid #e3e9f3;
	border-radius: 12px;
	box-shadow: 0 14px 34px rgba(15, 29, 51, 0.16);
	max-height: 300px;
	overflow-y: auto;
	display: none;
	text-align: left;
}

.nxp-dd.open .nxp-dd-list {
	display: block;
	animation: nxpDd 0.15s ease-out;
}

.nxp-dd.up .nxp-dd-list {
	top: auto;
	bottom: calc(100% + 6px);
}

@keyframes nxpDd {
	from { opacity: 0; transform: translateY(-4px); }
	to { opacity: 1; transform: none; }
}

.nxp-dd-opt {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 10px;
	margin: 0;
	padding: 10px 12px;
	border-radius: 8px;
	font-size: 14px;
	line-height: 1.35;
	color: #1d2b45;
	cursor: pointer;
}

.nxp-dd-opt.active {
	background: rgba(53, 125, 230, 0.08);
}

.nxp-dd-opt[aria-selected=true] {
	color: #1f6fd1;
	font-weight: 600;
}

.nxp-dd-opt[aria-selected=true]::after {
	content: "\2713";
	color: #1f6fd1;
	font-weight: 700;
}

/* ---------- Business name suggestions ---------- */
.nxp-sg-wrap {
	position: relative;
	z-index: 5;
}

.nxp-sg {
	position: absolute;
	left: 0;
	right: 0;
	top: calc(100% + 6px);
	z-index: 70;
	background: #fff;
	border: 1px solid #e3e9f3;
	border-radius: 14px;
	box-shadow: 0 18px 40px rgba(15, 29, 51, 0.16);
	padding: 6px;
	max-height: 320px;
	overflow-y: auto;
	text-align: left;
}

.nxp-sg:empty {
	display: none;
}

.nxp-sg-item {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 10px 12px;
	border-radius: 10px;
	cursor: pointer;
	transition: background 0.15s ease;
}

.nxp-sg-item + .nxp-sg-item {
	margin-top: 2px;
}

.nxp-sg-item:hover,
.nxp-sg-item.active {
	background: #f4f7fc;
}

.nxp-sg-pin {
	flex: 0 0 auto;
	width: 34px;
	height: 34px;
	border-radius: 50%;
	background: #eef4ff;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: background 0.15s ease;
}

.nxp-sg-pin svg {
	width: 16px;
	height: 16px;
	fill: #357de6;
	transition: fill 0.15s ease;
}

.nxp-sg-item:hover .nxp-sg-pin,
.nxp-sg-item.active .nxp-sg-pin {
	background: #357de6;
}

.nxp-sg-item:hover .nxp-sg-pin svg,
.nxp-sg-item.active .nxp-sg-pin svg {
	fill: #fff;
}

.nxp-sg-text {
	display: flex;
	flex-direction: column;
	min-width: 0;
}

.nxp-sg-name {
	font-size: 14.5px;
	font-weight: 600;
	line-height: 1.35;
	color: #1d2b45;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.nxp-sg-addr {
	font-size: 12.5px;
	line-height: 1.4;
	color: #6b7a90;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

/* never wider than its column; long choices end with an ellipsis */
.nxp-dd {
	min-width: 0;
	max-width: 100%;
}
