Kin discrimination and demography modulate patterns of sexual conflict