Can I use ":hover" effect to affect html tag which is higher in the nesting hierarchy? I am trying to affect element's CSS property by hovering over element lover in the hierarchy. As in example below. HTML example
<div>
<ul>
<li>
<a>link</a>
</li>
</ul>
</div>
CSS example /* Usualy this is how we use it */
ul>li{
color:red;
}
/* How can I use it other way round? */
li>div{
color:blue;
}
/* or ? */
li>ul{
color:yellow;
}
/* or ? */
a>div{
color:black;
}
Examples most welcome. Thank you very much guys.