:root{font-family:Inter,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;color:#192a29;background:#f6f7f4;font-synthesis:none;--ink:#192a29;--muted:#536865;--line:#d5dfd7;--pine:#153e35;--accent:#09634c;--tint:#e9f4ea}
*{box-sizing:border-box}
[hidden]{display:none!important}
body{margin:0}
button,input,select{font:inherit}
button{cursor:pointer}
button:disabled{cursor:wait;opacity:.65}
button:focus-visible,input:focus-visible,select:focus-visible{outline:3px solid #139977;outline-offset:3px}
button:focus:not(:focus-visible){outline:none}
h1,h2,p{margin:0}
h1{font-size:clamp(1.75rem,3vw,2.4rem);line-height:1.12;letter-spacing:-.055em}
h2{font-size:1.1rem;line-height:1.3;letter-spacing:-.025em}
p{line-height:1.55}
.muted,.meta{color:var(--muted)}
.topbar{height:72px;display:flex;align-items:center;gap:26px;background:var(--pine);color:white;padding:0 clamp(20px,4vw,64px)}
.brand{display:flex;align-items:center;gap:10px;font-size:1.7rem;font-weight:700;letter-spacing:-.075em}
.brand-mark{display:flex;align-items:flex-end;justify-content:center;gap:3px;width:33px;height:33px;padding:7px 5px;border-radius:8px;background:#c0edab}
.brand-mark i{display:block;width:5px;transform:skew(-12deg);height:12px;background:#174336;border-radius:2px}
.brand-mark i:nth-child(2){height:18px}.brand-mark i:nth-child(3){height:15px}
.product-name{font-size:.88rem;letter-spacing:.01em;color:#e1eee3;border-left:1px solid #53806e;padding-left:24px}
.btn{display:inline-flex;align-items:center;justify-content:center;gap:.45rem;min-height:42px;padding:9px 15px;border:1px solid #bfcfc4;border-radius:9px;background:#fff;color:var(--pine);font-weight:600;font-size:.9rem;line-height:1.25}
.btn:hover{background:#f0f4ee}
.btn.primary{background:var(--accent);border-color:var(--accent);color:white}.btn.primary:hover{background:#064c3a}
.btn.danger{color:white;background:#8e372a;border-color:#8e372a}
.top-action{margin-left:auto;min-height:36px;background:transparent;color:#f0f7ef;border-color:#56796a;padding:6px 15px}.top-action:hover{background:#285246}
.loading{padding:50px;text-align:center;color:var(--muted)}
.login-wrap{display:grid;place-items:center;min-height:calc(88vh - 72px);padding:28px 20px}
.login-card,.empty-card,dialog,.chat-pane,.summary-pane{background:white;border:1px solid var(--line);border-radius:16px}
.login-card{width:min(100%,420px);padding:clamp(24px,4vw,40px);box-shadow:0 4px 24px #173e350a}
.login-card .muted{margin:12px 0 27px}.login-card .btn{width:100%;margin-top:18px}
label{display:block;font-size:.86rem;font-weight:650;margin-bottom:7px}
input,select{width:100%;min-width:0;min-height:43px;border:1px solid #b8c8bf;border-radius:8px;background:white;padding:9px 12px;color:var(--ink)}
input::placeholder{color:#657874}
.workspace{max-width:1610px;margin:auto;display:grid;grid-template-columns:clamp(210px,19vw,285px) minmax(0,1fr);min-height:calc(100vh - 72px)}
.sidebar{padding:37px clamp(16px,2vw,30px);border-right:1px solid var(--line);background:#eff2ec}
.sidebar>h2{margin:0 0 18px 5px}.account-list{display:grid;gap:5px}
.account,.chat{width:100%;display:flex;align-items:center;gap:11px;text-align:left;color:var(--ink);background:transparent;border:1px solid transparent;border-radius:9px;padding:10px;min-width:0}
.account:hover,.chat:hover{background:#f4f6f1}.account[aria-pressed=true],.chat[aria-pressed=true]{background:#e0eee1;border-color:#c2d9c8}
.account-icon{display:grid;place-items:center;width:33px;height:33px;flex-shrink:0;border:1px solid #c3d1c7;background:white;border-radius:8px;color:#346653;font-size:.74rem;font-weight:700}
.account-info,.chat-info{display:grid;gap:3px;min-width:0}.account-info strong,.chat-info strong{overflow-wrap:anywhere;font-size:.9rem;font-weight:620}
.account-info small,.chat-info small,.count,.meta{color:var(--muted);font-size:.77rem;line-height:1.45}
.new-account{margin-top:16px;width:100%}.new-account span{font-size:1.2rem}
.content{padding:clamp(24px,3.4vw,54px);min-width:0}
.page-head,.account-actions,.pane-header,.dialog-actions{display:flex;align-items:center;gap:12px}
.page-head{justify-content:space-between;align-items:flex-start;margin-bottom:25px}.page-head .muted{margin-top:7px;overflow-wrap:anywhere}
.account-actions{justify-content:flex-end;flex-wrap:wrap}.account-actions .btn{min-height:36px;padding:7px 12px}
.badge,.count{border-radius:20px;padding:4px 10px;white-space:nowrap;font-size:.76rem;font-weight:650}
.badge{background:#e7ebe6;color:#455650}.badge.connected{background:#def0df;color:#205637}.badge.pair{background:#fff0c7;color:#775411}.badge.error-state{background:#fbe6e1;color:#883e2b}
.empty-card{padding:clamp(24px,4vw,48px);max-width:700px}.empty-card p{margin:8px 0 20px}
.pairing{display:flex;align-items:center;gap:24px;background:var(--tint);border:1px solid #c7ddc9;border-radius:16px;padding:20px;margin:0 0 20px}
.qr-slot{flex:0 0 193px;min-height:193px;display:grid;place-items:center;background:white;border-radius:9px;overflow:hidden;text-align:center;font-size:.85rem;color:var(--muted)}
.qr-slot img{width:193px;height:193px;image-rendering:pixelated}.pairing p{margin-top:8px;max-width:52ch}
.conversation-layout{display:grid;grid-template-columns:minmax(225px,.75fr) minmax(300px,1.25fr);gap:16px;align-items:start}
.chat-pane,.summary-pane{min-width:0;padding:20px}.pane-header{justify-content:space-between;margin-bottom:16px}.count{background:#edf2ed}
.chat-list{display:grid;gap:3px;max-height:62vh;overflow-y:auto;margin-top:12px;scrollbar-width:thin}
.chat{padding:10px 8px}.list-empty{font-size:.88rem;margin:14px 0 4px}
.chosen-chat{font-size:1.05rem;font-weight:650;overflow-wrap:anywhere;margin-bottom:16px}
.summary-form{display:flex;align-items:flex-end;gap:9px;flex-wrap:wrap}.summary-form>div{flex:1 1 150px}
.summary-form .btn{min-height:43px}.summary-result{margin-top:24px;padding-top:18px;border-top:1px solid var(--line)}
.summary-text{white-space:pre-wrap;overflow-wrap:anywhere;line-height:1.62;margin-top:12px;font-size:.95rem}
.error{font-size:.9rem;color:#883729;margin-top:10px}.panel-notice{padding:12px 14px;background:#fff0eb;border:1px solid #eed0c9;border-radius:9px;margin:0 0 15px}
dialog{width:min(430px,calc(100% - 32px));padding:26px;color:var(--ink);box-shadow:0 20px 80px #132e3022}
dialog::backdrop{background:#0b282b70}dialog .muted{margin:10px 0 18px}.dialog-actions{justify-content:flex-end;margin-top:24px}
.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
@media(max-width:1060px){.conversation-layout{grid-template-columns:minmax(190px,.85fr) minmax(235px,1.15fr)}.content{padding:24px}.chat-pane,.summary-pane{padding:16px}}
@media(max-width:790px){.workspace{display:block}.sidebar{border:0;border-bottom:1px solid var(--line);padding:14px 18px;display:flex;align-items:center;flex-wrap:wrap;gap:8px}.sidebar>h2{margin:0 10px 0 0}.account-list{display:flex;overflow:auto;flex:1;min-width:120px}.account{white-space:nowrap;width:auto}.account-icon{display:none}.new-account{width:auto;margin:0}.conversation-layout{grid-template-columns:1fr 1.25fr}.content{padding:22px 18px}.chat-list{max-height:48vh}}
@media(max-width:610px){.topbar{height:60px;padding:0 18px;gap:14px}.product-name{padding-left:14px;font-size:.8rem}.sidebar{align-items:center}.sidebar>h2{font-size:.95rem}.account-list{order:3;flex-basis:100%}.account-list:empty{display:none}.new-account{margin-left:auto;min-height:36px;padding:6px 10px}.content{padding:22px 14px}.page-head{flex-wrap:wrap;gap:12px}.conversation-layout{grid-template-columns:1fr}.chat-list{max-height:215px}.pairing{flex-direction:column;gap:14px;align-items:flex-start}.qr-slot{align-self:center}.account-actions{justify-content:flex-start}.summary-form .btn{flex:1}.login-wrap{min-height:calc(82vh - 60px)}}
