:root {
  --bg: #0b0a10;
  --panel: #16141f;
  --panel-2: #1f1c2b;
  --text: #f3efff;
  --muted: #9a94b3;
  --accent: #ff4fa3;
  --accent-2: #7c5cff;
  --ok: #39d98a;
  --warn: #ffc857;
  --bad: #ff6b6b;
  --radius: 14px;
}
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Inter, sans-serif; }
body { padding: 0 0 90px; }
header { position: sticky; top: 0; z-index: 5; background: linear-gradient(180deg, var(--bg) 70%, transparent);
  padding: 14px 16px 10px; display: flex; align-items: center; gap: 12px; }
header h1 { margin: 0; font-size: 22px; letter-spacing: .5px; }
header h1 span { color: var(--accent); }
header .spacer { flex: 1; }
#singer { background: var(--panel); color: var(--text); border: 1px solid #2b2740; border-radius: 999px;
  padding: 8px 14px; font-size: 15px; width: 150px; }
#singer:focus { outline: 2px solid var(--accent-2); border-color: transparent; }
main { max-width: 720px; margin: 0 auto; padding: 0 16px; display: grid; gap: 18px; }
section h2 { font-size: 13px; text-transform: uppercase; letter-spacing: 1.5px; color: var(--muted); margin: 0 0 8px; }
.card { background: var(--panel); border-radius: var(--radius); padding: 14px; }
.now { display: grid; grid-template-columns: 96px 1fr; gap: 14px; align-items: center;
  background: linear-gradient(135deg, #2a1a3a, #171a33); }
.now img { width: 96px; height: 54px; object-fit: cover; border-radius: 8px; }
.now .title { font-weight: 600; font-size: 16px; line-height: 1.25; }
.now .singer { color: var(--accent); font-size: 14px; margin-top: 4px; }
.now .idle { color: var(--muted); font-size: 15px; }
.bar { height: 4px; background: #2b2740; border-radius: 4px; margin-top: 10px; overflow: hidden; }
.bar > i { display: block; height: 100%; background: var(--accent); width: 0; transition: width .4s linear; }
.searchbox { display: flex; gap: 8px; }
.searchbox input { flex: 1; background: var(--panel); color: var(--text); border: 1px solid #2b2740;
  border-radius: 12px; padding: 12px 14px; font-size: 16px; }
.searchbox input:focus { outline: 2px solid var(--accent-2); border-color: transparent; }
button { background: var(--accent-2); color: white; border: 0; border-radius: 12px; padding: 12px 16px;
  font-size: 15px; font-weight: 600; cursor: pointer; }
button:disabled { opacity: .5; cursor: default; }
button.ghost { background: var(--panel-2); color: var(--text); padding: 8px 10px; font-size: 14px; }
button.danger { background: #3a1f2a; color: var(--bad); }
button.add { background: var(--accent); white-space: nowrap; }
.list { display: grid; gap: 8px; }
.row { display: grid; grid-template-columns: 80px 1fr auto; gap: 12px; align-items: center;
  background: var(--panel); border-radius: var(--radius); padding: 10px; }
.row img { width: 80px; height: 45px; object-fit: cover; border-radius: 6px; background: #000; }
.row .t { font-size: 14px; font-weight: 600; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2;
  -webkit-box-orient: vertical; overflow: hidden; }
.row .m { color: var(--muted); font-size: 12px; margin-top: 3px; }
.row .actions { display: flex; gap: 6px; flex-direction: column; }
.row .actions.h { flex-direction: row; }
.pill { display: inline-block; font-size: 11px; font-weight: 700; padding: 2px 8px; border-radius: 999px;
  text-transform: uppercase; letter-spacing: .5px; background: var(--panel-2); color: var(--muted); }
.pill.ready { background: #123a29; color: var(--ok); }
.pill.working { background: #3a2f12; color: var(--warn); }
.pill.failed { background: #3a1f2a; color: var(--bad); }
.pos { font-size: 22px; font-weight: 800; color: var(--muted); width: 80px; text-align: center; }
.err { color: var(--bad); font-size: 12px; margin-top: 4px; }
.empty { color: var(--muted); font-size: 14px; padding: 8px 2px; }
footer { position: fixed; bottom: 0; left: 0; right: 0; padding: 12px 16px calc(12px + env(safe-area-inset-bottom));
  background: linear-gradient(0deg, var(--bg) 70%, transparent); display: flex; justify-content: center; gap: 10px; }
footer .status { color: var(--muted); font-size: 12px; align-self: center; }
.toast { position: fixed; top: 70px; left: 50%; transform: translateX(-50%); background: var(--panel-2);
  color: var(--text); padding: 10px 16px; border-radius: 999px; font-size: 14px; opacity: 0; transition: opacity .2s;
  pointer-events: none; z-index: 10; border: 1px solid #2b2740; }
.toast.show { opacity: 1; }

.chips { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; }
.chip { display: inline-flex; align-items: center; gap: 6px; background: var(--panel-2); border-radius: 999px;
  padding: 5px 10px 5px 12px; font-size: 13px; }
.chip.spotify { border: 1px solid #1db95455; }
.chip .x { color: var(--muted); cursor: pointer; font-size: 14px; padding: 0 2px; }
.chip .x:hover { color: var(--bad); }
.recgroup { margin-top: 12px; }
.recgroup h3 { font-size: 13px; margin: 0 0 6px; color: var(--muted); font-weight: 600; }
.rec { display: grid; grid-template-columns: 44px 1fr auto; gap: 10px; align-items: center; padding: 6px 0;
  border-top: 1px solid #221f30; }
.rec img { width: 44px; height: 44px; border-radius: 6px; object-fit: cover; background: #000; }
.rec .t { font-size: 14px; font-weight: 600; line-height: 1.25; }
.rec .m { color: var(--muted); font-size: 12px; margin-top: 2px; }
.rec .fans { color: #1db954; }
.rec button { padding: 8px 12px; }
.connectrow { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
a.btn { display: inline-block; text-decoration: none; background: #1db954; color: #04130a; border-radius: 12px;
  padding: 10px 14px; font-size: 14px; font-weight: 700; }
.plform { display: flex; gap: 6px; margin-top: 10px; }
.plform input { flex: 1; min-width: 0; background: var(--panel-2); color: var(--text); border: 1px solid #2b2740;
  border-radius: 10px; padding: 9px 12px; font-size: 14px; }
.more { background: none; color: var(--accent-2); padding: 6px 0; font-size: 13px; }
