Everyone writes screenplays in their own way. But if you ask people who not only write but also sell, you repeatedly encounter similarities in the work process: Nobody sits down and starts writing: EXT. HOUSE - DAY - Arthur comes out the door, etc. The screenplay is always the last stage.
At the beginning stands the inspiration, a seed around which associations gather. William Faulkner, for example, wrote The Sound and the Fury because he saw before him the image of a little girl who had climbed into a tree at night to look into the lit kitchen of her parents' house, while her brothers lurked below at the trunk, waiting to hear what she had to report. This entire scene does not appear in the novel. The girl (Caddy) never appears directly either; she is only spoken about. And yet the entire novel is built only around her.
The seed doesn't need to appear in the story that has crystallized around it.
For the next four to six months, the author then has no more than three pages in front of them: one for each act. On these three pages, the story's rhythm of conflict is developed scene by scene, with each scene described in just a few sentences.
During this time, much is written: biographies, backstory, and so on. But the story itself is limited to three pages. These three pages are, by the way, barely comprehensible to anyone who hasn't written them themselves, making them a private tool.
Once the structure is finally finished, you go to friends and tell them the story. If they react, you know you have a story. They must react to the narration. The widespread error is to believe that only a screenplay can say everything. A story that fails as a narration will also fail as a screenplay. And a structure, even just a brief synopsis, can be meaningful.
You can tell whether you have a story by the audience's reactions while you're telling it. The best result you can achieve is that when you finish, the listener simply remains silent.
The next step is the treatment, which writes out the individual scenes but without dialogue (dialogue is written last of all; the moment you start writing dialogue, the creative process has stopped!). The treatment method comes from Hollywood. There, the original treatments had 200 to 300 pages; the assumption was that the screenplay had to be written "down" from the treatment (to 90 to 120 pages). The treatment was more extensive than the screenplay because it also spelled out the subtext (what really motivates the characters but what they conceal in the screenplay). This is how the professional still handles it today. The treatment is the place for subtext. You should allow one month for its completion.
Now—as the last step—you write the dialogue, or rather, you don't really need to write it any more: the characters, whose mouths you've held shut for so long, begin to speak on their own.