/* NEXEI 3.1.4 - alinhamento definitivo, redefinição isolada e respostas legíveis */

/* Barra de ações da visualização: uma única régua, sem itens espremidos. */
body.page-view .details .actions{
  display:flex!important;
  flex-flow:row nowrap!important;
  align-items:center!important;
  justify-content:flex-start!important;
  gap:8px!important;
  width:max-content!important;
  max-width:calc(100% - 4px)!important;
  min-width:0!important;
  height:42px!important;
  margin:0 0 12px -4px!important;
  padding:4px 0!important;
  overflow:visible!important;
  box-sizing:border-box!important;
  transform:none!important;
}
body.page-view .details .actions>* ,
body.page-view .details .actions>form{
  flex:0 0 34px!important;
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  width:34px!important;
  min-width:34px!important;
  max-width:34px!important;
  height:34px!important;
  min-height:34px!important;
  max-height:34px!important;
  margin:0!important;
  padding:0!important;
  border:0!important;
  background:transparent!important;
  box-sizing:border-box!important;
  position:relative!important;
  inset:auto!important;
  transform:none!important;
}
body.page-view .details .actions a,
body.page-view .details .actions button,
body.page-view .details .actions .icon-btn,
body.page-view .details .actions form button{
  flex:0 0 34px!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  width:34px!important;
  min-width:34px!important;
  max-width:34px!important;
  height:34px!important;
  min-height:34px!important;
  max-height:34px!important;
  margin:0!important;
  padding:0!important;
  border:1px solid #e4eaf5!important;
  border-radius:11px!important;
  background:#f3f6fb!important;
  color:#111827!important;
  box-sizing:border-box!important;
  line-height:1!important;
  position:relative!important;
  inset:auto!important;
  transform:none!important;
  overflow:hidden!important;
}
body.page-view .details .actions a:hover,
body.page-view .details .actions button:hover{background:#e9effa!important;border-color:#d5deed!important}
body.page-view .details .actions .copy-barcode-btn,
body.page-view .details .actions a[title="Download"]{background:#5b42e8!important;border-color:#5b42e8!important;color:#fff!important}
body.page-view .details .actions .danger-mini,
body.page-view .details .actions button[title="Cancelar"],
body.page-view .details .actions button[title="Excluir"],
body.page-view .details .actions button[title="Excluir rascunho"]{background:#fff0f0!important;border-color:#f7caca!important;color:#991b1b!important}
body.page-view .details .actions img,
body.page-view .details .actions svg,
body.page-view .details .actions .action-icon-img,
body.page-view .details .actions .nexei-icon-real,
body.page-view .details .actions .nexei-icon-lite{
  display:block!important;
  width:18px!important;
  min-width:18px!important;
  max-width:18px!important;
  height:18px!important;
  min-height:18px!important;
  max-height:18px!important;
  margin:0!important;
  padding:0!important;
  object-fit:contain!important;
  vertical-align:middle!important;
  transform:none!important;
}

/* Mesma medida e intervalo nas tabelas administrativas. */
.admin-table .row-actions,.table-actions,.list-actions{
  display:flex!important;
  flex-flow:row nowrap!important;
  align-items:center!important;
  justify-content:flex-start!important;
  gap:8px!important;
  margin:0!important;
  padding:0!important;
}
.admin-table .row-actions>*,.table-actions>*,.list-actions>*{margin:0!important;align-self:center!important}
.admin-table .row-actions>form,.table-actions>form,.list-actions>form{display:inline-flex!important;align-items:center!important;justify-content:center!important;margin:0!important;padding:0!important}

/* Olho exatamente centralizado no campo de senha. */
.password-field-v312{position:relative!important;display:flex!important;align-items:center!important;width:100%!important}
.password-field-v312>input{width:100%!important;height:42px!important;margin:0!important;padding-right:50px!important;box-sizing:border-box!important}
.password-field-v312>button[type="button"]{
  position:absolute!important;
  top:50%!important;
  right:5px!important;
  bottom:auto!important;
  left:auto!important;
  transform:translateY(-50%)!important;
  display:grid!important;
  place-items:center!important;
  width:34px!important;
  min-width:34px!important;
  max-width:34px!important;
  height:34px!important;
  min-height:34px!important;
  max-height:34px!important;
  margin:0!important;
  padding:0!important;
  border:1px solid #dbe3ef!important;
  border-radius:9px!important;
  line-height:1!important;
  z-index:2!important;
  box-sizing:border-box!important;
}

/* Páginas públicas nunca herdam geometria do shell autenticado. */
body.page-login .sidebar,body.page-login .topbar,
body.page-forgot_password .sidebar,body.page-forgot_password .topbar,
body.page-reset_password .sidebar,body.page-reset_password .topbar,
body.page-password_expired .sidebar,body.page-password_expired .topbar,
body.page-two_factor .sidebar,body.page-two_factor .topbar{display:none!important}
body.page-login .main,body.page-forgot_password .main,body.page-reset_password .main,body.page-password_expired .main,body.page-two_factor .main{margin-left:0!important;width:100%!important;padding:0!important}

/* Assistant: títulos e listas com hierarquia melhor. */
.assistant-msg p{line-height:1.55!important;white-space:pre-wrap!important}
.assistant-msg p strong{font-weight:850!important;color:inherit!important}
.assistant-msg-bot p strong:first-child{font-size:14px!important}
.assistant-msg-bot{padding:13px 15px!important}

@media(max-width:520px){
  body.page-view .details .actions{
    gap:6px!important;
    margin-left:-2px!important;
    max-width:100%!important;
    overflow-x:auto!important;
    overflow-y:hidden!important;
    scrollbar-width:none!important;
  }
  body.page-view .details .actions::-webkit-scrollbar{display:none!important}
  body.page-view .details .actions>*,body.page-view .details .actions>form,
  body.page-view .details .actions a,body.page-view .details .actions button,
  body.page-view .details .actions .icon-btn,body.page-view .details .actions form button{
    flex-basis:32px!important;width:32px!important;min-width:32px!important;max-width:32px!important;height:32px!important;min-height:32px!important;max-height:32px!important;
  }
}
