/* report-wizard.css — Fire Strategy mode, "Create a report"
   The four-step setup that runs before the B1-B5 interview.

   Built from the same --gxr-* tokens as report-assistant.css, which are
   declared there on both :root and .gx-report-screen. This screen is a body
   child and NOT inside .gx-report-screen, which is why that block has to stay
   on :root — every var() below resolves through it. Each one keeps a fallback
   so the wizard still reads correctly if the report stylesheet is ever
   loaded after this one. */

/* While the wizard is up, NOTHING else is. #app was being revealed for a frame
   on every step because enterProject -> hideProjectsLanding sets its inline
   display back to '' — and the wizard triggers that on the way in, and again
   through toggleSource on every guidance click. An inline style could not win
   that race; this rule does, and it is dropped in exactly one place. */
body.gx-wizard-active #app,
body.gx-wizard-active .gf-projects-landing,
body.gx-wizard-active .gx-launcher { display: none !important; }

.gx-wiz {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: flex;
  flex-direction: column;
  background: var(--gxr-canvas, #fafbfc);
  color: var(--gxr-ink, #1a1d20);
  font-family: var(--gxr-font, Inter, sans-serif);
}

/* ── top bar ─────────────────────────────────────────────────────────────── */
.gx-wiz-bar {
  flex: none;
  display: flex;
  align-items: center;
  gap: 10px;
  height: 64px;
  padding: 0 20px;
  background: var(--gxr-surface, #fff);
  border-bottom: 1px solid var(--gxr-border, #e5e7eb);
}
.gx-wiz-back-arrow {
  width: 30px; height: 30px;
  display: grid; place-items: center;
  border: 0; border-radius: var(--gxr-r-btn, 6px);
  background: transparent; color: var(--gxr-muted, #6b7280);
  font-size: 18px; line-height: 1; cursor: pointer;
  transition: background .16s, color .16s;
}
.gx-wiz-back-arrow:hover { background: var(--gxr-hover, #edf0ee); color: var(--gxr-ink, #1a1d20); }
.gx-wiz-bar .gx-lockup-sym { color: var(--gxr-brand, #63c76a); font-weight: 700; }
.gx-wiz-crumb { font-size: 13px; font-weight: 500; color: var(--gxr-muted, #6b7280); white-space: nowrap; }
.gx-wiz-sep { color: var(--gxr-muted-2, #9ca3af); padding: 0 4px; }
.gx-wiz-step-chip {
  font-size: 11.5px; font-weight: 600;
  color: var(--gxr-muted, #6b7280);
  background: var(--gxr-track, #e8ebe9);
  border-radius: var(--gxr-r-chip, 4px);
  padding: 4px 8px; white-space: nowrap;
}
.gx-wiz-title {
  margin: 0 0 0 6px;
  font-family: var(--gxr-font-display, 'Rethink Sans', Inter, sans-serif);
  font-size: 17px; font-weight: 700; letter-spacing: -.02em;
  color: var(--gxr-ink, #1a1d20);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.gx-wiz-bar-actions { margin-left: auto; display: flex; gap: 8px; }

/* ── step rail ───────────────────────────────────────────────────────────── */
.gx-wiz-rail {
  flex: none;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  background: var(--gxr-surface, #fff);
  border-bottom: 1px solid var(--gxr-border, #e5e7eb);
  padding: 0 20px;
}
.gx-wiz-step {
  display: flex; align-items: center; gap: 10px;
  border: 0; background: transparent;
  padding: 14px 8px;
  font: 500 13px var(--gxr-font, Inter, sans-serif);
  color: var(--gxr-muted-2, #9ca3af);
  cursor: pointer;
  transition: color .16s;
}
.gx-wiz-step:disabled { cursor: default; }
.gx-wiz-step:not(:disabled):hover { color: var(--gxr-ink, #1a1d20); }
.gx-wiz-step-mark {
  width: 22px; height: 22px; flex: none;
  display: grid; place-items: center;
  border: 1px solid var(--gxr-border-strong, #d1d5db);
  border-radius: 50%;
  font-size: 11px; font-weight: 700;
  background: var(--gxr-surface, #fff);
}
/* Done and current are told apart by the GLYPH first — a tick against a
   number — so the two states never rest on colour alone. */
.gx-wiz-step.is-done { color: var(--gxr-ink-soft, #374151); }
.gx-wiz-step.is-done .gx-wiz-step-mark {
  background: var(--gxr-accent, #2f9c58);
  border-color: var(--gxr-accent, #2f9c58);
  color: #fff;
}
.gx-wiz-step.is-current { color: var(--gxr-ink, #1a1d20); font-weight: 600; }
.gx-wiz-step.is-current .gx-wiz-step-mark {
  border-color: var(--gxr-accent, #2f9c58);
  color: var(--gxr-accent-ink, #2f9c58);
  box-shadow: 0 0 0 3px var(--gxr-focus, rgba(99,199,106,.09));
}

/* ── the panel ───────────────────────────────────────────────────────────── */
.gx-wiz-scroll { flex: 1; min-height: 0; overflow-y: auto; padding: 32px 24px 40px; }
.gx-wiz-panel {
  width: 100%; max-width: 900px; margin: 0 auto;
  background: var(--gxr-surface, #fff);
  border: 1px solid var(--gxr-border, #e5e7eb);
  border-radius: var(--gxr-r-card, 16px);
  padding: 32px;
}
.gx-wiz-lede { margin: 0 0 18px; font-size: 13.5px; line-height: 1.6; color: var(--gxr-muted, #6b7280); }
.gx-wiz-note { margin: 20px 0 0; font-size: 12px; color: var(--gxr-muted-2, #9ca3af); }

/* ── step 1: guidance ────────────────────────────────────────────────────── */
.gx-wiz-guides { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.gx-wiz-guide {
  display: flex; align-items: center; gap: 10px;
  text-align: left;
  border: 1px solid var(--gxr-border, #e5e7eb);
  border-radius: var(--gxr-r-ctl, 12px);
  background: var(--gxr-surface, #fff);
  padding: 13px 15px;
  font: 500 13.5px var(--gxr-font, Inter, sans-serif);
  color: var(--gxr-ink, #1a1d20);
  cursor: pointer;
  transition: border-color .16s, background .16s;
}
.gx-wiz-guide:hover:not(:disabled) { border-color: var(--gxr-border-strong, #d1d5db); background: var(--gxr-hover, #edf0ee); }
.gx-wiz-guide:disabled { opacity: .5; cursor: wait; }
.gx-wiz-guide.is-on {
  border-color: var(--gxr-accent, #2f9c58);
  background: var(--gxr-tint, rgba(99,199,106,.10));
  color: var(--gxr-accent-ink, #2f9c58);
}
.gx-wiz-guide-tick {
  width: 18px; height: 18px; flex: none;
  display: grid; place-items: center;
  border: 1px solid var(--gxr-border-strong, #d1d5db);
  border-radius: var(--gxr-r-chip, 4px);
  font-size: 11px; font-weight: 700;
  background: var(--gxr-surface, #fff);
}
.gx-wiz-guide.is-on .gx-wiz-guide-tick {
  background: var(--gxr-accent, #2f9c58);
  border-color: var(--gxr-accent, #2f9c58);
  color: #fff;
}
.gx-wiz-guide-name { flex: 1; }
.gx-wiz-guide-badge {
  font-size: 10.5px; font-weight: 600;
  color: var(--gxr-muted, #6b7280);
  background: var(--gxr-track, #e8ebe9);
  border-radius: var(--gxr-r-chip, 4px);
  padding: 3px 7px;
}

/* ── step 2: project context ─────────────────────────────────────────────── */
.gx-wiz-guide-chips { display: flex; flex-wrap: wrap; gap: 7px; margin-bottom: 26px; }
.gx-wiz-guide-chips span {
  font-size: 11.5px; font-weight: 600;
  color: var(--gxr-accent-ink, #2f9c58);
  background: var(--gxr-tint, rgba(99,199,106,.10));
  border: 1px solid var(--gxr-accent, #2f9c58);
  border-radius: var(--gxr-r-pill, 999px);
  padding: 4px 11px;
}
.gx-wiz-group + .gx-wiz-group { border-top: 1px solid var(--gxr-border, #e5e7eb); margin-top: 28px; padding-top: 28px; }
.gx-wiz-group-label {
  font-size: 11px; font-weight: 600;
  letter-spacing: .11em; text-transform: uppercase;
  color: var(--gxr-muted, #6b7280);
  margin-bottom: 18px;
}
.gx-wiz-questions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px 24px; }
.gx-wiz-q { display: flex; flex-direction: column; min-width: 0; }
.gx-wiz-q label { font-size: 14px; font-weight: 600; color: var(--gxr-ink, #1a1d20); }
.gx-wiz-q-help { font-size: 12px; line-height: 1.45; color: var(--gxr-muted, #6b7280); margin: 3px 0 8px; }
.gx-wiz-q select,
.gx-wiz-q input {
  box-sizing: border-box; width: 100%;
  border: 1px solid var(--gxr-border-strong, #d1d5db);
  border-radius: var(--gxr-r-btn, 6px);
  background: var(--gxr-surface, #fff);
  color: var(--gxr-ink, #1a1d20);
  font: 13.5px var(--gxr-font, Inter, sans-serif);
  padding: 10px 11px;
}
.gx-wiz-q input { margin-top: 7px; font-size: 12.5px; }
.gx-wiz-q select:focus,
.gx-wiz-q input:focus {
  outline: none;
  border-color: var(--gxr-accent, #2f9c58);
  box-shadow: 0 0 0 3px var(--gxr-focus, rgba(99,199,106,.09));
}

/* What the form is deliberately NOT asking. Without this an engineer cannot
   tell a short form from a broken one. */
.gx-wiz-hidden {
  margin: 26px 0 0;
  border: 1px dashed var(--gxr-border-strong, #d1d5db);
  border-radius: var(--gxr-r-ctl, 12px);
  background: var(--gxr-surface-2, #f2f4f3);
  padding: 12px 15px;
  font-size: 12.5px; color: var(--gxr-muted, #6b7280);
}

/* ── steps 3 and 4 ───────────────────────────────────────────────────────── */
.gx-wiz-drop {
  display: block; width: 100%; text-align: left;
  border: 1px dashed var(--gxr-border-strong, #d1d5db);
  border-radius: var(--gxr-r-ctl, 12px);
  background: var(--gxr-surface-2, #f2f4f3);
  padding: 22px;
  cursor: pointer;
  transition: border-color .16s, background .16s;
}
.gx-wiz-drop:hover { border-color: var(--gxr-accent, #2f9c58); background: var(--gxr-tint, rgba(99,199,106,.10)); }
.gx-wiz-drop strong { display: block; font-size: 14.5px; color: var(--gxr-ink, #1a1d20); margin-bottom: 4px; }
.gx-wiz-drop span { display: block; font-size: 12.5px; color: var(--gxr-muted, #6b7280); }
.gx-wiz-list { margin-top: 14px; }
.gx-wiz-list-row {
  display: flex; align-items: center; gap: 10px;
  border: 1px solid var(--gxr-border, #e5e7eb);
  border-radius: var(--gxr-r-btn, 6px);
  padding: 10px 13px; margin-bottom: 7px;
  font-size: 13px; color: var(--gxr-ink-soft, #374151);
  overflow-wrap: anywhere;
}
.gx-wiz-row-mark {
  width: 20px; height: 20px; flex: none;
  display: grid; place-items: center;
  border-radius: 50%;
  font-size: 11px; font-weight: 700;
}
.gx-wiz-row-name { flex: 1; min-width: 0; }
.gx-wiz-row-note { font-size: 11.5px; white-space: nowrap; }
/* A pinned plan against an unpinned one. The GLYPH and the WORDS carry the
   state — a tick and a count against an exclamation mark and the word
   "incomplete" — so the pair never rests on green-versus-amber alone. */
.gx-wiz-list-row.is-ok .gx-wiz-row-mark {
  background: var(--gxr-tint, rgba(99,199,106,.10));
  color: var(--gxr-accent-ink, #2f9c58);
}
.gx-wiz-list-row.is-ok .gx-wiz-row-note { color: var(--gxr-muted, #6b7280); }
.gx-wiz-list-row.is-todo {
  border-color: var(--gxr-amber-border, #e5ca7e);
  background: var(--gxr-amber-bg, #fff7df);
}
.gx-wiz-list-row.is-todo .gx-wiz-row-mark,
.gx-wiz-list-row.is-todo .gx-wiz-row-note { color: var(--gxr-amber, #7b5b0c); }
.gx-wiz-list-row.is-todo .gx-wiz-row-note { font-weight: 600; }
.gx-wiz-list-empty { font-size: 12.5px; color: var(--gxr-muted-2, #9ca3af); padding: 6px 2px; }

/* The two halves of the evidence step. A rule between them, not a card each —
   they are one job, and boxing them would undo the merge. */
.gx-wiz-half + .gx-wiz-half {
  border-top: 1px solid var(--gxr-border, #e5e7eb);
  margin-top: 30px; padding-top: 30px;
}
.gx-wiz-half-title {
  display: flex; align-items: center; gap: 9px;
  margin: 0 0 4px;
  font-family: var(--gxr-font-display, 'Rethink Sans', Inter, sans-serif);
  font-size: 16px; font-weight: 700; letter-spacing: -.02em;
  color: var(--gxr-ink, #1a1d20);
}
.gx-wiz-optional {
  font-family: var(--gxr-font, Inter, sans-serif);
  font-size: 10.5px; font-weight: 600;
  letter-spacing: .06em; text-transform: uppercase;
  color: var(--gxr-muted, #6b7280);
  background: var(--gxr-track, #e8ebe9);
  border-radius: var(--gxr-r-chip, 4px);
  padding: 3px 7px;
}
.gx-wiz-half-sub { margin: 0 0 14px; font-size: 12.5px; line-height: 1.55; color: var(--gxr-muted, #6b7280); }

/* ── footer ──────────────────────────────────────────────────────────────── */
.gx-wiz-foot {
  flex: none;
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px;
  padding: 16px 24px;
  background: var(--gxr-surface, #fff);
  border-top: 1px solid var(--gxr-border, #e5e7eb);
}
.gx-wiz-quiet {
  border: 1px solid var(--gxr-border, #e5e7eb);
  border-radius: var(--gxr-r-btn, 6px);
  background: transparent;
  color: var(--gxr-ink-soft, #374151);
  padding: 9px 14px;
  font: 600 12.5px var(--gxr-font, Inter, sans-serif);
  cursor: pointer;
  transition: background .16s, border-color .16s;
}
.gx-wiz-quiet:hover { background: var(--gxr-hover, #edf0ee); border-color: var(--gxr-border-strong, #d1d5db); }
.gx-wiz-next {
  border: 0;
  border-radius: var(--gxr-r-ctl, 12px);
  background: var(--gxr-ink, #1a1d20);
  color: #fff;
  padding: 11px 18px;
  font: 600 13px var(--gxr-font, Inter, sans-serif);
  cursor: pointer;
  transition: background .16s;
}
.gx-wiz-next:hover:not(:disabled) { background: var(--gxr-accent, #2f9c58); }
.gx-wiz-next:disabled { opacity: .5; cursor: not-allowed; }

@media (max-width: 860px) {
  .gx-wiz-crumb, .gx-wiz-title { display: none; }
  .gx-wiz-rail { grid-template-columns: repeat(4, auto); overflow-x: auto; }
  .gx-wiz-step-name { display: none; }
  .gx-wiz-scroll { padding: 18px 12px 32px; }
  .gx-wiz-panel { padding: 20px; border-radius: var(--gxr-r-ctl, 12px); }
  .gx-wiz-questions, .gx-wiz-guides { grid-template-columns: minmax(0, 1fr); }
}
