diff --git a/src/scss/global.scss b/src/scss/global.scss index abc54481..9e14d2dd 100644 --- a/src/scss/global.scss +++ b/src/scss/global.scss @@ -21,6 +21,13 @@ body { .main-content { contain: content; // see https://www.w3.org/TR/2018/CR-css-contain-1-20181108/#valdef-contain-content padding-top: var(--main-content-pad-top); + + @supports not (contain: content) { + // For browsers which don't support the "contain" CSS property, + // make a stacking context manually so that the z-index behavior + // is consistent. See: https://github.com/nolanlawson/pinafore/issues/1806 + isolation: isolate; + } } main {