Invertible complex square matrix

Here is a small question:

I was reading a problem in a textbook where the question is: Prove that $A$ is invertible? (where $A$ is a complex square matrix).

In the solution: the author proved that $$Re\left ( x^{*}Ax \right )> 0$$ for all $$x\neq 0$$

I don't understand how does the inequality: $Re\left ( x^{*}Ax \right )> 0$ for all $x\neq 0$ imply that $A$ is invertible!!

If $A$ was not invertible, there would be some nonzero $x$ with $Ax=0$, and then $Re(x^*Ax) = 0$.