:root {
  color-scheme: dark;
  --green: #64dc44;
  --ink: #050605;
  --frame: #161616;
}

* {
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

html,
body {
  width: 100%;
  height: 100%;
  margin: 0;
  overflow: hidden;
  background: #0a0a0a;
  color: #f7f1df;
  font-family: Monaco, "Courier New", monospace;
  touch-action: none;
  user-select: none;
}

.shell {
  width: 100vw;
  height: 100dvh;
  display: grid;
  place-items: center;
  background: radial-gradient(circle at 50% 50%, #171717 0, #050505 72%);
}

canvas {
  width: 100%;
  height: 100%;
  display: block;
  border-radius: clamp(14px, 4vw, 48px);
  box-shadow:
    0 0 0 clamp(8px, 1.5vw, 22px) #050505,
    0 0 0 clamp(14px, 2.4vw, 36px) var(--frame),
    0 24px 80px rgba(0, 0, 0, 0.7);
  background: var(--ink);
}

.game-wrap {
  position: relative;
  width: min(100vw, calc(100dvh * 2.16949));
  height: min(100dvh, calc(100vw / 2.16949));
}

.help-button {
  position: absolute;
  top: 5.3%;
  right: 5.5%;
  z-index: 2;
  width: clamp(58px, 6.2%, 80px);
  height: clamp(25px, 5.8%, 34px);
  border: 0;
  border-radius: 0;
  background: #d7f6d0;
  color: #083f2a;
  font: 800 clamp(12px, 1.35vw, 16px) Monaco, "Courier New", monospace;
  cursor: pointer;
}

.help-button.is-open {
  background: #fff044;
}

.help-button.is-hidden {
  display: none;
}

.rotate-note {
  display: none;
  position: fixed;
  inset: 0;
  align-content: center;
  justify-items: center;
  gap: 28px;
  padding: 32px;
  background:
    linear-gradient(rgba(27, 117, 81, 0.13) 1px, transparent 1px),
    #050605;
  background-size: 100% 6px;
  color: var(--green);
  font-weight: 800;
  text-align: center;
}

.portrait-title {
  font-size: clamp(54px, 17vw, 108px);
  line-height: 0.9;
}

.portrait-copy {
  color: #f7f1df;
  font-size: clamp(18px, 5vw, 28px);
}

.portrait-saucer {
  width: 138px;
  height: 52px;
  position: relative;
}

.portrait-saucer::before,
.portrait-saucer::after {
  content: "";
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
}

.portrait-saucer::before {
  top: 12px;
  width: 138px;
  height: 28px;
  background: #0d7d31;
  clip-path: polygon(0 45%, 22% 10%, 78% 10%, 100% 45%, 78% 100%, 22% 100%);
}

.portrait-saucer::after {
  top: 0;
  width: 68px;
  height: 28px;
  background: #62de61;
  clip-path: polygon(20% 100%, 38% 0, 72% 0, 100% 100%);
}

@media (orientation: portrait) and (max-width: 820px) {
  .game-wrap {
    display: none;
  }

  .rotate-note {
    display: grid;
  }
}
