.toc-container {
    /* border: 2px solid var(--color-1st,#bc2749); */
    /* display: table; */
    font-size: 95%;
    margin-bottom: 1em;
    padding: 20px;
    width: auto;
    background: #f4f4f4;
}

.toc-container.contracted {
    width: 100%;
}

.toc-container > ul {
    display: block !important;
    margin: 0 0;
    list-style-type: none;
    padding-left: 0;
}

.toc-container li {
    margin-bottom: 10px;
}

.toc-container li:last-child {
    margin-bottom: 0;
}

.toc-container > ul > li > a {
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 10px;
    display: block;
}

.toc-container > ul > li > ul {
    list-style-type: none;
    padding-left: 0;
}

.toc-container p.toc_title {
    font-weight: 700;
    margin-bottom: 20px !important;
    font-size: 20px;
}

.toc-container p.toc_title a:hover,
.toc-container p.toc_title a:visited,
.toc-container p.toc_title ul a:hover,
.toc-container p.toc_title ul a:visited {
    color: var(--color-1st, #bc2749);
}

.toc-container span.toc_toggle {
    font-size: 90%;
    font-weight: 400;
    display: none;
}

.toc-container span.toc_toggle .d-none {
    display: none;
}

.toc-container.toc-sidebar {
    width: 300px;
    max-width: 100%;
    flex: 0 0 300px;
    position: -webkit-sticky;
    position: sticky;
    top: 115px;
    max-height: calc(100vh - 40px);
    overflow-y: auto;
    margin-bottom: 0;
}

.toc-columns-wrapper {
    display: flex;
    align-items: flex-start;
    gap: 24px;
}

.toc-columns-wrapper .toc-content-column {
    flex: 1 1 0;
    min-width: 0;
}

@media (max-width: 767px) {
    .toc-columns-wrapper {
        flex-direction: column;
    }

    .toc-columns-wrapper .toc-container.toc-sidebar {
        position: static;
        width: 100%;
        max-width: 100%;
        max-height: none;
        overflow-y: visible;
        margin-bottom: 1em;
    }
}

/*
 * "minimal" style: a plain, unboxed list — typically used for a sticky
 * "in this article" sidebar nav next to a "boxed" style main ToC.
 */
.toc-container.toc-style-minimal {
    background: transparent;
    padding: 0;
}

.toc-container.toc-style-minimal p.toc_title {
    text-align: left;
    text-transform: uppercase;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.05em;
    color: #9ca3af;
    margin-bottom: 16px !important;
}

.toc-container.toc-style-minimal > ul {
    margin: 0;
    display: grid !important;
}

.toc-container.toc-style-minimal > ul > li > a {
    font-size: 14px;
    font-weight: 400;
    color: #374151;
    margin-bottom: 12px;
}

.toc-container.toc-style-minimal > ul > li > a:hover {
    color: var(--color-1st, #bc2749);
}
