I'm reading my pre-calc book and their definition of absolute values is driving me bonkers. They keep saying that |x| = -x and also -x = |x| = c. I can't figure out how to rationalize |x| = -x. In my mind if x = -5 then |-5| equals 5. BUT -5 can not equal 5 so how can they say |x| = -x?
Below is from from the book
The `Equality Properties' can be proved using Definition 2.4 and by looking at the cases when x >= 0, in which case |x| = x, or when x < 0, in which case |x| = -x. For example, if c > 0, and |x| = c, then if x >= 0, we have x = |j| = c. If, on the other hand, x < 0, then -x = |x| = c, so x = -c.

$$ \left|-5\right|=-\left(-5\right)=5 $$
The $x$ is negative too, in fact if $x<0$ $$ \left|x\right|=-x $$ and if $x \geq 0$ $$ \left|x\right|=x $$