:root {
  color-scheme: light;
  --paper: #f7f6f2;
  --ink: #242c29;
  --muted: #7b817b;
  --accent: #547763;
  --line: #e2e5dd;
  font-family:
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
  color: var(--ink);
  background: var(--paper);
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
}
button,
input {
  font: inherit;
}
button {
  cursor: pointer;
}
button:disabled {
  cursor: default;
  opacity: 0.4;
}
button,
a,
input {
  touch-action: manipulation;
}
button:focus-visible,
a:focus-visible,
input:focus-visible {
  outline: 3px solid #8db19c;
  outline-offset: 4px;
}
[hidden] {
  display: none !important;
}
main {
  max-width: 1140px;
  padding: 0 40px;
  margin: auto;
}
header {
  height: 105px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--line);
}
.brand {
  font-family: Georgia, serif;
  font-size: 43px;
  letter-spacing: -6px;
  font-weight: bold;
  color: var(--ink);
  text-decoration: none;
}
.brand span {
  color: var(--accent);
}
.brand i {
  font-size: 9px;
  letter-spacing: 0;
  margin-left: 10px;
  color: var(--accent);
}
.header-note,
.eyebrow {
  font-size: 10px;
  letter-spacing: 2px;
  font-weight: 650;
  color: var(--muted);
}
.intro {
  padding: 60px 0 55px;
}
.intro .eyebrow {
  color: var(--accent);
}
h1 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(42px, 5.5vw, 66px);
  font-weight: normal;
  line-height: 1.08;
  letter-spacing: -2px;
  margin: 20px 0;
}
h1 em {
  color: var(--accent);
  font-weight: normal;
}
h1 > span {
  color: var(--accent);
}
.intro > p:last-child {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.7;
}
.workspace {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 50px;
}
.section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 22px;
}
h2 {
  font-family: Georgia, serif;
  font-weight: normal;
  font-size: 25px;
  margin: 7px 0;
}
#count {
  font-family: system-ui, sans-serif;
  font-size: 11px;
  color: var(--muted);
  background: #e9ece5;
  padding: 5px 9px;
  border-radius: 20px;
  margin-left: 6px;
  white-space: nowrap;
}
.add-button,
.input-row button {
  background: var(--accent);
  color: white;
  border: 0;
  border-radius: 7px;
  padding: 11px 15px;
  white-space: nowrap;
}
.add-button:hover {
  background: #405e4c;
}
#add-form {
  background: #edeee7;
  padding: 17px;
  border-radius: 8px;
  margin-bottom: 18px;
}
#add-form label {
  display: block;
  font-size: 13px;
  margin-bottom: 9px;
}
.input-row {
  display: flex;
  gap: 8px;
}
.input-row input {
  min-width: 0;
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 5px;
  padding: 10px;
  background: #fff;
}
#add-form p {
  font-size: 11px;
  color: var(--muted);
  line-height: 1.6;
  margin-bottom: 0;
}
#notice {
  font-size: 13px;
  color: var(--accent);
  line-height: 1.6;
  margin: 0 0 12px;
}
#notice.error {
  color: #a74938;
}
.song {
  display: flex;
  align-items: center;
  gap: 13px;
  min-height: 84px;
  border-top: 1px solid var(--line);
  padding: 12px 8px;
  border-radius: 6px;
}
.song.selected {
  background: #e9eee5;
  border-color: transparent;
}
.song-select {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 13px;
  background: none;
  border: 0;
  text-align: left;
  padding: 0;
  color: inherit;
}
.song-number {
  color: #a2a79e;
  font-size: 12px;
  min-width: 19px;
}
.song-art {
  width: 46px;
  height: 46px;
  border-radius: 6px;
  background: #e6e6da;
  display: grid;
  place-items: center;
  font-family: Georgia, serif;
  font-size: 23px;
  color: #63755f;
  flex-shrink: 0;
}
.song:nth-child(3n + 2) .song-art {
  background: #ebe0d6;
  color: #977b64;
}
.song:nth-child(3n) .song-art {
  background: #dfe5ea;
  color: #6e8390;
}
.song-info {
  min-width: 0;
}
.song-info strong {
  font-size: 13px;
  display: block;
  overflow-wrap: anywhere;
  font-weight: 600;
}
.song-info small {
  display: block;
  font-size: 11px;
  color: var(--muted);
  margin-top: 5px;
  line-height: 1.5;
}
.unavailable {
  font-size: 10px;
  color: #947559;
}
.delete {
  color: #9a9f96;
  border: 0;
  background: none;
  padding: 12px;
  font-size: 19px;
}
.delete:hover {
  color: #a74938;
}
.collection-footer {
  border-top: 1px solid var(--line);
  padding-top: 21px;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.6;
}
.collection-footer span:last-child {
  font-size: 8px;
  letter-spacing: 1px;
}
.lyrics-panel {
  border-left: 1px solid var(--line);
  padding-left: 32px;
  min-width: 0;
}
#lyrics-title {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.6;
  overflow-wrap: anywhere;
}
.lyrics-rule {
  width: 30px;
  height: 2px;
  background: var(--accent);
  margin: 28px 0;
}
.lyrics {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  font-size: 14px;
  line-height: 2.05;
  color: #687167;
  max-height: 500px;
  overflow: auto;
}
#lyrics-source {
  font-size: 11px;
  color: var(--accent);
}
.empty {
  padding: 45px 25px;
  text-align: center;
  border: 1px dashed #d5dace;
  border-radius: 10px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.9;
}
.empty span {
  display: block;
  font-size: 28px;
  color: var(--accent);
  margin-bottom: 12px;
}
footer {
  padding: 55px 0 180px;
  display: flex;
  justify-content: space-between;
  gap: 15px;
  font-size: 9px;
  letter-spacing: 1px;
  color: #92998f;
}
.player {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: #fffdf8f5;
  backdrop-filter: blur(15px);
  border-top: 1px solid var(--line);
  padding: 20px 40px 12px;
}
.player-inner {
  max-width: 1060px;
  margin: auto;
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  align-items: center;
  gap: 15px;
}
.now-playing {
  display: flex;
  align-items: center;
  gap: 13px;
  min-width: 0;
}
.now-playing > div:last-child {
  min-width: 0;
}
.record {
  width: 49px;
  height: 49px;
  background: #e7ece2;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: var(--accent);
  font-size: 23px;
  flex-shrink: 0;
}
.now-playing .eyebrow {
  font-size: 8px;
  letter-spacing: 1.5px;
  margin: 0 0 5px;
}
.now-playing strong {
  font-size: 12px;
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
#playing-artist {
  font-size: 10px;
  color: var(--muted);
  margin: 5px 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.controls {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 22px;
}
.controls button {
  border: 0;
  background: none;
  font-size: 18px;
  color: #687366;
  padding: 6px;
}
.controls .play-button {
  width: 39px;
  height: 39px;
  background: var(--accent);
  color: #fff;
  border-radius: 50%;
  font-size: 16px;
}
.timeline {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 10px;
  font-size: 9px;
  color: var(--muted);
}
#progress {
  width: 100%;
  height: 3px;
  accent-color: var(--accent);
}
.autoplay {
  justify-self: end;
  font-size: 11px;
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 7px;
  cursor: pointer;
}
.autoplay input {
  accent-color: var(--accent);
}
#player-status {
  grid-column: 1/-1;
  text-align: center;
  font-size: 11px;
  color: #947559;
  margin: 0;
  min-height: 13px;
}
@media (max-width: 780px) {
  main {
    padding: 0 22px;
  }
  header {
    height: 77px;
  }
  .header-note {
    font-size: 8px;
    letter-spacing: 1px;
  }
  .intro {
    padding: 35px 0;
  }
  .workspace {
    grid-template-columns: 1fr;
    gap: 35px;
  }
  .lyrics-panel {
    border-left: 0;
    border-top: 1px solid var(--line);
    padding: 25px 0 0;
  }
  .lyrics {
    max-height: 350px;
  }
  h2 {
    font-size: 22px;
  }
  .player {
    padding: 13px 20px max(10px, env(safe-area-inset-bottom));
  }
  .player-inner {
    grid-template-columns: 1fr auto;
    gap: 9px;
  }
  .now-playing {
    grid-column: 1;
    grid-row: 1;
  }
  .playback {
    grid-column: 1/-1;
    grid-row: 2;
  }
  .controls {
    position: absolute;
    right: 20px;
    top: 14px;
    gap: 12px;
  }
  .controls .play-button {
    width: 36px;
    height: 36px;
  }
  .now-playing {
    padding-right: 130px;
  }
  .record {
    width: 38px;
    height: 38px;
  }
  .autoplay {
    grid-column: 1/-1;
    grid-row: 3;
    font-size: 10px;
    justify-self: center;
  }
  .timeline {
    margin-top: 5px;
  }
  #player-status {
    grid-row: 4;
  }
  footer {
    padding-bottom: 220px;
    font-size: 8px;
  }
  .collection-footer span:last-child {
    display: none;
  }
}
@media (prefers-reduced-motion: reduce) {
  * {
    scroll-behavior: auto;
  }
}

.controls svg {
  width: 18px;
  height: 18px;
  display: block;
  margin: auto;
  fill: currentColor;
}
