/* Fixwright chat: soft card, round header buttons, colored tiles, pill input. Tokens come from the theme, with fallbacks. */
.fw-chat-fab,.fw-chat,.fw-chat-teaser{--ink:var(--fw-ink,#142B4A);--b:var(--fw-brand,#0000F3);--sky:var(--fw-sky,#59C2F4);--mut:#6F7B93;--line:#E7EAF3;font-family:Inter,system-ui,-apple-system,"Segoe UI",sans-serif}
.fw-chat-fab{position:fixed;right:22px;bottom:22px;z-index:90;width:62px;height:62px;padding:0;border:0;border-radius:50%;cursor:pointer;display:grid;place-items:center;background:linear-gradient(135deg,#0000F3 0%,#3D6BFF 55%,#59C2F4 100%);box-shadow:0 14px 28px -8px rgba(0,0,243,.55),inset 0 1px 0 rgba(255,255,255,.35);transition:transform .2s,box-shadow .2s}
.fw-chat-fab.is-left{right:auto;left:22px}
.fw-chat-fab svg{width:32px;height:32px;fill:#fff;filter:drop-shadow(0 1px 2px rgba(0,0,60,.35));transition:transform .5s}.fw-chat-fab .s2{opacity:.9}
.fw-chat-fab:hover svg{transform:rotate(90deg) scale(1.08)}.fw-chat-fab:hover{transform:translateY(-3px);box-shadow:0 20px 36px -8px rgba(0,0,243,.6)}
.fw-chat-fab[aria-expanded=true]{display:none}
.fw-chat-teaser{position:fixed;right:96px;bottom:34px;z-index:89;max-width:230px;background:#fff;color:var(--ink);padding:12px 38px 12px 16px;border-radius:18px 18px 4px 18px;font:600 .9rem/1.35 Inter,sans-serif;box-shadow:0 14px 34px -10px rgba(20,43,74,.35);cursor:pointer;animation:fw-cin .35s ease both}
.fw-chat-teaser.is-left{right:auto;left:96px;border-radius:18px 18px 18px 4px}
.fw-chat-teaser button{position:absolute;top:6px;right:6px;width:24px;height:24px;border:0;border-radius:50%;background:transparent;color:#6B7F96;font-size:1.1rem;line-height:1;cursor:pointer}
@keyframes fw-cin{from{opacity:0;transform:translateY(10px) scale(.98)}to{opacity:1;transform:none}}

/* card */
.fw-chat{position:fixed;right:22px;bottom:22px;z-index:95;width:min(372px,calc(100vw - 28px));height:min(620px,calc(100dvh - 44px));display:flex;flex-direction:column;background:linear-gradient(180deg,#F5F7FE 0%,#FFFFFF 38%);border:1px solid rgba(255,255,255,.9);border-radius:30px;box-shadow:0 30px 70px -20px rgba(31,45,110,.38),0 2px 0 rgba(255,255,255,.8) inset,0 0 0 1px rgba(110,125,190,.10);overflow:hidden;animation:fw-cin .3s ease both}
.fw-chat.is-left{right:auto;left:22px}
.fw-chat[hidden]{display:none}
.admin-bar .fw-chat{height:min(620px,calc(100dvh - 76px))}
.fw-chat__head{display:flex;align-items:center;gap:12px;padding:20px 20px 8px}
.fw-chat__av{flex:none;width:52px;height:52px;border-radius:50%;background:#fff;display:grid;place-items:center;box-shadow:0 0 0 5px rgba(120,140,255,.12),0 6px 16px -6px rgba(31,45,110,.35)}
.fw-chat__av img{width:34px;height:auto;display:block}.fw-chat__av svg{width:24px;height:24px;color:var(--b)}
.fw-chat__id{flex:1;min-width:0}
.fw-chat__id b{display:block;font:700 1.02rem/1.2 Inter,sans-serif;color:var(--ink);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.fw-chat__id small{display:flex;align-items:center;gap:6px;margin-top:3px;font:500 .78rem/1.2 Inter,sans-serif;color:var(--mut)}
.fw-chat__id small i{width:8px;height:8px;border-radius:50%;background:#22C55E;box-shadow:0 0 0 3px rgba(34,197,94,.18)}
.fw-chat__btn{flex:none;width:38px;height:38px;display:grid;place-items:center;border:1px solid var(--line);border-radius:50%;background:#fff;color:#4B5873;cursor:pointer;padding:0;box-shadow:0 4px 10px -6px rgba(31,45,110,.25);transition:background .15s,transform .15s}
.fw-chat__btn svg{width:18px;height:18px}.fw-chat__btn:hover{background:#F1F4FC;transform:translateY(-1px)}

/* body */
.fw-chat__body{flex:1;overflow:auto;padding:14px 20px 8px;scroll-behavior:smooth}
.fw-chat__welcome h3{margin:14px 0 6px;font:800 1.85rem/1.1 var(--fw-font-h,Inter,sans-serif);letter-spacing:-.025em;color:var(--ink)}
.fw-chat__welcome p{margin:0 0 20px;color:var(--mut);font-size:.93rem;line-height:1.5}
.fw-chat__tiles{display:grid;grid-template-columns:1fr 1fr;gap:12px}
.fw-chat__tile{position:relative;display:flex;flex-direction:column;align-items:flex-start;gap:14px;padding:14px 14px 15px;min-height:128px;border:1px solid #EEF0F7;border-radius:20px;background:#fff;color:var(--ink);text-align:left;cursor:pointer;font:inherit;box-shadow:0 10px 24px -14px rgba(31,45,110,.28);transition:transform .15s,box-shadow .15s,border-color .15s}
.fw-chat__tile:hover,.fw-chat__tile:focus-visible{transform:translateY(-2px);border-color:#D9DEF0;box-shadow:0 16px 30px -14px rgba(31,45,110,.38);outline:0}
.fw-chat__tile strong{margin-top:auto;font:700 .93rem/1.28 Inter,sans-serif}
.fw-chat__tile em{position:absolute;top:16px;right:12px;color:#8A93A8;display:grid}.fw-chat__tile em svg{width:17px;height:17px}
.fw-chat__ti{width:42px;height:42px;border-radius:13px;display:grid;place-items:center}.fw-chat__ti svg{width:21px;height:21px}
.fw-chat__ti--blue{background:#E6EEFF;color:#3A6BFF}.fw-chat__ti--violet{background:#EEE9FF;color:#7A58F0}.fw-chat__ti--green{background:#DFF5EA;color:#1F9F67}.fw-chat__ti--orange{background:#FFEBDD;color:#F0782A}

/* conversation */
.fw-chat__row{display:flex;align-items:flex-end;gap:8px;margin:0 0 12px;animation:fw-cin .25s ease both}
.fw-chat__row--me{justify-content:flex-end}
.fw-chat__mini{flex:none;width:28px;height:28px;border-radius:50%;background:#fff;display:grid;place-items:center;box-shadow:0 3px 8px -3px rgba(31,45,110,.35)}
.fw-chat__mini img{width:18px;height:auto}.fw-chat__mini svg{width:14px;height:14px;color:var(--b)}
.fw-chat__m{max-width:82%;padding:11px 15px;font-size:.93rem;line-height:1.5;word-wrap:break-word}
.fw-chat__m--bot{background:#fff;color:var(--ink);border-radius:18px 18px 18px 6px;box-shadow:0 8px 20px -12px rgba(31,45,110,.35);border:1px solid #EEF0F7}
.fw-chat__m--me{background:linear-gradient(135deg,#1F3CFF,#0000F3);color:#fff;border-radius:18px 18px 6px 18px;box-shadow:0 10px 20px -10px rgba(0,0,243,.6)}
.fw-chat__m a{color:inherit;font-weight:700;text-decoration:underline;text-underline-offset:2px;overflow-wrap:anywhere}
.fw-chat__typing{display:flex;gap:5px;padding:14px 16px}
.fw-chat__typing i{width:7px;height:7px;border-radius:50%;background:#9AA6C0;animation:fw-cdot 1.1s infinite}.fw-chat__typing i:nth-child(2){animation-delay:.15s}.fw-chat__typing i:nth-child(3){animation-delay:.3s}
@keyframes fw-cdot{0%,60%,100%{transform:none;opacity:.5}30%{transform:translateY(-4px);opacity:1}}
.fw-chat__chips{display:flex;gap:8px;overflow-x:auto;padding:4px 20px 10px;scrollbar-width:none}.fw-chat__chips::-webkit-scrollbar{display:none}
.fw-chat__chip{flex:none;padding:8px 14px;border:1px solid var(--line);border-radius:99px;background:#fff;color:var(--ink);font:600 .8rem Inter,sans-serif;cursor:pointer;white-space:nowrap}
.fw-chat__chip:hover{background:#F1F4FC}

/* input */
.fw-chat__form{display:flex;align-items:center;gap:8px;margin:6px 16px 0;padding:8px 8px 8px 10px;background:#F2F4FA;border:1px solid #E9ECF5;border-radius:26px}
.fw-chat__spark{flex:none;width:34px;height:34px;display:grid;place-items:center;border-radius:11px;background:#fff;color:#5B6B90;box-shadow:0 3px 8px -4px rgba(31,45,110,.3);position:relative;margin-right:4px}
.fw-chat__spark svg{width:18px;height:18px}.fw-chat__spark::after{content:"";position:absolute;right:-8px;top:7px;bottom:7px;width:1px;background:#DDE2EE}
.fw-chat__form input{flex:1;min-width:0;border:0;background:transparent;font:500 .95rem Inter,sans-serif;color:var(--ink);padding:10px 4px 10px 8px;outline:0}
.fw-chat__form input::placeholder{color:#8D97AE}
.fw-chat__form:focus-within{background:#fff;border-color:#B9C4FF;box-shadow:0 0 0 4px rgba(61,107,255,.14)}
.fw-chat__send{flex:none;width:46px;height:46px;display:grid;place-items:center;border:0;border-radius:50%;cursor:pointer;color:#fff;background:linear-gradient(135deg,#3D6BFF,#0000F3);box-shadow:0 10px 20px -8px rgba(0,0,243,.65);transition:transform .15s}
.fw-chat__send svg{width:20px;height:20px}.fw-chat__send:hover{transform:scale(1.06)}.fw-chat__send:disabled{opacity:.55;transform:none;cursor:default}
.fw-chat__note{display:flex;align-items:center;justify-content:center;gap:6px;margin:0;padding:10px 20px 16px;color:#8A93A8;font-size:.72rem;line-height:1.35;text-align:center}
.fw-chat__note svg{flex:none;width:14px;height:14px}.fw-chat__note a{color:inherit;text-decoration:underline}

.fw-chat-fab:focus-visible,.fw-chat button:focus-visible,.fw-chat a:focus-visible{outline:3px solid var(--sky);outline-offset:2px}
@media(max-width:760px){.fw-chat-fab{bottom:88px;right:14px}.fw-chat-fab.is-left{left:14px;right:auto}.fw-chat-teaser{bottom:98px;right:84px}.fw-chat,.fw-chat.is-left{right:0;left:0;bottom:0;width:auto;height:min(88dvh,700px);border-radius:28px 28px 0 0}.admin-bar .fw-chat{height:min(80dvh,660px)}.fw-chat__welcome h3{font-size:1.6rem}}
@media(prefers-reduced-motion:reduce){.fw-chat,.fw-chat-teaser,.fw-chat__row,.fw-chat__typing i{animation:none!important}.fw-chat-fab,.fw-chat__tile,.fw-chat__send{transition:none}}
.fw-chat__chips[hidden]{display:none}
.fw .fw-chat__form input:focus,.fw .fw-chat__form input:focus-visible,.fw-chat__form input:focus,.fw-chat__form input:focus-visible{outline:0!important;box-shadow:none!important;border:0}

/* smaller, lighter tiles */
.fw-chat__tiles{gap:10px}
.fw-chat__tile{gap:10px;padding:11px 12px 12px;min-height:0;border-radius:16px;box-shadow:0 8px 18px -14px rgba(31,45,110,.3)}
.fw-chat__tile strong{font:600 .84rem/1.25 Inter,sans-serif;margin-top:2px}
.fw-chat__tile em{top:12px;right:10px}.fw-chat__tile em svg{width:15px;height:15px}
.fw-chat__ti{width:34px;height:34px;border-radius:11px}.fw-chat__ti svg{width:18px;height:18px}
.fw-chat__welcome h3{font-size:1.6rem;margin-top:10px}.fw-chat__welcome p{font-size:.88rem;margin-bottom:16px}

/* tiles as a compact list */
.fw-chat__tiles{grid-template-columns:1fr;gap:8px}
.fw-chat__tile{flex-direction:row;align-items:center;gap:12px;padding:9px 12px;min-height:0;border-radius:14px}
.fw-chat__tile strong{margin:0;flex:1;font:600 .86rem/1.25 Inter,sans-serif}
.fw-chat__tile em{position:static;order:3;margin:0}
.fw-chat__ti{width:32px;height:32px;border-radius:10px}.fw-chat__ti svg{width:17px;height:17px}
.fw-chat__welcome p{margin-bottom:14px}
