img {
position: absolute;
/*position: relative;
//position: fixed;*/
left: 0px;
top: 0px;
z-index: -1;
}
The z-index property specifies the stack order of an element.
#nav {
position: fixed;
...
z-index: 2;
}
#main {
position: absolute;
...
z-index: 1;
}
/* The z-index CSS property sets the z-order of a positioned element and its
descendants or flex items. Overlapping elements with a larger z-index cover
those with a smaller one. */
/* Keyword value */
z-index: auto;
/* <integer> values */
z-index: 0;
z-index: 3;
z-index: 289;
z-index: -1; /* Negative values to lower the priority */
/* Global values */
z-index: inherit;
z-index: initial;
z-index: unset;
img {
position: absolute;
left: 0px;
top: 0px;
z-index: -1;
}