.storaby-chatbot {
	--sc-orange: #ea7a1e;
	--sc-navy: #191a2e;
	--sc-cream: #fdf5f0;
	--sc-gray: #79797c;
	--sc-white: #ffffff;
	--sc-shadow: 0 7.73px 30.921px rgba(0, 0, 0, 0.05);
	--sc-input-border: rgba(234, 122, 30, 0.3);

	position: fixed;
	right: max(24px, env(safe-area-inset-right));
	bottom: max(24px, env(safe-area-inset-bottom));
	z-index: 99990;
	display: flex;
	flex-direction: column;
	align-items: flex-end;
	gap: 14px;
	font-family: 'Poppins', sans-serif;
	pointer-events: none;
}

.storaby-chatbot .screen-reader-text {
	border: 0;
	clip: rect(1px, 1px, 1px, 1px);
	clip-path: inset(50%);
	height: 1px;
	margin: -1px;
	overflow: hidden;
	padding: 0;
	position: absolute;
	width: 1px;
	word-wrap: normal !important;
}

.storaby-chatbot[hidden] {
	display: none !important;
}

.storaby-chatbot * {
	box-sizing: border-box;
}

.storaby-chatbot__panel,
.storaby-chatbot__fab {
	pointer-events: auto;
}

.storaby-chatbot button,
.storaby-chatbot button:hover,
.storaby-chatbot button:focus,
.storaby-chatbot button:focus-visible,
.storaby-chatbot button:active {
	background-image: none !important;
	text-decoration: none !important;
	box-shadow: none !important;
}

.storaby-chatbot a,
.storaby-chatbot a:hover,
.storaby-chatbot a:focus,
.storaby-chatbot a:active {
	text-decoration: none !important;
	box-shadow: none !important;
}

.storaby-chatbot__panel {
	position: relative;
	width: min(400px, calc(100vw - 32px));
	height: min(588px, calc(100vh - 120px));
	background: var(--sc-white);
	border: 1px solid var(--sc-orange);
	border-radius: 20px;
	box-shadow: var(--sc-shadow);
	overflow: hidden;
	display: flex;
	flex-direction: column;
	opacity: 0;
	transform: translateY(12px) scale(0.98);
	transform-origin: bottom right;
	transition: opacity 0.22s ease, transform 0.22s ease;
	pointer-events: none;
}

.storaby-chatbot.is-open .storaby-chatbot__panel {
	opacity: 1;
	transform: translateY(0) scale(1);
	pointer-events: auto;
}

.storaby-chatbot__panel[hidden] {
	display: none !important;
}

.storaby-chatbot.is-open .storaby-chatbot__panel[hidden] {
	display: flex !important;
}

.storaby-chatbot__header {
	position: relative;
	flex: 0 0 88px;
	height: 88px;
	overflow: hidden;
}

.storaby-chatbot__header-wave {
	position: absolute;
	left: 50%;
	top: 0;
	transform: translateX(-50%);
	width: 120%;
	max-width: none;
	height: 88px;
	object-fit: fill;
	pointer-events: none;
	user-select: none;
}

.storaby-chatbot__brand {
	position: relative;
	z-index: 1;
	display: flex;
	align-items: center;
	gap: 11px;
	height: 100%;
	padding: 0 28px;
}

.storaby-chatbot__status {
	position: relative;
	flex: 0 0 10px;
	width: 10px;
	height: 10px;
	border-radius: 50%;
	background: var(--sc-orange);
	box-shadow: 0 0 0 6px rgba(234, 122, 30, 0.18), 0 0 18px rgba(234, 122, 30, 0.55);
}

.storaby-chatbot__brand-text {
	min-width: 0;
}

.storaby-chatbot__title {
	margin: 0;
	font-size: 20px;
	line-height: 1.2;
	font-weight: 700;
	color: var(--sc-navy);
	white-space: nowrap;
}

.storaby-chatbot__title-accent {
	font-weight: 600;
	font-style: italic;
	color: var(--sc-orange);
}

.storaby-chatbot__subtitle {
	margin: 1px 0 0;
	font-size: 12px;
	font-weight: 400;
	line-height: 1.3;
	color: var(--sc-navy);
}

.storaby-chatbot__body {
	flex: 1 1 auto;
	display: flex;
	flex-direction: column;
	min-height: 0;
	padding: 12px 20px 20px;
}

.storaby-chatbot__messages {
	flex: 1 1 auto;
	overflow-y: auto;
	display: flex;
	flex-direction: column;
	gap: 14px;
	padding: 8px 0 16px;
	scrollbar-width: thin;
	scrollbar-color: rgba(234, 122, 30, 0.35) transparent;
}

.storaby-chatbot__bubble {
	max-width: 86%;
	padding: 10px 16px;
	border-radius: 24px;
	font-size: 12px;
	font-weight: 400;
	line-height: 1.45;
	word-wrap: break-word;
	overflow-wrap: anywhere;
}

.storaby-chatbot__bubble--bot {
	align-self: flex-start;
	background: var(--sc-navy);
	color: var(--sc-white);
	border-radius: 24px 24px 24px 0;
}

.storaby-chatbot__bubble--user {
	align-self: flex-end;
	background: var(--sc-cream);
	color: var(--sc-navy);
	border-radius: 24px 24px 0 24px;
}

.storaby-chatbot__bubble--error {
	align-self: flex-start;
	background: #f8e8e8;
	color: #8a2a2a;
	border-radius: 24px 24px 24px 0;
}

.storaby-chatbot__bubble p {
	margin: 0 0 0.55em;
}

.storaby-chatbot__bubble p:last-child {
	margin-bottom: 0;
}

.storaby-chatbot__bubble strong {
	font-weight: 600;
}

.storaby-chatbot__bubble ul,
.storaby-chatbot__bubble ol {
	margin: 0.4em 0 0.55em;
	padding-left: 1.2em;
}

.storaby-chatbot__bubble li {
	margin: 0.2em 0;
}

.storaby-chatbot__bubble a {
	color: inherit !important;
	text-decoration: underline !important;
}

.storaby-chatbot__bubble--bot a,
.storaby-chatbot__bubble--bot a:hover {
	color: #ffd7b0 !important;
}

.storaby-chatbot__typing {
	display: inline-flex;
	gap: 4px;
	align-items: center;
	padding: 4px 2px;
}

.storaby-chatbot__typing span {
	width: 6px;
	height: 6px;
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.75);
	animation: storaby-chatbot-dot 1s infinite ease-in-out;
}

.storaby-chatbot__typing span:nth-child(2) {
	animation-delay: 0.15s;
}

.storaby-chatbot__typing span:nth-child(3) {
	animation-delay: 0.3s;
}

@keyframes storaby-chatbot-dot {
	0%,
	80%,
	100% {
		opacity: 0.35;
		transform: translateY(0);
	}
	40% {
		opacity: 1;
		transform: translateY(-2px);
	}
}

.storaby-chatbot__composer {
	flex: 0 0 auto;
	display: flex;
	flex-direction: column;
	gap: 10px;
}

.storaby-chatbot__suggestions {
	display: flex;
	flex-wrap: wrap;
	gap: 7px;
	align-items: center;
}

.storaby-chatbot__suggestions[hidden] {
	display: none !important;
}

.storaby-chatbot__chip,
.storaby-chatbot__chip:hover,
.storaby-chatbot__chip:focus,
.storaby-chatbot__chip:focus-visible,
.storaby-chatbot__chip:active {
	appearance: none;
	-webkit-appearance: none;
	border: 0 !important;
	cursor: pointer;
	background: rgba(234, 122, 30, 0.1) !important;
	background-color: rgba(234, 122, 30, 0.1) !important;
	color: var(--sc-orange) !important;
	font-family: inherit;
	font-size: 12px;
	font-weight: 500;
	line-height: 1;
	padding: 12px 10px !important;
	border-radius: 50px !important;
	box-shadow: none !important;
	outline: none !important;
	transition: background 0.15s ease;
}

.storaby-chatbot__chip:hover,
.storaby-chatbot__chip:focus-visible {
	background: rgba(234, 122, 30, 0.18) !important;
	background-color: rgba(234, 122, 30, 0.18) !important;
	color: var(--sc-orange) !important;
}

.storaby-chatbot__chip:disabled {
	opacity: 0.55;
	cursor: not-allowed;
}

.storaby-chatbot__form {
	display: flex;
	align-items: center;
	gap: 9.178px;
	width: 100%;
}

.storaby-chatbot__input,
.storaby-chatbot__input:hover,
.storaby-chatbot__input:focus,
.storaby-chatbot__input:focus-visible,
.storaby-chatbot__input:active {
	flex: 1 1 auto;
	min-width: 0;
	width: 100%;
	height: 49px !important;
	min-height: 49px !important;
	max-height: 49px !important;
	padding: 16px !important;
	margin: 0 !important;
	border: 1px solid var(--sc-input-border) !important;
	border-radius: 50px !important;
	background: var(--sc-white) !important;
	background-color: var(--sc-white) !important;
	font-family: 'Poppins', sans-serif !important;
	font-size: 12px !important;
	font-weight: 400 !important;
	line-height: normal !important;
	color: var(--sc-navy) !important;
	outline: none !important;
	box-shadow: none !important;
	-webkit-appearance: none !important;
	appearance: none !important;
	caret-color: var(--sc-orange);
}

.storaby-chatbot__input::placeholder {
	color: var(--sc-gray) !important;
	opacity: 1;
}

.storaby-chatbot__input:focus,
.storaby-chatbot__input:focus-visible {
	border-color: var(--sc-orange) !important;
	box-shadow: none !important;
}

.storaby-chatbot__send,
.storaby-chatbot__send:hover,
.storaby-chatbot__send:focus,
.storaby-chatbot__send:focus-visible,
.storaby-chatbot__send:active {
	appearance: none;
	-webkit-appearance: none;
	border: 0 !important;
	padding: 0 !important;
	margin: 0 !important;
	background: transparent !important;
	background-color: transparent !important;
	color: inherit !important;
	cursor: pointer;
	flex: 0 0 50px;
	width: 50px;
	height: 50px;
	border-radius: 50%;
	line-height: 0;
	box-shadow: none !important;
	outline: none !important;
	transition: transform 0.15s ease, opacity 0.15s ease;
}

.storaby-chatbot__send img {
	display: block;
	width: 50px;
	height: 50px;
	
	transform: rotate(180deg) scaleY(-1);
	pointer-events: none;
}

.storaby-chatbot__send:hover:not(:disabled) {
	transform: scale(1.04);
}

.storaby-chatbot__send:disabled {
	opacity: 0.4;
	cursor: not-allowed;
	transform: none !important;
}

.storaby-chatbot__fab,
.storaby-chatbot__fab:hover,
.storaby-chatbot__fab:focus,
.storaby-chatbot__fab:focus-visible,
.storaby-chatbot__fab:active {
	appearance: none;
	-webkit-appearance: none;
	border: 0 !important;
	padding: 0 !important;
	margin: 0 !important;
	background: transparent !important;
	background-color: transparent !important;
	color: inherit !important;
	cursor: pointer;
	width: 75px;
	height: 68px;
	line-height: 0;
	box-shadow: none !important;
	outline: none !important;
	filter: drop-shadow(0 6px 16px rgba(234, 122, 30, 0.28));
	transition: transform 0.18s ease;
}

.storaby-chatbot__fab:hover {
	transform: translateY(-2px) scale(1.03);
}

.storaby-chatbot__fab-icon {
	display: block;
	width: 75px;
	height: 68px;
}

.storaby-chatbot__fab-icon[hidden] {
	display: none !important;
}

@media (max-width: 767px) {
	.storaby-chatbot__fab,
	.storaby-chatbot__fab:hover,
	.storaby-chatbot__fab:focus,
	.storaby-chatbot__fab:focus-visible,
	.storaby-chatbot__fab:active {
		width: 56px;
		height: 51px;
	}

	.storaby-chatbot__fab-icon {
		width: 56px;
		height: 51px;
	}
}

@media (max-width: 480px) {
	.storaby-chatbot {
		right: max(12px, env(safe-area-inset-right));
		bottom: max(12px, env(safe-area-inset-bottom));
		left: max(12px, env(safe-area-inset-left));
		align-items: stretch;
	}

	.storaby-chatbot__fab {
		align-self: flex-end;
	}

	.storaby-chatbot__panel {
		width: 100%;
		height: min(588px, calc(100vh - 100px - env(safe-area-inset-bottom, 0px)));
	}

	.storaby-chatbot__brand {
		padding: 0 18px;
	}

	.storaby-chatbot__body {
		padding: 10px 14px 16px;
	}
}

@media (prefers-reduced-motion: reduce) {
	.storaby-chatbot__panel,
	.storaby-chatbot__fab,
	.storaby-chatbot__send,
	.storaby-chatbot__chip,
	.storaby-chatbot__typing span {
		transition: none !important;
		animation: none !important;
	}

	.storaby-chatbot.is-open .storaby-chatbot__panel {
		transform: none;
	}
}

@media print {
	.storaby-chatbot {
		display: none !important;
	}
}
