。
She'll sometimes sit perfectly still for hours on end.
Literal
She [topic-は] sometimes how-many-hours [emphatic-も] motionlessly sitting-is [sometimes happens-ことがある].
Three layers stack to convey the duration and stillness: 何時間も ('hours and hours' — interrogative 何 + counter + emphatic も marking a surprisingly large amount), じっと (a 擬態語 for being still and fixed), and 座っている (resulting state, 'is in a sitting position'). The whole sits inside ~ことがある ('there are times when X happens'), framing it as a recurring habit rather than a single observation. Pile-ups like this are what give Japanese its characteristic precision about manner and aspect — three modifiers each doing distinct work.