Ritual or offering for sin?
See Leviticus 12:1-8. Pay special attention to verse 6.
Was the OT not covered in seminary?
Mary made a sin-offering because it was mandated in the Law. Doing so was not a profession of personal sin. FAILING to do so WOULD have been a sin.
Attempting to make this passage into evidence for Mary’s sinfulness is abuse of Scripture. There is no basis for the assertion that this passage was intended by the author to answer that question.