/* The ask-a-question dock, and the panel it opens. */

.praxia-dock {
	position: fixed;
	right: 16px;
	bottom: 16px;
	bottom: calc(16px + env(safe-area-inset-bottom, 0px));
	z-index: 60;
	display: flex;
	flex-direction: column;
	align-items: flex-end;
	gap: 10px;
}

.praxia-dock__btn {
	display: inline-flex;
	align-items: center;
	gap: 9px;
	padding: 12px 18px;
	border: 0;
	border-radius: 999px;
	font: inherit;
	font-size: 15px;
	font-weight: 600;
	line-height: 1;
	text-decoration: none;
	cursor: pointer;
	box-shadow: 0 10px 28px -12px rgba(18, 52, 59, .55);
	transition: transform .25s cubic-bezier(.2, .7, .3, 1), box-shadow .25s ease, background .25s ease;
}

.praxia-dock__btn:hover,
.praxia-dock__btn:focus-visible {
	transform: translateY(-2px);
	box-shadow: 0 16px 34px -14px rgba(18, 52, 59, .65);
}

.praxia-dock__btn--wa { background: #25D366; color: #06351B; }
.praxia-dock__btn--wa:hover { color: #06351B; }
.praxia-dock__btn--ask { background: #12343B; color: #FFFFFF; }
.praxia-dock__btn--ask:hover { color: #FFFFFF; }

.praxia-dock__icon { display: inline-flex; }

/* On a phone the labels would take half the width, so the buttons become
   round. The accessible name stays, because it is in the markup. */
@media (max-width: 600px) {
	.praxia-dock__label {
		position: absolute;
		width: 1px; height: 1px;
		overflow: hidden;
		clip: rect(1px, 1px, 1px, 1px);
		white-space: nowrap;
	}
	.praxia-dock__btn { padding: 15px; }
}

/* ------------------------------------------------------------- the panel */

.praxia-ask {
	position: fixed;
	right: 16px;
	bottom: 88px;
	bottom: calc(88px + env(safe-area-inset-bottom, 0px));
	z-index: 61;
	width: min(380px, calc(100vw - 32px));
	max-height: min(540px, calc(100vh - 140px));
	display: flex;
	flex-direction: column;
	background: #FFFFFF;
	border: 1px solid #DCE4E3;
	border-radius: 14px;
	box-shadow: 0 30px 70px -30px rgba(18, 52, 59, .6);
	overflow: hidden;
	animation: praxia-ask-in .28s cubic-bezier(.2, .7, .3, 1) both;
}

/* `display: flex` on the class beats the browser's own rule for [hidden], so
   without this the panel is open on every page from the moment it loads. The
   same mistake was in the specialty switcher; it is the one CSS trap this
   design keeps walking into, because every panel here is a flex or grid box
   that starts hidden. */
.praxia-ask[hidden] {
	display: none;
}

@keyframes praxia-ask-in {
	from { opacity: 0; transform: translateY(10px); }
	to   { opacity: 1; transform: none; }
}

.praxia-ask__head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	padding: 12px 10px 12px 16px;
	background: #12343B;
	color: #fff;
}

.praxia-ask__title { margin: 0; font-size: 15px; font-weight: 650; color: #fff; }

.praxia-ask__close {
	border: 0;
	background: transparent;
	color: #fff;
	font-size: 26px;
	line-height: 1;
	padding: 0 8px;
	cursor: pointer;
	border-radius: 6px;
}
.praxia-ask__close:hover { background: rgba(255,255,255,.12); }

.praxia-ask__log {
	flex: 1 1 auto;
	overflow-y: auto;
	padding: 14px 16px 4px;
	display: flex;
	flex-direction: column;
	gap: 10px;
	font-size: 15px;
	line-height: 1.5;
}

.praxia-ask__msg {
	max-width: 88%;
	padding: 9px 13px;
	border-radius: 12px;
	white-space: pre-wrap;
	overflow-wrap: anywhere;
}

.praxia-ask__msg--them { background: #F3F6F5; color: #12343B; align-self: flex-start; border-bottom-left-radius: 4px; }
.praxia-ask__msg--you  { background: #1B7F79; color: #FFFFFF; align-self: flex-end; border-bottom-right-radius: 4px; }
.praxia-ask__msg--wait { color: #5A6B69; font-style: italic; background: transparent; padding-left: 2px; }

.praxia-ask__note {
	margin: 0;
	padding: 8px 16px;
	font-size: 12px;
	line-height: 1.45;
	color: #5A6B69;
	border-top: 1px solid #EDF2F1;
}

.praxia-ask__form {
	display: flex;
	gap: 8px;
	padding: 10px 12px 12px;
	border-top: 1px solid #EDF2F1;
}

.praxia-ask__form input {
	flex: 1 1 auto;
	min-width: 0;
	font: inherit;
	font-size: 15px;
	padding: 10px 12px;
	border: 1px solid #DCE4E3;
	border-radius: 8px;
	background: #fff;
	color: #12343B;
}

.praxia-ask__form input:focus-visible { outline: 2px solid #1B7F79; outline-offset: 1px; }

.praxia-ask__form button {
	font: inherit;
	font-weight: 600;
	padding: 10px 16px;
	border: 0;
	border-radius: 8px;
	background: #1B7F79;
	color: #fff;
	cursor: pointer;
}

.praxia-ask__form button[disabled] { opacity: .5; cursor: default; }

@media (prefers-reduced-motion: reduce) {
	.praxia-dock__btn { transition: none; }
	.praxia-dock__btn:hover { transform: none; }
	.praxia-ask { animation: none; }
}
