I am not new to CSS, and I know there is a simple solution to this, but I just cannot find it anywhere (I am drawing a blank on the solution).
I have the following code:
<p class="paragraph">
blablabla, some text here!
<ol>
<li class="nobullet">
<p class="bold">Related Articles</p>
</li>
<li><a href="/">ArticleName</a></li>
<li><a href="/">ArticleName</a></li>
<li><a href="/">ArticleName</a></li>
<li><a href="/">ArticleName</a></li>
</ol>
</p>
<p class="footer">
<ol>
<li class="nobullet">
<p class="bold">Non-Related Articles</p>
</li>
<li><a href="/">ArticleName</a></li>
<li><a href="/">ArticleName</a></li>
<li><a href="/">ArticleName</a></li>
<li><a href="/">ArticleName</a></li>
</ol>
</p>
I want to add the rule "color:red" to only the list items in the ordered list within the paragraph element with the class of "paragraph" (So only the first Ordered List).
I have tried...
.paragraph ol li{color:red;}
.paragraph, ol, li{color:red;}
The second one works; however, it also styles the other OL element as well!
Thanks in advance!