/* BootStepper Playlists – Frontend */

.bsp {
	--bsp-columns: 2;
	--bsp-gap: 1rem;
	--bsp-border: rgba(0, 0, 0, 0.12);
	--bsp-muted: rgba(0, 0, 0, 0.6);
	--bsp-radius: 8px;

	margin: 0 0 2rem;
}

.bsp *,
.bsp *::before,
.bsp *::after {
	box-sizing: border-box;
}

.bsp__title {
	margin: 0 0 0.25rem;
}

.bsp__description {
	margin: 0 0 0.5rem;
}

.bsp__description p {
	margin: 0 0 0.5rem;
}

.bsp__meta {
	display: flex;
	flex-wrap: wrap;
	gap: 0.75rem;
	align-items: baseline;
	margin: 0 0 1rem;
	font-size: 0.875em;
	color: var(--bsp-muted);
}

.bsp__source {
	text-decoration: underline;
}

.bsp-notice {
	margin: 0 0 1rem;
	padding: 0.75rem 1rem;
	border: 1px solid var(--bsp-border, rgba(0, 0, 0, 0.12));
	border-radius: 8px;
	font-size: 0.9375em;
}

/* Filter */

.bsp__filter {
	display: flex;
	flex-wrap: wrap;
	gap: 0.75rem;
	align-items: center;
	margin: 0 0 1.25rem;
}

.bsp__filter-field {
	flex: 1 1 14rem;
	min-width: 0;
}

.bsp__search,
.bsp__level-filter {
	width: 100%;
	max-width: 100%;
	padding: 0.5rem 0.75rem;
	border: 1px solid var(--bsp-border);
	border-radius: var(--bsp-radius);
	font: inherit;
	background: transparent;
	color: inherit;
}

.bsp__filter-field:has(.bsp__level-filter) {
	flex: 0 1 14rem;
}

.bsp__filter-status {
	flex: 1 1 100%;
	margin: 0;
	font-size: 0.875em;
	color: var(--bsp-muted);
}

.bsp__filter-status:empty {
	display: none;
}

/* Karten */

.bsp__cards {
	display: grid;
	grid-template-columns: repeat(var(--bsp-columns), minmax(0, 1fr));
	gap: var(--bsp-gap);
	margin: 0;
	padding: 0;
	list-style: none;
	counter-reset: bsp-counter;
}

.bsp__cards > .bsp__item {
	margin: 0;
	padding: 0;
	list-style: none;
	counter-increment: bsp-counter;
}

.bsp__card {
	display: flex;
	flex-direction: column;
	gap: 0.35rem;
	height: 100%;
	padding: 1rem;
	border: 1px solid var(--bsp-border);
	border-radius: var(--bsp-radius);
}

.bsp__card-head {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
	align-items: baseline;
	justify-content: space-between;
}

.bsp__card-head::before {
	content: counter(bsp-counter) ".";
	order: -1;
	opacity: 0.45;
	font-variant-numeric: tabular-nums;
}

.bsp__dance-title {
	flex: 1 1 auto;
	font-weight: 600;
	text-decoration: none;
}

.bsp__dance-title:hover,
.bsp__dance-title:focus {
	text-decoration: underline;
}

.bsp__choreo,
.bsp__facts,
.bsp__song,
.bsp__links,
.bsp__actions {
	margin: 0;
}

.bsp__facts {
	font-size: 0.875em;
	color: var(--bsp-muted);
}

.bsp__song-title {
	font-style: italic;
}

.bsp__song-artist::before {
	content: " – ";
}

.bsp__song-artist {
	color: var(--bsp-muted);
}

/* Level */

.bsp__level {
	display: inline-block;
	padding: 0.15em 0.6em;
	border: 1px solid currentColor;
	border-radius: 999px;
	font-size: 0.75em;
	line-height: 1.6;
	white-space: nowrap;
}

/* Links und Schaltflächen */

.bsp__links,
.bsp__actions {
	display: flex;
	flex-wrap: wrap;
	gap: 0.4rem;
	margin-top: 0.25rem;
}

.bsp__link,
.bsp__action {
	display: inline-block;
	padding: 0.25em 0.7em;
	border: 1px solid var(--bsp-border);
	border-radius: 999px;
	background: transparent;
	color: inherit;
	font: inherit;
	font-size: 0.8125em;
	line-height: 1.7;
	text-decoration: none;
	cursor: pointer;
}

.bsp__link:hover,
.bsp__action:hover,
.bsp__link:focus-visible,
.bsp__action:focus-visible {
	border-color: currentColor;
	text-decoration: none;
}

.bsp__action[aria-expanded="true"] {
	border-color: currentColor;
	font-weight: 600;
}

/* Video */

.bsp__video {
	margin-top: 0.6rem;
}

.bsp__video[hidden] {
	display: none;
}

.bsp__video-frame {
	position: relative;
	width: 100%;
	aspect-ratio: 16 / 9;
	border-radius: var(--bsp-radius);
	overflow: hidden;
	background: #000;
}

.bsp__video-frame iframe {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	border: 0;
}

.bsp__video-status {
	margin: 0;
	font-size: 0.875em;
	color: var(--bsp-muted);
}

/* Tabelle */

.bsp__table-wrap {
	overflow-x: auto;
}

.bsp__table {
	width: 100%;
	border-collapse: collapse;
}

.bsp__table th,
.bsp__table td {
	padding: 0.6rem 0.75rem;
	border-bottom: 1px solid var(--bsp-border);
	text-align: left;
	vertical-align: top;
}

.bsp__table th {
	font-weight: 600;
	white-space: nowrap;
}

.bsp__cell--title .bsp__facts {
	display: block;
	margin-top: 0.15rem;
}

.bsp__cell--actions {
	white-space: nowrap;
}

.bsp__cell .bsp__song-title,
.bsp__cell .bsp__song-artist {
	display: block;
}

.bsp__cell .bsp__song-artist::before {
	content: none;
}

.bsp__empty {
	color: var(--bsp-muted);
}

/* Übersicht */

.bsp-index {
	--bsp-columns: 3;
	--bsp-gap: 1rem;
	--bsp-border: rgba(0, 0, 0, 0.12);
	--bsp-muted: rgba(0, 0, 0, 0.6);
	--bsp-radius: 8px;

	display: grid;
	grid-template-columns: repeat(var(--bsp-columns), minmax(0, 1fr));
	gap: var(--bsp-gap);
	margin: 0 0 2rem;
	padding: 0;
	list-style: none;
}

.bsp-index__item {
	margin: 0;
	padding: 0;
	list-style: none;
}

.bsp-index__card {
	display: flex;
	flex-direction: column;
	gap: 0.35rem;
	height: 100%;
	padding: 1.1rem;
	border: 1px solid var(--bsp-border);
	border-radius: var(--bsp-radius);
	color: inherit;
	text-decoration: none;
}

.bsp-index__card:hover,
.bsp-index__card:focus-visible {
	border-color: currentColor;
}

.bsp-index__title {
	font-weight: 600;
	font-size: 1.0625em;
}

.bsp-index__count,
.bsp-index__description {
	font-size: 0.875em;
	color: var(--bsp-muted);
}

/* Schmale Bildschirme */

@media (max-width: 782px) {
	.bsp__cards,
	.bsp-index {
		grid-template-columns: 1fr;
	}

	.bsp__table thead {
		display: none;
	}

	.bsp__table,
	.bsp__table tbody,
	.bsp__table tr,
	.bsp__table td {
		display: block;
		width: 100%;
	}

	.bsp__table tr {
		margin-bottom: 1rem;
		border: 1px solid var(--bsp-border);
		border-radius: var(--bsp-radius);
	}

	.bsp__table td {
		border-bottom: 0;
		padding: 0.35rem 0.75rem;
	}

	.bsp__table td:first-child {
		padding-top: 0.75rem;
	}

	.bsp__table td:last-child {
		padding-bottom: 0.75rem;
		white-space: normal;
	}

	.bsp__table td[data-label]::before {
		content: attr(data-label) ": ";
		font-size: 0.75em;
		text-transform: uppercase;
		letter-spacing: 0.04em;
		color: var(--bsp-muted);
	}

	.bsp__table td.bsp__cell--title::before,
	.bsp__table td.bsp__cell--actions::before {
		content: none;
	}
}

/* Dunkle Themes */

@media (prefers-color-scheme: dark) {
	.bsp,
	.bsp-index {
		--bsp-border: rgba(255, 255, 255, 0.22);
		--bsp-muted: rgba(255, 255, 255, 0.65);
	}
}
