Fix cloneNode to preserve ownerDocument