Whenever you see an expression with terms $a^2,b^2, c^2, ab, bc, ca$, keep in mind the following identity:
$a^2 + b^2 + c^2 - ab - bc - ca = \frac{1}{2}\left( (a - b)^2 + (b - c)^2 + (c - a)^2 \right)$
$a^2 + b^2 + c^2 - ab - bc - ca = \frac{1}{2}\left( (a - b)^2 + (b - c)^2 + (c - a)^2 \right)$