Because all elements have their z-index set to 0 by default, the browser puts the image in front because it's the first element in the HTML.
z-index
0
Make sure to pick 0.