Hi there!
Since square roots are non-negative, Inequality is only meaningful if both sides are non-negative. Hence, squaring both sides was indeed valid.
Similarly, applying a decreasing function toboth sides of an in- equality will reverse it.
Cheers!