/* Bot OPCO · assistente virtual */
.ob{--ob-red:#b3141c;--ob-red-d:#8e1016;--ob-red-50:#fbefef;--ob-fg:#141518;--ob-fg2:#3e434a;--ob-muted:#6a7078;--ob-line:rgba(20,21,24,.1);--ob-bg:#fff;--ob-bg2:#f5f5f3;--ob-ease:cubic-bezier(.22,.61,.16,1);
  font-family:"Inter","Helvetica Neue",Helvetica,Arial,sans-serif;font-size:15px;line-height:1.5;color:var(--ob-fg);-webkit-font-smoothing:antialiased}
.ob *,.ob *::before,.ob *::after{box-sizing:border-box}
.ob button{font:inherit;color:inherit}

/* botão flutuante */
.ob-launch{position:fixed;right:max(20px,env(safe-area-inset-right));bottom:max(20px,env(safe-area-inset-bottom));z-index:44;width:62px;height:62px;border-radius:50%;border:0;cursor:pointer;
  background:linear-gradient(150deg,#d0261f,var(--ob-red) 45%,var(--ob-red-d));box-shadow:0 14px 30px -10px rgba(142,16,22,.6),0 4px 10px -4px rgba(0,0,0,.25);
  display:grid;place-items:center;transition:transform .35s var(--ob-ease),box-shadow .35s var(--ob-ease),opacity .25s}
.ob-launch:hover{transform:translateY(-3px) scale(1.04);box-shadow:0 18px 36px -12px rgba(142,16,22,.7),0 6px 12px -4px rgba(0,0,0,.25)}
.ob-launch:focus-visible{outline:3px solid #fff;box-shadow:0 0 0 6px var(--ob-red)}
.ob-launch img{width:34px;height:34px;filter:brightness(0) invert(1)}
.ob-launch .ob-dot{position:absolute;top:3px;right:3px;width:14px;height:14px;border-radius:50%;background:#fff;border:3px solid var(--ob-red)}
.ob-launch::after{content:"";position:absolute;inset:0;border-radius:50%;border:2px solid var(--ob-red);opacity:0;animation:ob-ring 2.6s var(--ob-ease) 1.2s 2}
@keyframes ob-ring{0%{transform:scale(1);opacity:.55}100%{transform:scale(1.55);opacity:0}}
.ob.is-open .ob-launch{opacity:0;pointer-events:none;transform:scale(.8)}

/* balão de convite */
.ob-hint{position:fixed;right:max(92px,calc(env(safe-area-inset-right) + 92px));bottom:max(30px,calc(env(safe-area-inset-bottom) + 10px));z-index:44;max-width:240px;
  background:#fff;border-radius:16px 16px 4px 16px;padding:12px 38px 12px 16px;box-shadow:0 18px 40px -16px rgba(20,21,24,.35),0 0 0 1px var(--ob-line);
  font-size:14px;color:var(--ob-fg2);opacity:0;transform:translateY(8px) scale(.98);transition:opacity .45s var(--ob-ease),transform .45s var(--ob-ease);pointer-events:none}
.ob-hint.is-on{opacity:1;transform:none;pointer-events:auto;cursor:pointer}
.ob-hint b{display:block;color:var(--ob-fg);font-weight:600;margin-bottom:2px}
.ob-hint__x{position:absolute;top:6px;right:6px;width:26px;height:26px;border:0;background:none;border-radius:50%;cursor:pointer;color:var(--ob-muted);display:grid;place-items:center}
.ob-hint__x:hover{background:var(--ob-bg2)}
.ob-hint__x svg{width:12px;height:12px}

/* painel */
.ob-panel{position:fixed;right:max(20px,env(safe-area-inset-right));bottom:max(20px,env(safe-area-inset-bottom));z-index:60;width:396px;height:min(640px,calc(100vh - 110px));height:min(640px,calc(100dvh - 110px));
  background:var(--ob-bg);border-radius:22px;overflow:hidden;display:flex;flex-direction:column;
  box-shadow:0 40px 90px -30px rgba(40,8,6,.45),0 10px 30px -12px rgba(0,0,0,.25),0 0 0 1px var(--ob-line);
  transform-origin:100% 100%;opacity:0;transform:translateY(16px) scale(.96);visibility:hidden;transition:opacity .35s var(--ob-ease),transform .45s var(--ob-ease),visibility 0s .45s}
.ob.is-open .ob-panel{opacity:1;transform:none;visibility:visible;transition:opacity .35s var(--ob-ease),transform .45s var(--ob-ease),visibility 0s}

.ob-head{position:relative;flex:none;display:flex;align-items:center;gap:12px;padding:16px 14px 16px 18px;color:#fff;
  background:radial-gradient(120% 140% at 0% 0%,#d32a22 0%,var(--ob-red) 45%,var(--ob-red-d) 100%)}
.ob-head::after{content:"";position:absolute;right:-40px;top:-60px;width:180px;height:180px;background:url("simbolo.svg") center/contain no-repeat;filter:brightness(0) invert(1);opacity:.08;pointer-events:none}
.ob-ava{flex:none;width:42px;height:42px;border-radius:50%;background:#fff;display:grid;place-items:center;box-shadow:0 0 0 3px rgba(255,255,255,.25)}
.ob-ava img{width:28px;height:28px}
.ob-ttl{flex:1;min-width:0}
.ob-ttl b{display:block;font-size:16px;font-weight:600;letter-spacing:-.01em}
.ob-ttl span{display:block;font-size:12.5px;opacity:.85}
.ob-ibtn{flex:none;width:36px;height:36px;border-radius:50%;border:0;background:rgba(255,255,255,.12);color:#fff;cursor:pointer;display:grid;place-items:center;transition:background .2s;position:relative;z-index:1}
.ob-ibtn:hover{background:rgba(255,255,255,.24)}
.ob-ibtn:focus-visible{outline:2px solid #fff;outline-offset:2px}
.ob-ibtn svg{width:16px;height:16px}

.ob-body{flex:1;min-height:0;overflow-y:auto;overscroll-behavior:contain;padding:18px 16px 8px;background:linear-gradient(#fff,#fbfbfa)}
.ob-body::-webkit-scrollbar{width:8px}.ob-body::-webkit-scrollbar-thumb{background:rgba(20,21,24,.12);border-radius:8px}
.ob-msg{display:flex;margin:0 0 12px;animation:ob-in .35s var(--ob-ease)}
@keyframes ob-in{from{opacity:0;transform:translateY(6px)}to{opacity:1;transform:none}}
.ob-msg--bot{justify-content:flex-start}
.ob-msg--me{justify-content:flex-end}
.ob-bub{max-width:86%;padding:11px 14px;border-radius:18px;word-wrap:break-word;overflow-wrap:anywhere}
.ob-msg--bot .ob-bub{background:var(--ob-bg2);color:var(--ob-fg);border-top-left-radius:6px}
.ob-msg--me .ob-bub{background:var(--ob-red);color:#fff;border-top-right-radius:6px}
.ob-bub p{margin:0}.ob-bub p+p,.ob-bub p+ul,.ob-bub ul+p{margin-top:8px}
.ob-bub ul{margin:6px 0 0;padding-left:18px}.ob-bub li{margin:3px 0}
.ob-bub a{color:var(--ob-red);font-weight:600;text-decoration:underline;text-underline-offset:2px;text-decoration-thickness:1px}
.ob-msg--me .ob-bub a{color:#fff}
.ob-bub strong{font-weight:600}
.ob-msg--err .ob-bub{background:var(--ob-red-50);color:var(--ob-red-d)}

.ob-typing{display:inline-flex;gap:4px;padding:14px 16px}
.ob-typing i{width:7px;height:7px;border-radius:50%;background:#9aa0a6;animation:ob-b 1.2s infinite ease-in-out}
.ob-typing i:nth-child(2){animation-delay:.15s}.ob-typing i:nth-child(3){animation-delay:.3s}
@keyframes ob-b{0%,60%,100%{transform:translateY(0);opacity:.5}30%{transform:translateY(-5px);opacity:1}}

.ob-chips{display:flex;flex-wrap:wrap;gap:8px;margin:2px 0 14px}
.ob-chip{border:1px solid rgba(179,20,28,.28);background:#fff;color:var(--ob-red);border-radius:999px;padding:7px 13px;font-size:13.5px;font-weight:500;cursor:pointer;transition:background .2s,border-color .2s,color .2s;text-align:left}
.ob-chip:hover{background:var(--ob-red);border-color:var(--ob-red);color:#fff}
.ob-chip:focus-visible{outline:2px solid var(--ob-red);outline-offset:2px}

.ob-foot{flex:none;border-top:1px solid var(--ob-line);background:#fff;padding:10px 12px 8px}
.ob-form{display:flex;align-items:flex-end;gap:8px;background:var(--ob-bg2);border-radius:16px;padding:6px 6px 6px 14px;border:1px solid transparent;transition:border-color .2s,background .2s}
.ob-form:focus-within{border-color:rgba(179,20,28,.35);background:#fff}
.ob-in{flex:1;border:0;background:transparent;resize:none;font:inherit;font-size:15px;line-height:1.45;color:var(--ob-fg);padding:7px 0;max-height:120px;min-height:22px;outline:none}
.ob-in::placeholder{color:#8a9098}
.ob-send{flex:none;width:38px;height:38px;border-radius:12px;border:0;background:var(--ob-red);color:#fff;cursor:pointer;display:grid;place-items:center;transition:background .2s,opacity .2s,transform .2s}
.ob-send:hover{background:var(--ob-red-d)}
.ob-send:disabled{opacity:.35;cursor:default}
.ob-send:focus-visible{outline:2px solid var(--ob-red);outline-offset:2px}
.ob-send svg{width:17px;height:17px}
.ob-note{margin:7px 4px 0;font-size:11.5px;color:var(--ob-muted);line-height:1.4;text-align:center}
.ob-note a{color:inherit;text-decoration:underline}
.ob-hp{position:absolute!important;left:-9999px!important;width:1px;height:1px;opacity:0}
.ob-sr{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap}

@media (max-width:560px){
  .ob-panel{right:0;bottom:0;left:0;top:0;width:auto;height:auto;border-radius:0}
  .ob-head{padding-top:max(16px,env(safe-area-inset-top))}
  .ob-foot{padding-bottom:max(8px,env(safe-area-inset-bottom))}
  .ob-launch{width:56px;height:56px;right:16px;bottom:16px}
  .ob-launch img{width:30px;height:30px}
  .ob-hint{right:82px;bottom:22px;max-width:200px}
  .ob-in{font-size:16px}
}
@media (prefers-reduced-motion:reduce){
  .ob *,.ob *::after{animation:none!important;transition:none!important}
}
@media print{.ob{display:none!important}}
