/* AI Concierge bubble — Ourhotels v8.76.0
 * Self-contained styles. Deliberately uses CSS custom properties so the
 * brand color set in admin overrides the entire palette. No CSS resets;
 * every selector is scoped under #oh-ai-bubble or #oh-ai-panel.
 */

:root {
	--oh-ai-brand: #1a4d8c;
	--oh-ai-brand-fg: #fff;
	--oh-ai-bg: #fff;
	--oh-ai-text: #1a1a1a;
	--oh-ai-muted: #666;
	--oh-ai-border: #e0e0e0;
	--oh-ai-bubble-bg-user: #f0f6fc;
	--oh-ai-bubble-bg-bot: #f5f5f5;
	--oh-ai-radius: 14px;
	--oh-ai-shadow: 0 4px 24px rgba(0,0,0,.18);
	--oh-ai-z: 999990;
}

#oh-ai-bubble {
	position: fixed;
	bottom: 20px;
	right: 20px;
	width: 60px;
	height: 60px;
	border-radius: 50%;
	background: var(--oh-ai-brand);
	color: var(--oh-ai-brand-fg);
	border: none;
	cursor: pointer;
	box-shadow: var(--oh-ai-shadow);
	z-index: var(--oh-ai-z);
	display: flex;
	align-items: center;
	justify-content: center;
	transition: transform .12s ease;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
}
#oh-ai-bubble:hover { transform: scale(1.05); }
#oh-ai-bubble svg { width: 28px; height: 28px; fill: currentColor; }

#oh-ai-panel {
	position: fixed;
	bottom: 90px;
	right: 20px;
	width: 380px;
	max-width: calc(100vw - 40px);
	height: 600px;
	max-height: calc(100vh - 120px);
	background: var(--oh-ai-bg);
	color: var(--oh-ai-text);
	border-radius: var(--oh-ai-radius);
	box-shadow: var(--oh-ai-shadow);
	display: none;
	flex-direction: column;
	overflow: hidden;
	z-index: var(--oh-ai-z);
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
	font-size: 14px;
	line-height: 1.45;
}
#oh-ai-panel.open { display: flex; }

#oh-ai-header {
	background: var(--oh-ai-brand);
	color: var(--oh-ai-brand-fg);
	padding: 14px 16px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	flex-shrink: 0;
}
#oh-ai-header h3 { margin: 0; font-size: 15px; font-weight: 600; }
#oh-ai-header small { display: block; opacity: .85; font-size: 12px; font-weight: 400; margin-top: 2px; }
#oh-ai-close { background: transparent; border: 0; color: inherit; font-size: 22px; cursor: pointer; padding: 0 4px; line-height: 1; }
#oh-ai-close:hover { opacity: .8; }

#oh-ai-messages {
	flex: 1;
	overflow-y: auto;
	padding: 14px;
	background: #fafafa;
}
.oh-ai-msg {
	margin: 8px 0;
	max-width: 85%;
	padding: 10px 13px;
	border-radius: 12px;
	white-space: pre-wrap;
	word-wrap: break-word;
}
.oh-ai-msg.user {
	background: var(--oh-ai-bubble-bg-user);
	margin-left: auto;
	border-bottom-right-radius: 4px;
}
.oh-ai-msg.assistant {
	background: var(--oh-ai-bubble-bg-bot);
	margin-right: auto;
	border-bottom-left-radius: 4px;
}
.oh-ai-msg.system {
	background: #fff7e0;
	color: #5a4a00;
	font-size: 13px;
	border: 1px solid #f0e0a0;
	margin: 6px auto;
	max-width: 100%;
	text-align: center;
}
.oh-ai-typing {
	display: inline-block;
	color: var(--oh-ai-muted);
	font-style: italic;
	font-size: 13px;
	margin: 6px 0 6px 13px;
}
.oh-ai-typing::after {
	content: '...';
	animation: oh-ai-dots 1.2s steps(4, end) infinite;
}
@keyframes oh-ai-dots {
	0%, 20% { content: ''; }
	40%     { content: '.'; }
	60%     { content: '..'; }
	80%, 100%{ content: '...'; }
}

#oh-ai-input-row {
	border-top: 1px solid var(--oh-ai-border);
	padding: 10px;
	display: flex;
	gap: 8px;
	background: var(--oh-ai-bg);
	flex-shrink: 0;
}
#oh-ai-input {
	flex: 1;
	border: 1px solid var(--oh-ai-border);
	border-radius: 18px;
	padding: 9px 13px;
	font: inherit;
	resize: none;
	max-height: 100px;
	min-height: 36px;
	outline: none;
}
#oh-ai-input:focus { border-color: var(--oh-ai-brand); }
#oh-ai-send {
	background: var(--oh-ai-brand);
	color: var(--oh-ai-brand-fg);
	border: 0;
	border-radius: 18px;
	padding: 0 16px;
	cursor: pointer;
	font: inherit;
	font-weight: 600;
}
#oh-ai-send:disabled { opacity: .5; cursor: not-allowed; }

/* Cards (availability, payment, verify) */
.oh-ai-card {
	background: #fff;
	border: 1px solid var(--oh-ai-border);
	border-radius: 10px;
	padding: 12px;
	margin: 8px 0;
}
.oh-ai-card h4 { margin: 0 0 6px; font-size: 13px; font-weight: 600; }
.oh-ai-card .meta { color: var(--oh-ai-muted); font-size: 12px; margin-bottom: 8px; }

.oh-ai-room {
	display: flex;
	justify-content: space-between;
	align-items: center;
	padding: 8px 0;
	border-top: 1px solid #eee;
}
.oh-ai-room:first-of-type { border-top: 0; }
.oh-ai-room .name { flex: 1; }
.oh-ai-room .price { font-weight: 600; color: var(--oh-ai-brand); margin-right: 8px; }
.oh-ai-room button {
	background: var(--oh-ai-brand);
	color: var(--oh-ai-brand-fg);
	border: 0;
	border-radius: 6px;
	padding: 6px 12px;
	font-size: 12px;
	cursor: pointer;
}

#oh-ai-verify-card label { display: block; margin: 6px 0 2px; font-size: 13px; }
#oh-ai-verify-card input {
	width: 100%; padding: 7px; border: 1px solid var(--oh-ai-border); border-radius: 6px; font: inherit; box-sizing: border-box;
}
#oh-ai-verify-card .actions { margin-top: 10px; display: flex; gap: 6px; }
#oh-ai-verify-card button {
	background: var(--oh-ai-brand); color: var(--oh-ai-brand-fg);
	border: 0; border-radius: 6px; padding: 7px 14px; cursor: pointer; font: inherit;
}
#oh-ai-verify-card .err { color: #d63638; font-size: 12px; margin-top: 6px; }

#oh-ai-stripe-card { padding: 14px; }
#oh-ai-stripe-mount { min-height: 50px; }
#oh-ai-pay-btn {
	margin-top: 10px; width: 100%;
	background: var(--oh-ai-brand); color: var(--oh-ai-brand-fg);
	border: 0; border-radius: 8px; padding: 10px; cursor: pointer;
	font: inherit; font-weight: 600;
}
#oh-ai-pay-btn:disabled { opacity: .5; }

/* Mobile */
@media (max-width: 600px) {
	#oh-ai-panel {
		bottom: 0;
		right: 0;
		width: 100vw;
		max-width: 100vw;
		height: 100vh;
		max-height: 100vh;
		border-radius: 0;
	}
	#oh-ai-bubble { bottom: 16px; right: 16px; }
}
