.learn-page {
  margin-top: -80px;
  color: #292929;
  background: #fff;
}

.learn-page__hero {
  min-height: 487px;
  background: #f7faff;
}

.learn-page__hero-inner {
  position: relative;
  width: min(calc(100% - 40px), 1000px);
  min-height: 487px;
  margin-inline: auto;
}

.learn-page__hero-copy {
  padding-top: 152px;
}

.learn-page__hero h1 {
  width: fit-content;
  margin: 0;
  font-size: 38px;
  font-weight: 700;
  line-height: 46px;
}

.learn-page__subtitle {
  width: fit-content;
  margin: 20px 0 0;
  font-size: 28px;
  font-weight: 700;
  line-height: 34px;
}

.learn-page__marker {
  display: block;
  width: 150px;
  height: 5px;
  margin-top: 8px;
  border-radius: 999px;
  background: #ffec39;
}

.learn-page__lead {
  width: 651px;
  max-width: 100%;
  margin-top: 27px;
  font-size: 16px;
  font-weight: 400;
  line-height: 19px;
}

.learn-page__lead p {
  margin: 0;
}

.learn-page__lead p + p {
  margin-top: 19px;
}

.learn-page__hero-image {
  position: absolute;
  top: 173px;
  right: 13px;
  width: 350px;
  height: 263px;
  object-fit: contain;
}

.learn-page__contents {
  min-height: 400px;
  padding: 85px 20px;
  background: #fff;
}

.learn-page__grid {
  display: grid;
  width: min(100%, 1000px);
  margin-inline: auto;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
}

.learn-card {
  display: grid;
  min-width: 0;
  min-height: 230px;
  grid-template-columns: 200px minmax(0, 1fr);
  gap: 10px;
  padding: 15px 15px 15px 10px;
  overflow: hidden;
  color: #292929;
  background: #fff;
  box-shadow: 0 4px 15px rgb(0 0 0 / 15%);
  text-decoration: none;
}

.learn-card:focus-visible {
  outline: 3px solid var(--color-blue);
  outline-offset: 4px;
}

.learn-card__image {
  display: block;
  width: 200px;
  height: 200px;
  overflow: hidden;
  border-radius: 10px;
}

.learn-card__image img {
  width: 200px;
  height: 200px;
  object-fit: cover;
}

.learn-card__body {
  display: flex;
  min-width: 0;
  flex-direction: column;
  padding-top: 20px;
}

.learn-card__body h2 {
  margin: 0;
  font-size: 16px;
  font-weight: 700;
  line-height: 24px;
}

.learn-card__description {
  position: relative;
  display: block;
  margin-top: 30px;
  padding-top: 5px;
  font-size: 14px;
  font-weight: 700;
  line-height: 24px;
}

.learn-card__description::before {
  position: absolute;
  top: 0;
  left: 0;
  width: 35px;
  height: 2px;
  background: #292929;
  content: "";
}

.learn-card--no-image {
  grid-template-columns: minmax(0, 1fr);
  padding-left: 15px;
}

@media (max-width: 1023px) {
  .learn-page__hero,
  .learn-page__hero-inner {
    min-height: 0;
  }

  .learn-page__hero {
    padding-bottom: 50px;
  }

  .learn-page__hero-copy {
    padding-top: 100px;
  }

  .learn-page__hero-image {
    position: static;
    width: 350px;
    height: auto;
    margin: 30px auto 0;
  }

  .learn-page__contents {
    min-height: 0;
    padding-block: 50px;
  }

  .learn-page__grid {
    grid-template-columns: minmax(0, 490px);
    justify-content: center;
  }
}

@media (max-width: 899px) {
  .learn-page {
    margin-top: -50px;
  }
}

@media (max-width: 599px) {
  .learn-page__hero-inner {
    width: min(calc(100% - 28px), 365px);
  }

  .learn-page__hero-copy {
    padding-top: 80px;
  }

  .learn-page__hero h1 {
    font-size: 30px;
    line-height: 42px;
  }

  .learn-page__subtitle {
    font-size: 22px;
    line-height: 33px;
  }

  .learn-page__lead {
    line-height: 1.7;
  }

  .learn-page__lead p + p {
    margin-top: 1.7em;
  }

  .learn-page__hero-image {
    width: min(100%, 350px);
  }

  .learn-page__contents {
    padding: 35px 14px 50px;
  }

  .learn-page__grid {
    width: min(100%, 365px);
    grid-template-columns: minmax(0, 1fr);
    gap: 20px;
  }

  .learn-card {
    min-height: 0;
    grid-template-columns: minmax(0, 1fr);
    justify-items: center;
    padding: 15px;
  }

  .learn-card__body {
    width: 100%;
    padding-top: 10px;
  }

  .learn-card__description {
    margin-top: 20px;
  }
}

@media (max-width: 374px) {
  .learn-page__hero h1 span {
    display: block;
  }
}
