@gengage/assistant-fe 0.1.1 → 0.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (48) hide show
  1. package/dist/chat/components/ChatDrawer.d.ts +5 -1
  2. package/dist/chat/components/ChatDrawer.d.ts.map +1 -1
  3. package/dist/chat/components/ProactivePopup.d.ts +7 -0
  4. package/dist/chat/components/ProactivePopup.d.ts.map +1 -1
  5. package/dist/chat/index.d.ts +6 -0
  6. package/dist/chat/index.d.ts.map +1 -1
  7. package/dist/chat/session-persistence.d.ts +7 -3
  8. package/dist/chat/session-persistence.d.ts.map +1 -1
  9. package/dist/chat/types.d.ts +6 -0
  10. package/dist/chat/types.d.ts.map +1 -1
  11. package/dist/chat.cjs +1 -1
  12. package/dist/chat.iife.js +9 -9
  13. package/dist/chat.iife.js.map +1 -1
  14. package/dist/chat.js +2 -2
  15. package/dist/common/streaming.d.ts +6 -0
  16. package/dist/common/streaming.d.ts.map +1 -1
  17. package/dist/common/v1-protocol-adapter.d.ts.map +1 -1
  18. package/dist/common/widget-base.d.ts +1 -0
  19. package/dist/common/widget-base.d.ts.map +1 -1
  20. package/dist/common.cjs +1 -1
  21. package/dist/common.js +4 -4
  22. package/dist/{index-CmlYMq-h.js → index-CXbH-cw8.js} +741 -622
  23. package/dist/index-CXbH-cw8.js.map +1 -0
  24. package/dist/index-DHfTHscz.cjs +13 -0
  25. package/dist/index-DHfTHscz.cjs.map +1 -0
  26. package/dist/index.cjs +1 -1
  27. package/dist/index.js +2 -2
  28. package/dist/qna/components/renderUISpec.d.ts.map +1 -1
  29. package/dist/qna.cjs +1 -1
  30. package/dist/qna.cjs.map +1 -1
  31. package/dist/qna.iife.js +6 -6
  32. package/dist/qna.iife.js.map +1 -1
  33. package/dist/qna.js +8 -7
  34. package/dist/qna.js.map +1 -1
  35. package/dist/{schemas-SGuXpngy.js → schemas-CPkzbgia.js} +1034 -1020
  36. package/dist/schemas-CPkzbgia.js.map +1 -0
  37. package/dist/{schemas-DbbfBnZe.cjs → schemas-tCxs1sED.cjs} +16 -16
  38. package/dist/schemas-tCxs1sED.cjs.map +1 -0
  39. package/dist/simrel.cjs +1 -1
  40. package/dist/simrel.iife.js +6 -6
  41. package/dist/simrel.iife.js.map +1 -1
  42. package/dist/simrel.js +1 -1
  43. package/package.json +3 -2
  44. package/dist/index-CmlYMq-h.js.map +0 -1
  45. package/dist/index-DK4lqi85.cjs +0 -13
  46. package/dist/index-DK4lqi85.cjs.map +0 -1
  47. package/dist/schemas-DbbfBnZe.cjs.map +0 -1
  48. package/dist/schemas-SGuXpngy.js.map +0 -1
@@ -1,12 +1,12 @@
1
- import { b as Le, c as Ne, a as Ae, A as Pe, r as Be, o as L, s as x, f as B, C as te, d as ie, u as oe, v as W, e as $, _ as me, B as Me, D as ze, j as O, t as De, i as Re, E as Ue, F as He, g as Fe, m as Oe, G as qe, H as je, I as Ve, y as Ge, x as $e, n as Ke, J as Ye, K as We, L as le, h as Qe, M as Xe, N as Je, l as Ze, O as et, P as tt, Q as at, R as nt, S as it, T as ot } from "./schemas-SGuXpngy.js";
2
- import { s as Z, i as K, c as re, d as D, a as Q, f as F, e as G, r as fe, g as be, b as xe } from "./quantity-stepper-B8kX8GbN.js";
3
- function rt() {
1
+ import { b as fe, c as Ae, a as Pe, A as Be, r as Me, o as L, s as x, f as B, C as ae, d as oe, u as re, v as Y, e as $, _ as be, B as ze, D as De, j as O, t as Re, i as Ue, E as He, F as Fe, g as Oe, m as qe, G as je, H as Ve, I as Ge, y as $e, x as Ke, n as We, J as Ye, K as Qe, L as ge, h as Xe, M as Je, N as Ze, l as et, O as tt, P as at, Q as nt, R as it, S as ot, T as rt } from "./schemas-CPkzbgia.js";
2
+ import { s as Z, i as K, c as se, d as D, a as Q, f as F, e as G, r as xe, g as ve, b as we } from "./quantity-stepper-B8kX8GbN.js";
3
+ function st() {
4
4
  const o = Date.now(), e = new Uint8Array(16);
5
5
  crypto.getRandomValues(e), e[0] = o / 2 ** 40 & 255, e[1] = o / 2 ** 32 & 255, e[2] = o / 2 ** 24 & 255, e[3] = o / 2 ** 16 & 255, e[4] = o / 2 ** 8 & 255, e[5] = o & 255, e[6] = e[6] & 15 | 112, e[8] = e[8] & 63 | 128;
6
6
  const t = Array.from(e, (a) => a.toString(16).padStart(2, "0")).join("");
7
7
  return `${t.slice(0, 8)}-${t.slice(8, 12)}-${t.slice(12, 16)}-${t.slice(16, 20)}-${t.slice(20)}`;
8
8
  }
9
- class st {
9
+ class ct {
10
10
  constructor(e) {
11
11
  this._handlers = /* @__PURE__ */ new Map(), this._destroyed = !1, this._namespace = e.namespace, this._allowedOrigins = e.allowedOrigins ?? ["*"], this._onMessage = e.onMessage, this._allowedOrigins.includes("*"), this._messageListener = (t) => this._handlePostMessage(t), window.addEventListener("message", this._messageListener);
12
12
  }
@@ -45,7 +45,7 @@ class st {
45
45
  _handlePostMessage(e) {
46
46
  if (this._destroyed || !this._isOriginAllowed(e.origin)) return;
47
47
  const t = e.data;
48
- if (!ct(t) || t.gengage !== this._namespace) return;
48
+ if (!lt(t) || t.gengage !== this._namespace) return;
49
49
  const a = { type: t.type };
50
50
  t.payload !== void 0 && (a.payload = t.payload), this._onMessage?.(a);
51
51
  const n = this._handlers.get(a.type);
@@ -57,14 +57,14 @@ class st {
57
57
  return this._allowedOrigins.includes("*") ? !0 : this._allowedOrigins.includes(e);
58
58
  }
59
59
  }
60
- function ct(o) {
60
+ function lt(o) {
61
61
  if (typeof o != "object" || o === null) return !1;
62
62
  const e = o;
63
63
  return typeof e.gengage == "string" && typeof e.type == "string";
64
64
  }
65
- const lt = console;
66
- function gt(o, e, t = {}) {
67
- const a = o.action, n = t.logger ?? lt;
65
+ const gt = console;
66
+ function dt(o, e, t = {}) {
67
+ const a = o.action, n = t.logger ?? gt;
68
68
  switch (a.kind) {
69
69
  case "open_chat": {
70
70
  e.openChat?.(a.payload);
@@ -80,7 +80,7 @@ function gt(o, e, t = {}) {
80
80
  i !== void 0 ? e.navigate({ url: a.url, newTab: i }) : e.navigate({ url: a.url });
81
81
  return;
82
82
  }
83
- dt(a.url, i);
83
+ pt(a.url, i);
84
84
  return;
85
85
  }
86
86
  case "save_session": {
@@ -112,7 +112,7 @@ function gt(o, e, t = {}) {
112
112
  X(a, e, t, n);
113
113
  return;
114
114
  }
115
- const i = pt(a.payload) ? a.payload : void 0;
115
+ const i = ht(a.payload) ? a.payload : void 0;
116
116
  i !== void 0 ? e.scriptCall?.({ name: a.name, payload: i }) : e.scriptCall?.({ name: a.name });
117
117
  return;
118
118
  }
@@ -130,7 +130,7 @@ function X(o, e, t, a) {
130
130
  throw new Error(`[gengage] Unknown action kind: ${o.kind}`);
131
131
  a.warn("[gengage] Unknown action ignored", o);
132
132
  }
133
- function dt(o, e) {
133
+ function pt(o, e) {
134
134
  if (!(typeof window > "u")) {
135
135
  if (e) {
136
136
  window.open(o, "_blank", "noopener,noreferrer");
@@ -139,18 +139,18 @@ function dt(o, e) {
139
139
  window.location.href = o;
140
140
  }
141
141
  }
142
- function pt(o) {
142
+ function ht(o) {
143
143
  return typeof o == "object" && o !== null && !Array.isArray(o);
144
144
  }
145
- const ht = ["image/jpeg", "image/png", "image/webp"], ut = 5 * 1024 * 1024;
146
- function mt(o) {
147
- return ht.includes(o.type) ? o.size > ut ? { ok: !1, reason: "too_large" } : { ok: !0 } : { ok: !1, reason: "invalid_type" };
145
+ const ut = ["image/jpeg", "image/png", "image/webp"], mt = 5 * 1024 * 1024;
146
+ function ft(o) {
147
+ return ut.includes(o.type) ? o.size > mt ? { ok: !1, reason: "too_large" } : { ok: !0 } : { ok: !1, reason: "invalid_type" };
148
148
  }
149
- function ft(o, e) {
149
+ function bt(o, e) {
150
150
  const t = o.type, a = o.payload != null && typeof o.payload == "object" && !Array.isArray(o.payload) ? o.payload : {}, n = (i) => {
151
151
  const r = { ...a };
152
- for (const [s, g] of Object.entries(i))
153
- s in r || (r[s] = g);
152
+ for (const [s, l] of Object.entries(i))
153
+ s in r || (r[s] = l);
154
154
  return r;
155
155
  };
156
156
  switch (t) {
@@ -180,17 +180,17 @@ function ft(o, e) {
180
180
  return o;
181
181
  }
182
182
  }
183
- const bt = {
183
+ const xt = {
184
184
  user_message: "inputText"
185
185
  };
186
- function xt(o) {
187
- const { action: e, type: t, payload: a, ...n } = o, i = t ?? e?.type ?? "inputText", r = a ?? e?.payload, s = bt[i] ?? i, g = {
186
+ function vt(o) {
187
+ const { action: e, type: t, payload: a, ...n } = o, i = t ?? e?.type ?? "inputText", r = a ?? e?.payload, s = xt[i] ?? i, l = {
188
188
  ...n,
189
189
  type: s
190
190
  };
191
- return r !== void 0 && (g.payload = typeof r == "string" ? { text: r } : r), JSON.stringify(g);
191
+ return r !== void 0 && (l.payload = typeof r == "string" ? { text: r } : r), JSON.stringify(l);
192
192
  }
193
- function vt(o) {
193
+ function wt(o) {
194
194
  const e = o.type ?? o.action?.type ?? "inputText", t = o.payload ?? o.action?.payload;
195
195
  let a = o.action?.title ?? "";
196
196
  (e === "inputText" || e === "user_message") && (typeof t == "string" ? a = t : t && typeof t == "object" && "text" in t && (a = String(t.text)));
@@ -204,64 +204,64 @@ function vt(o) {
204
204
  }
205
205
  return e !== "inputText" && e !== "user_message" && (n.action_type = e, t !== void 0 && (n.action_payload = typeof t == "string" ? { text: t } : t)), JSON.stringify(n);
206
206
  }
207
- function wt(o, e, t) {
208
- const a = Le("process_action", t), n = new AbortController();
207
+ function yt(o, e, t) {
208
+ const a = fe("process_action", t), n = new AbortController();
209
209
  return (async () => {
210
210
  try {
211
- const r = t.backendType === "acap" ? vt(o) : xt(o), s = t.attachment !== void 0;
212
- let g;
211
+ const r = t.backendType === "acap" ? wt(o) : vt(o), s = t.attachment !== void 0;
212
+ let l;
213
213
  if (s) {
214
214
  const m = new FormData();
215
- m.append("request", r), t.attachment !== void 0 && m.append("attachment", t.attachment), g = {
215
+ m.append("request", r), t.attachment !== void 0 && m.append("attachment", t.attachment), l = {
216
216
  method: "POST",
217
217
  body: m,
218
218
  signal: n.signal
219
219
  };
220
220
  } else
221
- g = {
221
+ l = {
222
222
  method: "POST",
223
223
  headers: { "Content-Type": "application/json" },
224
224
  body: r,
225
225
  signal: n.signal
226
226
  };
227
- const d = await fetch(a, g);
228
- if (!d.ok) {
229
- let m = d.statusText;
227
+ const g = await fetch(a, l);
228
+ if (!g.ok) {
229
+ let m = g.statusText;
230
230
  try {
231
- const l = await d.json(), v = l.detail ?? l.message ?? l.error;
231
+ const d = await g.json(), v = d.detail ?? d.message ?? d.error;
232
232
  typeof v == "string" && (m = v);
233
233
  } catch {
234
234
  }
235
- e.onError(new Error(`HTTP ${d.status}: ${m}`));
235
+ e.onError(new Error(`HTTP ${g.status}: ${m}`));
236
236
  return;
237
237
  }
238
238
  let c = !1;
239
239
  const h = () => {
240
240
  c || (c = !0, e.onDone());
241
241
  };
242
- await Ne(d, {
242
+ await Ae(g, {
243
243
  onEvent: (m) => {
244
- const l = Ae(m);
245
- if (l)
246
- switch (l.type) {
244
+ const d = Pe(m);
245
+ if (d)
246
+ switch (d.type) {
247
247
  case "text_chunk":
248
- e.onTextChunk(l.content, l.final === !0, {
249
- productMentions: l.productMentions,
250
- skuToProductItem: l.skuToProductItem,
251
- conversationMode: l.conversationMode
248
+ e.onTextChunk(d.content, d.final === !0, {
249
+ productMentions: d.productMentions,
250
+ skuToProductItem: d.skuToProductItem,
251
+ conversationMode: d.conversationMode
252
252
  });
253
253
  break;
254
254
  case "ui_spec":
255
- e.onUISpec(l.spec, l.widget, l.panelHint);
255
+ e.onUISpec(d.spec, d.widget, d.panelHint);
256
256
  break;
257
257
  case "action":
258
- e.onAction(l);
258
+ e.onAction(d);
259
259
  break;
260
260
  case "metadata":
261
- e.onMetadata(l);
261
+ e.onMetadata(d);
262
262
  break;
263
263
  case "error":
264
- e.onError(new Error(l.message));
264
+ e.onError(new Error(d.message));
265
265
  break;
266
266
  case "done":
267
267
  h();
@@ -277,7 +277,20 @@ function wt(o, e, t) {
277
277
  }
278
278
  })(), n;
279
279
  }
280
- const se = {
280
+ async function _t(o, e) {
281
+ const t = fe("proactive_action", e);
282
+ try {
283
+ const a = await fetch(t, {
284
+ method: "POST",
285
+ headers: { "Content-Type": "application/json" },
286
+ body: JSON.stringify(o)
287
+ });
288
+ return a.ok ? await a.json() : null;
289
+ } catch {
290
+ return null;
291
+ }
292
+ }
293
+ const ce = {
281
294
  headerTitle: "Ürün Uzmanı",
282
295
  inputPlaceholder: "Ürün ara, soru sor",
283
296
  sendButton: "Gönder",
@@ -334,7 +347,7 @@ const se = {
334
347
  voicePermissionDenied: "Mikrofon erişimi reddedildi.",
335
348
  voiceError: "Sesli giriş hatası.",
336
349
  handoffHeading: "Destek temsilcisine aktarılıyor"
337
- }, yt = {
350
+ }, kt = {
338
351
  headerTitle: "Product Expert",
339
352
  inputPlaceholder: "Search products, ask questions",
340
353
  sendButton: "Send",
@@ -392,20 +405,20 @@ const se = {
392
405
  voiceError: "Voice input error.",
393
406
  handoffHeading: "Transferring to a support agent"
394
407
  };
395
- function _t(o) {
408
+ function Ct(o) {
396
409
  return o ? o.toLowerCase().split("-")[0] ?? "tr" : "tr";
397
410
  }
398
- function kt(o) {
399
- return _t(o) === "en" ? yt : se;
411
+ function Et(o) {
412
+ return Ct(o) === "en" ? kt : ce;
400
413
  }
401
- function Ct() {
402
- return ve() !== null;
414
+ function St() {
415
+ return ye() !== null;
403
416
  }
404
- function ve() {
417
+ function ye() {
405
418
  const o = globalThis;
406
419
  return o.SpeechRecognition ?? o.webkitSpeechRecognition ?? null;
407
420
  }
408
- class Et {
421
+ class Tt {
409
422
  constructor(e, t) {
410
423
  this.recognition = null, this._state = "idle", this.silenceTimer = null, this.accumulatedTranscript = "", this.intentionalStop = !1, this.callbacks = e, this.lang = t?.lang ?? "tr-TR", this.silenceTimeoutMs = t?.silenceTimeoutMs ?? 1500, this.autoSubmit = t?.autoSubmit ?? !0;
411
424
  }
@@ -417,7 +430,7 @@ class Et {
417
430
  */
418
431
  start() {
419
432
  if (this._state === "listening") return;
420
- const e = ve();
433
+ const e = ye();
421
434
  if (!e) {
422
435
  this.setState("error"), this.callbacks.onError?.("not-supported", "Web Speech API is not supported in this browser.");
423
436
  return;
@@ -436,12 +449,12 @@ class Et {
436
449
  for (let r = a.resultIndex; r < a.results.length; r++) {
437
450
  const s = a.results[r];
438
451
  if (!s) continue;
439
- const g = s[0];
440
- g && (s.isFinal ? i += g.transcript : n += g.transcript);
452
+ const l = s[0];
453
+ l && (s.isFinal ? i += l.transcript : n += l.transcript);
441
454
  }
442
455
  i && (this.accumulatedTranscript += i, this.callbacks.onFinal?.(this.accumulatedTranscript)), n && this.callbacks.onInterim?.(this.accumulatedTranscript + n), this.autoSubmit && this.accumulatedTranscript && this.startSilenceTimer();
443
456
  }, t.onerror = (a) => {
444
- const n = St(a.error);
457
+ const n = It(a.error);
445
458
  this.intentionalStop && (a.error === "no-speech" || a.error === "aborted") || (this.setState("error"), this.callbacks.onError?.(n, a.message || a.error));
446
459
  }, t.onend = () => {
447
460
  if (this.clearSilenceTimer(), this._state === "listening" && !this.intentionalStop) {
@@ -503,7 +516,7 @@ class Et {
503
516
  this.silenceTimer !== null && (clearTimeout(this.silenceTimer), this.silenceTimer = null);
504
517
  }
505
518
  }
506
- function St(o) {
519
+ function It(o) {
507
520
  switch (o) {
508
521
  case "not-allowed":
509
522
  return "not-allowed";
@@ -519,7 +532,7 @@ function St(o) {
519
532
  return "unknown";
520
533
  }
521
534
  }
522
- function Tt(o) {
535
+ function Lt(o) {
523
536
  const e = document.createElement("div");
524
537
  e.className = "gengage-chat-kvkk-banner", e.setAttribute("role", "alert");
525
538
  const t = document.createElement("div");
@@ -527,7 +540,7 @@ function Tt(o) {
527
540
  const a = document.createElement("button");
528
541
  return a.className = "gengage-chat-kvkk-dismiss", a.type = "button", a.setAttribute("aria-label", o.closeAriaLabel ?? "Kapat"), a.textContent = "×", a.addEventListener("click", o.onDismiss), e.appendChild(a), e;
529
542
  }
530
- class It {
543
+ class Nt {
531
544
  constructor(e) {
532
545
  this._el = document.createElement("div"), this._el.className = "gengage-chat-panel-topbar", this._backBtn = document.createElement("button"), this._backBtn.className = "gengage-chat-panel-topbar-back", this._backBtn.type = "button", this._backBtn.disabled = !0, this._backBtn.setAttribute("aria-label", "Back"), this._backBtn.textContent = "←", this._backBtn.addEventListener("click", () => e.onBack()), this._titleEl = document.createElement("span"), this._titleEl.className = "gengage-chat-panel-topbar-title", this._forwardBtn = document.createElement("button"), this._forwardBtn.className = "gengage-chat-panel-topbar-forward", this._forwardBtn.type = "button", this._forwardBtn.disabled = !0, this._forwardBtn.setAttribute("aria-label", "Forward"), this._forwardBtn.textContent = "→", this._forwardBtn.addEventListener("click", () => e.onForward()), this._el.appendChild(this._backBtn), this._el.appendChild(this._titleEl), this._el.appendChild(this._forwardBtn);
533
546
  }
@@ -538,7 +551,7 @@ class It {
538
551
  return this._el;
539
552
  }
540
553
  }
541
- class Lt {
554
+ class At {
542
555
  constructor(e) {
543
556
  this._onThumbnailClick = e.onThumbnailClick, this._el = document.createElement("div"), this._el.className = "gengage-chat-thumbnails-column", this._el.style.display = "none";
544
557
  }
@@ -568,15 +581,15 @@ class Lt {
568
581
  this._el.style.display = "none";
569
582
  }
570
583
  }
571
- const ge = {
584
+ const de = {
572
585
  search: '<svg viewBox="0 0 16 16" class="gengage-chat-icon"><circle cx="6.5" cy="6.5" r="5" fill="none" stroke="currentColor" stroke-width="1.5"/><line x1="10" y1="10" x2="15" y2="15" stroke="currentColor" stroke-width="1.5"/></svg>',
573
586
  review: '<svg viewBox="0 0 16 16" class="gengage-chat-icon"><polygon points="8,1 10,6 15,6 11,9 12.5,14 8,11 3.5,14 5,9 1,6 6,6" fill="none" stroke="currentColor" stroke-width="1.5"/></svg>',
574
587
  info: '<svg viewBox="0 0 16 16" class="gengage-chat-icon"><circle cx="8" cy="8" r="7" fill="none" stroke="currentColor" stroke-width="1.5"/><line x1="8" y1="7" x2="8" y2="12" stroke="currentColor" stroke-width="1.5"/><circle cx="8" cy="4.5" r="0.8" fill="currentColor"/></svg>',
575
588
  similar: '<svg viewBox="0 0 16 16" class="gengage-chat-icon"><rect x="1" y="3" width="6" height="6" rx="1" fill="none" stroke="currentColor" stroke-width="1.5"/><rect x="9" y="3" width="6" height="6" rx="1" fill="none" stroke="currentColor" stroke-width="1.5"/></svg>'
576
- }, Nt = se;
577
- class At {
589
+ }, Pt = ce;
590
+ class Bt {
578
591
  constructor(e, t) {
579
- this._panelVisible = !1, this._panelCollapsed = !1, this._panelForceExpanded = !1, this._onPanelToggle = void 0, this._pendingAttachment = null, this._onAttachment = void 0, this._onRollback = void 0, this._onLinkClick = void 0, this._userScrolledUp = !1, this._scrollLockedUntil = 0, this._thinkingSteps = [], this._firstBotMessageIds = /* @__PURE__ */ new Set(), this._voiceInput = null, this._micBtn = null, this._voiceEnabled = !1, this._voiceLang = "tr-TR", this.i18n = { ...Nt, ...t.i18n }, this.onSend = t.onSend, t.onPanelToggle !== void 0 && (this._onPanelToggle = t.onPanelToggle), t.onAttachment !== void 0 && (this._onAttachment = t.onAttachment), t.onRollback !== void 0 && (this._onRollback = t.onRollback), t.onLinkClick !== void 0 && (this._onLinkClick = t.onLinkClick), t.voiceEnabled && (this._voiceEnabled = !0), t.voiceLang !== void 0 && (this._voiceLang = t.voiceLang), this.root = document.createElement("div"), this.root.className = "gengage-chat-drawer", this.root.setAttribute("role", "dialog"), this.root.setAttribute("aria-label", this.i18n.headerTitle ?? "Chat"), this.root.setAttribute("aria-modal", "true");
592
+ this._panelVisible = !1, this._panelCollapsed = !1, this._panelForceExpanded = !1, this._onPanelToggle = void 0, this._pendingAttachment = null, this._onAttachment = void 0, this._onRollback = void 0, this._onLinkClick = void 0, this._userScrolledUp = !1, this._scrollLockedUntil = 0, this._thinkingSteps = [], this._firstBotMessageIds = /* @__PURE__ */ new Set(), this._voiceInput = null, this._micBtn = null, this._voiceEnabled = !1, this._voiceLang = "tr-TR", this.i18n = { ...Pt, ...t.i18n }, this.onSend = t.onSend, t.onPanelToggle !== void 0 && (this._onPanelToggle = t.onPanelToggle), t.onAttachment !== void 0 && (this._onAttachment = t.onAttachment), t.onRollback !== void 0 && (this._onRollback = t.onRollback), t.onLinkClick !== void 0 && (this._onLinkClick = t.onLinkClick), t.voiceEnabled && (this._voiceEnabled = !0), t.voiceLang !== void 0 && (this._voiceLang = t.voiceLang), this.root = document.createElement("div"), this.root.className = "gengage-chat-drawer", this.root.setAttribute("role", "dialog"), this.root.setAttribute("aria-label", this.i18n.headerTitle ?? "Chat"), this.root.setAttribute("aria-modal", "true");
580
593
  const a = document.createElement("div");
581
594
  a.className = "gengage-chat-header";
582
595
  const n = document.createElement("div");
@@ -594,21 +607,21 @@ class At {
594
607
  u.className = "gengage-chat-header-badge", u.textContent = t.headerBadge, r.appendChild(u);
595
608
  }
596
609
  i.appendChild(r);
597
- const g = document.createElement("a");
598
- g.className = "gengage-chat-header-powered", g.href = "https://gengage.ai/", g.target = "_blank", g.rel = "noopener noreferrer", g.innerHTML = '<svg viewBox="0 0 16 16" fill="currentColor"><path d="M8 1a7 7 0 110 14A7 7 0 018 1zm0 1.5a5.5 5.5 0 100 11 5.5 5.5 0 000-11zM7 4.5h2v4H7v-4zm0 5h2v2H7v-2z"/></svg>Powered by Gengage', i.appendChild(g), n.appendChild(i), a.appendChild(n);
599
- const d = document.createElement("div");
600
- if (d.className = "gengage-chat-header-right", t.headerCartUrl) {
610
+ const l = document.createElement("a");
611
+ l.className = "gengage-chat-header-powered", l.href = "https://gengage.ai/", l.target = "_blank", l.rel = "noopener noreferrer", l.innerHTML = '<svg viewBox="0 0 16 16" fill="currentColor"><path d="M8 1a7 7 0 110 14A7 7 0 018 1zm0 1.5a5.5 5.5 0 100 11 5.5 5.5 0 000-11zM7 4.5h2v4H7v-4zm0 5h2v2H7v-2z"/></svg>Powered by Gengage', i.appendChild(l), n.appendChild(i), a.appendChild(n);
612
+ const g = document.createElement("div");
613
+ if (g.className = "gengage-chat-header-right", t.headerCartUrl) {
601
614
  const u = document.createElement("a");
602
- u.className = "gengage-chat-header-btn", u.href = t.headerCartUrl, u.target = "_blank", u.rel = "noopener noreferrer", u.setAttribute("aria-label", "Sepetim"), u.innerHTML = '<svg width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><circle cx="9" cy="21" r="1"/><circle cx="20" cy="21" r="1"/><path d="M1 1h4l2.68 13.39a2 2 0 0 0 2 1.61h9.72a2 2 0 0 0 2-1.61L23 6H6"/></svg>', d.appendChild(u);
615
+ u.className = "gengage-chat-header-btn", u.href = t.headerCartUrl, u.target = "_blank", u.rel = "noopener noreferrer", u.setAttribute("aria-label", "Sepetim"), u.innerHTML = '<svg width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><circle cx="9" cy="21" r="1"/><circle cx="20" cy="21" r="1"/><path d="M1 1h4l2.68 13.39a2 2 0 0 0 2 1.61h9.72a2 2 0 0 0 2-1.61L23 6H6"/></svg>', g.appendChild(u);
603
616
  }
604
617
  if (t.headerFavoritesToggle) {
605
618
  const u = document.createElement("button");
606
- u.className = "gengage-chat-header-btn", u.type = "button", u.setAttribute("aria-label", "Favorilerim"), u.innerHTML = '<svg width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M20.84 4.61a5.5 5.5 0 0 0-7.78 0L12 5.67l-1.06-1.06a5.5 5.5 0 0 0-7.78 7.78l1.06 1.06L12 21.23l7.78-7.78 1.06-1.06a5.5 5.5 0 0 0 0-7.78z"/></svg>', u.addEventListener("click", () => t.onFavoritesClick?.()), d.appendChild(u);
619
+ u.className = "gengage-chat-header-btn", u.type = "button", u.setAttribute("aria-label", "Favorilerim"), u.innerHTML = '<svg width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M20.84 4.61a5.5 5.5 0 0 0-7.78 0L12 5.67l-1.06-1.06a5.5 5.5 0 0 0-7.78 7.78l1.06 1.06L12 21.23l7.78-7.78 1.06-1.06a5.5 5.5 0 0 0 0-7.78z"/></svg>', u.addEventListener("click", () => t.onFavoritesClick?.()), g.appendChild(u);
607
620
  }
608
621
  const c = document.createElement("button");
609
- c.className = "gengage-chat-close", c.type = "button", c.setAttribute("aria-label", this.i18n.closeButton), c.innerHTML = '<svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5" stroke-linecap="round"><line x1="18" y1="6" x2="6" y2="18"/><line x1="6" y1="6" x2="18" y2="18"/></svg>', c.addEventListener("click", t.onClose), d.appendChild(c), a.appendChild(d);
622
+ c.className = "gengage-chat-close", c.type = "button", c.setAttribute("aria-label", this.i18n.closeButton), c.innerHTML = '<svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.5" stroke-linecap="round"><line x1="18" y1="6" x2="6" y2="18"/><line x1="6" y1="6" x2="18" y2="18"/></svg>', c.addEventListener("click", t.onClose), g.appendChild(c), a.appendChild(g);
610
623
  const h = document.createElement("div");
611
- h.className = "gengage-chat-body", this._panelEl = document.createElement("div"), this._panelEl.className = "gengage-chat-panel", this._panelTopBar = new It({
624
+ h.className = "gengage-chat-body", this._panelEl = document.createElement("div"), this._panelEl.className = "gengage-chat-panel", this._panelTopBar = new Nt({
612
625
  onBack: () => t.onPanelBack?.(),
613
626
  onForward: () => t.onPanelForward?.()
614
627
  }), this._panelEl.appendChild(this._panelTopBar.getElement()), h.appendChild(this._panelEl), this._dividerEl = document.createElement("div"), this._dividerEl.className = "gengage-chat-panel-divider gengage-chat-panel-divider--hidden", this._dividerEl.setAttribute("role", "separator"), this._dividerEl.setAttribute("aria-label", "Toggle panel");
@@ -616,8 +629,8 @@ class At {
616
629
  m.className = "gengage-chat-panel-divider-toggle", m.type = "button", m.setAttribute("aria-label", "Toggle panel"), m.textContent = "»", m.addEventListener("click", () => {
617
630
  this.togglePanel(), this._onPanelToggle?.();
618
631
  }), this._dividerEl.appendChild(m), h.appendChild(this._dividerEl);
619
- const l = document.createElement("div");
620
- l.className = "gengage-chat-conversation", l.appendChild(a), this._kvkkSlot = document.createElement("div"), this._kvkkSlot.className = "gengage-chat-kvkk-slot", l.appendChild(this._kvkkSlot), this.messagesEl = document.createElement("div"), this.messagesEl.className = "gengage-chat-messages", this.messagesEl.setAttribute("role", "log"), this.messagesEl.setAttribute("aria-live", "polite"), this.messagesEl.setAttribute("aria-label", "Chat messages");
632
+ const d = document.createElement("div");
633
+ d.className = "gengage-chat-conversation", d.appendChild(a), this._kvkkSlot = document.createElement("div"), this._kvkkSlot.className = "gengage-chat-kvkk-slot", d.appendChild(this._kvkkSlot), this.messagesEl = document.createElement("div"), this.messagesEl.className = "gengage-chat-messages", this.messagesEl.setAttribute("role", "log"), this.messagesEl.setAttribute("aria-live", "polite"), this.messagesEl.setAttribute("aria-label", "Chat messages");
621
634
  let v = !1;
622
635
  this.messagesEl.addEventListener(
623
636
  "scroll",
@@ -629,7 +642,7 @@ class At {
629
642
  }));
630
643
  },
631
644
  { passive: !0 }
632
- ), l.appendChild(this.messagesEl), this._thumbnailsColumn = new Lt({
645
+ ), d.appendChild(this.messagesEl), this._thumbnailsColumn = new At({
633
646
  onThumbnailClick: (u) => t.onThumbnailClick?.(u)
634
647
  }), this._panelEl.appendChild(this._thumbnailsColumn.getElement()), this._pillsEl = document.createElement("div"), this._pillsEl.className = "gengage-chat-pills", this._pillsEl.setAttribute("role", "toolbar"), this._pillsEl.setAttribute("aria-label", "Suggestions"), this._pillsEl.style.display = "none";
635
648
  const w = document.createElement("div");
@@ -649,7 +662,7 @@ class At {
649
662
  }));
650
663
  },
651
664
  { passive: !0 }
652
- ), l.appendChild(this._pillsEl), this._inputChipsEl = document.createElement("div"), this._inputChipsEl.className = "gengage-chat-input-chips", this._inputChipsEl.style.display = "none", l.appendChild(this._inputChipsEl);
665
+ ), d.appendChild(this._pillsEl), this._inputChipsEl = document.createElement("div"), this._inputChipsEl.className = "gengage-chat-input-chips", this._inputChipsEl.style.display = "none", d.appendChild(this._inputChipsEl);
653
666
  const I = document.createElement("div");
654
667
  I.className = "gengage-chat-input-area", this.inputEl = document.createElement("textarea"), this.inputEl.className = "gengage-chat-input", this.inputEl.rows = 1, this.inputEl.placeholder = this.i18n.inputPlaceholder, this.inputEl.addEventListener("input", () => {
655
668
  requestAnimationFrame(() => {
@@ -679,7 +692,7 @@ class At {
679
692
  f && (this._onAttachment ? this._onAttachment(f) : this.stageAttachment(f));
680
693
  });
681
694
  const k = document.createElement("div");
682
- k.className = "gengage-chat-input-pill", k.appendChild(p), k.appendChild(this.inputEl), this._voiceEnabled && Ct() && (this._micBtn = document.createElement("button"), this._micBtn.className = "gengage-chat-mic-btn", this._micBtn.type = "button", this._micBtn.setAttribute("aria-label", this.i18n.voiceButton), this._micBtn.innerHTML = '<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M12 1a3 3 0 0 0-3 3v8a3 3 0 0 0 6 0V4a3 3 0 0 0-3-3z"/><path d="M19 10v2a7 7 0 0 1-14 0v-2"/><line x1="12" y1="19" x2="12" y2="23"/><line x1="8" y1="23" x2="16" y2="23"/></svg>', this._micBtn.addEventListener("click", () => this._toggleVoice()), k.appendChild(this._micBtn), this._voiceInput = new Et(
695
+ k.className = "gengage-chat-input-pill", k.appendChild(p), k.appendChild(this.inputEl), this._voiceEnabled && St() && (this._micBtn = document.createElement("button"), this._micBtn.className = "gengage-chat-mic-btn", this._micBtn.type = "button", this._micBtn.setAttribute("aria-label", this.i18n.voiceButton), this._micBtn.innerHTML = '<svg width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M12 1a3 3 0 0 0-3 3v8a3 3 0 0 0 6 0V4a3 3 0 0 0-3-3z"/><path d="M19 10v2a7 7 0 0 1-14 0v-2"/><line x1="12" y1="19" x2="12" y2="23"/><line x1="8" y1="23" x2="16" y2="23"/></svg>', this._micBtn.addEventListener("click", () => this._toggleVoice()), k.appendChild(this._micBtn), this._voiceInput = new Tt(
683
696
  {
684
697
  onInterim: (u) => {
685
698
  this.inputEl.value = u, this.inputEl.style.height = "auto", this.inputEl.style.height = `${Math.min(this.inputEl.scrollHeight, 120)}px`;
@@ -698,7 +711,7 @@ class At {
698
711
  }
699
712
  },
700
713
  { lang: this._voiceLang }
701
- )), k.appendChild(this.sendBtn), I.appendChild(this._previewStrip), I.appendChild(this._fileInput), I.appendChild(k), l.appendChild(I), h.appendChild(l), this.root.appendChild(h);
714
+ )), k.appendChild(this.sendBtn), I.appendChild(this._previewStrip), I.appendChild(this._fileInput), I.appendChild(k), d.appendChild(I), h.appendChild(d), this.root.appendChild(h);
702
715
  const A = document.createElement("div");
703
716
  A.className = "gengage-chat-footer", A.textContent = this.i18n.poweredBy, this.root.appendChild(A), this.root.addEventListener("keydown", (u) => {
704
717
  u.key === "Escape" && t.onClose();
@@ -789,10 +802,10 @@ class At {
789
802
  for (const n of e) {
790
803
  const i = document.createElement("button");
791
804
  if (i.className = n.image ? "gengage-chat-pill gengage-chat-pill--rich" : "gengage-chat-pill", i.type = "button", n.icon) {
792
- const s = ge[n.icon];
805
+ const s = de[n.icon];
793
806
  if (s) {
794
- const g = document.createElement("span");
795
- g.className = "gengage-chat-pill-icon", g.innerHTML = s, i.appendChild(g);
807
+ const l = document.createElement("span");
808
+ l.className = "gengage-chat-pill-icon", l.innerHTML = s, i.appendChild(l);
796
809
  }
797
810
  }
798
811
  if (n.image && K(n.image)) {
@@ -816,7 +829,7 @@ class At {
816
829
  }
817
830
  showKvkkBanner(e, t) {
818
831
  this._kvkkSlot.innerHTML = "";
819
- const a = Tt({ htmlContent: e, onDismiss: t });
832
+ const a = Lt({ htmlContent: e, onDismiss: t });
820
833
  this._kvkkSlot.appendChild(a);
821
834
  }
822
835
  hideKvkkBanner() {
@@ -912,9 +925,13 @@ class At {
912
925
  updatePanelTopBar(e, t, a) {
913
926
  this._panelTopBar.update(e, t, a);
914
927
  }
915
- /** Hide the panel and clear its content. In force-expanded mode, keeps panel visible. */
928
+ /**
929
+ * Hide the panel and clear its content. Always hides — even in force-expanded mode.
930
+ * Callers: _hideDrawer (stale panel cleanup), stream onDone (loading skeleton cleanup),
931
+ * thread navigation (no snapshot to restore). All require full hide.
932
+ */
916
933
  clearPanel() {
917
- this._panelEl.innerHTML = "", this._panelEl.appendChild(this._panelTopBar.getElement()), !this._panelForceExpanded && (this._panelVisible = !1, this._panelCollapsed = !1, this._panelEl.classList.remove("gengage-chat-panel--visible", "gengage-chat-panel--collapsed"), this.root.classList.remove("gengage-chat-drawer--with-panel"), this._dividerEl.classList.add("gengage-chat-panel-divider--hidden"));
934
+ this._panelEl.innerHTML = "", this._panelEl.appendChild(this._panelTopBar.getElement()), this._panelVisible = !1, this._panelCollapsed = !1, this._panelEl.classList.remove("gengage-chat-panel--visible", "gengage-chat-panel--collapsed"), this.root.classList.remove("gengage-chat-drawer--with-panel"), this._dividerEl.classList.add("gengage-chat-panel-divider--hidden");
918
935
  }
919
936
  /** Force the panel to stay expanded (panelMode: 'expanded'). Hides the divider toggle. */
920
937
  setForceExpanded() {
@@ -1046,7 +1063,7 @@ class At {
1046
1063
  for (const t of e) {
1047
1064
  const a = document.createElement("button");
1048
1065
  if (a.className = "gengage-chat-input-chip", a.type = "button", t.icon) {
1049
- const i = ge[t.icon];
1066
+ const i = de[t.icon];
1050
1067
  if (i) {
1051
1068
  const r = document.createElement("span");
1052
1069
  r.className = "gengage-chat-input-chip-icon", r.innerHTML = i, a.appendChild(r);
@@ -1067,7 +1084,7 @@ class At {
1067
1084
  this._thumbnailsColumn.hide();
1068
1085
  }
1069
1086
  }
1070
- const Pt = `<svg width="28" height="28" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
1087
+ const Mt = `<svg width="28" height="28" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
1071
1088
  <rect x="3" y="7" width="18" height="13" rx="3" fill="currentColor" opacity="0.15"/>
1072
1089
  <rect x="3" y="7" width="18" height="13" rx="3" stroke="currentColor" stroke-width="1.5"/>
1073
1090
  <circle cx="9" cy="13" r="1.5" fill="currentColor"/>
@@ -1078,13 +1095,13 @@ const Pt = `<svg width="28" height="28" viewBox="0 0 24 24" fill="none" xmlns="h
1078
1095
  <path d="M1 12V14" stroke="currentColor" stroke-width="1.5" stroke-linecap="round"/>
1079
1096
  <path d="M23 12V14" stroke="currentColor" stroke-width="1.5" stroke-linecap="round"/>
1080
1097
  </svg>`;
1081
- function Bt(o) {
1098
+ function zt(o) {
1082
1099
  const e = document.createElement("div");
1083
1100
  e.className = "gengage-chat-launcher-container";
1084
1101
  const t = document.createElement("div");
1085
1102
  t.className = "gengage-chat-launcher-content-area", e.appendChild(t);
1086
1103
  const a = document.createElement("button");
1087
- if (a.className = "gengage-chat-launcher", a.type = "button", a.setAttribute("aria-label", o.ariaLabel ?? "Open chat"), a.innerHTML = o.svgMarkup ?? Pt, o.tooltip !== void 0) {
1104
+ if (a.className = "gengage-chat-launcher", a.type = "button", a.setAttribute("aria-label", o.ariaLabel ?? "Open chat"), a.innerHTML = o.svgMarkup ?? Mt, o.tooltip !== void 0) {
1088
1105
  const i = document.createElement("span");
1089
1106
  i.className = "gengage-chat-launcher-tooltip", i.textContent = o.tooltip, a.appendChild(i);
1090
1107
  }
@@ -1092,7 +1109,7 @@ function Bt(o) {
1092
1109
  const n = document.createElement("div");
1093
1110
  return n.className = "gengage-chat-launcher-content-area-bottom", e.appendChild(n), { container: e, button: a, contentArea: t, contentAreaBottom: n };
1094
1111
  }
1095
- function Mt(o) {
1112
+ function Dt(o) {
1096
1113
  const e = document.createElement("div");
1097
1114
  e.className = "gengage-chat-proactive";
1098
1115
  const t = document.createElement("p");
@@ -1100,20 +1117,32 @@ function Mt(o) {
1100
1117
  const a = document.createElement("div");
1101
1118
  a.className = "gengage-chat-proactive-actions";
1102
1119
  let n = null;
1103
- const i = document.createElement("button");
1104
- i.className = "gengage-chat-proactive-accept", i.type = "button", i.textContent = o.acceptLabel ?? "Sohbete Başla", i.addEventListener("click", () => {
1105
- n !== null && clearTimeout(n), e.remove(), o.onAccept();
1106
- }), a.appendChild(i);
1120
+ function i() {
1121
+ n !== null && clearTimeout(n), e.remove();
1122
+ }
1123
+ if (o.actionButtons && o.actionButtons.length > 0)
1124
+ for (const l of o.actionButtons) {
1125
+ const g = document.createElement("button");
1126
+ g.className = "gengage-chat-proactive-accept", g.type = "button", g.textContent = l.title, g.addEventListener("click", () => {
1127
+ i(), l.onSelect();
1128
+ }), a.appendChild(g);
1129
+ }
1130
+ else {
1131
+ const l = document.createElement("button");
1132
+ l.className = "gengage-chat-proactive-accept", l.type = "button", l.textContent = o.acceptLabel ?? "Sohbete Başla", l.addEventListener("click", () => {
1133
+ i(), o.onAccept();
1134
+ }), a.appendChild(l);
1135
+ }
1107
1136
  const r = document.createElement("button");
1108
1137
  r.className = "gengage-chat-proactive-dismiss", r.type = "button", r.textContent = "×", r.setAttribute("aria-label", o.closeAriaLabel ?? "Kapat"), r.addEventListener("click", () => {
1109
- n !== null && clearTimeout(n), e.remove();
1138
+ i(), o.onDismiss();
1110
1139
  }), e.appendChild(r), e.appendChild(a);
1111
1140
  const s = o.autoDismissMs ?? 15e3;
1112
1141
  return s > 0 && (n = setTimeout(() => {
1113
- e.parentElement && e.remove();
1142
+ e.parentElement && (e.remove(), o.onDismiss());
1114
1143
  }, s)), requestAnimationFrame(() => e.classList.add("gengage-chat-proactive--visible")), e;
1115
1144
  }
1116
- class zt {
1145
+ class Rt {
1117
1146
  constructor(e = {}) {
1118
1147
  this._idleTimer = null, this._maxScrollDepth = 0, this._lastReportedDepth = 0, this._listeners = [], this._destroyed = !1, this._idleThreshold = e.idleThresholdMs ?? 3e4, this._scrollGranularity = e.scrollGranularity ?? 25, this._onActivity = e.onActivity ?? null, this._setup();
1119
1148
  }
@@ -1155,7 +1184,7 @@ class zt {
1155
1184
  this._listeners = [];
1156
1185
  }
1157
1186
  }
1158
- const Dt = /* @__PURE__ */ new Set([
1187
+ const Ut = /* @__PURE__ */ new Set([
1159
1188
  "audio/ogg",
1160
1189
  "audio/mpeg",
1161
1190
  "audio/mp3",
@@ -1164,9 +1193,9 @@ const Dt = /* @__PURE__ */ new Set([
1164
1193
  "audio/aac",
1165
1194
  "audio/mp4"
1166
1195
  ]);
1167
- function Rt(o, e = "audio/ogg") {
1196
+ function Ht(o, e = "audio/ogg") {
1168
1197
  const t = e.split(";")[0].trim();
1169
- if (!Dt.has(t)) return null;
1198
+ if (!Ut.has(t)) return null;
1170
1199
  try {
1171
1200
  const a = new Audio(`data:${e};base64,${o}`);
1172
1201
  return a.play().catch(() => {
@@ -1179,10 +1208,10 @@ function Rt(o, e = "audio/ogg") {
1179
1208
  return null;
1180
1209
  }
1181
1210
  }
1182
- class Ut {
1211
+ class Ft {
1183
1212
  constructor(e) {
1184
1213
  this._timer = null, this._destroyed = !1, this._abortController = null, this._sessionStart = Date.now(), this._lastActivity = Date.now(), this._searchesCount = 0, this._actionsCount = 0, this._triggerFireCounts = {}, this._options = e;
1185
- const t = Pe(e.middlewareUrl);
1214
+ const t = Be(e.middlewareUrl);
1186
1215
  this._endpoint = `${t}/v2/heartbeat`;
1187
1216
  }
1188
1217
  start() {
@@ -1243,7 +1272,7 @@ class Ut {
1243
1272
  }
1244
1273
  }
1245
1274
  }
1246
- const Ht = {
1275
+ const Ot = {
1247
1276
  screen_size: "Ekran Boyutu",
1248
1277
  weight: "Ağırlık",
1249
1278
  battery_capacity: "Batarya Kapasitesi",
@@ -1275,14 +1304,14 @@ const Ht = {
1275
1304
  height: "Yükseklik",
1276
1305
  depth: "Derinlik"
1277
1306
  };
1278
- function Ft(o) {
1279
- return Ht[o] ?? o.replace(/_/g, " ").replace(/^\w/, (e) => e.toUpperCase());
1307
+ function qt(o) {
1308
+ return Ot[o] ?? o.replace(/_/g, " ").replace(/^\w/, (e) => e.toUpperCase());
1280
1309
  }
1281
- function Ot(o) {
1282
- const { recommended: e, products: t, attributes: a, highlights: n, specialCases: i, onProductClick: r, i18n: s } = o, g = document.createElement("div");
1283
- g.className = "gengage-chat-comparison";
1284
- const d = document.createElement("h3");
1285
- if (d.className = "gengage-chat-comparison-heading", d.textContent = s?.comparisonHeading ?? "KARŞILAŞTIRMA SONUÇLARI", g.appendChild(d), e) {
1310
+ function jt(o) {
1311
+ const { recommended: e, products: t, attributes: a, highlights: n, specialCases: i, onProductClick: r, i18n: s } = o, l = document.createElement("div");
1312
+ l.className = "gengage-chat-comparison";
1313
+ const g = document.createElement("h3");
1314
+ if (g.className = "gengage-chat-comparison-heading", g.textContent = s?.comparisonHeading ?? "KARŞILAŞTIRMA SONUÇLARI", l.appendChild(g), e) {
1286
1315
  const c = document.createElement("div");
1287
1316
  c.className = "gengage-chat-comparison-recommended";
1288
1317
  const h = document.createElement("div");
@@ -1298,12 +1327,12 @@ function Ot(o) {
1298
1327
  { once: !0 }
1299
1328
  ), m.appendChild(b);
1300
1329
  }
1301
- const l = document.createElement("div");
1302
- l.className = "gengage-chat-comparison-recommended-info";
1330
+ const d = document.createElement("div");
1331
+ d.className = "gengage-chat-comparison-recommended-info";
1303
1332
  const v = document.createElement("div");
1304
- v.className = "gengage-chat-comparison-recommended-title", v.textContent = e.name, l.appendChild(v);
1333
+ v.className = "gengage-chat-comparison-recommended-title", v.textContent = e.name, d.appendChild(v);
1305
1334
  const w = document.createElement("div");
1306
- if (w.className = "gengage-chat-comparison-recommended-price", w.textContent = e.price, l.appendChild(w), m.appendChild(l), m.addEventListener("click", () => {
1335
+ if (w.className = "gengage-chat-comparison-recommended-price", w.textContent = e.price, d.appendChild(w), m.appendChild(d), m.addEventListener("click", () => {
1307
1336
  r(e.sku);
1308
1337
  }), m.style.cursor = "pointer", c.appendChild(m), n.length > 0) {
1309
1338
  const b = document.createElement("div");
@@ -1321,7 +1350,7 @@ function Ot(o) {
1321
1350
  const b = document.createElement("div");
1322
1351
  b.className = "gengage-chat-comparison-recommended-text", b.textContent = o.recommendedText, c.appendChild(b);
1323
1352
  }
1324
- g.appendChild(c);
1353
+ l.appendChild(c);
1325
1354
  }
1326
1355
  if (o.keyDifferencesHtml) {
1327
1356
  const c = document.createElement("div");
@@ -1329,7 +1358,7 @@ function Ot(o) {
1329
1358
  const h = document.createElement("h4");
1330
1359
  h.textContent = s?.keyDifferencesLabel ?? "Temel Farklar", c.appendChild(h);
1331
1360
  const m = document.createElement("div");
1332
- m.className = "gengage-chat-comparison-key-differences-content", m.innerHTML = Z(qt(o.keyDifferencesHtml)), c.appendChild(m), g.appendChild(c);
1361
+ m.className = "gengage-chat-comparison-key-differences-content", m.innerHTML = Z(Vt(o.keyDifferencesHtml)), c.appendChild(m), l.appendChild(c);
1333
1362
  }
1334
1363
  if (i && i.length > 0) {
1335
1364
  const c = document.createElement("details");
@@ -1337,17 +1366,17 @@ function Ot(o) {
1337
1366
  const h = document.createElement("summary");
1338
1367
  h.textContent = s?.specialCasesLabel ?? "Özel Durumlar İçin", c.appendChild(h);
1339
1368
  const m = document.createElement("ul");
1340
- for (const l of i) {
1369
+ for (const d of i) {
1341
1370
  const v = document.createElement("li");
1342
- v.textContent = l, m.appendChild(v);
1371
+ v.textContent = d, m.appendChild(v);
1343
1372
  }
1344
- c.appendChild(m), g.appendChild(c);
1373
+ c.appendChild(m), l.appendChild(c);
1345
1374
  }
1346
1375
  if (t.length > 0 && a.length > 0) {
1347
1376
  const c = document.createElement("table");
1348
1377
  c.className = "gengage-chat-comparison-table";
1349
- const h = document.createElement("thead"), m = document.createElement("tr"), l = document.createElement("th");
1350
- m.appendChild(l);
1378
+ const h = document.createElement("thead"), m = document.createElement("tr"), d = document.createElement("th");
1379
+ m.appendChild(d);
1351
1380
  for (const w of t) {
1352
1381
  const b = document.createElement("th");
1353
1382
  if (w.sku === e?.sku && (b.className = "gengage-chat-comparison-selected"), w.imageUrl && K(w.imageUrl)) {
@@ -1369,33 +1398,33 @@ function Ot(o) {
1369
1398
  const v = document.createElement("tbody");
1370
1399
  for (const w of a) {
1371
1400
  const b = document.createElement("tr"), N = document.createElement("td");
1372
- N.className = "gengage-chat-comparison-label", N.textContent = Ft(w.label), b.appendChild(N);
1401
+ N.className = "gengage-chat-comparison-label", N.textContent = qt(w.label), b.appendChild(N);
1373
1402
  for (let I = 0; I < w.values.length; I++) {
1374
1403
  const p = document.createElement("td");
1375
1404
  t[I]?.sku === e?.sku && (p.className = "gengage-chat-comparison-selected"), p.textContent = w.values[I] ?? "", b.appendChild(p);
1376
1405
  }
1377
1406
  v.appendChild(b);
1378
1407
  }
1379
- c.appendChild(v), g.appendChild(c);
1408
+ c.appendChild(v), l.appendChild(c);
1380
1409
  }
1381
1410
  if (o.productActions) {
1382
1411
  const c = document.createElement("div");
1383
1412
  c.className = "gengage-chat-comparison-product-actions";
1384
1413
  for (const h of t)
1385
1414
  if (o.productActions[h.sku]) {
1386
- const l = document.createElement("button");
1387
- l.className = "gengage-chat-comparison-view-btn", l.type = "button", l.textContent = h.name, l.addEventListener("click", () => r(h.sku)), c.appendChild(l);
1415
+ const d = document.createElement("button");
1416
+ d.className = "gengage-chat-comparison-view-btn", d.type = "button", d.textContent = h.name, d.addEventListener("click", () => r(h.sku)), c.appendChild(d);
1388
1417
  }
1389
- c.childElementCount > 0 && g.appendChild(c);
1418
+ c.childElementCount > 0 && l.appendChild(c);
1390
1419
  }
1391
- return g;
1420
+ return l;
1392
1421
  }
1393
- function qt(o) {
1422
+ function Vt(o) {
1394
1423
  const e = o.split(`
1395
1424
  `).filter((t) => t.trim());
1396
1425
  return e.length <= 1 ? o : "<ul>" + e.map((t) => `<li>${t.trim()}</li>`).join("") + "</ul>";
1397
1426
  }
1398
- function jt(o, e) {
1427
+ function Gt(o, e) {
1399
1428
  const t = document.createElement("div");
1400
1429
  t.className = "gengage-chat-review-highlights";
1401
1430
  const a = o.props?.reviews;
@@ -1412,57 +1441,57 @@ function jt(o, e) {
1412
1441
  r.className = "gengage-chat-review-tabs";
1413
1442
  const s = [{ label: `Tümü (${i.all})`, filter: "all" }];
1414
1443
  i.positive > 0 && s.push({ label: `Olumlu (${i.positive})`, filter: "positive" }), i.negative > 0 && s.push({ label: `Olumsuz (${i.negative})`, filter: "negative" });
1415
- let g = "all";
1416
- const d = document.createElement("div");
1417
- d.className = "gengage-chat-review-items";
1444
+ let l = "all";
1445
+ const g = document.createElement("div");
1446
+ g.className = "gengage-chat-review-items";
1418
1447
  function c() {
1419
- for (; d.firstChild; ) d.removeChild(d.firstChild);
1420
- const m = g === "all" ? n : n.filter((l) => l.review_class === g);
1421
- for (const l of m) {
1448
+ for (; g.firstChild; ) g.removeChild(g.firstChild);
1449
+ const m = l === "all" ? n : n.filter((d) => d.review_class === l);
1450
+ for (const d of m) {
1422
1451
  const v = document.createElement("article");
1423
1452
  v.className = "gengage-chat-review-item";
1424
- const w = l.review_class;
1425
- if ((w === "positive" || w === "negative" || w === "neutral") && (v.dataset.tone = w), typeof l.review_tag == "string" && l.review_tag.length > 0) {
1453
+ const w = d.review_class;
1454
+ if ((w === "positive" || w === "negative" || w === "neutral") && (v.dataset.tone = w), typeof d.review_tag == "string" && d.review_tag.length > 0) {
1426
1455
  const b = document.createElement("div");
1427
- b.className = "gengage-chat-review-tag", b.textContent = l.review_tag, v.appendChild(b);
1456
+ b.className = "gengage-chat-review-tag", b.textContent = d.review_tag, v.appendChild(b);
1428
1457
  }
1429
- if (typeof l.review_text == "string" && l.review_text.length > 0) {
1458
+ if (typeof d.review_text == "string" && d.review_text.length > 0) {
1430
1459
  const b = document.createElement("div");
1431
- b.className = "gengage-chat-review-text", b.textContent = l.review_text, v.appendChild(b);
1460
+ b.className = "gengage-chat-review-text", b.textContent = d.review_text, v.appendChild(b);
1432
1461
  }
1433
- if (l.review_rating !== void 0 && String(l.review_rating).length > 0) {
1462
+ if (d.review_rating !== void 0 && String(d.review_rating).length > 0) {
1434
1463
  const b = document.createElement("div");
1435
- b.className = "gengage-chat-review-rating", b.textContent = String(l.review_rating), v.appendChild(b);
1464
+ b.className = "gengage-chat-review-rating", b.textContent = String(d.review_rating), v.appendChild(b);
1436
1465
  }
1437
- d.appendChild(v);
1466
+ g.appendChild(v);
1438
1467
  }
1439
1468
  }
1440
1469
  for (const m of s) {
1441
- const l = document.createElement("button");
1442
- l.className = "gengage-chat-review-tab", l.type = "button", l.textContent = m.label, m.filter === g && l.classList.add("gengage-chat-review-tab--active"), l.addEventListener("click", () => {
1443
- g = m.filter;
1470
+ const d = document.createElement("button");
1471
+ d.className = "gengage-chat-review-tab", d.type = "button", d.textContent = m.label, m.filter === l && d.classList.add("gengage-chat-review-tab--active"), d.addEventListener("click", () => {
1472
+ l = m.filter;
1444
1473
  for (const v of r.querySelectorAll(".gengage-chat-review-tab"))
1445
- v.classList.toggle("gengage-chat-review-tab--active", v === l);
1474
+ v.classList.toggle("gengage-chat-review-tab--active", v === d);
1446
1475
  c();
1447
- }), r.appendChild(l);
1476
+ }), r.appendChild(d);
1448
1477
  }
1449
1478
  t.appendChild(r);
1450
1479
  const h = /* @__PURE__ */ new Map();
1451
1480
  for (const m of n)
1452
1481
  if (typeof m.review_tag == "string" && m.review_tag.length > 0) {
1453
- const l = h.get(m.review_tag);
1454
- l ? l.count++ : h.set(m.review_tag, { count: 1, sentiment: m.review_class ?? "neutral" });
1482
+ const d = h.get(m.review_tag);
1483
+ d ? d.count++ : h.set(m.review_tag, { count: 1, sentiment: m.review_class ?? "neutral" });
1455
1484
  }
1456
1485
  if (h.size > 0) {
1457
1486
  const m = document.createElement("div");
1458
1487
  m.className = "gengage-chat-review-pills";
1459
- for (const [l, v] of h) {
1488
+ for (const [d, v] of h) {
1460
1489
  const w = document.createElement("span");
1461
1490
  w.className = "gengage-chat-review-pill", w.dataset.tone = v.sentiment;
1462
1491
  const b = document.createElement("span");
1463
1492
  b.className = "gengage-chat-review-pill-icon", b.textContent = v.sentiment === "positive" ? "✓" : v.sentiment === "negative" ? "✕" : "●", w.appendChild(b);
1464
1493
  const N = document.createElement("span");
1465
- if (N.textContent = l, w.appendChild(N), v.count > 1) {
1494
+ if (N.textContent = d, w.appendChild(N), v.count > 1) {
1466
1495
  const I = document.createElement("span");
1467
1496
  I.className = "gengage-chat-review-pill-count", I.textContent = String(v.count), w.appendChild(I);
1468
1497
  }
@@ -1470,19 +1499,19 @@ function jt(o, e) {
1470
1499
  }
1471
1500
  t.appendChild(m);
1472
1501
  }
1473
- return c(), t.appendChild(d), t;
1502
+ return c(), t.appendChild(g), t;
1474
1503
  }
1475
- const Vt = {
1504
+ const $t = {
1476
1505
  winner: "roleWinner",
1477
1506
  best_value: "roleBestValue",
1478
1507
  best_alternative: "roleBestAlternative"
1479
1508
  };
1480
- function we(o, e) {
1509
+ function _e(o, e) {
1481
1510
  if (!o || !e) return null;
1482
- const t = Vt[o];
1511
+ const t = $t[o];
1483
1512
  return t ? e[t] ?? o : o;
1484
1513
  }
1485
- function Gt(o, e) {
1514
+ function Kt(o, e) {
1486
1515
  const t = document.createElement("div");
1487
1516
  t.className = "gengage-chat-ai-top-picks";
1488
1517
  const a = o.props?.suggestions ?? [];
@@ -1492,20 +1521,20 @@ function Gt(o, e) {
1492
1521
  const i = document.createElement("div");
1493
1522
  i.className = "gengage-chat-ai-top-picks-cards";
1494
1523
  for (let r = 0; r < a.length; r++) {
1495
- const s = a[r], d = s.role === "winner" || r === 0 ? $t(s, e) : Kt(s, e);
1496
- i.appendChild(d);
1524
+ const s = a[r], g = s.role === "winner" || r === 0 ? Wt(s, e) : Yt(s, e);
1525
+ i.appendChild(g);
1497
1526
  }
1498
1527
  return t.appendChild(i), t;
1499
1528
  }
1500
- function $t(o, e) {
1529
+ function Wt(o, e) {
1501
1530
  const t = document.createElement("div");
1502
1531
  t.className = "gengage-chat-ai-toppick-card gengage-chat-ai-toppick-card--winner";
1503
1532
  const a = document.createElement("span");
1504
- a.className = "gengage-chat-ai-toppick-badge", a.textContent = we(o.role, e.i18n) ?? e.i18n?.roleWinner ?? "TOP MATCH", t.appendChild(a);
1533
+ a.className = "gengage-chat-ai-toppick-badge", a.textContent = _e(o.role, e.i18n) ?? e.i18n?.roleWinner ?? "TOP MATCH", t.appendChild(a);
1505
1534
  const n = o.product, i = n.discountPercent;
1506
1535
  if (typeof i == "number" && i > 0) {
1507
1536
  const h = document.createElement("span");
1508
- h.className = "gengage-chat-ai-toppick-discount-badge", h.textContent = `%${re(i)}`, t.appendChild(h);
1537
+ h.className = "gengage-chat-ai-toppick-discount-badge", h.textContent = `%${se(i)}`, t.appendChild(h);
1509
1538
  }
1510
1539
  const r = n.imageUrl;
1511
1540
  if (r && K(r)) {
@@ -1514,16 +1543,16 @@ function $t(o, e) {
1514
1543
  }
1515
1544
  const s = document.createElement("div");
1516
1545
  s.className = "gengage-chat-ai-toppick-body";
1517
- const g = n.name;
1518
- if (g) {
1546
+ const l = n.name;
1547
+ if (l) {
1519
1548
  const h = document.createElement("div");
1520
- h.className = "gengage-chat-ai-toppick-name", h.textContent = g, s.appendChild(h);
1549
+ h.className = "gengage-chat-ai-toppick-name", h.textContent = l, s.appendChild(h);
1521
1550
  }
1522
1551
  if (o.reason) {
1523
1552
  const h = document.createElement("div");
1524
1553
  h.className = "gengage-chat-ai-toppick-reason", h.textContent = o.reason, s.appendChild(h);
1525
1554
  }
1526
- if (o.labels && o.labels.length > 0 && s.appendChild(ye(o.labels)), typeof o.expertQualityScore == "number") {
1555
+ if (o.labels && o.labels.length > 0 && s.appendChild(ke(o.labels)), typeof o.expertQualityScore == "number") {
1527
1556
  const h = document.createElement("div");
1528
1557
  h.className = "gengage-chat-ai-toppick-score", h.textContent = `${o.expertQualityScore}/10`, s.appendChild(h);
1529
1558
  }
@@ -1531,33 +1560,33 @@ function $t(o, e) {
1531
1560
  const h = document.createElement("blockquote");
1532
1561
  h.className = "gengage-chat-ai-toppick-review", h.textContent = o.reviewHighlight, s.appendChild(h);
1533
1562
  }
1534
- const d = n.price, c = n.originalPrice;
1535
- if (d) {
1563
+ const g = n.price, c = n.originalPrice;
1564
+ if (g) {
1536
1565
  const h = document.createElement("div");
1537
- if (h.className = "gengage-chat-ai-toppick-price", c && c !== d) {
1538
- const l = document.createElement("span");
1539
- l.className = "gengage-chat-ai-toppick-original-price", l.textContent = F(c, e.pricing), h.appendChild(l), h.appendChild(document.createTextNode(" "));
1566
+ if (h.className = "gengage-chat-ai-toppick-price", c && c !== g) {
1567
+ const d = document.createElement("span");
1568
+ d.className = "gengage-chat-ai-toppick-original-price", d.textContent = F(c, e.pricing), h.appendChild(d), h.appendChild(document.createTextNode(" "));
1540
1569
  }
1541
1570
  const m = document.createElement("span");
1542
- m.textContent = F(d, e.pricing), h.appendChild(m), s.appendChild(h);
1571
+ m.textContent = F(g, e.pricing), h.appendChild(m), s.appendChild(h);
1543
1572
  }
1544
1573
  if (t.appendChild(s), o.action) {
1545
1574
  const h = n.sku ?? null, m = document.createElement("div");
1546
1575
  m.className = "gengage-chat-ai-toppick-spinner", m.style.display = h && e.topPicksLoadingSku === h ? "" : "none", t.appendChild(m);
1547
- const l = document.createElement("button");
1548
- l.className = "gengage-chat-ai-toppick-cta", l.type = "button", l.textContent = e.i18n?.viewDetails ?? "View Details", l.addEventListener("click", () => {
1576
+ const d = document.createElement("button");
1577
+ d.className = "gengage-chat-ai-toppick-cta", d.type = "button", d.textContent = e.i18n?.viewDetails ?? "View Details", d.addEventListener("click", () => {
1549
1578
  h && (m.style.display = ""), e.onAction(o.action);
1550
- }), t.appendChild(l);
1579
+ }), t.appendChild(d);
1551
1580
  }
1552
1581
  return t;
1553
1582
  }
1554
- function Kt(o, e) {
1583
+ function Yt(o, e) {
1555
1584
  const t = document.createElement("div");
1556
1585
  t.className = "gengage-chat-ai-toppick-card gengage-chat-ai-toppick-card--compact";
1557
1586
  const a = o.product, n = a.discountPercent;
1558
1587
  if (typeof n == "number" && n > 0) {
1559
1588
  const c = document.createElement("span");
1560
- c.className = "gengage-chat-ai-toppick-discount-badge", c.textContent = `%${re(n)}`, t.appendChild(c);
1589
+ c.className = "gengage-chat-ai-toppick-discount-badge", c.textContent = `%${se(n)}`, t.appendChild(c);
1561
1590
  }
1562
1591
  const i = a.imageUrl;
1563
1592
  if (i && K(i)) {
@@ -1566,25 +1595,25 @@ function Kt(o, e) {
1566
1595
  }
1567
1596
  const r = document.createElement("div");
1568
1597
  r.className = "gengage-chat-ai-toppick-body";
1569
- const s = we(o.role, e.i18n);
1598
+ const s = _e(o.role, e.i18n);
1570
1599
  if (s) {
1571
1600
  const c = document.createElement("div");
1572
1601
  c.className = "gengage-chat-ai-toppick-role", c.textContent = s, r.appendChild(c);
1573
1602
  }
1574
- const g = a.name;
1575
- if (g) {
1603
+ const l = a.name;
1604
+ if (l) {
1576
1605
  const c = document.createElement("div");
1577
- c.className = "gengage-chat-ai-toppick-name", c.textContent = g, r.appendChild(c);
1606
+ c.className = "gengage-chat-ai-toppick-name", c.textContent = l, r.appendChild(c);
1578
1607
  }
1579
1608
  if (o.reason) {
1580
1609
  const c = document.createElement("div");
1581
1610
  c.className = "gengage-chat-ai-toppick-reason", c.textContent = o.reason, r.appendChild(c);
1582
1611
  }
1583
- o.labels && o.labels.length > 0 && r.appendChild(ye(o.labels));
1584
- const d = a.price;
1585
- if (d) {
1612
+ o.labels && o.labels.length > 0 && r.appendChild(ke(o.labels));
1613
+ const g = a.price;
1614
+ if (g) {
1586
1615
  const c = document.createElement("div");
1587
- c.className = "gengage-chat-ai-toppick-price", c.textContent = F(d, e.pricing), r.appendChild(c);
1616
+ c.className = "gengage-chat-ai-toppick-price", c.textContent = F(g, e.pricing), r.appendChild(c);
1588
1617
  }
1589
1618
  if (t.appendChild(r), o.action) {
1590
1619
  const c = a.sku ?? null, h = document.createElement("div");
@@ -1596,7 +1625,7 @@ function Kt(o, e) {
1596
1625
  }
1597
1626
  return t;
1598
1627
  }
1599
- function ye(o) {
1628
+ function ke(o) {
1600
1629
  const e = document.createElement("div");
1601
1630
  e.className = "gengage-chat-ai-toppick-labels";
1602
1631
  for (const t of o) {
@@ -1605,25 +1634,25 @@ function ye(o) {
1605
1634
  }
1606
1635
  return e;
1607
1636
  }
1608
- function Yt(o, e) {
1637
+ function Qt(o, e) {
1609
1638
  const t = document.createElement("div");
1610
1639
  t.className = "gengage-chat-grounding-review";
1611
- const a = o.props ?? {}, n = a.title, i = a.reviewCount, r = a.action, s = e.i18n?.groundingReviewCta ?? "Yorumları Oku", g = document.createElement("span");
1612
- g.className = "gengage-chat-grounding-review-icon", g.textContent = "📋", t.appendChild(g);
1613
- const d = document.createElement("div");
1614
- d.className = "gengage-chat-grounding-review-body";
1640
+ const a = o.props ?? {}, n = a.title, i = a.reviewCount, r = a.action, s = e.i18n?.groundingReviewCta ?? "Yorumları Oku", l = document.createElement("span");
1641
+ l.className = "gengage-chat-grounding-review-icon", l.textContent = "📋", t.appendChild(l);
1642
+ const g = document.createElement("div");
1643
+ g.className = "gengage-chat-grounding-review-body";
1615
1644
  const c = document.createElement("div");
1616
- if (c.className = "gengage-chat-grounding-review-title", c.textContent = n ?? "Müşteri Yorumları", d.appendChild(c), i) {
1645
+ if (c.className = "gengage-chat-grounding-review-title", c.textContent = n ?? "Müşteri Yorumları", g.appendChild(c), i) {
1617
1646
  const m = document.createElement("div");
1618
1647
  m.className = "gengage-chat-grounding-review-subtitle";
1619
- const l = e.i18n?.groundingReviewSubtitle ?? "{count} yorum mevcut";
1620
- m.textContent = l.replace("{count}", i), d.appendChild(m);
1648
+ const d = e.i18n?.groundingReviewSubtitle ?? "{count} yorum mevcut";
1649
+ m.textContent = d.replace("{count}", i), g.appendChild(m);
1621
1650
  }
1622
- t.appendChild(d);
1651
+ t.appendChild(g);
1623
1652
  const h = document.createElement("span");
1624
1653
  return h.className = "gengage-chat-grounding-review-cta", h.textContent = `${s} →`, t.appendChild(h), r && (t.style.cursor = "pointer", t.addEventListener("click", () => e.onAction(r))), t;
1625
1654
  }
1626
- function Wt(o, e) {
1655
+ function Xt(o, e) {
1627
1656
  const t = document.createElement("div");
1628
1657
  t.className = "gengage-chat-grouping-cards";
1629
1658
  const a = o.props?.entries ?? [];
@@ -1631,27 +1660,27 @@ function Wt(o, e) {
1631
1660
  for (const n of a) {
1632
1661
  const i = document.createElement("div");
1633
1662
  if (i.className = "gengage-chat-grouping-card", i.style.cursor = "pointer", i.addEventListener("click", () => e.onAction(n.action)), n.image && K(n.image)) {
1634
- const d = document.createElement("img");
1635
- d.className = "gengage-chat-grouping-card-img", d.src = n.image, d.alt = n.name, d.width = 20, d.height = 20, i.appendChild(d);
1663
+ const g = document.createElement("img");
1664
+ g.className = "gengage-chat-grouping-card-img", g.src = n.image, g.alt = n.name, g.width = 20, g.height = 20, i.appendChild(g);
1636
1665
  }
1637
1666
  const r = document.createElement("div");
1638
1667
  r.className = "gengage-chat-grouping-card-body";
1639
1668
  const s = document.createElement("span");
1640
1669
  if (s.className = "gengage-chat-grouping-card-name", s.textContent = n.name, r.appendChild(s), n.description) {
1641
- const d = document.createElement("span");
1642
- d.className = "gengage-chat-grouping-card-desc", d.textContent = n.description, r.appendChild(d);
1670
+ const g = document.createElement("span");
1671
+ g.className = "gengage-chat-grouping-card-desc", g.textContent = n.description, r.appendChild(g);
1643
1672
  }
1644
1673
  if (n.labels && n.labels.length > 0) {
1645
- const d = document.createElement("span");
1646
- d.className = "gengage-chat-grouping-card-labels", d.textContent = n.labels.slice(0, 3).join(" · "), r.appendChild(d);
1674
+ const g = document.createElement("span");
1675
+ g.className = "gengage-chat-grouping-card-labels", g.textContent = n.labels.slice(0, 3).join(" · "), r.appendChild(g);
1647
1676
  }
1648
1677
  i.appendChild(r);
1649
- const g = document.createElement("span");
1650
- g.className = "gengage-chat-grouping-card-arrow", g.textContent = "↳", i.insertBefore(g, i.firstChild), t.appendChild(i);
1678
+ const l = document.createElement("span");
1679
+ l.className = "gengage-chat-grouping-card-arrow", l.textContent = "↳", i.insertBefore(l, i.firstChild), t.appendChild(i);
1651
1680
  }
1652
1681
  return t;
1653
1682
  }
1654
- function Qt(o, e) {
1683
+ function Jt(o, e) {
1655
1684
  const t = document.createElement("div");
1656
1685
  t.className = "gengage-chat-suggested-search-cards";
1657
1686
  const a = o.props?.entries ?? [];
@@ -1659,25 +1688,25 @@ function Qt(o, e) {
1659
1688
  for (const n of a) {
1660
1689
  const i = document.createElement("div");
1661
1690
  if (i.className = "gengage-chat-suggested-search-card", i.style.cursor = "pointer", i.addEventListener("click", () => e.onAction(n.action)), n.image && K(n.image)) {
1662
- const g = document.createElement("img");
1663
- g.className = "gengage-chat-suggested-search-card-img", g.src = n.image, g.alt = n.shortName, g.width = 40, g.height = 40, i.appendChild(g);
1691
+ const l = document.createElement("img");
1692
+ l.className = "gengage-chat-suggested-search-card-img", l.src = n.image, l.alt = n.shortName, l.width = 40, l.height = 40, i.appendChild(l);
1664
1693
  }
1665
1694
  const r = document.createElement("div");
1666
1695
  r.className = "gengage-chat-suggested-search-card-body";
1667
1696
  const s = document.createElement("div");
1668
1697
  if (s.className = "gengage-chat-suggested-search-card-name", s.textContent = n.shortName, r.appendChild(s), n.detailedMessage) {
1669
- const g = document.createElement("div");
1670
- g.className = "gengage-chat-suggested-search-card-desc", g.textContent = n.detailedMessage, r.appendChild(g);
1698
+ const l = document.createElement("div");
1699
+ l.className = "gengage-chat-suggested-search-card-desc", l.textContent = n.detailedMessage, r.appendChild(l);
1671
1700
  }
1672
1701
  if (n.whyDifferent) {
1673
- const g = document.createElement("div");
1674
- g.className = "gengage-chat-suggested-search-card-diff", g.textContent = n.whyDifferent, r.appendChild(g);
1702
+ const l = document.createElement("div");
1703
+ l.className = "gengage-chat-suggested-search-card-diff", l.textContent = n.whyDifferent, r.appendChild(l);
1675
1704
  }
1676
1705
  i.appendChild(r), t.appendChild(i);
1677
1706
  }
1678
1707
  return t;
1679
1708
  }
1680
- function Xt(o, e) {
1709
+ function Zt(o, e) {
1681
1710
  const t = document.createElement("button");
1682
1711
  t.className = "gengage-chat-comparison-floating-btn", t.type = "button";
1683
1712
  const a = e.i18n?.compareSelected ?? "Karşılaştır";
@@ -1689,7 +1718,7 @@ function Xt(o, e) {
1689
1718
  });
1690
1719
  }), t;
1691
1720
  }
1692
- function Jt(o) {
1721
+ function ea(o) {
1693
1722
  const e = document.createElement("div");
1694
1723
  e.className = "gengage-chat-pros-cons";
1695
1724
  const t = o.props?.productName;
@@ -1704,10 +1733,10 @@ function Jt(o) {
1704
1733
  for (const r of a) {
1705
1734
  const s = document.createElement("li");
1706
1735
  s.className = "gengage-chat-pros-cons-item";
1736
+ const l = document.createElement("span");
1737
+ l.className = "gengage-chat-pros-cons-icon gengage-chat-pros-cons-icon--pro", l.textContent = "✓", s.appendChild(l);
1707
1738
  const g = document.createElement("span");
1708
- g.className = "gengage-chat-pros-cons-icon gengage-chat-pros-cons-icon--pro", g.textContent = "✓", s.appendChild(g);
1709
- const d = document.createElement("span");
1710
- d.textContent = r, s.appendChild(d), i.appendChild(s);
1739
+ g.textContent = r, s.appendChild(g), i.appendChild(s);
1711
1740
  }
1712
1741
  e.appendChild(i);
1713
1742
  }
@@ -1717,56 +1746,56 @@ function Jt(o) {
1717
1746
  for (const r of n) {
1718
1747
  const s = document.createElement("li");
1719
1748
  s.className = "gengage-chat-pros-cons-item";
1749
+ const l = document.createElement("span");
1750
+ l.className = "gengage-chat-pros-cons-icon gengage-chat-pros-cons-icon--con", l.textContent = "✗", s.appendChild(l);
1720
1751
  const g = document.createElement("span");
1721
- g.className = "gengage-chat-pros-cons-icon gengage-chat-pros-cons-icon--con", g.textContent = "✗", s.appendChild(g);
1722
- const d = document.createElement("span");
1723
- d.textContent = r, s.appendChild(d), i.appendChild(s);
1752
+ g.textContent = r, s.appendChild(g), i.appendChild(s);
1724
1753
  }
1725
1754
  e.appendChild(i);
1726
1755
  }
1727
1756
  return e;
1728
1757
  }
1729
- function Zt(o, e) {
1758
+ function ta(o, e) {
1730
1759
  const t = o.props?.groups ?? [], a = o.props?.filterTags ?? [], n = document.createElement("div");
1731
1760
  if (n.className = "gengage-chat-categories", t.length === 0) return n;
1732
1761
  const i = document.createElement("div");
1733
1762
  i.className = "gengage-chat-categories-tabs", i.setAttribute("role", "tablist");
1734
- const r = [], s = [], g = (d) => {
1763
+ const r = [], s = [], l = (g) => {
1735
1764
  for (let c = 0; c < r.length; c++) {
1736
- const h = c === d;
1765
+ const h = c === g;
1737
1766
  r[c].classList.toggle("gengage-chat-categories-tab--active", h), r[c].setAttribute("aria-selected", String(h)), r[c].tabIndex = h ? 0 : -1, s[c].style.display = h ? "" : "none";
1738
1767
  }
1739
1768
  };
1740
- for (let d = 0; d < t.length; d++) {
1741
- const c = t[d], h = `gengage-cat-tab-${d}`, m = `gengage-cat-panel-${d}`, l = document.createElement("button");
1742
- l.className = "gengage-chat-categories-tab", l.type = "button", l.id = h, l.setAttribute("role", "tab"), l.setAttribute("aria-controls", m), l.setAttribute("aria-selected", String(d === 0)), l.tabIndex = d === 0 ? 0 : -1, d === 0 && l.classList.add("gengage-chat-categories-tab--active"), l.textContent = c.groupName, l.addEventListener("click", () => g(d)), l.addEventListener("keydown", (w) => {
1769
+ for (let g = 0; g < t.length; g++) {
1770
+ const c = t[g], h = `gengage-cat-tab-${g}`, m = `gengage-cat-panel-${g}`, d = document.createElement("button");
1771
+ d.className = "gengage-chat-categories-tab", d.type = "button", d.id = h, d.setAttribute("role", "tab"), d.setAttribute("aria-controls", m), d.setAttribute("aria-selected", String(g === 0)), d.tabIndex = g === 0 ? 0 : -1, g === 0 && d.classList.add("gengage-chat-categories-tab--active"), d.textContent = c.groupName, d.addEventListener("click", () => l(g)), d.addEventListener("keydown", (w) => {
1743
1772
  let b = -1;
1744
- w.key === "ArrowRight" || w.key === "ArrowDown" ? b = (d + 1) % t.length : w.key === "ArrowLeft" || w.key === "ArrowUp" ? b = (d - 1 + t.length) % t.length : w.key === "Home" ? b = 0 : w.key === "End" && (b = t.length - 1), b >= 0 && (w.preventDefault(), g(b), r[b].focus());
1745
- }), r.push(l), i.appendChild(l);
1773
+ w.key === "ArrowRight" || w.key === "ArrowDown" ? b = (g + 1) % t.length : w.key === "ArrowLeft" || w.key === "ArrowUp" ? b = (g - 1 + t.length) % t.length : w.key === "Home" ? b = 0 : w.key === "End" && (b = t.length - 1), b >= 0 && (w.preventDefault(), l(b), r[b].focus());
1774
+ }), r.push(d), i.appendChild(d);
1746
1775
  const v = document.createElement("div");
1747
- v.className = "gengage-chat-categories-grid", v.id = m, v.setAttribute("role", "tabpanel"), v.setAttribute("aria-labelledby", h), d !== 0 && (v.style.display = "none");
1776
+ v.className = "gengage-chat-categories-grid", v.id = m, v.setAttribute("role", "tabpanel"), v.setAttribute("aria-labelledby", h), g !== 0 && (v.style.display = "none");
1748
1777
  for (const w of c.products) {
1749
- const b = ea(w, e);
1778
+ const b = aa(w, e);
1750
1779
  v.appendChild(b);
1751
1780
  }
1752
1781
  s.push(v);
1753
1782
  }
1754
1783
  n.appendChild(i);
1755
- for (const d of s) n.appendChild(d);
1784
+ for (const g of s) n.appendChild(g);
1756
1785
  if (a.length > 0) {
1757
- const d = document.createElement("div");
1758
- d.className = "gengage-chat-categories-filter-tags";
1786
+ const g = document.createElement("div");
1787
+ g.className = "gengage-chat-categories-filter-tags";
1759
1788
  for (const c of a) {
1760
1789
  const h = document.createElement("button");
1761
1790
  h.className = "gengage-chat-categories-filter-tag", h.type = "button", h.textContent = c.title, c.action && h.addEventListener("click", () => {
1762
1791
  e.onAction(c.action);
1763
- }), d.appendChild(h);
1792
+ }), g.appendChild(h);
1764
1793
  }
1765
- n.appendChild(d);
1794
+ n.appendChild(g);
1766
1795
  }
1767
1796
  return n;
1768
1797
  }
1769
- function ea(o, e) {
1798
+ function aa(o, e) {
1770
1799
  const t = document.createElement("div");
1771
1800
  if (t.className = "gengage-chat-product-card", o.imageUrl && K(o.imageUrl)) {
1772
1801
  const i = document.createElement("img");
@@ -1783,7 +1812,7 @@ function ea(o, e) {
1783
1812
  e.onProductSelect?.(o);
1784
1813
  })), t;
1785
1814
  }
1786
- function ta(o, e) {
1815
+ function na(o, e) {
1787
1816
  const t = document.createElement("div");
1788
1817
  t.className = "gengage-chat-handoff-notice", t.setAttribute("role", "alert");
1789
1818
  const a = document.createElement("span");
@@ -1797,78 +1826,78 @@ function ta(o, e) {
1797
1826
  }
1798
1827
  return t;
1799
1828
  }
1800
- function aa(o, e) {
1829
+ function ia(o, e) {
1801
1830
  const t = o.props?.product ?? o.props, a = document.createElement("div");
1802
1831
  if (a.className = "gengage-chat-product-summary", !t) return a;
1803
- a.style.cursor = "pointer", a.addEventListener("click", (l) => {
1804
- l.target.closest("a") || e.onProductSelect?.(t);
1832
+ a.style.cursor = "pointer", a.addEventListener("click", (d) => {
1833
+ d.target.closest("a") || e.onProductSelect?.(t);
1805
1834
  });
1806
1835
  const n = t.imageUrl;
1807
1836
  if (n && G(n)) {
1808
- const l = document.createElement("div");
1809
- l.className = "gengage-chat-product-summary__image";
1837
+ const d = document.createElement("div");
1838
+ d.className = "gengage-chat-product-summary__image";
1810
1839
  const v = document.createElement("img");
1811
1840
  D(v, "src", n);
1812
1841
  const w = t.name;
1813
- w && (v.alt = w), Q(v), l.appendChild(v), a.appendChild(l);
1842
+ w && (v.alt = w), Q(v), d.appendChild(v), a.appendChild(d);
1814
1843
  }
1815
1844
  const i = document.createElement("div");
1816
1845
  i.className = "gengage-chat-product-summary__content";
1817
1846
  const r = t.brand, s = t.name;
1818
1847
  if (s) {
1819
- const l = document.createElement("div");
1820
- l.className = "gengage-chat-product-summary__name";
1848
+ const d = document.createElement("div");
1849
+ d.className = "gengage-chat-product-summary__name";
1821
1850
  const v = r && !s.toLowerCase().startsWith(r.toLowerCase());
1822
- l.textContent = v ? `${r} ${s}` : s, i.appendChild(l);
1851
+ d.textContent = v ? `${r} ${s}` : s, i.appendChild(d);
1823
1852
  }
1824
- const g = t.rating, d = t.reviewCount;
1825
- if (typeof g == "number" && Number.isFinite(g) && g > 0) {
1826
- const l = document.createElement("div");
1827
- if (l.className = "gengage-chat-product-summary__rating", l.textContent = fe(be(g)), typeof d == "number" && Number.isFinite(d)) {
1853
+ const l = t.rating, g = t.reviewCount;
1854
+ if (typeof l == "number" && Number.isFinite(l) && l > 0) {
1855
+ const d = document.createElement("div");
1856
+ if (d.className = "gengage-chat-product-summary__rating", d.textContent = xe(ve(l)), typeof g == "number" && Number.isFinite(g)) {
1828
1857
  const v = document.createElement("span");
1829
- v.className = "gengage-chat-product-summary__review-count", v.textContent = ` (${d})`, l.appendChild(v);
1858
+ v.className = "gengage-chat-product-summary__review-count", v.textContent = ` (${g})`, d.appendChild(v);
1830
1859
  }
1831
- i.appendChild(l);
1860
+ i.appendChild(d);
1832
1861
  }
1833
1862
  const c = t.price, h = t.originalPrice;
1834
1863
  if (c) {
1835
- const l = document.createElement("div");
1836
- if (l.className = "gengage-chat-product-summary__price", h && h !== c) {
1864
+ const d = document.createElement("div");
1865
+ if (d.className = "gengage-chat-product-summary__price", h && h !== c) {
1837
1866
  const w = document.createElement("span");
1838
- w.className = "gengage-chat-product-summary__price-original", w.textContent = F(h, e.pricing), l.appendChild(w), l.appendChild(document.createTextNode(" "));
1867
+ w.className = "gengage-chat-product-summary__price-original", w.textContent = F(h, e.pricing), d.appendChild(w), d.appendChild(document.createTextNode(" "));
1839
1868
  }
1840
1869
  const v = document.createElement("span");
1841
- v.className = "gengage-chat-product-summary__price-current", v.textContent = F(c, e.pricing), l.appendChild(v), i.appendChild(l);
1870
+ v.className = "gengage-chat-product-summary__price-current", v.textContent = F(c, e.pricing), d.appendChild(v), i.appendChild(d);
1842
1871
  }
1843
1872
  a.appendChild(i);
1844
1873
  const m = t.url;
1845
1874
  if (m && G(m)) {
1846
- const l = document.createElement("a");
1847
- l.className = "gengage-chat-product-summary__cta", D(l, "href", m), D(l, "target", "_blank"), D(l, "rel", "noopener noreferrer"), l.textContent = e.i18n?.productCtaLabel ?? "İncele", a.appendChild(l);
1875
+ const d = document.createElement("a");
1876
+ d.className = "gengage-chat-product-summary__cta", D(d, "href", m), D(d, "target", "_blank"), D(d, "rel", "noopener noreferrer"), d.textContent = e.i18n?.productCtaLabel ?? "İncele", a.appendChild(d);
1848
1877
  }
1849
1878
  return a;
1850
1879
  }
1851
- function _e() {
1880
+ function Ce() {
1852
1881
  return window.innerWidth < 768;
1853
1882
  }
1854
- const ke = {
1855
- ActionButtons: ({ element: o, context: e }) => oa(o, e),
1856
- ActionButton: ({ element: o, context: e }) => ra(o, e),
1857
- ProductCard: ({ element: o, context: e }) => sa(o, e),
1858
- ProductDetailsPanel: ({ element: o, context: e }) => ca(o, e),
1859
- ProductGrid: ({ element: o, spec: e, renderElement: t, context: a }) => da(o, e, t, a),
1860
- ReviewHighlights: ({ element: o, context: e }) => jt(o, { emptyReviewsMessage: e.i18n?.emptyReviewsMessage }),
1861
- ComparisonTable: ({ element: o, context: e }) => pa(o, e),
1862
- AITopPicks: ({ element: o, context: e }) => Gt(o, e),
1863
- GroundingReviewCard: ({ element: o, context: e }) => Yt(o, e),
1864
- AIGroupingCards: ({ element: o, context: e }) => Wt(o, e),
1865
- AISuggestedSearchCards: ({ element: o, context: e }) => Qt(o, e),
1866
- ProsAndCons: ({ element: o }) => Jt(o),
1867
- CategoriesContainer: ({ element: o, context: e }) => Zt(o, e),
1868
- HandoffNotice: ({ element: o, context: e }) => ta(o, e),
1869
- ProductSummaryCard: ({ element: o, context: e }) => aa(o, e),
1870
- Divider: ({ element: o }) => ha(o)
1871
- }, Ce = ({
1883
+ const Ee = {
1884
+ ActionButtons: ({ element: o, context: e }) => sa(o, e),
1885
+ ActionButton: ({ element: o, context: e }) => ca(o, e),
1886
+ ProductCard: ({ element: o, context: e }) => la(o, e),
1887
+ ProductDetailsPanel: ({ element: o, context: e }) => ga(o, e),
1888
+ ProductGrid: ({ element: o, spec: e, renderElement: t, context: a }) => ha(o, e, t, a),
1889
+ ReviewHighlights: ({ element: o, context: e }) => Gt(o, { emptyReviewsMessage: e.i18n?.emptyReviewsMessage }),
1890
+ ComparisonTable: ({ element: o, context: e }) => ua(o, e),
1891
+ AITopPicks: ({ element: o, context: e }) => Kt(o, e),
1892
+ GroundingReviewCard: ({ element: o, context: e }) => Qt(o, e),
1893
+ AIGroupingCards: ({ element: o, context: e }) => Xt(o, e),
1894
+ AISuggestedSearchCards: ({ element: o, context: e }) => Jt(o, e),
1895
+ ProsAndCons: ({ element: o }) => ea(o),
1896
+ CategoriesContainer: ({ element: o, context: e }) => ta(o, e),
1897
+ HandoffNotice: ({ element: o, context: e }) => na(o, e),
1898
+ ProductSummaryCard: ({ element: o, context: e }) => ia(o, e),
1899
+ Divider: ({ element: o }) => ma(o)
1900
+ }, Se = ({
1872
1901
  element: o,
1873
1902
  renderElement: e
1874
1903
  }) => {
@@ -1881,11 +1910,11 @@ const ke = {
1881
1910
  }
1882
1911
  return t;
1883
1912
  };
1884
- function na() {
1885
- return { ...ke };
1913
+ function oa() {
1914
+ return { ...Ee };
1886
1915
  }
1887
- function ia(o, e, t = ke, a = Ce) {
1888
- return Be({
1916
+ function ra(o, e, t = Ee, a = Se) {
1917
+ return Me({
1889
1918
  spec: o,
1890
1919
  context: e,
1891
1920
  registry: t,
@@ -1893,7 +1922,7 @@ function ia(o, e, t = ke, a = Ce) {
1893
1922
  unknownRenderer: a
1894
1923
  });
1895
1924
  }
1896
- function oa(o, e) {
1925
+ function sa(o, e) {
1897
1926
  const t = document.createElement("div");
1898
1927
  t.className = "gengage-chat-action-buttons";
1899
1928
  const a = o.props?.buttons;
@@ -1904,7 +1933,7 @@ function oa(o, e) {
1904
1933
  }
1905
1934
  return t;
1906
1935
  }
1907
- function ra(o, e) {
1936
+ function ca(o, e) {
1908
1937
  const t = document.createElement("button");
1909
1938
  t.className = "gengage-chat-action-btn";
1910
1939
  const a = o.props?.label;
@@ -1912,7 +1941,7 @@ function ra(o, e) {
1912
1941
  const n = o.props?.action;
1913
1942
  return n && t.addEventListener("click", () => e.onAction(n)), t;
1914
1943
  }
1915
- function sa(o, e) {
1944
+ function la(o, e) {
1916
1945
  const t = document.createElement("div");
1917
1946
  t.className = "gengage-chat-product-card";
1918
1947
  const a = o.props?.product ?? o.props;
@@ -1931,7 +1960,7 @@ function sa(o, e) {
1931
1960
  const k = a.discountPercent;
1932
1961
  if (typeof k == "number" && k > 0) {
1933
1962
  const f = document.createElement("span");
1934
- f.className = "gengage-chat-product-card-discount-badge", f.textContent = `%${re(k)}`, p.appendChild(f);
1963
+ f.className = "gengage-chat-product-card-discount-badge", f.textContent = `%${se(k)}`, p.appendChild(f);
1935
1964
  }
1936
1965
  const A = a.sku;
1937
1966
  if (A) {
@@ -1974,12 +2003,12 @@ function sa(o, e) {
1974
2003
  const p = document.createElement("div");
1975
2004
  p.className = "gengage-chat-product-card-name", p.textContent = s, i.appendChild(p);
1976
2005
  }
1977
- const g = a.rating, d = a.reviewCount;
1978
- if (typeof g == "number" && Number.isFinite(g)) {
2006
+ const l = a.rating, g = a.reviewCount;
2007
+ if (typeof l == "number" && Number.isFinite(l)) {
1979
2008
  const p = document.createElement("div");
1980
- if (p.className = "gengage-chat-product-card-rating", p.textContent = fe(g), typeof d == "number" && Number.isFinite(d)) {
2009
+ if (p.className = "gengage-chat-product-card-rating", p.textContent = xe(l), typeof g == "number" && Number.isFinite(g)) {
1981
2010
  const y = document.createElement("span");
1982
- y.className = "gengage-chat-product-card-review-count", y.textContent = ` (${d})`, p.appendChild(y);
2011
+ y.className = "gengage-chat-product-card-review-count", y.textContent = ` (${g})`, p.appendChild(y);
1983
2012
  }
1984
2013
  i.appendChild(p);
1985
2014
  }
@@ -2000,10 +2029,10 @@ function sa(o, e) {
2000
2029
  const y = document.createElement("span");
2001
2030
  y.textContent = F(c, e.pricing), p.appendChild(y), i.appendChild(p);
2002
2031
  }
2003
- const l = a.inStock;
2004
- if (typeof l == "boolean") {
2032
+ const d = a.inStock;
2033
+ if (typeof d == "boolean") {
2005
2034
  const p = document.createElement("div");
2006
- p.className = `gengage-chat-product-card-stock ${l ? "is-in-stock" : "is-out-of-stock"}`, p.textContent = l ? e.i18n?.inStockLabel ?? "Stokta" : e.i18n?.outOfStockLabel ?? "Tükendi", i.appendChild(p);
2035
+ p.className = `gengage-chat-product-card-stock ${d ? "is-in-stock" : "is-out-of-stock"}`, p.textContent = d ? e.i18n?.inStockLabel ?? "Stokta" : e.i18n?.outOfStockLabel ?? "Tükendi", i.appendChild(p);
2007
2036
  }
2008
2037
  const v = a.promotions;
2009
2038
  if (v && v.length > 0) {
@@ -2028,7 +2057,7 @@ function sa(o, e) {
2028
2057
  }
2029
2058
  const I = a.cartCode;
2030
2059
  if (I && b) {
2031
- const p = xe({
2060
+ const p = we({
2032
2061
  compact: !0,
2033
2062
  label: e.i18n?.addToCartButton ?? "Sepete Ekle",
2034
2063
  onSubmit: (y) => {
@@ -2051,7 +2080,7 @@ function sa(o, e) {
2051
2080
  }
2052
2081
  return t;
2053
2082
  }
2054
- function ca(o, e) {
2083
+ function ga(o, e) {
2055
2084
  const t = document.createElement("article");
2056
2085
  t.className = "gengage-chat-product-details-panel";
2057
2086
  const a = o.props?.product ?? o.props;
@@ -2088,8 +2117,8 @@ function ca(o, e) {
2088
2117
  ), f.addEventListener("touchend", (z) => {
2089
2118
  const H = z.changedTouches[0].clientX, R = M - H;
2090
2119
  if (Math.abs(R) < U) return;
2091
- const ae = P.querySelectorAll(".gengage-chat-product-gallery-thumb"), ne = R > 0 ? Math.min(E + 1, ae.length - 1) : Math.max(E - 1, 0);
2092
- ne !== E && ae[ne] && ae[ne].click();
2120
+ const ne = P.querySelectorAll(".gengage-chat-product-gallery-thumb"), ie = R > 0 ? Math.min(E + 1, ne.length - 1) : Math.max(E - 1, 0);
2121
+ ie !== E && ne[ie] && ne[ie].click();
2093
2122
  }), u.appendChild(P), r) {
2094
2123
  const z = document.createElement("button");
2095
2124
  z.className = "gengage-chat-find-similar-pill", z.type = "button", z.textContent = e.i18n?.findSimilarLabel ?? "Benzerlerini Bul", z.addEventListener("click", () => {
@@ -2121,15 +2150,15 @@ function ca(o, e) {
2121
2150
  }
2122
2151
  const s = document.createElement("div");
2123
2152
  s.className = "gengage-chat-product-details-content";
2124
- const g = a.name;
2125
- if (g) {
2153
+ const l = a.name;
2154
+ if (l) {
2126
2155
  const u = document.createElement("h3");
2127
- u.className = "gengage-chat-product-details-title", u.textContent = g, s.appendChild(u);
2156
+ u.className = "gengage-chat-product-details-title", u.textContent = l, s.appendChild(u);
2128
2157
  }
2129
- const d = a.rating, c = a.reviewCount;
2130
- if (typeof d == "number" && Number.isFinite(d)) {
2158
+ const g = a.rating, c = a.reviewCount;
2159
+ if (typeof g == "number" && Number.isFinite(g)) {
2131
2160
  const u = document.createElement("div");
2132
- if (u.className = "gengage-chat-product-details-rating", u.textContent = `★ ${be(d).toFixed(1)}`, typeof c == "number" && Number.isFinite(c)) {
2161
+ if (u.className = "gengage-chat-product-details-rating", u.textContent = `★ ${ve(g).toFixed(1)}`, typeof c == "number" && Number.isFinite(c)) {
2133
2162
  const f = document.createElement("span");
2134
2163
  f.className = "gengage-chat-product-details-review-count", f.textContent = ` (${c})`, u.appendChild(f);
2135
2164
  }
@@ -2212,7 +2241,7 @@ function ca(o, e) {
2212
2241
  }
2213
2242
  }
2214
2243
  if (I && N) {
2215
- const u = xe({
2244
+ const u = we({
2216
2245
  compact: !1,
2217
2246
  label: e.i18n?.addToCartButton ?? "Sepete Ekle",
2218
2247
  onSubmit: (f) => {
@@ -2249,9 +2278,9 @@ function ca(o, e) {
2249
2278
  }
2250
2279
  p.childElementCount > 0 && s.appendChild(p), t.appendChild(s);
2251
2280
  const k = a.description, A = a.specifications;
2252
- return (k || A) && t.appendChild(la(k, A, e)), t;
2281
+ return (k || A) && t.appendChild(da(k, A, e)), t;
2253
2282
  }
2254
- function la(o, e, t) {
2283
+ function da(o, e, t) {
2255
2284
  const a = document.createElement("div");
2256
2285
  a.className = "gengage-chat-product-detail-tabs";
2257
2286
  const n = document.createElement("div");
@@ -2260,37 +2289,37 @@ function la(o, e, t) {
2260
2289
  if (o) {
2261
2290
  const s = document.createElement("button");
2262
2291
  s.className = "gengage-chat-product-detail-tab gengage-chat-product-detail-tab--active", s.type = "button", s.textContent = t.i18n?.productInfoTab ?? "Ürün Bilgileri", n.appendChild(s);
2263
- const g = document.createElement("div");
2264
- g.className = "gengage-chat-product-detail-tab-panel", g.textContent = o, i.push(g);
2292
+ const l = document.createElement("div");
2293
+ l.className = "gengage-chat-product-detail-tab-panel", l.textContent = o, i.push(l);
2265
2294
  }
2266
2295
  if (e) {
2267
2296
  const s = document.createElement("button");
2268
2297
  s.className = `gengage-chat-product-detail-tab${o ? "" : " gengage-chat-product-detail-tab--active"}`, s.type = "button", s.textContent = t.i18n?.specificationsTab ?? "Teknik Özellikler", n.appendChild(s);
2269
- const g = document.createElement("div");
2270
- g.className = "gengage-chat-product-detail-tab-panel", o && (g.style.display = "none");
2271
- const d = document.createElement("table");
2272
- d.className = "gengage-chat-product-specs-table";
2298
+ const l = document.createElement("div");
2299
+ l.className = "gengage-chat-product-detail-tab-panel", o && (l.style.display = "none");
2300
+ const g = document.createElement("table");
2301
+ g.className = "gengage-chat-product-specs-table";
2273
2302
  const c = Array.isArray(e) ? e : Object.entries(e).map(([h, m]) => ({ key: h, value: m }));
2274
2303
  for (const h of c) {
2275
- const m = document.createElement("tr"), l = document.createElement("td");
2276
- l.className = "gengage-chat-product-specs-key", l.textContent = h.key;
2304
+ const m = document.createElement("tr"), d = document.createElement("td");
2305
+ d.className = "gengage-chat-product-specs-key", d.textContent = h.key;
2277
2306
  const v = document.createElement("td");
2278
- v.className = "gengage-chat-product-specs-value", v.textContent = h.value, m.appendChild(l), m.appendChild(v), d.appendChild(m);
2307
+ v.className = "gengage-chat-product-specs-value", v.textContent = h.value, m.appendChild(d), m.appendChild(v), g.appendChild(m);
2279
2308
  }
2280
- g.appendChild(d), i.push(g);
2309
+ l.appendChild(g), i.push(l);
2281
2310
  }
2282
2311
  const r = n.querySelectorAll(".gengage-chat-product-detail-tab");
2283
- r.forEach((s, g) => {
2312
+ r.forEach((s, l) => {
2284
2313
  s.addEventListener("click", () => {
2285
- r.forEach((d) => d.classList.remove("gengage-chat-product-detail-tab--active")), s.classList.add("gengage-chat-product-detail-tab--active"), i.forEach((d, c) => {
2286
- d.style.display = c === g ? "" : "none";
2314
+ r.forEach((g) => g.classList.remove("gengage-chat-product-detail-tab--active")), s.classList.add("gengage-chat-product-detail-tab--active"), i.forEach((g, c) => {
2315
+ g.style.display = c === l ? "" : "none";
2287
2316
  });
2288
2317
  });
2289
2318
  }), a.appendChild(n);
2290
2319
  for (const s of i) a.appendChild(s);
2291
2320
  return a;
2292
2321
  }
2293
- function Ee(o, e, t) {
2322
+ function Te(o, e, t) {
2294
2323
  if (!t || t.type === "related") return o;
2295
2324
  const a = o.map((n) => {
2296
2325
  const r = e.elements[n]?.props?.product, s = r ? Number(r.price) : NaN;
@@ -2298,8 +2327,8 @@ function Ee(o, e, t) {
2298
2327
  });
2299
2328
  return a.sort((n, i) => n.price === 1 / 0 && i.price === 1 / 0 ? 0 : n.price === 1 / 0 ? 1 : i.price === 1 / 0 ? -1 : t.direction === "desc" ? i.price - n.price : n.price - i.price), a.map((n) => n.id);
2300
2329
  }
2301
- function ga(o, e, t, a) {
2302
- const n = Ee(e, t, a), i = /* @__PURE__ */ new Map();
2330
+ function pa(o, e, t, a) {
2331
+ const n = Te(e, t, a), i = /* @__PURE__ */ new Map();
2303
2332
  for (const r of Array.from(o.children)) {
2304
2333
  const s = r.dataset.elementId;
2305
2334
  s && i.set(s, r);
@@ -2309,56 +2338,56 @@ function ga(o, e, t, a) {
2309
2338
  s && o.appendChild(s);
2310
2339
  }
2311
2340
  }
2312
- function da(o, e, t, a) {
2341
+ function ha(o, e, t, a) {
2313
2342
  const n = document.createElement("div");
2314
2343
  n.className = "gengage-chat-product-grid-wrapper";
2315
2344
  const i = o.children ?? [];
2316
2345
  if (i.length > 1 && a?.onSortChange) {
2317
- const d = document.createElement("div");
2318
- d.className = "gengage-chat-product-sort-toolbar";
2346
+ const g = document.createElement("div");
2347
+ g.className = "gengage-chat-product-sort-toolbar";
2319
2348
  const c = a.productSort ?? { type: "related" }, h = [
2320
2349
  { label: a.i18n?.sortRelated ?? "Önerilen", sortState: { type: "related" } },
2321
2350
  { label: a.i18n?.sortPriceAsc ?? "Fiyat ↑", sortState: { type: "price", direction: "asc" } },
2322
2351
  { label: a.i18n?.sortPriceDesc ?? "Fiyat ↓", sortState: { type: "price", direction: "desc" } }
2323
2352
  ];
2324
2353
  for (const m of h) {
2325
- const l = document.createElement("button");
2326
- l.className = "gengage-chat-product-sort-btn", l.type = "button", c.type === m.sortState.type && c.direction === m.sortState.direction && l.classList.add("gengage-chat-product-sort-btn--active"), l.textContent = m.label, l.addEventListener("click", () => {
2327
- a.onSortChange?.(m.sortState), ga(r, i, e, m.sortState), d.querySelectorAll(".gengage-chat-product-sort-btn").forEach((w) => w.classList.remove("gengage-chat-product-sort-btn--active")), l.classList.add("gengage-chat-product-sort-btn--active");
2328
- }), d.appendChild(l);
2354
+ const d = document.createElement("button");
2355
+ d.className = "gengage-chat-product-sort-btn", d.type = "button", c.type === m.sortState.type && c.direction === m.sortState.direction && d.classList.add("gengage-chat-product-sort-btn--active"), d.textContent = m.label, d.addEventListener("click", () => {
2356
+ a.onSortChange?.(m.sortState), pa(r, i, e, m.sortState), g.querySelectorAll(".gengage-chat-product-sort-btn").forEach((w) => w.classList.remove("gengage-chat-product-sort-btn--active")), d.classList.add("gengage-chat-product-sort-btn--active");
2357
+ }), g.appendChild(d);
2329
2358
  }
2330
2359
  if (a.onToggleComparisonSku) {
2331
2360
  const m = document.createElement("div");
2332
- m.className = "gengage-chat-product-sort-separator", d.appendChild(m);
2333
- const l = document.createElement("button");
2334
- l.className = "gengage-chat-comparison-toggle-btn", l.type = "button", a.comparisonSelectMode && l.classList.add("gengage-chat-comparison-toggle-btn--active"), l.textContent = a.i18n?.compareSelected ?? "Karşılaştır", l.addEventListener("click", () => {
2361
+ m.className = "gengage-chat-product-sort-separator", g.appendChild(m);
2362
+ const d = document.createElement("button");
2363
+ d.className = "gengage-chat-comparison-toggle-btn", d.type = "button", a.comparisonSelectMode && d.classList.add("gengage-chat-comparison-toggle-btn--active"), d.textContent = a.i18n?.compareSelected ?? "Karşılaştır", d.addEventListener("click", () => {
2335
2364
  a.onToggleComparisonSku?.("");
2336
- }), d.appendChild(l);
2365
+ }), g.appendChild(d);
2337
2366
  }
2338
- n.appendChild(d);
2367
+ n.appendChild(g);
2339
2368
  }
2340
2369
  const r = document.createElement("div");
2341
2370
  r.className = "gengage-chat-product-grid";
2342
- const s = Ee(i, e, a?.productSort);
2343
- for (const d of s) {
2344
- if (!e.elements[d]) continue;
2345
- const c = t(d);
2346
- c && (c.dataset.elementId = d, r.appendChild(c));
2347
- }
2348
- if (_e() && r.classList.add("gengage-chat-product-grid--mobile"), n.appendChild(r), o.props?.endOfList !== !0 && i.length > 0) {
2349
- const d = document.createElement("button");
2350
- d.className = "gengage-chat-product-grid-view-more", d.type = "button", d.textContent = a?.i18n?.viewMoreLabel ?? "Daha Fazla Göster", d.addEventListener("click", () => {
2371
+ const s = Te(i, e, a?.productSort);
2372
+ for (const g of s) {
2373
+ if (!e.elements[g]) continue;
2374
+ const c = t(g);
2375
+ c && (c.dataset.elementId = g, r.appendChild(c));
2376
+ }
2377
+ if (Ce() && r.classList.add("gengage-chat-product-grid--mobile"), n.appendChild(r), o.props?.endOfList !== !0 && i.length > 0) {
2378
+ const g = document.createElement("button");
2379
+ g.className = "gengage-chat-product-grid-view-more", g.type = "button", g.textContent = a?.i18n?.viewMoreLabel ?? "Daha Fazla Göster", g.addEventListener("click", () => {
2351
2380
  a?.onAction({ title: "More", type: "moreProductList", payload: {} });
2352
- }), n.appendChild(d);
2381
+ }), n.appendChild(g);
2353
2382
  }
2354
2383
  if (a?.comparisonSelectMode && a.comparisonSelectedSkus && a.comparisonSelectedSkus.length >= 2) {
2355
- const d = Xt(a.comparisonSelectedSkus, a);
2356
- n.appendChild(d);
2384
+ const g = Zt(a.comparisonSelectedSkus, a);
2385
+ n.appendChild(g);
2357
2386
  }
2358
2387
  return n;
2359
2388
  }
2360
- function pa(o, e) {
2361
- const t = o.props ?? {}, a = t.keyDifferencesHtml, n = t.recommended, i = t.products ?? [], r = t.attributes ?? [], s = t.highlights ?? [], g = t.specialCases, d = t.recommendedText, c = t.winnerHits, h = t.productActions;
2389
+ function ua(o, e) {
2390
+ const t = o.props ?? {}, a = t.keyDifferencesHtml, n = t.recommended, i = t.products ?? [], r = t.attributes ?? [], s = t.highlights ?? [], l = t.specialCases, g = t.recommendedText, c = t.winnerHits, h = t.productActions;
2362
2391
  if (!n)
2363
2392
  return document.createElement("div");
2364
2393
  const m = {
@@ -2366,12 +2395,12 @@ function pa(o, e) {
2366
2395
  products: i,
2367
2396
  attributes: r,
2368
2397
  highlights: s,
2369
- specialCases: g,
2398
+ specialCases: l,
2370
2399
  onProductClick: (v) => {
2371
2400
  e.onProductClick?.({ sku: v, url: "" });
2372
2401
  }
2373
2402
  };
2374
- d !== void 0 && (m.recommendedText = d), c !== void 0 && (m.winnerHits = c), h !== void 0 && (m.productActions = h), a !== void 0 && (m.keyDifferencesHtml = a), e.i18n && (m.i18n = {
2403
+ g !== void 0 && (m.recommendedText = g), c !== void 0 && (m.winnerHits = c), h !== void 0 && (m.productActions = h), a !== void 0 && (m.keyDifferencesHtml = a), e.i18n && (m.i18n = {
2375
2404
  comparisonHeading: e.i18n.panelTitleComparisonResults,
2376
2405
  recommendedChoiceLabel: e.i18n.recommendedChoiceLabel,
2377
2406
  highlightsLabel: e.i18n.highlightsLabel,
@@ -2379,10 +2408,10 @@ function pa(o, e) {
2379
2408
  specialCasesLabel: e.i18n.specialCasesLabel,
2380
2409
  addToCartButton: e.i18n.addToCartButton
2381
2410
  });
2382
- const l = Ot(m);
2383
- return _e() && l.classList.add("gengage-chat-comparison--mobile"), l;
2411
+ const d = jt(m);
2412
+ return Ce() && d.classList.add("gengage-chat-comparison--mobile"), d;
2384
2413
  }
2385
- function ha(o) {
2414
+ function ma(o) {
2386
2415
  const e = document.createElement("hr");
2387
2416
  e.className = "gengage-chat-divider";
2388
2417
  const t = o.props?.label;
@@ -2394,7 +2423,7 @@ function ha(o) {
2394
2423
  }
2395
2424
  return e;
2396
2425
  }
2397
- const ua = /* @__PURE__ */ new Set([
2426
+ const fa = /* @__PURE__ */ new Set([
2398
2427
  "P",
2399
2428
  "DIV",
2400
2429
  "H1",
@@ -2417,57 +2446,57 @@ const ua = /* @__PURE__ */ new Set([
2417
2446
  "DT",
2418
2447
  "DD"
2419
2448
  ]);
2420
- function ma(o) {
2449
+ function ba(o) {
2421
2450
  const e = [];
2422
2451
  let t = [];
2423
2452
  for (const a of o)
2424
- a.nodeType === Node.ELEMENT_NODE && ua.has(a.tagName) ? (t.length > 0 && (e.push(t), t = []), e.push([a])) : t.push(a);
2453
+ a.nodeType === Node.ELEMENT_NODE && fa.has(a.tagName) ? (t.length > 0 && (e.push(t), t = []), e.push([a])) : t.push(a);
2425
2454
  return t.length > 0 && e.push(t), e;
2426
2455
  }
2427
- function fa(o) {
2456
+ function xa(o) {
2428
2457
  for (const e of o)
2429
2458
  for (const t of e)
2430
2459
  if (t.nodeType === Node.ELEMENT_NODE && (t.tagName === "TABLE" || t.querySelector?.("table")))
2431
2460
  return !0;
2432
2461
  return !1;
2433
2462
  }
2434
- function ba() {
2463
+ function va() {
2435
2464
  return typeof window > "u" || typeof window.matchMedia != "function" ? !1 : window.matchMedia("(prefers-reduced-motion: reduce)").matches;
2436
2465
  }
2437
- function xa(o) {
2466
+ function wa(o) {
2438
2467
  const { container: e, html: t, delayMs: a = 30, onTick: n, onComplete: i } = o, r = document.createElement("template");
2439
2468
  r.innerHTML = t;
2440
- const s = ma(r.content.childNodes);
2441
- if (ba() || s.length <= 1 || fa(s))
2469
+ const s = ba(r.content.childNodes);
2470
+ if (va() || s.length <= 1 || xa(s))
2442
2471
  return e.innerHTML = t, i?.(), { complete() {
2443
2472
  }, cancel() {
2444
2473
  }, isRunning: !1 };
2445
2474
  e.innerHTML = "";
2446
- let g = 0, d = null, c = !0;
2475
+ let l = 0, g = null, c = !0;
2447
2476
  function h() {
2448
- if (!c || g >= s.length) {
2477
+ if (!c || l >= s.length) {
2449
2478
  c = !1, i?.();
2450
2479
  return;
2451
2480
  }
2452
- const m = s[g], l = document.createElement("span");
2453
- l.className = "gengage-chat-typewriter-block";
2481
+ const m = s[l], d = document.createElement("span");
2482
+ d.className = "gengage-chat-typewriter-block";
2454
2483
  for (const v of m)
2455
- l.appendChild(v.cloneNode(!0));
2456
- e.appendChild(l), g++, n?.(), g < s.length ? d = setTimeout(h, a) : (c = !1, i?.());
2484
+ d.appendChild(v.cloneNode(!0));
2485
+ e.appendChild(d), l++, n?.(), l < s.length ? g = setTimeout(h, a) : (c = !1, i?.());
2457
2486
  }
2458
2487
  return h(), {
2459
2488
  complete() {
2460
- c && (d !== null && clearTimeout(d), c = !1, e.innerHTML = t, i?.());
2489
+ c && (g !== null && clearTimeout(g), c = !1, e.innerHTML = t, i?.());
2461
2490
  },
2462
2491
  cancel() {
2463
- d !== null && clearTimeout(d), c = !1;
2492
+ g !== null && clearTimeout(g), c = !1;
2464
2493
  },
2465
2494
  get isRunning() {
2466
2495
  return c;
2467
2496
  }
2468
2497
  };
2469
2498
  }
2470
- function va(o) {
2499
+ function ya(o) {
2471
2500
  const { container: e, mentions: t, onProductClick: a } = o;
2472
2501
  if (t.length === 0) return;
2473
2502
  const n = /* @__PURE__ */ new Map();
@@ -2476,37 +2505,37 @@ function va(o) {
2476
2505
  if (n.size !== 0)
2477
2506
  for (const [i, r] of n) {
2478
2507
  const s = document.createTreeWalker(e, NodeFilter.SHOW_TEXT);
2479
- let g = s.nextNode(), d = !1;
2480
- for (; g && !d; ) {
2481
- const c = g.textContent ?? "", h = c.toLowerCase().indexOf(i);
2508
+ let l = s.nextNode(), g = !1;
2509
+ for (; l && !g; ) {
2510
+ const c = l.textContent ?? "", h = c.toLowerCase().indexOf(i);
2482
2511
  if (h === -1) {
2483
- g = s.nextNode();
2512
+ l = s.nextNode();
2484
2513
  continue;
2485
2514
  }
2486
- const m = c.slice(0, h), l = c.slice(h, h + r.short_name.length), v = c.slice(h + r.short_name.length), w = g.parentNode;
2515
+ const m = c.slice(0, h), d = c.slice(h, h + r.short_name.length), v = c.slice(h + r.short_name.length), w = l.parentNode;
2487
2516
  if (!w) {
2488
- g = s.nextNode();
2517
+ l = s.nextNode();
2489
2518
  continue;
2490
2519
  }
2491
2520
  const b = document.createElement("a");
2492
- b.className = "gengage-product-mention", b.textContent = l, b.href = "#", b.addEventListener("click", (N) => {
2521
+ b.className = "gengage-product-mention", b.textContent = d, b.href = "#", b.addEventListener("click", (N) => {
2493
2522
  N.preventDefault(), a(r.sku);
2494
- }), m && w.insertBefore(document.createTextNode(m), g), w.insertBefore(b, g), v && w.insertBefore(document.createTextNode(v), g), w.removeChild(g), d = !0;
2523
+ }), m && w.insertBefore(document.createTextNode(m), l), w.insertBefore(b, l), v && w.insertBefore(document.createTextNode(v), l), w.removeChild(l), g = !0;
2495
2524
  }
2496
2525
  }
2497
2526
  }
2498
- const wa = /* @__PURE__ */ new Set(["search", "info", "review", "similar"]), ya = /* @__PURE__ */ new Set([
2527
+ const _a = /* @__PURE__ */ new Set(["search", "info", "review", "similar"]), ka = /* @__PURE__ */ new Set([
2499
2528
  "quickAnswer",
2500
2529
  "reviewSummary",
2501
2530
  "searchDiscovery",
2502
2531
  "launchDiscovery",
2503
2532
  "exploreTogetherV2"
2504
2533
  ]);
2505
- function _a(o) {
2506
- return !!(o.icon && wa.has(o.icon) || o.action?.type && ya.has(o.action.type));
2534
+ function Ca(o) {
2535
+ return !!(o.icon && _a.has(o.icon) || o.action?.type && ka.has(o.action.type));
2507
2536
  }
2508
- const Se = "gengage_choice_prompter_dismissed";
2509
- function ka(o) {
2537
+ const Ie = "gengage_choice_prompter_dismissed";
2538
+ function Ea(o) {
2510
2539
  const e = document.createElement("div");
2511
2540
  e.className = "gengage-chat-choice-prompter";
2512
2541
  const t = document.createElement("div");
@@ -2515,27 +2544,27 @@ function ka(o) {
2515
2544
  a.className = "gengage-chat-choice-prompter-suggestion", a.textContent = o.suggestion, e.appendChild(a);
2516
2545
  const n = document.createElement("button");
2517
2546
  n.type = "button", n.className = "gengage-chat-choice-prompter-cta", n.textContent = o.ctaLabel, n.addEventListener("click", () => {
2518
- de(), e.remove(), o.onCtaClick();
2547
+ pe(), e.remove(), o.onCtaClick();
2519
2548
  }), e.appendChild(n);
2520
2549
  const i = document.createElement("button");
2521
2550
  return i.type = "button", i.className = "gengage-chat-choice-prompter-dismiss", i.textContent = "×", i.setAttribute("aria-label", "Dismiss"), i.addEventListener("click", () => {
2522
- de(), e.remove(), o.onDismiss?.();
2551
+ pe(), e.remove(), o.onDismiss?.();
2523
2552
  }), e.appendChild(i), e;
2524
2553
  }
2525
- function Ca() {
2554
+ function Sa() {
2526
2555
  try {
2527
- return sessionStorage.getItem(Se) === "1";
2556
+ return sessionStorage.getItem(Ie) === "1";
2528
2557
  } catch {
2529
2558
  return !1;
2530
2559
  }
2531
2560
  }
2532
- function de() {
2561
+ function pe() {
2533
2562
  try {
2534
- sessionStorage.setItem(Se, "1");
2563
+ sessionStorage.setItem(Ie, "1");
2535
2564
  } catch {
2536
2565
  }
2537
2566
  }
2538
- const Ea = "gengage_assistant", Sa = 3, Y = "sessions", q = "context", V = "payload", j = "favorites";
2567
+ const Ta = "gengage_assistant", Ia = 3, W = "sessions", q = "context", V = "payload", j = "favorites";
2539
2568
  function ee(o) {
2540
2569
  return new Promise((e, t) => {
2541
2570
  o.onsuccess = () => e(o.result), o.onerror = () => t(o.error);
@@ -2546,8 +2575,8 @@ function J(o) {
2546
2575
  o.oncomplete = () => e(), o.onerror = () => t(o.error), o.onabort = () => t(o.error ?? new DOMException("Transaction aborted"));
2547
2576
  });
2548
2577
  }
2549
- class Ta {
2550
- constructor(e = Ea, t = Sa) {
2578
+ class La {
2579
+ constructor(e = Ta, t = Ia) {
2551
2580
  this._db = null, this._dbName = e, this._version = t;
2552
2581
  }
2553
2582
  // -------------------------------------------------------------------------
@@ -2558,9 +2587,9 @@ class Ta {
2558
2587
  const a = indexedDB.open(this._dbName, this._version);
2559
2588
  a.onupgradeneeded = (n) => {
2560
2589
  const i = a.result, r = n.oldVersion;
2561
- r < 1 && (i.createObjectStore(Y, { keyPath: ["userId", "appId", "sessionId"] }), i.createObjectStore(q, { keyPath: ["sessionId", "threadId"] }), i.createObjectStore(V, {
2590
+ r < 1 && (i.createObjectStore(W, { keyPath: ["userId", "appId", "sessionId"] }), i.createObjectStore(q, { keyPath: ["sessionId", "threadId"] }), i.createObjectStore(V, {
2562
2591
  keyPath: ["threadId", "messageId"]
2563
- }).createIndex("threadId", "threadId", { unique: !1 }), i.createObjectStore(j, { keyPath: ["userId", "appId", "sku"] })), r >= 1 && r < 2 && (i.objectStoreNames.contains(Y) && i.deleteObjectStore(Y), i.objectStoreNames.contains(V) && i.deleteObjectStore(V), i.createObjectStore(Y, { keyPath: ["userId", "appId", "sessionId"] }), i.createObjectStore(V, {
2592
+ }).createIndex("threadId", "threadId", { unique: !1 }), i.createObjectStore(j, { keyPath: ["userId", "appId", "sku"] })), r >= 1 && r < 2 && (i.objectStoreNames.contains(W) && i.deleteObjectStore(W), i.objectStoreNames.contains(V) && i.deleteObjectStore(V), i.createObjectStore(W, { keyPath: ["userId", "appId", "sessionId"] }), i.createObjectStore(V, {
2564
2593
  keyPath: ["threadId", "messageId"]
2565
2594
  }).createIndex("threadId", "threadId", { unique: !1 }), i.objectStoreNames.contains(q) || i.createObjectStore(q, { keyPath: ["sessionId", "threadId"] })), r < 3 && (i.objectStoreNames.contains(j) || i.createObjectStore(j, { keyPath: ["userId", "appId", "sku"] }));
2566
2595
  }, a.onsuccess = () => {
@@ -2575,12 +2604,12 @@ class Ta {
2575
2604
  // Sessions
2576
2605
  // -------------------------------------------------------------------------
2577
2606
  async saveSession(e) {
2578
- const a = this._requireDb().transaction(Y, "readwrite");
2579
- a.objectStore(Y).put(e), await J(a);
2607
+ const a = this._requireDb().transaction(W, "readwrite");
2608
+ a.objectStore(W).put(e), await J(a);
2580
2609
  }
2581
2610
  async loadSession(e, t, a) {
2582
- const i = this._requireDb().transaction(Y, "readonly");
2583
- return await ee(i.objectStore(Y).get([e, t, a])) ?? null;
2611
+ const i = this._requireDb().transaction(W, "readonly");
2612
+ return await ee(i.objectStore(W).get([e, t, a])) ?? null;
2584
2613
  }
2585
2614
  // -------------------------------------------------------------------------
2586
2615
  // Context (compound key: [sessionId, threadId])
@@ -2602,21 +2631,21 @@ class Ta {
2602
2631
  */
2603
2632
  async deleteContextsAfterThread(e, t) {
2604
2633
  const n = this._requireDb().transaction(q, "readwrite"), r = n.objectStore(q).openCursor();
2605
- await new Promise((s, g) => {
2634
+ await new Promise((s, l) => {
2606
2635
  r.onsuccess = () => {
2607
- const d = r.result;
2608
- if (!d) {
2636
+ const g = r.result;
2637
+ if (!g) {
2609
2638
  s();
2610
2639
  return;
2611
2640
  }
2612
- const c = d.value;
2641
+ const c = g.value;
2613
2642
  if (c.sessionId === e && c.threadId > t)
2614
2643
  try {
2615
- d.delete();
2644
+ g.delete();
2616
2645
  } catch {
2617
2646
  }
2618
- d.continue();
2619
- }, r.onerror = () => g(r.error);
2647
+ g.continue();
2648
+ }, r.onerror = () => l(r.error);
2620
2649
  }), await J(n);
2621
2650
  }
2622
2651
  /**
@@ -2626,11 +2655,11 @@ class Ta {
2626
2655
  async loadLatestContext(e) {
2627
2656
  const n = this._requireDb().transaction(q, "readonly").objectStore(q), i = IDBKeyRange.bound([e, ""], [e, "￿"]);
2628
2657
  return new Promise((r, s) => {
2629
- const g = n.openCursor(i, "prev");
2630
- g.onsuccess = () => {
2631
- const d = g.result;
2632
- r(d ? d.value : null);
2633
- }, g.onerror = () => s(g.error);
2658
+ const l = n.openCursor(i, "prev");
2659
+ l.onsuccess = () => {
2660
+ const g = l.result;
2661
+ r(g ? g.value : null);
2662
+ }, l.onerror = () => s(l.error);
2634
2663
  });
2635
2664
  }
2636
2665
  // -------------------------------------------------------------------------
@@ -2647,15 +2676,15 @@ class Ta {
2647
2676
  async loadPayloadsByThread(e) {
2648
2677
  const n = this._requireDb().transaction(V, "readonly").objectStore(V).index("threadId"), i = [];
2649
2678
  return new Promise((r, s) => {
2650
- const g = n.openCursor(IDBKeyRange.only(e));
2651
- g.onsuccess = () => {
2652
- const d = g.result;
2653
- if (!d) {
2679
+ const l = n.openCursor(IDBKeyRange.only(e));
2680
+ l.onsuccess = () => {
2681
+ const g = l.result;
2682
+ if (!g) {
2654
2683
  r(i);
2655
2684
  return;
2656
2685
  }
2657
- i.push(d.value), d.continue();
2658
- }, g.onerror = () => s(g.error);
2686
+ i.push(g.value), g.continue();
2687
+ }, l.onerror = () => s(l.error);
2659
2688
  });
2660
2689
  }
2661
2690
  // -------------------------------------------------------------------------
@@ -2686,16 +2715,16 @@ class Ta {
2686
2715
  return this._db;
2687
2716
  }
2688
2717
  }
2689
- const Ia = [
2718
+ const Na = [
2690
2719
  "comparisonTable",
2691
2720
  "groupList",
2692
2721
  "productDetailsSimilars",
2693
2722
  "productList"
2694
2723
  ];
2695
- class La {
2724
+ class Aa {
2696
2725
  constructor(e) {
2697
2726
  this._lockCount = 1, this._hiddenByUser = !1, this._lastPanelContentType = null, this._chatShown = !1, this._isFavoritesMode = !1, this._lastExtended = !1, this._onChange = e.onChange;
2698
- const t = new Set(Ia);
2727
+ const t = new Set(Na);
2699
2728
  e.productDetailsInPanel && t.add("productDetails"), this._panelContentTypes = t;
2700
2729
  }
2701
2730
  get isExtended() {
@@ -2724,7 +2753,7 @@ class La {
2724
2753
  e !== this._lastExtended && (this._lastExtended = e, this._onChange(e));
2725
2754
  }
2726
2755
  }
2727
- class Na {
2756
+ class Pa {
2728
2757
  constructor(e) {
2729
2758
  this.deps = e, this.snapshots = /* @__PURE__ */ new Map(), this.snapshotTypes = /* @__PURE__ */ new Map(), this.activePanelMessageId = null, this.currentType = null, this.threads = [];
2730
2759
  }
@@ -2746,7 +2775,7 @@ class Na {
2746
2775
  * the panel content that was active when that message was received.
2747
2776
  */
2748
2777
  attachClickHandler(e) {
2749
- const a = this.deps.shadow()?.querySelector(`[data-message-id="${e}"]`);
2778
+ const a = this.deps.shadow()?.querySelector(`[data-message-id="${CSS.escape(e)}"]`);
2750
2779
  a && (a.style.cursor = "pointer", a.addEventListener("click", () => this.restoreForMessage(e)));
2751
2780
  }
2752
2781
  /**
@@ -2759,7 +2788,7 @@ class Na {
2759
2788
  const t = this.snapshots.get(e);
2760
2789
  if (!t) return !1;
2761
2790
  const a = this.deps.shadow(), n = this.deps.drawer();
2762
- this.activePanelMessageId && a?.querySelector(`[data-message-id="${this.activePanelMessageId}"]`)?.classList.remove("gengage-chat-bubble--active"), a?.querySelector(`[data-message-id="${e}"]`)?.classList.add("gengage-chat-bubble--active"), this.activePanelMessageId = e, n?.setPanelContent(t.cloneNode(!0));
2791
+ this.activePanelMessageId && a?.querySelector(`[data-message-id="${CSS.escape(this.activePanelMessageId)}"]`)?.classList.remove("gengage-chat-bubble--active"), a?.querySelector(`[data-message-id="${CSS.escape(e)}"]`)?.classList.add("gengage-chat-bubble--active"), this.activePanelMessageId = e, n?.setPanelContent(t.cloneNode(!0));
2763
2792
  const r = this.snapshotTypes.get(e);
2764
2793
  return r && (this.currentType = r, this.updateTopBar(r)), !0;
2765
2794
  }
@@ -2810,8 +2839,8 @@ class Na {
2810
2839
  groupList: t.panelTitleCategories
2811
2840
  }[e] ?? "";
2812
2841
  if (n) {
2813
- const i = this.deps.currentThreadId(), r = i ? this.threads.indexOf(i) : -1, s = r > 0, g = r >= 0 && r < this.threads.length - 1;
2814
- this.deps.drawer()?.updatePanelTopBar(s, g, n);
2842
+ const i = this.deps.currentThreadId(), r = i ? this.threads.indexOf(i) : -1, s = r > 0, l = r >= 0 && r < this.threads.length - 1;
2843
+ this.deps.drawer()?.updatePanelTopBar(s, l, n);
2815
2844
  }
2816
2845
  }
2817
2846
  /**
@@ -2870,7 +2899,7 @@ class Na {
2870
2899
  this.snapshots.clear(), this.snapshotTypes.clear(), this.activePanelMessageId = null, this.currentType = null, this.threads = [];
2871
2900
  }
2872
2901
  }
2873
- class pe {
2902
+ class he {
2874
2903
  constructor(e) {
2875
2904
  this.favoritedSkus = /* @__PURE__ */ new Set(), this._db = e;
2876
2905
  }
@@ -2925,16 +2954,20 @@ class pe {
2925
2954
  }
2926
2955
  }
2927
2956
  /**
2928
- * Persist session to IndexedDB, then send openURLInNewTab bridge message.
2929
- * Used by product clicks and bot HTML link clicks so the session can be
2930
- * restored when the user returns from navigation.
2957
+ * Persist session to IndexedDB, then navigate to the URL.
2958
+ * Sends an 'openURLInNewTab' bridge message so the host page can intercept
2959
+ * (e.g. for SPA routing), then navigates directly as fallback.
2960
+ *
2961
+ * Legacy compatibility: robot-engine-lean navigated via window.location.href
2962
+ * after posting saveSessionAndOpenURL to the iframe. The clean-room runs in
2963
+ * the same window (Shadow DOM, not iframe), so it navigates directly.
2931
2964
  */
2932
2965
  async saveAndOpenURL(e, t, a) {
2933
2966
  try {
2934
2967
  await t();
2935
2968
  } catch {
2936
2969
  }
2937
- a?.send("openURLInNewTab", { url: e });
2970
+ a?.send("openURLInNewTab", { url: e }), window.location.href = e;
2938
2971
  }
2939
2972
  /**
2940
2973
  * Load a UISpec payload from IndexedDB with retry logic.
@@ -2981,54 +3014,54 @@ class pe {
2981
3014
  this._db?.close(), this._db = null;
2982
3015
  }
2983
3016
  }
2984
- const Te = "gengage_kvkk_shown", Aa = ["kvkk", "kişisel veri", "kisisel veri"], Pa = /\b6698\b/;
2985
- function ce(o) {
3017
+ const Le = "gengage_kvkk_shown", Ba = ["kvkk", "kişisel veri", "kisisel veri"], Ma = /\b6698\b/;
3018
+ function le(o) {
2986
3019
  const e = o.toLowerCase();
2987
- return Aa.some((t) => e.includes(t)) || Pa.test(e);
3020
+ return Ba.some((t) => e.includes(t)) || Ma.test(e);
2988
3021
  }
2989
- function he(o) {
3022
+ function ue(o) {
2990
3023
  try {
2991
- return localStorage.getItem(`${Te}_${o}`) === "1";
3024
+ return localStorage.getItem(`${Le}_${o}`) === "1";
2992
3025
  } catch {
2993
3026
  return !1;
2994
3027
  }
2995
3028
  }
2996
- function Ba(o) {
3029
+ function za(o) {
2997
3030
  try {
2998
- localStorage.setItem(`${Te}_${o}`, "1");
3031
+ localStorage.setItem(`${Le}_${o}`, "1");
2999
3032
  } catch {
3000
3033
  }
3001
3034
  }
3002
- function Ma(o) {
3035
+ function Da(o) {
3003
3036
  const t = new DOMParser().parseFromString(o, "text/html").body, a = Array.from(t.children);
3004
3037
  for (const n of a)
3005
- if (ce(n.textContent ?? "")) {
3038
+ if (le(n.textContent ?? "")) {
3006
3039
  n.remove();
3007
3040
  break;
3008
3041
  }
3009
3042
  return t.innerHTML.trim();
3010
3043
  }
3011
- function za(o) {
3044
+ function Ra(o) {
3012
3045
  const e = new DOMParser().parseFromString(o, "text/html");
3013
3046
  for (const t of Array.from(e.body.children))
3014
- if (ce(t.textContent ?? ""))
3047
+ if (le(t.textContent ?? ""))
3015
3048
  return t.outerHTML;
3016
3049
  return null;
3017
3050
  }
3018
- const Da = {
3051
+ const Ua = {
3019
3052
  tr: "TURKISH",
3020
3053
  en: "ENGLISH",
3021
3054
  de: "GERMAN",
3022
3055
  fr: "FRENCH"
3023
3056
  };
3024
- function Ra(o) {
3025
- return o ? Da[o.toLowerCase().slice(0, 2)] ?? "TURKISH" : "TURKISH";
3057
+ function Ha(o) {
3058
+ return o ? Ua[o.toLowerCase().slice(0, 2)] ?? "TURKISH" : "TURKISH";
3026
3059
  }
3027
- const Ua = ':host{all:initial;font-family:var(--gengage-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif);font-size:var(--gengage-font-size, 14px)}.gengage-chat-root{position:fixed;z-index:var(--gengage-z-index, 2147483647);--_gengage-chat-offset: var(--gengage-chat-offset, 20px);--_gengage-chat-launcher-bottom: var(--gengage-chat-launcher-bottom, 20px);--_gengage-chat-launcher-right: var(--gengage-chat-launcher-right, 20px);--_gengage-chat-launcher-size: var(--gengage-chat-launcher-size, 56px);--_gengage-chat-drawer-width: var(--gengage-chat-width, 400px);--_gengage-chat-radius: var(--gengage-chat-shell-radius, 12px);--_gengage-chat-header-height: var(--gengage-chat-header-height, 60px);--_gengage-chat-conversation-width: var(--gengage-chat-conversation-width, 396px);--_gengage-chat-panel-min-width: var(--gengage-chat-panel-min-width, 320px);--_gengage-chat-panel-max-width: var(--gengage-chat-panel-max-width, 860px);--_gengage-chat-input-height: var(--gengage-chat-input-height, 48px);--_gengage-chat-shadow: var(--gengage-chat-shadow, 0 12px 40px rgba(15, 23, 42, .18));--_gengage-border-color: var(--gengage-border-color, #e5e7eb);--_gengage-discount-color: var(--gengage-discount-color, #ef4444);--_gengage-success-color: var(--gengage-success-color, #16a34a);--_gengage-text-secondary: var(--gengage-text-secondary, #64748b);--_gengage-qty-btn-size: var(--gengage-qty-btn-size, 28px);--_gengage-qty-btn-size-compact: var(--gengage-qty-btn-size-compact, 24px)}.gengage-chat-launcher-container{position:fixed;bottom:var(--_gengage-chat-launcher-bottom);right:var(--_gengage-chat-launcher-right);display:flex;flex-direction:column;align-items:flex-end;gap:10px;z-index:var(--gengage-z-index, 2147483647)}.gengage-chat-launcher-content-area,.gengage-chat-launcher-content-area-bottom{display:flex;flex-direction:column;align-items:flex-end;gap:8px}.gengage-chat-launcher-content-area:empty,.gengage-chat-launcher-content-area-bottom:empty{display:none}.gengage-chat-root--open .gengage-chat-launcher-content-area,.gengage-chat-root--open .gengage-chat-launcher-content-area-bottom{display:none}.gengage-chat-launcher{width:var(--_gengage-chat-launcher-size);height:var(--_gengage-chat-launcher-size);border-radius:50%;border:none;background:var(--gengage-primary-color, #3b82f6);color:var(--gengage-primary-foreground, #fff);cursor:pointer;display:flex;align-items:center;justify-content:center;box-shadow:0 8px 22px #0f172a47;transition:transform .18s cubic-bezier(.2,.8,.2,1),box-shadow .18s ease;position:relative;flex-shrink:0}.gengage-chat-launcher:hover{transform:scale(1.05);box-shadow:0 14px 28px #0f172a47}.gengage-chat-launcher svg{width:24px;height:24px}.gengage-chat-launcher--hidden-mobile{display:none!important}.gengage-chat-launcher-tooltip{position:absolute;right:calc(100% + 12px);top:50%;transform:translateY(-50%);padding:6px 12px;border-radius:8px;background:#1e293b;color:#fff;font-size:13px;font-weight:500;white-space:nowrap;opacity:0;pointer-events:none;transition:opacity .2s ease;box-shadow:0 2px 8px #00000026}.gengage-chat-launcher-tooltip:after{content:"";position:absolute;left:100%;top:50%;transform:translateY(-50%);border:5px solid transparent;border-left-color:#1e293b}.gengage-chat-launcher:hover .gengage-chat-launcher-tooltip{opacity:1}.gengage-chat-root--open .gengage-chat-launcher-tooltip{display:none}.gengage-chat-proactive{position:fixed;bottom:calc(var(--_gengage-chat-launcher-bottom) + var(--_gengage-chat-launcher-size) + 14px);right:var(--_gengage-chat-launcher-right);width:280px;padding:16px 18px;border-radius:16px;background:#fff;box-shadow:0 8px 30px #0000001f,0 2px 8px #0000000f;opacity:0;transform:translateY(8px) scale(.96);transition:opacity .25s ease,transform .25s ease;z-index:2147483645}.gengage-chat-proactive--visible{opacity:1;transform:translateY(0) scale(1)}.gengage-chat-proactive-message{margin:0 0 12px;font-size:14px;line-height:1.5;color:#1f2937}.gengage-chat-proactive-actions{display:flex;gap:8px}.gengage-chat-proactive-accept{flex:1;padding:8px 16px;border:none;border-radius:10px;background:var(--gengage-primary-color, #3b82f6);color:#fff;font-size:13px;font-weight:700;font-family:inherit;cursor:pointer;transition:filter .15s ease}.gengage-chat-proactive-accept:hover{filter:brightness(1.08)}.gengage-chat-proactive-dismiss{position:absolute;top:8px;right:8px;width:24px;height:24px;border:none;border-radius:50%;background:transparent;color:#64748b;font-size:16px;cursor:pointer;display:flex;align-items:center;justify-content:center}.gengage-chat-proactive-dismiss:hover{color:#475569;background:#f1f5f9}.gengage-chat-drawer{position:fixed;top:0;bottom:0;right:0;width:var(--_gengage-chat-drawer-width);max-height:100dvh;border-radius:0;background:var(--gengage-background-color, #fff);box-shadow:var(--_gengage-chat-shadow);display:flex;flex-direction:column;overflow:hidden;z-index:var(--gengage-z-index, 2147483647);transform-origin:right center;clip-path:inset(0);transition:clip-path .42s cubic-bezier(.25,.46,.45,.94),opacity .32s ease}.gengage-chat-root--mobile .gengage-chat-launcher-container{right:16px;bottom:calc(16px + env(safe-area-inset-bottom))}.gengage-chat-root--mobile .gengage-chat-drawer{left:0;right:0;bottom:0;width:100%;max-width:none;max-height:100dvh;border-radius:16px 16px 0 0;padding-bottom:env(safe-area-inset-bottom,0px);clip-path:inset(0);transition:clip-path .42s cubic-bezier(.25,.46,.45,.94),opacity .32s ease}.gengage-chat-root--mobile.gengage-chat-root--mobile-half .gengage-chat-drawer{top:auto;height:min(72dvh,620px);max-height:min(72dvh,620px)}.gengage-chat-root--mobile.gengage-chat-root--mobile-full .gengage-chat-drawer{top:0;height:100dvh;max-height:100dvh;border-radius:0}.gengage-chat-root--mobile .gengage-chat-input-area{padding-bottom:calc(10px + env(safe-area-inset-bottom,0px));transform:translateY(calc(-1 * var(--gengage-keyboard-offset, 0px)))}.gengage-chat-header{display:flex;align-items:center;justify-content:space-between;box-sizing:border-box;min-height:var(--_gengage-chat-header-height);padding:4px 12px;background:var(--gengage-chat-header-bg, #1d2939);color:var(--gengage-chat-header-foreground, #fff);box-shadow:0 4px 20px #00000014,0 0 2px #0000001f;border:none;position:relative;z-index:2}.gengage-chat-header-left{display:flex;align-items:center;gap:10px;min-width:0}.gengage-chat-header-avatar{width:40px;height:40px;border-radius:50%;object-fit:cover;flex-shrink:0;border:2px solid rgba(255,255,255,.15)}.gengage-chat-header-info{display:flex;flex-direction:column;gap:2px;min-width:0}.gengage-chat-header-title-row{display:flex;align-items:center;gap:6px}.gengage-chat-header-title{font-weight:700;font-size:15px;line-height:1.25;letter-spacing:.01em;color:inherit}.gengage-chat-header-badge{display:inline-flex;align-items:center;padding:1px 6px;border-radius:4px;background:var(--gengage-primary-color, #3b82f6);color:#fff;font-size:10px;font-weight:700;letter-spacing:.04em;text-transform:uppercase;line-height:1.5}.gengage-chat-header-powered{display:flex;align-items:center;gap:4px;font-size:11px;color:#ffffffbf;text-decoration:none;transition:color .15s}.gengage-chat-header-powered:hover{color:#fffc}.gengage-chat-header-powered svg{width:12px;height:12px;opacity:.6}.gengage-chat-header-right{display:flex;align-items:center;gap:4px;flex-shrink:0}.gengage-chat-header-btn{width:32px;height:32px;border-radius:8px;background:transparent;border:1px solid rgba(255,255,255,.12);color:#ffffffb3;cursor:pointer;display:inline-flex;align-items:center;justify-content:center;text-decoration:none;line-height:1;transition:background-color .15s ease,color .15s ease,border-color .15s ease}.gengage-chat-header-btn:hover{background:#ffffff1a;color:#fff;border-color:#ffffff40}.gengage-chat-close{width:32px;height:32px;border-radius:8px;background:transparent;border:1px solid rgba(255,255,255,.12);color:#ffffffb3;font-size:18px;cursor:pointer;display:inline-flex;align-items:center;justify-content:center;line-height:1;transition:background-color .15s ease,color .15s ease,border-color .15s ease}.gengage-chat-close:hover{background:#ffffff1a;color:#fff;border-color:#ffffff40}.gengage-chat-body{display:flex;flex:1;overflow:hidden;min-height:0}.gengage-chat-panel{display:none;width:0;overflow:hidden;transition:width .22s cubic-bezier(.2,.72,.2,1)}.gengage-chat-panel--visible{display:flex;flex-direction:column;position:relative;width:440px;min-width:440px;border-right:1px solid var(--_gengage-border-color);overflow-y:auto;padding:16px;background:#f8fafc}.gengage-chat-panel-divider{display:flex;align-items:center;width:4px;cursor:pointer;background:#e5e7eb;position:relative;flex-shrink:0;transition:background .15s;z-index:2}.gengage-chat-panel-divider:hover{background:#cbd5e1}.gengage-chat-panel-divider--hidden{display:none}.gengage-chat-panel-divider-toggle{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);width:24px;height:48px;border:1px solid var(--_gengage-border-color);border-radius:6px;background:#fff;cursor:pointer;display:flex;align-items:center;justify-content:center;font-size:14px;color:var(--_gengage-text-secondary);box-shadow:0 1px 3px #00000014;transition:background .15s,color .15s;padding:0;line-height:1}.gengage-chat-panel-divider-toggle:hover{background:#f1f5f9;color:#334155}.gengage-chat-panel--collapsed{flex:0 0 0px!important;width:0!important;min-width:0!important;max-width:0!important;padding:0!important;border-right:none!important;overflow:hidden}.gengage-chat-panel--collapsed~.gengage-chat-panel-divider{width:0;background:transparent}.gengage-chat-panel--collapsed~.gengage-chat-panel-divider .gengage-chat-panel-divider-toggle{left:0;transform:translateY(-50%)}.gengage-chat-conversation{display:flex;flex-direction:column;flex:1;min-width:0;overflow:hidden;background:var(--gengage-background-color, #fff);position:relative;z-index:1}.gengage-chat-drawer--with-panel{width:auto;background:transparent;box-shadow:none}.gengage-chat-drawer--with-panel .gengage-chat-header{border-radius:0;flex-shrink:0}.gengage-chat-drawer--with-panel .gengage-chat-body{flex:1 1 0;min-height:0;gap:0;padding:0;align-items:stretch}.gengage-chat-drawer--with-panel .gengage-chat-panel--visible{flex:0 0 auto;width:clamp(var(--_gengage-chat-panel-min-width),50vw,var(--_gengage-chat-panel-max-width));min-width:var(--_gengage-chat-panel-min-width);max-width:var(--_gengage-chat-panel-max-width);border-right:none;background:#fff;padding:0 16px 16px;overflow-y:auto;margin:0;border-radius:0;box-shadow:0 8px 32px #0f172a1f,0 2px 8px #0f172a0f;max-height:100dvh}.gengage-chat-drawer--with-panel .gengage-chat-panel-divider{width:0;background:transparent}.gengage-chat-drawer--with-panel .gengage-chat-panel-divider-toggle{width:20px;height:48px;border-radius:10px;background:var(--gengage-primary-color, #3b82f6);color:#fff;border:2px solid #fff;box-shadow:0 2px 8px #0f172a2e;font-size:12px;z-index:10}.gengage-chat-drawer--with-panel .gengage-chat-panel-divider-toggle:hover{background:var(--gengage-primary-hover, #2563eb);color:#fff}.gengage-chat-drawer--with-panel .gengage-chat-conversation{flex:0 0 var(--_gengage-chat-conversation-width);width:var(--_gengage-chat-conversation-width);border-left:none;background:var(--gengage-background-color, #fff);box-shadow:-4px 0 24px #0f172a1f,-1px 0 4px #0f172a0f}.gengage-chat-drawer--with-panel .gengage-chat-messages{padding-right:6px;scrollbar-width:thin;scrollbar-color:rgba(0,0,0,.12) transparent}.gengage-chat-drawer--with-panel .gengage-chat-messages::-webkit-scrollbar{width:0}.gengage-chat-drawer--with-panel:has(.gengage-chat-panel--collapsed){width:var(--_gengage-chat-conversation-width);background:var(--gengage-background-color, #fff);box-shadow:var(--_gengage-chat-shadow)}.gengage-chat-drawer--with-panel .gengage-chat-footer{display:none}.gengage-chat-messages{flex:1;overflow-y:auto;padding:16px;display:flex;flex-direction:column;gap:16px;min-height:0;scroll-behavior:smooth}.gengage-chat-messages::-webkit-scrollbar{width:6px}.gengage-chat-messages::-webkit-scrollbar-track{background:transparent}.gengage-chat-messages::-webkit-scrollbar-thumb{background:#0000001f;border-radius:3px}.gengage-chat-messages::-webkit-scrollbar-thumb:hover{background:#0003}.gengage-chat-bubble{max-width:85%;padding:12px 16px;border-radius:12px;line-height:1.5;font-size:14px;font-weight:500;word-wrap:break-word;overflow-wrap:break-word;animation:gengage-chat-msg-in .3s cubic-bezier(.2,.7,.2,1)}@keyframes gengage-chat-msg-in{0%{opacity:0;transform:translateY(8px)}to{opacity:1;transform:translateY(0)}}.gengage-chat-bubble--user{align-self:flex-end;background:var(--gengage-primary-color, #3b82f6);color:var(--gengage-primary-foreground, #fff);border-bottom-right-radius:4px}.gengage-chat-bubble--assistant{align-self:flex-start;background:#f3f4f6;color:#1f2937;border-bottom-left-radius:4px;min-width:120px}.gengage-chat-bubble--active{outline:2px solid var(--gengage-primary-color, #3b82f6);outline-offset:-2px}.gengage-chat-bubble--assistant:empty{display:none}.gengage-chat-bubble--assistant .gengage-chat-bubble-text a{color:var(--gengage-primary-color, #2563eb);text-decoration:underline}.gengage-chat-bubble--assistant .gengage-chat-bubble-text a:hover{text-decoration:none}.gengage-chat-bubble--assistant .gengage-chat-bubble-text p{margin:0 0 8px}.gengage-chat-bubble--assistant .gengage-chat-bubble-text p:last-child{margin-bottom:0}.gengage-chat-bubble--assistant .gengage-chat-bubble-text ul,.gengage-chat-bubble--assistant .gengage-chat-bubble-text ol{margin:6px 0;padding-left:20px}.gengage-chat-bubble--assistant .gengage-chat-bubble-text li{margin-bottom:6px;line-height:1.5}.gengage-chat-bubble--assistant .gengage-chat-bubble-text code{background:#0000000f;padding:1px 4px;border-radius:3px;font-size:.9em}.gengage-chat-bubble--assistant .gengage-chat-bubble-text pre{background:#0000000a;padding:8px;border-radius:6px;overflow-x:auto;margin:4px 0}.gengage-chat-bubble--assistant .gengage-chat-bubble-text table{border-collapse:collapse;margin:4px 0;font-size:.9em}.gengage-chat-bubble--assistant .gengage-chat-bubble-text th,.gengage-chat-bubble--assistant .gengage-chat-bubble-text td{border:1px solid var(--_gengage-border-color);padding:4px 8px}.gengage-chat-bubble--assistant .gengage-chat-bubble-text img{max-width:100%;height:auto;border-radius:4px;margin:4px 0}.gengage-chat-bubble--assistant .gengage-chat-bubble-text h1,.gengage-chat-bubble--assistant .gengage-chat-bubble-text h2,.gengage-chat-bubble--assistant .gengage-chat-bubble-text h3,.gengage-chat-bubble--assistant .gengage-chat-bubble-text h4,.gengage-chat-bubble--assistant .gengage-chat-bubble-text h5,.gengage-chat-bubble--assistant .gengage-chat-bubble-text h6{margin:8px 0 4px;line-height:1.3;color:#0f172a}.gengage-chat-bubble--assistant .gengage-chat-bubble-text blockquote{border-left:3px solid var(--_gengage-border-color);padding-left:12px;margin:4px 0;color:var(--_gengage-text-secondary)}.gengage-chat-bubble--first{border-left:3px solid var(--gengage-accent-primary, #3b82f6);padding-left:12px}.gengage-chat-bubble--first .gengage-chat-bubble-text{font-size:15px}.gengage-chat-typing{display:flex;align-items:center;gap:5px;padding:8px 4px;align-self:flex-start;max-width:85%}.gengage-chat-typing:has(.gengage-chat-typing-text),.gengage-chat-typing:has(.gengage-chat-thinking-steps){background:#f3f4f6;padding:10px 14px;border-radius:12px 12px 12px 4px;gap:8px}.gengage-chat-typing-dots{display:flex;align-items:center;gap:5px}.gengage-chat-typing-dots span{width:6px;height:6px;border-radius:50%;background:#94a3b8;display:inline-block;animation:gengage-chat-typing-fade 1.4s ease-in-out infinite}.gengage-chat-typing-dots span:nth-child(2){animation-delay:.2s}.gengage-chat-typing-dots span:nth-child(3){animation-delay:.4s}@keyframes gengage-chat-typing-fade{0%,to{opacity:.25}50%{opacity:1}}.gengage-chat-typing-sparkle{animation:gengage-sparkle-pulse 1.2s infinite}@keyframes gengage-sparkle-pulse{0%,to{opacity:1}50%{opacity:.4}}.gengage-chat-typing-text{font-size:13px;color:var(--_gengage-text-secondary);font-style:italic;flex:1;min-width:0;word-wrap:break-word;overflow-wrap:break-word}.gengage-chat-thinking-steps{display:flex;flex-direction:column;gap:4px;padding:4px 0}.gengage-chat-thinking-step{display:flex;align-items:center;gap:6px;font-size:13px;color:var(--gengage-chat-text-secondary, #666)}.gengage-chat-thinking-step-marker{font-size:12px;width:16px;text-align:center;flex-shrink:0}.gengage-chat-thinking-step-marker--done{color:var(--gengage-chat-success, #4caf50)}.gengage-chat-thinking-step-marker--active{color:var(--gengage-chat-primary, #1976d2);animation:gengage-thinking-pulse 1.5s ease-in-out infinite}@keyframes gengage-thinking-pulse{0%,to{opacity:1}50%{opacity:.4}}.gengage-chat-thinking-step-text{line-height:1.4}.gengage-chat-error{display:flex;align-items:center;justify-content:center;gap:10px;padding:10px 14px;border-radius:10px;background:#fef2f2;color:#991b1b;font-size:13px;text-align:center;border:1px solid #fecaca}.gengage-chat-error-retry{flex-shrink:0;padding:4px 12px;border:1px solid #fca5a5;border-radius:6px;background:#fff;color:#991b1b;font-size:12px;font-weight:500;cursor:pointer;transition:background .15s}.gengage-chat-error-retry:hover{background:#fee2e2}.gengage-chat-input-area{display:flex;flex-wrap:wrap;align-items:center;gap:0;padding:8px 12px;border-top:1px solid var(--_gengage-border-color);background:var(--gengage-background-color, #fff)}.gengage-chat-input-pill{display:flex;align-items:center;gap:4px;flex:1;min-width:0;height:44px;background:#f3f4f6;border:1px solid var(--_gengage-border-color);border-radius:30px;padding:2px 8px;overflow:hidden;transition:border-color .2s ease,box-shadow .2s ease}.gengage-chat-input-pill:focus-within{border-color:var(--gengage-primary-color, #3b82f6);box-shadow:0 0 0 2px #3b82f626}.gengage-chat-input{flex:1;min-width:0;min-height:40px;max-height:120px;padding:0 6px 0 14px;border:none;border-radius:0;font-size:14px;font-family:inherit;line-height:1.4;align-content:center;outline:none;background:transparent;color:#1f2937;resize:none;overflow-y:hidden}@media(max-width:767px){.gengage-chat-input{max-height:40px;white-space:nowrap;overflow:hidden}.gengage-chat-send{width:44px;height:44px;min-width:44px}}.gengage-chat-input::placeholder{font-size:14px;color:#6b7280}.gengage-chat-send{width:36px;height:36px;min-width:36px;padding:0;border:none;border-radius:50%;background:var(--gengage-primary-color, #3b82f6);color:var(--gengage-primary-foreground, #fff);font-weight:700;font-size:0;font-family:inherit;cursor:pointer;display:flex;align-items:center;justify-content:center;flex-shrink:0;transition:background-color .2s cubic-bezier(.4,0,.2,1),box-shadow .2s ease,transform .15s ease;box-shadow:0 2px 4px #0000001f}.gengage-chat-send:hover{filter:brightness(.92);transform:translateY(-1px);box-shadow:0 4px 8px #0000002e}.gengage-chat-send:active{transform:translateY(0);box-shadow:0 1px 2px #0000001f}.gengage-chat-send svg{width:18px;height:18px}.gengage-chat-send:disabled{background:#d1d5db;box-shadow:none;cursor:not-allowed}.gengage-chat-footer{padding:4px 10px;text-align:center;font-size:10px;color:#6b7280;border-top:1px solid #f1f5f9;background:var(--gengage-background-color, #fff)}.gengage-chat-uispec{width:100%}.gengage-chat-uispec:empty{display:none}.gengage-chat-uispec>*{animation:gengage-chat-widget-enter .16s cubic-bezier(.2,.7,.2,1) both}@keyframes gengage-chat-widget-enter{0%{opacity:0;transform:translateY(5px) scale(.99)}to{opacity:1;transform:translateY(0) scale(1)}}.gengage-chat-action-buttons{display:flex;gap:8px;padding:6px 0 4px;overflow-x:auto;scrollbar-width:none;-webkit-overflow-scrolling:touch}.gengage-chat-action-buttons::-webkit-scrollbar{display:none}.gengage-chat-action-btn{flex:0 0 auto;padding:8px 16px;border:none;border-radius:999px;background:var(--gengage-primary-color, #3b82f6);color:var(--gengage-primary-foreground, #fff);font-size:13px;font-weight:600;line-height:1.25;font-family:inherit;cursor:pointer;white-space:nowrap;transition:filter .15s ease,transform .1s ease}.gengage-chat-action-btn:hover{filter:brightness(.92)}.gengage-chat-action-btn:active{transform:scale(.97)}.gengage-chat-product-card{position:relative;border:1px solid #eee;border-radius:16px;overflow:hidden;background:#fff;width:160px;min-width:160px;max-width:160px;box-shadow:0 2px 8px #0000000f;transition:transform .1s ease,box-shadow .2s ease}.gengage-chat-product-card:hover{transform:translateY(-2px);box-shadow:0 4px 16px #0000001f}.gengage-chat-product-card-img{width:100%;height:120px;object-fit:contain;display:block;background:#fff;padding:8px;box-sizing:border-box}.gengage-chat-product-card-body{display:flex;flex-direction:column;gap:4px;padding:8px 10px 10px;text-align:center}.gengage-chat-product-card-name{font-size:13px;font-weight:600;color:#1f2937;line-height:1.35;margin-bottom:0;min-height:0;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;text-overflow:ellipsis}.gengage-chat-product-card-brand{font-size:10px;color:#666}.gengage-chat-product-card-rating{font-size:11px;color:#f59e0b;line-height:1}.gengage-chat-product-card-review-count{color:#64748b;font-size:10px}.gengage-chat-product-card-price{display:flex;align-items:baseline;justify-content:center;gap:4px;font-size:16px;font-weight:800;color:#0f172a}.gengage-chat-product-card-original-price{text-decoration:line-through;color:#64748b;font-weight:400;font-size:12px}.gengage-chat-price-skeleton{display:inline-block;width:80px;height:16px;background:linear-gradient(90deg,#e2e8f0 25%,#f1f5f9,#e2e8f0 75%);background-size:200% 100%;animation:gengage-skeleton-price-pulse 1.5s ease-in-out infinite;border-radius:4px;vertical-align:middle}@keyframes gengage-skeleton-price-pulse{0%{background-position:200% 0}to{background-position:-200% 0}}.gengage-chat-product-card-cta{display:block;padding:8px 10px;text-align:center;background:transparent;color:var(--gengage-primary-color, #3b82f6);text-decoration:none;font-size:12px;font-weight:700;letter-spacing:.01em;border-top:1px solid #f1f5f9;transition:color .15s ease,background .15s ease}.gengage-chat-product-card-cta:hover{color:var(--gengage-primary-color, #0b24d6);background:#f8fafc}.gengage-chat-product-card-cta:active{background:#f1f5f9}.gengage-chat-product-summary{display:flex;align-items:center;gap:12px;padding:10px 12px;border:1px solid #e5e7eb;border-radius:12px;background:#fff;cursor:pointer;transition:background .15s,box-shadow .15s;margin:4px 0}.gengage-chat-product-summary:hover{background:#f9fafb;box-shadow:0 1px 4px #0000000f}.gengage-chat-product-summary__image{flex-shrink:0;width:64px;height:64px;border-radius:8px;overflow:hidden;border:1px solid #f3f4f6;background:#f9fafb}.gengage-chat-product-summary__image img{width:100%;height:100%;object-fit:cover;display:block}.gengage-chat-product-summary__content{flex:1;min-width:0;display:flex;flex-direction:column;gap:2px}.gengage-chat-product-summary__name{font-size:13px;font-weight:500;line-height:1.3;color:#111827;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}.gengage-chat-product-summary__rating{font-size:11px;color:#f59e0b;line-height:1}.gengage-chat-product-summary__review-count{color:#6b7280;font-size:11px}.gengage-chat-product-summary__price{font-size:13px;font-weight:600;color:#111827;line-height:1;margin-top:2px}.gengage-chat-product-summary__price-original{text-decoration:line-through;color:#6b7280;font-weight:400;font-size:11px}.gengage-chat-product-summary__price-current{color:var(--gengage-primary-color, #111827)}.gengage-chat-product-summary__cta{flex-shrink:0;font-size:12px;font-weight:500;color:var(--gengage-primary-color, #2563eb);text-decoration:none;padding:4px 10px;border-radius:8px;transition:background .15s;white-space:nowrap}.gengage-chat-product-summary__cta:hover{background:#0000000a}.gengage-chat-product-summary__cta:focus-visible{outline:2px solid var(--gengage-primary-color, #2563eb);outline-offset:2px}.gengage-chat-product-grid{display:flex;gap:12px;overflow-x:auto;padding:8px 0;-webkit-overflow-scrolling:touch;scrollbar-width:none;scroll-snap-type:x proximity;min-height:180px}.gengage-chat-product-grid>*{scroll-snap-align:start;flex:0 0 auto}.gengage-chat-product-grid::-webkit-scrollbar{display:none}.gengage-chat-review-highlights{padding:2px 0 6px}.gengage-chat-review-item{border:1px solid var(--_gengage-border-color);border-radius:12px;padding:10px 12px;background:#fff}.gengage-chat-review-item[data-tone=positive]{border-color:#bbf7d0;background:#f0fdf4}.gengage-chat-review-item[data-tone=negative]{border-color:#fecaca;background:#fef2f2}.gengage-chat-review-tag{font-size:11px;font-weight:700;text-transform:uppercase;letter-spacing:.03em;color:var(--_gengage-text-secondary);margin-bottom:4px}.gengage-chat-review-text{font-size:13px;line-height:1.45;color:#1f2937}.gengage-chat-review-rating{margin-top:6px;font-size:12px;font-weight:700;color:#0f172a}.gengage-chat-review-empty{font-size:12px;color:var(--_gengage-text-secondary)}.gengage-chat-review-tabs{display:flex;gap:6px;margin-bottom:10px}.gengage-chat-review-tab{padding:6px 14px;border:1px solid var(--_gengage-border-color);border-radius:999px;background:#fff;color:var(--_gengage-text-secondary);font-size:12px;font-weight:600;font-family:inherit;cursor:pointer;transition:background .15s,border-color .15s}.gengage-chat-review-tab:hover{background:#f8fafc}.gengage-chat-review-tab--active{background:#f1f5f9;border-color:#94a3b8;color:#0f172a}.gengage-chat-review-pills{display:flex;flex-wrap:wrap;gap:6px;margin-bottom:10px}.gengage-chat-review-pill{display:flex;align-items:center;gap:6px;padding:6px 10px;border:1px solid var(--_gengage-border-color);border-radius:8px;background:#fff;font-size:12px;color:#334155;box-shadow:0 1px 2px #0000000a}.gengage-chat-review-pill[data-tone=positive]{border-color:#bbf7d0}.gengage-chat-review-pill[data-tone=negative]{border-color:#fecaca}.gengage-chat-review-pill-icon{font-size:11px;font-weight:700}.gengage-chat-review-pill[data-tone=positive] .gengage-chat-review-pill-icon{color:#16a34a}.gengage-chat-review-pill[data-tone=negative] .gengage-chat-review-pill-icon{color:#dc2626}.gengage-chat-review-pill-count{font-size:10px;font-weight:700;background:#f1f5f9;color:var(--_gengage-text-secondary);border-radius:4px;padding:1px 5px}.gengage-chat-review-items{display:grid;gap:10px}.gengage-chat-divider{border:none;border-top:1px solid var(--_gengage-border-color);margin:8px 0}.gengage-chat-divider-wrapper{display:flex;align-items:center;gap:8px;margin:8px 0}.gengage-chat-divider-wrapper hr{flex:1;border:none;border-top:1px solid var(--_gengage-border-color);margin:0}.gengage-chat-divider-label{font-size:11px;color:#6b7280;white-space:nowrap}.gengage-chat--overlay .gengage-chat-drawer{position:fixed;inset:0;width:100%;max-width:480px;max-height:100%;margin:0 auto;border-radius:0;animation:gengage-chat-overlay-in .24s cubic-bezier(.2,.72,.2,1)}.gengage-chat--overlay:before{content:"";position:fixed;inset:0;background:#00000073;z-index:-1}@keyframes gengage-chat-overlay-in{0%{opacity:0;transform:translateY(12px)}to{opacity:1;transform:translateY(0)}}.gengage-chat-panel-skeleton{display:flex;flex-direction:column;gap:14px;padding:6px 0}.gengage-chat-panel-skeleton-block{height:110px;border-radius:10px;background:linear-gradient(90deg,#e5e7eb 25%,#f3f4f6,#e5e7eb 75%);background-size:200% 100%;animation:gengage-panel-shimmer 1.4s infinite}@keyframes gengage-panel-shimmer{0%{background-position:200% 0}to{background-position:-200% 0}}.gengage-chat-panel-skeleton-block--image{height:200px;border-radius:8px;margin-bottom:12px}.gengage-chat-panel-skeleton-block--text{height:16px;border-radius:4px;margin-bottom:8px}.gengage-chat-panel-skeleton-block--text:nth-child(3){width:80%}.gengage-chat-panel-skeleton-block--text:nth-child(4){width:60%}.gengage-chat-panel-skeleton-grid{display:grid;grid-template-columns:1fr 1fr;gap:8px}.gengage-chat-panel-skeleton-block--card{height:120px;border-radius:8px}.gengage-chat-panel-skeleton-block--row{height:32px;border-radius:4px;margin-bottom:4px}.gengage-chat-panel .gengage-chat-product-card{width:100%;max-width:100%;min-width:0;display:flex;flex-direction:column;border-radius:12px;border:1px solid var(--_gengage-border-color);box-shadow:0 1px 4px #0000000f;overflow:hidden;padding:0}.gengage-chat-panel .gengage-chat-product-card:hover{transform:translateY(-2px);box-shadow:0 4px 12px #0000001a;border-color:#d1d5db}.gengage-chat-panel .gengage-chat-product-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(180px,1fr));overflow-x:visible;gap:12px;min-height:auto;padding:4px 0}.gengage-chat-panel .gengage-chat-product-card-img{width:100%;height:160px;border-radius:0;object-fit:contain;background:#fafafa;padding:12px;box-sizing:border-box}.gengage-chat-panel .gengage-chat-product-card-body{padding:10px 12px 12px;text-align:left;gap:4px}.gengage-chat-panel .gengage-chat-product-card-name{min-height:0;margin-bottom:2px;font-size:13px;-webkit-line-clamp:2}.gengage-chat-panel .gengage-chat-product-card-price{justify-content:flex-start;font-size:15px}.gengage-chat-panel .gengage-chat-product-card-cta{display:block;padding:10px 12px;text-align:center;border-top:1px solid #f1f5f9;border-radius:0;background:transparent;color:var(--gengage-primary-color, #3b82f6);font-weight:700;font-size:13px}.gengage-chat-product-details-panel{display:flex;flex-direction:column;gap:12px;width:100%;background:#fff;border:1px solid var(--_gengage-border-color);border-radius:16px;padding:14px;box-sizing:border-box}.gengage-chat-product-details-media{border:1px solid #f1f5f9;border-radius:12px;background:#fafafa;padding:12px;display:flex;flex-direction:column;align-items:center}.gengage-chat-product-details-img{width:100%;height:auto;max-height:300px;object-fit:contain;border-radius:8px}.gengage-chat-product-details-content{display:flex;flex-direction:column;gap:8px;min-width:0}.gengage-chat-product-details-title{margin:0;font-size:17px;font-weight:700;line-height:1.3;color:#0f172a}.gengage-chat-product-details-rating{display:inline-flex;align-items:center;gap:4px;width:fit-content;padding:3px 8px;border-radius:999px;background:#fff7ed;color:#9a3412;font-size:13px;font-weight:700}.gengage-chat-product-details-review-count{color:#7c2d12;font-weight:600}.gengage-chat-product-details-price{display:flex;align-items:baseline;gap:6px}.gengage-chat-product-details-original-price{font-size:14px;color:#64748b;text-decoration:line-through}.gengage-chat-product-details-current-price{font-size:22px;font-weight:800;line-height:1.1;color:#0f172a}.gengage-chat-product-details-stock{width:fit-content;padding:4px 10px;border-radius:999px;font-size:12px;font-weight:700}.gengage-chat-product-details-stock.is-in-stock{background:#dcfce7;color:#166534}.gengage-chat-product-details-stock.is-out-of-stock{background:#fee2e2;color:#991b1b}.gengage-chat-product-details-actions{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin-top:4px}.gengage-chat-product-details-cta{display:inline-flex;align-items:center;justify-content:center;min-height:40px;padding:0 20px;border-radius:999px;border:none;text-decoration:none;background:var(--gengage-primary-color, #3b82f6);color:var(--gengage-primary-foreground, #fff);font-size:14px;font-weight:700;cursor:pointer;transition:filter .14s ease,transform .12s ease}.gengage-chat-product-details-cta:hover{filter:brightness(1.05);transform:translateY(-1px)}.gengage-chat-product-details-cta:active{transform:translateY(1px)}.gengage-chat-product-details-atc{display:inline-flex;align-items:center;justify-content:center;gap:6px;padding:10px 20px;border:none;border-radius:10px;background:var(--_gengage-success-color);color:#fff;font-size:14px;font-weight:700;font-family:inherit;cursor:pointer;transition:filter .12s ease,transform .12s ease}.gengage-chat-product-details-atc:hover{filter:brightness(1.08);transform:translateY(-1px)}.gengage-chat-product-details-atc:active{transform:translateY(1px)}.gengage-chat-product-detail-tabs{margin-top:4px;border-top:1px solid var(--_gengage-border-color);padding-top:12px}.gengage-chat-product-detail-tab-bar{display:flex;gap:0;border-bottom:2px solid var(--_gengage-border-color);margin-bottom:12px}.gengage-chat-product-detail-tab{flex:1;padding:8px 12px;border:none;background:transparent;color:var(--_gengage-text-secondary);font-size:13px;font-weight:600;font-family:inherit;cursor:pointer;border-bottom:2px solid transparent;margin-bottom:-2px;transition:color .15s,border-color .15s}.gengage-chat-product-detail-tab:hover{color:#334155}.gengage-chat-product-detail-tab--active{color:var(--gengage-primary-color, #3b82f6);border-bottom-color:var(--gengage-primary-color, #3b82f6)}.gengage-chat-product-detail-tab-panel{font-size:13px;line-height:1.6;color:#374151}.gengage-chat-product-specs-table{width:100%;border-collapse:collapse;font-size:13px}.gengage-chat-product-specs-table tr:nth-child(2n){background:#f8fafc}.gengage-chat-product-specs-key{padding:6px 10px;font-weight:600;color:#475569;white-space:nowrap;border-bottom:1px solid #f1f5f9;width:40%}.gengage-chat-product-specs-value{padding:6px 10px;color:#1f2937;border-bottom:1px solid #f1f5f9}.gengage-chat-product-card-atc{position:absolute;bottom:42px;right:6px;opacity:0;transition:opacity .15s ease;z-index:1}.gengage-chat-product-card:hover .gengage-chat-product-card-atc{opacity:1}.gengage-chat-drawer.gengage-chat-drawer--hidden{clip-path:inset(0 0 0 100%);opacity:0;pointer-events:none;box-shadow:none}.gengage-chat-root--mobile .gengage-chat-drawer.gengage-chat-drawer--hidden{clip-path:inset(100% 0 0 0);opacity:0;pointer-events:none;box-shadow:none}@media(max-width:900px){.gengage-chat-drawer--with-panel .gengage-chat-panel--visible{width:clamp(280px,calc(100vw - var(--_gengage-chat-conversation-width)),560px);max-width:560px}}.gengage-chat-attachment-preview{display:flex;align-items:center;gap:8px;padding:6px 10px;background:#f3f4f6;border:1px solid var(--_gengage-border-color);border-radius:8px;width:100%;box-sizing:border-box}.gengage-chat-attachment-preview--hidden{display:none}.gengage-chat-attachment-preview-thumb{width:40px;height:40px;border-radius:4px;object-fit:cover;flex-shrink:0}.gengage-chat-attachment-name{flex:1;font-size:12px;color:#4b5563;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.gengage-chat-attachment-remove{background:none;border:none;cursor:pointer;font-size:18px;color:#6b7280;padding:0 4px;line-height:1;flex-shrink:0}.gengage-chat-attachment-remove:hover{color:#ef4444}.gengage-chat-attach-btn{background:none;border:none;cursor:pointer;padding:6px;line-height:1;flex-shrink:0;display:flex;align-items:center;justify-content:center;border-radius:50%;color:#6b7280;transition:color .15s,background .15s}.gengage-chat-attach-btn:hover{color:#4b5563;background:#0000000d}.gengage-chat-attach-btn svg{width:20px;height:20px}.gengage-chat-mic-btn{background:none;border:none;cursor:pointer;padding:6px;line-height:1;flex-shrink:0;display:flex;align-items:center;justify-content:center;border-radius:50%;color:#6b7280;transition:color .15s,background .15s}.gengage-chat-mic-btn:hover{color:#4b5563;background:#0000000d}.gengage-chat-mic-btn svg{width:20px;height:20px}.gengage-chat-mic-btn--active{color:#ef4444;animation:gengage-mic-pulse 1.2s ease-in-out infinite}.gengage-chat-mic-btn--active:hover{color:#dc2626}@keyframes gengage-mic-pulse{0%,to{transform:scale(1);opacity:1}50%{transform:scale(1.15);opacity:.8}}.gengage-chat-input-area--dragover{outline:2px dashed var(--gengage-primary-color, #3b82f6);outline-offset:-2px;background:#eff6ff}.gengage-chat-attachment-thumb{width:120px;max-width:100%;height:auto;border-radius:8px;margin-bottom:6px;display:block}@media(max-width:768px){.gengage-chat-panel-divider{display:none}.gengage-chat-drawer--with-panel{left:0;right:0;width:100%;border-radius:0}.gengage-chat-drawer--with-panel .gengage-chat-body{flex-direction:column}.gengage-chat-drawer--with-panel .gengage-chat-panel--visible{width:100%;min-width:0;max-width:none;max-height:30dvh;border-right:none;border-bottom:1px solid var(--_gengage-border-color);padding:0 12px 12px;margin:0;border-radius:0;box-shadow:none}.gengage-chat-drawer--with-panel .gengage-chat-conversation{width:100%;flex:1;border-left:none}.gengage-chat-panel .gengage-chat-product-card{grid-template-columns:84px 1fr}.gengage-chat-panel .gengage-chat-product-card-cta{grid-column:1 / -1;width:100%}.gengage-chat-product-details-panel{padding:12px;gap:12px}.gengage-chat-product-details-media{min-height:140px}.gengage-chat-product-details-title{font-size:15px}.gengage-chat-product-details-current-price{font-size:20px}.gengage-chat-product-grid{scroll-snap-type:x mandatory}.gengage-chat-product-card{width:280px;min-width:280px;scroll-snap-align:center}.gengage-chat-product-card-img{height:180px}}@media(max-width:480px){.gengage-chat-drawer{position:fixed;inset:0;width:100%;max-height:100%;border-radius:0}.gengage-chat-bubble{max-width:100%}}.gengage-chat-kvkk-banner{display:flex;align-items:flex-start;gap:8px;padding:10px 14px;background:#fffbeb;border-bottom:1px solid #fde68a;font-size:12px;line-height:1.5;color:#92400e}.gengage-chat-kvkk-content{flex:1;min-width:0}.gengage-chat-kvkk-content a{color:#b45309;text-decoration:underline}.gengage-chat-kvkk-dismiss{flex-shrink:0;width:20px;height:20px;border:none;background:transparent;color:#92400e;font-size:16px;cursor:pointer;padding:0;line-height:1}.gengage-chat-comparison{padding:16px}.gengage-chat-comparison-heading{font-size:14px;font-weight:700;letter-spacing:.05em;color:#0f172a;margin:0 0 16px}.gengage-chat-comparison-recommended{border:1px solid var(--_gengage-border-color);border-radius:12px;padding:16px;background:#fff;box-shadow:0 1px 3px #0000000f;margin-bottom:12px}.gengage-chat-comparison-recommended-label{font-size:12px;font-weight:700;color:#16a34a;text-transform:uppercase;letter-spacing:.04em;margin-bottom:12px}.gengage-chat-comparison-recommended-body{display:flex;gap:12px;align-items:flex-start}.gengage-chat-comparison-recommended-body img{width:80px;height:80px;object-fit:contain;border-radius:8px;background:#f8fafc}.gengage-chat-comparison-recommended-info{flex:1;min-width:0}.gengage-chat-comparison-recommended-title{font-size:14px;font-weight:600;color:#0f172a;margin-bottom:4px}.gengage-chat-comparison-recommended-price{font-size:16px;font-weight:700;color:#0f172a}.gengage-chat-comparison-highlights{margin-top:12px;padding-top:12px;border-top:1px solid #f1f5f9}.gengage-chat-comparison-highlights-label{font-size:12px;font-weight:600;color:var(--_gengage-text-secondary);margin-bottom:6px}.gengage-chat-comparison-highlights ul{margin:0;padding-left:18px;font-size:13px;color:#334155;line-height:1.6}.gengage-chat-comparison-special{background:#fffbeb;border:1px solid #fde68a;border-radius:12px;padding:12px 16px;margin-bottom:12px;font-size:13px;color:#92400e}.gengage-chat-comparison-special summary{cursor:pointer;font-weight:600}.gengage-chat-comparison-special ul{margin:8px 0 0;padding-left:18px;line-height:1.6}.gengage-chat-comparison-table{width:100%;border-collapse:collapse;font-size:13px;margin-top:12px}.gengage-chat-comparison-table th,.gengage-chat-comparison-table td{padding:10px 12px;text-align:center;border-bottom:1px solid #f1f5f9;vertical-align:top}.gengage-chat-comparison-table th{font-weight:600;font-size:12px;color:#334155}.gengage-chat-comparison-table th img{width:60px;height:60px;object-fit:contain;border-radius:6px;background:#f8fafc;margin-bottom:6px}.gengage-chat-comparison-table-price{font-weight:700;color:#0f172a}.gengage-chat-comparison-label{text-align:left;font-weight:600;color:var(--_gengage-text-secondary);white-space:nowrap}.gengage-chat-comparison-selected{background:#f0fdf4}.gengage-chat-comparison-recommended-text{padding:8px 12px;font-size:12px;color:var(--gengage-text-secondary, #475569);font-style:italic;border-top:1px solid var(--gengage-border-color, #e2e8f0);margin-top:8px}.gengage-chat-comparison-product-actions{display:flex;gap:8px;margin-top:12px;flex-wrap:wrap}.gengage-chat-comparison-view-btn{flex:1;min-width:0;padding:8px 12px;border:1px solid var(--gengage-primary-color, #3b82f6);border-radius:6px;background:transparent;color:var(--gengage-primary-color, #3b82f6);font-size:12px;font-weight:500;font-family:inherit;cursor:pointer;transition:background .15s ease,color .15s ease;text-overflow:ellipsis;overflow:hidden;white-space:nowrap}.gengage-chat-comparison-view-btn:hover{background:var(--gengage-primary-color, #3b82f6);color:#fff}.gengage-chat-pills{position:relative;padding:8px 12px;border-top:1px solid #f1f5f9;background:var(--gengage-background-color, #fff)}.gengage-chat-pills-scroll{display:flex;gap:8px;overflow-x:auto;scrollbar-width:none;-webkit-overflow-scrolling:touch;padding-right:28px}.gengage-chat-pills-scroll::-webkit-scrollbar{display:none}.gengage-chat-pill{flex:0 0 auto;padding:8px 16px;border:none;border-radius:999px;background:var(--gengage-primary-color, #3b82f6);color:var(--gengage-primary-foreground, #fff);font-size:13px;font-weight:600;font-family:inherit;white-space:nowrap;cursor:pointer;transition:filter .15s,transform .1s}.gengage-chat-pill:hover{filter:brightness(.92)}.gengage-chat-pill:active{transform:scale(.97)}.gengage-chat-pill--rich{display:flex;align-items:center;gap:8px;padding:6px 14px 6px 6px;border-radius:20px}.gengage-chat-pill-img{width:32px;height:32px;border-radius:50%;object-fit:cover;flex-shrink:0;background:#ffffff26}.gengage-chat-pill-text{font-size:13px;font-weight:600;line-height:1.2}.gengage-chat-pill-desc{display:none}.gengage-chat-pill--rich .gengage-chat-pill-desc{display:block;font-size:10px;font-weight:400;opacity:.8;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:160px}.gengage-chat-pills-arrow{position:absolute;right:8px;top:50%;transform:translateY(-50%);width:28px;height:28px;border-radius:50%;border:1px solid var(--_gengage-border-color);background:#fff;color:var(--_gengage-text-secondary);font-size:16px;cursor:pointer;display:flex;align-items:center;justify-content:center;box-shadow:-4px 0 8px #ffffffe6;z-index:1}.gengage-chat-pills-arrow:hover{background:#f8fafc;color:#334155}@media(prefers-reduced-motion:reduce){.gengage-chat-uispec>*,.gengage-chat-action-btn,.gengage-chat-product-card,.gengage-chat-product-card-cta,.gengage-chat-send,.gengage-chat-launcher,.gengage-chat-pill,.gengage-chat-drawer,.gengage-chat-proactive,.gengage-chat-typing-dots span,.gengage-chat-typing-sparkle,.gengage-chat-thinking-step-marker--active,.gengage-chat-bubble,.gengage-chat-panel-skeleton-block,.gengage-chat-ai-toppick-card,.gengage-chat-mic-btn--active,.gengage-chat-ai-toppick-spinner:after,.gengage-chat-panel-shimmer,.gengage-chat-overlay,.gengage-chat-product-details-skeleton-price{animation:none!important;transition:none!important;transform:none!important}}.gengage-chat-bubble--user{position:relative}.gengage-chat-rollback-btn{position:absolute;left:-28px;top:50%;transform:translateY(-50%);width:24px;height:24px;border:none;border-radius:50%;background:var(--gengage-surface-color, #f1f5f9);color:var(--gengage-text-secondary, #64748b);cursor:pointer;display:flex;align-items:center;justify-content:center;opacity:0;transition:opacity .15s ease;padding:0}.gengage-chat-bubble--user:hover .gengage-chat-rollback-btn{opacity:1}.gengage-chat-rollback-btn:hover{background:var(--gengage-primary-color, #3b82f6);color:#fff}.gengage-chat-bubble--hidden{display:none}.gengage-chat-ai-top-picks{display:flex;flex-direction:column;gap:12px;padding:8px 0}.gengage-chat-ai-top-picks-title{font-size:15px;font-weight:600;color:var(--gengage-text-primary, #1e293b);margin:0 0 4px}.gengage-chat-ai-top-picks-cards{display:flex;flex-direction:column;gap:10px}.gengage-chat-ai-toppick-discount-badge{position:absolute;top:8px;left:8px;background:var(--gengage-discount-bg, #ef4444);color:#fff;font-size:11px;font-weight:700;padding:2px 6px;border-radius:4px;z-index:1}.gengage-chat-ai-toppick-card--winner{position:relative;display:flex;flex-direction:column;border:2px solid var(--gengage-primary-color, #3b82f6);border-radius:12px;background:#fff;overflow:hidden;transition:box-shadow .2s ease}.gengage-chat-ai-toppick-card--winner:hover{box-shadow:0 4px 16px #3b82f626}.gengage-chat-ai-toppick-card--winner .gengage-chat-ai-toppick-img{width:100%;height:140px;object-fit:contain;background:#f8fafc}.gengage-chat-ai-toppick-card--compact{position:relative;display:flex;flex-direction:row;align-items:center;gap:12px;border:1px solid var(--gengage-border-color, #e2e8f0);border-radius:10px;background:#fff;padding:10px;transition:box-shadow .2s ease,transform .15s ease}.gengage-chat-ai-toppick-card--compact:hover{box-shadow:0 2px 8px #00000014;transform:translateY(-1px)}.gengage-chat-ai-toppick-card--compact .gengage-chat-ai-toppick-img{width:64px;height:64px;object-fit:contain;border-radius:8px;background:#f8fafc;flex-shrink:0}.gengage-chat-ai-toppick-badge{position:absolute;top:8px;left:8px;background:var(--gengage-primary-color, #3b82f6);color:#fff;font-size:10px;font-weight:700;text-transform:uppercase;padding:2px 8px;border-radius:4px;z-index:1;letter-spacing:.5px}.gengage-chat-ai-toppick-body{display:flex;flex-direction:column;gap:4px;padding:10px;flex:1;min-width:0}.gengage-chat-ai-toppick-card--compact .gengage-chat-ai-toppick-body{padding:0}.gengage-chat-ai-toppick-name{font-size:13px;font-weight:600;color:var(--gengage-text-primary, #1e293b);overflow:hidden;text-overflow:ellipsis;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical}.gengage-chat-ai-toppick-role{font-size:11px;font-weight:600;color:var(--gengage-primary-color, #3b82f6);text-transform:uppercase;letter-spacing:.3px}.gengage-chat-ai-toppick-labels{display:flex;flex-wrap:wrap;gap:4px}.gengage-chat-ai-toppick-label{font-size:11px;padding:1px 6px;border-radius:4px;font-weight:500}.gengage-chat-ai-toppick-label[data-sentiment=positive]{background:#dcfce7;color:#166534}.gengage-chat-ai-toppick-label[data-sentiment=negative]{background:#fee2e2;color:#991b1b}.gengage-chat-ai-toppick-label[data-sentiment=neutral]{background:#f1f5f9;color:#475569}.gengage-chat-ai-toppick-score{font-size:12px;font-weight:700;color:var(--gengage-primary-color, #3b82f6)}.gengage-chat-ai-toppick-reason{font-size:12px;color:var(--gengage-chat-text-secondary, #666);line-height:1.4;margin-top:4px}.gengage-chat-ai-toppick-review{font-size:12px;font-style:italic;color:var(--gengage-text-secondary, #64748b);margin:2px 0;padding-left:8px;border-left:2px solid var(--gengage-border-color, #e2e8f0)}.gengage-chat-ai-toppick-price{font-size:14px;font-weight:700;color:var(--gengage-text-primary, #1e293b)}.gengage-chat-ai-toppick-original-price{text-decoration:line-through;color:var(--gengage-text-secondary, #64748b);font-weight:400;font-size:12px}.gengage-chat-ai-toppick-cta{display:block;width:calc(100% - 20px);margin:6px 10px 10px;padding:8px 0;border:none;border-radius:8px;background:var(--gengage-primary-color, #3b82f6);color:#fff;font-size:13px;font-weight:600;cursor:pointer;text-align:center;transition:background .15s ease}.gengage-chat-ai-toppick-cta:hover{filter:brightness(.92)}.gengage-chat-ai-toppick-card--compact .gengage-chat-ai-toppick-cta{width:auto;margin:0;padding:6px 14px;flex-shrink:0;align-self:center}.gengage-chat-ai-toppick-spinner{position:absolute;inset:0;background:#ffffffb3;display:flex;align-items:center;justify-content:center;border-radius:12px;z-index:3}.gengage-chat-ai-toppick-spinner:after{content:"";width:24px;height:24px;border:3px solid var(--gengage-border, #e2e8f0);border-top-color:var(--gengage-accent-primary, #3b82f6);border-radius:50%;animation:gengage-spin .7s linear infinite}@keyframes gengage-spin{to{transform:rotate(360deg)}}@media(max-width:768px){.gengage-chat-ai-top-picks-cards{flex-direction:row;overflow-x:auto;scroll-snap-type:x mandatory;-webkit-overflow-scrolling:touch;gap:10px;padding-bottom:4px}.gengage-chat-ai-toppick-card--winner,.gengage-chat-ai-toppick-card--compact{min-width:280px;max-width:280px;flex-shrink:0;scroll-snap-align:start}.gengage-chat-ai-toppick-card--compact{flex-direction:column;align-items:stretch}.gengage-chat-ai-toppick-card--compact .gengage-chat-ai-toppick-img{width:100%;height:100px;border-radius:8px 8px 0 0}.gengage-chat-ai-toppick-card--compact .gengage-chat-ai-toppick-cta{width:calc(100% - 20px);margin:6px 10px 10px;align-self:stretch}.gengage-chat-rollback-btn{left:-24px}}.gengage-chat-grounding-review{display:flex;align-items:center;gap:12px;padding:12px 16px;background:var(--gengage-surface-color, #f8fafc);border:1px solid var(--gengage-border-color, #e2e8f0);border-radius:10px;transition:background .15s ease,border-color .15s ease}.gengage-chat-grounding-review:hover{background:var(--gengage-hover-color, #f1f5f9);border-color:var(--gengage-primary-color, #3b82f6)}.gengage-chat-grounding-review-icon{font-size:20px;flex-shrink:0}.gengage-chat-grounding-review-body{flex:1;min-width:0}.gengage-chat-grounding-review-title{font-weight:600;font-size:13px;color:var(--gengage-text-color, #1e293b)}.gengage-chat-grounding-review-subtitle{font-size:12px;color:var(--gengage-text-muted, #64748b);margin-top:2px}.gengage-chat-grounding-review-cta{font-size:13px;font-weight:500;color:var(--gengage-primary-color, #3b82f6);white-space:nowrap;flex-shrink:0}.gengage-chat-grouping-cards{display:flex;flex-direction:column;gap:6px}.gengage-chat-grouping-card{display:flex;align-items:center;gap:10px;padding:8px 12px;background:var(--gengage-surface-color, #f8fafc);border:1px solid var(--gengage-border-color, #e2e8f0);border-radius:8px;transition:background .15s ease,border-color .15s ease}.gengage-chat-grouping-card:hover{background:var(--gengage-hover-color, #f1f5f9);border-color:var(--gengage-primary-color, #3b82f6)}.gengage-chat-grouping-card-arrow{display:none;font-size:14px;color:var(--gengage-primary-color, #3b82f6);flex-shrink:0}.gengage-chat-grouping-card-img{width:20px;height:20px;border-radius:4px;object-fit:cover;flex-shrink:0}.gengage-chat-grouping-card-body{flex:1;min-width:0;display:flex;align-items:baseline;gap:6px;flex-wrap:wrap}.gengage-chat-grouping-card-name{font-weight:600;font-size:13px;color:var(--gengage-text-color, #1e293b)}.gengage-chat-grouping-card-desc{font-size:12px;color:var(--gengage-text-muted, #64748b)}.gengage-chat-grouping-card-labels{display:block;font-size:11px;color:var(--gengage-chat-text-secondary, #888);margin-top:2px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.gengage-chat-root--mobile .gengage-chat-grouping-card-img{display:none}.gengage-chat-root--mobile .gengage-chat-grouping-card-arrow{display:inline}.gengage-chat-suggested-search-cards{display:flex;flex-direction:column;gap:8px}.gengage-chat-suggested-search-card{display:flex;align-items:flex-start;gap:12px;padding:10px 14px;background:var(--gengage-surface-color, #f8fafc);border:1px solid var(--gengage-border-color, #e2e8f0);border-radius:10px;transition:background .15s ease,border-color .15s ease}.gengage-chat-suggested-search-card:hover{background:var(--gengage-hover-color, #f1f5f9);border-color:var(--gengage-primary-color, #3b82f6)}.gengage-chat-suggested-search-card-img{width:40px;height:40px;border-radius:6px;object-fit:cover;flex-shrink:0}.gengage-chat-suggested-search-card-body{flex:1;min-width:0}.gengage-chat-suggested-search-card-name{font-weight:600;font-size:13px;color:var(--gengage-text-color, #1e293b)}.gengage-chat-suggested-search-card-desc{font-size:12px;color:var(--gengage-text-secondary, #475569);margin-top:2px}.gengage-chat-suggested-search-card-diff{font-size:11px;color:var(--gengage-text-muted, #64748b);margin-top:2px;font-style:italic}.gengage-chat-product-details-gallery{position:relative}.gengage-chat-product-details-gallery .gengage-chat-product-details-img{touch-action:pan-y}.gengage-chat-product-gallery-thumbs{display:flex;gap:8px;padding:10px 0 4px;overflow-x:auto;scrollbar-width:thin;justify-content:center;width:100%}.gengage-chat-product-gallery-thumb{width:56px;height:56px;object-fit:cover;border-radius:8px;border:2px solid transparent;cursor:pointer;flex-shrink:0;transition:border-color .15s ease;background:#fff}.gengage-chat-product-gallery-thumb:hover{border-color:var(--gengage-border-color, #cbd5e1)}.gengage-chat-product-gallery-thumb--active{border-color:var(--gengage-primary-color, #3b82f6)}.gengage-chat-product-variants{margin-top:12px}.gengage-chat-product-variants-label{font-size:12px;font-weight:600;color:var(--gengage-text-muted, #64748b);margin-bottom:6px;text-transform:uppercase;letter-spacing:.5px}.gengage-chat-product-variants-list{display:flex;flex-wrap:wrap;gap:6px}.gengage-chat-product-variant-btn{padding:6px 12px;border:1px solid var(--gengage-border-color, #e2e8f0);border-radius:6px;background:var(--gengage-surface-color, #f8fafc);color:var(--gengage-text-color, #1e293b);font-size:12px;cursor:pointer;transition:background .15s ease,border-color .15s ease}.gengage-chat-product-variant-btn:hover{background:var(--gengage-hover-color, #f1f5f9);border-color:var(--gengage-primary-color, #3b82f6)}.gengage-chat-product-grid-wrapper{display:flex;flex-direction:column;gap:8px}.gengage-chat-product-sort-toolbar{display:flex;gap:4px;padding:4px;background:var(--gengage-surface-color, #f8fafc);border-radius:8px;border:1px solid var(--gengage-border-color, #e2e8f0)}.gengage-chat-product-sort-btn{flex:1;padding:6px 10px;border:none;border-radius:6px;background:transparent;color:var(--gengage-text-muted, #64748b);font-size:12px;font-weight:500;cursor:pointer;transition:background .15s ease,color .15s ease}.gengage-chat-product-sort-btn:hover{background:var(--gengage-hover-color, #f1f5f9);color:var(--gengage-text-color, #1e293b)}.gengage-chat-product-sort-btn--active,.gengage-chat-product-sort-btn--active:hover{background:var(--gengage-primary-color, #3b82f6);color:#fff}.gengage-chat-product-sort-separator{width:1px;background:var(--gengage-border-color, #e2e8f0);margin:2px}.gengage-chat-comparison-toggle-btn{flex:none;padding:6px 10px;border:none;border-radius:6px;background:transparent;color:var(--gengage-text-muted, #64748b);font-size:12px;font-weight:500;cursor:pointer;transition:background .15s ease,color .15s ease;white-space:nowrap}.gengage-chat-comparison-toggle-btn:hover{background:var(--gengage-hover-color, #f1f5f9);color:var(--gengage-text-color, #1e293b)}.gengage-chat-comparison-toggle-btn--active,.gengage-chat-comparison-toggle-btn--active:hover{background:var(--gengage-primary-color, #3b82f6);color:#fff}.gengage-chat-comparison-select-wrapper{position:relative}.gengage-chat-comparison-checkbox{position:absolute;top:8px;left:8px;z-index:2;width:18px;height:18px;cursor:pointer;accent-color:var(--gengage-primary-color, #3b82f6)}.gengage-chat-comparison-floating-btn{display:block;width:100%;margin-top:8px;padding:10px 16px;border:none;border-radius:8px;background:var(--gengage-primary-color, #3b82f6);color:#fff;font-size:14px;font-weight:600;cursor:pointer;transition:background .15s ease;text-align:center}.gengage-chat-comparison-floating-btn:hover{background:var(--gengage-primary-hover, #2563eb)}.gengage-chat-panel-topbar{display:flex;align-items:center;gap:8px;padding:10px 12px;border-bottom:1px solid var(--_gengage-border-color);background:#f8fafc;min-height:44px;flex-shrink:0;position:sticky;top:0;z-index:3}.gengage-chat-panel-topbar-back,.gengage-chat-panel-topbar-forward{width:28px;height:28px;min-width:28px;padding:0;border:1px solid #d1d5db;border-radius:6px;background:transparent;color:#374151;font-size:14px;font-family:inherit;cursor:pointer;display:flex;align-items:center;justify-content:center;transition:background .15s ease,border-color .15s ease,opacity .15s ease}.gengage-chat-panel-topbar-back:hover:not(:disabled),.gengage-chat-panel-topbar-forward:hover:not(:disabled){background:#f3f4f6;border-color:#9ca3af}.gengage-chat-panel-topbar-back:disabled,.gengage-chat-panel-topbar-forward:disabled{opacity:.3;cursor:default}.gengage-chat-panel-topbar-title{flex:1;font-size:14px;font-weight:600;color:#1f2937;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;text-align:center}@keyframes gengage-typewriter-fade-in{0%{opacity:0;transform:translateY(4px)}to{opacity:1;transform:translateY(0)}}.gengage-chat-typewriter-block{display:block;animation:gengage-typewriter-fade-in .15s ease both}@media(prefers-reduced-motion:reduce){.gengage-chat-typewriter-block{animation:none}}.gengage-product-mention{color:var(--gengage-primary-color, #3b82f6);text-decoration:none;cursor:pointer;font-weight:500;border-bottom:1px dashed var(--gengage-primary-color, #3b82f6);transition:border-color .15s}.gengage-product-mention:hover{border-bottom-style:solid}@keyframes gengage-skeleton-pulse{0%,to{opacity:.4}50%{opacity:.8}}.gengage-chat-panel-skeleton-block{animation:gengage-skeleton-pulse 1.5s ease-in-out infinite}@media(prefers-reduced-motion:reduce){.gengage-chat-panel-skeleton-block{animation:none}}.gengage-chat-input-chips{display:flex;gap:6px;padding:4px 12px 2px;flex-wrap:wrap}.gengage-chat-input-chip{display:inline-flex;align-items:center;padding:4px 10px;border-radius:12px;border:1px solid var(--_gengage-border-color);background:#f9fafb;color:#374151;font-size:12px;font-weight:500;font-family:inherit;cursor:pointer;transition:background .12s,border-color .12s;white-space:nowrap}.gengage-chat-input-chip:hover{background:#f3f4f6;border-color:#d1d5db}.gengage-chat-icon{width:14px;height:14px;flex-shrink:0}.gengage-chat-input-chip-icon,.gengage-chat-pill-icon{display:inline-flex;align-items:center;margin-right:4px}.gengage-chat-product-card-img-wrapper,.gengage-chat-product-details-img-wrap{position:relative;overflow:hidden}.gengage-chat-product-card-discount-badge{position:absolute;top:6px;left:6px;padding:2px 6px;border-radius:4px;background:var(--_gengage-discount-color);color:#fff;font-size:11px;font-weight:700;line-height:1.3;z-index:1}.gengage-chat-product-card-stock{font-size:11px;font-weight:600;margin-top:2px}.gengage-chat-product-card-stock.is-in-stock{color:var(--_gengage-success-color)}.gengage-chat-product-card-stock.is-out-of-stock{color:#dc2626}.gengage-chat-find-similar-pill{position:absolute;top:8px;right:8px;opacity:0;pointer-events:none;transition:opacity .2s ease;padding:4px 10px;font-size:11px;font-weight:500;font-family:inherit;border:none;border-radius:12px;background:var(--gengage-chat-pill-bg, rgba(0, 0, 0, .7));color:var(--gengage-chat-pill-text, #fff);cursor:pointer;white-space:nowrap;z-index:2}.gengage-chat-product-card-img-wrapper:hover .gengage-chat-find-similar-pill,.gengage-chat-product-details-img-wrap:hover .gengage-chat-find-similar-pill{opacity:1;pointer-events:auto}.gengage-chat-favorite-btn{position:absolute;top:8px;right:8px;background:#ffffffe6;border:none;border-radius:50%;width:28px;height:28px;display:flex;align-items:center;justify-content:center;cursor:pointer;color:var(--gengage-text-secondary, #64748b);z-index:3;transition:color .2s;padding:0}.gengage-chat-favorite-btn:hover,.gengage-chat-favorite-btn--active{color:var(--gengage-accent-primary, #ef4444)}.gengage-chat-product-card-promos,.gengage-chat-product-details-promos{display:flex;flex-wrap:wrap;gap:4px;margin-top:4px}.gengage-chat-product-card-promo-badge,.gengage-chat-product-details-promo-badge{display:inline-block;padding:2px 6px;font-size:10px;font-weight:500;border-radius:4px;background:var(--gengage-chat-promo-bg, #e8f5e9);color:var(--gengage-chat-promo-text, #2e7d32);white-space:nowrap}.gengage-chat-thumbnails-column{position:absolute;right:4px;top:50%;transform:translateY(-50%);display:flex;flex-direction:column;gap:4px;z-index:2;pointer-events:auto}.gengage-chat-thumbnail-btn{display:flex;align-items:center;justify-content:center;width:40px;height:40px;padding:0;border:2px solid #e5e7eb;border-radius:6px;background:#fff;cursor:pointer;overflow:hidden;transition:border-color .15s ease}.gengage-chat-thumbnail-btn:hover{border-color:var(--gengage-primary-color, #3b82f6)}.gengage-chat-thumbnail-img{width:100%;height:100%;object-fit:cover}.gengage-chat-choice-prompter{position:absolute;bottom:12px;right:12px;width:200px;padding:12px 14px;background:#fff;border:1px solid var(--_gengage-border-color);border-radius:10px;box-shadow:0 4px 12px #0000001a;z-index:10;animation:gengage-choice-prompter-in .2s ease}@keyframes gengage-choice-prompter-in{0%{opacity:0;transform:translateY(8px)}to{opacity:1;transform:translateY(0)}}.gengage-chat-choice-prompter-heading{font-size:13px;font-weight:600;color:#1f2937;margin-bottom:4px}.gengage-chat-choice-prompter-suggestion{font-size:12px;color:#6b7280;margin-bottom:10px;line-height:1.4}.gengage-chat-choice-prompter-cta{display:block;width:100%;padding:6px 12px;border:none;border-radius:6px;background:var(--gengage-primary-color, #3b82f6);color:#fff;font-size:12px;font-weight:600;font-family:inherit;cursor:pointer;text-align:center;transition:opacity .15s ease}.gengage-chat-choice-prompter-cta:hover{opacity:.9}.gengage-chat-choice-prompter-dismiss{position:absolute;top:4px;right:6px;padding:2px 6px;border:none;background:none;color:#6b7280;font-size:16px;cursor:pointer;line-height:1}.gengage-chat-choice-prompter-dismiss:hover{color:#6b7280}@media(prefers-reduced-motion:reduce){.gengage-chat-choice-prompter{animation:none}}.gengage-chat-pros-cons{padding:12px 14px;background:#f8fafc;border-radius:8px;margin:8px 0}.gengage-chat-pros-cons-heading{margin:0 0 10px;font-size:14px;font-weight:600;color:#0f172a}.gengage-chat-pros-cons-list{list-style:none;margin:0 0 8px;padding:0}.gengage-chat-pros-cons-list:last-child{margin-bottom:0}.gengage-chat-pros-cons-item{display:flex;align-items:flex-start;gap:8px;padding:4px 0;font-size:13px;line-height:1.5;color:#334155}.gengage-chat-pros-cons-icon{flex-shrink:0;width:18px;height:18px;display:flex;align-items:center;justify-content:center;font-size:12px;font-weight:700;border-radius:50%}.gengage-chat-pros-cons-icon--pro{color:#16a34a;background:#dcfce7}.gengage-chat-pros-cons-icon--con{color:#dc2626;background:#fee2e2}.gengage-chat-categories{display:flex;flex-direction:column;gap:8px}.gengage-chat-categories-tabs{display:flex;gap:4px;overflow-x:auto;padding:4px 0;-webkit-overflow-scrolling:touch}.gengage-chat-categories-tab{padding:6px 14px;border:1px solid var(--gengage-border-color, #e5e7eb);border-radius:20px;background:var(--gengage-bg, #fff);color:var(--gengage-text, #374151);cursor:pointer;white-space:nowrap;font-size:13px;transition:background .15s,color .15s}.gengage-chat-categories-tab:hover{background:var(--gengage-bg-hover, #f3f4f6)}.gengage-chat-categories-tab--active{background:var(--gengage-primary, #2563eb);color:#fff;border-color:var(--gengage-primary, #2563eb)}.gengage-chat-categories-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(140px,1fr));gap:8px}.gengage-chat-categories-filter-tags{display:flex;gap:6px;flex-wrap:wrap;margin-top:4px}.gengage-chat-categories-filter-tag{padding:4px 10px;border:1px solid var(--gengage-border-color, #e5e7eb);border-radius:14px;background:var(--gengage-bg, #fff);color:var(--gengage-text-secondary, #6b7280);font-size:12px;cursor:pointer;transition:background .15s}.gengage-chat-categories-filter-tag:hover{background:var(--gengage-bg-hover, #f3f4f6)}.gengage-chat-product-grid-view-more{display:block;width:100%;padding:10px;margin-top:8px;border:1px solid var(--gengage-border-color, #e5e7eb);border-radius:8px;background:var(--gengage-bg, #fff);color:var(--gengage-primary, #2563eb);font-size:14px;font-weight:500;cursor:pointer;text-align:center;transition:background .15s;grid-column:1 / -1}.gengage-chat-product-grid-view-more:hover{background:var(--gengage-bg-hover, #f3f4f6)}.gengage-chat-product-grid--mobile{display:flex;overflow-x:auto;gap:8px;padding:8px 0;-webkit-overflow-scrolling:touch}.gengage-chat-product-grid--mobile .gengage-chat-product-card{min-width:160px;max-width:180px;flex-shrink:0}.gengage-chat-comparison--mobile .gengage-chat-comparison-table,.gengage-chat-comparison--mobile .gengage-chat-comparison-table thead,.gengage-chat-comparison--mobile .gengage-chat-comparison-table tbody{display:block}.gengage-chat-comparison--mobile .gengage-chat-comparison-table tr{display:flex;flex-wrap:wrap}.gengage-chat-comparison-key-differences{margin-top:12px;padding:12px;background:var(--gengage-bg-secondary, #f9fafb);border-radius:8px}.gengage-chat-comparison-key-differences h4{margin:0 0 8px;font-size:14px;font-weight:600;color:var(--gengage-text, #374151)}.gengage-chat-comparison-key-differences-content{font-size:13px;color:var(--gengage-text-secondary, #6b7280);line-height:1.5}.gengage-chat-comparison-key-differences-content ul{margin:0;padding-left:18px}.gengage-chat-comparison-key-differences-content li{margin-bottom:4px}.gengage-chat-product-details-similars-heading{margin:16px 0 8px;font-size:15px;font-weight:600;color:var(--gengage-text, #374151)}.gengage-chat-product-details-similars{margin-top:8px}.gengage-chat-handoff-notice{display:flex;flex-direction:column;align-items:center;gap:6px;padding:16px;margin:8px 0;background:#fef3c7;border:1px solid #fcd34d;border-radius:8px;text-align:center}.gengage-chat-handoff-notice-icon{font-size:24px}.gengage-chat-handoff-notice-heading{margin:0;font-size:14px;font-weight:600;color:#92400e}.gengage-chat-handoff-notice-summary{margin:0;font-size:13px;line-height:1.5;color:#78350f}.gengage-qty-stepper{display:inline-flex;align-items:center;gap:0;border:1px solid #d1d5db;border-radius:8px;overflow:hidden;background:#fff}.gengage-qty-btn{width:var(--_gengage-qty-btn-size);height:var(--_gengage-qty-btn-size);border:none;background:transparent;color:#374151;font-size:14px;font-weight:600;font-family:inherit;cursor:pointer;display:flex;align-items:center;justify-content:center;transition:background-color .12s}.gengage-qty-btn:hover:not(:disabled){background:#f3f4f6}.gengage-qty-btn:disabled{opacity:.35;cursor:default}.gengage-qty-value{min-width:24px;text-align:center;font-size:13px;font-weight:600;color:#1f2937;-webkit-user-select:none;user-select:none}.gengage-qty-submit{border:none;border-left:1px solid #d1d5db;background:var(--_gengage-success-color);color:#fff;font-size:13px;font-weight:700;font-family:inherit;cursor:pointer;padding:6px 12px;transition:filter .12s ease,transform .12s ease}.gengage-qty-submit:hover{filter:brightness(1.08)}.gengage-qty-submit:active{transform:translateY(1px)}.gengage-qty-stepper--compact{border-radius:14px;box-shadow:0 2px 6px #0000001f}.gengage-qty-stepper--compact .gengage-qty-btn{width:var(--_gengage-qty-btn-size-compact);height:var(--_gengage-qty-btn-size-compact);font-size:12px}.gengage-qty-stepper--compact .gengage-qty-value{min-width:18px;font-size:12px}.gengage-qty-stepper--compact .gengage-qty-submit{padding:4px 8px;font-size:13px;border-radius:0 14px 14px 0}.gengage-chat-product-details-atc-stepper{border-radius:10px}.gengage-chat-product-details-atc-stepper .gengage-qty-btn{width:32px;height:32px}.gengage-chat-product-details-atc-stepper .gengage-qty-value{min-width:28px;font-size:14px}.gengage-chat-product-details-atc-stepper .gengage-qty-submit{padding:8px 18px;font-size:14px;border-radius:0 10px 10px 0}.gengage-chat-product-details-share{display:inline-flex;align-items:center;justify-content:center;width:36px;height:36px;border:1px solid #d1d5db;border-radius:10px;background:transparent;color:#6b7280;cursor:pointer;transition:color .12s,border-color .12s,background-color .12s;position:relative;flex-shrink:0}.gengage-chat-product-details-share:hover{color:var(--gengage-primary-color, #3b82f6);border-color:var(--gengage-primary-color, #3b82f6);background:#f0f7ff}.gengage-chat-product-details-share:before{content:attr(aria-label);position:absolute;bottom:calc(100% + 6px);left:50%;transform:translate(-50%);padding:4px 8px;border-radius:4px;background:#1e293b;color:#fff;font-size:11px;font-weight:500;white-space:nowrap;pointer-events:none;opacity:0;transition:opacity .15s ease;z-index:2}.gengage-chat-product-details-share:hover:before{opacity:1}.gengage-chat-product-details-share--copied:after{content:"✓";position:absolute;inset:0;display:flex;align-items:center;justify-content:center;background:var(--_gengage-success-color);color:#fff;border-radius:10px;font-size:16px;font-weight:700}.gengage-chat-launcher:focus-visible,.gengage-chat-close:focus-visible,.gengage-chat-header-btn:focus-visible,.gengage-chat-header-powered:focus-visible,.gengage-chat-proactive-accept:focus-visible,.gengage-chat-proactive-dismiss:focus-visible,.gengage-chat-send:focus-visible,.gengage-chat-action-btn:focus-visible,.gengage-chat-pill:focus-visible,.gengage-chat-input-chip:focus-visible,.gengage-chat-pills-arrow:focus-visible,.gengage-chat-error-retry:focus-visible,.gengage-chat-product-card-cta:focus-visible,.gengage-chat-product-details-cta:focus-visible,.gengage-chat-product-details-atc:focus-visible,.gengage-chat-product-detail-tab:focus-visible,.gengage-chat-panel-divider-toggle:focus-visible,.gengage-chat-panel-topbar-back:focus-visible,.gengage-chat-panel-topbar-forward:focus-visible,.gengage-chat-rollback-btn:focus-visible,.gengage-chat-ai-toppick-cta:focus-visible,.gengage-chat-comparison-view-btn:focus-visible,.gengage-chat-comparison-toggle-btn:focus-visible,.gengage-chat-comparison-floating-btn:focus-visible,.gengage-chat-comparison-checkbox:focus-visible,.gengage-chat-product-sort-btn:focus-visible,.gengage-chat-product-variant-btn:focus-visible,.gengage-chat-product-gallery-thumb:focus-visible,.gengage-chat-thumbnail-btn:focus-visible,.gengage-chat-find-similar-pill:focus-visible,.gengage-chat-favorite-btn:focus-visible,.gengage-chat-attach-btn:focus-visible,.gengage-chat-mic-btn:focus-visible,.gengage-chat-attachment-remove:focus-visible,.gengage-chat-kvkk-dismiss:focus-visible,.gengage-chat-choice-prompter-cta:focus-visible,.gengage-chat-choice-prompter-dismiss:focus-visible,.gengage-chat-categories-tab:focus-visible,.gengage-chat-categories-filter-tag:focus-visible,.gengage-chat-product-grid-view-more:focus-visible,.gengage-chat-product-details-share:focus-visible,.gengage-qty-btn:focus-visible,.gengage-qty-submit:focus-visible{outline:2px solid var(--gengage-primary-color, #3b82f6);outline-offset:2px}', Ha = L({
3028
- role: me(["user", "assistant"]),
3060
+ const Fa = ':host{all:initial;font-family:var(--gengage-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif);font-size:var(--gengage-font-size, 14px)}.gengage-chat-root{position:fixed;z-index:var(--gengage-z-index, 2147483647);--_gengage-chat-offset: var(--gengage-chat-offset, 20px);--_gengage-chat-launcher-bottom: var(--gengage-chat-launcher-bottom, 20px);--_gengage-chat-launcher-right: var(--gengage-chat-launcher-right, 20px);--_gengage-chat-launcher-size: var(--gengage-chat-launcher-size, 56px);--_gengage-chat-drawer-width: var(--gengage-chat-width, 400px);--_gengage-chat-radius: var(--gengage-chat-shell-radius, 12px);--_gengage-chat-header-height: var(--gengage-chat-header-height, 60px);--_gengage-chat-conversation-width: var(--gengage-chat-conversation-width, 396px);--_gengage-chat-panel-min-width: var(--gengage-chat-panel-min-width, 320px);--_gengage-chat-panel-max-width: var(--gengage-chat-panel-max-width, 860px);--_gengage-chat-input-height: var(--gengage-chat-input-height, 48px);--_gengage-chat-shadow: var(--gengage-chat-shadow, 0 12px 40px rgba(15, 23, 42, .18));--_gengage-border-color: var(--gengage-border-color, #e5e7eb);--_gengage-discount-color: var(--gengage-discount-color, #ef4444);--_gengage-success-color: var(--gengage-success-color, #16a34a);--_gengage-text-secondary: var(--gengage-text-secondary, #64748b);--_gengage-qty-btn-size: var(--gengage-qty-btn-size, 28px);--_gengage-qty-btn-size-compact: var(--gengage-qty-btn-size-compact, 24px)}.gengage-chat-launcher-container{position:fixed;bottom:var(--_gengage-chat-launcher-bottom);right:var(--_gengage-chat-launcher-right);display:flex;flex-direction:column;align-items:flex-end;gap:10px;z-index:var(--gengage-z-index, 2147483647)}.gengage-chat-launcher-content-area,.gengage-chat-launcher-content-area-bottom{display:flex;flex-direction:column;align-items:flex-end;gap:8px}.gengage-chat-launcher-content-area:empty,.gengage-chat-launcher-content-area-bottom:empty{display:none}.gengage-chat-root--open .gengage-chat-launcher-content-area,.gengage-chat-root--open .gengage-chat-launcher-content-area-bottom{display:none}.gengage-chat-launcher{width:var(--_gengage-chat-launcher-size);height:var(--_gengage-chat-launcher-size);border-radius:50%;border:none;background:var(--gengage-primary-color, #3b82f6);color:var(--gengage-primary-foreground, #fff);cursor:pointer;display:flex;align-items:center;justify-content:center;box-shadow:0 8px 22px #0f172a47;transition:transform .18s cubic-bezier(.2,.8,.2,1),box-shadow .18s ease;position:relative;flex-shrink:0}.gengage-chat-launcher:hover{transform:scale(1.05);box-shadow:0 14px 28px #0f172a47}.gengage-chat-launcher svg{width:24px;height:24px}.gengage-chat-launcher--hidden-mobile{display:none!important}.gengage-chat-launcher-tooltip{position:absolute;right:calc(100% + 12px);top:50%;transform:translateY(-50%);padding:6px 12px;border-radius:8px;background:#1e293b;color:#fff;font-size:13px;font-weight:500;white-space:nowrap;opacity:0;pointer-events:none;transition:opacity .2s ease;box-shadow:0 2px 8px #00000026}.gengage-chat-launcher-tooltip:after{content:"";position:absolute;left:100%;top:50%;transform:translateY(-50%);border:5px solid transparent;border-left-color:#1e293b}.gengage-chat-launcher:hover .gengage-chat-launcher-tooltip{opacity:1}.gengage-chat-root--open .gengage-chat-launcher-tooltip{display:none}.gengage-chat-proactive{position:fixed;bottom:calc(var(--_gengage-chat-launcher-bottom) + var(--_gengage-chat-launcher-size) + 14px);right:var(--_gengage-chat-launcher-right);width:280px;padding:16px 18px;border-radius:16px;background:#fff;box-shadow:0 8px 30px #0000001f,0 2px 8px #0000000f;opacity:0;transform:translateY(8px) scale(.96);transition:opacity .25s ease,transform .25s ease;z-index:2147483645}.gengage-chat-proactive--visible{opacity:1;transform:translateY(0) scale(1)}.gengage-chat-proactive-message{margin:0 0 12px;font-size:14px;line-height:1.5;color:#1f2937}.gengage-chat-proactive-actions{display:flex;gap:8px}.gengage-chat-proactive-accept{flex:1;padding:8px 16px;border:none;border-radius:10px;background:var(--gengage-primary-color, #3b82f6);color:#fff;font-size:13px;font-weight:700;font-family:inherit;cursor:pointer;transition:filter .15s ease}.gengage-chat-proactive-accept:hover{filter:brightness(1.08)}.gengage-chat-proactive-dismiss{position:absolute;top:8px;right:8px;width:24px;height:24px;border:none;border-radius:50%;background:transparent;color:#64748b;font-size:16px;cursor:pointer;display:flex;align-items:center;justify-content:center}.gengage-chat-proactive-dismiss:hover{color:#475569;background:#f1f5f9}.gengage-chat-drawer{position:fixed;top:0;bottom:0;right:0;width:var(--_gengage-chat-drawer-width);max-height:-webkit-fill-available;max-height:100dvh;border-radius:0;background:var(--gengage-background-color, #fff);box-shadow:var(--_gengage-chat-shadow);display:flex;flex-direction:column;overflow:hidden;z-index:var(--gengage-z-index, 2147483647);transform-origin:right center;clip-path:inset(0);transition:clip-path .42s cubic-bezier(.25,.46,.45,.94),opacity .32s ease}.gengage-chat-root--mobile .gengage-chat-launcher-container{right:16px;bottom:calc(16px + env(safe-area-inset-bottom))}.gengage-chat-root--mobile .gengage-chat-drawer{left:0;right:0;bottom:0;width:100%;max-width:none;max-height:-webkit-fill-available;max-height:100dvh;border-radius:16px 16px 0 0;padding-bottom:env(safe-area-inset-bottom,0px);clip-path:inset(0);transition:clip-path .42s cubic-bezier(.25,.46,.45,.94),opacity .32s ease}.gengage-chat-root--mobile.gengage-chat-root--mobile-half .gengage-chat-drawer{top:auto;height:min(72dvh,620px);max-height:min(72dvh,620px)}.gengage-chat-root--mobile.gengage-chat-root--mobile-full .gengage-chat-drawer{top:0;height:100dvh;max-height:100dvh;border-radius:0}.gengage-chat-root--mobile .gengage-chat-input-area{padding-bottom:calc(10px + env(safe-area-inset-bottom,0px));transform:translateY(calc(-1 * var(--gengage-keyboard-offset, 0px)))}.gengage-chat-header{display:flex;align-items:center;justify-content:space-between;box-sizing:border-box;min-height:var(--_gengage-chat-header-height);padding:4px 12px;background:var(--gengage-chat-header-bg, #1d2939);color:var(--gengage-chat-header-foreground, #fff);box-shadow:0 4px 20px #00000014,0 0 2px #0000001f;border:none;position:relative;z-index:2}.gengage-chat-header-left{display:flex;align-items:center;gap:10px;min-width:0}.gengage-chat-header-avatar{width:40px;height:40px;border-radius:50%;object-fit:cover;flex-shrink:0;border:2px solid rgba(255,255,255,.15)}.gengage-chat-header-info{display:flex;flex-direction:column;gap:2px;min-width:0}.gengage-chat-header-title-row{display:flex;align-items:center;gap:6px}.gengage-chat-header-title{font-weight:700;font-size:15px;line-height:1.25;letter-spacing:.01em;color:inherit}.gengage-chat-header-badge{display:inline-flex;align-items:center;padding:1px 6px;border-radius:4px;background:var(--gengage-primary-color, #3b82f6);color:#fff;font-size:10px;font-weight:700;letter-spacing:.04em;text-transform:uppercase;line-height:1.5}.gengage-chat-header-powered{display:flex;align-items:center;gap:4px;font-size:11px;color:#ffffffbf;text-decoration:none;transition:color .15s}.gengage-chat-header-powered:hover{color:#fffc}.gengage-chat-header-powered svg{width:12px;height:12px;opacity:.6}.gengage-chat-header-right{display:flex;align-items:center;gap:4px;flex-shrink:0}.gengage-chat-header-btn{width:32px;height:32px;border-radius:8px;background:transparent;border:1px solid rgba(255,255,255,.12);color:#ffffffb3;cursor:pointer;display:inline-flex;align-items:center;justify-content:center;text-decoration:none;line-height:1;transition:background-color .15s ease,color .15s ease,border-color .15s ease}.gengage-chat-header-btn:hover{background:#ffffff1a;color:#fff;border-color:#ffffff40}.gengage-chat-close{width:32px;height:32px;border-radius:8px;background:transparent;border:1px solid rgba(255,255,255,.12);color:#ffffffb3;font-size:18px;cursor:pointer;display:inline-flex;align-items:center;justify-content:center;line-height:1;transition:background-color .15s ease,color .15s ease,border-color .15s ease}.gengage-chat-close:hover{background:#ffffff1a;color:#fff;border-color:#ffffff40}.gengage-chat-body{display:flex;flex:1;overflow:hidden;min-height:0}.gengage-chat-panel{display:none;width:0;overflow:hidden;transition:width .22s cubic-bezier(.2,.72,.2,1)}.gengage-chat-panel--visible{display:flex;flex-direction:column;position:relative;width:440px;min-width:440px;border-right:1px solid var(--_gengage-border-color);overflow-y:auto;padding:16px;background:#f8fafc}.gengage-chat-panel-divider{display:flex;align-items:center;width:4px;cursor:pointer;background:#e5e7eb;position:relative;flex-shrink:0;transition:background .15s;z-index:2}.gengage-chat-panel-divider:hover{background:#cbd5e1}.gengage-chat-panel-divider--hidden{display:none}.gengage-chat-panel-divider-toggle{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);width:24px;height:48px;border:1px solid var(--_gengage-border-color);border-radius:6px;background:#fff;cursor:pointer;display:flex;align-items:center;justify-content:center;font-size:14px;color:var(--_gengage-text-secondary);box-shadow:0 1px 3px #00000014;transition:background .15s,color .15s;padding:0;line-height:1}.gengage-chat-panel-divider-toggle:hover{background:#f1f5f9;color:#334155}.gengage-chat-panel--collapsed{flex:0 0 0px!important;width:0!important;min-width:0!important;max-width:0!important;padding:0!important;border-right:none!important;overflow:hidden}.gengage-chat-panel--collapsed~.gengage-chat-panel-divider{width:0;background:transparent}.gengage-chat-panel--collapsed~.gengage-chat-panel-divider .gengage-chat-panel-divider-toggle{left:0;transform:translateY(-50%)}.gengage-chat-conversation{display:flex;flex-direction:column;flex:1;min-width:0;overflow:hidden;background:var(--gengage-background-color, #fff);position:relative;z-index:1}.gengage-chat-drawer--with-panel{width:auto;background:transparent;box-shadow:none}.gengage-chat-drawer--with-panel .gengage-chat-header{border-radius:0;flex-shrink:0}.gengage-chat-drawer--with-panel .gengage-chat-body{flex:1 1 0;min-height:0;gap:0;padding:0;align-items:stretch}.gengage-chat-drawer--with-panel .gengage-chat-panel--visible{flex:0 0 auto;width:clamp(var(--_gengage-chat-panel-min-width),50vw,var(--_gengage-chat-panel-max-width));min-width:var(--_gengage-chat-panel-min-width);max-width:var(--_gengage-chat-panel-max-width);border-right:none;background:#fff;padding:0 16px 16px;overflow-y:auto;margin:0;border-radius:0;box-shadow:0 8px 32px #0f172a1f,0 2px 8px #0f172a0f;max-height:100dvh}.gengage-chat-drawer--with-panel .gengage-chat-panel-divider{width:0;background:transparent}.gengage-chat-drawer--with-panel .gengage-chat-panel-divider-toggle{width:20px;height:48px;border-radius:10px;background:var(--gengage-primary-color, #3b82f6);color:#fff;border:2px solid #fff;box-shadow:0 2px 8px #0f172a2e;font-size:12px;z-index:10}.gengage-chat-drawer--with-panel .gengage-chat-panel-divider-toggle:hover{background:var(--gengage-primary-hover, #2563eb);color:#fff}.gengage-chat-drawer--with-panel .gengage-chat-conversation{flex:0 0 var(--_gengage-chat-conversation-width);width:var(--_gengage-chat-conversation-width);border-left:none;background:var(--gengage-background-color, #fff);box-shadow:-4px 0 24px #0f172a1f,-1px 0 4px #0f172a0f}.gengage-chat-drawer--with-panel .gengage-chat-messages{padding-right:6px;scrollbar-width:thin;scrollbar-color:rgba(0,0,0,.12) transparent}.gengage-chat-drawer--with-panel .gengage-chat-messages::-webkit-scrollbar{width:0}.gengage-chat-drawer--with-panel:has(.gengage-chat-panel--collapsed){width:var(--_gengage-chat-conversation-width);background:var(--gengage-background-color, #fff);box-shadow:var(--_gengage-chat-shadow)}.gengage-chat-drawer--with-panel .gengage-chat-footer{display:none}.gengage-chat-messages{flex:1;overflow-y:auto;padding:16px;display:flex;flex-direction:column;gap:16px;min-height:0;scroll-behavior:smooth;-webkit-overflow-scrolling:touch;overscroll-behavior:contain;touch-action:pan-y}.gengage-chat-messages::-webkit-scrollbar{width:6px}.gengage-chat-messages::-webkit-scrollbar-track{background:transparent}.gengage-chat-messages::-webkit-scrollbar-thumb{background:#0000001f;border-radius:3px}.gengage-chat-messages::-webkit-scrollbar-thumb:hover{background:#0003}.gengage-chat-bubble{max-width:85%;padding:12px 16px;border-radius:12px;line-height:1.5;font-size:14px;font-weight:500;word-wrap:break-word;overflow-wrap:break-word;animation:gengage-chat-msg-in .3s cubic-bezier(.2,.7,.2,1)}@keyframes gengage-chat-msg-in{0%{opacity:0;transform:translateY(8px)}to{opacity:1;transform:translateY(0)}}.gengage-chat-bubble--user{align-self:flex-end;background:var(--gengage-primary-color, #3b82f6);color:var(--gengage-primary-foreground, #fff);border-bottom-right-radius:4px}.gengage-chat-bubble--assistant{align-self:flex-start;background:#f3f4f6;color:#1f2937;border-bottom-left-radius:4px;min-width:120px}.gengage-chat-bubble--active{outline:2px solid var(--gengage-primary-color, #3b82f6);outline-offset:-2px}.gengage-chat-bubble--assistant:empty{display:none}.gengage-chat-bubble--assistant .gengage-chat-bubble-text a{color:var(--gengage-primary-color, #2563eb);text-decoration:underline}.gengage-chat-bubble--assistant .gengage-chat-bubble-text a:hover{text-decoration:none}.gengage-chat-bubble--assistant .gengage-chat-bubble-text p{margin:0 0 8px}.gengage-chat-bubble--assistant .gengage-chat-bubble-text p:last-child{margin-bottom:0}.gengage-chat-bubble--assistant .gengage-chat-bubble-text ul,.gengage-chat-bubble--assistant .gengage-chat-bubble-text ol{margin:6px 0;padding-left:20px}.gengage-chat-bubble--assistant .gengage-chat-bubble-text li{margin-bottom:6px;line-height:1.5}.gengage-chat-bubble--assistant .gengage-chat-bubble-text code{background:#0000000f;padding:1px 4px;border-radius:3px;font-size:.9em}.gengage-chat-bubble--assistant .gengage-chat-bubble-text pre{background:#0000000a;padding:8px;border-radius:6px;overflow-x:auto;margin:4px 0}.gengage-chat-bubble--assistant .gengage-chat-bubble-text table{border-collapse:collapse;margin:4px 0;font-size:.9em}.gengage-chat-bubble--assistant .gengage-chat-bubble-text th,.gengage-chat-bubble--assistant .gengage-chat-bubble-text td{border:1px solid var(--_gengage-border-color);padding:4px 8px}.gengage-chat-bubble--assistant .gengage-chat-bubble-text img{max-width:100%;height:auto;border-radius:4px;margin:4px 0}.gengage-chat-bubble--assistant .gengage-chat-bubble-text h1,.gengage-chat-bubble--assistant .gengage-chat-bubble-text h2,.gengage-chat-bubble--assistant .gengage-chat-bubble-text h3,.gengage-chat-bubble--assistant .gengage-chat-bubble-text h4,.gengage-chat-bubble--assistant .gengage-chat-bubble-text h5,.gengage-chat-bubble--assistant .gengage-chat-bubble-text h6{margin:8px 0 4px;line-height:1.3;color:#0f172a}.gengage-chat-bubble--assistant .gengage-chat-bubble-text blockquote{border-left:3px solid var(--_gengage-border-color);padding-left:12px;margin:4px 0;color:var(--_gengage-text-secondary)}.gengage-chat-bubble--first{border-left:3px solid var(--gengage-accent-primary, #3b82f6);padding-left:12px}.gengage-chat-bubble--first .gengage-chat-bubble-text{font-size:15px}.gengage-chat-typing{display:flex;align-items:center;gap:5px;padding:8px 4px;align-self:flex-start;max-width:85%}.gengage-chat-typing:has(.gengage-chat-typing-text),.gengage-chat-typing:has(.gengage-chat-thinking-steps){background:#f3f4f6;padding:10px 14px;border-radius:12px 12px 12px 4px;gap:8px}.gengage-chat-typing-dots{display:flex;align-items:center;gap:5px}.gengage-chat-typing-dots span{width:6px;height:6px;border-radius:50%;background:#94a3b8;display:inline-block;animation:gengage-chat-typing-fade 1.4s ease-in-out infinite}.gengage-chat-typing-dots span:nth-child(2){animation-delay:.2s}.gengage-chat-typing-dots span:nth-child(3){animation-delay:.4s}@keyframes gengage-chat-typing-fade{0%,to{opacity:.25}50%{opacity:1}}.gengage-chat-typing-sparkle{animation:gengage-sparkle-pulse 1.2s infinite}@keyframes gengage-sparkle-pulse{0%,to{opacity:1}50%{opacity:.4}}.gengage-chat-typing-text{font-size:13px;color:var(--_gengage-text-secondary);font-style:italic;flex:1;min-width:0;word-wrap:break-word;overflow-wrap:break-word}.gengage-chat-thinking-steps{display:flex;flex-direction:column;gap:4px;padding:4px 0}.gengage-chat-thinking-step{display:flex;align-items:center;gap:6px;font-size:13px;color:var(--gengage-chat-text-secondary, #666)}.gengage-chat-thinking-step-marker{font-size:12px;width:16px;text-align:center;flex-shrink:0}.gengage-chat-thinking-step-marker--done{color:var(--gengage-chat-success, #4caf50)}.gengage-chat-thinking-step-marker--active{color:var(--gengage-chat-primary, #1976d2);animation:gengage-thinking-pulse 1.5s ease-in-out infinite}@keyframes gengage-thinking-pulse{0%,to{opacity:1}50%{opacity:.4}}.gengage-chat-thinking-step-text{line-height:1.4}.gengage-chat-error{display:flex;align-items:center;justify-content:center;gap:10px;padding:10px 14px;border-radius:10px;background:#fef2f2;color:#991b1b;font-size:13px;text-align:center;border:1px solid #fecaca}.gengage-chat-error-retry{flex-shrink:0;padding:4px 12px;border:1px solid #fca5a5;border-radius:6px;background:#fff;color:#991b1b;font-size:12px;font-weight:500;cursor:pointer;transition:background .15s}.gengage-chat-error-retry:hover{background:#fee2e2}.gengage-chat-input-area{display:flex;flex-wrap:wrap;align-items:center;gap:0;padding:8px 12px;border-top:1px solid var(--_gengage-border-color);background:var(--gengage-background-color, #fff)}.gengage-chat-input-pill{display:flex;align-items:center;gap:4px;flex:1;min-width:0;height:44px;background:#f3f4f6;border:1px solid var(--_gengage-border-color);border-radius:30px;padding:2px 8px;overflow:hidden;transition:border-color .2s ease,box-shadow .2s ease}.gengage-chat-input-pill:focus-within{border-color:var(--gengage-primary-color, #3b82f6);box-shadow:0 0 0 2px #3b82f626}.gengage-chat-input{flex:1;min-width:0;min-height:40px;max-height:120px;padding:0 6px 0 14px;border:none;border-radius:0;font-size:14px;font-family:inherit;line-height:1.4;align-content:center;outline:none;background:transparent;color:#1f2937;resize:none;overflow-y:hidden}@media(max-width:767px){.gengage-chat-input{max-height:40px;white-space:nowrap;overflow:hidden}.gengage-chat-send{width:44px;height:44px;min-width:44px}}.gengage-chat-input::placeholder{font-size:14px;color:#6b7280}.gengage-chat-send{width:36px;height:36px;min-width:36px;padding:0;border:none;border-radius:50%;background:var(--gengage-primary-color, #3b82f6);color:var(--gengage-primary-foreground, #fff);font-weight:700;font-size:0;font-family:inherit;cursor:pointer;display:flex;align-items:center;justify-content:center;flex-shrink:0;transition:background-color .2s cubic-bezier(.4,0,.2,1),box-shadow .2s ease,transform .15s ease;box-shadow:0 2px 4px #0000001f}.gengage-chat-send:hover{filter:brightness(.92);transform:translateY(-1px);box-shadow:0 4px 8px #0000002e}.gengage-chat-send:active{transform:translateY(0);box-shadow:0 1px 2px #0000001f}.gengage-chat-send svg{width:18px;height:18px}.gengage-chat-send:disabled{background:#d1d5db;box-shadow:none;cursor:not-allowed}.gengage-chat-footer{padding:4px 10px;text-align:center;font-size:10px;color:#6b7280;border-top:1px solid #f1f5f9;background:var(--gengage-background-color, #fff)}.gengage-chat-uispec{width:100%}.gengage-chat-uispec:empty{display:none}.gengage-chat-uispec>*{animation:gengage-chat-widget-enter .16s cubic-bezier(.2,.7,.2,1) both}@keyframes gengage-chat-widget-enter{0%{opacity:0;transform:translateY(5px) scale(.99)}to{opacity:1;transform:translateY(0) scale(1)}}.gengage-chat-action-buttons{display:flex;gap:8px;padding:6px 0 4px;overflow-x:auto;scrollbar-width:none;-webkit-overflow-scrolling:touch}.gengage-chat-action-buttons::-webkit-scrollbar{display:none}.gengage-chat-action-btn{flex:0 0 auto;padding:8px 16px;border:none;border-radius:999px;background:var(--gengage-primary-color, #3b82f6);color:var(--gengage-primary-foreground, #fff);font-size:13px;font-weight:600;line-height:1.25;font-family:inherit;cursor:pointer;white-space:nowrap;transition:filter .15s ease,transform .1s ease}.gengage-chat-action-btn:hover{filter:brightness(.92)}.gengage-chat-action-btn:active{transform:scale(.97)}.gengage-chat-product-card{position:relative;border:1px solid #eee;border-radius:16px;overflow:hidden;background:#fff;width:160px;min-width:160px;max-width:160px;box-shadow:0 2px 8px #0000000f;transition:transform .1s ease,box-shadow .2s ease}.gengage-chat-product-card:hover{transform:translateY(-2px);box-shadow:0 4px 16px #0000001f}.gengage-chat-product-card-img{width:100%;height:120px;object-fit:contain;display:block;background:#fff;padding:8px;box-sizing:border-box}.gengage-chat-product-card-body{display:flex;flex-direction:column;gap:4px;padding:8px 10px 10px;text-align:center}.gengage-chat-product-card-name{font-size:13px;font-weight:600;color:#1f2937;line-height:1.35;margin-bottom:0;min-height:0;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;text-overflow:ellipsis}.gengage-chat-product-card-brand{font-size:10px;color:#666}.gengage-chat-product-card-rating{font-size:11px;color:#f59e0b;line-height:1}.gengage-chat-product-card-review-count{color:#64748b;font-size:10px}.gengage-chat-product-card-price{display:flex;align-items:baseline;justify-content:center;gap:4px;font-size:16px;font-weight:800;color:#0f172a}.gengage-chat-product-card-original-price{text-decoration:line-through;color:#64748b;font-weight:400;font-size:12px}.gengage-chat-price-skeleton{display:inline-block;width:80px;height:16px;background:linear-gradient(90deg,#e2e8f0 25%,#f1f5f9,#e2e8f0 75%);background-size:200% 100%;animation:gengage-skeleton-price-pulse 1.5s ease-in-out infinite;border-radius:4px;vertical-align:middle}@keyframes gengage-skeleton-price-pulse{0%{background-position:200% 0}to{background-position:-200% 0}}.gengage-chat-product-card-cta{display:block;padding:8px 10px;text-align:center;background:transparent;color:var(--gengage-primary-color, #3b82f6);text-decoration:none;font-size:12px;font-weight:700;letter-spacing:.01em;border-top:1px solid #f1f5f9;transition:color .15s ease,background .15s ease}.gengage-chat-product-card-cta:hover{color:var(--gengage-primary-color, #0b24d6);background:#f8fafc}.gengage-chat-product-card-cta:active{background:#f1f5f9}.gengage-chat-product-summary{display:flex;align-items:center;gap:12px;padding:10px 12px;border:1px solid #e5e7eb;border-radius:12px;background:#fff;cursor:pointer;transition:background .15s,box-shadow .15s;margin:4px 0}.gengage-chat-product-summary:hover{background:#f9fafb;box-shadow:0 1px 4px #0000000f}.gengage-chat-product-summary__image{flex-shrink:0;width:64px;height:64px;border-radius:8px;overflow:hidden;border:1px solid #f3f4f6;background:#f9fafb}.gengage-chat-product-summary__image img{width:100%;height:100%;object-fit:cover;display:block}.gengage-chat-product-summary__content{flex:1;min-width:0;display:flex;flex-direction:column;gap:2px}.gengage-chat-product-summary__name{font-size:13px;font-weight:500;line-height:1.3;color:#111827;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}.gengage-chat-product-summary__rating{font-size:11px;color:#f59e0b;line-height:1}.gengage-chat-product-summary__review-count{color:#6b7280;font-size:11px}.gengage-chat-product-summary__price{font-size:13px;font-weight:600;color:#111827;line-height:1;margin-top:2px}.gengage-chat-product-summary__price-original{text-decoration:line-through;color:#6b7280;font-weight:400;font-size:11px}.gengage-chat-product-summary__price-current{color:var(--gengage-primary-color, #111827)}.gengage-chat-product-summary__cta{flex-shrink:0;font-size:12px;font-weight:500;color:var(--gengage-primary-color, #2563eb);text-decoration:none;padding:4px 10px;border-radius:8px;transition:background .15s;white-space:nowrap}.gengage-chat-product-summary__cta:hover{background:#0000000a}.gengage-chat-product-summary__cta:focus-visible{outline:2px solid var(--gengage-primary-color, #2563eb);outline-offset:2px}.gengage-chat-product-grid{display:flex;gap:12px;overflow-x:auto;padding:8px 0;-webkit-overflow-scrolling:touch;scrollbar-width:none;scroll-snap-type:x proximity;min-height:180px}.gengage-chat-product-grid>*{scroll-snap-align:start;flex:0 0 auto}.gengage-chat-product-grid::-webkit-scrollbar{display:none}.gengage-chat-review-highlights{padding:2px 0 6px}.gengage-chat-review-item{border:1px solid var(--_gengage-border-color);border-radius:12px;padding:10px 12px;background:#fff}.gengage-chat-review-item[data-tone=positive]{border-color:#bbf7d0;background:#f0fdf4}.gengage-chat-review-item[data-tone=negative]{border-color:#fecaca;background:#fef2f2}.gengage-chat-review-tag{font-size:11px;font-weight:700;text-transform:uppercase;letter-spacing:.03em;color:var(--_gengage-text-secondary);margin-bottom:4px}.gengage-chat-review-text{font-size:13px;line-height:1.45;color:#1f2937}.gengage-chat-review-rating{margin-top:6px;font-size:12px;font-weight:700;color:#0f172a}.gengage-chat-review-empty{font-size:12px;color:var(--_gengage-text-secondary)}.gengage-chat-review-tabs{display:flex;gap:6px;margin-bottom:10px}.gengage-chat-review-tab{padding:6px 14px;border:1px solid var(--_gengage-border-color);border-radius:999px;background:#fff;color:var(--_gengage-text-secondary);font-size:12px;font-weight:600;font-family:inherit;cursor:pointer;transition:background .15s,border-color .15s}.gengage-chat-review-tab:hover{background:#f8fafc}.gengage-chat-review-tab--active{background:#f1f5f9;border-color:#94a3b8;color:#0f172a}.gengage-chat-review-pills{display:flex;flex-wrap:wrap;gap:6px;margin-bottom:10px}.gengage-chat-review-pill{display:flex;align-items:center;gap:6px;padding:6px 10px;border:1px solid var(--_gengage-border-color);border-radius:8px;background:#fff;font-size:12px;color:#334155;box-shadow:0 1px 2px #0000000a}.gengage-chat-review-pill[data-tone=positive]{border-color:#bbf7d0}.gengage-chat-review-pill[data-tone=negative]{border-color:#fecaca}.gengage-chat-review-pill-icon{font-size:11px;font-weight:700}.gengage-chat-review-pill[data-tone=positive] .gengage-chat-review-pill-icon{color:#16a34a}.gengage-chat-review-pill[data-tone=negative] .gengage-chat-review-pill-icon{color:#dc2626}.gengage-chat-review-pill-count{font-size:10px;font-weight:700;background:#f1f5f9;color:var(--_gengage-text-secondary);border-radius:4px;padding:1px 5px}.gengage-chat-review-items{display:grid;gap:10px}.gengage-chat-divider{border:none;border-top:1px solid var(--_gengage-border-color);margin:8px 0}.gengage-chat-divider-wrapper{display:flex;align-items:center;gap:8px;margin:8px 0}.gengage-chat-divider-wrapper hr{flex:1;border:none;border-top:1px solid var(--_gengage-border-color);margin:0}.gengage-chat-divider-label{font-size:11px;color:#6b7280;white-space:nowrap}.gengage-chat--overlay .gengage-chat-drawer{position:fixed;inset:0;width:100%;max-width:480px;max-height:100%;margin:0 auto;border-radius:0;animation:gengage-chat-overlay-in .24s cubic-bezier(.2,.72,.2,1)}.gengage-chat--overlay:before{content:"";position:fixed;inset:0;background:#00000073;z-index:-1}@keyframes gengage-chat-overlay-in{0%{opacity:0;transform:translateY(12px)}to{opacity:1;transform:translateY(0)}}.gengage-chat-panel-skeleton{display:flex;flex-direction:column;gap:14px;padding:6px 0}.gengage-chat-panel-skeleton-block{height:110px;border-radius:10px;background:linear-gradient(90deg,#e5e7eb 25%,#f3f4f6,#e5e7eb 75%);background-size:200% 100%;animation:gengage-panel-shimmer 1.4s infinite}@keyframes gengage-panel-shimmer{0%{background-position:200% 0}to{background-position:-200% 0}}.gengage-chat-panel-skeleton-block--image{height:200px;border-radius:8px;margin-bottom:12px}.gengage-chat-panel-skeleton-block--text{height:16px;border-radius:4px;margin-bottom:8px}.gengage-chat-panel-skeleton-block--text:nth-child(3){width:80%}.gengage-chat-panel-skeleton-block--text:nth-child(4){width:60%}.gengage-chat-panel-skeleton-grid{display:grid;grid-template-columns:1fr 1fr;gap:8px}.gengage-chat-panel-skeleton-block--card{height:120px;border-radius:8px}.gengage-chat-panel-skeleton-block--row{height:32px;border-radius:4px;margin-bottom:4px}.gengage-chat-panel .gengage-chat-product-card{width:100%;max-width:100%;min-width:0;display:flex;flex-direction:column;border-radius:12px;border:1px solid var(--_gengage-border-color);box-shadow:0 1px 4px #0000000f;overflow:hidden;padding:0}.gengage-chat-panel .gengage-chat-product-card:hover{transform:translateY(-2px);box-shadow:0 4px 12px #0000001a;border-color:#d1d5db}.gengage-chat-panel .gengage-chat-product-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(180px,1fr));overflow-x:visible;gap:12px;min-height:auto;padding:4px 0}.gengage-chat-panel .gengage-chat-product-card-img{width:100%;height:160px;border-radius:0;object-fit:contain;background:#fafafa;padding:12px;box-sizing:border-box}.gengage-chat-panel .gengage-chat-product-card-body{padding:10px 12px 12px;text-align:left;gap:4px}.gengage-chat-panel .gengage-chat-product-card-name{min-height:0;margin-bottom:2px;font-size:13px;-webkit-line-clamp:2}.gengage-chat-panel .gengage-chat-product-card-price{justify-content:flex-start;font-size:15px}.gengage-chat-panel .gengage-chat-product-card-cta{display:block;padding:10px 12px;text-align:center;border-top:1px solid #f1f5f9;border-radius:0;background:transparent;color:var(--gengage-primary-color, #3b82f6);font-weight:700;font-size:13px}.gengage-chat-product-details-panel{display:flex;flex-direction:column;gap:12px;width:100%;background:#fff;border:1px solid var(--_gengage-border-color);border-radius:16px;padding:14px;box-sizing:border-box}.gengage-chat-product-details-media{border:1px solid #f1f5f9;border-radius:12px;background:#fafafa;padding:12px;display:flex;flex-direction:column;align-items:center}.gengage-chat-product-details-img{width:100%;height:auto;max-height:300px;object-fit:contain;border-radius:8px}.gengage-chat-product-details-content{display:flex;flex-direction:column;gap:8px;min-width:0}.gengage-chat-product-details-title{margin:0;font-size:17px;font-weight:700;line-height:1.3;color:#0f172a}.gengage-chat-product-details-rating{display:inline-flex;align-items:center;gap:4px;width:fit-content;padding:3px 8px;border-radius:999px;background:#fff7ed;color:#9a3412;font-size:13px;font-weight:700}.gengage-chat-product-details-review-count{color:#7c2d12;font-weight:600}.gengage-chat-product-details-price{display:flex;align-items:baseline;gap:6px}.gengage-chat-product-details-original-price{font-size:14px;color:#64748b;text-decoration:line-through}.gengage-chat-product-details-current-price{font-size:22px;font-weight:800;line-height:1.1;color:#0f172a}.gengage-chat-product-details-stock{width:fit-content;padding:4px 10px;border-radius:999px;font-size:12px;font-weight:700}.gengage-chat-product-details-stock.is-in-stock{background:#dcfce7;color:#166534}.gengage-chat-product-details-stock.is-out-of-stock{background:#fee2e2;color:#991b1b}.gengage-chat-product-details-actions{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin-top:4px}.gengage-chat-product-details-cta{display:inline-flex;align-items:center;justify-content:center;min-height:40px;padding:0 20px;border-radius:999px;border:none;text-decoration:none;background:var(--gengage-primary-color, #3b82f6);color:var(--gengage-primary-foreground, #fff);font-size:14px;font-weight:700;cursor:pointer;transition:filter .14s ease,transform .12s ease}.gengage-chat-product-details-cta:hover{filter:brightness(1.05);transform:translateY(-1px)}.gengage-chat-product-details-cta:active{transform:translateY(1px)}.gengage-chat-product-details-atc{display:inline-flex;align-items:center;justify-content:center;gap:6px;padding:10px 20px;border:none;border-radius:10px;background:var(--_gengage-success-color);color:#fff;font-size:14px;font-weight:700;font-family:inherit;cursor:pointer;transition:filter .12s ease,transform .12s ease}.gengage-chat-product-details-atc:hover{filter:brightness(1.08);transform:translateY(-1px)}.gengage-chat-product-details-atc:active{transform:translateY(1px)}.gengage-chat-product-detail-tabs{margin-top:4px;border-top:1px solid var(--_gengage-border-color);padding-top:12px}.gengage-chat-product-detail-tab-bar{display:flex;gap:0;border-bottom:2px solid var(--_gengage-border-color);margin-bottom:12px}.gengage-chat-product-detail-tab{flex:1;padding:8px 12px;border:none;background:transparent;color:var(--_gengage-text-secondary);font-size:13px;font-weight:600;font-family:inherit;cursor:pointer;border-bottom:2px solid transparent;margin-bottom:-2px;transition:color .15s,border-color .15s}.gengage-chat-product-detail-tab:hover{color:#334155}.gengage-chat-product-detail-tab--active{color:var(--gengage-primary-color, #3b82f6);border-bottom-color:var(--gengage-primary-color, #3b82f6)}.gengage-chat-product-detail-tab-panel{font-size:13px;line-height:1.6;color:#374151}.gengage-chat-product-specs-table{width:100%;border-collapse:collapse;font-size:13px}.gengage-chat-product-specs-table tr:nth-child(2n){background:#f8fafc}.gengage-chat-product-specs-key{padding:6px 10px;font-weight:600;color:#475569;white-space:nowrap;border-bottom:1px solid #f1f5f9;width:40%}.gengage-chat-product-specs-value{padding:6px 10px;color:#1f2937;border-bottom:1px solid #f1f5f9}.gengage-chat-product-card-atc{position:absolute;bottom:42px;right:6px;opacity:0;transition:opacity .15s ease;z-index:1}.gengage-chat-product-card:hover .gengage-chat-product-card-atc{opacity:1}.gengage-chat-drawer.gengage-chat-drawer--hidden{clip-path:inset(0 0 0 100%);opacity:0;pointer-events:none;box-shadow:none}.gengage-chat-root--mobile .gengage-chat-drawer.gengage-chat-drawer--hidden{clip-path:inset(100% 0 0 0);opacity:0;pointer-events:none;box-shadow:none}@media(max-width:900px){.gengage-chat-drawer--with-panel .gengage-chat-panel--visible{width:clamp(280px,calc(100vw - var(--_gengage-chat-conversation-width)),560px);max-width:560px}}.gengage-chat-attachment-preview{display:flex;align-items:center;gap:8px;padding:6px 10px;background:#f3f4f6;border:1px solid var(--_gengage-border-color);border-radius:8px;width:100%;box-sizing:border-box}.gengage-chat-attachment-preview--hidden{display:none}.gengage-chat-attachment-preview-thumb{width:40px;height:40px;border-radius:4px;object-fit:cover;flex-shrink:0}.gengage-chat-attachment-name{flex:1;font-size:12px;color:#4b5563;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.gengage-chat-attachment-remove{background:none;border:none;cursor:pointer;font-size:18px;color:#6b7280;padding:0 4px;line-height:1;flex-shrink:0}.gengage-chat-attachment-remove:hover{color:#ef4444}.gengage-chat-attach-btn{background:none;border:none;cursor:pointer;padding:6px;line-height:1;flex-shrink:0;display:flex;align-items:center;justify-content:center;border-radius:50%;color:#6b7280;transition:color .15s,background .15s}.gengage-chat-attach-btn:hover{color:#4b5563;background:#0000000d}.gengage-chat-attach-btn svg{width:20px;height:20px}.gengage-chat-mic-btn{background:none;border:none;cursor:pointer;padding:6px;line-height:1;flex-shrink:0;display:flex;align-items:center;justify-content:center;border-radius:50%;color:#6b7280;transition:color .15s,background .15s}.gengage-chat-mic-btn:hover{color:#4b5563;background:#0000000d}.gengage-chat-mic-btn svg{width:20px;height:20px}.gengage-chat-mic-btn--active{color:#ef4444;animation:gengage-mic-pulse 1.2s ease-in-out infinite}.gengage-chat-mic-btn--active:hover{color:#dc2626}@keyframes gengage-mic-pulse{0%,to{transform:scale(1);opacity:1}50%{transform:scale(1.15);opacity:.8}}.gengage-chat-input-area--dragover{outline:2px dashed var(--gengage-primary-color, #3b82f6);outline-offset:-2px;background:#eff6ff}.gengage-chat-attachment-thumb{width:120px;max-width:100%;height:auto;border-radius:8px;margin-bottom:6px;display:block}@media(max-width:768px){.gengage-chat-panel-divider{display:none}.gengage-chat-drawer--with-panel{left:0;right:0;width:100%;border-radius:0}.gengage-chat-drawer--with-panel .gengage-chat-body{flex-direction:column}.gengage-chat-drawer--with-panel .gengage-chat-panel--visible{width:100%;min-width:0;max-width:none;max-height:30dvh;border-right:none;border-bottom:1px solid var(--_gengage-border-color);padding:0 12px 12px;margin:0;border-radius:0;box-shadow:none}.gengage-chat-drawer--with-panel .gengage-chat-conversation{width:100%;flex:1;border-left:none}.gengage-chat-panel .gengage-chat-product-card{grid-template-columns:84px 1fr}.gengage-chat-panel .gengage-chat-product-card-cta{grid-column:1 / -1;width:100%}.gengage-chat-product-details-panel{padding:12px;gap:12px}.gengage-chat-product-details-media{min-height:140px}.gengage-chat-product-details-title{font-size:15px}.gengage-chat-product-details-current-price{font-size:20px}.gengage-chat-product-grid{scroll-snap-type:x mandatory}.gengage-chat-product-card{width:280px;min-width:280px;scroll-snap-align:center}.gengage-chat-product-card-img{height:180px}}@media(max-width:480px){.gengage-chat-drawer{position:fixed;inset:0;width:100%;max-height:100%;border-radius:0}.gengage-chat-bubble{max-width:100%}}.gengage-chat-kvkk-banner{display:flex;align-items:flex-start;gap:8px;padding:10px 14px;background:#fffbeb;border-bottom:1px solid #fde68a;font-size:12px;line-height:1.5;color:#92400e}.gengage-chat-kvkk-content{flex:1;min-width:0}.gengage-chat-kvkk-content a{color:#b45309;text-decoration:underline}.gengage-chat-kvkk-dismiss{flex-shrink:0;width:20px;height:20px;border:none;background:transparent;color:#92400e;font-size:16px;cursor:pointer;padding:0;line-height:1}.gengage-chat-comparison{padding:16px}.gengage-chat-comparison-heading{font-size:14px;font-weight:700;letter-spacing:.05em;color:#0f172a;margin:0 0 16px}.gengage-chat-comparison-recommended{border:1px solid var(--_gengage-border-color);border-radius:12px;padding:16px;background:#fff;box-shadow:0 1px 3px #0000000f;margin-bottom:12px}.gengage-chat-comparison-recommended-label{font-size:12px;font-weight:700;color:#16a34a;text-transform:uppercase;letter-spacing:.04em;margin-bottom:12px}.gengage-chat-comparison-recommended-body{display:flex;gap:12px;align-items:flex-start}.gengage-chat-comparison-recommended-body img{width:80px;height:80px;object-fit:contain;border-radius:8px;background:#f8fafc}.gengage-chat-comparison-recommended-info{flex:1;min-width:0}.gengage-chat-comparison-recommended-title{font-size:14px;font-weight:600;color:#0f172a;margin-bottom:4px}.gengage-chat-comparison-recommended-price{font-size:16px;font-weight:700;color:#0f172a}.gengage-chat-comparison-highlights{margin-top:12px;padding-top:12px;border-top:1px solid #f1f5f9}.gengage-chat-comparison-highlights-label{font-size:12px;font-weight:600;color:var(--_gengage-text-secondary);margin-bottom:6px}.gengage-chat-comparison-highlights ul{margin:0;padding-left:18px;font-size:13px;color:#334155;line-height:1.6}.gengage-chat-comparison-special{background:#fffbeb;border:1px solid #fde68a;border-radius:12px;padding:12px 16px;margin-bottom:12px;font-size:13px;color:#92400e}.gengage-chat-comparison-special summary{cursor:pointer;font-weight:600}.gengage-chat-comparison-special ul{margin:8px 0 0;padding-left:18px;line-height:1.6}.gengage-chat-comparison-table{width:100%;border-collapse:collapse;font-size:13px;margin-top:12px}.gengage-chat-comparison-table th,.gengage-chat-comparison-table td{padding:10px 12px;text-align:center;border-bottom:1px solid #f1f5f9;vertical-align:top}.gengage-chat-comparison-table th{font-weight:600;font-size:12px;color:#334155}.gengage-chat-comparison-table th img{width:60px;height:60px;object-fit:contain;border-radius:6px;background:#f8fafc;margin-bottom:6px}.gengage-chat-comparison-table-price{font-weight:700;color:#0f172a}.gengage-chat-comparison-label{text-align:left;font-weight:600;color:var(--_gengage-text-secondary);white-space:nowrap}.gengage-chat-comparison-selected{background:#f0fdf4}.gengage-chat-comparison-recommended-text{padding:8px 12px;font-size:12px;color:var(--gengage-text-secondary, #475569);font-style:italic;border-top:1px solid var(--gengage-border-color, #e2e8f0);margin-top:8px}.gengage-chat-comparison-product-actions{display:flex;gap:8px;margin-top:12px;flex-wrap:wrap}.gengage-chat-comparison-view-btn{flex:1;min-width:0;padding:8px 12px;border:1px solid var(--gengage-primary-color, #3b82f6);border-radius:6px;background:transparent;color:var(--gengage-primary-color, #3b82f6);font-size:12px;font-weight:500;font-family:inherit;cursor:pointer;transition:background .15s ease,color .15s ease;text-overflow:ellipsis;overflow:hidden;white-space:nowrap}.gengage-chat-comparison-view-btn:hover{background:var(--gengage-primary-color, #3b82f6);color:#fff}.gengage-chat-pills{position:relative;padding:8px 12px;border-top:1px solid #f1f5f9;background:var(--gengage-background-color, #fff)}.gengage-chat-pills-scroll{display:flex;gap:8px;overflow-x:auto;scrollbar-width:none;-webkit-overflow-scrolling:touch;padding-right:28px}.gengage-chat-pills-scroll::-webkit-scrollbar{display:none}.gengage-chat-pill{flex:0 0 auto;padding:8px 16px;border:none;border-radius:999px;background:var(--gengage-primary-color, #3b82f6);color:var(--gengage-primary-foreground, #fff);font-size:13px;font-weight:600;font-family:inherit;white-space:nowrap;cursor:pointer;transition:filter .15s,transform .1s}.gengage-chat-pill:hover{filter:brightness(.92)}.gengage-chat-pill:active{transform:scale(.97)}.gengage-chat-pill--rich{display:flex;align-items:center;gap:8px;padding:6px 14px 6px 6px;border-radius:20px}.gengage-chat-pill-img{width:32px;height:32px;border-radius:50%;object-fit:cover;flex-shrink:0;background:#ffffff26}.gengage-chat-pill-text{font-size:13px;font-weight:600;line-height:1.2}.gengage-chat-pill-desc{display:none}.gengage-chat-pill--rich .gengage-chat-pill-desc{display:block;font-size:10px;font-weight:400;opacity:.8;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:160px}.gengage-chat-pills-arrow{position:absolute;right:8px;top:50%;transform:translateY(-50%);width:28px;height:28px;border-radius:50%;border:1px solid var(--_gengage-border-color);background:#fff;color:var(--_gengage-text-secondary);font-size:16px;cursor:pointer;display:flex;align-items:center;justify-content:center;box-shadow:-4px 0 8px #ffffffe6;z-index:1}.gengage-chat-pills-arrow:hover{background:#f8fafc;color:#334155}@media(prefers-reduced-motion:reduce){.gengage-chat-uispec>*,.gengage-chat-action-btn,.gengage-chat-product-card,.gengage-chat-product-card-cta,.gengage-chat-send,.gengage-chat-launcher,.gengage-chat-pill,.gengage-chat-drawer,.gengage-chat-proactive,.gengage-chat-typing-dots span,.gengage-chat-typing-sparkle,.gengage-chat-thinking-step-marker--active,.gengage-chat-bubble,.gengage-chat-panel-skeleton-block,.gengage-chat-ai-toppick-card,.gengage-chat-mic-btn--active,.gengage-chat-ai-toppick-spinner:after,.gengage-chat-panel-shimmer,.gengage-chat-overlay,.gengage-chat-product-details-skeleton-price{animation:none!important;transition:none!important;transform:none!important}}.gengage-chat-bubble--user{position:relative}.gengage-chat-rollback-btn{position:absolute;left:-28px;top:50%;transform:translateY(-50%);width:24px;height:24px;border:none;border-radius:50%;background:var(--gengage-surface-color, #f1f5f9);color:var(--gengage-text-secondary, #64748b);cursor:pointer;display:flex;align-items:center;justify-content:center;opacity:0;transition:opacity .15s ease;padding:0}.gengage-chat-bubble--user:hover .gengage-chat-rollback-btn{opacity:1}.gengage-chat-rollback-btn:hover{background:var(--gengage-primary-color, #3b82f6);color:#fff}.gengage-chat-bubble--hidden{display:none}.gengage-chat-ai-top-picks{display:flex;flex-direction:column;gap:12px;padding:8px 0}.gengage-chat-ai-top-picks-title{font-size:15px;font-weight:600;color:var(--gengage-text-primary, #1e293b);margin:0 0 4px}.gengage-chat-ai-top-picks-cards{display:flex;flex-direction:column;gap:10px}.gengage-chat-ai-toppick-discount-badge{position:absolute;top:8px;left:8px;background:var(--gengage-discount-bg, #ef4444);color:#fff;font-size:11px;font-weight:700;padding:2px 6px;border-radius:4px;z-index:1}.gengage-chat-ai-toppick-card--winner{position:relative;display:flex;flex-direction:column;border:2px solid var(--gengage-primary-color, #3b82f6);border-radius:12px;background:#fff;overflow:hidden;transition:box-shadow .2s ease}.gengage-chat-ai-toppick-card--winner:hover{box-shadow:0 4px 16px #3b82f626}.gengage-chat-ai-toppick-card--winner .gengage-chat-ai-toppick-img{width:100%;height:140px;object-fit:contain;background:#f8fafc}.gengage-chat-ai-toppick-card--compact{position:relative;display:flex;flex-direction:row;align-items:center;gap:12px;border:1px solid var(--gengage-border-color, #e2e8f0);border-radius:10px;background:#fff;padding:10px;transition:box-shadow .2s ease,transform .15s ease}.gengage-chat-ai-toppick-card--compact:hover{box-shadow:0 2px 8px #00000014;transform:translateY(-1px)}.gengage-chat-ai-toppick-card--compact .gengage-chat-ai-toppick-img{width:64px;height:64px;object-fit:contain;border-radius:8px;background:#f8fafc;flex-shrink:0}.gengage-chat-ai-toppick-badge{position:absolute;top:8px;left:8px;background:var(--gengage-primary-color, #3b82f6);color:#fff;font-size:10px;font-weight:700;text-transform:uppercase;padding:2px 8px;border-radius:4px;z-index:1;letter-spacing:.5px}.gengage-chat-ai-toppick-body{display:flex;flex-direction:column;gap:4px;padding:10px;flex:1;min-width:0}.gengage-chat-ai-toppick-card--compact .gengage-chat-ai-toppick-body{padding:0}.gengage-chat-ai-toppick-name{font-size:13px;font-weight:600;color:var(--gengage-text-primary, #1e293b);overflow:hidden;text-overflow:ellipsis;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical}.gengage-chat-ai-toppick-role{font-size:11px;font-weight:600;color:var(--gengage-primary-color, #3b82f6);text-transform:uppercase;letter-spacing:.3px}.gengage-chat-ai-toppick-labels{display:flex;flex-wrap:wrap;gap:4px}.gengage-chat-ai-toppick-label{font-size:11px;padding:1px 6px;border-radius:4px;font-weight:500}.gengage-chat-ai-toppick-label[data-sentiment=positive]{background:#dcfce7;color:#166534}.gengage-chat-ai-toppick-label[data-sentiment=negative]{background:#fee2e2;color:#991b1b}.gengage-chat-ai-toppick-label[data-sentiment=neutral]{background:#f1f5f9;color:#475569}.gengage-chat-ai-toppick-score{font-size:12px;font-weight:700;color:var(--gengage-primary-color, #3b82f6)}.gengage-chat-ai-toppick-reason{font-size:12px;color:var(--gengage-chat-text-secondary, #666);line-height:1.4;margin-top:4px}.gengage-chat-ai-toppick-review{font-size:12px;font-style:italic;color:var(--gengage-text-secondary, #64748b);margin:2px 0;padding-left:8px;border-left:2px solid var(--gengage-border-color, #e2e8f0)}.gengage-chat-ai-toppick-price{font-size:14px;font-weight:700;color:var(--gengage-text-primary, #1e293b)}.gengage-chat-ai-toppick-original-price{text-decoration:line-through;color:var(--gengage-text-secondary, #64748b);font-weight:400;font-size:12px}.gengage-chat-ai-toppick-cta{display:block;width:calc(100% - 20px);margin:6px 10px 10px;padding:8px 0;border:none;border-radius:8px;background:var(--gengage-primary-color, #3b82f6);color:#fff;font-size:13px;font-weight:600;cursor:pointer;text-align:center;transition:background .15s ease}.gengage-chat-ai-toppick-cta:hover{filter:brightness(.92)}.gengage-chat-ai-toppick-card--compact .gengage-chat-ai-toppick-cta{width:auto;margin:0;padding:6px 14px;flex-shrink:0;align-self:center}.gengage-chat-ai-toppick-spinner{position:absolute;inset:0;background:#ffffffb3;display:flex;align-items:center;justify-content:center;border-radius:12px;z-index:3}.gengage-chat-ai-toppick-spinner:after{content:"";width:24px;height:24px;border:3px solid var(--gengage-border, #e2e8f0);border-top-color:var(--gengage-accent-primary, #3b82f6);border-radius:50%;animation:gengage-spin .7s linear infinite}@keyframes gengage-spin{to{transform:rotate(360deg)}}@media(max-width:768px){.gengage-chat-ai-top-picks-cards{flex-direction:row;overflow-x:auto;scroll-snap-type:x mandatory;-webkit-overflow-scrolling:touch;gap:10px;padding-bottom:4px}.gengage-chat-ai-toppick-card--winner,.gengage-chat-ai-toppick-card--compact{min-width:280px;max-width:280px;flex-shrink:0;scroll-snap-align:start}.gengage-chat-ai-toppick-card--compact{flex-direction:column;align-items:stretch}.gengage-chat-ai-toppick-card--compact .gengage-chat-ai-toppick-img{width:100%;height:100px;border-radius:8px 8px 0 0}.gengage-chat-ai-toppick-card--compact .gengage-chat-ai-toppick-cta{width:calc(100% - 20px);margin:6px 10px 10px;align-self:stretch}.gengage-chat-rollback-btn{left:-24px}}.gengage-chat-grounding-review{display:flex;align-items:center;gap:12px;padding:12px 16px;background:var(--gengage-surface-color, #f8fafc);border:1px solid var(--gengage-border-color, #e2e8f0);border-radius:10px;transition:background .15s ease,border-color .15s ease}.gengage-chat-grounding-review:hover{background:var(--gengage-hover-color, #f1f5f9);border-color:var(--gengage-primary-color, #3b82f6)}.gengage-chat-grounding-review-icon{font-size:20px;flex-shrink:0}.gengage-chat-grounding-review-body{flex:1;min-width:0}.gengage-chat-grounding-review-title{font-weight:600;font-size:13px;color:var(--gengage-text-color, #1e293b)}.gengage-chat-grounding-review-subtitle{font-size:12px;color:var(--gengage-text-muted, #64748b);margin-top:2px}.gengage-chat-grounding-review-cta{font-size:13px;font-weight:500;color:var(--gengage-primary-color, #3b82f6);white-space:nowrap;flex-shrink:0}.gengage-chat-grouping-cards{display:flex;flex-direction:column;gap:6px}.gengage-chat-grouping-card{display:flex;align-items:center;gap:10px;padding:8px 12px;background:var(--gengage-surface-color, #f8fafc);border:1px solid var(--gengage-border-color, #e2e8f0);border-radius:8px;transition:background .15s ease,border-color .15s ease}.gengage-chat-grouping-card:hover{background:var(--gengage-hover-color, #f1f5f9);border-color:var(--gengage-primary-color, #3b82f6)}.gengage-chat-grouping-card-arrow{display:none;font-size:14px;color:var(--gengage-primary-color, #3b82f6);flex-shrink:0}.gengage-chat-grouping-card-img{width:20px;height:20px;border-radius:4px;object-fit:cover;flex-shrink:0}.gengage-chat-grouping-card-body{flex:1;min-width:0;display:flex;align-items:baseline;gap:6px;flex-wrap:wrap}.gengage-chat-grouping-card-name{font-weight:600;font-size:13px;color:var(--gengage-text-color, #1e293b)}.gengage-chat-grouping-card-desc{font-size:12px;color:var(--gengage-text-muted, #64748b)}.gengage-chat-grouping-card-labels{display:block;font-size:11px;color:var(--gengage-chat-text-secondary, #888);margin-top:2px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.gengage-chat-root--mobile .gengage-chat-grouping-card-img{display:none}.gengage-chat-root--mobile .gengage-chat-grouping-card-arrow{display:inline}.gengage-chat-suggested-search-cards{display:flex;flex-direction:column;gap:8px}.gengage-chat-suggested-search-card{display:flex;align-items:flex-start;gap:12px;padding:10px 14px;background:var(--gengage-surface-color, #f8fafc);border:1px solid var(--gengage-border-color, #e2e8f0);border-radius:10px;transition:background .15s ease,border-color .15s ease}.gengage-chat-suggested-search-card:hover{background:var(--gengage-hover-color, #f1f5f9);border-color:var(--gengage-primary-color, #3b82f6)}.gengage-chat-suggested-search-card-img{width:40px;height:40px;border-radius:6px;object-fit:cover;flex-shrink:0}.gengage-chat-suggested-search-card-body{flex:1;min-width:0}.gengage-chat-suggested-search-card-name{font-weight:600;font-size:13px;color:var(--gengage-text-color, #1e293b)}.gengage-chat-suggested-search-card-desc{font-size:12px;color:var(--gengage-text-secondary, #475569);margin-top:2px}.gengage-chat-suggested-search-card-diff{font-size:11px;color:var(--gengage-text-muted, #64748b);margin-top:2px;font-style:italic}.gengage-chat-product-details-gallery{position:relative}.gengage-chat-product-details-gallery .gengage-chat-product-details-img{touch-action:pan-y}.gengage-chat-product-gallery-thumbs{display:flex;gap:8px;padding:10px 0 4px;overflow-x:auto;scrollbar-width:thin;justify-content:center;width:100%}.gengage-chat-product-gallery-thumb{width:56px;height:56px;object-fit:cover;border-radius:8px;border:2px solid transparent;cursor:pointer;flex-shrink:0;transition:border-color .15s ease;background:#fff}.gengage-chat-product-gallery-thumb:hover{border-color:var(--gengage-border-color, #cbd5e1)}.gengage-chat-product-gallery-thumb--active{border-color:var(--gengage-primary-color, #3b82f6)}.gengage-chat-product-variants{margin-top:12px}.gengage-chat-product-variants-label{font-size:12px;font-weight:600;color:var(--gengage-text-muted, #64748b);margin-bottom:6px;text-transform:uppercase;letter-spacing:.5px}.gengage-chat-product-variants-list{display:flex;flex-wrap:wrap;gap:6px}.gengage-chat-product-variant-btn{padding:6px 12px;border:1px solid var(--gengage-border-color, #e2e8f0);border-radius:6px;background:var(--gengage-surface-color, #f8fafc);color:var(--gengage-text-color, #1e293b);font-size:12px;cursor:pointer;transition:background .15s ease,border-color .15s ease}.gengage-chat-product-variant-btn:hover{background:var(--gengage-hover-color, #f1f5f9);border-color:var(--gengage-primary-color, #3b82f6)}.gengage-chat-product-grid-wrapper{display:flex;flex-direction:column;gap:8px}.gengage-chat-product-sort-toolbar{display:flex;gap:4px;padding:4px;background:var(--gengage-surface-color, #f8fafc);border-radius:8px;border:1px solid var(--gengage-border-color, #e2e8f0)}.gengage-chat-product-sort-btn{flex:1;padding:6px 10px;border:none;border-radius:6px;background:transparent;color:var(--gengage-text-muted, #64748b);font-size:12px;font-weight:500;cursor:pointer;transition:background .15s ease,color .15s ease}.gengage-chat-product-sort-btn:hover{background:var(--gengage-hover-color, #f1f5f9);color:var(--gengage-text-color, #1e293b)}.gengage-chat-product-sort-btn--active,.gengage-chat-product-sort-btn--active:hover{background:var(--gengage-primary-color, #3b82f6);color:#fff}.gengage-chat-product-sort-separator{width:1px;background:var(--gengage-border-color, #e2e8f0);margin:2px}.gengage-chat-comparison-toggle-btn{flex:none;padding:6px 10px;border:none;border-radius:6px;background:transparent;color:var(--gengage-text-muted, #64748b);font-size:12px;font-weight:500;cursor:pointer;transition:background .15s ease,color .15s ease;white-space:nowrap}.gengage-chat-comparison-toggle-btn:hover{background:var(--gengage-hover-color, #f1f5f9);color:var(--gengage-text-color, #1e293b)}.gengage-chat-comparison-toggle-btn--active,.gengage-chat-comparison-toggle-btn--active:hover{background:var(--gengage-primary-color, #3b82f6);color:#fff}.gengage-chat-comparison-select-wrapper{position:relative}.gengage-chat-comparison-checkbox{position:absolute;top:8px;left:8px;z-index:2;width:18px;height:18px;cursor:pointer;accent-color:var(--gengage-primary-color, #3b82f6)}.gengage-chat-comparison-floating-btn{display:block;width:100%;margin-top:8px;padding:10px 16px;border:none;border-radius:8px;background:var(--gengage-primary-color, #3b82f6);color:#fff;font-size:14px;font-weight:600;cursor:pointer;transition:background .15s ease;text-align:center}.gengage-chat-comparison-floating-btn:hover{background:var(--gengage-primary-hover, #2563eb)}.gengage-chat-panel-topbar{display:flex;align-items:center;gap:8px;padding:10px 12px;border-bottom:1px solid var(--_gengage-border-color);background:#f8fafc;min-height:44px;flex-shrink:0;position:sticky;top:0;z-index:3}.gengage-chat-panel-topbar-back,.gengage-chat-panel-topbar-forward{width:28px;height:28px;min-width:28px;padding:0;border:1px solid #d1d5db;border-radius:6px;background:transparent;color:#374151;font-size:14px;font-family:inherit;cursor:pointer;display:flex;align-items:center;justify-content:center;transition:background .15s ease,border-color .15s ease,opacity .15s ease}.gengage-chat-panel-topbar-back:hover:not(:disabled),.gengage-chat-panel-topbar-forward:hover:not(:disabled){background:#f3f4f6;border-color:#9ca3af}.gengage-chat-panel-topbar-back:disabled,.gengage-chat-panel-topbar-forward:disabled{opacity:.3;cursor:default}.gengage-chat-panel-topbar-title{flex:1;font-size:14px;font-weight:600;color:#1f2937;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;text-align:center}@keyframes gengage-typewriter-fade-in{0%{opacity:0;transform:translateY(4px)}to{opacity:1;transform:translateY(0)}}.gengage-chat-typewriter-block{display:block;animation:gengage-typewriter-fade-in .15s ease both}@media(prefers-reduced-motion:reduce){.gengage-chat-typewriter-block{animation:none}}.gengage-product-mention{color:var(--gengage-primary-color, #3b82f6);text-decoration:none;cursor:pointer;font-weight:500;border-bottom:1px dashed var(--gengage-primary-color, #3b82f6);transition:border-color .15s}.gengage-product-mention:hover{border-bottom-style:solid}@keyframes gengage-skeleton-pulse{0%,to{opacity:.4}50%{opacity:.8}}.gengage-chat-panel-skeleton-block{animation:gengage-skeleton-pulse 1.5s ease-in-out infinite}@media(prefers-reduced-motion:reduce){.gengage-chat-panel-skeleton-block{animation:none}}.gengage-chat-input-chips{display:flex;gap:6px;padding:4px 12px 2px;flex-wrap:wrap}.gengage-chat-input-chip{display:inline-flex;align-items:center;padding:4px 10px;border-radius:12px;border:1px solid var(--_gengage-border-color);background:#f9fafb;color:#374151;font-size:12px;font-weight:500;font-family:inherit;cursor:pointer;transition:background .12s,border-color .12s;white-space:nowrap}.gengage-chat-input-chip:hover{background:#f3f4f6;border-color:#d1d5db}.gengage-chat-icon{width:14px;height:14px;flex-shrink:0}.gengage-chat-input-chip-icon,.gengage-chat-pill-icon{display:inline-flex;align-items:center;margin-right:4px}.gengage-chat-product-card-img-wrapper,.gengage-chat-product-details-img-wrap{position:relative;overflow:hidden}.gengage-chat-product-card-discount-badge{position:absolute;top:6px;left:6px;padding:2px 6px;border-radius:4px;background:var(--_gengage-discount-color);color:#fff;font-size:11px;font-weight:700;line-height:1.3;z-index:1}.gengage-chat-product-card-stock{font-size:11px;font-weight:600;margin-top:2px}.gengage-chat-product-card-stock.is-in-stock{color:var(--_gengage-success-color)}.gengage-chat-product-card-stock.is-out-of-stock{color:#dc2626}.gengage-chat-find-similar-pill{position:absolute;top:8px;right:8px;opacity:0;pointer-events:none;transition:opacity .2s ease;padding:4px 10px;font-size:11px;font-weight:500;font-family:inherit;border:none;border-radius:12px;background:var(--gengage-chat-pill-bg, rgba(0, 0, 0, .7));color:var(--gengage-chat-pill-text, #fff);cursor:pointer;white-space:nowrap;z-index:2}.gengage-chat-product-card-img-wrapper:hover .gengage-chat-find-similar-pill,.gengage-chat-product-details-img-wrap:hover .gengage-chat-find-similar-pill{opacity:1;pointer-events:auto}.gengage-chat-favorite-btn{position:absolute;top:8px;right:8px;background:#ffffffe6;border:none;border-radius:50%;width:28px;height:28px;display:flex;align-items:center;justify-content:center;cursor:pointer;color:var(--gengage-text-secondary, #64748b);z-index:3;transition:color .2s;padding:0}.gengage-chat-favorite-btn:hover,.gengage-chat-favorite-btn--active{color:var(--gengage-accent-primary, #ef4444)}.gengage-chat-product-card-promos,.gengage-chat-product-details-promos{display:flex;flex-wrap:wrap;gap:4px;margin-top:4px}.gengage-chat-product-card-promo-badge,.gengage-chat-product-details-promo-badge{display:inline-block;padding:2px 6px;font-size:10px;font-weight:500;border-radius:4px;background:var(--gengage-chat-promo-bg, #e8f5e9);color:var(--gengage-chat-promo-text, #2e7d32);white-space:nowrap}.gengage-chat-thumbnails-column{position:absolute;right:4px;top:50%;transform:translateY(-50%);display:flex;flex-direction:column;gap:4px;z-index:2;pointer-events:auto}.gengage-chat-thumbnail-btn{display:flex;align-items:center;justify-content:center;width:40px;height:40px;padding:0;border:2px solid #e5e7eb;border-radius:6px;background:#fff;cursor:pointer;overflow:hidden;transition:border-color .15s ease}.gengage-chat-thumbnail-btn:hover{border-color:var(--gengage-primary-color, #3b82f6)}.gengage-chat-thumbnail-img{width:100%;height:100%;object-fit:cover}.gengage-chat-choice-prompter{position:absolute;bottom:12px;right:12px;width:200px;padding:12px 14px;background:#fff;border:1px solid var(--_gengage-border-color);border-radius:10px;box-shadow:0 4px 12px #0000001a;z-index:10;animation:gengage-choice-prompter-in .2s ease}@keyframes gengage-choice-prompter-in{0%{opacity:0;transform:translateY(8px)}to{opacity:1;transform:translateY(0)}}.gengage-chat-choice-prompter-heading{font-size:13px;font-weight:600;color:#1f2937;margin-bottom:4px}.gengage-chat-choice-prompter-suggestion{font-size:12px;color:#6b7280;margin-bottom:10px;line-height:1.4}.gengage-chat-choice-prompter-cta{display:block;width:100%;padding:6px 12px;border:none;border-radius:6px;background:var(--gengage-primary-color, #3b82f6);color:#fff;font-size:12px;font-weight:600;font-family:inherit;cursor:pointer;text-align:center;transition:opacity .15s ease}.gengage-chat-choice-prompter-cta:hover{opacity:.9}.gengage-chat-choice-prompter-dismiss{position:absolute;top:4px;right:6px;padding:2px 6px;border:none;background:none;color:#6b7280;font-size:16px;cursor:pointer;line-height:1}.gengage-chat-choice-prompter-dismiss:hover{color:#6b7280}@media(prefers-reduced-motion:reduce){.gengage-chat-choice-prompter{animation:none}}.gengage-chat-pros-cons{padding:12px 14px;background:#f8fafc;border-radius:8px;margin:8px 0}.gengage-chat-pros-cons-heading{margin:0 0 10px;font-size:14px;font-weight:600;color:#0f172a}.gengage-chat-pros-cons-list{list-style:none;margin:0 0 8px;padding:0}.gengage-chat-pros-cons-list:last-child{margin-bottom:0}.gengage-chat-pros-cons-item{display:flex;align-items:flex-start;gap:8px;padding:4px 0;font-size:13px;line-height:1.5;color:#334155}.gengage-chat-pros-cons-icon{flex-shrink:0;width:18px;height:18px;display:flex;align-items:center;justify-content:center;font-size:12px;font-weight:700;border-radius:50%}.gengage-chat-pros-cons-icon--pro{color:#16a34a;background:#dcfce7}.gengage-chat-pros-cons-icon--con{color:#dc2626;background:#fee2e2}.gengage-chat-categories{display:flex;flex-direction:column;gap:8px}.gengage-chat-categories-tabs{display:flex;gap:4px;overflow-x:auto;padding:4px 0;-webkit-overflow-scrolling:touch}.gengage-chat-categories-tab{padding:6px 14px;border:1px solid var(--gengage-border-color, #e5e7eb);border-radius:20px;background:var(--gengage-bg, #fff);color:var(--gengage-text, #374151);cursor:pointer;white-space:nowrap;font-size:13px;transition:background .15s,color .15s}.gengage-chat-categories-tab:hover{background:var(--gengage-bg-hover, #f3f4f6)}.gengage-chat-categories-tab--active{background:var(--gengage-primary, #2563eb);color:#fff;border-color:var(--gengage-primary, #2563eb)}.gengage-chat-categories-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(140px,1fr));gap:8px}.gengage-chat-categories-filter-tags{display:flex;gap:6px;flex-wrap:wrap;margin-top:4px}.gengage-chat-categories-filter-tag{padding:4px 10px;border:1px solid var(--gengage-border-color, #e5e7eb);border-radius:14px;background:var(--gengage-bg, #fff);color:var(--gengage-text-secondary, #6b7280);font-size:12px;cursor:pointer;transition:background .15s}.gengage-chat-categories-filter-tag:hover{background:var(--gengage-bg-hover, #f3f4f6)}.gengage-chat-product-grid-view-more{display:block;width:100%;padding:10px;margin-top:8px;border:1px solid var(--gengage-border-color, #e5e7eb);border-radius:8px;background:var(--gengage-bg, #fff);color:var(--gengage-primary, #2563eb);font-size:14px;font-weight:500;cursor:pointer;text-align:center;transition:background .15s;grid-column:1 / -1}.gengage-chat-product-grid-view-more:hover{background:var(--gengage-bg-hover, #f3f4f6)}.gengage-chat-product-grid--mobile{display:flex;overflow-x:auto;gap:8px;padding:8px 0;-webkit-overflow-scrolling:touch}.gengage-chat-product-grid--mobile .gengage-chat-product-card{min-width:160px;max-width:180px;flex-shrink:0}.gengage-chat-comparison--mobile .gengage-chat-comparison-table,.gengage-chat-comparison--mobile .gengage-chat-comparison-table thead,.gengage-chat-comparison--mobile .gengage-chat-comparison-table tbody{display:block}.gengage-chat-comparison--mobile .gengage-chat-comparison-table tr{display:flex;flex-wrap:wrap}.gengage-chat-comparison-key-differences{margin-top:12px;padding:12px;background:var(--gengage-bg-secondary, #f9fafb);border-radius:8px}.gengage-chat-comparison-key-differences h4{margin:0 0 8px;font-size:14px;font-weight:600;color:var(--gengage-text, #374151)}.gengage-chat-comparison-key-differences-content{font-size:13px;color:var(--gengage-text-secondary, #6b7280);line-height:1.5}.gengage-chat-comparison-key-differences-content ul{margin:0;padding-left:18px}.gengage-chat-comparison-key-differences-content li{margin-bottom:4px}.gengage-chat-product-details-similars-heading{margin:16px 0 8px;font-size:15px;font-weight:600;color:var(--gengage-text, #374151)}.gengage-chat-product-details-similars{margin-top:8px}.gengage-chat-handoff-notice{display:flex;flex-direction:column;align-items:center;gap:6px;padding:16px;margin:8px 0;background:#fef3c7;border:1px solid #fcd34d;border-radius:8px;text-align:center}.gengage-chat-handoff-notice-icon{font-size:24px}.gengage-chat-handoff-notice-heading{margin:0;font-size:14px;font-weight:600;color:#92400e}.gengage-chat-handoff-notice-summary{margin:0;font-size:13px;line-height:1.5;color:#78350f}.gengage-qty-stepper{display:inline-flex;align-items:center;gap:0;border:1px solid #d1d5db;border-radius:8px;overflow:hidden;background:#fff}.gengage-qty-btn{width:var(--_gengage-qty-btn-size);height:var(--_gengage-qty-btn-size);border:none;background:transparent;color:#374151;font-size:14px;font-weight:600;font-family:inherit;cursor:pointer;display:flex;align-items:center;justify-content:center;transition:background-color .12s}.gengage-qty-btn:hover:not(:disabled){background:#f3f4f6}.gengage-qty-btn:disabled{opacity:.35;cursor:default}.gengage-qty-value{min-width:24px;text-align:center;font-size:13px;font-weight:600;color:#1f2937;-webkit-user-select:none;user-select:none}.gengage-qty-submit{border:none;border-left:1px solid #d1d5db;background:var(--_gengage-success-color);color:#fff;font-size:13px;font-weight:700;font-family:inherit;cursor:pointer;padding:6px 12px;transition:filter .12s ease,transform .12s ease}.gengage-qty-submit:hover{filter:brightness(1.08)}.gengage-qty-submit:active{transform:translateY(1px)}.gengage-qty-stepper--compact{border-radius:14px;box-shadow:0 2px 6px #0000001f}.gengage-qty-stepper--compact .gengage-qty-btn{width:var(--_gengage-qty-btn-size-compact);height:var(--_gengage-qty-btn-size-compact);font-size:12px}.gengage-qty-stepper--compact .gengage-qty-value{min-width:18px;font-size:12px}.gengage-qty-stepper--compact .gengage-qty-submit{padding:4px 8px;font-size:13px;border-radius:0 14px 14px 0}.gengage-chat-product-details-atc-stepper{border-radius:10px}.gengage-chat-product-details-atc-stepper .gengage-qty-btn{width:32px;height:32px}.gengage-chat-product-details-atc-stepper .gengage-qty-value{min-width:28px;font-size:14px}.gengage-chat-product-details-atc-stepper .gengage-qty-submit{padding:8px 18px;font-size:14px;border-radius:0 10px 10px 0}.gengage-chat-product-details-share{display:inline-flex;align-items:center;justify-content:center;width:36px;height:36px;border:1px solid #d1d5db;border-radius:10px;background:transparent;color:#6b7280;cursor:pointer;transition:color .12s,border-color .12s,background-color .12s;position:relative;flex-shrink:0}.gengage-chat-product-details-share:hover{color:var(--gengage-primary-color, #3b82f6);border-color:var(--gengage-primary-color, #3b82f6);background:#f0f7ff}.gengage-chat-product-details-share:before{content:attr(aria-label);position:absolute;bottom:calc(100% + 6px);left:50%;transform:translate(-50%);padding:4px 8px;border-radius:4px;background:#1e293b;color:#fff;font-size:11px;font-weight:500;white-space:nowrap;pointer-events:none;opacity:0;transition:opacity .15s ease;z-index:2}.gengage-chat-product-details-share:hover:before{opacity:1}.gengage-chat-product-details-share--copied:after{content:"✓";position:absolute;inset:0;display:flex;align-items:center;justify-content:center;background:var(--_gengage-success-color);color:#fff;border-radius:10px;font-size:16px;font-weight:700}.gengage-chat-launcher:focus-visible,.gengage-chat-close:focus-visible,.gengage-chat-header-btn:focus-visible,.gengage-chat-header-powered:focus-visible,.gengage-chat-proactive-accept:focus-visible,.gengage-chat-proactive-dismiss:focus-visible,.gengage-chat-send:focus-visible,.gengage-chat-action-btn:focus-visible,.gengage-chat-pill:focus-visible,.gengage-chat-input-chip:focus-visible,.gengage-chat-pills-arrow:focus-visible,.gengage-chat-error-retry:focus-visible,.gengage-chat-product-card-cta:focus-visible,.gengage-chat-product-details-cta:focus-visible,.gengage-chat-product-details-atc:focus-visible,.gengage-chat-product-detail-tab:focus-visible,.gengage-chat-panel-divider-toggle:focus-visible,.gengage-chat-panel-topbar-back:focus-visible,.gengage-chat-panel-topbar-forward:focus-visible,.gengage-chat-rollback-btn:focus-visible,.gengage-chat-ai-toppick-cta:focus-visible,.gengage-chat-comparison-view-btn:focus-visible,.gengage-chat-comparison-toggle-btn:focus-visible,.gengage-chat-comparison-floating-btn:focus-visible,.gengage-chat-comparison-checkbox:focus-visible,.gengage-chat-product-sort-btn:focus-visible,.gengage-chat-product-variant-btn:focus-visible,.gengage-chat-product-gallery-thumb:focus-visible,.gengage-chat-thumbnail-btn:focus-visible,.gengage-chat-find-similar-pill:focus-visible,.gengage-chat-favorite-btn:focus-visible,.gengage-chat-attach-btn:focus-visible,.gengage-chat-mic-btn:focus-visible,.gengage-chat-attachment-remove:focus-visible,.gengage-chat-kvkk-dismiss:focus-visible,.gengage-chat-choice-prompter-cta:focus-visible,.gengage-chat-choice-prompter-dismiss:focus-visible,.gengage-chat-categories-tab:focus-visible,.gengage-chat-categories-filter-tag:focus-visible,.gengage-chat-product-grid-view-more:focus-visible,.gengage-chat-product-details-share:focus-visible,.gengage-qty-btn:focus-visible,.gengage-qty-submit:focus-visible{outline:2px solid var(--gengage-primary-color, #3b82f6);outline-offset:2px}', Oa = L({
3061
+ role: be(["user", "assistant"]),
3029
3062
  content: x(),
3030
- timestamp: W().optional()
3031
- }), Fa = L({
3063
+ timestamp: Y().optional()
3064
+ }), qa = L({
3032
3065
  sku: x(),
3033
3066
  name: x(),
3034
3067
  imageUrl: x().url().optional(),
@@ -3037,7 +3070,7 @@ const Ua = ':host{all:initial;font-family:var(--gengage-font-family, -apple-syst
3037
3070
  url: x().url(),
3038
3071
  /** Override CTA label (default: "View product") */
3039
3072
  ctaLabel: x().optional()
3040
- }), Oa = L({
3073
+ }), ja = L({
3041
3074
  buttons: B(
3042
3075
  L({
3043
3076
  label: x(),
@@ -3049,18 +3082,18 @@ const Ua = ':host{all:initial;font-family:var(--gengage-font-family, -apple-syst
3049
3082
  })
3050
3083
  })
3051
3084
  )
3052
- }), qa = L({}), ja = L({
3085
+ }), Va = L({}), Ga = L({
3053
3086
  label: x().optional()
3054
- }), ue = L({
3087
+ }), me = L({
3055
3088
  sku: x(),
3056
3089
  name: x(),
3057
3090
  price: x(),
3058
3091
  imageUrl: x().optional(),
3059
- rating: W().optional(),
3060
- reviewCount: W().optional()
3061
- }), Va = L({
3062
- recommended: ue,
3063
- products: B(ue),
3092
+ rating: Y().optional(),
3093
+ reviewCount: Y().optional()
3094
+ }), $a = L({
3095
+ recommended: me,
3096
+ products: B(me),
3064
3097
  attributes: B(
3065
3098
  L({
3066
3099
  label: x(),
@@ -3070,14 +3103,14 @@ const Ua = ':host{all:initial;font-family:var(--gengage-font-family, -apple-syst
3070
3103
  highlights: B(x()),
3071
3104
  specialCases: B(x()).optional(),
3072
3105
  recommendedText: x().optional(),
3073
- winnerHits: te(
3106
+ winnerHits: ae(
3074
3107
  x(),
3075
3108
  L({
3076
3109
  positive: B(x()).optional(),
3077
3110
  negative: B(x()).optional()
3078
3111
  })
3079
3112
  ).optional(),
3080
- productActions: te(
3113
+ productActions: ae(
3081
3114
  x(),
3082
3115
  L({
3083
3116
  title: x(),
@@ -3085,29 +3118,29 @@ const Ua = ':host{all:initial;font-family:var(--gengage-font-family, -apple-syst
3085
3118
  payload: $().optional()
3086
3119
  })
3087
3120
  ).optional()
3088
- }), Ga = L({
3121
+ }), Ka = L({
3089
3122
  label: x(),
3090
- sentiment: me(["positive", "negative", "neutral"]).optional()
3091
- }), $a = L({
3092
- product: te(x(), $()),
3123
+ sentiment: be(["positive", "negative", "neutral"]).optional()
3124
+ }), Wa = L({
3125
+ product: ae(x(), $()),
3093
3126
  role: x().optional(),
3094
3127
  reason: x().optional(),
3095
- labels: B(Ga).optional(),
3096
- expertQualityScore: W().optional(),
3128
+ labels: B(Ka).optional(),
3129
+ expertQualityScore: Y().optional(),
3097
3130
  reviewHighlight: x().optional(),
3098
3131
  action: L({
3099
3132
  title: x(),
3100
3133
  type: x(),
3101
3134
  payload: $().optional()
3102
3135
  }).optional()
3103
- }), Ka = L({
3104
- suggestions: B($a)
3105
3136
  }), Ya = L({
3137
+ suggestions: B(Wa)
3138
+ }), Qa = L({
3106
3139
  title: x().optional(),
3107
3140
  text: x().optional(),
3108
3141
  reviewCount: x().optional(),
3109
3142
  action: L({ title: x(), type: x(), payload: $().optional() })
3110
- }), Wa = L({
3143
+ }), Xa = L({
3111
3144
  entries: B(
3112
3145
  L({
3113
3146
  name: x(),
@@ -3116,7 +3149,7 @@ const Ua = ':host{all:initial;font-family:var(--gengage-font-family, -apple-syst
3116
3149
  action: L({ title: x(), type: x(), payload: $().optional() })
3117
3150
  })
3118
3151
  )
3119
- }), Qa = L({
3152
+ }), Ja = L({
3120
3153
  entries: B(
3121
3154
  L({
3122
3155
  shortName: x(),
@@ -3126,141 +3159,147 @@ const Ua = ':host{all:initial;font-family:var(--gengage-font-family, -apple-syst
3126
3159
  action: L({ title: x(), type: x(), payload: $().optional() })
3127
3160
  })
3128
3161
  )
3129
- }), Ie = L({
3162
+ }), Ne = L({
3130
3163
  title: x(),
3131
3164
  type: x(),
3132
3165
  payload: $().optional()
3133
- }), Xa = L({
3166
+ }), Za = L({
3134
3167
  name: x().optional(),
3135
3168
  variant_name: x().optional(),
3136
3169
  sku: x().optional(),
3137
- price: oe([W(), x()]).optional()
3138
- }), Ja = L({
3170
+ price: re([Y(), x()]).optional()
3171
+ }), en = L({
3139
3172
  product: L({
3140
3173
  sku: x().optional(),
3141
3174
  name: x().optional(),
3142
3175
  images: B(x()).optional(),
3143
3176
  imageUrl: x().optional(),
3144
- rating: W().optional(),
3145
- reviewCount: W().optional(),
3177
+ rating: Y().optional(),
3178
+ reviewCount: Y().optional(),
3146
3179
  price: x().optional(),
3147
3180
  originalPrice: x().optional(),
3148
- price_async: ie().optional(),
3149
- inStock: ie().optional(),
3181
+ price_async: oe().optional(),
3182
+ inStock: oe().optional(),
3150
3183
  promotions: B(x()).optional(),
3151
- variants: B(Xa).optional(),
3184
+ variants: B(Za).optional(),
3152
3185
  url: x().optional(),
3153
3186
  cartCode: x().optional(),
3154
3187
  description: x().optional(),
3155
- specifications: oe([te(x(), x()), B(L({ key: x(), value: x() }))]).optional()
3188
+ specifications: re([ae(x(), x()), B(L({ key: x(), value: x() }))]).optional()
3156
3189
  }).optional(),
3157
- action: Ie.optional()
3158
- }), Za = L({
3159
- endOfList: ie().optional()
3160
- }), en = L({
3190
+ action: Ne.optional()
3191
+ }), tn = L({
3192
+ endOfList: oe().optional()
3193
+ }), an = L({
3161
3194
  review_class: x().optional(),
3162
3195
  review_text: x().optional(),
3163
- review_rating: oe([x(), W()]).optional(),
3196
+ review_rating: re([x(), Y()]).optional(),
3164
3197
  review_tag: x().optional()
3165
- }), tn = L({
3166
- reviews: B(en).optional()
3167
- }), an = L({
3198
+ }), nn = L({
3199
+ reviews: B(an).optional()
3200
+ }), on = L({
3168
3201
  productName: x().optional(),
3169
3202
  pros: B(x()).optional(),
3170
3203
  cons: B(x()).optional()
3171
- }), nn = L({
3204
+ }), rn = L({
3172
3205
  groups: B(
3173
3206
  L({
3174
3207
  groupName: x(),
3175
- products: B(te(x(), $())).optional()
3208
+ products: B(ae(x(), $())).optional()
3176
3209
  })
3177
3210
  ).optional(),
3178
3211
  filterTags: B(
3179
3212
  L({
3180
3213
  title: x(),
3181
- action: Ie.optional()
3214
+ action: Ne.optional()
3182
3215
  })
3183
3216
  ).optional()
3184
- }), on = L({
3217
+ }), sn = L({
3185
3218
  summary: x().optional(),
3186
3219
  products_discussed: B(x()).optional(),
3187
3220
  user_sentiment: x().optional()
3188
- }), ln = {
3221
+ }), pn = {
3189
3222
  components: {
3190
3223
  MessageBubble: {
3191
- schema: Ha,
3224
+ schema: Oa,
3192
3225
  description: "A single chat message bubble for user or assistant turns."
3193
3226
  },
3194
3227
  ProductCard: {
3195
- schema: Fa,
3228
+ schema: qa,
3196
3229
  description: "A product card rendered inline in the chat stream."
3197
3230
  },
3198
3231
  ActionButtons: {
3199
- schema: Oa,
3232
+ schema: ja,
3200
3233
  description: "A horizontal row of quick-reply action buttons."
3201
3234
  },
3202
3235
  TypingIndicator: {
3203
- schema: qa,
3236
+ schema: Va,
3204
3237
  description: "An animated indicator shown while the assistant is typing."
3205
3238
  },
3206
3239
  Divider: {
3207
- schema: ja,
3240
+ schema: Ga,
3208
3241
  description: "A horizontal rule with an optional label."
3209
3242
  },
3210
3243
  ComparisonTable: {
3211
- schema: Va,
3244
+ schema: $a,
3212
3245
  description: "A product comparison table with recommended pick, attribute rows, and highlights."
3213
3246
  },
3214
3247
  AITopPicks: {
3215
- schema: Ka,
3248
+ schema: Ya,
3216
3249
  description: "Rich AI-curated product suggestion cards with roles, sentiment labels, scores, and review quotes."
3217
3250
  },
3218
3251
  GroundingReviewCard: {
3219
- schema: Ya,
3252
+ schema: Qa,
3220
3253
  description: "A card showing review grounding data with review count and CTA."
3221
3254
  },
3222
3255
  AIGroupingCards: {
3223
- schema: Wa,
3256
+ schema: Xa,
3224
3257
  description: "Category grouping cards with images and labels for product discovery."
3225
3258
  },
3226
3259
  AISuggestedSearchCards: {
3227
- schema: Qa,
3260
+ schema: Ja,
3228
3261
  description: "Suggested search cards with images, descriptions, and differentiation."
3229
3262
  },
3230
3263
  ProductDetailsPanel: {
3231
- schema: Ja,
3264
+ schema: en,
3232
3265
  description: "Full product detail view with images, specs, variants, and purchase actions."
3233
3266
  },
3234
3267
  ProductGrid: {
3235
- schema: Za,
3268
+ schema: tn,
3236
3269
  description: 'A scrollable grid of ProductCard children with optional "more" pagination.'
3237
3270
  },
3238
3271
  ReviewHighlights: {
3239
- schema: tn,
3272
+ schema: nn,
3240
3273
  description: "A list of highlighted customer reviews with sentiment and ratings."
3241
3274
  },
3242
3275
  ProsAndCons: {
3243
- schema: an,
3276
+ schema: on,
3244
3277
  description: "A pros and cons list for a product."
3245
3278
  },
3246
3279
  CategoriesContainer: {
3247
- schema: nn,
3280
+ schema: rn,
3248
3281
  description: "Tabbed product groups with optional filter tag buttons."
3249
3282
  },
3250
3283
  HandoffNotice: {
3251
- schema: on,
3284
+ schema: sn,
3252
3285
  description: "A notice shown when the conversation is escalated to a human agent."
3253
3286
  }
3254
3287
  }
3255
3288
  };
3256
- class rn extends Me {
3289
+ function cn(o) {
3290
+ return o.length > 120 ? !1 : /^[a-zA-Z0-9#(),.\s%/\-]+$/.test(o);
3291
+ }
3292
+ function te(o) {
3293
+ return typeof o == "object" && o !== null && typeof o.type == "string";
3294
+ }
3295
+ class ln extends ze {
3257
3296
  constructor() {
3258
- super(...arguments), this._shadow = null, this._rootEl = null, this._launcher = null, this._drawer = null, this._bridge = null, this._activityTracker = null, this._heartbeat = null, this._proactiveShown = !1, this._drawerVisible = !1, this._messages = [], this._currentMessageId = 0, this._abortControllers = /* @__PURE__ */ new Set(), this._currentThreadId = null, this._lastThreadId = null, this._chatCreatedAt = "", this._lastBackendContext = null, this._productSort = { type: "related" }, this._comparisonSelectMode = !1, this._comparisonSelectedSkus = [], this._thumbnailEntries = [], this._choicePrompterEl = null, this._openState = "full", this._mobileBreakpoint = 768, this._isMobileViewport = !1, this._pdpLaunched = !1, this._i18n = se, this._extendedModeManager = null, this._activeTypewriter = null, this._activeTtsHandle = null, this._activeRequestThreadId = null, this._skuToProductItem = {}, this._conversationMode = null, this._initComplete = !1, this._pendingActions = [], this._bridgeContext = null, this._cartQuantity = null, this._threadsWithFirstBot = /* @__PURE__ */ new Set(), this._panel = null, this._session = null, this._eventCallbacks = /* @__PURE__ */ new Map();
3297
+ super(...arguments), this._shadow = null, this._rootEl = null, this._launcher = null, this._drawer = null, this._bridge = null, this._activityTracker = null, this._heartbeat = null, this._proactiveShown = !1, this._drawerVisible = !1, this._messages = [], this._currentMessageId = 0, this._abortControllers = /* @__PURE__ */ new Set(), this._currentThreadId = null, this._lastThreadId = null, this._chatCreatedAt = "", this._lastBackendContext = null, this._productSort = { type: "related" }, this._comparisonSelectMode = !1, this._comparisonSelectedSkus = [], this._thumbnailEntries = [], this._choicePrompterEl = null, this._openState = "full", this._mobileBreakpoint = 768, this._isMobileViewport = !1, this._pdpLaunched = !1, this._i18n = ce, this._extendedModeManager = null, this._activeTypewriter = null, this._activeTtsHandle = null, this._activeRequestThreadId = null, this._skuToProductItem = {}, this._conversationMode = null, this._initComplete = !1, this._pendingActions = [], this._bridgeContext = null, this._cartQuantity = null, this._threadsWithFirstBot = /* @__PURE__ */ new Set(), this._panel = null, this._session = null, this._eventCallbacks = /* @__PURE__ */ new Map();
3259
3298
  }
3260
3299
  async onInit(e) {
3261
3300
  this._i18n = this._resolveI18n(e), this._chatCreatedAt = (/* @__PURE__ */ new Date()).toISOString(), this._shadow = this.root.attachShadow({ mode: "open" });
3262
3301
  const t = document.createElement("style");
3263
- t.textContent = Ua, this._shadow.appendChild(t);
3302
+ t.textContent = Fa, this._shadow.appendChild(t);
3264
3303
  const a = document.createElement("div");
3265
3304
  a.className = "gengage-chat-root", this._rootEl = a, this._shadow.appendChild(a);
3266
3305
  const n = e.variant ?? "floating";
@@ -3269,11 +3308,11 @@ class rn extends Me {
3269
3308
  onClick: () => this.open(),
3270
3309
  ariaLabel: this._i18n.openButton
3271
3310
  };
3272
- e.launcherSvg !== void 0 && (c.svgMarkup = e.launcherSvg), e.hideMobileLauncher !== void 0 && (c.hideMobile = e.hideMobileLauncher), e.mobileBreakpoint !== void 0 && (c.mobileBreakpoint = e.mobileBreakpoint), e.launcherTooltip !== void 0 && (c.tooltip = e.launcherTooltip), this._launcher = Bt(c), a.appendChild(this._launcher.container);
3311
+ e.launcherSvg !== void 0 && (c.svgMarkup = e.launcherSvg), e.hideMobileLauncher !== void 0 && (c.hideMobile = e.hideMobileLauncher), e.mobileBreakpoint !== void 0 && (c.mobileBreakpoint = e.mobileBreakpoint), e.launcherTooltip !== void 0 && (c.tooltip = e.launcherTooltip), this._launcher = zt(c), a.appendChild(this._launcher.container);
3273
3312
  }
3274
3313
  n === "overlay" && a.classList.add("gengage-chat--overlay");
3275
3314
  const i = document.createElement("div");
3276
- a.appendChild(i), this._drawer = new At(i, {
3315
+ a.appendChild(i), this._drawer = new Bt(i, {
3277
3316
  i18n: this._i18n,
3278
3317
  onSend: (c, h) => this._sendMessage(c, h),
3279
3318
  onClose: () => this.close(),
@@ -3290,7 +3329,7 @@ class rn extends Me {
3290
3329
  headerCartUrl: e.headerCartUrl,
3291
3330
  headerFavoritesToggle: e.headerFavoritesToggle,
3292
3331
  onFavoritesClick: () => {
3293
- ze(), e.onFavoritesClick?.();
3332
+ De(), e.onFavoritesClick?.();
3294
3333
  },
3295
3334
  onThumbnailClick: (c) => this._rollbackToThread(c),
3296
3335
  onLinkClick: (c) => {
@@ -3298,10 +3337,10 @@ class rn extends Me {
3298
3337
  },
3299
3338
  voiceEnabled: e.voiceEnabled,
3300
3339
  voiceLang: e.locale ? `${e.locale.split("-")[0] ?? "tr"}-${(e.locale.split("-")[1] ?? e.locale.split("-")[0] ?? "TR").toUpperCase()}` : void 0
3301
- }), this._extendedModeManager = new La({
3340
+ }), this._extendedModeManager = new Aa({
3302
3341
  onChange: (c) => this._panel?.notifyExtension(c),
3303
3342
  productDetailsInPanel: e.isDemoWebsite ?? !1
3304
- }), this._panel = new Na({
3343
+ }), this._panel = new Pa({
3305
3344
  drawer: () => this._drawer,
3306
3345
  shadow: () => this._shadow,
3307
3346
  currentThreadId: () => this._currentThreadId,
@@ -3310,17 +3349,17 @@ class rn extends Me {
3310
3349
  i18n: () => this._i18n,
3311
3350
  rollbackToThread: (c) => this._rollbackToThread(c)
3312
3351
  }), n !== "inline" && this._drawer.getElement().classList.add("gengage-chat-drawer--hidden"), this._drawer.restorePanelState(e.accountId), (e.panelMode ?? "auto") === "collapsed" ? this._drawer.setPanelCollapsed(!0) : this._drawer.setForceExpanded();
3313
- const s = sessionStorage.getItem("gengage_restore_session_id"), g = sessionStorage.getItem("gengage_restore_sku");
3314
- s && g && (sessionStorage.removeItem("gengage_restore_session_id"), sessionStorage.removeItem("gengage_restore_sku"));
3352
+ const s = sessionStorage.getItem("gengage_restore_session_id"), l = sessionStorage.getItem("gengage_restore_sku");
3353
+ s && l && (sessionStorage.removeItem("gengage_restore_session_id"), sessionStorage.removeItem("gengage_restore_sku"));
3315
3354
  try {
3316
- const c = new Ta();
3317
- await c.open(), this._session = new pe(c), await this._restoreFromIndexedDB();
3355
+ const c = new La();
3356
+ await c.open(), this._session = new he(c), await this._restoreFromIndexedDB();
3318
3357
  } catch {
3319
- this._session = new pe(null);
3358
+ this._session = new he(null);
3320
3359
  }
3321
3360
  this._registerPublicAPI(), e.mobileInitialState !== void 0 && (this._openState = e.mobileInitialState), this._mobileBreakpoint = e.mobileBreakpoint ?? 768, this._syncViewportState();
3322
- const d = () => this._syncViewportState();
3323
- if (window.addEventListener("resize", d, { passive: !0 }), this.addCleanup(() => window.removeEventListener("resize", d)), window.visualViewport) {
3361
+ const g = () => this._syncViewportState();
3362
+ if (window.addEventListener("resize", g, { passive: !0 }), this.addCleanup(() => window.removeEventListener("resize", g)), window.visualViewport) {
3324
3363
  const c = () => {
3325
3364
  if (!this._drawerVisible || !this._isMobileViewport) return;
3326
3365
  const h = this._drawer?.getElement();
@@ -3330,13 +3369,13 @@ class rn extends Me {
3330
3369
  };
3331
3370
  window.visualViewport.addEventListener("resize", c), this.addCleanup(() => window.visualViewport?.removeEventListener("resize", c));
3332
3371
  }
3333
- n === "inline" && (this._drawerVisible = !0, this.isVisible = !0, this._applyOpenStateClasses()), this._bridge = new st({
3372
+ n === "inline" && (this._drawerVisible = !0, this.isVisible = !0, this._applyOpenStateClasses()), this._bridge = new ct({
3334
3373
  namespace: "chat",
3335
3374
  onMessage: (c) => this._handleBridgeMessage(c)
3336
- }), this._activityTracker = new zt({
3375
+ }), this._activityTracker = new Rt({
3337
3376
  idleThresholdMs: e.proactiveDelayMs ?? 3e4,
3338
3377
  onActivity: (c) => {
3339
- if (c.type === "idle" && !this._proactiveShown && !this._drawerVisible && e.proactiveMessage) {
3378
+ if (c.type === "idle" && !this._proactiveShown && !this._drawerVisible) {
3340
3379
  const h = e.proactiveMinScrollDepth ?? 0;
3341
3380
  if (h > 0 && (this._activityTracker?.maxScrollDepth ?? 0) < h * 100)
3342
3381
  return;
@@ -3344,10 +3383,11 @@ class rn extends Me {
3344
3383
  if (sessionStorage.getItem("gengage_proactive_shown")) return;
3345
3384
  } catch {
3346
3385
  }
3347
- this._showProactivePopup(e.proactiveMessage);
3386
+ if (this._isProactiveCooldownActive()) return;
3387
+ e.proactiveFetchActions ? this._fetchAndShowProactive() : e.proactiveMessage && this._showProactivePopup(e.proactiveMessage);
3348
3388
  }
3349
3389
  }
3350
- }), this.addCleanup(() => this._activityTracker?.destroy()), e.enableHeartbeat && (this._heartbeat = new Ut({
3390
+ }), this.addCleanup(() => this._activityTracker?.destroy()), e.enableHeartbeat && (this._heartbeat = new Ft({
3351
3391
  middlewareUrl: e.middlewareUrl,
3352
3392
  accountId: e.accountId,
3353
3393
  sessionId: e.session?.sessionId ?? "",
@@ -3356,17 +3396,28 @@ class rn extends Me {
3356
3396
  getPageType: () => this.config.pageContext?.pageType ?? "other",
3357
3397
  getCurrentSku: () => this.config.pageContext?.sku ?? "",
3358
3398
  onMessage: (c) => {
3359
- !this._proactiveShown && !this._drawerVisible && c.message && this._showProactivePopup(c.message);
3399
+ if (!this._proactiveShown && !this._drawerVisible && c.message) {
3400
+ const h = [];
3401
+ if (c.suggested_actions && Array.isArray(c.suggested_actions))
3402
+ for (const m of c.suggested_actions)
3403
+ m.title && te(m.requestDetails) && h.push({
3404
+ title: m.title,
3405
+ onSelect: () => {
3406
+ this.openWithAction(m.requestDetails);
3407
+ }
3408
+ });
3409
+ this._showProactivePopup(c.message, h.length > 0 ? h : void 0);
3410
+ }
3360
3411
  }
3361
3412
  }), this._heartbeat.start(), this.addCleanup(() => this._heartbeat?.destroy())), this._initComplete = !0;
3362
3413
  for (const c of this._pendingActions)
3363
3414
  this._sendAction(c.action, c.options);
3364
- this._pendingActions = [], O("gengage:chat:ready", {}), De("chat"), e.onReady?.();
3415
+ this._pendingActions = [], O("gengage:chat:ready", {}), Re("chat"), e.onReady?.();
3365
3416
  }
3366
3417
  onUpdate(e) {
3367
3418
  }
3368
3419
  onShow() {
3369
- this._showDrawer(), this.emit("open"), O("gengage:chat:open", { state: this._openState }), Re("chat"), this.config.onOpen?.(), !this._pdpLaunched && this.config.pageContext?.sku && (this._pdpLaunched = !0, this._sendAction(
3420
+ this._showDrawer(), this.emit("open"), O("gengage:chat:open", { state: this._openState }), Ue("chat"), this.config.onOpen?.(), !this._pdpLaunched && this.config.pageContext?.sku && (this._pdpLaunched = !0, this._sendAction(
3370
3421
  {
3371
3422
  title: "",
3372
3423
  type: "launchSingleProduct",
@@ -3388,7 +3439,7 @@ class rn extends Me {
3388
3439
  e?.state !== void 0 && (this._openState = e.state, this._drawerVisible && this._applyOpenStateClasses()), this.show(), e?.initialMessage !== void 0 && this._sendMessage(e.initialMessage);
3389
3440
  }
3390
3441
  openWithAction(e, t) {
3391
- t?.sku !== void 0 && this.update({ sku: t.sku }), this._pdpLaunched = !0, this.show(), this._sendAction(e);
3442
+ t?.sku !== void 0 && this.update({ sku: t.sku }), this._pdpLaunched = !0, t?.state !== void 0 ? this._openState = t.state : this._isMobileViewport && (this._openState = "half"), this.show(), this._drawerVisible && this._applyOpenStateClasses(), this._sendAction(e);
3392
3443
  }
3393
3444
  /** Send a user message programmatically (same flow as typing + submit). */
3394
3445
  sendMessage(e) {
@@ -3431,13 +3482,21 @@ class rn extends Me {
3431
3482
  this.close();
3432
3483
  break;
3433
3484
  case "startNewChatWithLauncherAction": {
3434
- const a = e.payload?.action;
3435
- a && typeof a == "object" && "type" in a && this._sendAction(a, { silent: !0 }), this.open();
3485
+ const t = e.payload, a = t?.action, n = te(a) ? a : te(t) ? t : null;
3486
+ n && this._sendAction(n, { silent: !0 }), this.open();
3436
3487
  break;
3437
3488
  }
3438
3489
  case "startNewChatWithDetailContext": {
3439
3490
  const t = e.payload;
3440
- t && typeof t == "object" && (this._bridgeContext = t), this.open();
3491
+ if (t && typeof t == "object") {
3492
+ this._bridgeContext = t;
3493
+ const a = t.sku;
3494
+ if (a && this.update({ sku: a }), te(t.action)) {
3495
+ this._pdpLaunched = !0, this.open(), this._sendAction(t.action);
3496
+ break;
3497
+ }
3498
+ }
3499
+ this.open();
3441
3500
  break;
3442
3501
  }
3443
3502
  case "launcherAction": {
@@ -3462,7 +3521,7 @@ class rn extends Me {
3462
3521
  break;
3463
3522
  case "bgColorChange": {
3464
3523
  const a = e.payload?.color;
3465
- typeof a == "string" && this._shadow && this._shadow.host.style.setProperty("--gengage-chat-bg", a);
3524
+ typeof a == "string" && cn(a) && this._shadow && this._shadow.host.style.setProperty("--gengage-chat-bg", a);
3466
3525
  break;
3467
3526
  }
3468
3527
  }
@@ -3493,26 +3552,86 @@ class rn extends Me {
3493
3552
  const e = this._drawer?.getElement();
3494
3553
  e && e.classList.remove("gengage-chat-drawer--hidden"), this._applyOpenStateClasses(), this._isMobileViewport && this._openState === "half" || this._drawer?.focusInput(), this._extendedModeManager?.setChatShown(!0);
3495
3554
  }
3496
- _showProactivePopup(e) {
3555
+ _showProactivePopup(e, t) {
3497
3556
  if (this._proactiveShown || !this._rootEl) return;
3498
3557
  this._proactiveShown = !0;
3499
3558
  try {
3500
3559
  sessionStorage.setItem("gengage_proactive_shown", "1");
3501
3560
  } catch {
3502
3561
  }
3503
- const t = {
3562
+ this._setProactiveCooldown();
3563
+ const a = {
3504
3564
  message: e,
3505
3565
  onAccept: () => this.open(),
3506
3566
  onDismiss: () => {
3507
- }
3567
+ },
3568
+ ...t && t.length > 0 && { actionButtons: t }
3508
3569
  };
3509
- this.config.proactiveAcceptLabel !== void 0 && (t.acceptLabel = this.config.proactiveAcceptLabel);
3510
- const a = Mt(t);
3511
- this._rootEl.appendChild(a);
3570
+ this.config.proactiveAcceptLabel !== void 0 && (a.acceptLabel = this.config.proactiveAcceptLabel);
3571
+ const n = Dt(a);
3572
+ this._rootEl.appendChild(n);
3573
+ }
3574
+ /** Fetch proactive actions from backend and show popup with per-action buttons. */
3575
+ async _fetchAndShowProactive() {
3576
+ if (!this._proactiveShown)
3577
+ try {
3578
+ const e = {
3579
+ middlewareUrl: this.config.middlewareUrl,
3580
+ accountId: this.config.accountId,
3581
+ backendType: this.config.backendType ?? "v1"
3582
+ }, t = this.config.pageContext?.sku, a = this.config.pageContext?.pageType, n = this.config.locale, i = await _t(
3583
+ {
3584
+ account_id: this.config.accountId,
3585
+ ...t && { sku: t },
3586
+ ...a && { page_type: a },
3587
+ ...n && { output_language: n }
3588
+ },
3589
+ e
3590
+ );
3591
+ if (!i) return;
3592
+ const r = i.question ?? i.title ?? "";
3593
+ if (!r) return;
3594
+ const s = [];
3595
+ if (i.actions && Array.isArray(i.actions))
3596
+ for (const l of i.actions) {
3597
+ const g = l, c = g.title;
3598
+ if (c && te(g.requestDetails)) {
3599
+ const h = g.requestDetails;
3600
+ s.push({
3601
+ title: c,
3602
+ onSelect: () => {
3603
+ this.openWithAction(h);
3604
+ }
3605
+ });
3606
+ }
3607
+ }
3608
+ this._showProactivePopup(r, s);
3609
+ } catch {
3610
+ }
3611
+ }
3612
+ _proactiveCooldownKey() {
3613
+ return `gengage_proactive_time_${this.config.accountId}`;
3614
+ }
3615
+ _isProactiveCooldownActive() {
3616
+ try {
3617
+ const e = localStorage.getItem(this._proactiveCooldownKey());
3618
+ if (e) {
3619
+ const t = Date.now() - parseInt(e, 10), a = this.config.proactiveCooldownMs ?? 36e5;
3620
+ return t < a;
3621
+ }
3622
+ } catch {
3623
+ }
3624
+ return !1;
3625
+ }
3626
+ _setProactiveCooldown() {
3627
+ try {
3628
+ localStorage.setItem(this._proactiveCooldownKey(), String(Date.now()));
3629
+ } catch {
3630
+ }
3512
3631
  }
3513
3632
  _hideDrawer() {
3514
3633
  if (!this._drawerVisible) return;
3515
- this._activeTypewriter?.cancel(), this._activeTypewriter = null, this._activeTtsHandle?.stop(), this._activeTtsHandle = null, this._drawerVisible = !1;
3634
+ this._activeTypewriter?.cancel(), this._activeTypewriter = null, this._activeTtsHandle?.stop(), this._activeTtsHandle = null, this._drawerVisible = !1, this._openState = "full", this._drawer?.clearPanel();
3516
3635
  const e = this._drawer?.getElement();
3517
3636
  e && e.classList.add("gengage-chat-drawer--hidden"), this._applyOpenStateClasses(), this._extendedModeManager?.setChatShown(!1);
3518
3637
  }
@@ -3531,7 +3650,7 @@ class rn extends Me {
3531
3650
  this._rootEl.classList.toggle("gengage-chat-root--open", this._drawerVisible), this._rootEl.classList.toggle("gengage-chat-root--mobile-half", e), this._rootEl.classList.toggle("gengage-chat-root--mobile-full", t);
3532
3651
  }
3533
3652
  _handleAttachment(e) {
3534
- const t = mt(e);
3653
+ const t = ft(e);
3535
3654
  if (!t.ok) {
3536
3655
  const a = t.reason === "invalid_type" ? this._i18n.invalidFileType : this._i18n.fileTooLarge;
3537
3656
  O("gengage:global:error", {
@@ -3543,7 +3662,7 @@ class rn extends Me {
3543
3662
  this._drawer?.stageAttachment(e);
3544
3663
  }
3545
3664
  _sendMessage(e, t) {
3546
- Ue(), this._messages.some((i) => i.role === "user") || He();
3665
+ He(), this._messages.some((i) => i.role === "user") || Fe();
3547
3666
  const n = {
3548
3667
  title: e,
3549
3668
  type: "user_message",
@@ -3560,13 +3679,13 @@ class rn extends Me {
3560
3679
  const p = this._currentThreadId, y = this._messages.filter((k) => k.threadId !== void 0 && k.threadId > p);
3561
3680
  this._messages = this._messages.filter((k) => !k.threadId || k.threadId <= p);
3562
3681
  for (const k of y)
3563
- this._shadow?.querySelector(`[data-message-id="${k.id}"]`)?.remove(), this._panel.snapshots.delete(k.id), this._panel.snapshotTypes.delete(k.id);
3682
+ this._shadow?.querySelector(`[data-message-id="${CSS.escape(k.id)}"]`)?.remove(), this._panel.snapshots.delete(k.id), this._panel.snapshotTypes.delete(k.id);
3564
3683
  this._shadow?.querySelectorAll("[data-thread-id]")?.forEach((k) => {
3565
3684
  k instanceof HTMLElement && k.dataset.threadId && k.dataset.threadId > p && k.remove();
3566
3685
  });
3567
3686
  }
3568
3687
  this._drawer?.setPills([]), this._drawer?.clearInputAreaChips(), this._bridge?.send("isResponding", !0);
3569
- const a = rt();
3688
+ const a = st();
3570
3689
  this._currentThreadId = a, this._lastThreadId = a;
3571
3690
  const n = t?.preservePanel === !0;
3572
3691
  if (n || (this._activeRequestThreadId = a), !t?.silent) {
@@ -3583,11 +3702,11 @@ class rn extends Me {
3583
3702
  ...this.config.accountId ? { accountId: this.config.accountId } : {}
3584
3703
  };
3585
3704
  t?.attachment !== void 0 && (s.attachment = t.attachment);
3586
- const d = this._getVisibleMessages().filter((p) => p.content).slice(-50).map((p) => ({
3705
+ const g = this._getVisibleMessages().filter((p) => p.content).slice(-50).map((p) => ({
3587
3706
  role: p.role === "user" ? "user" : "model",
3588
3707
  content: p.content ?? ""
3589
3708
  })), c = {
3590
- outputLanguage: Ra(this.config.locale),
3709
+ outputLanguage: Ha(this.config.locale),
3591
3710
  parentUrl: window.location.href,
3592
3711
  windowWidth: String(window.innerWidth),
3593
3712
  windowHeight: String(window.innerHeight),
@@ -3597,14 +3716,14 @@ class rn extends Me {
3597
3716
  appId: this.config.accountId,
3598
3717
  threads: [],
3599
3718
  createdAt: this._chatCreatedAt,
3600
- kvkkApproved: he(this.config.accountId),
3719
+ kvkkApproved: ue(this.config.accountId),
3601
3720
  voiceEnabled: this.config.voiceEnabled ?? !1,
3602
3721
  threadId: a,
3603
3722
  isControlGroup: this.config.session?.abTestVariant === "control",
3604
3723
  isMobile: this._isMobileViewport
3605
3724
  };
3606
3725
  this.config.session?.viewId !== void 0 && (c.viewId = this.config.session.viewId);
3607
- const h = ft(e, {
3726
+ const h = bt(e, {
3608
3727
  pageContext: this.config.pageContext,
3609
3728
  backendContext: this._lastBackendContext,
3610
3729
  isMobile: this._isMobileViewport
@@ -3620,62 +3739,62 @@ class rn extends Me {
3620
3739
  // authoritative chatHistory — the backend's stale `messages` must not
3621
3740
  // overwrite the up-to-date conversation history built by the widget.
3622
3741
  ...this._lastBackendContext ?? {},
3623
- messages: d,
3742
+ messages: g,
3624
3743
  // V1 backend reads session_id from context (not top-level).
3625
3744
  // Include here for V1 compatibility; V2 uses thread_id from meta.
3626
3745
  session_id: this.config.session?.sessionId ?? ""
3627
3746
  }
3628
3747
  };
3629
3748
  this.config.session?.userId !== void 0 && (m.user_id = this.config.session.userId), this.config.session?.viewId !== void 0 && (m.view_id = this.config.session.viewId), h.payload !== void 0 && (m.payload = h.payload), this.config.pageContext?.sku !== void 0 && (m.sku = this.config.pageContext.sku), this.config.pageContext?.pageType !== void 0 && (m.page_type = this.config.pageContext.pageType);
3630
- const l = crypto.randomUUID(), v = Date.now();
3749
+ const d = crypto.randomUUID(), v = Date.now();
3631
3750
  let w = 0, b = !1, N = !1;
3632
3751
  this.track(
3633
- Fe(this.analyticsContext(), {
3752
+ Oe(this.analyticsContext(), {
3634
3753
  endpoint: "process_action",
3635
- request_id: l,
3754
+ request_id: d,
3636
3755
  widget: "chat"
3637
3756
  })
3638
3757
  );
3639
3758
  let I = null;
3640
- I = wt(
3759
+ I = yt(
3641
3760
  m,
3642
3761
  {
3643
3762
  onTextChunk: (p, y, _) => {
3644
3763
  if (!n && a !== this._activeRequestThreadId || (i += p, this._drawer?.removeTypingIndicator(), _?.skuToProductItem && (this._skuToProductItem = { ...this._skuToProductItem, ..._.skuToProductItem }), _?.conversationMode && (this._conversationMode = _.conversationMode), this.track(
3645
- ot(this.analyticsContext(), {
3646
- request_id: l,
3764
+ rt(this.analyticsContext(), {
3765
+ request_id: d,
3647
3766
  chunk_index: w++,
3648
3767
  widget: "chat"
3649
3768
  })
3650
3769
  ), !this._drawer)) return;
3651
3770
  let k = i;
3652
- if (y && ce(k)) {
3771
+ if (y && le(k)) {
3653
3772
  const u = this.config.accountId;
3654
- if (!he(u)) {
3655
- const f = za(k);
3773
+ if (!ue(u)) {
3774
+ const f = Ra(k);
3656
3775
  f && this._drawer?.showKvkkBanner(f, () => {
3657
3776
  this._drawer?.hideKvkkBanner();
3658
- }), Ba(u);
3777
+ }), za(u);
3659
3778
  }
3660
- k = Ma(k);
3779
+ k = Da(k);
3661
3780
  }
3662
3781
  const A = this._shadow?.querySelector(
3663
3782
  `[data-message-id="${r.id}"] .gengage-chat-bubble-text`
3664
3783
  );
3665
3784
  if (A ? A.innerHTML = Z(k) : (r.content = k, r.role === "assistant" && r.threadId && !this._threadsWithFirstBot.has(r.threadId) && (this._threadsWithFirstBot.add(r.threadId), this._drawer.markFirstBotMessage(r.id)), this._drawer.addMessage(r)), y) {
3666
- r.content = k, r.status = "done", le();
3785
+ r.content = k, r.status = "done", ge();
3667
3786
  const u = this._shadow?.querySelector(
3668
3787
  `[data-message-id="${r.id}"] .gengage-chat-bubble-text`
3669
3788
  );
3670
3789
  if (u) {
3671
3790
  this._activeTypewriter?.cancel();
3672
3791
  const f = _?.productMentions;
3673
- this._activeTypewriter = xa({
3792
+ this._activeTypewriter = wa({
3674
3793
  container: u,
3675
3794
  html: Z(k),
3676
3795
  onTick: () => this._drawer?.scrollToBottomIfNeeded(),
3677
3796
  onComplete: () => {
3678
- this._activeTypewriter = null, f && f.length > 0 && u && va({
3797
+ this._activeTypewriter = null, f && f.length > 0 && u && ya({
3679
3798
  container: u,
3680
3799
  mentions: f,
3681
3800
  onProductClick: (C) => {
@@ -3695,8 +3814,8 @@ class rn extends Me {
3695
3814
  if (!n && a !== this._activeRequestThreadId || y !== "chat") return;
3696
3815
  const k = p.elements[p.root], A = k?.type ?? "unknown";
3697
3816
  this.track(
3698
- at(this.analyticsContext(), {
3699
- request_id: l,
3817
+ nt(this.analyticsContext(), {
3818
+ request_id: d,
3700
3819
  chunk_index: w,
3701
3820
  component_type: A,
3702
3821
  widget: "chat"
@@ -3705,11 +3824,11 @@ class rn extends Me {
3705
3824
  const u = this._buildRenderContext();
3706
3825
  if (A === "ComparisonTable") {
3707
3826
  const S = k?.props?.products;
3708
- nt(Array.isArray(S) ? S.length : 0);
3827
+ it(Array.isArray(S) ? S.length : 0);
3709
3828
  }
3710
3829
  if (A === "ProductGrid") {
3711
3830
  const S = k?.children?.length ?? 0;
3712
- it(void 0, S);
3831
+ ot(void 0, S);
3713
3832
  }
3714
3833
  const f = _ === "panel" && this._panel ? this._panel.toPanelSpec(p) : p, C = !r.silent && (_ !== "panel" || A === "ProductCard") && A !== "ActionButtons";
3715
3834
  if (_ === "panel" && this._panel) {
@@ -3756,7 +3875,7 @@ class rn extends Me {
3756
3875
  ].filter(Boolean)).map((T) => T.imageUrl).filter((T) => typeof T == "string").slice(0, 5);
3757
3876
  P.length > 0 && this._bridge?.send("previewImages", { images: P });
3758
3877
  }
3759
- if (A === "ProductGrid" && _ === "panel" && !this._comparisonSelectMode && !Ca() && (this._choicePrompterEl?.remove(), this._choicePrompterEl = ka({
3878
+ if (A === "ProductGrid" && _ === "panel" && !this._comparisonSelectMode && !Sa() && (this._choicePrompterEl?.remove(), this._choicePrompterEl = Ea({
3760
3879
  heading: this._i18n.choicePrompterHeading,
3761
3880
  suggestion: this._i18n.choicePrompterSuggestion,
3762
3881
  ctaLabel: this._i18n.choicePrompterCta,
@@ -3771,7 +3890,7 @@ class rn extends Me {
3771
3890
  if (S && S.length > 0) {
3772
3891
  const P = [], T = [];
3773
3892
  for (const E of S)
3774
- if (_a(E)) {
3893
+ if (Ca(E)) {
3775
3894
  const M = {
3776
3895
  label: E.label,
3777
3896
  action: E.action
@@ -3801,7 +3920,7 @@ class rn extends Me {
3801
3920
  onAction: (p) => {
3802
3921
  if (!(!n && a !== this._activeRequestThreadId) && p.type === "action") {
3803
3922
  const y = {};
3804
- this.config.actionHandling?.unknownActionPolicy !== void 0 && (y.unknownActionPolicy = this.config.actionHandling.unknownActionPolicy), this.config.actionHandling?.allowScriptCall !== void 0 && (y.allowScriptCall = this.config.actionHandling.allowScriptCall), gt(
3923
+ this.config.actionHandling?.unknownActionPolicy !== void 0 && (y.unknownActionPolicy = this.config.actionHandling.unknownActionPolicy), this.config.actionHandling?.allowScriptCall !== void 0 && (y.allowScriptCall = this.config.actionHandling.allowScriptCall), dt(
3805
3924
  p,
3806
3925
  {
3807
3926
  openChat: () => this.open(),
@@ -3833,9 +3952,9 @@ class rn extends Me {
3833
3952
  bubbles: !1,
3834
3953
  cancelable: !0
3835
3954
  }), k = window.dispatchEvent(_);
3836
- if (et(), k) {
3955
+ if (tt(), k) {
3837
3956
  const A = p.meta.voice;
3838
- A.audio_base64 && (this._activeTtsHandle?.stop(), this._activeTtsHandle = Rt(
3957
+ A.audio_base64 && (this._activeTtsHandle?.stop(), this._activeTtsHandle = Ht(
3839
3958
  A.audio_base64,
3840
3959
  A.content_type ?? "audio/ogg"
3841
3960
  ));
@@ -3850,7 +3969,7 @@ class rn extends Me {
3850
3969
  }), p.meta.launcherContent && this._bridge?.send("launcherContent", p.meta.launcherContent), O("gengage:chat:metadata", { payload: p.meta });
3851
3970
  const y = p.meta;
3852
3971
  typeof y.prompt_tokens == "number" && typeof y.completion_tokens == "number" && this.track(
3853
- tt(this.analyticsContext(), {
3972
+ at(this.analyticsContext(), {
3854
3973
  model: p.model ?? "unknown",
3855
3974
  prompt_tokens: y.prompt_tokens,
3856
3975
  completion_tokens: y.completion_tokens,
@@ -3865,8 +3984,8 @@ class rn extends Me {
3865
3984
  code: "STREAM_ERROR",
3866
3985
  message: this._i18n.errorMessage
3867
3986
  }), this.emit("error", p), this._drawer?.showError(p.message), r.status === "streaming" && (r.status = "error"), this.track(
3868
- Ze(this.analyticsContext(), {
3869
- request_id: l,
3987
+ et(this.analyticsContext(), {
3988
+ request_id: d,
3870
3989
  error_code: "STREAM_ERROR",
3871
3990
  error_message: p.message,
3872
3991
  widget: "chat"
@@ -3874,21 +3993,21 @@ class rn extends Me {
3874
3993
  ));
3875
3994
  },
3876
3995
  onDone: () => {
3877
- I && this._abortControllers.delete(I), !(!n && a !== this._activeRequestThreadId) && (this._activeRequestThreadId = null, this._bridge?.send("isResponding", !1), this._bridge?.send("loadingMessage", { text: null }), this._drawer?.removeTypingIndicator(), b && !N && this._drawer?.isPanelLoading() && this._drawer.clearPanel(), b = !1, N = !1, r.status === "streaming" && (r.status = "done", le()), this.emit("message", r), this._panel?.snapshotForMessage(r.id), this._panel?.attachClickHandler(r.id), this.track(
3878
- Qe(this.analyticsContext(), {
3879
- request_id: l,
3996
+ I && this._abortControllers.delete(I), !(!n && a !== this._activeRequestThreadId) && (this._activeRequestThreadId = null, this._bridge?.send("isResponding", !1), this._bridge?.send("loadingMessage", { text: null }), this._drawer?.removeTypingIndicator(), b && !N && this._drawer?.isPanelLoading() && this._drawer.clearPanel(), b = !1, N = !1, r.status === "streaming" && (r.status = "done", ge()), this.emit("message", r), this._panel?.snapshotForMessage(r.id), this._panel?.attachClickHandler(r.id), this.track(
3997
+ Xe(this.analyticsContext(), {
3998
+ request_id: d,
3880
3999
  latency_ms: Date.now() - v,
3881
4000
  chunk_count: w,
3882
4001
  widget: "chat"
3883
4002
  })
3884
4003
  ), this.track(
3885
- Xe(this.analyticsContext(), {
4004
+ Je(this.analyticsContext(), {
3886
4005
  meter_key: "chat_request",
3887
4006
  quantity: 1,
3888
4007
  unit: "request"
3889
4008
  })
3890
4009
  ), this.track(
3891
- Je(this.analyticsContext(), {
4010
+ Ze(this.analyticsContext(), {
3892
4011
  message_count: this._messages.length,
3893
4012
  history_ref: this.config.session?.sessionId ?? "",
3894
4013
  redaction_level: "none"
@@ -3925,7 +4044,7 @@ class rn extends Me {
3925
4044
  _rollbackToThread(e) {
3926
4045
  this._currentThreadId = e, this._extendedModeManager?.setHiddenByUser(!1);
3927
4046
  for (const i of this._messages) {
3928
- const r = this._shadow?.querySelector(`[data-message-id="${i.id}"]`);
4047
+ const r = this._shadow?.querySelector(`[data-message-id="${CSS.escape(i.id)}"]`);
3929
4048
  r && (i.threadId && i.threadId > e ? r.classList.add("gengage-chat-bubble--hidden") : r.classList.remove("gengage-chat-bubble--hidden"));
3930
4049
  }
3931
4050
  this._shadow?.querySelectorAll("[data-thread-id]").forEach((i) => {
@@ -3986,8 +4105,8 @@ class rn extends Me {
3986
4105
  if (!n || n.messages.length === 0) return;
3987
4106
  if (this._pdpLaunched = !0, this._drawer?.lockScrollForRestore(), this._currentThreadId = n.currentThreadId, this._lastThreadId = n.lastThreadId, this._chatCreatedAt = n.createdAt, n.panelThreads && (this._panel.threads = n.panelThreads), n.thumbnailEntries && (this._thumbnailEntries = n.thumbnailEntries, this._drawer?.setThumbnails(this._thumbnailEntries)), n.panelSnapshotHtml)
3988
4107
  for (const [r, s] of Object.entries(n.panelSnapshotHtml)) {
3989
- const g = document.createElement("div");
3990
- g.innerHTML = Z(s), this._panel.snapshots.set(r, g);
4108
+ const l = document.createElement("div");
4109
+ l.innerHTML = Z(s), this._panel.snapshots.set(r, l);
3991
4110
  }
3992
4111
  let i = 0;
3993
4112
  for (const r of n.messages) {
@@ -3999,10 +4118,10 @@ class rn extends Me {
3999
4118
  };
4000
4119
  if (r.threadId !== void 0 && (s.threadId = r.threadId), r.content !== void 0 && (s.content = r.content), r.silent && (s.silent = !0), this._messages.push(s), s.silent) continue;
4001
4120
  s.role === "assistant" && s.threadId && !this._threadsWithFirstBot.has(s.threadId) && (this._threadsWithFirstBot.add(s.threadId), this._drawer?.markFirstBotMessage(s.id)), this._drawer?.addMessage(s);
4002
- const g = parseInt(r.id.replace("msg-", ""), 10);
4003
- if (!isNaN(g) && g > i && (i = g), s.role === "assistant" && s.threadId) {
4004
- const d = await this._loadPayload(s.threadId, s.id);
4005
- d && (s.uiSpec = d, this._restoreInlineUISpec(s), this._panel?.attachClickHandler(s.id), delete s.uiSpec);
4121
+ const l = parseInt(r.id.replace("msg-", ""), 10);
4122
+ if (!isNaN(l) && l > i && (i = l), s.role === "assistant" && s.threadId) {
4123
+ const g = await this._loadPayload(s.threadId, s.id);
4124
+ g && (s.uiSpec = g, this._restoreInlineUISpec(s), this._panel?.attachClickHandler(s.id), delete s.uiSpec);
4006
4125
  }
4007
4126
  }
4008
4127
  if (i > this._currentMessageId && (this._currentMessageId = i), this._currentThreadId) {
@@ -4016,7 +4135,7 @@ class rn extends Me {
4016
4135
  if (this._currentThreadId) {
4017
4136
  const r = this._currentThreadId;
4018
4137
  for (const s of this._messages)
4019
- s.threadId && s.threadId > r && this._shadow?.querySelector(`[data-message-id="${s.id}"]`)?.classList.add("gengage-chat-bubble--hidden");
4138
+ s.threadId && s.threadId > r && this._shadow?.querySelector(`[data-message-id="${CSS.escape(s.id)}"]`)?.classList.add("gengage-chat-bubble--hidden");
4020
4139
  this._shadow?.querySelectorAll("[data-thread-id]").forEach((s) => {
4021
4140
  s instanceof HTMLElement && s.dataset.threadId && s.dataset.threadId > r && s.classList.add("gengage-chat-bubble--hidden");
4022
4141
  });
@@ -4024,12 +4143,12 @@ class rn extends Me {
4024
4143
  if (this._panel.threads.length > 0 && this._currentThreadId) {
4025
4144
  const r = this._panel.threads[this._panel.threads.length - 1];
4026
4145
  if (r) {
4027
- const s = [...this._messages].reverse().find((g) => g.role === "assistant" && g.threadId === r);
4146
+ const s = [...this._messages].reverse().find((l) => l.role === "assistant" && l.threadId === r);
4028
4147
  if (s?.threadId) {
4029
- const g = await this._loadPayload(s.threadId, s.id);
4030
- if (g) {
4031
- const d = g.elements[g.root];
4032
- d && this._panel?.updateTopBar(d.type);
4148
+ const l = await this._loadPayload(s.threadId, s.id);
4149
+ if (l) {
4150
+ const g = l.elements[l.root];
4151
+ g && this._panel?.updateTopBar(g.type);
4033
4152
  }
4034
4153
  }
4035
4154
  }
@@ -4045,16 +4164,16 @@ class rn extends Me {
4045
4164
  _buildRenderContext() {
4046
4165
  const e = {
4047
4166
  onAction: (t) => {
4048
- if (Ke(t.title, t.type), t.type === "findSimilar") {
4167
+ if (We(t.title, t.type), t.type === "findSimilar") {
4049
4168
  const n = typeof t.payload == "object" && t.payload !== null && "sku" in t.payload ? String(t.payload.sku) : "";
4050
4169
  Ye(n);
4051
4170
  }
4052
- t.type === "getComparisonTable" && We(this._comparisonSelectedSkus);
4171
+ t.type === "getComparisonTable" && Qe(this._comparisonSelectedSkus);
4053
4172
  const a = t.type === "addToCart" || t.type === "like";
4054
4173
  this._sendAction(t, a ? { preservePanel: !0 } : void 0);
4055
4174
  },
4056
4175
  onProductClick: (t) => {
4057
- $e(t.sku), O("gengage:similar:product-click", {
4176
+ Ke(t.sku), O("gengage:similar:product-click", {
4058
4177
  sku: t.sku,
4059
4178
  url: t.url,
4060
4179
  sessionId: this.config.session?.sessionId ?? null
@@ -4065,7 +4184,7 @@ class rn extends Me {
4065
4184
  }) : this._saveSessionAndOpenURL(t.url);
4066
4185
  },
4067
4186
  onAddToCart: (t) => {
4068
- Ge(t.sku, t.quantity);
4187
+ $e(t.sku, t.quantity);
4069
4188
  const a = {
4070
4189
  ...t,
4071
4190
  sessionId: this.config.session?.sessionId ?? null
@@ -4100,11 +4219,11 @@ class rn extends Me {
4100
4219
  comparisonSelectMode: this._comparisonSelectMode,
4101
4220
  comparisonSelectedSkus: this._comparisonSelectedSkus,
4102
4221
  onToggleComparisonSku: (t) => {
4103
- t === "" ? (this._comparisonSelectMode = !this._comparisonSelectMode, this._comparisonSelectMode || (this._comparisonSelectedSkus = [], je())) : this._comparisonSelectedSkus.indexOf(t) >= 0 ? this._comparisonSelectedSkus = this._comparisonSelectedSkus.filter((n) => n !== t) : (this._comparisonSelectedSkus = [...this._comparisonSelectedSkus, t], Ve(t));
4222
+ t === "" ? (this._comparisonSelectMode = !this._comparisonSelectMode, this._comparisonSelectMode || (this._comparisonSelectedSkus = [], Ve())) : this._comparisonSelectedSkus.indexOf(t) >= 0 ? this._comparisonSelectedSkus = this._comparisonSelectedSkus.filter((n) => n !== t) : (this._comparisonSelectedSkus = [...this._comparisonSelectedSkus, t], Ge(t));
4104
4223
  },
4105
4224
  favoritedSkus: this._session?.favoritedSkus ?? /* @__PURE__ */ new Set(),
4106
4225
  onFavoriteToggle: (t, a) => {
4107
- qe(t), this._toggleFavorite(t, a);
4226
+ je(t), this._toggleFavorite(t, a);
4108
4227
  const n = a.name ?? t;
4109
4228
  this._sendAction(
4110
4229
  {
@@ -4164,12 +4283,12 @@ class rn extends Me {
4164
4283
  const i = this._buildRenderContext(), r = this._shadow?.querySelector(".gengage-chat-messages");
4165
4284
  if (!r) return;
4166
4285
  if (n === "ProductDetailsPanel") {
4167
- const g = a.props?.product;
4168
- if (!g) return;
4169
- const d = {
4286
+ const l = a.props?.product;
4287
+ if (!l) return;
4288
+ const g = {
4170
4289
  root: "root",
4171
- elements: { root: { type: "ProductSummaryCard", props: { product: g } } }
4172
- }, c = this._renderUISpec(d, i);
4290
+ elements: { root: { type: "ProductSummaryCard", props: { product: l } } }
4291
+ }, c = this._renderUISpec(g, i);
4173
4292
  e.threadId && (c.dataset.threadId = e.threadId), r.appendChild(c);
4174
4293
  return;
4175
4294
  }
@@ -4186,14 +4305,14 @@ class rn extends Me {
4186
4305
  };
4187
4306
  }
4188
4307
  _resolveI18n(e) {
4189
- return { ...kt(e.locale), ...e.i18n };
4308
+ return { ...Et(e.locale), ...e.i18n };
4190
4309
  }
4191
4310
  _resolveUISpecRegistry() {
4192
- const e = na();
4193
- return Oe(e, this.config.renderer?.registry);
4311
+ const e = oa();
4312
+ return qe(e, this.config.renderer?.registry);
4194
4313
  }
4195
4314
  _renderUISpec(e, t) {
4196
- const a = this._resolveUISpecRegistry(), n = this.config.renderer?.unknownRenderer ?? Ce, i = (g, d) => ia(g, d, a, n), r = this.config.renderer?.renderUISpec;
4315
+ const a = this._resolveUISpecRegistry(), n = this.config.renderer?.unknownRenderer ?? Se, i = (l, g) => ra(l, g, a, n), r = this.config.renderer?.renderUISpec;
4197
4316
  return r ? r(e, t, {
4198
4317
  registry: a,
4199
4318
  unknownRenderer: n,
@@ -4201,18 +4320,18 @@ class rn extends Me {
4201
4320
  }) : i(e, t);
4202
4321
  }
4203
4322
  }
4204
- function gn() {
4205
- return new rn();
4323
+ function hn() {
4324
+ return new ln();
4206
4325
  }
4207
4326
  export {
4208
- rn as G,
4209
- Et as V,
4210
- na as a,
4211
- ia as b,
4212
- gn as c,
4213
- Ce as d,
4214
- ln as e,
4215
- Ct as i,
4216
- gt as r
4327
+ ln as G,
4328
+ Tt as V,
4329
+ oa as a,
4330
+ ra as b,
4331
+ hn as c,
4332
+ Se as d,
4333
+ pn as e,
4334
+ St as i,
4335
+ dt as r
4217
4336
  };
4218
- //# sourceMappingURL=index-CmlYMq-h.js.map
4337
+ //# sourceMappingURL=index-CXbH-cw8.js.map