.bcops-chat {
	--bcops-color: #1e6fd9;
	position: fixed;
	bottom: 20px;
	z-index: 99999;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
	font-size: 15px;
	line-height: 1.4;
}

.bcops-chat--right { right: 20px; }
.bcops-chat--left { left: 20px; }

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

.bcops-chat__toggle:hover { transform: scale(1.06); }

.bcops-chat__panel {
	position: absolute;
	bottom: 70px;
	width: 340px;
	max-width: calc(100vw - 40px);
	height: 460px;
	max-height: calc(100vh - 120px);
	display: flex;
	flex-direction: column;
	background: #fff;
	border-radius: 12px;
	box-shadow: 0 8px 30px rgba(0, 0, 0, 0.25);
	overflow: hidden;
}

.bcops-chat--right .bcops-chat__panel { right: 0; }
.bcops-chat--left .bcops-chat__panel { left: 0; }

.bcops-chat__panel[hidden] { display: none; }

.bcops-chat__header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 12px 16px;
	background: var(--bcops-color);
	color: #fff;
}

.bcops-chat__title { font-weight: 600; }

.bcops-chat__close {
	border: none;
	background: transparent;
	color: #fff;
	font-size: 24px;
	line-height: 1;
	cursor: pointer;
	padding: 0 4px;
}

.bcops-chat__messages {
	flex: 1;
	overflow-y: auto;
	padding: 14px;
	display: flex;
	flex-direction: column;
	gap: 8px;
	background: #f6f7f9;
}

.bcops-chat__msg {
	max-width: 85%;
	padding: 9px 13px;
	border-radius: 14px;
	white-space: pre-wrap;
	word-wrap: break-word;
	overflow-wrap: break-word;
}

.bcops-chat__msg--user {
	align-self: flex-end;
	background: var(--bcops-color);
	color: #fff;
	border-bottom-right-radius: 4px;
}

.bcops-chat__msg--bot {
	align-self: flex-start;
	background: #fff;
	color: #222;
	border: 1px solid #e2e4e8;
	border-bottom-left-radius: 4px;
}

.bcops-chat__typing { opacity: 0.6; }

.bcops-chat__consent {
	padding: 6px 14px;
	font-size: 11px;
	color: #666;
	background: #fdfdfd;
	border-top: 1px solid #eee;
}

.bcops-chat__form {
	display: flex;
	gap: 8px;
	padding: 10px;
	border-top: 1px solid #e2e4e8;
	background: #fff;
}

.bcops-chat__input {
	flex: 1;
	border: 1px solid #ccd0d5;
	border-radius: 8px;
	padding: 9px 12px;
	font-size: 15px;
	outline: none;
}

.bcops-chat__input:focus { border-color: var(--bcops-color); }

.bcops-chat__send {
	border: none;
	border-radius: 8px;
	background: var(--bcops-color);
	color: #fff;
	padding: 9px 16px;
	cursor: pointer;
	font-size: 14px;
}

.bcops-chat__send:disabled { opacity: 0.6; cursor: default; }

@media (max-width: 480px) {
	.bcops-chat__panel {
		width: calc(100vw - 40px);
		height: 70vh;
	}
}
