Normally you calculate range as follows: replace unknown characters by "1", decode, it will be your starting range. Then add 58^unknown characters (in your case 21?), if you add to starting range you will have the end range for search.
Keep in mind that this method is only accurate when the missing characters are all at the end since the farther away they get from the end, the bigger the range is going to be compared to the actual range of missing characters. Take the following private key for example:
L2QCuJrrk5c5VrD1xEPzHVYQf3hv4UoSUejn8fZ6mKXdXCUt19vs
If the last character is replaced by 1 and then incremented by 1 (...19v1 to ...19v2) the integer values are the following:
809a96095dbbf6e7fddf52b0c06f96c1e107723599a4059d0d081db68f0c2c740901c8f9def2
809a96095dbbf6e7fddf52b0c06f96c1e107723599a4059d0d081db68f0c2c740901c8f9def3
The difference between these two numbers is 100% accurate and equal to 1 (we incremented by 1)
Now lets say the missing character is the second from the right, and we repeat the same thing (...191s to 192s):
809a96095dbbf6e7fddf52b0c06f96c1e107723599a4059d0d081db68f0c2c740901c8f9d322
809a96095dbbf6e7fddf52b0c06f96c1e107723599a4059d0d081db68f0c2c740901c8f9d35c
The difference is now less accurate and equal to 58.
Now lets take a random character in the middle and repeat the same thing again (..UoS1ejn8... to ...UoS2ejn8...):
809a96095dbbf6e7fddf52b0c06f96c1e107723599a4058c695c4030531c07c151f5a0c1df24
809a96095dbbf6e7fddf52b0c06f96c1e107723599a4058d07203ee971c61c13ca844ce9df24
Now the difference is huge and equal to 3199866632452173458088315935260672 while it was only 1 character and we only incremented the character by 1.