/* NEXUS hotfix: teclado virtual no mobile (ver assets/teclado-seguro.js). */
html.teclado-aberto nav.fixed.inset-x-4.bottom-4 { display: none !important; }

@supports (height: 100dvh) {
  div[style*="calc(100vh - 132px)"] { height: calc(100dvh - 132px) !important; }
}

@media (max-width: 767px) {
  div[style*="calc(100vh - 132px)"] { min-height: 0 !important; }
}

/* v2: evita o "puxão" quando o campo recalcula a altura e o tremor por ancoragem de rolagem */
html.teclado-aberto body { padding-bottom: 45vh; }
html.teclado-aberto .p-chat-log,
html.teclado-aberto .p-chat-campo { overflow-anchor: none; }

/* v3: altura fixa do campo com teclado aberto — elimina o recálculo de altura a cada tecla */
html.teclado-aberto .p-chat-campo {
  height: 104px !important;
  min-height: 104px !important;
  max-height: 104px !important;
  overflow-y: auto !important;
  overscroll-behavior: contain;
}

/* v4: tela Atualizar Dados = só o questionário. O chat fica apenas no Painel · Hoje. */
div[style*="calc(100vh - 132px)"] > :first-child,
div[style*="calc(100vh - 132px)"] > :nth-child(n+3) { display: none !important; }
div[style*="calc(100vh - 132px)"] { height: auto !important; min-height: 0 !important; }
button[aria-label="Abrir chat com o Genisys IA"] { display: none !important; }

/* v5: mesmo objetivo da v4, sem depender do texto do atributo style
   (o navegador reescreve calc(100vh - 132px) como calc(-132px + 100vh)). */
div.scrollbar-none.flex.flex-col.gap-4:has(> div.sh-rl.bg-bg.w-full) > :first-child,
div.scrollbar-none.flex.flex-col.gap-4:has(> div.sh-rl.bg-bg.w-full) > :nth-child(n+3) { display: none !important; }
div.scrollbar-none.flex.flex-col.gap-4:has(> div.sh-rl.bg-bg.w-full) { height: auto !important; min-height: 0 !important; }
