<!doctype html>
<title>CSS Container Queries Test: query of inline-size container is affected by min-width property</title>
<link rel="help" href="https://drafts.csswg.org/css-conditional-5/#container-queries">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="support/cq-testcommon.js"></script>
<style>
#container {
container-type: inline-size;
min-width: 200px;
width: fit-content;
}
@container (min-width: 200px) {
#child { color: green }
}
</style>
<div id="container">
<div id="child">Green</div>
</div>
<script>
setup(() => assert_implements_container_queries());
test(() => {
assert_equals(getComputedStyle(child).color, "rgb(0, 128, 0)");
}, "min-width of inline-size container affects container size");
</script>