Using appropriate `data-` attributes would be preferable to checking classes. If you added a new class to these divs, for instance (or possibly even reordered the existing classes), all this code would have to change.