@font-face {
  font-family: 'Fragment Mono';
  src: url('../fonts/FragmentMono-Regular.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}

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

html, body {
  height: 100%;
  background: #000;
  color: #fff;
  font-family: 'Fragment Mono', monospace;
  font-size: 0.875rem;
  line-height: 1;
  -webkit-font-smoothing: antialiased;
  -webkit-user-select: none;
  user-select: none;
}

body {
  overflow: hidden;
}

video::-webkit-media-controls,
video::-webkit-media-controls-start-playback-button {
  display: none !important;
  opacity: 0;
}

.fixed-fill {
  position: fixed;
  inset: 0;
}

.abs-fill {
  position: absolute;
  inset: 0;
}

.hidden {
  display: none;
}

@keyframes blink {
  50% { opacity: 0; }
}

.animate-blink {
  animation: blink 1s step-start infinite;
}

.tap-to-play {
  position: fixed;
  bottom: 1rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 20;
  padding: 1rem;
  background: #000;
  color: #fff;
  text-transform: uppercase;
  pointer-events: none;
  animation: tap-to-play-flash 1s step-start infinite;
}

@keyframes tap-to-play-flash {
  50% {
    background: #fff;
    color: #000;
  }
}

/* Hash router app root */
.overlay-btn {
  position: absolute;
  inset: 0;
  display: flex;
  justify-content: center;
  align-items: center;
  text-transform: uppercase;
  color: #fff;
  mix-blend-mode: difference;
  background: none;
  border: none;
  font: inherit;
  cursor: pointer;
  text-decoration: none;
}

.hud {
  position: absolute;
  inset: 0;
  padding: 1rem;
  display: flex;
  justify-content: center;
  align-items: center;
  flex-direction: column;
  pointer-events: none;
  mix-blend-mode: difference;
}

.hud-inner {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 80vmin;
  width: 80vmin;
  max-width: 40rem;
  max-height: 40rem;
}

.hud-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  color: #fff;
  text-decoration: none;
  text-transform: uppercase;
  pointer-events: auto;
  padding: 0.5rem;
}

.hud-arrow:hover {
  animation: blink 1s step-start infinite;
}

.hud-arrow-left { left: 0; }
.hud-arrow-right { right: 0; }

.hud-top, .hud-bottom-pos {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  color: #fff;
  text-transform: uppercase;
  line-height: 1;
}

.hud-top > *:nth-child(2),
.hud-bottom-pos > *:nth-child(2) {
  justify-self: center;
}

.hud-top > *:last-child,
.hud-bottom-pos > *:last-child {
  justify-self: end;
}

.hud-link {
  color: #fff;
  text-decoration: none;
  pointer-events: auto;
  text-transform: uppercase;
}

.hud-link:hover {
  animation: blink 1s step-start infinite;
}

.hud-right {
  display: flex;
  gap: 1rem;
  pointer-events: auto;
}

/* Global nav — visible on every route */
.nav {
  position: fixed;
  top: 1rem;
  left: 1rem;
  right: 1rem;
  display: flex;
  justify-content: space-between;
  z-index: 10;
  mix-blend-mode: difference;
  pointer-events: none;
  text-transform: uppercase;
}

.nav .hud-link {
  pointer-events: auto;
}

.nav-download {
  position: fixed;
  bottom: 1rem;
  left: 1rem;
  z-index: 10;
  mix-blend-mode: difference;
  text-transform: uppercase;
  pointer-events: auto;
}

.nav-prevnext {
  position: fixed;
  bottom: 1rem;
  right: 1rem;
  z-index: 10;
  display: flex;
  gap: 1rem;
  mix-blend-mode: difference;
  text-transform: uppercase;
}

.nav-prevnext .hud-link {
  pointer-events: auto;
}

/* Index — overview of all collections */
.index {
  position: fixed;
  inset: 0;
  overflow-y: auto;
  padding: 3rem 1rem 1rem;
  color: #fff;
  text-transform: uppercase;
}

@media (min-width: 601px) {
  .index {
    padding-top: calc(min(25vw, 20rem) - 3rem);
  }
}

.index-collections {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 3rem;
  width: 80vmin;
  max-width: 40rem;
  margin: 0 auto;
}

.index-collection {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem;
}

.index-right {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 100%;
}

@media (max-width: 600px) {
  .index-collection {
    grid-template-columns: 1fr;
  }

  .index-collections {
    width: auto;
  }
}

.index-cover {
  display: block;
  border-top: 1px solid #fff;
  border-bottom: 1px solid #fff;
  padding-top: 0.5rem;
  padding-bottom: 0.5rem;
}

.index-cover-frame {
  display: block;
  width: 100%;
  aspect-ratio: 1;
  background: #111;
}

@media (max-width: 600px) {
  .index-cover {
    border-bottom: none;
    padding-bottom: 0;
  }
}

.index-cover img,
.index-cover-placeholder {
  width: 100%;
  height: 100%;
  display: block;
  aspect-ratio: 1;
  object-fit: cover;
}

.index-cover-placeholder {
  background: #222;
  display: flex;
  align-items: center;
  justify-content: center;
}

.index-meta {
  margin-bottom: 0.5rem;
  border-top: 1px solid #fff;
  padding-top: 0.5rem;
  display: flex;
  justify-content: space-between;
  gap: 1rem;
}

.index-download {
  color: inherit;
  text-decoration: none;
}

.index-download:hover {
  animation: blink 1s step-start infinite;
}

.index-title a {
  color: inherit;
  text-decoration: none;
}

.index-title a:hover {
  animation: blink 1s step-start infinite;
}

.index-description {
  margin-top: 0.5rem;
  opacity: 0.6;
  line-height: 1.5;
  text-transform: none;
  max-width: 40rem;
}

.index-tracks {
  list-style: none;
  display: flex;
  flex-direction: column;
  border-bottom: 1px solid #fff;
}

.index-tracks li {
  border-top: 1px solid #fff;
}

.index-tracks a {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.5rem 0;
  color: inherit;
  text-decoration: none;
}

.index-track-title {
  flex: 1;
}

.index-tracks a:hover {
  animation: blink 1s step-start infinite;
}

