[subject] + 竟然 + [verb phrase]
[subject] + 竟然 + [adjective]
竟然 says that what happened goes against what the speaker expected. It sits after the subject, before the verb or adjective, and the surprise can be pleasant or not.
The first clause often sets up the expectation, so the second can overturn it.
In writing, 竟 alone does the same job.
English puts "surprisingly" at the front. 竟然 normally follows the subject.
A sentence with no subject, or with a time word in front, can start with 竟然.
居然 has the same meaning and is a little more spoken; 果然 is the opposite, "just as expected".