Before her marriage, her surname was Smith.

Literal

She [topic-は] before-marriage Smith surname was.

姓 ('surname, family name') is the more formal counterpart of 名字, the everyday word — 姓 turns up in legal documents, biographical writing, and discussions of marriage and naming. The sentence implicitly carries the cultural weight of Japan's 夫婦同氏 system, which legally requires a married couple to share one surname; in practice this almost always means the woman takes her husband's name, and her pre-marital surname becomes her 旧姓 ('former surname'). Some Japanese women now use 旧姓 professionally even after marriage.