/* Стили для компонента Roll/Hide + Sympathy */

.rh-sympathy-widget {
	display: inline-block;
	vertical-align: middle;
	margin-left: 0.5rem;
}

.rh-sympathy-widget .btn-group {
	margin-left: 0;
}

.rh-sympathy-widget .btn {
	padding: 0.25rem 0.5rem;
	font-size: 0.875rem;
	line-height: 1.5;
	border-radius: 0.2rem;
	transition: all 0.2s ease;
}

.rh-sympathy-widget .btn.active {
	background-color: #6c757d;
	border-color: #6c757d;
	color: white;
}

.rh-sympathy-widget .btn.btn-secondary {
	background-color: #6c757d;
	border-color: #6c757d;
	color: white;
}

.rh-sympathy-widget .btn:disabled {
	opacity: 0.65;
	cursor: not-allowed;
}

/* .rh-sympathy-widget .btn:focus {
	 box-shadow: 0 0 0 0.2rem rgba(108, 117, 125, 0.25);
} */

.rh-sympathy-widget .btn:hover:not(:disabled) {
	transform: translateY(-1px);
}

.rh-status-indicator {
	display: inline-flex;
	align-items: center;
	font-size: 0.75rem;
	color: #6c757d;
	margin-left: 0.5rem;
	height: 100%;
	vertical-align: middle;
}

.rh-spinner {
	margin-left: 0.25rem;
	vertical-align: middle;
}

.rh-status-short {
	font-weight: bold;
	font-size: 0.7rem;
	padding: 0.1rem 0.3rem;
	border-radius: 0.2rem;
	background-color: transparent;
}

.rh-status-indicator.text-success .rh-status-short {
	background-color: rgba(40, 167, 69, 0.1);
	color: #28a745;
}

.rh-status-indicator.text-danger .rh-status-short {
	background-color: rgba(220, 53, 69, 0.1);
	color: #dc3545;
}

.rh-status-indicator.text-muted .rh-status-short {
	background-color: rgba(108, 117, 125, 0.1);
	color: #6c757d;
}

.rh-guest-warning,
.rh-cannot-manage {
	opacity: 0.7;
	cursor: help;
	display: inline-block;
	margin-left: 0.5rem;
}

.rh-guest-warning svg,
.rh-cannot-manage svg {
	width: 16px;
	height: 16px;
}

/* Стили для состояний сообщений */
.rh-rolled .icms-forum__post-content,
.rh-rolled .icms-forum__post-footer {
	display: none !important;
}

.rh-rolled .icms-forum__post-header {
	background-color: #f8f9fa;
	border-left: 3px solid #6c757d;
}

.rh-rolled-view {
	background-color: #f8f9fa;
	border-left: 3px solid #6c757d;
	margin: 0.5rem 0;
	padding: 0.5rem;
	/*  border-radius: 0.25rem; */
	animation: rh-fade-in 0.5s ease-in-out;
}

.rh-rolled-view .font-weight-bold {
	color: #495057;
}

.rh-rolled-view .text-muted {
	font-size: 0.875rem;
}

.rh-hidden .icms-forum__post-content,
.rh-hidden .icms-forum__post-footer {
	display: none !important;
}

.rh-hidden .icms-forum__post-header {
	background-color: #f8f9fa;
	border-left: 3px solid #dc3545;
	opacity: 0.8;
}

.rh-hidden-placeholder {
	background-color: #f8f9fa;
	border: 2px dashed #dee2e6;
	border-radius: 0.5rem;
	margin: 1rem 0;
	padding: 2rem 1rem;
	text-align: center;
	color: #6c757d;
	animation: rh-fade-in 0.3s ease-in-out;
}

.rh-hidden-placeholder i {
	color: #adb5bd;
	margin-bottom: 1rem;
}

.rh-hidden-placeholder .small {
	font-size: 0.875rem;
	font-style: italic;
}

/* Анимации */
@keyframes rh-fade-in {
	from {
		opacity: 0;
		transform: translateY(-10px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

/* Плавные переходы */
.icms-forum__post-content,
.icms-forum__post-footer,
.rh-rolled-view,
.rh-hidden-placeholder {
	transition: all 0.3s ease;
}

/* Адаптивность */
@media (max-width: 576px) {
	/* Мобильные устройства */
	.rh-sympathy-widget .btn span {
		display: none;
	}

	.rh-sympathy-widget .btn {
		padding: 0.25rem;
	}

	.rh-status-indicator {
		margin-left: 0.25rem;
		font-size: 0.7rem;
	}

	.rh-status-text {
		display: none !important;
	}

	.rh-status-short {
		display: inline-block !important;
		font-size: 0.65rem;
		padding: 0.1rem 0.2rem;
	}

	.rh-rolled-view,
	.rh-hidden-placeholder {
		padding: 0.5rem;
		margin: 0.25rem 0;
	}

	.rh-hidden-placeholder {
		padding: 1rem 0.5rem;
	}
}

@media (min-width: 577px) and (max-width: 768px) {
	/* Планшеты и маленькие экраны */
	.rh-status-indicator {
		font-size: 0.7rem;
		margin-left: 0.35rem;
	}

	.rh-status-text {
		font-size: 0.7rem;
		max-width: 120px;
		white-space: nowrap;
		overflow: hidden;
		text-overflow: ellipsis;
	}

	.rh-status-short {
		display: none !important;
	}
}

@media (min-width: 769px) and (max-width: 992px) {
	/* Средние экраны */
	.rh-status-indicator {
		font-size: 0.75rem;
		margin-left: 0.5rem;
	}

	.rh-status-text {
		font-size: 0.75rem;
		max-width: 150px;
		white-space: nowrap;
		overflow: hidden;
		text-overflow: ellipsis;
	}

	.rh-status-short {
		display: none !important;
	}
}

@media (min-width: 993px) {
	/* Большие экраны */
	.rh-status-indicator {
		font-size: 0.8rem;
		margin-left: 0.5rem;
	}

	.rh-status-text {
		font-size: 0.8rem;
		max-width: 200px;
		white-space: nowrap;
		overflow: hidden;
		text-overflow: ellipsis;
	}

	.rh-status-short {
		display: none !important;
	}
}

/* Состояния для отладки */
.rh-sympathy-widget[data-initialized="true"] {
	/* border: 1px solid #28a745; */
}

.rh-sympathy-widget[data-is-logged="false"] .btn {
	opacity: 0.7;
	cursor: not-allowed;
}
