:root{--bg: #f0f2f5;--panel: #ffffff;--chat-bg: #efeae2;--mine: #d9fdd3;--theirs: #ffffff;--grey: #e9e9e9;--text: #111b21;--muted: #667781;--line: #e9edef;--accent: #0b8a6b;--gap: #b26a00;--system: #fff5c4;--selected: #f0f2f5;color-scheme:light;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,sans-serif;font-size:15px;color:var(--text)}@media (prefers-color-scheme: dark){:root{--bg: #0b141a;--panel: #111b21;--chat-bg: #0b141a;--mine: #005c4b;--theirs: #202c33;--grey: #2a3942;--text: #e9edef;--muted: #8696a0;--line: #222d34;--system: #3b3420;--selected: #202c33;color-scheme:dark}}*{box-sizing:border-box}body{margin:0;background:var(--bg)}button{font:inherit}.muted{color:var(--muted)}.small{font-size:12px}.pad{padding:12px 16px}.error{color:#d93025}.center{display:flex;align-items:center;justify-content:center;min-height:100vh;padding:16px;text-align:center}.login{background:var(--panel);padding:32px;border-radius:12px;width:min(360px,100%);display:flex;flex-direction:column;gap:12px;align-items:stretch;box-shadow:0 1px 3px #0000001a}.login img{align-self:center;border-radius:14px}.login h1{margin:0}.login input{padding:10px 12px;border:1px solid var(--line);border-radius:8px;background:var(--bg);color:var(--text);font:inherit}.login button,.sheet button{padding:10px;border:0;border-radius:8px;background:var(--accent);color:#fff;cursor:pointer}.login button:disabled{opacity:.5;cursor:default}.app{display:grid;grid-template-columns:minmax(260px,360px) 1fr;height:100vh}.list{background:var(--panel);border-right:1px solid var(--line);overflow-y:auto}.list header{display:flex;align-items:center;justify-content:space-between;padding:14px 16px 4px}.list .title{font-size:20px;font-weight:600}.link{background:none;border:0;color:var(--accent);cursor:pointer}.status{padding:0 16px 10px;font-size:12px;border-bottom:1px solid var(--line)}.dot{display:inline-block;width:8px;height:8px;border-radius:50%;background:var(--muted);margin-right:4px}.dot.on{background:#25d366}.row{display:block;width:100%;text-align:left;background:none;border:0;border-bottom:1px solid var(--line);padding:10px 16px;cursor:pointer;color:inherit}.row:hover,.row.selected{background:var(--selected)}.row-top{display:flex;justify-content:space-between;gap:8px}.name{font-weight:600;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.preview{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font-size:14px}.chat{display:flex;flex-direction:column;background:var(--chat-bg);min-width:0}.chat-head{background:var(--panel);padding:12px 20px;border-bottom:1px solid var(--line)}.messages{flex:1;overflow-y:auto;padding:12px 6%}.divider,.system,.gap{text-align:center;margin:10px 0}.divider span{background:var(--panel);padding:4px 10px;border-radius:8px;font-size:12px;color:var(--muted)}.system span{background:var(--system);padding:4px 10px;border-radius:8px;font-size:12px;color:var(--muted)}.gap{color:var(--gap);font-style:italic;font-size:12px}.bubble-row{display:flex;margin:2px 0}.bubble-row.mine{justify-content:flex-end}.bubble{max-width:min(560px,75%);padding:6px 10px;border-radius:8px;background:var(--theirs);box-shadow:0 1px .5px #00000021}.mine .bubble{background:var(--mine)}.bubble.grey{background:var(--grey)}.bubble.clickable{cursor:pointer}.sender{font-size:12px;font-weight:600;color:#1f7aec}.quote{background:#0000000f;border-left:3px solid var(--accent);padding:4px 8px;border-radius:4px;margin-bottom:4px;font-size:13px;color:var(--muted)}.text{white-space:pre-wrap;word-wrap:break-word}.meta{text-align:right;font-size:11px;color:var(--muted);margin-top:2px;display:flex;gap:6px;justify-content:flex-end}.modal{position:fixed;top:0;right:0;bottom:0;left:0;background:#0006;display:flex;align-items:center;justify-content:center;padding:16px}.sheet{background:var(--panel);border-radius:12px;padding:20px;width:min(440px,100%);display:flex;flex-direction:column;gap:8px}.sheet h3{margin:0}.earlier{background:var(--grey);padding:8px 10px;border-radius:8px;white-space:pre-wrap}@media (max-width: 700px){.app{grid-template-columns:1fr}.chat{display:none}}
