/* AI Live Chat Widget Styles */

#ai-live-chat-widget {
	position: fixed;
	bottom: 20px;
	right: 20px;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
	z-index: 9999;
}

.ai-chat-launcher {
	width: 60px;
	height: 60px;
	background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
	transition: all 0.3s ease;
	border: none;
	color: white;
	font-size: 24px;
}

.ai-chat-launcher:hover {
	transform: scale(1.1);
	box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

.ai-chat-launcher.active {
	background: linear-gradient(135deg, #764ba2 0%, #667eea 100%);
}

.ai-chat-window {
	position: absolute;
	bottom: 80px;
	right: 0;
	width: 400px;
	height: 600px;
	background: white;
	border-radius: 12px;
	box-shadow: 0 5px 40px rgba(0, 0, 0, 0.16);
	display: flex;
	flex-direction: column;
	overflow: hidden;
	animation: slideUp 0.3s ease;
}

@keyframes slideUp {
	from {
		opacity: 0;
		transform: translateY(20px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

.ai-chat-header {
	background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
	color: white;
	padding: 16px;
	display: flex;
	justify-content: space-between;
	align-items: center;
}

.ai-chat-header h3 {
	margin: 0;
	font-size: 16px;
	font-weight: 600;
}

.ai-chat-close {
	background: none;
	border: none;
	color: white;
	cursor: pointer;
	font-size: 20px;
	padding: 0;
	width: 24px;
	height: 24px;
	display: flex;
	align-items: center;
	justify-content: center;
}

.ai-chat-messages {
	flex: 1;
	overflow-y: auto;
	padding: 16px;
	background: #f5f5f5;
}

.ai-chat-message {
	margin-bottom: 12px;
	display: flex;
	animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
	from {
		opacity: 0;
		transform: translateY(10px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

.ai-chat-message.user {
	justify-content: flex-end;
}

.ai-chat-message.ai {
	justify-content: flex-start;
}

.ai-chat-message.admin {
	justify-content: flex-start;
}

.ai-chat-bubble {
	max-width: 80%;
	padding: 12px 16px;
	border-radius: 8px;
	word-wrap: break-word;
	font-size: 14px;
	line-height: 1.4;
}

.ai-chat-message.user .ai-chat-bubble {
	background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
	color: white;
}

.ai-chat-message.ai .ai-chat-bubble {
	background: #e0e0e0;
	color: #333;
}

.ai-chat-message.admin .ai-chat-bubble {
	background: #c8e6c9;
	color: #1b5e20;
	border-left: 4px solid #4caf50;
}

.ai-chat-timestamp {
	font-size: 12px;
	color: #999;
	margin-top: 4px;
	text-align: right;
}

.ai-chat-input-area {
	padding: 12px;
	background: white;
	border-top: 1px solid #e0e0e0;
	display: flex;
	gap: 8px;
}

.ai-chat-input {
	flex: 1;
	border: 1px solid #ddd;
	border-radius: 6px;
	padding: 10px 12px;
	font-size: 14px;
	font-family: inherit;
	resize: none;
	max-height: 100px;
}

.ai-chat-input:focus {
	outline: none;
	border-color: #667eea;
	box-shadow: 0 0 0 2px rgba(102, 126, 234, 0.1);
}

.ai-chat-send {
	background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
	color: white;
	border: none;
	border-radius: 6px;
	padding: 10px 16px;
	cursor: pointer;
	font-weight: 600;
	transition: all 0.2s ease;
	align-self: flex-end;
}

.ai-chat-send:hover {
	transform: translateY(-2px);
	box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

.ai-chat-send:active {
	transform: translateY(0);
}

.ai-chat-loading {
	display: flex;
	gap: 4px;
	align-items: center;
}

.ai-chat-loading span {
	width: 8px;
	height: 8px;
	background: #667eea;
	border-radius: 50%;
	animation: bounce 1.4s infinite;
}

.ai-chat-loading span:nth-child(1) {
	animation-delay: -0.32s;
}

.ai-chat-loading span:nth-child(2) {
	animation-delay: -0.16s;
}

@keyframes bounce {
	0%, 80%, 100% {
		transform: scaleY(0.5);
		opacity: 0.5;
	}
	40% {
		transform: scaleY(1);
		opacity: 1;
	}
}

/* Mobile responsive */
@media (max-width: 480px) {
	.ai-chat-window {
		width: 100%;
		height: 100%;
		bottom: 0;
		right: 0;
		border-radius: 0;
	}
}
