#yeat-merge {
  display: grid;
  max-width: 480px;
  margin: 24px auto 0;
  gap: 16px;
  font-size: 14px;
  line-height: 1.5;
}

#yeat-merge p, #yeat-merge li {
  margin: 0;
}

#yeat-merge .ym-title, #yeat-merge .ym-over, #yeat-merge #celebration {
  font-family: "Unbounded", sans-serif;
}

#yeat-merge .ym-title {
  font-size: clamp(17px, 5vw, 25px);
  font-weight: 900;
  background: linear-gradient(180deg, #fff 0%, #c9ced6 38%, #6f7682 52%, #e9edf2 70%, #9aa1ab 100%);
  background-clip: text;
  -webkit-background-clip: text;
  color: transparent;
}

#yeat-merge .ym-over {
  font-size: 1.5em;
  font-weight: 700;
}

#yeat-merge .ym-kicker, #yeat-merge .hud, #yeat-merge .music, #yeat-merge .best {
  font-family: "Space Mono", monospace;
  font-weight: 700;
}

#yeat-merge .ym-kicker {
  margin-top: 6px;
  color: #8dff6a;
  text-transform: uppercase;
  letter-spacing: .12em;
  font-size: 11px;
}

#yeat-merge .hud, #yeat-merge .next, #yeat-merge .actions, #yeat-merge .highest {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

#yeat-merge .hud {
  font-size: 11px;
}

#yeat-merge .score {
  color: #8dff6a;
  font: 700 32px/1.2 "Space Mono", monospace;
}

#yeat-merge .best {
  color: #ffd166;
}

#yeat-merge #next {
  width: 32px;
  height: 32px;
}

#yeat-merge button, #yeat-merge select, #yeat-merge input {
  border: 1px solid #1d1f26;
  border-radius: 10px;
  padding: 10px;
  color: #ecedf0;
  background: #0b0d10;
  font: inherit;
}

#yeat-merge button:focus-visible, #yeat-merge select:focus-visible, #yeat-merge input:focus-visible {
  outline: 2px solid #b99bff;
  outline-offset: 2px;
}

#yeat-merge #game {
  position: relative;
  justify-self: center;
  width: min(100%, calc((100vh - 120px) * 48 / 73));
  width: min(100%, calc((100svh - 120px) * 48 / 73));
  aspect-ratio: 48 / 73;
  border: 1px solid #1d1f26;
  border-radius: 18px;
  overflow: hidden;
  touch-action: none;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
  background-color: #0b0d10;
  background-image: linear-gradient(rgba(141,255,106,.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(141,255,106,.05) 1px, transparent 1px);
  background-size: 5% calc(100% * 24 / 730);
}

#yeat-merge #canvas {
  display: block;
  width: 100%;
  height: calc(100% * 72 / 73);
}

#yeat-merge #floor {
  height: calc(100% / 73);
  background: #284a1f;
}

#yeat-merge #overlay, #yeat-merge #celebration {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 12px;
}

#yeat-merge #overlay {
  background: #050507cc;
}

#yeat-merge .card {
  width: 100%;
  max-width: 330px;
  max-height: 100%;
  overflow-y: auto;
  padding: 18px;
  border: 1px solid #1d1f26;
  border-radius: 18px;
  background: #0b0d10;
  text-align: center;
}

#yeat-merge .card > * + * {
  margin-top: 10px;
}

#yeat-merge .highest {
  justify-content: center;
  color: #b99bff;
}

#yeat-merge #highest {
  width: 48px;
  height: 48px;
}

#yeat-merge #playAgainButton {
  background: #8dff6a;
  color: #050507;
}

#yeat-merge #shareText, #yeat-merge select {
  width: 100%;
}

#yeat-merge #celebration {
  color: #8dff6a;
  font-size: clamp(24px, 7vw, 40px);
  font-weight: 900;
  text-shadow: 0 2px 16px #050507;
  pointer-events: none;
}

#yeat-merge #legend {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

#yeat-merge #legend li {
  width: 65px;
  text-align: center;
  color: #c3c7cf;
  font-size: 11px;
}

#yeat-merge #legend img {
  display: block;
  width: 30px;
  height: 30px;
  margin: 0 auto 4px;
}

#yeat-merge .music {
  display: grid;
  gap: 6px;
}

#yeat-merge .instructions, #yeat-merge a {
  color: #c3c7cf;
}

#yeat-merge .ym-foot {
  color: #8b909c;
  font-size: 11px;
}

#yeat-merge [hidden] {
  display: none !important;
}
#yeat-merge ~ .ym-intro { margin-top: 28px; font-size: 19px; color: #d3d6dd; max-width: 720px; }
