With perl, finding all sequences of decimal digits and rounding them up to multiple of 4096:
$ echo foo123bar 4095-4097 1e+2 0x1f2 004123 3.4 |
perl -pe 's{\d+}{int(($& + 4095)/4096)*4096}ge'
foo4096bar 4096-8192 4096e+4096 0x4096f4096 8192 4096.4096