.ai-chatbot-widget {
	position: fixed;
	bottom: 20px;
	z-index: 999999;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

.ai-chatbot-widget [hidden] {
	display: none !important;
}

.ai-chatbot-widget.ai-chatbot-pos-right {
	right: 20px;
}

.ai-chatbot-widget.ai-chatbot-pos-left {
	left: 20px;
}

.ai-chatbot-bubble {
	width: 60px;
	height: 60px;
	border-radius: 50%;
	background: #2563eb;
	color: #fff;
	border: none;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	box-shadow: 0 4px 14px rgba(0, 0, 0, 0.25);
	transition: transform 0.15s ease;
}

.ai-chatbot-bubble:hover {
	transform: scale(1.05);
}

.ai-chatbot-icon-close {
	display: none;
}

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

.ai-chatbot-widget.is-open .ai-chatbot-icon-close {
	display: block;
}

.ai-chatbot-window {
	position: absolute;
	bottom: 76px;
	width: 340px;
	max-width: calc(100vw - 40px);
	height: 460px;
	max-height: 70vh;
	background: #fff;
	border-radius: 12px;
	box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
	display: flex;
	flex-direction: column;
	overflow: hidden;
}

.ai-chatbot-pos-right .ai-chatbot-window {
	right: 0;
}

.ai-chatbot-pos-left .ai-chatbot-window {
	left: 0;
}

.ai-chatbot-header {
	background: #2563eb;
	color: #fff;
	padding: 12px 16px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	font-weight: 600;
}

.ai-chatbot-header-title {
	font-size: 15px;
}

#ai-chatbot-close {
	background: none;
	border: none;
	color: #fff;
	font-size: 22px;
	line-height: 1;
	cursor: pointer;
}

.ai-chatbot-messages {
	flex: 1;
	overflow-y: auto;
	padding: 12px;
	display: flex;
	flex-direction: column;
	gap: 8px;
	background: #f5f7fb;
}

.ai-chatbot-msg {
	max-width: 85%;
	padding: 8px 12px;
	border-radius: 12px;
	font-size: 14px;
	line-height: 1.4;
	white-space: pre-wrap;
	word-wrap: break-word;
}

.ai-chatbot-msg-bot {
	background: #fff;
	border: 1px solid #e2e8f0;
	align-self: flex-start;
	border-bottom-left-radius: 2px;
}

.ai-chatbot-msg-user {
	background: #2563eb;
	color: #fff;
	align-self: flex-end;
	border-bottom-right-radius: 2px;
}

.ai-chatbot-msg-typing {
	font-style: italic;
	color: #64748b;
}

.ai-chatbot-msg a.ai-chatbot-link-btn {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	margin-top: 8px;
	padding: 8px 14px;
	background: #2563eb;
	color: #fff !important;
	border-radius: 999px;
	font-size: 13px;
	font-weight: 600;
	text-decoration: none !important;
	box-shadow: 0 2px 6px rgba(37, 99, 235, 0.35);
	transition: background 0.15s ease, transform 0.15s ease;
}

.ai-chatbot-msg a.ai-chatbot-link-btn:hover {
	background: #1d4ed8;
	transform: translateY(-1px);
}

.ai-chatbot-form {
	display: flex;
	align-items: center;
	border-top: 1px solid #e2e8f0;
	padding: 8px;
	gap: 8px;
}

#ai-chatbot-input {
	flex: 1;
	border: 1px solid #cbd5e1;
	border-radius: 20px;
	padding: 9px 14px;
	font-size: 14px;
}

#ai-chatbot-input:focus {
	outline: none;
	border-color: #2563eb;
}

#ai-chatbot-send {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 38px;
	height: 38px;
	flex-shrink: 0;
	background: #2563eb;
	color: #fff;
	border: none;
	border-radius: 50%;
	cursor: pointer;
	box-shadow: 0 2px 6px rgba(37, 99, 235, 0.35);
	transition: background 0.15s ease, transform 0.15s ease;
}

#ai-chatbot-send:hover:not(:disabled) {
	background: #1d4ed8;
	transform: scale(1.05);
}

#ai-chatbot-send svg {
	width: 17px;
	height: 17px;
}

#ai-chatbot-send:disabled,
#ai-chatbot-input:disabled {
	opacity: 0.6;
	cursor: not-allowed;
}

.ai-chatbot-email-form {
	border-top: 1px solid #e2e8f0;
	padding: 12px;
	background: #f8fafc;
	display: flex;
	flex-direction: column;
	gap: 8px;
}

.ai-chatbot-email-label {
	font-size: 13px;
	margin: 0;
	color: #334155;
}

#ai-chatbot-email-input {
	border: 1px solid #cbd5e1;
	border-radius: 8px;
	padding: 9px 12px;
	font-size: 14px;
}

#ai-chatbot-email-input:focus {
	outline: none;
	border-color: #16a34a;
}

#ai-chatbot-email-send {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	background: #16a34a;
	color: #fff;
	border: none;
	border-radius: 999px;
	padding: 10px 16px;
	cursor: pointer;
	font-size: 14px;
	font-weight: 600;
	box-shadow: 0 2px 6px rgba(22, 163, 74, 0.35);
	transition: background 0.15s ease, transform 0.15s ease;
}

#ai-chatbot-email-send:hover:not(:disabled) {
	background: #15803d;
	transform: translateY(-1px);
}

#ai-chatbot-email-send:disabled {
	opacity: 0.6;
	cursor: not-allowed;
}

.ai-chatbot-email-status {
	font-size: 12px;
	color: #334155;
}

@media (max-width: 480px) {
	.ai-chatbot-window {
		width: calc(100vw - 24px);
		height: 70vh;
	}
}
