The point $(x,y)$ in the coordinate has a distance of $6$ units from the $x$-axis, a distance of $15$ units from the point $(5,7)$, and a distance of $\sqrt{n}$ from the origin. If both $x$ and $y$ are negative, what is $n$?