Evolution is not arithmetic. There is only so much data available in genetic material. The genes for gills are not available to dogs. There are genetic boundaries that have never been observed being crossed. When science begins to pontificate about the unobserved, it is no longer science but guesswork.
What? Why would a plant become a mammal?
Evolution teaches we came from the same single-celled organism. Plants came before animals. Therefore we came from plants. So you tell me why a plant would become a mammal.