In Massachusetts, a family of four needs more than $300,000 to live comfortably — the highest of all U.S. states.