If people had been able to investment the money that was taken from them in the Ponzi scheme known as Social Security in the market they would have been better off.
No, they would be much worse off, because they wouldn't have made those investments. We have 401Ks and all sorts of IRAs in which people can make very tax-advantageous investments AND THEY DON'T to a large extent. If you really want them to do better than Social Security in terms of return, you would have to MAKE then invest much like Social Security does. And you can't let them make their own choices, because even seasoned fund managers usually don't beat SPY.
But aside from that, Social Security is not an investment. It is old-age insurance. More like an annuity. Can you find an annuity that works like Social Security and costs less? Good luck on that.