The language of "colors" maps more-or-less straightforwardly to the actual group theory that controls the strong force:
The gauge symmetry that is associated to the strong force is the unitary group in three (complex) dimensions, $\mathrm{SU}(3)$. The analogon for the other forces would be $\mathrm{U}(1)$ for electromagnetism and $\mathrm{SU}(2)$ for the weak force. The lowest-dimensional "fundamental" representation is three-dimensional, it's just the natural action of $\mathrm{SU}(3)$ on $\mathbb{C}^3$. We pick three basis vectors in $\mathbb{C}^3$ and call them (arbitrarily) "red, blue, green". This is the representation in which the quarks transform, so for quarks, we speak of red/blue/green quarks.
Now, the number of conserved quantities is unrelated to the dimension of hte fundamental representation - the number of conserved quantities is the dimension of the group as a Lie group, which is 8. Not coincidentally, this is also the number of gluons - the force carriers always transform in the so-called adjoint representation, which is the natural action of the group on its own Lie algebra. Rather by definition, the dimension of the Lie algebra is that of the group.
Finally, let's discuss how the naming scheme of "blue-antired" etc. for gluons arises: If we call $V_\text{f}$ the fundamental representation, $V_\text{ad}$ the adjoint and $V_1$ the trivial representation, then we have
$$ V_\text{f}\otimes V^\ast_\text{f} = V_1\oplus V_\text{ad}$$
where $V^\ast$ is the dual representation. It's sort-of traditional to see the dual/conjugate representation as the antipode to the original representation, so the three basis vectors of $V_\text{f}^\ast$ would be called antired/antiblue/antigreen. So the nine basis vectors of the l.h.s. would be called red-antired,blue-antired,green-antired,red-antigreen, etc. Reorganizing those into eight vectors that span $V_\text{ad}$ gives the usual color nomenclature for gluons.