<!DOCTYPE html><title>Variable substitution in @position-try rules</title><linkrel="help"href="https://drafts.csswg.org/css-anchor-1/#fallback"><scriptsrc="/resources/testharness.js"></script><scriptsrc="/resources/testharnessreport.js"></script><scriptsrc="/resources/check-layout-th.js"></script><scriptsrc="support/test-common.js"></script><style>.cb{position:relative;width:195px;height:70px;background:yellow;border-bottom:1pxsolidblack;}.spacer{width:1px;height:20px;}.anchor1{anchor-name:--a1;margin-left:45px;width:100px;height:30px;background:blue;}.target{position:absolute;position-try-fallbacks:--fallback1;width:40px;height:15px;margin:5px;background:orange;--left:anchor(--a1right);--top:anchor(--a1top);}.fallback1{position-try-fallbacks:--fallback1;}.fallback2{position-try-fallbacks:--fallback2;}@position-try--fallback1{/* Position to the right of the anchor. */left:var(--left);top:var(--top);}/* Same as above, but using a shorthand. */@position-try--fallback2{inset:var(--top)0px0pxvar(--left);}</style><bodyonload="checkLayoutForAnchorPos('.target')"><divclass="cb"><divclass="spacer"></div><divclass="anchor1"></div><divclass="target fallback1"data-offset-x=150data-offset-y=25></div></div><divclass="cb"><divclass="spacer"></div><divclass="anchor1"></div><divclass="target fallback2"data-offset-x=150data-offset-y=25></div></div></body>