improved wrap method in Mojo::DOM to allow wrapping of the root node