/* Nodo IA — widget flotante de kuvolab.com.
   No se toca desde ningún otro sitio: vive en su propio bloque, se agrega al FINAL del <style>
   de la página (gana la cascada, como manda Kuvo-Estudio/CLAUDE.md).
   Manual de marca: Inter, --accent #4A8CF7, radios 8/10/16/20, blanco/negro puro, sin emojis.
   Rediseño 23-sep-2026: panel más compacto, burbujas diferenciadas por color (usuario con tinte
   de acento, Nodo IA en gris neutro de chrome funcional), entrada en píldora. Ver nota al pie del
   informe de Kuvo.Estudio para el detalle de cada decisión. */

#nodo-kbia {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 9999;
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background: #0B0B0F;
  border: none;
  padding: 0;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.22);
  box-sizing: border-box;
  outline: 2px solid rgba(74, 140, 247, 0.55);
  outline-offset: 2px;
  opacity: 0;
  transform: translateY(12px) scale(0.94);
  transition: opacity 0.35s cubic-bezier(.2,.8,.2,1), transform 0.35s cubic-bezier(.2,.8,.2,1);
  pointer-events: none;
}
#nodo-kbia.nodo-visible {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}
#nodo-kbia:focus-visible {
  outline: 2px solid #4A8CF7;
  outline-offset: 3px;
}

/* Panel del chat — compacto, 320×460 (antes 360×520) */
#nodo-panel {
  position: fixed;
  right: 20px;
  bottom: 76px;
  z-index: 9999;
  width: min(320px, calc(100vw - 40px));
  height: min(460px, calc(100vh - 140px));
  background: #FFFFFF;
  border-radius: 20px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.25);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  font-family: "Inter", -apple-system, sans-serif;
  opacity: 0;
  transform: translateY(16px) scale(0.98);
  pointer-events: none;
  transition: opacity 0.3s cubic-bezier(.2,.8,.2,1), transform 0.3s cubic-bezier(.2,.8,.2,1),
    width 0.25s cubic-bezier(.2,.8,.2,1), height 0.25s cubic-bezier(.2,.8,.2,1);
}
#nodo-panel.nodo-abierto {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}
/* Expandido: a pedido del dueño, para leer mejor una recomendacion larga sin sentirse encerrado */
#nodo-panel.nodo-grande {
  width: min(440px, calc(100vw - 40px));
  height: min(640px, calc(100vh - 100px));
}
#nodo-panel .nodo-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 13px 16px;
  background: #0B0B0F;
  color: #FFFFFF;
  flex-shrink: 0;
}
#nodo-panel .nodo-header-acciones {
  display: flex;
  align-items: center;
  gap: 6px;
}
#nodo-panel .nodo-expandir {
  background: none;
  border: none;
  color: #FFFFFF;
  cursor: pointer;
  padding: 4px;
  display: flex;
  opacity: 0.65;
  transition: opacity 0.15s ease;
}
#nodo-panel .nodo-expandir:hover { opacity: 1; }
#nodo-panel .nodo-expandir svg { width: 15px; height: 15px; }
#nodo-panel .nodo-header-titulo {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
  font-size: 14px;
  letter-spacing: -0.01em;
}
#nodo-panel .nodo-header-titulo .nodo-punto {
  width: 8px;
  height: 8px;
  border-radius: 999px; /* estado — permitido por la regla 3 del manual (círculos solo para avatar/bandera/estado) */
  background: #4A8CF7;
}
#nodo-panel .nodo-cerrar {
  background: none;
  border: none;
  color: #FFFFFF;
  font-size: 16px;
  line-height: 1;
  cursor: pointer;
  padding: 4px;
  opacity: 0.65;
  transition: opacity 0.15s ease;
}
#nodo-panel .nodo-cerrar:hover { opacity: 1; }

#nodo-panel .nodo-mensajes {
  flex: 1;
  overflow-y: auto;
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  background: #FFFFFF;
}

/* Burbujas — diferenciadas por color, no por borde:
   usuario = tinte muy suave del acento (--accent al 10%), Nodo IA = gris de chrome funcional.
   Radio 16 en las tres esquinas abiertas, 8 en la esquina "de cola" (el 6px viejo no era un
   radio del sistema 8/10/16/20). */
.nodo-msg {
  max-width: 84%;
  padding: 9px 13px;
  border-radius: 16px;
  font-size: 13.5px;
  line-height: 1.45;
  white-space: pre-wrap;
  overflow-wrap: anywhere; /* una URL o un correo largo no se sale de la burbuja */
}
.nodo-msg-usuario {
  align-self: flex-end;
  background: rgba(74, 140, 247, 0.12);
  color: #0B0B0F;
  border-bottom-right-radius: 8px;
}
.nodo-msg-nodo {
  align-self: flex-start;
  background: #F2F2F4;
  color: #0B0B0F;
  border-bottom-left-radius: 8px;
}
.nodo-msg-cargando {
  align-self: flex-start;
  display: flex;
  gap: 4px;
  padding: 11px 14px;
  background: #F2F2F4;
  border-radius: 16px;
  border-bottom-left-radius: 8px;
}
.nodo-msg-cargando span {
  width: 6px; height: 6px; border-radius: 999px; background: #B4B4BC;
  animation: nodo-cargando 1s ease-in-out infinite;
}
.nodo-msg-cargando span:nth-child(2) { animation-delay: 0.15s; }
.nodo-msg-cargando span:nth-child(3) { animation-delay: 0.3s; }
@keyframes nodo-cargando { 0%, 100% { opacity: 0.3; } 50% { opacity: 1; } }

.nodo-tarjeta {
  align-self: flex-start;
  max-width: 84%;
  background: #F2F2F4;
  border-radius: 16px;
  border-bottom-left-radius: 8px;
  padding: 11px 13px;
  font-size: 13px;
  color: #0B0B0F;
}
.nodo-tarjeta a {
  display: inline-block;
  margin-top: 8px;
  background: #0B0B0F;
  color: #FFFFFF;
  text-decoration: none;
  font-weight: 600;
  font-size: 12.5px;
  padding: 8px 14px;
  border-radius: 10px;
}

/* Opciones clicables — la persona elige en vez de escribir. */
.nodo-opciones-pregunta {
  font-weight: 600;
  margin-bottom: 8px;
}
.nodo-opciones-fila {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.nodo-opcion {
  background: #FFFFFF;
  border: 1px solid #E2E2E6;
  border-radius: 10px;
  padding: 7px 12px;
  font-family: inherit;
  font-size: 12.5px;
  font-weight: 500;
  color: #0B0B0F;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease, opacity 0.15s ease;
}
.nodo-opcion:hover:not(:disabled) { background: #F2F2F4; }
.nodo-opcion:disabled { opacity: 0.45; cursor: default; }
.nodo-opcion-elegida {
  background: #0B0B0F !important;
  color: #FFFFFF !important;
  border-color: #0B0B0F !important;
  opacity: 1 !important;
}

/* Tarjeta de recomendacion — el sistema que le conviene, con enlace directo a su pagina. */
.nodo-recomendacion-titulo {
  font-weight: 700;
  font-size: 14px;
  margin-bottom: 4px;
}
.nodo-recomendacion-motivo {
  font-size: 12.5px;
  color: #55555C;
  line-height: 1.4;
  margin-bottom: 10px;
}
a.nodo-recomendacion-ir {
  display: inline-block;
  background: #4A8CF7;
  color: #FFFFFF;
  text-decoration: none;
  font-weight: 600;
  font-size: 12.5px;
  padding: 8px 14px;
  border-radius: 10px;
}
/* Segundo enlace (la demo de una pagina web): mismo tamano, secundario — borde, no relleno. */
a.nodo-recomendacion-ir:not(:last-child) { margin-right: 6px; }
a.nodo-recomendacion-demo {
  margin-top: 6px;
  background: transparent;
  color: #4A8CF7;
  box-shadow: inset 0 0 0 1px #4A8CF7;
}

/* Avatar de Nodo IA: su símbolo (círculo + bucle). Círculo permitido: es avatar. */
.nodo-fila-nodo {
  display: flex;
  align-items: flex-end;
  gap: 6px;
  align-self: flex-start;
  max-width: 90%;
}
.nodo-fila-nodo .nodo-msg-nodo,
.nodo-fila-nodo .nodo-tarjeta {
  align-self: auto;
  max-width: none;
}
.nodo-avatar-nodo {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
  border-radius: 999px;
  background: #0B0B0F;
  display: flex;
  align-items: center;
  justify-content: center;
}
.nodo-avatar-nodo svg { width: 100%; height: 100%; display: block; }

/* Entrada en píldora: el contenedor ES la píldora (radio 20), textarea y botón viven adentro
   sin borde propio — así se evita crear un elemento nuevo en el DOM. */
#nodo-panel .nodo-entrada {
  display: flex;
  align-items: flex-end;
  gap: 6px;
  margin: 10px 14px 14px;
  padding: 6px 6px 6px 14px;
  background: #F2F2F4;
  border-radius: 20px;
  flex-shrink: 0;
  transition: box-shadow 0.15s ease;
}
#nodo-panel .nodo-entrada:focus-within {
  box-shadow: 0 0 0 2px rgba(74, 140, 247, 0.45);
}
#nodo-panel .nodo-input {
  flex: 1;
  border: none;
  background: transparent;
  padding: 8px 0;
  font-family: inherit;
  font-size: 13.5px;
  resize: none;
  max-height: 90px;
  outline: none;
  color: #0B0B0F;
}
#nodo-panel .nodo-input::placeholder { color: #8A8A93; }
/* iPhone: Safari hace zoom al enfocar un campo con letra < 16px; en pantalla chica va a 16px, sin zoom */
@media (max-width: 640px) { #nodo-panel .nodo-input { font-size: 16px; } }
#nodo-panel .nodo-enviar {
  background: #4A8CF7;
  color: #FFFFFF;
  border: none;
  border-radius: 10px;
  padding: 9px 15px;
  font-weight: 600;
  font-size: 13px;
  cursor: pointer;
  flex-shrink: 0;
  transition: opacity 0.15s ease;
}
#nodo-panel .nodo-enviar:hover:not(:disabled) { opacity: 0.88; }
#nodo-panel .nodo-enviar:disabled { opacity: 0.35; cursor: not-allowed; }

#nodo-turnstile-caja {
  padding: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 1;
}

@media (prefers-reduced-motion: reduce) {
  #nodo-kbia, #nodo-panel { transition: opacity 0.01s linear; }
}


/* ===== Rediseño 9-oct-2026 (orden del dueño, referencia «AI Chat»): panel blanco limpio,
   encabezado sin barra negra, burbujas suaves de radio parejo, entrada y envío separados.
   Se traduce al manual: radios 8/10/16/20 (nada de píldoras), avatar con el símbolo real de
   Nodo IA (no la esfera degradada de la referencia), un solo azul. ===== */
#nodo-panel {
  width: min(352px, calc(100vw - 32px));
  height: min(520px, calc(100vh - 130px));
  border-radius: 20px;
  border: 1px solid rgba(11, 11, 15, 0.08);
  box-shadow: 0 24px 64px -18px rgba(11, 11, 15, 0.28), 0 2px 8px rgba(11, 11, 15, 0.06);
}
#nodo-panel.nodo-grande { width: min(460px, calc(100vw - 32px)); height: min(660px, calc(100vh - 100px)); }
#nodo-panel .nodo-header { background: #FFFFFF; color: #0B0B0F; padding: 18px 18px 8px 20px; }
#nodo-panel .nodo-header-titulo { font-size: 15px; font-weight: 600; letter-spacing: -0.015em; gap: 8px; }
#nodo-panel .nodo-header-titulo .nodo-punto { width: 7px; height: 7px; }
#nodo-panel .nodo-expandir, #nodo-panel .nodo-cerrar {
  color: #0B0B0F; opacity: 0.55; width: 30px; height: 30px; padding: 0; border-radius: 8px;
  display: flex; align-items: center; justify-content: center; transition: opacity .15s ease, background .15s ease;
}
#nodo-panel .nodo-expandir:hover, #nodo-panel .nodo-cerrar:hover { opacity: 1; background: #F3F4F6; }
#nodo-panel .nodo-cerrar svg { width: 17px; height: 17px; }
#nodo-panel .nodo-expandir svg { width: 14px; height: 14px; }
#nodo-panel .nodo-mensajes { padding: 12px 18px 8px; gap: 12px; }
.nodo-msg { font-size: 14px; line-height: 1.5; padding: 11px 15px; border-radius: 16px; max-width: 82%; }
.nodo-msg-usuario { background: #EAF2FE; color: #2563C9; border-bottom-right-radius: 16px; }
.nodo-msg-nodo { background: #F3F4F6; color: #0B0B0F; border-bottom-left-radius: 16px; }
.nodo-msg-cargando, .nodo-tarjeta { background: #F3F4F6; border-radius: 16px; border-bottom-left-radius: 16px; }
.nodo-tarjeta { padding: 13px 15px; font-size: 13.5px; }
.nodo-fila-nodo { gap: 10px; max-width: 92%; }
.nodo-fila-nodo > * { min-width: 0; }  /* una palabra larga ya no se sale de la burbuja */
.nodo-avatar-nodo { width: 28px; height: 28px; }
.nodo-opcion { background: #FFFFFF; border-color: #E4E4E8; }
#nodo-panel .nodo-entrada {
  background: transparent; padding: 0; margin: 8px 16px 16px; gap: 8px; align-items: center; border-radius: 0;
}
#nodo-panel .nodo-entrada:focus-within { box-shadow: none; }
#nodo-panel .nodo-input {
  background: #F3F4F6; border-radius: 16px; padding: 12px 16px; font-size: 14px; line-height: 1.4;
  transition: box-shadow .15s ease;
}
#nodo-panel .nodo-input:focus { box-shadow: 0 0 0 2px rgba(74, 140, 247, 0.4); }
@media (max-width: 640px) { #nodo-panel .nodo-input { font-size: 16px; } }
#nodo-panel .nodo-enviar {
  width: 44px; height: 44px; padding: 0; border-radius: 16px; background: #4A8CF7; color: #FFFFFF;
  display: flex; align-items: center; justify-content: center;
}
#nodo-panel .nodo-enviar svg { width: 18px; height: 18px; }
#nodo-panel .nodo-enviar:disabled { background: #F3F4F6; color: #8A8A93; opacity: 1; }

/* Móvil (9-oct-2026, orden del dueño): el botón flotante se veía demasiado grande y tapaba
   contenido. Más chico, más pegado a la esquina y sin el aro exterior; el panel baja con él. */
@media (max-width: 640px) {
  #nodo-kbia { width: 36px; height: 36px; right: 12px; bottom: 12px; border-radius: 8px;
    outline: none; box-shadow: 0 6px 18px rgba(0, 0, 0, 0.2); }
  #nodo-panel { right: 12px; bottom: 56px; width: calc(100vw - 24px); height: min(520px, calc(100vh - 96px)); }
  #nodo-panel.nodo-grande { width: calc(100vw - 24px); height: calc(100vh - 80px); }
}

/* 15-oct-2026 (dueño): Nodo IA sin personaje. El botón es su símbolo: círculo negro con el bucle blanco;
   en tema oscuro se invierte (círculo blanco, bucle negro). Sin ojos, sin gestos, sin seguir el cursor. */
#nodo-kbia { width: 56px; height: 56px; border-radius: 50%; background: #0B0B0F; border: 0; overflow: hidden;
  outline: 2px solid rgba(74, 140, 247, 0.55); outline-offset: 2px; }
#nodo-kbia .nodo-ia-orbe { transition: transform 0.35s cubic-bezier(.2,.8,.2,1); }
#nodo-kbia:hover .nodo-ia-orbe { transform: scale(1.04); }
/* 18-oct-2026: el orbe está pensado para brillar sobre negro; en tema oscuro el botón sigue negro con un filete claro */
html[data-theme="dark"] #nodo-kbia { background: #0B0B0F; box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.16), 0 8px 24px rgba(0, 0, 0, 0.5); }
/* pensando: el bucle se recorre a sí mismo, en el botón y en el avatar de la fila que carga */
@media (prefers-reduced-motion: reduce) {
  #nodo-kbia .nodo-ia-orbe { transition: none; }
}
.nodo-avatar-nodo { width: 28px; height: 28px; border-radius: 50%; background: transparent; overflow: hidden; }
/* 11-oct-2026: el panel del chat se abre por encima del botón redondo, sin taparlo */
#nodo-panel { bottom: 96px; height: min(460px, calc(100vh - 160px)); }
@media (max-width: 600px) {
  #nodo-kbia { width: 48px; height: 48px; border-radius: 50%; right: 14px; bottom: 14px; }
  #nodo-panel { bottom: 78px; height: min(520px, calc(100vh - 120px)); }
}
/* 11-oct-2026: en el celular el panel (normal o expandido) nunca se sale de la pantalla:
   usa el alto visible real (dvh, descuenta la barra del navegador) y deja libre la esquina del botón */
@media (max-width: 600px) {
  #nodo-panel, #nodo-panel.nodo-grande {
    right: 10px; left: 10px; width: auto;
    top: max(10px, env(safe-area-inset-top));
    bottom: calc(76px + env(safe-area-inset-bottom));
    height: auto; max-height: none;
  }
  #nodo-panel:not(.nodo-grande) { top: auto; height: min(520px, calc(100dvh - 96px - env(safe-area-inset-bottom))); }
}

/* ===== 13-oct-2026 (dueño, referencia «AI Chat»): chat limpio, tarjeta blanca, sugerencias para tocar,
   campo gris y botón redondo azul. Radios de la casa (sin píldoras) y el azul único en vez del degradado. ===== */
#nodo-panel { background: #FFFFFF; color: #0B0B0F; border: 1px solid rgba(11, 11, 15, 0.08); border-radius: 20px;
  box-shadow: 0 24px 60px -24px rgba(16, 24, 40, 0.28), 0 2px 6px rgba(16, 24, 40, 0.06); }
#nodo-panel .nodo-header { padding: 16px 16px 10px 18px; border-bottom: 0; background: #FFFFFF; }
#nodo-panel .nodo-header-titulo { display: flex; align-items: center; gap: 10px; color: #0B0B0F; }
#nodo-panel .nodo-header-av { width: 32px; height: 32px; flex: none; display: block; }
#nodo-panel .nodo-header-titulo > span { display: flex; flex-direction: column; line-height: 1.15; }
#nodo-panel .nodo-header-titulo b { font-size: 15px; font-weight: 650; letter-spacing: -0.01em; }
#nodo-panel .nodo-header-sub { font-size: 11.5px; font-weight: 500; color: #1E8E3E; }
#nodo-panel .nodo-header-acciones button { color: #6E6E73; background: transparent; border-radius: 10px; }
#nodo-panel .nodo-header-acciones button:hover { background: #F2F3F5; color: #0B0B0F; }
#nodo-panel .nodo-mensajes { background: #FFFFFF; padding: 6px 18px 12px; }
#nodo-panel .nodo-msg-nodo { background: #F4F5F7; color: #0B0B0F; border: 0; }
#nodo-panel .nodo-msg-usuario { background: #4A8CF7; color: #FFFFFF; }
/* sugerencias y opciones: tarjetitas grises con texto azul, alineadas a la izquierda */
.nodo-sugerencias { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; margin: 14px 0 4px; }
.nodo-sugerencias-t { font-size: 13px; font-weight: 600; color: #0B0B0F; margin: 0 0 2px 2px; }
.nodo-sugerencia, #nodo-panel .nodo-opcion { font: 500 13.5px/1.35 Inter, system-ui, sans-serif; text-align: left; color: #2F6FE0; background: #F2F3F5;
  border: 0; border-radius: 10px; padding: 9px 14px; cursor: pointer; max-width: 92%;
  transition: background 0.2s cubic-bezier(.2,.8,.2,1), transform 0.2s cubic-bezier(.2,.8,.2,1); }
.nodo-sugerencia:hover, #nodo-panel .nodo-opcion:hover:not(:disabled) { background: #E8EEFC; transform: translateX(2px); }
.nodo-sugerencia:focus-visible, #nodo-panel .nodo-opcion:focus-visible { outline: 2px solid #4A8CF7; outline-offset: 2px; }
.nodo-sugerencias .nodo-sugerencia { opacity: 0; transform: translateY(6px); animation: nodo-sug 0.45s cubic-bezier(.2,.8,.2,1) forwards; }
.nodo-sugerencias .nodo-sugerencia:nth-of-type(2) { animation-delay: .06s; } .nodo-sugerencias .nodo-sugerencia:nth-of-type(3) { animation-delay: .12s; }
.nodo-sugerencias .nodo-sugerencia:nth-of-type(4) { animation-delay: .18s; } .nodo-sugerencias .nodo-sugerencia:nth-of-type(5) { animation-delay: .24s; }
@keyframes nodo-sug { to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .nodo-sugerencias .nodo-sugerencia { animation: none; opacity: 1; transform: none; } }
/* entrada: campo gris redondeado y botón redondo azul aparte */
#nodo-panel .nodo-entrada { display: flex; align-items: center; gap: 10px; padding: 10px 14px 14px 16px; border-top: 0; background: #FFFFFF; }
#nodo-panel .nodo-input { flex: 1; background: #F2F3F5; border: 0; border-radius: 16px; padding: 12px 16px; color: #0B0B0F; font-size: 14px; min-height: 0; box-shadow: none; }
#nodo-panel .nodo-input::placeholder { color: #8A8A90; }
#nodo-panel .nodo-input:focus { outline: none; box-shadow: 0 0 0 2px rgba(74, 140, 247, 0.35); }
#nodo-panel .nodo-enviar { flex: none; width: 44px; height: 44px; border-radius: 50%; background: #4A8CF7; color: #FFFFFF; border: 0;
  box-shadow: 0 0 0 4px rgba(74, 140, 247, 0.14); }
#nodo-panel .nodo-enviar svg { width: 18px; height: 18px; }
#nodo-panel .nodo-enviar:disabled { background: #C9D7F5; box-shadow: none; }
#nodo-panel .nodo-fila-nodo > .nodo-avatar-nodo:not(.nodo-avatar-carga) { display: none; }
#nodo-panel .nodo-fila-nodo .nodo-msg-nodo { max-width: 90%; }
@media (min-width: 601px) { #nodo-panel:not(.nodo-grande) { height: min(560px, calc(100vh - 130px)); width: 360px; } }

/* ============================================================================================
   18-oct-2026 (dueño: «tenemos nuevo diseño de Nodo, impleméntalo en todas las páginas»): el orbe de Nodo IA,
   aprobado el 17-oct-2026 en Collab (kuvolab/kuvo-colab, web/orbe-nodo/orbe.css). Dos lentes de vidrio que se cruzan
   con una almendra de luz; en reposo respiran, pensando se cruzan y el brillo corre. Solo grises. Reemplaza al
   símbolo neutro del bucle. Fotogramas con prefijo «orbe-» para no chocar con los de cada página.
   Marcado: <span class="orbe [oscuro|claro|mini|grande|piensa]"><i class="o1"></i><i class="o2"></i><i class="o3"></i></span>
   ============================================================================================ */
.orbe { --o: 28px; position: relative; display: inline-block; width: var(--o); height: var(--o); flex: none; isolation: isolate; }
.orbe::before { content: ''; position: absolute; inset: -35%; border-radius: 50%; background: radial-gradient(closest-side, rgba(255, 255, 255, 0.14), transparent 72%); z-index: -1; }
.orbe .o1, .orbe .o2 {
  position: absolute; top: 15%; width: 70%; height: 70%; border-radius: 50%;
  background:
    radial-gradient(circle at 32% 26%, rgba(255, 255, 255, 0.75) 0, rgba(255, 255, 255, 0.18) 22%, transparent 46%),
    radial-gradient(circle at 70% 78%, rgba(255, 255, 255, 0.22) 0, transparent 40%),
    radial-gradient(circle at 50% 50%, rgba(120, 120, 130, 0.10) 0, rgba(200, 200, 210, 0.18) 64%, rgba(255, 255, 255, 0.34) 71%);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.42), inset 0 0 calc(var(--o) * 0.08) rgba(255, 255, 255, 0.35), 0 0 calc(var(--o) * 0.10) rgba(255, 255, 255, 0.10);
  mix-blend-mode: screen; will-change: transform;
}
.orbe .o1 { left: 0; animation: orbe-lenteA 6s cubic-bezier(0.2, 0.8, 0.2, 1) infinite alternate; }
.orbe .o2 { right: 0; animation: orbe-lenteB 6s cubic-bezier(0.2, 0.8, 0.2, 1) infinite alternate; }
.orbe .o1::after, .orbe .o2::after {
  content: ''; position: absolute; inset: 0; border-radius: 50%;
  background: conic-gradient(from 0deg, transparent 0 62%, rgba(255, 255, 255, 0.95) 76%, transparent 86% 100%);
  -webkit-mask: radial-gradient(closest-side, transparent calc(100% - 2px), #000 calc(100% - 1.5px));
  mask: radial-gradient(closest-side, transparent calc(100% - 2px), #000 calc(100% - 1.5px));
  animation: orbe-canto 7s linear infinite;
}
.orbe .o2::after { animation-direction: reverse; animation-delay: -2s; }
.orbe .o3 {
  position: absolute; left: 39%; top: 28%; width: 22%; height: 44%; border-radius: 50%;
  background: radial-gradient(closest-side, rgba(255, 255, 255, 0.95), rgba(255, 255, 255, 0.35) 55%, transparent);
  filter: blur(calc(var(--o) * 0.025)); mix-blend-mode: screen;
  animation: orbe-almendra 6s cubic-bezier(0.2, 0.8, 0.2, 1) infinite alternate;
}
@keyframes orbe-lenteA { from { transform: translateX(-3%); } to { transform: translateX(4%); } }
@keyframes orbe-lenteB { from { transform: translateX(3%); } to { transform: translateX(-4%); } }
@keyframes orbe-canto { to { transform: rotate(360deg); } }
@keyframes orbe-almendra { from { opacity: 0.7; transform: scaleX(0.85); } to { opacity: 1; transform: scaleX(1.12); } }
.orbe.piensa .o1, .nodo-pensando .orbe .o1, .nodo-avatar-carga .orbe .o1 { animation: orbe-cruzaA 1.1s cubic-bezier(0.2, 0.8, 0.2, 1) infinite alternate; }
.orbe.piensa .o2, .nodo-pensando .orbe .o2, .nodo-avatar-carga .orbe .o2 { animation: orbe-cruzaB 1.1s cubic-bezier(0.2, 0.8, 0.2, 1) infinite alternate; }
.orbe.piensa .o1::after, .orbe.piensa .o2::after, .nodo-pensando .orbe i::after, .nodo-avatar-carga .orbe i::after { animation-duration: 1.2s; }
.orbe.piensa .o3, .nodo-pensando .orbe .o3, .nodo-avatar-carga .orbe .o3 { animation: orbe-late 0.55s ease-in-out infinite alternate; }
@keyframes orbe-cruzaA { from { transform: translateX(-4%); } to { transform: translateX(12%); } }
@keyframes orbe-cruzaB { from { transform: translateX(4%); } to { transform: translateX(-12%); } }
@keyframes orbe-late { from { opacity: 0.6; transform: scale(0.8); } to { opacity: 1; transform: scale(1.35, 1.15); } }
.orbe.mini { --o: 18px; }
.orbe.grande { --o: 64px; }
/* en su disco negro: botones, avatares y cabeceras sobre fondo claro */
.orbe.oscuro { background: #0B0B0F; border-radius: 50%; box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.06); }
.orbe.oscuro::before { display: none; }
.orbe.oscuro .o1, .orbe.oscuro .o2 { top: 22%; width: 58%; height: 58%; }
.orbe.oscuro .o1 { left: 8%; } .orbe.oscuro .o2 { right: 8%; }
.orbe.oscuro .o3 { left: 42%; top: 32%; width: 16%; height: 36%; }
html[data-theme="dark"] .orbe.oscuro { box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.14); }
/* llena el contenedor que ya tiene su tamaño (botón, avatar, cara del chat) */
.orbe.llena { width: 100%; height: 100%; display: block; }
@media (prefers-reduced-motion: reduce) {
  .orbe i, .orbe i::after { animation: none !important; }
}

/* ============================================================================================
   18-oct-2026 (dueño: «me gusta más este diseño, ese es el diseño real de Nodo IA»): el botón flotante es la
   píldora de Collab (kuvo-colab, web/estilos.css .nodo-flota): el orbe sin disco y «Nodo IA» en un cristal oscuro.
   Reemplaza al círculo negro con aro azul. Excepción a «sin píldoras» del manual, por orden del dueño.
   ============================================================================================ */
#nodo-kbia, html[data-theme="dark"] #nodo-kbia {
  width: auto; height: 48px; padding: 0 17px 0 9px; gap: 10px; border-radius: 24px; overflow: visible;
  background: rgba(16, 16, 19, 0.82); border: 1px solid rgba(255, 255, 255, 0.10);
  -webkit-backdrop-filter: blur(16px) saturate(140%); backdrop-filter: blur(16px) saturate(140%);
  box-shadow: 0 16px 40px -18px rgba(0, 0, 0, 0.9), inset 0 1px 0 rgba(255, 255, 255, 0.06);
  outline: none; color: #F5F5F7; font-family: Inter, -apple-system, system-ui, sans-serif; font-size: 14px; font-weight: 600; letter-spacing: -0.01em;
}
#nodo-kbia .orbe { --o: 30px; }
#nodo-kbia .nodo-flota-t { white-space: nowrap; line-height: 1; }
#nodo-kbia:hover { background: rgba(28, 28, 33, 0.9); }
#nodo-kbia.nodo-visible:active { transform: scale(0.97); }
#nodo-kbia:focus-visible { outline: 2px solid #4A8CF7; outline-offset: 3px; }
@media (max-width: 640px) {
  #nodo-kbia, html[data-theme="dark"] #nodo-kbia { width: auto; height: 40px; padding: 0 14px 0 7px; gap: 8px; border-radius: 20px; right: 12px; bottom: 14px; font-size: 13px; }
  #nodo-kbia .orbe { --o: 25px; }
}

/* Orbe sobre fondo claro (kuvo-colab web/orbe-nodo/orbe.css, variante «claro»): canto oscuro nítido, cuerpo de
   vidrio y almendra gris. Es la que va dentro del panel blanco del chat. */
.orbe.claro::before { inset: 8% -6% -14%; border-radius: 50%; background: radial-gradient(closest-side, rgba(11, 11, 15, 0.10), transparent 75%); transform: translateY(18%); filter: blur(1px); }
.orbe.claro .o1, .orbe.claro .o2 {
  mix-blend-mode: multiply;
  background:
    radial-gradient(circle at 30% 26%, rgba(255, 255, 255, 1) 0, rgba(255, 255, 255, 0.85) 16%, transparent 34%),
    radial-gradient(circle at 70% 80%, rgba(11, 11, 15, 0.10) 0, transparent 42%),
    radial-gradient(circle at 50% 50%, rgba(244, 244, 247, 0.55) 0, rgba(214, 214, 220, 0.55) 62%, rgba(140, 140, 150, 0.6) 70.5%);
  box-shadow: inset 0 0 0 1px rgba(11, 11, 15, 0.55), inset 0 0 calc(var(--o) * 0.06) rgba(11, 11, 15, 0.18);
}
.orbe.claro .o1::after, .orbe.claro .o2::after { background: conic-gradient(from 0deg, transparent 0 62%, rgba(11, 11, 15, 0.75) 76%, transparent 86% 100%); }
.orbe.claro .o3 { mix-blend-mode: multiply; background: radial-gradient(closest-side, rgba(11, 11, 15, 0.42), rgba(11, 11, 15, 0.16) 55%, transparent); filter: none; }

/* ============================================================================================
   18-oct-2026 (dueño: «el diseño del chat tampoco debe ser así, es así, sin la parte de créditos»): el panel sigue
   el chat de Nodo IA de Collab — cabecera con el orbe y «Nodo IA», bienvenida grande, sugerencias en filas grises
   con chispa, caja de escritura con borde y envío negro, aviso al pie. Sin créditos, sin «En línea», sin agrandar.
   ============================================================================================ */
#nodo-panel { border-radius: 20px; }
#nodo-panel .nodo-header { padding: 14px 14px 14px 18px; border-bottom: 1px solid rgba(11, 11, 15, 0.08); }
#nodo-panel .nodo-header-titulo { gap: 10px; }
#nodo-panel .nodo-header-av { --o: 28px; width: 28px; height: 28px; }
#nodo-panel .nodo-header-titulo b { font-size: 16px; font-weight: 650; letter-spacing: -0.015em; }
#nodo-panel .nodo-header-acciones button { width: 34px; height: 34px; }
#nodo-panel .nodo-mensajes { padding: 16px 18px 12px; }
.nodo-sugerencias.nodo-bienvenida { align-items: stretch; gap: 8px; margin: auto 0 0; padding-top: 18px; }
.nodo-bienvenida-orbe { margin: 0 0 10px 2px; }
.nodo-bienvenida-orbe .orbe { --o: 54px; }
.nodo-bienvenida-h { margin: 0; font: 700 22px/1.15 Inter, -apple-system, system-ui, sans-serif; letter-spacing: -0.03em; color: #0B0B0F; }
.nodo-bienvenida-p { margin: 4px 0 10px; font: 400 14.5px/1.5 Inter, -apple-system, system-ui, sans-serif; color: #6E6E73; }
.nodo-bienvenida .nodo-sugerencia {
  display: flex; align-items: center; gap: 12px; width: 100%; padding: 13px 14px; border: 0; border-radius: 12px;
  background: #F2F2F5; color: #0B0B0F; font: 500 14px/1.35 Inter, -apple-system, system-ui, sans-serif; text-align: left; cursor: pointer;
}
.nodo-bienvenida .nodo-sugerencia svg { width: 16px; height: 16px; flex: none; color: #3A3A40; }
.nodo-bienvenida .nodo-sugerencia:hover { background: #E9E9ED; transform: none; }
.nodo-bienvenida .nodo-sugerencia:focus-visible { outline: 2px solid #0B0B0F; outline-offset: 2px; }
#nodo-panel .nodo-entrada {
  display: flex; flex-direction: column; align-items: stretch; gap: 6px; margin: 0 14px; padding: 12px 10px 10px 14px;
  border: 1px solid rgba(11, 11, 15, 0.16); border-radius: 16px; background: #FFFFFF;
}
#nodo-panel .nodo-entrada:focus-within { border-color: rgba(11, 11, 15, 0.42); box-shadow: none; }
#nodo-panel .nodo-input { background: transparent; border: 0; border-radius: 0; padding: 2px 0; min-height: 24px; }
#nodo-panel .nodo-input:focus { box-shadow: none; outline: none; }
.nodo-entrada-pie { display: flex; justify-content: flex-end; }
#nodo-panel .nodo-enviar { width: 36px; height: 36px; border-radius: 50%; background: #0B0B0F; color: #FFFFFF; box-shadow: none; }
#nodo-panel .nodo-enviar:disabled { background: #D6D6DB; color: #FFFFFF; }
#nodo-panel .nodo-enviar svg { width: 16px; height: 16px; }
.nodo-aviso { margin: 8px 14px 12px; font: 400 11.5px/1.4 Inter, -apple-system, system-ui, sans-serif; color: #8A8A90; text-align: center; }
#nodo-panel .nodo-msg-usuario { background: #0B0B0F; color: #FFFFFF; }
.nodo-bienvenida .nodo-sugerencia { max-width: none; align-self: stretch; box-sizing: border-box; }
