Handling collaboration requests from the authors of double-blind reviewed papers (after submitting the review)
Given the timeline there is no ethical concern. You don't need to retract your review and you can agree to collaborate.
However, you should decline to review paper A if it goes to a next round. And in the short term you should refrain from telling the authors of your review. I don't see an issue in telling them later, after a final decision is made by others.
You might want to inform the program chair of the situation, giving the timeline. I doubt that they would have any complaint nor any reason to act.
Given what you say, the events seem to be entirely independent. Serendipity happens.