In the recent question "What's the probability that a sequence of coin flips never has twice as many heads as tails?" I argue in my answer that the number of ways $S(n)$ to obtain twice as many heads as tails for the first time in $3n$ coin flips is $\binom{3n}{n} \frac{2}{3n-1}$. The argument works by showing that $S(n)$ satisfies a recurrence and then using a binomial convolution identity to show that $\binom{3n}{n} \frac{2}{3n-1}$ satisfies the recurrence as well.
However, it seems to me that there ought to be a nice, direct combinatorial proof that $S(n) = \binom{3n}{n} \frac{2}{3n-1}$. After all, there are $\binom{3n}{n}$ sequences of $3n$ coin flips in which $n$ are tails, and the number of those for which we see twice as many heads as tails for the first time is just $\frac{2}{3n-1}$ of that. I've been thinking about this some the past few days but have been unable to find a combinatorial explanation of the fraction $\frac{2}{3n-1}$.
So my question is...
Can someone provide a combinatorial proof that $S(n) = \binom{3n}{n} \frac{2}{3n-1}$?
And, more generally, if $S(n,r)$ is the number of ways to obtain $r$ times as many heads as tails then my argument in the answer mentioned above shows that $S(n,r) = \binom{(r+1)n}{n} \frac{r}{(r+1)n-1}$. It would be nice if the proof were generalizable to the $S(n,r)$ case.
One thought is that it might be possible to adapt one of the combinatorial proofs that the $n$th Catalan number $C_n$ is $\binom{2n}{n} \frac{1}{n+1}$. In fact, in the $r=1$ case the question is equivalent to finding the number of Dyck paths from $(0,0)$ to $(n,n)$ that do not touch the diagonal $y=x$ except at $(0,0)$ and $(n,n)$. This is known to be $2C_{n-1} = \binom{2n-2}{n-1} \frac{1}{n} = \binom{2n}{n}\frac{1}{2n-1} = S(n,2).$
In fact, that last paragraph makes me wonder if there might be some generalization of the Catalan numbers in this direction. Or perhaps the alternative formulation $S(n,r) = \binom{(r+1)n-2}{n-1} \frac{r+1}{n}$ admits a combinatorial proof more easily.
Added: I think Qiaochu Yuan's argument below about using Raney's lemma is on the right track, but it doesn't quite get to the expression I'm looking for. Raney's lemma is about a sequence in which all partial sums are positive. However, in obtaining $r$ times as many heads as tails for the first time the partial sums ($+r$ for each tail and $-1$ for each head) do not all have to be positive or all negative. For example, you could have a sequence like HHHT, with overall $+1$, and then if the next flip is a tail you would have HHHTT, with overall $-1$, and we still haven't reached exactly twice as many heads as tails.
I suspect the Raney's lemma argument can be adapted, but I don't think we quite have an answer to the question yet. Does anyone see how to do it?
Added 2: I found a complete combinatorial argument. See my answer below.