what is the cost for legal services to buy a house