/* CSS Variables */
:root {
  --aky-y5: #4f46e5;
  --ng920-aj3: #ffffff;
  --t5d-zonq: #f9fafb;
  --uofs-gu: #0f172a;
  --lpemv-el: #6b7280;
  --r66ter-a4: #e5e7eb;
  --zpevp-xz4: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --r9z-e7w: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  --fzl6z-crvc: 16px;
  --ftbtam-g64: 56px;
  --q8oven-td: 12px;
  --lcp-mcj: 999999;
}

/* Base Reset */
.glir,
.glir * { box-sizing: border-box; margin: 0; padding: 0; }

/* Main Container */
.glir {
  position: fixed; bottom: 24px; right: 24px; z-index: var(--lcp-mcj);
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  font-size: 14px; line-height: 1.5; color: var(--uofs-gu);
}
.glir.kx6slr { right: auto; left: 24px; }

/* Floating Panel - Buttons */
.e23lh { display: flex; flex-direction: column-reverse; gap: var(--q8oven-td); align-items: center; }
.cssplx {
  width: var(--ftbtam-g64); height: var(--ftbtam-g64); min-width: var(--ftbtam-g64); min-height: var(--ftbtam-g64);
  border-radius: 50%; border: none; background: var(--aky-y5); color: #fff; cursor: pointer;
  display: flex; align-items: center; justify-content: center; box-shadow: var(--zpevp-xz4);
  transition: transform .2s ease, box-shadow .2s ease; position: relative; overflow: visible;
}
.cssplx:hover { transform: scale(1.05); box-shadow: var(--r9z-e7w); }
.cssplx:active { transform: scale(0.95); }
.cssplx:focus { outline: 2px solid var(--aky-y5); outline-offset: 2px; }
.cssplx svg { width: 24px; height: 24px; fill: currentColor; }

/* Messenger Buttons - Specific Colors */
.cssplx[data-xakuhl3="telegram"]{ background:#0088cc; }
.cssplx[data-xakuhl3="whatsapp"]{ background:#25d366; }
.cssplx[data-xakuhl3="viber"]{ background:#7360f2; }
.cssplx[data-xakuhl3="messenger"]{ background:#0084ff; }

/* Pulse Animation */
@keyframes pulse { 0%,100%{ transform:scale(1); opacity:1;} 50%{ transform:scale(1.05); opacity:.9;} }
.cssplx.p5pd15{ animation:pulse 2s ease-in-out infinite; }

/* Reduced motion */
@media (prefers-reduced-motion: reduce){
  .cssplx.p5pd15{ animation:none; }
  .cssplx,.w57y67,.uma3t{ transition:none!important; animation:none!important; }
}

/* Chat Window (animate with visibility/pointer-events, not display) */
.w57y67{
  position: fixed; bottom: 96px; right: 24px; width: 360px; height: 480px;
  background: var(--ng920-aj3); border-radius: var(--fzl6z-crvc); box-shadow: var(--r9z-e7w);
  display: flex; flex-direction: column; overflow: hidden;
  opacity: 0; transform: translateY(20px) scale(0.95); transition: opacity .2s ease, transform .2s ease;
  visibility: hidden; pointer-events: none;
}
.glir.kx6slr .w57y67{ right:auto; left:24px; }
.w57y67.ziwcuq{ opacity:1; transform:translateY(0) scale(1); visibility:visible; pointer-events:auto; }

/* Header */
.kdoa{
  padding:16px 20px; background:var(--ng920-aj3); border-bottom:1px solid var(--r66ter-a4);
  display:flex; align-items:center; gap:12px; min-height:64px;
}
.teehh{ width:10px; height:10px; border-radius:50%; background:var(--aky-y5); flex-shrink:0; }
.et0cw{ flex:1; min-width:0; }
.wtw8we{ font-size:16px; font-weight:600; color:var(--uofs-gu); margin:0 0 2px 0; }
.qtxjqe{ font-size:13px; color:var(--lpemv-el); margin:0; }
.qfct{
  width:32px; height:32px; min-width:32px; border:none; background:transparent; color:var(--lpemv-el);
  cursor:pointer; border-radius:8px; display:flex; align-items:center; justify-content:center;
  transition: background .2s ease, color .2s ease; flex-shrink:0;
}
.qfct:hover{ background:var(--t5d-zonq); color:var(--uofs-gu); }
.qfct:focus{ outline:2px solid var(--aky-y5); outline-offset:2px; }
.qfct svg{ width:20px; height:20px; }

/* Body */
.dmuwit{
  flex:1; overflow-y:auto; padding:16px; background:var(--t5d-zonq);
  display:flex; flex-direction:column; gap:12px;
}
.dmuwit::-webkit-scrollbar{ width:6px; }
.dmuwit::-webkit-scrollbar-track{ background:transparent; }
.dmuwit::-webkit-scrollbar-thumb{ background:var(--r66ter-a4); border-radius:3px; }
.dmuwit::-webkit-scrollbar-thumb:hover{ background:var(--lpemv-el); }

/* Messages */
.uma3t{ display:flex; gap:8px; animation:slideIn .2s ease; }
@keyframes slideIn{ from{opacity:0; transform:translateY(10px);} to{opacity:1; transform:translateY(0);} }
.uma3t.lg72z{ flex-direction:row-reverse; }
.m70d{
  max-width:75%; padding:10px 14px; border-radius:12px; word-wrap:break-word; word-break:break-word;
}
.m70d a{ color:inherit; }
.uma3t.t3jf5 .m70d{ background:var(--ng920-aj3); color:var(--uofs-gu); border-bottom-left-radius:4px; }
.uma3t.lg72z .m70d{ background:var(--aky-y5); color:#fff; border-bottom-right-radius:4px; }
.htnx2{ font-size:11px; color:var(--lpemv-el); margin-top:4px; display:block; }

/* Typing Indicator */
.j1luh{
  display:flex; gap:8px; padding:10px 14px; background:var(--ng920-aj3);
  border-radius:12px; border-bottom-left-radius:4px; max-width:fit-content;
}
.wxmkt{ width:8px; height:8px; border-radius:50%; background:var(--lpemv-el); animation:typingDot 1.4s infinite; }
.wxmkt:nth-child(2){ animation-delay:.2s; }
.wxmkt:nth-child(3){ animation-delay:.4s; }
@keyframes typingDot{ 0%,60%,100%{ transform:translateY(0); opacity:.5;} 30%{ transform:translateY(-8px); opacity:1;} }

/* Quick Replies (chips) */
.narde4{
  display:flex; flex-wrap:wrap; gap:8px; margin:6px 0 0; padding:0 2px;
}
.otkx8{
  border:0; border-radius:999px; padding:8px 12px; background:var(--aky-y5); color:#fff; cursor:pointer;
  font:inherit; line-height:1; transition:transform .08s ease, background .2s ease, color .2s ease, border-color .2s ease;
  box-shadow: var(--zpevp-xz4);
}
.otkx8:is(:hover,:focus){ transform:translateY(-1px); }
a.otkx8{ text-decoration:none; display:inline-block; }
a.otkx8:link, a.otkx8:visited{ color:#fff; }
a.otkx8:hover, a.otkx8:focus{ color:#fff; }

/* Error Banner */
.dsofk{
  padding:12px 16px; background:#fee; color:#c00; border-radius:8px; font-size:13px;
  display:flex; align-items:center; justify-content:space-between; gap:12px;
}
.ug6m{
  padding:6px 12px; background:#c00; color:#fff; border:none; border-radius:6px; font-size:12px; cursor:pointer; white-space:nowrap;
}

/* Footer */
.fbr3{
  padding:16px; background:var(--ng920-aj3); border-top:1px solid var(--r66ter-a4);
  display:flex; gap:12px; align-items:flex-end; position:relative;
}
.t9n3{
  flex:1; padding:10px 14px; border:1px solid var(--r66ter-a4); border-radius:20px;
  font-family:inherit; font-size:14px; line-height:1.5; color:var(--uofs-gu);
  background:var(--t5d-zonq); resize:none; max-height:96px; min-height:40px; outline:none; transition:border-color .2s ease;
}
.t9n3:focus{ border-color:var(--aky-y5); }
.t9n3::placeholder{ color:var(--lpemv-el); }
.t9n3.tkogsm{ border-color:#c00; }
.lnwhel{
  width:40px; height:40px; min-width:40px; border:none; background:var(--aky-y5); color:#fff;
  border-radius:50%; cursor:pointer; display:flex; align-items:center; justify-content:center; transition:transform .2s ease, opacity .2s ease;
}
.lnwhel:disabled{ opacity:.5; cursor:not-allowed; }
.lnwhel:not(:disabled):hover{ transform:scale(1.05); }
.lnwhel:not(:disabled):active{ transform:scale(0.95); }
.lnwhel:focus{ outline:2px solid var(--aky-y5); outline-offset:2px; }
.lnwhel svg{ width:20px; height:20px; }

/* Character Counter */
.wrha{ position:absolute; bottom:4px; right:52px; font-size:11px; color:var(--lpemv-el); }
.wrha.zysfs9{ color:#c00; font-weight:600; }

/* ---- INLINE CTA BUTTONS ("buttons" payload) ---- */
/* Looks like an operator bubble with pill buttons inside */
.ww99{
  align-self:flex-start;
  max-width:75%;
  background: var(--ng920-aj3);
  color: var(--uofs-gu);
  border-radius:12px; border-bottom-left-radius:4px;
  padding:10px 12px;
  box-shadow: var(--zpevp-xz4);
}
.bsxq{ display:flex; flex-wrap:wrap; gap:8px; }

/* Solid pill buttons */
.j23o{
  display:inline-flex; align-items:center; gap:6px;
  padding:8px 14px; border-radius:999px;
  background: var(--aky-y5); color:#fff; border:1px solid transparent;
  font-size:13px; line-height:1; text-decoration:none;
  box-shadow: var(--zpevp-xz4);
  transition: transform .08s ease, background .2s ease, color .2s ease, box-shadow .2s ease;
}
.j23o:link, .j23o:visited{ color:#fff; }
.j23o:hover{ transform:translateY(-1px); box-shadow: var(--r9z-e7w); }
.j23o:active{ transform:translateY(0); }
.j23o:focus-visible{ outline:2px solid var(--aky-y5); outline-offset:2px; }

/* Optional outline variant */
.j23o.l5jfy{
  background: transparent; color: var(--uofs-gu); border-color: var(--r66ter-a4);
}
.j23o.l5jfy:hover{
  background: var(--aky-y5); color:#fff; border-color: var(--aky-y5);
}

/* Mobile */
@media (max-width: 768px){
  .glir{ bottom:16px; right:16px; }
  .glir.kx6slr{ left:16px; }
  .cssplx{ --ftbtam-g64:60px; }
  .w57y67{
    position:fixed; bottom:0; right:0; left:0; width:100%; height:65vh; max-height:65vh;
    border-radius: var(--fzl6z-crvc) var(--fzl6z-crvc) 0 0; transform: translateY(100%);
  }
  .w57y67.ziwcuq{ transform: translateY(0); }
  .kdoa{ padding:20px; }
  .fbr3{ padding:16px; padding-bottom:max(16px, env(safe-area-inset-bottom)); }
}

/* High Contrast */
@media (prefers-contrast: high){ .cssplx, .w57y67{ border:2px solid currentColor; } }

/* Focus Visible */
.glir :focus-visible{ outline:2px solid var(--aky-y5); outline-offset:2px; }

/* SR-only */
.k3zp4{
  position:absolute; width:1px; height:1px; padding:0; margin:-1px; overflow:hidden; clip:rect(0,0,0,0); white-space:nowrap; border-width:0;
}

/* Hidden */
.udcm{ display:none !important; }
