/* Asistente de la web de BOGI con estética de conversación de mensajería (burbujas, hora y tildes). */
.bc-launch { position: fixed; right: 20px; bottom: 20px; z-index: 60; display: inline-flex; align-items: center; gap: 10px; border: 0; cursor: pointer; font: 600 15px/1 system-ui, sans-serif; color: #fff; background: var(--orange); padding: 0 20px 0 16px; height: 56px; border-radius: 999px; box-shadow: 0 12px 32px rgba(255, 64, 0, .4); transition: transform .15s, background .15s, opacity .15s; }
.bc-launch:hover { background: var(--orange-d); transform: translateY(-2px); }
.bc-launch svg { width: 24px; height: 24px; flex: none; }
.bc-launch[aria-expanded="true"] { opacity: 0; pointer-events: none; }

.bc-win { --wa-head: #0f6b5c; --wa-bg: #efeae2; --wa-out: #d9fdd3; --wa-in: #ffffff; --wa-time: #667781; --wa-tick: #53bdeb;
  position: fixed; right: 20px; bottom: 20px; z-index: 61; width: min(392px, calc(100vw - 24px)); height: min(620px, calc(100dvh - 40px)); display: flex; flex-direction: column; background: var(--wa-bg); color: #111b21; border-radius: 18px; overflow: hidden; box-shadow: 0 24px 70px rgba(0, 0, 0, .38); animation: bc-in .18s ease-out; }
@keyframes bc-in { from { opacity: 0; transform: translateY(12px) scale(.98); } to { opacity: 1; transform: none; } }

.bc-head { display: flex; align-items: center; gap: 12px; padding: 10px 8px 10px 14px; background: var(--wa-head); color: #fff; }
.bc-av { flex: none; width: 42px; height: 42px; border-radius: 50%; background: #fff; display: grid; place-items: center; overflow: hidden; }
.bc-av img { width: 28px; height: auto; }
.bc-head .t { flex: 1; min-width: 0; line-height: 1.25; }
.bc-head b { display: block; font-size: 16px; font-weight: 600; }
.bc-head small { font-size: 12.5px; opacity: .85; display: flex; align-items: center; gap: 6px; }
.bc-head small::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: #5fe08a; }
.bc-x { border: 0; background: transparent; color: #fff; width: 40px; height: 40px; border-radius: 50%; cursor: pointer; font-size: 24px; line-height: 1; }
.bc-x:hover { background: rgba(255, 255, 255, .16); }

.bc-log { flex: 1; overflow-y: auto; padding: 14px 12px; display: flex; flex-direction: column; gap: 4px; overscroll-behavior: contain;
  background-color: var(--wa-bg);
  background-image: radial-gradient(rgba(11, 20, 26, .045) 1.2px, transparent 1.3px), radial-gradient(rgba(11, 20, 26, .035) 1px, transparent 1.1px);
  background-size: 26px 26px, 38px 38px; background-position: 0 0, 13px 17px; }
.bc-day { align-self: center; margin: 2px 0 8px; padding: 4px 12px; border-radius: 8px; background: #fff; box-shadow: 0 1px 1px rgba(11, 20, 26, .12); font-size: 12px; color: var(--wa-time); }
.bc-sec { align-self: center; max-width: 92%; margin: 0 0 8px; padding: 6px 12px; border-radius: 8px; background: #fff6c5; box-shadow: 0 1px 1px rgba(11, 20, 26, .1); font-size: 12px; line-height: 1.35; color: #54656f; text-align: center; }

.bc-m { position: relative; max-width: 84%; padding: 7px 9px 6px 10px; border-radius: 9px; font-size: 15px; line-height: 1.36; box-shadow: 0 1px 1px rgba(11, 20, 26, .13); white-space: pre-wrap; overflow-wrap: anywhere; animation: bc-pop .16s ease-out; }
@keyframes bc-pop { from { opacity: 0; transform: translateY(6px) scale(.97); } to { opacity: 1; transform: none; } }
.bc-m a { color: #027eb5; text-decoration: underline; }
.bc-m .bc-txt { padding-right: 62px; }
.bc-m .bc-meta { position: absolute; right: 8px; bottom: 4px; display: inline-flex; align-items: center; gap: 3px; font-size: 11px; color: var(--wa-time); line-height: 1; }
.bc-m .bc-tick { width: 17px; height: 11px; color: var(--wa-time); }
.bc-m .bc-tick.read { color: var(--wa-tick); }
.bc-m.bot { align-self: flex-start; background: var(--wa-in); border-top-left-radius: 0; margin-top: 2px; }
.bc-m.bot.cont { border-top-left-radius: 9px; margin-top: 0; }
.bc-m.bot:not(.cont)::before { content: ""; position: absolute; left: -7px; top: 0; border: 7px solid transparent; border-top-color: var(--wa-in); border-right-color: var(--wa-in); }
.bc-m.me { align-self: flex-end; background: var(--wa-out); border-top-right-radius: 0; margin-top: 4px; }
.bc-m.me.cont { border-top-right-radius: 9px; margin-top: 0; }
.bc-m.me:not(.cont)::before { content: ""; position: absolute; right: -7px; top: 0; border: 7px solid transparent; border-top-color: var(--wa-out); border-left-color: var(--wa-out); }
.bc-m.err { align-self: flex-start; background: #fff4f0; color: #8a2500; border: 1px solid #ffc9b8; }
.bc-m.ok { align-self: center; max-width: 94%; background: #e1f3fb; color: #3b4a54; font-size: 13px; text-align: center; box-shadow: none; }
.bc-m.ok .bc-txt { padding-right: 0; }

.bc-typing { align-self: flex-start; display: inline-flex; gap: 4px; padding: 12px 14px; background: var(--wa-in); border-radius: 9px; border-top-left-radius: 0; box-shadow: 0 1px 1px rgba(11, 20, 26, .13); margin-top: 2px; }
.bc-typing i { width: 7px; height: 7px; border-radius: 50%; background: #8696a0; animation: bc-dot 1s infinite; }
.bc-typing i:nth-child(2) { animation-delay: .15s; }
.bc-typing i:nth-child(3) { animation-delay: .3s; }
@keyframes bc-dot { 0%, 60%, 100% { transform: none; opacity: .4; } 30% { transform: translateY(-4px); opacity: 1; } }

.bc-chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 6px 0 2px; align-self: flex-end; justify-content: flex-end; max-width: 94%; }
.bc-chip { border: 1px solid #c9d4da; color: #027eb5; background: #fff; border-radius: 999px; padding: 7px 13px; font: 600 14px/1.2 system-ui, sans-serif; cursor: pointer; box-shadow: 0 1px 1px rgba(11, 20, 26, .1); }
.bc-chip:hover { background: #027eb5; color: #fff; border-color: #027eb5; }

.bc-form { display: flex; gap: 8px; padding: 8px 10px; background: #f0f2f5; align-items: flex-end; }
.bc-in { flex: 1; resize: none; border: 0; border-radius: 22px; padding: 12px 16px; font: 16px/1.3 system-ui, sans-serif; max-height: 120px; min-height: 46px; background: #fff; color: #111b21; }
.bc-in:focus { outline: 2px solid var(--wa-head); outline-offset: 0; }
.bc-send { flex: none; width: 46px; height: 46px; border-radius: 50%; border: 0; background: var(--wa-head); color: #fff; cursor: pointer; display: grid; place-items: center; }
.bc-send:disabled { opacity: .5; cursor: default; }
.bc-send svg { width: 21px; height: 21px; }
.bc-note { margin: 0; padding: 0 14px 8px; background: #f0f2f5; font-size: 11.5px; line-height: 1.35; color: var(--wa-time); text-align: center; }

@media (max-width: 520px) {
  .bc-launch { right: 14px; bottom: 14px; padding: 0 16px; }
  .bc-launch span { display: none; }
  .bc-win { right: 0; bottom: 0; width: 100vw; height: 100dvh; border-radius: 0; }
}
@media (prefers-reduced-motion: reduce) { .bc-win, .bc-m, .bc-typing i { animation: none; } .bc-launch { transition: none; } }
