Basically, if you change the size of the border on hover the element box will grow or shrink so it might affect other elements.
The way you declare the border on hover, black 2px as opposed to 2px solid black it’s actually setting the border-style back to initial which is removing the border (setting border-style to none). So the element box is getting smaller which is why it’s affecting other elements.
Example
BTW, your labels are missing the for attribute (at least for the labels without nested inputs).