"You've got no chance of beating that thing in a fight, mate" "yeah, nah" (I agree)
"Reckon it's never going to rain again?" "nah, yeah" (it will, eventually)
“Do you serve Pepsi here?”
-(no) “yeah no, we are all out”
-(no) “no, yeah we are all out”
-(yes) “no yeah, we got it”
-(yes) “yeah, no we got it”
Your example of "no, yeah we're all out" doesn't actually work, because the "yeah" is dangling. The "yeah, no" works (the yeah agrees with the question, we do serve Pepsi, but the no modifies it because we're all out).
and the same for the "yeah, no" in the second example - the "no" is dangling.
but yeah, it can be confusing if the tone of the original question implies a negative (like "you don't serve Pepsi here do you?").
took me ages to work out that the first value doesn't matter ;)
https://pics.me.me/california-english-no-yeah-yes-yeah-no-ye...
There's that old joke where a lecturer is telling the audience about how two affirmatives never make a negative in English, and a voice is heard "Yeah yeah". I guess you could try "You don't like me, do you?" "No no, I do!". But whatever's said, the meaning would be determined mostly by the tone of voice, facial expression, body language etc
the "nah" indicates disagreement with the statement, and the "yeah" affirms the positive. Often with a restatement of the statement attached.
e.g: "nah, yeah I like you mate"