<xsl:template match=" m:* [
not(self::m:math)
and
child::m:mstyle[
@mathvariant
and
child::text()
and
(count(child::m:*) = 0)
]
and
(count(child::m:*) = 1)
and
not(@mathvariant)
] " >
<xsl:copy>
<xsl:apply-templates select="@*" />
<xsl:apply-templates select="m:mstyle/@*" />
<xsl:apply-templates select="m:mstyle/text()" />
</xsl:copy>
</xsl:template>
-_-_-