/* Authored \n breaks are desktop-only; below the site's mobile breakpoint
   (navbar switch, 1280px) the text reflows naturally. */
@media (max-width: 1280px) {
  br.multiline-br {
    display: none;
  }
}

.nm-details {
  width: 100%;
  padding: 63px 30px;
  box-sizing: border-box;
  background: #fcfcfc;
  color: #18141e;
  font-family: "Mona Sans", "Helvetica Neue", Arial, sans-serif;
}

/* Header column : cards = 484 : 851 with a 45px gap (484+45+851 = 1380) */
.nm-details__inner {
  display: grid;
  grid-template-columns: minmax(0, 484fr) minmax(0, 851fr);
  column-gap: 45px;
  align-items: start;
  width: min(1380px, 100%);
  margin-inline: auto;
}

.nm-details__badge {
  display: inline-block;
  margin-bottom: 34px;
  padding: 3.5px 17.5px;
  border-radius: 81.25px;
  background: #e6ece9;
  font-size: 13px;
  font-style: normal;
  font-weight: 500;
  line-height: 16.25px;
  letter-spacing: 0.1em;
  text-align: center;
  text-transform: uppercase;
}

.nm-details__title {
  margin: 0;
  font-size: 60px;
  font-style: normal;
  font-weight: 500;
  line-height: 70px;
  letter-spacing: 0;
}

.nm-details__description {
  max-width: 506px;
  margin: 44px 0 0;
  font-size: 16px;
  font-style: normal;
  font-weight: 400;
  line-height: 20px;
  letter-spacing: 0;
}

/* ---------- Cards column ---------- */

.nm-details__cards {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.nm-details__cards slot {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.nm-details__cards slot::slotted(*) {
  display: contents;
}

/* ---------- Card ---------- */

/* Icon column : content = 276 : 509 with the 66px gap (276+66+509 = 851) */
.nm-detail-card {
  display: grid;
  grid-template-columns: minmax(0, 276fr) minmax(0, 509fr);
  column-gap: 66px;
  padding: 33px 45px 33px 33px;
  box-sizing: border-box;
  border-radius: 20px;
  background: linear-gradient(155.46deg, #fcfcfc 0%, #e6ece9 100%);
  color: #18141e;
  font-family: "Mona Sans", "Helvetica Neue", Arial, sans-serif;
}

.nm-detail-card__icon-column {
  display: flex;
  align-items: center;
  justify-content: center;
}

.nm-detail-card--icon-top .nm-detail-card__icon-column {
  align-items: flex-start;
}

.nm-detail-card--icon-bottom .nm-detail-card__icon-column {
  align-items: flex-end;
}

/* Text column vertical alignment (Figma centers it on description cards) */
.nm-detail-card--content-center .nm-detail-card__content {
  align-self: center;
}

.nm-detail-card--content-bottom .nm-detail-card__content {
  align-self: end;
}

.nm-detail-card__icon {
  max-width: 200px;
  max-height: 200px;
  object-fit: contain;
}

.nm-detail-card__title {
  margin: 0;
  font-size: 27px;
  font-style: normal;
  font-weight: 400;
  line-height: 1.2;
  letter-spacing: 0;
}

/* List body: one row per \n line, hairlines between title and rows */
.nm-detail-card__list {
  margin: 16px 0 0;
  padding: 0;
  list-style: none;
}

.nm-detail-card__item {
  padding: 14px 0;
  border-top: 1px solid rgba(24, 20, 30, 0.2);
  font-size: 16px;
  font-style: normal;
  font-weight: 400;
  line-height: 1;
  letter-spacing: 0;
}

.nm-detail-card__item:last-child {
  padding-bottom: 0;
}

/* Description body */
.nm-detail-card__body {
  margin: 16px 0 0;
  font-size: 16px;
  font-style: normal;
  font-weight: 400;
  line-height: 1.2;
  letter-spacing: 0;
}

/* ---------- Same breakpoint as the navbar: header stacks above cards ---------- */

@media (max-width: 1280px) {
  .nm-details__inner {
    grid-template-columns: 1fr;
  }

  .nm-details__header {
    margin-bottom: 38px;
  }

  /* With a description the header sits closer to the cards (from Figma) */
  .nm-details__header:has(.nm-details__description) {
    margin-bottom: 19px;
  }

  /* Stacked header spans the section; the desktop-column cap comes off */
  .nm-details__description {
    max-width: none;
  }
}

/* ---------- Mobile ---------- */

@media (max-width: 767px) {
  .nm-details {
    padding: 32px 15px;
  }

  .nm-details__badge {
    margin-bottom: 19px;
  }

  .nm-details__title {
    font-size: 32px;
    line-height: 1.1;
  }

  .nm-details__description {
    margin-top: 19px;
    font-size: 14px;
    line-height: 18px;
  }

  /* Small icon stays beside the text on mobile, pinned top-left */
  .nm-detail-card {
    grid-template-columns: 90px 1fr;
    column-gap: 28px;
    padding: 28px 19px;
  }

  .nm-detail-card__icon-column {
    align-items: flex-start;
    justify-content: flex-start;
  }

  .nm-detail-card__icon {
    max-width: 90px;
    max-height: 96px;
  }

  .nm-detail-card__title {
    font-size: 20px;
  }

  .nm-detail-card__item {
    padding: 10px 0;
    font-size: 14px;
  }

  .nm-detail-card__body {
    font-size: 14px;
    line-height: 18px;
  }
}


@keyframes nm-details-reveal {
  from {
    opacity: 0;
    transform: translateY(36px);
  }

  to {
    opacity: 1;
    transform: none;
  }
}

.nm-details-reveal .nm-details__inner {
  opacity: 0;
}

.nm-details-reveal.is-revealed .nm-details__inner {
  animation: nm-details-reveal 850ms cubic-bezier(0.4, 0, 0.2, 1) 100ms both;
}

@media (prefers-reduced-motion: reduce) {
  .nm-details-reveal .nm-details__inner {
    opacity: 1;
    animation: none;
  }
}


@keyframes nm-detail-card-reveal {
  from {
    opacity: 0;
    transform: translateY(36px);
  }

  to {
    opacity: 1;
    transform: none;
  }
}

.nm-detail-card--reveal {
  opacity: 0;
}

.nm-detail-card--reveal.is-revealed {
  animation: nm-detail-card-reveal 850ms cubic-bezier(0.4, 0, 0.2, 1) 60ms both;
}

@media (prefers-reduced-motion: reduce) {
  .nm-detail-card--reveal {
    opacity: 1;
    animation: none;
  }
}

/* Waterfall: siblings entering together stagger left-to-right */

/* waterfall-nm-detail-card */
:host(:nth-child(2)) .nm-detail-card--reveal.is-revealed,
.nm-detail-card--reveal.is-revealed:nth-child(2) {
  animation-delay: 160ms;
}
:host(:nth-child(3)) .nm-detail-card--reveal.is-revealed,
.nm-detail-card--reveal.is-revealed:nth-child(3) {
  animation-delay: 260ms;
}
:host(:nth-child(4)) .nm-detail-card--reveal.is-revealed,
.nm-detail-card--reveal.is-revealed:nth-child(4) {
  animation-delay: 360ms;
}
:host(:nth-child(5)) .nm-detail-card--reveal.is-revealed,
.nm-detail-card--reveal.is-revealed:nth-child(5) {
  animation-delay: 460ms;
}
:host(:nth-child(6)) .nm-detail-card--reveal.is-revealed,
.nm-detail-card--reveal.is-revealed:nth-child(6) {
  animation-delay: 560ms;
}
:host(:nth-child(7)) .nm-detail-card--reveal.is-revealed,
.nm-detail-card--reveal.is-revealed:nth-child(7) {
  animation-delay: 660ms;
}

/* waterfall-ext-nm-detail-card: items 8+ keep cascading instead of snapping to the base delay */
:host(:nth-child(8)) .nm-detail-card--reveal.is-revealed,
.nm-detail-card--reveal.is-revealed:nth-child(8) {
  animation-delay: 760ms;
}
:host(:nth-child(9)) .nm-detail-card--reveal.is-revealed,
.nm-detail-card--reveal.is-revealed:nth-child(9) {
  animation-delay: 860ms;
}
:host(:nth-child(n + 10)) .nm-detail-card--reveal.is-revealed,
.nm-detail-card--reveal.is-revealed:nth-child(n + 10) {
  animation-delay: 960ms;
}

