Is there any good way to recover from this? Or should I give up and order a replacement top?
I doubt you'd need to order a replacement top, no matter how bad the rust seems to you compared to the pristine surface around it. People have restored Craigslist finds where the rust was old and far more pervasive than what you're facing...... and the after photos sort of speak for themselves I think:
So no need to panic :-)
Once the surface rust is gone discolouration may bother you since the saw was so new, but the main practical issue is of course pitting. It's a safe bet that the rust won't have progressed far enough that any pitting left behind is a dealbreaker based on all the rusty garage/barn queens posted online that have been brought back to working condition!
Removing the rust
So the main way to deal with this is abrasive methods. You could take the bed off to immerse it in a rust-removal soak or to do electrolysis but it's very unlikely to be necessary to go to that extreme.
Remove the loose surface rust first by scrubbing with coarse steel wool or a Scotch-Brite, lubricated with something oily — mineral spirits, WD-40 or some oil (baby oil is just fine if it's all you have). Then wipe clean and assess the bed surface.
If there's some minor pitting you could do some sanding but only if you want to, once the active rust is gone you can pretty much leave it if the slight discolouration doesn't bother you. Some pitting usually doesn't affect function in any way that you'd notice so it's not actually vital to remove it.
So after tackling the surface rust you can apply a fresh coat of your usual waxy or oily rust-preventative and put the saw straight back to work.
If you do want to sand, first response in this thread on Fine Woodworking's forum is well worth a read to reassure yourself you won't do any harm to the bed of your saw by sanding it.
Some further reading:
Using Naval Jelly before sanding, here on Wood Bin.
Some people swear by solid rubber abrasive blocks such as Sandflex, here's John Hintz talking about them on NewWoodworker.com, Resurfacing Cast Iron Tables.
Three rust removal methods compared by Wood Magazine, here.
And is there any good way to reduce this risk in the future?
A very thorough waxing might have helped, but almost no rust-proofers are intended to stave off rust when there's standing liquid water, they're mainly to resist water vapour. This is at working thickness, many things (including common paste wax and petroleum jelly) in a thick layer would have allowed the table saw to come through this unscathed but they're never normally applied at that level of course.