CSS transform detection when DOM is ready

The code to detect CSS transforms requires a DOM to append an
element to. By performing this action when first called instead
of unconditionally upon library load, we can load OpenLayers in
the document's head again.
Properly cache the css transform support result
Simplifying has2d and has3d check
Merge pull request #1707 from ahocevar/css-transform-detection

CSS transform detection when DOM is ready