/* ── Discover / Tags ── */
.tag-presets {
  display: flex; align-items: center; flex-wrap: wrap; gap: 10px;
  margin-bottom: 20px; padding-bottom: 18px;
  border-bottom: 1px solid var(--border);
}
.tag-presets-label {
  font-size: 12px; font-weight: 700; letter-spacing: .06em;
  text-transform: uppercase; color: var(--text-dim); margin-right: 4px;
}
.tag-chip-preset {
  background: var(--accent-dim); border-color: var(--accent);
  color: var(--accent);
}
.tag-chip-preset:hover { box-shadow: 0 0 16px rgba(162,230,64,.18); }
.tag-cloud { display: flex; flex-wrap: wrap; gap: 10px; }
.tag-chip {
  background: var(--bg-card); border: 1px solid var(--border);
  color: var(--text); padding: 10px 20px; border-radius: 24px;
  cursor: pointer; font-size: 14px; transition: all var(--transition);
  font-family: inherit; font-weight: 500;
}
.tag-chip:hover {
  border-color: var(--accent); color: var(--accent);
  background: var(--accent-dim);
  box-shadow: 0 0 16px rgba(162,230,64,.1);
}
.tag-chip .tag-count { font-size: 11px; color: var(--text-dim); margin-left: 8px; font-weight: 400; }
.tag-detail-header { display: flex; align-items: center; gap: 14px; margin-bottom: 24px; }
.tag-back-btn {
  background: none; border: 1px solid var(--border); color: var(--text);
  padding: 8px 16px; border-radius: 20px; cursor: pointer; font-size: 13px;
  font-family: inherit; font-weight: 500; transition: all var(--transition);
}
.tag-back-btn:hover { border-color: var(--accent); color: var(--accent); }

/* ── Spotify Library Tabs ── */
.sp-tabs {
  display: flex; gap: 8px; margin-bottom: 24px; overflow-x: auto;
  -webkit-overflow-scrolling: touch; scrollbar-width: none;
}
.sp-tabs::-webkit-scrollbar { display: none; }
.sp-tab {
  padding: 10px 22px; border-radius: 50px; border: none; cursor: pointer;
  font-size: 14px; font-weight: 600; white-space: nowrap;
  background: var(--bg-elevated); color: var(--text-muted);
  transition: all .2s ease;
}
.sp-tab:hover { background: var(--bg-card); color: var(--text); }
.sp-tab.active { background: var(--accent); color: #000; }

/* Muted one-line subtitle under a page/sub-view heading. */
.page-subtitle {
  font-size: 13px; color: var(--text-muted); margin: -12px 0 20px;
}

/* Header row for a sub-view that pairs a title with its own secondary nav
   (e.g. Spotify sub-view inside the Library tabs). Keeps the sub-tabs
   visually anchored to *this* section's heading instead of reading as a
   second full-width tab bar stacked under the top-level Library tabs. */
.sp-header {
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: 16px; flex-wrap: wrap; margin-bottom: 20px;
}
.sp-header .page-title { margin-bottom: 2px; }
.sp-header .page-subtitle { margin: 0; }

/* Secondary sub-navigation: nested inside a page that already has peer nav.
   Rendered as a compact segmented pill control (own pill "track" background,
   small selected pill inside) so it reads unmistakably as sub-nav, not a
   second row of primary tabs. */
.sp-tabs--sub {
  gap: 2px; margin-bottom: 0; flex-shrink: 0;
  padding: 3px; background: var(--bg-elevated); border: 1px solid var(--border);
  border-radius: 999px;
}
.sp-tabs--sub .sp-tab {
  padding: 5px 14px; border-radius: 999px; font-size: 12px; font-weight: 600;
  background: none; color: var(--text-muted); border-bottom: none;
}
.sp-tabs--sub .sp-tab:hover { background: var(--bg-card); color: var(--text); }
.sp-tabs--sub .sp-tab.active {
  background: var(--accent); color: #000; border-bottom: none;
}
.sp-section-title {
  font-size: 13px; font-weight: 600; color: var(--text-muted);
  text-transform: uppercase; letter-spacing: 1px; margin-bottom: 16px;
}

/* ── Playlist Detail ──
   One hero, four pages: artist, album, playlist from search, library playlist.
   The widest of them carries seven buttons, so the actions get a line of their
   own (flex-basis: 100%) instead of a column squeezed next to the title. Turning
   that column into a row IN PLACE overflows 1024 px instead: measured 1027 px on
   an album hero and 1167 px on a library playlist, which carries seven buttons.
   flex-shrink: 1 alone does not help either — the title collapses to 0 px before
   the buttons give up any width. */
.playlist-hero {
  display: flex; gap: 20px; align-items: flex-end; flex-wrap: wrap;
  margin-bottom: 24px;
  padding: 24px; background: var(--bg-card); border-radius: 16px;
  border: 1px solid var(--border);
}
.playlist-hero-img {
  width: 100px; height: 100px; border-radius: 12px; object-fit: cover;
  box-shadow: 0 4px 20px rgba(0,0,0,.4); flex-shrink: 0;
}
/* The big cover is desktop-only on purpose: the phone layout is already right
   and lives in responsive.css, which this batch must not open. */
@media (min-width: 641px) {
  .playlist-hero-img { width: 180px; height: 180px; }
}
.playlist-hero-info { flex: 1; min-width: 0; }
.playlist-hero-info h2 { font-size: 22px; font-weight: 700; letter-spacing: -0.3px; }
.playlist-hero-info p { color: var(--text-muted); font-size: 14px; margin-top: 4px; }
.playlist-hero-desc { white-space: pre-line; line-height: 1.4; }
.playlist-hero-actions {
  display: flex; flex-direction: row; align-items: center; flex-wrap: wrap;
  gap: 10px; flex-basis: 100%; flex-shrink: 1;
}
/* Icons inside hero buttons sit on the text baseline row, not above it. */
.hero-ico { vertical-align: -2px; margin-right: 6px; }

/* Shared hero action button classes (replace per-button inline styles). */
.btn-hero-primary { width: auto; padding: 12px 28px; background: var(--accent); color: #000; }
.btn-hero-secondary { width: auto; padding: 12px 28px; background: var(--bg-elevated); color: var(--text); border: 1px solid var(--border); }
.btn-hero-danger { width: auto; padding: 12px 28px; background: var(--red); color: #fff; }

/* ── Imported playlists (Library → Downloaded) ──
   Its own section under the Navidrome grid, separated by a rule so the two
   grids never read as one list: these playlists are NOT in Navidrome, they
   only stream, and the badge on each card says so at a glance. */
.imported-section {
  margin-top: 32px; padding-top: 24px; border-top: 1px solid var(--border);
}
.imported-title {
  font-size: 16px; font-weight: 700; letter-spacing: -0.2px;
  display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap;
}
.imported-count { font-size: 12px; font-weight: 500; color: var(--text-dim); }
.imported-sub {
  font-size: 12px; color: var(--text-muted); line-height: 1.5;
  margin: 5px 0 16px; max-width: 560px;
}
/* Top-RIGHT on purpose: the kebab (.card .kebab-btn) owns top-left. */
.imported-badge {
  position: absolute; top: 8px; right: 8px; z-index: 4;
  background: var(--accent-dim); border: 1px solid var(--accent); color: var(--accent);
  font-size: 10px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase;
  padding: 3px 8px; border-radius: 999px; pointer-events: none;
}
.imported-card:hover { border-color: var(--accent); }

/* ── "Save to Library" on an imported playlist ──
   Lives in the detail hero's note (#plDetailNote) and in the search banner's
   action row, so it must wrap rather than widen its host. */
.import-save {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-top: 8px;
}
.import-banner-actions .import-save { margin-top: 0; }
.import-save-hint {
  font-size: 11px; color: var(--text-muted); line-height: 1.4;
  flex: 1 1 180px; min-width: 0;
}
.import-save-btn { border-color: var(--accent); color: var(--accent); }
.import-save-btn:disabled { cursor: default; }
.import-save-btn--done {
  background: var(--accent-dim); border-color: var(--accent);
  color: var(--accent); opacity: .9;
}

@media (max-width: 640px) {
  .imported-section { margin-top: 24px; padding-top: 18px; }
  .import-save-btn { flex: 1 1 auto; text-align: center; }
}

/* ── Empty state ── */
.empty-state {
  text-align: center; padding: 60px 20px; color: var(--text-muted);
}
.empty-state p { font-size: 15px; }

/* Podcasts page */
.podcast-show-card {
  display: flex; align-items: center; justify-content: space-between;
  background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 16px 20px; margin-bottom: 10px; cursor: pointer; transition: background 0.15s;
}
.podcast-show-card:hover { background: var(--bg-elevated); }
.podcast-show-info { flex: 1; min-width: 0; }
.podcast-show-name { font-weight: 700; font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.podcast-show-meta { font-size: 12px; color: var(--text-muted); margin-top: 4px; }
.podcast-ep-row {
  display: flex; align-items: center; gap: 12px;
  background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius-sm);
  padding: 12px 16px; margin-bottom: 8px;
}
.podcast-ep-row .ep-name { flex: 1; min-width: 0; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.podcast-ep-row .ep-size { font-size: 12px; color: var(--text-muted); white-space: nowrap; }
.podcast-ep-row .ep-date { font-size: 12px; color: var(--text-muted); white-space: nowrap; }
.btn-delete-ep, .btn-delete-show {
  background: none; border: 1px solid var(--border); border-radius: var(--radius-sm);
  color: var(--text-muted); font-size: 12px; padding: 4px 10px; cursor: pointer; white-space: nowrap;
}
.btn-delete-ep:hover, .btn-delete-show:hover { border-color: #e74c3c; color: #e74c3c; }
.btn-check-new, .btn-dl-missing {
  background: none; border: 1px solid var(--accent); border-radius: var(--radius-sm);
  color: var(--accent); font-size: 12px; padding: 4px 10px; cursor: pointer; white-space: nowrap;
}
.btn-check-new:hover, .btn-dl-missing:hover { background: var(--accent); color: #000; }
.missing-ep-row {
  display: flex; align-items: center; gap: 12px;
  background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius-sm);
  padding: 12px 16px; margin-bottom: 8px;
}
.missing-ep-row .ep-name { flex: 1; min-width: 0; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.missing-ep-row .ep-date { font-size: 12px; color: var(--text-muted); white-space: nowrap; }
.missing-section-header { font-size: 14px; font-weight: 600; color: var(--accent); margin: 20px 0 10px; display: flex; align-items: center; justify-content: space-between; }
.missing-section-header .missing-count { font-weight: 400; font-size: 12px; color: var(--text-muted); }
.podcast-ep-row .ep-check { width: 16px; height: 16px; accent-color: var(--accent); cursor: pointer; flex-shrink: 0; }
.podcast-sub-card {
  display: flex; align-items: center; gap: 12px;
  background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 12px 16px; margin-bottom: 8px;
}
.podcast-sub-card img { width: 48px; height: 48px; border-radius: 8px; object-fit: cover; flex-shrink: 0; }
.podcast-sub-info { flex: 1; min-width: 0; }
.podcast-sub-name { font-weight: 600; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.podcast-sub-meta { font-size: 12px; color: var(--text-muted); margin-top: 2px; }
.podcast-sub-actions { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.podcast-sub-actions select { background: var(--bg-elevated); color: var(--text-primary); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 4px 6px; font-size: 12px; }
.btn-unsub { background: none; border: 1px solid var(--border); border-radius: var(--radius-sm); color: var(--text-muted); font-size: 12px; padding: 4px 10px; cursor: pointer; }
.btn-unsub:hover { border-color: #e74c3c; color: #e74c3c; }

/* ── Sbírky jako řádky (knihovna) ──
   Mřížka je pro hledání, kde obal je ta položka; knihovna je seznam věcí, které
   uživatel zná a hledá v nich podle jména. Stejné rozdělení má Spotify. */
.coll-list { display: flex; flex-direction: column; gap: 2px; }
.coll-row {
  display: flex; align-items: center; gap: 12px;
  padding: 8px 12px; border-radius: 8px; cursor: pointer;
  position: relative; transition: background .15s;
}
.coll-row:hover { background: var(--bg-elevated); }
.coll-thumb {
  width: 48px; height: 48px; flex-shrink: 0; border-radius: 6px;
  object-fit: cover; background: var(--bg-elevated);
  display: flex; align-items: center; justify-content: center;
  font-size: 20px; color: var(--text);
}
.coll-list-round .coll-thumb { border-radius: 50%; }
.coll-info { min-width: 0; flex: 1; }
.coll-title {
  font-size: 15px; font-weight: 600; color: var(--text);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.coll-meta {
  font-size: 12px; color: var(--text-muted); margin-top: 2px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
/* Kebab sedí v řádku, ne absolutně nad obalem jako na kartě. */
.coll-row .kebab-btn {
  position: static; width: 32px; height: 32px; flex-shrink: 0;
  opacity: 1; transform: none;
}
.coll-row .fav-new-badge,
.coll-row .fav-auto-dl-badge {
  position: static; flex-shrink: 0; margin-left: 4px;
}
.skeleton-coll { height: 64px; border-radius: 8px; margin-bottom: 2px; }

/* ── Library → Mixes ──
   Every control is visible without hover: a tablet at 1024 px gets the desktop
   rules and has no hover. Rows wrap their actions under the text on a phone. */
.mix-section { margin-bottom: 32px; }
.mix-section-head {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  flex-wrap: wrap; margin: 0 0 12px;
}
.mix-section-title { font-size: 15px; font-weight: 600; margin: 0; color: var(--text-muted); }
.mix-section-tools { display: flex; align-items: center; gap: 10px; }
.mix-total { font-size: 13px; color: var(--text-muted); }
.mix-search-form { display: flex; gap: 8px; margin: 14px 0 12px; }
.mix-search-form input {
  flex: 1; min-width: 0; padding: 10px 14px; border: 1px solid var(--border);
  border-radius: var(--radius-sm); background: var(--bg-elevated); color: var(--text);
  font-family: inherit; font-size: 15px; outline: none;
}
.mix-search-form input:focus { border-color: var(--accent); }
.mix-filters { display: flex; flex-wrap: wrap; gap: 10px 16px; align-items: center; margin-bottom: 10px; }
.mix-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.mix-chip {
  background: var(--bg-card); border: 1px solid var(--border); color: var(--text-muted);
  padding: 6px 12px; border-radius: 16px; font-family: inherit; font-size: 12px; cursor: pointer;
}
.mix-chip.active { border-color: var(--accent); color: var(--accent); background: var(--accent-dim); }
.mix-selects { display: flex; flex-wrap: wrap; gap: 8px 12px; }
.mix-selects label { font-size: 12px; color: var(--text-muted); display: flex; align-items: center; gap: 6px; }
.mix-selects select, .mix-follow-opts select {
  background: var(--bg-elevated); color: var(--text); border: 1px solid var(--border);
  border-radius: var(--radius-sm); padding: 5px 6px; font-size: 12px; font-family: inherit;
}
.mix-status { margin-bottom: 10px; }
.mix-count { font-size: 12px; color: var(--text-muted); }
.mix-err { font-size: 12px; color: var(--red); margin-top: 4px; }
.mix-hint { font-size: 13px; color: var(--text-muted); line-height: 1.5; margin: 4px 0; }
.mix-empty { padding: 30px 10px; }
.mix-linkbtn {
  background: none; border: none; padding: 0; margin-left: 6px; color: var(--accent);
  font-family: inherit; font-size: 12px; font-weight: 600; cursor: pointer; text-decoration: underline;
}
.mix-list { display: flex; flex-direction: column; gap: 6px; }
.mix-row {
  display: flex; align-items: center; gap: 12px; padding: 10px 12px;
  background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius-sm);
  min-width: 0;
}
.mix-thumb, .mix-avatar {
  width: 56px; height: 56px; flex-shrink: 0; border-radius: 8px; object-fit: cover;
  background: var(--bg-elevated); display: flex; align-items: center; justify-content: center;
  color: var(--text-muted); font-size: 22px;
}
.mix-avatar { width: 44px; height: 44px; border-radius: 50%; }
.mix-thumb--empty, .mix-avatar--empty { border: 1px solid var(--border); }
.mix-info { flex: 1; min-width: 0; }
.mix-title {
  font-size: 14px; font-weight: 600; color: var(--text);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.mix-title a { color: inherit; text-decoration: none; }
.mix-title a:hover { text-decoration: underline; }
.mix-meta { font-size: 12px; color: var(--text-muted); margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mix-badges { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
.mix-q, .mix-src, .mix-owned {
  font-size: 11px; font-weight: 600; padding: 2px 8px; border-radius: 10px; white-space: nowrap;
  border: 1px solid var(--border); color: var(--text-muted);
}
.mix-q--hi { color: #000; background: var(--accent); border-color: var(--accent); }
.mix-q--good { color: var(--accent); border-color: var(--accent); }
.mix-q--ok { color: var(--text); border-color: var(--border-hover); }
.mix-q--low { color: var(--red); border-color: var(--red); }
.mix-q-typ { font-weight: 400; margin-left: 4px; opacity: .8; }
.mix-owned { color: var(--accent); }
.mix-also { font-size: 11px; color: var(--text-dim); margin-top: 4px; }
.mix-actions { display: flex; flex-wrap: wrap; gap: 6px; flex-shrink: 0; justify-content: flex-end; }
.mix-actions .import-btn { padding: 7px 12px; font-size: 12px; }
.mix-actions .import-btn:disabled { opacity: .55; cursor: default; }
.mix-follow {
  background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 12px 14px; margin-bottom: 8px;
}
.mix-follow-main { display: flex; align-items: center; gap: 12px; min-width: 0; }
.mix-follow-opts { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; margin-top: 10px; }
.mix-toggle { font-size: 12px; color: var(--text); display: flex; align-items: center; gap: 6px; cursor: pointer; }
.mix-toggle input { width: 16px; height: 16px; accent-color: var(--accent); }
.mix-uploads { display: flex; flex-direction: column; gap: 6px; margin-top: 10px; }
.mix-uploads .mix-row { background: var(--bg-elevated); }
.mix-dj { margin-bottom: 16px; }
.mix-dj-head { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; margin: 0 2px 6px; }
.mix-dj-name { font-weight: 700; font-size: 14px; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mix-dj-meta { font-size: 12px; color: var(--text-muted); white-space: nowrap; }
.mix-lib-row + .mix-lib-row { margin-top: 6px; }

@media (max-width: 640px) {
  .mix-row, .mix-follow-main { flex-wrap: wrap; }
  .mix-row .mix-info, .mix-follow-main .mix-info { flex: 1 1 calc(100% - 80px); }
  .mix-row .mix-actions, .mix-follow-main .mix-actions { width: 100%; justify-content: flex-start; }
  .mix-thumb { width: 48px; height: 48px; }
}

/* ── mixcut: cut a clip out of a downloaded set (static/js/mixcut.js) ── */
.mixcut-overlay { position: fixed; inset: 0; z-index: 300; display: flex; flex-direction: column; background: #07070b; color: var(--text, #eee); }
.mixcut-head { display: flex; align-items: center; gap: 12px; padding: 10px 16px; border-bottom: 1px solid var(--border, #2a2a3a); }
.mixcut-headtext { flex: 1; min-width: 0; }
.mixcut-h-title { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mixcut-h-sub { font-size: 12px; color: var(--text-muted, #999); }
.mixcut-close { width: 44px; height: 44px; font-size: 28px; line-height: 1; background: none; border: 0; color: inherit; cursor: pointer; }
.mixcut-body { flex: 1; overflow-y: auto; padding: 12px 16px 32px; max-width: 1100px; width: 100%; margin: 0 auto; box-sizing: border-box; }
.mixcut-status { font-size: 13px; color: var(--text-muted, #999); padding: 6px 0; }
.mixcut-wrap { position: relative; width: 100%; background: #101018; border-radius: 8px; overflow: hidden; margin-bottom: 8px; }
.mixcut-canvas { display: block; width: 100%; touch-action: none; cursor: crosshair; }
.mixcut-detailbar { display: flex; align-items: center; justify-content: space-between; margin: 6px 0; }
.mixcut-label { font-size: 12px; color: var(--text-muted, #999); text-transform: uppercase; letter-spacing: .04em; }
.mixcut-bpm { text-transform: none; }
.mixcut-transport, .mixcut-nudge { display: flex; flex-wrap: wrap; gap: 8px; margin: 8px 0; align-items: center; }
.mixcut-btn { min-height: 40px; padding: 0 14px; border-radius: 8px; border: 1px solid var(--border, #2a2a3a); background: var(--bg-elevated, #1c1c2e); color: inherit; font: inherit; font-size: 14px; cursor: pointer; }
.mixcut-btn:hover { border-color: var(--accent, #1db954); }
.mixcut-btn:disabled { opacity: .45; cursor: default; }
.mixcut-btn--sm { min-height: 36px; padding: 0 10px; font-size: 13px; }
.mixcut-btn--primary { background: var(--accent, #1db954); color: #000; border-color: transparent; font-weight: 600; }
.mixcut-btn--danger { color: #ff6b6b; }
.mixcut-toggle.on { background: var(--accent-dim, rgba(29,185,84,.18)); border-color: var(--accent, #1db954); color: var(--accent, #1db954); }
.mixcut-readout { display: flex; flex-wrap: wrap; gap: 18px; font-size: 14px; margin: 10px 0 4px; font-variant-numeric: tabular-nums; }
.mixcut-hint { min-height: 18px; font-size: 13px; color: var(--text-muted, #999); margin-bottom: 8px; }
.mixcut-hint--bad { color: #ff9f43; }
.mixcut-form { display: grid; gap: 8px; margin: 8px 0 16px; }
.mixcut-form label { display: grid; gap: 4px; font-size: 12px; color: var(--text-muted, #999); }
.mixcut-form input { min-height: 42px; padding: 0 12px; border-radius: 8px; border: 1px solid var(--border, #2a2a3a); background: var(--bg-input, #1a1a2a); color: var(--text, #eee); font: inherit; font-size: 16px; }
.mixcut-err { color: #ff6b6b; font-size: 13px; min-height: 0; }
.mixcut-save { justify-self: start; }
.mixcut-clips { border-top: 1px solid var(--border, #2a2a3a); padding-top: 12px; }
.mixcut-empty { font-size: 13px; color: var(--text-muted, #999); }
.mixcut-clip { display: flex; align-items: center; gap: 10px; padding: 8px 4px; border-bottom: 1px solid var(--border, #2a2a3a); cursor: pointer; flex-wrap: wrap; }
.mixcut-section .mixcut-clip { cursor: default; }
.mixcut-clip-dot { width: 8px; height: 8px; border-radius: 50%; flex: none; }
.mixcut-clip-main { flex: 1 1 160px; min-width: 0; display: grid; }
.mixcut-clip-title { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mixcut-clip-meta, .mixcut-group-sub, .mixcut-count { font-size: 12px; color: var(--text-muted, #999); }
.mixcut-clip-actions { display: flex; gap: 6px; flex-wrap: wrap; }
.mixcut-section { margin-top: 24px; }
.mixcut-sec-h { margin: 0 0 8px; font-size: 18px; }
.mixcut-group { margin-bottom: 14px; }
.mixcut-group-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-bottom: 4px; }
.mixcut-group-title { font-weight: 600; display: grid; }
@media (max-width: 640px) { .mixcut-btn { padding: 0 10px; } .mixcut-body { padding: 10px 12px 28px; } }

.mixcut-readout label { display: inline-flex; align-items: center; gap: 6px; }
.mixcut-time { width: 6.2em; padding: 6px 8px; border-radius: 8px; border: 1px solid var(--border, #2a2a3a);
  background: var(--bg-input, #14141f); color: inherit; font: inherit; font-weight: 700; font-variant-numeric: tabular-nums; }
.mixcut-time:focus { outline: 2px solid var(--accent, #a3e635); outline-offset: 1px; }
/* a source the server refuses (e.g. a track that is not in the user's own library) is final: say so plainly */
.mixcut-status--bad { color: var(--danger, #ff6b6b); font-weight: 600; }

/* ── Library → Manager (static/js/plmanager.js) ── */
.plm-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 14px; }
.plm-sub { margin: 4px 0 0; }
.plm-mode { display: flex; gap: 6px; }
.plm-panes { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.plm-pane {
  min-width: 0; display: flex; flex-direction: column;
  background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius-sm);
}
.plm-pane-head { display: flex; gap: 8px; padding: 10px 10px 6px; }
.plm-select {
  flex: 1; min-width: 0; padding: 9px 10px; border: 1px solid var(--border); border-radius: var(--radius-xs);
  background: var(--bg-elevated); color: var(--text); font: inherit; font-size: 14px; font-weight: 600;
}
.plm-play {
  flex: none; width: 40px; height: 40px; border: none; border-radius: 50%;
  background: var(--accent); color: #000; font-size: 15px; cursor: pointer;
}
.plm-pane-tools { display: flex; align-items: center; gap: 8px; padding: 0 10px 8px; }
.plm-filter {
  flex: 1; min-width: 0; padding: 7px 10px; border: 1px solid var(--border); border-radius: var(--radius-xs);
  background: var(--bg-input); color: var(--text); font: inherit; font-size: 13px; outline: none;
}
.plm-count { flex: none; font-size: 12px; color: var(--text-muted); }
.plm-list {
  height: calc(100vh - 330px); min-height: 280px; overflow-y: auto; overscroll-behavior: contain;
  border-top: 1px solid var(--border); padding: 4px 0; position: relative;
}
.plm-note { padding: 24px 14px; text-align: center; color: var(--text-muted); font-size: 13px; }
.plm-row {
  display: flex; align-items: center; gap: 8px; padding: 5px 6px 5px 2px; cursor: pointer;
  border-top: 2px solid transparent; border-bottom: 2px solid transparent;
  user-select: none; -webkit-user-select: none; -webkit-touch-callout: none;
}
.plm-row:hover { background: var(--bg-elevated); }
.plm-handle {
  flex: none; width: 32px; height: 40px; display: flex; align-items: center; justify-content: center;
  color: var(--text-dim); cursor: grab; touch-action: none; font-size: 15px;
}
.plm-row:hover .plm-handle { color: var(--text-muted); }
.plm-num { flex: none; width: 26px; text-align: right; font-size: 12px; color: var(--text-dim); font-variant-numeric: tabular-nums; }
.plm-thumb { flex: none; width: 36px; height: 36px; border-radius: 4px; object-fit: cover; background: var(--bg-elevated); -webkit-user-drag: none; }
.plm-info { flex: 1; min-width: 0; }
.plm-title, .plm-artist { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.plm-title { font-size: 14px; color: var(--text); }
.plm-artist { font-size: 12px; color: var(--text-muted); }
.plm-dur { flex: none; font-size: 12px; color: var(--text-muted); font-variant-numeric: tabular-nums; }
.plm-more {
  flex: none; width: 32px; height: 36px; border: none; background: none; color: var(--text-muted);
  font-size: 18px; cursor: pointer; border-radius: var(--radius-xs);
}
.plm-more:hover { background: var(--bg-card); color: var(--text); }
.plm-now .plm-title { color: var(--accent); font-weight: 600; }
.plm-dragging { opacity: .35; }
.plm-drop-before { border-top-color: var(--accent); }
.plm-drop-after { border-bottom-color: var(--accent); }
.plm-list.plm-drop-into { box-shadow: inset 0 0 0 2px var(--accent); }
.plm-ghost {
  position: fixed; left: 0; top: 0; z-index: 10001; pointer-events: none;
  background: var(--bg-elevated); border: 1px solid var(--accent); border-radius: var(--radius-xs);
  box-shadow: 0 8px 24px rgba(0,0,0,.5); opacity: .95;
}
.plm-ghost .plm-more { display: none; }
body.plm-drag-active, body.plm-drag-active * { cursor: grabbing !important; }
#pagePlManager.plm-busy .plm-count::after { content: ' · saving…'; color: var(--accent); }
@media (hover: none) {
  .plm-handle { color: var(--text-muted); }
}
@media (max-width: 640px) {
  .plm-panes { grid-template-columns: 1fr; gap: 10px; }
  .plm-sub { font-size: 12px; }
  .plm-list { height: var(--plm-list-h, 34vh); min-height: 150px; }
  body.plm-active #feedbackFab { display: none; }
  .plm-head { margin-bottom: 10px; align-items: center; }
  .plm-sub { display: none; }
  .plm-pane-head { padding: 8px 8px 6px; }
  .plm-pane-tools { padding: 0 8px 6px; }
  .plm-select { padding: 7px 8px; }
  .plm-play { width: 36px; height: 36px; }
  .plm-filter { padding: 5px 8px; }
  .plm-num { display: none; }
}
