:root {
  --border-color: #31393b;
  --link-color: #a8a452;
  --link-hover: #5ab0ac;
  --bg-color: #293133;
  --footer-color: #126864;
  --font-mono: Iosevka, monospace;
}

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-family: system-ui;
  font-size: clamp(1em, 0.909em + 0.45vmin, 1.25em);
}

body {
  max-width: 1000px;
  min-height: 100vh;
  margin-inline: auto;
  background: var(--bg-color);
  display: flex;
  flex-direction: column;
}

header {
  text-align: center;
  margin: 2em;
}

nav {
  border-top: 1px solid var(--border-color);
  font-family: var(--font-mono);
  font-size: 0.85em;
  margin-bottom: 2em;
  padding-right: 1em;
  text-align: right;
}

nav a {
  color: var(--link-color);
  text-decoration: none;
  transition: color 500ms ease;
}

nav a:not(:last-child):after {
  content: " • ";
  color: var(--border-color);
}

nav a:hover {
  color: var(--link-hover);
}

main {
  flex: 1;
  display: grid;
  grid-template-columns: repeat(auto-fill, 240px);
  row-gap: 10px;
  column-gap: 10px;
  justify-content: center;
  align-items: center;
}

.cover {
  width: 240px;
  height: 240px;
  object-fit: cover;
  border: 2px solid var(--border-color);
  display: block;
  transition: transform 100ms ease-in-out;
}

.cover:hover {
  transform: scale(1.02);
}

footer {
  border-top: 1px solid var(--border-color);
  color: var(--footer-color);
  font-family: var(--font-mono);
  font-size: 0.5em;
  margin-top: 1em;
  padding-top: 0.5em;
  text-align: right;
}

@media (max-width: 600px) {
  body {
    padding: 0.5rem;
  }

  main {
    grid-template-columns: repeat(auto-fill, 150px);
    gap: 10px;
  }

  .cover {
    width: 150px;
    height: 150px;
  }
}