body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "PingFang SC",
    "Hiragino Sans GB", "Microsoft YaHei", Arial, sans-serif;
  margin: 0;
  background: #f5f7fb;
  color: #0f172a;
}

.wrap {
  max-width: 1180px;
  margin: 0 auto;
  padding: 20px 16px 40px;
}

.wrap > h1 {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.wrap::before {
  content: "";
  display: block;
  height: 8px;
  width: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, #60a5fa, #34d399);
  margin-bottom: 14px;
}

h1 {
  font-size: 20px;
  margin: 0 0 12px;
}

.tabs {
  display: flex;
  gap: 10px;
  margin: 12px 0 16px;
  flex-wrap: wrap;
}

.tab {
  border: 1px solid #e2e8f0;
  background: rgba(255, 255, 255, 0.9);
  padding: 8px 12px;
  border-radius: 999px;
  cursor: pointer;
  color: #334155;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

.tab.active {
  border-color: rgba(37, 99, 235, 0.25);
  color: #1d4ed8;
  background: rgba(219, 234, 254, 0.9);
}

.panel {
  display: none;
}

.panel.active {
  display: block;
}

.panel.active > table {
  box-shadow: 0 10px 22px rgba(15, 23, 42, 0.06);
}

.toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 8px 0 10px;
  gap: 10px;
  flex-wrap: wrap;
}

.pager {
  display: flex;
  align-items: center;
  gap: 8px;
}

button {
  border: 1px solid #e2e8f0;
  background: #ffffff;
  padding: 7px 12px;
  border-radius: 10px;
  cursor: pointer;
  color: #334155;
  transition: background 120ms ease, border-color 120ms ease, transform 60ms ease;
}

button:hover {
  background: #f8fafc;
  border-color: #cbd5e1;
}

button:active {
  transform: translateY(1px);
}

button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

.btn-primary {
  background: #2563eb;
  border-color: rgba(37, 99, 235, 0.5);
  color: #ffffff;
}

.btn-primary:hover {
  background: #1d4ed8;
  border-color: rgba(29, 78, 216, 0.6);
}

.h4-actions {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-left: 10px;
}

#ssq-search {
  background: #2563eb;
  border-color: rgba(37, 99, 235, 0.5);
  color: #ffffff;
}

#ssq-search:hover {
  background: #1d4ed8;
  border-color: rgba(29, 78, 216, 0.6);
}

.pagesize {
  display: flex;
  align-items: center;
  gap: 8px;
}

.filters,
.search-box {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.filters input,
.search-box input {
  width: 110px;
  padding: 6px 8px;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  background: #fff;
  font-size: 14px;
  color: #0f172a;
}

.filters input:focus,
.search-box input:focus,
select:focus {
  outline: none;
  border-color: rgba(37, 99, 235, 0.5);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
}

select {
  border: 1px solid #e2e8f0;
  background: #fff;
  padding: 7px 10px;
  border-radius: 10px;
  color: #0f172a;
}

table {
  width: 100%;
  border-collapse: collapse;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  overflow: hidden;
}

th,
td {
  padding: 10px 8px;
  border-bottom: 1px solid #eef2f7;
  text-align: left;
  font-size: 14px;
}

th {
  background: #f8fafc;
  font-weight: 600;
  color: #334155;
}

tr:last-child td {
  border-bottom: 0;
}

tbody tr:hover td {
  background: #fbfdff;
}

.balls {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.ball {
  display: inline-flex;
  width: 28px;
  height: 28px;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  border: 1px solid rgba(15, 23, 42, 0.06);
}

.ball.red {
  background: rgba(239, 68, 68, 0.12);
  color: #b91c1c;
}

.ball.blue {
  background: rgba(59, 130, 246, 0.12);
  color: #1d4ed8;
}

.hint {
  margin-top: 10px;
  font-size: 12px;
  color: #64748b;
}

.hint strong {
  color: #0f172a;
}

.hint a {
  color: #2563eb;
  text-decoration: none;
}

.hint a:hover {
  text-decoration: underline;
}

.expanded {
  background: #fbfbfb;
}

.expanded .box {
  padding: 10px 8px 14px;
}

.expanded table {
  border-radius: 8px;
}

.expanded th,
.expanded td {
  font-size: 12px;
  padding: 8px 6px;
}

.rec-detail {
  background: #f8fafc;
}

.rec-detail h4 {
  margin: 12px 0 8px;
  font-size: 13px;
  color: #334155;
}

pre {
  margin: 0;
  padding: 12px;
  overflow: auto;
  font-size: 12px;
  line-height: 1.45;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
}
