improved regex to handle negative numbers