FIDDLE IS HERE (logs to console)
The situation is when the page starts out with a <H1> that has a margin-top greater than the margin found on <body>.
This causes the <body> to be pushed lower in the page yet $('body').offset().top remains set to the <body>‘s margin-top. This of course causes my debug element (which highlights the position of elements) to be incorrect since the body’s dummy element is now in the wrong position.
Curiously the rest of the $(elem).offset() values are correct for any descendant of <body>.
Is there a fix for this short of manually checking the margin-top of the recursively first childs of body with a while loop?
Noticing the issue on Safari 6 though I suspect I’ll find it on Chrome as well.
jQuery 1.9.0 has addressed this issue. Thanks so much, jQuery is awesome.