Hi all. I've gotten myself a bit muddled in trying to implement a design. The idea is to have a normal box that fades to a shadow at the top. A nice cool effect, please see the attached file for a rough demo of what I mean.
I've quickly established I need to use a normal box to begin with, let's say:
And then use an absolute positioning of an internal div, which contains a background image of the gradient effect, for the top of the box:
Now that I have the topshadow in place, I can write normal content, images, paragraphs, etc, and they will appear at the top of the mainbox, regardless of the topshadow positioning as it is "absolute".
HOWEVER, the z-index is giving me problems. The topshadow div is appearing above my normal <p> tags, and I can't shift it. This is when laid out as so:
If anyone has any ideas what I'm doing wrong, if there are some z-index quirks I'm not aware of, or if there is a better way of implementing this design that I haven't happened upon yet, I would be very happy. Hopefully I've explained myself well enough.
Thanks!