/**
 * A9工厂固定视口工作台。
 * 页面外壳禁止滚动，变长信息只在对应面板内滚动，以维持桌面应用的稳定结构。
 */
:root {
  --factory-text: 14px;
  --factory-meta: 12px;
  --factory-title: 18px;
  --factory-topbar: 58px;
  --factory-commandbar: 58px;
  --factory-sidebar: 208px;
  --factory-context: 306px;
}

html,
body {
  width: 100%;
  height: 100%;
  overflow: hidden;
}

body {
  font-size: var(--factory-text);
  background: #050605;
}

button { cursor: pointer; }
.factory-app { height: 100dvh; display: grid; grid-template-rows: var(--factory-topbar) minmax(0, 1fr) var(--factory-commandbar); overflow: hidden; background: var(--a9-black); }
.factory-topbar { min-width: 0; display: grid; grid-template-columns: minmax(330px, 1fr) auto minmax(270px, 1fr); align-items: center; padding: 0 14px; border-bottom: 1px solid var(--a9-line-dark); background: #090b09; }
.factory-brand { min-width: 0; display: flex; align-items: center; gap: 10px; }
.back-link { width: 30px; height: 30px; display: grid; place-items: center; border: 1px solid var(--a9-line-dark); border-radius: 8px; color: var(--a9-muted); }
.factory-mark { display: inline-grid; width: 25px; height: 25px; place-items: center; }
.factory-mark img { width: 100%; height: 100%; object-fit: contain; filter: invert(88%) sepia(22%) saturate(954%) hue-rotate(70deg) brightness(103%) contrast(88%); }
.factory-brand > div { display: grid; line-height: 1.1; }
.factory-brand > div strong { font-size: var(--factory-title); }
.factory-brand > div span { margin-top: 4px; color: #6f736e; font-size: 10px; text-transform: uppercase; letter-spacing: .08em; }
.demo-chip { display: inline-flex; align-items: center; gap: 7px; width: fit-content; padding: 5px 9px; border: 1px solid #2e3e31; border-radius: 999px; background: #101a12; color: var(--a9-green); font-size: var(--factory-meta); }
.demo-chip i { width: 6px; height: 6px; border-radius: 50%; background: var(--a9-green); box-shadow: 0 0 10px var(--a9-green); }
.org-pulse { display: flex; align-items: center; gap: 18px; color: #888c87; font-size: var(--factory-meta); }
.org-pulse span { display: flex; align-items: center; gap: 7px; white-space: nowrap; }
.org-pulse i { width: 6px; height: 6px; border-radius: 50%; background: #4b504b; }
.org-pulse span:first-child i { background: var(--a9-green); }
.org-pulse b { color: var(--a9-white); font-weight: 660; }
.top-actions { display: flex; justify-content: flex-end; align-items: center; gap: 8px; }
.quiet-button, .primary-action { min-height: 32px; display: inline-flex; align-items: center; padding: 0 13px; border: 1px solid var(--a9-line-dark); border-radius: 8px; background: #101210; color: #a7aba6; font-size: var(--factory-meta); }
.primary-action { border-color: var(--a9-green); background: var(--a9-green); color: #0d180f; font-weight: 720; }

.factory-body { min-height: 0; display: grid; grid-template-columns: var(--factory-sidebar) minmax(0, 1fr) var(--factory-context); overflow: hidden; }
.factory-sidebar, .factory-context, .factory-main { min-height: 0; }
.factory-sidebar { display: flex; flex-direction: column; overflow-y: auto; border-right: 1px solid var(--a9-line-dark); background: #0c0e0c; }
.workspace-nav, .sidebar-groups { display: grid; gap: 3px; padding: 14px 10px; }
.workspace-nav > p, .sidebar-groups > p { margin: 0 10px 7px; color: #666a65; font-size: var(--factory-meta); }
.workspace-nav button, .sidebar-groups button { min-height: 34px; display: grid; grid-template-columns: 24px 1fr auto; align-items: center; padding: 0 10px; border-radius: 7px; background: transparent; color: #8f938e; text-align: left; }
.workspace-nav button:hover, .workspace-nav button.is-active, .sidebar-groups button:hover { background: #171a17; color: var(--a9-white); }
.workspace-nav button.is-active { box-shadow: inset 2px 0 var(--a9-green); }
.workspace-nav button > span, .sidebar-groups button > span { color: #737772; }
.workspace-nav button.is-active > span { color: var(--a9-green); }
.workspace-nav button i { min-width: 20px; padding: 1px 5px; border-radius: 999px; background: #242724; color: #777b76; font-size: 10px; font-style: normal; text-align: center; }
.sidebar-groups { border-top: 1px solid var(--a9-line-dark); }
.sidebar-user { min-height: 58px; display: flex; align-items: center; gap: 9px; margin-top: auto; padding: 10px 14px; border-top: 1px solid var(--a9-line-dark); }
.sidebar-user > span { width: 30px; height: 30px; display: grid; place-items: center; border-radius: 50%; background: var(--a9-green-soft); color: #182019; font-size: var(--factory-meta); font-weight: 800; }
.sidebar-user div { display: grid; }
.sidebar-user b { font-size: var(--factory-meta); }
.sidebar-user small { color: #686c67; font-size: 10px; }

.factory-main { overflow-y: auto; background: #080a08; }
.workspace { min-height: 100%; padding: 16px; }
.mobile-summary { display: none; }
.workspace-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; margin-bottom: 14px; }
.workspace-header h1 { margin: 0; font-size: var(--factory-title); line-height: 1.25; }
.workspace-header p { margin: 5px 0 0; color: #767a75; font-size: var(--factory-meta); }
.workspace-header .status-line { display: flex; gap: 8px; }
.status-tag { min-height: 26px; display: inline-flex; align-items: center; gap: 6px; padding: 0 9px; border: 1px solid #303430; border-radius: 999px; color: #969a95; font-size: var(--factory-meta); }
.status-tag strong { color: var(--a9-green); font-weight: 700; }
.panel { border: 1px solid var(--a9-line-dark); border-radius: 10px; background: #101210; }
.panel-head { min-height: 40px; display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 0 12px; border-bottom: 1px solid var(--a9-line-dark); }
.panel-head h2 { margin: 0; font-size: var(--factory-text); }
.panel-head span { color: #6f736e; font-size: var(--factory-meta); }
.overview-grid { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(270px, .7fr); gap: 12px; }
.agenda-panel { min-height: 238px; }
.agenda-content { padding: 14px; }
.agenda-row { display: flex; align-items: center; justify-content: space-between; gap: 18px; }
.agenda-row h3 { margin: 0; font-size: var(--factory-title); }
.agenda-row p { margin: 5px 0 0; color: #747873; font-size: var(--factory-meta); }
.progress-value { color: var(--a9-green); font-size: var(--factory-title); }
.progress-track { height: 5px; margin: 14px 0; overflow: hidden; border-radius: 999px; background: #242724; }
.progress-track i { display: block; height: 100%; background: var(--a9-green); }
.stage-track { display: grid; grid-template-columns: repeat(5, 1fr); margin-top: 18px; }
.stage-track span { position: relative; padding-top: 15px; color: #656965; font-size: 10px; text-align: center; }
.stage-track span::before { content: ""; position: absolute; left: 0; right: 0; top: 3px; height: 1px; background: #303430; }
.stage-track span::after { content: ""; position: absolute; left: 50%; top: 0; width: 7px; height: 7px; border: 2px solid #101210; border-radius: 50%; background: #414641; transform: translateX(-50%); }
.stage-track span.is-done, .stage-track span.is-current { color: #bdc1bc; }
.stage-track span.is-done::before, .stage-track span.is-current::before { background: var(--a9-green); }
.stage-track span.is-done::after, .stage-track span.is-current::after { background: var(--a9-green); }
.decision-panel { min-height: 238px; padding: 14px; background: linear-gradient(145deg, #121712, #0c0e0c); }
.decision-panel > span { color: var(--a9-warn); font-size: var(--factory-meta); }
.decision-panel h3 { margin: 46px 0 9px; font-size: var(--factory-title); }
.decision-panel p { color: #8c908b; }
.decision-actions { display: flex; gap: 7px; margin-top: 18px; }
.small-button { min-height: 30px; padding: 0 11px; border: 1px solid #343834; border-radius: 7px; background: #161916; color: #a8aca7; font-size: var(--factory-meta); }
.small-button.primary { border-color: var(--a9-green); background: var(--a9-green); color: #0d180f; font-weight: 720; }
.overview-pipelines { grid-column: 1 / -1; }
.pipeline-mini-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; padding: 10px; }
.pipeline-mini { min-height: 198px; display: grid; grid-template-rows: 92px auto; overflow: hidden; border: 1px solid #292d29; border-radius: 8px; background: #0b0d0b; }
.pipeline-mini figure { position: relative; margin: 0; overflow: hidden; }
.pipeline-mini img { width: 100%; height: 100%; object-fit: cover; filter: brightness(.62) saturate(.72); }
.pipeline-mini figure span { position: absolute; left: 8px; top: 8px; padding: 3px 6px; border-radius: 4px; background: #071008d9; color: var(--a9-green); font-size: 10px; }
.pipeline-mini-content { padding: 10px; }
.pipeline-mini h3 { margin: 0 0 4px; font-size: var(--factory-text); }
.pipeline-mini p { margin: 0; color: #717570; font-size: var(--factory-meta); }
.mini-progress { height: 3px; margin-top: 10px; background: #242724; }
.mini-progress i { display: block; height: 100%; background: var(--a9-green); }
.manager-report { grid-column: 1 / -1; display: grid; grid-template-columns: 180px 1fr auto; align-items: center; gap: 18px; min-height: 78px; padding: 12px 14px; }
.manager-id { display: flex; align-items: center; gap: 9px; }
.member-avatar { position: relative; width: 34px; height: 34px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 9px; background: #1b291d; color: var(--a9-green); font-size: var(--factory-meta); font-weight: 800; }
.member-avatar img { width: 100%; height: 100%; display: block; border-radius: inherit; object-fit: cover; }
.member-avatar::after { content: ""; position: absolute; right: -2px; bottom: -2px; width: 7px; height: 7px; border: 2px solid #101210; border-radius: 50%; background: var(--a9-green); }
.manager-id div { display: grid; }
.manager-id small { color: #717570; font-size: 10px; }
.report-copy { color: #b9bdb8; }

.member-layout { min-height: 560px; display: grid; grid-template-columns: 250px minmax(0, 1fr); overflow: hidden; }
.member-list { min-height: 0; overflow-y: auto; border-right: 1px solid var(--a9-line-dark); }
.member-list button { width: 100%; min-height: 60px; display: flex; align-items: center; gap: 10px; padding: 9px 12px; border-bottom: 1px solid #1f221f; background: transparent; color: inherit; text-align: left; }
.member-list button:hover, .member-list button.is-active { background: #171a17; box-shadow: inset 2px 0 var(--a9-green); }
.member-list button > div { min-width: 0; display: grid; flex: 1; }
.member-list button b { font-size: var(--factory-text); }
.member-list button span { color: #777b76; font-size: var(--factory-meta); }
.load { color: var(--a9-green); font-size: var(--factory-meta); }
.member-detail { min-width: 0; min-height: 0; overflow-y: auto; }
.member-hero { display: grid; grid-template-columns: auto 1fr auto; gap: 14px; align-items: center; padding: 16px; border-bottom: 1px solid var(--a9-line-dark); }
.member-hero .member-avatar { width: 46px; height: 46px; }
.member-hero h2 { margin: 0; font-size: var(--factory-title); }
.member-hero p { margin: 4px 0 0; color: #737772; font-size: var(--factory-meta); }
.load-meter { display: grid; grid-template-columns: auto 80px; gap: 8px; align-items: center; color: #8b8f8a; font-size: var(--factory-meta); }
.load-meter i { height: 4px; overflow: hidden; border-radius: 99px; background: #2b2e2b; }
.load-meter i::after { content: ""; display: block; width: var(--load); height: 100%; background: var(--a9-green); }
.profile-tabs { display: flex; gap: 3px; padding: 8px 12px; border-bottom: 1px solid var(--a9-line-dark); }
.profile-tabs button { min-height: 29px; padding: 0 9px; border-radius: 6px; background: transparent; color: #787c77; font-size: var(--factory-meta); }
.profile-tabs button.is-active { background: #1b1e1b; color: var(--a9-white); }
.profile-content { padding: 16px; }
.profile-content h3 { margin: 0 0 12px; font-size: var(--factory-text); }
.profile-content > p { max-width: 700px; color: #a5a9a4; line-height: 1.8; }
.tag-grid { display: flex; flex-wrap: wrap; gap: 7px; }
.tag-grid span { padding: 6px 9px; border: 1px solid #303430; border-radius: 6px; background: #171a17; color: #a6aaa5; font-size: var(--factory-meta); }
.record-list { display: grid; gap: 7px; margin: 0; padding: 0; list-style: none; }
.record-list li { display: flex; gap: 10px; padding: 10px; border: 1px solid #282b28; border-radius: 7px; background: #121512; }
.record-list li::before { content: ""; width: 6px; height: 6px; margin-top: 7px; border-radius: 50%; background: var(--a9-green); }

.collaboration-layout { min-height: 570px; display: grid; grid-template-columns: 250px minmax(0, 1fr); overflow: hidden; }
.group-list { border-right: 1px solid var(--a9-line-dark); }
.group-list button { width: 100%; display: grid; gap: 4px; padding: 13px; border-bottom: 1px solid #1f221f; background: transparent; color: inherit; text-align: left; }
.group-list button:hover, .group-list button.is-active { background: #171a17; box-shadow: inset 2px 0 var(--a9-green); }
.group-list span { color: var(--a9-green); font-size: var(--factory-meta); }
.group-list small { color: #6d716c; font-size: 10px; }
.chat-panel { min-height: 0; display: grid; grid-template-rows: auto minmax(0, 1fr) auto; }
.chat-head { min-height: 62px; display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 10px 14px; border-bottom: 1px solid var(--a9-line-dark); }
.chat-head h2 { margin: 0; font-size: var(--factory-text); }
.chat-head p { margin: 3px 0 0; color: #727671; font-size: var(--factory-meta); }
.group-members { display: flex; align-items: center; }
.group-members span { width: 27px; height: 27px; display: grid; place-items: center; margin-left: -5px; border: 2px solid #101210; border-radius: 50%; background: #243027; color: #dce3dc; font-size: 9px; }
.group-members span:first-child { margin-left: 0; background: var(--a9-green-soft); color: #182019; }
.group-members img { width: 100%; height: 100%; display: block; border-radius: 50%; object-fit: cover; }
.message-list { min-height: 0; overflow-y: auto; padding: 14px; }
.message { display: grid; grid-template-columns: 34px 1fr; gap: 10px; margin-bottom: 16px; }
.message .member-avatar { border-radius: 50%; }
.message-head { display: flex; align-items: baseline; gap: 8px; }
.message-head b { font-size: var(--factory-text); }
.message-head span, .message-head time { color: #6d716c; font-size: 10px; }
.message p { margin: 4px 0 0; color: #b4b8b3; line-height: 1.65; }
.message.is-source .message-body { padding: 10px 12px; border: 1px solid #36503b; border-radius: 8px; background: #111a13; }
.source-label { display: inline-flex; margin-top: 8px; padding: 3px 6px; border-radius: 4px; background: #1d2a20; color: var(--a9-green); font-size: 10px; }
.assignment-summary { margin: 0 14px 14px; padding: 10px 12px; border: 1px dashed #3d433d; border-radius: 8px; color: #929691; font-size: var(--factory-meta); }

.production-list { display: grid; gap: 10px; }
.pipeline-row { display: grid; grid-template-columns: 190px minmax(0, 1fr) 120px; min-height: 190px; overflow: hidden; border: 1px solid var(--a9-line-dark); border-radius: 10px; background: #101210; }
.pipeline-cover { position: relative; overflow: hidden; }
.pipeline-cover img { width: 100%; height: 100%; object-fit: cover; filter: brightness(.55) saturate(.7); }
.pipeline-cover span { position: absolute; left: 10px; top: 10px; padding: 4px 7px; border-radius: 5px; background: #071008e8; color: var(--a9-green); font-size: 10px; }
.pipeline-body { min-width: 0; padding: 14px; border-right: 1px solid var(--a9-line-dark); }
.pipeline-body h2 { margin: 0; font-size: var(--factory-title); }
.pipeline-meta { display: flex; gap: 14px; margin-top: 5px; color: #747873; font-size: var(--factory-meta); }
.step-list { display: flex; align-items: flex-start; margin-top: 34px; }
.step-list span { position: relative; min-width: 0; flex: 1; padding: 17px 4px 0; color: #666a65; font-size: 10px; text-align: center; }
.step-list span::before { content: ""; position: absolute; left: 0; right: 0; top: 4px; height: 1px; background: #343834; }
.step-list span::after { content: ""; position: absolute; left: 50%; top: 0; width: 8px; height: 8px; border: 2px solid #101210; border-radius: 50%; background: #444944; transform: translateX(-50%); }
.step-list span.is-done, .step-list span.is-current { color: #bec2bd; }
.step-list span.is-done::before, .step-list span.is-current::before, .step-list span.is-done::after, .step-list span.is-current::after { background: var(--a9-green); }
.pipeline-action { display: grid; place-content: center; gap: 10px; padding: 12px; text-align: center; }
.pipeline-action strong { color: var(--a9-green); font-size: var(--factory-title); }
.pipeline-action small { color: #70746f; }

.review-layout { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(270px, .6fr); gap: 12px; }
.review-preview { min-height: 520px; overflow: hidden; }
.review-preview figure { height: 460px; margin: 0; padding: 14px; }
.review-preview img { width: 100%; height: 100%; object-fit: cover; border-radius: 7px; filter: brightness(.72) saturate(.76); }
.review-inspector { min-height: 520px; display: flex; flex-direction: column; padding: 14px; }
.review-status { color: var(--a9-warn); font-size: var(--factory-meta); }
.review-inspector h2 { margin: 10px 0 18px; font-size: var(--factory-title); }
.check-list { display: grid; gap: 6px; }
.check-item { display: flex; align-items: center; justify-content: space-between; min-height: 38px; padding: 0 10px; border: 1px solid #292d29; border-radius: 7px; background: #141714; }
.check-item span:last-child { color: var(--a9-green); font-size: var(--factory-meta); }
.check-item.is-warn span:last-child { color: var(--a9-warn); }
.review-suggestion { margin-top: 16px; padding: 11px; border-left: 2px solid var(--a9-warn); background: #171711; color: #a9ada8; }
.review-actions { display: flex; gap: 8px; margin-top: auto; }
.review-actions button { flex: 1; }

.artifact-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.artifact-card { min-height: 390px; display: flex; flex-direction: column; overflow: hidden; border: 1px solid var(--a9-line-dark); border-radius: 10px; background: #101210; }
.artifact-card figure { position: relative; height: 225px; margin: 0; overflow: hidden; }
.artifact-card img { width: 100%; height: 100%; object-fit: cover; filter: brightness(.62) saturate(.72); }
.artifact-card.is-locked img { filter: grayscale(1) brightness(.35); }
.artifact-state { position: absolute; left: 10px; top: 10px; padding: 4px 7px; border-radius: 5px; background: #071008e6; color: var(--a9-green); font-size: 10px; }
.artifact-card.is-locked .artifact-state { color: var(--a9-warn); }
.artifact-content { display: flex; flex-direction: column; flex: 1; padding: 13px; }
.artifact-content h2 { margin: 0 0 5px; font-size: var(--factory-title); }
.artifact-content p { margin: 0; color: #747873; font-size: var(--factory-meta); }
.artifact-content button { margin-top: auto; }

.factory-context { overflow-y: auto; border-left: 1px solid var(--a9-line-dark); background: #0d0f0d; }
.context-section { padding: 14px; border-bottom: 1px solid var(--a9-line-dark); }
.context-section > header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.context-section h2 { margin: 0; color: #a9ada8; font-size: var(--factory-meta); text-transform: uppercase; letter-spacing: .08em; }
.context-section header span { color: #626661; font-size: 10px; }
.context-member { display: flex; align-items: center; gap: 9px; margin-bottom: 10px; }
.context-member div { display: grid; }
.context-member small { color: #717570; font-size: 10px; }
.context-list { display: grid; gap: 7px; }
.context-list article { padding: 9px; border: 1px solid #282b28; border-radius: 7px; background: #121512; }
.context-list b { display: block; margin-bottom: 3px; font-size: var(--factory-meta); }
.context-list p { margin: 0; color: #717570; font-size: 10px; line-height: 1.5; }
.context-decision { padding: 10px; border: 1px solid #403a27; border-radius: 7px; background: #17150f; }
.context-decision span { color: var(--a9-warn); font-size: 10px; }
.context-decision p { margin: 7px 0 0; color: #a6aaa5; font-size: var(--factory-meta); }

.factory-commandbar { min-width: 0; display: grid; grid-template-columns: var(--factory-sidebar) minmax(0, 1fr) var(--factory-context); align-items: center; border-top: 1px solid var(--a9-line-dark); background: #090b09; }
.command-source { height: 100%; display: grid; align-content: center; padding: 0 14px; border-right: 1px solid var(--a9-line-dark); }
.command-source span { color: #626661; font-size: 10px; }
.command-source b { overflow: hidden; color: #a6aaa5; font-size: var(--factory-meta); text-overflow: ellipsis; white-space: nowrap; }
.factory-commandbar form { min-width: 0; height: 38px; display: grid; grid-template-columns: minmax(0, 1fr) auto; margin: 0 12px; overflow: hidden; border: 1px solid #303430; border-radius: 8px; background: #131613; }
.factory-commandbar input { min-width: 0; padding: 0 12px; border: 0; outline: 0; background: transparent; color: #c2c6c1; font-size: var(--factory-meta); }
.factory-commandbar form button { padding: 0 14px; background: var(--a9-green); color: #0b150c; font-size: var(--factory-meta); font-weight: 760; }
.connection { height: 100%; display: flex; align-items: center; gap: 8px; padding: 0 14px; border-left: 1px solid var(--a9-line-dark); color: #6b6f6a; font-size: 10px; }
.connection i { width: 6px; height: 6px; border-radius: 50%; background: var(--a9-green); }

.factory-toast { position: fixed; z-index: 90; left: 50%; bottom: 72px; max-width: min(520px, calc(100% - 40px)); padding: 10px 14px; border: 1px solid #354037; border-radius: 8px; background: #152018; color: #cfe7d3; opacity: 0; pointer-events: none; transform: translate(-50%, 12px); transition: opacity .2s ease, transform .2s ease; }
.factory-toast.is-visible { opacity: 1; transform: translate(-50%, 0); }
.artifact-dialog { width: min(1120px, calc(100% - 32px)); max-width: none; max-height: calc(100dvh - 32px); padding: 0; overflow: hidden; border: 1px solid #3d423d; border-radius: 12px; background: #090b09; color: var(--a9-white); box-shadow: 0 40px 120px #000d; }
.artifact-dialog::backdrop { background: #000c; backdrop-filter: blur(7px); }
.artifact-dialog header { height: 52px; display: flex; align-items: center; justify-content: space-between; padding: 0 12px 0 16px; border-bottom: 1px solid var(--a9-line-dark); }
.artifact-dialog header div { display: grid; }
.artifact-dialog header span { color: var(--a9-green); font-size: 10px; }
.artifact-dialog header strong { font-size: var(--factory-text); }
.artifact-dialog header button { width: 30px; height: 30px; border-radius: 7px; background: #1b1e1b; color: var(--a9-white); }
.artifact-dialog video { width: 100%; max-height: calc(100dvh - 86px); background: #000; }
.artifact-dialog.is-fullscreen-player { inset: 0; width: 100dvw; height: 100dvh; max-width: none; max-height: none; margin: 0; border: 0; border-radius: 0; background: #000; }
.artifact-dialog.is-fullscreen-player header { position: absolute; z-index: 4; inset: 0 0 auto; border: 0; background: linear-gradient(#000b, transparent); }
.artifact-dialog.is-fullscreen-player [data-artifact-media] { width: 100%; height: 100%; }
.artifact-dialog.is-fullscreen-player video { width: 100%; height: 100%; max-height: none; object-fit: contain; }

@media (max-width: 1120px) {
  :root { --factory-context: 250px; --factory-sidebar: 184px; }
  .org-pulse span:nth-child(n+3) { display: none; }
  .pipeline-row { grid-template-columns: 160px minmax(0, 1fr) 100px; }
  .artifact-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 760px) {
  html, body { overflow: auto; }
  .factory-app { min-height: 100dvh; height: auto; grid-template-rows: 56px auto; overflow: visible; }
  .factory-topbar { position: sticky; top: 0; z-index: 20; grid-template-columns: 1fr auto; }
  .factory-brand > div span, .factory-brand .demo-chip, .org-pulse, .quiet-button { display: none; }
  .factory-body { display: block; overflow: visible; }
  .factory-sidebar, .factory-context, .factory-commandbar, .workspace { display: none; }
  .factory-main { overflow: visible; }
  .mobile-summary { min-height: calc(100dvh - 56px); display: block; padding: 32px 18px; }
  .mobile-summary h1 { margin: 20px 0 8px; font-size: var(--factory-title); }
  .mobile-summary > p { color: #7d817c; }
  .mobile-summary > div:last-child { display: grid; gap: 10px; margin-top: 28px; }
  .mobile-card { padding: 14px; border: 1px solid var(--a9-line-dark); border-radius: 9px; background: #101210; }
  .mobile-card span { color: var(--a9-green); font-size: var(--factory-meta); }
  .mobile-card h2 { margin: 8px 0 5px; font-size: var(--factory-text); }
  .mobile-card p { margin: 0; color: #747873; font-size: var(--factory-meta); }
}
