/* AI Business Booking OS — booking widget
   Identity: a concierge desk. Warm graphite, brass bell accent,
   ink-on-paper conversation. Deliberately not the cream/terracotta AI default. */

.aibos-widget {
	--aibos-ink: #1b1d23;
	--aibos-graphite: #22252e;
	--aibos-paper: #ffffff;
	--aibos-soft: #f4f3ef;
	--aibos-line: #e7e5df;
	--aibos-brass: #c08a2d;
	--aibos-brass-deep: #9a6c1e;
	--aibos-teal: #0f6e63;
	--aibos-muted: #6c7079;

	max-width: 440px;
	margin: 0 auto;
	border: 1px solid var(--aibos-line);
	border-radius: 16px;
	overflow: hidden;
	background: var(--aibos-paper);
	box-shadow: 0 18px 50px -28px rgba(20, 22, 28, 0.45);
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
	color: var(--aibos-ink);
	display: flex;
	flex-direction: column;
	height: 560px;
}

/* Header — the concierge desk */
.aibos-widget .aibos-head {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 16px 18px;
	background: var(--aibos-graphite);
	color: #f6f5f2;
}
.aibos-widget .aibos-bell {
	display: grid;
	place-items: center;
	width: 34px;
	height: 34px;
	border-radius: 50%;
	background: linear-gradient(160deg, var(--aibos-brass), var(--aibos-brass-deep));
	color: #fff;
	flex: none;
}
.aibos-widget .aibos-head-text { display: flex; flex-direction: column; line-height: 1.25; }
.aibos-widget .aibos-head-text strong { font-size: 15px; letter-spacing: 0.2px; }
.aibos-widget .aibos-status {
	font-size: 11.5px;
	color: #b8bcc4;
	display: inline-flex;
	align-items: center;
	gap: 6px;
}
.aibos-widget .aibos-status::before {
	content: "";
	width: 7px; height: 7px;
	border-radius: 50%;
	background: #3ecf8e;
	box-shadow: 0 0 0 3px rgba(62, 207, 142, 0.18);
}

/* Conversation log */
.aibos-widget .aibos-log {
	flex: 1;
	overflow-y: auto;
	padding: 18px;
	background: var(--aibos-soft);
	display: flex;
	flex-direction: column;
	gap: 10px;
}
.aibos-widget .aibos-msg {
	max-width: 82%;
	padding: 10px 13px;
	border-radius: 14px;
	font-size: 14px;
	line-height: 1.45;
	white-space: pre-wrap;
	word-wrap: break-word;
	animation: aibos-rise 0.22s ease;
}
.aibos-widget .aibos-msg.bot {
	align-self: flex-start;
	background: var(--aibos-paper);
	border: 1px solid var(--aibos-line);
	border-bottom-left-radius: 5px;
}
.aibos-widget .aibos-msg.user {
	align-self: flex-end;
	background: var(--aibos-ink);
	color: #f6f5f2;
	border-bottom-right-radius: 5px;
}
.aibos-widget .aibos-typing {
	align-self: flex-start;
	display: inline-flex;
	gap: 4px;
	padding: 12px 14px;
	background: var(--aibos-paper);
	border: 1px solid var(--aibos-line);
	border-radius: 14px;
	border-bottom-left-radius: 5px;
}
.aibos-widget .aibos-typing span {
	width: 6px; height: 6px; border-radius: 50%;
	background: var(--aibos-muted);
	animation: aibos-blink 1.2s infinite ease-in-out both;
}
.aibos-widget .aibos-typing span:nth-child(2) { animation-delay: 0.2s; }
.aibos-widget .aibos-typing span:nth-child(3) { animation-delay: 0.4s; }

/* Affordances: quick replies, slots, contact form */
.aibos-widget .aibos-affordance:not(:empty) {
	padding: 12px 16px;
	border-top: 1px solid var(--aibos-line);
	background: var(--aibos-paper);
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}
.aibos-widget .aibos-chip {
	appearance: none;
	border: 1px solid var(--aibos-line);
	background: #fff;
	color: var(--aibos-ink);
	padding: 9px 14px;
	border-radius: 999px;
	font-size: 13.5px;
	cursor: pointer;
	transition: border-color 0.15s, background 0.15s, transform 0.05s;
}
.aibos-widget .aibos-chip:hover { border-color: var(--aibos-brass); background: #fdf7ec; }
.aibos-widget .aibos-chip:active { transform: translateY(1px); }

.aibos-widget .aibos-slot {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 2px;
	width: 100%;
	border: 1px solid var(--aibos-line);
	background: #fff;
	padding: 11px 14px;
	border-radius: 12px;
	cursor: pointer;
	text-align: left;
	transition: border-color 0.15s, background 0.15s;
}
.aibos-widget .aibos-slot:hover { border-color: var(--aibos-brass); background: #fdf7ec; }
.aibos-widget .aibos-slot .t { font-size: 14px; font-weight: 600; }
.aibos-widget .aibos-slot .s { font-size: 12px; color: var(--aibos-muted); }

.aibos-widget .aibos-form { width: 100%; display: flex; flex-direction: column; gap: 8px; }
.aibos-widget .aibos-form input {
	width: 100%;
	border: 1px solid var(--aibos-line);
	border-radius: 10px;
	padding: 11px 13px;
	font-size: 14px;
	box-sizing: border-box;
	background: #fff;
	color: var(--aibos-ink);
}
.aibos-widget .aibos-form input:focus {
	outline: none;
	border-color: var(--aibos-brass);
	box-shadow: 0 0 0 3px rgba(192, 138, 45, 0.15);
}
.aibos-widget .aibos-confirm {
	background: var(--aibos-teal);
	color: #fff;
	border: none;
	padding: 12px;
	border-radius: 10px;
	font-size: 14px;
	font-weight: 600;
	cursor: pointer;
}
.aibos-widget .aibos-confirm:hover { background: #0c584f; }
.aibos-widget .aibos-confirm:disabled { opacity: 0.6; cursor: default; }

.aibos-widget .aibos-receipt {
	align-self: stretch;
	background: #fff;
	border: 1px solid var(--aibos-line);
	border-left: 3px solid var(--aibos-teal);
	border-radius: 10px;
	padding: 12px 14px;
	font-size: 13px;
}
.aibos-widget .aibos-receipt b { display: block; font-size: 13.5px; margin-bottom: 3px; }
.aibos-widget .aibos-receipt span { color: var(--aibos-muted); }
.aibos-widget .aibos-pay {
	display: inline-block;
	margin-top: 10px;
	background: var(--aibos-brass, #c08a2d);
	color: #fff;
	text-decoration: none;
	font-weight: 600;
	padding: 9px 16px;
	border-radius: 8px;
	font-size: 13.5px;
}
.aibos-widget .aibos-pay:hover { filter: brightness( 0.95 ); }

/* Composer */
.aibos-widget .aibos-input {
	display: flex;
	gap: 8px;
	padding: 12px;
	border-top: 1px solid var(--aibos-line);
	background: var(--aibos-paper);
}
.aibos-widget .aibos-input input {
	flex: 1;
	border: 1px solid var(--aibos-line);
	border-radius: 999px;
	padding: 11px 16px;
	font-size: 14px;
	background: var(--aibos-soft);
	color: var(--aibos-ink);
}
.aibos-widget .aibos-input input:focus {
	outline: none;
	border-color: var(--aibos-brass);
	background: #fff;
}
.aibos-widget .aibos-input button {
	flex: none;
	width: 42px; height: 42px;
	border: none;
	border-radius: 50%;
	background: var(--aibos-ink);
	color: #fff;
	cursor: pointer;
	display: grid;
	place-items: center;
	transition: background 0.15s;
}
.aibos-widget .aibos-input button:hover { background: var(--aibos-brass-deep); }

@keyframes aibos-rise { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
@keyframes aibos-blink { 0%, 80%, 100% { opacity: 0.3; } 40% { opacity: 1; } }

@media (prefers-reduced-motion: reduce) {
	.aibos-widget .aibos-msg,
	.aibos-widget .aibos-typing span { animation: none; }
}

@media (max-width: 480px) {
	.aibos-widget { height: 78vh; border-radius: 12px; }
}
