Rule: Selecting exact positions of children is fragile and so avoid doing it.
You don't need to call out a child's position.
Use document order so that instead of this:
<xsl:template match="description"> <div> <xsl:apply-templates select="p[1]"/> <xsl:apply-templates select="p[2]"/> <xsl:apply-templates select="p[3]"/> </div> </xsl:template>
do this:
<xsl:template match="description"> <div> <xsl:apply-templates select="p"/> </div> </xsl:template>
Example: doc-order.xml no-doc-order.xsl doc-order.xsl