/* ============================================================
   Zytaia · Demo asesores — estilos
   Base clara con tinte violeta (tokens de la landing de Zytaia).
   ============================================================ */
:root {
  --bg: oklch(0.981 0.006 290);
  --bg-2: oklch(0.965 0.009 290);
  --surface: #ffffff;
  --ink: oklch(0.23 0.028 288);
  --ink-soft: oklch(0.44 0.022 288);
  --ink-mute: oklch(0.58 0.016 288);
  --line: oklch(0.91 0.008 290);
  --line-strong: oklch(0.86 0.012 290);

  --brand: oklch(0.55 0.225 296);
  --brand-deep: oklch(0.43 0.2 293);
  --brand-bright: oklch(0.68 0.205 300);
  --brand-ghost: oklch(0.95 0.03 296);
  --brand-soft: oklch(0.9 0.06 296);

  --amber: oklch(0.8 0.142 72);
  --amber-ink: oklch(0.5 0.13 60);
  --amber-soft: oklch(0.96 0.05 80);
  --green: oklch(0.72 0.17 150);
  --green-ink: oklch(0.45 0.13 150);
  --green-soft: oklch(0.95 0.05 150);
  --coral: oklch(0.72 0.16 28);
  --slate: oklch(0.6 0.02 260);
  --slate-soft: oklch(0.94 0.01 260);

  --wa: #25d366;
  --wa-ink: #128c4a;
  --ig-a: #f58529; --ig-b: #dd2a7b; --ig-c: #8134af;
  --fb: #0084ff;
  --mail: oklch(0.55 0.08 250);

  --font-display: 'Space Grotesk', system-ui, -apple-system, sans-serif;
  --font-body: 'Inter', system-ui, -apple-system, sans-serif;

  --r-sm: 10px; --r-md: 16px; --r-lg: 24px;
  --shadow-sm: 0 1px 2px oklch(0.3 0.05 290 / 0.06), 0 2px 8px oklch(0.3 0.05 290 / 0.05);
  --shadow-md: 0 4px 16px oklch(0.3 0.05 290 / 0.08), 0 12px 32px oklch(0.3 0.05 290 / 0.06);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow: hidden;
}
button { font: inherit; color: inherit; cursor: pointer; background: none; border: 0; }
h1, h2, h3, h4 { font-family: var(--font-display); margin: 0; letter-spacing: -0.01em; }

/* ---------- Estructura general ---------- */
.app {
  height: 100dvh;
  display: grid;
  grid-template-rows: auto 1fr auto;
  max-width: 1600px;
  margin: 0 auto;
}

/* Barra superior */
.top {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 16px;
  padding: 14px 24px 8px;
}
.brand { display: flex; align-items: center; gap: 10px; font-family: var(--font-display); font-weight: 600; font-size: 18px; }
.brand-dot {
  width: 22px; height: 22px; border-radius: 50%;
  background:
    radial-gradient(circle at 30% 28%, #fff 0, rgba(255,255,255,.85) 8%, transparent 30%),
    radial-gradient(circle at 60% 70%, var(--brand-bright), var(--brand) 55%, var(--brand-deep) 100%);
  box-shadow: 0 2px 8px oklch(0.55 0.225 296 / 0.45);
}
.brand small { font-weight: 500; color: var(--ink-mute); font-size: 12px; margin-left: 4px; }

.asesor-chip {
  display: flex; align-items: center; gap: 12px;
  padding: 6px 16px 6px 6px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 999px;
  box-shadow: var(--shadow-sm);
  transition: opacity .4s var(--ease);
}
.asesor-chip img { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; background: var(--brand-ghost); }
.asesor-chip .n { font-weight: 600; font-size: 14px; line-height: 1.2; }
.asesor-chip .r { color: var(--ink-mute); font-size: 12px; }

.top-right { display: flex; justify-content: flex-end; align-items: center; gap: 8px; }
.hora {
  font-family: var(--font-display); font-weight: 600; font-size: 15px;
  padding: 6px 12px; border-radius: 999px; background: var(--brand-ghost); color: var(--brand-deep);
  min-width: 70px; text-align: center;
}
.icon-btn {
  width: 38px; height: 38px; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--surface); border: 1px solid var(--line);
  color: var(--ink-soft);
  transition: all .2s var(--ease);
}
.icon-btn:hover { border-color: var(--brand-soft); color: var(--brand); }
.icon-btn svg { width: 18px; height: 18px; }
.icon-btn.on { background: var(--brand); color: #fff; border-color: var(--brand); }

/* ---------- Escenario ---------- */
.stage {
  display: grid;
  grid-template-columns: minmax(300px, 0.9fr) minmax(320px, 1fr) minmax(340px, 1.05fr);
  gap: 20px;
  padding: 8px 24px 12px;
  min-height: 0;
}
.col { min-height: 0; display: flex; flex-direction: column; gap: 12px; }
.col-title {
  display: flex; align-items: center; justify-content: space-between;
  font-family: var(--font-display); font-size: 12px; font-weight: 600;
  letter-spacing: .08em; text-transform: uppercase; color: var(--ink-mute);
  padding: 0 4px;
}
.col-title .count { font-weight: 500; letter-spacing: 0; text-transform: none; }

/* --- Columna del avatar --- */
.col-avatar { align-items: center; justify-content: center; text-align: center; gap: 18px; position: relative; }
.scene-tag {
  font-family: var(--font-display); font-weight: 600; font-size: 13px; color: var(--brand-deep);
  background: var(--brand-ghost); padding: 6px 14px; border-radius: 999px;
}
.scene-sub { color: var(--ink-mute); font-size: 13px; margin-top: -10px; }

.orb-wrap { position: relative; width: min(260px, 46vw); aspect-ratio: 1; display: grid; place-items: center; }
.orb {
  position: relative; width: 78%; aspect-ratio: 1; border-radius: 50%;
  background:
    radial-gradient(circle at 32% 26%, rgba(255,255,255,.98) 0, rgba(255,255,255,.75) 10%, rgba(255,255,255,0) 32%),
    radial-gradient(circle at 70% 78%, oklch(0.75 0.19 300 / .9) 0, transparent 45%),
    radial-gradient(circle at 50% 50%, oklch(0.7 0.2 298) 0%, oklch(0.58 0.23 296) 60%, oklch(0.42 0.2 292) 100%);
  box-shadow:
    inset 0 -18px 40px oklch(0.4 0.2 292 / .55),
    inset 0 10px 30px rgba(255,255,255,.35),
    0 24px 60px oklch(0.55 0.225 296 / .35),
    0 6px 18px oklch(0.55 0.225 296 / .25);
  animation: breathe 5.5s ease-in-out infinite;
  transition: transform .5s var(--ease), filter .5s var(--ease);
}
.orb::after {
  content: ''; position: absolute; inset: 0; border-radius: 50%;
  background: radial-gradient(circle at 50% 118%, rgba(255,255,255,.5), transparent 45%);
}
.orb-ring {
  position: absolute; inset: 0; border-radius: 50%;
  border: 1.5px solid oklch(0.55 0.225 296 / .0);
  transform: scale(.8);
  pointer-events: none;
}
.orb-wrap.hablando .orb { animation: breathe 2.2s ease-in-out infinite; }
.orb-wrap.hablando .orb-ring { animation: ripple 2.4s ease-out infinite; }
.orb-wrap.hablando .orb-ring.r2 { animation-delay: .8s; }
.orb-wrap.hablando .orb-ring.r3 { animation-delay: 1.6s; }
.orb-wrap.escuchando .orb { filter: saturate(.7) brightness(1.03); }
.orb-wrap.escuchando .orb-ring { animation: ripple-in 1.6s ease-in infinite; border-color: oklch(0.72 0.16 28 / .5); }
.orb-wrap.atencion .orb { box-shadow: inset 0 -18px 40px oklch(0.4 0.2 292 / .55), inset 0 10px 30px rgba(255,255,255,.35), 0 24px 60px oklch(0.8 0.142 72 / .45), 0 6px 18px oklch(0.8 0.142 72 / .3); }

@keyframes breathe { 0%,100% { transform: scale(1); } 50% { transform: scale(1.035); } }
@keyframes ripple { 0% { transform: scale(.8); border-color: oklch(0.55 0.225 296 / .55); } 100% { transform: scale(1.18); border-color: oklch(0.55 0.225 296 / 0); } }
@keyframes ripple-in { 0% { transform: scale(1.18); opacity: 0; } 40% { opacity: 1; } 100% { transform: scale(.82); opacity: 0; } }

.wave { display: flex; gap: 4px; align-items: center; height: 26px; justify-content: center; opacity: 0; transition: opacity .3s; }
.orb-wrap.hablando ~ .wave, .wave.on { opacity: 1; }
.wave i { display: block; width: 4px; height: 6px; border-radius: 2px; background: var(--brand); animation: wave 1s ease-in-out infinite; }
.wave i:nth-child(2) { animation-delay: .1s; } .wave i:nth-child(3) { animation-delay: .2s; } .wave i:nth-child(4) { animation-delay: .3s; }
.wave i:nth-child(5) { animation-delay: .4s; } .wave i:nth-child(6) { animation-delay: .5s; } .wave i:nth-child(7) { animation-delay: .6s; }
@keyframes wave { 0%,100% { height: 5px; opacity: .5; } 50% { height: 22px; opacity: 1; } }

.caption {
  width: 100%; max-width: 420px;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg);
  padding: 18px 22px; box-shadow: var(--shadow-md);
  font-size: 17px; line-height: 1.5; text-align: left; position: relative;
  min-height: 92px;
  transition: opacity .35s var(--ease), transform .35s var(--ease);
}
.caption.fade { opacity: 0; transform: translateY(6px); }
.caption .who { font-family: var(--font-display); font-size: 11px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--brand); margin-bottom: 6px; display: flex; align-items: center; gap: 6px; }
.caption .who::before { content: ''; width: 8px; height: 8px; border-radius: 50%; background: var(--brand); box-shadow: 0 0 0 3px var(--brand-ghost); }

/* Comando de voz del asesor */
.command {
  width: 100%; max-width: 420px;
  border-radius: var(--r-lg); padding: 16px 18px; text-align: left;
  background: linear-gradient(135deg, oklch(0.27 0.06 290), oklch(0.2 0.05 290));
  color: #fff; box-shadow: var(--shadow-md);
  display: none; position: relative; overflow: hidden;
}
.command.on { display: block; animation: rise .5s var(--ease); }
.command .head { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.command .mic {
  width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center;
  background: var(--coral); box-shadow: 0 0 0 0 oklch(0.72 0.16 28 / .6);
}
.command.grabando .mic { animation: micpulse 1.2s ease-out infinite; }
@keyframes micpulse { 0% { box-shadow: 0 0 0 0 oklch(0.72 0.16 28 / .6); } 100% { box-shadow: 0 0 0 14px oklch(0.72 0.16 28 / 0); } }
.command .mic svg { width: 16px; height: 16px; }
.command .who { font-family: var(--font-display); font-size: 12px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; opacity: .8; }
.command .who b { color: #fff; opacity: 1; }
.command .text { font-size: 16px; line-height: 1.5; min-height: 48px; }
.command .text .cursor { display: inline-block; width: 2px; height: 1em; background: #fff; vertical-align: -2px; margin-left: 2px; animation: blink .9s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }

/* Botón para "dictar" manualmente (se muestra en pausa en escenas de comando) */
.dictar-btn {
  display: none; margin-top: 4px;
  padding: 10px 18px; border-radius: 999px; background: var(--brand); color: #fff; font-weight: 600;
  box-shadow: 0 8px 20px oklch(0.55 0.225 296 / .35);
}
.dictar-btn.on { display: inline-flex; align-items: center; gap: 8px; animation: rise .4s var(--ease); }
.dictar-btn svg { width: 18px; height: 18px; flex: none; }

/* --- Columna del flujo --- */
.flow {
  flex: 1; min-height: 0; overflow-y: auto; padding: 4px 4px 24px; scroll-behavior: smooth;
  mask-image: linear-gradient(to bottom, #000 calc(100% - 40px), transparent);
}
.flow::-webkit-scrollbar, .detail::-webkit-scrollbar { width: 0; }
.step {
  display: grid; grid-template-columns: 40px 1fr; gap: 12px; position: relative;
  padding: 0 0 18px;
  opacity: 0; transform: translateY(14px);
  animation: rise .55s var(--ease) forwards;
}
.step::before {
  content: ''; position: absolute; left: 19px; top: 40px; bottom: 0; width: 2px;
  background: var(--line-strong);
}
.step:last-child::before { display: none; }
.step .ic {
  width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center;
  background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-sm);
  color: var(--brand); position: relative; z-index: 1;
}
.step .ic svg { width: 18px; height: 18px; }
.step .ic.whatsapp { background: var(--wa); color: #fff; border-color: transparent; }
.step .ic.instagram { background: linear-gradient(135deg, var(--ig-a), var(--ig-b) 55%, var(--ig-c)); color: #fff; border-color: transparent; }
.step .ic.messenger { background: var(--fb); color: #fff; border-color: transparent; }
.step .ic.correo { background: var(--mail); color: #fff; border-color: transparent; }
.step .ic.atencion { background: var(--amber-soft); color: var(--amber-ink); border-color: oklch(0.85 0.1 75); }
.step .ic.detenido { background: var(--slate-soft); color: var(--slate); }
.step .card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md);
  padding: 12px 14px; box-shadow: var(--shadow-sm);
}
.step.atencion .card { border-color: oklch(0.85 0.1 75); background: linear-gradient(0deg, var(--amber-soft), #fff 70%); }
.step .row { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.step .t { font-weight: 600; font-size: 14px; line-height: 1.3; }
.step .d { color: var(--ink-soft); font-size: 13px; margin-top: 3px; }
.step .meta { display: flex; align-items: center; gap: 8px; margin-top: 8px; }
.step .h { font-size: 11px; color: var(--ink-mute); font-variant-numeric: tabular-nums; }
.pill {
  display: inline-flex; align-items: center; gap: 5px;
  font-size: 11px; font-weight: 600; padding: 3px 9px; border-radius: 999px; letter-spacing: .02em;
}
.pill svg { width: 11px; height: 11px; }
.pill.hecho { background: var(--green-soft); color: var(--green-ink); }
.pill.programado { background: var(--brand-ghost); color: var(--brand-deep); }
.pill.atencion { background: var(--amber-soft); color: var(--amber-ink); }
.pill.detenido { background: var(--slate-soft); color: var(--slate); }

@keyframes rise { to { opacity: 1; transform: none; } }

/* --- Columna del detalle --- */
.detail { flex: 1; min-height: 0; overflow-y: auto; padding: 4px 4px 24px; display: flex; flex-direction: column; gap: 14px; scroll-behavior: smooth; }
.art {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg);
  box-shadow: var(--shadow-md); overflow: hidden;
  opacity: 0; transform: translateY(16px) scale(.98);
  animation: rise .6s var(--ease) forwards;
}
.art .ah {
  display: flex; align-items: center; gap: 10px; padding: 12px 16px;
  border-bottom: 1px solid var(--line); font-family: var(--font-display); font-weight: 600; font-size: 13px;
}
.art .ah > svg { width: 16px; height: 16px; color: var(--brand); flex: none; }
.art .ah .k { margin-left: auto; font-size: 11px; font-weight: 500; color: var(--ink-mute); text-transform: uppercase; letter-spacing: .06em; font-family: var(--font-body); }
.art .ab { padding: 14px 16px; }

/* Chat (teléfono) */
.art.chat .ah img { width: 30px; height: 30px; border-radius: 50%; object-fit: cover; background: var(--brand-ghost); }
.art.chat .ah .ch { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; color: #fff; }
.art.chat .ah .ch svg { width: 12px; height: 12px; }
.ch.whatsapp { background: var(--wa); } .ch.instagram { background: linear-gradient(135deg, var(--ig-a), var(--ig-b) 55%, var(--ig-c)); }
.ch.messenger { background: var(--fb); } .ch.correo { background: var(--mail); }
.art.chat .ab { background: var(--bg-2); display: flex; flex-direction: column; gap: 8px; }
.art.chat.whatsapp .ab { background: #ece5dd; }
.msg { max-width: 86%; padding: 9px 12px; border-radius: 14px; font-size: 13.5px; line-height: 1.4; position: relative; animation: rise .4s var(--ease); }
.msg .h { display: block; font-size: 10px; opacity: .55; margin-top: 4px; text-align: right; }
.msg.ellos { align-self: flex-start; background: #fff; border-bottom-left-radius: 4px; box-shadow: var(--shadow-sm); }
.msg.zytaia { align-self: flex-end; background: var(--brand-ghost); border-bottom-right-radius: 4px; }
.art.chat.whatsapp .msg.zytaia { background: #d9fdd3; }
.art.chat.instagram .msg.zytaia { background: linear-gradient(135deg, oklch(0.94 0.04 340), oklch(0.94 0.04 300)); }
.art.chat.messenger .msg.zytaia { background: var(--fb); color: #fff; }
.art.chat.messenger .msg.zytaia .h { opacity: .8; }
.msg .adj { display: flex; align-items: center; gap: 8px; font-weight: 600; font-size: 12.5px; }
.msg .adj .f { width: 30px; height: 36px; border-radius: 6px; background: #fff; border: 1px solid var(--line); display: grid; place-items: center; color: var(--coral); font-size: 9px; font-weight: 700; }
.msg .zy { font-size: 10px; font-weight: 600; color: var(--brand-deep); letter-spacing: .04em; text-transform: uppercase; display: block; margin-bottom: 3px; }
.art.chat.messenger .msg .zy { color: rgba(255,255,255,.85); }

/* Propiedad */
.art.propiedad .ab { display: grid; grid-template-columns: 96px 1fr; gap: 14px; align-items: start; }
.art.propiedad .ph {
  width: 96px; height: 96px; border-radius: var(--r-md);
  background: linear-gradient(160deg, oklch(0.85 0.06 250), oklch(0.7 0.08 260) 60%, oklch(0.5 0.08 270)); position: relative; overflow: hidden;
}
.art.propiedad .ph::after { content: ''; position: absolute; left: 14px; right: 14px; bottom: 14px; height: 40%; background: oklch(0.96 0.02 80); clip-path: polygon(0 40%, 50% 0, 100% 40%, 100% 100%, 0 100%); }
.art.propiedad .pn { font-weight: 600; font-size: 15px; }
.art.propiedad .pp { font-family: var(--font-display); font-weight: 700; font-size: 20px; color: var(--brand-deep); margin: 2px 0 6px; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; }
.tag { font-size: 11.5px; padding: 3px 8px; border-radius: 999px; background: var(--bg-2); border: 1px solid var(--line); color: var(--ink-soft); }
.tag.ok { background: var(--green-soft); color: var(--green-ink); border-color: transparent; }

/* Contacto */
.art.contacto .ah img { width: 34px; height: 34px; border-radius: 50%; object-fit: cover; }
.art.contacto .ah .n { display: flex; flex-direction: column; line-height: 1.2; }
.art.contacto .ah .n small { font-weight: 500; color: var(--brand-deep); font-size: 11px; font-family: var(--font-body); }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 6px 14px; font-size: 13px; }
.kv dt { color: var(--ink-mute); } .kv dd { margin: 0; font-weight: 500; }

/* Secuencia */
.seq { display: flex; flex-direction: column; gap: 0; }
.seq .s { display: grid; grid-template-columns: 30px 1fr; gap: 10px; padding-bottom: 12px; position: relative; }
.seq .s::before { content: ''; position: absolute; left: 14px; top: 30px; bottom: 0; width: 2px; background: var(--line); }
.seq .s:last-child::before { display: none; }
.seq .s .n { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; font-weight: 700; font-size: 12px; background: var(--brand-ghost); color: var(--brand-deep); position: relative; z-index: 1; }
.seq .s.enviado .n { background: var(--green); color: #fff; }
.seq .s.espera .n { background: var(--bg-2); color: var(--ink-mute); border: 1px dashed var(--line-strong); }
.seq .s .w { font-size: 12px; color: var(--ink-mute); display: flex; align-items: center; gap: 8px; }
.seq .s .x { font-size: 13px; margin-top: 3px; color: var(--ink); background: var(--bg-2); padding: 8px 10px; border-radius: 10px; border: 1px solid var(--line); }
.rule { margin-top: 8px; font-size: 12px; color: var(--ink-soft); display: flex; gap: 8px; align-items: flex-start; padding: 8px 10px; background: var(--brand-ghost); border-radius: 10px; }
.rule svg { width: 14px; height: 14px; flex: none; color: var(--brand); margin-top: 1px; }
.chip { display: inline-flex; align-items: center; gap: 4px; font-size: 10.5px; font-weight: 600; padding: 2px 7px; border-radius: 999px; color: #fff; }
.chip svg { width: 10px; height: 10px; }
.chip.whatsapp { background: var(--wa); } .chip.instagram { background: linear-gradient(135deg, var(--ig-a), var(--ig-b) 55%, var(--ig-c)); }
.chip.messenger { background: var(--fb); } .chip.correo { background: var(--mail); }
.chip.cita { background: var(--brand); } .chip.split { background: var(--brand-deep); } .chip.detenido { background: var(--slate); } .chip.excluido { background: var(--slate); }

/* Resumen */
.sum { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.sum .c { padding: 12px 14px; border-radius: var(--r-md); background: var(--bg-2); border: 1px solid var(--line); }
.sum .c.alerta { background: var(--amber-soft); border-color: oklch(0.85 0.1 75); }
.sum .n { font-family: var(--font-display); font-weight: 700; font-size: 26px; line-height: 1; color: var(--brand-deep); }
.sum .c.alerta .n { color: var(--amber-ink); }
.sum .l { font-size: 12px; color: var(--ink-soft); margin-top: 4px; }

/* Cita / fecha / nota / borrador / correo / acciones / lista */
.art.cita .ab, .art.fecha .ab { display: grid; grid-template-columns: 56px 1fr; gap: 14px; align-items: center; }
.datebox { width: 56px; height: 62px; border-radius: 12px; background: var(--brand); color: #fff; display: grid; place-items: center; text-align: center; line-height: 1; padding: 6px 0; }
.datebox b { font-family: var(--font-display); font-size: 22px; display: block; }
.datebox span { font-size: 10px; text-transform: uppercase; letter-spacing: .06em; opacity: .9; }
.art.fecha .datebox { background: var(--amber); color: oklch(0.3 0.08 60); }
.art .big { font-weight: 600; font-size: 15px; }
.art .sub { color: var(--ink-soft); font-size: 13px; margin-top: 2px; }
.art .sub b { color: var(--ink); font-weight: 600; }
.withav { display: flex; align-items: center; gap: 8px; margin-top: 6px; font-size: 13px; }
.withav img { width: 24px; height: 24px; border-radius: 50%; object-fit: cover; }
.note { font-size: 14px; line-height: 1.5; color: var(--ink); }
.art.nota .ab { background: var(--amber-soft); }
.art.borrador .ab, .art.correo .ab { font-size: 13.5px; line-height: 1.5; }
.art.correo .ab .f { display: grid; grid-template-columns: auto 1fr; gap: 4px 10px; font-size: 12.5px; color: var(--ink-soft); padding-bottom: 10px; margin-bottom: 10px; border-bottom: 1px solid var(--line); }
.art.correo .ab .f b { color: var(--ink); font-weight: 500; }
.acts { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.acts li { display: grid; grid-template-columns: 24px 1fr; gap: 10px; font-size: 13.5px; align-items: start; }
.acts li i { width: 24px; height: 24px; border-radius: 50%; background: var(--brand); color: #fff; font-style: normal; font-size: 12px; font-weight: 700; display: grid; place-items: center; }
.lst { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.lst li { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--line); font-size: 13.5px; }
.lst li:last-child { border-bottom: 0; }
.lst li .nm { font-weight: 500; flex: 1; }
.lst li .nt { font-size: 11.5px; color: var(--ink-mute); }
.lst li.excluido .nm { color: var(--ink-mute); text-decoration: line-through; }

/* Semana */
.week { display: grid; gap: 8px; }
.week .d { display: grid; grid-template-columns: 64px 1fr; gap: 10px; align-items: start; }
.week .d .dn { font-family: var(--font-display); font-weight: 600; font-size: 12px; color: var(--ink-soft); padding-top: 5px; }
.week .d .it { display: flex; flex-direction: column; gap: 5px; }
.week .d .it span { display: flex; align-items: center; gap: 8px; font-size: 12.5px; padding: 5px 9px; background: var(--bg-2); border: 1px solid var(--line); border-radius: 9px; }
.week .d .it span i { width: 8px; height: 8px; border-radius: 50%; display: inline-block; flex: none; }
.week i.whatsapp { background: var(--wa); } .week i.instagram { background: var(--ig-b); } .week i.correo { background: var(--mail); }
.week i.cita { background: var(--brand); } .week i.split { background: var(--brand-deep); } .week i.detenido { background: var(--slate); }

.empty { color: var(--ink-mute); font-size: 13px; text-align: center; padding: 40px 12px; border: 1px dashed var(--line-strong); border-radius: var(--r-lg); }

/* ---------- Barra inferior / reproductor ---------- */
.bottom {
  display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 20px;
  padding: 10px 24px 16px;
}
.transport { display: flex; align-items: center; gap: 8px; }
.transport .play {
  width: 50px; height: 50px; border-radius: 50%; background: var(--brand); color: #fff;
  display: grid; place-items: center; box-shadow: 0 10px 24px oklch(0.55 0.225 296 / .35);
  transition: transform .15s var(--ease);
}
.transport .play:active { transform: scale(.95); }
.transport .play svg { width: 20px; height: 20px; }
.scenes { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.dots { display: flex; gap: 6px; align-items: center; }
.dot {
  flex: 1; height: 6px; border-radius: 3px; background: var(--line-strong); position: relative; overflow: hidden;
  transition: background .3s;
}
.dot.done { background: var(--brand-soft); }
.dot .fill { position: absolute; inset: 0; width: 0; background: var(--brand); border-radius: 3px; }
.dot:hover { background: var(--brand-soft); }
.scene-names { display: flex; justify-content: space-between; font-size: 11.5px; color: var(--ink-mute); }
.scene-names .cur { color: var(--brand-deep); font-weight: 600; }
.bottom-right { display: flex; align-items: center; gap: 8px; }

/* Menú de escenas */
.menu {
  position: fixed; right: 24px; bottom: 80px; width: 300px; max-height: 70vh; overflow: auto;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--shadow-md);
  padding: 8px; display: none; z-index: 50;
}
.menu.on { display: block; animation: rise .3s var(--ease); }
.menu button {
  width: 100%; text-align: left; display: grid; grid-template-columns: 52px 1fr; gap: 10px; align-items: center;
  padding: 9px 10px; border-radius: 12px; font-size: 13.5px;
}
.menu button:hover { background: var(--bg-2); }
.menu button.cur { background: var(--brand-ghost); color: var(--brand-deep); font-weight: 600; }
.menu button small { color: var(--ink-mute); font-weight: 500; font-variant-numeric: tabular-nums; }

/* Pantalla inicial */
.gate {
  position: fixed; inset: 0; z-index: 100; display: grid; place-items: center;
  background: radial-gradient(1200px 700px at 50% 30%, oklch(0.96 0.03 296), var(--bg) 70%);
  text-align: center; padding: 24px;
}
.gate.off { display: none; }
.gate .g-in { max-width: 560px; display: flex; flex-direction: column; align-items: center; gap: 18px; }
.gate .orb-wrap { width: 200px; }
.gate h1 { font-size: 34px; line-height: 1.15; }
.gate h1 em { font-style: italic; font-family: Georgia, 'Times New Roman', serif; font-weight: 400; color: var(--brand); }
.gate p { color: var(--ink-soft); font-size: 16px; margin: 0; max-width: 460px; }
.gate .start { padding: 14px 28px; border-radius: 999px; background: var(--brand); color: #fff; font-weight: 600; font-size: 16px; box-shadow: 0 12px 30px oklch(0.55 0.225 296 / .35); display: inline-flex; align-items: center; gap: 10px; }
.gate .start svg { width: 18px; height: 18px; }
.gate .hint { font-size: 12.5px; color: var(--ink-mute); }
.gate .hint kbd { font-family: inherit; padding: 1px 6px; border: 1px solid var(--line-strong); border-radius: 5px; background: #fff; }

/* Fin */
.fin { display: none; }

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
  .stage { grid-template-columns: minmax(280px, .9fr) 1fr; }
  .col-detalle { grid-column: 1 / -1; max-height: 40vh; }
}
@media (max-width: 760px) {
  body { overflow: auto; }
  .app { height: auto; min-height: 100dvh; }
  .top { grid-template-columns: 1fr auto; padding: 12px 16px 6px; }
  .asesor-chip { grid-column: 1 / -1; justify-self: start; }
  .brand small { display: none; }
  .stage { grid-template-columns: 1fr; padding: 6px 16px; gap: 16px; }
  .col-avatar { gap: 12px; }
  .orb-wrap { width: 160px; }
  .caption { font-size: 15.5px; padding: 14px 16px; }
  .flow, .detail { overflow: visible; mask-image: none; }
  .col-detalle { max-height: none; }
  .bottom { position: sticky; bottom: 0; background: var(--bg); border-top: 1px solid var(--line); grid-template-columns: auto 1fr; padding: 10px 16px; }
  .bottom-right { display: none; }
  .scene-names span:not(.cur) { display: none; }
  .menu { right: 12px; left: 12px; width: auto; }
}
@media (prefers-reduced-motion: reduce) {
  .orb, .orb-ring, .wave i, .command .mic { animation: none !important; }
}

/* Etapa y puntaje en la ficha del contacto */
.etapas { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; }
.etapa, .puntaje { display: inline-flex; align-items: center; gap: 5px; font-size: 11.5px; font-weight: 600; padding: 4px 10px; border-radius: 999px; }
.etapa { background: var(--brand-ghost); color: var(--brand-deep); }
.etapa svg { width: 12px; height: 12px; }
.etapa.perdido { background: var(--slate-soft); color: var(--slate); }
.puntaje.caliente { background: oklch(0.95 0.06 40); color: oklch(0.5 0.16 35); }
.puntaje.tibio { background: var(--amber-soft); color: var(--amber-ink); }
.puntaje.frio { background: oklch(0.95 0.03 240); color: oklch(0.45 0.08 250); }

/* Adjuntos que no son PDF */
.msg .adj .f.vid { color: var(--brand); }
.msg .adj .f.img { color: var(--green-ink); }

/* Correo entrante (portal) */
.art.correo.entrante .ab { background: oklch(0.97 0.01 250); }

/* Ubicación: mapa esquemático */
.art.ubicacion .map {
  position: relative; height: 110px; border-radius: var(--r-md); overflow: hidden; margin-bottom: 10px;
  background: linear-gradient(160deg, oklch(0.95 0.02 140), oklch(0.93 0.02 120));
}
.map-road { position: absolute; background: #fff; box-shadow: 0 0 0 1px oklch(0.88 0.01 120); }
.map-road.r1 { left: 0; right: 0; top: 46%; height: 14px; transform: rotate(-6deg); }
.map-road.r2 { top: 0; bottom: 0; left: 34%; width: 12px; transform: rotate(8deg); }
.map-road.r3 { top: 0; bottom: 0; left: 68%; width: 9px; transform: rotate(-4deg); }
.map-pin { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -80%); width: 34px; height: 34px; border-radius: 50%; background: var(--coral); color: #fff; display: grid; place-items: center; box-shadow: 0 6px 14px oklch(0.72 0.16 28 / .45); animation: pinDrop .6s var(--ease); }
.map-pin svg { width: 18px; height: 18px; }
@keyframes pinDrop { from { transform: translate(-50%, -160%); opacity: 0; } to { transform: translate(-50%, -80%); opacity: 1; } }
