XF 1.5 Fixing 11-year old vB URLs for xF via HTACCESS

I hope you can help me sort this out. I am converting my 11-year old vBulletin 3.8 forum to xenForo 1.5 and would like to create some redirects that will minimize any loss of backlinks. Here is a list of example URLs currently used on my vB forum:

Forum root installation: /community/
Forum category: /community/#category-name/ (it does not go to a separate page, but automatically scrolls to the category)
Forum name: /community/carpet-q-and-a/ (this is accomplished the same way using the optional URL Portion in the node tree)
Thread name: /community/carpet-q-and-a/20776-need-help-with-new-carpet.html (I understand xF doesn't use the forum name or the .html extension in the URL, so I need to redirect that to /community/thread/20776-need-help-with-new-carpet/)
Thread name with additional pages: /community/carpet-q-and-a/20776-need-help-with-new-carpet-2.html (note the -2 added to the thread title - so I would have to redirect that in a similar fashion to the previous rule, or just redirect to the first page of a multi-page thread)

Can you help me out with some example htaccess rules? Would I need a separate rule for threads in a specific forum? Will it be possible to create URLs that use the thread ID at the beginning of the thread slug and with a dash instead of a dot?

Thanks for any help you can provide.