.nimbleaf-toc {
    margin: 0 0 28px;
    border: 1px solid rgba(17, 24, 39, .12);
    border-radius: 10px;
    background: #ffffff;
    box-shadow: 0 14px 36px rgba(15, 23, 42, .08);
    color: #111827;
    overflow: hidden;
}

.nimbleaf-toc__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 15px 18px;
    border-bottom: 1px solid rgba(17, 24, 39, .08);
    background: linear-gradient(135deg, rgba(40, 213, 200, .12), rgba(124, 58, 237, .10));
}

.nimbleaf-toc__header strong {
    color: #111827;
    font-size: 16px;
    line-height: 1.2;
}

.nimbleaf-toc__header button {
    border: 1px solid rgba(17, 24, 39, .12);
    border-radius: 999px;
    background: #fff;
    color: #111827;
    cursor: pointer;
    font-size: 12px;
    font-weight: 800;
    padding: 6px 10px;
}

.nimbleaf-toc__list {
    display: grid;
    gap: 8px;
    margin: 0;
    padding: 16px 18px 18px;
    list-style: none;
}

.nimbleaf-toc__item {
    margin: 0;
    line-height: 1.35;
}

.nimbleaf-toc__item.depth-1 {
    padding-left: 18px;
}

.nimbleaf-toc__item.depth-2 {
    padding-left: 36px;
}

.nimbleaf-toc__item a {
    color: #374151;
    text-decoration: none;
    font-size: 14px;
}

.nimbleaf-toc__item a:hover,
.nimbleaf-toc__item a:focus {
    color: #16a89d;
    text-decoration: underline;
}

.nimbleaf-toc.is-closed .nimbleaf-toc__list {
    display: none;
}

html {
    scroll-behavior: smooth;
}

@media (max-width: 640px) {
    .nimbleaf-toc__header {
        align-items: flex-start;
        flex-direction: column;
    }

    .nimbleaf-toc__header button {
        align-self: flex-start;
    }
}
