.upload .fields { display: flex; gap: 10px; margin-bottom: 12px; flex-wrap: wrap; }
.upload .fields input { flex: 1; min-width: 190px; }

.drop {
  border: 1.5px dashed var(--line);
  border-radius: var(--radius);
  padding: 26px;
  text-align: center;
  display: grid;
  gap: 6px;
  background: var(--panel-2);
  transition: border-color .15s, background .15s;
}
.drop.over { border-color: var(--accent); background: #241d10; }
.link { color: var(--accent); cursor: pointer; text-decoration: underline; }

.progress {
  height: 6px;
  background: var(--panel-2);
  border-radius: 999px;
  overflow: hidden;
  margin-top: 12px;
}
.progress > div { height: 100%; width: 0; background: var(--accent); transition: width .2s; }

.stages { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 12px; }
.stage {
  font-size: 11px;
  font-family: var(--mono);
  padding: 2px 9px;
  border-radius: 999px;
  border: 1px solid var(--line);
  color: var(--dimmer);
}
.stage.on   { color: var(--accent); border-color: var(--accent-dim); background: #241d10; }
.stage.done { color: var(--leaf);   border-color: #33472c; background: #1a2417; }
.stage.bad  { color: var(--clay);   border-color: #4d2b2a; background: #251717; }

.status { margin-top: 10px; font-size: 13px; min-height: 20px; }
.status.bad { color: var(--clay); }
.status.ok  { color: var(--leaf); }
.upload button { margin-top: 12px; }

.agent-dot {
  display: inline-block;
  width: 9px; height: 9px;
  border-radius: 3px;
  margin-right: 8px;
  vertical-align: baseline;
}
.rating { font-weight: 600; }
.band { color: var(--dimmer); font-size: 11px; }
.spark { vertical-align: middle; }
#kwrap input { vertical-align: middle; width: 120px; }
tr.moved { animation: flash .9s ease-out; }
@keyframes flash { from { background: #2a2313; } to { background: transparent; } }

/* Closest finishes: the matches actually worth opening. */
.notable { display: grid; gap: 2px; }
.notable-row {
  display: grid;
  grid-template-columns: 1fr auto 1fr auto;
  align-items: center;
  gap: 12px;
  padding: 7px 10px;
  border-radius: 7px;
  color: var(--fg);
  font-size: 13px;
}
.notable-row:hover { background: var(--panel-2); text-decoration: none; }
.notable-row .side { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--dim); }
.notable-row .side.right { text-align: right; }
.notable-row .side.won { color: var(--fg); font-weight: 600; }
.notable-row .score { font-size: 12px; font-variant-numeric: tabular-nums; color: var(--dim); }
.notable-row .score b { color: var(--fg); font-weight: 500; }
.notable-row .margin { font-size: 11px; color: var(--accent); min-width: 72px; text-align: right; }
