/* Reading layout, scoped to documentation so the homepage remains unchanged. */
.doc-layout {
    gap: clamp(24px, 3vw, 48px);
    padding-block: 32px 64px;
}

.doc-sidebar {
    height: auto;
    max-height: calc(100dvh - 120px);
    padding: 20px;
}

.doc-sidebar__disclosure > summary {
    padding: 4px 0 12px;
    color: var(--text-color);
    border-bottom: 1px solid var(--doc-sidebar-border);
    font-size: .9rem;
    font-weight: 700;
    cursor: pointer;
}

.doc-sidebar__disclosure > summary:focus-visible {
    outline: 2px solid var(--link-color);
    outline-offset: 5px;
    border-radius: 3px;
}

.doc-layout .doc-content {
    width: 100%;
    max-width: 920px;
    padding: 0;
    text-align: left;
    background: none;
}

.doc-layout .doc-content section {
    padding: 0;
    text-align: left;
    background: none;
}

.doc-layout .doc-content h1 {
    font-size: clamp(2rem, 3.8vw, 3.25rem);
    line-height: 1.12;
    margin-bottom: 20px;
}

.doc-layout .doc-content h2::after {
    left: 0;
    transform: none;
}

.doc-content > p,
.doc-section > p,
.doc-section > ul,
.doc-section > ol {
    max-width: 75ch;
}

.doc-content .doc-section {
    margin-top: 32px;
}

.doc-content .doc-section h2 {
    margin-top: 0;
    margin-bottom: 18px;
}

@media (max-width: 992px) {
    .doc-layout {
        gap: 28px;
        padding-top: 20px;
    }

    .doc-sidebar {
        margin: 0;
        padding: 14px 18px;
        max-height: none;
        border: 1px solid var(--doc-sidebar-border);
    }

    .doc-sidebar__disclosure:not([open]) > summary {
        padding-bottom: 4px;
        border-bottom: 0;
    }
}
