/* The Generations pane: a right-hand column of job cards, in the style of the video tools. It sits beside the page and pushes it; on a narrow screen, and over the editor, it floats above instead. */
#activity { flex: none; width: 0; overflow: hidden; background: var(--bg-2); border-left: 0 solid var(--line); transition: width .18s ease; position: relative; z-index: 30; }
#activity[hidden] { display: none; }
body.act-open #activity { width: 372px; border-left-width: 1px; }
.act-in { width: 372px; height: 100%; display: flex; flex-direction: column; min-height: 0; }
.act-head { flex: none; height: var(--nav-h); display: flex; align-items: center; gap: 8px; padding: 0 10px 0 16px; border-bottom: 1px solid var(--line); }
.act-head h2 { margin: 0; font-size: 15px; font-weight: 650; letter-spacing: -.005em; }
.act-tabs { flex: none; display: flex; flex-wrap: wrap; gap: 4px; padding: 10px 12px 8px; }
.act-tab { display: inline-flex; align-items: center; gap: 5px; padding: 5px 9px; border-radius: 999px; border: 1px solid transparent; background: none; color: var(--muted); font-size: 12.5px; font-weight: 600; cursor: pointer; }
.act-tab:hover { color: var(--text); background: var(--panel); } .act-tab.on { background: var(--accent-bg); color: var(--accent-2); border-color: rgba(108, 140, 255, .35); }
.act-tab .n { font-size: 11px; font-variant-numeric: tabular-nums; padding: 0 6px; border-radius: 99px; background: var(--panel-3); color: var(--text); }
.act-scroll { flex: 1 1 auto; min-height: 0; overflow-y: auto; padding: 4px 12px 18px; scrollbar-width: thin; }
.act-list { display: flex; flex-direction: column; gap: 12px; }
.act-empty { text-align: center; color: var(--muted); padding: 56px 20px; display: flex; flex-direction: column; align-items: center; gap: 12px; } .act-empty .ic { opacity: .5; } .act-empty p { margin: 0; font-size: 13px; line-height: 1.5; max-width: 260px; }

/* the record: every generation ever made, by day */
.act-hist { display: flex; flex-direction: column; gap: 10px; }
.act-hist[hidden] { display: none; }
.act-hist-bar { display: flex; flex-direction: column; gap: 8px; position: sticky; top: -4px; z-index: 2; background: var(--bg-2); padding: 4px 0 8px; }
.act-hist-q { width: 100%; box-sizing: border-box; padding: 7px 11px; border-radius: 10px; border: 1px solid var(--line); background: var(--panel); color: var(--text); font-size: 13px; }
.act-hist-q:focus { outline: none; border-color: rgba(108, 140, 255, .55); }
.act-hist-sels { display: flex; gap: 8px; } .act-hist-sel { flex: 1 1 0; min-width: 0; padding: 6px 8px; border-radius: 9px; border: 1px solid var(--line); background: var(--panel); color: var(--text); font-size: 12.5px; }
.act-day { margin: 8px 0 -2px; font-size: 11.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--faint); }
.act-day:first-child { margin-top: 0; }
.act-hist-note { margin: 0; font-size: 12px; color: var(--muted); } .act-hist-note.bad { color: var(--danger); } .act-hist-note:empty { display: none; }
.act-hist-more { align-self: center; } .act-hist-more[hidden] { display: none; }
.act-empty .btn { margin-top: 2px; }

/* the top-bar button */
.act-btn { position: relative; } .act-btn .ic { width: 16px; height: 16px; }
.act-btn.busy { border-color: rgba(108, 140, 255, .55); color: var(--accent-2); } .act-btn.busy .ic { animation: actspin 2.4s linear infinite; }
.act-badge { min-width: 17px; height: 17px; padding: 0 5px; display: inline-grid; place-items: center; border-radius: 99px; background: var(--accent); color: #fff; font-size: 11px; font-weight: 700; font-variant-numeric: tabular-nums; }
.act-badge.bad { background: var(--danger); } .act-badge[hidden] { display: none; }
@keyframes actspin { to { transform: rotate(360deg); } }

/* a job card */
.gc { background: var(--panel); border: 1px solid var(--line); border-radius: 14px; overflow: hidden; transition: border-color .15s, box-shadow .15s; }
.gc.running { border-color: rgba(108, 140, 255, .5); box-shadow: 0 0 0 1px rgba(108, 140, 255, .12), 0 8px 24px -12px rgba(108, 140, 255, .55); }
.gc.failed { border-color: rgba(255, 107, 107, .4); } .gc.done:hover { border-color: var(--line-2); }
.gc-media { position: relative; height: 138px; background: linear-gradient(135deg, #1b2236, #251b3a); display: grid; place-items: center; overflow: hidden; }
.gc.edit .gc-media, .gc.render .gc-media { background: linear-gradient(135deg, #172a2f, #1b2236); } .gc.post .gc-media { background: linear-gradient(135deg, #2a2236, #1b2236); } .gc.enhance .gc-media { background: linear-gradient(135deg, #2f2a17, #1b2236); }
.gc-glyph { color: rgba(255, 255, 255, .28); display: grid; } .gc-media.has-img .gc-glyph { display: none; }
.gc-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity .3s; } .gc-img.ready { opacity: 1; } .gc.running .gc-img { filter: saturate(.9) brightness(.92); }
.gc-shimmer { position: absolute; inset: 0; pointer-events: none; display: none; background: linear-gradient(105deg, transparent 30%, rgba(255, 255, 255, .13) 50%, transparent 70%); background-size: 220% 100%; animation: gcshimmer 1.9s linear infinite; }
.gc.running .gc-shimmer { display: block; }
@keyframes gcshimmer { from { background-position: 160% 0; } to { background-position: -60% 0; } }
.gc-chip { position: absolute; left: 8px; top: 8px; font-size: 10.5px; font-weight: 700; letter-spacing: .03em; padding: 3px 8px; border-radius: 999px; background: rgba(9, 12, 20, .62); backdrop-filter: blur(6px); color: #e8ecf8; max-width: 60%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gc-state { position: absolute; right: 8px; top: 8px; font-size: 11px; font-weight: 700; font-variant-numeric: tabular-nums; padding: 3px 9px; border-radius: 999px; background: rgba(9, 12, 20, .72); backdrop-filter: blur(6px); color: #e8ecf8; }
.gc-state.run { background: var(--accent); color: #fff; } .gc-state.ok { background: rgba(62, 207, 142, .92); color: #05241a; } .gc-state.bad { background: var(--danger); color: #fff; } .gc-state.wait { background: rgba(245, 185, 66, .92); color: #2b1d00; }
.gc-bar { position: absolute; left: 0; right: 0; bottom: 0; height: 5px; background: rgba(0, 0, 0, .45); } .gc-bar[hidden] { display: none; }
.gc-bar i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--accent), #a06bff); border-radius: 0 3px 3px 0; transition: width .9s ease; }
.gc-bar.indet i { width: 36%; animation: gcindet 1.3s ease-in-out infinite; } .gc-bar.idle i { width: 0; }
@keyframes gcindet { 0% { transform: translateX(-100%); } 100% { transform: translateX(290%); } }
.gc-body { padding: 11px 13px 12px; display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.gc-title { font-size: 13.5px; font-weight: 650; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gc-stage { margin: 0; font-size: 12.5px; color: var(--muted); line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; } .gc-stage.bad { color: var(--danger); }
.gc-meta { margin: 0; font-size: 11.5px; color: var(--faint); font-variant-numeric: tabular-nums; min-height: 1em; }
.gc-actions { display: flex; align-items: center; gap: 6px; margin-top: 6px; flex-wrap: wrap; } .gc-actions:empty { display: none; }
.gc-actions .btn.small { padding: 4px 10px; font-size: 12px; } .gc-actions .btn .ic { width: 14px; height: 14px; }
.gc-x { margin-left: auto; opacity: .7; } .gc-x:hover { opacity: 1; }
.gc-log { margin: 6px 0 0; padding: 8px 10px; list-style: none; background: var(--bg-2); border: 1px solid var(--line); border-radius: 9px; max-height: 150px; overflow: auto; font-size: 11.5px; color: var(--muted); display: flex; flex-direction: column; gap: 4px; }
.gc-log[hidden] { display: none; } .gc-log time { color: var(--faint); margin-right: 7px; font-variant-numeric: tabular-nums; }

/* narrow screens, and the editor, where the pane floats over the page instead of squeezing it */
@media (max-width: 1100px) {
  #activity { position: fixed; right: 0; top: 0; bottom: 0; width: min(94vw, 380px); transform: translateX(105%); transition: transform .2s; border-left-width: 1px; box-shadow: var(--shadow); }
  body.act-open #activity { width: min(94vw, 380px); transform: none; } .act-in { width: 100%; } .act-btn-t { display: none; }
}
#shell:has(#app.editor-main) #activity { position: fixed; right: 0; top: 0; bottom: 0; width: 372px; transform: translateX(105%); transition: transform .2s; border-left-width: 1px; box-shadow: var(--shadow); }
body.act-open #shell:has(#app.editor-main) #activity { transform: none; }
@media (prefers-reduced-motion: reduce) { .gc-shimmer, .gc-bar.indet i, .act-btn.busy .ic { animation: none; } .gc-bar i, #activity { transition: none; } }

/* ---- the slim progress bar across the top of every screen, and its pill ---- */
.act-top { position: fixed; top: 0; left: 0; right: 0; z-index: 900; pointer-events: none; }
.act-topbar { height: 3px; background: rgba(120, 140, 255, .18); overflow: hidden; }
.act-topbar i { display: block; height: 100%; background: linear-gradient(90deg, #6d7cff, #36d1c4, #6d7cff); background-size: 200% 100%; animation: act-flow 1.6s linear infinite; transition: width .8s ease; border-radius: 0 3px 3px 0; box-shadow: 0 0 10px rgba(109, 124, 255, .7); }
.act-top.indeterminate .act-topbar i { animation: act-flow 1.6s linear infinite, act-slide 1.8s ease-in-out infinite; }
.act-toppill { pointer-events: auto; position: absolute; top: 8px; left: 50%; transform: translateX(-50%); border: 1px solid rgba(109, 124, 255, .55); background: color-mix(in srgb, var(--bg, #0b0f1a) 88%, #6d7cff); color: var(--fg, #e8ecff); border-radius: 999px; padding: 4px 14px; font-size: 12px; font-weight: 600; cursor: pointer; box-shadow: 0 4px 18px rgba(0, 0, 0, .35); animation: act-breathe 2.4s ease-in-out infinite; max-width: min(80vw, 420px); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.act-toppill:hover { border-color: #8fa0ff; }
@keyframes act-flow { to { background-position: -200% 0; } }
@keyframes act-slide { 0%, 100% { transform: translateX(-60%); } 50% { transform: translateX(240%); } }
@keyframes act-breathe { 0%, 100% { box-shadow: 0 4px 18px rgba(0, 0, 0, .35), 0 0 0 0 rgba(109, 124, 255, .0); } 50% { box-shadow: 0 4px 18px rgba(0, 0, 0, .35), 0 0 0 5px rgba(109, 124, 255, .18); } }
@media (prefers-reduced-motion: reduce) { .act-topbar i, .act-toppill, .act-top.indeterminate .act-topbar i { animation: none; } }

/* the size a finished render was delivered at, bottom-right of its thumbnail (the label chip is top-left and the state top-right) */
.gc-media .qbadge { position: absolute; right: 8px; bottom: 8px; z-index: 2; }
.gc-reuse { color: var(--muted, #8a94ad); }
