I had this exact same problem. I was using all the standard calculations for how much I should eat in order to lose weight and did it for 7 weeks and made very little progress at all.
I was getting pretty discouraged and I had read an article about how some people have more effecient metabolisms then others. Those people can gain mass without eating as much and in order to cut weight they need to eat less then most people. Over the years I have realized that I can gain muscle without eating tons of cals like I see most people do so I figured I may just have a more efficient metabolism.
What I did was basically take my daily caloric intake at the time (2100) and used it as my new maintenance calorie intake since I had been eating that for several weeks without gaining or losing weight.
I then used this to get an estimate of my BF%.
Body-Mass Index, Waist-to-Height Ratio and More...
After that I applied a formula from this article to determine my maximum dietary deficit for fat loss.
Determining the Maximum Dietary Deficit for Fat Loss | Mind and Muscle
I weighed 185 with approx 15% BF. which means I had 27.75lbs of fat * 30 = 832.5 maximum calorie deficit.
My maintenance cals of 2100 - 832 = 1268 cals.
That seemed drastic and I did not feel like doing that non-stop. The other issue was that to maintain an intake of 1268 calories I had to eat almost all protein or my protein level would drop pretty low and maintaining muscle might be hard. so I dropped my calorie intake to 1300 or so cals/day Mon-Fri and during the weekend I eat carbs and basically cheat without going too crazy. I don't count cals on the weekend though. I workout mon/wed/fri and don't do cardio. Once in a while I throw in a workout on Sat/Sun if I feel like it.
On workout days I drink 30grams of dextrose post workout with my protein shake. I also use creatine mono with my postworkout shake. Two hours later I do allow for like 15 or so grams carbs in my after workout meal. On non-workout days I try to keep carbs as low as I can. I eat cottage cheese and almonds which have small amounts of carbs, but that has been fine for me.
So far I have been gaining muscle every week until the most recent week where my reps for DB press stayed the same, but my widegrip pullups still went up. 5wks later I now weigh 174 and my waist is down by 1.5". I am starting to see some abs and I am no longer depressed about being on a diet that is not working.
I honestly thought I was gonna start losing muscle when I did this but I just wanted to try something different because what I was doing before just was not working. I was really happy and a bit surprised when the strength kept edging forward bit by bit while fat was coming off at a nice rate.
I know this plan will not work for most people, but I see that you (like me) are not having success with the diet plan that does work for most people. Hope this info helps you. Good luck, don't give up; you'll find what works for if you keep searching.