/* Page-specific rules only — theme fundamentals (colors, body, .app-header,
   .subtitle, main, .panel, .filter-bar, .filter-tab, .app-footer) live in the
   shared styles.css, loaded alongside this file. Don't redefine them here. */

.controls-panel {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.mode-toggle {
  display: inline-flex;
  background: var(--bg);
  border: 1px solid var(--panel-border);
  border-radius: var(--radius);
  padding: 3px;
  width: fit-content;
}
.mode-btn {
  background: transparent;
  border: 1px solid transparent;
  color: var(--text-dim);
  padding: 8px 18px;
  border-radius: 6px;
  font-size: 0.9rem;
  cursor: pointer;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}
.mode-btn.active {
  background: transparent;
  color: var(--text);
  border-color: var(--accent);
}

.rank-row {
  display: flex;
  align-items: center;
  gap: 10px;
}
.rank-row label {
  color: var(--text-dim);
  font-size: 0.85rem;
}
.rank-row select {
  background: var(--bg);
  border: 1px solid var(--panel-border);
  color: var(--text);
  padding: 6px 10px;
  border-radius: 6px;
  font-size: 0.9rem;
}

.filter-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}

#hero-search {
  background: var(--bg);
  border: 1px solid var(--panel-border);
  color: var(--text);
  padding: 6px 10px;
  border-radius: 6px;
  font-size: 0.85rem;
  flex: 1;
  min-width: 140px;
}

.platform-toggle {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--text-dim);
  font-size: 0.82rem;
  white-space: nowrap;
}

table {
  width: 100%;
  border-collapse: collapse;
}

th, td {
  text-align: left;
  padding: 9px 10px;
  border-bottom: 1px solid var(--panel-border);
  font-size: 0.88rem;
}

th.sortable {
  cursor: pointer;
  color: var(--text-dim);
  font-weight: 600;
  user-select: none;
  white-space: nowrap;
}
th.sortable:hover { color: var(--text); }
th.sortable.sort-active { color: var(--accent-2); }
th.num, td.num { text-align: right; }

.role-tag {
  font-size: 0.75rem;
  color: var(--text-dim);
}

.rate-pill {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 999px;
  font-variant-numeric: tabular-nums;
  font-weight: 600;
  font-size: 0.82rem;
}
.rate-good { background: rgba(63, 185, 80, 0.15); color: var(--good); }
.rate-warn { background: rgba(212, 167, 46, 0.15); color: var(--warn); }
.rate-bad  { background: rgba(212, 55, 46, 0.15); color: var(--bad); }

.sub-platform {
  color: var(--text-dim);
  font-size: 0.75rem;
  margin-top: 2px;
}

.source-note {
  color: var(--text-dim);
  font-size: 0.78rem;
  text-align: center;
  margin-top: 4px;
}

@media (max-width: 560px) {
  .filter-row { flex-direction: column; align-items: stretch; }
  #hero-search { width: 100%; }
}
