/* Breadcrumb trail — see breadcrumb/breadcrumb.php */

.breadcrumb {
  margin: 0 0 1.25rem;
  font-size: 0.85rem;
  line-height: 1.4;
}

.breadcrumb-list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.breadcrumb-item {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  color: var(--text-muted);
  min-width: 0;
}

/* The › separator is decoration, not content: drawn in CSS so a screen
   reader (and anything copying the text) doesn't read it out. */
.breadcrumb-item + .breadcrumb-item::before {
  content: "›";
  color: var(--border-strong);
}

.breadcrumb-item a {
  color: var(--text-muted);
  text-decoration: none;
}

.breadcrumb-item a:hover {
  color: var(--primary);
  text-decoration: underline;
}

/* The current page: not a link, and allowed to truncate — product names run
   long, and a wrapped trail pushes the photo below the fold on a phone. */
.breadcrumb-item [aria-current="page"] {
  color: var(--text-soft);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 22rem;
}

@media (max-width: 600px) {
  .breadcrumb {
    font-size: 0.8rem;
    margin-bottom: 1rem;
  }
  .breadcrumb-item [aria-current="page"] {
    max-width: 12rem;
  }
}
