The next leader of Europe's biggest economy will face a public deeply dissatisfied with living standards, housing and less tolerant towards migrants than in previous years.