Applies translateZ in JavaScript instead of CSS.