/* Citable Chat Widget — stile, palette brand (#26344E / #CCFF00 / #F8F9FA) */

#citable-chat-launcher {
	position: fixed;
	bottom: 24px;
	right: 24px;
	width: 72px;
	height: 72px;
	border-radius: 50%;
	background: #26344E;
	border: none;
	cursor: pointer;
	z-index: 9998;
	display: flex;
	align-items: center;
	justify-content: center;
	box-shadow: 0 4px 14px rgba(0, 0, 0, 0.25);
	transition: transform 0.15s ease;
}
#citable-chat-launcher:hover {
	transform: scale(1.05);
}
#citable-chat-launcher svg {
	width: 34px;
	height: 34px;
	stroke: #CCFF00;
}

#citable-chat-panel {
	position: fixed;
	bottom: 96px;
	right: 24px;
	width: 380px;
	max-width: calc(100vw - 32px);
	height: 560px;
	max-height: calc(100vh - 140px);
	background: #F8F9FA;
	border-radius: 12px;
	box-shadow: 0 8px 30px rgba(0, 0, 0, 0.3);
	display: none;
	flex-direction: column;
	overflow: hidden;
	z-index: 9999;
	font-family: Montserrat, system-ui, sans-serif;
}
#citable-chat-panel.is-open {
	display: flex;
}

.citable-chat-header {
	background: #26344E;
	color: #F8F9FA;
	padding: 16px;
	font-weight: 700;
	display: flex;
	align-items: center;
	justify-content: space-between;
	flex-shrink: 0;
}
.citable-chat-header button {
	background: none;
	border: none;
	color: #F8F9FA;
	cursor: pointer;
	font-size: 18px;
	line-height: 1;
}

.citable-chat-body {
	flex: 1;
	overflow-y: auto;
	padding: 16px;
	display: flex;
	flex-direction: column;
	gap: 12px;
}

.citable-chat-msg {
	max-width: 90%;
	padding: 10px 14px;
	border-radius: 10px;
	font-size: 14px;
	line-height: 1.5;
}
.citable-chat-msg p {
	margin: 0 0 8px 0;
}
.citable-chat-msg p:last-child {
	margin-bottom: 0;
}
.citable-chat-msg ul,
.citable-chat-msg ol {
	margin: 4px 0 8px 0;
	padding-left: 18px;
}
.citable-chat-msg li {
	margin-bottom: 4px;
}
.citable-chat-msg.is-user {
	align-self: flex-end;
	background: #26344E;
	color: #F8F9FA;
	white-space: pre-wrap;
}
.citable-chat-msg.is-assistant {
	align-self: flex-start;
	background: #ffffff;
	color: #0E0E10;
	border: 1px solid #E6E6E0;
}
.citable-chat-msg.is-error {
	align-self: flex-start;
	background: #ffffff;
	color: #5B5B62;
	border: 1px dashed #E6E6E0;
	font-style: italic;
}

.citable-chat-suggestions {
	display: flex;
	flex-direction: column;
	gap: 8px;
	align-self: stretch;
}
.citable-chat-suggestion-btn {
	background: #ffffff;
	border: 1px solid #26344E;
	color: #26344E;
	border-radius: 8px;
	padding: 10px 12px;
	font-size: 13px;
	font-weight: 600;
	text-align: left;
	cursor: pointer;
	font-family: inherit;
}
.citable-chat-suggestion-btn:hover {
	background: #26344E;
	color: #F8F9FA;
}

.citable-chat-audit-link {
	align-self: flex-start;
	background: #CCFF00;
	color: #26344E;
	border-radius: 8px;
	padding: 8px 14px;
	font-size: 13px;
	font-weight: 700;
	text-decoration: none;
	cursor: pointer;
}
.citable-chat-audit-link:hover {
	filter: brightness(0.95);
}

.citable-chat-contact-btn {
	align-self: flex-start;
	background: none;
	border: 1px solid #26344E;
	color: #26344E;
	border-radius: 8px;
	padding: 8px 14px;
	font-size: 13px;
	font-weight: 600;
	cursor: pointer;
}
.citable-chat-contact-btn:disabled {
	opacity: 0.6;
	cursor: default;
}

.citable-chat-form {
	padding: 16px;
	display: flex;
	flex-direction: column;
	gap: 10px;
	border-top: 1px solid #E6E6E0;
	flex-shrink: 0;
}
.citable-chat-form input[type="text"],
.citable-chat-form input[type="email"] {
	padding: 10px 12px;
	border: 1px solid #E6E6E0;
	border-radius: 8px;
	font-size: 14px;
	font-family: inherit;
}
.citable-chat-form button {
	background: #26344E;
	color: #F8F9FA;
	border: none;
	border-radius: 8px;
	padding: 10px;
	font-weight: 600;
	cursor: pointer;
}

.citable-chat-input-row {
	display: flex;
	gap: 8px;
	padding: 12px 16px;
	border-top: 1px solid #E6E6E0;
	flex-shrink: 0;
}
.citable-chat-input-row textarea {
	flex: 1;
	resize: none;
	border: 1px solid #E6E6E0;
	border-radius: 8px;
	padding: 8px 10px;
	font-family: inherit;
	font-size: 14px;
	height: 40px;
}
.citable-chat-input-row button {
	background: #CCFF00;
	color: #26344E;
	border: none;
	border-radius: 8px;
	padding: 0 16px;
	font-weight: 700;
	cursor: pointer;
}
.citable-chat-input-row button:disabled {
	opacity: 0.5;
	cursor: default;
}

.citable-chat-hp {
	display: none !important;
}

@media (max-width: 420px) {
	#citable-chat-panel {
		right: 12px;
		bottom: 84px;
	}
}