I have a complex websites which consists of containers. My goal is to check a class on a div container if the class is "active" and if so, I need to color another container which is "far" outside of that container. So the Code looks like this:
.tooltip:has(tooltip > div.active)~main-view>div.colorme {
  background: orange
}<div class="tooltip">
  <tooltip>
    <div class="active">
      My tooltip is active
    </div>
  </tooltip>
</div>
<div class="othercontainer">
</div>
<main-view>
  <div class="colorme">
    Test
  </div>
</main-view>And I want to color the div with class colorme as soon as the <tooltip> tag has a container with class active. I am not sure if this is in general possible, but I thought I could build something like this.
 
     
     
    