Sublattice entanglement and quantum phase transitions in antiferromagnetic spin chains