/* ================= TRENDING NOW SECTION ================= */
/* Based on BoomKit Trending Now design */

/* -- Custom Properties -- */
:root {
	--kf-accent: #8b5cf6;
	--kf-accent-2: #a78bfa;
	--kf-accent-glow: rgba(139, 92, 246, 0.14);
	--kf-font-head: 'Space Grotesk', 'Roboto Condensed', sans-serif;
	--kf-font-body: 'Inter', 'Arimo', sans-serif;
	--kf-r-sm: 6px;
	--kf-r-md: 10px;
	--kf-r-lg: 16px;
	--kf-r-full: 999px;
}

/* -- Section Wrapper -- */
.kf-trending-section {
	padding: 0 0 0.5rem;
}

/* -- Container -- */
.kf-trending-section .kf-container {
	max-width: 980px;
	margin: 0 auto;
	padding: 0 1rem;
}

/* -- Section Header -- */
.kf-section-header {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-bottom: 1.25rem;
}

.kf-section-title {
	display: flex;
	align-items: center;
	gap: 0.5rem;
	margin: 0;
	font-weight: 700;
	font-size: 1.1rem;
	letter-spacing: -0.02em;
	color: #0f172a;
	font-family: var(--kf-font-head);
}

.kf-title-icon {
	display: inline-flex;
	color: var(--kf-accent);
}

.kf-title-icon svg {
	width: 20px;
	height: 20px;
}

/* -- Trending Row (horizontal scroll) -- */
.kf-trending-row {
	display: flex;
	gap: 1rem;
	overflow-x: auto;
	padding-bottom: 0.5rem;
	scroll-snap-type: x mandatory;
	-webkit-overflow-scrolling: touch;
	scrollbar-width: thin;
}

.kf-trending-row::-webkit-scrollbar {
	height: 4px;
}

.kf-trending-row::-webkit-scrollbar-track {
	background: #f1f5f9;
	border-radius: 10px;
}

.kf-trending-row::-webkit-scrollbar-thumb {
	background: var(--kf-accent);
	border-radius: 10px;
}

/* -- Individual Trending Card -- */
.kf-trending-card {
	flex: 0 0 180px;
	max-width: 200px;
	background: #ffffff;
	border-radius: var(--kf-r-md);
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
	padding: 0.75rem 0.75rem 0.5rem;
	text-decoration: none;
	color: inherit;
	display: flex;
	flex-direction: column;
	align-items: center;
	text-align: center;
	transition: transform 0.2s ease, box-shadow 0.2s ease;
	scroll-snap-align: start;
	position: relative;
	border: 1px solid rgba(0, 0, 0, 0.04);
}

.kf-trending-card:hover {
	transform: translateY(-3px);
	box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
}

/* -- Rank Badge -- */
.kf-trending-card__rank {
	position: absolute;
	top: -6px;
	left: -6px;
	background: var(--kf-accent);
	color: #fff;
	font-weight: 700;
	font-size: 0.7rem;
	width: 24px;
	height: 24px;
	display: flex;
	align-items: center;
	justify-content: center;
	border-radius: 50%;
	box-shadow: 0 2px 6px rgba(139, 92, 246, 0.3);
	font-family: var(--kf-font-head);
}

/* -- Rank Colors: 1 = dark yellow, 2 = grey, 3 = yellow, rest purple -- */
.kf-trending-card:nth-child(1) .kf-trending-card__rank {
	background: #b8860b;
	box-shadow: 0 2px 6px rgba(184, 134, 11, 0.35);
}

.kf-trending-card:nth-child(2) .kf-trending-card__rank {
	background: #808080;
	box-shadow: 0 2px 6px rgba(128, 128, 128, 0.35);
}

.kf-trending-card:nth-child(3) .kf-trending-card__rank {
	background: #f4b400;
	color: #1a1a1a;
	box-shadow: 0 2px 6px rgba(244, 180, 0, 0.4);
}

/* -- Artwork -- */
.kf-trending-card__art {
	position: relative;
	width: 100%;
	height: 180px; /* matches the 180px card column width => always square */
	flex: none;
	border-radius: var(--kf-r-sm);
	overflow: hidden;
	background: #f1f5f9;
	margin-bottom: 0.5rem;
}

.kf-trending-card__art img {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

/* -- Info Area -- */
.kf-trending-card__info {
	width: 100%;
}

.kf-trending-card__title {
	display: block;
	font-weight: 600;
	font-size: 0.85rem;
	line-height: 1.3;
	color: #0f172a;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
	font-family: var(--kf-font-head);
}

/* -- Responsive -- */
@media (max-width: 600px) {
	.kf-trending-section .kf-container {
		padding: 0 0.75rem;
	}

	.kf-section-title {
		font-size: 0.95rem;
	}

	.kf-trending-card {
		flex: 0 0 140px;
		padding: 0.5rem;
	}

	.kf-trending-card__art {
		height: 140px; /* matches the 140px card column width => always square */
	}

	.kf-trending-card__rank {
		width: 20px;
		height: 20px;
		font-size: 0.6rem;
		top: -4px;
		left: -4px;
	}

	.kf-trending-card__title {
		font-size: 0.75rem;
	}
}
