Mazda Repair Questions? Ask Mechanics for Answers ASAP
This would have to be an issue with the clutch master cylinder or the slave cylinder. If you are unable to change gears with the engine running that indicates the clutch is not doing it's job. Because it's not happening all the time, this tells me the actual clutch on the car is not the issue. There is either an air bubble in the hydraulics for the clutch, or the parts that make it work are failing. Sadly, it is probably going to have to get worse to be diagnosed properly.
I would ask the dealer to try bleeding the clutch master cylinder and slave cylinder. Then drive the car and see if the condition persists. If it does, the I would wait until it's consistent enough to have them actually feel the problem and get you squared away. I know it's a hassle to do that of course, but in this case it might be the only way to get it sorted without just replacing a bunch of parts.
Please let me know what more I can do to assist you today. Also, please remember to rate my answer, Just Answer does not compensate me for my time and resources. Follow up questions are included in the price of your question. If you are using the free trial, or have a subscription a rating is still required.Thank you so much!