Is there a way to "have an idea" of the number of seconds the routers
can remain ON after the AC goes down?
You want to hold the 12 volt DC on for a period of time using a capacitor so, the first limitation of this idea is that the voltage will instantly start to droop once the power is removed. But that isn't necessarily a show-stopper if the router can survive all the way down to 10 volts. It will be taking a roughly constant current as the capacitor is supplying the rapidly drooping voltage and this might be (say) 1 amp (just for numerical convenience).
The formula: -
$$I = C\dfrac{dv}{dt}$$
So, dv will be the change in voltage (say 2 volts) and dt will be the time allowed for it to droop (say 2 seconds). Hence: -
$$1\text{ amp} = C\dfrac{2\text{ volts}}{2\text{ seconds}}$$
Or, rearranging, C = 1 farad.
That's quite large (supercap sort of size) so pick carefully. If your current is only 100 mA then a 0.1 farad capacitor would hold up a drooping supply of 12 volts for 2 seconds. If only 1 second is required then 50,000 uF would do the job.
But, it all comes down to how low a voltage can you tolerate on your router before it gives up the ghost?
One idea is to place 10x electrolytic caps of 10.000uF x 16V on the
12V output out the adapter (supply input of WiFi router), a nominal
100.000uF capacitance.
Very unlikely to be anywhere near enough. You are probably about a thousand times too small.