/* Ana, de Full Class, como botón de chat (mismo patrón que María de Promtdea).
   Usa los tokens de la página; objetivos táctiles de 44 px, botón de 58 px, panel de 380 px y hoja de borde a borde en celular. */
.jh-btn { position: fixed; right: 18px; bottom: calc(18px + env(safe-area-inset-bottom, 0px)); z-index: 30; display: inline-flex; align-items: center; gap: 10px; min-height: 58px; padding: 0 22px 0 8px; border: 0; border-radius: 999px; background: #002960; color: #fff; font-weight: 600; font-size: 16px; line-height: 1; font-family: inherit; cursor: pointer; box-shadow: 0 10px 28px rgba(26, 45, 94, .35); transition: transform .15s ease; }
.jh-btn:hover { transform: translateY(-2px); }
.jh-btn:focus-visible { outline: 3px solid #00bf63; outline-offset: 3px; }
.jh-btn .jh-av { width: 42px; height: 42px; }
.jh-btn .jh-txt small { display: block; font-weight: 400; font-size: 12px; opacity: .8; margin-top: 3px; }
.jh-btn.recogido { padding: 0 8px; }
.jh-btn.recogido .jh-txt { display: none; }
.jh-av { position: relative; flex: none; width: 40px; height: 40px; border-radius: 50%; background: linear-gradient(135deg, #24407f, #002960); color: #fff; display: grid; place-items: center; font-weight: 700; font-size: 17px; border: 2px solid rgba(255, 255, 255, .25); }
.jh-av::after { content: ""; position: absolute; right: -1px; bottom: 1px; width: 11px; height: 11px; border-radius: 50%; background: #00bf63; border: 2px solid #002960; }
.jh-panel { padding: 0; margin: 0; position: fixed; right: 18px; bottom: calc(90px + env(safe-area-inset-bottom, 0px)); z-index: 31; width: min(380px, 100vw - 32px); height: min(620px, calc(100vh - 120px)); display: flex; flex-direction: column; background: var(--surface, #fff); color: var(--ink, #002960); border: 1px solid var(--line, #d9e1ef); border-radius: 24px; box-shadow: 0 24px 60px rgba(26, 45, 94, .28); overflow: hidden; animation: jh-entra .22s ease-out; }
.jh-panel[hidden] { display: none; }
@keyframes jh-entra { from { opacity: 0; transform: translateY(14px) scale(.98); } to { opacity: 1; transform: none; } }
.jh-cab { display: flex; align-items: center; gap: 12px; padding: 14px 10px 12px 16px; background: #002960; color: #fff; }
.jh-tit { display: flex; flex-direction: column; min-width: 0; }
.jh-tit b { font-size: 16px; }
.jh-tit span { font-size: 12px; opacity: .85; line-height: 1.3; }
.jh-cerrar { margin-left: auto; flex: none; width: 44px; height: 44px; border: 0; border-radius: 12px; background: transparent; color: #fff; font-size: 20px; cursor: pointer; }
.jh-cerrar:hover { background: rgba(255, 255, 255, .12); }
.jh-cuerpo { flex: 1; min-height: 0; overflow: auto; overscroll-behavior: contain; padding: 14px 14px 6px; display: flex; flex-direction: column; gap: 8px; }
.jh-m { max-width: 88%; padding: 10px 14px; border-radius: 18px; line-height: 1.5; font-size: 14.5px; white-space: pre-line; overflow-wrap: anywhere; }
.jh-m.bot { align-self: flex-start; background: var(--surface-2, #eef3fa); border-bottom-left-radius: 6px; }
.jh-m.yo { align-self: flex-end; background: #002960; color: #fff; border-bottom-right-radius: 6px; }
.jh-m.nota { align-self: stretch; max-width: none; background: transparent; color: var(--ink-2, #4a5677); font-size: 12px; padding: 2px 4px; }
.jh-m a { color: inherit; font-weight: 600; }
.jh-m.escribiendo { display: inline-flex; gap: 5px; padding: 14px 16px; }
.jh-m.escribiendo i { width: 7px; height: 7px; border-radius: 50%; background: var(--ink-2, #4a5677); animation: jh-puntos 1.2s ease-in-out infinite; }
.jh-m.escribiendo i:nth-child(2) { animation-delay: .15s; }
.jh-m.escribiendo i:nth-child(3) { animation-delay: .3s; }
@keyframes jh-puntos { 0%, 80%, 100% { opacity: .3; transform: none; } 40% { opacity: 1; transform: translateY(-3px); } }
.jh-tarjeta { align-self: stretch; border: 1px solid var(--line, #d9e1ef); border-radius: 16px; padding: 12px 14px; background: var(--surface, #fff); display: grid; gap: 8px; font-size: 14px; }
.jh-tarjeta b { font-size: 14.5px; }
.jh-tarjeta ol { margin: 0; padding-left: 20px; display: grid; gap: 6px; }
.jh-tarjeta li a { color: var(--accent, #00813f); font-weight: 600; text-decoration: none; }
.jh-tarjeta li a:hover { text-decoration: underline; }
.jh-tarjeta small { color: var(--ink-2, #4a5677); }
.jh-tarjeta img { height: 32px; width: auto; }
.jh-acciones { display: flex; flex-wrap: wrap; gap: 8px; }
.jh-acciones a, .jh-acciones button { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 8px 16px; border-radius: 999px; border: 0; background: #00bf63; color: #002960; font-weight: 600; font-size: 14px; line-height: 1.2; font-family: inherit; text-decoration: none; cursor: pointer; }
.jh-acciones .sec { background: var(--surface-2, #eef3fa); color: var(--ink, #002960); }
.jh-rapidas { display: flex; flex-wrap: wrap; gap: 6px; padding: 6px 14px 10px; }
.jh-rapidas:empty { display: none; }
.jh-rapidas button { min-height: 44px; padding: 8px 14px; border-radius: 999px; border: 1.5px solid color-mix(in srgb, #002960 30%, var(--line, #d9e1ef)); background: var(--surface, #fff); color: var(--ink, #002960); font: 500 13.5px/1.25 inherit; font-family: inherit; cursor: pointer; text-align: left; }
.jh-rapidas button:hover { background: var(--surface-2, #eef3fa); }
.jh-barra { display: flex; gap: 8px; padding: 10px 14px; margin: 0; max-width: none; border-radius: 0; background: var(--surface, #fff); border-top: 1px solid var(--line, #d9e1ef); }
.jh-barra input { flex: 1; min-width: 0; min-height: 44px; padding: 10px 16px; border-radius: 999px; border: 1.5px solid var(--line, #d9e1ef); background: var(--surface, #fff); color: var(--ink, #002960); font: inherit; font-size: 15px; }
.jh-barra input:focus { outline: none; border-color: #002960; }
.jh-barra button { min-width: 44px; min-height: 44px; padding: 0 16px; border: 0; border-radius: 999px; background: #002960; color: #fff; font-weight: 600; font-size: 14px; font-family: inherit; cursor: pointer; }
.jh-barra .jh-mic { padding: 0; width: 44px; background: var(--surface-2, #eef3fa); color: var(--ink, #002960); display: inline-grid; place-items: center; }
.jh-barra .jh-mic[hidden] { display: none; }
.jh-barra .jh-mic.activo { background: #00bf63; color: #002960; animation: jh-pulso 1.2s ease-in-out infinite; }
@keyframes jh-pulso { 50% { box-shadow: 0 0 0 6px rgba(196, 69, 26, .2); } }
.jh-dims { display: grid; gap: 8px; }
.jh-dim { display: grid; grid-template-columns: 96px 1fr; align-items: center; gap: 8px; font-size: 13px; }
.jh-dim-barra { height: 10px; border-radius: 999px; background: var(--surface-2, #eef3fa); overflow: hidden; }
.jh-dim-barra i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #00bf63, #00813f); }
.jh-fort { margin: 0; padding-left: 18px; display: grid; gap: 4px; font-size: 13.5px; }
.jh-tarjeta li strong { font-size: 14px; }
.jh-pie { margin: 0; padding: 0 14px 10px; font-size: 11px; color: var(--ink-2, #4a5677); }
.jh-pie a { color: inherit; }
@media (max-width: 599px) {
  .jh-panel { left: 0; right: 0; bottom: 0; width: 100%; height: min(92vh, 92dvh); border-radius: 26px 26px 0 0; }
  .jh-btn[aria-expanded="true"] { display: none; }
  .jh-btn .jh-txt small { display: none; }
  /* en celular el botón es solo el círculo de Ana: tapa menos texto mientras la persona lee */
  .jh-btn { right: 12px; min-height: 52px; padding: 0 5px; }
  .jh-btn .jh-txt { display: none; }
  /* no tapa lo que la persona escribe ni el cuestionario del Talent Map */
  body.fc-escribiendo .jh-btn, body.fc-en-calc .jh-btn, body:has(#tm-quiz:not([hidden])) .jh-btn { display: none; }
  .jh-btn { transition: transform .2s ease; }
  body.fc-bajando .jh-btn { transform: translateY(140%); }
  .jh-btn { min-height: 48px; }
  .jh-barra { padding-bottom: calc(10px + env(safe-area-inset-bottom, 0px)); }
}
@media (prefers-reduced-motion: reduce) {
  .jh-panel { animation: none; }
  .jh-m.escribiendo i { animation: none; }
  .jh-barra .jh-mic.activo { animation: none; }
  .jh-btn, .jh-btn:hover { transition: none; transform: none; }
}
@media print { .jh-btn, .jh-panel { display: none; } }
