Can Maine Dems gerrymander its congressional districts so both voted for Biden without sacrificing either seat?
Sure, by moving Lewiston into district 1 and moving some coastal areas north/east of Portland into district 2. This would make both districts D-leaning.
This isn’t as easy as you think. Portland City (obviously) and then South Portland/Brunswick are the bulk of Democratic strength in the First District, most of the other outlying/coastal areas are also fairly D but not as strongly D (except for Yarmouth, Falmouth, Cumberland) or not as populous. There’s no way you can add enough D areas of CD-1 into CD-2 to make CD-2 reliably Democratic-leaning without risking a far more competitive CD-1. it’s mostly a matter of population and Portland's geographic location, although the maps wouldn’t be clean either -- you can add Brunswick but Portland/South Portland is more difficult and obviously not a compact map/a blatant gerrymander.