:root {
  color-scheme: dark;
  --bg: #0b1020;
  --panel: #121a2f;
  --text: #e8ecff;
  --muted: #9aa4c0;
  --line: #243055;
  --accent: #6ea8fe;
  --good: #3ddc97;
  --bad: #ff7b7b;
  --warn: #ffd479;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  background: radial-gradient(1200px 800px at 20% 0%, #1a2550 0%, var(--bg) 55%);
  color: var(--text);
  min-height: 100vh;
}

.header {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  justify-content: space-between;
  padding: 28px 22px 10px;
  border-bottom: 1px solid var(--line);
}

h1 {
  margin: 0 0 6px;
  font-size: 22px;
  letter-spacing: 0.2px;
}

.sub {
  margin: 0;
  color: var(--muted);
  max-width: 720px;
  line-height: 1.45;
}

.banner {
  border: 1px solid var(--line);
  background: rgba(255, 180, 120, 0.08);
  color: var(--warn);
  padding: 10px 12px;
  border-radius: 10px;
  max-width: 520px;
  line-height: 1.35;
}

.panel {
  padding: 16px 22px 8px;
}

.row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.fileBtn input {
  display: none;
}

.fileBtn span,
button {
  border: 1px solid var(--line);
  background: var(--panel);
  color: var(--text);
  padding: 10px 12px;
  border-radius: 10px;
  cursor: pointer;
  font-weight: 600;
}

.fileBtn span {
  display: inline-block;
}

button.primary {
  border-color: rgba(110, 168, 254, 0.55);
  background: linear-gradient(180deg, rgba(110, 168, 254, 0.22), rgba(110, 168, 254, 0.08));
}

button.ghost {
  background: transparent;
}

button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.meta {
  margin-top: 10px;
  color: var(--muted);
  font-size: 13px;
}

.sep {
  margin: 0 6px;
}

.tableWrap {
  padding: 10px 22px 40px;
  overflow: auto;
}

table.grid {
  width: 100%;
  border-collapse: collapse;
  min-width: 1420px;
  border: 1px solid var(--line);
  border-radius: 12px;
  overflow: hidden;
}

th,
td {
  border-bottom: 1px solid var(--line);
  padding: 10px 10px;
  vertical-align: top;
  font-size: 13px;
}

th {
  text-align: left;
  color: var(--muted);
  font-weight: 700;
  background: rgba(18, 26, 47, 0.75);
  position: sticky;
  top: 0;
  z-index: 1;
}

.thSort {
  all: unset;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  color: inherit;
  font: inherit;
  font-weight: 700;
  text-align: left;
  max-width: 100%;
}

.thSort:hover {
  color: var(--text);
}

.thSort:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: 4px;
}

.sortInd {
  font-size: 10px;
  line-height: 1;
  min-width: 0.85em;
  opacity: 0.45;
}

th[aria-sort="ascending"] .sortInd,
th[aria-sort="descending"] .sortInd {
  opacity: 1;
}

tr:last-child td {
  border-bottom: none;
}

.mono {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 12px;
  white-space: nowrap;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 4px 8px;
  border-radius: 999px;
  border: 1px solid var(--line);
  color: var(--muted);
  font-weight: 700;
}

.pill.ok {
  border-color: rgba(61, 220, 151, 0.35);
  color: var(--good);
}

.pill.err {
  border-color: rgba(255, 123, 123, 0.35);
  color: var(--bad);
}

.pill.run {
  border-color: rgba(110, 168, 254, 0.35);
  color: var(--accent);
}

.fileName {
  max-width: 360px;
  word-break: break-word;
}
