/* Live chat dashboard */
#support-ongoing-chats .chat-widget .chat-box {
	min-height: 300px;
}

.users-scroll {
	max-height: calc(100vh - 190px);
	overflow-y: auto;
}

/* --- User card tweaks --- */
.user-card .card-header {
	background: #fff;
	border-bottom: 1px solid rgba(0, 0, 0, 0.125);
}
.user-card .btn-link {
	color: #212529;
	text-align: left;
}
.user-card .btn-link:hover,
.user-card .btn-link:focus {
	text-decoration: none;
}
.user-name {
	max-width: 11rem;
}

/* Truncate helper for collapsed header */
.text-truncate-1 {
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.stat-card {
	text-align: center;
	padding: 15px;
}
.stat-card .stat-value {
	font-size: 2.5rem;
	font-weight: bold;
	color: #007bff;
}
.stat-card .stat-label {
	color: #6c757d;
	font-size: 0.9rem;
}

/* Live chat widget */
.chat-widget-bottom-left {
	position: fixed;
	bottom: 20px;
	left: 20px;
	width: 380px;
	z-index: 1050;
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}
.chat-widget .card {
	margin-bottom: 0;
}
.chat-widget .chat-box {
	max-height: 300px;
	overflow-y: auto;
}
.chat-widget .chat-message {
	margin-bottom: 10px;
	position: relative;
}
.chat-widget .chat-message.msg-self {
	text-align: right;
}
.chat-widget .chat-message.msg-other {
	text-align: left;
}
.chat-widget .chat-message.msg-support-other {
	text-align: left;
}
.chat-widget .chat-badge {
	position: relative;
	top: -2px;
}
.chat-widget .chat-separator {
	text-align: center;
	border-bottom: 1px solid #ddd;
	line-height: 0.1em;
	margin: 10px 0 20px;
}
.chat-widget .chat-separator span {
	background: #f8f9fa;
	padding: 0 10px;
	font-size: 0.8rem;
	color: #888;
}
.chat-widget.minimized .card-body,
.chat-widget.minimized .card-footer {
	display: none !important;
}
.chat-header-toggle {
	cursor: pointer;
	min-height: 3.4rem;
}
.chat-widget .card-footer {
	min-height: 4rem;
}

.chat-widget .open-widget-icon {
	display: none;
}

.chat-widget.minimized .open-widget-icon {
	display: inline-block;
}

.chat-widget .close-widget-icon {
	display: inline-block;
}

.chat-widget.minimized .close-widget-icon {
	display: none;
}

.chat-widget .card-footer .start-chat-box,
.chat-widget .card-footer .join-chat-box {
	width: 100%;
}
.chat-widget .js-chat-input {
	resize: none;
	overflow: hidden;
	min-height: 38px;
	max-height: 120px;
	transition: height 0.1s ease;
}
.chat-widget .js-chat-input-area {
	align-items: flex-end;
}
