/*
 * Applied IT Solutions — AI Chatbot
 */
.aits-chatbot {
	position: fixed;
	right: 24px;
	bottom: 24px;
	z-index: 99999;
	font-family: Arial, Helvetica, sans-serif;
}
.aits-chatbot-toggle {
	display: flex;
	align-items: center;
	gap: 10px;
	border: 0;
	border-radius: 28px;
	padding: 13px 18px;
	background: #d97706;
	color: #ffffff;
	box-shadow: 0 8px 28px rgba(0, 0, 0, 0.25);
	cursor: pointer;
	font-size: 15px;
	font-weight: 700;
}
.aits-chatbot-toggle:hover {
	background: #b45309;
}
.aits-chatbot-toggle-icon {
	display: inline-flex;
	width: 25px;
	height: 25px;
	align-items: center;
	justify-content: center;
	border: 2px solid rgba(255, 255, 255, 0.9);
	border-radius: 50%;
	font-weight: 700;
}
.aits-chatbot-panel {
	position: absolute;
	right: 0;
	bottom: 64px;
	display: flex;
	width: 390px;
	max-width: calc(100vw - 32px);
	height: 570px;
	max-height: calc(100vh - 110px);
	flex-direction: column;
	overflow: hidden;
	border: 1px solid #334155;
	border-radius: 14px;
	background: #0f172a;
	color: #e2e8f0;
	box-shadow: 0 18px 55px rgba(0, 0, 0, 0.4);
	opacity: 0;
	visibility: hidden;
	transform: translateY(12px);
	transition:
		opacity 0.18s ease,
		transform 0.18s ease,
		visibility 0.18s ease;
}
.aits-chatbot-panel.aits-chatbot-open {
	opacity: 1;
	visibility: visible;
	transform: translateY(0);
}
.aits-chatbot-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 16px 18px;
	background: #111827;
	border-bottom: 1px solid #334155;
}
.aits-chatbot-title {
	font-size: 16px;
	font-weight: 700;
}
.aits-chatbot-subtitle {
	margin-top: 3px;
	color: #94a3b8;
	font-size: 12px;
}
.aits-chatbot-close {
	border: 0;
	background: transparent;
	color: #cbd5e1;
	font-size: 27px;
	line-height: 1;
	cursor: pointer;
}
.aits-chatbot-messages {
	flex: 1;
	overflow-y: auto;
	padding: 18px;
}
.aits-chatbot-message {
	width: fit-content;
	max-width: 88%;
	margin-bottom: 12px;
	padding: 11px 13px;
	border-radius: 12px;
	font-size: 14px;
	line-height: 1.5;
	white-space: pre-line;
}
.aits-chatbot-message-bot {
	margin-right: auto;
	background: #1e293b;
	color: #e2e8f0;
}
.aits-chatbot-message-user {
	margin-left: auto;
	background: #d97706;
	color: #ffffff;
}
.aits-chatbot-typing {
	color: #94a3b8;
	font-style: italic;
}
.aits-chatbot-sources {
	display: flex;
	flex-direction: column;
	gap: 5px;
	margin: -3px 0 14px;
	padding-left: 5px;
	font-size: 12px;
}
.aits-chatbot-sources-label {
	color: #94a3b8;
	font-weight: 700;
}
.aits-chatbot-sources a {
	color: #f59e0b;
	text-decoration: none;
}
.aits-chatbot-sources a:hover {
	text-decoration: underline;
}
.aits-chatbot-form {
	display: flex;
	gap: 8px;
	padding: 12px;
	border-top: 1px solid #334155;
	background: #111827;
}
.aits-chatbot-form textarea {
	min-width: 0;
	flex: 1;
	resize: none;
	border: 1px solid #475569;
	border-radius: 9px;
	padding: 10px;
	background: #0f172a;
	color: #f8fafc;
	font: inherit;
	font-size: 14px;
	outline: none;
}
.aits-chatbot-form textarea:focus {
	border-color: #d97706;
}
.aits-chatbot-form button {
	align-self: stretch;
	border: 0;
	border-radius: 9px;
	padding: 0 14px;
	background: #d97706;
	color: #ffffff;
	cursor: pointer;
	font-weight: 700;
}
.aits-chatbot-form button:disabled {
	opacity: 0.55;
	cursor: default;
}
.aits-chatbot-disclaimer {
	padding: 7px 12px 10px;
	background: #111827;
	color: #64748b;
	font-size: 10px;
	text-align: center;
}
@media (max-width: 600px) {
	.aits-chatbot {
		right: 12px;
		bottom: 12px;
		left: 12px;
	}
	.aits-chatbot-toggle {
		margin-left: auto;
	}
	.aits-chatbot-panel {
		right: 0;
		bottom: 60px;
		width: calc(100vw - 24px);
		height: min(
			570px,
			calc(100vh - 90px)
		);
	}
}
.aits-chatbot-header-actions {
	display: flex;
	align-items: center;
	gap: 8px;
	margin-left: auto;
}

.aits-chatbot-clear {
	display: inline-block;
	border: 0;
	background: transparent;
	color: #94a3b8;
	padding: 4px 6px;
	cursor: pointer;
	font-family: Arial, Helvetica, sans-serif;
	font-size: 12px;
	font-weight: 700;
	line-height: 1.2;
	visibility: visible;
	opacity: 1;
}

.aits-chatbot-clear:hover {
	color: #f59e0b;
}