<div>
<p>text</p>
<p>
<span>text>span</span>
</p>
<span>span</span>
</div>
/* 選取 div 裡面所有的 span */
div span {
color: blue;
}
/* 只會選取 div 下一層的 span */
div > span {
color: red;
}
This Pen doesn't use any external CSS resources.
This Pen doesn't use any external JavaScript resources.