<!DOCTYPE html>
<html class=reftest-wait>
<title>::backdrop inherits style from the fullscreen element</title>
<link rel=match href="backdrop-green-ref.html">
<link rel=help href="https://github.com/whatwg/fullscreen/issues/124">
<script src="/resources/testdriver.js"></script>
<script src="/resources/testdriver-vendor.js"></script>
<style>
body {
  --bg: red;
}
div {
  --bg: green;
}
div::backdrop {
  background: var(--bg);
}
</style>
<div></div>
<script>
document.addEventListener('fullscreenchange', () =>