Learning Representations Through Contrastive Neural Model Checking