At scale and with long-term projects it requires knowledge, mastery of tools, foresight, experience, intuition, creativity, planning and many judgement calls.
This is not special. The same is true for many other occupations. Be it carpentry, electrical engineering, finance or, yes, even marketing.
In a lot of ways it is easier than others, because (non-architectural) mistakes can be corrected a lot more quickly, and there is a plethora of (often free) learning materials, knowledge resources, tools and and projects to build on that other fields can only dream of.
I think many programmers have minimal experience with other jobs, and assume that coding is somehow more elevated or demanding than other professions, while the reality is quite different.