You back up the entire grid with combined cycle plants burning hydrogen. Even if you hardly ever use them, that's affordable compared to running nuclear power plants.
Or you use some even cheaper (but more complex) combination of various storage solutions, transmission, and demand dispatch.
"when there's clouds and the wind doesn't blow, what happens?" Meteorologically speaking that won't happen over a large enough area like Europe or USA. When there's clouds there's always wind close by. It's also never cloudy over a whole continent (air has to come back down somewhere)
In your example: when there's clouds and the wind doesn't blow, what happens? Currently we burn coal, gas and petrol. This means that in order to accept hydro and solar as the main source of energy, we have to take fossil fuels along, as a backup. Unless we find a different backup.
And nuclear is right there.