How much would it cost to build out batteries which cover entire continent's electricy needs for say three weeks (as there can be 2-3 week lulls of no wind and no sun in Europe in the winter)? Cause that sounds like a lot of batteries. Not to mention, if a freak 4 week lull occurs, we'll go back to Middle Ages for a week.
(for Australia it is 5, for other countries it might be 8)
Once you get to that "nice to have" problem of what to do about the remaining 3% of power needs it would probably make most sense to synthesize and store gas (methane/hydrogen) from electricity when solar and wind is overproducing. Gas can be stored cheaply for long durations. The roundtrip efficiency is poor but it's still cheaper than nuclear power on the windiest sunniest day.
The nuclear + carbon lobbies would of course prefer to model green energy transitions by pretending that the wind and sun simultaneously turn off for 2 weeks at a time every year and that electricity can only be stored in very expensive batteries. This is not realistic.
It might not be quite that good in less sunny countries. Similar modest overbuilding of wind and solar in Denmark is simulated to get to about 90% with 12h of storage. This is still good enough though.
Australia's CSIRO studied this for Australia, renewables were half the cost of nuclear, factoring in storage and transmission for both renewables and nuclear (yes, nuclear also needs storage because energy demand varies with time). Australia is uniquely endowed with sun and land, so other countries/regions may arrive at different results.
Australia is also well endowed with coal and no carbon pricing, so for Australia the cheapest form of electricity production is a mix of solar + battery + coal.
Solar still produces even in overcast conditions, during the day. If it's light/medium overcast, most of which Germany usually is it still produces 50-80% of nominal. It only really doesn't produce anything at night or when it snows.
"But what if thing thing that never happens were to happen?"
We'd probably go deep into hydro, fire up every gas peaker plant, and through skyrocketing prices incentivize everyone to switch to emergency diesel generators where possible.
You're talking about a once-in-100+-years event. We'll deal with it the same way we dealt with the various oil crises.
"Based on the much-studied 1977 New York City blackout. ICF Consulting estimated the total economic cost of the August 2003 blackout to be between $7 and $10 billion"