Spin-flavor formalism for the relativistic coupled-channels quark model