>Do I need a still larger monitor?
I don't know, maybe you need to advance to as modern an approach as you can get.
But no more modern than necessary.
I'm not a software professional but I do produce reliable code from time to time.
What's worked for me in Windows has been pretty well tried and proven over the long term, and may be somewhat similar to your situation.
With me it would be a terminal, Notepad (in lieu of IDE), and file manager and I want to juggle 3 as fast as possible without dropping the ball. Very often :\
For HTML add a browser (or two).
Whether it's building and filing pages of code or manually testing scripts which can get pretty tedious, what seems to work the best these days is overlapping windows where part of each window is always visible and available for you to drop back to it. Carefully arranged so the bit you click on to bring each window to the forefront brings it up without triggering any unintended action.
You almost never use the whole screen for any one window, but when you do that's a more deliberate event, which is the kind of thing you expect as an interruption to a muscle-memory workflow anyway.
You're not the first one to wish for a bigger screen, but really needs a system capable of working OK with lesser size and resolution, as well as working outstanding with any truly halfway decently sized modern monitor.
Check out this page for an example, the top picture says it all ;)
Focused tasks go on other workspaces but with the same kind of stacking. The browser windows usually multiply onto the 2nd screen off tot he left for those, with documentation and references.
I used to use "focus follows mouse" but ive lost some dexterity over the past couple years and slowing down with "click to focus" has helped cope with that.
I use a 43" 4K TV as a monitor, with six virtual desktops. Seems enough surface area for me. At the moment, anyway.
You can put a different 'task' in each desktop: email in one, the normal browser in another, 3 or 4 xterms doing program development in yet another, and so on.
From there I just hold the Windows key and press one of the numpad keys to flip that screen to that virtual desktop. It helps that Sway is tiling by default, and so everything begins maximized.