:root {
  --bg: #080d1a;
  --bg2: #0e1528;
  --bg3: #14203a;
  --panel: #0b1220;
  --row-even: #101a30;
  --border: #1e3060;
  --border2: #2a4a8a;
  --accent: #4a9eff;
  --gold: #ffd700;
  --text: #e8f0fe;
  --text-dim: #5a6a8a;
  --text-mid: #9aaace;
  --font-px: 'Press Start 2P', monospace;
  --font-vt: 'VT323', monospace;
  --r: 3px;
  --glow: 0 0 24px rgba(74, 158, 255, .18);
  --glow-gold: 0 0 20px rgba(255, 215, 0, .4);
}

body {
  margin: 0;
  font-family: var(--font-vt);
  font-size: 20px;
  font-weight: 400;
  color: var(--text);
  background-color: var(--bg);
}

a {
  text-decoration: none;
  color: var(--accent);
}

a:hover {
  text-decoration: underline;
  color: #6ab4ff;
}

a:visited {
  color: var(--text-mid);
}

.back-home {
  display: inline-block;
  margin: 14px 0.625rem 0;
  font-family: var(--font-vt);
  font-size: 1.05rem;
  color: var(--text-mid);
}

.back-home:hover {
  color: var(--accent);
}

table {
  width: 100%;
  background: var(--panel);
  border: 2px solid var(--border);
  border-radius: var(--r);
  table-layout: auto;
  border-collapse: separate;
  border-spacing: 0;
  overflow: hidden;
}

table thead {
  background: var(--bg2);
}

table tr th,
table tr td {
  padding: 0.5625rem 0.625rem;
  font-size: 1rem;
  color: var(--text);
  text-align: left;
  line-height: 1.25rem;
}

table thead tr th {
  padding: 0.5rem 0.625rem 0.625rem;
  font-weight: bold;
  color: var(--text-mid);
  border-bottom: 2px solid var(--border);
}

table tbody tr:hover {
  background: var(--bg3);
}

table tr.even {
  background: var(--row-even);
}

.img-wrap {
  vertical-align: middle;
  display: inline-block;
  margin-right: 8px;
  width: 16px;
  height: 16px;
}

.img-wrap img {
  display: block;
  width: 100%;
  height: 100%;
  max-width: none;
  object-fit: contain;
  filter: brightness(0) invert(1) opacity(.8);
}

.img-wrap + a {
  display: inline-block;
  vertical-align: middle;
}

.hidden {
  display: none;
}

#page-header {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin: 20px 0.625rem;
}

#page-header h1 {
  font-family: var(--font-px);
  font-size: clamp(10px, 3vw, 15px);
  letter-spacing: 1px;
  color: var(--gold);
  text-shadow: var(--glow-gold);
  margin: 0;
}

#search {
  display: block;
  padding: 0.5rem 0.75rem;
  font-family: var(--font-vt);
  font-size: 1.1rem;
  line-height: 1.25;
  color: var(--text);
  background-color: var(--bg2);
  background-image: none;
  background-clip: padding-box;
  border: 2px solid var(--border);
  border-radius: var(--r);
  margin-left: auto;
  -webkit-appearance: textfield;
}

#search::placeholder {
  color: var(--text-dim);
}

#search:focus {
  border-color: var(--accent);
  box-shadow: var(--glow);
  outline: 0;
}

::-webkit-scrollbar {
  width: 5px;
  height: 5px;
  background-color: var(--bg);
}

::-webkit-scrollbar-thumb {
  background-color: var(--border2);
  border-radius: 3px;
  border: none;
}

::-webkit-scrollbar-thumb:hover {
  background-color: var(--accent);
}

* {
  scrollbar-width: thin;
  scrollbar-color: var(--border2) var(--bg);
}

/* Hide extra columns so they don't squash file names */
@media (max-width: 600px) {

  .indexcollastmod,
  .indexcoldesc,
  .indexcolsize {
    display: none;
  }

  #page-header h1 {
    font-size: 11px;
  }

  #page-header {
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-start;
    margin-bottom: 1em;
  }

  #search {
    margin-left: 0;
    width: 100%;
    box-sizing: border-box;
  }
}
