Wisely, she followed the local customs there.

Literal

She [topic-は] sensibly there [possessive-の], customs [target-に] obeyed.

The little phrase 賢明にも ('wisely-enough,' 'sensibly enough as one would say') is built from the na-adjective 賢明 ('wise, sensible') in adverbial form 賢明に, then capped with も to add an evaluative, almost editorializing nuance. The same template — adverb + も — generates many comments-from-the-narrator phrases: 親切にも ('kindly enough'), 不注意にも ('carelessly'), 愚かにも ('foolishly'). 風習 specifically means 'local customs / folk practices' — the lived, regional habits of a community, not capital-T Tradition. 従う always takes its target with に, never を: you obey 'to' a rule, not obey 'it.' The orphan comma after そこの is unusual punctuation, a slight pause before 風習に従った.