The problem is caused by the translate3d transform that you apply in the iframe ;
-webkit-transform: translate3d(0, 0, 0);
There is a known issue in which translate3d causes position:fixed elements to behave like position:absolute in some webkit browsers, such as those on iOS, as well as some desktop versions of chrome.
Here is a demo demonstrating a mistake in action:
html, body { width:100%; height:100%; margin:0; padding:0; transform: translate3d(0, 0, 0); } #nav{ width:100%; height:10%; position:fixed; top:0; left:0; background-color:red; } #content { width:100%; height:500%; }
<!DOCTYPE html> <html> <body> <nav id="nav"> </nav> <main id="content"> </main> </body> </html>
In the demo, the red navigator should be visible even after scrolling down. Depending on your browser, this may or may not work properly. Removing the problematic style -webkit-transform: translate3d(0, 0, 0); allows you to work correctly in all browsers.
This error occurs due to a transformation creating a new coordinate system, causing the position:fixed element to attach to the transformed element instead of the viewport.
I myself came across this error while trying to smooth out transitions on iOS and created a post about it here . More information can be found in this thread , which I also linked to in my own post.
The only fix I know is to remove the problematic translate3d style. If it is necessary, for example, in order to coax iOS, to enable hardware acceleration (for which I need it), try to apply it to various elements: parent (body, html) or children of the iframe owner. I found that applying it to a completely unrelated element gave me the desired result.
There are also some workarounds and fixes for specific cases in the thread I am attached to. One of them can do the trick.
This is a pretty nasty bug to track. Spent me finding it on my page.
Good luck.