:root{--bg-rail: #1a1b1e;--bg-sidebar: #232428;--bg-chat: #2f3136;--bg-input: #383a40;--bg-hover: #35373c;--bg-active: #3f4248;--bg-modal: #313338;--bg-elevated: #2b2d31;--text: #dbdee1;--text-strong: #f2f3f5;--text-muted: #949ba4;--accent: #5865f2;--accent-hover: #4752c4;--danger: #ed4245;--success: #23a55a;--radius: 8px;--rail-w: 72px;--sidebar-w: 240px;--members-w: 240px;--font: "gg sans", "Segoe UI", system-ui, -apple-system, sans-serif}*{box-sizing:border-box}html,body,#root{height:100%;margin:0;overflow:hidden}body{font-family:var(--font);font-size:15px;color:var(--text);background:var(--bg-chat);-webkit-font-smoothing:antialiased}button{font:inherit;color:inherit;background:none;border:none;cursor:pointer}input,textarea{font:inherit;color:inherit}::-webkit-scrollbar{width:8px;height:8px}::-webkit-scrollbar-thumb{background:#202225;border-radius:4px}::-webkit-scrollbar-track{background:transparent}.auth-page{height:100%;min-height:0;overflow-y:auto;padding:24px 0;box-sizing:border-box;display:grid;place-items:center;background:radial-gradient(circle at 30% 20%,#404eed,#1a1b1e 55%)}.auth-card{width:420px;max-width:calc(100vw - 32px);padding:28px;background:var(--bg-modal);border-radius:var(--radius);box-shadow:0 8px 32px #00000073;box-sizing:border-box;max-height:calc(100% - 8px);overflow-y:auto}.auth-card h1{margin:0 0 6px;font-size:24px;color:var(--text-strong);text-align:center}.auth-card p.sub{margin:0 0 22px;text-align:center;color:var(--text-muted);font-size:14px}.field{margin-bottom:16px}.field label{display:block;margin-bottom:8px;font-size:12px;font-weight:700;text-transform:uppercase;letter-spacing:.02em;color:var(--text-muted)}.field input{width:100%;padding:10px 12px;background:#1e1f22;border:1px solid #1e1f22;border-radius:4px;outline:none}.field input:focus{border-color:var(--accent)}.btn-primary{width:100%;padding:11px;margin-top:4px;background:var(--accent);color:#fff;font-weight:600;border-radius:4px;transition:background .15s}.btn-primary:hover:not(:disabled){background:var(--accent-hover)}.btn-primary:disabled{opacity:.5;cursor:not-allowed}.auth-switch{margin-top:16px;font-size:14px;text-align:center;color:var(--text-muted)}.auth-switch button{color:#00a8fc}.auth-switch button:hover{text-decoration:underline}.auth-exit{margin-top:20px;padding-top:14px;border-top:1px solid rgb(255 255 255 / 6%);display:flex;flex-direction:column;align-items:center;gap:4px}.auth-exit button{padding:6px 14px;font-size:13px;color:var(--text-muted);border:1px solid rgb(255 255 255 / 10%);border-radius:4px}.auth-exit button:hover{color:var(--text-strong);border-color:#ffffff38;background:var(--bg-hover)}.auth-exit-hint{font-size:11px;color:var(--text-muted);opacity:.75}.form-error{margin-bottom:12px;padding:10px;font-size:13px;color:#fff;background:#ed424533;border:1px solid rgb(237 66 69 / 40%);border-radius:4px}.shell{display:flex;height:100%;overflow:hidden}.titlebar{height:34px;flex:0 0 34px;display:flex;align-items:center;justify-content:space-between;padding:0 6px 0 12px;background:#16171a;border-bottom:1px solid #000;-webkit-app-region:drag;-webkit-user-select:none;user-select:none}.titlebar-brand{display:flex;align-items:center;gap:8px;font-size:12px;font-weight:600;letter-spacing:.02em;color:#949ba4}.titlebar-logo{width:18px;height:18px;display:grid;place-items:center;border-radius:5px;background:var(--accent);color:#fff;font-size:11px;font-weight:700}.titlebar-actions{display:flex;gap:2px;-webkit-app-region:no-drag}.titlebar-btn{width:34px;height:26px;display:grid;place-items:center;border-radius:4px;color:#949ba4}.titlebar-btn:hover{background:#2b2d31;color:#f2f3f5}.titlebar-btn.close:hover,.titlebar-btn.close:focus-visible{background:#ed4245;color:#fff}.titlebar-exit{flex:1 0 auto;min-width:34px;min-height:26px;align-self:stretch}.titlebar-user{color:var(--text-muted);font-weight:400;max-width:260px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.titlebar-menu{position:relative}.app-menu{position:absolute;top:calc(100% + 6px);right:0;min-width:210px;padding:6px;background:#111214;border:1px solid #2b2d31;border-radius:6px;box-shadow:0 8px 24px #0000008c;z-index:100;-webkit-app-region:no-drag}.app-menu button{display:flex;align-items:baseline;justify-content:space-between;gap:12px;width:100%;padding:8px 10px;border-radius:4px;font-size:13px;color:var(--text);text-align:left}.app-menu button:hover{background:var(--accent);color:#fff}.app-menu button.danger{color:#ed4245}.app-menu button.danger:hover{background:#ed4245;color:#fff}.app-menu-hint{font-size:11px;color:var(--text-muted);white-space:nowrap}.app-menu button:hover .app-menu-hint{color:#ffffffbf}.app-menu-sep{height:1px;margin:4px 6px;background:#2b2d31}body{display:flex;flex-direction:column}#root{flex:1;min-height:0;display:flex;flex-direction:column}#root>.shell{flex:1;min-height:0}.rail{width:var(--rail-w);flex:0 0 var(--rail-w);display:flex;flex-direction:column;align-items:center;gap:8px;padding:12px 0;background:var(--bg-rail);overflow-y:auto}.rail-item{position:relative;width:48px;height:48px;display:grid;place-items:center;border-radius:16px;background:var(--bg-sidebar);color:var(--text-strong);font-weight:600;font-size:15px;transition:border-radius .15s,background .15s}.rail-item:hover,.rail-item.active{border-radius:50%;background:var(--accent)}.rail-item.active:before,.rail-item.unread:before{content:"";position:absolute;left:-12px;width:4px;border-radius:0 4px 4px 0;background:#fff;transition:height .15s}.rail-item.active:before{height:40px}.rail-item.unread:before{height:8px}.rail-sep{width:32px;height:2px;background:var(--bg-sidebar);border-radius:1px}.rail-add{width:48px;height:48px;display:grid;place-items:center;border-radius:50%;background:var(--bg-sidebar);color:var(--success);font-size:24px;transition:background .15s,color .15s,border-radius .15s}.rail-add:hover{background:var(--success);color:#fff;border-radius:16px}.sidebar{width:var(--sidebar-w);flex:0 0 var(--sidebar-w);display:flex;flex-direction:column;background:var(--bg-sidebar)}.sidebar-header{height:48px;flex:0 0 48px;display:flex;align-items:center;justify-content:space-between;padding:0 16px;font-weight:700;color:var(--text-strong);box-shadow:0 1px #0003}.sidebar-header .name{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.sidebar-scroll{flex:1;overflow-y:auto;padding:16px 8px}.category-header{display:flex;align-items:center;gap:4px;width:100%;padding:4px 8px;font-size:12px;font-weight:700;text-transform:uppercase;letter-spacing:.02em;color:var(--text-muted)}.category-header:hover{color:var(--text-strong)}.category-header .chevron{font-size:10px;transition:transform .15s}.category-header .chevron.collapsed{transform:rotate(-90deg)}.channel{display:flex;align-items:center;gap:6px;width:100%;padding:6px 8px;margin-bottom:2px;border-radius:4px;color:var(--text-muted);font-weight:500;text-align:left}.channel:hover{background:var(--bg-hover);color:var(--text)}.channel.active{background:var(--bg-active);color:var(--text-strong)}.channel .hash{font-size:18px;color:var(--text-muted);width:18px;text-align:center}.channel .label{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.add-channel{padding:2px 8px;color:var(--text-muted);font-size:13px}.add-channel:hover{color:var(--text-strong)}.user-panel{display:flex;align-items:center;gap:8px;padding:8px;background:#232428;border-top:1px solid rgb(0 0 0 / 20%)}.user-panel .meta{flex:1;min-width:0}.user-panel .display{font-size:14px;font-weight:600;color:var(--text-strong);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.user-panel .handle{font-size:12px;color:var(--text-muted)}.icon-btn{width:32px;height:32px;display:grid;place-items:center;border-radius:4px;color:var(--text-muted)}.icon-btn:hover{background:var(--bg-hover);color:var(--text-strong)}.icon-btn.danger:hover{color:var(--danger)}.avatar{position:relative;flex:0 0 auto;display:grid;place-items:center;border-radius:50%;color:#fff;font-weight:600;-webkit-user-select:none;user-select:none}.avatar .dot{position:absolute;right:-2px;bottom:-2px;width:12px;height:12px;border-radius:50%;background:var(--text-muted);border:2px solid var(--bg-sidebar)}.avatar .dot.online{background:var(--success)}.chat{flex:1;min-width:0;display:flex;flex-direction:column;background:var(--bg-chat)}.chat-header{height:48px;flex:0 0 48px;display:flex;align-items:center;gap:8px;padding:0 16px;box-shadow:0 1px #0003}.chat-header .hash{font-size:22px;color:var(--text-muted)}.chat-header h2{margin:0;font-size:16px;color:var(--text-strong)}.chat-header .divider{width:1px;height:24px;margin:0 8px;background:#42454a}.chat-header .topic{font-size:14px;color:var(--text-muted);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.messages{flex:1;overflow-y:auto;padding:16px 0}.messages>.message:first-of-type{margin-top:auto}.message{position:relative;display:flex;gap:16px;padding:2px 16px 2px 72px;flex:0 0 auto}.message:hover{background:#00000012}.message .avatar-slot{position:absolute;left:16px;width:40px}.message.first{margin-top:16px}.message .head{display:flex;align-items:baseline;gap:8px}.message .author{font-weight:600;color:var(--text-strong)}.message .stamp{font-size:12px;color:var(--text-muted)}.message .body{white-space:pre-wrap;overflow-wrap:anywhere;line-height:1.375}.message .body a{color:#00a8fc;text-decoration:none}.message .body a:hover{text-decoration:underline}.message .body .inline-code{padding:1px 4px;font-family:Consolas,Courier New,monospace;font-size:.9em;background:#202225;border-radius:3px}.message .body .code-block{margin:4px 0;padding:10px 12px;font-family:Consolas,Courier New,monospace;font-size:13px;background:#202225;border:1px solid #1a1b1e;border-radius:4px;overflow-x:auto;white-space:pre}.message .body .quote{display:block;padding-left:10px;margin:2px 0;border-left:3px solid #4e5058;color:var(--text-muted)}.message .edited{margin-left:4px;font-size:11px;color:var(--text-muted)}.message .reply{display:flex;align-items:center;gap:6px;margin-bottom:2px;font-size:13px;color:var(--text-muted)}.message .reply:before{content:"";width:32px;height:10px;margin-left:-32px;border-left:2px solid #4e5058;border-top:2px solid #4e5058;border-top-left-radius:6px}.message .actions{position:absolute;top:-12px;right:16px;display:none;gap:2px;padding:2px;background:var(--bg-elevated);border:1px solid #1e1f22;border-radius:4px}.message:hover .actions{display:flex}.messages .empty{padding:40px 16px;text-align:center;color:var(--text-muted)}.typing{height:20px;padding:0 16px 4px;font-size:12px;color:var(--text-muted)}.composer{padding:0 16px 24px}.composer .reply-bar{display:flex;align-items:center;justify-content:space-between;padding:6px 12px;font-size:13px;color:var(--text-muted);background:var(--bg-elevated);border-radius:8px 8px 0 0}.composer .box{display:flex;align-items:center;gap:8px;padding:0 8px 0 12px;background:var(--bg-input);border-radius:8px}.composer textarea{flex:1;max-height:200px;padding:11px 0;background:none;border:none;outline:none;resize:none}.composer textarea::placeholder{color:var(--text-muted)}.members{width:var(--members-w);flex:0 0 var(--members-w);padding:16px 8px;background:var(--bg-sidebar);overflow-y:auto}.members .group-title{padding:0 8px 8px;font-size:12px;font-weight:700;text-transform:uppercase;letter-spacing:.02em;color:var(--text-muted)}.member{display:flex;align-items:center;gap:12px;padding:6px 8px;border-radius:4px}.member:hover{background:var(--bg-hover)}.member .name{font-size:14px;font-weight:500;color:var(--text);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.member.offline{opacity:.45}.member .role{margin-left:auto;font-size:10px;font-weight:700;text-transform:uppercase;color:var(--text-muted)}.modal-backdrop{position:fixed;inset:0;display:grid;place-items:center;background:#000000b3;z-index:50}.modal{width:440px;max-width:calc(100vw - 32px);padding:24px;background:var(--bg-modal);border-radius:var(--radius);box-shadow:0 8px 32px #00000073}.modal h3{margin:0 0 8px;color:var(--text-strong)}.modal .hint{margin:0 0 16px;font-size:13px;color:var(--text-muted)}.modal .row{display:flex;gap:8px;margin-top:8px}.btn-secondary{flex:1;padding:10px;border-radius:4px;color:var(--text)}.btn-secondary:hover{background:var(--bg-hover)}.centered{height:100%;display:grid;place-items:center;color:var(--text-muted)}.btn-muninn{display:block;text-align:center;text-decoration:none}.auth-or{display:flex;align-items:center;gap:10px;margin:18px 0 12px;font-size:12px;color:var(--text-muted)}.auth-or:before,.auth-or:after{content:"";flex:1;border-top:1px solid rgb(255 255 255 / 10%)}a.profile-link{color:inherit;text-decoration:none}a.profile-link:hover .name,a.profile-link.author:hover,.user-panel .display a.profile-link:hover{text-decoration:underline}a.profile-link:focus-visible{outline:2px solid var(--accent);outline-offset:2px;border-radius:4px}.avatar.emoji{font-weight:400;line-height:1}.invite{display:flex;align-items:center;gap:8px;margin:8px 8px 0;padding:8px 10px;font-size:12px;background:var(--bg-elevated);border-radius:6px}.invite-label{color:var(--text-muted);white-space:nowrap}.invite-code{font-family:ui-monospace,Cascadia Mono,Consolas,monospace;font-size:13px;font-weight:600;letter-spacing:.06em;color:var(--text-strong)}.invite-code:hover{color:#00a8fc}.invite-actions{margin-left:auto;color:var(--success);white-space:nowrap}.invite-reset{font-size:12px;color:var(--text-muted)}.invite-reset:hover{color:var(--text-strong);text-decoration:underline}
