:root {
  --ink: #000000;
  --cream: #f4e2a8;
  --mute: rgba(244, 210, 122, 0.5);
}

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

html,
body {
  height: 100%;
  background: var(--ink);
  color: var(--cream);
  overflow: hidden;
  font-family: "Zen Kaku Gothic New", system-ui, sans-serif;
}

#field {
  display: block;
  width: 100%;
  height: 100%;
  cursor: none;
}

.grain {
  pointer-events: none;
  position: fixed;
  inset: 0;
  opacity: 0.04;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

#hud {
  position: fixed;
  top: 28px;
  left: 32px;
  z-index: 2;
  pointer-events: none;
  letter-spacing: 0.18em;
}

#hud .jp {
  font-size: 13px;
  opacity: 0.9;
}

#hud .en {
  margin-top: 6px;
  font-family: "Cormorant Garamond", serif;
  font-style: italic;
  letter-spacing: 0.08em;
  font-size: 18px;
}

#hud .artist {
  margin-top: 4px;
  font-size: 11px;
  opacity: 0.45;
  letter-spacing: 0.28em;
  text-transform: uppercase;
}

#player-wrap {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 4;
  width: 280px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

#local-audio {
  width: 280px;
  height: 36px;
  border-radius: 10px;
  filter: invert(1);
}

#drop {
  cursor: pointer;
  display: block;
  padding: 8px 10px;
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.45);
  border: 1px solid rgba(255, 255, 255, 0.22);
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--mute);
  text-align: center;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.35s ease, visibility 0.35s ease;
}

#drop input {
  display: none;
}

#hint {
  position: fixed;
  left: 32px;
  bottom: 24px;
  z-index: 2;
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--mute);
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.35s ease, visibility 0.35s ease;
}

body.edge-ui #hint,
body.edge-ui #drop {
  opacity: 1;
  visibility: visible;
}

body.edge-ui #drop {
  pointer-events: auto;
}

#params {
  position: fixed;
  top: 28px;
  right: 24px;
  z-index: 3;
  pointer-events: none;
  min-width: 148px;
  font-variant-numeric: tabular-nums;
}

#params .label {
  font-size: 10px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  opacity: 0.45;
  margin-bottom: 8px;
}

#params li {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  font-size: 11px;
  letter-spacing: 0.08em;
  line-height: 1.55;
  list-style: none;
  opacity: 0.7;
}

#params li span {
  opacity: 0.45;
}

#gate {
  position: fixed;
  inset: 0;
  z-index: 10;
  display: grid;
  place-items: center;
  background: radial-gradient(ellipse at center, #1a1408 0%, #000000 70%);
  transition: opacity 0.9s ease, visibility 0.9s ease;
}

#gate.gone {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

#enter {
  appearance: none;
  background: none;
  border: 0;
  color: var(--cream);
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

#enter .jp {
  letter-spacing: 0.4em;
  font-size: 15px;
  opacity: 0.75;
}

#enter .title {
  font-family: "Cormorant Garamond", serif;
  font-style: italic;
  font-size: clamp(42px, 8vw, 88px);
  font-weight: 400;
  letter-spacing: 0.04em;
}

#enter .hint {
  margin-top: 18px;
  font-size: 11px;
  letter-spacing: 0.42em;
  text-transform: uppercase;
  opacity: 0.4;
}

@media (max-width: 640px) {
  #player-wrap {
    width: 180px;
  }

  #local-audio {
    width: 180px;
  }

  #hud {
    left: 18px;
    top: 18px;
  }
}
