/* Shared page and nested scrollbars in the MoveWell palette. */
/* Keep the content width stable when switching between short and long pages. */
html {
    overflow-y: auto;
    scrollbar-gutter: stable;
}
@supports not (scrollbar-gutter: stable) {
    html { overflow-y: scroll; }
}
:root {
    --scrollbar-track: #eef7f1;
    --scrollbar-thumb: #648b76;
    --scrollbar-hover: #0e4d31;
}
html[data-theme='dark'] {
    --scrollbar-track: #14251c;
    --scrollbar-thumb: #78a88d;
    --scrollbar-hover: #0e4d31;
}
html, body * {
    scrollbar-width: auto;
    scrollbar-color: var(--scrollbar-thumb) var(--scrollbar-track);
}
/* Chromium/WebKit expose thumb hover and rounded track styling. */
@supports selector(::-webkit-scrollbar) {
    html, body * { scrollbar-color: auto; }
    ::-webkit-scrollbar { width: 12px; height: 12px; }
    ::-webkit-scrollbar-track { background: var(--scrollbar-track); }
    ::-webkit-scrollbar-thumb {
        background: var(--scrollbar-thumb);
        border: 3px solid var(--scrollbar-track);
        border-radius: 12px;
        min-height: 40px;
    }
    ::-webkit-scrollbar-thumb:hover { background: var(--scrollbar-hover); }
    ::-webkit-scrollbar-thumb:active { background: #198751; }
    ::-webkit-scrollbar-corner { background: var(--scrollbar-track); }
    ::-webkit-scrollbar-button { display: none; width: 0; height: 0; }
}
/* Preserve operating-system contrast choices. */
@media (forced-colors: active) {
    html, body * { scrollbar-color: auto; }
    ::-webkit-scrollbar-track, ::-webkit-scrollbar-corner { background: Canvas; }
    ::-webkit-scrollbar-thumb { background: ButtonText; border-color: Canvas; }
}
