CSS code isn't working


#1



https://www.codecademy.com/en/courses/web-beginner-en-WF0CF/1/4?curriculum_id=50579fb998b470000202dc8b#

Oops, try again. Did you remember to bold the introduction and summary paragraphs?

p {
font-family: Garamond;
}
p1 {
font-weight: bold;
}
p5 {
font-weight: bold;
}

p2 {
color:#7ac5cd;
}
li p {
color:#000000
}


Replace this line with your code.


#2

Have a look at the instructions again.. p1, p2, p3 isn't going to work

div > p { /* Some CSS */ }

This only grabs <p>s that are nested directly inside of <div>s; it won't grab any paragraphs that are, say, nested inside lists that are in turn nested inside <div>s.


#3

This is all new to me, BRAND new! Thanks for the tip. I finally figured out I needed div > I just have no clue why


#4

Let me explain to you quickly,

<div>

  <ul>
     <li>
        <p>Some text in a paragraph in a list in a div</p>
     </li>
  </ul>

  <p>Some text in a paragraph in a div</p>

</div>

Have a close look at the above code.

p{
color:red;
//this will select all paragraphs to be red
} 

div > p {
color: red;
//this will select paragraphs that are directly under div(so div in list won't be selected) 
} 

//I hope you understand now :)

#5

Okay yeah that makes sense, thank you sir!