/* Animart Chat – clean, shadcn-like widget. Uses the theme colours when present. */
.ach{--ach:#e11d48;--ach-bg:var(--wp--preset--color--base,#fff);--ach-bg2:var(--wp--preset--color--base-2,#f4f4f5);--ach-ink:var(--wp--preset--color--contrast,#09090b);--ach-mut:var(--wp--preset--color--contrast-2,#71717a);--ach-line:var(--wp--preset--color--border,#e4e4e7);position:fixed;right:20px;bottom:20px;z-index:9990;font-family:inherit;font-size:14px;line-height:1.45;color:var(--ach-ink)}
.ach *{box-sizing:border-box}
.ach-sr{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0)}
.ach-bubble{position:relative;display:grid;place-items:center;width:56px;height:56px;margin-left:auto;padding:0;border:0;border-radius:50%;background:var(--ach);color:#fff;cursor:pointer;box-shadow:0 10px 30px -6px rgba(0,0,0,.35);transition:transform .2s}
.ach-bubble:hover{transform:scale(1.06)}
.ach-bubble:focus-visible{outline:2px solid var(--ach-ink);outline-offset:3px}
.ach.is-open .ach-bubble{transform:scale(.92)}
.ach.has-new .ach-bubble{animation:ach-pulse 1.6s ease-in-out infinite}
@keyframes ach-pulse{50%{box-shadow:0 0 0 10px rgba(225,29,72,.15),0 10px 30px -6px rgba(0,0,0,.35)}}
.ach-badge{position:absolute;top:-4px;right:-4px;min-width:20px;height:20px;padding:0 6px;border-radius:999px;background:var(--ach-ink);color:var(--ach-bg);font-size:11px;font-weight:700;line-height:20px;text-align:center}
.ach-badge[hidden]{display:none}
.ach-panel{position:absolute;right:0;bottom:70px;display:flex;flex-direction:column;width:min(370px,calc(100vw - 32px));height:min(560px,calc(100vh - 120px));border:1px solid var(--ach-line);border-radius:16px;background:var(--ach-bg);box-shadow:0 24px 60px -12px rgba(0,0,0,.28);overflow:hidden;transform-origin:bottom right;animation:ach-in .18s ease-out}
.ach-panel[hidden]{display:none}
@keyframes ach-in{from{opacity:0;transform:translateY(8px) scale(.98)}}
.ach-head{display:flex;align-items:center;justify-content:space-between;gap:.75rem;padding:14px 14px 12px 16px;border-bottom:1px solid var(--ach-line)}
.ach-head strong{display:block;font-size:15px}
.ach-status{display:flex;align-items:center;gap:6px;margin-top:2px;font-size:12px;color:var(--ach-mut)}
.ach-status i{width:8px;height:8px;border-radius:50%;background:#a1a1aa;flex:0 0 auto}
.ach.is-online .ach-status i{background:#22c55e;box-shadow:0 0 0 3px rgba(34,197,94,.2)}
.ach-status em{font-style:normal}
.ach-x{display:grid;place-items:center;width:34px;height:34px;padding:0;border:0;border-radius:8px;background:transparent;color:var(--ach-mut);cursor:pointer}
.ach-x:hover{background:var(--ach-bg2);color:var(--ach-ink)}
.ach-body{flex:1 1 auto;overflow-y:auto;padding:16px;background:var(--ach-bg)}
.ach-msgs{display:flex;flex-direction:column;gap:10px}
.ach-msg{display:flex;flex-direction:column;max-width:82%}
.ach-msg--me{align-self:flex-end;align-items:flex-end}
.ach-msg--them{align-self:flex-start}
.ach-msg__b{padding:9px 12px;border-radius:14px;white-space:pre-wrap;word-break:break-word}
.ach-msg--me .ach-msg__b{background:var(--ach);color:#fff;border-bottom-right-radius:4px}
.ach-msg--them .ach-msg__b{background:var(--ach-bg2);border-bottom-left-radius:4px}
.ach-msg__t{margin-top:3px;font-size:11px;color:var(--ach-mut)}
.ach-msg.is-failed .ach-msg__b{opacity:.55}
.ach-start{display:grid;gap:8px;padding:12px 16px 14px;border-top:1px solid var(--ach-line)}
.ach-start[hidden],.ach-input[hidden],.ach-err[hidden]{display:none}
.ach-start input,.ach-start textarea,.ach-input textarea{width:100%;padding:9px 11px;border:1px solid var(--ach-line);border-radius:10px;background:var(--ach-bg);color:var(--ach-ink);font:inherit;font-size:16px;resize:none;outline:none}
.ach-start input:focus,.ach-start textarea:focus,.ach-input textarea:focus{border-color:var(--ach-ink);box-shadow:0 0 0 3px rgba(0,0,0,.06)}
.ach-start button{height:42px;border:0;border-radius:10px;background:var(--ach-ink);color:var(--ach-bg);font:inherit;font-weight:600;cursor:pointer}
.ach-privacy{margin:0;font-size:11px;color:var(--ach-mut)}
.ach-input{display:flex;align-items:flex-end;gap:8px;padding:10px 12px;border-top:1px solid var(--ach-line)}
.ach-input textarea{min-height:42px;max-height:120px}
.ach-input button{flex:0 0 42px;height:42px;display:grid;place-items:center;padding:0;border:0;border-radius:10px;background:var(--ach);color:#fff;cursor:pointer}
.ach-err{margin:0;padding:8px 16px;background:#fef2f2;color:#b91c1c;font-size:12px}
@media (max-width:600px){.ach{right:14px;bottom:14px}.ach.is-open{left:0;right:0;top:0;bottom:0}.ach.is-open .ach-bubble{display:none}.ach-panel{position:fixed;inset:0;width:100%;height:100%;border:0;border-radius:0}}
@media (max-width:700px){.single-product .ach:not(.is-open){bottom:84px}}
html[data-theme=dark] .ach-panel{box-shadow:0 24px 60px -12px rgba(0,0,0,.7)}
html[data-theme=dark] .ach-err{background:rgba(185,28,28,.15);color:#fca5a5}
@media (prefers-reduced-motion:reduce){.ach-panel,.ach.has-new .ach-bubble{animation:none}}
