Nanospace-confinement copolymerization strategy for encapsulating polymeric sulfur into porous carbon for lithium-sulfur batteries.