/* Learner Stories page */

/* Independent from .info-blocks (44rem) — tune this value on its own. */
.ls-content {
  max-width: 44rem;
  margin: 0 auto;
}

.ls-page-title {
  margin: 2rem 0 1.5rem;
  font-size: 2rem;
  text-align: center;
}

.ls-intro .wp-block-heading.is-style-h2-turquoise {
  margin: 0 auto 1.75rem auto;
  padding: 0 0 1rem 0;
  border-bottom: 2px dotted currentColor;
  color: var(--turquoise);
  font-size: clamp(2rem, 1.6vw + 1.2rem, 2.4rem);
  line-height: 1.2;
  font-weight: 700;
}

.ls-story-card {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 1rem;
  text-align: left;
  /* background-color: var(--bg-color); */
  background-color: var(--light-orange);
  border-radius: 1rem;
  padding: 0 0 1.5rem;
  margin: 0 0 2rem;
  max-width: 58rem;
  overflow: hidden;
  border: 3px var(--mid-orange) solid;
}

.ls-story-card:focus {
  outline: none;
}

/* Highlighted on arrival via anchor link — matches .course-item--highlighted.
     No transition: fixes outline not painting until next interaction.
     :focus variant needed since .ls-story-card:focus (2 selectors) otherwise
     beats this rule's specificity while JS-focused on landing. */
.ls-story-card--highlighted,
.ls-story-card--highlighted:focus {
  /* outline: 3px solid var(--pink); */
  outline: 3px solid var(--pink);
  outline-offset: 3px;
}

/* Scroll-margin tuned per breakpoint by eye — page layout above the card
     (breadcrumbs, intro heading) differs from the course archive, so values
     won't match .course-item--highlighted's. 80rem confirmed working at 24px;
     fill in the others the same way. */
@media (min-width: 37.5rem) and (max-width: 63.9375rem) {
  /* 600px–1023px */
  .ls-story-card--highlighted {
    scroll-margin-top: 24px; /* TODO: tune */
  }
}

@media (min-width: 64rem) and (max-width: 79.9375rem) {
  /* 1024px–1279px */
  .ls-story-card--highlighted {
    scroll-margin-top: 24px; /* TODO: tune */
  }
}

@media (min-width: 80rem) {
  /* 1280px+ */
  .ls-story-card--highlighted {
    scroll-margin-top: 32px;
  }
}

.ls-story-card__header {
  display: flex;
  flex-direction: column;
}

.ls-story-card__image {
  width: 85%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  display: block;
  margin: 1.5rem auto 1rem;
  border-radius: 0.8rem;
  border: 3px #ffffff solid;
}

.ls-story-card__name p {
  font-weight: 400;
  font-size: 1.25rem;
  margin: 0;
  padding: 0 1.5rem;
}

.ls-story-card__quote {
  display: none;
  /* width: 14rem;
    height: auto;
    color: var(--mid-orange-2);
    padding: 1rem 1.5rem 0;
    margin-bottom: 1rem; */
}

.ls-story-card__text {
  text-align: left;
  padding: 0.25rem 1.5rem 0;
}

.ls-story-card__text > p {
  margin: 0 0 1.125rem;
}

/* Tablet / Desktop — image + name side by side, text row below at full measure */
@media (min-width: 48.0625rem) {
  .ls-story-card__header {
    flex-direction: row;
    align-items: center;
    padding: 2rem 2rem 0;
  }

  .ls-story-card__image {
    width: 240px;
    height: 240px;
    aspect-ratio: 1 / 1;
    flex-shrink: 0;
    margin: 0 3rem 0 0;
    border-radius: 1rem;
  }

  .ls-story-card__name {
    padding: 0;
  }

  .ls-story-card__name p {
    padding: 0;
  }

  /* .ls-story-card__quote {
      padding: 0;
    } */

  .ls-story-card__quote {
    display: block;
    width: 14rem;
    height: auto;
    color: var(--mid-orange-2);
    padding: 1rem 0 0;
    margin-bottom: 1rem;
  }

  .ls-story-card__text {
    padding: 1rem 2rem 0;
  }
}
