Hi Sanjukta,
There might be padding or margin added to the text or text input widget.
Opening your browser console (right click > inspect) en navigating to Elements in the top bar gives you the ability to check the element. If you use the most left button (a left upwards pointing arrow in a striped box) you can already if there is more space beneath it.
In the computed tab on the left you can see if there is indeed margin (orange) or padding (green) added to it. You can then set them to 0 in the styling part or add the standard class of Atlas either Outer None or Inner None based on you need to remove marging or padding. You can also remove both but then you need to set one of them in the class field.
Hope this helps!
KR, Jurre