/* ---------- AI ghosts (section 26d) ----------
   What the AI made, before it is kept: the object it would be, see-through, its outline dashed, flat on the canvas
   (no paper shadow: it hasn't landed). Hovered or typed in, its contents show in full. No colour of its own. */
#aig { position: absolute; inset: 0; transform-origin: 0 0; pointer-events: none; }      /* the camera's, as #objs (section 8b) */
#aig > .obj { pointer-events: auto; cursor: grab; background: color-mix(in srgb, var(--surface) 58%, transparent); border-style: dashed; border-color: var(--ink-3); box-shadow: none; }
#aig > .obj > * { opacity: .72; }
@media (hover: hover) { #aig > .obj:hover > * { opacity: 1; } }
#aig > .obj:focus-within > * { opacity: 1; }
#aig > .obj:focus-within { border-color: var(--ink-2); box-shadow: 0 0 0 3px var(--halo); }
#aig > .obj .ed { cursor: text; }
body.ghosting #empty { opacity: 0; visibility: hidden; transition: opacity 120ms ease-out, visibility 0s linear 120ms; }
#aig > .obj.gh-held { cursor: grabbing; box-shadow: var(--pop); }
/* A header has no box: its rule is dashed instead, and its anchor is the ghost's grey. */
#aig > .obj.header, #aig > .obj.header:focus-within { background: transparent; box-shadow: none; }
#aig > .obj.header::after { height: 0; background: none; border-bottom: 1px dashed var(--ink-3); }
#aig > .obj.header::before { background: var(--ink-3); }
/* A board's tile: the tile is the outline, not the box round it and its name. */
#aig > .obj.board[data-view="icon"] { background: transparent; border-color: transparent; }
#aig > .obj.board[data-view="icon"] > .binner { box-shadow: none; outline: 1px dashed var(--ink-3); outline-offset: -1px; background-color: color-mix(in srgb, var(--surface) 58%, transparent); cursor: inherit; }
#aig > .obj.board[data-view="icon"]:focus-within { box-shadow: none; }
#aig .bicon { pointer-events: none; }

/* Over each ghost, its Keep and Discard: a small pill like the dock; under the group, the bar (the preview's, ai.css). */
#aigui { position: fixed; inset: 0; z-index: 11; pointer-events: none; }     /* over the guide, under the rail, as the preview */
.gh-one {
  position: absolute; left: 0; top: 0; display: flex; gap: 1px; padding: 2px; border-radius: 6px; pointer-events: auto;
  background: var(--glass); box-shadow: var(--glass-sh);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); user-select: none; -webkit-user-select: none;
  transition: opacity 120ms ease-out;
}
.gh-one.far { opacity: 0; pointer-events: none; }
.gh-one button {
  display: grid; place-items: center; height: 22px; padding: 0 8px; border: 0; border-radius: 5px; cursor: pointer;
  font: 500 11.5px/1 var(--f-ui); color: var(--ink-2); background: transparent;
  transition: background-color 140ms ease-out, color 140ms ease-out;
}
.gh-one .gh-x { width: 22px; padding: 0; }
.gh-one svg { width: 10px; height: 10px; fill: none; stroke: currentColor; stroke-width: 1.5px; stroke-linecap: round; }
@media (hover: hover) { .gh-one button:hover { color: var(--ink); background: color-mix(in srgb, var(--surface) 90%, transparent); } }
.gh-one button:active { background: var(--press-bg); box-shadow: var(--press); }
.gh-one button:focus-visible { outline: 2px solid var(--ink); outline-offset: 0; }
.gh-bar .btn { flex: none; }
.gh-bar .gh-t { flex: 0 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; }   /* gives way first on a narrow screen */
/* Asking before the level is left: a question in words, not a label. */
.gh-bar.ask .gh-t { font: 500 13px/1 var(--f-ui); letter-spacing: -.005em; text-transform: none; color: var(--ink); }
body.moving #aigui .gh-one, body.sizing #aigui .gh-one, body.drawing #aigui .gh-one, body.panning #aigui .gh-one { opacity: 0; pointer-events: none; }
@media (pointer: coarse) {
  .gh-one button { height: 30px; padding: 0 11px; }
  .gh-one .gh-x { width: 30px; }
  .gh-bar .btn { height: 36px; }
}
/* a mind map's arrows (ai-map.js): ink, not cards; never pressed (they go with their ends) */
#aig > .obj.arrow { background: none; border: 0; pointer-events: none; cursor: default; }
#aig > .obj.arrow .ar-hit, #aig > .obj.arrow > .ar-lb { pointer-events: none; }
#aig > .obj.arrow:not([data-label]) > .ar-lb { opacity: 0; }       /* no words: no placeholder (a ghost's parts are see-through, not hidden) */
