/* Joey — Transcon AI Assistant */
.tcj-tool-page {
	--tcj-red: #c8102e;
	--tcj-ink: #14171a;
	--tcj-ink-2: #3b4046;
	--tcj-mute: #6b7280;
	--tcj-line: #e5e7eb;
	--tcj-bg: #f5f6f8;
	--tcj-card: #ffffff;
	--tcj-shadow: 0 1px 2px rgba(20,23,26,.04), 0 8px 24px rgba(20,23,26,.06);
	color: var(--tcj-ink);
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}
.tcj-tool-page * { box-sizing: border-box; }

.tcj-eyebrow {
	display: inline-block;
	font-size: 11px;
	font-weight: 700;
	letter-spacing: .12em;
	text-transform: uppercase;
	color: var(--tcj-red);
	background: rgba(200,16,46,.08);
	padding: 4px 10px;
	border-radius: 999px;
	margin-bottom: 12px;
}

.tcj-hero {
	background: linear-gradient(180deg, #fafbfc 0%, #ffffff 100%);
	padding: 56px 0 24px;
	border-bottom: 1px solid var(--tcj-line);
}
.tcj-hero h1 {
	font-size: clamp(28px, 4vw, 42px);
	line-height: 1.15;
	margin: 0 0 12px;
}
.tcj-lede {
	font-size: 17px;
	line-height: 1.6;
	color: var(--tcj-ink-2);
	max-width: 760px;
	margin: 0;
}

.tcj-stage {
	background: var(--tcj-bg);
	padding: 36px 0 60px;
}

/* Fullpage chat shell */
.tcj-fullpage {
	background: var(--tcj-card);
	border: 1px solid var(--tcj-line);
	border-radius: 14px;
	box-shadow: var(--tcj-shadow);
	display: flex;
	flex-direction: column;
	overflow: hidden;
	min-height: 540px;
	max-height: 70vh;
}

.tcj-header {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 16px 22px;
	background: var(--tcj-ink);
	color: #fff;
	border-bottom: 1px solid #000;
}
.tcj-avatar {
	width: 44px;
	height: 44px;
	border-radius: 10px;
	background: #fff;
	display: flex;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
	overflow: hidden;
	padding: 4px;
}
.tcj-avatar img { width: 100%; height: 100%; object-fit: contain; display: block; }
.tcj-avatar svg { width: 28px; height: 28px; }
.tcj-header-text { flex: 1; min-width: 0; }
.tcj-header-text strong {
	display: block;
	font-size: 15px;
	color: #fff;
	font-weight: 600;
}
.tcj-header-text span {
	font-size: 12px;
	color: #c0c4ca;
}
.tcj-header-text span.is-online::before {
	content: "";
	display: inline-block;
	width: 7px; height: 7px;
	border-radius: 50%;
	background: #10b981;
	margin-right: 6px;
	vertical-align: middle;
	animation: tcj-pulse 2s infinite;
}
@keyframes tcj-pulse {
	0%, 100% { opacity: 1; }
	50% { opacity: 0.4; }
}

.tcj-messages {
	flex: 1;
	overflow-y: auto;
	padding: 22px;
	background: #fafbfc;
}

.tcj-msg {
	display: flex;
	gap: 10px;
	margin-bottom: 16px;
	max-width: 85%;
	animation: tcj-fade-in .25s ease;
}
@keyframes tcj-fade-in {
	from { opacity: 0; transform: translateY(6px); }
	to { opacity: 1; transform: translateY(0); }
}

.tcj-msg-bot {
	align-self: flex-start;
}
.tcj-msg-user {
	align-self: flex-end;
	flex-direction: row-reverse;
	margin-left: auto;
}

.tcj-msg-avatar {
	width: 36px;
	height: 36px;
	border-radius: 8px;
	flex-shrink: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	overflow: hidden;
	padding: 3px;
}
.tcj-msg-bot .tcj-msg-avatar { background: #fff; border: 1px solid var(--tcj-line); }
.tcj-msg-user .tcj-msg-avatar {
	background: #d1d5db;
	color: #fff;
	font-weight: 600;
	font-size: 12px;
	padding: 0;
	border-radius: 50%;
}
.tcj-msg-bot .tcj-msg-avatar img { width: 100%; height: 100%; object-fit: contain; display: block; }

.tcj-msg-bubble {
	background: #fff;
	color: var(--tcj-ink);
	padding: 11px 15px;
	border-radius: 14px;
	border: 1px solid var(--tcj-line);
	font-size: 14.5px;
	line-height: 1.55;
	word-wrap: break-word;
}
.tcj-msg-user .tcj-msg-bubble {
	background: var(--tcj-ink);
	color: #fff;
	border-color: var(--tcj-ink);
}

.tcj-msg-bubble p { margin: 0 0 10px; }
.tcj-msg-bubble p:last-child { margin-bottom: 0; }
.tcj-msg-bubble strong { color: inherit; }
.tcj-msg-bubble a { color: var(--tcj-red); text-decoration: underline; }
.tcj-msg-user .tcj-msg-bubble a { color: #ffd1d8; }

.tcj-typing {
	display: flex;
	gap: 4px;
	padding: 4px 0;
}
.tcj-typing span {
	width: 7px; height: 7px;
	border-radius: 50%;
	background: var(--tcj-mute);
	animation: tcj-bounce 1.2s infinite;
}
.tcj-typing span:nth-child(2) { animation-delay: .2s; }
.tcj-typing span:nth-child(3) { animation-delay: .4s; }
@keyframes tcj-bounce {
	0%, 60%, 100% { transform: translateY(0); opacity: .4; }
	30% { transform: translateY(-5px); opacity: 1; }
}

.tcj-composer {
	padding: 14px 22px;
	border-top: 1px solid var(--tcj-line);
	background: #fff;
	display: flex;
	gap: 10px;
	align-items: flex-end;
}
.tcj-composer textarea {
	flex: 1;
	resize: none;
	border: 1.5px solid var(--tcj-line);
	border-radius: 10px;
	padding: 10px 14px;
	font-size: 14.5px;
	font-family: inherit;
	color: var(--tcj-ink);
	min-height: 42px;
	max-height: 140px;
	line-height: 1.4;
	outline: none;
	transition: border-color .15s ease;
}
.tcj-composer textarea:focus { border-color: var(--tcj-ink); }

.tcj-send {
	background: var(--tcj-red);
	color: #fff;
	border: 0;
	border-radius: 10px;
	padding: 0 18px;
	height: 42px;
	font-size: 14px;
	font-weight: 600;
	cursor: pointer;
	font-family: inherit;
	transition: background .15s ease;
	flex-shrink: 0;
}
.tcj-send:hover { background: #9a0c23; }
.tcj-send:disabled { background: #d1d5db; cursor: not-allowed; }

.tcj-demo-banner {
	background: #fff7e6;
	color: #6b5418;
	padding: 8px 22px;
	font-size: 12px;
	border-bottom: 1px solid #f0d9a8;
	text-align: center;
}

.tcj-suggestions {
	margin-top: 18px;
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	align-items: center;
}
.tcj-suggestions-label {
	margin: 0 8px 0 0;
	font-size: 13px;
	color: var(--tcj-mute);
	font-weight: 500;
}
.tcj-suggestion {
	background: #fff;
	border: 1.5px solid var(--tcj-line);
	color: var(--tcj-ink-2);
	padding: 8px 14px;
	border-radius: 999px;
	font-size: 13px;
	font-weight: 500;
	cursor: pointer;
	font-family: inherit;
	transition: all .15s ease;
}
.tcj-suggestion:hover {
	border-color: var(--tcj-ink);
	color: var(--tcj-ink);
}

.tcj-disclaimer {
	background: #fff7e6;
	border-top: 1px solid #f0d9a8;
	padding: 14px 0;
	font-size: 13px;
	color: #6b5418;
}
.tcj-disclaimer code {
	background: rgba(0,0,0,.06);
	padding: 1px 6px;
	border-radius: 3px;
	font-size: 12px;
}

/* ----- Floating launcher (for site-wide embedding) ----- */
.tcj-launcher {
	position: fixed;
	bottom: 24px;
	right: 24px;
	z-index: 9999;
	width: 60px; height: 60px;
	background: var(--tcj-red, #c8102e);
	color: #fff;
	border: 0;
	border-radius: 50%;
	box-shadow: 0 8px 24px rgba(20,23,26,.18);
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: transform .15s ease;
	font-family: inherit;
}
.tcj-launcher:hover { transform: scale(1.05); }
.tcj-launcher svg { width: 32px; height: 32px; }
.tcj-launcher img { width: 38px; height: 38px; object-fit: contain; display: block; filter: brightness(0) invert(1); }

.tcj-launcher-tooltip {
	position: fixed;
	bottom: 96px;
	right: 24px;
	background: #14171a;
	color: #fff;
	padding: 10px 14px;
	border-radius: 10px;
	font-size: 13px;
	max-width: 240px;
	box-shadow: 0 8px 24px rgba(20,23,26,.18);
	z-index: 9998;
}
.tcj-launcher-tooltip::after {
	content: "";
	position: absolute;
	bottom: -6px;
	right: 24px;
	width: 0; height: 0;
	border: 6px solid transparent;
	border-top-color: #14171a;
	border-bottom: 0;
}

@media (max-width: 600px) {
	.tcj-fullpage { max-height: 75vh; }
	.tcj-launcher { width: 54px; height: 54px; bottom: 16px; right: 16px; }
}
