snip
I'm curious about this myself.
Manure is grass and plant life that has passed through a cows digestive tract. In theory it might be possible to harvest grass and process it through an acidic decompositional state similar to a cow's digestion to produce unlimited amounts of organic fertilizer. It is very easy to get nitrogen and carbon from compost and decomposing plant life. The more difficult to obtain nutrients are phosphorous and other elements more commonly associated with fertilizers...
snip
I don't even garden but got curious about this since I live on a nation of islands so I've always wondered what will happen to agriculture if every island got isolated from each other. You are right, nitrogen is easier to get and even possible when practicing organic farming by planting legumes. P and K, not so sure.
I know that seaweeds are used for fertilizer but I don't know what nutrients are in there. If commercial synthetic fertilizers became unavailable for some reason maybe seaweed harvesting would become a viable business. Maybe collecting guano as well. Countries would also probably start mining their deposits though that's unsustainable, as the fate of Nauru has shown.