:root{--bg-primary: #36393f;--bg-secondary: #2f3136;--bg-tertiary: #202225;--bg-chat: #36393f;--bg-modifier: #40444b;--text-primary: #dcddde;--text-secondary: #b9bbbe;--text-muted: #72767d;--text-link: #00b0f4;--brand: #5865f2;--brand-hover: #4752c4;--success: #3ba55d;--danger: #ed4245;--warning: #faa81a;--border: #202225;--scrollbar-bg: #2e3338;--scrollbar-thumb: #202225;--bubble-me: #5865f2;--bubble-other: #40444b}*{margin:0;padding:0;box-sizing:border-box;-webkit-tap-highlight-color:transparent}html{font-size:16px;-webkit-text-size-adjust:100%}body{font-family:Segoe UI,Tahoma,Geneva,Verdana,sans-serif;background:var(--bg-tertiary);color:var(--text-primary);overflow:hidden;touch-action:manipulation;-webkit-overflow-scrolling:touch}#root{height:100vh;height:100dvh;width:100vw;overflow:hidden;position:fixed;top:0;left:0}::-webkit-scrollbar{width:12px}::-webkit-scrollbar-track{background:var(--scrollbar-bg)}::-webkit-scrollbar-thumb{background:var(--scrollbar-thumb);border-radius:6px;border:3px solid var(--scrollbar-bg)}::-webkit-scrollbar-thumb:hover{background:#18191c}.appShell{display:flex;height:100vh;background:var(--bg-tertiary)}.serverBar{width:72px;background:var(--bg-tertiary);display:flex;flex-direction:column;align-items:center;padding:12px 0;gap:8px;border-right:1px solid var(--border)}.serverDot{width:48px;height:48px;border-radius:50%;background:var(--bg-primary);display:flex;align-items:center;justify-content:center;cursor:pointer;transition:all .2s ease;color:var(--text-secondary);position:relative;overflow:hidden}.serverDot:before{content:"";position:absolute;left:-3px;top:50%;transform:translateY(-50%);width:0;height:8px;background:var(--text-primary);border-radius:0 4px 4px 0;transition:all .2s ease}.serverDot:hover{border-radius:16px;background:var(--brand);color:#fff}.serverDot:hover:before{width:4px;height:20px}.serverDot.active{border-radius:16px;background:var(--brand);color:#fff}.serverDot.active:before{width:4px;height:40px}.serverDot.add{background:transparent;border:2px dashed var(--text-muted);color:var(--success)}.serverDot.add:hover{border-color:var(--success);background:var(--success);color:#fff}.backdrop{display:none;position:fixed;inset:0;background:#000000d9;z-index:999;animation:fadeIn .2s ease}@media(max-width:768px){.backdrop{display:block}}@keyframes fadeIn{0%{opacity:0}to{opacity:1}}.sidebar{width:240px;background:var(--bg-secondary);display:flex;flex-direction:column;transition:transform .3s ease;border-right:1px solid var(--border)}@media(max-width:768px){.sidebar{position:fixed;left:72px;top:0;bottom:0;z-index:1000;transform:translate(-100%);box-shadow:4px 0 12px #0006}.sidebar.open{transform:translate(0)}}.sidebarHeader{padding:16px;font-weight:700;font-size:16px;border-bottom:1px solid var(--border);box-shadow:0 1px #04040533,0 1.5px #0606070d,0 2px #0404050d;display:flex;align-items:center;color:var(--text-primary);gap:8px}.sidebarHeader .adminLink{margin-left:auto;color:var(--text-muted);display:flex;align-items:center;justify-content:center;padding:6px;border-radius:6px;transition:all .15s ease}.sidebarHeader .adminLink:hover{color:var(--brand);background:var(--bg-modifier)}.sidebarScroll{flex:1;overflow-y:auto;padding:8px}.sectionLabel{font-size:12px;font-weight:600;color:var(--text-muted);padding:16px 8px 4px;text-transform:uppercase;letter-spacing:.5px}.userItem{display:flex;align-items:center;padding:8px;margin:2px 0;border-radius:4px;cursor:pointer;transition:all .15s ease;gap:12px}.userItem:hover,.userItem.active{background:var(--bg-modifier)}.channelItem{gap:8px}.channelIcon{color:var(--text-muted);display:flex;align-items:center;transition:color .15s ease}.userItem:hover .channelIcon,.userItem.active .channelIcon{color:var(--text-primary)}.avatar{width:32px;height:32px;border-radius:50%;background:var(--brand);display:flex;align-items:center;justify-content:center;font-size:12px;font-weight:600;color:#fff;flex-shrink:0;position:relative}.avatar.small{width:24px;height:24px;font-size:10px}.statusDot{position:absolute;bottom:-2px;right:-2px;width:12px;height:12px;border-radius:50%;border:3px solid var(--bg-secondary);transition:background .2s ease}.statusDot.online{background:var(--success);box-shadow:0 0 8px #3ba55d80}.statusDot.offline{background:var(--text-muted)}.userMeta{flex:1;min-width:0}.userName{font-size:14px;font-weight:500;color:var(--text-primary);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.userStatus{font-size:12px;color:var(--text-muted);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.voicePanel{background:var(--bg-tertiary);padding:12px;border-top:1px solid var(--border)}.voiceHeader{display:flex;align-items:center;color:var(--text-primary);font-size:13px;font-weight:600;margin-bottom:8px}.voiceStatus{display:flex;align-items:center;font-size:12px;margin-bottom:12px;padding:8px;background:var(--bg-secondary);border-radius:4px}.voiceControls{display:flex;gap:8px;justify-content:center}.voiceBtn{width:40px;height:40px;border-radius:50%;border:none;background:var(--bg-modifier);color:var(--text-primary);cursor:pointer;display:flex;align-items:center;justify-content:center;transition:all .15s ease}.voiceBtn:hover{background:var(--bg-primary);color:#fff}.voiceBtn:active{transform:scale(.95)}.main{flex:1;display:flex;flex-direction:column;background:var(--bg-chat);min-width:0}.topbar{height:48px;border-bottom:1px solid var(--border);display:flex;align-items:center;padding:0 16px;gap:12px;box-shadow:0 1px #04040533,0 1.5px #0606070d,0 2px #0404050d}.menuBtn{display:none;width:36px;height:36px;border-radius:4px;border:none;background:transparent;color:var(--text-muted);cursor:pointer;transition:all .15s ease;padding:0;align-items:center;justify-content:center}.menuBtn:hover{background:var(--bg-modifier);color:var(--text-primary)}@media(max-width:768px){.menuBtn{display:flex}}.channelInfo{display:flex;align-items:center;gap:8px;color:var(--text-primary)}.channelTitle{font-weight:600;font-size:16px}.chatArea{flex:1;overflow-y:auto;padding:16px;display:flex;flex-direction:column;gap:8px}.systemMsg{display:flex;align-items:center;gap:12px;margin:16px 0;color:var(--text-muted);font-size:12px}.systemLine{flex:1;height:1px;background:var(--border)}.systemText{padding:4px 8px;background:var(--bg-secondary);border-radius:4px}.chatRow{display:flex;padding:4px 0;animation:messageSlide .2s ease;width:100%}@keyframes messageSlide{0%{opacity:0;transform:translateY(8px)}to{opacity:1;transform:translateY(0)}}.chatRow.me{flex-direction:row-reverse;justify-content:flex-start;margin-left:auto;margin-right:0}.chatRow.other{flex-direction:row;justify-content:flex-start;margin-right:auto;margin-left:0}.chatAvatar{width:40px;height:40px;border-radius:50%;background:var(--brand);display:flex;align-items:center;justify-content:center;font-size:14px;font-weight:600;color:#fff;flex-shrink:0;cursor:pointer;transition:all .15s ease;margin:0 8px}.chatAvatar:hover{transform:scale(1.05);box-shadow:0 4px 8px #0000004d}.myAvatar{background:var(--success)}.chatContent{display:flex;flex-direction:column;gap:4px;max-width:65%;min-width:0}.chatRow.me .chatContent{align-items:flex-end}.chatRow.other .chatContent{align-items:flex-start}.chatMeta{display:flex;align-items:center;gap:8px;padding:0 4px}.chatName{font-size:14px;font-weight:600;color:var(--text-primary)}.msgTime{font-size:11px;color:var(--text-muted)}.myTime{text-align:right;margin-top:2px}.chatBubble{padding:10px 14px;border-radius:16px;word-wrap:break-word;position:relative;animation:bubblePop .2s ease}@keyframes bubblePop{0%{transform:scale(.9);opacity:0}to{transform:scale(1);opacity:1}}.myBubble{background:var(--bubble-me);color:#fff;border-bottom-right-radius:4px}.otherBubble{background:var(--bubble-other);color:var(--text-primary);border-bottom-left-radius:4px}.chatText{font-size:15px;line-height:1.5;white-space:pre-wrap}.reactionsDisplay{display:flex;gap:4px;flex-wrap:wrap;padding:4px 0}.reactionBubble{display:flex;align-items:center;gap:4px;padding:4px 8px;background:var(--bg-modifier);border:1px solid transparent;border-radius:12px;font-size:13px;cursor:pointer;transition:all .15s ease}.reactionBubble:hover{background:var(--bg-primary);border-color:var(--brand);transform:scale(1.05)}.reactionBubble.myReaction{background:#5865f226;border-color:var(--brand)}.reactionEmoji{font-size:14px}.reactionCount{font-size:12px;font-weight:600;color:var(--text-secondary)}.addReaction{display:none;gap:4px;padding:4px 0;animation:slideDown .2s ease}@keyframes slideDown{0%{opacity:0;transform:translateY(-4px)}to{opacity:1;transform:translateY(0)}}.chatRow:hover .addReaction{display:flex}.quickReact{width:28px;height:28px;border-radius:50%;border:none;background:var(--bg-modifier);cursor:pointer;display:flex;align-items:center;justify-content:center;transition:all .15s ease;font-size:14px}.quickReact:hover{background:var(--bg-primary);transform:scale(1.1)}.chatComposer{padding:16px;background:var(--bg-chat)}.emojiBar{display:flex;gap:6px;margin-bottom:8px;padding:8px;background:var(--bg-secondary);border-radius:8px;overflow-x:auto}.emojiBar::-webkit-scrollbar{height:6px}.emojiBtn{background:transparent;border:1px solid var(--border);border-radius:8px;padding:6px 10px;cursor:pointer;font-size:18px;transition:all .15s ease;flex-shrink:0}.emojiBtn:hover{background:var(--bg-modifier);border-color:var(--brand);transform:scale(1.1)}.emojiBtn:active{transform:scale(.95)}.composerBox{display:flex;align-items:center;gap:8px;background:var(--bg-modifier);border-radius:8px;padding:8px 12px}.attachBtn{width:36px;height:36px;border-radius:50%;border:none;background:transparent;color:var(--text-muted);cursor:pointer;display:flex;align-items:center;justify-content:center;transition:all .15s ease;flex-shrink:0}.attachBtn:hover{color:var(--text-primary);background:var(--bg-primary)}.composerInput{flex:1;background:transparent;border:none;outline:none;color:var(--text-primary);font-size:15px;padding:8px}.composerInput::-moz-placeholder{color:var(--text-muted)}.composerInput::placeholder{color:var(--text-muted)}.sendBtn{width:36px;height:36px;border-radius:50%;border:none;background:var(--brand);color:#fff;cursor:pointer;display:flex;align-items:center;justify-content:center;transition:all .15s ease;flex-shrink:0}.sendBtn:hover:not(:disabled){background:var(--brand-hover);transform:scale(1.05)}.sendBtn:active:not(:disabled){transform:scale(.95)}.sendBtn:disabled{background:var(--bg-primary);color:var(--text-muted);cursor:not-allowed;opacity:.5}.typingLine{display:flex;align-items:center;gap:8px;margin-top:8px;padding:0 4px;font-size:13px;color:var(--text-muted);min-height:20px}.typingDots{display:flex;gap:3px;align-items:center}.typingDots span{width:6px;height:6px;border-radius:50%;background:var(--text-muted);animation:typing 1.4s infinite ease-in-out}.typingDots span:nth-child(1){animation-delay:0s}.typingDots span:nth-child(2){animation-delay:.2s}.typingDots span:nth-child(3){animation-delay:.4s}@keyframes typing{0%,60%,to{transform:translateY(0);opacity:.5}30%{transform:translateY(-8px);opacity:1}}@media(max-width:768px){.chatContent{max-width:75%}.emojiBar{overflow-x:scroll}}@media(max-width:480px){.chatContent{max-width:80%}.chatBubble{padding:8px 12px}.chatText{font-size:14px}}@media(max-width:768px){.appShell{flex-direction:column}.serverBar{display:none}.main{width:100%;height:100vh;display:flex;flex-direction:column;position:relative}.topbar{position:fixed;top:0;left:0;right:0;z-index:100;height:50px;padding:0 12px;background:var(--bg-chat);backdrop-filter:blur(8px);-webkit-backdrop-filter:blur(8px)}.chatArea{flex:1;overflow-y:auto;padding:64px 12px 80px;gap:6px}.chatRow{padding:2px 0}.chatAvatar{width:32px;height:32px;font-size:11px;margin:0 4px}.chatContent{max-width:75%}.chatBubble{padding:8px 12px;border-radius:14px}.chatText{font-size:14px;line-height:1.4}.chatName{font-size:12px}.msgTime{font-size:10px}.chatComposer{position:fixed;bottom:0;left:0;right:0;padding:10px;background:var(--bg-chat);backdrop-filter:blur(8px);-webkit-backdrop-filter:blur(8px);border-top:1px solid var(--border);z-index:100}.emojiBar{padding:6px;gap:4px;margin-bottom:6px}.emojiBtn{padding:4px 8px;font-size:16px}.composerBox{padding:6px 10px;border-radius:20px}.composerInput{font-size:15px;padding:6px}.sendBtn,.attachBtn,.voiceRecordBtn{width:40px;height:40px;min-width:40px}.menuBtn{display:flex!important;width:40px;height:40px}.channelInfo{flex:1;min-width:0}.channelTitle{font-size:15px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.currentUserBadge{flex-shrink:0}.sidebar{position:fixed!important;left:0!important;top:0!important;bottom:0!important;width:85%!important;max-width:320px;z-index:1001;transform:translate(-100%);box-shadow:4px 0 20px #00000080}.sidebar.open{transform:translate(0)!important}.sidebarHeader{padding:14px 16px;font-size:15px}.sidebarScroll{padding:4px}.userItem{padding:10px 8px;border-radius:6px}.sectionLabel{padding:12px 8px 4px;font-size:11px}.voicePanel{padding:10px;background:var(--bg-tertiary)}.voiceHeader{font-size:12px;margin-bottom:6px}.voiceStatus{padding:6px 8px;margin-bottom:10px;font-size:11px}.voiceControls{gap:12px}.voiceBtn{width:48px;height:48px}.volumeControls{padding:8px 0}.reactionBubble{padding:6px 10px;font-size:14px;min-height:36px;min-width:36px}.quickReact{width:36px;height:36px;font-size:16px}.recordingBar{padding:12px;border-radius:20px}.cancelRecordBtn,.sendRecordBtn{width:48px;height:48px;font-size:20px}.recordingTime{font-size:16px}.recordingDot{width:12px;height:12px}.backdrop{display:block!important;background:#000000b3}.typingLine{font-size:12px;padding:0 2px}.voiceMessage{min-width:120px}.voicePlayBtn{width:36px;height:36px;font-size:14px}.voiceDuration{font-size:11px}.modalOverlay{padding:16px}.modal{width:100%;max-width:none;margin:0}.modalHeader{padding:16px}.modalTitle{font-size:18px}.modalBody{padding:16px}.input{padding:14px 12px;font-size:16px}.createButton{padding:14px;font-size:15px}.emojiGrid{grid-template-columns:repeat(5,1fr);gap:6px}.emojiOption{padding:10px;font-size:20px}}@media(max-width:480px){.chatArea{padding:58px 8px 70px}.chatAvatar{width:28px;height:28px;font-size:10px;margin:0 3px}.chatContent{max-width:80%}.chatBubble{padding:7px 10px;border-radius:12px}.chatText{font-size:13px}.chatName{font-size:11px}.msgTime{font-size:9px}.composerBox{padding:5px 8px;border-radius:18px}.composerInput{font-size:14px;padding:5px}.sendBtn,.attachBtn,.voiceRecordBtn{width:36px;height:36px;min-width:36px}.emojiBar{padding:4px;gap:2px}.emojiBtn{padding:3px 6px;font-size:14px}.voiceBtn{width:44px;height:44px}.quickReact{width:32px;height:32px;font-size:14px}.reactionBubble{padding:5px 8px;font-size:13px}.cancelRecordBtn,.sendRecordBtn{width:44px;height:44px}}@media(hover:none)and (pointer:coarse){.userItem:hover,.emojiBtn:hover,.voiceBtn:hover,.sendBtn:hover:not(:disabled),.attachBtn:hover,.quickReact:hover,.reactionBubble:hover{background:inherit;border-color:inherit;transform:none}.userItem:active,.emojiBtn:active,.voiceBtn:active,.sendBtn:active:not(:disabled),.attachBtn:active,.quickReact:active,.reactionBubble:active,.chatRow:active .addReaction{opacity:.7}.addReaction{display:flex!important;opacity:.6}.chatRow:hover .addReaction{opacity:.6}.serverDot:hover{border-radius:16px;background:var(--brand);color:#fff}.menuBtn:hover{background:var(--bg-modifier);color:var(--text-primary)}}@media(max-height:500px)and (orientation:landscape){.appShell{flex-direction:row}.main{height:100%}.chatArea{padding:8px 12px}.sidebar{position:relative!important;transform:none!important;width:200px!important;left:0!important}.backdrop{display:none!important}.voicePanel{padding:6px}.voiceControls{flex-direction:row}.volumeControls{display:none}}@supports (padding: env(safe-area-inset-bottom)){.chatComposer{padding-bottom:calc(10px + env(safe-area-inset-bottom))}.voicePanel{padding-bottom:calc(12px + env(safe-area-inset-bottom))}}@supports (-webkit-overflow-scrolling: touch){.sidebarScroll,.chatArea{-webkit-overflow-scrolling:touch}}.serverBar,.sidebarHeader,.voicePanel,.topbar,.menuBtn{-moz-user-select:none;user-select:none;-webkit-user-select:none}.appShell{overscroll-behavior:none;-webkit-overflow-scrolling:touch}audio{playsinline:true;-webkit-playsinline:true}.voiceRecordBtn{width:36px;height:36px;border-radius:50%;border:none;background:var(--bg-primary);color:var(--text-muted);cursor:pointer;display:flex;align-items:center;justify-content:center;transition:all .15s ease;flex-shrink:0;font-size:18px}.voiceRecordBtn:hover{background:var(--bg-modifier);color:var(--text-primary)}.voiceRecordBtn:active{transform:scale(.95);background:var(--brand);color:#fff}.recordingBar{display:flex;align-items:center;gap:12px;padding:12px 16px;background:var(--bg-modifier);border-radius:8px}.cancelRecordBtn{width:40px;height:40px;border-radius:50%;border:none;background:var(--danger);color:#fff;cursor:pointer;display:flex;align-items:center;justify-content:center;transition:all .15s ease;font-size:16px}.cancelRecordBtn:active{transform:scale(.95)}.recordingInfo{flex:1;display:flex;align-items:center;justify-content:center}.recordingIndicator{display:flex;align-items:center;gap:8px}.recordingDot{width:10px;height:10px;border-radius:50%;background:var(--danger);animation:pulse 1s infinite}@keyframes pulse{0%,to{opacity:1}50%{opacity:.4}}.recordingTime{font-size:14px;color:var(--text-primary);font-weight:600;font-variant-numeric:tabular-nums}.sendRecordBtn{width:40px;height:40px;border-radius:50%;border:none;background:var(--brand);color:#fff;cursor:pointer;display:flex;align-items:center;justify-content:center;transition:all .15s ease;font-size:16px}.sendRecordBtn:active{transform:scale(.95)}.voiceMessage{display:flex;align-items:center;gap:8px;min-width:80px}.voicePlayBtn{width:32px;height:32px;border-radius:50%;border:none;background:var(--brand);color:#fff;cursor:pointer;display:flex;align-items:center;justify-content:center;transition:all .15s ease;font-size:12px;flex-shrink:0}.voicePlayBtn:active{transform:scale(.95)}.voiceWaveform{flex:1;display:flex;flex-direction:column;gap:4px}.voiceDuration{font-size:10px;color:var(--text-muted)}.waveformBars{display:flex;align-items:center;gap:2px;height:20px}.waveBar{width:3px;background:currentColor;border-radius:1px;opacity:.5}@media(max-width:768px){.voiceRecordBtn{width:40px;height:40px;font-size:20px}.recordingBar{padding:14px;border-radius:24px}.cancelRecordBtn,.sendRecordBtn{width:48px;height:48px;font-size:18px}.recordingTime{font-size:16px}.recordingDot{width:12px;height:12px}}
