Inflation and changing consumer habits forced companies to get creative in terms of maintaining margins, and pet food is going strong.