


/*--------------------------------------------------------------
# Base Shortcode Styles
--------------------------------------------------------------*/
.bpmb-shortcode {
	margin: 0 0 2em;
}

.bpmb-shortcode-empty,
.bpmb-shortcode-error {
	padding: 1.5em;
	text-align: center;
	color: var(--bpmb-text-secondary, #6c757d);
	background: var(--bpmb-bg-secondary, #f8f9fa);
	border-radius: var(--bpmb-radius-lg, 8px);
}

.bpmb-shortcode-error {
	color: var(--bpmb-danger, #dc3545);
	background: var(--bpmb-danger-light, #fce8ea);
}

/*--------------------------------------------------------------
# Archive Filter Bar (search + category)
--------------------------------------------------------------*/
.bpmb-recent-posts-wrap {
	margin: 0 0 2em;
}

.bpmb-archive-filters {
	display: flex;
	flex-wrap: wrap;
	gap: var(--bpmb-space-sm, 12px);
	align-items: center;
	margin-bottom: var(--bpmb-space-lg, 24px);
	padding: var(--bpmb-space-md, 16px);
	background: var(--bpmb-bg-secondary, #f8f9fa);
	border: 1px solid var(--bpmb-border-color, #e9ecef);
	border-radius: var(--bpmb-radius-lg, 8px);
}

.bpmb-archive-filters__field {
	flex: 1 1 200px;
	min-width: 0;
}

.bpmb-archive-filters__search {
	flex: 2 1 240px;
}

.bpmb-archive-filters input[type="search"],
.bpmb-archive-filters select {
	width: 100%;
	padding: 8px 12px;
	border: 1px solid var(--bpmb-border-color, #d1d5db);
	border-radius: var(--bpmb-radius-md, 6px);
	background: var(--bpmb-bg-primary, #fff);
	color: var(--bpmb-text-primary, #1f2937);
	font-size: 14px;
	line-height: 1.4;
	box-sizing: border-box;
}

.bpmb-archive-filters input[type="search"]:focus,
.bpmb-archive-filters select:focus {
	outline: 2px solid var(--bpmb-primary, #3b82f6);
	outline-offset: 1px;
	border-color: var(--bpmb-primary, #3b82f6);
}

.bpmb-archive-filters__actions {
	display: flex;
	gap: 8px;
	align-items: center;
	flex-shrink: 0;
}

.bpmb-archive-filters__submit {
	padding: 8px 18px;
	background: var(--bpmb-primary, #3b82f6);
	color: var(--bpmb-text-light, #fff);
	border: 1px solid var(--bpmb-primary, #3b82f6);
	border-radius: var(--bpmb-radius-md, 6px);
	cursor: pointer;
	font-size: 14px;
	font-weight: 500;
	line-height: 1.4;
}

.bpmb-archive-filters__submit:hover,
.bpmb-archive-filters__submit:focus {
	background: var(--bpmb-primary-dark, #2563eb);
	border-color: var(--bpmb-primary-dark, #2563eb);
}

.bpmb-archive-filters__reset {
	padding: 8px 12px;
	color: var(--bpmb-text-secondary, #6b7280);
	text-decoration: none;
	font-size: 13px;
	line-height: 1.4;
}

.bpmb-archive-filters__reset:hover,
.bpmb-archive-filters__reset:focus {
	color: var(--bpmb-danger, #dc3545);
	text-decoration: underline;
}

.dark-mode .bpmb-archive-filters,
.dark-scheme .bpmb-archive-filters,
:root[data-bx-mode="dark"] .bpmb-archive-filters {
	background: var(--bpmb-bg-tertiary, #1f2937);
	border-color: var(--bpmb-border-color, #374151);
}

.dark-mode .bpmb-archive-filters input[type="search"],
.dark-mode .bpmb-archive-filters select,
.dark-scheme .bpmb-archive-filters input[type="search"],
.dark-scheme .bpmb-archive-filters select,
:root[data-bx-mode="dark"] .bpmb-archive-filters input[type="search"],
:root[data-bx-mode="dark"] .bpmb-archive-filters select {
	background: var(--bpmb-bg-secondary, #111827);
	border-color: var(--bpmb-border-color, #374151);
	color: var(--bpmb-text-primary, #f3f4f6);
}

@media (max-width: 600px) {
	.bpmb-archive-filters {
		flex-direction: column;
		align-items: stretch;
	}

	.bpmb-archive-filters__field,
	.bpmb-archive-filters__actions {
		width: 100%;
		flex: none;
	}

	.bpmb-archive-filters__actions {
		justify-content: space-between;
	}

	.bpmb-archive-filters__submit {
		flex: 1;
	}
}

/*--------------------------------------------------------------
# Post Grid Layouts
--------------------------------------------------------------*/
.bpmb-member-blog-list,
.bpmb-recent-posts,
.bpmb-popular-posts,
.bpmb-authors {
	display: grid;
	gap: var(--bpmb-space-lg, 24px);
}

.bpmb-columns-1 {
	grid-template-columns: 1fr;
}

.bpmb-columns-2 {
	grid-template-columns: repeat(2, 1fr);
}

.bpmb-columns-3 {
	grid-template-columns: repeat(3, 1fr);
}

.bpmb-columns-4 {
	grid-template-columns: repeat(4, 1fr);
}

/*--------------------------------------------------------------
# Post Item Card
--------------------------------------------------------------*/
.bpmb-post-item {
	position: relative;
	display: flex;
	flex-direction: column;
	background: var(--bpmb-bg-primary, #fff);
	border: 1px solid var(--bpmb-border-color, #e9ecef);
	border-radius: var(--bpmb-radius-lg, 8px);
	overflow: hidden;
	transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.bpmb-post-item:hover {
	box-shadow: var(--bpmb-shadow-md, 0 4px 12px rgba(0, 0, 0, 0.1));
	transform: translateY(-2px);
}

/* Thumbnail */
.bpmb-post-thumbnail {
	position: relative;
	aspect-ratio: 16 / 10;
	overflow: hidden;
}

.bpmb-post-thumbnail a {
	display: block;
	height: 100%;
}

.bpmb-post-thumbnail img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 0.3s ease;
}

.bpmb-post-item:hover .bpmb-post-thumbnail img {
	transform: scale(1.05);
}

/* Content */
.bpmb-post-content {
	flex: 1;
	display: flex;
	flex-direction: column;
	padding: var(--bpmb-space-md, 16px);
}

.bpmb-post-title {
	margin: 0 0 var(--bpmb-space-sm, 8px);
	font-size: 1.125rem;
	font-weight: 600;
	line-height: 1.3;
}

.bpmb-post-title a {
	/*
	 * BLOCK, not inline. The title is a card's primary target, and as an inline link its hit
	 * box was only as tall as one line of text (23px) — a pixel under WCAG 2.5.8 (AA), which
	 * asks for 24x24. Block + a hair of padding takes it over the line and widens it to the
	 * card, at no visual cost.
	 *
	 * Deliberately NOT 40px/44px. Those figures are for controls — buttons, icons. Padding a
	 * heading link out to 44px would put a visible gap under every card title to satisfy a
	 * number that does not apply to a text link. The generous target here is the THUMBNAIL,
	 * which is a 245px block link to the same place.
	 */
	display: block;
	padding-block: 2px;
	color: var(--bpmb-text-primary, #212529);
	text-decoration: none;
}

.bpmb-post-title a:hover {
	color: var(--bpmb-primary, #2468c6);
}

/* Meta */
.bpmb-post-meta {
	display: flex;
	flex-wrap: wrap;
	gap: var(--bpmb-space-sm, 8px) var(--bpmb-space-md, 16px);
	margin-bottom: 12px;
	font-size: 0.875rem;
	color: var(--bpmb-text-secondary, #6c757d);
}

.bpmb-post-meta span {
	display: inline-flex;
	align-items: center;
	gap: var(--bpmb-space-xs, 4px);
}

.bpmb-post-meta svg {
	opacity: 0.7;
}

.bpmb-author-avatar {
	display: inline-flex;
	align-items: center;
}

.bpmb-author-avatar img {
	border-radius: 50%;
	margin-right: 4px;
}

.bpmb-post-author a {
	color: var(--bpmb-text-secondary, #495057);
	text-decoration: none;
}

.bpmb-post-author a:hover {
	color: var(--bpmb-primary, #2468c6);
}

/* Excerpt */
.bpmb-post-excerpt {
	flex: 1;
	margin-bottom: 12px;
	font-size: 0.9375rem;
	line-height: 1.6;
	color: var(--bpmb-text-primary, #495057);
}

.bpmb-post-excerpt p {
	margin: 0;
}

/* Read More */
.bpmb-read-more {
	display: inline-flex;
	align-items: center;
	margin-top: auto;
	padding: var(--bpmb-space-sm, 8px) var(--bpmb-space-md, 16px);
	font-size: 0.875rem;
	font-weight: 500;
	color: var(--bpmb-primary, #2468c6);
	text-decoration: none;
	background: var(--bpmb-primary-light, #e8f0fc);
	border-radius: var(--bpmb-radius-sm, 4px);
	transition: all 0.2s ease;
	align-self: flex-start;
}

.bpmb-read-more:hover {
	background: var(--bpmb-primary, #2468c6);
	color: var(--bpmb-text-light, #fff);
}

/*--------------------------------------------------------------
# Popular Posts - Rank Badge
--------------------------------------------------------------*/
.bpmb-post-rank {
	position: absolute;
	top: 12px;
	left: 12px;
	z-index: 1;
	width: 28px;
	height: 28px;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 0.75rem;
	font-weight: 700;
	color: var(--bpmb-text-light, #fff);
	background: var(--bpmb-primary, #2468c6);
	border-radius: 50%;
	box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.bpmb-post-item:not(:has(.bpmb-post-thumbnail)) .bpmb-post-rank {
	position: relative;
}

.bpmb-rank-1 .bpmb-post-rank {
	background: linear-gradient(135deg, #ffd700, #ffa500);
	/* Fixed dark text on the fixed gold medal — intentionally NOT tokenised. */
	color: #212529;
}

.bpmb-rank-2 .bpmb-post-rank {
	background: linear-gradient(135deg, #c0c0c0, #a0a0a0);
}

.bpmb-rank-3 .bpmb-post-rank {
	background: linear-gradient(135deg, #cd7f32, #a0522d);
}

/* Views count styling */
.bpmb-post-views {
	font-weight: 500;
	color: var(--bpmb-text-secondary, #495057);
}

.bpmb-post-views svg {
	width: 14px;
	height: 14px;
}

/*--------------------------------------------------------------
# Categories - Cloud Style
--------------------------------------------------------------*/
.bpmb-categories-cloud {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	align-items: center;
}

.bpmb-category-tag {
	display: inline-block;
	padding: 6px 12px;
	color: var(--bpmb-text-primary, #495057);
	text-decoration: none;
	background: var(--bpmb-bg-secondary, #f8f9fa);
	border-radius: 20px;
	transition: all 0.2s ease;
	line-height: 1.4;
}

.bpmb-category-tag:hover {
	background: var(--bpmb-primary, #2468c6);
	color: var(--bpmb-text-light, #fff);
}

.bpmb-category-tag .bpmb-category-count {
	font-size: 0.75em;
	opacity: 0.7;
	margin-left: 2px;
}

/*--------------------------------------------------------------
# Categories - List Style
--------------------------------------------------------------*/
.bpmb-categories-list {
	background: var(--bpmb-bg-primary, #fff);
	border: 1px solid var(--bpmb-border-color, #e9ecef);
	border-radius: 8px;
	padding: 0;
}

.bpmb-category-list {
	list-style: none;
	margin: 0;
	padding: 0;
}

.bpmb-category-item {
	border-bottom: 1px solid var(--bpmb-border-color, #e9ecef);
}

.bpmb-category-item:last-child {
	border-bottom: none;
}

.bpmb-category-item a {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 12px 16px;
	color: var(--bpmb-text-secondary, #495057);
	text-decoration: none;
	transition: all 0.2s ease;
}

.bpmb-category-item a:hover {
	background: var(--bpmb-bg-secondary, #f8f9fa);
	color: var(--bpmb-primary, #2468c6);
}

.bpmb-categories-list .bpmb-category-count {
	font-size: 0.875rem;
	padding: 2px 8px;
	background: var(--bpmb-bg-tertiary, #e9ecef);
	border-radius: 12px;
	color: var(--bpmb-text-secondary, #6c757d);
}

.bpmb-category-item a:hover .bpmb-category-count {
	background: var(--bpmb-primary, #2468c6);
	color: var(--bpmb-text-light, #fff);
}

/*--------------------------------------------------------------
# Categories - Grid Style
--------------------------------------------------------------*/
.bpmb-categories-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
	gap: 16px;
}

.bpmb-category-card {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	padding: 20px 16px;
	text-align: center;
	background: var(--bpmb-bg-primary, #fff);
	border: 1px solid var(--bpmb-border-color, #e9ecef);
	border-radius: 8px;
	text-decoration: none;
	transition: all 0.2s ease;
}

.bpmb-category-card:hover {
	border-color: var(--bpmb-primary, #2468c6);
	box-shadow: 0 4px 12px rgba(36, 104, 198, 0.15);
	transform: translateY(-2px);
}

.bpmb-category-card .bpmb-category-name {
	display: block;
	font-size: 1rem;
	font-weight: 600;
	color: var(--bpmb-text-primary, #212529);
	margin-bottom: 4px;
}

.bpmb-category-card .bpmb-category-count {
	font-size: 0.875rem;
	color: var(--bpmb-text-secondary, #6c757d);
}

.bpmb-category-card:hover .bpmb-category-name {
	color: var(--bpmb-primary, #2468c6);
}

/*--------------------------------------------------------------
# Authors Grid
--------------------------------------------------------------*/
.bpmb-author-card {
	display: flex;
	flex-direction: column;
	align-items: center;
	padding: 24px 16px;
	text-align: center;
	background: var(--bpmb-bg-primary, #fff);
	border: 1px solid var(--bpmb-border-color, #e9ecef);
	border-radius: 12px;
	transition: all 0.2s ease;
}

.bpmb-author-card:hover {
	border-color: var(--bpmb-primary, #2468c6);
	box-shadow: 0 8px 24px rgba(36, 104, 198, 0.12);
	transform: translateY(-4px);
}

.bpmb-authors .bpmb-author-avatar {
	margin-bottom: 16px;
}

.bpmb-authors .bpmb-author-avatar a {
	display: block;
	border-radius: 50%;
	overflow: hidden;
	transition: transform 0.2s ease;
}

.bpmb-authors .bpmb-author-avatar a:hover {
	transform: scale(1.05);
}

.bpmb-authors .bpmb-author-avatar img {
	border-radius: 50%;
	border: 3px solid var(--bpmb-border-color, #e9ecef);
	transition: border-color 0.2s ease;
}

.bpmb-author-card:hover .bpmb-author-avatar img {
	border-color: var(--bpmb-primary, #2468c6);
}

.bpmb-author-info {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 8px;
}

.bpmb-author-name {
	margin: 0;
	font-size: 1.125rem;
	font-weight: 600;
	line-height: 1.3;
}

.bpmb-author-name a {
	color: var(--bpmb-text-primary, #212529);
	text-decoration: none;
	transition: color 0.2s ease;
}

.bpmb-author-name a:hover {
	color: var(--bpmb-primary, #2468c6);
}

.bpmb-author-post-count {
	font-size: 0.875rem;
	color: var(--bpmb-text-secondary, #6c757d);
	font-weight: 500;
}

.bpmb-author-bio {
	margin: 8px 0 0;
	font-size: 0.875rem;
	line-height: 1.5;
	color: var(--bpmb-text-secondary, #495057);
}

.bpmb-view-posts {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	margin-top: 12px;
	padding: 8px 16px;
	font-size: 0.875rem;
	font-weight: 500;
	color: var(--bpmb-primary, #2468c6);
	text-decoration: none;
	background: var(--bpmb-primary-light, #e8f0fc);
	border-radius: 20px;
	transition: all 0.2s ease;
}

.bpmb-view-posts:hover {
	background: var(--bpmb-primary, #2468c6);
	color: var(--bpmb-text-light, #fff);
}

.bpmb-view-posts svg {
	transition: transform 0.2s ease;
}

.bpmb-view-posts:hover svg {
	transform: translateX(3px);
}

/*--------------------------------------------------------------
# Responsive Styles
--------------------------------------------------------------*/
@media (max-width: 992px) {
	.bpmb-columns-4 {
		grid-template-columns: repeat(3, 1fr);
	}
}

@media (max-width: 768px) {
	.bpmb-columns-3,
	.bpmb-columns-4 {
		grid-template-columns: repeat(2, 1fr);
	}

	.bpmb-post-meta {
		flex-direction: column;
		gap: 4px;
	}

	.bpmb-categories-grid {
		grid-template-columns: repeat(2, 1fr);
	}
}

@media (max-width: 480px) {
	.bpmb-columns-2,
	.bpmb-columns-3,
	.bpmb-columns-4 {
		grid-template-columns: 1fr;
	}

	.bpmb-post-content {
		padding: 12px;
	}

	.bpmb-post-title {
		font-size: 1rem;
	}

	.bpmb-categories-grid {
		grid-template-columns: 1fr;
	}

	.bpmb-category-card {
		padding: 16px 12px;
	}
}

/*--------------------------------------------------------------
# Dark Mode Support
--------------------------------------------------------------*/
.dark-mode .bpmb-post-item,
.dark-scheme .bpmb-post-item {
	background: #1e1e1e;
	border-color: #333;
}

.dark-mode .bpmb-post-title a,
.dark-scheme .bpmb-post-title a {
	color: #e0e0e0;
}

.dark-mode .bpmb-post-excerpt,
.dark-scheme .bpmb-post-excerpt {
	color: #a0a0a0;
}

.dark-mode .bpmb-category-tag,
.dark-scheme .bpmb-category-tag {
	background: #333;
	color: #e0e0e0;
}

.dark-mode .bpmb-categories-list,
.dark-scheme .bpmb-categories-list {
	background: #1e1e1e;
	border-color: #333;
}

.dark-mode .bpmb-category-item,
.dark-scheme .bpmb-category-item {
	border-color: #333;
}

.dark-mode .bpmb-category-item a,
.dark-scheme .bpmb-category-item a {
	color: #e0e0e0;
}

.dark-mode .bpmb-category-card,
.dark-scheme .bpmb-category-card {
	background: #1e1e1e;
	border-color: #333;
}

.dark-mode .bpmb-category-card .bpmb-category-name,
.dark-scheme .bpmb-category-card .bpmb-category-name {
	color: #e0e0e0;
}

.dark-mode .bpmb-shortcode-empty,
.dark-scheme .bpmb-shortcode-empty {
	background: #2d2d2d;
	color: #a0a0a0;
}

/* Authors dark mode */
.dark-mode .bpmb-author-card,
.dark-scheme .bpmb-author-card {
	background: #1e1e1e;
	border-color: #333;
}

.dark-mode .bpmb-author-name a,
.dark-scheme .bpmb-author-name a {
	color: #e0e0e0;
}

.dark-mode .bpmb-author-post-count,
.dark-scheme .bpmb-author-post-count {
	color: #a0a0a0;
}

.dark-mode .bpmb-author-bio,
.dark-scheme .bpmb-author-bio {
	color: #a0a0a0;
}

.dark-mode .bpmb-authors .bpmb-author-avatar img,
.dark-scheme .bpmb-authors .bpmb-author-avatar img {
	border-color: #444;
}

.dark-mode .bpmb-view-posts,
.dark-scheme .bpmb-view-posts {
	background: #2d3748;
	color: #60a5fa;
}

.dark-mode .bpmb-view-posts:hover,
.dark-scheme .bpmb-view-posts:hover {
	background: #3b82f6;
	/* Flips with the theme toggle. `--bpmb-primary` becomes a PALE accent in dark mode, so a raw
	   #fff here measured 1.89:1 against it — WCAG AA wants 4.5. */
	color: var(--bpmb-on-primary, #fff);
}

/* Dark mode: soften the light no-post-image fallback so it does not glare on a dark page (BuddyX/Reign data-bx-mode + BuddyBoss dark-mode). */
:root[data-bx-mode="dark"] img[src*="no-post-image"],html[data-bx-mode="dark"] img[src*="no-post-image"],body.buddyx-dark img[src*="no-post-image"],body.dark-mode img[src*="no-post-image"],body.bb-dark-mode img[src*="no-post-image"]{filter:brightness(.32) contrast(.85);}
/*--------------------------------------------------------------
# Save for later (bookmark toggle)
--------------------------------------------------------------
This one IS a control, so 40px applies — unlike a card title link, which is
text and is governed by WCAG 2.5.8's 24px. */
.bpmb-post-actions-inline {
	display: flex;
	justify-content: flex-end;
	margin-block-start: auto;
	padding-block-start: var(--bpmb-space-sm, 8px);
}

.bpmb-bookmark-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: var(--bpmb-space-xs, 4px);
	min-width: 40px;
	min-height: 40px;
	padding: 0 var(--bpmb-space-sm, 8px);
	border: 0;
	border-radius: var(--bpmb-border-radius, 6px);
	background: transparent;
	color: var(--bpmb-text-secondary, #6b7280);
	cursor: pointer;
}

.bpmb-bookmark-btn:hover,
.bpmb-bookmark-btn:focus-visible {
	background: var(--bpmb-bg-secondary, #f3f4f6);
	color: var(--bpmb-primary, #2468c6);
}

/* Never remove the focus ring — a keyboard user must be able to see where they are. */
.bpmb-bookmark-btn:focus-visible {
	outline: 2px solid var(--bpmb-primary, #2468c6);
	outline-offset: 2px;
}

.bpmb-bookmark-btn.is-saved {
	color: var(--bpmb-primary, #2468c6);
}

/* The icon swap is pure CSS, driven by .is-saved — so the JS only flips a class and the
   button cannot get stuck rendering both states or neither. */
.bpmb-bookmark-btn .bpmb-icon-saved,
.bpmb-bookmark-btn.is-saved .bpmb-icon-save {
	display: none;
}

.bpmb-bookmark-btn.is-saved .bpmb-icon-saved {
	display: block;
}

.bpmb-bookmark-btn .bpmb-bookmark-icon {
	display: flex;
	transition: transform 120ms ease;
}

.bpmb-bookmark-btn.is-saved .bpmb-bookmark-icon {
	transform: scale(1.12);
}

.bpmb-bookmark-count {
	font-size: var(--bpmb-font-size-sm, 0.875rem);
	font-variant-numeric: tabular-nums;
}

/* A pop on save is delight for most people and a problem for some. Respect the setting. */
@media (prefers-reduced-motion: reduce) {
	.bpmb-bookmark-btn .bpmb-bookmark-icon {
		transition: none;
	}

	.bpmb-bookmark-btn.is-saved .bpmb-bookmark-icon {
		transform: none;
	}
}

/*--------------------------------------------------------------
# Follow button
--------------------------------------------------------------
Carries a visible label AND a count — a follower count is social proof and
part of why somebody clicks. (A save count is not: nobody bookmarks a post
because 40 other people did, which is why the bookmark button has no count
on a card.) */
.bpmb-follow-btn {
	display: inline-flex;
	align-items: center;
	gap: var(--bpmb-space-xs, 4px);
	min-height: 40px;
	padding: 0 var(--bpmb-space-md, 16px);
	border: 1px solid var(--bpmb-primary-filled, var(--bpmb-primary, #2468c6));
	border-radius: var(--bpmb-border-radius, 6px);
	/* `--bpmb-primary-filled`: the theme's accent, darkened just enough that the LABEL is readable.
	   The raw accent carries white at only 3.46:1 on BuddyX's coral. */
	background: var(--bpmb-primary-filled, var(--bpmb-primary, #2468c6));
	/* Flips with the theme toggle. `--bpmb-primary` becomes a PALE accent in dark mode, so a raw
	   #fff here measured 1.89:1 against it — WCAG AA wants 4.5. */
	color: var(--bpmb-on-primary, #fff);
	font-size: var(--bpmb-font-size-sm, 0.875rem);
	font-weight: 600;
	cursor: pointer;
}

/* Following = a quieter, secondary state. It is a thing you can undo, not a
   call to action, so it should stop shouting once you have done it. */
.bpmb-follow-btn.is-following {
	background: transparent;
	color: var(--bpmb-primary, #2468c6);
}

.bpmb-follow-btn:focus-visible {
	outline: 2px solid var(--bpmb-primary, #2468c6);
	outline-offset: 2px;
}

/* One label is shown, the other hidden — swapped by CSS on .is-following, so
   the JS only flips a class and cannot leave the button showing both. */
.bpmb-follow-btn .bpmb-follow-text--following,
.bpmb-follow-btn.is-following .bpmb-follow-text--follow {
	display: none;
}

.bpmb-follow-btn.is-following .bpmb-follow-text--following {
	display: inline;
}

.bpmb-follow-count {
	padding-inline-start: var(--bpmb-space-xs, 4px);
	border-inline-start: 1px solid currentColor;
	margin-inline-start: var(--bpmb-space-xs, 4px);
	font-variant-numeric: tabular-nums;
	opacity: 0.85;
}

/*--------------------------------------------------------------
# Claps
--------------------------------------------------------------
A DIAL, not a toggle: the member's own count sits on the button, the post's
total sits beside it. Two different numbers — conflating them is the classic
clap-UI mistake, where a reader cannot tell whether "7" is their contribution
or everyone's. */
.bpmb-claps {
	display: inline-flex;
	align-items: center;
	gap: var(--bpmb-space-sm, 8px);
}

.bpmb-clap-btn {
	display: inline-flex;
	align-items: center;
	gap: var(--bpmb-space-xs, 4px);
	min-width: 40px;
	min-height: 40px;
	padding: 0 var(--bpmb-space-sm, 8px);
	border: 1px solid var(--bpmb-border-color, #e5e7eb);
	border-radius: 999px;
	background: transparent;
	color: var(--bpmb-text-secondary, #6b7280);
	cursor: pointer;
}

.bpmb-clap-btn:hover {
	border-color: var(--bpmb-primary, #2468c6);
	color: var(--bpmb-primary, #2468c6);
}

.bpmb-clap-btn:focus-visible {
	outline: 2px solid var(--bpmb-primary, #2468c6);
	outline-offset: 2px;
}

.bpmb-clap-btn.has-clapped {
	border-color: var(--bpmb-primary, #2468c6);
	color: var(--bpmb-primary, #2468c6);
}

/* Maxed out: still readable, clearly not pressable. Not display:none — the count
   they gave is theirs and should stay visible. */
.bpmb-clap-btn.is-maxed {
	opacity: 0.6;
	cursor: default;
}

.bpmb-clap-mine {
	font-size: var(--bpmb-font-size-sm, 0.875rem);
	font-weight: 600;
	font-variant-numeric: tabular-nums;
}

.bpmb-clap-total {
	color: var(--bpmb-text-secondary, #6b7280);
	font-size: var(--bpmb-font-size-sm, 0.875rem);
	font-variant-numeric: tabular-nums;
}

/* The pop is the whole feel of clapping — it is what makes hammering the button
   satisfying rather than a form submission. */
@keyframes bpmb-clap-pop {
	0%   { transform: scale(1); }
	40%  { transform: scale(1.25); }
	100% { transform: scale(1); }
}

.bpmb-clap-btn.is-popping .bpmb-clap-icon {
	animation: bpmb-clap-pop 220ms ease;
}

@media (prefers-reduced-motion: reduce) {
	.bpmb-clap-btn.is-popping .bpmb-clap-icon {
		animation: none;
	}
}

/* ==========================================================================
   Featured — the editor's picks
   ========================================================================== */

.bpmb-featured-title {
	margin: 0 0 var(--bpmb-space-md);
	color: var(--bpmb-text-primary);
}

/* A gold hairline and a star, and nothing else. A featured strip that shouts — a coloured
   background, a badge on every card — competes with the posts it is supposed to be selling. */
.bpmb-featured .bpmb-post-item {
	position: relative;
	border-top: 3px solid var(--bpmb-primary);
}

.bpmb-featured .bpmb-post-item::before {
	content: "\2605"; /* ★ */
	position: absolute;
	inset-block-start: var(--bpmb-space-xs);
	inset-inline-end: var(--bpmb-space-xs); /* NOT `right` — this flips for RTL. */
	z-index: 1;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 24px;
	height: 24px;
	border-radius: 50%;
	background: var(--bpmb-primary);
	/* Flips with the mode — `--bpmb-primary` is a pale accent in dark mode, so white on it would be
	   unreadable. */
	color: var(--bpmb-on-primary, #fff);
	font-size: 13px;
	line-height: 1;
}

@media screen and (max-width: 640px) {
	.bpmb-featured .bpmb-post-item {
		border-top-width: 2px;
	}
}
