/* Feedback button (bottom-right on every screen), its form, and Dom's list
   in Settings → Account (js/modules/feedback.js). High Contrast look: the
   --hc-* colours come from look-hc.css, so Dark mode follows on its own.
   Label text, not colour, tells every state apart. */

/* Above the Settings page (950), under popups' dimmed backdrops (1000+).
   #app and the Settings page leave room at the bottom, so scrolled-down
   content (Knew It / Needs Work, Got It) can always sit clear of it. */
.fb-btn {
  position: fixed;
  right: calc(12px + env(safe-area-inset-right));
  bottom: calc(12px + env(safe-area-inset-bottom));
  z-index: 960;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 36px;
  padding: 6px 12px 6px 8px;
  border: 2px solid var(--hc-line);
  border-radius: 4px;
  background: var(--hc-surface);
  color: var(--hc-ink);
  box-shadow: 3px 3px 0 var(--hc-shadow);
  font: 700 0.8rem/1 var(--font);
  cursor: pointer;
}
.fb-btn .ic { padding: 3px; border: 1.5px solid var(--hc-line); border-radius: 3px; background: var(--hc-accent); color: var(--hc-on-accent); box-sizing: content-box; }
.fb-btn:hover { background: var(--hc-surface-2); }
.fb-btn:active { transform: translate(2px, 2px); box-shadow: 1px 1px 0 var(--hc-shadow); }
.fb-btn:focus-visible { outline: 3px solid var(--hc-accent); outline-offset: 2px; }
/* Out of the way of bars that sit at the bottom of the screen. */
body:has(.select-bar) .fb-btn, body:has(.undo-toast) .fb-btn { bottom: calc(84px + env(safe-area-inset-bottom)); }
#settings-page .sp-wrap { padding-bottom: 72px; }
@media print { .fb-btn { display: none; } }

/* The form */
.fb-dialog { width: min(440px, calc(100vw - 32px)); padding: 18px 18px 16px; box-sizing: border-box; font-family: var(--font); }
.fb-dialog h2 { margin: 0 0 4px; font-size: 1.3rem; }
.fb-hint { margin: 4px 0; font-size: 0.82rem; color: var(--hc-muted); }
.fb-types { display: flex; gap: 8px; margin: 12px 0; flex-wrap: wrap; }
.fb-type {
  min-height: 40px; padding: 6px 14px;
  border: 2px solid var(--hc-line); border-radius: 4px;
  background: var(--hc-surface); color: var(--hc-ink);
  font: 700 0.9rem var(--font); cursor: pointer;
}
.fb-type.selected { background: var(--hc-fill); border-color: var(--hc-fill); color: var(--hc-on-fill); }
.fb-label { display: block; margin: 4px 0; font-weight: 700; font-size: 0.9rem; }
.fb-dialog textarea {
  display: block; width: 100%; box-sizing: border-box; min-height: 120px; resize: vertical;
  padding: 10px; border: 2px solid var(--hc-line); border-radius: 4px;
  background: var(--hc-surface); color: var(--hc-ink); font: 1rem/1.4 var(--font);
}
.fb-dialog textarea:focus { outline: 3px solid var(--hc-accent); outline-offset: 1px; }
.fb-msg { min-height: 1.2em; margin: 6px 0; font-weight: 700; font-size: 0.9rem; }
.fb-actions { display: flex; gap: 10px; }
.fb-actions .btn { flex: 1; display: inline-flex; align-items: center; justify-content: center; gap: 6px; }
.fb-done { text-align: center; padding: 8px 0 0; }
.fb-done-text { margin: 8px 0 4px; font-size: 1.4rem; font-weight: 700; }
.fb-done .btn { width: 100%; margin-top: 12px; }

/* Dom's list */
.fb-inbox h3 { margin: 12px 0 2px; font-size: 1rem; }
.fb-inbox-list { list-style: none; margin: 8px 0 0; padding: 0; }
.fb-item { padding: 10px 0; border-top: 2px solid var(--hc-line); }
.fb-item-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 8px; }
.fb-badge { padding: 1px 6px; border: 2px solid var(--hc-line); border-radius: 3px; font-size: 0.72rem; font-weight: 700; text-transform: uppercase; background: var(--hc-accent); color: var(--hc-on-accent); }
.fb-item.is-read .fb-badge { background: var(--hc-surface); color: var(--hc-muted); }
.fb-item-text { margin: 6px 0; white-space: pre-wrap; overflow-wrap: anywhere; }
.fb-item details { overflow-wrap: anywhere; }
.fb-item-actions { display: flex; gap: 8px; }
.fb-item-actions .us-data-btn { margin: 6px 0 0; }
