/**
 * Live Comment Frontend Toast & Highlighting.
 */

.rc-cgh-toast-container {
	position: fixed;
	bottom: 24px;
	right: 24px;
	z-index: 999999;
	max-width: 360px;
	width: calc(100vw - 32px);
	pointer-events: none;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
}

.rc-cgh-toast {
	background: #ffffff;
	color: #1d2327;
	border: 1px solid #dcdcde;
	border-left: 4px solid #2271b1;
	border-radius: 8px;
	box-shadow: 0 4px 18px rgba(0, 0, 0, 0.15), 0 1px 3px rgba(0, 0, 0, 0.08);
	padding: 12px 14px;
	opacity: 0;
	transform: translateY(20px) scale(0.97);
	transition: opacity 0.35s cubic-bezier(0.16, 1, 0.3, 1), transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
	pointer-events: auto;
	cursor: pointer;
	position: relative;
	box-sizing: border-box;
}

.rc-cgh-toast.rc-cgh-toast-visible {
	opacity: 1;
	transform: translateY(0) scale(1);
}

.rc-cgh-toast-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	font-size: 11px;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	color: #2271b1;
	margin-bottom: 5px;
}

.rc-cgh-toast-badge {
	display: inline-flex;
	align-items: center;
	gap: 4px;
}

.rc-cgh-toast-badge-dot {
	width: 7px;
	height: 7px;
	background: #00a32a;
	border-radius: 50%;
	display: inline-block;
	animation: rcCghPulseDot 1.6s infinite ease-in-out;
}

@keyframes rcCghPulseDot {
	0%, 100% { transform: scale(0.9); opacity: 0.8; }
	50% { transform: scale(1.3); opacity: 1; }
}

.rc-cgh-toast-close {
	background: none;
	border: none;
	font-size: 16px;
	line-height: 1;
	color: #8c8f94;
	cursor: pointer;
	padding: 0 4px;
	margin: 0;
}

.rc-cgh-toast-close:hover {
	color: #1d2327;
}

.rc-cgh-toast-title {
	font-size: 12px;
	font-weight: 600;
	color: #50575e;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
	margin-bottom: 4px;
}

.rc-cgh-toast-author {
	font-weight: 700;
	color: #1d2327;
}

.rc-cgh-toast-body {
	font-size: 13px;
	line-height: 1.4;
	color: #2c3338;
	margin-bottom: 6px;
	word-break: break-word;
}

.rc-cgh-toast-footer {
	display: flex;
	align-items: center;
	justify-content: flex-end;
	font-size: 11px;
	font-weight: 600;
	color: #2271b1;
}

.rc-cgh-toast:hover .rc-cgh-toast-footer {
	text-decoration: underline;
}

/* Comment target pulsing highlight when navigated to */
.rc-cgh-comment-highlight {
	animation: rcCghCommentFlash 2.5s ease-out forwards;
	border-radius: 4px;
}

@keyframes rcCghCommentFlash {
	0% {
		background-color: rgba(34, 113, 177, 0.28);
		outline: 2px solid #2271b1;
	}
	70% {
		background-color: rgba(34, 113, 177, 0.12);
		outline: 2px solid transparent;
	}
	100% {
		background-color: transparent;
		outline: 2px solid transparent;
	}
}

@media (max-width: 600px) {
	.rc-cgh-toast-container {
		bottom: 16px;
		right: 16px;
		left: 16px;
		max-width: none;
		width: auto;
	}
}
