body.chat-active{min-height:100dvh;display:flex;flex-direction:column}body.chat-active:not(.game-active) main{display:block;flex:1 0 auto;min-height:0;min-width:0;width:100%;max-width:1000px;margin:0 auto;padding:20px 24px;box-sizing:border-box;height:auto}body.chat-active footer{margin-top:auto}
body.chat-active #server-chats{max-width:1200px;width:100%;margin:0 auto;padding:0;box-sizing:border-box;font-family:Montserrat,sans-serif}
#server-chats .dialog-layout{margin:0;display:grid;grid-template-columns:minmax(0,1fr) 270px;gap:20px;height:clamp(360px,calc(100dvh - 240px),620px);padding:16px;border-radius:24px;background:#fff;box-shadow:0 4px 22px #7c65c51c;box-sizing:border-box}
#server-chats .dialog-content{display:flex;flex-direction:column;min-width:0;min-height:0;gap:12px}#server-chats .dialog-paper{flex:1;display:flex;flex-direction:column;min-height:0;margin:0;padding:14px 16px;border-radius:18px;box-shadow:0 3px 20px #7c65c51c;background:#fff}#server-chats .dialog-placeholder{align-items:center;justify-content:center}#server-chats .dialog-placeholder p{font-size:12px;color:#86828e;background:#f4f3f7;border-radius:12px;padding:12px 20px;text-align:center}
#server-chats .dialog-sidebar{min-width:0;min-height:0;display:flex;flex-direction:column;padding:0;border:0;background:none}#server-chats .chat-tabs{display:flex;gap:6px;margin-bottom:12px}#server-chats .chat-tab{border:0;background:transparent;color:#aaa6b3;flex:1;min-width:0;padding:10px 6px;border-radius:12px;font:600 12px Montserrat,sans-serif;cursor:pointer}#server-chats .chat-tab.selected{color:#25202e;background:transparent;border-bottom:2px solid #68aaf2;border-radius:0}#server-chats .dialog-contacts{display:block;overflow-y:auto;min-height:0;flex:1;padding:4px 8px 4px 2px;scrollbar-width:thin;scrollbar-color:#cbc8d3 transparent}
#server-chats .chat-contact-row{display:flex;min-height:60px;height:auto;box-sizing:border-box;align-items:center;position:relative;gap:2px;padding:8px;margin-bottom:10px;border-radius:16px;background:#fff;box-shadow:0 3px 13px #7c65c526;border:1px solid transparent}#server-chats .chat-contact-row.selected{background:#f5f6ff;border-color:#dce3ff}#server-chats .dialog-contact{display:flex;align-items:center;gap:10px;background:none;border:0;box-shadow:none;flex:1;min-width:0;width:auto;padding:0;text-align:left;color:#24202d;cursor:pointer}#server-chats .dialog-contact img{width:42px;height:42px;border-radius:50%;object-fit:cover;flex-shrink:0}#server-chats .chat-contact-info{display:flex;flex-direction:column;gap:5px;min-width:0}#server-chats .chat-contact-info b{font-size:12px;font-weight:600;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}#server-chats .chat-contact-info small{font-size:10px;color:#96919d}#server-chats .chat-unread{padding:4px;border-radius:7px;background:#e1ebff;font-size:11px;color:#5888c2}#server-chats .dialog-empty{font-size:12px;line-height:1.7;color:#96919d;padding:8px}
#server-chats button.chat-icon,#server-chats .chat-plus,#server-chats .chat-menu-close,#server-chats .chat-message-options{display:inline-flex;align-items:center;justify-content:center;border:0;background:transparent;box-shadow:none;padding:6px;min-height:28px;width:28px;flex-shrink:0;border-radius:9px;cursor:pointer}#server-chats .chat-icon img,#server-chats .chat-plus img,#server-chats .chat-menu-close img,#server-chats .chat-message-options img{width:16px;height:16px;opacity:.55}#server-chats .dialog-heading{display:flex;align-items:center;justify-content:space-between;position:relative;border:0;margin:0 0 10px;padding:0 0 8px;gap:8px}#server-chats .chat-person{display:flex;align-items:center;gap:10px;background:none;border:0;padding:0;color:#282330;font-size:12px;cursor:pointer}#server-chats .chat-person img{width:34px;height:34px;border-radius:10px;object-fit:cover}#server-chats .server-chat-notice{font-size:11px;color:#9b6676;margin:0 0 6px;line-height:1.4}#server-chats .server-chat-notice:empty{display:none}
#server-chats .dialog-messages{flex:1;min-height:0;overflow-y:auto;padding:8px 3px;display:flex;flex-direction:column;gap:14px;scrollbar-width:thin;scrollbar-color:#cbc8d3 transparent}#server-chats .chat-message-row{display:flex;align-items:flex-start;gap:8px;max-width:86%;align-self:flex-start}#server-chats .chat-message-row.mine{align-self:flex-end}#server-chats .chat-message-avatar{width:28px;height:28px;object-fit:cover;border-radius:50%;flex-shrink:0;margin-top:3px}#server-chats .chat-message-wrap{position:relative;display:flex;flex-direction:column;align-items:flex-start;min-width:0;padding-right:20px}#server-chats .mine .chat-message-wrap{align-items:flex-end;padding-right:0}#server-chats .dialog-bubble{padding:10px 13px;max-width:100%;border-radius:14px 14px 14px 3px;background:#f3f2f6;box-sizing:border-box;margin:0;color:#3a3444;font-size:12px;line-height:1.6;overflow-wrap:anywhere}#server-chats .dialog-bubble.mine{background:#43a3d7;color:#fff;border-radius:14px 14px 3px 14px}#server-chats .dialog-bubble p{margin:0;font-size:12px}#server-chats .dialog-bubble.blocked{background:#fff0f1;color:#9b5360}#server-chats .chat-message-time{font-size:10px;color:#aaa5b0;margin:5px 4px 0}#server-chats .chat-message-options{position:absolute;right:-4px;top:1px;width:20px;opacity:.3}#server-chats .chat-message-options:focus,#server-chats .chat-message-options:hover{opacity:1}
#server-chats .dialog-composer{position:relative;display:flex;gap:10px;align-items:center;padding:10px 12px;border-radius:16px;background:#fff;box-shadow:0 3px 16px #7c65c526;margin:0;flex-shrink:0}#server-chats .chat-plus{width:34px;height:34px;background:#f3f2f6;border-radius:10px}#server-chats .dialog-composer input{width:100%;min-width:0;flex:1;border:0;border-radius:11px;padding:10px 12px;font:12px Montserrat,sans-serif;background:#f5f4f8;height:36px;box-sizing:border-box;margin:0;color:#332b40}#server-chats .chat-send{width:36px;height:36px;min-height:36px;border:0;border-radius:11px;background:#8dbef5;padding:8px;flex-shrink:0;cursor:pointer}#server-chats .chat-send img{width:20px;height:20px;filter:brightness(0) invert(1)}#server-chats button:disabled{opacity:.45;cursor:default}
#server-chats .chat-action-menu{position:absolute;z-index:8;right:4px;top:calc(100% - 4px);width:210px;max-width:calc(100vw - 60px);padding:26px 10px 10px;border-radius:16px;background:white;box-shadow:0 6px 26px #73628638;border:1px solid #f1edf7}#server-chats .dialog-composer .chat-action-menu{top:auto;bottom:calc(100% + 10px);left:0;right:auto}#server-chats .chat-menu-item{width:100%;display:block;text-align:left;padding:10px 9px;border:0;border-radius:8px;background:none;font:12px Montserrat,sans-serif;color:#3a3245;cursor:pointer}#server-chats .chat-menu-item:hover{background:#f4f2f8}#server-chats .chat-menu-close{position:absolute;top:3px;right:4px}#server-chats .chat-vk-requests{max-height:130px;overflow-y:auto;flex-shrink:0}#server-chats .chat-vk-request,#server-chats .chat-vk-shared{display:flex;align-items:center;gap:8px;padding:9px 12px;background:#f3f2f7;border-radius:12px;margin-top:8px;font-size:11px;line-height:1.5}#server-chats .chat-vk-request span,#server-chats .chat-vk-shared span{flex:1}#server-chats .chat-vk-request .primary{font-size:11px;padding:7px 10px;min-height:30px;background:#8dbef5;border:0;border-radius:9px;cursor:pointer;white-space:nowrap}#server-chats .chat-vk-shared a{color:#558dcb;font-size:11px}#server-chats button:focus-visible,#server-chats a:focus-visible{outline:2px solid #78a8e5;outline-offset:2px}#server-chats [hidden]{display:none!important}
@media(max-width:800px){#server-chats .dialog-layout{grid-template-columns:minmax(0,1fr) 220px;gap:12px;padding:12px}#server-chats .chat-contact-info b{font-size:11px}}
@media(max-width:600px){body.chat-active:not(.game-active) main{padding:12px}#server-chats .dialog-layout{display:flex;flex-direction:column-reverse;height:calc(100dvh - 270px);min-height:380px;padding:10px;gap:12px}#server-chats .dialog-sidebar{max-height:130px;flex-shrink:0}#server-chats .chat-tabs{margin-bottom:4px}#server-chats .dialog-contacts{display:flex;gap:8px;overflow-x:auto;overflow-y:hidden;padding:4px;flex:none}#server-chats .chat-contact-row{width:185px;min-width:185px;margin-bottom:4px;box-sizing:border-box}#server-chats .dialog-content{flex:1}#server-chats .dialog-paper{padding:10px}#server-chats .chat-vk-request{flex-wrap:wrap}#server-chats .chat-vk-request span{flex-basis:100%}#server-chats .dialog-bubble{font-size:12px}#server-chats .chat-action-menu{position:fixed;top:auto;bottom:80px;left:20px;right:auto}#server-chats .dialog-composer .chat-action-menu{position:absolute;left:0;bottom:calc(100% + 10px)}}

/* Loove moderation 0.42 */
#server-chats .chat-safety-warning{border:1px solid #e5ba75;background:#fff6e6;color:#62491f;padding:12px;border-radius:12px;margin:8px 0;max-width:360px;font-size:12px;line-height:18px}
#server-chats .chat-safety-warning p{font-size:12px;line-height:18px;margin:6px 0}
#server-chats .chat-safety-warning button{font:500 12px Montserrat,sans-serif;padding:7px 10px;margin:4px 4px 0 0;border:1px solid #d2b984;border-radius:8px;background:#fff;min-height:32px}
