I checked the css snippet and I’d like to suggest a slight change so that the css customization will affect only the TOC and not the normal numbered lists:
nav.table-of-contents ol { counter-reset: list-item; }
nav.table-of-contents li { display: block; counter-increment: list-item; }
nav.table-of-contents li:before { content: counters(list-item,'.') ' '; }