.interactive-workflow-link { display: inline-flex; align-items: center; justify-content: center; gap: 14px; padding: 11px 16px; border: 1px solid #5adecc; border-radius: 9px; color: #07221e; background: linear-gradient(125deg, #8bf3d4, #42d5c6); font-weight: 750; text-decoration: none; white-space: nowrap; box-shadow: 0 0 22px #43d7c61a; }
.interactive-workflow-link:hover { filter: brightness(1.08); }
.interactive-workflow-link[hidden] { display: none !important; }
#interactiveWorkflowView { padding: 0; min-width: 0; }
#interactiveWorkflowFrame { display: block; width: 100%; height: max(800px, calc(100dvh - 105px)); border: 0; }
.iw-workspace-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 15px; }
.iw-workspace-head h1 { font-size: 24px; margin: 4px 0; }
.iw-context { position: sticky; top: 0; z-index: 2; display: flex; align-items: center; gap: 12px; padding: 12px 16px; border: 1px solid #38514e; border-radius: 10px; margin-bottom: 12px; background: #12201e; }
.iw-conversation-bar { display: flex; align-items: center; gap: 10px; padding: 9px 16px; border-bottom: 1px solid var(--iw-line); font-size: 12px; color: var(--iw-muted); }
.iw-conversation-bar select { min-width: 0; flex: 1; padding: 7px; }
.iw-run-status { min-height: 26px; padding: 0 22px 8px; font-size: 12px; color: var(--iw-muted); }
#iwImage { width: 100%; height: 100%; position: absolute; object-fit: contain; }
.interactive-workflow-link:focus-visible { outline: 2px solid #fff; outline-offset: 4px; }
.iw-page { --iw-bg: #090e10; --iw-panel: #111a1d; --iw-line: #273438; --iw-muted: #93a5a4; --iw-text: #edf5f1; --iw-accent: #77e3c5; margin: 0; min-width: 320px; color: var(--iw-text); background: radial-gradient(ellipse at 77% 2%, #18372d55, transparent 42%), var(--iw-bg); font: 14px/1.5 "Microsoft YaHei", "PingFang SC", sans-serif; color-scheme: dark; }
.iw-page * { box-sizing: border-box; }
.iw-page [hidden] { display: none !important; }
.iw-page button, .iw-page select, .iw-page textarea { font: inherit; }
.iw-page button, .iw-page select { cursor: pointer; }
.iw-page button:disabled, .iw-page select:disabled, .iw-page textarea:disabled { opacity: .45; cursor: not-allowed; }
.iw-page button:focus-visible, .iw-page a:focus-visible, .iw-page select:focus-visible, .iw-page textarea:focus-visible { outline: 2px solid var(--iw-accent); outline-offset: 3px; }
.iw-page a { color: inherit; }
.iw-header { min-height: 82px; border-bottom: 1px solid var(--iw-line); padding: 16px 32px; display: flex; align-items: center; gap: 36px; background: #0a1112d9; }
.iw-brand { display: flex; align-items: center; gap: 11px; text-decoration: none; font-weight: 700; font-size: 17px; flex-shrink: 0; }
.iw-brand-mark { display: grid; place-items: center; width: 42px; height: 42px; border: 1px solid #77e3c56b; border-radius: 12px; color: var(--iw-accent); font: 700 20px Georgia, serif; }
.iw-brand small { display: block; color: var(--iw-muted); font-size: 11px; font-weight: 400; letter-spacing: 2px; }
.iw-project-field { display: flex; align-items: center; gap: 12px; min-width: 0; flex: 1; }
.iw-project-field label { color: var(--iw-muted); white-space: nowrap; }
.iw-page select { border: 1px solid var(--iw-line); border-radius: 8px; background: #0d1517; padding: 10px 30px 10px 12px; color: var(--iw-text); max-width: 100%; }
#iwProject { width: min(430px, 100%); min-width: 0; text-overflow: ellipsis; }
.iw-company { color: var(--iw-muted); white-space: nowrap; font-size: 12px; }
.iw-header-actions { display: flex; align-items: center; gap: 24px; flex-shrink: 0; }
.iw-badge { display: inline-flex; align-items: center; gap: 7px; border-radius: 24px; padding: 6px 10px; background: #e6b75a0c; color: #e4c887; border: 1px solid #e6b75a35; font-size: 12px; white-space: nowrap; }
.iw-badge i { width: 6px; height: 6px; border-radius: 50%; background: #d9b86d; }
.iw-back { text-decoration: none; color: var(--iw-muted) !important; font-size: 12px; }
.iw-main { max-width: 1920px; padding: 18px 20px; margin: auto; }
.iw-intro { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-bottom: 20px; }
.iw-eyebrow { color: var(--iw-muted); font: 10px/1.5 "Courier New", monospace; letter-spacing: 2px; }
.iw-intro h1 { font-size: clamp(22px, 2.1vw, 32px); letter-spacing: -.6px; margin: 6px 0 7px; font-weight: 600; }
.iw-intro p { color: var(--iw-muted); margin: 0; font-size: 13px; }
.iw-preview-label { text-align: right; flex-shrink: 0; }
.iw-preview-label span { color: var(--iw-accent); font-size: 12px; }
.iw-preview-label small { display: block; color: var(--iw-muted); margin-top: 5px; font-size: 11px; }
.iw-notice { border: 1px solid #cba75c32; border-radius: 8px; color: #cbb784; background: #cba75c08; padding: 10px 14px; margin-bottom: 18px; font-size: 12px; }
.iw-layout { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: 20px; align-items: stretch; }
.iw-chat-panel, .iw-output-panel { border: 1px solid var(--iw-line); border-radius: 14px; background: linear-gradient(145deg, #152023, #10181b); min-width: 0; overflow: hidden; }
.iw-chat-panel { display: flex; flex-direction: column; height: max(460px, calc(100dvh - 216px)); }
.iw-panel-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 18px 22px; border-bottom: 1px solid var(--iw-line); }
.iw-panel-head h2 { margin: 0; font-size: 17px; font-weight: 600; }
.iw-panel-heading { display: flex; gap: 12px; align-items: center; }
.iw-panel-heading p { margin: 3px 0 0; color: var(--iw-muted); font-size: 11px; }
.iw-agent-mark { display: grid; place-items: center; width: 35px; height: 35px; background: #77e3c518; color: var(--iw-accent); border-radius: 10px; font: 700 16px Georgia, serif; }
.iw-button { border: 1px solid #38514e; border-radius: 8px; background: #1d2d2c; color: #d1eee5; padding: 8px 12px; font-size: 12px !important; white-space: nowrap; }
.iw-quiet { background: transparent; border-color: var(--iw-line); color: #b4c3bf; }
.iw-primary { color: #0b2c24; background: var(--iw-accent); border-color: var(--iw-accent); font-weight: 700 !important; min-width: 110px; }
.iw-messages { flex: 1; min-height: 170px; overflow: auto; padding: 25px 22px; scrollbar-width: thin; scrollbar-color: #3b504d transparent; }
.iw-welcome { text-align: center; max-width: 520px; margin: 10px auto; animation: iw-rise .4s ease-out; }
.iw-orbit { display: grid; place-items: center; width: 72px; height: 72px; margin: 8px auto 22px; border-radius: 50%; border: 1px solid #77e3c526; background: radial-gradient(circle, #77e3c520, transparent 70%); box-shadow: 0 0 0 11px #77e3c504; }
.iw-orbit b { font: italic 26px Georgia, serif; color: var(--iw-accent); }
.iw-welcome h3 { font-size: 19px; font-weight: 500; margin: 0 0 10px; }
.iw-welcome > p { font-size: 12px; color: var(--iw-muted); max-width: 350px; margin: 0 auto 22px; line-height: 1.9; }
.iw-suggestions { display: grid; gap: 9px; text-align: left; }
.iw-suggestions button { padding: 12px 16px; background: #0e171955; border: 1px solid var(--iw-line); border-radius: 10px; color: var(--iw-text); text-align: left; display: grid; gap: 3px; }
.iw-suggestions button:hover { border-color: #77e3c56b; background: #77e3c508; }
.iw-suggestions span { font-size: 10px; color: var(--iw-accent); letter-spacing: 1px; }
.iw-suggestions strong { font-size: 13px; font-weight: 500; }
.iw-suggestions small { font-size: 11px; color: var(--iw-muted); }
.iw-message { max-width: 100%; margin: 0 0 22px; padding: 14px 4px; border: 0; border-radius: 10px; background: transparent; white-space: pre-wrap; overflow-wrap: anywhere; line-height: 1.85; }
.iw-message.is-user { max-width: 90%; margin-left: auto; padding: 12px 16px; background: #263432; border: 1px solid #436e5c50; }
.iw-message small { display: block; color: var(--iw-muted); font-size: 10px; margin-bottom: 7px; }
.iw-message p { margin: 0; }
.iw-message .iw-message-note { font-size: 11px; margin-top: 9px; color: #bea875; }
.iw-composer { margin: 0 16px 16px; padding: 13px; background: #0a1214; border: 1px solid #344a46; border-radius: 11px; }
.iw-model-bar { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 9px; color: var(--iw-muted); font-size: 11px; }
.iw-model-bar label { white-space: nowrap; }
.iw-model-bar .iw-claude { display: inline-flex; align-items: center; gap: 4px; cursor: pointer; }
.iw-model-bar .iw-claude:has(input:disabled) { opacity: .5; cursor: not-allowed; }
.iw-model-bar select { width: 166px; padding: 5px 8px; color: var(--iw-accent); border-color: #38514e; font-size: 12px; }
.iw-model-bar span { flex: 1; min-width: 100px; font-size: 10px; }
.iw-composer textarea { width: 100%; background: transparent; color: var(--iw-text); border: 0; outline: 0; min-height: 76px; resize: vertical; padding: 4px; font-size: 13px; line-height: 1.8; }
.iw-composer textarea::placeholder { color: #69807c; }
.iw-composer-actions { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-top: 9px; }
.iw-composer-actions > div { display: flex; align-items: center; gap: 8px; }
.iw-composer-actions small { color: #708a82; font-size: 10px; }
.iw-composer-foot { display: flex; justify-content: space-between; color: #647b73; font-size: 10px; padding: 10px 2px 0; }
.iw-attachments { display: flex; gap: 6px; flex-wrap: wrap; }
.iw-attachment { max-width: 100%; overflow-wrap: anywhere; padding: 5px 9px; border-radius: 6px; color: #c2ddd5; font-size: 11px; background: #263b35; border: 0; }
.iw-output-panel { display: flex; flex-direction: column; }
.iw-output-toolbar { display: flex; justify-content: space-between; gap: 10px; align-items: center; padding: 15px 20px; flex-wrap: wrap; }
.iw-tabs { display: flex; gap: 5px; }
.iw-tabs button { border: 0; background: transparent; color: var(--iw-muted); padding: 7px 10px; font-size: 12px; border-radius: 6px; }
.iw-tabs button.is-active { background: #77e3c515; color: var(--iw-accent); }
.iw-tabs span { font: 10px monospace; border: 1px solid #6d84764a; padding: 0 4px; border-radius: 3px; }
.iw-episode-field { font-size: 11px; color: var(--iw-muted); display: flex; gap: 6px; align-items: center; }
.iw-episode-field select { padding: 6px; font-size: 11px; }
.iw-screen { position: relative; display: grid; place-items: center; margin: 0 20px; border-radius: 10px; min-height: 270px; aspect-ratio: 16/9; background: radial-gradient(ellipse, #1c292c66, transparent 70%), repeating-linear-gradient(0deg, #ffffff02 0, #ffffff02 1px, transparent 1px, transparent 30px), #080e10; border: 1px solid #293a3c; overflow: hidden; }
.iw-empty { padding: 25px; text-align: center; }
.iw-frame-icon { display: grid; place-items: center; margin: 0 auto 20px; width: 58px; height: 43px; border: 1px solid #587770; border-radius: 9px; color: #87a59e; font-size: 25px; }
.iw-empty h3 { font-size: 19px; font-weight: 500; margin: 12px 0; }
.iw-empty p { color: var(--iw-muted); font-size: 12px; line-height: 1.9; }
.iw-empty-meta { display: inline-block; margin-top: 14px; color: #637a74; font-size: 10px; }
#iwPlayer { width: 100%; height: 100%; position: absolute; object-fit: contain; background: #06090a; }
.iw-video-info { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 15px 20px; }
.iw-video-info h3 { margin: 0 0 4px; font-size: 13px; font-weight: 500; }
.iw-video-info p { margin: 0; color: var(--iw-muted); font-size: 11px; }
.iw-video-list { display: flex; flex-wrap: wrap; gap: 8px; max-height: 160px; overflow: auto; padding: 0 20px 16px; }
.iw-video-list button { border: 1px solid var(--iw-line); background: #0e1618; color: #b4c6c0; border-radius: 7px; padding: 10px; text-align: left; min-width: 140px; flex: 1; font-size: 12px; }
.iw-video-list button.is-active { border-color: #77e3c58c; color: var(--iw-accent); }
.iw-video-list small { display: block; color: var(--iw-muted); font-size: 10px; margin-top: 4px; }
.iw-video-list > p { color: var(--iw-muted); font-size: 12px; }
.iw-production-flow { margin-top: auto; padding: 20px; border-top: 1px solid var(--iw-line); background: #0b131533; }
.iw-production-flow > div { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.iw-production-flow strong { font-size: 12px; font-weight: 500; }
.iw-flow-note { font-size: 10px; color: #8c9c95; margin-left: auto; border: 1px solid #33423c; border-radius: 4px; padding: 2px 7px; }
.iw-production-flow ol { list-style: none; display: flex; padding: 0; margin: 17px 0 12px; justify-content: space-between; gap: 8px; counter-reset: flow; }
.iw-production-flow li { counter-increment: flow; font-size: 11px; color: #829b92; }
.iw-production-flow li::before { content: "0" counter(flow); display: block; color: #536a62; font: 11px monospace; margin-bottom: 4px; }
.iw-production-flow p { color: #637b72; font-size: 10px; margin: 0; }
.iw-toast { position: fixed; bottom: 26px; left: 50%; transform: translateX(-50%); padding: 12px 20px; max-width: calc(100vw - 32px); border: 1px solid #54746b; border-radius: 9px; color: #e3f4ec; background: #1f342e; box-shadow: 0 12px 30px #0007; z-index: 10; }
.iw-sr-only { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; }
@keyframes iw-rise { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: translateY(0); } }
@media (prefers-reduced-motion: reduce) { .iw-welcome { animation: none; } }
@media (min-width: 761px) {
  .iw-page { height: 100dvh; overflow: hidden; }
  .iw-main { height: 100%; display: flex; flex-direction: column; }
  .iw-workspace-head { margin-bottom: 8px; }
  .iw-workspace-head h1 { font-size: 21px; }
  .iw-layout { flex: 1; min-height: 0; }
  .iw-chat-panel { height: 100%; min-height: 0; }
  .iw-output-panel { height: 100%; overflow: auto; }
  .iw-messages { min-height: 0; }
  .iw-chat-panel > .iw-panel-head { padding: 12px 18px; flex-shrink: 0; }
  .iw-conversation-bar, .iw-composer, .iw-run-status { flex-shrink: 0; }
  .iw-composer textarea { min-height: 60px; max-height: 150px; }
}
@media (max-width: 1100px) { .iw-header { gap: 18px; padding: 16px 20px; flex-wrap: wrap; } .iw-company { display: none; } .iw-main { padding: 24px 20px; } .iw-header-actions { gap: 12px; } .iw-layout { grid-template-columns: minmax(310px, 1fr) minmax(360px, 1fr); gap: 14px; } .iw-composer-actions small { display: none; } }
@media (max-width: 760px) { .iw-header { padding: 14px 16px; gap: 14px; } .iw-brand { font-size: 14px; } .iw-header-actions { margin-left: auto; } .iw-back { font-size: 11px; } .iw-project-field { order: 3; flex-basis: 100%; } #iwProject { width: 100%; } .iw-main { padding: 22px 12px; } .iw-intro { align-items: start; } .iw-intro p { font-size: 11px; } .iw-preview-label { display: none; } .iw-layout { grid-template-columns: minmax(0, 1fr); } .iw-chat-panel { height: 700px; max-height: none; } .iw-panel-head { padding: 16px; } .iw-messages { padding: 20px 16px; } .iw-screen { margin: 0 12px; min-height: 250px; } .iw-output-toolbar { padding: 12px; } .iw-video-info, .iw-video-list, .iw-production-flow { padding-left: 14px; padding-right: 14px; } .iw-video-info { flex-wrap: wrap; } .iw-production-flow ol { gap: 4px; } .iw-production-flow li { font-size: 10px; } }

/* Execution mode switch: server agent / Codex bridge / Claude Code bridge (v714) */
.iw-mode-bar { display: flex; align-items: stretch; gap: 8px; padding: 8px 12px; border-bottom: 1px solid rgba(0,0,0,.08); background: #fff; flex-wrap: wrap; }
.iw-mode-label { align-self: center; font-size: 13px; color: #667085; margin-right: 4px; }
.iw-mode-bar button { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; padding: 6px 14px; border: 1px solid #d0d5dd; border-radius: 8px; background: #f9fafb; color: #344054; font-size: 14px; font-weight: 600; cursor: pointer; }
.iw-mode-bar button small { font-size: 12px; font-weight: 400; color: #667085; }
.iw-mode-bar button[aria-selected="true"] { border-color: #2563eb; background: #eff6ff; color: #1d4ed8; }
.iw-mode-bar button[aria-selected="true"] small { color: #3b5bdb; }
