State regulators approved a deal to sell the hospitals months ago. However, Prospect said in court filings it couldn’t afford to carry out the attorney general’s hefty closing conditions.