The fact that W3C defines a standard without creating an implementation is what leads to different interpretations, regardless of which browser does it 'right or wrong'.
The proper way to do what you want in all browsers is something like:
<div style="position:relative; z-index:1;"> OUTERFOO
<div style="position:relative; z-index:1;">OUTERBAR
<div style="position:absolute; z-index:1;">BAR</div>
</div>
<div style="position:absolute; z-index:2;">FOO</div>
</div>
or
<div style="position:relative; z-index:1;"> OUTERFOO
<div style="position:relative; z-index:1;">OUTERBAR
<div style="position:absolute; z-index:1;">BAR</div>
<div style="position:absolute; z-index:2;">FOO</div>
</div>
</div>
No need for ziindexes with ridiculous numbers - that leads to confusion.
Basically, when you are using z-index, you should position all sibling elements and the parent element, and you should z-index all siblings for sake of clarity. This makes for far more headaches.
The way you were trying to do this in your question violates the basic rules of layering in the same way that this does, for example:
<div><span></div></span>
You are looking for a solution that uses css to break the nesting rules of html syntax. The examples I provide accomplish what you really want while obeying those rules.