* {
  box-sizing: border-box;
}

body {
  display: flex;
  align-items: center;
  flex-direction: column;
  margin-bottom: 20vh;
}

h2 {
  margin-bottom: 10px;
}

section {
  width: 100%;
  max-width: 600px;
}

.demo {
  margin: 30px 0;
}

.demo img {
  width: 100%;
  max-width: 600px;
  display: block;
}

.demo a {
  margin-left: 20px;
}

.preview > a > div {
  width: 100%;
  height: 375px;
  overflow: hidden;
}

.preview iframe {
  width: 1600px;
  height: 1000px;
  transform: scale(0.375);
  transform-origin: 0 0;
  pointer-events: none;
  margin: 0 auto;
}

.preview > nav {
  width: 100%;
  margin-top: 1em;
  display: flex;
  justify-content: flex-end;
  gap: 1em;
  font-size: small;
}

.preview > nav > a {
  color: #ccc;
  background-color: #1a1a1a;
  border-radius: 50%;
  height: 4.5em;
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
}

.preview .mobile {
  overflow: hidden;
  background-color: lime;
}
.preview .mobile > iframe {
  width: 400px;
  height: 800px;
  transform: scale(0.375);
  transform-origin: 0 0;
  pointer-events: none;
  margin: 0 auto;
}
.preview.grid {
  display: grid;
  gap: 0.5rem;
}

.grid div {
	width: min-content;
}

.grid .desktop {
	grid-row: 1;
	grid-column: 1;
}
.grid .mobile {
	grid-row: 1;
	grid-column: 2;
}

.grid nav {
  grid-row: 2;
  grid-column: 1/-1;
}
