.hca-widget-root,
.hca-inline-root {
	position: relative;
	font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
	font-size: 15px;
	line-height: 1.5;
	color: #111827;
	box-sizing: border-box;
	-webkit-font-smoothing: antialiased;
}

.hca-inline-root {
	margin: 1.5rem 0;
	max-width: 400px;
}

.hca-widget-root .hca-panel,
.hca-inline-root .hca-panel {
	box-sizing: border-box;
}

/* Launcher — Asyntai-style accent */
.hca-fab {
	position: fixed;
	right: 22px;
	bottom: 22px;
	z-index: 99998;
	width: 56px;
	height: 56px;
	border: none;
	border-radius: 50%;
	background: #0d9488;
	color: #fff;
	cursor: pointer;
	box-shadow: 0 4px 20px rgba(13, 148, 136, 0.4);
	display: flex;
	align-items: center;
	justify-content: center;
	transition: transform 0.15s ease, background 0.15s ease, box-shadow 0.15s ease;
}

.hca-fab:hover {
	background: #0f766e;
	transform: scale(1.06);
	box-shadow: 0 6px 24px rgba(13, 148, 136, 0.45);
}

.hca-panel {
	position: fixed;
	right: 22px;
	bottom: 90px;
	z-index: 99999;
	width: min(380px, calc(100vw - 36px));
	max-height: min(520px, calc(100vh - 120px));
	background: #fff;
	border-radius: 16px;
	box-shadow: 0 16px 48px rgba(15, 23, 42, 0.12), 0 0 0 1px rgba(15, 23, 42, 0.06);
	display: flex;
	flex-direction: column;
	overflow: hidden;
}

.hca-inline-root .hca-panel {
	position: relative;
	right: auto;
	bottom: auto;
	width: 100%;
	max-height: 500px;
	box-shadow: 0 8px 32px rgba(15, 23, 42, 0.08), 0 0 0 1px rgba(15, 23, 42, 0.06);
}

.hca-panel[hidden] {
	display: none !important;
}

.hca-header {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 12px;
	padding: 16px 14px 14px 18px;
	background: #fff;
	border-bottom: 1px solid #f1f5f9;
}

.hca-brand {
	flex: 1;
	min-width: 0;
}

.hca-title-row {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 10px;
	margin-bottom: 2px;
}

.hca-title {
	font-weight: 600;
	font-size: 16px;
	color: #0f172a;
	letter-spacing: -0.02em;
}

.hca-online {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	font-size: 12px;
	font-weight: 500;
	color: #64748b;
}

.hca-online-dot {
	width: 8px;
	height: 8px;
	border-radius: 50%;
	background: #22c55e;
	box-shadow: 0 0 0 2px rgba(34, 197, 94, 0.25);
	flex-shrink: 0;
}

.hca-subtitle {
	font-size: 12px;
	color: #94a3b8;
	margin-top: 2px;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.hca-close {
	flex-shrink: 0;
	width: 32px;
	height: 32px;
	border: none;
	border-radius: 8px;
	background: transparent;
	color: #94a3b8;
	font-size: 22px;
	line-height: 1;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	margin: -4px -4px 0 0;
	transition: background 0.12s ease, color 0.12s ease;
}

.hca-close:hover {
	background: #f1f5f9;
	color: #475569;
}

.hca-messages {
	flex: 1;
	overflow-y: auto;
	padding: 14px 14px 12px;
	background: #f8fafc;
	min-height: 200px;
}

.hca-row {
	display: flex;
	margin-bottom: 12px;
}

.hca-row-user {
	justify-content: flex-end;
}

.hca-row-bot {
	justify-content: flex-start;
}

.hca-bubble {
	max-width: 90%;
	padding: 11px 14px;
	border-radius: 14px;
	word-break: break-word;
	font-size: 14px;
}

.hca-bubble-user {
	background: #0d9488;
	color: #fff;
	border-bottom-right-radius: 4px;
}

.hca-bubble-bot {
	background: #fff;
	color: #1e293b;
	border: 1px solid #e2e8f0;
	border-bottom-left-radius: 4px;
	box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

.hca-bubble-bot a {
	color: #0d9488;
	text-decoration: underline;
	text-underline-offset: 2px;
}

.hca-bubble-bot a:hover {
	color: #0f766e;
}

.hca-form {
	display: flex;
	gap: 8px;
	padding: 12px 14px 14px;
	background: #fff;
	border-top: 1px solid #f1f5f9;
}

.hca-input {
	flex: 1;
	border: 1px solid #e2e8f0;
	border-radius: 10px;
	padding: 10px 12px;
	font-size: 14px;
	outline: none;
	background: #f8fafc;
	transition: border-color 0.12s ease, box-shadow 0.12s ease, background 0.12s ease;
}

.hca-input::placeholder {
	color: #94a3b8;
}

.hca-input:focus {
	border-color: #0d9488;
	background: #fff;
	box-shadow: 0 0 0 3px rgba(13, 148, 136, 0.15);
}

.hca-send {
	border: none;
	border-radius: 10px;
	padding: 10px 16px;
	background: #0d9488;
	color: #fff;
	font-weight: 600;
	font-size: 14px;
	cursor: pointer;
	transition: background 0.12s ease;
}

.hca-send:hover {
	background: #0f766e;
}

.hca-typing {
	opacity: 0.7;
	font-style: italic;
	color: #64748b !important;
	border-style: dashed !important;
}
