:root {
	--gcw-tint: rgba(22, 26, 40, 0.6);
	--gcw-tint-strong: rgba(22, 26, 40, 0.55);
	--gcw-highlight: rgba(255, 255, 255, 0.16);
	--gcw-border: rgba(255, 255, 255, 0.28);
	--gcw-shadow: 0 24px 60px rgba(0, 0, 0, 0.38), inset 0 1px 0 rgba(255, 255, 255, 0.35);

	--gcw-ink: #f5f6f8;
	--gcw-ink-soft: rgba(245, 246, 248, 0.68);
	--gcw-accent: #f5f6f8;
	--gcw-accent-soft: rgba(79, 168, 255, 0.18);
	--gcw-bubble-user: linear-gradient(135deg, #3a8dff, #63c7ff);
	--gcw-bubble-bot: rgba(255, 255, 255, 0.12);
	--gcw-bubble-bot-border: rgba(255, 255, 255, 0.22);
}
.gcw-fab {
	position: fixed;
	bottom: 28px;
	right: 28px;
	width: 65px;
	height: 65px;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	background: linear-gradient(160deg, var(--gcw-highlight), transparent 45%), var(--gcw-tint-strong);
	backdrop-filter: blur(24px) saturate(180%);
	-webkit-backdrop-filter: blur(24px) saturate(180%);
	border: 1px solid var(--gcw-border);
	box-shadow: var(--gcw-shadow);
	color: var(--gcw-accent);
	font-size: 1.35rem;
	cursor: pointer;
	z-index: 3147483640;
	transition:
		transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1),
		box-shadow 0.25s ease,
		opacity 0.2s ease;
}
.gcw-fab:hover {
	transform: translateY(-3px) scale(1.05);
	box-shadow:
		0 12px 36px rgba(0, 0, 0, 0.45),
		inset 0 1px 0 rgba(255, 255, 255, 0.4);
}
.gcw-fab:active {
	transform: scale(0.96);
}
.gcw-fab .fa-xmark {
	display: none;
}
.gcw-fab.gcw-open .fa-magnifying-glass {
	display: none;
}
.gcw-fab.gcw-open .fa-sparkles {
	display: none;
}
.gcw-fab.gcw-open .fa-xmark {
	display: inline-block;
}

.gcw-fab-pulse {
	position: absolute;
	inset: 0;
	border-radius: 50%;
	box-shadow: 0 0 0 0 rgba(79, 168, 255, 0.45);
	animation: gcw-pulse 2.6s infinite;
	pointer-events: none;
}
@keyframes gcw-pulse {
	0% {
		box-shadow: 0 0 0 0 rgba(79, 168, 255, 0.35);
	}
	70% {
		box-shadow: 0 0 0 14px rgba(79, 168, 255, 0);
	}
	100% {
		box-shadow: 0 0 0 0 rgba(79, 168, 255, 0);
	}
}

/* ---------- Chat panel ---------- */
.gcw-panel {
	position: fixed;
	bottom: 105px;
	right: 28px;
	width: 690px;
	max-width: calc(100vw - 32px);
	height: 720px;
	max-height: calc(100vh - 100px);
	border-radius: 30px;
	background: linear-gradient(165deg, var(--gcw-highlight) 0%, transparent 35%), var(--gcw-tint);
	backdrop-filter: blur(36px) saturate(180%);
	-webkit-backdrop-filter: blur(36px) saturate(180%);
	border: 1px solid var(--gcw-border);
	box-shadow: var(--gcw-shadow);
	display: flex;
	flex-direction: column;
	overflow: hidden;
	z-index: 3147483640;
	transform-origin: bottom right;
	transform: scale(0.4) translateY(20px);
	opacity: 0;
	pointer-events: none;
	transition:
		transform 0.32s cubic-bezier(0.34, 1.4, 0.4, 1),
		opacity 0.24s ease;
}
.gcw-panel.gcw-open {
	transform: scale(1) translateY(0);
	opacity: 1;
	pointer-events: auto;
}
/* thin specular line along the very top edge, like a light catching glass */
.gcw-panel::before {
	content: '';
	position: absolute;
	top: 0;
	left: 14%;
	right: 14%;
	height: 1px;
	background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.9), transparent);
}

.gcw-header {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 18px 18px 16px;
	border-bottom: 1px solid rgba(255, 255, 255, 0.14);
}
.gcw-avatar {
	width: 36px;
	height: 36px;
	border-radius: 50%;
	background: linear-gradient(135deg, rgba(0, 55, 104, 1), 80%, rgba(255, 255, 255, 0.05));
	display: flex;
	align-items: center;
	justify-content: center;
	color: #fff;
	font-size: 1rem;
	box-shadow: 0 2px 10px rgba(79, 168, 255, 0.45);
}
.gcw-title {
	font-weight: 600;
	color: var(--gcw-ink);
	font-size: 0.98rem;
	line-height: 1.1;
}
.gcw-status {
	font-size: 0.76rem;
	color: #4ee08a;
	display: flex;
	align-items: center;
	gap: 5px;
}
.gcw-status .gcw-dot {
	width: 6px;
	height: 6px;
	border-radius: 50%;
	background: #4ee08a;
	box-shadow: 0 0 0 2px rgba(78, 224, 138, 0.25);
}
.gcw-close-btn {
	margin-left: auto;
	border: none;
	background: rgba(255, 255, 255, 0.1);
	width: 30px;
	height: 30px;
	border-radius: 50%;
	color: var(--gcw-ink-soft);
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 0.85rem;
	border: 1px solid rgba(255, 255, 255, 0.16);
	transition: background 0.2s ease;
}
.gcw-close-btn:hover {
	background: rgba(255, 255, 255, 0.2);
	color: var(--gcw-ink);
}

.gcw-body {
	flex: 1;
	overflow-y: auto;
	padding: 16px 16px 8px;
	display: flex;
	flex-direction: column;
	gap: 10px;
}
.gcw-body::-webkit-scrollbar {
	width: 6px;
}
.gcw-body::-webkit-scrollbar-thumb {
	background: rgba(255, 255, 255, 0.18);
	border-radius: 10px;
}

.gcw-greeting {
	max-width: 82%;
	padding: 10px 14px;
	border-radius: 18px;
	font-size: 0.88rem;
	line-height: 1.4;
	animation: gcw-rise 0.28s ease;
}
@keyframes gcw-rise {
	from {
		opacity: 0;
		transform: translateY(8px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

.gcw-greeting {
	align-self: flex-start;
	background: var(--gcw-bubble-bot);
	color: var(--gcw-ink);
	border-bottom-left-radius: 6px;
	box-shadow: 0 2px 10px rgba(0, 0, 0, 0.15);
	border: 1px solid var(--gcw-bubble-bot-border);
	backdrop-filter: blur(6px);
}
.gcw-msg.gcw-user {
	align-self: flex-end;
	background: var(--gcw-bubble-user);
	color: #0a1a2e;
	border-bottom-right-radius: 6px;
	box-shadow: 0 4px 14px rgba(58, 141, 255, 0.4);
	font-weight: 500;
}

.gcw-typing {
	align-self: flex-start;
	display: flex;
	gap: 4px;
	align-items: center;
	background: var(--gcw-bubble-bot);
	border: 1px solid var(--gcw-bubble-bot-border);
	padding: 12px 14px;
	border-radius: 18px;
	border-bottom-left-radius: 6px;
}
.gcw-typing span {
	width: 6px;
	height: 6px;
	border-radius: 50%;
	background: var(--gcw-ink-soft);
	animation: gcw-blink 1.2s infinite ease-in-out;
}
.gcw-typing span:nth-child(2) {
	animation-delay: 0.18s;
}
.gcw-typing span:nth-child(3) {
	animation-delay: 0.36s;
}
@keyframes gcw-blink {
	0%,
	80%,
	100% {
		opacity: 0.25;
		transform: scale(0.85);
	}
	40% {
		opacity: 1;
		transform: scale(1);
	}
}

.gcw-seeds {
	padding: 4px 16px 12px;
	display: flex;
	flex-direction: column;
	gap: 8px;
}
.gcw-chip {
	display: flex;
	align-items: center;
	gap: 9px;
	width: 100%;
	text-align: left;
	border: 1px solid rgba(255, 255, 255, 0.22);
	background: rgba(255, 255, 255, 0.08);
	color: var(--gcw-ink);
	font-size: 0.78rem;
	line-height: 1.35;
	padding: 9px 12px;
	border-radius: 14px;
	cursor: pointer;
	transition:
		background 0.18s ease,
		transform 0.15s ease,
		box-shadow 0.18s ease;
	white-space: normal;
}
.gcw-chip:hover {
	background: rgba(255, 255, 255, 0.18);
	border-color: rgba(255, 255, 255, 0.4);
	transform: translateY(-1px);
	box-shadow: 0 4px 10px rgba(0, 0, 0, 0.25);
}
.gcw-chip i {
	margin-right: 2px;
	color: var(--gcw-accent);
	font-size: 0.72rem;
}

.gcw-footer {
	padding: 12px 14px 16px;
	border-top: 1px solid rgba(255, 255, 255, 0.14);
}
.gcw-input-group {
	display: flex;
	align-items: center;
	gap: 8px;
	background: rgba(255, 255, 255, 0.08);
	border: 1px solid rgba(255, 255, 255, 0.24);
	border-radius: 999px;
	padding: 6px 6px 6px 16px;
	transition:
		box-shadow 0.2s ease,
		border-color 0.2s ease,
		background 0.2s ease;
}
.gcw-input-group:focus-within {
	border-color: rgba(79, 168, 255, 0.6);
	background: rgba(255, 255, 255, 0.12);
	box-shadow: 0 0 0 3px rgba(79, 168, 255, 0.18);
}
.gcw-input-group .addsearch-searchfield input[type='search'] {
	border: none !important;
	background: transparent;
	outline: none;
	min-width: unset;
	max-width: unset;
	flex: 1;
	font-size: 0.88rem;
	color: var(--gcw-ink);
}

.gcw-input-group .addsearch-searchfield {
	min-width: 100%;
}

.gcw-input-group input::placeholder {
	color: rgba(245, 246, 248, 0.5);
}
.gcw-input-group .addsearch-searchfield-container button {
	width: 34px;
	height: 34px;
	border-radius: 50%;
	border: none;
	background: linear-gradient(135deg, #3a8dff, #63c7ff);
	color: #fff;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 0.85rem;
	flex-shrink: 0;
	transition:
		transform 0.15s ease,
		opacity 0.15s ease;
}
.gcw-input-group .addsearch-searchfield-container button:disabled {
	opacity: 0.35;
}
.gcw-input-group .addsearch-searchfield-container button:not(:disabled):hover {
	transform: scale(1.08);
}
.gcw-input-group .addsearch-searchfield-container button:not(:disabled):active {
	transform: scale(0.94);
}

#gcwInput .addsearch-searchfield input[type='search'].icon {
	background-image: none;
	padding-left: 0px !important;
}

.gcw-input-group .addsearch-searchfield button::before {
	display: flex;
	justify-content: center;
	align-items: center;
	content: '\f002';
	font-family: 'Font Awesome 7 Pro';
	font-weight: 900;
	font-size: 16px;
	color: white;
}

.gcw-input-group .addsearch-searchfield button {
	position: relative;
	font-size: 0;
}

.gcw-body .addsearch-ai-answers-result .header {
	display: none;
}

#gcwBody .addsearch-ai-answers-result .loading-overlay {
	background-color: unset !important;
}

#gcwBody .addsearch-ai-answers-result {
	border: 1px solid rgba(255, 255, 255, 0.22);
	/* background: red; */
	background: rgba(255, 255, 255, 0.013);
	color: var(--gcw-ink);
	font-size: 1rem;
	padding: 7px 12px;
}

#gcwBody .addsearch-ai-answers-result .show-more-btn {
	color: var(--gcw-ink);
}

#gcwBody .addsearch-ai-answers-result .fade-out-overlay {
	display: none !important;
}

#gcwBody .copy-btn svg path,
#gcwBody .thumbs-up-btn svg path,
#gcwBody .thumbs-down-btn svg path {
	fill: var(--gcw-ink) !important;
}

#gcwBody .chevron path {
	stroke: var(--gcw-ink) !important;
}

#gcwBody .sources-list a {
	border: 1px solid rgba(255, 255, 255, 0.22);
	background: rgba(255, 255, 255, 0.08);
	color: var(--gcw-ink);
	font-size: 0.78rem;
	border-radius: 10px;
	cursor: pointer;
	transition:
		background 0.18s ease,
		transform 0.15s ease,
		box-shadow 0.18s ease;
	display: flex;
	align-items: center;
}

@media (min-width: 1920px) {
	.gcw-fab,
	.gcw-panel {
		right: calc((100vw - 1920px) / 2 + 28px);
	}
}

@media (max-width: 480px) {
	.gcw-panel {
		right: 16px;
		bottom: 16px;
		width: calc(100vw - 32px);
		height: calc(100vh - 110px);
	}
	.gcw-fab {
		right: 16px;
		bottom: 16px;
	}
}
