1<div id="container">
2 <div id="cube">
3 </div>
4</div>
5
6//If the cube is directly inside the container:
7#container:hover > #cube { background-color: yellow; }
8
9//If cube is next to (after containers closing tag) the container:
10#container:hover + #cube { background-color: yellow; }
11
12//If the cube is somewhere inside the container:
13#container:hover #cube { background-color: yellow; }
14
15//If the cube is a sibling of the container:
16#container:hover ~ #cube { background-color: yellow; }