Modal second, infinitive last
In I can swim well today, the two verbs sit next to each other. German pulls them apart: the modal takes position two, the infinitive goes to the very end, and everything else goes in between. The two verbs form a bracket around the rest of the sentence, the Satzklammer.
The bracket
The bracket getting wider
Ich kann schwimmen.
I can swim.
Ich kann gut schwimmen.
I can swim well.
Ich kann heute leider nicht gut schwimmen.
Unfortunately I can't swim well today.
Darf ich mit Karte bezahlen?
May I pay by card?
Questions keep the bracket
The infinitive stays at the end in questions too. In a yes/no question the modal moves to the front; in a W-question it comes right after the question word.
Musst du morgen früh arbeiten?
Do you have to work early tomorrow?
Wann sollen wir uns morgen treffen?
When shall we meet tomorrow?
Wie lange müssen wir hier warten?
How long do we have to wait here?
Where nicht goes
When you deny the whole sentence, nicht usually sits right in front of the infinitive, inside the bracket.
Ich kann heute nicht kommen.
I can't come today.
Ich kann dir heute nicht helfen.
I can't help you today.
Hier darf man nicht rauchen.
You're not allowed to smoke here.