I am struggling with CSS combinators, especially when dealing with nested div, ul, and li elements.
My issue involves changing the CSS of a div with the class "H" when hovering over li elements with the class "G". Since all of this is contained within a single div with the class "A", I assume this can be accomplished using only CSS. However, I cannot seem to figure out the syntax. I am also open to exploring any JavaScript solutions.
The HTML code snippet is as follows:
<div class="A">
<div class="B otherClasses">
<div class="C otherClasses">
<div class="D otherClasses">
...SOMECODE...
</div>
<div class="E otherClasses">
<ul class="F otherClasses">
<li>...SOMECODE...</li>
<li>...SOMECODE...</li>
<li class="G">...SOMECODE...</li>
<li class="G">...SOMECODE...</li>
<li class="G">...SOMECODE...</li>
<li>...SOMECODE...</li>
<li class="G">...SOMECODE...</li>
</ul>
</div>
</div>
</div>
<div class="H"></div>
</div>