Try shifting the css cell to the end to see if this fixes the nbviewer issue.