.table-of-contents .toc-outline-toggle {
    width: 100%;
    background: none;
    border: 0;
    padding: 0;
    color: inherit;
    font: inherit;
    text-align: start;
    cursor: pointer;
}

.table-of-contents.is-collapsed .toc-outline-toggle {
    margin-bottom: 0;
}

.table-of-contents .toc-chevron {
    display: inline-block;
    width: 0.45rem;
    height: 0.45rem;
    margin-inline-start: auto;
    flex-shrink: 0;
    border-inline-end: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: rotate(45deg);
    transition: transform 0.15s ease;
}

.table-of-contents.is-collapsed .toc-chevron {
    transform: rotate(-45deg);
}

.table-of-contents.is-collapsed .toc-outline-body {
    display: none;
}

.toc-thread {
    display: flex;
    align-items: stretch;
    gap: 0.5rem;
}

.toc-thread.is-leaf {
    gap: 0;
}

.toc-thread-rail {
    flex: 0 0 12px;
    display: flex;
    justify-content: center;
}

.toc-collapse-line {
    position: relative;
    width: 12px;
    padding: 0;
    border: 0;
    background: none;
    cursor: pointer;
    align-self: stretch;
}

.toc-collapse-line::before {
    content: "";
    position: absolute;
    inset-block: 0.35rem 0.15rem;
    inset-inline-start: 50%;
    width: 2px;
    margin-inline-start: -1px;
    border-radius: 1px;
    background: var(--vr-gray-250);
    transition: width 0.12s ease, margin-inline-start 0.12s ease, background-color 0.12s ease;
}

.toc-collapse-line:hover::before,
.toc-collapse-line:focus-visible::before {
    width: 4px;
    margin-inline-start: -2px;
    background: var(--vr-gray-450);
}

.toc-thread-main {
    flex: 1 1 auto;
    min-width: 0;
}

.toc-thread-toggle {
    cursor: pointer;
    user-select: none;
}

.toc-thread.is-collapsed > .toc-thread-main > [data-title] > .toc-thread-fold,
.toc-thread.is-collapsed > .toc-thread-main > .toc-thread-fold {
    display: none;
}

.container-toc .toc-thread .ul-toc-content-sub {
    padding-inline-start: 0;
    padding-left: 0;
    padding-right: 0;
}

.container-toc .li-toc-content.toc-thread {
    margin-bottom: 0.75rem;
}

.container-toc .li-toc-content-main.toc-thread {
    margin-bottom: 1.25rem;
}

[data-bs-theme="dark"] .toc-collapse-line::before {
    background: var(--vr-gray-700);
}

[data-bs-theme="dark"] .toc-collapse-line:hover::before,
[data-bs-theme="dark"] .toc-collapse-line:focus-visible::before {
    background: var(--vr-gray-400);
}

[data-bs-theme="dark"] .table-of-contents,
[data-bs-theme="dark"] .table-of-contents .title,
[data-bs-theme="dark"] .table-of-contents .title h2,
[data-bs-theme="dark"] .table-of-contents ul,
[data-bs-theme="dark"] .table-of-contents ul li,
[data-bs-theme="dark"] .table-of-contents ul li::marker,
[data-bs-theme="dark"] .table-of-contents ul li a {
    color: var(--vr-color-white);
}

[data-bs-theme="dark"] .container-toc .title-post-item,
[data-bs-theme="dark"] .container-toc .title-post-item::marker {
    color: var(--vr-color-white);
}
