/* ── Layout ─────────────────────────────────────────────────── */
.layout {
  display: grid;
  grid-template-columns: 272px 1fr;
  min-height: calc(100vh - 60px);
}

/* ── Sidebar ─────────────────────────────────────────────────── */
aside {
  background: var(--bg2);
  border-right: 1px solid var(--border);
  padding: var(--space-xl) var(--space-md);
  display: flex;
  flex-direction: column;
  gap: var(--space-xl);
  position: sticky;
  top: 60px;
  height: calc(100vh - 60px);
  overflow-y: auto;
}

/* Stats */
.stats-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.stat-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 14px 12px;
  transition: border-color var(--duration);
}
.stat-card:hover { border-color: var(--yellow); }
.stat-val {
  font-family: var(--font-title);
  font-size: 1.9rem;
  color: var(--yellow);
  line-height: 1;
  margin-bottom: 3px;
  letter-spacing: 0.05em;
}
.stat-label {
  font-size: 10px;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

/* Filters */
.filter-list { display: flex; flex-direction: column; gap: 2px; }
.filter-btn {
  background: transparent;
  color: var(--text-muted);
  padding: 8px 10px;
  border-radius: var(--radius-md);
  text-align: left;
  font-size: 13px;
  border: 1px solid transparent;
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  gap: 8px;
  transition: all var(--duration) var(--ease);
}
.filter-btn:hover { color: var(--text); background: var(--card); }
.filter-btn.active { color: var(--yellow); border-color: var(--border2); background: var(--card); }
.badge {
  font-size: 10px;
  font-weight: 700;
  background: var(--border);
  padding: 2px 7px;
  border-radius: 20px;
  min-width: 22px;
  text-align: center;
  flex-shrink: 0;
}
.filter-btn.active .badge { background: var(--yellow-dim); color: var(--yellow); }

/* ── Genre stats ─────────────────────────────────────────────── */
.genre-list { display: flex; flex-direction: column; gap: 6px; }

.genre-row {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
}
.genre-label {
  flex: 1;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.genre-bar-wrap {
  flex: 2;
  height: 4px;
  background: var(--border);
  border-radius: 2px;
  overflow: hidden;
}
.genre-bar {
  height: 100%;
  background: var(--yellow);
  border-radius: 2px;
  transition: width 0.4s var(--ease);
}
.genre-count {
  font-size: 10px;
  color: var(--text-dim);
  min-width: 20px;
  text-align: right;
  font-family: var(--font-mono);
}

/* Sidebar footer */
.sidebar-footer { margin-top: auto; }
.sidebar-footer button { width: 100%; }

/* ── Responsive ─────────────────────────────────────────────── */
@media (max-width: 900px) {
  .layout { grid-template-columns: 1fr; }
  aside   { display: none; }
}
