#ddca-root {
	position: fixed;
	bottom: 20px;
	right: 20px;
	z-index: 99999;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.ddca-bubble {
	width: 58px;
	height: 58px;
	border-radius: 50%;
	background: var(--ddca-accent, #1b1b1b);
	color: #fff;
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	box-shadow: 0 4px 16px rgba(0,0,0,.2);
	border: none;
}

.ddca-bubble svg { width: 26px; height: 26px; }

.ddca-panel {
	display: none;
	flex-direction: column;
	position: absolute;
	bottom: 72px;
	right: 0;
	width: 340px;
	max-width: 90vw;
	height: 460px;
	max-height: 70vh;
	background: #fff;
	border-radius: 14px;
	box-shadow: 0 8px 30px rgba(0,0,0,.25);
	overflow: hidden;
}

.ddca-panel.ddca-open { display: flex; }

.ddca-header {
	background: var(--ddca-accent, #1b1b1b);
	color: #fff;
	padding: 12px 16px;
	font-weight: 600;
	display: flex;
	justify-content: space-between;
	align-items: center;
}

.ddca-header button {
	background: none;
	border: none;
	color: #fff;
	font-size: 18px;
	cursor: pointer;
}

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

.ddca-msg {
	max-width: 85%;
	padding: 8px 12px;
	border-radius: 12px;
	font-size: 13.5px;
	line-height: 1.4;
	white-space: pre-wrap;
}

.ddca-msg.user {
	align-self: flex-end;
	background: var(--ddca-accent, #1b1b1b);
	color: #fff;
}

.ddca-msg.assistant {
	align-self: flex-start;
	background: #fff;
	border: 1px solid #e5e5e5;
	color: #222;
}

.ddca-msg.typing { opacity: .6; font-style: italic; }

.ddca-msg.assistant a {
	color: var(--ddca-accent, #1b1b1b);
	text-decoration: underline;
	font-weight: 600;
}

.ddca-inputrow {
	display: flex;
	border-top: 1px solid #eee;
	padding: 8px;
	gap: 8px;
}

.ddca-inputrow input {
	flex: 1;
	border: 1px solid #ddd;
	border-radius: 20px;
	padding: 8px 14px;
	font-size: 13.5px;
	outline: none;
}

.ddca-inputrow button {
	background: var(--ddca-accent, #1b1b1b);
	color: #fff;
	border: none;
	border-radius: 20px;
	padding: 0 16px;
	cursor: pointer;
	font-size: 13.5px;
}

.ddca-inputrow button:disabled { opacity: .5; cursor: default; }
