What did you do for me and why did you do like that What is the composition of "for me" in the first sentence and "like that" in the second sentence,

What did you do for me and why did you do like that What is the composition of "for me" in the first sentence and "like that" in the second sentence,

You are the subject, did is the predicate, what is the object, and for me is the complement of the object
Like that is used as an adverbial of manner