The ratio gives us two equations so that's three equations in three unknowns. Actually we're after the total t; let's put that in to solve for directly.
c:g:s:t = 5 : 2 : 1 : 5+2+1
We turn the ratio to fraction equations. s has the one; let's write everything in terms of s.