It's not easy to achieve that in datagrid. Maybe you can play a bit with the dynamic row class (see picture).
Listviews are much easier for complex content...Hence I would solve it with a listview & groupbox or a listview with some conditionally displayed content for the salary…