/* AM Studio — интерфейс по брендбуку AM: светлый фон, пиксельные заголовки VCR, текст Helvetica Neue,
   синий — выбор и интерфейс, оранжевый — агент (Claude), правки и главное действие. */
@font-face { font-family: "VCR"; src: url("/assets/fonts/VCR.ttf") format("truetype"); font-display: swap; }

:root {
  --bg: #E8E7EE;
  --panel: #FFFFFF;
  --panel2: #F3F2F7;
  --hover: #ECEBF2;
  --line: #D3D2DC;
  --line2: #E2E1E9;
  --text: #0E0E0E;
  --muted: #8B8A96;
  --accent: #183EF5;
  --accent2: #6079FF;
  --accent-bg: rgba(24, 62, 245, 0.10);
  --hot: #FF7940;
  --hot2: #FFB392;
  --hot-bg: rgba(255, 121, 64, 0.14);
  --ink: #0E0E0E;
  --dark: #191919;
  --ai: #FF7940;
  --ai-bg: rgba(255, 121, 64, 0.14);
  --user: #183EF5;
  --user-bg: rgba(24, 62, 245, 0.10);
  --trimc: #5B5A66;
  --trim-bg: rgba(14, 14, 14, 0.07);
  --ok: #183EF5;
  --tl-bg: #FFFFFF;
  --tl-wave: #183EF5;
  --tl-wave-cut: #C9C8D3;
  --shadow: 0 1px 0 rgba(14,14,14,.04), 0 10px 30px rgba(14,14,14,.07);
  --r: 14px;
  --fd: "VCR", ui-monospace, Menlo, monospace;
  --ft: "Helvetica Neue", Helvetica, Arial, sans-serif;
  --side: 268px;
  color-scheme: light;
}
:root[data-theme="dark"] {
  --bg: #0E0E0E;
  --panel: #191919;
  --panel2: #222225;
  --hover: #26262A;
  --line: #2E2E33;
  --line2: #262629;
  --text: #E8E7EE;
  --muted: #8B8A96;
  --accent: #6079FF;
  --accent-bg: rgba(96, 121, 255, 0.16);
  --user: #6079FF;
  --user-bg: rgba(96, 121, 255, 0.16);
  --trimc: #A9A8B4;
  --trim-bg: rgba(232, 231, 238, 0.08);
  --tl-bg: #141414;
  --tl-wave: #6079FF;
  --tl-wave-cut: #3A3A40;
  --shadow: 0 0 0 1px #2E2E33;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; background: var(--bg); color: var(--text); font: 14px/1.45 var(--ft); -webkit-font-smoothing: antialiased; }
.hidden { display: none !important; }
.muted { color: var(--muted); }
.spacer { flex: 1; }
.d { font-family: var(--fd); text-transform: uppercase; letter-spacing: 0; font-weight: 400; }
.acc { color: var(--accent); }
button, select, input, textarea { font: inherit; color: inherit; }
button { cursor: pointer; border: 1px solid var(--line); background: var(--panel); border-radius: 10px; padding: 7px 12px; transition: background .12s, border-color .12s; }
button:hover { background: var(--hover); }
button:disabled { opacity: .45; cursor: default; }
button.ghost { background: transparent; border-color: transparent; }
button.ghost:hover { background: var(--hover); }
button.sm { padding: 4px 9px; font-size: 12.5px; border-radius: 8px; }
.btn { font-family: var(--fd); text-transform: uppercase; font-size: 14px; padding: 9px 16px 8px; border-radius: 10px; border: none; display: inline-flex; gap: 8px; align-items: center; white-space: nowrap; }
.btn.dark { background: var(--ink); color: #fff; }
:root[data-theme="dark"] .btn.dark { background: #E8E7EE; color: #0E0E0E; }
.btn.dark:hover { opacity: .88; background: var(--ink); }
.btn.hot { background: var(--hot); color: #0E0E0E; }
.btn.hot:hover { background: #ff8a57; }
.btn.blue { background: var(--accent); color: #fff; }
.btn.sm { font-size: 12px; padding: 6px 11px 5px; }
.btn .n { background: #0E0E0E; color: var(--hot); border-radius: 6px; padding: 1px 6px 0; font-size: 12px; }
.icon-btn { width: 36px; height: 36px; padding: 0; border-radius: 10px; font-size: 17px; background: transparent; border-color: transparent; }
.mini { font-size: 12px; padding: 3px 8px; border-radius: 7px; background: transparent; border: 1px solid var(--line); cursor: pointer; color: var(--muted); }
.mini:hover { color: var(--text); background: var(--hover); }
kbd { font: 10.5px ui-monospace, SFMono-Regular, Menlo, monospace; border: 1px solid var(--line); border-bottom-width: 2px; border-radius: 4px; padding: 0 4px; background: var(--panel2); color: var(--text); }
.btn kbd { background: rgba(0,0,0,.12); border-color: rgba(0,0,0,.18); color: inherit; }
select { background: var(--panel); border: 1px solid var(--line); border-radius: 9px; padding: 5px 8px; }
textarea { width: 100%; resize: vertical; background: var(--panel2); border: 1px solid var(--line2); border-radius: 10px; padding: 9px 11px; outline: none; line-height: 1.4; }
textarea:focus, input[type=text]:focus { border-color: var(--accent); background: var(--panel); }
input[type=text], input[type=url] { width: 100%; background: var(--panel2); border: 1px solid var(--line2); border-radius: 10px; padding: 9px 11px; outline: none; }
code { font: 12.5px ui-monospace, Menlo, monospace; background: var(--panel2); padding: 1px 5px; border-radius: 4px; }
::selection { background: rgba(24, 62, 245, .22); }

/* ═════════ каркас ═════════ */
#app { display: grid; grid-template-columns: var(--side) 1fr; grid-template-rows: 60px 1fr; height: 100vh; }
#top { grid-column: 1 / -1; display: flex; align-items: center; gap: 12px; padding: 0 14px 0 18px; background: var(--panel); border-bottom: 1px solid var(--line); min-width: 0; }
.brand { display: flex; align-items: center; gap: 10px; color: inherit; text-decoration: none; width: calc(var(--side) - 30px); flex: none; }
.brand-t { font-size: 18px; }
.beta { font: 10px var(--fd); text-transform: uppercase; background: var(--hot); color: #0E0E0E; padding: 3px 6px 2px; border-radius: 5px; }
.crumb { display: flex; flex-direction: column; min-width: 0; max-width: 34vw; }
.pname { font-weight: 700; font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; cursor: text; border-radius: 6px; outline: none; }
.pname[contenteditable="true"] { background: var(--panel2); padding: 0 6px; }
#projMeta { font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.modes { display: flex; gap: 0; background: var(--panel2); border: 1px solid var(--line2); border-radius: 12px; padding: 3px; margin-left: 8px; }
.mode { font-family: var(--fd); text-transform: uppercase; font-size: 14px; border: none; background: transparent; border-radius: 9px; padding: 7px 14px 6px; color: var(--muted); display: flex; gap: 8px; align-items: center; }
.mode .mi { font-size: 11px; color: var(--muted); }
.mode.active { background: var(--panel); color: var(--text); box-shadow: 0 1px 2px rgba(14,14,14,.08); }
.mode.active .mi { color: var(--accent); }
.mode:disabled { opacity: .4; }
.chip { font-size: 12.5px; padding: 6px 11px; border-radius: 99px; border: none; background: var(--accent-bg); color: var(--accent); white-space: nowrap; max-width: 380px; overflow: hidden; text-overflow: ellipsis; }
.chip.hot { background: var(--hot-bg); color: #C24E17; }
:root[data-theme="dark"] .chip.hot { color: var(--hot); }
.chip.warn { background: var(--hot-bg); color: #C24E17; }
.chip.err { background: #0E0E0E; color: var(--hot); }
.chip.ok { background: var(--accent-bg); color: var(--accent); }
#aiBtn.ai-on { color: #C24E17; }
:root[data-theme="dark"] #aiBtn.ai-on { color: var(--hot); }
#aiBtn.ai-warn { background: var(--hot-bg); color: #C24E17; }
#aiBtn:disabled { opacity: 1; color: #C24E17; }
.spin { display: inline-block; width: 10px; height: 10px; border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; animation: sp .8s linear infinite; vertical-align: -1px; margin-right: 7px; }
@keyframes sp { to { transform: rotate(360deg); } }
.bar { height: 6px; background: var(--panel2); border-radius: 99px; overflow: hidden; }
.bar.big { height: 8px; margin: 14px 0; }
.bar i { display: block; height: 100%; width: 0; background: var(--accent); transition: width .3s; }
.bar.hot i { background: var(--hot); }

/* ═════════ левая панель ═════════ */
#side { background: var(--panel); border-right: 1px solid var(--line); overflow-y: auto; padding: 8px 0 30px; }
.sb { padding: 14px 14px 10px; border-bottom: 1px solid var(--line2); }
.sb-h { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.sb-h .d { font-size: 13px; color: var(--muted); }
.sb-sub { font-size: 12px; margin: 2px 0 8px; }
.plist { display: grid; gap: 4px; margin-top: 10px; max-height: 34vh; overflow-y: auto; }
.pi { display: grid; grid-template-columns: 1fr auto; gap: 2px 8px; padding: 9px 10px; border-radius: 10px; cursor: pointer; border: 1px solid transparent; }
.pi:hover { background: var(--hover); }
.pi.active { background: var(--panel2); border-color: var(--line); box-shadow: inset 3px 0 0 var(--hot); }
.pi .nm { font-weight: 600; font-size: 13.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pi .du { font: 11px ui-monospace, Menlo, monospace; color: var(--muted); align-self: center; }
.pi { position: relative; }
.pi .pdel { position: absolute; top: 6px; right: 6px; padding: 1px 6px; font-size: 11px; border-radius: 6px; background: var(--panel); color: var(--muted); opacity: 0; transition: opacity .12s; }
.pi:hover .pdel { opacity: 1; }
.pi .pdel:hover { color: var(--hot); border-color: var(--hot); }
.pi .st { grid-column: 1 / -1; font-size: 11.5px; color: var(--muted); display: flex; gap: 5px; flex-wrap: wrap; align-items: center; }
.tag { font: 10px var(--fd); text-transform: uppercase; padding: 2px 5px 1px; border-radius: 4px; background: var(--panel2); color: var(--muted); border: 1px solid var(--line2); }
.tag.b { background: var(--accent); color: #fff; border-color: var(--accent); }
.tag.o { background: var(--hot); color: #0E0E0E; border-color: var(--hot); }
.tag.k { background: var(--ink); color: #fff; border-color: var(--ink); }
.empty-s { color: var(--muted); font-size: 12.5px; padding: 6px 2px; }

.syslist { display: grid; gap: 6px; }
.sys { position: relative; padding: 10px 10px 9px; border-radius: 12px; border: 1px solid var(--line2); cursor: pointer; background: var(--panel); display: grid; gap: 6px; }
.sys:hover { border-color: var(--line); background: var(--hover); }
.sys.active { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent); }
.sys.active::after { content: ""; position: absolute; right: 9px; top: 10px; width: 12px; height: 9px; background: var(--accent); clip-path: polygon(0 45%, 18% 30%, 40% 55%, 82% 0, 100% 16%, 40% 100%); }
.sys .nm { font-weight: 600; font-size: 13px; padding-right: 18px; }
.sys .ds { font-size: 11.5px; color: var(--muted); line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.sys .row { display: flex; align-items: center; gap: 8px; }
.sw { display: flex; gap: 0; border-radius: 6px; overflow: hidden; border: 1px solid var(--line2); }
.sw i { width: 16px; height: 16px; display: block; }
.fontAa { font-size: 15px; line-height: 1; }
.fontAa .t { font-family: var(--ft); font-size: 13px; margin-left: 4px; }
.sys .open { position: absolute; right: 30px; top: 6px; font-size: 11px; padding: 2px 6px; opacity: 0; }
.sys:hover .open { opacity: 1; }
.schema { width: 100%; height: auto; display: block; border-radius: 6px; background: var(--bg); }
.job-row { font-size: 12px; color: var(--muted); padding: 8px 10px; border: 1px dashed var(--line); border-radius: 10px; }

/* ═════════ главная ═════════ */
#main { min-width: 0; min-height: 0; position: relative; overflow: hidden; }
.screen { height: 100%; }
#home { overflow-y: auto; background:
  radial-gradient(circle, var(--line) 1.2px, transparent 1.4px) 0 0 / 26px 26px, var(--bg); }
.home-in { max-width: 860px; margin: 0 auto; padding: 56px 28px 60px; }
.hero-t { font-size: 64px; line-height: 1; }
.lead { font-size: 18px; line-height: 1.5; max-width: 640px; margin: 18px 0 28px; }
.drop { display: flex; flex-direction: column; align-items: center; gap: 6px; border: 2px dashed var(--line); border-radius: 22px; padding: 44px 20px; text-align: center; cursor: pointer; background: var(--panel); transition: .15s; }
.drop:hover, .drop.over { border-color: var(--accent); background: var(--accent-bg); }
.drop-ic { display: block; height: 70px; }
.drop-t { font-size: 20px; font-weight: 700; }
.drop-s { color: var(--muted); }
.upl { margin-top: 14px; width: min(420px, 100%); display: flex; gap: 10px; align-items: center; }
.upl .bar { flex: 1; }
.steps { list-style: none; padding: 0; margin: 28px 0 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.steps li { background: var(--panel); border-radius: 16px; padding: 16px; display: grid; gap: 6px; box-shadow: var(--shadow); }
.steps b { font-size: 16px; color: var(--accent); }
.steps li:nth-child(2) b { color: var(--hot); }
.steps span { color: var(--muted); font-size: 13px; }

/* ═════════ режим «Трим» ═════════ */
#trim { display: grid; grid-template-rows: 1fr auto; }
.work { display: grid; grid-template-columns: minmax(380px, 1.15fr) minmax(320px, 1fr); min-height: 0; }
.left { display: flex; flex-direction: column; min-height: 0; border-right: 1px solid var(--line); position: relative; background: var(--panel); }
.tabs { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; padding: 8px 12px; border-bottom: 1px solid var(--line2); }
.tabs button { white-space: nowrap; }
.tab { background: transparent; border-color: transparent; color: var(--muted); padding: 6px 10px; }
.tab.active { color: var(--text); background: var(--panel2); border-color: var(--line2); }
.tab b { color: var(--hot); font-weight: 700; }
.settings { position: absolute; right: 12px; top: 46px; z-index: 20; width: 330px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--r); padding: 16px; display: grid; gap: 12px; box-shadow: 0 16px 50px rgba(14,14,14,.18); }
.settings label { display: block; font-size: 13px; }
.settings input[type=range] { display: block; margin-top: 7px; width: 100%; accent-color: var(--accent); }
.settings label.row { display: flex; gap: 8px; align-items: center; }
.settings .sep { font: 12px var(--fd); text-transform: uppercase; color: var(--muted); border-top: 1px solid var(--line2); padding-top: 12px; }
.settings .hint { font-size: 12px; color: var(--muted); line-height: 1.45; }
.settings .hint button { margin-top: 6px; display: block; }

.transcript { flex: 1; overflow-y: auto; padding: 22px 30px 80px; font-size: 17px; line-height: 1.85; user-select: text; outline: none; }
.para { margin: 0 0 14px; }
.tk { border-radius: 3px; cursor: text; padding: 1px 0; transition: background .1s; }
.tk.w:hover { background: var(--hover); }
.tk.lowp { text-decoration: underline dotted var(--muted); text-underline-offset: 4px; }
.tk.cut { text-decoration: line-through; text-decoration-thickness: 1.5px; }
.tk.cut.by-ai { color: #C24E17; background: var(--ai-bg); text-decoration-color: rgba(255,121,64,.8); }
:root[data-theme="dark"] .tk.cut.by-ai { color: var(--hot); }
.tk.cut.by-user { color: var(--user); background: var(--user-bg); text-decoration-color: var(--user); }
.tk.cut.by-trim { color: var(--trimc); background: var(--trim-bg); text-decoration-color: var(--trimc); }
.tk.cut.by-ai.gh, .tk.gh { outline: 1px solid rgba(255,121,64,.6); }
.tk.now { background: var(--accent) !important; color: #fff !important; box-shadow: 0 0 0 2px var(--accent); }
.tk.cut.now { background: rgba(24,62,245,.35) !important; }
.tk.pz { display: inline-block; font-size: 12px; line-height: 1; padding: 4px 9px; margin: 0 2px; border-radius: 99px; vertical-align: 2px; white-space: nowrap; cursor: pointer; user-select: none; -webkit-user-select: none;
  color: var(--accent); background: var(--accent-bg); border: 1px solid rgba(24,62,245,.3); transition: .12s; }
.tk.pz:hover { background: rgba(24,62,245,.18); }
.tk.pz.cut { color: var(--muted); background: transparent; border: 1px dashed var(--line); text-decoration: line-through; }
.badge { user-select: none; font: 10.5px var(--fd); text-transform: uppercase; color: #0E0E0E; background: var(--hot); border-radius: 4px; padding: 2px 5px 1px; margin-right: 4px; cursor: pointer; }
.badge.off { background: transparent; color: var(--hot); border: 1px solid var(--hot2); text-decoration: line-through; }
#tailsBtn { color: var(--trimc); }

.sugg { flex: 1; overflow-y: auto; padding: 12px; display: grid; gap: 8px; align-content: start; }
.si { background: var(--panel); border: 1px solid var(--line2); border-radius: 12px; padding: 11px 13px; display: grid; gap: 6px; cursor: pointer; }
.si:hover { border-color: var(--line); }
.si.off { opacity: .55; }
.si-h { display: flex; gap: 8px; align-items: center; }
.si-h .tm { color: var(--muted); font-size: 12px; font-family: ui-monospace, Menlo, monospace; }
.si-h .spacer + button { padding: 3px 9px; font-size: 12px; }
.si .rs { font-size: 13px; }
.si .tx { font-size: 13px; color: var(--muted); text-decoration: line-through; text-decoration-color: rgba(255,121,64,.6); }
.si.off .tx { text-decoration: none; }
.empty { color: var(--muted); padding: 20px 0; }
.legend { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; padding: 9px 16px; border-top: 1px solid var(--line2); font-size: 12px; }
.lg { display: inline-block; width: 10px; height: 10px; border-radius: 2px; margin-right: 5px; vertical-align: -1px; }
.lg.ai { background: var(--hot); } .lg.user { background: var(--user); } .lg.pause { background: var(--accent-bg); border: 1px solid var(--accent); }

.right { display: flex; flex-direction: column; min-height: 0; padding: 14px; gap: 10px; }
.playerWrap { flex: 1; min-height: 0; background: #0E0E0E; border-radius: var(--r); overflow: hidden; display: flex; align-items: center; justify-content: center; position: relative; }
.playerWrap video { width: 100%; height: 100%; object-fit: contain; display: block; }
.audioOnly { position: absolute; color: var(--muted); font-size: 18px; }
/* скринкаст: экран большой, камера маленьким окном в углу (⇄ — наоборот) */
.playerWrap.dual video.pip { position: absolute; inset: auto 12px 12px auto; width: 30%; height: auto; max-height: 45%; border-radius: 10px; box-shadow: 0 6px 20px rgba(0,0,0,.5); z-index: 2; background: #000; }
.playerWrap.dual video:not(.pip) { position: absolute; inset: 0; }
.screenOut { position: absolute; left: 12px; top: 12px; font-size: 12px; color: #aaa; background: rgba(0,0,0,.6); padding: 4px 8px; border-radius: 6px; z-index: 3; }
.swapBtn { position: absolute; right: 12px; top: 12px; z-index: 3; width: 32px; height: 32px; padding: 0; border-radius: 8px; background: rgba(0,0,0,.55); color: #fff; border: 1px solid rgba(255,255,255,.2); }
.screenBar { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-size: 13px; min-height: 30px; }
.screenBar .sbT { margin-right: 4px; }
.screenBar .ok { color: var(--accent); }
.screenBar .warn { color: var(--hot); }
.screenBar .bar { flex: 1; min-width: 80px; height: 6px; border-radius: 3px; background: var(--line2); overflow: hidden; }
.screenBar .bar i { display: block; height: 100%; background: var(--accent); }
.controls, .rv-controls { display: flex; align-items: center; gap: 12px; }
.round { width: 42px; height: 42px; border-radius: 50%; padding: 0; background: var(--accent); border: none; color: #fff; display: grid; place-items: center; flex: none; }
.round:hover { background: var(--accent); filter: brightness(1.1); }
.round svg { display: block; }
.time { font: 15px ui-monospace, SFMono-Regular, Menlo, monospace; white-space: nowrap; }
.pstats { font-size: 12.5px; }
.pstats b { color: var(--accent); }
.toggle { display: flex; align-items: center; gap: 8px; cursor: pointer; font-size: 13px; user-select: none; }
.toggle input { display: none; }
.toggle span { width: 30px; height: 18px; border-radius: 99px; background: var(--line); position: relative; transition: .15s; }
.toggle span::after { content: ""; position: absolute; left: 2px; top: 2px; width: 14px; height: 14px; border-radius: 50%; background: #fff; transition: .15s; }
.toggle input:checked + span { background: var(--accent); }
.toggle input:checked + span::after { left: 14px; }
.keys { display: flex; flex-wrap: wrap; gap: 12px; font-size: 12px; }

.tlwrap { height: 200px; border-top: 1px solid var(--line); background: var(--tl-bg); display: flex; flex-direction: column; }
.tl-h { flex: none; height: 38px; display: flex; align-items: center; gap: 6px; padding: 0 10px 0 14px; font-size: 12px; white-space: nowrap; overflow: hidden; border-bottom: 1px solid var(--line2); }
.tl-h .d { font-size: 12px; color: var(--muted); margin-right: 8px; }
#tl, #rvtl { width: 100%; flex: 1; min-height: 0; display: block; cursor: crosshair; }
#tlCut:not(:disabled) { color: var(--user); }
.selbar { position: fixed; z-index: 50; display: flex; gap: 4px; padding: 4px; background: var(--panel); border: 1px solid var(--line); border-radius: 10px; box-shadow: 0 10px 30px rgba(14,14,14,.18); }
.selbar button { padding: 5px 10px; font-size: 13px; border-color: transparent; }
.selbar #cutSel { color: var(--user); }
.tip { position: fixed; z-index: 60; max-width: 320px; background: var(--ink); color: #fff; border-radius: 8px; padding: 8px 10px; font-size: 12.5px; pointer-events: none; box-shadow: 0 8px 26px rgba(14,14,14,.3); }
.tip b { color: var(--hot); }

/* ═════════ режим «Правки» ═════════ */
#review { display: grid; grid-template-rows: 1fr auto; }
.rv { display: grid; grid-template-columns: 1fr 360px; min-height: 0; }
.rv-main { display: flex; flex-direction: column; min-width: 0; min-height: 0; padding: 14px; gap: 10px; }
.stage-box { flex: 1; min-height: 0; display: flex; align-items: center; justify-content: center; }
.stage { position: relative; width: 640px; height: 360px; flex: none; background: #0E0E0E; border-radius: 12px; overflow: hidden; box-shadow: var(--shadow); }
.stage iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; display: block; pointer-events: none; }
.hit { position: absolute; inset: 0;
  cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='38' viewBox='0 0 12 19' shape-rendering='crispEdges'%3E%3Cpath fill='%230E0E0E' d='M0 0h1v1h1v1h1v1h1v1h1v1h1v1h1v1h1v1h1v1h1v1h1v1H7v1h1v2h1v2H7v1H6v-2H5v-2H4v1H3v1H2v1H1v1H0z'/%3E%3Cpath fill='%23FF7940' d='M1 2h1v1h1v1h1v1h1v1h1v1h1v1h1v1h1v1h1v1H6v1h1v2h1v2H7v-2H6v-2H5v-1H4v1H3v1H2v1H1z'/%3E%3C/svg%3E") 1 1, crosshair; }
.stage-tag { position: absolute; left: 12px; top: 12px; font-size: 11px; padding: 4px 7px 3px; border-radius: 6px; background: var(--hot); color: #0E0E0E; pointer-events: none; }
.rv-empty { position: absolute; inset: 0; display: flex; flex-direction: column; gap: 14px; align-items: center; justify-content: center; text-align: center; padding: 30px; color: #E8E7EE; background: #0E0E0E; }
.rv-empty .d { font-size: 22px; }
.rv-empty p { max-width: 460px; color: #8B8A96; margin: 0; }
.pin-layer { position: absolute; inset: 0; pointer-events: none; }
.pin { position: absolute; transform: translate(-50%, -100%); pointer-events: auto; cursor: pointer; display: flex; flex-direction: column; align-items: center; }
.pin b { font: 13px var(--fd); background: var(--hot); color: #0E0E0E; min-width: 26px; height: 26px; border-radius: 13px 13px 13px 3px; display: grid; place-items: center; padding: 2px 6px 0; box-shadow: 0 0 0 2px #fff, 0 4px 14px rgba(0,0,0,.35); }
.pin.sel b { background: var(--accent); color: #fff; }
.pin.draft b { background: #fff; color: #0E0E0E; }
.shot-tag { font: 11px var(--fd); text-transform: uppercase; color: var(--muted); white-space: nowrap; max-width: 260px; overflow: hidden; text-overflow: ellipsis; }

.rv-side { border-left: 1px solid var(--line); background: var(--panel); display: flex; flex-direction: column; min-height: 0; overflow-y: auto; }
.panel-h { display: flex; align-items: center; gap: 8px; padding: 14px 14px 6px; }
.panel-h .d { font-size: 14px; }
.panel-h.small { padding: 10px 14px 6px; }
.panel-h.small .d { font-size: 12px; color: var(--muted); }
.count { font: 12px var(--fd); background: var(--hot); color: #0E0E0E; border-radius: 6px; padding: 2px 6px 1px; }
.count:empty { display: none; }
.howto { font-size: 12px; padding: 0 14px 10px; }
.clist { display: grid; gap: 8px; padding: 0 12px 12px; align-content: start; }
#cList { flex: 1 0 auto; min-height: 120px; }
.cm { border: 1px solid var(--line2); border-radius: 12px; padding: 10px 11px; display: grid; gap: 6px; background: var(--panel); box-shadow: inset 3px 0 0 var(--hot); cursor: pointer; }
.cm.sel { border-color: var(--hot); box-shadow: inset 3px 0 0 var(--hot), 0 0 0 1px var(--hot); }
.cm.done { box-shadow: inset 3px 0 0 var(--accent); opacity: .85; }
.cm.skipped { box-shadow: inset 3px 0 0 var(--muted); }
.cm-h { display: flex; align-items: center; gap: 6px; font-size: 12px; }
.cm-h .no { font: 13px var(--fd); }
.cm-h .tm { font: 12px ui-monospace, Menlo, monospace; color: var(--muted); }
.cm-h .el { font-size: 11.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; flex: 1; }
.cm-h button { padding: 2px 6px; font-size: 12px; border-color: transparent; background: transparent; }
.cm .say { font-size: 12.5px; color: var(--muted); }
.cm .say i { font-style: normal; color: var(--text); }
.cm textarea { font-size: 13.5px; min-height: 54px; }
.cm .ans { font-size: 12.5px; color: var(--accent); }
.cm .gen { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-size: 12.5px; }
.cm .gen:empty { display: none; }
.cm .gen select { font-size: 12px; padding: 2px 4px; width: auto; }
.cm .gen-img { display: block; width: 100%; }
.cm .gen-img img { display: block; max-width: 100%; max-height: 180px; border-radius: 8px; border: 1px solid var(--line2); }
.cm .gen-acts { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.cm .gen-run { color: var(--accent); }
.cm .gen-err { color: var(--hot); flex-basis: 100%; }
.cm .ans.sk { color: var(--muted); }
.fixed { border-top: 1px solid var(--line2); }
.fixed summary { cursor: pointer; padding: 10px 14px; font: 12px var(--fd); text-transform: uppercase; color: var(--muted); list-style: none; }
.fixed summary::before { content: "▸ "; }
.fixed[open] summary::before { content: "▾ "; }
.fixed .clist { max-height: 26vh; overflow-y: auto; }
.notes { border-top: 1px solid var(--line2); padding: 0 12px 12px; }
.brief { border-bottom: 1px solid var(--line2); padding: 0 12px 10px; }
.brief textarea { font-size: 13px; width: 100%; }
.sw { display: inline-flex; align-items: center; gap: 5px; cursor: pointer; }
.cm .ans.lr { color: var(--accent); background: color-mix(in srgb, var(--accent) 8%, transparent); padding: 3px 7px; border-radius: 7px; margin-top: 4px; }
.learned { font-size: 11px; color: var(--accent); white-space: nowrap; }
.sv-snd { display: flex; flex-wrap: wrap; gap: 6px; margin: 6px 0; }
.notes textarea { font-size: 13px; }
.mediaBox { border-top: 1px solid var(--line2); padding: 0 12px 12px; }
.media-list { display: flex; flex-wrap: wrap; gap: 6px; font-size: 12px; }
.media-list span { background: var(--panel2); border-radius: 7px; padding: 3px 7px; }
.pop { position: fixed; z-index: 70; width: 340px; background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 12px; display: grid; gap: 8px; box-shadow: 0 18px 50px rgba(14,14,14,.22); }
.pop-h { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.pop-h .d { font-size: 13px; }
.pop-b { display: flex; justify-content: flex-end; gap: 6px; }
.rv-tlwrap { height: 290px; }
.tl-tools { display: flex; align-items: center; gap: 2px; margin-left: 10px; }
.tl-tools .tt { min-width: 30px; height: 26px; padding: 0 7px; border: 1px solid transparent; border-radius: 7px; background: transparent; color: var(--text); font-size: 13px; cursor: pointer; }
.tl-tools .tt:hover:not(:disabled) { background: var(--panel2); }
.tl-tools .tt.on { background: var(--text); color: var(--bg); }
.tl-tools .tt:disabled { opacity: .35; cursor: default; }
.tl-tools .tt-sep { width: 1px; height: 18px; background: var(--line2); margin: 0 5px; }
.tl-tools .tt-snap { font-size: 12px; color: var(--muted); display: flex; gap: 4px; align-items: center; margin-left: 6px; }
#tlState { font-size: 12px; margin-left: 8px; }
#tlState.busy { color: var(--hot); }
#rvtl.blade { cursor: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='20' height='20'><text x='2' y='16' font-size='16'>✂</text></svg>") 4 10, crosshair; }
.hit-drag { cursor: grabbing !important; }

/* ═════════ окна ═════════ */
.overlay { position: fixed; inset: 0; z-index: 100; background: rgba(14,14,14,.55); display: flex; align-items: center; justify-content: center; padding: 16px; }
#trim .overlay { position: absolute; }
.card { width: min(480px, 100%); background: var(--panel); border: 1px solid var(--line); border-radius: 18px; padding: 22px; display: grid; gap: 8px; box-shadow: 0 30px 80px rgba(14,14,14,.3); max-height: 92vh; overflow-y: auto; }
.card.wide { width: min(640px, 100%); }
.card-t { font-size: 20px; margin-bottom: 4px; }
.card .acts { display: flex; gap: 8px; justify-content: flex-end; margin-top: 10px; flex-wrap: wrap; }
.err { color: #C24E17; font-size: 13px; white-space: pre-wrap; }
:root[data-theme="dark"] .err { color: var(--hot); }
.files { margin: 6px 0; padding-left: 18px; display: grid; gap: 4px; }
.field { display: grid; gap: 5px; font-size: 13px; }
.field > span { color: var(--muted); font-size: 12px; }
.dropmini { border: 2px dashed var(--line); border-radius: 12px; padding: 18px; text-align: center; cursor: pointer; color: var(--muted); font-size: 13px; }
.dropmini.over { border-color: var(--accent); background: var(--accent-bg); }
.reflist { display: flex; flex-wrap: wrap; gap: 6px; font-size: 12px; }
.reflist span { background: var(--panel2); border-radius: 7px; padding: 3px 8px; }
.sysview { display: grid; gap: 14px; }
.sysview h4 { margin: 0 0 6px; font: 12px var(--fd); text-transform: uppercase; color: var(--muted); }
.sv-prev img { display: block; width: 100%; border-radius: 12px; border: 1px solid var(--line); }
.sv-prev small { display: block; margin-top: 4px; }
.sv-colors { display: grid; grid-template-columns: repeat(auto-fill, minmax(92px, 1fr)); gap: 6px; }
.sv-colors div { border-radius: 10px; overflow: hidden; border: 1px solid var(--line2); font: 11px ui-monospace, Menlo, monospace; }
.sv-colors i { display: block; height: 42px; }
.sv-colors span { display: block; padding: 4px 6px; }
.sv-type div { padding: 4px 0; border-bottom: 1px solid var(--line2); display: flex; align-items: baseline; gap: 10px; overflow: hidden; white-space: nowrap; }
.sv-type small { color: var(--muted); font: 11px ui-monospace, Menlo, monospace; width: 110px; flex: none; }
.sv-rules { margin: 0; padding-left: 18px; display: grid; gap: 4px; font-size: 13px; }
.sv-cams { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; }
.sv-cams figure { margin: 0; font-size: 11.5px; color: var(--muted); }
.set-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.set-grid .full { grid-column: 1 / -1; }

@media (max-width: 1180px) {
  :root { --side: 228px; }
  .rv { grid-template-columns: 1fr 300px; }
  .hide-narrow { display: none; }
  .brand { width: auto; }
}

@media (max-width: 1000px) {
  :root { --side: 200px; }
  .rv { grid-template-columns: 1fr 260px; }
  .crumb, #jobChip, .mode .mi, .beta { display: none; }
  .brand { width: auto; }
  .btn { padding: 8px 11px 7px; font-size: 13px; }
  .work { grid-template-columns: 1fr 1fr; }
  .steps { grid-template-columns: 1fr; }
}
.say { display: flex; align-items: center; gap: 10px; justify-content: space-between; background: var(--panel2); border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; margin: 6px 0 10px; }
.say b { font-weight: 600; }

/* очередь задач */
.qlist { display: grid; gap: 8px; max-height: 50vh; overflow: auto; }
.qrow { display: flex; align-items: center; gap: 12px; justify-content: space-between; padding: 10px 12px; background: var(--panel2); border-radius: 10px; }

/* ═════════ разделы слева ═════════ */
#side { display: flex; flex-direction: column; padding: 10px 8px 20px; }
.nav { display: grid; gap: 2px; }
.nv { display: flex; align-items: center; gap: 10px; text-align: left; border: none; background: transparent; padding: 9px 10px; border-radius: 10px; font-size: 14px; }
.nv:hover { background: var(--hover); }
.nv.active { background: var(--panel2); box-shadow: inset 3px 0 0 var(--accent); font-weight: 600; }
.nv b { margin-left: auto; font: 11px ui-monospace, Menlo, monospace; color: var(--muted); font-weight: 400; }
.nvi { width: 18px; text-align: center; color: var(--accent); }
.nv-sep { font-size: 11px; color: var(--muted); padding: 14px 10px 4px; }
.side-up { margin: 10px 4px 0; padding: 10px; border-radius: 10px; background: var(--panel2); display: grid; gap: 6px; font-size: 12px; }
.side-projects { display: grid; gap: 2px; margin-top: 6px; }
.sp { display: grid; gap: 2px; text-align: left; border: none; background: transparent; padding: 7px 10px; border-radius: 10px; min-width: 0; }
.sp:hover { background: var(--hover); }
.sp.active { background: var(--panel2); box-shadow: inset 3px 0 0 var(--hot); }
.sp .nm { font-size: 13px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sp .ph { justify-self: start; }

/* статус проекта */
.ph { display: inline-flex; align-items: center; font-size: 11.5px; padding: 2px 8px; border-radius: 99px; background: var(--panel2); color: var(--muted); white-space: nowrap; }
.ph .spin { width: 8px; height: 8px; margin-right: 5px; }
.ph.busy, .ph.upload { background: var(--hot-bg); color: #C24E17; }
.ph.wait, .ph.queue { background: var(--panel2); color: var(--muted); }
.ph.trim { background: var(--accent-bg); color: var(--accent); }
.ph.trimmed { background: var(--accent); color: #fff; }
.ph.montaged { background: var(--hot); color: #0E0E0E; }
.ph.rendered { background: var(--ink); color: #fff; }
.ph.err, .ph.error { background: #0E0E0E; color: var(--hot); }
:root[data-theme="dark"] .ph.rendered { background: #E8E7EE; color: #0E0E0E; }
:root[data-theme="dark"] .ph.busy { color: var(--hot); }

.ptitle { font-size: 16px; }
.sys-chip { max-width: 260px; }
.chip.lim { background: var(--panel2); color: var(--muted); }
.chip.lim.warn { background: var(--hot-bg); color: #C24E17; }

/* ═════════ страницы-каталоги ═════════ */
.page { overflow-y: auto; }
.page-in { max-width: 1280px; margin: 0 auto; padding: 26px 28px 60px; }
.page-h { display: flex; align-items: center; gap: 12px; margin-bottom: 18px; flex-wrap: wrap; }
.page-h > div:first-child { max-width: 640px; }
.page-t { font-size: 30px; line-height: 1.1; margin-bottom: 4px; }
.seg { display: flex; background: var(--panel2); border: 1px solid var(--line2); border-radius: 10px; padding: 3px; }
.seg button { border: none; background: transparent; padding: 5px 11px; font-size: 13px; border-radius: 8px; color: var(--muted); }
.seg button.on { background: var(--panel); color: var(--text); box-shadow: 0 1px 2px rgba(14,14,14,.08); }
.empty-big { grid-column: 1 / -1; display: grid; gap: 6px; justify-items: center; text-align: center; padding: 40px 20px; color: var(--muted); }
.empty-big b { color: var(--text); font-size: 17px; }

/* проекты */
.pgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 14px; }
.pc { position: relative; background: var(--panel); border: 1px solid var(--line2); border-radius: var(--r); overflow: hidden; cursor: pointer; display: flex; flex-direction: column; text-align: left; padding: 0; transition: border-color .12s, box-shadow .12s; }
.pc:hover { border-color: var(--line); box-shadow: var(--shadow); background: var(--panel); }
.pc-th { position: relative; aspect-ratio: 16 / 10; background: #0E0E0E; display: grid; place-items: center; overflow: hidden; }
.pc-th img { width: 100%; height: 100%; object-fit: cover; display: block; }
.pc-b { padding: 10px 12px 12px; display: grid; gap: 6px; }
.pc-nm { font-weight: 700; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; padding-right: 22px; }
.pc-st { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; font-size: 12px; }
.pc .err { font-size: 12px; }
.pc-more { position: absolute; right: 8px; top: 8px; padding: 2px 9px; border-radius: 8px; font-size: 15px; line-height: 1; background: var(--panel); opacity: 0; }
.pc:hover .pc-more { opacity: 1; }
.pc-new { align-items: center; justify-content: center; gap: 6px; min-height: 220px; border: 2px dashed var(--line); background: transparent; }
.pc-new span { font-size: 34px; color: var(--hot); line-height: 1; }
.pc-new b { font-family: var(--fd); text-transform: uppercase; font-weight: 400; }
.pc-new:hover { border-color: var(--hot); background: var(--hot-bg); }

/* файлы */
.fdrop { border: 2px dashed var(--line); border-radius: var(--r); padding: 18px; text-align: center; color: var(--muted); margin-bottom: 14px; transition: .12s; }
.fdrop.over { border-color: var(--accent); background: var(--accent-bg); color: var(--accent); }
.upq { background: var(--panel); border: 1px solid var(--line2); border-radius: var(--r); padding: 10px 14px; margin-bottom: 14px; display: grid; gap: 6px; max-height: 260px; overflow-y: auto; }
.upq-h { font-size: 13px; }
.upq-r { display: grid; grid-template-columns: minmax(0, 1fr) 70px 160px 110px; gap: 10px; align-items: center; font-size: 12.5px; }
.upq-r .nm { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.upq-r.done { opacity: .6; }
.upq-r.err .st { color: var(--hot); }
.fbar { display: flex; align-items: center; gap: 8px; min-height: 0; margin-bottom: 10px; flex-wrap: wrap; }
.fbar:empty { display: none; }
.fbar:not(:empty) { position: sticky; top: 0; z-index: 5; background: var(--panel); border: 1px solid var(--accent); border-radius: 12px; padding: 8px 12px; }
.fgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 12px; user-select: none; }
.fc { background: var(--panel); border: 1px solid var(--line2); border-radius: 12px; overflow: hidden; cursor: pointer; outline: none; }
.fc:hover { border-color: var(--line); }
.fc.sel { border-color: var(--accent); box-shadow: 0 0 0 2px var(--accent); }
.fc.busy { opacity: .75; }
.fc-th { position: relative; aspect-ratio: 16 / 10; background: #0E0E0E; display: grid; place-items: center; overflow: hidden; }
.fc-th img { width: 100%; height: 100%; object-fit: cover; display: block; }
.fc-ic { color: #8B8A96; font-size: 22px; }
.fc-du, .fc-st, .fc-or { position: absolute; font: 11px ui-monospace, Menlo, monospace; background: rgba(14,14,14,.75); color: #fff; padding: 2px 6px; border-radius: 5px; }
.fc-du { right: 6px; bottom: 6px; }
.fc-or { left: 6px; top: 6px; }
.fc-st { left: 6px; bottom: 6px; background: var(--hot); color: #0E0E0E; }
.fc-st.err { background: #0E0E0E; color: var(--hot); }
.fc-nm { padding: 8px 10px 0; font-size: 13px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fc-mt { padding: 2px 10px 9px; font-size: 11.5px; }
.fc-in { color: var(--accent); }
.pplist, .nplist { display: grid; gap: 4px; max-height: 46vh; overflow-y: auto; margin: 6px 0; }
.pp { display: grid; gap: 2px; text-align: left; border-color: var(--line2); }
.pp span { font-size: 12px; }
.npi { display: grid; grid-template-columns: 64px minmax(0, 1fr) auto; gap: 10px; align-items: center; text-align: left; padding: 5px 8px; border-color: var(--line2); }
.npi img, .npi i { width: 64px; height: 40px; object-fit: cover; border-radius: 6px; background: #0E0E0E; display: grid; place-items: center; color: #8B8A96; font-style: normal; }
.npi span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 13px; }
.npi small { color: var(--muted); font: 11px ui-monospace, Menlo, monospace; }
.npi.on { border-color: var(--accent); background: var(--accent-bg); }

/* лента роликов проекта в триме */
.clipbar { display: flex; align-items: center; gap: 6px; padding: 7px 12px; border-top: 1px solid var(--line2); background: var(--panel); overflow-x: auto; white-space: nowrap; }
.cb-t { font-size: 12px; color: var(--muted); margin-right: 4px; }
.cb-n { font-size: 12px; }
.clip { display: inline-flex; align-items: center; gap: 6px; padding: 4px 9px; border-radius: 8px; border: 1px solid var(--line2); background: var(--panel2); font-size: 12.5px; cursor: grab; max-width: 220px; }
.clip b { font: 11px var(--fd); color: var(--accent); }
.clip span { overflow: hidden; text-overflow: ellipsis; }
.clip small { color: var(--muted); font: 11px ui-monospace, Menlo, monospace; }
.clip.drag { opacity: .4; }
.clip.over { border-color: var(--accent); box-shadow: -3px 0 0 var(--accent); }

/* меню правого клика и всплывашка */
.ctx { position: fixed; z-index: 200; min-width: 210px; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 5px; box-shadow: 0 16px 44px rgba(14,14,14,.22); font-size: 13.5px; }
.ctx-i { position: relative; padding: 7px 11px; border-radius: 8px; cursor: pointer; white-space: nowrap; }
.ctx-i:hover { background: var(--hover); }
.ctx-i.off { opacity: .4; cursor: default; }
.ctx-i.off:hover { background: transparent; }
.ctx-i.danger { color: #C24E17; }
:root[data-theme="dark"] .ctx-i.danger { color: var(--hot); }
.ctx-i.has-sub::after { content: "›"; position: absolute; right: 10px; color: var(--muted); }
.ctx-i.has-sub { padding-right: 26px; }
.ctx-sub { display: none; position: absolute; left: 100%; top: -6px; min-width: 220px; max-height: 60vh; overflow-y: auto; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 5px; box-shadow: 0 16px 44px rgba(14,14,14,.22); }
.ctx.sub-left .ctx-sub { left: auto; right: 100%; }
.ctx-i.has-sub:hover > .ctx-sub { display: block; }
.ctx-sep { height: 1px; background: var(--line2); margin: 4px 6px; }
.toast { position: fixed; z-index: 300; left: 50%; bottom: 26px; transform: translateX(-50%); background: var(--ink); color: #fff; padding: 10px 16px; border-radius: 12px; font-size: 13.5px; box-shadow: 0 12px 34px rgba(14,14,14,.3); max-width: min(560px, 92vw); }
:root[data-theme="dark"] .toast { background: #E8E7EE; color: #0E0E0E; }

/* ═════════ системы ═════════ */
.sgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 14px; }
#sysJobs { display: grid; gap: 6px; margin-bottom: 12px; }
#sysJobs:empty { display: none; }
.sc { background: var(--panel); border: 1px solid var(--line2); border-radius: var(--r); overflow: hidden; cursor: pointer; }
.sc:hover { border-color: var(--line); box-shadow: var(--shadow); }
.sc-prev { aspect-ratio: 16 / 9; background: var(--panel2); display: grid; place-items: center; overflow: hidden; }
.sc-prev img { width: 100%; height: 100%; object-fit: cover; display: block; }
.sc-noprev { color: var(--muted); font-size: 12px; }
.sc-b { padding: 10px 12px 12px; display: grid; gap: 6px; }
.sc-nm { font-weight: 700; }
.sc-ds { font-size: 12.5px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
#system { overflow: hidden; }
.sysx { display: grid; grid-template-columns: minmax(0, 1fr) 380px; height: 100%; }
.sysx-main { display: flex; flex-direction: column; min-height: 0; min-width: 0; }
.sysx-h { display: flex; align-items: center; gap: 8px; padding: 12px 16px; border-bottom: 1px solid var(--line2); background: var(--panel); flex-wrap: wrap; }
.sysx-name { display: grid; gap: 2px; flex: 1 1 340px; min-width: 240px; max-width: 640px; }
.inline-in { background: transparent !important; border: 1px solid transparent !important; padding: 3px 6px !important; border-radius: 7px !important; }
.inline-in:hover { border-color: var(--line2) !important; }
.inline-in:focus { border-color: var(--accent) !important; background: var(--panel) !important; }
.inline-in.d { font-size: 20px; }
#sysDel:hover { color: var(--hot); }
.sysx-tabs { background: var(--panel); }
.sysx-body { flex: 1; overflow-y: auto; padding: 18px 20px 40px; }
.sysx-chat { border-left: 1px solid var(--line); background: var(--panel); display: flex; flex-direction: column; min-height: 0; }
.chat-log { flex: 1; overflow-y: auto; padding: 4px 12px 12px; display: grid; gap: 8px; align-content: start; }
.msg { padding: 9px 11px; border-radius: 12px; font-size: 13.5px; line-height: 1.45; display: grid; gap: 4px; overflow-wrap: anywhere; }
.msg.user { background: var(--accent-bg); margin-left: 28px; }
.msg.claude { background: var(--panel2); margin-right: 16px; box-shadow: inset 3px 0 0 var(--hot); }
.msg.error { background: var(--hot-bg); }
.msg.working { color: var(--muted); display: block; }
.msg small { font-size: 11.5px; color: var(--muted); }
.msg p { margin: 0 0 6px; }
.msg pre { white-space: pre-wrap; margin: 0; font: 12px ui-monospace, Menlo, monospace; }
.chat-in { border-top: 1px solid var(--line2); padding: 10px 12px; display: grid; gap: 8px; justify-items: end; }
.rlist { display: grid; gap: 8px; }
.rrow { display: grid; grid-template-columns: 28px minmax(0, 1fr) auto; gap: 8px; align-items: start; }
.rrow .learned { grid-column: 2; }
.rn { font: 13px var(--fd); color: var(--muted); padding-top: 9px; text-align: right; }
.rrow.add { margin-top: 10px; grid-template-columns: 28px minmax(0, 1fr); }
.rrow.add .rn { color: var(--hot); }
.ract { display: flex; flex-direction: column; gap: 0; }
.ract button { padding: 1px 7px; }
.fh { margin: 18px 0 8px; font: 12px var(--fd); text-transform: uppercase; color: var(--muted); }
.sfgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.sf { position: relative; border: 1px solid var(--line2); border-radius: 10px; overflow: hidden; background: var(--panel); display: grid; font-size: 12px; }
.sf img, .sf video { width: 100%; height: 100px; object-fit: cover; display: block; background: var(--panel2); }
.sf > span { padding: 5px 8px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sf .mini { margin: 8px; justify-self: start; }
.sf [data-del] { position: absolute; top: 4px; right: 4px; background: var(--panel); padding: 1px 6px; }
.sf-doc { height: 100px; display: grid; place-items: center; background: var(--panel2); font: 14px var(--fd); color: var(--muted); text-decoration: none; }
.json-ed { width: 100%; min-height: 60vh; font: 12.5px/1.5 ui-monospace, Menlo, monospace; white-space: pre; }

/* ═════════ расход Claude ═════════ */
.ugrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 14px; }
.ucard { background: var(--panel); border: 1px solid var(--line2); border-radius: var(--r); padding: 14px 16px; display: grid; gap: 6px; align-content: start; }
.ucard.wide { grid-column: 1 / -1; }
.ucard.warn { background: var(--hot-bg); border-color: var(--hot2); }
.ucard h4 { margin: 0 0 4px; font: 12px var(--fd); text-transform: uppercase; color: var(--muted); }
.lims { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 10px 22px; }
.lim { font-size: 12.5px; }
.lim-h { display: flex; justify-content: space-between; font-size: 13.5px; }
.lim .bar.big { margin: 6px 0; }
.bar.warn i { background: var(--hot2); }
.bar.hot i { background: var(--hot); }
.ubig { font: 34px var(--fd); line-height: 1.1; }
.udays { display: flex; align-items: flex-end; gap: 6px; height: 130px; padding-top: 6px; }
.ud { flex: 1; max-width: 46px; height: 100%; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; gap: 4px; }
.ud i { display: block; width: 100%; background: var(--accent); border-radius: 4px 4px 0 0; min-height: 2px; }
.ud small { font: 10px ui-monospace, Menlo, monospace; color: var(--muted); }
.urow { display: grid; grid-template-columns: minmax(90px, 160px) minmax(40px, 1fr) 70px; gap: 4px 10px; align-items: center; font-size: 13px; }
.uk { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ub { height: 6px; background: var(--panel2); border-radius: 99px; overflow: hidden; }
.ub i { display: block; height: 100%; background: var(--accent); }
.uv { text-align: right; font: 12px ui-monospace, Menlo, monospace; }
.uc { grid-column: 1 / -1; font-size: 11.5px; margin-top: -3px; }

/* ═════════ правки: вкладки «Шот» и «Звук» ═════════ */
.rv-tabs { padding: 8px 12px; }
.rv-pane { padding: 12px 14px 20px; }
.shot-p { display: grid; gap: 10px; }
.sp-h { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-size: 12.5px; }
.sp-h .d { font-size: 14px; }
.sp-acts { display: grid; gap: 4px; }
.sp-acts button { text-align: left; border-color: var(--line2); }
button.danger { color: #C24E17; }
:root[data-theme="dark"] button.danger { color: var(--hot); }
.au { display: grid; gap: 10px; }
.au-row { display: grid; grid-template-columns: 82px minmax(0, 1fr) 46px; gap: 8px; align-items: center; font-size: 13px; }
.au-row input[type=range] { width: 100%; accent-color: var(--accent); }
.au-row b { font: 12px ui-monospace, Menlo, monospace; font-weight: 400; text-align: right; }
.au-h { display: flex; align-items: center; gap: 8px; border-top: 1px solid var(--line2); padding-top: 10px; font-size: 13px; }
.au-h select { font-size: 12px; max-width: 170px; }
.au-m { display: grid; gap: 8px; font-size: 12.5px; }
.au-m > span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.btnlike { display: inline-flex; align-items: center; justify-self: start; border: 1px solid var(--line); border-radius: 8px; padding: 4px 9px; font-size: 12.5px; cursor: pointer; }
.btnlike:hover { background: var(--hover); }
.sfx-list { display: grid; gap: 4px; max-height: 300px; overflow-y: auto; }
.sfx-r { display: grid; grid-template-columns: auto auto minmax(0, 1fr) 70px auto; gap: 5px; align-items: center; font-size: 12.5px; }
.sfx-r span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sfx-r input[type=range] { width: 70px; accent-color: var(--accent); }
.warn-s { background: var(--hot-bg); padding: 8px 10px; border-radius: 9px; font-size: 12.5px; }

@media (max-width: 1180px) { .sysx { grid-template-columns: minmax(0, 1fr) 320px; } }
@media (max-width: 900px) {
  #app { grid-template-columns: 1fr; }
  #side { display: none; }
  .sysx { grid-template-columns: 1fr; grid-template-rows: 1fr 300px; }
  .upq-r { grid-template-columns: minmax(0, 1fr) 80px; }
}

/* ═════════ раскадровка ═════════ */
#board { display: grid; min-height: 0; }
.bd { display: grid; grid-template-columns: 1fr 360px; min-height: 0; }
.bd-main { min-width: 0; min-height: 0; overflow-y: auto; padding: 14px 18px 40px; display: flex; flex-direction: column; gap: 12px; }
.bd-top { display: flex; align-items: center; gap: 10px; }
.bd-top .d { font-size: 18px; }
.bd-sum { font-size: 13px; line-height: 1.45; background: var(--panel); border: 1px solid var(--line2); border-radius: 12px; padding: 10px 12px; }
.bd-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 14px; align-content: start; }
.bd-grid.big { grid-template-columns: repeat(auto-fill, minmax(460px, 1fr)); }
.bd-grid.vert { grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); }
.bd-grid.vert.big { grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
.bd-empty { display: flex; flex-direction: column; gap: 10px; align-items: center; text-align: center; padding: 60px 20px; }
.bd-empty .d { font-size: 22px; }
.bd-empty p { max-width: 520px; margin: 0; }
.bf { background: var(--panel); border: 1px solid var(--line2); border-radius: 14px; padding: 10px; display: flex; flex-direction: column; gap: 7px; box-shadow: var(--shadow); }
.bf-h { display: flex; align-items: center; gap: 7px; font-size: 12px; }
.bf-h .d { font-size: 15px; }
.bf-h .tm { font: 12px ui-monospace, Menlo, monospace; }
.bf-rc, .bf-cam { font-size: 11px; padding: 2px 7px; border-radius: 99px; background: var(--accent-bg); color: var(--accent); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 120px; }
.bf-cam { background: var(--panel2); color: var(--muted); }
.bf-frame { position: relative; width: 100%; overflow: hidden; border-radius: 8px; cursor: crosshair; container-type: inline-size; outline: 1px solid var(--line2); }
.bcam { position: absolute; overflow: hidden; background: #2a2a2a; }
.bcam img { width: 100%; height: 100%; object-fit: cover; display: block; }
.be { position: absolute; border: 1.5px dashed var(--accent); background: rgba(24, 62, 245, .08); border-radius: 1.2cqw; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; overflow: hidden; padding: .8cqw; color: var(--accent); font: 600 3.2cqw/1.15 var(--ft); }
.be span { position: relative; z-index: 1; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; }
.be i { position: relative; z-index: 1; font: italic 2.4cqw var(--ft); opacity: .8; margin-top: .4cqw; }
.be img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .9; }
.be img + span { background: rgba(255,255,255,.85); border-radius: .8cqw; padding: .2cqw .8cqw; font-size: 2.6cqw; align-self: flex-start; margin-top: auto; }
.be.k-text { border-color: transparent; background: none; color: var(--text); font: 5.5cqw/1.05 var(--fd); text-transform: uppercase; }
.be.k-card, .be.k-subtitle { border-style: solid; background: #fff; color: #0E0E0E; box-shadow: 0 .6cqw 2cqw rgba(0,0,0,.15); }
.be.k-number { font: 9cqw/1 var(--fd); border-color: transparent; background: none; }
.be.k-image, .be.k-video, .be.k-screen { border-color: var(--hot); color: #8a3a12; background: rgba(255, 121, 64, .12); }
.be.k-arrow, .be.k-shape, .be.k-icon { border-color: var(--muted); color: var(--muted); background: rgba(14,14,14,.04); }
.bf-what { font-size: 13px; line-height: 1.4; }
.bf-say { font-size: 12px; color: var(--muted); font-style: italic; line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.bf-sfx { display: flex; flex-wrap: wrap; gap: 5px; font-size: 11px; color: var(--muted); }
.bf-sfx span { background: var(--panel2); border-radius: 99px; padding: 1px 7px; }
.bd-side .pin b { font-size: 12px; }
.bd-acts { display: grid; gap: 8px; padding: 14px; border-bottom: 1px solid var(--line2); }
.bd-acts .btn { width: 100%; justify-content: center; }
.bd-state { font-size: 12.5px; display: grid; gap: 6px; }
.bd-state .bar { margin-top: 4px; }
.bd-side .notes textarea { width: 100%; }
/* музыка и звуки проекта */
.snd-box { display: grid; gap: 6px; padding: 0 14px 14px; font-size: 13px; }
.snd-h { display: flex; align-items: center; gap: 6px; margin-top: 6px; }
.snd-r { display: grid; grid-template-columns: auto auto 1fr auto; gap: 6px; align-items: center; }
.snd-r small { grid-column: 3 / 5; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.snd-r input { min-width: 0; font-size: 12px; padding: 4px 6px; }
.snd-r:not(.own) { grid-template-columns: auto auto 1fr; }
.snd-note { font-size: 12px; }
.snd-more summary { cursor: pointer; color: var(--muted); font-size: 12px; margin: 4px 0; }
.snd-more .snd-r { margin: 3px 0; }
.snd-st { font-size: 12px; min-height: 1em; }
@media (max-width: 900px) { .bd { grid-template-columns: 1fr; } .bd-side { border-left: 0; border-top: 1px solid var(--line); } }
a.btn { text-decoration: none; }
a.btn.ghost { background: transparent; border: 1px solid var(--line); color: var(--text); }
.btn.ghost { background: transparent; border: 1px solid var(--line); color: var(--text); }
/* папки в «Файлах» */
.fnav { margin: 4px 0 12px; }
.spaces { display: flex; gap: 8px; margin-bottom: 8px; flex-wrap: wrap; }
.space { display: flex; align-items: center; gap: 8px; border: 1px solid var(--line); background: var(--panel); color: var(--text); border-radius: 12px; padding: 9px 14px; font-size: 14px; font-weight: 600; }
.space i { font-style: normal; color: var(--accent); }
.space small { color: var(--muted); font-weight: 400; }
.space.on { background: var(--dark); color: #fff; border-color: var(--dark); }
.space.on i { color: var(--hot); }
:root[data-theme="dark"] .space.on { background: #E8E7EE; color: #0E0E0E; }
.space.over { outline: 2px dashed var(--accent); }
.crumbs-f { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; }
.fc-ab { padding: 2px 10px 0; font-size: 11.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; cursor: text; }
.fc-ab:hover { color: var(--accent); }
.crumb-f { border: 0; background: none; padding: 4px 8px; border-radius: 8px; font-size: 14px; color: var(--muted); }
.crumb-f.cur { color: var(--text); font-weight: 600; }
.crumb-f.over, .fc.fd.over { background: var(--accent-bg); outline: 2px dashed var(--accent); }
.fc.fd { cursor: pointer; }
.fc.fd .fc-th { background: var(--accent-bg); }
.fc.fd .fc-ic { color: var(--accent); font-size: 34px; }
.fc-or.rd { background: var(--hot); color: #0E0E0E; left: 6px; right: auto; }
/* выбор музыки и звуков из хранилища */
.pk-top { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.pk-top input { flex: 1; min-width: 160px; }
.spaces.sm { margin: 0; }
.spaces.sm .space { padding: 6px 11px; font-size: 13px; }
.pk-list { max-height: 52vh; overflow: auto; border: 1px solid var(--line2); border-radius: 12px; padding: 4px; margin-top: 6px; }
.pk-r { display: grid; grid-template-columns: auto minmax(90px, 1fr) 2fr auto; gap: 10px; align-items: center; padding: 7px 8px; border-radius: 9px; cursor: pointer; width: 100%; text-align: left; border: 0; background: none; color: var(--text); font-size: 13px; }
.pk-r:hover { background: var(--hover); }
.pk-r.on { background: var(--accent-bg); outline: 1px solid var(--accent); }
.pk-r b, .pk-r small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pk-d { grid-template-columns: auto 1fr auto; }
.pk-d i { font-style: normal; color: var(--accent); }
.pk-empty { padding: 18px; font-size: 13px; }
.btnlike { cursor: pointer; display: inline-flex; align-items: center; }
/* субтитры отдельной дорожкой */
.subs-p { display: flex; flex-direction: column; gap: 10px; padding: 12px; }
.sub-cur { border: 1px solid var(--line2); border-radius: 12px; padding: 10px; display: flex; flex-direction: column; gap: 8px; }
.sub-cur textarea { width: 100%; font-size: 14px; }
.sub-grid { display: grid; grid-template-columns: 70px 1fr; gap: 8px 10px; align-items: center; font-size: 12.5px; }
.sub-grid > span { color: var(--muted); }
.nudge { display: flex; gap: 4px; align-items: center; flex-wrap: wrap; }
.sw-row { display: flex; gap: 5px; align-items: center; flex-wrap: wrap; }
.swc { width: 22px; height: 22px; border-radius: 6px; border: 1px solid var(--line); padding: 0; cursor: pointer; }
.swc.none { background: var(--panel); color: var(--muted); font-size: 12px; line-height: 1; }
.swc.on { outline: 2px solid var(--accent); outline-offset: 1px; }
.sw-row input[type=color] { width: 26px; height: 24px; padding: 0; border: 0; background: none; }
.sub-all summary { cursor: pointer; color: var(--muted); font-size: 12.5px; margin-bottom: 8px; }
.tag.trk-camera { background: #B4B3BF; color: #0E0E0E; }
.tag.trk-graphics { background: var(--accent-bg); color: var(--accent); }
.tag.trk-subtitles { background: #0E0E0E; color: #fff; }
.sw-line { display: flex; gap: 8px; align-items: baseline; font-size: 13px; margin: 6px 0; cursor: pointer; }
.cm-au { font-size: 11px; color: var(--muted); background: var(--panel2); border-radius: 6px; padding: 1px 6px; white-space: nowrap; }
.mini.hold { font-size: 11px; white-space: nowrap; color: var(--accent); }
.mini.hold.on { color: var(--muted); }
/* место на диске */
.fdisk { margin: 0 0 10px; font-size: 12.5px; }
.disk-h { display: flex; gap: 10px; align-items: baseline; flex-wrap: wrap; margin-bottom: 5px; }
.bar.disk { height: 6px; }
.bar.disk.warn i { background: var(--hot2); }
.bar.disk.hot i { background: var(--hot); }
.disk-s { margin-top: 4px; font-size: 11.5px; }
/* журнал трима */
.lg-body { max-height: 62vh; overflow: auto; display: flex; flex-direction: column; gap: 6px; }
.lg-r { display: grid; grid-template-columns: auto auto auto 1fr; gap: 4px 10px; align-items: baseline; padding: 7px 9px; border-radius: 9px; background: var(--panel2); font-size: 12.5px; }
.lg-r.keep { border-left: 3px solid var(--accent); }
.lg-r.cut { border-left: 3px solid var(--hot); }
.lg-r.ai { border-left: 3px solid var(--muted); }
.lg-t { color: var(--muted); font-size: 11.5px; }
.lg-a { font-weight: 600; }
.lg-x { grid-column: 1 / -1; }
.lg-x mark { background: var(--hot-bg); color: var(--text); padding: 0 2px; border-radius: 3px; }
.lg-r.keep mark { background: var(--accent-bg); }
.lg-why { font-size: 11.5px; }
.lg-sum { font-size: 12.5px; margin-bottom: 4px; }
.lg-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin: 6px 0 10px; }
.lg-stats div { background: var(--panel2); border-radius: 10px; padding: 8px 10px; display: flex; flex-direction: column; }
.lg-stats b { font-size: 20px; }
.lg-stats span { font-size: 11.5px; color: var(--muted); }
.lg-rules { white-space: pre-wrap; font: 12.5px/1.45 var(--ft); background: var(--panel2); border-radius: 10px; padding: 10px; margin: 6px 0; }
@media (max-width: 700px) { .lg-stats { grid-template-columns: repeat(2, 1fr); } }
/* доска проектов (канбан) */
.kanban { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(190px, 1fr); gap: 10px; overflow-x: auto; padding-bottom: 10px; align-items: start; min-height: 60vh; }
.kcol { background: var(--panel2); border: 1px solid var(--line2); border-radius: 14px; padding: 8px; display: flex; flex-direction: column; gap: 8px; min-height: 240px; transition: .12s; }
.kcol.over { outline: 2px dashed var(--accent); background: var(--accent-bg); }
.kcol-h { display: flex; gap: 8px; align-items: center; padding: 4px 6px 2px; font-size: 13px; }
.kcol-h .mini { margin-left: auto; }
.kcol-b { display: flex; flex-direction: column; gap: 8px; }
.kcol-e { font-size: 12px; padding: 14px 8px; text-align: center; border: 1px dashed var(--line); border-radius: 10px; }
.kc { background: var(--panel); border: 1px solid var(--line2); border-radius: 12px; padding: 8px; cursor: grab; display: flex; flex-direction: column; gap: 6px; box-shadow: var(--shadow); }
.kc:hover { border-color: var(--accent2); }
.kc.drag { opacity: .45; }
.kc-th { position: relative; border-radius: 8px; overflow: hidden; aspect-ratio: 16 / 9; background: #0E0E0E; }
.kc-th img { width: 100%; height: 100%; object-fit: cover; display: block; }
.kc-nm { font-weight: 600; font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.kc .pc-st { font-size: 11.5px; display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.kc-pub { font-size: 11px; color: #E1306C; }
/* карточка проекта */
.card.xwide { width: min(1120px, calc(100vw - 32px)); max-height: calc(100vh - 40px); overflow: auto; }
.pcard { display: flex; flex-direction: column; gap: 10px; }
.pc-head { display: flex; gap: 10px; align-items: center; }
.pc-title { font-size: 20px; border: 0; background: transparent; color: var(--text); flex: 1; min-width: 0; padding: 4px 0; }
.pc-title:focus { outline: none; border-bottom: 1px solid var(--accent); }
.stg { display: flex; gap: 4px; flex-wrap: wrap; }
.stg-i { display: flex; gap: 6px; align-items: center; border: 1px solid var(--line2); background: var(--panel); color: var(--muted); border-radius: 99px; padding: 5px 11px; font-size: 12.5px; }
.stg-i i { font-style: normal; font-size: 10.5px; }
.stg-i.past { color: var(--text); }
.stg-i.past i::before { content: "✓ "; color: var(--accent); }
.stg-i.cur { background: var(--dark); color: #fff; border-color: var(--dark); }
:root[data-theme="dark"] .stg-i.cur { background: #E8E7EE; color: #0E0E0E; }
.pc-now { display: flex; gap: 8px; align-items: center; font-size: 13px; flex-wrap: wrap; }
.pc-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.pc-col { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.pc-sec { border: 1px solid var(--line2); border-radius: 12px; padding: 12px; display: flex; flex-direction: column; gap: 8px; }
.pc-sh { display: flex; gap: 8px; align-items: center; font-weight: 600; font-size: 14px; }
.pc-sh2 { font-weight: 600; font-size: 13px; margin: 4px 0; }
.pc-sec textarea { width: 100%; }
.pc-st2 { font-size: 11.5px; min-height: 1em; }
.pc-clips { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 8px; }
.pc-clip { border-radius: 9px; overflow: hidden; background: var(--panel2); font-size: 11.5px; }
.pc-clip img, .pc-clip > span { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; display: grid; place-items: center; background: #0E0E0E; color: #fff; }
.pc-clip small { display: block; padding: 4px 6px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pc-video { width: 100%; max-height: 56vh; border-radius: 10px; background: #000; }
.pub-yt, .pub-ig { display: flex; flex-direction: column; gap: 6px; }
.pub-ig { border-top: 1px solid var(--line2); padding-top: 10px; margin-top: 4px; }
.ok-s { color: var(--accent); font-size: 13px; }
.howto-l { padding-left: 18px; display: flex; flex-direction: column; gap: 8px; font-size: 13.5px; }
@media (max-width: 860px) { .pc-grid { grid-template-columns: 1fr; } }
/* этап проекта в шапке */
.stage-btn { border: 0; background: var(--dark); color: #fff; border-radius: 9px; padding: 6px 10px 5px; font-size: 12.5px; display: flex; gap: 6px; align-items: center; margin-right: 3px; }
.stage-btn i { font-style: normal; font-size: 10.5px; opacity: .7; }
.stage-btn b { color: var(--hot); }
:root[data-theme="dark"] .stage-btn { background: #E8E7EE; color: #0E0E0E; }
.mode.stage-cur::after { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--hot); }
.pc-clips > .muted { grid-column: 1 / -1; }

/* ── доска: рилсы / длинные, пространства ── */
.proj-bar { display: flex; align-items: center; gap: 12px; margin: 4px 0 14px; flex-wrap: wrap; }
.seg .seg-i small { margin-left: 5px; color: var(--muted); font-size: 11px; }
.seg.sm button { padding: 3px 9px; font-size: 12px; }
.pb-sp { display: flex; align-items: center; gap: 6px; font-size: 13px; }
.fmt-b { display: inline-block; width: 15px; margin-right: 4px; color: var(--muted); font-size: 12px; }
.fmt-b.reels { color: var(--hot); }
.kc-sp { font-size: 11px; margin-top: -2px; }
.pc-head #pcSpace { max-width: 170px; }
/* ── команда и доступ ── */
.team .tm-list { display: grid; gap: 6px; }
.tm-row { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border: 1px solid var(--line2); border-radius: 10px; background: var(--panel); flex-wrap: wrap; }
.tm-row.off { opacity: .55; }
.tm-who { display: grid; min-width: 160px; }
.tm-who .muted { font-size: 12px; }
.tm-acc { display: flex; gap: 4px; flex-wrap: wrap; font-size: 12px; }
.tm-chip { background: var(--panel2); border-radius: 6px; padding: 2px 7px; }
.tm-all { color: var(--accent); }
.tm-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 10px 0; }
.tm-sps { display: flex; flex-wrap: wrap; gap: 6px 14px; margin: 6px 0; }
.tm-sps.dis { opacity: .5; }
.tm-ck { display: inline-flex; gap: 6px; align-items: center; font-size: 13px; color: var(--text); }
@media (max-width: 700px) { .tm-grid { grid-template-columns: 1fr; } }
