Google's blog features a unique header design - as you scroll down, the gray bar in the header moves up until it locks at the top of the screen. While CSS's position:fixed can achieve a similar effect, Google seems to have used a combination of position:fixed and position:relative based on the vertical scroll bar's position. Is there a cleaner solution using CSS2 and jQuery that doesn't involve complex scripting or reinventing the wheel?
What is the best way to implement a header like Google's blog without specifying heights for elements above the scrolling element? Any suggestions for achieving this elegant effect with x-browser compatibility using CSS2 and jQuery would be greatly appreciated.