/* Offering: NextOne India Growth Portfolio. Shared tokens and components come from
   styles.css; of- = offering. */

/* Why 20–25 businesses: the heading beside one sentence */
.of-focus {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: 16px 64px;
  align-items: baseline;
}
.of-focus h2 {
  margin: 0;
}
.of-focus p {
  font: 400 clamp(1.3rem, 2.3vw, 1.65rem) / 1.4 var(--font-serif);
  color: var(--heading);
  max-width: 24em;
  margin: 0;
  text-wrap: pretty;
}

/* Each quality card spans three rows of the grid (icon, name, text) through subgrid, so the
   texts in a row start level even where one name wraps to two lines */
.of-qualities > li,
.of-qualities .card {
  grid-row: span 3;
  display: grid;
  grid-template-rows: subgrid;
  row-gap: 0;
}

/* Is it for you? Three short cards */
.of-fit {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}

@media (max-width: 860px) {
  .of-focus {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 760px) {
  .of-fit {
    grid-template-columns: 1fr;
  }
}

/* Phones: one card per row, so each quality's icon sits beside its name to save height. With
   one card per row there is nothing to line up, so the cards leave the subgrid (its third row
   would stay empty here and add space under the text). */
@media (max-width: 680px) {
  .of-qualities > li {
    grid-row: auto;
    display: flex;
  }
  .of-qualities .card {
    grid-row: auto;
    grid-template-rows: none;
    display: grid;
    grid-template-columns: auto 1fr;
    align-items: center;
    column-gap: 14px;
  }
  .of-qualities .icon-tile {
    margin: 0;
  }
  .of-qualities .card h3 {
    margin: 0;
  }
  .of-qualities .card p {
    grid-column: 1 / -1;
    margin-top: 12px;
  }
}
