mailserver: fix notmuch-flag-sync Seen flag detection
The grep patterns (',.*S' and '-v ,.*S') matched Dovecot's size
metadata (,S=7520) instead of the actual Maildir Seen flag after :2,.
This prevented read status from propagating from notmuch to IMAP.
Replace grep-based filtering with case statements that check the
flags field after :2, correctly.