/* Directory Listings — Cards (front-page style) */

.ht-directory-listings--cards .ht-trailer-directory__list.ht-directory-cards {
	display: grid;
	grid-template-columns: repeat(var(--ht-dcard-columns, 3), minmax(0, 1fr));
	gap: 28px 24px;
	list-style: none;
	margin: 0;
	padding: 0;
}

@media (max-width: 1024px) {
	.ht-directory-listings--cards .ht-trailer-directory__list.ht-directory-cards {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

@media (max-width: 640px) {
	.ht-directory-listings--cards .ht-trailer-directory__list.ht-directory-cards {
		grid-template-columns: minmax(0, 1fr);
	}
}

/* Override the compact directory item chrome inside cards. */
.ht-directory-listings--cards .ht-trailer-directory__item.ht-dcard {
	display: block;
	border: 0;
	border-radius: 0;
	padding: 0;
	background: transparent;
}

.ht-dcard__inner {
	display: flex;
	flex-direction: column;
	gap: 10px;
}

.ht-dcard__media {
	position: relative;
}

.ht-dcard__media .ht-wishlist-heart {
	position: absolute;
	top: 10px;
	right: 10px;
	z-index: 5;
}

/* Gallery */

.ht-dcard__gallery {
	position: relative;
	border-radius: 14px;
	overflow: hidden;
	background: #f0f0f1;
	aspect-ratio: 4 / 3;
}

.ht-dcard__track {
	position: relative;
	width: 100%;
	height: 100%;
}

.ht-dcard__slide {
	position: absolute;
	inset: 0;
	display: block;
	opacity: 0;
	pointer-events: none;
	transition: opacity 0.25s ease;
}

.ht-dcard__slide.is-active {
	opacity: 1;
	pointer-events: auto;
}

.ht-dcard__slide img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.ht-dcard__nav {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	z-index: 4;
	width: 32px;
	height: 32px;
	border: 0;
	border-radius: 999px;
	background: rgba(255, 255, 255, 0.92);
	color: #1d2327; /* on photo overlay pill — keep high-contrast */
	font-size: 20px;
	line-height: 1;
	cursor: pointer;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.18);
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 0 0 2px;
}

.ht-dcard__nav--prev { left: 10px; }
.ht-dcard__nav--next { right: 10px; }

.ht-dcard__nav:hover {
	background: #fff;
	transform: translateY(-50%) scale(1.06);
}

.ht-dcard__dots {
	position: absolute;
	left: 0;
	right: 0;
	bottom: 10px;
	z-index: 4;
	display: flex;
	justify-content: center;
	gap: 5px;
	pointer-events: none;
}

.ht-dcard__dot {
	width: 6px;
	height: 6px;
	border-radius: 999px;
	background: rgba(255, 255, 255, 0.55);
	transition: background 0.15s ease, transform 0.15s ease;
}

.ht-dcard__dot.is-active {
	background: #fff;
	transform: scale(1.25);
}

/* Body */

.ht-dcard__body {
	display: flex;
	flex-direction: column;
	gap: 2px;
	padding: 0 2px;
}

.ht-dcard__title {
	margin: 0;
	font-size: 16px;
	font-weight: 600;
	line-height: 1.3;
}

.ht-dcard__title a {
	color: var(--htr-text, var(--wp--preset--color--text, #1d2327));
	text-decoration: none;
}

.ht-dcard__title a:hover {
	text-decoration: underline;
}

.ht-dcard__price {
	margin: 2px 0 0;
	font-size: 15px;
	font-weight: 600;
	color: var(--htr-text, var(--wp--preset--color--text, #1d2327));
}

.ht-dcard__meta {
	margin: 0;
	font-size: 14px;
	color: var(--htr-muted, var(--wp--preset--color--muted, #646970));
}

.ht-dcard__excerpt {
	margin: 4px 0 0;
	font-size: 13.5px;
	line-height: 1.45;
	color: var(--htr-muted, var(--wp--preset--color--muted, #646970));
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}
