Fixing logic around how the css styles are generated