Click fraud doesn't fuck over online advertising platforms, if it goes undetected it fucks over advertisers who use the platform. If it's detected, no one pays for it.
On the off chance you're interested in the distinction... Uncaught click fraud is paid for by advertisers (including small businesses and startups who can't easily absorb that cost). The platform (Google Ads for instance) pays nothing. In fact they make a profit.
It only hurts them if there is enough of it that it pushes advertisers elsewhere, which is why so much of it is caught (in which case no one pays for it).