:root {
  color-scheme: dark;
  --bg: #090b0e;
  --surface: #101419;
  --surface-hover: #161b22;
  --line: #252b33;
  --text: #edf1f5;
  --muted: #96a0ad;
  --accent: #7dd3fc;
  --accent-strong: #38bdf8;
  --danger: #fb7185;
  --focus: rgba(125, 211, 252, 0.24);
  font-family: Inter, "Segoe UI", "PingFang SC", "Noto Sans SC", sans-serif;
}

* {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
}

body {
  margin: 0;
  color: var(--text);
  background: var(--bg);
}

.shell {
  width: min(1120px, calc(100vw - 32px));
  margin: 0 auto;
  padding: 28px 0 44px;
}

.page-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
}

h1 {
  margin: 0;
  font-size: 1.35rem;
  font-weight: 800;
  letter-spacing: 0;
}

#countText {
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 700;
}

.panel {
  display: grid;
  gap: 12px;
}

.toolbar {
  display: flex;
  gap: 10px;
}

input,
button {
  min-height: 40px;
  border-radius: 7px;
  font: inherit;
}

input {
  flex: 1;
  min-width: 0;
  border: 1px solid var(--line);
  padding: 0 12px;
  background: var(--surface);
  color: var(--text);
}

input::placeholder {
  color: var(--muted);
}

input:focus {
  border-color: var(--accent);
  outline: 3px solid var(--focus);
}

button {
  border: 1px solid transparent;
  padding: 0 14px;
  background: var(--accent);
  color: #061018;
  font-weight: 800;
  cursor: pointer;
}

button:hover {
  background: var(--accent-strong);
}

.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

table {
  width: 100%;
  min-width: 860px;
  border-collapse: collapse;
}

th,
td {
  padding: 13px 14px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
  font-size: 0.92rem;
}

th {
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

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

tbody tr:hover td {
  background: var(--surface-hover);
}

.file-name {
  display: block;
  font-weight: 800;
}

.file-path {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 0.82rem;
  word-break: break-all;
}

.note-cell {
  max-width: 390px;
  color: var(--muted);
  white-space: pre-wrap;
  word-break: break-word;
}

a.download {
  color: var(--accent);
  text-decoration: none;
  font-weight: 800;
}

a.download:hover {
  color: var(--accent-strong);
}

small,
.message {
  color: var(--muted);
  font-size: 0.9rem;
}

.message.error {
  color: var(--danger);
}

.panel-foot {
  min-height: 22px;
}

@media (max-width: 760px) {
  .shell {
    width: min(100vw - 24px, 1120px);
    padding-top: 18px;
  }

  .page-head,
  .toolbar {
    flex-direction: column;
    align-items: stretch;
  }

  button {
    width: 100%;
  }
}
