/* 第三步“中文剧本”页：左边一列章节，中间是内容，所有操作在正下方一条。
   只作用于带 script-stage 的这一页；分集方案页和翻译页用的是各自的那套。 */

/* 顶上：标题、状态、剧名，导出在最右。 */
.lab #overseasShell .script-reader.stage-app.script-stage>header{display:flex;align-items:center;gap:12px;flex-wrap:wrap}
.lab #overseasShell .script-reader.stage-app.script-stage>header .sub{margin-left:0}
.lab #overseasShell .script-reader.stage-app.script-stage>header .script-export{margin-left:auto}

.lab #overseasShell .script-export{position:relative}
.lab #overseasShell .script-menu{
  position:absolute;right:0;top:calc(100% + 6px);z-index:30;min-width:260px;
  display:flex;flex-direction:column;gap:4px;padding:6px;
  background:var(--surface-raised);border:1px solid var(--line);border-radius:8px;box-shadow:0 14px 36px #0009;
}
.lab #overseasShell .script-menu[hidden]{display:none}
.lab #overseasShell .script-menu .btn{width:100%;justify-content:flex-start}
.lab #overseasShell .script-menu-note{margin:6px 6px 2px;font-size:12px;line-height:1.6;color:var(--muted)}

/* 左边：一列文字链接，不带卡片和数量。 */
.lab #overseasShell .script-reader.stage-app.script-stage .script-layout{grid-template-columns:124px minmax(0,1fr);gap:8px 28px}
.lab #overseasShell .script-reader.stage-app.script-stage .stage-nav{overflow:visible}
.lab #overseasShell .script-reader.stage-app.script-stage .stage-nav .btn{
  justify-content:flex-start;min-height:32px;padding:5px 10px;margin:1px 0;
  border-color:transparent;background:transparent;color:var(--muted);font-weight:400;
}
.lab #overseasShell .script-reader.stage-app.script-stage .stage-nav .btn:hover:not(:disabled){background:transparent;border-color:transparent;color:var(--ink)}
.lab #overseasShell .script-reader.stage-app.script-stage .stage-nav .btn[aria-current=true]{background:transparent;border-color:transparent;color:var(--ink);font-weight:600;box-shadow:inset 2px 0 0 var(--green)}
.lab #overseasShell .script-reader.stage-app.script-stage .stage-nav .nav-count{display:none}

/* 正文：分集目录和这一集。分集目录不再撑高，跟内容一起滚。 */
.lab #overseasShell .script-reader.stage-app.script-stage .stage-browse{grid-template-columns:150px minmax(0,1fr)}
.lab #overseasShell .script-reader.stage-app.script-stage .stage-browse .input-directory{max-height:none;position:sticky;align-self:start}
.lab #overseasShell .script-reader.stage-app.script-stage .script-toolbar .link-button{margin:0 0 0 auto}

/* 校验：一行一条，左边色条，右边是这一行能做的事。 */
.lab #overseasShell .script-check{
  display:flex;align-items:center;gap:10px;margin:6px 0;padding:8px 12px;
  border-left:3px solid var(--text-error);border-radius:0 6px 6px 0;background:var(--surface-raised);
}
.lab #overseasShell .script-check p{flex:1;min-width:0;margin:0;font-size:13px;line-height:1.7;color:var(--text-error)}
.lab #overseasShell .script-check .btn{flex-shrink:0;min-height:32px;padding:4px 12px}
.lab #overseasShell .script-check-head{margin:10px 0 8px}
.lab #overseasShell .script-check-why{flex-shrink:0;font-size:12px;color:var(--muted)}
.lab #overseasShell .script-check-excused{border-left-color:var(--muted)}
.lab #overseasShell .script-check-excused p{color:var(--muted)}
.lab #overseasShell .script-check-excused .btn{color:var(--muted)}

/* 正下方一条：改编设定 | 生成正文 ………… 确认设定 / 翻译与质检。 */
.lab #overseasShell .script-dock{
  display:flex;align-items:center;flex-wrap:wrap;gap:10px 0;
  margin-top:16px;padding:10px 14px;border:1px solid var(--line);border-radius:10px;background:var(--surface-raised);
}
.lab #overseasShell .script-dock-group{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.lab #overseasShell .script-dock-group+.script-dock-group{margin-left:14px;padding-left:14px;border-left:1px solid var(--line)}
.lab #overseasShell .script-dock-spacer{flex:1}
.lab #overseasShell .script-dock .btn{white-space:nowrap}
.lab #overseasShell .script-dock .script-dock-next{min-width:150px}
.lab #overseasShell .script-dock .script-dock-job{display:flex;flex:1 1 100%;align-items:center;gap:12px;margin-bottom:10px;padding-bottom:10px;border-bottom:1px solid var(--line)}
.lab #overseasShell .script-dock .script-dock-job>*{flex:1}

@media(max-width:960px){
  .lab #overseasShell .script-reader.stage-app.script-stage .script-layout{display:flex;flex-direction:column;gap:12px}
  .lab #overseasShell .script-reader.stage-app.script-stage .stage-nav{display:flex;overflow-x:auto;gap:4px}
  .lab #overseasShell .script-reader.stage-app.script-stage .stage-nav h3{display:none}
  .lab #overseasShell .script-reader.stage-app.script-stage .script-dock-spacer,
  .lab #overseasShell .script-reader.stage-app.script-stage .script-dock-group+.script-dock-group{margin-left:0;padding-left:0;border-left:0}
  .lab #overseasShell .script-reader.stage-app.script-stage .script-dock-group{flex-basis:100%;padding:6px 0}
}
