Hello
Thank you for posting in Q&A forum
If you can success using A domain account login to B domain , it means that your domain set is correct .
But still they say access denied . so can you test to add this A domain trust account into B domain enterprise admin group to see if it can work (enterprise admin means in the forest range)
If it can work, you can try to add it to domain admin , or local admin limit the right range.
How trusts work for Microsoft Entra Domain Services - Microsoft Entra ID | Microsoft Learn
Best regards
Yanhong
=====================================
If the answer is helpful, please click "Accept answer" and upvote it