.vrbot{position:fixed;bottom:22px;right:20px;z-index:9900;font-family:inherit;max-width:calc(100vw - 20px)}
.vrbot-toggle{background:#123f35;color:#fff;border:1px solid #123f35;border-radius:28px;box-shadow:0 8px 28px #123f3533;padding:13px 19px;font-weight:700;cursor:pointer}
.vrbot-toggle:focus-visible,.vrbot button:focus-visible,.vrbot a:focus-visible{outline:3px solid #bda66e;outline-offset:2px}
.vrbot-panel{position:absolute;right:0;bottom:62px;width:min(390px,calc(100vw - 24px));height:min(530px,75dvh);display:flex;flex-direction:column;background:#fffdf9;border:1px solid #d9e3dc;box-shadow:0 15px 45px #14392c30;border-radius:19px;overflow:hidden}
.vrbot-panel[hidden]{display:none!important}
.vrbot-head{display:flex;align-items:center;justify-content:space-between;padding:15px 16px;background:#123f35;color:white}
.vrbot-head strong{font-size:1rem}.vrbot-head small{display:block;font-size:.76rem;opacity:.85}
.vrbot-close{font-size:1.4rem;background:transparent;color:#fff;border:0;cursor:pointer}
.vrbot-feed{padding:15px;overflow:auto;flex:1;scroll-behavior:smooth;display:flex;flex-direction:column;gap:10px}
.vrbot-line{font-size:.9rem;line-height:1.52;padding:10px 12px;border-radius:13px;margin:0;white-space:pre-line;max-width:95%;align-self:flex-start;background:#eef3ef;color:#16392e}
.vrbot-line.vrbot-user{align-self:flex-end;background:#dcece6}.vrbot-error{color:#9b3a23;background:#fff1eb}
.vrbot-links{display:flex;gap:6px;flex-wrap:wrap}.vrbot-links a{color:#123f35;background:#fff;border:1px solid #c7dcd4;padding:7px 10px;border-radius:22px;font-size:.76rem;text-decoration:none}
.vrbot-quick{display:flex;gap:6px;flex-wrap:wrap;padding:0 12px 10px}.vrbot-quick button{background:#eef3ef;color:#123f35;border:1px solid #d6e5dc;border-radius:20px;padding:6px 10px;cursor:pointer;font-size:.75rem}
.vrbot-form{display:flex;gap:7px;padding:11px;border-top:1px solid #e1e7e2}
.vrbot-form input{flex:1;min-width:0;border:1px solid #cddbd2;border-radius:11px;padding:10px;font-size:.86rem}
.vrbot-form button{border:0;color:white;background:#123f35;border-radius:11px;padding:9px 12px;cursor:pointer}
.vrbot-form button:disabled{opacity:.5;cursor:wait}
.vrbot-notice{color:#657871;font-size:.69rem;padding:0 13px 12px;line-height:1.3}
@media(max-width:600px){.vrbot{right:10px;bottom:12px}.vrbot-toggle{padding:12px 15px}.vrbot-panel{bottom:55px;height:min(540px,77dvh)}}

/* V5.1.1 · mejora de lectura y acciones */
.vrbot-line.vrbot-rich{white-space:normal;width:fit-content;overflow-wrap:anywhere}
.vrbot-rich p{margin:0 0 9px;line-height:1.56}
.vrbot-rich p:last-child{margin-bottom:0}
.vrbot-rich ul{margin:7px 0 9px;padding-left:21px;list-style:disc}
.vrbot-rich li{padding:2px 0;line-height:1.55}
.vrbot-rich strong{font-weight:750}
.vrbot-rich code{background:#e3eae5;padding:1px 4px;border-radius:4px}
.vrbot-links.vrbot-recs{display:grid;grid-template-columns:1fr;gap:7px}
.vrbot-recs a{position:relative;display:flex;flex-direction:column;align-items:flex-start;gap:2px;border-radius:11px;padding:9px 36px 9px 11px;background:#f7fbf8;font-size:.82rem;line-height:1.35}
.vrbot-recs a:hover,.vrbot-actions a:hover{background:#e8f4ec;border-color:#97c7ae}
.vrbot-link-category{display:block;font-size:.69rem;color:#678275;text-transform:uppercase;letter-spacing:.06em;font-weight:700}
.vrbot-arrow{position:absolute;right:12px;top:calc(50% - 11px);font-size:1.15rem}
.vrbot-actions{gap:6px}.vrbot-actions a{background:#fff;font-weight:650}
.vrbot-quick{flex-shrink:0}.vrbot-notice{flex-shrink:0}
.vrbot-feed{overscroll-behavior:contain}
@media(max-width:600px){
  .vrbot-panel{right:0;bottom:58px;width:min(420px,calc(100vw - 20px));height:min(620px,78dvh);max-height:calc(100dvh - 88px)}
  .vrbot-feed{padding:12px;gap:9px}
  .vrbot-form{padding:9px}.vrbot-notice{padding:0 11px 9px}
  .vrbot-quick button{font-size:.72rem;padding:7px 9px}
}

/* V5.1.2 · Acciones del encabezado y continuidad de chat entre páginas */
.vrbot-head-actions{display:flex;align-items:center;gap:8px;flex-shrink:0}
.vrbot-clear{border:1px solid rgba(255,255,255,.5);background:transparent;color:#fff;font:inherit;font-size:.73rem;line-height:1.2;border-radius:9px;padding:7px 9px;cursor:pointer}
.vrbot-clear:hover{background:rgba(255,255,255,.12)}
.vrbot-clear:disabled{opacity:.55;cursor:wait}
@media(max-width:370px){.vrbot-head{padding:12px 10px}.vrbot-clear{font-size:.68rem;padding:6px 7px}.vrbot-head-actions{gap:5px}}


/* V5.4 · Floating assistant compact only when closed on narrow screens. */
@media (max-width: 680px){
  .vrbot{right:12px;bottom:calc(12px + env(safe-area-inset-bottom,0px));max-width:calc(100vw - 24px)}
  .vrbot-toggle{width:52px;height:52px;min-height:52px;min-width:52px;display:grid;place-items:center;border-radius:50%;padding:0;font-size:0;line-height:1;white-space:nowrap;overflow:hidden}
  .vrbot-toggle::before{content:"✦";font-size:25px;line-height:1;color:#fff}
  .vrbot-panel{right:0;bottom:62px;width:min(390px,calc(100vw - 24px));max-height:calc(100dvh - 104px)}
}

/* Planificador: dejar libre la barra fija de acciones cuando hay resultados.
   El resto de paginas mantiene la posicion original del asistente. */
@media (min-width: 721px){
  body:has([data-trip-dock]) .vrbot{bottom:166px}
  body:has([data-trip-dock]) .vrbot-panel{
    height:min(530px,calc(100dvh - 270px));
    max-height:calc(100dvh - 270px);
  }
}
@media (max-width: 720px){
  body:has([data-trip-dock]) .vrbot{
    bottom:calc(116px + env(safe-area-inset-bottom,0px));
  }
  body:has([data-trip-dock]) .vrbot-panel{
    height:min(540px,calc(100dvh - 230px));
    max-height:calc(100dvh - 230px);
  }
}
