/* mod_cf_search - live product preview dropdown */

.cf-searchmod-wrapper {
	position: relative;
}

.cf-live-preview {
	position: absolute;
	top: 100%;
	left: 0;
	right: 0;
	z-index: 1050; /* above Bootstrap 2's default 1000 */
	margin-top: 2px;
	background: #fff;
	border: 1px solid #ccc;
	border-radius: 3px;
	box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
	max-height: 60vh;
	overflow-y: auto;
}

.cf-live-preview[hidden] {
	display: none;
}

.cf-live-preview .cf-preview-item {
	display: flex;
	align-items: center;
	padding: 8px 10px;
	min-height: 44px;
	cursor: pointer;
	border-bottom: 1px solid #eee;
}

.cf-live-preview .cf-preview-item:last-child {
	border-bottom: none;
}

.cf-live-preview .cf-preview-item:hover,
.cf-live-preview .cf-preview-item.active {
	background: #f5f5f5;
}

.cf-live-preview .cf-preview-thumb-wrap {
	flex: 0 0 auto;
	width: 40px;
	height: 40px;
	margin-right: 10px;
	display: flex;
	align-items: center;
	justify-content: center;
}

.cf-live-preview .cf-preview-thumb-wrap img {
	max-width: 40px;
	max-height: 40px;
	object-fit: contain;
}

.cf-live-preview .cf-preview-name {
	flex: 1 1 auto;
	font-size: 13px;
	line-height: 1.3;
	padding-right: 8px;
}

.cf-live-preview .cf-preview-price {
	flex: 0 0 auto;
	font-size: 13px;
	font-weight: bold;
	white-space: nowrap;
}

.cf-live-preview .cf-preview-empty {
	padding: 10px;
	font-size: 13px;
	color: #777;
}

@media (max-width: 767px) {
	.cf-live-preview {
		max-height: 70vh;
	}

	.cf-live-preview .cf-preview-item {
		padding: 10px 10px;
	}
}
