/* Track D: select mode, playlist editor, Replay, library settings card, drop overlay.
   Uses the app.css tokens only; controls stay on the single --brand. */

/* ---- select mode */
.select-mode { display: flex; flex-direction: column; min-height: 100%; }
.sel-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 0 4px 8px; color: var(--ink-2); font-size: 14px; }
.sel-bar {
  position: sticky; bottom: -16px; margin-top: auto; display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px;
  padding: 10px 0 calc(14px + var(--safe-b)); background: linear-gradient(transparent, rgb(28 28 34) 28%);
}
.sel-act {
  display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 10px 4px; border-radius: var(--r-md);
  background: var(--s1); color: var(--ink); font-size: 12.5px; font-weight: 550;
  transition: background .18s var(--ease), opacity .18s var(--ease), transform .18s var(--ease);
}
.sel-act .ic { width: 22px; height: 22px; color: var(--brand-ink); }
.sel-act:active:not(:disabled) { transform: scale(.96); background: var(--s2); }
.sel-act:disabled { opacity: .38; }
.sel-act.danger, .sel-act.danger .ic { color: var(--danger); }

/* ---- playlist editor */
.pe .edit-art { display: grid; place-items: center; }
.pe > .link-btn { align-self: center; margin-top: -8px; }
.pe-desc { resize: vertical; min-height: 64px; font: inherit; line-height: 1.5; }
.pe-tools { display: flex; flex-wrap: wrap; gap: 8px; }
.pe .section-head { margin: 4px 2px 0; font-size: 13px; }
.pe-list { display: flex; flex-direction: column; gap: 2px; }
.pe-row {
  display: flex; align-items: center; gap: 10px; padding: 6px 4px; border-radius: var(--r-sm); background: transparent;
  transition: background .16s var(--ease), box-shadow .16s var(--ease), transform .16s var(--ease);
}
.pe-row .art { width: 42px; height: 42px; flex: none; }
.pe-row .row-text { flex: 1; min-width: 0; }
.pe-row.lifting { background: var(--s2); box-shadow: 0 10px 30px rgb(0 0 0 / .45); transform: scale(1.02); position: relative; z-index: 1; }
.pe-handle { touch-action: none; cursor: grab; color: var(--ink-3); }
.pe-row.lifting .pe-handle { cursor: grabbing; color: var(--brand-ink); }

/* ---- Replay */
.replay .chips { margin-inline: 0; padding-inline: 0; }
.rp-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 6px 0 22px; }
.rp-stat { display: flex; flex-direction: column; gap: 2px; padding: 14px 16px; border-radius: var(--r-lg); background: var(--s1); }
.rp-stat b { font-size: 26px; font-weight: 700; font-variant-numeric: tabular-nums; }
.rp-stat span { color: var(--ink-2); font-size: 13px; }
.rp-stat.big { grid-column: 1 / -1; background: linear-gradient(135deg, var(--brand-24), var(--s1)); }
.rp-stat.big b { font-size: 46px; color: var(--brand-ink); line-height: 1.1; }
.rp-h { font-size: 17px; font-weight: 650; margin: 18px 2px 8px; }
.rp-list { list-style: none; display: flex; flex-direction: column; gap: 4px; }
.rp-list li { display: flex; align-items: center; gap: 12px; padding: 6px 4px; }
.rp-list .art { width: 46px; height: 46px; flex: none; }
.rp-list .row-text { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.rp-rank { width: 22px; text-align: center; font-weight: 700; color: var(--brand-ink); font-variant-numeric: tabular-nums; }
.rp-n { color: var(--ink-2); font-size: 13px; font-variant-numeric: tabular-nums; }
.rp-share { margin: 24px 0 calc(8px + var(--safe-b)); }

/* ---- settings card */
.lt-section { display: flex; flex-direction: column; gap: 18px; }
.lt-section .setting-line { flex-direction: column; align-items: stretch; gap: 10px; }
.lt-section .setting-line + .setting-line { padding-top: 16px; border-top: 1px solid var(--hair); }
.lt-acts { display: flex; flex-wrap: wrap; gap: 8px; }

/* ---- drop overlay (desktop drag & drop) */
.drop-overlay {
  position: fixed; inset: 0; z-index: 200; display: grid; place-items: center; pointer-events: none;
  background: rgb(6 6 8 / .72); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
}
.drop-overlay[hidden] { display: none; }
.drop-box {
  display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 36px 48px; text-align: center;
  border: 2px dashed var(--brand); border-radius: var(--r-xl); background: var(--brand-12);
}
.drop-box .ic { width: 40px; height: 40px; color: var(--brand-ink); }
.drop-box b { font-size: 18px; }
.drop-box small { color: var(--ink-2); }
