Improves navigation on narrow viewports by moving the TOC into the article and collapsing long lists with a show more/less toggle.
Prevents duplicate TOCs and reduces scroll “fighting” by disposing/reinitializing scrollspy on resize and keeping auto-scrolling behavior limited to the right-side desktop panel.
Keeps heading permalink icons visible by allowing horizontal overflow.
Prevents long code blocks and tables from overlapping the page TOC by enabling horizontal scrolling where needed.
Prevents long paths, links, and inline code from overflowing into the page TOC.
Stabilizes the two-column layout by defining grid areas, keeping breadcrumbs full-width, and forcing content to respect column width so wide elements don’t render under the TOC.
Improves TOC readability by adding a background and stacking context when content still overflows.