.toc-container {
    position: sticky;
    top: var(--header-height);
    background-color: var(--main-background);
    z-index: 2;

}

.admin-bar .toc-container {
    top: calc(var(--header-height) + 32px);
}



.toc-container-title {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem var(--container-space);
    /* background-color: var(--border-color); */
    border-bottom: 1px solid var(--border-color);
}

.toc-container-title-name {
    font-size: 1rem;
    font-weight: 500;
    line-height: 140%;
    text-transform: uppercase;
}

.toc-list-items {
    list-style: none;
    margin: 0;
    padding: 0;
}

.toc-container.toc-open .toc-container-title {
    background-color: transparent;
}



.toc-container-items {
    display: flex;
    flex-direction: column;
    margin: 0;
    padding: 0;
}


.toc-container-items ul {
    margin: 0;
    padding: 0;
}

.toc-container-items li {
    list-style-type: none;
}

.toc-container-items>li:last-child {
    border-bottom: none;
}

.toc-container-items>li>ul a {
    font-size: 0.875rem;
}

.toc-container-items li a {
    display: flex;
    /* color: #ffffff80; */
    line-height: 140%;
    width: calc(100% - 2rem);
}

.toc-level-2 {
    border-bottom: 1px solid var(--border-color);
    /* background-color: var(--border-color); */
}

.toc-level-2.toc-open {
    background-color: transparent;
}

.toc-item-name {
    display: flex;
}

.toc-item-name-level-2 {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.5rem var(--container-space);
}

.toc-ul-level-2 li.toc-level-3 {
    padding: 0.5rem 1.75rem 0.25rem 3.25rem;
}

.toc-list-items>.toc-level-3 {
    padding: 0.5rem var(--container-space);
    border-bottom: 1px solid var(--border-color);
}

.toc-ul-level-2 li.toc-level-3:last-child {
    padding-bottom: 1rem;
}


.toc-item a {
    color: #666;
    max-width: calc(100% - 2rem);
}

.toc-plus,
.toc-plus-title {
    width: 1.5rem;
    height: 1.5rem;
    padding: 0.2rem;
    cursor: pointer;
}

.toc-plus>div,
.toc-plus-title>div {
    position: relative;
    display: flex;
    width: 100%;
    height: 100%;
}

.toc-plus>div div,
.toc-plus-title>div div {
    position: absolute;
    top: 50%;
    left: 0;
    height: 1px;
    width: 100%;
    background-color: var(--main-text-color);
}

.toc-item>div>div.toc-plus>div div:nth-child(2),
.toc-item>div>div.toc-plus-title>div div:nth-child(2) {
    transition: transform 0.3s;
    transform: rotate(90deg);
}

.toc-item.toc-open>div>div.toc-plus>div div:nth-child(2),
.toc-item.toc-open>div>div.toc-plus-title>div div:nth-child(2) {
    transform: rotate(0deg);
}






.toc-container ul {
    max-height: 0;
    overflow: hidden;
    transition: max-height 200ms ease-in-out;
}

.toc-item.toc-open>ul {
    max-height: none;
    list-style: none;
    padding: 0;
}



@media screen and (max-width: 782px) {
    .admin-bar .toc-container {
        top: calc(var(--header-height) + 46px);
    }
}


@media (max-width: 1100px) {}

@media (max-width: 992px) {}

@media (max-width: 768px) {}