/*
 * A viewer looks; they change nothing. The dashboard wrapper carries the
 * person's role (components/shell/shell.tsx, `data-role`), and every control
 * that would change a prompt, a competitor, the project's settings or an
 * article is hidden for a viewer. The worker refuses those changes anyway;
 * this only spares the viewer a button that answers "view-only".
 *
 * Project settings' fields are read-only and Articles' controls are left out
 * on the server (lib/live/project-settings.ts, components/articles/page.tsx);
 * what is here is the rest.
 */

/* Prompts: Add prompts, a prompt's "…" menu (edit, tags, pause), and the selection bar's
   changes (the bar is appended to <body>, outside the wrapper). Export stays. */
[data-role="viewer"] [data-add-prompts],
[data-role="viewer"] [data-prompt-actions],
body:has([data-role="viewer"]) .gn-selbar [data-sel="pause"],
body:has([data-role="viewer"]) .gn-selbar [data-sel="resume"],
body:has([data-role="viewer"]) .gn-selbar [data-sel="tag"],
/* Competitors: the add form, Edit and Remove. */
[data-role="viewer"] form[data-getnodded-brands],
[data-role="viewer"] button[data-competitor-edit],
[data-role="viewer"] button[data-competitor],
/* Project settings: the Save rows and the danger zone. */
[data-role="viewer"] [data-settings-section="project"] [data-slot="card-footer"],
[data-role="viewer"] [data-settings-section="models"] [data-slot="card-footer"],
[data-role="viewer"] #danger-zone,
/* Article settings: the Save rows, the reference image and the destinations' actions. */
[data-role="viewer"] .ar-settings .ar-card > footer,
[data-role="viewer"] .ar-settings .ar-upload,
[data-role="viewer"] .ar-settings .ar-reference > button,
[data-role="viewer"] .ar-settings .ar-integration-actions {
  display: none !important;
}

/* A prompt's Active switch still shows its state; it just doesn't switch. */
[data-role="viewer"] [role="switch"][data-prompt-id] {
  pointer-events: none;
}
