/**
 * Assistente com IA (assets/js/ajuda-chat.js) — botão flutuante e janela.
 * Aparece na área logada (Inter) e na Central de Ajuda (Instrument Sans):
 * herda a fonte do corpo e usa Outfit nos títulos, as duas páginas já carregam.
 * Cores: roxo de IA do design system (#7C3AED / #8B5CF6, só para IA) e os
 * neutros da área logada. Prefixo próprio para não vazar entre páginas.
 */
.ajc-fab,
.ajc-painel {
    --ajc-roxo: #7C3AED;
    --ajc-roxo-2: #8B5CF6;
    --ajc-degrade: linear-gradient(135deg, #7C3AED 0%, #8B5CF6 100%);
    --ajc-roxo-fundo: rgba(124, 58, 237, .07);
    --ajc-roxo-linha: rgba(124, 58, 237, .28);
    --ajc-texto: #111827;
    --ajc-muted: #6B7280;
    --ajc-linha: rgba(15, 23, 42, .09);
    --ajc-cinza: rgba(15, 23, 42, .05);
    --ajc-fundo: #FFFFFF;
    --ajc-verde: #2ECC71;
    --ajc-perigo: #E74C3C;
    --ajc-titulo: 'Outfit', system-ui, sans-serif;
}

/* ── Botão flutuante ─────────────────────────────────────────────────────── */
.ajc-fab {
    position: fixed;
    right: 24px;
    bottom: calc(24px + env(safe-area-inset-bottom, 0px));
    z-index: 1040;
    width: 56px;
    height: 56px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: var(--ajc-degrade);
    color: #fff;
    box-shadow: 0 10px 24px -8px rgba(124, 58, 237, .6), 0 2px 6px rgba(15, 23, 42, .12);
    cursor: pointer;
    font-family: inherit; /* o balão de apresentação usa a fonte da página */
    display: grid;
    place-items: center;
    transition: transform .2s cubic-bezier(.2, .8, .2, 1), box-shadow .2s ease;
    animation: ajc-entrar .35s cubic-bezier(.2, .8, .2, 1) .4s backwards;
    -webkit-tap-highlight-color: transparent;
}
.ajc-fab:hover { transform: translateY(-2px); box-shadow: 0 14px 28px -8px rgba(124, 58, 237, .65), 0 2px 6px rgba(15, 23, 42, .12); }
.ajc-fab:active { transform: scale(.96); }
.ajc-fab:focus-visible { outline: 3px solid rgba(124, 58, 237, .4); outline-offset: 3px; }
.ajc-fab-ico { grid-area: 1 / 1; display: grid; place-items: center; transition: opacity .18s ease, transform .22s cubic-bezier(.2, .8, .2, 1); }
.ajc-fab-ico svg { width: 26px; height: 26px; }
.ajc-fab-baixo { opacity: 0; transform: rotate(-90deg) scale(.6); }
.ajc-fab.ajc-aberto .ajc-fab-balao { opacity: 0; transform: rotate(90deg) scale(.6); }
.ajc-fab.ajc-aberto .ajc-fab-baixo { opacity: 1; transform: none; }

/*
 * Apresentação ao passar o mouse (21/10/2026). Só onde há mouse: no toque
 * não existe "passar por cima" e o balão ficaria preso depois do toque.
 * Não aparece com a janela aberta. O botão já tem aria-label: o balão é
 * só visual (aria-hidden) e não recebe clique.
 */
.ajc-fab-dica {
    position: absolute;
    right: calc(100% + 14px);
    top: 50%;
    width: max-content;
    max-width: 260px;
    padding: 10px 14px;
    border-radius: 12px;
    background: var(--ajc-fundo);
    color: var(--ajc-texto);
    box-shadow: 0 24px 56px -16px rgba(15, 23, 42, .32), 0 0 0 1px var(--ajc-linha);
    font-family: inherit;
    font-size: 13.5px;
    font-weight: 400;
    line-height: 1.45;
    text-align: left;
    text-wrap: pretty;
    pointer-events: none;
    opacity: 0;
    visibility: hidden;
    transform: translate(6px, -50%);
    transition: opacity .18s ease, transform .22s cubic-bezier(.2, .8, .2, 1), visibility 0s linear .22s;
}
.ajc-fab-dica::after { content: ''; position: absolute; right: -5px; top: 50%; width: 10px; height: 10px; background: var(--ajc-fundo); box-shadow: 1px -1px 0 var(--ajc-linha); transform: translateY(-50%) rotate(45deg); }
@media (hover: hover) and (pointer: fine) {
    .ajc-fab:hover .ajc-fab-dica { opacity: 1; visibility: visible; transform: translate(0, -50%); transition-delay: .15s, .15s, 0s; }
}
.ajc-fab.ajc-aberto .ajc-fab-dica { display: none; }

@keyframes ajc-entrar { from { opacity: 0; transform: scale(.6); } to { opacity: 1; transform: none; } }

/* Telas que cobrem tudo escondem o botão (Configure sua conta, impressão) */
body.cfgc-aberto .ajc-fab,
body.cfgc-aberto .ajc-painel { display: none !important; }
@media print { .ajc-fab, .ajc-painel { display: none !important; } }

/* ── Janela ──────────────────────────────────────────────────────────────── */
.ajc-painel {
    position: fixed;
    right: 24px;
    bottom: calc(92px + env(safe-area-inset-bottom, 0px));
    z-index: 1045;
    width: 392px;
    height: min(660px, calc(100vh - 120px));
    height: min(660px, calc(100dvh - 120px));
    display: flex;
    flex-direction: column;
    background: var(--ajc-fundo);
    color: var(--ajc-texto);
    border-radius: 16px;
    box-shadow: 0 24px 56px -16px rgba(15, 23, 42, .32), 0 0 0 1px var(--ajc-linha);
    overflow: hidden;
    font-size: 14.5px;
    line-height: 1.55;
    text-align: left;
    opacity: 0;
    transform: translateY(10px) scale(.98);
    transform-origin: bottom right;
    transition: opacity .18s ease, transform .22s cubic-bezier(.2, .8, .2, 1);
}
.ajc-painel[hidden] { display: none; }
.ajc-painel.ajc-visivel { opacity: 1; transform: none; }
.ajc-painel *, .ajc-painel *::before, .ajc-painel *::after { box-sizing: border-box; }
.ajc-painel svg { width: 20px; height: 20px; flex: none; }
.ajc-painel button { font: inherit; color: inherit; }
.ajc-vo { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Cabeçalho */
.ajc-topo {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 8px 12px 16px;
    border-bottom: 1px solid var(--ajc-linha);
    background: linear-gradient(180deg, rgba(124, 58, 237, .05), rgba(124, 58, 237, 0));
}
.ajc-avatar { width: 34px; height: 34px; border-radius: 10px; background: var(--ajc-degrade); color: #fff; display: grid; place-items: center; flex: none; }
.ajc-avatar svg { width: 20px; height: 20px; }
.ajc-topo-txt { min-width: 0; flex: 1; }
.ajc-topo-txt h2 { margin: 0; font-family: var(--ajc-titulo); font-size: 15.5px; font-weight: 600; line-height: 1.25; color: var(--ajc-texto); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ajc-topo-txt p { margin: 1px 0 0; font-size: 12.5px; color: var(--ajc-roxo); font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
/* Etiqueta Beta ao lado do nome (Íris) */
.ajc-beta { display: inline-block; margin-left: 4px; padding: 1px 7px; border-radius: 999px; background: var(--ajc-roxo-fundo); color: var(--ajc-roxo); font-family: inherit; font-size: 11px; font-weight: 600; line-height: 1.5; vertical-align: 2px; letter-spacing: .01em; }
.ajc-topo-acoes { display: flex; align-items: center; }
.ajc-ico {
    position: relative;
    width: 40px;
    height: 40px;
    border: 0;
    border-radius: 10px;
    background: transparent;
    color: var(--ajc-muted) !important;
    display: grid;
    place-items: center;
    cursor: pointer;
    transition: background-color .15s ease, color .15s ease;
}
.ajc-ico::after { content: ''; position: absolute; inset: -2px; } /* toque de 44 px */
.ajc-ico:hover { background: var(--ajc-cinza); color: var(--ajc-texto) !important; }
.ajc-ico:focus-visible { outline: 2px solid var(--ajc-roxo); outline-offset: -2px; }
.ajc-ico[hidden] { display: none; }

/* Corpo e vistas */
.ajc-corpo { flex: 1; overflow-y: auto; overscroll-behavior: contain; padding: 18px 16px 8px; scroll-behavior: smooth; }
.ajc-vista[hidden] { display: none; }

/* Boas-vindas */
.ajc-bv { min-height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 16px 12px 24px; }
.ajc-bv-icone { width: 60px; height: 60px; border-radius: 18px; background: var(--ajc-degrade); color: #fff; display: grid; place-items: center; box-shadow: 0 12px 28px -12px rgba(124, 58, 237, .7); }
.ajc-bv-icone svg { width: 32px; height: 32px; }
.ajc-selo { display: inline-flex; align-items: center; gap: 5px; margin-top: 18px; padding: 4px 10px 4px 8px; border-radius: 999px; background: var(--ajc-roxo-fundo); color: var(--ajc-roxo); font-size: 12.5px; font-weight: 600; }
.ajc-selo svg { width: 14px; height: 14px; }
.ajc-bv h3 { text-wrap: balance; margin: 10px 0 8px; font-family: var(--ajc-titulo); font-size: 24px; font-weight: 700; letter-spacing: -.01em; color: var(--ajc-texto); }
.ajc-bv p { margin: 0 0 22px; max-width: 300px; color: var(--ajc-muted); font-size: 14.5px; text-wrap: pretty; }
.ajc-bv p.ajc-bv-beta { margin-top: -14px; font-size: 13px; }
.ajc-bv-links { margin-top: 18px; display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 2px 6px; color: var(--ajc-muted); font-size: 13px; }
.ajc-bv-links button { border: 0; background: none; padding: 10px 4px; color: var(--ajc-muted); cursor: pointer; text-decoration: underline; text-decoration-color: rgba(107, 114, 128, .4); text-underline-offset: 3px; }
.ajc-bv-links button:hover { color: var(--ajc-texto); }

/* Botões */
.ajc-btn {
    min-height: 48px;
    width: 100%;
    max-width: 280px;
    padding: 0 20px;
    border: 0;
    border-radius: 12px;
    background: var(--ajc-degrade);
    color: #fff !important;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 8px 18px -10px rgba(124, 58, 237, .8);
    transition: transform .15s ease, filter .15s ease;
}
.ajc-btn:hover { filter: brightness(1.05); }
.ajc-btn:active { transform: scale(.98); }
.ajc-btn:disabled { opacity: .6; cursor: default; }
.ajc-btn:focus-visible { outline: 3px solid rgba(124, 58, 237, .35); outline-offset: 2px; }
.ajc-btn-link { border: 0; background: none; padding: 10px 4px; color: var(--ajc-texto) !important; font-size: 13.5px; font-weight: 500; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.ajc-btn-equipe {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 44px;
    margin-top: 10px;
    padding: 0 14px;
    border: 1px solid var(--ajc-roxo-linha);
    border-radius: 10px;
    background: #fff;
    color: var(--ajc-roxo) !important;
    font-size: 13.5px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color .15s ease;
}
.ajc-btn-equipe:hover { background: var(--ajc-roxo-fundo); }
.ajc-btn-equipe svg { width: 18px; height: 18px; }

/* Mensagens */
.ajc-conversa { display: flex; flex-direction: column; gap: 16px; }
.ajc-msg { display: flex; gap: 10px; min-width: 0; animation: ajc-msg .22s ease-out; }
@keyframes ajc-msg { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }
.ajc-msg-avatar { width: 28px; height: 28px; border-radius: 8px; background: var(--ajc-roxo-fundo); color: var(--ajc-roxo); display: grid; place-items: center; flex: none; margin-top: 1px; }
.ajc-msg-avatar svg { width: 17px; height: 17px; }
.ajc-msg-corpo { min-width: 0; flex: 1; }
.ajc-texto { overflow-wrap: anywhere; }
.ajc-texto p { margin: 0 0 8px; }
.ajc-texto p:last-child, .ajc-texto ol:last-child, .ajc-texto ul:last-child { margin-bottom: 0; }
.ajc-texto ol, .ajc-texto ul { margin: 4px 0 10px; padding-left: 22px; }
.ajc-texto li { margin: 5px 0; padding-left: 2px; }
.ajc-texto li::marker { color: var(--ajc-roxo); font-weight: 600; }
.ajc-texto strong { font-weight: 600; color: var(--ajc-texto); }
.ajc-texto a { color: var(--ajc-roxo); font-weight: 500; text-decoration: underline; text-decoration-color: rgba(124, 58, 237, .35); text-underline-offset: 3px; }
.ajc-texto a:hover { text-decoration-color: currentColor; }

.ajc-msg-usuario { justify-content: flex-end; }
.ajc-bolha { max-width: 85%; padding: 10px 14px; border-radius: 16px 16px 4px 16px; background: var(--ajc-cinza); color: var(--ajc-texto); white-space: pre-wrap; overflow-wrap: anywhere; }

.ajc-sugestoes { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.ajc-sugestao {
    position: relative;
    min-height: 36px;
    padding: 7px 12px;
    border: 1px solid var(--ajc-roxo-linha);
    border-radius: 999px;
    background: rgba(124, 58, 237, .03);
    color: var(--ajc-roxo) !important;
    font-size: 13.5px;
    font-weight: 500;
    line-height: 1.3;
    text-align: left;
    cursor: pointer;
    transition: background-color .15s ease;
}
.ajc-sugestao::after { content: ''; position: absolute; inset: -4px; }
.ajc-sugestao:hover { background: var(--ajc-roxo-fundo); }

.ajc-fontes { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 12px; }
.ajc-fontes-rot { width: 100%; font-size: 12px; color: var(--ajc-muted); }
.ajc-fonte {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    max-width: 100%;
    min-height: 36px;
    padding: 6px 10px;
    border: 1px solid var(--ajc-linha);
    border-radius: 8px;
    background: #fff;
    color: var(--ajc-texto) !important;
    font-size: 13px;
    line-height: 1.3;
    text-decoration: none !important;
    transition: border-color .15s ease;
}
.ajc-fonte:hover { border-color: var(--ajc-roxo-linha); }
.ajc-fonte svg { width: 15px; height: 15px; color: var(--ajc-roxo); }

.ajc-avaliar { display: flex; gap: 8px; margin: 6px 0 0 -9px; }
.ajc-av { position: relative; width: 36px; height: 36px; border: 0; border-radius: 8px; background: none; color: rgba(107, 114, 128, .8) !important; display: grid; place-items: center; cursor: pointer; transition: color .15s ease, background-color .15s ease; }
.ajc-av::after { content: ''; position: absolute; inset: -4px; } /* 44 px sem sobrepor o vizinho */
.ajc-av svg { width: 16px; height: 16px; }
.ajc-av:hover { color: var(--ajc-texto) !important; background: var(--ajc-cinza); }
.ajc-av[aria-pressed="true"] { color: var(--ajc-roxo) !important; background: var(--ajc-roxo-fundo); }
.ajc-av[aria-pressed="true"] svg path { fill: rgba(124, 58, 237, .18); }
.ajc-nota p { margin: 4px 0 0; font-size: 13px; color: var(--ajc-muted); }

.ajc-msg-aviso { align-items: flex-start; padding: 12px 14px; border-radius: 12px; background: rgba(46, 204, 113, .1); border: 1px solid rgba(46, 204, 113, .32); }
.ajc-aviso-ico { width: 24px; height: 24px; border-radius: 50%; background: var(--ajc-verde); color: #fff; display: grid; place-items: center; flex: none; }
.ajc-aviso-ico svg { width: 14px; height: 14px; }

.ajc-msg-erro { display: block; padding: 10px 14px; border-radius: 12px; background: rgba(231, 76, 60, .06); border: 1px solid rgba(231, 76, 60, .25); }
.ajc-msg-erro p { margin: 0; }

.ajc-digitando .ajc-msg-corpo, .ajc-carregando { display: flex; align-items: center; gap: 10px; color: var(--ajc-muted); font-size: 13.5px; }
.ajc-pontos { display: inline-flex; gap: 4px; }
.ajc-pontos i { width: 6px; height: 6px; border-radius: 50%; background: var(--ajc-roxo-2); animation: ajc-ponto 1.1s infinite ease-in-out; }
.ajc-pontos i:nth-child(2) { animation-delay: .15s; }
.ajc-pontos i:nth-child(3) { animation-delay: .3s; }
@keyframes ajc-ponto { 0%, 80%, 100% { opacity: .25; transform: translateY(0); } 40% { opacity: 1; transform: translateY(-3px); } }

/* Pedido à equipe */
.ajc-pedido { padding: 14px; border: 1px solid var(--ajc-roxo-linha); border-radius: 12px; background: #fff; box-shadow: 0 6px 18px -12px rgba(124, 58, 237, .5); animation: ajc-msg .22s ease-out; }
.ajc-pedido-tit { display: flex; align-items: center; gap: 8px; margin: 0; font-family: var(--ajc-titulo); font-size: 15px; font-weight: 600; }
.ajc-pedido-tit svg { color: var(--ajc-roxo); }
.ajc-pedido-sub { margin: 2px 0 12px; font-size: 13px; color: var(--ajc-muted); }
.ajc-p-campo { margin-bottom: 10px; }
.ajc-p-campo label { display: block; margin-bottom: 4px; font-size: 12.5px; font-weight: 600; color: var(--ajc-texto); }
.ajc-p-campo input,
.ajc-p-campo textarea,
.ajc-form textarea {
    width: 100%;
    border: 1.5px solid rgba(15, 23, 42, .14);
    border-radius: 10px;
    background: #fff;
    color: var(--ajc-texto);
    font: inherit;
    font-size: 14.5px;
    line-height: 1.45;
    transition: border-color .15s ease, box-shadow .15s ease;
}
.ajc-p-campo input { min-height: 44px; padding: 0 12px; }
.ajc-p-campo textarea { padding: 10px 12px; resize: vertical; min-height: 110px; }
.ajc-p-campo input:focus, .ajc-p-campo textarea:focus, .ajc-form textarea:focus { outline: none; border-color: var(--ajc-roxo); box-shadow: 0 0 0 3px rgba(124, 58, 237, .14); }
.ajc-p-campo [aria-invalid="true"] { border-color: var(--ajc-perigo); }
.ajc-p-erro, .ajc-pedido-erro { margin: 4px 0 0; font-size: 12.5px; color: var(--ajc-perigo); }
.ajc-pedido-erro { margin: 0 0 10px; }
.ajc-p-erro[hidden], .ajc-pedido-erro[hidden] { display: none; }
.ajc-pedido-acoes { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 12px; margin-top: 4px; }
.ajc-pedido-acoes .ajc-btn { max-width: none; flex: 1 1 180px; min-height: 44px; font-size: 14.5px; }

/* Histórico */
.ajc-hist-tit { margin: 0 0 8px; font-family: var(--ajc-titulo); font-size: 15px; font-weight: 600; }
.ajc-hist-lista { list-style: none; margin: 0 -8px; padding: 0; }
.ajc-hist-item { width: 100%; display: flex; flex-direction: column; gap: 2px; padding: 12px 8px; border: 0; border-bottom: 1px solid var(--ajc-linha); border-radius: 0; background: none; text-align: left; cursor: pointer; transition: background-color .15s ease; }
.ajc-hist-item:hover, .ajc-hist-item[aria-current="true"] { background: var(--ajc-cinza); }
.ajc-hist-titulo { font-size: 14px; font-weight: 500; color: var(--ajc-texto); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.ajc-hist-quando { font-size: 12px; color: var(--ajc-muted); font-variant-numeric: tabular-nums; }
.ajc-vazio { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 40px 12px; text-align: center; color: var(--ajc-muted); }
.ajc-vazio > span { width: 48px; height: 48px; border-radius: 50%; background: var(--ajc-cinza); display: grid; place-items: center; margin-bottom: 6px; }
.ajc-vazio p { margin: 0 0 14px; }

/* Super admin: conversas de todas as contas, só leitura (21/10/2026) */
.ajc-hist-filtro { display: flex; flex-direction: column; gap: 8px; margin: 0 0 6px; }
.ajc-seg { display: flex; gap: 2px; padding: 2px; border-radius: 12px; background: var(--ajc-cinza); }
.ajc-painel .ajc-seg button { flex: 1; min-height: 44px; border: 1px solid transparent; border-radius: 10px; background: none; color: var(--ajc-muted); font-size: 13.5px; font-weight: 500; cursor: pointer; transition: background-color .15s ease, color .15s ease; }
.ajc-painel .ajc-seg button[aria-pressed="true"] { background: var(--ajc-fundo); border-color: var(--ajc-linha); color: var(--ajc-texto); }
.ajc-hist-busca { width: 100%; min-height: 44px; padding: 0 12px; border: 1.5px solid rgba(15, 23, 42, .14); border-radius: 10px; background: #fff; color: var(--ajc-texto); font: inherit; font-size: 14.5px; }
.ajc-hist-busca:focus { outline: none; border-color: var(--ajc-roxo); box-shadow: 0 0 0 3px rgba(124, 58, 237, .14); }
.ajc-hist-dono { font-size: 12.5px; color: var(--ajc-texto); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ajc-hist-nada { margin: 0; padding: 24px 8px; text-align: center; color: var(--ajc-muted); }
.ajc-hist-mais { display: block; min-height: 44px; margin: 6px auto 0; }
.ajc-form[hidden], .ajc-aviso[hidden] { display: none; }
.ajc-leitura { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 4px 4px 4px 12px; border-radius: 10px; background: var(--ajc-cinza); font-size: 13px; }
.ajc-leitura[hidden] { display: none; }
.ajc-leitura p { display: flex; flex-direction: column; min-width: 0; margin: 0; line-height: 1.35; }
.ajc-leitura-rot { font-weight: 600; color: var(--ajc-texto); }
.ajc-leitura-dono { color: var(--ajc-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ajc-leitura button { flex: none; min-height: 44px; padding: 0 8px; border: 0; background: none; color: var(--ajc-texto); font-size: 13px; font-weight: 500; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.ajc-av:disabled { cursor: default; }
.ajc-av:disabled:hover { color: rgba(107, 114, 128, .8) !important; background: none; }
.ajc-av[aria-pressed="true"]:disabled:hover { color: var(--ajc-roxo) !important; background: var(--ajc-roxo-fundo); }

/* Rodapé: campo de texto */
.ajc-rodape { border-top: 1px solid var(--ajc-linha); padding: 10px 12px calc(8px + env(safe-area-inset-bottom, 0px)); background: #fff; }
.ajc-rodape[hidden] { display: none; }
.ajc-faixa { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin: -2px 0 8px; padding: 6px 6px 6px 10px; border-radius: 10px; background: var(--ajc-roxo-fundo); color: var(--ajc-roxo); font-size: 12.5px; font-weight: 600; }
.ajc-faixa[hidden] { display: none; }
.ajc-faixa span { display: inline-flex; align-items: center; gap: 6px; }
.ajc-faixa svg { width: 16px; height: 16px; }
.ajc-faixa button { border: 0; background: none; min-height: 40px; margin: -4px 0; padding: 0 6px; color: var(--ajc-texto); font-size: 12.5px; font-weight: 500; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.ajc-form { display: flex; align-items: flex-end; gap: 8px; }
.ajc-form textarea { flex: 1; min-height: 46px; max-height: 132px; padding: 11px 14px; resize: none; border-radius: 14px; }
.ajc-enviar { width: 46px; height: 46px; flex: none; border: 0; border-radius: 50%; background: var(--ajc-degrade); color: #fff !important; display: grid; place-items: center; cursor: pointer; transition: transform .15s ease, opacity .15s ease, background-color .15s ease; }
.ajc-enviar svg { width: 20px; height: 20px; }
.ajc-enviar:active { transform: scale(.96); }
.ajc-enviar:disabled { background: rgba(15, 23, 42, .08); color: rgba(107, 114, 128, .8) !important; cursor: default; }
.ajc-enviar:focus-visible { outline: 3px solid rgba(124, 58, 237, .35); outline-offset: 2px; }
.ajc-aviso { margin: 8px 0 0; text-align: center; font-size: 11.5px; color: var(--ajc-muted); }

/* ── Celular ─────────────────────────────────────────────────────────────── */
@media (max-width: 768px) {
    /* Área logada: mesma altura do botão antigo, acima das barras do wizard */
    .ajc-fab.ajc-sistema { right: 16px; bottom: calc(80px + env(safe-area-inset-bottom, 0px)); width: 52px; height: 52px; }
    .ajc-fab.ajc-ajuda { right: 16px; bottom: calc(16px + env(safe-area-inset-bottom, 0px)); }
    .ajc-painel { right: 16px; bottom: calc(144px + env(safe-area-inset-bottom, 0px)); }
    .ajc-painel.ajc-ajuda { bottom: calc(84px + env(safe-area-inset-bottom, 0px)); }
}
@media (max-width: 576px) {
    /* Janela em tela cheia: teclado e polegar */
    .ajc-painel,
    .ajc-painel.ajc-ajuda { inset: 0; width: 100%; height: 100%; height: 100dvh; border-radius: 0; box-shadow: none; }
    .ajc-painel:not(.ajc-visivel) { transform: translateY(16px); }
    .ajc-topo { padding-top: calc(10px + env(safe-area-inset-top, 0px)); }
    .ajc-form textarea, .ajc-p-campo input, .ajc-p-campo textarea { font-size: 16px; } /* o iPhone dá zoom abaixo de 16 px */
    html.ajc-com-painel, html.ajc-com-painel body { overflow: hidden; }
    html.ajc-com-painel .ajc-fab { display: none; }
}

@media (prefers-reduced-motion: reduce) {
    .ajc-fab, .ajc-painel, .ajc-msg, .ajc-pedido, .ajc-fab-ico, .ajc-fab-dica { animation: none; transition: none; }
    .ajc-pontos i { animation-duration: 2.4s; }
    .ajc-corpo { scroll-behavior: auto; }
}

/* Chat bloqueado pelo servidor (uso indevido ou conta em somente leitura) */
.ajc-bloqueio { min-height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; text-align: center; padding: 16px 12px 24px; }
.ajc-bloqueio[hidden] { display: none; }
.ajc-bloq-icone { width: 56px; height: 56px; border-radius: 16px; background: var(--ajc-cinza); color: var(--ajc-muted); display: grid; place-items: center; margin-bottom: 12px; }
.ajc-bloq-icone svg { width: 28px; height: 28px; }
.ajc-bloqueio h3 { margin: 0 0 6px; font-family: var(--ajc-titulo); font-size: 20px; font-weight: 700; color: var(--ajc-texto); text-wrap: balance; }
.ajc-bloqueio p { margin: 0 0 8px; max-width: 300px; color: var(--ajc-muted); text-wrap: pretty; }
