<section>
<h2>top right</h2>
<div class="section image bg-top-right"></div>
</section>
<section>
<h2>right bottom</h2>
<div class="section image bg-right-bottom"></div>
</section>
xxxxxxxxxx
body {
display: grid;
grid-gap: 30px;
grid-template-columns: 1fr 1fr;
font: 14px/1.5 monospace;
}
.section {
height: 200px;
background: #ffeb3b;
}
.image {
background-image: url("https://assets.codepen.io/1425525/Hexlet_Logo-01-svg__1_.png");
background-repeat: no-repeat;
}
.bg-top-right {
background-position: top right;
}
.bg-right-bottom {
background-position: right bottom;
}
This Pen doesn't use any external CSS resources.
This Pen doesn't use any external JavaScript resources.