When the cooler fan is connected, the bottom USB-C port is only used for charging, so your scenario won't work. If you really want to keep the fan connected while your phone is in your pocket, you could look for 3.5 mm earphones with a 90 degree angle connector.