/* CSS Variables */
:root {
  --v1akgm-z2: #4f46e5;
  --ivy0-w7k: #ffffff;
  --mfvil-k9zc: #f9fafb;
  --e38g-xpt: #0f172a;
  --yj5q2f-ck7: #6b7280;
  --xjo4yd-et64: #e5e7eb;
  --c1xv5-i6a: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --c4a-qgwt: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  --twz1-j8: 16px;
  --cvsi-lf87: 56px;
  --lniq-hnt9: 12px;
  --mfqf-o7a: 999999;
}

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

/* Main Container */
.bw97 {
  position: fixed; bottom: 24px; right: 24px; z-index: var(--mfqf-o7a);
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  font-size: 14px; line-height: 1.5; color: var(--e38g-xpt);
}
.bw97.ve3b57 { right: auto; left: 24px; }

/* Floating Panel - Buttons */
.d6eb { display: flex; flex-direction: column-reverse; gap: var(--lniq-hnt9); align-items: center; }
.z54n4 {
  width: var(--cvsi-lf87); height: var(--cvsi-lf87); min-width: var(--cvsi-lf87); min-height: var(--cvsi-lf87);
  border-radius: 50%; border: none; background: var(--v1akgm-z2); color: #fff; cursor: pointer;
  display: flex; align-items: center; justify-content: center; box-shadow: var(--c1xv5-i6a);
  transition: transform .2s ease, box-shadow .2s ease; position: relative; overflow: visible;
}
.z54n4:hover { transform: scale(1.05); box-shadow: var(--c4a-qgwt); }
.z54n4:active { transform: scale(0.95); }
.z54n4:focus { outline: 2px solid var(--v1akgm-z2); outline-offset: 2px; }
.z54n4 svg { width: 24px; height: 24px; fill: currentColor; }

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

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

/* Reduced motion */
@media (prefers-reduced-motion: reduce){
  .z54n4.h0xumj{ animation:none; }
  .z54n4,.u1yd,.au4o4{ transition:none!important; animation:none!important; }
}

/* Chat Window (animate with visibility/pointer-events, not display) */
.u1yd{
  position: fixed; bottom: 96px; right: 24px; width: 360px; height: 480px;
  background: var(--ivy0-w7k); border-radius: var(--twz1-j8); box-shadow: var(--c4a-qgwt);
  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;
}
.bw97.ve3b57 .u1yd{ right:auto; left:24px; }
.u1yd.s7pohu{ opacity:1; transform:translateY(0) scale(1); visibility:visible; pointer-events:auto; }

/* Header */
.trkwz{
  padding:16px 20px; background:var(--ivy0-w7k); border-bottom:1px solid var(--xjo4yd-et64);
  display:flex; align-items:center; gap:12px; min-height:64px;
}
.envqip{ width:10px; height:10px; border-radius:50%; background:var(--v1akgm-z2); flex-shrink:0; }
.iel8{ flex:1; min-width:0; }
.na6za{ font-size:16px; font-weight:600; color:var(--e38g-xpt); margin:0 0 2px 0; }
.u0w6{ font-size:13px; color:var(--yj5q2f-ck7); margin:0; }
.e2awxr{
  width:32px; height:32px; min-width:32px; border:none; background:transparent; color:var(--yj5q2f-ck7);
  cursor:pointer; border-radius:8px; display:flex; align-items:center; justify-content:center;
  transition: background .2s ease, color .2s ease; flex-shrink:0;
}
.e2awxr:hover{ background:var(--mfvil-k9zc); color:var(--e38g-xpt); }
.e2awxr:focus{ outline:2px solid var(--v1akgm-z2); outline-offset:2px; }
.e2awxr svg{ width:20px; height:20px; }

/* Body */
.ksy6s{
  flex:1; overflow-y:auto; padding:16px; background:var(--mfvil-k9zc);
  display:flex; flex-direction:column; gap:12px;
}
.ksy6s::-webkit-scrollbar{ width:6px; }
.ksy6s::-webkit-scrollbar-track{ background:transparent; }
.ksy6s::-webkit-scrollbar-thumb{ background:var(--xjo4yd-et64); border-radius:3px; }
.ksy6s::-webkit-scrollbar-thumb:hover{ background:var(--yj5q2f-ck7); }

/* Messages */
.au4o4{ display:flex; gap:8px; animation:slideIn .2s ease; }
@keyframes slideIn{ from{opacity:0; transform:translateY(10px);} to{opacity:1; transform:translateY(0);} }
.au4o4.budy{ flex-direction:row-reverse; }
.gdi2e{
  max-width:75%; padding:10px 14px; border-radius:12px; word-wrap:break-word; word-break:break-word;
}
.gdi2e a{ color:inherit; }
.au4o4.laoww .gdi2e{ background:var(--ivy0-w7k); color:var(--e38g-xpt); border-bottom-left-radius:4px; }
.au4o4.budy .gdi2e{ background:var(--v1akgm-z2); color:#fff; border-bottom-right-radius:4px; }
.tvum{ font-size:11px; color:var(--yj5q2f-ck7); margin-top:4px; display:block; }

/* Typing Indicator */
.v7tnd{
  display:flex; gap:8px; padding:10px 14px; background:var(--ivy0-w7k);
  border-radius:12px; border-bottom-left-radius:4px; max-width:fit-content;
}
.f6j8q{ width:8px; height:8px; border-radius:50%; background:var(--yj5q2f-ck7); animation:typingDot 1.4s infinite; }
.f6j8q:nth-child(2){ animation-delay:.2s; }
.f6j8q: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) */
.b4oj{
  display:flex; flex-wrap:wrap; gap:8px; margin:6px 0 0; padding:0 2px;
}
.hwvdj{
  border:0; border-radius:999px; padding:8px 12px; background:var(--v1akgm-z2); 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(--c1xv5-i6a);
}
.hwvdj:is(:hover,:focus){ transform:translateY(-1px); }
a.hwvdj{ text-decoration:none; display:inline-block; }
a.hwvdj:link, a.hwvdj:visited{ color:#fff; }
a.hwvdj:hover, a.hwvdj:focus{ color:#fff; }

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

/* Footer */
.zv7iet{
  padding:16px; background:var(--ivy0-w7k); border-top:1px solid var(--xjo4yd-et64);
  display:flex; gap:12px; align-items:flex-end; position:relative;
}
.lra3{
  flex:1; padding:10px 14px; border:1px solid var(--xjo4yd-et64); border-radius:20px;
  font-family:inherit; font-size:14px; line-height:1.5; color:var(--e38g-xpt);
  background:var(--mfvil-k9zc); resize:none; max-height:96px; min-height:40px; outline:none; transition:border-color .2s ease;
}
.lra3:focus{ border-color:var(--v1akgm-z2); }
.lra3::placeholder{ color:var(--yj5q2f-ck7); }
.lra3.a9yr1{ border-color:#c00; }
.k3jl{
  width:40px; height:40px; min-width:40px; border:none; background:var(--v1akgm-z2); color:#fff;
  border-radius:50%; cursor:pointer; display:flex; align-items:center; justify-content:center; transition:transform .2s ease, opacity .2s ease;
}
.k3jl:disabled{ opacity:.5; cursor:not-allowed; }
.k3jl:not(:disabled):hover{ transform:scale(1.05); }
.k3jl:not(:disabled):active{ transform:scale(0.95); }
.k3jl:focus{ outline:2px solid var(--v1akgm-z2); outline-offset:2px; }
.k3jl svg{ width:20px; height:20px; }

/* Character Counter */
.h2v4{ position:absolute; bottom:4px; right:52px; font-size:11px; color:var(--yj5q2f-ck7); }
.h2v4.eft5sf{ color:#c00; font-weight:600; }

/* ---- INLINE CTA BUTTONS ("buttons" payload) ---- */
/* Looks like an operator bubble with pill buttons inside */
.g7c26{
  align-self:flex-start;
  max-width:75%;
  background: var(--ivy0-w7k);
  color: var(--e38g-xpt);
  border-radius:12px; border-bottom-left-radius:4px;
  padding:10px 12px;
  box-shadow: var(--c1xv5-i6a);
}
.z7z08{ display:flex; flex-wrap:wrap; gap:8px; }

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

/* Optional outline variant */
.akke9s.ew6vhi{
  background: transparent; color: var(--e38g-xpt); border-color: var(--xjo4yd-et64);
}
.akke9s.ew6vhi:hover{
  background: var(--v1akgm-z2); color:#fff; border-color: var(--v1akgm-z2);
}

/* Mobile */
@media (max-width: 768px){
  .bw97{ bottom:16px; right:16px; }
  .bw97.ve3b57{ left:16px; }
  .z54n4{ --cvsi-lf87:60px; }
  .u1yd{
    position:fixed; bottom:0; right:0; left:0; width:100%; height:65vh; max-height:65vh;
    border-radius: var(--twz1-j8) var(--twz1-j8) 0 0; transform: translateY(100%);
  }
  .u1yd.s7pohu{ transform: translateY(0); }
  .trkwz{ padding:20px; }
  .zv7iet{ padding:16px; padding-bottom:max(16px, env(safe-area-inset-bottom)); }
}

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

/* Focus Visible */
.bw97 :focus-visible{ outline:2px solid var(--v1akgm-z2); outline-offset:2px; }

/* SR-only */
.xf0xj{
  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 */
.nijs5{ display:none !important; }
