[data-component-id='ecore_common:image_card'] {
  background-color: #fff;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
  overflow: hidden;
  width: 100%;
  transition: box-shadow 0.2s ease;

  &:hover {
    box-shadow: 0 8px 28px rgba(0, 0, 0, 0.2);
  }

  /* The entire card is the link. */
  a {
    display: block;
    text-decoration: none;
    color: inherit;
  }

  .image {
    width: 100%;
    /* Fixed height to match prod's .casestudy-image (avoids the 16/9 image
       ballooning when the grid stacks to one column). Responsive values below
       mirror the live breakpoints. */
    height: 225px;
    overflow: hidden;

    img {
      display: block;
      width: 100%;
      height: 100%;
      object-fit: cover;
      object-position: center;
      transition: transform 0.3s ease;
    }
  }

  &:hover .image img {
    transform: scale(1.03);
  }

  .text {
    padding: 28px 32px 32px;
  }

  .heading {
    font-family: Geomanist, sans-serif;
    font-weight: 700;
    font-size: 20px;
    line-height: 1.3;
    color: #363940;
    /* Room for the accent bar below the title (matches prod). */
    position: relative;
    margin: 0 0 32px;

    /* Accent bar below the card header — grey by default, brand orange on
       hover, mirroring the prod .casestudy-title treatment. */
    &::after {
      content: '';
      display: block;
      position: absolute;
      left: 0;
      bottom: -16px;
      width: 55px;
      height: 3px;
      background-color: #f1f1f1;
      transition: background-color 0.3s ease;
    }
  }

  &:hover .heading::after {
    background-color: #f44604;
  }

  .summary {
    font-family: Silka, sans-serif;
    font-weight: 400;
    font-size: 15px;
    line-height: 1.6;
    color: #54555a;
    margin: 0 0 16px;
  }

  .link {
    font-family: Silka, sans-serif;
    font-weight: 600;
    font-size: 14px;
    color: #002bff;
    display: inline-block;
    margin-top: 4px;

    &::after {
      content: ' \2192';
    }
  }

  /* Live breakpoints for the image height. */
  @media (max-width: 782px) {
    .image {
      height: 155px;
    }
  }

  @media (max-width: 640px) {
    .image {
      height: 200px;
    }

    .text {
      padding: 20px 24px 24px;
    }

    .heading {
      font-size: 18px;
    }
  }
}
