/* Asistente: conversación con el bot. */
.chatlog { display: flex; flex-direction: column; gap: 8px; padding-bottom: 86px; }
.bubble { align-self: flex-start; max-width: 88%; background: var(--card-2); border: 1px solid var(--line); border-radius: 16px 16px 16px 4px; padding: 10px 13px; white-space: pre-line; font-size: 14.5px; margin-bottom: 4px; }
.bubble.me { align-self: flex-end; background: var(--text); color: #000; border-color: var(--text); border-radius: 16px 16px 4px 16px; }
.card .bubble.me { margin-left: auto; display: table; }
.bubble.typing { color: var(--muted); display: flex; align-items: center; gap: 6px; }
.bubble .act { display: flex; align-items: center; gap: 8px; margin-top: 8px; padding-top: 8px; border-top: 1px solid var(--line-2); font-size: 13px; white-space: normal; }
.bubble.me .act { border-color: #ccc; }
.bubble .act.done { color: var(--green); }
.composer { position: fixed; left: 0; right: 0; bottom: var(--nav); padding: 10px 16px; background: rgba(0, 0, 0, 0.94); border-top: 1px solid var(--line); display: flex; gap: 8px; z-index: 18; max-width: 720px; margin: 0 auto; }
.composer textarea { min-height: 48px; max-height: 120px; resize: none; }
.composer .btn { width: 52px; padding: 0; flex: none; }
nav.tabs button { min-width: 52px; }
@media (min-width: 1000px) {
  .composer { left: 232px; bottom: 0; max-width: none; }
  .chatlog { padding-bottom: 90px; }
}

/* Gráficas: etiquetas como texto y barras en HTML (no se deforman en pantallas anchas). */
.chart-labels { display: flex; justify-content: space-between; font-size: 10.5px; color: var(--dim); margin-top: 4px; }
.bars { display: flex; align-items: stretch; gap: 4px; }
.bcol { flex: 1; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; min-width: 0; }
.bbar { width: 64%; max-width: 34px; border-radius: 4px 4px 2px 2px; }
.bval { font-size: 10.5px; color: var(--text); white-space: nowrap; min-height: 14px; }
.blab { font-size: 10.5px; color: var(--dim); min-height: 14px; margin-top: 3px; }

/* Imágenes adjuntas y documentos. */
.composer-files { position: fixed; left: 0; right: 0; bottom: calc(var(--nav) + 70px); display: flex; gap: 8px; padding: 0 16px; z-index: 18; max-width: 720px; margin: 0 auto; }
.cf { position: relative; width: 56px; height: 56px; border-radius: 12px; overflow: hidden; border: 1px solid var(--line-2); }
.cf img { width: 100%; height: 100%; object-fit: cover; }
.cf span { position: absolute; top: 2px; right: 2px; background: rgba(0,0,0,.7); border-radius: 99px; display: grid; place-items: center; width: 20px; height: 20px; }
.doc-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.doc { background: var(--card); border: 1px solid var(--line); border-radius: 14px; overflow: hidden; text-align: left; }
.doc img, .doc .ph { width: 100%; height: 120px; object-fit: cover; display: grid; place-items: center; background: #19191b; color: var(--dim); }
.doc .b { padding: 8px 10px; }
@media (min-width: 1000px) { .composer-files { left: 232px; bottom: 74px; max-width: none; } }
