Number validation for input fields