/* ============================================================
   /activity/ — who is online.

   The block that says "985 buyers are online right now, here are some of
   them". It had six things wrong with it, all visible in one screenshot:

     1. THREE STATEMENTS OF ONE FACT — a count pill, then a card, then an
        "ONLINE SELLERS" heading inside that card.
     2. PAGER ARROWS ON THE FACES. They are centred on the row, so ‹ and ›
        landed squarely on the first and last avatar.
     3. A HALF CIRCLE bleeding off the left edge — the paging offset, not a
        styling slip.
     4. NO NAMES. A row of anonymous circles, with the crop often landing on
        a dog or a lamp rather than a face. The names existed the whole time,
        as data-bp-tooltip and nothing else; both renderers now print them.
     5. A PINK RING ON EVERY AVATAR that meant nothing, while the one green
        dot that did mean something was barely visible.
     6. A FULL-WIDTH SOLID PINK button pointing at the same URL as the count
        pill above it, which is already a link.

   🚨 The circles stay, deliberately. Circles say "person, present" — the
   chat-roster idiom — and rectangles say "listing, browse me". This block's
   whole job is presence, and staying circular is now what keeps it distinct
   from the two paid rails, which are rectangular tiles on dark bands. That is
   a functional difference, not decoration.

   So the green inverts: it is stated ONCE in the header, where it reports
   something true, and the avatars get a neutral 1px edge instead of a ninth
   colour. Eight green rings would read as a traffic light.

   Scope: body.activity, plus .snifffr-live-card which is carried only by the
   six .buyers_widget_mobile wrappers in activity/index.php. The same wrapper
   class appears in template-parts/index.php (the home page); body.activity
   keeps this off it.
   ============================================================ */

:root {
	--alo-ink: #332E4D;
	--alo-name: #4A4458;
	--alo-pink: #D63384;
	--alo-green: #2EB872;
	--alo-edge: rgba(51, 46, 77, 0.10);
}

/* ── one card ─────────────────────────────────────────────────────────
   🚨 (0,3,1) + !important, answering two rules that paint this wrapper:
   `body.snifffr-desktop-beta .buyers_widget_mobile` (0,2,1) !important and
   `.buyers_widget_mobile { border-radius: 30px }` (0,1,0) !important. The
   30px radius was a pill's radius, inherited from when this block was one. */
body.activity .buyers_widget_mobile.snifffr-live-card {
	background: #ffffff !important;
	border: 1px solid var(--alo-edge) !important;
	border-radius: 16px !important;
	/* No padding-right: the row of faces runs off the card's edge and the
	   mask below dissolves it, the same way the featured rails say they
	   scroll. */
	padding: 15px 0 16px 16px !important;
	margin: 0 0 16px !important;
	box-shadow: 0 1px 3px rgba(51, 46, 77, 0.04) !important;
	text-align: left !important;
	overflow: hidden !important;
}

/* Whatever widget body lands inside — the BP who's-online widget on a
   seller's view, the theme's own block on a buyer's — contributes no box of
   its own. The card is the only container now. */
body.activity .snifffr-live-card > *,
body.activity .snifffr-live-card .widget,
body.activity .snifffr-live-card section,
body.activity .snifffr-live-card .widget_bp_core_whos_online_widget {
	background: none !important;
	border: 0 !important;
	border-radius: 0 !important;
	padding: 0 !important;
	margin: 0 !important;
	box-shadow: none !important;
	text-align: left !important;
}

/* 🚨 THE RULE EVERYTHING BELOW IS FIGHTING. snifffr-desktop-redesign.css
   carries one blanket declaration over every a / p / span / h1-h6 in this
   wrapper:

     body.snifffr-desktop-beta .buyers_widget_mobile span, … (0,2,1)
         min-height: 48px !important;
         padding: 14px 18px !important;
         display: flex !important;
         line-height: 1.2 !important;

   It is from when this card held one line of text and that was how it was
   centred. With real content in it, it is 48px of floor and 28px of padding
   on EVERY element: measured, it rendered a one-line 11px label 42px tall
   and turned a 60px avatar plus a name into a 109px item.

   It is answered per element rather than with a blanket reset of its own,
   because the count strip is itself an <a> in that list and DOES want to be
   a flex row. Each selector below reaches (0,4,1) or better to clear it.

   The durable fix is the one the featured rail took: stop wearing the class
   names these rules target. That means renaming .avatar-block / .item-avatar
   in both renderers, which the lightSlider init also keys on — a change
   worth making on its own, not as a rider here. */

/* The "ONLINE SELLERS" / "Online Buyers" heading inside the card. The count
   line above it already names the thing and gives the number, so this is the
   third statement of one fact. (0,3,1) beats the (0,1,1) that un-hid it. */
body.activity .snifffr-live-card h4,
body.activity .snifffr-live-card .widget-title {
	display: none !important;
}

/* ── the count, as the card's header ──────────────────────────────────
   On the mobile panes this strip is rendered INSIDE the wrapper
   (activity/index.php:100 and :226), so it becomes the header row simply by
   losing its own card. (0,3,1) beats the (0,1,0) in the footer <style>
   without depending on which came last. */
body.activity .buyers_widget_mobile.snifffr-live-card .snifffr-live-count-strip {
	display: flex !important;
	min-height: 0 !important;
	height: auto !important;
	align-items: center !important;
	gap: 8px !important;
	background: none !important;
	border: 0 !important;
	border-radius: 0 !important;
	box-shadow: none !important;
	padding: 0 16px 0 0 !important;
	margin: 0 0 13px !important;
	text-decoration: none !important;
}

/* The presence dot. Styled here rather than left to the footer <style> in
   snifffr-activity-sidebar-blocks.php: that sheet is gated on
   bp_is_activity_component(), and the dot is a <span>, so without this it
   inherits the 48px floor and single-handedly makes the header 48px tall.
   Green lives here and nowhere else on this block. */
body.activity .buyers_widget_mobile.snifffr-live-card .snifffr-live-count-dot {
	display: block !important;
	flex: 0 0 auto !important;
	width: 9px !important;
	height: 9px !important;
	min-height: 0 !important;
	padding: 0 !important;
	margin: 0 !important;
	border-radius: 50% !important;
	background: var(--alo-green) !important;
	box-shadow: 0 0 0 3px rgba(46, 184, 114, 0.22) !important;
}

body.activity .buyers_widget_mobile.snifffr-live-card .snifffr-live-count-num {
	display: block !important;
	min-height: 0 !important;
	height: auto !important;
	padding: 0 !important;
	font-size: 20px !important;
	font-weight: 700 !important;
	line-height: 1 !important;
	color: var(--alo-pink) !important;
	font-variant-numeric: tabular-nums;
}

/* The same uppercase label the featured sections use, so every section on
   this page is announced the same way. */
body.activity .buyers_widget_mobile.snifffr-live-card .snifffr-live-count-label {
	display: block !important;
	min-height: 0 !important;
	height: auto !important;
	padding: 0 !important;
	/* 🚨 Without this it wraps to three lines and triples the header's
	   height: it is a flex item in a 300px row, so it shrinks before the
	   number does. Measured 106px wide and 71px tall before. */
	white-space: nowrap !important;
	flex: 0 1 auto !important;
	font-size: 11px !important;
	font-weight: 700 !important;
	letter-spacing: 0.1em !important;
	text-transform: uppercase !important;
	color: var(--alo-ink) !important;
	line-height: 1.3 !important;
}

/* Pushed to the right-hand end, where "See all" sits on the featured band. */
body.activity .buyers_widget_mobile.snifffr-live-card .snifffr-live-count-arrow {
	display: block !important;
	min-height: 0 !important;
	height: auto !important;
	padding: 0 !important;
	margin-left: auto !important;
	color: var(--alo-pink) !important;
	font-size: 17px !important;
	line-height: 1 !important;
}

/* 🚨 The desktop sidebar's count sits in its own .newmemtoday-mob div ABOVE
   the card (activity/index.php:504), not inside it. There WAS a rule here
   restyling it and squaring off the card below so the pair read as one unit.
   It is gone, for two reasons:

     - they are not adjacent siblings, so the "square the card below" half
       matched the wrong element and shipped a square-topped card floating
       under a fully rounded pill;
     - the restyle half never applied anyway. Measured: every declaration lost
       to `body.snifffr-desktop-beta .newmemtoday-mob`, which is (0,2,1) —
       the same specificity, winning on source order.

   A half-applied restyle is worse than none, so that element is left exactly
   as it was. Merging the two properly means moving the pill inside the card
   in the template, which is a separate change. */

/* ── the row of faces ─────────────────────────────────────────────────
   One row that scrolls, not two that page. That removes the arrows, and with
   them the half circle — which was the paging offset showing through. */

body.activity .snifffr-live-card .avatar-block {
	display: flex !important;
	flex-wrap: nowrap !important;
	align-items: flex-start !important;
	gap: 12px !important;
	padding: 0 !important;
	margin: 0 !important;
	overflow-x: auto !important;
	overflow-y: hidden !important;
	-webkit-overflow-scrolling: touch;
	scrollbar-width: none;
	-ms-overflow-style: none;
	/* 🚨 Never scroll-snap. `x mandatory` cancels programmatic scrolling and
	   stops the row resting at 0 — it is what froze the shop shelf and the
	   featured rail before it. */
	scroll-snap-type: none !important;
	-webkit-mask-image: linear-gradient(to right, #000 0%, #000 90%, transparent 100%);
	mask-image: linear-gradient(to right, #000 0%, #000 90%, transparent 100%);
}

body.activity .snifffr-live-card .avatar-block::-webkit-scrollbar {
	width: 0;
	height: 0;
	display: none;
}

/* The pager. lightSlider's arrows are centred on the row, which is why they
   sat on the first and last face. With the row scrolling there is nothing
   for them to do. */
/* 🚨 The arrows are .snifffr-feat-arrow, created by initSlider() in
   activity/index.php and appended to the widget wrapper. The first attempt
   hid .lSAction — lightSlider's class, which this block never renders — so
   the arrows stayed exactly where they were, on top of the first and last
   face. The initSlider call for this widget is removed as well; this is the
   belt to its braces, and it also covers a cached page still running the old
   script. */
body.activity .snifffr-live-card .snifffr-feat-arrow,
body.activity .snifffr-live-card .lSAction,
body.activity .snifffr-live-card .lSAction > a,
body.activity .snifffr-live-card .lSPager {
	display: none !important;
}

/* 🚨 (0,4,1), not (0,3,1). The legacy grid sizes this at
   `body.snifffr-desktop-beta .buyers_widget_mobile .item-avatar`, which is
   also (0,3,1) — so a tie, settled by whichever stylesheet loaded last.
   Measured at 60px instead of 66 before the wrapper class was added to the
   selector. */
body.activity .buyers_widget_mobile.snifffr-live-card .avatar-block .item-avatar {
	flex: 0 0 auto !important;
	width: 66px !important;
	/* 🚨 Not optional, and the reason the item measured 60px with `width:66px`
	   winning the cascade: custom.css also sets
	   `.widget_bp_core_whos_online_widget .avatar-block .item-avatar
	    { max-width: 60px !important }`
	   and MAX-WIDTH BEATS WIDTH. Same trap the featured rail hit from the
	   other side with min-width. */
	max-width: none !important;
	/* 🚨 Same rule also pins `height: 60px !important` — exactly the avatar,
	   with nothing left for a name. Measured: the name's bottom edge fell
	   18px BELOW the card's, and the card clips. */
	height: auto !important;
	margin: 0 !important;
	padding: 0 !important;
	text-align: center !important;
	/* 🚨 A flex item defaults to min-width:auto, which resolves to min-content
	   and beats max-width — a long name would otherwise widen the item rather
	   than clip. The name carries its own ellipsis. */
	min-width: 0 !important;
}

body.activity .buyers_widget_mobile.snifffr-live-card .avatar-block .item-avatar > a {
	display: block !important;
	min-height: 0 !important;
	height: auto !important;
	padding: 0 !important;
	text-decoration: none !important;
	min-width: 0;
	/* 🚨 snifffr-mobile-redesign.css:10775 sets `overflow: hidden` here. With
	   the name now inside this link, that clipped it at BOTH ends — centred
	   text overflowing a box it cannot ellipsise, because the overflow was on
	   an ancestor rather than on the name itself. */
	overflow: visible !important;
}

body.activity .buyers_widget_mobile.snifffr-live-card .avatar-block .item-avatar img {
	display: block !important;
	width: 60px !important;
	height: 60px !important;
	/* 🚨 snifffr-mobile-redesign.css:10784 forces `height: 56px` AND
	   `min-height: 56px` at (0,4,2). A 60x56 box with border-radius:50% is an
	   ellipse with a flattened top, which is exactly what shipped. Both are
	   released here; the selector above reaches (0,5,2) to do it. */
	min-height: 0 !important;
	max-height: none !important;
	margin: 0 auto !important;
	border-radius: 50% !important;
	object-fit: cover !important;
	/* A 1px edge rather than the old 2px pink ring. It defines a photo with a
	   pale border against a white card without adding colour, and it leaves
	   green meaning one thing on this block instead of nine. */
	border: 0 !important;
	box-shadow: 0 0 0 1px var(--alo-edge) !important;
	transition: transform 0.18s ease;
}

body.activity .buyers_widget_mobile.snifffr-live-card .avatar-block .item-avatar > a:hover img {
	transform: translateY(-2px);
}

body.activity .buyers_widget_mobile.snifffr-live-card .avatar-block .item-avatar > a:focus-visible img {
	box-shadow: 0 0 0 2px var(--alo-pink) !important;
}

/* 🚨 (0,4,1) + !important, and every property spelled out. A blanket rule at
   `body.snifffr-desktop-beta .buyers_widget_mobile span` (0,2,1) !important
   sets display and font on every span in this card — the name came out as a
   13px flex box before this answered it. */
body.activity .buyers_widget_mobile.snifffr-live-card .avatar-block .item-avatar .snifffr-live-name {
	display: block !important;
	margin: 7px 0 0 !important;
	padding: 0 !important;
	/* 🚨 The same blanket rule sets a min-height on every span in this
	   wrapper, which rendered a one-line name as a 48px box. */
	height: auto !important;
	min-height: 0 !important;
	font-size: 11px !important;
	font-weight: 600 !important;
	line-height: 1.3 !important;
	color: var(--alo-name) !important;
	text-align: center !important;
	/* 🚨 Something upstream uppercases text in this card — a name is not a
	   label, and "NAUGHTYBYHEEL…" eats about three more characters of the
	   66px than "NaughtybyHeel…" does. */
	text-transform: none !important;
	letter-spacing: 0 !important;
	white-space: nowrap !important;
	overflow: hidden !important;
	text-overflow: ellipsis !important;
	background: none !important;
}

/* ── the "view all" button ────────────────────────────────────────────
   Kept, at the user's call, but as an outline rather than a solid pink slab.
   It points at the same URL as the count header above it, so it is a second
   route to one place and should not also be the loudest thing in the column.

   🚨 (0,4,1) + !important. The rules it answers are
   `a.btn.btn-primary.snifffr-online-cta` (0,3,1) !important, written twice —
   once in snifffr-mobile-redesign.css and once in snifffr-desktop-redesign.css
   — so neither source order nor breakpoint decides this. */
body.activity a.btn.btn-primary.snifffr-online-cta {
	background: transparent !important;
	background-image: none !important;
	border: 1.5px solid var(--alo-pink) !important;
	color: var(--alo-pink) !important;
	box-shadow: none !important;
	font-weight: 700 !important;
}

body.activity a.btn.btn-primary.snifffr-online-cta:hover,
body.activity a.btn.btn-primary.snifffr-online-cta:focus {
	background: var(--alo-pink) !important;
	border-color: var(--alo-pink) !important;
	color: #ffffff !important;
}

@media (prefers-reduced-motion: reduce) {
	body.activity .buyers_widget_mobile.snifffr-live-card .avatar-block .item-avatar img {
		transition: none;
	}
	body.activity .buyers_widget_mobile.snifffr-live-card .avatar-block .item-avatar > a:hover img {
		transform: none;
	}
}
