perf: use structuredClone() for cloning