Officials say world powers and Iran are close to a nuclear deal that would end 12-year dispute over Tehran’s ambitions.