If your concern is which motherboard will perform well, you can go with any. NAS applications are incredibly easy to run. Basically no resources required.
Your biggest issue will be narrowing it down based on port requirements. Then just go with whatever is cheapest. I’d still recommend AM4, because AM5 is still expensive af. It does mean you won’t have any upgrade path, but for what you’re doing, you shouldn’t need to upgrade ever.
If you’re planning on transcoding the media you’re serving, then you may want to think about throwing an A310 in there to handle that.
You could conceivable even just get a used desktop second hand and harvest the parts.