代码示例:(标识:cssref_justify-items_absolute)
<!DOCTYPE html>
<html>
<head>
<style> 
#container {
  width: 200px;
  aspect-ratio: 2/3;
  border: 1px solid black;
  display: grid;
  position: relative;
  justify-items: right;
}

#container > div {
  border: 1px solid black;
  padding: 10px;
  position: absolute;
}

.blue {
  background-color: lightblue;
  width: 50%;
}

.red {
  background-color: coral;
  width: 40%;
  top: 100px;
}

.green {
  background-color: lightgreen;
  width: 60%;
  top: 200px;
}
</style>
</head>
<body>

<h1>在定位项目上设置 justify-items: right</h1>

<div id="container">
  <div class="red">红色</div>
  <div class="blue">蓝色</div>
  <div class="green">绿色</div>
</div>

</body>
</html>
运行结果: