.cheat-sheet {
  display: flex;
  flex-direction: column;
  position: absolute;
  top: 8px;
  left: 8px;
  z-index: 3;
  background-color: #141414dd;
  pointer-events: none;
  padding: 3px 9px;
  width: 342px;
  user-select: none;

  ul {
    margin-block-start: 0;
    margin-inline-start: 0;
    padding-inline-start: 0;
    list-style: none;
    margin: 0;

    > div {
      display: flex;
      flex-direction: row;
      padding-bottom: 4px;
      padding-top: 4px;
      border-bottom: 1px solid #cccccc56;
      font-size: 13px;

      .name {
        flex: 1;
        color: #eeeeee9b;
      }

      .keybind {
        flex: 0.45;
        font-family: 'Input Mono', 'Oxygen Mono', 'Hack', 'IBM Plex Mono', monospace;
      }
    }

    > div:last-child {
      border-bottom: none;
    }
  }
}

.mobile-cheat-sheet {
  bottom: 0;
  top: unset;
  width: 100vw;
  left: 0;
  box-sizing: border-box;

  ul {
    > div {
      font-size: 13px !important;
    }
  }
}

@media screen and (orientation: landscape) {
  .mobile-cheat-sheet {
    max-width: 236px;
    left: unset;
    right: 0;

    ul {
      > div {
        font-size: 11px !important;
      }
    }

    .keybind {
      flex: 0.8 !important;
    }
  }
}

.collapsed-cheat-sheet {
  .cheat-sheet {
    width: 218px;
    padding: 3px 9px;

    ul > div {
      padding-bottom: 0;
    }
  }
}

.cheat-sheet-about-button {
  position: absolute;
  z-index: 3;
  pointer-events: auto;
  user-select: none;
  color: #eeeeee9b;
  background-color: #141414dd;
  padding: 3px 9px;
  right: 0;
  border: 1px solid #cccccc56;
  cursor: pointer;
}

.mobile-cheat-sheet-about-button {
  top: -23px;
  border-top-left-radius: 3px;
  border-top-right-radius: 3px;
  font-size: 13px;
}

.desktop-cheat-sheet-about-button {
  bottom: -26px;
  border-bottom-left-radius: 3px;
  border-bottom-right-radius: 3px;
  font-size: 15.5px;
}
