/* Stimmung Song Library — design system ported from design_handoff_stimmung_library */

html,
body {
	margin: 0;
	padding: 0;
	background: #000;
}
body {
	font-family: Poppins, system-ui, sans-serif;
	font-weight: 300;
	color: #fff;
	text-wrap: pretty;
}
* {
	box-sizing: border-box;
}
a {
	color: #fff;
	text-decoration: none;
}
a:hover {
	color: #b9b9b9;
}
input,
button {
	font-family: inherit;
}
input:focus {
	outline: none;
}
::selection {
	background: #fff;
	color: #000;
}

:focus-visible {
	outline: 1px solid #fff;
	outline-offset: 3px;
}

@keyframes fadeUp {
	from {
		opacity: 0;
		transform: translateY(8px);
	}
	to {
		opacity: 1;
		transform: none;
	}
}
@keyframes shake {
	0%,
	100% {
		transform: none;
	}
	20% {
		transform: translateX(-6px);
	}
	40% {
		transform: translateX(6px);
	}
	60% {
		transform: translateX(-3px);
	}
	80% {
		transform: translateX(3px);
	}
}
@keyframes bar {
	0%,
	100% {
		height: 25%;
	}
	50% {
		height: 95%;
	}
}

@media (prefers-reduced-motion: reduce) {
	.row,
	.gate-error {
		animation: none !important;
	}
	.eq span {
		animation: none !important;
		height: 60% !important;
	}
}

.blackletter {
	font-family: baroque-text-jf, UnifrakturMaguntia, serif;
	font-weight: 400;
}

/* ---------- Password gate ---------- */

.gate {
	min-height: 100vh;
	display: flex;
	flex-direction: column;
	justify-content: space-between;
	padding: clamp(20px, 5vw, 40px);
	background: #000;
}
.gate-meta {
	display: flex;
	justify-content: space-between;
	align-items: center;
	font-size: 14px;
	font-weight: 300;
	color: #8a8a8a;
}
.gate-meta.bottom {
	font-size: 13px;
}
.gate-center {
	max-width: 900px;
	margin: 0 auto;
	width: 100%;
	padding: 60px 0;
	text-align: center;
}
.gate-title {
	font-family: baroque-text-jf, UnifrakturMaguntia, serif;
	font-weight: 400;
	font-size: clamp(2rem, 11vw, 4rem);
	line-height: 1.06;
	margin: 0;
	color: #fff;
}
.gate-copy {
	max-width: 44ch;
	margin: 32px auto 46px;
	font-size: 17px;
	font-weight: 300;
	line-height: 1.6;
	color: #9a9a9a;
}
.gate-form {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 18px;
	max-width: 420px;
	margin: 0 auto;
}
.gate-input {
	width: 100%;
	background: transparent;
	border: none;
	border-bottom: 1px solid rgba(255, 255, 255, 0.35);
	color: #fff;
	font-size: 19px;
	font-weight: 300;
	text-align: center;
	padding: 14px 8px;
}
.gate-submit {
	width: 100%;
	border: 1px solid #fff;
	background: transparent;
	color: #fff;
	font-size: 14px;
	font-weight: 400;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	padding: 20px 28px;
	cursor: pointer;
}
.gate-submit:hover {
	background: #fff;
	color: #000;
}
.gate-msg {
	height: 30px;
	margin-top: 20px;
	font-size: 13px;
	font-weight: 300;
}
.gate-error {
	display: inline-block;
	color: #fff;
	border-bottom: 1px solid #fff;
	padding-bottom: 3px;
	animation: shake 0.4s ease;
}

/* ---------- App shell ---------- */

.shell {
	min-height: 100vh;
	background: #000;
	padding-bottom: 150px;
}
.wrap {
	max-width: 1400px;
	margin: 0 auto;
	padding: 0 clamp(18px, 4vw, 44px);
}

header.site {
	position: sticky;
	top: 0;
	z-index: 40;
	background: #000;
}
.site-inner {
	max-width: 1400px;
	margin: 0 auto;
	padding: 22px clamp(18px, 4vw, 44px);
	display: flex;
	align-items: center;
	gap: 22px;
	flex-wrap: wrap;
}
.wordmark {
	display: inline-flex;
	align-items: center;
	font-family: baroque-text-jf, UnifrakturMaguntia, serif;
	font-size: 30px;
	color: #fff;
	line-height: 1;
}
.wordmark:hover {
	color: #b9b9b9;
}
.wordmark img {
	height: 38px;
	width: auto;
	display: block;
}
.wordmark:hover img {
	opacity: 0.72;
}
.site-spacer {
	flex: 1;
}
.site-nav {
	display: flex;
	align-items: center;
	gap: 26px;
	font-size: 14px;
	font-weight: 300;
	color: #9a9a9a;
}
.site-nav .current {
	color: #fff;
	border-bottom: 1px solid #fff;
	padding-bottom: 3px;
}
.menu {
	position: relative;
}
.menu-btn {
	display: flex;
	flex-direction: column;
	justify-content: center;
	gap: 5px;
	width: 36px;
	height: 36px;
	padding: 9px 8px;
	background: none;
	border: none;
	cursor: pointer;
}
.menu-btn span {
	display: block;
	height: 1px;
	background: #9a9a9a;
}
.menu-btn:hover span,
.menu-btn[aria-expanded="true"] span {
	background: #fff;
}
.menu-panel {
	position: absolute;
	right: 0;
	top: calc(100% + 12px);
	z-index: 50;
	min-width: 160px;
	background: #000;
	border: 1px solid rgba(255, 255, 255, 0.4);
}
.menu-panel[hidden] {
	display: none;
}
.signout-btn {
	display: block;
	width: 100%;
	text-align: left;
	background: none;
	border: none;
	padding: 14px 18px;
	cursor: pointer;
	font-size: 14px;
	font-weight: 300;
	color: #fff;
}
.signout-btn:hover {
	background: #fff;
	color: #000;
}

/* ---------- Repertoire index ---------- */

.page-head {
	padding: clamp(40px, 8vw, 90px) 0 clamp(30px, 5vw, 54px);
	text-align: center;
}
.page-title {
	font-family: baroque-text-jf, UnifrakturMaguntia, serif;
	font-weight: 400;
	font-size: clamp(2rem, 9vw, 4rem);
	line-height: 1.06;
	margin: 0;
}
.page-counts {
	margin-top: 22px;
	font-size: 15px;
	font-weight: 300;
	color: #8a8a8a;
}

.filter-bar {
	display: flex;
	gap: 20px;
	flex-wrap: wrap;
	align-items: center;
	padding-bottom: 22px;
	border-bottom: 1px solid rgba(255, 255, 255, 0.18);
}
.search-box {
	flex: 1 1 300px;
	display: flex;
	align-items: center;
	gap: 12px;
	border-bottom: 1px solid rgba(255, 255, 255, 0.35);
	padding: 10px 2px;
}
.search-box input {
	flex: 1;
	min-width: 0;
	border: none;
	background: transparent;
	font-size: 17px;
	font-weight: 300;
	color: #fff;
}
.clear-btn {
	border: none;
	background: none;
	color: #9a9a9a;
	cursor: pointer;
	font-size: 12px;
	letter-spacing: 0.1em;
	text-transform: uppercase;
}
.clear-btn:hover {
	color: #fff;
}

.current-toggle {
	cursor: pointer;
	display: flex;
	align-items: center;
	gap: 12px;
	border: 1px solid rgba(255, 255, 255, 0.4);
	background: transparent;
	color: #fff;
	padding: 13px 20px;
	font-size: 12px;
	font-weight: 400;
	letter-spacing: 0.12em;
	text-transform: uppercase;
}
.current-toggle .track {
	width: 30px;
	height: 16px;
	flex: none;
	border: 1px solid currentColor;
	display: flex;
	align-items: center;
	padding: 2px;
	justify-content: flex-start;
}
.current-toggle .knob {
	width: 10px;
	height: 10px;
	background: currentColor;
}
.current-toggle .count {
	opacity: 0.5;
}
.current-toggle.on {
	background: #fff;
	color: #000;
	border-color: #fff;
}
.current-toggle.on .track {
	justify-content: flex-end;
}

.empty-state {
	padding: 120px 0;
	text-align: center;
}
.empty-state .big {
	font-family: baroque-text-jf, UnifrakturMaguntia, serif;
	font-size: 54px;
	margin-bottom: 14px;
}
.empty-state .sub {
	font-size: 15px;
	font-weight: 300;
	color: #8a8a8a;
}

.song-list {
	padding: 10px 0 40px;
}
.row {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: clamp(12px, 2vw, 26px);
	padding: clamp(16px, 2.4vw, 24px) 4px;
	border-bottom: 1px solid rgba(255, 255, 255, 0.14);
	animation: fadeUp 0.25s ease both;
	color: #fff;
}
/* Search/toggle repaints swap rows in place — no fade on re-render. */
#results.static .row {
	animation: none;
}
.row:hover {
	background: #101010;
	color: #fff;
}
.row-num {
	font-size: 12px;
	font-weight: 300;
	color: #8a8a8a;
	width: 30px;
	flex: none;
}
.row-main {
	flex: 1 1 55%;
	min-width: 0;
}
.row-title {
	font-family: baroque-text-jf, UnifrakturMaguntia, serif;
	font-size: clamp(1rem, 4.4vw, 2rem);
	line-height: 1.14;
}
.row-meta {
	margin-top: 6px;
	font-size: 14px;
	font-weight: 300;
	color: #8a8a8a;
}
.row-arrow {
	flex: none;
	font-size: 18px;
	color: #8a8a8a;
	width: 24px;
	text-align: right;
}

.badge {
	flex: none;
	font-size: 11px;
	font-weight: 400;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	border: 1px solid;
	padding: 6px 12px;
}
.badge.current {
	background: #fff;
	color: #000;
	border-color: #fff;
}

/* ---------- Song page ---------- */

.crumbs {
	display: flex;
	align-items: center;
	gap: 10px;
	flex-wrap: wrap;
	padding: 14px 0 0;
	font-size: 13px;
	font-weight: 300;
	color: #8a8a8a;
}
.crumbs a {
	color: #9a9a9a;
}
.crumbs a:hover {
	color: #fff;
}
.crumbs .here {
	color: #fff;
}

.song-head {
	padding: clamp(40px, 7vw, 88px) 0 clamp(30px, 4vw, 46px);
	text-align: center;
}
.song-title {
	font-family: baroque-text-jf, UnifrakturMaguntia, serif;
	font-weight: 400;
	font-size: clamp(2rem, 9.5vw, 4rem);
	line-height: 1.06;
	margin: 0;
}
.song-detail {
	margin-top: 26px;
	font-size: 13px;
	font-weight: 300;
	letter-spacing: 0.06em;
	color: #8a8a8a;
}
.song-note {
	max-width: 52ch;
	margin: 18px auto 0;
	font-size: 15px;
	font-weight: 300;
	line-height: 1.6;
	color: #9a9a9a;
}

.download-wrap {
	display: flex;
	justify-content: center;
	padding-bottom: clamp(40px, 6vw, 70px);
}
.download-btn {
	border: 1px solid #fff;
	color: #fff;
	font-size: 14px;
	font-weight: 400;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	padding: 22px 46px;
	text-align: center;
}
.download-btn:hover {
	background: #fff;
	color: #000;
}

/* Mobile layout runs through tablet sizes; the two-column song page is desktop-only. */
.song-body {
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	gap: clamp(34px, 4vw, 56px);
	padding-bottom: 60px;
	align-items: start;
	border-top: 1px solid rgba(255, 255, 255, 0.18);
	padding-top: clamp(34px, 5vw, 60px);
}
@media (min-width: 1025px) {
	.song-body {
		grid-template-columns: repeat(auto-fit, minmax(min(100%, 340px), 1fr));
	}
	.song-body.no-media {
		grid-template-columns: minmax(0, 1fr);
	}
}
.song-main {
	display: flex;
	flex-direction: column;
	gap: clamp(34px, 4vw, 52px);
	min-width: 0;
}

.tracks-head {
	display: flex;
	align-items: baseline;
	gap: 14px;
	flex-wrap: wrap;
	margin-bottom: 22px;
}
.tracks-head h2 {
	font-family: baroque-text-jf, UnifrakturMaguntia, serif;
	font-weight: 400;
	font-size: clamp(30px, 5vw, 42px);
	margin: 0;
}
.tracks-head .hint {
	font-size: 13px;
	font-weight: 300;
	color: #8a8a8a;
}

.section-pref {
	margin-left: auto;
	display: flex;
	align-items: center;
	gap: 10px;
	font-size: 12px;
	font-weight: 400;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: #8a8a8a;
}
.section-pref select {
	appearance: none;
	-webkit-appearance: none;
	border-radius: 0;
	background: transparent;
	color: #fff;
	border: 1px solid rgba(255, 255, 255, 0.4);
	font-family: inherit;
	font-size: 12px;
	font-weight: 400;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	padding: 10px 14px;
	cursor: pointer;
}
.section-pref select:hover {
	background: #fff;
	color: #000;
	border-color: #fff;
}

.ensemble-row {
	cursor: pointer;
	display: flex;
	align-items: center;
	gap: 18px;
	width: 100%;
	text-align: left;
	border: 1px solid rgba(255, 255, 255, 0.5);
	background: transparent;
	color: #fff;
	padding: 18px 22px;
	margin-bottom: 12px;
}
.ensemble-row:hover,
.ensemble-row.playing {
	background: #fff;
	color: #000;
}
.ensemble-row .disc {
	width: 34px;
	height: 34px;
	flex: none;
	border: 1px solid currentColor;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 12px;
}
.ensemble-row .t {
	font-size: 17px;
	font-weight: 400;
}
.ensemble-row .d {
	font-size: 12px;
	font-weight: 300;
	opacity: 0.6;
}

/* A movement/set heading when a song carries several groups of guide tracks. */
.group-title {
	font-size: clamp(22px, 3.4vw, 30px);
	margin: 30px 0 16px;
}

/* One line per section — the 1 & 2 splits share it at every size. */
.part-grid {
	display: flex;
	flex-direction: column;
	gap: 10px;
}
.part-line {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 10px;
}
.part-line.one {
	grid-template-columns: 1fr;
}
/* a merged section (e.g. Mezzo 1 & 2 in one file) takes the whole line */
.part-tile.merged {
	grid-column: 1 / -1;
}
.part-tile {
	cursor: pointer;
	display: flex;
	align-items: center;
	gap: 12px;
	text-align: left;
	border: 1px solid rgba(255, 255, 255, 0.22);
	background: transparent;
	color: #fff;
	padding: 13px 15px;
}
.part-tile:hover,
.part-tile.playing {
	background: #fff;
	color: #000;
}
/* the chosen section stays in its slot, pointing at the promoted row above */
.part-tile:disabled,
.part-tile:disabled:hover {
	background: transparent;
	color: #fff;
	opacity: 0.4;
	cursor: default;
}
.part-tile .abbr {
	width: 28px;
	flex: none;
	font-size: 11px;
	letter-spacing: 0.08em;
	opacity: 0.6;
}
.part-tile .mid {
	flex: 1;
	min-width: 0;
}
.part-tile .name {
	font-size: 14px;
	font-weight: 400;
}
.part-tile .len {
	font-size: 11px;
	font-weight: 300;
	opacity: 0.55;
}
.part-tile .glyph {
	font-size: 11px;
}

.media-side {
	display: flex;
	flex-direction: column;
	gap: 30px;
}
@media (min-width: 1025px) {
	.media-side {
		position: sticky;
		top: 96px;
	}
}
.media-label {
	font-size: 12px;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: #8a8a8a;
	margin-bottom: 12px;
}
.media-frame {
	border: 1px solid rgba(255, 255, 255, 0.28);
	background: #0a0a0a;
	display: block;
}
.media-frame iframe {
	display: block;
	width: 100%;
	height: 100%;
	border: 0;
}
.media-frame.flat {
	aspect-ratio: 4 / 3;
}

.song-foot {
	border-top: 1px solid rgba(255, 255, 255, 0.18);
	padding: 28px 0 20px;
	display: flex;
	justify-content: space-between;
	gap: 18px;
	flex-wrap: wrap;
	font-size: 13px;
	font-weight: 300;
}
.song-foot a {
	color: #9a9a9a;
}
.song-foot a:hover {
	color: #fff;
}

/* ---------- Site footer ---------- */

.site-foot {
	border-top: 1px solid rgba(255, 255, 255, 0.18);
	margin-top: clamp(40px, 6vw, 70px);
	padding: clamp(30px, 5vw, 50px) 0 10px;
	text-align: center;
}
.site-foot .foot-name {
	font-size: 30px;
}
.site-foot .foot-mail {
	display: inline-block;
	margin-top: 12px;
	font-size: 13px;
	font-weight: 300;
	color: #9a9a9a;
}
.site-foot .foot-mail:hover {
	color: #fff;
}
.foot-social {
	margin-top: 16px;
	display: flex;
	justify-content: center;
	align-items: center;
	gap: 22px;
}
.foot-social a {
	color: #9a9a9a;
	display: inline-flex;
	padding: 4px;
}
.foot-social a:hover {
	color: #fff;
}
.foot-social svg {
	/* 1:1 with the 24px viewBox so strokes land on whole pixels */
	width: 24px;
	height: 24px;
}

.gate-foot {
	border-top: none;
	margin: 0 0 26px;
	padding: 0;
}

/* ---------- Persistent player ---------- */

.player {
	position: fixed;
	left: 0;
	right: 0;
	bottom: 0;
	z-index: 60;
	background: #000;
	border-top: 1px solid rgba(255, 255, 255, 0.3);
}
.player[hidden] {
	display: none;
}
/* A tall (≥44px) seek strip sits on top; press or drag anywhere on it to seek.
   The controls row sits underneath. */
.player-progress {
	height: 44px;
	background: #222;
	cursor: pointer;
	position: relative;
	touch-action: none;
}
.player-progress:focus-visible {
	outline: 2px solid rgba(255, 255, 255, 0.6);
	outline-offset: -2px;
}
.player-progress:hover .fill {
	background: #fff;
}
.player-progress .fill {
	height: 100%;
	background: #e6e6e6;
	border-right: 2px solid #fff;
	width: 0%;
}
.player-body {
	max-width: 1400px;
	margin: 0 auto;
	padding: 14px clamp(18px, 4vw, 44px);
	display: flex;
	align-items: center;
	gap: 18px;
	flex-wrap: wrap;
}
.play-btn {
	width: 42px;
	height: 42px;
	flex: none;
	border-radius: 50%;
	border: 1px solid #fff;
	background: transparent;
	color: #fff;
	cursor: pointer;
	font-size: 13px;
}
.play-btn:hover {
	background: #fff;
	color: #000;
}
.eq {
	display: flex;
	align-items: flex-end;
	gap: 3px;
	height: 22px;
	width: 30px;
	flex: none;
}
.eq span {
	width: 3px;
	background: #3a3a3a;
}
.eq span:nth-child(1) {
	height: 40%;
}
.eq span:nth-child(2) {
	height: 80%;
}
.eq span:nth-child(3) {
	height: 55%;
}
.eq span:nth-child(4) {
	height: 90%;
}
.player.playing .eq span {
	background: #fff;
	animation: bar 0.7s ease-in-out infinite;
}
.player.playing .eq span:nth-child(2) {
	animation-delay: 0.15s;
}
.player.playing .eq span:nth-child(3) {
	animation-delay: 0.3s;
}
.player.playing .eq span:nth-child(4) {
	animation-delay: 0.45s;
}
.player-song {
	flex: 1 1 200px;
	min-width: 0;
	font-size: 15px;
	font-weight: 400;
	color: #fff;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}
.player-time {
	font-size: 12px;
	font-weight: 300;
	color: #8a8a8a;
	flex: none;
}
.player-close {
	flex: none;
	border: none;
	background: none;
	cursor: pointer;
	font-size: 13px;
	color: #9a9a9a;
}
.player-close:hover {
	color: #fff;
}
