Html – How do I use CSS to select a "cousin" element
I have the following (simplified) HTML <ul class="sidenav"> <li class="tree-node"> <a href="url"> <span class="submenu-toggle-container">Text</span> </a> <ul class="accordion-menu"> <li class="HideMenu">.......</li> </ul> </li> <li class="tree-node">...</li> </ul> I am trying to use CSS to hide the .submenu-toggle-container span when the sibling is ul…