As described here and discussed in this chromium bug report according to W3C spec
In the HTML namespace, any value other than
nonefor the transform results in the creation of both a stacking context and a containing block. The object acts as a containing block for fixed positioned descendants.
position: fixed that are descendant of any element with transform other than none are relative to that element.
However IE <= 11 and Firefox at least up to FF36 do not conform to the spec but position the element relative to the viewport (as originally intended).
Is there any fix ("polyfill") to get the same behaviour across all browsers?
Otherwise is there a way to "feature detect" instead of browser detect this behaviour to alternatively style affected elements?