You ever play Civilization, or Factorio, or any sort of game with building simulations? You have to use the old technology to build towards the new.
If petroleum supplies are already running low, we might not even have enough to actually run the machines that create solar panels and windmills and whatnot.
You're absolutely correct, the problem is that the whole fucking world has squandered its resources. If we were to legitimately go full renewables? It would have to be a team effort with every country in on the plan. It ain't something that can happen overnight.
The situation is a mess. My money is on things turning into Mad Max before any sort of actual renewable energy is locked in.