This function finds the value \(q\) using a root-finding algorithm
applied to the pmvnormr function. It solves for the value where
the multivariate normal cumulative distribution function equals the
target probability \(p\).
Positive semidefinite sigma matrices (including singular cases) are
supported in the general covariance branch via minimal diagonal
stabilization during factorization.