#hwai-widget{position:fixed;right:18px;bottom:90px;z-index:99990;font:15px/1.45 system-ui,sans-serif;color:#102449}#hwai-widget *{box-sizing:border-box}#hwai-widget [hidden]{display:none!important}#hwai-widget button,#hwai-widget a{cursor:pointer;font:inherit}#hwai-open{border:0;background:#ef750d;color:#fff;border-radius:30px;padding:12px 20px;box-shadow:0 5px 18px #0003;font-weight:700!important}#hwai-panel{position:absolute;bottom:60px;right:0;width:min(390px,calc(100vw - 28px));max-height:calc(100dvh - 170px);display:flex;flex-direction:column;background:#fff;border-radius:16px;overflow:auto;box-shadow:0 8px 40px #0003;border:1px solid #dae2ed}#hwai-panel header{display:flex;align-items:center;justify-content:space-between;background:#102449;color:#fff;padding:14px 16px}#hwai-panel header small{display:block;color:#d7e2ef}#hwai-close{background:transparent;color:#fff;border:0;font-size:25px!important}#hwai-log{min-height:100px;height:230px;overflow:auto;padding:12px;background:#f3f6fa;flex-shrink:1}.hwai-bubble{white-space:pre-wrap;overflow-wrap:anywhere;max-width:90%;padding:10px 12px;border-radius:12px;margin-bottom:9px;background:#fff}.hwai-bubble.user{margin-left:auto;background:#103f77;color:white}.hwai-quick,.hwai-tools,#hwai-panel nav{display:flex;gap:6px;flex-wrap:wrap;padding:8px 12px}.hwai-quick button,.hwai-tools button,#hwai-panel nav a{border:1px solid #ccd9e7;border-radius:7px;background:white;color:#103f77;padding:6px 8px;text-decoration:none;font-size:12px!important}#hwai-form{padding:0 12px}.hwai-consent{display:block;font-size:11px;line-height:1.4;margin:8px 0}.hwai-compose{display:flex;gap:6px}.hwai-compose input{min-width:0;flex:1;border:1px solid #cbd5e1;border-radius:8px;padding:10px;font:inherit}.hwai-compose button{background:#ef750d;color:white;border:0;border-radius:8px;padding:8px 15px}.hwai-tools{padding:8px 0}#hwai-status{display:block;color:#9a4500;font-size:12px}.hwai-note{padding:0 12px 12px;font-size:11px;color:#53647b}#hwai-panel nav{border-top:1px solid #e6eaf0}@media(max-width:480px){#hwai-widget{right:12px;bottom:74px}#hwai-panel{max-height:calc(100dvh - 145px)}#hwai-log{height:180px}}

/* v1.0.1: dedicated AI launcher above contact buttons; independent chat window */
#hwai-widget{right:22px;bottom:var(--hwai-bottom,200px);z-index:99990}
#hwai-open{display:flex;align-items:center;gap:12px;text-align:left;min-height:70px;padding:12px 19px;border-radius:18px;background:#103f77;border:2px solid #ef750d;box-shadow:0 8px 26px #10244945;color:white}
#hwai-open:hover,#hwai-open:focus-visible{background:#102449;outline:2px solid #ef750d;outline-offset:3px}
.hwai-launch-icon{display:grid;place-items:center;width:38px;height:38px;border-radius:50%;background:#ef750d;color:white;font-size:24px;flex:none}
.hwai-launch-text{display:grid;gap:2px}.hwai-launch-text strong{font-size:16px;line-height:1.2;color:white}.hwai-launch-text small{font-size:12px;color:#e0ecff;font-weight:500}
#hwai-panel{position:fixed;right:22px;bottom:24px;width:min(470px,calc(100vw - 44px));height:min(710px,calc(100vh - 48px));height:min(710px,calc(100dvh - 48px));max-height:none;overflow:auto;z-index:2}
#hwai-panel header,#hwai-form,#hwai-panel nav,.hwai-quick,.hwai-note{flex-shrink:0}#hwai-log{flex:1 1 auto;height:auto;min-height:100px;overflow-y:auto}.hwai-compose input{min-height:48px;font-size:16px}.hwai-compose button{min-height:48px}
@media(max-width:480px){#hwai-widget{right:10px;bottom:var(--hwai-bottom,180px)}#hwai-open{min-height:58px;padding:9px 12px;gap:8px;border-radius:14px}.hwai-launch-icon{width:32px;height:32px;font-size:20px}.hwai-launch-text strong{font-size:14px}.hwai-launch-text small{font-size:11px}#hwai-panel{right:8px;bottom:max(8px,env(safe-area-inset-bottom));width:calc(100vw - 16px);height:calc(100dvh - 24px);max-height:calc(100vh - 16px)}}

/* v1.0.2: separate mobile launcher; visual viewport-aware conversation */
#hwai-widget.hwai-active #hwai-open{visibility:hidden;pointer-events:none}
#hwai-panel{isolation:isolate}
#hwai-close{min-width:44px;min-height:44px;line-height:1}
@media(max-width:767px){
 #hwai-widget{left:max(10px,env(safe-area-inset-left));right:auto;bottom:max(18px,calc(env(safe-area-inset-bottom) + 12px));max-width:calc(100vw - 145px)}
 #hwai-open{min-height:54px;max-width:100%;padding:8px 12px;gap:8px;border-radius:16px}
 .hwai-launch-icon{width:32px;height:32px;font-size:20px}
 .hwai-launch-text strong{font-size:13px;white-space:nowrap}
 .hwai-launch-text small{font-size:10px;line-height:1.2}
 #hwai-panel{position:fixed;left:calc(var(--hwai-vleft,0px) + 4px);right:auto;top:calc(var(--hwai-vtop,0px) + 4px);bottom:auto;width:calc(var(--hwai-vw,100vw) - 8px);height:calc(var(--hwai-vh,100dvh) - 8px);max-height:none;border-radius:14px;overflow:auto;padding-bottom:env(safe-area-inset-bottom,0px)}
 #hwai-panel header{padding:8px 12px;padding-top:max(8px,env(safe-area-inset-top))}
 #hwai-log{min-height:90px;flex:1 1 0;overscroll-behavior:contain}
 #hwai-panel .hwai-quick{padding:6px 10px;flex-wrap:nowrap;overflow-x:auto}
 #hwai-panel .hwai-quick button{white-space:nowrap;min-height:36px}
 #hwai-form{padding:0 10px}
 .hwai-tools button,.hwai-tools select,#hwai-panel nav a{min-height:40px}
 .hwai-compose input{font-size:16px!important}
 #hwai-panel nav{padding:6px 10px}
 .hwai-note{padding:0 10px 6px}
}
@media(max-width:767px) and (max-height:480px){#hwai-panel .hwai-quick{display:none}#hwai-panel header{padding:4px 10px}#hwai-panel nav{padding:4px 10px}}
@media(max-width:350px){#hwai-open{padding:8px;gap:5px}.hwai-launch-icon{width:26px;height:26px}.hwai-launch-text strong{font-size:11px}.hwai-launch-text small{font-size:9px}}

/* v1.0.3: voice listening state and compact disclosure */
.hwai-disclosure{display:block;font-size:11px;line-height:1.35;color:#53647b;margin:5px 0 0;overflow-wrap:anywhere}
#hwai-listening{display:flex;flex-direction:column;align-items:center;gap:7px;padding:12px;margin:0 0 8px;border:1px solid #d6e2ef;border-radius:14px;background:#f1f6fc;color:#103f77;text-align:center}
.hwai-mic-orb{display:grid;place-items:center;width:64px;height:64px;border-radius:50%;background:#ef750d;color:white;box-shadow:0 0 0 8px #ef750d22; margin:5px}
.hwai-wave{display:flex;align-items:center;gap:4px;height:24px}.hwai-wave i{display:block;background:#103f77;width:4px;height:8px;border-radius:4px}.is-listening .hwai-wave i{animation:hwai-wave .85s ease-in-out infinite alternate}.hwai-wave i:nth-child(2n){animation-delay:.15s}.hwai-wave i:nth-child(3n){animation-delay:.3s}.hwai-wave i:nth-child(4n){animation-delay:.45s}@keyframes hwai-wave{from{transform:scaleY(.7)}to{transform:scaleY(2.7)}}
#hwai-stop-mic{border:1px solid #c65a00;border-radius:20px;padding:6px 18px;background:#fff;color:#a44300;min-height:36px}#hwai-mic[aria-pressed=true]{background:#ef750d;color:#fff;border-color:#ef750d}
@media(max-width:767px){#hwai-listening{padding:8px;gap:4px}.hwai-mic-orb{width:48px;height:48px}.hwai-disclosure{font-size:10px}}@media(max-height:480px){#hwai-listening{flex-direction:row;flex-wrap:wrap;justify-content:center}.hwai-mic-orb{width:38px;height:38px}.hwai-mic-orb svg{width:23px;height:23px}.hwai-wave{display:none}#hwai-listening small{display:none}}@media(prefers-reduced-motion:reduce){.is-listening .hwai-wave i{animation:none}}
/* v1.1.1: real portrait, mobile-safe and visible speech state */
.hwai-avatar{object-fit:cover;object-position:center;border:2px solid #fff;flex:none;border-radius:50%;background:#e9eff5}.hwai-launch-icon.hwai-avatar{width:56px;height:56px}.hwai-header-avatar{width:48px;height:48px;margin-right:10px}.hwai-header-text{flex:1}.hwai-message-avatar{width:32px;height:32px;object-fit:cover;border-radius:50%;float:left;margin:0 8px 4px 0}.hwai-bubble.assistant{display:flow-root}.hwai-speaking .hwai-header-avatar{animation:hwai-speak 1s ease-in-out infinite alternate}@keyframes hwai-speak{from{box-shadow:0 0 0 2px #ef750d}to{box-shadow:0 0 0 8px #ef750d55}}@media(max-width:767px){.hwai-launch-icon.hwai-avatar{width:42px;height:42px}.hwai-header-avatar{width:40px;height:40px}}@media(max-width:350px){.hwai-launch-icon.hwai-avatar{width:32px;height:32px}}@media(prefers-reduced-motion:reduce){.hwai-speaking .hwai-header-avatar{animation:none}}
#hwai-source{display:block;color:#245b78;font-size:12px;font-weight:600;line-height:1.4}#hwai-source:empty{display:none}#hwai-replay{align-self:flex-start;border:1px solid #c6d6e6;background:#fff;color:#103f77;border-radius:8px;padding:7px 10px;font-size:13px;cursor:pointer}#hwai-replay[hidden]{display:none!important}
