/* Colony interface mock, lifted from the Colony landing (Bare Metal skin). Tokens are scoped to .mc-frame so they never touch the page. */
.mc-frame {
  --bg-primary: #141414; --bg-secondary: #181818; --bg-card: #1c1c1c; --bg-card-hover: #242424; --border: #2a2a2a; --border-active: #3a3a3a;
  --text-primary: #e4e4e4; --text-secondary: #a0a0a0; --text-muted: #6e6e6e;
  --green: #22c55e; --green-bg: rgba(34, 197, 94, 0.12); --yellow: #eab308; --yellow-bg: rgba(234, 179, 8, 0.12); --red: #ef4444; --red-bg: rgba(239, 68, 68, 0.12);
  --blue: #3b82f6; --blue-bg: rgba(59, 130, 246, 0.12); --purple: #a855f7; --purple-bg: rgba(168, 85, 247, 0.12); --cyan: #06b6d4; --cyan-bg: rgba(6, 182, 212, 0.12);
  --orange: #f97316; --orange-bg: rgba(249, 115, 22, 0.12); --mc-selection: rgba(59, 130, 246, 0.3);
  --logo-blue: #2b4cff; --logo-violet: #7a2bd9; --logo-signal: #ff5a5f;
  --art-night: #181c24; --art-slate: #344a50; --art-teal: #538e91; --art-teal-light: #6da1a0; --art-sky: #87acb3; --art-fog: #a9bba3; --art-ochre: #a38c69; --art-amber: #d0a46d; --art-rust: #a85d41; --art-seed: #4fb1a2;
  --mc-shadow-card-hover: 0 0 0 1px #3a3a3a, 0 4px 12px rgba(0, 0, 0, 0.2); --mc-shadow-popover: 0 12px 40px rgba(0, 0, 0, 0.5);
  --mc-space-xs: 4px; --mc-space-sm: 6px; --mc-space-md: 8px; --mc-space-lg: 12px; --mc-space-xl: 16px; --mc-space-2xl: 24px;
  --mc-card-padding: 16px; --mc-content-pad: 24px; --mc-scroll-gutter: 8px; --mc-chrome-label-gap: 6px;
  --mc-radius-sm: 4px; --mc-radius-chrome: 6px; --mc-radius: 8px; --mc-radius-lg: 12px; --mc-radius-pill: 999px;
  --mc-header-height: 32px; --mc-header-control-size: 24px; --mc-top-tabs-height: 40px;
  --mc-ui-font-size: 13px; --mc-chrome-label-size: 13px; --mc-chrome-subtitle-size: 12px; --mc-chrome-meta-size: 11px; --mc-chrome-icon-size: 16px;
  --mc-status-dot-size: 7px; --mc-stepbar-height: 6px; --mc-step-marker-size: 20px;
  --mc-chrome-label-weight: 500; --mc-chrome-subtitle-weight: 400; --mc-chrome-meta-weight: 400;
  --font-sans: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
 --mc-font-sans: var(--font-sans); --mc-font-mono: var(--font-mono); --mc-card-padding-dense: 10px 12px; --bg: var(--bg-primary); --bg-2: var(--bg-secondary); --bg-3: var(--bg-card-hover); --card: var(--bg-card); --line: var(--border); --line-2: var(--border-active); --fg: var(--text-primary); --fg-dim: var(--text-secondary); --fg-muted: var(--text-muted); --accent: var(--blue); --accent-2: var(--purple); --danger: var(--red); --ok: var(--green); --warn: var(--yellow); --mono: var(--mc-font-mono); --sans: var(--mc-font-sans); --mc-bg-primary: var(--bg-primary); --mc-border: var(--border); --mc-border-active: var(--border-active); --mc-blue-bg: var(--blue-bg); --mc-yellow-bg: var(--yellow-bg); 
}
.mc-frame .type-meta { font-family: var(--font-sans); font-size: 11px; line-height: 1.3; font-weight: 400; }
.mc-frame { margin: 0; background: var(--bg); color: var(--fg); font: var(--mc-ui-font-size)/1.4 var(--sans); }
.mc-frame button { font: inherit; font-size: var(--mc-chrome-subtitle-size); color: var(--text-secondary); background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--mc-radius-sm); padding: 3px 10px; cursor: pointer; transition: background 0.15s, border-color 0.15s, color 0.15s; }
.mc-frame button:hover, .mc-frame button.is-hover { background: var(--bg-card-hover); border-color: var(--border-active); color: var(--text-primary); }
.mc-frame button:focus-visible, .mc-frame button.is-focus { outline: 2px solid var(--blue); outline-offset: 2px; }
.mc-frame button.primary { background: var(--blue); border-color: var(--blue); color: #fff; font-weight: 500; }
.mc-frame button.status-bar-btn { font-size: var(--mc-chrome-meta-size); padding: 4px 14px; }
.mc-frame button:disabled { opacity: 0.5; cursor: default; }
.mc-frame .dim { color: var(--fg-dim); }
.mc-frame .hint { color: var(--fg-dim); font-size: var(--mc-fs-sm); margin: 4px 0; }
.mc-frame .hint.warn { color: var(--warn); }
.mc-frame .tabbar { display: flex; align-items: stretch; gap: 1px; background: var(--bg-2); border-bottom: 1px solid var(--line); overflow: hidden; min-height: 32px; flex: none; }
.mc-frame .tabbar .tab { border: 0; border-radius: 0; background: transparent; color: var(--fg-dim); padding: 6px 12px; display: inline-flex; gap: 8px; align-items: center; white-space: nowrap; border-bottom: 2px solid transparent; }
.mc-frame .tabbar .tab.active { color: var(--fg); background: var(--bg); border-bottom-color: var(--accent); }
.mc-frame .badge { display: inline-block; min-width: 16px; padding: 0 5px; border-radius: var(--mc-radius-chrome); background: var(--accent); color: #fff; font-size: var(--mc-fs-xs); line-height: 16px; text-align: center; font-weight: 600; }
.mc-frame .badge.warn { background: var(--warn); color: var(--mc-bg-primary); }
.mc-frame .tabbar .tab .tab-icon { color: var(--fg-dim); }
.mc-frame .tabbar .tab.active .tab-icon { color: var(--accent); }
.mc-frame .tabbar .tab.pin { padding: 6px 10px; gap: 6px; font-weight: 500; }
.mc-frame .tabs-pins { display: flex; flex: none; gap: 1px; }
.mc-frame .tabs-docs { display: flex; gap: 1px; overflow: hidden; min-width: 0; flex: 1; }
.mc-frame .tab-sep { width: 1px; background: var(--line); margin: 6px 4px; flex: none; }
.mc-frame .tabbar .tab.run-live .tab-icon { color: var(--ok); }
.mc-frame .tabbar .tab.run-gate .tab-icon { color: var(--warn); }
.mc-frame .tabbar .tab.run-fail .tab-icon { color: var(--danger); }
.gi { display: inline-block; vertical-align: -0.15em; flex: none; }
.mc-frame button .gi { margin-right: 4px; }
.mc-frame .top-icons button .gi { margin: 0; }
.mc-frame .caret .gi, .mc-frame .pill-mark .gi { vertical-align: -0.1em; }
.mc-frame .tab-icon { width: var(--mc-icon); height: var(--mc-icon); flex: none; }
.mc-frame .card { background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--mc-radius-lg); padding: var(--mc-card-padding); display: flex; flex-direction: column; gap: var(--mc-space-sm); min-width: 0; }
.mc-frame .card-header { display: flex; align-items: center; justify-content: space-between; gap: var(--mc-space-md); margin-bottom: var(--mc-space-sm); min-height: 22px; }
.mc-frame .card-title { display: inline-flex; align-items: center; gap: var(--mc-chrome-label-gap); min-width: 0; font-size: var(--mc-chrome-label-size); font-weight: var(--mc-chrome-label-weight); line-height: 1.2; color: var(--text-primary); }
.mc-frame .card-aside { display: inline-flex; align-items: center; gap: var(--mc-space-sm); flex-wrap: wrap; justify-content: flex-end; min-width: 0; }
.mc-frame .card-count { font-size: var(--mc-chrome-meta-size); color: var(--text-muted); }
.mc-frame .space-icon { flex-shrink: 0; width: var(--mc-chrome-icon-size); height: var(--mc-chrome-icon-size); color: var(--text-muted); opacity: 0.9; display: block; }
.mc-frame .row { display: flex; align-items: center; gap: var(--mc-space-md); min-width: 0; padding: 3px 0; }
.mc-frame .row.current { color: var(--text-primary); }
.mc-frame .mono { font-family: var(--mono); }
.mc-frame .chip { display: inline-flex; align-items: center; gap: var(--mc-space-xs); padding: 0 6px; min-height: 18px; border-radius: var(--mc-radius-chrome); font-size: var(--mc-chrome-meta-size); background: var(--bg-secondary); color: var(--text-secondary); white-space: nowrap; flex: none; border: 1px solid var(--border); }
.mc-frame .chip-running { background: var(--green-bg); color: var(--green); border-color: transparent; }
.mc-frame .chip-gate { background: var(--yellow-bg); color: var(--yellow); border-color: transparent; }
.mc-frame .chip-done { background: var(--green-bg); color: var(--green); border-color: transparent; }
.mc-frame .chip-failed { background: var(--red-bg); color: var(--red); border-color: transparent; }
.mc-frame .pill { display: inline-flex; align-items: center; gap: var(--mc-space-xs); font-size: var(--mc-chrome-meta-size); font-weight: 600; letter-spacing: 0.02em; line-height: 1.3; padding: 2px 6px; border-radius: var(--mc-radius-chrome); color: var(--text-muted); background: var(--bg-secondary); text-transform: uppercase; white-space: nowrap; flex: none; }
.mc-frame .pill-mark { font-size: var(--mc-fs-2xs); line-height: 1; }
.mc-frame .pill-executing { background: var(--blue-bg); color: var(--blue); }
.mc-frame .pill-awaiting { background: var(--yellow-bg); color: var(--yellow); }
.mc-frame .role-pill { display: inline-flex; align-items: center; font-size: var(--mc-chrome-meta-size); font-weight: 600; letter-spacing: 0.02em; padding: 1px 4px; text-transform: uppercase; color: var(--text-muted); white-space: nowrap; flex: none; }
.mc-frame .role-next-up { color: var(--blue); }
.mc-frame .bar { display: block; flex: 1; min-width: 60px; height: var(--mc-stepbar-height); border-radius: 3px; background: var(--border); overflow: hidden; }
.mc-frame .bar-fill { display: block; height: 100%; background: var(--green); transition: width 0.2s; }
.mc-frame .gate { border: 1px solid var(--warn); background: var(--mc-yellow-bg); border-radius: var(--mc-radius); padding: var(--mc-card-padding-dense); display: flex; flex-direction: column; gap: 8px; }
.mc-frame .gate-title { font-weight: 600; color: var(--warn); }
.mc-frame .gate-buttons { display: flex; flex-wrap: wrap; gap: 4px; }
.mc-frame .gate-prompt { color: var(--text-primary); }
.mc-frame .inbox-line { font: 11px/1.4 var(--mono); color: var(--text-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* Mission Control frames: layout, beat states, scene-only rules. Every colour and radius is a token above.
   Chrome icons follow src/icons.ts of the Colony repo: 16px viewBox, stroke 1, butt caps, miter joins. */
/* The window shell after src/styles.css #shell: 40px top bar, 68px rail (labels under icons), center tabs + view, the closed terminal drawer's bar, 24px status. Explorer hidden (no-side). */
.mc-frame { container-type: inline-size; position: relative; display: grid; --mc-u: 1px; grid-template-columns: calc(44 * var(--mc-u)) auto minmax(0, 1fr); grid-template-rows: calc(40 * var(--mc-u)) minmax(0, 1fr) calc(28 * var(--mc-u)) calc(24 * var(--mc-u)); --mc-fs: 13px; --mc-fs-sm: 12px; --mc-fs-xs: 11px; --mc-fs-2xs: 10px; --mc-icon: 16px; grid-template-areas: "top top top" "rail side center" "rail side term" "status status status"; aspect-ratio: 16 / 10; width: 100%; max-width: 1100px; background: var(--bg-primary); color: var(--text-primary); border: 1px solid var(--border); font: var(--mc-fs)/1.4 var(--font-sans); pointer-events: none; user-select: none; text-align: left; overflow: hidden; }
.mc-top { grid-area: top; display: flex; align-items: center; gap: 8px; padding: 0 10px; background: var(--bg-secondary); border-bottom: 1px solid var(--border); min-width: 0; white-space: nowrap; }
.mc-top .brand { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; letter-spacing: 0.02em; margin-right: 2px; color: var(--text-primary); }
.mc-top .brand img { width: 16px; height: 16px; display: block; }
.mc-top .ws-name { display: inline-flex; min-width: 0; overflow: hidden; font: var(--mc-fs-xs)/1.3 var(--mono); color: var(--text-secondary); flex: 0 100 auto; }
.mc-top .ws-name .leaf { color: var(--text-primary); font-weight: 600; }
.mc-top .top-actions { display: inline-flex; align-items: center; gap: 6px; margin-left: auto; padding: 0 8px 0 0; border-right: 1px solid var(--border); flex: none; }
.mc-top .top-actions button { min-height: 26px; }
.mc-top .top-menus { display: inline-flex; gap: 0; flex: none; margin-right: 4px; }
.mc-top .top-menus button, .mc-top .top-icons button { background: transparent; border-color: transparent; padding: 2px 8px; min-height: 26px; }
.mc-top .top-icons { display: inline-flex; gap: 2px; flex: none; }
.mc-rail { grid-area: rail; display: flex; flex-direction: column; gap: 2px; padding: 6px 4px; background: var(--bg-secondary); border-right: 1px solid var(--border); min-height: 0; overflow: hidden; -webkit-mask-image: linear-gradient(to bottom, #000 calc(100% - 18px), transparent calc(100% - 1px), #000 calc(100% - 1px)); mask-image: linear-gradient(to bottom, #000 calc(100% - 18px), transparent calc(100% - 1px), #000 calc(100% - 1px)); }
.mc-rail .rail-item { display: flex; flex: none; flex-direction: column; align-items: center; gap: 2px; padding: 5px 2px 4px; border: 1px solid transparent; border-radius: var(--mc-radius-chrome); background: transparent; color: var(--text-muted); font-size: var(--mc-fs-2xs); line-height: 1.2; position: relative; transition: color 0.15s, border-color 0.15s; }
.mc-rail .rail-item.active { color: var(--text-primary); border-color: var(--border-active); }
.mc-rail .rail-item.active .rail-icon { color: var(--blue); }
.mc-rail .rail-icon-wrap { position: relative; display: inline-flex; }
.mc-rail .rail-icon { width: var(--mc-icon); height: var(--mc-icon); display: block; }
.mc-rail .rail-icon-wrap .badge { position: absolute; top: -6px; left: 12px; font-size: var(--mc-fs-2xs); line-height: 14px; min-width: 14px; padding: 0 4px; }
.mc-rail .lbl { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }   /* rail in icons mode (#shell.rail-icons) */
.mc-rail .rail-item { padding: 7px 0; }
.mc-side { grid-area: side; width: calc(196 * var(--mc-u)); display: flex; flex-direction: column; min-height: 0; background: var(--bg-secondary); border-right: 1px solid var(--border); overflow: hidden; }
.mc-side .side-head { display: flex; justify-content: space-between; align-items: center; padding: 6px 10px; font-size: var(--mc-fs-xs); font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase; color: var(--text-secondary); }
.mc-side .side-icon { width: 14px; height: 14px; color: var(--text-muted); }
.mc-tree { flex: 1; min-height: 0; overflow: hidden; font-size: var(--mc-fs-sm); line-height: 1.5; -webkit-mask-image: linear-gradient(to bottom, #000 calc(100% - 24px), transparent); mask-image: linear-gradient(to bottom, #000 calc(100% - 24px), transparent); }
.mc-tree .tree-row { display: flex; gap: 4px; align-items: center; padding: 1px 7px; border: 1px solid transparent; white-space: nowrap; min-width: 0; color: var(--text-secondary); }
.mc-tree .tree-row .name { overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.mc-tree .tree-row .caret { width: 12px; flex: none; color: var(--text-secondary); font-size: var(--mc-fs-2xs); }
.mc-tree .tree-row.dir .name { color: var(--text-primary); }
.mc-tree .tree-row.active { border-color: var(--blue); color: var(--text-primary); }
.mc-frame .tabbar .tab.file .tab-close { color: var(--text-muted); margin-left: -2px; }
.mc-frame .tabbar .tab.dirty { font-style: italic; }
.mc-frame .tabbar .tab.inter .tab-icon { color: var(--text-secondary); }
/* Proportional type: the frame's chrome type follows its rendered width (1.2cqw ≈ 13px at 1100px, floored at the Bare Metal minimums). */
/* The frame's own grid cannot read its own container size, so the unit for row heights comes from the scene wrapper's width (frame ≈ 60% of it on wide screens, 100% below 1200px). */
.scene-body, .pair { container-type: inline-size; }
@container (min-width: 0) {
  .scene .mc-frame { --mc-u: clamp(0.82px, 0.0555cqw, 1.08px); }
  .pair .mc-frame { --mc-u: clamp(0.82px, 0.0555cqw, 1.08px); }
  .mc-frame > * { --mc-u: clamp(0.82px, 0.0925cqw, 1.08px); --mc-fs: clamp(11px, 1.2cqw, 14px); --mc-fs-sm: clamp(10px, 1.1cqw, 13px); --mc-fs-xs: clamp(9.5px, 1cqw, 12px); --mc-fs-2xs: clamp(9px, 0.9cqw, 11px); --mc-icon: clamp(13px, 1.45cqw, 17px); --mc-space-xs: calc(4 * var(--mc-u)); --mc-space-sm: calc(8 * var(--mc-u)); --mc-space-md: calc(12 * var(--mc-u)); --mc-space-lg: calc(16 * var(--mc-u)); --mc-space-xl: calc(24 * var(--mc-u)); --mc-ui-font-size: var(--mc-fs); --mc-chrome-label-size: var(--mc-fs); --mc-chrome-subtitle-size: var(--mc-fs-sm); --mc-chrome-meta-size: var(--mc-fs-xs); --mc-chrome-icon-size: var(--mc-icon); font-size: var(--mc-fs); }
}
@container (max-width: 820px) { .mc-side { width: calc(170 * var(--mc-u)); } }
@container (max-width: 700px) { .mc-side { display: none; } .mc-frame { grid-template-columns: calc(44 * var(--mc-u)) 0 minmax(0, 1fr); } }
.mc-center { grid-area: center; display: flex; flex-direction: column; min-width: 0; min-height: 0; }
.mc-frame .tab-nav { display: flex; flex: none; align-items: center; gap: 2px; padding: 0 4px 0 6px; color: var(--text-muted); }
.mc-frame .tab-nav span { display: inline-flex; align-items: center; justify-content: center; width: 24px; height: 24px; }
.mc-frame .tab-nav svg { width: var(--mc-icon); height: var(--mc-icon); }
.mc-view { flex: 1; padding: var(--mc-space-xl); display: flex; flex-direction: column; gap: var(--mc-space-lg); min-width: 0; min-height: 0; overflow: hidden; }
.mc-term { grid-area: term; display: flex; align-items: stretch; gap: 1px; background: var(--bg-secondary); border-top: 1px solid var(--border); white-space: nowrap; overflow: hidden; }
.mc-term .tab { border: 0; border-radius: 0; background: transparent; color: var(--text-secondary); padding: 0 12px; display: inline-flex; gap: 8px; align-items: center; font-size: var(--mc-fs-sm); }
.mc-term .tab.active { color: var(--text-primary); background: var(--bg-primary); }
.mc-term .tab.exited { opacity: 0.6; }
.mc-term .tab .tab-close { color: var(--text-muted); margin-left: 2px; }
@container (max-width: 820px) { .mc-term .tab:nth-of-type(3) { display: none; } }
.mc-term .tab-add { padding: 0 10px; color: var(--text-secondary); display: inline-flex; align-items: center; font-size: calc(var(--mc-fs) + 2px); }
.mc-term .drawer-ctl { margin-left: auto; display: inline-flex; align-items: center; gap: 2px; padding: 0 6px; color: var(--text-muted); }
.mc-term .drawer-ctl svg { width: 14px; height: 14px; display: block; margin: 0 4px; }
.mc-term .drawer-ctl .on { color: var(--text-primary); }
.mc-status { grid-area: status; height: calc(24 * var(--mc-u)); background: var(--bg-secondary); border-top: 1px solid var(--border); display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 0 10px; color: var(--text-secondary); white-space: nowrap; overflow: hidden; font-size: var(--mc-fs-xs); }
.mc-status .st-ws { font-weight: 600; color: var(--text-primary); margin-right: 14px; }
.mc-status .feed { color: var(--text-muted); }
.mc-cols { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: var(--mc-space-lg); align-items: start; }
.mc-cols.wide { grid-template-columns: minmax(0, 1fr) minmax(0, 1.6fr); }
.mc-frame .engine-bar { display: flex; flex-wrap: wrap; gap: 6px 14px; align-items: center; }
.mc-frame .engine-bar label { display: inline-flex; gap: 6px; align-items: center; font-size: var(--mc-fs-sm); }
.mc-frame .field { display: inline-flex; align-items: center; gap: 6px; min-height: 22px; padding: 0 8px; border: 1px solid var(--border); border-radius: var(--mc-radius-sm); background: var(--bg-secondary); color: var(--text-primary); font-size: var(--mc-fs-sm); white-space: nowrap; }
.mc-frame .field.placeholder { color: var(--text-muted); }
.mc-frame .field.grow { flex: 1; min-width: 0; }
.mc-frame .field .caret { color: var(--text-muted); font-size: var(--mc-fs-2xs); }
.mc-frame .panel-row { display: flex; gap: 6px; align-items: center; }
.mc-frame .att { display: flex; flex-direction: column; gap: 4px; }
.mc-frame .actions { display: flex; flex-wrap: wrap; gap: 4px; align-items: center; }
.mc-frame .notice { position: absolute; top: 78px; right: 16px; z-index: 2; width: 300px; max-width: 70%; background: var(--bg-card); border: 1px solid var(--border-active); border-radius: var(--mc-radius-chrome); padding: 8px 12px; box-shadow: var(--mc-shadow-popover); font-size: var(--mc-fs-sm); display: flex; flex-direction: column; gap: 2px; transition: opacity 0.3s, transform 0.3s; }
.mc-frame .notice strong { color: var(--text-primary); font-size: var(--mc-fs-sm); }
.mc-frame .notice.hidden { opacity: 0; transform: translateY(-6px); }
.mc-frame .rv-side { display: flex; flex-direction: column; gap: 4px; }
.mc-frame .side-head { font-size: var(--mc-fs-xs); font-weight: 600; letter-spacing: 0.02em; text-transform: uppercase; color: var(--text-muted); padding-bottom: 4px; border-bottom: 1px solid var(--border); margin-bottom: 4px; }
.mc-frame .rv-tick { display: flex; gap: 6px; align-items: center; font-size: var(--mc-fs-sm); padding: 4px 0; }
.mc-frame .rv-tick .caret { color: var(--text-muted); }
.mc-frame .rv-count { margin-left: auto; font: var(--mc-fs-xs)/1 var(--mono); color: var(--text-muted); }
.mc-frame .rv-meta { font-size: var(--mc-fs-xs); color: var(--text-muted); padding: 0 0 4px 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mc-frame .rv-file { display: flex; gap: 8px; align-items: center; padding: 3px 6px; margin: 0 0 0 8px; border-radius: var(--mc-radius-sm); font: var(--mc-fs-sm)/1.4 var(--mono); color: var(--text-secondary); min-width: 0; transition: background 0.15s, color 0.15s; }
.mc-frame .rv-file span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mc-frame .rv-file.sel { background: var(--blue-bg); color: var(--text-primary); }
.mc-frame .st { width: 12px; flex: none; font-weight: 600; }
.mc-frame .st-M { color: var(--yellow); }
.mc-frame .st-A { color: var(--green); }
.mc-frame .rv-head { display: flex; gap: 8px; align-items: center; font-size: var(--mc-fs-sm); min-width: 0; }
.mc-frame .rv-head strong { font-family: var(--mono); font-weight: 500; color: var(--text-primary); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mc-frame .rv-head .spacer { flex: 1; }
.mc-frame .rv-head strong { min-width: 0; flex: 0 1 auto; }
.mc-frame .rv-head > button, .mc-frame .rv-head .dim { white-space: nowrap; flex: none; }
/* Review needs the width for a side-by-side diff: a narrower Explorer, a tighter tick list, and no Explorer once the frame is under 900px. */
.mc-frame[aria-label^="Review"] .mc-side { width: 150px; }
.mc-frame[aria-label^="Review"] .mc-cols.wide { grid-template-columns: minmax(0, 0.78fr) minmax(0, 1.9fr); }
.mc-frame[aria-label^="Review"] .diff-ln { width: 28px; padding-right: 8px; }
@container (max-width: 900px) { .mc-frame[aria-label^="Review"] .mc-side { display: none; } }
.mc-diff { background: var(--bg-secondary); border: 1px solid var(--border); border-radius: var(--mc-radius); font: var(--mc-fs-sm)/1.6 var(--font-mono); overflow: hidden; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.mc-diff .diff-col { padding: 8px 0; min-width: 0; }
.mc-diff .diff-col + .diff-col { border-left: 1px solid var(--border); }
.diff-line { display: flex; padding: 0 12px 0 0; white-space: pre; overflow: hidden; text-overflow: ellipsis; opacity: 1; transition: opacity 0.15s; min-height: 19px; }
.diff-tx { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: pre; }
.diff-ln { flex: none; width: 36px; text-align: right; padding-right: 10px; color: var(--text-muted); }
.diff-line.del { color: var(--red); background: var(--red-bg); }
.diff-line.add { color: var(--green); background: var(--green-bg); }
.mc-frame[data-beat="0"] .diff-line.add, .mc-frame[data-beat="0"] .diff-line.del { opacity: 0; }
.mc-frame[data-beat="1"] .diff-line.d2 { transition-delay: 0.5s; }
.mc-frame[data-beat="1"] .diff-line.d3 { transition-delay: 1s; }
.mc-frame .bento { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: var(--mc-space-lg); align-items: start; }
.mc-frame .stack { display: flex; flex-direction: column; gap: var(--mc-space-lg); min-width: 0; }
.mc-frame .req { border: 1px solid var(--border-active); border-radius: var(--mc-radius); background: var(--bg-secondary); padding: 8px 10px; display: flex; flex-direction: column; gap: 6px; }
.mc-frame .kv { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 1px 10px; font-size: var(--mc-fs-sm); }
.mc-frame .kv span:nth-child(odd) { color: var(--text-muted); }
.mc-frame .kv span:nth-child(even) { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mc-frame .chip, .mc-frame .pill, .mc-frame .tab-icon, .mc-frame .row { transition: background 0.15s, color 0.15s, border-color 0.15s; }
.mc-frame .row.rwrap { flex-wrap: wrap; }
.mc-frame .two { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.mc-frame .two > b, .mc-frame .two > i { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mc-frame .two > b { font-weight: 500; color: var(--text-primary); }
.mc-frame .two > i { font: normal var(--mc-fs-xs)/1.35 var(--mono); color: var(--text-muted); }
.mc-frame .rv-file .two { flex: 1; } .mc-frame .rv-file .two > b { font-weight: 400; }
.mc-frame .lane { display: flex; flex-direction: column; gap: 5px; padding: 3px 0 5px; min-width: 0; }
.mc-frame .lane-name { font-family: var(--mono); color: var(--text-primary); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mc-frame .lane-meta { display: flex; align-items: center; gap: var(--mc-space-sm); flex-wrap: wrap; }
.mc-frame .cmd { display: block; min-width: 0; font: var(--mc-fs-xs)/1.5 var(--mono); color: var(--text-secondary); background: var(--bg-primary); border: 1px solid var(--border); border-radius: var(--mc-radius-sm); padding: 3px 8px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mc-frame .req .actions { flex-wrap: nowrap; } .mc-frame .actions .cmd { flex: 1 1 0; }
.mc-frame .cmd::before { content: "$ "; color: var(--text-muted); }
.mc-frame .req .kv span:nth-child(even) { white-space: normal; overflow-wrap: anywhere; }
.mc-frame .flow { position: relative; display: flex; flex-direction: column; }
.mc-frame .flow::before { content: ""; position: absolute; left: 4px; top: 14px; bottom: 14px; width: 1px; background: var(--border-active); }
.mc-frame .flow .row { padding: 5px 0; }
.mc-frame .node { width: 9px; height: 9px; border-radius: 50%; flex: none; box-sizing: border-box; background: var(--bg-card); border: 1.5px solid var(--text-muted); position: relative; z-index: 1; }
.mc-frame .node.b { border-color: var(--blue); }
.mc-frame .node.s { border-color: var(--green); background: var(--green); }
.mc-diff .diff-hunk { grid-column: 1 / -1; display: flex; gap: 12px; padding: 3px 12px; color: var(--text-muted); background: var(--bg-primary); border-bottom: 1px solid var(--border); font-size: var(--mc-fs-xs); }
.mc-diff .diff-hunk .add-n { color: var(--green); } .mc-diff .diff-hunk .del-n { color: var(--red); }
.diff-line.fill { background: repeating-linear-gradient(135deg, transparent 0 5px, rgb(255 255 255 / 0.04) 5px 6px); }
.mc-frame .tick-strip { display: flex; flex-wrap: wrap; gap: 4px; }
.mc-frame .tl { display: flex; flex-direction: column; }
.mc-frame .tl-row { display: grid; grid-template-columns: calc(38 * var(--mc-u)) 9px minmax(0, 1fr); gap: 0 10px; align-items: center; position: relative; padding: 4px 0; font-size: var(--mc-fs-sm); }
.mc-frame .tl-row::before { content: ""; position: absolute; top: 0; bottom: 0; left: calc(38 * var(--mc-u) + 14px); width: 1px; background: var(--border-active); }
.mc-frame .tl-row:first-child::before { top: 50%; } .mc-frame .tl-row:last-child::before { bottom: 50%; }
.mc-frame .tl-row .t { font: var(--mc-fs-xs)/1 var(--mono); color: var(--text-muted); }
.mc-frame .tl-dot { width: 9px; height: 9px; border-radius: 50%; box-sizing: border-box; background: var(--bg-card); border: 1.5px solid var(--text-muted); position: relative; z-index: 1; }
.mc-frame .tl-dot.g { border-color: var(--green); background: var(--green); } .mc-frame .tl-dot.y { border-color: var(--yellow); background: var(--yellow); } .mc-frame .tl-dot.b { border-color: var(--blue); }
.mc-frame .tl-row .x { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--text-secondary); }
.mc-frame .tl-row .x b { font-weight: 500; color: var(--text-primary); }
.mc-frame .row .grow, .mc-frame .grow { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mc-frame .run-meta { font: var(--mc-fs-xs)/1.3 var(--mono); color: var(--text-muted); flex: none; }
.mc-frame .ellipsis { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@container (max-width: 960px) { .mc-frame .third { display: none; } .mc-frame .top-actions .fold { display: none; } }
@container (max-width: 900px) { .mc-frame { grid-template-columns: calc(44 * var(--mc-u)) auto minmax(0, 1fr); } .mc-rail .lbl { display: none; } .mc-rail .rail-item { padding: 7px 2px; } .mc-rail .rail-icon-wrap .badge { left: 9px; } .mc-top .top-menus button { padding: 2px 6px; } }
@container (max-width: 960px) { .mc-frame .pin-label { display: none; } }
@container (max-width: 820px) { .mc-frame .mc-status .feed { display: none; } .mc-top .top-icons { display: none; } .mc-top .top-actions { border-right: 0; padding-right: 0; } }
@container (max-width: 640px) { .mc-top .ws-name { display: none; } }
@container (max-width: 520px) { .mc-top .top-menus { display: none; } }
@container (max-width: 560px) { .mc-frame .second, .mc-frame .run-meta, .mc-frame .engine-bar, .mc-frame .notice, .mc-frame .kv span:nth-child(n+5), .mc-frame .rv-tick.second, .mc-frame .inbox-line { display: none; } .mc-frame .card { padding: 10px 12px; } .mc-frame .gate-buttons button { flex: 1 1 100%; } }
@container (max-width: 640px) { .mc-cols, .mc-cols.wide, .mc-frame .bento { grid-template-columns: minmax(0, 1fr); } .mc-frame .engine-bar .optional { display: none; } .mc-frame .notice { display: none; } .mc-frame .second { display: none; } }
@media (prefers-reduced-motion: reduce) { .mc-frame * { transition: none !important; } }
