/*
 * Jazzport — front page only (video carousel, hero article, latest list header).
 * Enqueued only on is_front_page().
 */

.homepage-layout {
	display: grid;
	grid-template-columns: minmax(0, 1fr) 340px;
	gap: 48px;
	align-items: start;
}

.homepage-main {
	min-width: 0;
}

.homepage-banner {
	width: 100%;
	padding: 30px 0;
	border-bottom: 1px solid var(--jazzport-border);
}

.video-carousel {
	padding-bottom: 20px;
	margin-bottom: 20px;
	border-bottom: 1px solid var(--jazzport-border);
}

.video-carousel-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	margin-bottom: 12px;
}

.video-carousel-header h2 {
	display: flex;
	align-items: center;
	gap: 8px;
	font-size: 1.25rem;
	font-weight: 600;
	margin: 0;
}

.video-carousel-channel {
	font-size: 0.78rem;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.06em;
	color: var(--jazzport-accent);
}

.video-carousel-track {
	display: flex;
	gap: 15px;
	overflow-x: auto;
	padding-bottom: 6px;
}

.video-carousel-item {
	flex: 0 0 179px;
	color: var(--jazzport-ink);
}

.video-carousel-item img {
	border-radius: 6px;
	aspect-ratio: 16 / 9;
	object-fit: cover;
}

.video-carousel-title {
	display: -webkit-box;
	-webkit-box-orient: vertical;
	-webkit-line-clamp: 2;
	overflow: hidden;
	text-overflow: ellipsis;
	margin-top: 6px;
	font-size: 0.8125rem;
	font-weight: 600;
	line-height: 1.3;
	max-height: calc(1.3em * 2);
	color: var(--jazzport-ink);
}

.video-carousel-meta {
	display: block;
	margin-top: 4px;
	font-size: 0.75rem;
	color: #8a8a90;
}

.homepage-hero {
	display: grid;
	grid-template-columns: 1.1fr 1fr;
	gap: 30px;
	align-items: center;
	margin-bottom: 24px;
}

.homepage-hero-thumb {
	position: relative;
	display: block;
	border-radius: 8px;
	overflow: hidden;
	background-color: #f2f2f2;
	border: 1px solid rgba(0, 0, 0, 0.1);
	aspect-ratio: 16 / 9;
}

.homepage-hero-thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.homepage-hero-thumb .category-badge {
	position: absolute;
	bottom: 12px;
	left: 12px;
	margin-bottom: 0;
}

.hero-thumb-overlays {
	position: absolute;
	top: 10px;
	left: 10px;
	z-index: 2;
	display: grid;
	grid-template-columns: max-content;
	gap: 8px;
}

.hero-thumb-overlays .thumb-overlay-score {
	position: static;
}

.hero-thumb-overlays .thumb-overlay-event {
	position: static;
	max-width: none;
	overflow: visible;
	border: 1px solid rgba(0, 0, 0, 0.08); /* inset 10px, not in the corner */
}

.hero-thumb-overlays .thumb-overlay-star svg {
	width: 16px;
	height: 16px;
}

.thumb-overlay-album {
	display: block;
	width: 0;
	min-width: 100%;
	box-sizing: border-box;
	overflow: hidden;
	border: 1px solid rgba(255, 255, 255, 0.7);
	box-shadow: 0 2px 10px rgba(0, 0, 0, 0.25);
}

.thumb-overlay-album img {
	display: block;
	width: 100%;
	height: auto;
	object-fit: cover;
}

.homepage-hero-title {
	font-size: 2.5rem;
	font-weight: 600;
	margin: 0 0 12px;
	line-height: 1.2;
}

.homepage-hero-title a {
	color: var(--jazzport-ink);
}

.homepage-hero-excerpt {
	display: -webkit-box;
	-webkit-box-orient: vertical;
	-webkit-line-clamp: 3;
	overflow: hidden;
	color: var(--jazzport-muted);
	margin: 0 0 12px;
	font-size: 1rem;
	line-height: 1.5;
	max-height: calc(1.5em * 3);
}

.homepage-latest-header {
	position: relative;
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	margin-bottom: 15px;
	padding-bottom: 10px;
}

.homepage-latest-header::after {
	content: "";
	position: absolute;
	bottom: 0;
	left: 0;
	right: 0;
	height: 4px;
	background-image: linear-gradient(to right, rgba(0, 0, 0, 0), rgba(0, 0, 0, 1) 20%, rgba(0, 0, 0, 1) 80%, rgba(0, 0, 0, 0));
	pointer-events: none;
}

.homepage-latest-header h2 {
	margin: 0;
	font-size: 1.25rem;
	font-weight: 600;
}

.homepage-latest-header a {
	font-size: 0.78rem;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.06em;
	color: var(--jazzport-accent);
}

@media (max-width: 900px) {
	.homepage-hero {
		grid-template-columns: 1fr;
	}
}

@media (max-width: 768px) {
	.homepage-banner {
		display: none;
	}

	.homepage-layout {
		grid-template-columns: 1fr;
	}

	/* Lightly highlight the top homepage article on mobile. */
	.homepage-hero {
		background-color: var(--jazzport-soft-bg);
		margin-left: -16px;
		margin-right: -16px;
		padding: 16px;
		border-radius: 8px;
	}

	.homepage-hero-title {
		font-size: 1.7rem;
	}

	.hero-thumb-overlays {
		display: none;
	}

	.homepage-hero-excerpt {
		-webkit-line-clamp: 2;
		max-height: calc(1.5em * 2);
	}

	.video-carousel-item {
		flex-basis: 150px;
	}
}

@media (max-width: 480px) {
	.homepage-hero-title {
		font-size: 1.4rem;
	}
}
