/**
 * Bristle Up Categories — the slim breadcrumb on product pages (1.50.0, WO-057 C, R-195.3).
 * Loaded ONLY on a single product while "Slim breadcrumb on product pages" is on. In the category header's crumb style
 * (.bch-crumb): one line, small, the links quiet, the last item in the ink colour. Computer from 850 px (the theme's
 * breakpoint), phone below.
 */

.bpc {
	--bpc-ink: #1b1b1b;
	--bpc-muted: #5f5a52;
	display: flex;
	align-items: center;
	gap: 10px;
	min-width: 0;
	margin: 0 0 8px;
	font-size: 13px;
	line-height: 1.4;
	color: var(--bpc-muted);
}

/* The theme's trail, one line. Flex, so a trail too long for the line is cut on the LEFT (the end, the product's own
   category, always shows): the items sit at the end; the ::after's auto margin takes any room left, so a trail that
   fits starts at the left as usual. */
.bpc .woocommerce-breadcrumb,
.bpc .breadcrumbs,
.bpc > nav {
	display: flex;
	flex: 1 1 auto;
	justify-content: flex-end;
	align-items: baseline;
	min-width: 0;
	margin: 0;
	padding: 0;
	overflow: hidden;
	white-space: nowrap;
	font-size: inherit;
	line-height: inherit;
	text-transform: none;
	letter-spacing: 0;
	color: var(--bpc-ink);
	font-weight: 600;
}
.bpc .woocommerce-breadcrumb::after,
.bpc .breadcrumbs::after,
.bpc > nav::after { content: ""; margin-right: auto; }
.bpc .woocommerce-breadcrumb > *,
.bpc .breadcrumbs > *,
.bpc > nav > * { flex: 0 0 auto; }
.bpc a { color: var(--bpc-muted); font-weight: 400; text-decoration: none; }
.bpc a:hover,
.bpc a:focus { color: var(--bpc-ink); text-decoration: underline; }
/* The last link in the trail is the page's own category: it reads as the current item. */
.bpc nav a:last-of-type { color: var(--bpc-ink); font-weight: 600; }
.bpc .divider { color: var(--bpc-muted); font-weight: 400; margin: 0 .35em; opacity: 1; }

/* "‹ <category>": phones only. */
.bpc .bpc-back { display: none; }

/* The arrow, kept small at the right of the line (the theme's own list and its hover thumbnail). */
.bpc .next-prev-thumbs { flex: 0 0 auto; margin: 0 0 0 auto; padding: 0; line-height: 1; }
.bpc .next-prev-thumbs li { margin: 0 0 0 2px !important; }
.bpc .next-prev-thumbs .button.icon {
	width: 26px; height: 26px; min-height: 26px; min-width: 26px; margin: 0; padding: 0; line-height: 24px; font-size: 13px;
}

@media (max-width: 849px) {
	/* "‹ <category>": the back link; the trail stays in the page, clipped, for screen readers, and shows again while a
	   link in it has the keyboard's focus. */
	.bpc.bpc-has-back .bpc-back {
		display: inline-flex; align-items: center; min-height: 32px; color: var(--bpc-ink); font-size: 14px; font-weight: 600;
		text-decoration: none; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0;
	}
	.bpc.bpc-has-back .bpc-back::before { content: "\2039"; content: "\2039" / ""; margin-right: 6px; font-size: 18px; line-height: 1; }
	.bpc.bpc-has-back .bpc-back:hover,
	.bpc.bpc-has-back .bpc-back:focus { text-decoration: underline; }
	.bpc.bpc-has-back > nav:not(:focus-within) {
		position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden;
		clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; border: 0;
	}

	/* The whole trail on one line that swipes sideways: no wrap, no scrollbar; it starts at the left. */
	.bpc.bpc-line > nav {
		justify-content: flex-start; overflow-x: auto; overflow-y: hidden; -webkit-overflow-scrolling: touch;
		scrollbar-width: none; white-space: nowrap;
	}
	.bpc.bpc-line > nav::-webkit-scrollbar { display: none; }
	.bpc.bpc-line > nav::after { content: none; }
}

@media (min-width: 850px) {
	.bpc { margin: 0 0 10px; font-size: 14px; }
}
