/* Micro-Feed panel + bell styles */

.micro-feed-bell {
	position: relative;
	background: transparent;
	border: none;
	cursor: pointer;
	padding: 8px;
	color: inherit;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	line-height: 1;
	border-radius: 4px;
}

.micro-feed-bell svg {
	width: 22px;
	height: 22px;
	display: block;
}

.micro-feed-bell:hover {
	color: var( --micro-feed-accent, #2563eb );
}

.micro-feed-bell:focus-visible {
	outline: 2px solid var( --micro-feed-accent, #2563eb );
	outline-offset: 2px;
}

.micro-feed-badge {
	position: absolute;
	top: 0;
	right: 0;
	min-width: 16px;
	height: 16px;
	padding: 0 4px;
	border-radius: 8px;
	background: #ef4444;
	color: #fff;
	font-size: 10px;
	font-weight: 600;
	line-height: 16px;
	text-align: center;
	box-sizing: border-box;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.micro-feed-menu-item {
	display: inline-flex;
	align-items: center;
	list-style: none;
}

.micro-feed-panel__backdrop {
	position: fixed;
	inset: 0;
	background: rgba( 0, 0, 0, 0.2 );
	z-index: 99998;
	opacity: 0;
	transition: opacity 250ms ease;
}

.micro-feed-panel__backdrop.is-open {
	opacity: 1;
}

.micro-feed-panel {
	position: fixed;
	top: 0;
	right: 0;
	height: 100vh;
	height: 100dvh;
	width: var( --micro-feed-width, 380px );
	max-width: 100vw;
	background: #ffffff;
	color: #111827;
	box-shadow: -8px 0 32px rgba( 0, 0, 0, 0.08 );
	border-left: 1px solid #e5e7eb;
	z-index: 99999;
	display: flex;
	flex-direction: column;
	transform: translateX( 100% );
	transition: transform 250ms cubic-bezier( 0.16, 1, 0.3, 1 );
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
	font-size: 14px;
}

.micro-feed-panel.is-open {
	transform: translateX( 0 );
}

@media ( max-width: 480px ) {
	.micro-feed-panel {
		width: 100vw;
	}
}

@media ( prefers-reduced-motion: reduce ) {
	.micro-feed-panel,
	.micro-feed-panel__backdrop {
		transition: none;
	}
}

.micro-feed-panel__header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 16px 20px;
	border-bottom: 1px solid #e5e7eb;
	flex-shrink: 0;
}

.micro-feed-panel__header h2 {
	margin: 0;
	font-size: 16px;
	font-weight: 600;
	color: #111827;
	line-height: 1.4;
}

.micro-feed-panel__close {
	background: transparent;
	border: none;
	cursor: pointer;
	padding: 4px;
	color: #6b7280;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	border-radius: 4px;
}

.micro-feed-panel__close:hover {
	color: #111827;
	background: #f3f4f6;
}

.micro-feed-panel__close:focus-visible {
	outline: 2px solid var( --micro-feed-accent, #2563eb );
	outline-offset: 2px;
}

.micro-feed-panel__close svg {
	width: 20px;
	height: 20px;
}

.micro-feed-panel__body {
	flex: 1;
	overflow-y: auto;
	padding: 0;
	-webkit-overflow-scrolling: touch;
}

.micro-feed-panel__loading,
.micro-feed-panel__empty {
	text-align: center;
	color: #6b7280;
	padding: 40px 20px;
	margin: 0;
	font-size: 14px;
}

.micro-feed-panel__footer {
	border-top: 1px solid #e5e7eb;
	padding: 12px 20px;
	text-align: right;
	flex-shrink: 0;
	background: #fafafa;
}

.micro-feed-panel__mark-read {
	background: transparent;
	border: none;
	color: var( --micro-feed-accent, #2563eb );
	cursor: pointer;
	font-size: 13px;
	padding: 4px 8px;
	font-family: inherit;
}

.micro-feed-panel__mark-read:hover {
	text-decoration: underline;
}

.micro-feed-card {
	padding: 16px 20px;
	border-bottom: 1px solid #f3f4f6;
}

.micro-feed-card:last-child {
	border-bottom: none;
}

.micro-feed-card__time {
	font-size: 12px;
	color: #6b7280;
	margin-bottom: 6px;
}

.micro-feed-card__body {
	color: #111827;
	font-size: 14px;
	line-height: 1.6;
	word-wrap: break-word;
}

.micro-feed-card__body p {
	margin: 0 0 8px;
}

.micro-feed-card__body p:last-child {
	margin-bottom: 0;
}

.micro-feed-card__body a {
	color: var( --micro-feed-accent, #2563eb );
}

.micro-feed-card__image {
	display: block;
	width: 100%;
	max-height: 240px;
	object-fit: cover;
	border-radius: 8px;
	margin: 10px 0 0;
}

.micro-feed-card__link {
	display: inline-block;
	margin-top: 10px;
	padding: 6px 12px;
	font-size: 13px;
	font-weight: 500;
	color: var( --micro-feed-accent, #2563eb );
	border: 1px solid var( --micro-feed-accent, #2563eb );
	border-radius: 999px;
	text-decoration: none;
	transition: background 150ms ease, color 150ms ease;
}

.micro-feed-card__link:hover {
	background: var( --micro-feed-accent, #2563eb );
	color: #ffffff;
}
