/* Saved model and launch time stay visible independently from live progress. */
html body.studio-shell[data-page="create"] .gen-main{grid-template-columns:minmax(0,1fr) 8.25rem}
html body.studio-shell[data-page="create"] .gen-history-rail{min-width:0;overflow:hidden}
.gen-history-item{position:relative;flex:none;min-width:0;width:100%;scroll-snap-align:start}
html body.studio-shell[data-page="create"] .gen-history-item .gen-frame{display:grid;grid-template-columns:minmax(0,1fr);gap:.4rem;width:100%;height:auto;min-width:0;padding:.45rem;border:0;border-radius:.75rem;overflow:hidden;text-align:left}
html body.studio-shell[data-page="create"] .gen-history-item .gen-frame-media{width:100%;height:4rem;min-height:0;aspect-ratio:auto;border-radius:.5rem;position:relative}
html body.studio-shell[data-page="create"] .gen-frame-caption{display:flex;flex-direction:column;gap:.3rem;min-width:0;width:100%;overflow:hidden}
.gen-frame-heading{display:flex;align-items:center;justify-content:space-between;gap:.35rem;flex-wrap:wrap;min-width:0;padding-right:.1rem}
.gen-model-badge{display:inline-block;max-width:100%;padding:.2rem .4rem;border-radius:.35rem;background:var(--nd-control);color:var(--nd-ink);font-size:.75rem;font-weight:650;line-height:1.25;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.gen-model-badge[data-tier=pro]{background:#7b49d429;color:#bba0ff;box-shadow:inset 0 0 0 1px #a47af77a}
.gen-model-badge[data-tier=base]{background:#87b63925;color:#b6da80;box-shadow:inset 0 0 0 1px #87b63966}
html[data-theme=light] .gen-model-badge[data-tier=pro]{color:#6639a1}
html[data-theme=light] .gen-model-badge[data-tier=base]{color:#385b19}
.gen-model-badge[data-accent=violet]{background:#7b49d429;color:#c4aaff;box-shadow:inset 0 0 0 1px #a47af77a}
.gen-model-badge[data-accent=blue]{background:#4788df29;color:#a4cdff;box-shadow:inset 0 0 0 1px #78acf080}
.gen-model-badge[data-accent=red]{background:#e46d6929;color:#ffc0bc;box-shadow:inset 0 0 0 1px #e9837b80}
.gen-model-badge[data-accent=amber]{background:#e4b24a29;color:#f4d38b;box-shadow:inset 0 0 0 1px #d7b56c80}
.gen-model-badge[data-accent=green]{background:#87b63925;color:#b6da80;box-shadow:inset 0 0 0 1px #87b63966}
html[data-theme=light] .gen-model-badge[data-accent=violet]{color:#6639a1}
html[data-theme=light] .gen-model-badge[data-accent=blue]{color:#195da0}
html[data-theme=light] .gen-model-badge[data-accent=red]{color:#963e36}
html[data-theme=light] .gen-model-badge[data-accent=amber]{color:#775317}
html[data-theme=light] .gen-model-badge[data-accent=green]{color:#385b19}
.gen-frame-time{display:block;font-size:.75rem;line-height:1.3;font-variant-numeric:tabular-nums;color:var(--nd-secondary);white-space:nowrap}
html body.studio-shell[data-page="create"] .gen-history-item .gen-frame-meta{position:static;display:-webkit-box;width:auto;height:auto;max-height:3em;margin:0;clip-path:none;overflow:hidden;overflow-wrap:anywhere;-webkit-line-clamp:2;-webkit-box-orient:vertical;font-size:.75rem;line-height:1.45;color:var(--nd-secondary)}
html body.studio-shell[data-page="create"] .gen-history-item .gen-frame-prompt{display:none}
html body.studio-shell[data-page="create"] .gen-frame-order{top:.65rem;bottom:auto;left:.65rem;font-size:.65rem;pointer-events:none}
.gen-frame-remove{position:absolute;top:.2rem;right:.2rem;z-index:2;width:2.5rem;height:2.5rem;border:1px solid var(--nd-border);border-radius:.5rem;background:var(--nd-panel);color:var(--nd-secondary);font-size:1.3rem;line-height:1;cursor:pointer}
.gen-frame-remove:hover{color:var(--nd-ink);background:var(--nd-control)}
html body.studio-shell[data-page="create"] .gen-rail-tools{flex-direction:row;flex-wrap:wrap;width:100%;gap:.2rem}
html body.studio-shell[data-page="create"] .gen-rail-tools .gen-clear-failed{width:100%;min-width:0;height:auto;min-height:2.75rem;padding:.35rem;font-size:.75rem;line-height:1.3;white-space:normal}
html body.studio-shell[data-page="create"] .gen-selected-head{flex-wrap:wrap;min-width:0}
html body.studio-shell[data-page="create"] .gen-selected-date{white-space:normal;overflow-wrap:anywhere;font-variant-numeric:tabular-nums}
/* Receipt certainty and render outcome are separate, durable states. */
.gen-history-item,.gen-selected,.nd-mobile-result{--gen-state-ink:var(--nd-ink);--gen-state-tint:var(--nd-control)}
:is(.gen-history-item,.gen-selected,.nd-mobile-result)[data-outcome=rejected]{--gen-state-ink:#ff9da7;--gen-state-tint:#b62d4526}
:is(.gen-history-item,.gen-selected,.nd-mobile-result)[data-outcome=unconfirmed]{--gen-state-ink:#efd288;--gen-state-tint:#a47a1726}
:is(.gen-history-item,.gen-selected,.nd-mobile-result)[data-outcome=accepted_failure]{--gen-state-ink:#ffb68b;--gen-state-tint:#bb5c2526}
:is(.gen-history-item,.gen-selected,.nd-mobile-result)[data-outcome=complete]{--gen-state-ink:#b6da80;--gen-state-tint:#87b63925}
html[data-theme=light] :is(.gen-history-item,.gen-selected,.nd-mobile-result)[data-outcome=rejected]{--gen-state-ink:#9f1730;--gen-state-tint:#bb294613}
html[data-theme=light] :is(.gen-history-item,.gen-selected,.nd-mobile-result)[data-outcome=unconfirmed]{--gen-state-ink:#755200;--gen-state-tint:#a47a1717}
html[data-theme=light] :is(.gen-history-item,.gen-selected,.nd-mobile-result)[data-outcome=accepted_failure]{--gen-state-ink:#9b410e;--gen-state-tint:#bb5c2517}
html[data-theme=light] :is(.gen-history-item,.gen-selected,.nd-mobile-result)[data-outcome=complete]{--gen-state-ink:#385b19;--gen-state-tint:#87b63918}
html body.studio-shell[data-page="create"] .gen-history-item[data-outcome] .gen-frame-media{background:var(--gen-state-tint)!important}
html body.studio-shell[data-page="create"] .gen-history-item:is([data-outcome=rejected],[data-outcome=unconfirmed],[data-outcome=accepted_failure]) .gen-frame{box-shadow:inset .2rem 0 var(--gen-state-ink)}
html body.studio-shell[data-page="create"] .gen-history-item[data-outcome] .gen-frame-symbol{display:grid;place-items:center;width:2rem;height:2rem;margin-bottom:.35rem;border:1px solid currentColor;border-radius:50%;font-size:1.5rem;font-weight:650;color:var(--gen-state-ink);animation:none}
html body.studio-shell[data-page="create"] .gen-history-item[data-outcome] .nd-frame-state{color:var(--gen-state-ink);font-size:.625rem;line-height:1.2;bottom:.3rem}
html body.studio-shell[data-page="create"] .gen-selected .gen-job-message{position:relative;display:flex;flex-direction:column;gap:.5rem;min-width:0;max-width:100%;margin:.75rem 0;padding:1rem;background:var(--gen-state-tint)!important;border-left:.2rem solid var(--gen-state-ink)!important;overflow-wrap:anywhere}
.gen-job-cause{font-size:.9375rem;line-height:1.5;color:var(--nd-ink)}
.gen-job-next{margin:0;font-size:.875rem;line-height:1.5;color:var(--nd-ink)}
.gen-job-finance,.gen-job-reference{font-size:.75rem;line-height:1.5;color:var(--nd-secondary)}
.gen-job-reference{font-variant-numeric:tabular-nums;user-select:text}
html body.studio-shell[data-page="create"] :is(#status,#gen-history-status,.gen-submit-feedback){position:relative;max-width:100%;overflow-wrap:anywhere;padding-right:3.25rem}
html body.studio-shell[data-page="create"] :is(#status,#gen-history-status,.gen-submit-feedback)[hidden]{display:none!important}
.gen-notice-close{position:absolute;top:0;right:0;display:grid;place-items:center;min-width:44px;min-height:44px;padding:.5rem;border:0;border-radius:.5rem;background:transparent;color:inherit;font:inherit;font-size:1.25rem;line-height:1;cursor:pointer}
.gen-notice-close:hover{background:var(--nd-control)}
:is(.gen-notice-close,.gen-frame-remove):focus-visible{outline:2px solid var(--nd-ink);outline-offset:2px}
.gen-frame-remove{width:2.75rem;height:2.75rem;min-width:44px;min-height:44px}
html body.studio-shell[data-page="create"] .gen-result-actions{min-width:0;flex-wrap:wrap}
html body.studio-shell[data-page="create"] .gen-result-actions .btn{min-height:44px;max-width:100%;white-space:normal;overflow-wrap:anywhere}
@media(min-width:1180px){
 html body.studio-shell[data-page="create"] .gen-main{grid-template-columns:minmax(0,1fr) clamp(16rem,23vw,24rem)}
 html body.studio-shell[data-page="create"] .gen-history-item .gen-frame{grid-template-columns:4rem minmax(0,1fr);align-items:center;gap:.7rem;padding:.6rem}
 html body.studio-shell[data-page="create"] .gen-history-item .gen-frame-prompt{position:static;display:-webkit-box;width:auto;height:auto;max-height:1.5em;margin:0;clip-path:none;overflow:hidden;overflow-wrap:anywhere;-webkit-line-clamp:1;-webkit-box-orient:vertical;font-size:.8125rem;line-height:1.5}
 .gen-history-item:has(.gen-frame-remove:not([hidden])) .gen-frame-heading{padding-right:2.75rem}
 html body.studio-shell[data-page="create"] .gen-rail-head{flex-direction:row;justify-content:space-between;flex-wrap:wrap;gap:.3rem}
 html body.studio-shell[data-page="create"] .gen-rail-tools{width:auto;justify-content:flex-end}
 html body.studio-shell[data-page="create"] .gen-rail-tools .gen-clear-failed{width:auto;padding:.35rem .6rem}
}
@media(max-width:719px){
 html body.studio-shell[data-page="create"] .gen-history-rail{display:flex!important;flex-direction:column;padding:.5rem;gap:.5rem;width:100%}
 html body.studio-shell[data-page="create"] .gen-rail-head{display:flex;flex-direction:row;flex-wrap:wrap;justify-content:space-between;align-items:center;width:100%;min-height:2.75rem;gap:.35rem;padding:0}
 html body.studio-shell[data-page="create"] .gen-rail-tools{display:flex;flex-direction:row;flex-wrap:wrap;justify-content:flex-end;width:auto;min-width:0;margin:0;flex:1}
 html body.studio-shell[data-page="create"] .gen-rail-tools .gen-clear-failed{width:auto;max-width:10rem;flex:1;min-width:0}
 html body.studio-shell[data-page="create"] .gen-sheets{display:flex;flex-direction:column;align-items:stretch;max-height:24rem;width:100%;overflow-x:hidden;overflow-y:auto;scroll-snap-type:y proximity;touch-action:pan-y pinch-zoom}
 html body.studio-shell[data-page="create"] .gen-history-item .gen-frame{grid-template-columns:4rem minmax(0,1fr);align-items:center;gap:.65rem}
 .gen-history-item:has(.gen-frame-remove:not([hidden])) .gen-frame-heading{padding-right:2.75rem}
 html body.studio-shell[data-page="create"] .gen-rail-gallery{width:100%;height:2.75rem}
}

html body.studio-shell[data-page="create"] .nd-mobile-result[data-outcome] .nd-mobile-result-icon{color:var(--gen-state-ink);background:var(--gen-state-tint)}
html body.studio-shell[data-page="create"] :is(#status,#gen-history-status):not([hidden]){box-sizing:border-box;min-height:44px;padding-top:.65rem;padding-bottom:.65rem;padding-left:.75rem}
/* The page navigation button must not cover status details in the phone dialog. */
html.nd-result-view-open body.studio-shell[data-page="create"] #menu-toggle{visibility:hidden}
@media(min-width:901px){
 html.nd-density-compact:not(.nd-context-child) body.studio-shell[data-page="create"] :is(.gen-frame-remove,.gen-notice-close){min-width:55px;min-height:55px}
 html.nd-density-compact:not(.nd-context-child) body.studio-shell[data-page="create"] :is(#status,#gen-history-status):not([hidden]),html.nd-density-compact:not(.nd-context-child) body.studio-shell[data-page="create"] .gen-result-actions .btn{min-height:55px}
 html.nd-density-compact:not(.nd-context-child) .gen-history-item:has(.gen-frame-remove:not([hidden])) .gen-frame-heading{padding-right:3.5rem}
}

html body.studio-shell[data-page="create"] .gen-selected:is([data-outcome=rejected],[data-outcome=unconfirmed],[data-outcome=accepted_failure]) .gen-selected-head h2:before{background:var(--gen-state-ink);box-shadow:none}
