Dogs can tell fear from sadness — and scientists saw it in their brains