/* BuddyBot Shortcode Chat - Modern Design Alignment */
/* Matching rainmaker-buddybot internal design patterns */

:root {
	/* Color palette matching internal design */
	--bb-color-primary: #0073aa;
	--bb-color-header: #2a374a;
	--bb-color-success: #46b450;
	--bb-color-warning: #ffb900;
	--bb-color-danger: #dc6803;

	/* Gray tones */
	--bb-gray-50: #fafafa;
	--bb-gray-100: #f6f7f7;
	--bb-gray-200: #dcdcde;
	--bb-gray-300: #c3c4c7;
	--bb-gray-400: #a7aaad;
	--bb-gray-500: #8c8f94;
	--bb-gray-600: #646970;
	--bb-gray-700: #3c434a;
	--bb-gray-800: #1d2327;

	/* Typography */
	--bb-text-xs: 12px;
	--bb-text-sm: 13px;
	--bb-text-base: 14px;
	--bb-text-lg: 15px;
	--bb-text-xl: 18px;

	/* Spacing */
	--bb-space-1: 4px;
	--bb-space-2: 8px;
	--bb-space-3: 12px;
	--bb-space-4: 16px;
	--bb-space-5: 20px;
	--bb-space-6: 24px;

	/* Borders and shadows */
	--bb-radius: 4px;
	--bb-radius-md: 6px;
	--bb-radius-lg: 12px;
	--bb-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
	--bb-shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
	--bb-shadow-lg: 0 4px 20px rgba(0, 0, 0, 0.08);
}

span.fw-bold.text-dark.assistat-chat-name {
	margin-left: 20px;
	font-size: 1.7em;
	margin-bottom: 14px !important;
	display: flex;
}

/* Main wrapper with modern card design */
#buddybot-single-conversation-wrapper {
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
	background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
	border-radius: var(--bb-radius-lg);
	box-shadow: var(--bb-shadow-lg), 0 1px 3px rgba(0, 0, 0, 0.05);
	border: 1px solid rgba(255, 255, 255, 0.2);
	padding: var(--bb-space-5);
	margin: var(--bb-space-5) auto;
	max-width: 800px;
	color: var(--bb-gray-700);
	line-height: 1.4;
}

/* Conversation list header with modern design */
#buddybot-chat-conversation-list-header {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-bottom: var(--bb-space-4);
	padding: var(--bb-space-5);
	background: var(--bb-color-header);
	border-radius: var(--bb-radius-md);
	margin-left: calc(-1 * var(--bb-space-5));
	margin-right: calc(-1 * var(--bb-space-5));
	margin-top: calc(-1 * var(--bb-space-5));
	position: relative;
}

#buddybot-chat-conversation-list-header::after {
	content: "";
	position: absolute;
	bottom: 0;
	left: 0;
	right: 0;
	height: 1px;
	background: linear-gradient(90deg, transparent 0%, rgba(255, 255, 255, 0.2) 50%, transparent 100%);
}

/* Instructions wrapper styling */
.buddybot-instructions-wrapper {
	flex: 1;
	text-align: left;
}

.buddybot-header-title {
	color: rgba(255, 255, 255, 0.95);
	font-size: var(--bb-text-lg);
	font-weight: 600;
	text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
	margin-bottom: 2px;
}

.buddybot-instruction-text {
	color: rgba(255, 255, 255, 0.75);
	font-size: var(--bb-text-sm);
	font-weight: 400;
	text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
	line-height: 1.3;
}

#buddybot-chat-conversation-list-header .small {
	color: rgba(255, 255, 255, 0.9) !important;
	font-size: var(--bb-text-lg);
	font-weight: 600;
	text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

/* Start New button with internal design style */
#buddybot-chat-conversation-start-new {
	background: linear-gradient(135deg, var(--bb-color-primary) 0%, #005a87 100%) !important;
	border: 1px solid rgba(255, 255, 255, 0.15) !important;
	color: #fff !important;
	font-weight: 500;
	font-size: var(--bb-text-sm);
	padding: var(--bb-space-3) var(--bb-space-4) !important;
	border-radius: var(--bb-radius-md) !important;
	transition: all 0.2s ease;
	box-shadow: 0 2px 6px rgba(0, 115, 170, 0.25);
	text-shadow: none;
	white-space: nowrap;
	display: flex;
	align-items: center;
	gap: var(--bb-space-1);
}

.buddybot-new-icon {
	font-size: 16px;
	font-weight: bold;
	line-height: 1;
}

#buddybot-chat-conversation-start-new:hover {
	background: linear-gradient(135deg, #005a87 0%, #004c73 100%) !important;
	border-color: rgba(255, 255, 255, 0.25) !important;
	transform: translateY(-1px);
	box-shadow: 0 3px 8px rgba(0, 115, 170, 0.35);
}

/* Section divider between header and conversations */
.buddybot-conversation-section-divider {
	height: 1px;
	background: linear-gradient(90deg, transparent 0%, var(--bb-gray-200) 20%, var(--bb-gray-200) 80%, transparent 100%);
	margin: var(--bb-space-4) 0;
	opacity: 0.6;
}

/* Conversation list styling */
#buddybot-chat-conversation-list-wrapper {
	background: white;
	border-radius: var(--bb-radius-md);
	border: 1px solid var(--bb-gray-200);
	overflow: hidden;
	margin-bottom: var(--bb-space-4);
}

#buddybot-chat-conversation-list-wrapper .list-group {
	margin: 0;
	border-radius: 0;
}

#buddybot-chat-conversation-list-wrapper .list-group-item {
	border: none !important;
	border-bottom: 1px solid var(--bb-gray-200) !important;
	background: transparent !important;
	padding: var(--bb-space-4) var(--bb-space-5) !important;
	transition: all 0.2s ease;
	cursor: pointer;
}

#buddybot-chat-conversation-list-wrapper .list-group-item:hover {
	background: var(--bb-gray-50) !important;
	transform: translateX(2px);
}

#buddybot-chat-conversation-list-wrapper .list-group-item:last-child {
	border-bottom: none !important;
}

#buddybot-chat-conversation-list-wrapper .fw-bold {
	font-weight: 600;
	color: var(--bb-gray-800);
	font-size: var(--bb-text-base);
	margin-bottom: 2px;
}

#buddybot-chat-conversation-list-wrapper .text-muted {
	color: var(--bb-gray-500) !important;
	font-size: var(--bb-text-xs);
}

/* Conversations header */
.buddybot-conversations-header {
	padding: var(--bb-space-4) var(--bb-space-5) var(--bb-space-3);
	background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
	border-bottom: 1px solid var(--bb-gray-200);
}

.buddybot-conversation-help-text {
	color: var(--bb-gray-500) !important;
	font-style: italic;
}

/* Individual conversation items */
.buddybot-conversation-item {
	position: relative;
	align-items: center !important;
}

.buddybot-conversation-item:hover .buddybot-conversation-indicator {
	opacity: 1;
	transform: translateX(2px);
}

.buddybot-conversation-indicator {
	opacity: 0.5;
	transition: all 0.2s ease;
	color: var(--bb-gray-400);
	font-size: 18px;
	display: flex;
	align-items: center;
	padding-right: var(--bb-space-2);
}

.buddybot-conversation-title {
	color: var(--bb-gray-800) !important;
}

.buddybot-conversation-date {
	color: var(--bb-gray-500) !important;
}

/* Loading state */
#buddybot-chat-conversation-list-loader {
	text-align: center;
	padding: var(--bb-space-6);
	color: var(--bb-gray-500);
	font-size: var(--bb-text-base);
	background: white;
	border-radius: var(--bb-radius-md);
	border: 1px solid var(--bb-gray-200);
}

/* Temporary chat alert with modern styling */
.Buddybot-alert {
	position: relative;
	display: flex;
	justify-content: center;
	align-items: center;
	margin-bottom: var(--bb-space-4);
	padding: var(--bb-space-3) var(--bb-space-4);
	background: linear-gradient(135deg, #fff3cd 0%, #ffeaa7 100%);
	border: 1px solid #ffeaa7;
	border-radius: var(--bb-radius-md);
	color: var(--bb-gray-700);
	font-size: var(--bb-text-sm);
	font-weight: 500;
}

.buddybot-temp-chat-wrap {
	position: relative;
	display: flex;
	align-items: center;
	gap: var(--bb-space-2);
}

.buddybot-temp-chat-wrap svg {
	width: 18px;
	height: 18px;
	opacity: 0.7;
	transition: transform 0.2s ease;
}

.buddybot-temp-chat-wrap:hover svg {
	transform: scale(1.1);
}

/* Popover with modern design */
.buddybot-popover {
	position: absolute;
	bottom: calc(100% + 8px);
	left: 50%;
	transform: translateX(-50%);
	width: 300px;
	max-width: 90vw;
	background: white;
	color: var(--bb-gray-700);
	font-size: var(--bb-text-sm);
	padding: var(--bb-space-4);
	border-radius: var(--bb-radius-md);
	border: 1px solid var(--bb-gray-200);
	box-shadow: 0 10px 40px rgba(0, 0, 0, 0.12), 0 4px 20px rgba(0, 0, 0, 0.08);
	opacity: 0;
	visibility: hidden;
	transition: all 0.2s ease;
	z-index: 1000;
	line-height: 1.5;
}

.buddybot-popover::before {
	content: "";
	position: absolute;
	top: 100%;
	left: 50%;
	transform: translateX(-50%);
	border-width: 6px;
	border-style: solid;
	border-color: var(--bb-gray-200) transparent transparent transparent;
}

.buddybot-popover::after {
	content: "";
	position: absolute;
	top: 100%;
	left: 50%;
	transform: translateX(-50%);
	border-width: 5px;
	border-style: solid;
	border-color: white transparent transparent transparent;
}

.buddybot-temp-chat-wrap:hover .buddybot-popover {
	opacity: 1;
	visibility: visible;
	transform: translateX(-50%) translateY(-4px);
}

/* Single conversation actions with modern buttons */
#buddybot-single-conversation-wrapper .d-flex.justify-content-between.align-items-center {
	margin-bottom: 0;
	padding: 0;
}

#buddybot-single-conversation-wrapper button#buddybot-single-conversation-back-btn {
	width: 32px;
	height: 32px;
	padding: 21px !important;
}

#buddybot-single-conversation-wrapper button {
	background: linear-gradient(135deg,#0073aa,#005a87) !important;
	border: 1px solid var(--bb-gray-300) !important;
	color: #fff !important;
	padding: var(--bb-space-2) !important;
	border-radius: var(--bb-radius) !important;
	transition: all 0.2s ease;
	width: 36px;
	height: 36px;
	display: flex;
	align-items: center;
	justify-content: center;
}

button#buddybot-single-conversation-delete-thread-btn {
	background: none !important;
	color: #0073aa !important;
	border-color: #0073aa !important;
}

#buddybot-single-conversation-wrapper button#buddybot-single-conversation-delete-thread-btn:hover {
	background: #e44a3c !important;
}

#buddybot-single-conversation-wrapper button:hover {
	background: linear-gradient(135deg, #005a87, #004c73) !important;
	border-color: hsla(0, 0%, 100%, .25) !important;
	color: #fff !important;
	transform: translateY(-1px);
	box-shadow: var(--bb-shadow-sm);
}

/* Messages wrapper with modern styling and increased height */
#buddybot-single-conversation-messages-wrapper {
	background: white;
	border: 1px solid var(--bb-gray-200);
	border-radius: var(--bb-radius-md);
	margin-bottom: var(--bb-space-4) !important;
	max-height: 600px !important; /* Increased from 400px */
	overflow-y: auto;
	padding: var(--bb-space-4);
	min-height: 350px; /* Increased from 200px */
	box-shadow: var(--bb-shadow-sm);
}

/* Scrollbar styling */
#buddybot-single-conversation-messages-wrapper::-webkit-scrollbar {
	width: 6px;
}

#buddybot-single-conversation-messages-wrapper::-webkit-scrollbar-track {
	background: transparent;
}

#buddybot-single-conversation-messages-wrapper::-webkit-scrollbar-thumb {
	background: var(--bb-gray-300);
	border-radius: 3px;
}

#buddybot-single-conversation-messages-wrapper::-webkit-scrollbar-thumb:hover {
	background: var(--bb-gray-400);
}

/* Status bar and spinners */
#buddybot-single-conversation-status-bar {
	margin-bottom: var(--bb-space-3);
}

#buddybot-single-conversation-top-spinners {
	justify-content: center !important;
	margin-bottom: var(--bb-space-3) !important;
}

#buddybot-single-conversation-top-spinners .spinner-grow {
	width: 0.8rem !important;
	height: 0.8rem !important;
	color: var(--bb-color-primary) !important;
}

/* Message input with modern design and inline button */
#buddybot-single-conversation-new-messages-wrapper {
	background: linear-gradient(135deg, #fff 0%, #f8fafc 100%);
	border: 1px solid var(--bb-gray-200);
	border-radius: var(--bb-radius-md);
	padding: var(--bb-space-5);
	box-shadow: var(--bb-shadow-sm);
	position: relative;
}

/* Container for textarea and button positioning */
#buddybot-single-conversation-new-messages-wrapper > div:first-of-type {
	position: relative;
}

#buddybot-single-conversation-user-message {
	border: 2px solid var(--bb-gray-200) !important;
	border-radius: var(--bb-radius-md) !important;
	padding: var(--bb-space-4) 50px var(--bb-space-4) var(--bb-space-4) !important; /* Extra right padding for button */
	transition: all 0.3s ease;
	font-size: var(--bb-text-base);
	line-height: 1.5;
	box-shadow: var(--bb-shadow-sm);
	background: #fff;
	resize: vertical;
	min-height: 80px;
	width: 100%;
}

#buddybot-single-conversation-user-message:focus {
	border-color: var(--bb-color-primary) !important;
	box-shadow: 0 0 0 3px rgba(0, 115, 170, 0.1), var(--bb-shadow-sm) !important;
	outline: none !important;
}

#buddybot-single-conversation-user-message::placeholder {
	color: var(--bb-gray-400);
	font-weight: 400;
}

/* Send button positioned inside textarea - Force all styles */
#buddybot-single-conversation-send-message-btn,
button#buddybot-single-conversation-send-message-btn,
.btn#buddybot-single-conversation-send-message-btn {
	background: linear-gradient(135deg, #0073aa 0%, #005a87 100%) !important;
	background-color: #0073aa !important;
	border: none !important;
	color: #fff !important;
	font-weight: 500 !important;
	width: 40px !important;
	height: 40px !important;
	min-width: 40px !important;
	min-height: 40px !important;
	padding: 0 !important;
	margin: 0 !important;
	border-radius: 50% !important;
	transition: all 0.2s ease !important;
	box-shadow: 0 2px 8px rgba(0, 115, 170, 0.25) !important;
	display: flex !important;
	align-items: center !important;
	justify-content: center !important;
	text-indent: -9999px !important; /* Hide text */
	overflow: hidden !important;
	cursor: pointer !important;
	position: relative !important;
	outline: none !important;
	text-decoration: none !important;
	text-align: center !important;
	vertical-align: middle !important;
	font-size: 0 !important; /* Hide any text */
	line-height: 1 !important;
}

/* Reposition the button container div */
#buddybot-single-conversation-new-messages-wrapper .text-center {
	position: absolute !important;
	bottom: 48px !important;
	right: 37px !important;
	margin: 0 !important;
	z-index: 10;
	display: block !important;
}

#buddybot-single-conversation-send-message-btn:hover,
button#buddybot-single-conversation-send-message-btn:hover,
.btn#buddybot-single-conversation-send-message-btn:hover {
	background: linear-gradient(135deg, #005a87 0%, #004c73 100%) !important;
	background-color: #005a87 !important;
	transform: translateY(-1px) scale(1.05) !important;
	box-shadow: 0 4px 12px rgba(0, 115, 170, 0.35) !important;
}

#buddybot-single-conversation-send-message-btn:active,
button#buddybot-single-conversation-send-message-btn:active,
.btn#buddybot-single-conversation-send-message-btn:active {
	transform: translateY(0) scale(0.95) !important;
}

/* Add arrow icon to send button - Force display */
#buddybot-single-conversation-send-message-btn::before,
button#buddybot-single-conversation-send-message-btn::before,
.btn#buddybot-single-conversation-send-message-btn::before {
	content: "→" !important;
	position: absolute !important;
	top: 50% !important;
	left: 50% !important;
	transform: translate(-50%, -50%) !important;
	font-size: 16px !important;
	font-weight: bold !important;
	color: white !important;
	text-indent: 0 !important;
	line-height: 1 !important;
	display: block !important;
	z-index: 10 !important;
	width: auto !important;
	height: auto !important;
	text-align: center !important;
	font-family: Arial, sans-serif !important;
}

/* Override Bootstrap button styles completely */
.btn-dark#buddybot-single-conversation-send-message-btn,
button.btn-dark#buddybot-single-conversation-send-message-btn,
.btn.btn-dark#buddybot-single-conversation-send-message-btn {
	background: linear-gradient(135deg, #0073aa 0%, #005a87 100%) !important;
	background-color: #0073aa !important;
	border-color: #0073aa !important;
}

.btn-dark#buddybot-single-conversation-send-message-btn:hover,
button.btn-dark#buddybot-single-conversation-send-message-btn:hover,
.btn.btn-dark#buddybot-single-conversation-send-message-btn:hover {
	background: linear-gradient(135deg, #005a87 0%, #004c73 100%) !important;
	background-color: #005a87 !important;
	border-color: #005a87 !important;
}

/* Chat messages styling - User and Bot messages */
.buddybot-chat-conversation-list-item {
	margin-bottom: var(--bb-space-4);
	padding: 0;
	width: 100%;
}

/* User messages (right side, blue) */
.buddybot-chat-conversation-list-item.d-flex.justify-content-end {
	align-items: flex-start;
}

.buddybot-chat-conversation-list-item.d-flex.justify-content-end .p-2 {
	background: linear-gradient(135deg, var(--bb-color-primary) 0%, #005a87 100%) !important;
	color: white !important;
	border-radius: 18px 18px 4px 18px !important;
	box-shadow: 0 2px 8px rgba(0, 115, 170, 0.15);
	border: none !important;
	max-width: 70% !important;
	margin-right: var(--bb-space-3) !important;
	margin-left: auto;
	word-wrap: break-word;
	padding: var(--bb-space-3) var(--bb-space-4) !important;
}

.buddybot-chat-conversation-list-item.d-flex.justify-content-end .p-2 strong {
	color: rgba(255, 255, 255, 0.95);
}

.buddybot-chat-conversation-list-item.d-flex.justify-content-end .p-2 code {
	background: rgba(255, 255, 255, 0.2);
	color: rgba(255, 255, 255, 0.95);
	padding: 2px 6px;
	border-radius: 4px;
	font-family: "SF Mono", Monaco, "Cascadia Code", "Roboto Mono", Consolas, monospace;
}

/* Bot messages (left side, gray) */
.buddybot-chat-conversation-list-item.d-flex.justify-content-start {
	align-items: flex-start;
}

.buddybot-chat-conversation-assistant-response {
	background: linear-gradient(135deg, #f1f5f9 0%, #e2e8f0 100%) !important;
	color: var(--bb-gray-800) !important;
	border-radius: 18px 18px 18px 4px !important;
	box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
	border: 1px solid var(--bb-gray-200) !important;
	max-width: 70%;
	margin-left: var(--bb-space-3) !important;
	margin-right: auto;
	word-wrap: break-word;
	padding: var(--bb-space-3) var(--bb-space-4) !important;
}

.buddybot-chat-conversation-assistant-response strong {
	color: var(--bb-gray-900);
}

.buddybot-chat-conversation-assistant-response code {
	background: rgba(0, 0, 0, 0.08);
	color: var(--bb-gray-800);
	padding: 2px 6px;
	border-radius: 4px;
	font-family: "SF Mono", Monaco, "Cascadia Code", "Roboto Mono", Consolas, monospace;
}

/* Message avatars */
.buddybot-chat-conversation-list-item img {
	width: 32px !important;
	height: 32px !important;
	border-radius: 50%;
	box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
	border: 2px solid white;
}

/* Message timestamps */
.buddybot-chat-conversation-list-item .small.text-secondary {
	font-size: var(--bb-text-xs) !important;
	color: var(--bb-gray-500) !important;
	margin-top: var(--bb-space-1);
	opacity: 0.8;
}

/* File attachments in messages */
.buddybot-chat-conversation-list-item .bg-dark.bg-opacity-10 {
	background: rgba(0, 0, 0, 0.05) !important;
	border: 1px solid var(--bb-gray-200);
	border-radius: var(--bb-radius-md);
	padding: var(--bb-space-3) !important;
	margin-top: var(--bb-space-2);
}

/* Image attachments in messages */
.buddybot-chat-conversation-list-item .bg-secondary.bg-opacity-10 {
	background: rgba(0, 0, 0, 0.05) !important;
	border: 1px solid var(--bb-gray-200);
	border-radius: var(--bb-radius-md);
	padding: var(--bb-space-2) !important;
	margin-bottom: var(--bb-space-2);
}

/* Cookie consent offcanvas with modern styling */
.buddybot-offcanvas-wrap {
	border-radius: var(--bb-radius-lg) var(--bb-radius-lg) 0 0 !important;
	border: 1px solid var(--bb-gray-200);
	box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.1);
}

.buddybot-offcanvas-wrap .offcanvas-header {
	background: linear-gradient(135deg, var(--bb-color-header) 0%, #334155 100%);
	color: white;
	border-bottom: 1px solid rgba(255, 255, 255, 0.1);
	padding: var(--bb-space-4) var(--bb-space-5);
}

.buddybot-offcanvas-wrap .offcanvas-title {
	font-size: var(--bb-text-xl) !important;
	font-weight: 600;
	display: flex;
	align-items: center;
	gap: var(--bb-space-2);
}

.buddybot-offcanvas-wrap .buddybot-offcanvas-body {
	padding: var(--bb-space-5) !important;
	background: linear-gradient(135deg, #fff 0%, #f8fafc 100%);
}

.buddybot-offcanvas-wrap .buddybot-offcanvas-body p {
	font-size: var(--bb-text-base) !important;
	line-height: 1.6;
	color: var(--bb-gray-700);
	margin-bottom: var(--bb-space-4) !important;
}

.buddybot-offcanvas-wrap .buddybot-offcanvas-footer {
	padding: var(--bb-space-4) var(--bb-space-5);
	background: var(--bb-gray-50);
	border-top: 1px solid var(--bb-gray-200);
}

#buddybot-acceptCookies {
	background: linear-gradient(135deg, var(--bb-color-primary) 0%, #005a87 100%) !important;
	border: none !important;
	color: #fff !important;
	font-weight: 500;
	padding: var(--bb-space-3) var(--bb-space-5) !important;
	border-radius: var(--bb-radius-md) !important;
	transition: all 0.2s ease;
	box-shadow: 0 2px 8px rgba(0, 115, 170, 0.25);
}

#buddybot-acceptCookies:hover {
	background: linear-gradient(135deg, #005a87 0%, #004c73 100%) !important;
	transform: translateY(-1px);
	box-shadow: 0 4px 12px rgba(0, 115, 170, 0.35);
}

/* Visitor ID card */
#buddybot-visitor-id-card {
	max-width: 600px;
	width: 100%;
	background: white;
	border: 1px solid var(--bb-gray-200);
	border-radius: var(--bb-radius-lg);
	box-shadow: var(--bb-shadow-lg);
}

/* Responsive design */
@media (max-width: 768px) {
	#buddybot-single-conversation-wrapper {
		margin: var(--bb-space-3) auto;
		padding: var(--bb-space-4);
		border-radius: var(--bb-radius-md);
	}

	#buddybot-chat-conversation-list-header {
		flex-direction: column;
		gap: var(--bb-space-3);
		align-items: stretch;
		padding: var(--bb-space-4);
		margin-left: calc(0 * var(--bb-space-4));
		margin-right: calc(0 * var(--bb-space-4));
		margin-top: calc(0 * var(--bb-space-4));
	}

	.buddybot-instructions-wrapper {
		text-align: center;
		margin-bottom: var(--bb-space-2);
	}

	.buddybot-header-title {
		font-size: var(--bb-text-base);
	}

	.buddybot-instruction-text {
		font-size: var(--bb-text-xs);
	}

	#buddybot-chat-conversation-start-new {
		justify-content: center;
		align-self: center;
		min-width: 140px;
	}

	.buddybot-empty-title {
		font-size: var(--bb-text-lg);
	}

	.buddybot-empty-description {
		font-size: var(--bb-text-sm);
		max-width: 100%;
	}

	.buddybot-empty-tip {
		margin-top: var(--bb-space-3);
	}

	.buddybot-popover {
		width: 280px;
		font-size: var(--bb-text-xs);
		padding: var(--bb-space-3);
	}

	#buddybot-single-conversation-messages-wrapper {
		max-height: 550px !important; /* Increased from 300px */
		min-height: 350px; /* Increased from 150px */
	}

	#buddybot-single-conversation-new-messages-wrapper {
		padding: var(--bb-space-4);
	}

	#buddybot-single-conversation-user-message {
		min-height: 60px;
		font-size: var(--bb-text-sm);
		padding: var(--bb-space-3) 46px var(--bb-space-3) var(--bb-space-3) !important;
	}

	#buddybot-single-conversation-send-message-btn {
		width: 36px !important;
		height: 36px !important;
		min-width: 36px !important;
		font-size: var(--bb-text-sm);
	}

	#buddybot-single-conversation-send-message-btn::before {
		font-size: 14px;
	}

	#buddybot-single-conversation-new-messages-wrapper .text-center {
		bottom: 6px !important;
		right: 6px !important;
	}

	.buddybot-chat-conversation-list-item.d-flex.justify-content-end .p-2 {
		max-width: 80% !important;
		font-size: var(--bb-text-sm);
		padding: var(--bb-space-2) var(--bb-space-3) !important;
	}

	.buddybot-chat-conversation-assistant-response {
		max-width: 80% !important;
		font-size: var(--bb-text-sm);
		padding: var(--bb-space-2) var(--bb-space-3) !important;
	}

	.buddybot-chat-conversation-list-item img {
		width: 28px !important;
		height: 28px !important;
	}

	#buddybot-visitor-id-card {
		width: 95%;
		max-width: 95%;
	}
}

@media (max-width: 480px) {
	#buddybot-single-conversation-wrapper {
		margin: var(--bb-space-2) auto;
		padding: var(--bb-space-3);
	}

	#buddybot-chat-conversation-list-header {
		padding: var(--bb-space-3);
	}

	#buddybot-chat-conversation-list-header .small {
		font-size: var(--bb-text-sm);
	}

	#buddybot-chat-conversation-start-new {
		font-size: var(--bb-text-xs);
		padding: var(--bb-space-2) var(--bb-space-3) !important;
		min-width: 120px;
	}

	.buddybot-empty-title {
		font-size: var(--bb-text-base);
	}

	.buddybot-empty-description {
		font-size: var(--bb-text-xs);
	}

	.buddybot-no-conversations-state {
		padding: var(--bb-space-4);
	}

	.buddybot-popover {
		width: 250px;
		bottom: calc(100% + 4px);
	}

	#buddybot-single-conversation-user-message {
		padding: var(--bb-space-2) 38px var(--bb-space-2) var(--bb-space-2) !important;
	}

	#buddybot-single-conversation-send-message-btn {
		width: 32px !important;
		height: 32px !important;
		min-width: 32px !important;
	}

	#buddybot-single-conversation-send-message-btn::before {
		font-size: 12px;
	}

	#buddybot-single-conversation-new-messages-wrapper .text-center {
		bottom: 4px !important;
		right: 4px !important;
	}

	.buddybot-chat-conversation-list-item.d-flex.justify-content-end .p-2 {
		max-width: 85% !important;
		font-size: var(--bb-text-xs);
		border-radius: 16px 16px 4px 16px !important;
	}

	.buddybot-chat-conversation-assistant-response {
		max-width: 85% !important;
		font-size: var(--bb-text-xs);
		border-radius: 16px 16px 16px 4px !important;
	}

	.buddybot-chat-conversation-list-item img {
		width: 24px !important;
		height: 24px !important;
	}
}

/* Accessibility improvements */
@media (prefers-reduced-motion: reduce) {
	* {
		transition: none !important;
		animation: none !important;
	}
}

/* Focus states for accessibility */
button:focus,
textarea:focus {
	outline: 2px solid var(--bb-color-primary) !important;
	outline-offset: 1px !important;
}

/* No conversations empty state styling */
.buddybot-no-conversations-state {
	background: linear-gradient(135deg, #f8fafc 0%, #ffffff 100%);
	border: 1px solid var(--bb-gray-200);
	border-radius: var(--bb-radius-md);
	padding: var(--bb-space-6);
	margin: var(--bb-space-4) 0;
}

.buddybot-empty-state-icon img {
	opacity: 0.8;
	filter: grayscale(10%);
	transition: all 0.3s ease;
}

.buddybot-empty-state-icon:hover img {
	opacity: 1;
	filter: grayscale(0%);
	transform: scale(1.02);
}

.buddybot-empty-title {
	color: var(--bb-gray-800);
	font-size: var(--bb-text-xl);
	font-weight: 600;
	margin-bottom: var(--bb-space-3);
	line-height: 1.3;
}

.buddybot-empty-description {
	color: var(--bb-gray-600);
	font-size: var(--bb-text-base);
	margin-bottom: var(--bb-space-4);
	line-height: 1.5;
	max-width: 400px;
	margin-left: auto;
	margin-right: auto;
}

.buddybot-empty-tip {
	background: linear-gradient(135deg, #fff3cd 0%, #fef7e0 100%);
	border: 1px solid #f0d000;
	border-radius: var(--bb-radius);
	padding: var(--bb-space-3);
	margin-top: var(--bb-space-4);
	display: inline-block;
}

.buddybot-empty-tip small {
	color: var(--bb-gray-700);
	font-weight: 500;
}

.buddybot-empty-tip strong {
	color: var(--bb-gray-800);
}

/* High contrast mode support */
@media (prefers-contrast: high) {
	:root {
		--bb-gray-200: #999;
		--bb-gray-300: #777;
		--bb-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
	}
}
