I have had an “unread” smart mailbox in Mail for some years. The criteria are unread and not in various mailboxes. Until recently, it’s worked fine. It continues to work perfectly on my laptop, which is still running Sierra, but on my iMac, which has High Sierra, it’s behaving very oddly. All the appropriate unread messages are there, but so are quite a few which I have read. It knows I’ve read them, as they appear in normal rather than bold face in the list of messages (I use the old style display), but they won’t disappear.
I haven’t found any pattern to which remain and which, correctly, aren’t shown. They come from each of my three accounts and are of various ages. Many which don’t appear are more recent.
I’ve tried rebuilding the smart mailbox, deleting it and recreating it, quitting Mail, restarting the Mac, etc etc. It’s been going on for several months now.
Here are some screenshots. Any ideas gratefully received.