Péter Magyar’s victory might be a product of well-timed opportunism in a country fed up with a failing government