Terminal width in columns.
Terminal height in rows.
Hide the terminal cursor.
Show the terminal cursor.
Enter raw mode, enable Kitty level 1 keyboard reporting, enable bracketed paste mode, enable mouse tracking, and hide the cursor.
The framework prefers Kitty semantics but its parser also accepts mixed tmux/legacy keyboard encodings that may still arrive on stdin.
Restore terminal state.
Write a string to the terminal output.
Real terminal using process.stdin/stdout.
Enables Kitty keyboard protocol level 1, bracketed paste mode, SGR mouse tracking, and raw mode. The runtime prefers Kitty semantics for full modifier fidelity, while the parser remains compatible with mixed tmux/legacy keyboard encodings that may still arrive on stdin. All modes are restored on stop/crash.