move legend to top right so it does not interfere with chart