.testr-toc {
    --testr-toc-text: #17191d;
    --testr-toc-muted: #62656b;
    --testr-toc-hover: #fafafa;
    --testr-toc-active: #f6f6f6;
    --testr-toc-gold: #f3c566;
    width: 100%;
    overflow: hidden;
    border: 0;
    border-radius: 0;
    background: #ffffff;
    color: var(--testr-toc-text);
    font-family: inherit;
}

.testr-toc__toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    width: 100%;
    margin: 0;
    padding: 17px 18px;
    border: 0;
    border-radius: 0;
    background: #ffffff;
    color: var(--testr-toc-text);
    font: inherit;
    text-align: left;
    cursor: pointer;
}

.testr-toc__title {
    font-size: var(--testr-toc-title-size, 16px);
    font-weight: var(--testr-toc-title-weight, 700);
    line-height: 1.3;
    letter-spacing: .01em;
}

.testr-toc__arrow {
    flex: 0 0 auto;
    width: 8px;
    height: 8px;
    border-right: 1.5px solid var(--testr-toc-gold);
    border-bottom: 1.5px solid var(--testr-toc-gold);
    transform: rotate(45deg) translateY(-2px);
}

.testr-toc.is-open .testr-toc__arrow {
    transform: rotate(225deg) translate(-2px, -2px);
}

.testr-toc__content {
    background: #ffffff;
}

.testr-toc--hide-title .testr-toc__toggle {
    display: none;
}

.testr-toc__list {
    display: flex;
    flex-direction: column;
    gap: 1px;
    max-height: calc(100vh - 150px);
    margin: 0;
    padding: 8px 8px 10px;
    overflow-y: auto;
    list-style: none;
}

.testr-toc__item {
    margin: 0;
    padding: 0;
}

.testr-toc__link {
    position: relative;
    display: block;
    padding: 5px 9px 5px 13px;
    border-radius: 4px;
    color: #444444;
    font-family: inherit;
    font-size: 14px;
    line-height: 1.25;
    text-decoration: none;
    transition: background-color .18s ease, color .18s ease;
}

.testr-toc__link::before {
    position: absolute;
    top: 5px;
    bottom: 5px;
    left: 0;
    width: 3px;
    border-radius: 2px;
    background: transparent;
    content: "";
}

.testr-toc__link:hover,
.testr-toc__link:focus-visible {
    background: var(--testr-toc-hover);
    color: var(--testr-toc-text);
    text-decoration: none;
}

.testr-toc__link.is-active {
    background: var(--testr-toc-active);
    color: var(--testr-toc-text);
}

.testr-toc__link.is-active::before {
    background: var(--testr-toc-gold);
}

.testr-toc__item--h2 .testr-toc__link {
    font-size: var(--testr-toc-h2-size, 14px);
    font-weight: var(--testr-toc-h2-weight, 600);
}

.testr-toc__item--h3 .testr-toc__link {
    padding-left: 25px;
    font-size: var(--testr-toc-h3-size, 13px);
    font-weight: var(--testr-toc-h3-weight, 400);
}

.testr-toc-target {
    scroll-margin-top: 104px;
}

.testr-toc__empty {
    margin: 0;
    padding: 13px 18px 16px;
    color: var(--testr-toc-muted);
    font-size: 13px;
}

@media (min-width: 960px) {
    .testr-toc__toggle {
        cursor: default;
    }

    .testr-toc__arrow {
        display: none;
    }

    .testr-toc__content {
        display: block !important;
    }
}

@media (max-width: 959px) {
    .testr-toc__content {
        display: none;
    }

    .testr-toc.is-open .testr-toc__content {
        display: block;
    }

    .testr-toc.testr-toc--hide-title .testr-toc__content {
        display: block;
    }

    .testr-toc__list {
        max-height: 55vh;
    }
}

@media (prefers-reduced-motion: reduce) {
    .testr-toc__link {
        transition: none;
    }
}
