I like to perform a selection of the first and last element which does not contain the class hidden.
<div class="gallery-cell hidden"></div>
<div class="gallery-cell hidden"></div>
<div class="gallery-cell"></div>
<div class="gallery-cell"></div>
<div class="gallery-cell"></div>
<div class="gallery-cell"></div>
<div class="gallery-cell hidden"></div>
<div class="gallery-cell hidden"></div>
This works for me to catch all elements.
But how do I get only the first and last?
.gallery-cell:not(.hidden){
opacity:0.2 !important;
}
Pure css would be awesome.