/* Music - now playing*/
.music-now-playing {
	display: flex;
	gap: 20px;
	align-items: flex-start;
	max-width: 452px;
	margin: 5px auto 5px auto;
	padding: 20px;
	background-color: #fafafa;
	border-radius: 8px;
	border: 1px solid #eee;
	overflow: hidden;
}

.np-thumbnail {
	width: 140px;
	height: 140px;
	object-fit: cover;
	flex-shrink: 0;
}

.np-info {
	flex: 1;
	display: flex;
	flex-direction: column;
	gap: 8px;
	padding-top: 10px;
	overflow: hidden;
	align-items: flex-start;
	width: 100%;
	justify-content: flex-start;
}

.np-title {
	margin: 0;
	font-size: 1.1em;
	font-weight: bold;
	white-space: nowrap;
	overflow: hidden;
	width: 100%;
	text-align: left;
	padding-right: 10px;
	animation: none;
}

.np-title.scroll {
	animation: marquee 15s linear infinite;
}

.np-title:hover {
	animation-play-state: paused;
}

.np-artist {
	margin: 0;
	width: 100%;  /* Full width to measure properly */
	white-space: nowrap;
	overflow: hidden;
	text-align: left;
	animation: none;
}

.np-artist.scroll {
	animation: marquee 15s linear infinite;
}

.np-artist:hover {
	animation-play-state: paused;
}

@keyframes marquee {
	0% {
		transform: translateX(100%);
	}
	100% {
		transform: translateX(-90%);
	}
}

.np-waveform {
	display: flex;
	align-items: flex-end;
	justify-content: center;
	gap: 4px;
	height: 40px;
	margin-top: -20px;  /* Move higher */
}

.wavebar {
	width: 8px;  /* Wider bars */
	background-color: #7fcfff;  /* Blue color */
	border-radius: 2px;
	animation: wavebar 0.6s ease-in-out infinite;
}

.wavebar:nth-child(2) { animation-delay: 0.1s; }
.wavebar:nth-child(3) { animation-delay: 0.2s; }
.wavebar:nth-child(4) { animation-delay: 0.3s; }
.wavebar:nth-child(5) { animation-delay: 0.4s; }
.wavebar:nth-child(6) { animation-delay: 0.5s; }
.wavebar:nth-child(7) { animation-delay: 0.6s; }

@keyframes wavebar {
	0%, 100% { height: 10px; }
	50% { height: 30px; }
}

.np-waveform.paused .wavebar {
	animation: none;
	height: 10px;
}

.music-favorites {
	margin-top: 20px;
	margin-bottom: 20px;
}

.music-favorites h3 {
	font-weight: bold;
	text-align: left;
	margin: 10px;
}


.favorites-grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 20px;
	max-width: 475px;
	margin: 0 auto;
}

.favorite-card {
	position: relative;
	overflow: hidden;
	border-radius: 8px;
	aspect-ratio: 1 / 1;
	cursor: pointer;
	transition: transform 0.2s ease, filter 0.2s ease;
}

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

.favorite-card:hover {
	transform: scale(1.05);
	filter: brightness(0.8);
}

.favorite-card-overlay {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background: rgba(0, 0, 0, 0.6);
	display: flex;
	flex-direction: column;
	justify-content: flex-end;
	padding: 15px;
	opacity: 0;
	transition: opacity 0.2s ease;
	color: white;
	font-size: 0.9em;
	text-align: center;
}

.favorite-card:hover .favorite-card-overlay {
	opacity: 1;
}

.favorite-card-title {
	font-weight: bold;
	margin-bottom: 5px;
	word-break: break-word;
}

.favorite-card-artist {
	font-size: 0.85em;
	opacity: 0.9;
}
/*weekly section*/
.weekly-tracks {
	display: flex;
	flex-direction: column;
	gap: 12px;
	max-width: 490px;
	margin: 0 auto;
}

.weekly-track-item {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 10px;
	border-radius: 6px;
	background: #f5f5f5;
	cursor: pointer;
	transition: background 0.2s ease;
}

.weekly-track-item:hover {
	background: #e0e0e0;
}

.weekly-thumbnail {
	width: 50px;
	height: 50px;
	border-radius: 4px;
	object-fit: cover;
}

.weekly-info {
	flex: 1;
	min-width: 0;
	overflow: hidden;
}

.weekly-title,
.weekly-artist {
	margin: 0;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
	font-size: 0.95em;
	text-align: left;
}

.weekly-artist {
	font-size: 0.85em;
	opacity: 0.7;
}

.weekly-count {
	margin: 0;
	font-weight: bold;
	white-space: nowrap;
}

/* genre */
.music-dashboard {
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 15px;
	max-width: 450px;
	margin: 15px auto;
	box-sizing: border-box;
}

.dashboard-box {
	flex: 1;
	height: 145px;
	display: flex;
	flex-direction: column;
}

.dashboard-box h3 {
	margin: 0 0 8px 0;
	font-size: 1rem;
	text-align: left;
}

.library-summary-list {
	list-style-type: none;
	padding: 10px;
	margin: 0;
	text-align: left;
	border: 1px solid #eee;
	background-color: #fafafa;
	border-radius: 6px;
	height: 100%;
	box-sizing: border-box;
	display: flex;
	flex-direction: column;
	justify-content: center;
}

.library-summary-list li {
	font-size: 0.9rem;
	line-height: 1.5;
	margin-bottom: 5px;
	color: #333;
}
.library-summary-list li:last-child {
	margin-bottom: 0;
}

.genre-scroll-box {
	width: 100%;
	height: 100%;
	overflow-y: auto;
	border: 1px solid #eee;
	background-color: #fafafa;
	border-radius: 6px;
	padding: 10px;
	box-sizing: border-box;
}

.genre-scroll-box::-webkit-scrollbar {
	width: 4px;
}
.genre-scroll-box::-webkit-scrollbar-track {
	background: #f1f1f1;
	border-radius: 4px;
}
.genre-scroll-box::-webkit-scrollbar-thumb {
	background: #ccc;
	border-radius: 4px;
}
.genre-scroll-box::-webkit-scrollbar-thumb:hover {
	background: #aaa;
}

.genre-row {
	display: flex;
	align-items: center;
	gap: 8px;
	margin-bottom: 6px;
	width: 100%;
	box-sizing: border-box;
}

.genre-name {
	width: 55px;
	font-size: 0.8rem;
	font-weight: bold;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.genre-pct {
	width: 28px;
	text-align: right;
	font-size: 0.75rem;
	color: #666;
}

.bar-bg {
	flex-grow: 1;
	background-color: #e8e8e8;
	height: 8px;
	border-radius: 4px;
	overflow: hidden;
}

.bar-fill {
	background-color: #7fcfff;
	height: 100%;
	border-radius: 4px;
	transition: width 0.4s ease-in-out;
}

/* years */
.year-histogram-wrapper {
	width: 100%;
	max-width: 450px;
	margin: 25px auto;
	background: white;
}

.histogram-readout {
	width: 100%;
	text-align: center;
	font-size: 0.85rem;
	font-weight: bold;
	color: #666;
	background-color: #f8f9fa;
	padding: 8px 0;
	border-radius: 4px;
	margin-bottom: 12px;
	min-height: 18px;
	border: 1px solid #eee;
}

.histogram-grid {
	display: flex;
	align-items: flex-end;
	gap: 1.5px;
	height: 120px;
	padding: 10px 0 5px 0;
	overflow: hidden;
	border-bottom: 2px solid #e0e0e0;
}

.hist-column {
	display: flex;
	flex-direction: column;
	justify-content: flex-end;
	height: 100%;
	flex: 1;
}

.hist-bar {
	width: 100%;
	background-color: #7fcfff;
	border-radius: 1px 1px 0 0;
	transition: background-color 0.15s ease;
	cursor: pointer;
}

.hist-bar:hover {
	background-color: #ff4081;
}

.histogram-timeline-labels {
	display: flex;
	justify-content: space-between;
	padding-top: 6px;
	font-size: 0.8rem;
	font-weight: bold;
	color: #888;
}

.top-divider {
	border: none;
	border-top: 2px solid #d3d3d3;
	margin: 15px auto;
	width: 98%;
}





