I'm paining to make a custom miner from scratch
You mean "assembling" a custom miner I suppose.
or maybe is there a way to just solve math problems on a paper to mine bitcoin?
Mining isn't solving math problems, people who use that term to explain how mining works either have no clue or are just trying to come out with the simplest explanation for the average joe to digest which is fine for those who don't care much about how mining actually works, but the reality is mining is all about guessing a random number, the faster you can make and submit your guess the higher chances of winning a block.
So if you want to mine using a piece of paper and then type that hash on your PC and broadcast it to the network, nobody will stop you, a hash is a hash and it will always have a chance of hitting a block, but then I am afraid by that by the time you put the pen down and start typing it on your keyboard, someone else will hit a block and then the hash of the previous block changes which will make your paper hash completely useless with 0% chances to hit a block.