/* Send queue: one list per data date, with 出队 and 一键发送. */
#report-queue-panel { padding: 20px 24px 16px; scroll-margin-top: 80px; }
.queue-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.queue-title h3 { margin: 0 0 3px; font-size: 16px; font-weight: 650; color: var(--ink); }
.queue-meta { margin: 0; font-size: 12px; color: var(--muted); }
.queue-service { margin-left: 8px; font-size: 12px; color: var(--muted); }
.queue-service.warn { color: #a2512f; }
.queue-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.queue-actions button { padding: 8px 14px; font-size: 12px; border-radius: 8px; }
.queue-feedback { margin: 8px 0 0; font-size: 12px; color: var(--muted); }
.queue-feedback:empty { display: none; }
#queue-items { max-height: min(520px, calc(100dvh - 320px)); overflow-y: auto; scrollbar-width: none; }
#queue-items::-webkit-scrollbar { display: none; }

.queue-row { padding: 12px 0; border-top: 1px solid var(--line); }
.queue-row:first-child { border-top: 0; }
.queue-row-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.queue-row-head strong { font-size: 14px; color: var(--ink); }
.queue-store { font-size: 12px; color: var(--muted); }
.queue-row-actions { display: flex; gap: 6px; margin-left: auto; }
.queue-row-actions button { padding: 4px 10px; font-size: 12px; border-radius: 7px; }
.queue-row-actions:empty { display: none; }

.queue-state { font-size: 11px; padding: 1px 8px; border-radius: 6px; background: #eef4f0; color: #46604f; }
.queue-state[data-state="pending"] { background: #eaf1fb; color: #2f5c93; }
.queue-state[data-state="sending"] { background: #e8f0fb; color: #2b5f9e; }
.queue-state[data-state="sent"] { background: #e4f2e9; color: #1f6b4a; }
.queue-state[data-state="failed"] { background: #fdecec; color: #9c3232; }
.queue-state[data-state="unknown"] { background: #fff3df; color: #8a5a12; }
.queue-state[data-state="cancelled"] { background: #f0f1f1; color: #6b7772; }

.queue-warn { margin: 6px 0 0; font-size: 12px; color: #8b5713; }
.queue-body { margin-top: 4px; }
.queue-body > summary { font-size: 12px; color: #235f52; cursor: pointer; }
.queue-content { margin: 8px 0 0; padding: 12px 14px; background: #f4f7f5; border-radius: 8px;
  font: inherit; font-size: 12px; line-height: 1.7; white-space: pre-wrap; overflow-wrap: anywhere; max-height: 300px; overflow: auto; }

.queue-empty { margin: 10px 0 0; font-size: 12px; color: var(--muted); }
.queue-note { margin: 8px 0 0; font-size: 12px; line-height: 1.7; color: var(--muted); }
.queue-note[hidden] { display: none; }
.queue-note .text-button { margin-left: 4px; font-size: 12px; color: #2f6b56; text-decoration: underline; text-underline-offset: 3px; }
.queue-empty[hidden] { display: none; }

@media (max-width: 700px) {
  #report-queue-panel { padding: 16px 16px 12px; }
  .queue-actions { width: 100%; }
  .queue-actions button { flex: 1 1 auto; }
  .queue-row-actions { margin-left: 0; width: 100%; }
  .queue-row-actions button { flex: 1 1 auto; }
}

/* 接收群卡片将群名和公司/原因分行，避免说明挤占群名宽度。 */
.group-picker-dialog { width: min(620px, calc(100vw - 24px)); height: auto; max-height: min(680px, calc(100dvh - 32px)); }
.group-picker-dialog .report-detail-content { flex: 1 1 auto; min-height: 0; overflow: hidden; }
.group-picker { display: flex; flex-direction: column; gap: 10px; min-width: 0; height: auto; max-height: 100%; box-sizing: border-box; overflow-x: hidden; padding: 18px 22px 20px; }
.group-picker-note { margin: 0; font-size: 13px; color: var(--muted); }
.group-picker-search { width: 100%; box-sizing: border-box; padding: 9px 12px; font-size: 13px; }
.group-picker-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 8px 2px; border-bottom: 1px solid var(--line); flex: 0 0 auto; }
.group-picker-all { flex: 0 0 auto; padding: 5px 14px; font-size: 12px; border-radius: 7px; }
.group-picker-count { font-size: 12px; color: var(--muted); }
.group-picker-list { display: flex; flex-direction: column; gap: 10px; flex: 1 1 auto; min-height: 0; max-height: 46vh; overflow-y: auto; overflow-x: hidden; padding: 2px; }
.group-picker-dialog .group-picker-row { display: grid; grid-template-columns: 18px minmax(0, 1fr); align-items: start; gap: 6px 10px; flex: 0 0 auto; padding: 14px; margin: 0; border: 1px solid var(--line); border-radius: 12px; background: #fff; font-size: 13px; cursor: pointer; min-width: 0; }
.group-picker-dialog .group-picker-row:has(input:checked) { border-color: var(--green); background: #f0f7f3; }
.group-picker-dialog .group-picker-row:focus-within { outline: 2px solid var(--green); outline-offset: -2px; }
.group-picker-row input { grid-column: 1; grid-row: 1; width: 16px; height: 16px; margin: 3px 0 0; padding: 0; }
.group-picker-name { grid-column: 2; min-width: 0; overflow-wrap: anywhere; white-space: normal; line-height: 1.6; font-weight: 600; color: var(--ink); }
.group-picker-company { grid-column: 2; min-width: 0; overflow-wrap: anywhere; white-space: normal; font-size: 12px; line-height: 1.7; color: var(--muted); }
.group-picker-feedback { margin: 0; font-size: 12px; color: var(--muted); }
.group-picker-feedback:empty { display: none; }
.group-picker-footer { display: flex; justify-content: flex-end; gap: 8px; padding-top: 4px; flex: 0 0 auto; }
.group-picker-footer button { padding: 8px 16px; font-size: 13px; border-radius: 8px; }


.group-picker-dialog .group-picker-row.disabled { cursor: not-allowed; color: var(--muted); background: #f6f8f6; border-style: dashed; }
.group-picker-row.disabled .group-picker-name { color: var(--muted); }
.group-picker-company:empty { display: none; }
