<!DOCTYPE html>
<meta charset="utf-8" />
<title>CSS Selectors Invalidation: :nth-child(... of sibling)</title>
<link rel="author" title="Steinar H. Gunderson" href="sesse@chromium.org">
<link rel="match" href="nth-child-of-sibling-ref.html">
<link rel="help" href="https://drafts.csswg.org/selectors-4/#child-index">
<style>
  p:nth-child(even of .a + .b) {
    color: green;
  }
</style>
<div>
  <p>Ignored</p>
  <p class="a" id="toggler">Ignored</p>
  <p class="b">Selectively ignored</p>
  <p class="a">Ignored</p>
  <p class="b">Not ignored</p>
  <p class="a">Ignored</p>
  <p class="b">Not ignored</p>
  <p class="a">Ignored</p>
</div>
<script>
  document.documentElement.offsetTop;
  toggler.classList.toggle("a");
</script>

