Online piracy necessarily costs the economy as a whole nothing. There are two kinds of people who pirate: those who would purchase the product if they could not pirate it and those who would not. For those who would purchase the product, the fact that they pirate it instead does not cost the economy as a whole anything. The firms that sell movies, music, and whatever else do not get as much revenue, but the economy as a whole does not suffer. That person eventually spends the money they would have spent on that song or that movie on something else.
For those who would not purchase the product if they could not pirate it, neither the media content firms nor the economy suffers from their pirating. If they could not pirate, the firms would still get absolutely nothing just as they do right now. Those kinds of pirates would not be spending any extra money in the alternative non-piracy world, meaning the net effect of their pirating on the economy is still zero.