
#activityFeedContainer .template {
	display: block;
}

/* ============================================================
Masonry feed grid + new card design (WIP redesign, Figma 2040:13339)
Items are split into fixed columns in JS (round-robin, see user_feed.mjs)
rather than CSS multi-column: `column-count` auto-balances/reshuffles which
column each item falls into on every content change, so appending a card
during infinite scroll would shift cards already on screen between columns.
Assigning each item's column once in JS and rendering plain flex columns
here means a card can only ever be appended to the bottom of its column.
============================================================ */
#activityFeed {
	display: flex;
	align-items: flex-start;
	--feed-gap: max(15px, min(7vw, 90px));
	gap: var(--feed-gap);
	overflow: hidden;
	width: 100%;
}
@media (max-width: 767px) {
	#activityFeed {
		flex-direction: column;
	}
}
#activityFeed .feedColumn {
	display: flex;
	flex-direction: column;
	gap: var(--feed-gap);
	flex: 1;
	min-width: 0;
	max-width: 100%;
}

/* New feed card shell (Figma node 2040:13343). min-width:0 is required here:
   .feedColumn stretches each card to its width by default, but without this
   the card can still be forced wider by a nowrap title/meta line inside it
   (flex items don't shrink below their content's intrinsic width otherwise),
   which is what was overflowing the column/viewport on narrow screens. */
#activityFeed .feedColumn > li.feedCard {
	display: flex;
	flex-direction: column;
	gap: 5px;
	margin: 0;
	padding: 0;
	min-width: 0;
	list-style: none;
	max-width: 100%;
	overflow: hidden;
}
#activityFeed .placeholder {
	pointer-events: none;
}
#activityFeed .placeholder span {
	opacity: 0.3;
}
#activityFeed .placeholder * {
	border-color: var(--greyD) !important;
}
.feedCard .feedCardTop {
	display: flex;
	gap: 15px;
	align-items: center;
}
.feedCard .feedCardTop .userThumbContainer,
.feedCard .feedCardTop .thumbContainer {
	flex: 0 0 45px;
}
.feedCard .feedCardTop .userThumb {
	width: 100%;
	border-radius: 50%;
	object-fit: cover;
}
.feedCard .feedCardHeader {
	display: flex;
	flex-direction: column;
	flex: 1;
	min-width: 0;
	padding-top: 5px;
}
.feedCard .feedCardMeta {
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}
.feedCard .feedActor,
.feedCard .feedAction {
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.feedCard h3 {
	display: block;
	overflow: hidden;
	margin-bottom: -4px;
	line-height: 1.2;
}
.feedCard h3 a {
	overflow: hidden;
	white-space: nowrap;
	text-overflow: ellipsis;
	max-width: 100%;
	display: inline-block;
}
.feedCard .feedSketchImg {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

/* Sketch mosaic grid â€” shared by newSketchGroup (1999:3754) and
   newCurationSubmit (2081:2997), both a 5-col grid of <sketch> tiles. */
.feedCard .feedCardMeta--stacked {
	flex-direction: column;
	display: flex;
}

/* newFollow card (Figma node 2086:3220) â€” shared with the followSuggestion
   variant (2040:2177) via the `suggestion` prop on feed_newFollow.mjs. */
#activityFeed .newFollow .feedFollowRow {
	display: flex;
	align-items: center;
	justify-content: space-between;
	width: 100%;
	gap: 5px;
}
#activityFeed .newFollow .feedFollowRow .feedActor {
	flex: 1;
	min-width: 0;
}
#activityFeed .newFollow .feedFollowBack {
	display: flex;
	align-items: center;
	gap: 5px;
	
	flex: 0 0 auto;
}
#activityFeed .newFollow .feedFollowBack.loading {
	pointer-events: none;
	opacity: 0.6;
}
#activityFeed .newFollow .feedFollowBack.following {
	color: var(--grey9);
}
#activityFeed .feedSketchGrid {
	display: grid;
	grid-template-columns: repeat(5, minmax(0, 1fr));
	gap: 5px;
	width: 100%;
}
#activityFeed .feedSketchGrid .sketch {
	aspect-ratio: 1 / 1; /* default 1Ã—1 tile */
	margin: 0;
	min-width: 0;
	box-sizing: border-box;
}
/* Dynamic spans so each row fills all 5 columns (see itemClass in feed_newSketchGroup.mjs).
   Column spans come from grid.css (.grid-xs-2/3); sketches stay 1:1 always, so
   each column-span gets an equal row-span â€” a wider tile is a bigger square,
   never a stretched rectangle. */
#activityFeed .feedSketchGrid .sketch.feedSketch--span3 {
	grid-row: span 3;
}
#activityFeed .feedSketchGrid .sketch.feedSketch--span2 {
	grid-row: span 2;
}
/* newCurationSubmit: the first tile is always the sketch you submitted,
   spanning 2x2 with a grey ring to set it apart from the curation's own
   sketches that follow it. */
#activityFeed .feedSketchGrid .sketch.feedSketch--mine {
	border-size: 10px;
}
/* Shared by both the <sketch> Vue component (root div) and the raw
   `<a class="sketch">` single-image hero wrapper (feed_newSketch.mjs,
   feed_newCurationSketchSubmission.mjs, and the loading placeholder in
   user_feed.mjs). `display:block` is explicit here rather than relying on
   flex-item blockification, since this rule needs to hold regardless of what
   context a `.sketch` ends up in. aspect-ratio replaces height:100%, which
   never actually resolved here (percentage heights need a definite-height
   ancestor, and .feedCard's height is intrinsic/auto) â€” the square shape
   only "worked" before because thumbnail assets themselves happen to be square. */
#activityFeed .sketch {
	display: block;
	width: 100%;
	aspect-ratio: 1 / 1;
	border-radius: 12px;
	overflow: hidden;
	box-sizing: border-box;
	border: 1px solid var(--greyD);
}
#activityFeed .feedSketchGrid .sketchThumb {
	object-fit: cover;
	display: block;
}

/* newComment card (Figma node 2100:2954) — grey speech bubble with a tail.
   The bubble is indented (pl:25px) so it sits under the header text, and its
   top-left corner is square (the tail lives there). */
#activityFeed .newComment .feedCommentBottom {
	display: flex;
	padding-left: 25px;
	width: 100%;
}
#activityFeed .newComment .feedCommentBubble {
	position: relative;
	/* flex: 1; */
	padding: 15px;
	background: var(--greyE);
	border-radius: 0 12px 12px 12px;
	font-size: 18px;
}
/* speech-bubble tail at the (square) top-left corner, pointing up */
#activityFeed .newComment .feedCommentBubble::before {
	content: '';
	position: absolute;
	top: -7px;
	left: 0;
	width: 0;
	height: 0;
	border-right: 8px solid transparent;
	border-bottom: 8px solid var(--greyE);
}

/* Dev-only demo overlay (?feedDemo) â€” see assets/js/user/feed/feedDemo.mjs */
#feedDemoOverlay {
	position: fixed;
	inset: 0;
	z-index: 99999;
	background: #f5f5f5;
	overflow-y: auto;
	padding: 0 0 60px;
}
#feedDemoHeader {
	position: sticky;
	top: 0;
	z-index: 1;
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 15px 20px;
	background: #222;
	color: #fff;
}
#feedDemoHeader span {
	color: #999;
	font-size: 13px;
}
#feedDemoClose {
	margin-left: auto;
	background: none;
	border: none;
	color: #fff;
	font-size: 24px;
	line-height: 1;
	cursor: pointer;
}
#feedDemoOverlay .feedDemoList {
	max-width: 900px;
	margin: 30px auto 0;
	column-count: 2;
	column-gap: 30px;
	padding: 0 20px;
	list-style: none;
}
#feedDemoOverlay .feedDemoItem {
	break-inside: avoid;
	margin-bottom: 30px;
}
#feedDemoOverlay .feedDemoLabel {
	font-family: monospace;
	font-size: 12px;
	color: #999;
	margin: 0 0 8px;
}

/* Onboarding banner (shown above the feed for new users) */
#onboarding {
	position: relative;
	padding: 30px 0;
	margin-bottom: 60px;
	overflow: hidden;
}
#onboarding .onboardingBg {
	height: 107px;
	margin-bottom: calc(10vw - 103px);
	font-size: calc(15.6vw - 30px);
	color: var(--greyE);
	white-space: nowrap;
	text-align: center;
	margin-top: -50px;
}
#onboarding .onboardingPillars {
	position: relative;
	font-size: 18px;
}
#onboarding .onboardingCard {
	background: #fff;
	border-radius: 12px;
	padding: 15px;
	display: flex;
	flex-direction: column;
	gap: 15px;
	justify-content: space-between;
}
#onboarding .onboardingCard h3 {
	margin-bottom: -6px;
}

#onboarding .onboardingLink {
	flex:1;
	display: flex;
	align-items: flex-end;
}
#onboarding .onboardingHide {
	margin: 5px 0 0;
	text-align: right;
}


#activityFeedContainer li.feedItem.unread .from::before {
	content: "â—";
	position: absolute;
	left: 3px;
	top: 50%;
	display: block;
	width: 10px;
	height: 20px;
	transform: translateY(-50%);
	/* background: #bbb; */
}

#activityFeedContainer .placeholder .text{
	color: #ccc;
}
#activityFeedContainer li.feedItem .from::after {
	background: url('/assets/img/icons/icon_caret_right_dark.png') right center no-repeat;
	background-position: center center;
	background-size: 7px 14px;
	content: '';
	display: block;
	width: 15px;
	height: 100%;
	left: 84%;
	position: absolute;
	top: 0;
}

#activityFeedContainer .sketchThumb {
	/* position: relative; */
}

#activityFeedContainer .welcome .to {
	position: relative;
	height: 100%;
	padding-top: 10px;
}

#activityFeedContainer .to {
	flex-basis: 128px;
}

#activityFeedContainer .feedItem h2 {
	font-size: 32px;
	margin-bottom: 5px !important;
	line-height: 1;
}

#activityFeedContainer .groupSketch {
	padding: 0;
	flex: 1;
	max-width: 300px;
}
#activityFeedContainer .newSketchGroup .groupSketch:first-child {
	display: none;
}


#activityFeedContainer .newComment h2 {
	font-size: 22px;
	margin-top: 5px;
}


#activityFeedContainer .sketchThumb {
	border: none;
}

#activityFeedContainer .text {flex: 1;}

#activityFeedContainer .plus {
	display: none;
}

#ulactivityFeedContainer,
#activityFeedContainer li.feedItem {
	list-style: none;
	padding: 0;
	margin-bottom: 60px;
	transition: all 200ms;
	opacity: 1;
	padding-top: 0px;
	position: relative;
	display: flex;
	align-items: flex-start;
	justify-content: flex-start;
	gap: 15px;
}
#activityFeedContainer li.tip {
	/* border: 1px solid #ccc; */
	/* background: #fafafa; */
	/* padding: 30px; */
	margin-bottom: 15px;
}
#activityFeedContainer li.tip h2 {
	margin-bottom: 10px !important;
}

#activityFeedContainer li.feedItem.animateEntry {
	/* opacity: 0; */
	margin-bottom: 0px;
	padding-bottom: 40px;
}

#activity .from {
	position: relative;
}
#activityFeedContainer .text > * {
	margin-bottom: 6px;
}

#activityFeedContainer .icon_star {
	width: 50px;
	height: 50px;
}
#activityFeedContainer li.feedItem ul {
	padding-left: 20px;
}
#activityFeedContainer li.feedItem li {
	list-style-type: circle;
	padding-left: 5px;
	margin-bottom: 10px;
}
#activityFeedContainer .actionText {
	/* color: #999; */
}
#activityFeedContainer .groupSketchContainer {
	display: flex;
	flex-wrap: wrap;
}
#activityFeedContainer .groupSketch {
	flex: 0 0 100px;
	max-width: 300px;
}

@media (max-width: 767px) {
	#activityFeedContainer .groupSketch:first-child {
		display: none;
	}
	#activityFeedContainer .groupSketch:first-child {
		display: block;
	}

}