I have a header div above a scrolling div and I'd like to pad the header on the right the same width as the scrollbar. I know I can use JavaScript to calculate the scrollbar width, but I was wondering if there's a pure CSS method to do this?
Edit
To complicate this more, if there are few results that come back so the scrolling div doesn't produce a scrollbar, then I'd want the header to not be padded as well. I'm not sure if that's possible using only CSS, but thought it's worth asking.