Hi aleem.
You are scaling towards the active element:

which is in this case the lighter colored bottom plank and to be more precise: the center of the plank:

So everything (that is selected) shrinks towards the center of that bottom plank, so also the bottom of that bottom plank scales towards that center.