The physical image size limit for .jpeg compression is 65,535 pixels, this applies to any file format that uses >jpeg compression.

If you need to capture an image that is too large to work with .jpeg you can instead use .tiff with deflate or G4 compression.

Architecturally there is only one limit in the PDF standard: the overall file size must be below ~10GB as the cross-reference tables which define the PDF structure use 10 bits.

A workaround could be to scan at a lower resolution to say 200dpi with a file format as TIFF.  Use a different compression (or no compression),