/* PAVEL 2 new app. Colour = meaning: accent = main action / Pasha,
   ok = ready, warn = your decision needed, live = on air / STOP. */
:root{
  --bg:#0E0F12;--surface:#16181D;--surface-2:#1B1E24;--border:#23262D;--border-2:#2C3038;
  --text:#ECEDEF;--text-2:#B4B9C2;--text-3:#8A909B;
  --accent:#9DB4FF;--accent-ink:#0E0F12;--accent-soft:#1A2033;--accent-text:#C7D4FF;
  --ok:#3DD68C;--warn:#F5A524;--live:#FF5A5F;--live-text:#FF8A8D;
  --radius:16px;--font:Inter,"Segoe UI",system-ui,-apple-system,sans-serif;
  --mono:"JetBrains Mono",ui-monospace,Consolas,monospace;
  color-scheme:dark;
}
:root[data-theme="light"]{
  --bg:#F7F7F8;--surface:#FFFFFF;--surface-2:#F0F1F4;--border:#E3E5EA;--border-2:#D3D6DD;
  --text:#14161A;--text-2:#4A505B;--text-3:#6B7280;
  --accent:#3355D6;--accent-ink:#FFFFFF;--accent-soft:#E8EDFF;--accent-text:#2443B8;
  --ok:#14955B;--warn:#B76E00;--live:#D92D33;--live-text:#C0262C;
  color-scheme:light;
}
@media (prefers-color-scheme: light){
  :root:not([data-theme="dark"]){
    --bg:#F7F7F8;--surface:#FFFFFF;--surface-2:#F0F1F4;--border:#E3E5EA;--border-2:#D3D6DD;
    --text:#14161A;--text-2:#4A505B;--text-3:#6B7280;
    --accent:#3355D6;--accent-ink:#FFFFFF;--accent-soft:#E8EDFF;--accent-text:#2443B8;
    --ok:#14955B;--warn:#B76E00;--live:#D92D33;--live-text:#C0262C;
    color-scheme:light;
  }
}
*{box-sizing:border-box}
html,body{margin:0;height:100%;background:var(--bg);color:var(--text);font-family:var(--font);font-size:16px;line-height:1.5}
a{color:var(--accent-text)}
button,input,textarea,select{font:inherit;color:inherit}
:focus-visible{outline:2px solid var(--accent);outline-offset:2px}
.shell{display:flex;min-height:100vh}
.side{flex:0 0 232px;display:flex;flex-direction:column;gap:4px;padding:24px 16px;border-right:1px solid var(--border);position:sticky;top:0;height:100vh}
.brand{display:flex;align-items:center;gap:10px;padding:4px 10px 24px}
.brand-mark{width:32px;height:32px;border-radius:10px;background:var(--accent);color:var(--accent-ink);display:flex;align-items:center;justify-content:center;font-weight:700;overflow:hidden}
[hidden]{display:none!important}
.login{min-height:100vh;display:flex;align-items:center;justify-content:center;padding:24px 16px;background:var(--bg)}
.login-card{width:100%;max-width:420px;display:flex;flex-direction:column;gap:16px}
.login-card h1{margin:8px 0 0;font-size:28px;line-height:1.2}
.login-card .lead{margin:0}
.login-form{display:flex;flex-direction:column;gap:10px}
.login-card .small{font-size:13px}
.login .brand{display:flex!important;padding:0}
dialog.proof{border:1px solid var(--border);border-radius:16px;padding:0;max-width:520px;width:calc(100% - 32px);background:var(--surface);color:inherit}
dialog.proof::backdrop{background:#0008}
.proof-box{display:flex;flex-direction:column;gap:14px;padding:22px}
.proof-phrase{margin:0;font-size:24px;line-height:1.4;font-weight:600;text-align:center;padding:14px;border-radius:12px;background:var(--surface-2)}
.brand-mark img{width:100%;height:100%;object-fit:cover;display:block}
.who-av{width:20px;height:20px;border-radius:50%;object-fit:cover;vertical-align:middle;margin-right:6px}
.talk-av{width:72px;height:72px;border-radius:50%;object-fit:cover;display:block;margin:0 auto 14px}
.avatar-big{width:72px;height:72px;border-radius:50%;background:var(--accent);color:var(--accent-ink);display:flex;align-items:center;justify-content:center;font-size:28px;font-weight:700;overflow:hidden;flex:none}
.avatar-big img{width:100%;height:100%;object-fit:cover;display:block}
.brand-name{font-weight:600}
.side a{display:flex;align-items:center;gap:10px;padding:10px 12px;border-radius:8px;color:var(--text-2);text-decoration:none;font-size:14px}
.side a svg{width:18px;height:18px;fill:none;stroke:currentColor;stroke-width:1.8;flex:none}
.side a:hover{background:var(--surface-2);color:var(--text)}
.side a.on{background:var(--surface-2);color:var(--text);font-weight:500}
.side a.quiet{color:var(--text-3);font-size:13px}
.side-gap{flex:1}
.side-extra{display:flex;flex-direction:column;gap:2px}
.side-extra .label{padding:16px 12px 4px;font-size:12px;font-weight:600;letter-spacing:.06em;color:var(--text-3)}
.side-extra a{font-size:13px;padding:8px 12px}
.view{flex:1;min-width:0;outline:none}
.page{max-width:760px;margin:0 auto;padding:48px 40px;display:flex;flex-direction:column;gap:24px}
.eyebrow{font-size:13px;color:var(--text-3);letter-spacing:.04em;text-transform:uppercase}
h1{margin:0;font-size:32px;font-weight:600;letter-spacing:-.02em;line-height:1.2}
h2{margin:0;font-size:15px;font-weight:600;color:var(--text-2)}
.lead{margin:0;color:var(--text-2)}
.muted{color:var(--text-3);font-size:14px}
.card{background:var(--surface);border:1px solid var(--border);border-radius:var(--radius);padding:20px 24px}
.btn{height:44px;padding:0 18px;border-radius:12px;border:1px solid var(--border-2);background:transparent;color:var(--text);cursor:pointer;display:inline-flex;align-items:center;justify-content:center;gap:8px;font-size:15px;font-weight:500;text-decoration:none}
.btn:hover{background:var(--surface-2)}
.btn:disabled{opacity:.45;cursor:not-allowed}
.btn.primary{background:var(--accent);border-color:var(--accent);color:var(--accent-ink);font-weight:600}
.btn.primary:hover{filter:brightness(1.06)}
.btn.big{height:64px;font-size:18px;border-radius:16px;width:100%}
.btn.stop{background:var(--live);border-color:var(--live);color:#fff;font-weight:600;height:52px}
.btn.small{height:36px;padding:0 12px;font-size:13px;border-radius:10px}
.chips{display:flex;flex-wrap:wrap;gap:8px}
.chip{height:36px;padding:0 14px;border-radius:999px;border:1px solid var(--border-2);background:transparent;color:var(--text-2);font-size:13px;cursor:pointer}
.chip.on{border-color:var(--accent);background:var(--accent-soft);color:var(--accent-text);font-weight:500}
.field{display:flex;flex-direction:column;gap:6px}
.field label{font-size:14px;color:var(--text)}
.input,textarea.input,select.input{width:100%;min-height:44px;padding:10px 14px;border-radius:10px;border:1px solid var(--border-2);background:var(--bg);color:var(--text)}
textarea.input{resize:vertical;line-height:1.5}
.toast{position:fixed;left:50%;bottom:24px;transform:translateX(-50%);background:var(--surface-2);border:1px solid var(--border-2);padding:12px 18px;border-radius:12px;display:none;max-width:90vw;z-index:20}
.toast.show{display:block}
.toast.bad{border-color:var(--live)}
/* readiness checklist */
.checks{padding:4px 24px}
.check{display:flex;align-items:flex-start;gap:14px;padding:16px 0;border-bottom:1px solid var(--border)}
.check:last-child{border-bottom:none}
.dot{width:10px;height:10px;border-radius:50%;flex:none;margin-top:7px;background:var(--text-3)}
.dot.ok{background:var(--ok)}.dot.warn{background:var(--warn)}.dot.bad{background:var(--live)}
.dot.wait{background:transparent;border:2px solid var(--text-3);animation:pulse 1.2s infinite}
@keyframes pulse{50%{opacity:.3}}
.check-body{flex:1;min-width:0}
.check-title{font-size:15px}
.check-note{font-size:13px;color:var(--text-3);margin-top:2px}
.check-action{flex:none;display:flex;gap:8px;align-items:center}
.check details{margin-top:8px;font-size:14px;color:var(--text-2)}
.check details ol{margin:8px 0 0;padding-left:20px}
.toggle{display:inline-flex;align-items:center;gap:8px;font-size:14px;cursor:pointer}
.toggle input{width:18px;height:18px;accent-color:var(--accent)}
.call-list{display:flex;flex-direction:column;gap:12px}
.call-item{display:flex;align-items:center;gap:16px;text-decoration:none;color:var(--text)}
.call-item:hover{border-color:var(--border-2)}
.call-item .grow{flex:1;min-width:0}
.call-item .t{font-weight:600}
.under{margin:-12px 0 0;text-align:center;font-size:13px;color:var(--text-3)}
/* live call */
.live{display:flex;flex-direction:column;min-height:100vh}
.live-top{display:flex;flex-wrap:wrap;align-items:center;gap:16px;padding:16px 32px;border-bottom:1px solid var(--border)}
.onair{display:flex;align-items:center;gap:10px;font-size:13px;font-weight:600;letter-spacing:.05em;color:var(--live-text)}
.onair .dot{margin:0;background:var(--live)}
.timer{font-family:var(--mono);font-size:14px;color:var(--text-2)}
.live-title{flex:1;font-weight:500}
.pills{display:flex;gap:8px;flex-wrap:wrap}
.pill{display:flex;align-items:center;gap:8px;padding:6px 12px;border-radius:999px;background:var(--surface);border:1px solid var(--border);font-size:13px;color:var(--text-2)}
.pill .dot{margin:0;width:8px;height:8px}
.live-mid{flex:1;display:flex;min-height:0}
.feed{flex:1;min-width:0;padding:28px 40px;display:flex;flex-direction:column;gap:18px;overflow:auto;max-height:calc(100vh - 170px)}
.line{max-width:760px;display:flex;flex-direction:column;gap:4px}
.line .who{font-size:12px;font-weight:600;letter-spacing:.06em;color:var(--text-3)}
.line .en{font-size:18px;line-height:1.5;color:var(--text-2)}
.line .ru{font-size:14px;color:var(--text-3)}
.line.pasha{align-self:flex-end;background:var(--surface);border:1px solid var(--border);border-radius:16px;padding:14px 18px}
.line.pasha .who{color:var(--accent-text)}
.line.pasha .en{color:var(--text)}
.now{margin-top:auto;border:1px dashed var(--border-2);border-radius:16px;padding:18px 20px;max-width:760px}
.now .who{font-size:12px;font-weight:600;letter-spacing:.06em;display:flex;align-items:center;gap:10px}
.now .txt{font-size:19px;line-height:1.5;margin-top:4px}
.now .sub{font-size:13px;color:var(--text-3);margin-top:4px}
.bars{display:inline-flex;gap:3px;align-items:center;height:20px}
.bars i{width:3px;border-radius:2px;background:var(--text);height:6px;transition:height .12s}
.aside{flex:0 0 320px;padding:28px 24px;border-left:1px solid var(--border);display:flex;flex-direction:column;gap:14px;overflow:auto;max-height:calc(100vh - 170px)}
.aside h3{margin:0;font-size:12px;font-weight:600;letter-spacing:.06em;color:var(--text-3)}
.aside h3.warn{color:var(--warn)}
.aside ul{margin:0;padding:0;list-style:none;display:flex;flex-direction:column;gap:10px;font-size:14px;color:var(--text-2)}
.live-bottom{display:flex;flex-wrap:wrap;gap:12px;align-items:center;padding:16px 32px;border-top:1px solid var(--border);background:var(--surface)}
.live-bottom .input{flex:1 1 300px;height:52px}
.hint-chip{font-size:13px;color:var(--accent-text)}
/* talk */
.talk{display:flex;flex-direction:column;min-height:100vh}
.talk-top{display:flex;flex-wrap:wrap;align-items:center;gap:8px;padding:16px 40px;border-bottom:1px solid var(--border)}
.talk-top .grow{flex:1}
.talk-feed{flex:1;padding:32px 40px;display:flex;flex-direction:column;gap:22px;overflow:auto}
.msg-me{align-self:flex-end;max-width:620px;background:var(--surface-2);border-radius:16px 16px 4px 16px;padding:12px 16px;white-space:pre-wrap}
.msg-p{max-width:720px;display:flex;flex-direction:column;gap:8px}
.msg-p .who{font-size:12px;font-weight:600;letter-spacing:.06em;color:var(--accent-text)}
.msg-p .meta{font-size:12px;color:var(--text-3)}
.talk-empty{margin:auto;text-align:center;max-width:460px;color:var(--text-2)}
.talk-empty h1{margin-bottom:8px}
.composer{padding:16px 40px 24px}
.composer-box{display:flex;align-items:flex-end;gap:12px;max-width:880px;margin:0 auto;background:var(--surface);border:1px solid var(--border-2);border-radius:20px;padding:10px 10px 10px 18px}
.composer-box textarea{flex:1;min-height:48px;max-height:220px;border:none;background:transparent;resize:none;outline:none;line-height:1.5;padding:12px 0}
.round{width:48px;height:48px;border-radius:50%;border:1px solid var(--border-2);background:var(--bg);display:flex;align-items:center;justify-content:center;cursor:pointer;flex:none}
.round.primary{background:var(--accent);border-color:var(--accent);color:var(--accent-ink)}
.round svg{width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:2}
.typing{color:var(--text-3);font-size:14px}
@media (max-width:860px){
  .shell{flex-direction:column}
  .side{flex:none;height:auto;position:static;flex-direction:row;flex-wrap:wrap;padding:10px 16px;border-right:none;border-bottom:1px solid var(--border)}
  .brand,.side-gap,.side-extra{display:none}
  .page{padding:24px 16px}
  .aside{display:none}
  .feed,.talk-feed{padding:20px 16px}
  .live-top,.live-bottom,.talk-top,.composer{padding-left:16px;padding-right:16px}
}
/* stage 2-5 additions */
.attach{max-width:880px;margin:0 auto 8px;display:flex;flex-wrap:wrap;gap:8px;align-items:center}
.doc-chip{display:inline-flex;align-items:center;gap:6px;padding:6px 12px;border-radius:999px;background:var(--accent-soft);color:var(--accent-text);font-size:13px}
.msg-doc{align-self:flex-end;font-size:13px;color:var(--accent-text);background:var(--accent-soft);padding:6px 12px;border-radius:999px}
.msg-actions{margin-top:4px}
.round.rec{background:var(--live);border-color:var(--live);color:#fff;animation:pulse 1.2s infinite}
.composer.drop .composer-box{border-color:var(--accent);box-shadow:0 0 0 3px var(--accent-soft)}
.row{display:flex;flex-wrap:wrap;gap:8px;align-items:center}
.list-plain{margin:0;padding:0;list-style:none;display:flex;flex-direction:column;gap:10px}
.result{display:flex;flex-direction:column;gap:4px}
.result .src{font-size:12px;color:var(--text-3)}
.tabs{display:flex;gap:4px;border-bottom:1px solid var(--border)}
.tabs button{background:none;border:none;border-bottom:2px solid transparent;padding:10px 14px;color:var(--text-2);cursor:pointer;font-size:14px}
.tabs button.on{border-color:var(--accent);color:var(--text);font-weight:500}
.stat{display:flex;flex-direction:column;gap:2px}
.stat b{font-size:24px;font-weight:600}
.stats{display:grid;grid-template-columns:repeat(auto-fit,minmax(140px,1fr));gap:12px}
.transcript .line{max-width:none}
.dropzone{border:1.5px dashed var(--border-2);border-radius:16px;padding:24px;text-align:center;color:var(--text-2);cursor:pointer}
.dropzone.drop{border-color:var(--accent);background:var(--accent-soft)}

/* Prompter (суфлёр): Pavel <-> Pasha privately during a call */
.prompter{display:flex;gap:10px;flex-wrap:wrap;width:100%}
.btn.ptt{height:52px;font-weight:600;border-style:dashed;touch-action:none;user-select:none}
.btn.ptt kbd{font-family:var(--mono);font-size:12px;border:1px solid var(--border-2);border-radius:6px;padding:1px 6px;margin-left:6px;color:var(--text-3)}
.btn.ptt.on{background:var(--accent);border-color:var(--accent);color:var(--accent-ink)}
.btn.ptt.on kbd{color:var(--accent-ink);border-color:var(--accent-ink)}
.ptt-banner{width:100%;font-size:13px;color:var(--accent-text);min-height:18px}
.line.owner{align-self:flex-end;border:1px dashed var(--accent);border-radius:16px;padding:10px 16px;background:var(--accent-soft)}
.line.owner .who{color:var(--accent-text)}
.ask-card{max-width:760px;border:2px solid var(--warn);border-radius:16px;padding:16px 20px;background:var(--surface);display:flex;flex-direction:column;gap:8px}
.ask-card .ask-title{font-size:12px;font-weight:700;letter-spacing:.06em;color:var(--warn)}
.ask-card .ask-q{font-size:20px;line-height:1.4;font-weight:600}
.ask-card .ask-help{font-size:13px;color:var(--text-2)}
.whispers{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:8px}
.whispers li{font-size:13px;line-height:1.45;border-left:2px solid var(--accent);padding-left:8px}
.whispers .q{color:var(--text-3)}
/* «Встреча»: Meet-style grouped transcript */
.meet-live{display:flex;flex-direction:column;height:100vh;height:100dvh}
.m-top{display:flex;align-items:center;gap:16px;padding:14px 32px;border-bottom:1px solid var(--border);background:var(--surface)}
.m-top .live-title{flex:1;font-weight:600;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.m-mid{flex:1;display:grid;grid-template-columns:minmax(0,1fr) 320px;min-height:0}
.m-feed-wrap{position:relative;display:flex;flex-direction:column;min-height:0;padding:16px 32px 0}
.m-feed{flex:1;overflow-y:auto;display:flex;flex-direction:column;gap:18px;padding-bottom:24px}
.m-feed.static{overflow:visible}
.m-jump{position:absolute;bottom:16px;left:50%;transform:translateX(-50%)}
.m-empty{color:var(--text-3);padding:40px 0;text-align:center}
.m-speakers{display:flex;flex-wrap:wrap;align-items:center;gap:8px;padding-bottom:12px}.m-speakers.open{max-height:30vh;overflow-y:auto}.m-more{white-space:nowrap}
.m-chip{display:inline-flex;align-items:center;gap:6px;border:1px solid var(--border);border-radius:999px;padding:3px 10px 3px 3px;font-size:13px;background:var(--surface)}
.m-chip .m-ava{width:22px;height:22px;font-size:10px}
.link{background:none;border:0;padding:0;color:var(--accent-text);cursor:pointer;font:inherit}
.link.small{font-size:12px;color:var(--text-3)}
.m-group{display:flex;gap:12px;align-items:flex-start;max-width:860px}
.m-ava{flex:none;width:36px;height:36px;border-radius:50%;display:inline-flex;align-items:center;justify-content:center;font-size:13px;font-weight:700;color:#fff}
.m-ava.c0{background:#5B7CFA}.m-ava.c1{background:#E0606A}.m-ava.c2{background:#2FA77A}.m-ava.c3{background:#C98A1B}
.m-ava.c4{background:#9A5BE0}.m-ava.c5{background:#1F9BB8}.m-ava.c6{background:#D2558F}.m-ava.c7{background:#6E8B3D}
.m-ava.cme{background:var(--text-3)}
.m-body{flex:1;min-width:0;display:flex;flex-direction:column;gap:6px}
.m-who{display:flex;align-items:baseline;gap:10px}
.m-name{background:none;border:0;padding:0;font:inherit;font-weight:700;font-size:14px;color:var(--text);cursor:pointer}
.m-name:disabled{cursor:default}
.m-name:not(:disabled):hover{text-decoration:underline}
.m-time{font-size:12px;color:var(--text-3);font-family:var(--mono)}
.m-line{position:relative;padding-right:64px}
.m-text{font-size:18px;line-height:1.5}
.m-orig{font-size:13px;line-height:1.4;color:var(--text-3);margin-top:2px}
.m-pending{color:var(--text-3);font-size:15px}
.m-fix{position:absolute;right:0;top:2px;opacity:0;background:none;border:1px solid var(--border);border-radius:8px;font-size:11px;color:var(--text-3);padding:1px 6px;cursor:pointer}
.m-line:hover .m-fix,.m-fix:focus{opacity:1}
.m-group.me .m-name{color:var(--text-2)}
.m-audio{display:flex;gap:16px;flex-wrap:wrap}
.m-audio audio{height:36px;max-width:100%}
.m-summary h3{margin:14px 0 6px;font-size:15px}
.m-summary li{margin-left:18px;line-height:1.5}
.m-summary p{margin:4px 0;line-height:1.5}
.m-title-btn{background:none;border:0;padding:0;font:inherit;color:inherit;cursor:pointer;text-align:left}
.warn-note{color:var(--warn);margin:0}
@media (max-width:900px){.m-mid{grid-template-columns:1fr}.m-mid .aside{border-top:1px solid var(--border)}.m-top,.m-feed-wrap{padding-left:16px;padding-right:16px}}
.m-jump[hidden]{display:none}

/* 'Узнай меня': facts Pasha extracted from Pavel's answer, to confirm */
.fact-pick{display:flex;flex-direction:column;gap:8px;align-self:flex-end;max-width:640px;width:100%}
.fact-row{display:flex;gap:8px;align-items:flex-start}
.fact-row input{margin-top:10px}
.fact-row textarea{flex:1;resize:vertical;min-height:44px}

/* Call prep: public web research Pasha may talk about */
.research{font-size:14px;line-height:1.5;max-height:320px;overflow:auto;padding:10px 12px;border-radius:10px;background:var(--surface-2,rgba(127,127,127,.08))}
.meter{display:inline-block;width:90px;height:6px;border-radius:3px;background:var(--line,#8884);overflow:hidden;vertical-align:middle}
.meter>span{display:block;height:100%;width:0;background:var(--accent,#3b82f6);transition:width .08s}
/* «Синхрон» */
.interp .card{max-width:none}
.interp-cols{display:grid;grid-template-columns:1fr 1fr;gap:16px;align-items:start}
@media (max-width:900px){.interp-cols{grid-template-columns:1fr}}
.interp-feed{display:flex;flex-direction:column;gap:12px;max-height:56vh;overflow:auto}
.interp-feed li{display:flex;flex-direction:column;gap:3px;padding-bottom:10px;border-bottom:1px solid var(--line,#8883)}
.interp-feed .i-said{font-size:17px;line-height:1.45}
.interp-feed .i-src{font-size:13px}
.interp-feed .i-meta{font-size:12px}
.interp-feed .btn.small{align-self:flex-start;margin-top:4px}
