Added is-dark comparison function