It has gotten much better in the pandemic. I pay at the bakery etc with cards. Not sure when I last paid enything with cash. Only caveat is that "cards" not always means Visa/MC/AmEx, but can mean Girocard only. If that is the case (and I'd just ask) then you as a non German will have to pay cash.