.medsi-bot-dock{position:fixed;z-index:1100;left:max(8px,env(safe-area-inset-left));bottom:calc(14px + env(safe-area-inset-bottom));width:164px;display:grid;justify-items:center;pointer-events:none;animation:medsi-bot-arrive .55s cubic-bezier(.2,.75,.3,1) both}
.medsi-bot-dock[hidden],.medsi-bot-launcher[hidden],.medsi-bot-hint[hidden]{display:none!important}
.medsi-bot-launcher{position:relative;display:grid;place-items:center;width:144px;height:144px;padding:0;border:0;border-radius:50%;background:transparent;cursor:pointer;pointer-events:auto}
.medsi-bot-scale{position:absolute;width:238px;height:238px;transform:scale(.605042);pointer-events:none}
.medsi-bot-scale .medsi-character{width:238px;height:238px;--eye-width:17px;--eye-height:43px;--eye-gap:35px}
.medsi-bot-launcher:active .medsi-bot-scale{scale:.95}
.medsi-bot-launcher:focus-visible{outline:2px solid #20bec9;outline-offset:-5px}
.medsi-bot-hint{position:absolute;z-index:1;left:50%;bottom:calc(100% + 2px);width:max-content;max-width:164px;display:block;padding:9px 12px;border:1px solid #dfedeb;border-radius:15px;background:#fff;color:#356d70;font:500 13px/1.3 system-ui,-apple-system,sans-serif;box-shadow:0 6px 20px #115c6014;opacity:0;transform:translate(-50%,7px);pointer-events:none;transition:opacity .25s ease,transform .25s ease}
.medsi-bot-hint.is-visible{opacity:1;transform:translate(-50%,0);pointer-events:auto}
.medsi-bot-overlay{position:absolute;z-index:20000;top:0;left:0;display:grid;grid-template-rows:minmax(0,1fr);place-items:center;padding:clamp(10px,3vw,28px);padding-bottom:max(10px,env(safe-area-inset-bottom));isolation:isolate;overflow:visible}
.medsi-bot-backdrop{position:fixed;z-index:-1;inset:0;width:auto;height:auto;padding:0;border:0;background:#bfd5d6;cursor:default}
.medsi-bot-frame{display:block;width:min(100%,570px);height:min(850px,calc(100dvh - 40px));min-height:0;border:1px solid rgba(255,255,255,.85);border-radius:28px;background:#fff;box-shadow:0 25px 80px rgba(17,72,79,.27);}
@media(max-width:600px){.medsi-bot-overlay{padding:22px 20px;padding-top:max(22px,env(safe-area-inset-top));padding-bottom:max(22px,env(safe-area-inset-bottom))}.medsi-bot-frame{width:100%;height:100%;max-height:850px;border:1px solid rgba(255,255,255,.85);border-radius:28px}}
@media(prefers-reduced-motion:reduce){.medsi-bot-frame,.medsi-bot-backdrop{animation:none}.medsi-bot-hint{transition:none}}

@keyframes medsi-bot-arrive{from{opacity:0;transform:translateY(16px) scale(.92)}to{opacity:1;transform:none}}
@media(prefers-reduced-motion:reduce){.medsi-bot-dock{animation:none}}

.medsi-bot-frame[hidden]{display:none!important}

/* The menu mascot keeps the same body and eye proportions at logo size. */
.medsi-assistant-logo{position:relative;flex:none;width:112px;height:86px}
.medsi-bot-dock--brand{position:absolute;z-index:2;inset:-9px 0 auto;width:112px;animation:none}
.medsi-bot-dock--brand .medsi-bot-launcher{width:112px;height:112px}
.medsi-bot-dock--brand .medsi-bot-scale{transform:scale(.470588)}
.medsi-bot-dock--brand .medsi-bot-hint{left:calc(100% - 4px);top:50%;bottom:auto;width:max-content;max-width:min(104px,calc(50vw - 72px));padding:9px 12px;border-radius:24px;font-size:12px;transform:translateY(calc(-50% + 5px));text-align:center}
.medsi-bot-dock--brand .medsi-bot-hint.is-visible{transform:translateY(-50%)}
.medsi-bot-dock--brand .medsi-bot-hint:before{content:'';position:absolute;left:-5px;top:calc(50% - 5px);width:8px;height:8px;background:#fff;border-left:1px solid #dfedeb;border-bottom:1px solid #dfedeb;transform:rotate(45deg)}

.medsi-bot-dock--brand .medsi-character .medsi-character-body{filter:none}
.medsi-bot-dock--brand .medsi-character-glow{display:none}

.medsi-bot-overlay.is-preparing{visibility:hidden;pointer-events:none}
.medsi-bot-overlay.is-open .medsi-bot-curtain{opacity:0}

@media(prefers-reduced-motion:reduce){.medsi-bot-overlay.is-open .medsi-bot-frame,.medsi-bot-overlay.is-open .medsi-bot-backdrop{animation:none}}

.medsi-bot-overlay.is-open{transition:none}
.medsi-bot-overlay.is-closing{pointer-events:none}
.medsi-bot-overlay.is-closing .medsi-bot-curtain{opacity:1;transition-duration:.18s}
@media(prefers-reduced-motion:reduce){.medsi-bot-overlay.is-open{transition:none}.medsi-bot-overlay.is-closing .medsi-bot-frame,.medsi-bot-overlay.is-closing .medsi-bot-backdrop{animation:none}}

/* Also cover Safari's exposed page canvas while it pans for the keyboard. */
html.medsi-bot-active,html.medsi-bot-active body{background:#bfd5d6}

html.medsi-bot-active{overflow-anchor:none}

@media(min-width:821px){
  .medsi-assistant-logo{width:152px;height:114px}
  .medsi-bot-dock--brand{width:152px}
  .medsi-bot-dock--brand .medsi-bot-launcher{width:152px;height:152px}
  .medsi-bot-dock--brand .medsi-bot-scale{transform:scale(.638655)}
}

@media(prefers-reduced-motion:reduce){.medsi-bot-frame{transition:none}}

/* The chat itself never scales, fades, or moves between DOM containers. */
.medsi-bot-overlay[hidden]{display:none!important}
.medsi-bot-curtain{position:absolute;z-index:2;inset:0;background:#bfd5d6;opacity:1;pointer-events:none;transition:opacity .28s ease-out}
@media(prefers-reduced-motion:reduce){.medsi-bot-curtain{transition:none}}
