New insights into the structure and phase transitions of polymers