What's a trademark?
Technically, trademarks and brands are just words that companies tells to their customers. Like IDs and numbers in a price list, but here lies roots of the problem known as "what is genuine and what is not".
If you will put a margarine in a box with picture of a cream-milk butter and start to sell it, people eventually will hate both you and your fake butter. Sooner or later, they will realize that it is a poison full of omega 6 trans fat (because it is a margarine from cotton oil, and omega 6 TF is a poison), and will start to buy 25%-fat baked milk and 50%-fat butter with a true vengeance (both contains a saturated fat, which keeps temperature of human body close to 36.6 C). They will treat your product as "not genuine" and will never buy it again.
To understand this particular example, you could read a book "Fat for Fuel" by Joseph Mercola. But there are same problems with other goods and services, from chocolate and green tea to clothes and shoes, from ballroom dances and relaxing music to... for example, software.
So... despite you would prefer to keep API compatibility, don't imitate other's trademark (including icons, fonts and colors) because people will feel that "this is not a genuine software".