Fix some warnings.

Closes #906
Avoid another CSS counters bug on IE7.

Closes #908