/* ITSA Floating Chatbot - isolated component styles. */

.itsa-chatbot {
	bottom: 110px;
	font-family: inherit;
	pointer-events: none;
	position: fixed;
	right: 22px;
	z-index: 10020;
}

.itsa-chatbot *,
.itsa-chatbot *:before,
.itsa-chatbot *:after {
	box-sizing: border-box;
}

.itsa-chatbot-toggle {
	align-items: center;
	background: rgba(16, 24, 39, 0.88);
	border: solid 1px rgba(125, 239, 255, 0.42);
	border-radius: 999px;
	box-shadow: 0 0 0 0 rgba(0, 212, 255, 0.28), 0 1em 2.6em rgba(0, 0, 0, 0.34);
	color: #ffffff;
	cursor: pointer;
	display: inline-flex;
	flex-direction: column;
	gap: 0.18em;
	height: 68px;
	justify-content: center;
	min-height: 68px;
	overflow: visible;
	padding: 3px;
	pointer-events: auto;
	position: relative;
	transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
	width: 68px;
}

.itsa-floating-avatar,
.itsa-header-avatar,
.itsa-bot-avatar {
	border-radius: 50%;
	display: block;
	object-fit: cover;
}

.itsa-floating-avatar {
	border: 2px solid #00d9ff;
	box-shadow: 0 0 18px rgba(0, 217, 255, 0.55);
	height: 100%;
	width: 100%;
}

.itsa-chatbot-toggle:before {
	animation: itsa-chatbot-pulse 2.6s ease-out infinite;
	border: solid 1px rgba(0, 212, 255, 0.45);
	border-radius: inherit;
	content: '';
	inset: -6px;
	position: absolute;
}

.itsa-chatbot-toggle:hover {
	border-color: rgba(241, 207, 114, 0.68);
	box-shadow: 0 0 1.4em rgba(0, 212, 255, 0.36), 0 1em 2.8em rgba(0, 0, 0, 0.42);
	transform: translateY(-2px);
}

.itsa-chatbot-toggle:focus-visible,
.itsa-chatbot-close:focus-visible,
.itsa-chatbot-action:focus-visible,
.itsa-chatbot-send:focus-visible,
.itsa-chatbot-input:focus-visible,
.itsa-chatbot-contact:focus-visible {
	outline: solid 2px #f1cf72;
	outline-offset: 3px;
}

.itsa-chatbot-toggle-icon {
	align-items: center;
	background: rgba(255, 255, 255, 0.13);
	border: solid 1px rgba(255, 255, 255, 0.18);
	border-radius: 999px;
	display: inline-flex;
	height: 1.9em;
	justify-content: center;
	position: relative;
	width: 1.9em;
}

.itsa-chatbot-toggle-icon:before,
.itsa-chatbot-toggle-icon:after {
	background: #ffffff;
	border-radius: 999px;
	content: '';
	display: block;
	position: absolute;
}

.itsa-chatbot-toggle-icon:before {
	height: 0.78em;
	width: 1.05em;
}

.itsa-chatbot-toggle-icon:after {
	height: 0.35em;
	right: 0.42em;
	top: 1.16em;
	transform: rotate(42deg);
	width: 0.48em;
}

.itsa-chatbot-toggle-text {
	font-size: 0.72em;
	font-weight: 700;
	letter-spacing: 0.08em;
	line-height: 1;
}

.itsa-chatbot-window {
	background: linear-gradient(180deg, rgba(18, 22, 35, 0.96), rgba(11, 15, 24, 0.98));
	border: solid 1px rgba(125, 239, 255, 0.26);
	border-radius: 18px;
	bottom: 160px;
	box-shadow: 0 1.3em 4em rgba(0, 0, 0, 0.52), inset 0 1px 0 rgba(255, 255, 255, 0.08);
	color: rgba(255, 255, 255, 0.86);
	display: flex;
	flex-direction: column;
	max-height: min(520px, calc(100dvh - 184px));
	opacity: 0;
	overflow: hidden;
	pointer-events: none;
	position: fixed;
	right: 24px;
	transform: translateY(14px) scale(0.98);
	transition: opacity 180ms ease, transform 180ms ease, visibility 180ms ease;
	visibility: hidden;
	width: min(360px, calc(100vw - 32px));
	z-index: 10021;
}

.itsa-chatbot.is-open .itsa-chatbot-window {
	opacity: 1;
	pointer-events: auto;
	transform: translateY(0) scale(1);
	visibility: visible;
}

.itsa-chatbot-header {
	align-items: center;
	background: linear-gradient(135deg, rgba(0, 212, 255, 0.14), rgba(214, 169, 74, 0.1));
	border-bottom: solid 1px rgba(255, 255, 255, 0.09);
	display: flex;
	gap: 0.85em;
	padding: 1em;
}

.itsa-chatbot-avatar {
	align-items: center;
	background: #101827;
	border: solid 1px rgba(241, 207, 114, 0.58);
	border-radius: 999px;
	box-shadow: 0 0 1em rgba(0, 212, 255, 0.18);
	color: #f1cf72;
	display: inline-flex;
	flex: 0 0 auto;
	font-size: 0.82em;
	font-weight: 800;
	height: 3em;
	justify-content: center;
	letter-spacing: 0.06em;
	width: 3em;
}

.itsa-header-avatar {
	border: 2px solid rgba(0, 217, 255, 0.7);
	box-shadow: 0 0 12px rgba(0, 217, 255, 0.35);
	flex: 0 0 auto;
	height: 44px;
	width: 44px;
}

.itsa-chatbot-title {
	flex: 1;
	min-width: 0;
}

.itsa-chatbot-title strong,
.itsa-chatbot-title span {
	display: block;
}

.itsa-chatbot-title strong {
	color: #ffffff;
	font-size: 1em;
	font-weight: 700;
	line-height: 1.2;
}

.itsa-chatbot-title span {
	color: rgba(255, 255, 255, 0.62);
	font-size: 0.8em;
	line-height: 1.35;
	margin-top: 0.15em;
}

.itsa-chatbot-close {
	align-items: center;
	background: rgba(255, 255, 255, 0.08);
	border: solid 1px rgba(255, 255, 255, 0.12);
	border-radius: 999px;
	color: rgba(255, 255, 255, 0.86);
	cursor: pointer;
	display: inline-flex;
	flex: 0 0 auto;
	font-size: 1.15em;
	height: 2.1em;
	justify-content: center;
	line-height: 1;
	padding: 0;
	transition: background-color 180ms ease, color 180ms ease;
	width: 2.1em;
}

.itsa-chatbot-close:hover {
	background: rgba(241, 207, 114, 0.16);
	color: #ffffff;
}

.itsa-chatbot-messages {
	display: flex;
	flex: 1 1 auto;
	flex-direction: column;
	gap: 0.75em;
	overflow-y: auto;
	padding: 1em;
	scrollbar-color: rgba(0, 212, 255, 0.5) rgba(255, 255, 255, 0.08);
}

.itsa-chatbot-message {
	border-radius: 14px;
	font-size: 0.92em;
	line-height: 1.48;
	max-width: 88%;
	padding: 0.8em 0.9em;
	white-space: pre-line;
}

.itsa-chatbot-message-row {
	align-items: flex-start;
	display: flex;
	gap: 0.6em;
	max-width: 100%;
}

.itsa-chatbot-message-row.is-bot {
	align-self: flex-start;
}

.itsa-chatbot-message-row .itsa-chatbot-message {
	max-width: min(18.5em, calc(100vw - 7.5em));
}

.itsa-bot-avatar {
	border: 1px solid rgba(0, 217, 255, 0.65);
	box-shadow: 0 0 8px rgba(0, 217, 255, 0.25);
	flex: 0 0 36px;
	height: 36px;
	margin-top: 0.05em;
	min-width: 36px;
	width: 36px;
}

.itsa-chatbot-message.is-bot {
	align-self: flex-start;
	background: rgba(255, 255, 255, 0.08);
	border: solid 1px rgba(255, 255, 255, 0.08);
	color: rgba(255, 255, 255, 0.88);
}

.itsa-chatbot-message.is-user {
	align-self: flex-end;
	background: linear-gradient(135deg, rgba(0, 212, 255, 0.92), rgba(0, 109, 255, 0.92));
	color: #ffffff;
}

.itsa-chatbot-actions {
	display: block;
	padding: 0 1em 1em;
}

.itsa-chatbot-actions-toggle {
	align-items: center;
	background: rgba(255, 255, 255, 0.07);
	border: solid 1px rgba(241, 207, 114, 0.28);
	border-radius: 999px;
	color: rgba(255, 255, 255, 0.9);
	cursor: pointer;
	display: inline-flex;
	font-size: 0.82em;
	font-weight: 700;
	gap: 0.6em;
	justify-content: space-between;
	line-height: 1.2;
	padding: 0.75em 1em;
	transition: background-color 180ms ease, border-color 180ms ease, color 180ms ease;
	width: 100%;
}

.itsa-chatbot-actions-toggle:after {
	color: #f1cf72;
	content: '+';
	font-size: 1.15em;
	line-height: 1;
}

.itsa-chatbot-actions-toggle[aria-expanded="true"]:after {
	content: '-';
}

.itsa-chatbot-actions-toggle:hover {
	background: rgba(0, 212, 255, 0.12);
	border-color: rgba(0, 212, 255, 0.42);
	color: #ffffff;
}

.itsa-chatbot-actions-panel {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5em;
	margin-top: 0.65em;
	max-height: 9.75em;
	overflow-y: auto;
	padding-right: 0.15em;
	scrollbar-color: rgba(0, 212, 255, 0.5) rgba(255, 255, 255, 0.08);
}

.itsa-chatbot-actions-panel[hidden] {
	display: none;
}

.itsa-chatbot-action,
.itsa-chatbot-contact {
	background: rgba(255, 255, 255, 0.07);
	border: solid 1px rgba(255, 255, 255, 0.12);
	border-radius: 999px;
	color: rgba(255, 255, 255, 0.88);
	cursor: pointer;
	font-size: 0.78em;
	line-height: 1.2;
	padding: 0.68em 0.85em;
	text-decoration: none;
	transition: background-color 180ms ease, border-color 180ms ease, color 180ms ease, transform 180ms ease;
}

.itsa-chatbot-action:hover,
.itsa-chatbot-contact:hover {
	background: rgba(0, 212, 255, 0.15);
	border-color: rgba(0, 212, 255, 0.44);
	color: #ffffff !important;
	transform: translateY(-1px);
}

.itsa-chatbot-actions-toggle:focus-visible,
.itsa-chatbot-action:focus-visible,
.itsa-chatbot-contact:focus-visible {
	outline: solid 2px #f1cf72;
	outline-offset: 3px;
}

.itsa-chatbot-contact {
	border-color: rgba(241, 207, 114, 0.36);
	color: #f1cf72;
}

.itsa-chatbot-form {
	align-items: center;
	border-top: solid 1px rgba(255, 255, 255, 0.09);
	display: flex;
	gap: 0.6em;
	padding: 0.85em;
}

.itsa-chatbot-input {
	background: rgba(255, 255, 255, 0.08) !important;
	border: solid 1px rgba(255, 255, 255, 0.13) !important;
	border-radius: 999px !important;
	color: #ffffff !important;
	flex: 1;
	font-size: 0.92em;
	height: 3em !important;
	min-width: 0;
	padding: 0 1em !important;
}

.itsa-chatbot-input::placeholder {
	color: rgba(255, 255, 255, 0.48);
}

.itsa-chatbot-send {
	align-items: center;
	background: linear-gradient(135deg, #f1cf72, #d6a94a);
	border: 0;
	border-radius: 999px;
	color: #171820;
	cursor: pointer;
	display: inline-flex;
	flex: 0 0 auto;
	font-size: 0.9em;
	font-weight: 800;
	height: 3em;
	justify-content: center;
	padding: 0 1em;
	transition: transform 180ms ease, filter 180ms ease;
}

.itsa-chatbot-send:hover {
	filter: brightness(1.05);
	transform: translateY(-1px);
}

@keyframes itsa-chatbot-pulse {
	0% {
		opacity: 0.65;
		transform: scale(0.98);
	}

	70% {
		opacity: 0;
		transform: scale(1.22);
	}

	100% {
		opacity: 0;
		transform: scale(1.22);
	}
}

@media screen and (max-width: 736px) {
	.itsa-chatbot {
		bottom: 96px;
		right: 16px;
	}

	.itsa-chatbot-toggle {
		height: 62px;
		min-height: 62px;
		width: 62px;
	}

	.itsa-chatbot-window {
		bottom: 140px;
		max-height: calc(100dvh - 158px);
		right: 16px;
		width: calc(100vw - 32px);
	}
}
