Usually that's up to the insurance company isn't it? If a car is totaled they own it after they pay out, but usually you can buy it back.
From what I have read, it is one of the easier engine swaps you can do on any vehicle, usually the biggest hurdle on a motor swap is motor mounts as they are usually custom, but the mounts are bolt on. As long as you are getting a ZX2 engine (and maybe transmission? not a necessity but it might be preferable for more aggressive gearing) from a ZX2 you are fine, a Focus zetec has some slight differences and the transmission will not work without modification. The biggest generation difference between ZX2s is the cars from 98-99 and 99.5-2003, but the differences are not very drastic.
I also read somewhere that the ECU doesn't need to be changed, but I would definitely swap the ZX2 ECU in. As for wiring, and well, the swap in general it would be best to get a zx2 that was crashed in the back or side, pull the harness, engine, trans, axles, ECU, etc. and swap everything over.
Here is one person's thread where they documented their swap:
6 months ago my beloved 99 sedan dropped her valve seat at 158k miles, the seat fell onto the piston, breaking it, and then sending the rod right through the block...ending that engine's story. I had just dropped my tuition money for fall term, so there was no getting another engine right away...
www.feoa.net