Creating a scroll-spy with two lines of CSS

Two incredible lines of CSS code to reflect the current scroll position in a table of contents, by Una Kravets: Creating a scroll-spy with 2 lines of CSS . This required JavaScript coding in the past.