/* Keep the nearest categories readable on narrow screens. */
@media (max-width: 767px) {
  :is(.page-category, .page-product) .breadcrumb__wrapper .breadcrumb {
    flex-wrap: nowrap;
    align-items: center;
    min-width: 0;
    margin: 0;
    padding: 12px 0;
    font-size: 13px;
    line-height: 20px;
  }

  :is(.page-category, .page-product) .breadcrumb__wrapper .breadcrumb-item {
    display: none;
    align-items: center;
    min-width: 0;
    max-width: calc(50% - 6px);
    padding-left: 0;
    white-space: nowrap;
  }

  .page-category .breadcrumb__wrapper .breadcrumb-item:nth-last-child(-n + 2),
  .page-product .breadcrumb__wrapper .breadcrumb-item:nth-last-child(2),
  .page-product .breadcrumb__wrapper .breadcrumb-item:nth-last-child(3) {
    display: flex;
  }

  .page-category .breadcrumb__wrapper .breadcrumb-item:nth-last-child(2) .breadcrumb-angle,
  .page-product .breadcrumb__wrapper .breadcrumb-item:nth-last-child(3) .breadcrumb-angle {
    display: none;
  }

  :is(.page-category, .page-product) .breadcrumb__wrapper .breadcrumb-link,
  :is(.page-category, .page-product) .breadcrumb__wrapper .breadcrumb-item > span:last-child {
    display: block;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  :is(.page-category, .page-product) .breadcrumb__wrapper .breadcrumb-angle {
    flex: 0 0 auto;
    padding: 0 8px;
  }
}
