/* Copia de crm-danweb 24aced4. No editar: scripts/oficina-demo-sync.mjs */
@font-face { font-family: 'Nixie One'; src: url(fuentes/nixie-one-latin-400-normal.woff2) format('woff2'); font-weight: 400; font-display: swap; }
@font-face { font-family: 'Roboto Mono'; src: url(fuentes/roboto-mono-latin-400-normal.woff2) format('woff2'); font-weight: 400; font-display: swap; }
@font-face { font-family: 'Roboto Mono'; src: url(fuentes/roboto-mono-latin-500-normal.woff2) format('woff2'); font-weight: 500; font-display: swap; }
@font-face { font-family: 'Andika'; src: url(fuentes/andika-latin-400-normal.woff2) format('woff2'); font-weight: 400; font-display: swap; }
@font-face { font-family: 'Andika'; src: url(fuentes/andika-latin-700-normal.woff2) format('woff2'); font-weight: 700; font-display: swap; }
:root {
  --pizarra: #4C5273; --marino: #1C618C; --teal: #3290A6; --gris: #E6E6E6; --claro: #F2F2F2;
  --tinta: #2B3050; --suave: #6B7090; --linea: #DCDFE8; --fondo: #F2F3F6;
  --titulo: 'Nixie One', 'Andika', system-ui, sans-serif;
  --mono: 'Roboto Mono', ui-monospace, monospace;
  --texto: 'Andika', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --radio: 12px; --alto-cabecera: 60px;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--fondo); color: var(--tinta); font: 15px/1.55 var(--texto); }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3 { margin: 0; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid var(--teal); outline-offset: 2px; }
.saltar { position: absolute; left: 12px; top: -60px; background: var(--marino); color: #fff; padding: 8px 14px; border-radius: 8px; z-index: 50; }
.saltar:focus { top: 12px; }
.eyebrow { font: 500 11px/1.4 var(--mono); letter-spacing: .14em; text-transform: uppercase; color: var(--teal); margin: 0 0 6px; }
.nota { color: var(--suave); font-size: 13px; margin: 6px 0 14px; }
.cabecera { height: var(--alto-cabecera); display: flex; align-items: center; gap: 14px; padding: 0 18px; background: #fff; border-bottom: 1px solid var(--linea); }
.marca { display: block; flex-shrink: 0; }
.marca img { display: block; width: 150px; height: auto; } 
.cabecera h1 { font: 400 28px/1 var(--titulo); color: var(--pizarra); }
.marca-demo { font: 500 10px var(--mono); letter-spacing: .1em; text-transform: uppercase; background: #F1ECF7; color: #5B4685; border-radius: 6px; padding: 3px 7px; }
.cabecera-derecha { margin-left: auto; display: flex; align-items: center; gap: 16px; }
.directo { display: inline-flex; align-items: center; gap: 7px; font: 500 11px var(--mono); letter-spacing: .1em; text-transform: uppercase; color: var(--teal); }
.directo i { width: 9px; height: 9px; border-radius: 50%; background: var(--teal); box-shadow: 0 0 0 0 rgba(50, 144, 166, .5); animation: latido 2s infinite; }
.directo.caido { color: #9AA0B4; }
.directo.caido i { background: #9AA0B4; animation: none; }
@keyframes latido { 70% { box-shadow: 0 0 0 7px rgba(50, 144, 166, 0); } 100% { box-shadow: 0 0 0 0 rgba(50, 144, 166, 0); } }
.reloj { display: flex; align-items: baseline; gap: 5px; }
.reloj strong { font: 500 22px/1 var(--mono); color: var(--pizarra); }
.reloj small { font: 400 11px var(--mono); color: var(--suave); }
.fase { display: inline-flex; align-items: center; gap: 6px; font: 500 11px var(--mono); letter-spacing: .08em; text-transform: uppercase; padding: 4px 10px; border-radius: 999px; background: #FFF4D6; color: #8A5A0E; transition: background .8s, color .8s; }
.fase i { font-style: normal; font-size: 13px; line-height: 1; }
.fase-amanecer, .fase-atardecer { background: #FDE3CF; color: #9C4A22; }
.fase-noche { background: #1B2A57; color: #DCE5FF; }
.zona-oficina { display: grid; grid-template-columns: minmax(0, 1fr) 320px; height: calc(100vh - var(--alto-cabecera)); height: calc(100dvh - var(--alto-cabecera)); }
.escenario { position: relative; overflow: hidden; background: #E9EEF4; min-height: 0; }
.escenario:focus-visible { outline-offset: -3px; }
.plano { display: block; width: 100%; height: 100%; touch-action: none; user-select: none; -webkit-user-select: none; cursor: grab; }
.plano.arrastrando { cursor: grabbing; }
.capa-luz { mix-blend-mode: multiply; pointer-events: none; }
.capa-brillos { mix-blend-mode: screen; pointer-events: none; }
.capa-paredes, .capa-suelo { pointer-events: none; }
.cristal polygon { fill: rgba(50, 144, 166, .10); stroke: rgba(28, 97, 140, .32); stroke-width: 1; }
.cristal .riel { stroke: #fff; stroke-width: 2.4; fill: none; }
.cristal.opaco polygon { fill: rgba(76, 82, 115, .32); stroke: rgba(28, 97, 140, .7); }
.cristal.opaco .riel { stroke: #1C618C; stroke-width: 3; }
.capa-placas { pointer-events: none; }
.placa rect { fill: rgba(255, 255, 255, .94); stroke: #C9CCD8; stroke-width: 1; }
.placa text { font: 500 9.5px var(--mono); letter-spacing: .1em; fill: var(--pizarra); }
.placa-sala rect { fill: #F1ECF7; stroke: #C9B8E0; }
.placa-dani rect { fill: #1C618C; stroke: #fff; }
.placa-dani text { fill: #fff; }
.capa-lazos { pointer-events: none; }
.lazo { stroke: #3290A6; stroke-width: 2; stroke-dasharray: 5 5; opacity: 0; transition: opacity .6s; animation: lazo 1.2s linear infinite; }
@keyframes lazo { to { stroke-dashoffset: -10; } }
.hud .con { opacity: 0; transition: opacity .4s; }
.hud .con.visible { opacity: 1; }
.hud .con rect { fill: #3290A6; }
.hud .con text { font: 700 8.5px var(--texto); fill: #fff; }
.burbuja.comun rect { stroke: #7B5EA7; stroke-width: 1.6; fill: #F7F3FC; }
.burbuja.comun .cola { fill: #F7F3FC; }
.fila-con { width: 100%; font-size: 11px; color: #7B5EA7; font-weight: 700; }
.rotulo-sala { font: 500 12px var(--mono); letter-spacing: .08em; fill: var(--pizarra); opacity: .72; }
.personaje, .hud { transition: opacity .35s; }
.mesa { cursor: pointer; }
.mesa:hover polygon { filter: brightness(1.06); }
.sombra { fill: rgba(28, 33, 60, .22); }
.led { animation: led 2.4s infinite; }
.led-b { animation-delay: 1.1s; }
@keyframes led { 50% { opacity: .25; } }
.hud { cursor: pointer; outline: none; }
.hud .anillo { fill: none; stroke: var(--teal); stroke-width: 3; opacity: 0; }
.hud:focus-visible .anillo, .hud.destacado .anillo { opacity: 1; }
.hud .nombre { transition: opacity .3s; }
.hud .nombre rect { fill: #fff; stroke: var(--teal); stroke-width: 1.2; }
.hud .nombre text { font: 700 10px var(--texto); fill: var(--marino); }
.hud-persona .nombre rect { fill: var(--pizarra); stroke: #fff; }
.hud-persona .nombre text { fill: #fff; }
.hud.en-pausa .nombre rect { stroke: #B7BCCB; }
.hud.en-pausa .nombre text { fill: var(--suave); }
.hud-persona.en-pausa .nombre rect { fill: #7A7F99; }
.hud-persona.en-pausa .nombre text { fill: #fff; }
.vapor { animation: vapor 2.6s ease-in-out infinite; }
@keyframes vapor { 0%, 100% { opacity: .2; transform: translateY(0); } 50% { opacity: .9; transform: translateY(-1px); } }
.hud .estado { filter: drop-shadow(0 1px 1px rgba(0, 0, 0, .2)); }
.capa-halos { pointer-events: none; }
.luz-mesa { transition: opacity 1s ease; }
.pantalla { transition: fill .6s; }
.pantalla.encendida { animation: pantalla 3.2s ease-in-out infinite; }
@keyframes pantalla { 50% { opacity: .8; } }
.estrella { animation: titila 3.4s ease-in-out infinite; animation-delay: var(--d, 0s); }
@keyframes titila { 50% { opacity: .3; } }
.personaje .respira { transform-box: fill-box; transform-origin: 50% 100%; animation: respirar 4.2s ease-in-out infinite; animation-delay: var(--d, 0s); }
@keyframes respirar { 50% { transform: scaleY(1.02); } }
.personaje .cabeza { transform-box: fill-box; transform-origin: 50% 90%; animation: cabeza 9s ease-in-out infinite; animation-delay: var(--d, 0s); }
@keyframes cabeza { 0%, 60%, 100% { transform: rotate(0); } 66%, 74% { transform: rotate(-7deg); } 82%, 90% { transform: rotate(6deg); } }
.personaje.andando .respira, .personaje.andando .cabeza { animation: none; }
.personaje.tecleando .bi { animation: teclear .36s ease-in-out infinite alternate; }
.personaje.tecleando .bd { animation: teclear .36s ease-in-out infinite alternate-reverse; }
@keyframes teclear { to { transform: translateY(-2px); } }
.personaje.disponible .bi { transform-box: fill-box; transform-origin: 50% 0; animation: sorbo 8s ease-in-out infinite; animation-delay: var(--d, 0s); }
@keyframes sorbo { 0%, 70%, 100% { transform: none; } 77%, 88% { transform: translate(2.5px, -6px) rotate(-20deg); } }
.hojas { transform-box: fill-box; transform-origin: 50% 100%; animation: mecer 6s ease-in-out infinite; animation-delay: var(--d, 0s); }
.palmera { transform-box: fill-box; transform-origin: 70% 100%; animation: mecer 7s ease-in-out infinite; }
@keyframes mecer { 50% { transform: rotate(1.8deg); } }
.gira { transform-box: fill-box; transform-origin: center; animation: girar 3.5s linear infinite; }
@keyframes girar { to { transform: rotate(360deg); } }
.pausado *, .pausado *::before, .pausado *::after { animation-play-state: paused !important; }
.teclea circle { fill: var(--teal); animation: teclea 1.2s infinite; }
.teclea circle:nth-child(2) { animation-delay: .2s; }
.teclea circle:nth-child(3) { animation-delay: .4s; }
@keyframes teclea { 50% { opacity: .2; } }
.burbuja { opacity: 0; transition: opacity .3s; pointer-events: none; }
.burbuja.visible { opacity: 1; }
.burbuja rect, .burbuja .cola { fill: #fff; stroke: #C9CCD8; stroke-width: 1; }
.burbuja .cola { stroke: none; }
.burbuja text { font: 400 11px var(--texto); fill: var(--tinta); }
.hud.destacado .burbuja rect { stroke: var(--teal); stroke-width: 1.6; }
.zoom { position: absolute; right: 12px; top: 12px; display: flex; flex-direction: column; gap: 6px; }
.zoom button { width: 40px; height: 40px; border-radius: 10px; border: 1px solid var(--linea); background: rgba(255, 255, 255, .92); font-size: 20px; line-height: 1; cursor: pointer; color: var(--pizarra); }
.zoom button:hover { color: var(--marino); border-color: var(--teal); }
.leyenda { position: absolute; left: 12px; bottom: 12px; display: flex; flex-wrap: wrap; gap: 6px 14px; align-items: center; background: rgba(255, 255, 255, .9); border: 1px solid var(--linea); border-radius: 10px; padding: 7px 12px; font-size: 12px; max-width: calc(100% - 76px); }
.leyenda span { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; }
.leyenda .sep { border-left: 1px solid var(--linea); padding-left: 12px; }
.punto { display: inline-block; width: 10px; height: 10px; border-radius: 50%; flex: none; }
.forma { display: inline-block; width: 12px; height: 12px; border: 2px solid var(--pizarra); }
.forma.circ { border-radius: 50%; }
.forma.hex { border: 0; background: var(--teal); clip-path: polygon(50% 0, 100% 25%, 100% 75%, 50% 100%, 0 75%, 0 25%); }
.aviso { position: absolute; left: 50%; top: 12px; transform: translateX(-50%); background: rgba(28, 33, 60, .85); color: #fff; padding: 7px 14px; border-radius: 999px; font-size: 13px; margin: 0; max-width: calc(100% - 80px); text-align: center; }
.ir-equipo { display: none; }
.panel-equipo { background: #fff; border-left: 1px solid var(--linea); padding: 16px; overflow: auto; min-height: 0; }
.panel-equipo h2 { font: 400 24px var(--titulo); color: var(--pizarra); }
.cuentas { list-style: none; display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; padding: 0; margin: 12px 0; font-size: 11px; color: var(--suave); }
.cuentas li { background: var(--claro); border-radius: 8px; padding: 6px 8px; line-height: 1.3; }
.cuentas b { display: block; font: 500 18px var(--mono); color: var(--pizarra); }
.lista-equipo { list-style: none; margin: 0; padding: 0; }
.grupo-estado { display: flex; align-items: center; gap: 7px; font: 500 11px var(--mono); letter-spacing: .1em; text-transform: uppercase; color: var(--suave); margin: 14px 0 4px; }
.grupo-estado small { letter-spacing: 0; }
.fila-miembro { display: flex; gap: 10px; width: 100%; text-align: left; border: 0; background: none; border-radius: 10px; padding: 7px 6px; cursor: pointer; align-items: flex-start; }
.fila-miembro:hover { background: var(--claro); }
.retrato { display: inline-flex; flex: none; }
.retrato svg { display: block; overflow: visible; }
.fila-texto { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 6px; min-width: 0; }
.fila-texto b { font-size: 14px; }
.fila-texto small { width: 100%; color: var(--suave); font-size: 12px; line-height: 1.3; }
.fila-tarea { width: 100%; font-size: 12px; color: var(--marino); line-height: 1.35; overflow-wrap: anywhere; }
.etiqueta-tipo { font: 500 9px var(--mono); letter-spacing: .08em; text-transform: uppercase; border-radius: 4px; padding: 1px 5px; }
.etiqueta-tipo.persona { background: var(--pizarra); color: #fff; }
.etiqueta-tipo.agente { border: 1px solid var(--teal); color: var(--teal); }
.boton { border: 1px solid var(--linea); background: #fff; border-radius: 999px; padding: 8px 16px; min-height: 40px; cursor: pointer; font-weight: 700; color: var(--pizarra); }
.boton.primario { background: var(--marino); border-color: var(--marino); color: #fff; }
.boton.primario:hover { background: var(--teal); border-color: var(--teal); }
.cerrar { border: 0; background: var(--claro); width: 36px; height: 36px; border-radius: 50%; font-size: 22px; line-height: 1; cursor: pointer; color: var(--pizarra); flex: none; }
.cerrar:hover { background: var(--gris); }
.ficha { margin: 0 0 0 auto; height: 100%; max-height: 100%; max-width: 100%; width: min(480px, 100%); border: 0; padding: 0; background: #fff; color: var(--tinta); box-shadow: -10px 0 40px rgba(28, 33, 60, .2); display: none; flex-direction: column; }
.ficha[open] { display: flex; }
.ficha::backdrop { background: rgba(28, 33, 60, .35); }
.ficha-cabecera { display: flex; gap: 14px; padding: 20px 20px 12px; align-items: flex-start; background: linear-gradient(180deg, #F2F5F9, #fff); }
.ficha-avatar { flex: none; width: 72px; height: 72px; border-radius: 16px; background: #fff; border: 1px solid var(--linea); display: grid; place-items: center; }
.ficha-quien { flex: 1; min-width: 0; }
.ficha-quien h2 { font: 400 32px/1.05 var(--titulo); color: var(--pizarra); }
.ficha .eyebrow.persona { color: var(--pizarra); }
.ficha-funcion { margin: 4px 0; color: var(--suave); font-size: 14px; }
.ficha-estado { display: flex; gap: 7px; align-items: baseline; font-size: 13px; margin: 0; color: var(--marino); overflow-wrap: anywhere; }
.pestanas { display: flex; gap: 4px; padding: 0 16px; border-bottom: 1px solid var(--linea); }
.pestanas [role=tab] { border: 0; background: none; padding: 12px 12px 10px; cursor: pointer; font-weight: 700; color: var(--suave); border-bottom: 3px solid transparent; }
.pestanas [aria-selected=true] { color: var(--marino); border-bottom-color: var(--teal); }
.ficha-cuerpo { overflow: auto; padding: 16px 20px 28px; flex: 1; }
.aporta { background: #F2F6F9; border-radius: 10px; padding: 12px 14px; margin-bottom: 12px; }
.aporta-texto { font-weight: 700; margin: 0 0 4px; }
.aporta p { margin: 0; }
.bloque { padding: 12px 0; border-top: 1px solid var(--claro); }
.bloque h3 { font: 500 11px/1.4 var(--mono); letter-spacing: .12em; text-transform: uppercase; color: var(--teal); margin-bottom: 8px; }
.bloque p { margin: 6px 0 0; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { border: 1px solid var(--linea); border-radius: 999px; padding: 3px 10px; font-size: 12px; background: #fff; }
.chip-teal { background: rgba(50, 144, 166, .1); border-color: transparent; color: var(--marino); }
.lista-puntos { margin: 0; padding-left: 18px; }
.lista-puntos li { margin: 3px 0; }
.socios { display: flex; flex-wrap: wrap; gap: 6px; }
.socio { display: inline-flex; gap: 4px; align-items: center; border: 1px solid var(--linea); background: #fff; border-radius: 999px; padding: 2px 12px 2px 4px; cursor: pointer; font-size: 13px; min-height: 36px; }
.socio:hover { border-color: var(--teal); }
.lista-horario { list-style: none; padding: 0; margin: 0; }
.lista-horario li { display: grid; gap: 1px; padding: 5px 0; }
.lista-horario b { font: 500 12px var(--mono); color: var(--marino); }
.preguntas { display: grid; gap: 6px; }
.pregunta { text-align: left; border: 1px solid var(--linea); background: #fff; border-radius: 10px; padding: 10px 12px; cursor: pointer; }
.pregunta:hover { border-color: var(--teal); }
.entregables { list-style: none; padding: 0; margin: 0; }
.entregables li { display: flex; gap: 10px; padding: 10px 0; border-top: 1px solid var(--claro); }
.ent-icono { width: 30px; height: 36px; flex: none; border-radius: 5px; background: linear-gradient(135deg, var(--teal), var(--marino)); clip-path: polygon(0 0, 70% 0, 100% 25%, 100% 100%, 0 100%); }
.entregables b { display: block; overflow-wrap: anywhere; }
.entregables a { color: var(--marino); }
.entregables small { color: var(--suave); font-size: 12px; }
.cargando, .aviso-texto { color: var(--suave); }
.chat-vacio { text-align: center; padding: 30px 10px; color: var(--suave); }
.chat-vacio h3 { font: 400 26px var(--titulo); color: var(--pizarra); margin-bottom: 8px; }
.nota.demo { background: #F1ECF7; color: #5B4685; padding: 6px 10px; border-radius: 8px; }
.mensajes { list-style: none; padding: 0; margin: 0 0 8px; max-height: 50vh; overflow: auto; display: flex; flex-direction: column; gap: 8px; }
.msg { max-width: 86%; padding: 8px 12px; border-radius: 12px; }
.msg p { margin: 2px 0; white-space: pre-wrap; overflow-wrap: anywhere; }
.msg.de-agente { background: var(--claro); align-self: flex-start; border-bottom-left-radius: 4px; }
.msg.mio { background: var(--marino); color: #fff; align-self: flex-end; border-bottom-right-radius: 4px; }
.msg-autor { font: 500 10px var(--mono); letter-spacing: .08em; text-transform: uppercase; opacity: .8; }
.msg time { font-size: 10px; opacity: .7; }
.chat-sin { color: var(--suave); text-align: center; }
.chat-estado { font-size: 12px; color: var(--suave); min-height: 1.4em; margin: 0 0 6px; }
.chat-form { display: flex; gap: 8px; align-items: flex-end; }
.ficha-cuerpo.en-chat { display: flex; flex-direction: column; overflow: hidden; padding-bottom: 16px; }
.ficha-cuerpo.en-chat #panel-chat { display: flex; flex-direction: column; flex: 1; min-height: 0; }
.ficha-cuerpo.en-chat .mensajes { flex: 1; max-height: none; min-height: 120px; }
.chat-intro { font-size: 12px; color: var(--suave); margin: 0 0 8px; }
.msg.escribiendo { padding: 10px 12px; }
.msg.en-servidor { background: transparent; border: 1px dashed #9AA0B4; font-style: italic; }
.puntos { display: inline-flex; gap: 4px; }
.puntos i { width: 6px; height: 6px; border-radius: 50%; background: #9AA0B4; animation: teclea 1.2s infinite; }
.puntos i:nth-child(2) { animation-delay: .2s; }
.puntos i:nth-child(3) { animation-delay: .4s; }
.estado-persona { display: flex; gap: 12px; align-items: flex-start; background: #F2F6F9; border-radius: 12px; padding: 16px; }
.estado-persona b { font-size: 17px; }
.estado-persona p { margin: 4px 0 0; color: var(--marino); }
.punto.grande { width: 14px; height: 14px; margin-top: 6px; }
.chat-form textarea { flex: 1; resize: vertical; border: 1px solid var(--linea); border-radius: 8px; background: #fff; padding: 8px 10px; min-height: 40px; }
.error-carga { max-width: 760px; margin: 40px auto; background: #fff; border: 1px solid var(--linea); border-left: 4px solid #C0392B; border-radius: var(--radio); padding: 20px 24px; }
.error-carga h2 { font: 400 28px var(--titulo); color: var(--pizarra); }
.sin-datos main { display: none; }
@media (max-width: 760px) {
  :root { --alto-cabecera: 54px; }
  .cabecera { padding: 0 12px; gap: 10px; }
  .marca img { width: 48px; } 
  .cabecera h1 { font-size: 21px; white-space: nowrap; }
  .marca-demo { font-size: 9px; padding: 2px 5px; white-space: nowrap; }
  .cabecera-derecha { gap: 10px; }
  .directo { font-size: 10px; letter-spacing: .04em; white-space: nowrap; }
  .reloj strong { font-size: 18px; }
  .reloj small { display: none; }
  .cabecera-derecha .fase { font-size: 10px; }
  .zona-oficina { display: block; height: auto; }
  .escenario { height: calc(100vh - var(--alto-cabecera) - 64px); height: calc(100dvh - var(--alto-cabecera) - 64px); min-height: 380px; }
  .leyenda { font-size: 11px; padding: 6px 8px; gap: 4px 10px; }
  .leyenda .sep { border: 0; padding: 0; }
  .panel-equipo { border-left: 0; border-top: 1px solid var(--linea); scroll-margin-top: 0; }
  .ir-equipo { display: block; position: absolute; right: 12px; bottom: 12px; border: 0; border-radius: 999px; background: var(--marino); color: #fff; font-weight: 700; padding: 9px 14px; min-height: 40px; cursor: pointer; box-shadow: 0 4px 14px rgba(28, 33, 60, .25); }
  .leyenda { max-width: calc(100% - 150px); }
  .ficha { width: 100%; }
  .ficha-quien h2 { font-size: 26px; }
}
@media (max-width: 420px) {
  .cabecera { gap: 8px; }
  .cabecera h1 { font-size: 19px; }
  .directo span, .fase span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  .fase { padding: 4px 7px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
