/* Surroundings: items one under another, without cards. Wide screens: the
 * picture on the left of odd items and on the right of even ones, the title
 * and text beside it. Phones: the picture above the text. */
.features {
  display: grid;
  gap: 72px;
}

.feature {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 56px;
  align-items: center;
}

.feature:nth-child(even) .feature-media {
  order: 2;
}

/* Without a picture the text keeps a readable line length. */
.feature.no-media {
  grid-template-columns: minmax(0, 1fr);
  max-width: 760px;
}

/* Scroll reveal (base.css): the text follows its picture a moment later. */
.feature-text[data-reveal] {
  --reveal-delay: .12s;
}

.feature-media img {
  width: 100%;
  aspect-ratio: 4/3;
  object-fit: cover;
  border-radius: 10px;
  background: var(--line);
}

.feature h3 {
  font-size: clamp(1.4rem, 2.4vw, 1.8rem);
}

.feature .desc {
  margin-top: 14px;
  line-height: 1.7;
}

.feature .desc p:last-child {
  margin-bottom: 0;
}

@media (max-width: 760px) {
  .features {
    gap: 48px;
  }

  .feature {
    grid-template-columns: minmax(0, 1fr);
    gap: 20px;
  }

  .feature:nth-child(even) .feature-media {
    order: 0;
  }
}
