I was just going through a chapter and noticed this heading doesn't "balance ragged lines." Hmph.
I was sure I had set that in the paragraph style. I checked, and indeed it was set for "Balance Ragged Lines" in the paragraph style. Hmph. I said to myself, "I'll just manually fix it with a line but not paragraph break after the colon" and it looked fine. Until I looked at the Table of Contents and that line break was there in the Table of Contents, messing it up. Hmph.
I did a bit of experimenting. If you note the headers at the top, and read https://community.adobe.com/t5/indesign/option-make-subsection-headers-not-persist-beyond-their-ends..., I have the heading styled with the do-nothing HeadText1 character style, a space after the heading's text styled with the do-nothing HeadText2 character style, and a space after that styled with the do-nothing HeadText3 character style. As you can see from the headers, this prevents the H3 heading from the previous page, styled with the do-nothing HeadText3 character style, from showing up in this page's headers.
However… and I tested this… it's those spaces that break the Balance Ragged Lines.
Why would a space at the end of the line break this? I bounced the idea around in my head for a reason, and couldn't come up with this. I suspect it's a bug and not a feature. If anyone can suggest a workaround, or Adobe can fix it in the next version of InDesign, I would appreciate it.