/* Shared article navigation. Editorial labels and destinations stay in each page. */
.article-toc {
    min-width: 0;
    color: #374151;
    font-size: 1rem;
    line-height: 1.35;
}
.article-toc .article-toc__disclosure { position: relative; }
.article-toc .article-toc__toggle {
    display: inline-flex;
    align-items: center;
    justify-content: space-between;
    box-sizing: border-box;
    gap: .75rem;
    width: 100%;
    max-width: 100%;
    min-height: 44px;
    padding: .75rem 1.25rem;
    border: 1px solid #2c3e50;
    border-radius: .5rem;
    background: #2c3e50;
    color: #fff;
    cursor: pointer;
    font-weight: 600;
    overflow-wrap: anywhere;
    list-style: none;
}
.article-toc__toggle::-webkit-details-marker { display: none; }
.article-toc .article-toc__toggle:hover { background: #1f2937; }
.article-toc .article-toc__toggle:focus-visible { outline: 2px solid #1d4ed8; outline-offset: 2px; }
.article-toc .article-toc__toggle::after {
    content: "";
    flex: 0 0 .45rem;
    height: .45rem;
    border: solid currentColor;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}
.article-toc__disclosure[open] > .article-toc__toggle::after { transform: rotate(225deg); }
.article-toc .article-toc__items {
    position: absolute;
    z-index: 20;
    inset-inline: 0;
    max-height: min(60vh, 24rem);
    overflow: auto;
    overscroll-behavior: contain;
    box-shadow: 0 .5rem 1.5rem rgb(44 62 80 / 16%);
    display: grid;
    gap: 0 .75rem;
    margin: .5rem 0 0;
    padding: .125rem .5rem;
    border: 1px solid #e5e7eb;
    border-radius: .75rem;
    background: #fff;
    list-style: none;
}
.article-toc .article-toc__items > li { margin: 0; min-width: 0; padding: 0; }
.article-toc .article-toc__link {
    display: flex;
    align-items: center;
    min-height: 44px;
    box-sizing: border-box;
    padding: .25rem .375rem;
    border-radius: .25rem;
    color: #2474a8;
    font-weight: 400;
    line-height: 1.35;
    overflow-wrap: anywhere;
    text-decoration: none;
}
.article-toc .article-toc__link:hover,
.article-toc .article-toc__link:focus-visible {
    background: #eaf2f8;
    color: #2c3e50;
    text-decoration: none;
}
.article-toc .article-toc__link:focus-visible { outline: 2px solid #2474a8; outline-offset: -2px; }
.article-toc[data-toc-numbered] .article-toc__items { counter-reset: toc; }
.article-toc[data-toc-numbered] .article-toc__link::before {
    counter-increment: toc;
    content: counter(toc) ".";
    flex: 0 0 1.75rem;
    align-self: flex-start;
    color: #374151;
}
[data-article-toc-target] { scroll-margin-top: 12rem !important; }
@media (min-width: 640px) {
    .article-toc .article-toc__items { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (min-width: 768px) {
    .article-toc .article-toc__toggle { width: auto; }
}
