ping nas works but dig nas says NXDOMAIN. That is not a DNS problem: dig ignores the search domains in /etc/resolv.conf unless you tell it otherwise.
Add +search, and +showsearch if you want to see each attempt:
dig +search nas
dig +showsearch nas
With a search home.example line in resolv.conf, dig now tries nas.home.example and returns that answer. +showsearch prints every name it tried along the way, which shows the order in which the domains are tried.
I think this is the most common reason people distrust dig on a LAN. The ndots setting decides when the search list kicks in. A name with fewer dots than ndots (1 by default) gets the search domains appended first. You can override it for one query with +ndots=2. Kubernetes pods use ndots:5, which is why a lookup of api.example.com inside a pod first tries several cluster domains; that is a nice thing to see with +showsearch.
dig reads /etc/resolv.conf itself. On systems with systemd-resolved that file may point at the stub resolver, and per link search domains live in resolved, so resolvectl query nas can still give a different answer than dig. On macOS dig also misses domains set per network service; scutil --dns shows those.
Further reading: dig manual (BIND 9), resolv.conf(5) man page
Going deeper: Guide: dig for beginners, look up DNS records and read the answer