/** * TOC - Table of Contents * used as a page index, recent posts block */ @use "../variables" as variables; main { .toc { max-width: 15rem; min-width: 14rem; margin-left: var(--s1); } .toc-item { padding: .4rem 0; color: var(--f1); } .toc-item a, .toc-item-child a { color: var(--f1); &:hover { cursor: pointer; color: var(--a2); text-decoration: underline; } } .toc-item a.active, .toc-item-child a.active { color: var(--a2); } .toc-item-child { padding: 0 var(--s1); color: var(--f1); } } .toc-sticky { border-radius: var(--br); border-top: 5px solid var(--a1); background-color: var(--c2); position: sticky; top: var(--s2); margin-top: var(--s2); padding: 0 var(--s2) var(--s2); max-height: 100vh; overflow: auto; } @if map-get(variables.$breakpoints, "md") { @media (max-width: map-get(variables.$breakpoints, "md")) { .toc { display: none; } } }