Hi Abhishek,
for datagrid2 try to change the size of column from manual to auto-fill
or add a class for the datagrid2 and on inspection window you can see the grid-templete column property you try to overwrite it with your custom code as of lessthan 1fr it will help for reducing column size
for changing the color on different values use the dynamic classes where your code needs to in the format of changing background color to the row of datagrid2.
hope this helps.