:root {
	--border-radius: 1rem;
}

.product-vehicle-list {
	position: relative;
}

.product-vehicle-list__content details summary::marker {
	content: "";
}
.product-vehicle-list__content details summary::-webkit-details-marker {
	display: none;
}

.product-vehicle-list__contents {
	max-height: 460px;
	height: 460px;
	overflow-y: auto;
}

.product-vehicle-list__scroll-indicator {
	position: absolute;
	bottom: 0;
	left: 0;
	right: 0;
	display: flex;
	justify-content: center;
	padding: 8px 0;
	background: linear-gradient(to bottom, transparent, var(--vehiclelist-bg, #fff) 50%);
	pointer-events: none;
	opacity: 0;
	transition: opacity 0.2s ease;
}

.product-vehicle-list.is-initialized .product-vehicle-list__scroll-indicator {
	opacity: 1;
}

.product-vehicle-list.is-initialized .product-vehicle-list__scroll-indicator.is-hidden {
	opacity: 0;
}

.product-vehicle-list__scroll-indicator svg {
	animation: product-vehicle-list-bounce 1.5s ease-in-out infinite;
}

@keyframes product-vehicle-list-bounce {
	0%, 100% {
		transform: translateY(0);
	}
	50% {
		transform: translateY(4px);
	}
}

.product-vehicle-list__popup-trigger {
	padding: 0;
	border: unset;
	outline: unset;
	background: unset;
	color: inherit;
}

.product-vehicle-list__popup:not(.product-vehicle-list__popup--open) .product-vehicle-list__popup-content {
	right: -100vw;
}

.product-vehicle-list__popup-content {
	--width: 560px;
	transition: right 0.2s ease, bottom 0.2s ease;
	position: fixed;
	right: 0;
	top: 0;
	height: 100vh;
	height: 100dvh;
	width: 100%;
	max-width: var(--width);
	background: #000;
	color: #fff;
	z-index: calc(var(--header-z-index) + 10);
	border-left: 1px solid #3C3B3C;
}

.product-vehicle-list__popup-overlay {
	position: fixed;
	z-index: calc(var(--header-z-index) + 9);
	background: #494949;
	opacity: 0;
	transition: opacity 0.2s ease;
	inset: 0;
	pointer-events: none;
}

.product-vehicle-list__popup-overlay.product-vehicle-list__popup-overlay--open {
	opacity: var(--overlay-opacity, 0.5);
	pointer-events: auto;
}

.product-vehicle-list__popup-content *:not(.product-vehicle-list__popup-close) {
	z-index: calc(var(--header-z-index) + 10);
	position: relative;
}

.product-vehicle-list__popup-content__inner {
	height: 100%;
	display: flex;
	flex-direction: column;
	justify-content: start;
	padding: 4rem 1.5rem 2rem 1.5rem;
}

.product-vehicle-list__popup-close {
	position: absolute;
	top: 1rem;
	right: 1rem;
	background: unset;
	border: unset;
	font-size: 1.5rem;
	color: inherit;
	cursor: pointer;
	z-index: calc(var(--header-z-index) + 12);
}

.product-vehicle-list__popup-notes {
	list-style: none;
	padding-left: 0;
	overflow-y: scroll;
}

.product-vehicle-list__popup-notes li + li {
	margin-top: 0.5rem;
	padding-top: 0.5rem;
	border-top: 1px solid #3C3B3C;
}

.product-vehicle-list__popup-drag-area {
	display: none;
}

.product-vehicle-list__popup-title {
	font-weight: bold;
	font-size: 1.25rem;
	margin-bottom: 0;
}

.product-vehicle-list__popup-description {
	font-size: 1rem;
	opacity: 0.8;
	margin-bottom: 1rem;
}

.product-vehicle-list__popup-trigger:focus-visible,
.product-vehicle-list__popup-close:focus-visible {
	outline: 2px solid var(--wp--preset--color--primary);
	outline-offset: 2px;
}

@media screen and (max-width: 640px) {
	.product-vehicle-list__popup-close {
		display: none;
	}
	.product-vehicle-list__popup-content {
		--width: 100%;
		--height: max(500px, 40vh);
		height: var(--height);
		top: unset;
		bottom: calc(var(--height) * -1);
		right: 0 !important;
		left: 0 !important;
		padding-top: 0;
	}

	.product-vehicle-list__popup-content__inner {
		height: calc(100% + 48px); /* match max upward pull from dragging functionality */
		padding-top: 0;
	}

	.product-vehicle-list__popup-content__inner::after {
		content: "";
		display: block;
		position: absolute;
		bottom: 0;
		left: 0;
		right: 0;
		background-color: black;
		height: 48px; /* match max upward pull from dragging functionality */
	}

	.product-vehicle-list__popup--open .product-vehicle-list__popup-content {
		bottom: 0;
	}
	.product-vehicle-list__popup--open .product-vehicle-list__popup-drag-area {
		display: block;
		position: absolute;
		top: 1px;
		transform: translateY(-100%);
		left: -1px;
		right: -1px;
		width: calc(100% + 2px);
		height: 4.5rem;
		cursor: ns-resize;
		background-color: inherit;
		border-top-left-radius: 2rem;
		border-top-right-radius: 2rem;
		padding-block: 0.5rem;
		touch-action: none;
		user-select: none;
		-webkit-user-select: none;
	}

	.product-vehicle-list__popup-drag-handle {
		width: 2.5rem;
		height: 0.3rem;
		margin: 0.5rem auto 0;
		border-radius: 999px;
		background-color: rgba(255, 255, 255, 0.35);
	}

	.product-vehicle-list__popup-content__inner {
		justify-content: flex-start;
	}

	:not(#fakeid).product-vehicle-list__popup-notes li:last-child {
		padding-bottom: 3rem;
	}
}


.product-vehicle-list__tabs:not([hidden]) {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0.25rem;
}

.product-vehicle-list__tabs [data-tab-target] {
	--_border-color: rgba(255, 255, 255, 0.3);
	text-decoration: none;
	font-weight: inherit;
	line-height: 1;
	padding: 0.75rem 0.9rem 0.55rem 0.9rem;
	background: transparent;
	border: 1px solid var(--_border-color);
}

.product-vehicle-list__tabs [data-tab-target][data-selected] {
	--_border-color: var(--wp--preset--color--primary);
	color: var(--wp--preset--color--primary);
}
