/* HighPony Chat — liquid glass, same design language as the cart drawer and
   age gate: dark glass gradient, pink→violet accent, 20px-class radii. */

#hp-chat-root {
	position: fixed;
	right: 18px;
	bottom: 18px;
	z-index: 99990; /* above content, under Complianz (99999), FiboSearch (100000), the cart drawer (999990) and the age gate */
	font-size: 15px;
}

.hp-chat-bubble {
	width: 62px;
	height: 62px;
	border-radius: 50%;
	border: none;
	cursor: pointer;
	color: #fff;
	background: linear-gradient(135deg, #ff7ad9, #8b5cf6);
	box-shadow: 0 12px 30px rgba(139, 92, 246, 0.45);
	display: flex;
	align-items: center;
	justify-content: center;
	transition: transform 0.18s ease, filter 0.18s ease;
}
.hp-chat-bubble:hover {
	transform: translateY(-2px);
	filter: brightness(1.08);
}
.hp-chat-open .hp-chat-bubble {
	display: none;
}

.hp-chat-panel {
	display: none;
	position: fixed;
	right: 18px;
	bottom: 18px;
	width: min(372px, calc(100vw - 24px));
	height: min(560px, calc(100dvh - 40px));
	flex-direction: column;
	border-radius: 22px;
	background: linear-gradient(160deg, rgba(30, 25, 60, 0.86), rgba(15, 12, 35, 0.92));
	backdrop-filter: blur(26px) saturate(1.5);
	-webkit-backdrop-filter: blur(26px) saturate(1.5);
	border: 1px solid rgba(255, 255, 255, 0.22);
	box-shadow: 0 24px 70px rgba(0, 0, 0, 0.5);
	color: #fff;
	overflow: hidden;
}
.hp-chat-open .hp-chat-panel {
	display: flex;
}
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
	.hp-chat-panel {
		background: linear-gradient(160deg, rgba(30, 25, 60, 0.97), rgba(15, 12, 35, 0.98));
	}
}

.hp-chat-head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 14px 16px 10px;
	border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}
.hp-chat-ident {
	display: flex;
	align-items: center;
	gap: 10px;
	min-width: 0;
}
.hp-chat-title {
	font-weight: 700;
	font-size: 1.02em;
}
.hp-chat-avatar {
	width: 34px;
	height: 34px;
	border-radius: 50%;
	object-fit: cover;
	flex: 0 0 auto;
	border: 1px solid rgba(255, 255, 255, 0.35);
	background: rgba(255, 255, 255, 0.08);
}
.hp-chat-intro {
	display: flex;
	justify-content: center;
	padding: 6px 0 2px;
}
.hp-chat-avatar-intro {
	width: 84px;
	height: 84px;
	border-radius: 50%;
	object-fit: cover;
	border: 2px solid rgba(255, 255, 255, 0.35);
	box-shadow: 0 8px 22px rgba(0, 0, 0, 0.35);
	background: rgba(255, 255, 255, 0.08);
}
.hp-chat-close {
	background: rgba(255, 255, 255, 0.1);
	border: 1px solid rgba(255, 255, 255, 0.22);
	color: #fff;
	border-radius: 99px;
	width: 30px;
	height: 30px;
	padding: 0;
	font-size: 17px;
	line-height: 1;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
}

.hp-chat-body {
	flex: 1;
	overflow-y: auto;
	padding: 14px;
	display: flex;
	flex-direction: column;
	gap: 8px;
}
.hp-chat-msg p {
	margin: 0;
	padding: 9px 13px;
	border-radius: 15px;
	max-width: 85%;
	line-height: 1.4;
	font-size: 0.93em;
	white-space: pre-wrap;
	overflow-wrap: anywhere;
	display: inline-block;
}
.hp-chat-msg-assistant p {
	background: rgba(255, 255, 255, 0.09);
	border: 1px solid rgba(255, 255, 255, 0.12);
	border-bottom-left-radius: 5px;
}
.hp-chat-msg-user {
	text-align: right;
}
.hp-chat-msg-user p {
	background: linear-gradient(135deg, rgba(255, 122, 217, 0.85), rgba(139, 92, 246, 0.85));
	border-bottom-right-radius: 5px;
	text-align: left;
}
.hp-chat-typing p {
	color: rgba(255, 255, 255, 0.6);
	letter-spacing: 2px;
}

.hp-chat-products {
	display: flex;
	flex-direction: column;
	gap: 6px;
}
.hp-chat-product {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 8px 10px;
	border-radius: 13px;
	background: rgba(255, 255, 255, 0.06);
	border: 1px solid rgba(255, 122, 217, 0.35);
	color: #fff;
	text-decoration: none;
	transition: background 0.15s ease;
}
.hp-chat-product:hover {
	background: rgba(255, 122, 217, 0.14);
}
.hp-chat-product img {
	width: 42px;
	height: 42px;
	object-fit: cover;
	border-radius: 9px;
	flex: none;
}
.hp-chat-product-meta {
	display: flex;
	flex-direction: column;
	min-width: 0;
}
.hp-chat-product-name {
	font-size: 0.85em;
	line-height: 1.25;
	overflow: hidden;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
}
.hp-chat-product-price {
	font-size: 0.83em;
	font-weight: 700;
	color: #f599ff;
}

.hp-chat-note {
	padding: 4px 16px;
	font-size: 0.68em;
	color: rgba(255, 255, 255, 0.45);
	text-align: center;
}
.hp-chat-form {
	display: flex;
	gap: 8px;
	padding: 8px 12px 12px;
}
.hp-chat-input {
	flex: 1;
	background: rgba(255, 255, 255, 0.08);
	border: 1px solid rgba(255, 255, 255, 0.22);
	border-radius: 13px;
	color: #fff;
	padding: 10px 13px;
	font-size: 16px; /* below 16px iOS Safari zooms the page on focus */
	outline: none;
}
.hp-chat-input:focus {
	border-color: #ff7ad9;
}
.hp-chat-input::placeholder {
	color: rgba(255, 255, 255, 0.4);
}
.hp-chat-send {
	width: 42px;
	border: none;
	border-radius: 13px;
	background: linear-gradient(135deg, #ff7ad9, #8b5cf6);
	color: #fff;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: filter 0.15s ease;
}
.hp-chat-send:hover {
	filter: brightness(1.08);
}

@media (max-width: 480px) {
	.hp-chat-panel {
		right: 0;
		bottom: 0;
		width: 100vw;
		height: min(72dvh, 560px);
		border-radius: 20px 20px 0 0;
	}
}
@media (prefers-reduced-motion: reduce) {
	.hp-chat-bubble {
		transition: none;
	}
}

/* Teaser: a small card above the bubble with two ready questions. */
.hp-chat-teaser {
	position: fixed;
	right: 18px;
	bottom: 92px;
	width: min(268px, calc(100vw - 36px));
	padding: 13px 14px 12px;
	border-radius: 18px;
	background: linear-gradient(160deg, rgba(30, 25, 60, 0.94), rgba(15, 12, 35, 0.96));
	backdrop-filter: blur(20px) saturate(1.4);
	-webkit-backdrop-filter: blur(20px) saturate(1.4);
	border: 1px solid rgba(255, 255, 255, 0.22);
	box-shadow: 0 18px 44px rgba(0, 0, 0, 0.42);
	color: #fff;
	animation: hp-chat-teaser-in 0.32s ease both;
}
@keyframes hp-chat-teaser-in {
	from { opacity: 0; transform: translateY(8px) scale(0.97); }
	to   { opacity: 1; transform: none; }
}
@media (prefers-reduced-motion: reduce) {
	.hp-chat-teaser { animation: none; }
}
.hp-chat-open .hp-chat-teaser { display: none; }
.hp-chat-teaser-text {
	margin: 0 18px 9px 0;
	font-size: 0.92em;
	line-height: 1.35;
}
.hp-chat-teaser-x {
	position: absolute;
	top: 7px;
	right: 9px;
	width: 22px;
	height: 22px;
	padding: 0;
	border: none;
	border-radius: 99px;
	background: rgba(255, 255, 255, 0.12);
	color: #fff;
	font-size: 15px;
	line-height: 1;
	cursor: pointer;
}
.hp-chat-chip {
	display: block;
	width: 100%;
	margin-top: 6px;
	padding: 8px 11px;
	border-radius: 12px;
	border: 1px solid rgba(255, 255, 255, 0.26);
	background: rgba(255, 255, 255, 0.09);
	color: #fff;
	font: inherit;
	font-size: 0.87em;
	text-align: left;
	cursor: pointer;
	transition: background 0.15s ease;
}
.hp-chat-chip:hover { background: rgba(255, 255, 255, 0.18); }

/* Opening options inside the panel. Right-aligned and outlined rather than
   filled: they sit on the visitor's side because clicking one speaks AS them,
   but they must not read as messages already sent — the filled gradient is
   reserved for that. */
.hp-chat-starters {
	display: flex;
	flex-direction: column;
	align-items: flex-end;
	gap: 6px;
	margin-top: 10px;
}
/* Scoped to the wrapper on purpose. The theme reset carries
   `[type="button"] { color: #c36 }` — an attribute selector has the SAME
   specificity as a single class, so it wins on load order, and these buttons
   set type="button". Two classes settle it. */
.hp-chat-starters .hp-chat-starter {
	max-width: 85%;
	padding: 8px 13px;
	border-radius: 15px;
	border-bottom-right-radius: 5px;
	border: 1px solid rgba(255, 122, 217, 0.55);
	background: rgba(255, 122, 217, 0.12);
	color: #fff;
	font: inherit;
	font-size: 0.9em;
	line-height: 1.35;
	text-align: left;
	cursor: pointer;
	transition: background 0.15s ease, border-color 0.15s ease, transform 0.14s ease;
}
.hp-chat-starters .hp-chat-starter:hover {
	background: rgba(255, 122, 217, 0.24);
	border-color: rgba(255, 122, 217, 0.8);
}
.hp-chat-starters .hp-chat-starter:active {
	transform: scale(0.97);
	transition: none;   /* press feedback is immediate */
}
.hp-chat-starters .hp-chat-starter:focus-visible {
	outline: 2px solid rgba(255, 122, 217, 0.9);
	outline-offset: 2px;
}
@media (prefers-reduced-motion: reduce) {
	.hp-chat-starters .hp-chat-starter { transition: none; }
}

/* Category chips — "browse the whole aisle", shown above the product cards.
   Deliberately lighter than a product card: a pill, not a tile, so three of
   them never compete with the real recommendations. */
.hp-chat-cats {
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
	margin: 8px 0 0;
}
.hp-chat-cat {
	display: inline-flex;
	align-items: center;
	gap: 7px;
	padding: 5px 11px 5px 5px;
	border-radius: 999px;
	background: rgba(255, 255, 255, 0.05);
	border: 1px solid rgba(255, 194, 0, 0.45);
	color: #fff;
	text-decoration: none;
	font-size: 13px;
	line-height: 1.3;
	transition: background 0.15s ease;
}
.hp-chat-cat:hover,
.hp-chat-cat:focus-visible {
	background: rgba(255, 194, 0, 0.16);
}
.hp-chat-cat img {
	width: 22px;
	height: 22px;
	border-radius: 999px;
	object-fit: cover;
	flex: 0 0 auto;
}
.hp-chat-cat-name {
	font-weight: 600;
}
.hp-chat-cat-count {
	opacity: 0.65;
	font-size: 11px;
}
