/* Mais um item no rodapé da lista de membros, com a cara de uma linha de membro e um traço separando da lista.
   Fica na linha da barra de conversar: a mesma altura (46px) e o mesmo espaço embaixo (os 24px do "digitando…").
   Só aparece quando a lista está visível, para nunca disputar espaço com o chat, a call ou o chat da call.
   No celular, fica nas Configurações. Largura: a coluna de membros (240px; a gaveta do tablet tem 260px). */
.feedback-link {
  position: fixed; right: var(--dock-gap); bottom: 24px; z-index: 8;
  display: none; align-items: center; gap: 12px; width: 223px; height: 46px; margin: 0; padding: 0 10px;
  border: 0; border-radius: 8px; background: transparent;
  color: var(--interactive); font-size: 14px; font-weight: 500; text-align: left;
}
.feedback-link::before { content: ''; position: absolute; top: -9px; left: 2px; right: 2px; height: 1px; background: var(--divider); }
.feedback-link-icon {
  display: grid; place-items: center; flex-shrink: 0; width: 32px; height: 32px; border-radius: 50%;
  background: var(--hover-strong); color: var(--text);
}
/* A bolinha do dev (verde online, cinza offline) fica à esquerda do ícone; o resto anda um pouco para a direita. */
.feedback-link .feedback-dot { margin: 0 -4px 0 2px; }
.feedback-link:hover { color: var(--text); background: var(--hover); }
.feedback-link:hover .feedback-link-icon { color: var(--text-strong); }
.feedback-link:focus-visible { outline: 2px solid var(--focus-ring); outline-offset: 2px; }
@media (min-width: 1101px) {
  #app:not(.hide-members) > .feedback-link { display: flex; }
  #app:not(.hide-members) > #members { padding-bottom: 92px; }
}
@media (min-width: 641px) and (max-width: 1100px) {
  #app.members-open > .feedback-link { display: flex; z-index: 14; width: 243px; }
  #app.members-open > #members { padding-bottom: 92px; }
}
body.stream-immersive .feedback-link { display: none !important; }
.feedback-overlay {
  position: fixed; inset: 0; z-index: 45; display: grid; place-items: center;
  padding: 20px; background: rgba(6, 6, 8, .8);
}
.feedback-card {
  position: relative; width: min(480px, 100%); max-height: calc(100dvh - 40px); overflow-y: auto;
  padding: 28px; border: 1px solid var(--divider); border-radius: 16px;
  background: var(--bg-sidebar); box-shadow: 0 24px 80px #0006;
}
.feedback-close {
  position: absolute; top: 14px; right: 14px; width: 32px; height: 32px; display: grid; place-items: center;
  padding: 0; border: 0; border-radius: 8px; background: transparent; color: var(--text-muted);
}
.feedback-close:hover { background: var(--hover); color: var(--text-strong); }
.feedback-mark {
  width: 44px; height: 44px; display: grid; place-items: center; border-radius: 12px;
  background: color-mix(in srgb, var(--brand) 13%, transparent); color: var(--brand); margin-bottom: 18px;
}
.feedback-card h2 { margin: 0 28px 10px 0; color: var(--text-strong); font-size: 24px; letter-spacing: -.025em; }
.feedback-card p { margin: 0 0 20px; font-size: 14px; line-height: 1.6; color: var(--interactive); }
.feedback-card label { display: block; font-size: 12px; font-weight: 600; color: var(--text); margin-bottom: 8px; }
.feedback-card textarea {
  display: block; width: 100%; min-height: 148px; max-height: 260px; resize: vertical;
  padding: 12px 14px; border: 1px solid var(--divider); border-radius: 9px;
  font-size: 15px; line-height: 1.6; color: var(--text-strong); background: var(--bg-panel);
}
.feedback-card textarea:focus { outline: 2px solid var(--focus-ring); outline-offset: 1px; }
.feedback-card textarea::placeholder { color: var(--text-muted); }
.feedback-meta { display: flex; justify-content: space-between; gap: 12px; margin-top: 8px; color: var(--text-muted); font-size: 11px; }
.feedback-meta span:first-child { min-width: 0; }
#feedback-count { flex-shrink: 0; font-variant-numeric: tabular-nums; }
/* Como enviar: e-mail (padrão) ou mensagem direta para o dev, com a bolinha verde (online) ou cinza (offline). */
.feedback-via { margin: 18px 0 0; padding: 0; border: 0; min-width: 0; }
.feedback-via legend { padding: 0; margin-bottom: 8px; font-size: 12px; font-weight: 600; color: var(--text); }
.feedback-via-options { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.feedback-card label.feedback-option {
  position: relative; display: flex; align-items: center; justify-content: center; gap: 8px; margin: 0; min-height: 42px; padding: 8px 12px;
  border: 1px solid var(--divider); border-radius: 9px; background: var(--bg-panel);
  color: var(--interactive); font-size: 13px; font-weight: 500; cursor: pointer;
  transition: border-color var(--motion-fast, .12s) ease, background-color var(--motion-fast, .12s) ease, color var(--motion-fast, .12s) ease;
}
.feedback-option input { position: absolute; opacity: 0; pointer-events: none; }
.feedback-card label.feedback-option:hover { color: var(--text-strong); background: var(--hover); }
.feedback-card label.feedback-option:has(input:checked) { border-color: var(--brand); color: var(--text-strong); background: color-mix(in srgb, var(--brand) 12%, var(--bg-panel)); }
.feedback-option:has(input:focus-visible) { outline: 2px solid var(--focus-ring); outline-offset: 2px; }
.feedback-dot { flex-shrink: 0; width: 9px; height: 9px; border-radius: 50%; background: var(--text-muted); transition: background-color .2s ease; }
.feedback-dot.online { background: var(--green); box-shadow: 0 0 0 3px color-mix(in srgb, var(--green) 22%, transparent); }
.feedback-card p.feedback-via-note { margin: 8px 0 0; font-size: 12px; line-height: 1.5; color: var(--text-muted); }
.feedback-card p.feedback-status { margin: 12px 0 0; font-size: 12px; }
.feedback-status:empty { display: none; }
.feedback-card p.feedback-status.error { color: var(--red); }
.feedback-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 22px; }
.feedback-actions button { padding: 10px 16px; border: 0; border-radius: 8px; font-size: 13px; }
.feedback-actions .feedback-cancel { background: transparent; color: var(--text-muted); }
.feedback-actions .feedback-cancel:hover { background: var(--hover); color: var(--text-strong); }
.feedback-actions .feedback-submit { background: var(--brand); color: #fff; font-weight: 600; }
.feedback-actions .feedback-submit:hover:not(:disabled) { background: var(--brand-hover); }
.feedback-actions button:disabled { opacity: .5; }
.feedback-actions button:focus-visible, .feedback-close:focus-visible { outline: 2px solid var(--focus-ring); outline-offset: 3px; }
.feedback-success-mark { color: var(--green); background: color-mix(in srgb, var(--green) 12%, transparent); }
@media (max-width: 640px) {
  .feedback-overlay { padding: 12px; }
  .feedback-card { padding: 24px 20px; max-height: calc(100dvh - 24px); }
  .feedback-card label.feedback-option { gap: 6px; padding: 8px; font-size: 12.5px; white-space: nowrap; }
  /* No celular, o rodapé das Configurações vira uma fileira abaixo das abas: é aqui que Propor Melhorias mora. */
  /* Quebra em duas linhas em vez de rolar de lado: "Sair da conta" aparecia cortado no meio da palavra, sem sinal de que havia mais. */
  #settings .settings-nav-bottom { display: flex; flex-direction: row; flex-wrap: wrap; gap: 4px 6px; margin: 0; padding: 8px 0 0; }
  #settings .settings-nav-bottom button { width: auto; flex-shrink: 0; gap: 6px; padding: 8px 10px; font-size: 12px; white-space: nowrap; }
  #settings .settings-nav-bottom .settings-version { display: block; width: auto; padding: 8px 4px; }
}
