*{box-sizing:border-box}body{margin:0;background:var(--bg);color:var(--text);font:14px -apple-system,BlinkMacSystemFont,'Segoe UI',Arial,sans-serif}button,input,textarea,select{font:inherit}button,a,input,textarea,select{-webkit-tap-highlight-color:transparent}button{cursor:pointer;border:0;color:inherit;background:transparent;border-radius:10px;padding:10px}button:hover{background:#ffffff09}button:disabled{opacity:.45;cursor:wait}input,textarea,select{border:1px solid transparent;outline:0;border-radius:10px;background:var(--input);color:var(--text);padding:12px;min-width:0;width:100%}input:focus,textarea:focus{border-color:var(--blue)}textarea{resize:vertical}a{color:var(--blue);text-decoration:none}svg.i{width:22px;height:22px;stroke:currentColor;stroke-width:1.7;fill:none;stroke-linecap:round;stroke-linejoin:round;flex-shrink:0;vertical-align:middle}h1,h2,h3,p{margin:0}h1{font-size:24px}h2{font-size:19px}h3{font-size:16px}small,.muted{color:var(--muted);font-size:12px}.primary{background:var(--blue);color:#fff;min-height:42px}.primary:hover{background:#2192ff}.secondary{background:#444252}.danger{color:#ec4772}.red{background:#cf305d;color:#fff}.row{display:flex;align-items:center;gap:12px}.between{justify-content:space-between}.grow{flex:1;min-width:0}.stack{display:flex;flex-direction:column;gap:12px}.full{width:100%}.center{text-align:center}.card{background:var(--card);border-radius:14px;padding:16px;margin-bottom:16px}.field{display:block;margin:14px 0}.field>span{display:block;font-size:12px;color:var(--muted);margin:0 0 7px 3px}.avatar{height:48px;width:48px;min-width:48px;border-radius:50%;display:grid;place-items:center;background:linear-gradient(140deg,#8c69e4,#5251c9);color:white;font-size:20px;overflow:hidden;object-fit:cover;position:relative;isolation:isolate;flex-shrink:0}.avatar img{display:block;width:100%;height:100%;min-width:100%;min-height:100%;object-fit:cover;object-position:center center;transform:scale(var(--avatar-zoom,1.08));transform-origin:center center}.avatar.channel-avatar{background:#1b1d24;box-shadow:inset 0 0 0 1px rgba(255,255,255,.08);padding:4px;--avatar-zoom:1}
.avatar.channel-avatar img{width:100%;height:100%;min-width:0;min-height:0;object-fit:contain;object-position:center center;transform:none;border-radius:inherit;background:transparent}
.avatar.big{width:90px;height:90px;font-size:34px;margin:18px auto}.avatar.tiny{width:32px;height:32px;min-width:32px;font-size:14px}.auth{min-height:100dvh;display:grid;place-items:center;padding:24px;background:radial-gradient(ellipse at 50% 10%,#24203d,transparent 55%),var(--bg)}.auth-box{width:min(390px,100%)}.brand{font-size:42px;letter-spacing:5px;font-weight:800;margin:8px 0}.brand-icon{width:76px;height:76px}.auth-box>p{color:var(--muted);margin:10px 0 28px}.auth-box form{display:flex;flex-direction:column;gap:12px}.error{color:#ff7295;min-height:20px}.shell{height:100dvh;display:grid;grid-template-columns:72px 330px minmax(0,1fr);overflow:hidden}.rail{background:var(--panel);border-right:1px solid var(--line);display:flex;flex-direction:column;align-items:center;padding:12px 4px;gap:10px}.rail .logo{width:40px;margin-bottom:5px}.navbtn{display:flex;flex-direction:column;align-items:center;gap:5px;font-size:10px;color:var(--muted);width:64px;padding:12px 0}.navbtn.active{color:var(--blue)}.rail .settings-nav{margin-top:auto}.sidebar{background:var(--panel);border-right:1px solid var(--line);min-height:0;display:flex;flex-direction:column}.sidehead{padding:18px 16px 10px;min-height:62px}.round-btn{padding:5px;background:var(--blue);border-radius:50%;color:#fff;display:grid;place-items:center}.round-btn .i{width:18px;height:18px}.searchbox{margin:5px 12px 12px;position:relative}.searchbox input{padding:9px 12px 9px 34px;font-size:13px}.searchbox .i{position:absolute;left:10px;top:10px;width:16px;height:16px;color:var(--muted)}.tabs{display:flex;overflow:auto;gap:16px;padding:0 16px;min-height:39px;flex-shrink:0}.tabs button{border-radius:0;padding:8px 0;color:var(--muted);white-space:nowrap;font-size:13px}.tabs button.active{color:var(--blue);border-bottom:2px solid var(--blue)}.list{overflow:auto;flex:1;min-height:0}.chat-item{width:100%;display:flex;gap:11px;padding:12px;border-radius:0;text-align:left;align-items:center;min-height:77px}.chat-item.active{background:#34313f}.chat-item .name{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font-weight:600;font-size:14px}.chat-item .preview{color:var(--muted);line-height:18px;height:36px;overflow:hidden;font-size:13px;margin-top:3px}.chat-item .preview-row{align-items:center;gap:8px}.chat-item .preview.rich-preview{height:auto;min-height:36px;display:flex;align-items:center;overflow:visible}.chat-preview-line{display:flex;align-items:center;gap:7px;min-width:0;width:100%}.chat-preview-sender-avatar{margin:0!important;width:22px!important;height:22px!important;min-width:22px!important;font-size:11px!important;flex:none}.chat-preview-sender{color:#d8dae2;font-weight:650;flex:none;white-space:nowrap}.chat-preview-text{min-width:0;flex:1;overflow:hidden;text-overflow:ellipsis;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;word-break:break-word}.chat-preview-media{position:relative;display:inline-flex;align-items:center;justify-content:center;width:24px;height:24px;min-width:24px;border-radius:8px;overflow:hidden;background:#1b1d25;border:1px solid #ffffff14;flex:none}.chat-preview-media.round{border-radius:50%}.chat-preview-media img{width:100%;height:100%;object-fit:cover;display:block}.chat-preview-play{position:absolute;right:1px;bottom:1px;display:grid;place-items:center;width:12px;height:12px;border-radius:50%;background:#000a;color:#fff;backdrop-filter:blur(3px)}.chat-preview-play .i,.chat-preview-kind .i{width:9px;height:9px}.chat-preview-kind{display:grid;place-items:center;width:20px;height:20px;min-width:20px;border-radius:50%;background:#ffffff0a;color:#b9bdc8;flex:none}.chat-preview-kind.self{background:#168cff26;color:#7cc2ff}.chat-item .time{font-size:10px;color:var(--muted);white-space:nowrap}.badge{background:var(--blue);border-radius:12px;padding:2px 6px;font-size:10px;color:white}.empty-list{padding:36px 24px;text-align:center;color:var(--muted);line-height:1.6}.empty-list button{margin-top:12px;color:var(--blue)}.stories{display:flex;gap:12px;overflow:auto;padding:4px 15px 14px}.story-thumb{padding:0;flex-shrink:0;width:52px;text-align:center}.story-thumb .avatar{border:2px solid var(--blue);padding:2px;width:48px;height:48px}.story-thumb small{display:block;margin-top:5px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:10px}.main{min-height:0;min-width:0;position:relative;display:flex;flex-direction:column;background:var(--bg)}.wallpaper{background-color:var(--bg);background-image:url('/wallpaper.svg');background-size:420px}.welcome{height:100%;display:flex;flex-direction:column;justify-content:center;align-items:center;gap:14px;text-align:center;padding:25px}.welcome img{width:78px;opacity:.7}.welcome p{color:var(--muted)}.chathead{height:64px;flex-shrink:0;background:var(--panel);border-bottom:1px solid var(--line);padding:8px 18px;display:flex;align-items:center;gap:12px}.chathead .avatar{width:40px;height:40px;min-width:40px;font-size:16px}.chathead .info{cursor:pointer;flex:1;min-width:0}.chathead .info b{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;margin-bottom:3px}.chathead .back{display:none}.chathead button{padding:8px}.messages{flex:1;min-height:0;overflow:auto;padding:18px max(24px,calc((100% - 820px)/2));display:flex;flex-direction:column;gap:7px;scroll-behavior:auto}.day{text-align:center;align-self:center;font-size:11px;padding:4px 9px;border-radius:10px;background:var(--card);color:var(--muted);margin:9px 0}.message{align-self:flex-start;max-width:78%;position:relative;display:flex;flex-direction:column;align-items:flex-start}.message.mine{align-self:flex-end;align-items:flex-end}.bubble{background:var(--incoming);border-radius:13px 13px 13px 4px;padding:8px 10px;min-width:72px;max-width:100%;overflow-wrap:anywhere;box-shadow:0 1px 1px #0002}.mine .bubble{background:var(--out);border-radius:13px 13px 4px 13px}.bubble .body{white-space:pre-wrap;font-size:var(--font);line-height:1.4}.bubble .sender{font-size:12px;color:#a8bfff;display:block;margin-bottom:5px}.bubble .meta{font-size:10px;opacity:.7;display:flex;justify-content:flex-end;gap:5px;margin:4px 0 -1px}.bubble a{color:#b5d7ff;text-decoration:underline}.bubble .attachment{display:block;max-width:360px;width:100%;max-height:420px;object-fit:contain;border-radius:8px;margin-bottom:5px}.bubble audio{max-width:270px;width:100%;height:38px}.bubble .round-video{border-radius:50%;aspect-ratio:1;width:240px;object-fit:cover}.file-link{display:flex;gap:10px;align-items:center;padding:10px 0}.reply{border-left:3px solid #ab9bff;background:#0002;border-radius:4px;padding:7px 9px;margin-bottom:6px;max-width:100%;font-size:12px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.reactions{display:flex;gap:4px;flex-wrap:wrap;margin-top:4px}.reaction{font-size:12px;padding:4px 7px;background:#ffffff18;border-radius:14px}.reaction.mine{background:#0785ff55}.composer-area{padding:8px max(20px,calc((100% - 850px)/2)) 14px;background:var(--panel);flex-shrink:0}.composer{display:flex;align-items:flex-end;gap:3px}.composer textarea{background:transparent;border:0;resize:none;max-height:160px;min-height:42px;padding:12px 8px;line-height:20px}.composer button{padding:10px 7px;color:var(--muted)}.composer .send{color:var(--blue)}.replybar{padding:8px 12px;display:flex;align-items:center;color:var(--muted);font-size:12px;border-bottom:1px solid var(--line)}.replybar span{flex:1;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.pinbar{padding:8px 18px;background:var(--panel);color:var(--muted);font-size:12px;cursor:pointer}.mobile-nav{display:none}.panehead{height:60px;display:flex;align-items:center;gap:16px;padding:10px 20px;border-bottom:1px solid var(--line);flex-shrink:0}.panehead h3{flex:1;text-align:center;margin-right:40px}.page-scroll{overflow:auto;padding:24px;flex:1;min-height:0}.page{max-width:480px;margin:0 auto}.setting-row{display:flex;gap:12px;align-items:center;width:100%;text-align:left;padding:16px 10px;border-radius:0;border-bottom:1px solid var(--line)}.setting-row .right{margin-left:auto;color:var(--muted);font-size:12px}.switch{width:38px;height:23px;background:#51505c;border-radius:20px;position:relative;flex-shrink:0}.switch:after{content:'';position:absolute;width:19px;height:19px;border-radius:50%;background:#ddd;left:2px;top:2px}.switch.on{background:var(--blue)}.switch.on:after{left:17px;background:white}.setting-row .i{width:20px}.profile-header{text-align:center;padding:10px 0 24px}.actions{display:flex;gap:8px;margin:18px 0}.actions button{flex:1;background:var(--card);color:var(--blue);font-size:11px;display:flex;flex-direction:column;align-items:center;gap:8px}.gallery{display:grid;grid-template-columns:repeat(3,1fr);gap:4px}.gallery img,.gallery video{width:100%;height:120px;object-fit:cover;cursor:pointer}.modal-shade{position:fixed;inset:0;background:#0009;backdrop-filter:blur(3px);display:flex;align-items:center;justify-content:center;padding:24px;z-index:50}.modal{width:min(440px,100%);max-height:88dvh;overflow:auto;background:var(--panel);border-radius:17px;box-shadow:0 20px 80px #0007}.modal-head{position:sticky;top:0;background:var(--panel);padding:16px 20px;display:flex;align-items:center;justify-content:space-between;z-index:1}.modal-body{padding:0 20px 22px}.menu-item{width:100%;display:flex;align-items:center;gap:14px;text-align:left;padding:14px 10px}.emoji-grid{display:grid;grid-template-columns:repeat(7,1fr);gap:4px}.emoji-grid button{font-size:26px;padding:8px 3px}.user-choice{display:flex;align-items:center;gap:10px;padding:10px 0;cursor:pointer}.user-choice input{width:18px;margin-left:auto}.modal-footer{display:flex;gap:10px;margin-top:20px}.modal-footer>*{flex:1}.poll-option{display:block;width:100%;text-align:left;background:#0002;padding:10px;margin:7px 0;border:1px solid #ffffff22}.poll-option.selected{border-color:#bcd7ff}.poll-bar{height:3px;background:#bcadff;margin-top:5px;border-radius:3px}.toast{opacity:1}#toast{position:fixed;bottom:85px;left:50%;transform:translateX(-50%);background:#41404d;color:white;border-radius:12px;max-width:90vw;padding:12px 20px;z-index:200;pointer-events:none;display:none;text-align:center;font-size:13px}.viewer{position:fixed;inset:0;background:#000e;z-index:80;display:flex;align-items:center;justify-content:center}.viewer>img,.viewer>video{max-width:90vw;max-height:88dvh;object-fit:contain}.viewer .close{position:absolute;right:20px;top:20px;background:#333a}.story-view{height:94dvh;width:min(430px,100vw);position:relative;background:#17171d;overflow:hidden;border-radius:16px;display:flex;flex-direction:column}.story-view>img,.story-view>video{width:100%;flex:1;min-height:0;object-fit:contain}.story-top{padding:12px;display:flex;align-items:center;gap:8px;position:absolute;top:0;left:0;right:0;background:linear-gradient(#000a,transparent);z-index:1}.story-bottom{padding:16px;background:linear-gradient(transparent,#0009);position:absolute;bottom:0;width:100%;display:flex;gap:10px;flex-direction:column}.story-caption{text-shadow:0 1px 5px #000}.story-nav{position:absolute;top:45%;background:#3339;z-index:2}.story-prev{left:3px}.story-next{right:3px}.call-screen{position:fixed;inset:0;background:radial-gradient(ellipse at 50% 45%,#292057 0%,#101014 52%);z-index:70;display:flex;align-items:center;justify-content:center;flex-direction:column;padding:30px}.call-screen.minimized{inset:auto 18px 20px auto;width:280px;height:210px;border-radius:20px;padding:12px;box-shadow:0 8px 50px #0009}.call-screen.minimized .call-title{font-size:16px}.call-screen.minimized .call-avatar{display:none}.call-title{font-size:24px;margin:15px}.call-avatar{width:120px;height:120px;border-radius:50%;display:grid;place-items:center;font-size:45px;background:var(--out);margin:20px}.call-controls{position:absolute;bottom:max(30px,env(safe-area-inset-bottom));display:flex;gap:12px;background:#ffffff0c;border-radius:40px;padding:6px}.call-controls button{width:48px;height:48px;border-radius:50%;background:#454251}.call-controls .red{background:#d93464}.call-controls button.off{background:white;color:#202026}.call-top{position:absolute;top:20px;left:20px;right:20px;display:flex;justify-content:space-between}.local-video{position:absolute;top:70px;right:30px;width:180px;max-height:160px;border-radius:15px;object-fit:cover}.remote-videos{display:flex;flex-wrap:wrap;gap:12px;justify-content:center;max-width:90%;max-height:65vh}.remote-videos video{max-width:100%;max-height:60vh;border-radius:16px}.call-screen.minimized .remote-videos{display:none}.call-screen.minimized .local-video{display:none}.call-screen.minimized .call-controls{bottom:12px}.color-picks{display:flex;gap:10px}.color-picks button{width:70px;height:55px;border:3px solid transparent}.color-picks button.selected{border-color:var(--blue)}.loading{padding:30px;text-align:center;color:var(--muted)}.connection{position:fixed;top:0;left:50%;transform:translateX(-50%);background:#bd7923;z-index:100;padding:6px 20px;border-radius:0 0 10px 10px;font-size:12px}.record-preview{width:220px;height:220px;object-fit:cover;border-radius:50%;display:block;margin:15px auto}.record-time{font-variant-numeric:tabular-nums;font-size:28px;text-align:center;padding:20px}.light{color-scheme:light;--bg:#f0f0f5;--panel:#fff;--card:#e6e6ee;--input:#ededf2;--text:#181824;--muted:#73737e;--line:#00000009;--incoming:#fff}.light .mine .bubble{color:#fff}.light .wallpaper{background-color:#e5e9f4}.light .chat-item.active{background:#e3e9f8}body{overscroll-behavior:none}button:focus-visible,a:focus-visible{outline:2px solid var(--blue)}::-webkit-scrollbar{width:5px;height:3px}::-webkit-scrollbar-thumb{background:#8884;border-radius:4px}
@media(min-width:1600px){.shell{grid-template-columns:72px 350px minmax(0,1fr)}}
@media(max-width:760px){.shell{grid-template-columns:1fr;grid-template-rows:minmax(0,1fr) auto}.rail{display:none}.sidebar{border:0}.main{display:none}.shell.detail .sidebar{display:none}.shell.detail .main{display:flex}.shell.detail .mobile-nav{display:none}.mobile-nav{display:flex;justify-content:space-around;align-items:center;background:var(--panel);padding:5px 0 calc(5px + env(safe-area-inset-bottom));border-top:1px solid var(--line)}.mobile-nav .navbtn{padding:7px 0;width:25%;font-size:10px}.mobile-nav .i{width:22px;height:22px}.sidehead{padding:16px 16px 8px}.sidehead h2{font-size:22px}.chat-item{padding:11px 14px;min-height:76px}.chathead{height:62px;padding:8px 8px;gap:7px}.chathead .back{display:block}.chathead .avatar{width:34px;height:34px;min-width:34px}.chathead button{padding:7px 5px}.chathead .info b{font-size:14px}.chathead .info small{font-size:11px}.messages{padding:12px 10px}.message{max-width:87%}.bubble .attachment{max-width:290px}.composer-area{padding:5px 5px calc(7px + env(safe-area-inset-bottom))}.composer button{padding:10px 6px}.composer textarea{font-size:16px}.page-scroll{padding:18px 12px}.modal-shade{padding:0;align-items:flex-end}.modal{width:100%;max-height:88dvh;border-radius:22px 22px 0 0;padding-bottom:env(safe-area-inset-bottom)}.modal:before{content:'';display:block;width:34px;height:4px;background:#666;border-radius:4px;margin:10px auto 0}.modal-head{padding-top:10px}.story-view{height:100dvh;width:100vw;border-radius:0}.viewer .close{top:10px;right:10px}.call-screen{padding:15px}.local-video{width:100px;right:15px;top:70px;max-height:140px}.call-controls{bottom:45px}.remote-videos{max-width:100%}.call-top{top:15px;left:15px;right:15px}.panehead{padding:10px}.settings-list .setting-row{padding:17px 13px}}

/* NOVO 2.0 — reference-aligned surfaces, phone auth, admin and mobile UX */
.auth-phone{position:relative;overflow:hidden;background:#0e0e12}.auth-pattern{position:absolute;inset:0;background-color:#111116;background-image:url('/wallpaper.svg');background-size:430px;opacity:.95}.auth-card{position:relative;width:min(610px,calc(100vw - 32px));min-height:620px;border-radius:30px;background:linear-gradient(180deg,#1d1d23 0,#17171c 52%,#17171c 100%);border:1px solid #ffffff10;box-shadow:0 26px 90px #0008;display:flex;flex-direction:column;overflow:hidden}.auth-card:before{content:'';position:absolute;inset:0 0 auto;height:140px;background:radial-gradient(ellipse at 50% 0,#283c8b88,transparent 68%),radial-gradient(ellipse at 20% 0,#0ea5b955,transparent 55%);pointer-events:none}.auth-top{height:74px;padding:21px 26px;display:flex;justify-content:space-between;position:relative;z-index:1}.auth-top button,.auth-back{width:38px;height:38px;display:grid;place-items:center;border-radius:50%;font-size:20px}.auth-stage{position:relative;z-index:1;flex:1;display:flex;flex-direction:column;align-items:center;text-align:center;padding:42px 80px 54px}.auth-stage .brand-icon{width:58px;height:58px}.auth-stage .brand{font-size:32px;letter-spacing:1px;margin:14px 0 36px}.auth-stage h2{font-size:21px;line-height:1.22;margin:0 0 10px}.auth-stage>p{max-width:390px;line-height:1.4;margin-bottom:22px}.auth-stage form{width:100%;max-width:370px}.phone-field{height:54px;background:#2b2b32;border-radius:14px;display:flex;align-items:center;padding:0 14px;border:1px solid transparent;transition:.2s}.phone-field:focus-within{border-color:#2789ff}.phone-field .country{white-space:nowrap;padding-right:12px;border-right:1px solid #ffffff12}.phone-field input{background:transparent;border:0!important;padding:0 0 0 12px;height:100%;font-size:16px}.auth-main{height:54px;margin-top:6px;font-weight:700}.auth-back{position:absolute;left:18px;top:-28px}.dev-code{width:100%;max-width:370px;padding:13px 15px;border:1px solid #2d77ff66;background:#0e67ff18;border-radius:14px;display:grid;gap:3px;margin:4px 0 18px}.dev-code strong{font-size:28px;letter-spacing:8px;color:#fff}.dev-code span,.dev-code small{font-size:11px;color:var(--muted)}.otp-row{display:flex;gap:9px;justify-content:center;margin:4px 0 8px}.otp-row .otp{width:50px;height:58px;padding:0;text-align:center;font-size:24px;font-weight:700;border-radius:13px}.otp-timer{font-size:12px;margin:10px 0 4px!important}.link-btn{color:var(--blue)}.auth-name{margin:4px 0 14px;width:100%;max-width:370px}.net-state{position:fixed;z-index:5000;top:max(10px,env(safe-area-inset-top));left:50%;transform:translateX(-50%);background:#34343d;color:#fff;padding:9px 15px;border-radius:18px;box-shadow:0 8px 30px #0007;font-size:12px;font-weight:600;animation:netin .2s ease}.net-state.bad{background:#a72942}.net-state.wait{background:#7b5a21}.net-state.ok{background:#247648}@keyframes netin{from{opacity:0;transform:translate(-50%,-10px)}to{opacity:1;transform:translate(-50%,0)}}
.admin-shell{width:min(1180px,100%);margin:0 auto;display:grid;grid-template-columns:200px minmax(0,1fr);gap:18px}.admin-tabs{display:flex;flex-direction:column;gap:4px;position:sticky;top:0;align-self:start}.admin-tabs button{text-align:left;padding:12px 14px;color:var(--muted)}.admin-tabs button.active{background:var(--card);color:#fff}.admin-body{min-width:0;display:flex;flex-direction:column;gap:12px}.admin-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px}.metric{background:var(--card);border:1px solid var(--line);border-radius:16px;padding:18px;display:flex;flex-direction:column;gap:6px}.metric strong{font-size:27px}.metric span{color:var(--muted);font-size:12px}.admin-toolbar{display:flex;gap:12px;align-items:center;background:var(--card);padding:10px;border-radius:14px}.admin-row{display:flex;align-items:center;gap:10px;background:var(--card);border:1px solid var(--line);border-radius:14px;padding:13px 15px}.admin-row pre{white-space:pre-wrap;color:var(--muted);font-size:11px;max-width:900px}.status-pill{background:#ffffff0d;border-radius:999px;padding:4px 9px;color:var(--muted);font-size:11px}.support-ticket{width:100%;text-align:left;margin-bottom:10px}.support-thread{display:flex;flex-direction:column;gap:10px;max-height:55vh;overflow:auto;margin-bottom:14px}.support-msg{align-self:flex-start;background:var(--card);border-radius:14px;padding:10px 12px;max-width:85%}.support-msg.admin{align-self:flex-end;background:#15427a}.support-msg p{white-space:pre-wrap;margin:5px 0}.sticker-admin-grid{display:grid;grid-template-columns:repeat(auto-fill,72px);gap:8px;margin:14px 0}.sticker-admin-grid>div{position:relative;background:#111117;border-radius:14px;padding:6px}.sticker-admin-grid img{width:60px;height:60px;object-fit:contain}.sticker-admin-grid button{position:absolute;right:-6px;top:-6px;padding:4px;border-radius:50%}.check-row{display:flex;gap:10px;align-items:center;padding:10px}.check-row input{width:auto}.skeleton-card{height:90px;border-radius:16px;background:linear-gradient(90deg,#24242c 25%,#30304a 37%,#24242c 63%);background-size:400% 100%;animation:skeleton 1.3s ease infinite}@keyframes skeleton{0%{background-position:100% 0}100%{background-position:0 0}}
.message{transition:transform .16s ease}.message:active .bubble{filter:brightness(1.05)}.chat-item{transition:background .12s ease,transform .12s ease}.chat-item:active{transform:scale(.995)}
@media(min-width:1200px){.shell{grid-template-columns:70px 356px minmax(0,1fr)}.sidebar{background:#18181d}.rail{background:#111216}.sidehead{min-height:58px;padding:15px 14px 8px}.chat-item{min-height:72px;padding:9px 14px}.messages{padding-left:max(24px,calc((100% - 760px)/2));padding-right:max(24px,calc((100% - 760px)/2))}.page{max-width:590px}.page-scroll{padding-top:22px}.panehead{height:58px}}
@media(max-width:760px){body{overscroll-behavior:none}.auth{padding:0}.auth-card{width:100%;min-height:100dvh;border:0;border-radius:0}.auth-stage{padding:36px 22px max(38px,calc(20px + env(safe-area-inset-bottom)))}.auth-top{padding-top:max(18px,env(safe-area-inset-top))}.auth-stage .brand{margin-bottom:28px}.otp-row{gap:6px}.otp-row .otp{width:44px;height:54px}.admin-shell{display:block}.admin-tabs{position:static;display:flex;flex-direction:row;overflow:auto;margin-bottom:12px;padding-bottom:4px}.admin-tabs button{white-space:nowrap}.admin-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.admin-row{align-items:flex-start;flex-wrap:wrap}.page-scroll{padding:14px 12px calc(20px + env(safe-area-inset-bottom))}.page{max-width:none}.modal-shade{align-items:flex-end}.modal{width:100%;max-width:none;border-radius:22px 22px 0 0;max-height:86dvh;padding-bottom:env(safe-area-inset-bottom);animation:sheetup .22s ease}@keyframes sheetup{from{transform:translateY(30px);opacity:.5}to{transform:none;opacity:1}}.stories{padding-left:12px}.chat-item{min-height:70px}.messages{padding-bottom:18px}.composer-area{background:#18181ed9;backdrop-filter:blur(16px)}.composer{background:#24242b;border-radius:20px;padding:0 4px}.composer textarea{padding-left:6px}.chathead{padding-top:max(8px,env(safe-area-inset-top));height:calc(62px + env(safe-area-inset-top))}.sidebar{padding-top:env(safe-area-inset-top)}.mobile-nav{min-height:54px}.message{max-width:89%}.bubble{font-size:15px}.net-state{width:max-content;max-width:calc(100vw - 24px);text-align:center}}
.sticker-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:8px}.sticker-grid button{aspect-ratio:1;display:grid;place-items:center;background:#ffffff07}.sticker-grid img{max-width:76px;max-height:76px;object-fit:contain}
.location-card{display:flex;align-items:center;gap:10px;background:#ffffff0c;border-radius:12px;padding:12px;color:inherit;margin-bottom:6px}.location-card .i{color:var(--blue)}.location-card span{display:flex;flex-direction:column}.location-card small{color:var(--muted)}
.shortcut-list kbd{font:600 13px/1.2 ui-monospace,SFMono-Regular,Menlo,Consolas,monospace;color:var(--muted);background:rgba(255,255,255,.05);border:1px solid var(--border);border-radius:8px;padding:6px 9px;min-width:88px;text-align:center}
.skeleton-messages{justify-content:flex-end}.skeleton-message{height:42px;max-width:72%;border-radius:14px 14px 14px 5px;background:linear-gradient(90deg,#25252d 25%,#31313a 38%,#25252d 63%);background-size:400% 100%;animation:skeleton 1.2s ease infinite;margin:3px 0}.skeleton-message.mine{align-self:flex-end;border-radius:14px 14px 5px 14px}.skeleton-composer{height:44px;border-radius:22px;background:linear-gradient(90deg,#25252d 25%,#31313a 38%,#25252d 63%);background-size:400% 100%;animation:skeleton 1.2s ease infinite}
/* NOVO 2.1: common icon geometry, readable panels and gesture feedback */
svg.i{stroke-width:1.8;overflow:visible}.brand-icon,.rail .logo,.welcome img{object-fit:contain;border-radius:22%;opacity:1}.rail .logo{width:36px;height:36px}.modal-shade{z-index:140}.modal{box-shadow:0 24px 90px #0006}.message-actions .modal{width:320px;border-radius:18px}.message-actions .modal-head{display:none}.message-actions .modal-body{padding:12px}.message-actions .menu-item{min-height:43px;padding:10px 12px}.message-actions .quick-reaction{padding:7px 5px;min-width:34px}.message-actions .row{gap:0;background:var(--card);border-radius:30px;padding:3px;margin-bottom:7px}.reaction-picker{display:flex;gap:6px;flex-wrap:wrap;margin:12px 0}.reaction-picker button{font-size:27px;min-width:44px}.reaction-picker .selected{background:var(--blue)}.message.swiping{transition:none;will-change:transform}.message.swipe-ready:before{content:attr(data-swipe);position:absolute;inset:50% auto auto -68px;font-size:11px;color:var(--blue);white-space:nowrap}.message{transition:transform .16s ease}.call-screen [hidden]{display:none!important}.call-screen video{pointer-events:none}.call-screen video::-webkit-media-controls{display:none!important}.remote-videos{position:absolute;inset:130px 24px 115px;display:grid;grid-template-columns:repeat(auto-fit,minmax(200px,1fr));gap:12px;align-items:center;justify-items:center;pointer-events:none}.remote-tile{width:100%;height:100%;min-height:0;position:relative;display:flex;align-items:center;justify-content:center}.remote-videos .remote-tile video{width:100%;height:100%;max-height:100%;object-fit:contain;border-radius:18px}.remote-tile audio{display:none}.peer-placeholder{align-self:flex-end;color:#aaa6ba;font-size:12px;padding:12px}.local-video{z-index:3;object-fit:cover;transform:none}.local-video.screen-preview{transform:none;object-fit:contain}.call-avatar{position:relative;z-index:1;pointer-events:none}.call-top,.call-controls{z-index:5}.call-title,#call-status{position:relative;z-index:4;pointer-events:none}.audio-unlock{position:absolute;bottom:108px;left:50%;transform:translateX(-50%);z-index:6;max-width:90%}.call-controls .active{background:var(--blue)}.call-screen.minimized .remote-videos,.call-screen.minimized .local-video{display:none}.call-screen.minimized .call-top{display:flex}.call-screen.minimized .audio-unlock{position:static;transform:none}.call-screen.minimized{cursor:default}
@media(min-width:1200px){.shell{grid-template-columns:76px 394px minmax(0,1fr)}.rail{background:var(--panel);gap:4px}.sidebar{background:var(--panel)}.page{max-width:640px}.page-scroll{padding-top:28px}.panehead{justify-content:center;position:relative}.panehead>button{position:absolute;left:16px}.sidehead h2{font-size:24px}.setting-row{min-height:52px}.settings-list{padding:8px 14px}.settings-list .setting-row{border-radius:12px}.chat-item{min-height:78px}.searchbox input{min-height:38px}.navbtn{min-height:64px}}
@media(max-width:760px){.shell{height:var(--app-height,100dvh)}.message{touch-action:pan-y;user-select:none;-webkit-user-select:none;-webkit-touch-callout:none}.message a,.message button{touch-action:manipulation}.message img{user-select:none;-webkit-user-drag:none}.message-actions .modal{width:100%;border-radius:24px 24px 0 0}.message-actions .modal:before{content:'';display:block;width:36px;height:4px;background:var(--muted);border-radius:4px;margin:10px auto 0}.message-actions .menu-item{min-height:48px}.message-actions .quick-reaction{font-size:28px!important;flex:1}.message-actions .modal-body{padding:12px 16px 20px}.modal-shade{padding:0}.modal{max-height:calc(var(--app-height,100dvh) - 18px)}.call-screen{height:var(--app-height,100dvh);padding-top:env(safe-area-inset-top)}.remote-videos{inset:135px 10px 130px;grid-template-columns:1fr}.local-video{top:76px;right:12px;width:96px;height:136px}.call-controls{bottom:calc(22px + env(safe-area-inset-bottom));gap:12px}.call-controls button{width:52px;height:52px}.audio-unlock{bottom:calc(88px + env(safe-area-inset-bottom))}.composer textarea{font-size:16px;max-height:120px}.page input,.page textarea,.modal input,.modal textarea{font-size:16px}.mobile-nav{padding-bottom:env(safe-area-inset-bottom)}body.keyboard-open .mobile-nav{display:none}}
@media(prefers-reduced-motion:reduce){.message,.modal{transition:none;animation:none}}
.selected-message{outline:2px solid var(--blue);outline-offset:3px;border-radius:14px}.selection-bar{position:absolute;bottom:0;left:0;right:0;z-index:12;display:flex;align-items:center;gap:10px;padding:12px 18px calc(12px + env(safe-area-inset-bottom));background:var(--panel);border-top:1px solid var(--line);box-shadow:0 -5px 20px #0003}.selection-bar button{min-width:44px;min-height:44px}
/* 2.2 — reference-driven layout */
:root{--bg:#101114;--panel:#18191d;--card:#27282e;--input:#2b2c30;--muted:#a2a3aa;--incoming:#38384a;--out:#7854d4}
.rail-glyph{fill:currentColor!important;stroke:none!important;width:24px!important;height:24px!important}.rail-glyph .cutout{fill:var(--panel)}.rail-icon-wrap{position:relative}.rail-count{position:absolute;right:-7px;top:-4px;background:#7d8084;border-radius:12px;color:white;font-size:10px;font-weight:600;padding:1px 4px}.navbtn.active .rail-count{background:var(--blue)}.rail-divider{height:1px;background:var(--line);width:60px;margin:18px 0 8px}.rail-brand{margin-top:auto;padding:10px}.rail-brand img{width:26px;height:26px;border-radius:8px}.rail .settings-nav{margin-top:0}.rail .navbtn{font-size:11px;font-weight:600;min-height:67px;gap:6px}.rail .navbtn.active{color:#fff}.sidehead{justify-content:flex-start}.sidehead .round-btn{margin-left:auto;width:32px;height:32px}.header-story{padding:0;margin-left:0}.header-story .avatar{border:1px solid #8c8d93}.sidehead h2{font-weight:700}.action-popover .modal{width:280px;max-height:calc(100dvh - 24px);border-radius:16px;background:var(--panel);box-shadow:0 10px 40px #0006}.action-popover .modal-head{display:none}.action-popover .modal-body{padding:8px}.action-popover .menu-item{min-height:40px;padding:10px 12px;gap:10px;font-weight:500}.action-popover .menu-item .i{width:20px;height:20px}.action-popover.modal-shade{background:transparent;backdrop-filter:none}.action-popover .menu-item:focus{outline:0;background:var(--card)}
.message.media-only .bubble{padding:0;border-radius:15px;background:transparent!important;box-shadow:none;position:relative;min-width:0;overflow:hidden}.message.media-only .attachment{display:block;width:auto;max-width:min(350px,100%);max-height:440px;height:auto;margin:0;border-radius:15px}.message.media-only .body:empty{display:none}.message.media-only .meta{position:absolute;bottom:7px;right:7px;margin:0;padding:3px 6px;background:#0008;border-radius:10px;color:#fff;opacity:1;pointer-events:none}.message.media-only .reactions:empty{display:none}.message.media-only .reactions:not(:empty){padding:5px;background:var(--panel)}.message-hover{position:absolute;display:flex;gap:4px;right:-78px;top:50%;opacity:0;pointer-events:none;transform:translateY(-50%)}.message.mine .message-hover{right:auto;left:-78px}.message:hover .message-hover,.message:focus-within .message-hover{opacity:1;pointer-events:auto}.message-hover button{border-radius:50%;background:var(--incoming);width:32px;height:32px;padding:6px}.message-hover svg{width:18px;height:18px}.voice-player{display:flex;align-items:center;gap:10px;min-width:220px;max-width:330px;padding:4px 0}.voice-player audio{display:none}.voice-toggle{border-radius:50%;width:44px;height:44px;padding:11px;background:#e3e0ff;color:#494292}.voice-middle{flex:1;min-width:80px;display:flex;flex-direction:column;gap:4px}.voice-seek{height:18px;padding:0;background:transparent;accent-color:#dfdbff}.voice-clock{font-size:10px;font-variant-numeric:tabular-nums}.voice-speed{padding:6px;font-size:12px}.recording .composer{display:none}.record-bar{display:flex;align-items:center;gap:12px;min-height:52px;background:var(--panel);padding:6px 8px;border-radius:20px}.record-bar time{font-weight:600;font-variant-numeric:tabular-nums;min-width:48px}.record-wave{flex:1;min-width:20px;height:36px;width:100%}.record-dot{height:7px;width:7px;border-radius:50%;background:#ef4274;animation:recordblink 1s infinite}.record-bar.paused .record-dot{animation:none;opacity:.4}.record-send{background:var(--blue);border-radius:50%;padding:6px;color:white}.record-bar button{flex-shrink:0}.copy-phone{color:var(--blue);display:flex;align-items:center;justify-content:space-between;width:100%;padding:4px 0;font-size:16px}.profile-header .actions{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:12px;margin:22px 0 20px}.profile-header .actions button{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:8px;color:var(--blue);background:var(--card);min-height:68px;border-radius:17px;font-weight:600}.profile-header .actions .i{margin:0}.profile-header .avatar.big{width:88px;height:88px}.call-screen .call-title{position:absolute;top:24px;left:100px;right:100px;text-align:center;margin:0}.call-screen #call-status{position:absolute;top:53px;left:100px;right:100px;text-align:center;margin:0}.call-screen.has-remote-video .call-avatar{display:none}.call-screen .remote-videos{inset:88px 24px 108px}.call-screen.minimized .call-title{position:static}.call-screen.minimized #call-status{position:static}.call-screen .remote-tile video{border-radius:20px}.call-screen .call-top{position:absolute;inset:18px 22px auto}.call-screen .local-video{top:78px}
@keyframes recordblink{50%{opacity:.35}}
@media(min-width:761px){.sidebar>.stories{display:none}.sidebar>.stories.expanded{display:flex}.sidebar>.tabs{display:none}.sidebar>.tabs:has([data-filter]:nth-child(5)){display:flex}.composer-area{padding:0 max(24px,calc((100% - 720px)/2)) 14px;background:transparent}.composer{border-radius:19px;background:var(--panel);min-height:50px;gap:4px}.composer textarea{background:transparent}.composer button{color:#aaaab3}.composer .send{color:var(--blue)}.messages{padding-left:max(30px,calc((100% - 720px)/2));padding-right:max(30px,calc((100% - 720px)/2))}.page{max-width:640px}.page .tabs{gap:22px;padding:0 8px;border-bottom:1px solid var(--line);margin-bottom:14px}.page .card:has(.tabs){padding:10px 20px}.panehead h3{font-size:16px}}
@media(max-width:760px){.message-hover{display:none!important}.header-story{display:none}.action-popover.modal-shade{background:#0006;backdrop-filter:blur(3px)}.action-popover .modal{width:100%;border-radius:22px 22px 0 0;max-height:80dvh}.action-popover .menu-item{min-height:48px}.action-popover .modal-head{display:flex}.message.media-only{max-width:82%}.message.media-only .attachment{max-width:100%;max-height:380px}.profile-header .actions{gap:6px}.profile-header .actions button{padding:8px 2px;font-size:11px;min-height:62px;border-radius:13px}.record-bar{gap:7px}.record-wave{max-width:45vw}.record-bar button{padding:8px}.record-bar time{min-width:42px;font-size:12px}.call-screen .call-title{top:calc(24px + env(safe-area-inset-top));font-size:17px;left:64px;right:64px}.call-screen #call-status{top:calc(49px + env(safe-area-inset-top));left:64px;right:64px}.call-screen .remote-videos{inset:96px 8px 114px}.call-screen .local-video{width:82px;height:118px;top:80px}.voice-player{min-width:190px;width:100%}.composer-area{padding-bottom:calc(8px + env(safe-area-inset-bottom))}}
.encryption-banner{border-radius:0;padding:6px 12px;background:#172b25;color:#a7dac2;font-size:12px;flex-shrink:0}.encrypted-file{display:flex;align-items:center;gap:10px;text-align:left;max-width:310px;min-height:64px}.encrypted-file small{display:block;margin-top:5px}.key-fingerprint{font:12px monospace;overflow-wrap:anywhere;user-select:all}#key-export-value{margin:14px 0;font:12px monospace;user-select:all}.record-bar{max-width:100%}

/* NOVO 3.0 — auth, call links, ringtone settings and reference-aligned call UI */
.auth-v3{position:relative;overflow:hidden;background:#101114}.auth-v3 .auth-pattern{position:fixed;inset:0;background:radial-gradient(circle at 50% 8%,#25345c66,transparent 34%),radial-gradient(circle at 20% 80%,#2a17584d,transparent 36%);pointer-events:none}.auth-card{position:relative;z-index:1;width:min(470px,calc(100vw - 32px));min-height:520px;background:var(--panel);border:1px solid var(--line);border-radius:22px;box-shadow:0 24px 90px #0007;overflow:hidden}.auth-top{height:58px;padding:12px 16px;display:flex;justify-content:space-between;align-items:center}.auth-globe,.auth-help,.auth-back{width:38px;height:38px;display:grid;place-items:center;border-radius:50%}.auth-help{font-size:18px}.auth-stage{position:relative;padding:18px 48px 46px;text-align:center}.auth-stage .brand-icon{width:70px;height:70px}.auth-stage .brand{font-size:34px;letter-spacing:3px;margin:7px 0 26px}.auth-stage h2{font-size:25px;margin-bottom:8px}.auth-stage>.muted{display:block;line-height:1.5;margin:0 auto 24px;max-width:350px}.auth-stage .stack{text-align:left}.auth-choice{display:grid;gap:10px;margin:22px 0 12px}.auth-main{min-height:48px;font-weight:700}.auth-back{position:absolute;left:12px;top:-42px}.link-btn{width:100%;margin-top:9px;color:var(--blue)}.yandex-id-btn{width:100%;min-height:48px;border-radius:12px;background:#fff;color:#111;display:flex;align-items:center;justify-content:center;gap:10px;font-weight:700;margin:10px 0}.yandex-id-btn:hover{background:#f1f1f1}.yandex-id-btn:disabled{cursor:default;opacity:.75}.ya-mark{width:28px;height:28px;display:grid;place-items:center;border-radius:50%;background:#fc3f1d;color:#fff;font-weight:800}.auth-provider-note{display:flex;align-items:center;gap:12px;text-align:left;background:var(--card);border-radius:13px;padding:12px 14px;margin:14px 0}.auth-provider-note small{display:block;margin-top:3px}.auth-steps{display:flex;justify-content:center;gap:7px;margin:18px 0}.auth-steps span{width:28px;height:4px;background:#4a4b52;border-radius:3px}.auth-steps span.active{background:var(--blue)}.availability{min-height:20px;font-size:12px;margin:-6px 2px 3px}.availability.free{color:#54d585}.availability.busy{color:#ff637e}.availability.checking{color:var(--muted)}.prefix-input{display:flex;align-items:center;background:var(--input);border:1px solid transparent;border-radius:10px;overflow:hidden}.prefix-input:focus-within{border-color:var(--blue)}.prefix-input>span{padding-left:12px;color:var(--muted);font-weight:700}.prefix-input input{border:0;background:transparent;padding-left:3px}.two-fields{display:grid;grid-template-columns:1fr 1fr;gap:10px}.auth-agree{font-size:12px;color:var(--muted);line-height:1.4}.identity-card{display:grid;grid-template-columns:1fr 1fr;gap:10px;background:var(--card);padding:13px;border-radius:14px}.identity-card div{min-width:0}.identity-card small,.identity-card b{display:block}.identity-card b{margin-top:4px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.profile-edit-head{text-align:center;margin-bottom:16px}.profile-photo-btn{display:inline-flex;align-items:center;gap:7px;color:var(--blue)}.settings-yandex{margin:14px 0 0}.radio{width:20px;height:20px;border:2px solid #555862;border-radius:50%;position:relative}.radio.on{border-color:var(--blue)}.radio.on:after{content:'';position:absolute;inset:4px;background:var(--blue);border-radius:50%}.language-list .setting-row:last-child{border-bottom:0}.copy-line{display:flex;gap:8px;align-items:center;overflow-wrap:anywhere;background:#0002;border-radius:10px;padding:10px 12px;margin:10px 0 16px}.copy-line button{margin-left:auto;flex-shrink:0}

.group-call-create{color:var(--blue);font-weight:650;padding-left:20px}.group-call-page{text-align:center;padding-top:6px}.group-call-icon{width:82px;height:82px;border-radius:50%;margin:0 auto 14px;display:grid;place-items:center;background:linear-gradient(145deg,#58aaff,#7856ef);color:white}.group-call-icon .i{width:40px;height:40px}.group-call-page h2{font-size:22px;margin-bottom:8px}.call-link-url{display:block;max-width:100%;margin:0 auto 18px;color:var(--blue);font-size:12px;overflow-wrap:anywhere}.call-share-card{text-align:left;padding:7px 12px}.call-share-card .setting-row:last-child{border-bottom:0}.group-call-start{min-height:54px;font-weight:700;margin:14px 0 10px}.group-call-page>.secondary{min-height:46px}.group-call-page>.muted{line-height:1.5;margin-top:16px}

.ringtone-intro{display:flex;align-items:center;gap:14px}.ringtone-logo{width:54px;height:54px;display:grid;place-items:center;border-radius:50%;background:var(--blue);color:#fff;flex-shrink:0}.ringtone-logo .i{width:27px;height:27px}.ringtone-card>.row button{width:40px;height:40px;border-radius:50%;background:#ffffff0b}.ringtone-actions{display:grid;grid-template-columns:repeat(3,1fr);gap:8px;margin-top:16px}.ringtone-actions button{background:#ffffff0b;min-height:42px;font-size:12px}.ringtone-actions button.active{background:#113c6b;color:#6bb5ff;outline:1px solid #188fff77}

.call-screen{background:#0d0f12;isolation:isolate}.call-ambient{position:absolute;inset:0;z-index:-1;background:radial-gradient(circle at 50% 43%,#185d535f 0,transparent 31%),radial-gradient(circle at 50% 55%,#17264872 0,transparent 46%)}.call-screen .call-avatar{width:min(31vw,360px);height:min(31vw,360px);min-width:140px;min-height:140px;max-width:360px;max-height:360px;background:#323641;margin:0;border:1px solid #ffffff16;box-shadow:0 0 70px #37a47738;overflow:hidden}.call-screen .call-avatar img{display:block;width:100%;height:100%;object-fit:cover;object-position:center center;transform:scale(1.05)}.call-screen .call-top button{width:52px;height:52px;border-radius:50%;background:#484b5a;display:grid;place-items:center}.call-screen .call-title{font-size:29px;top:calc(50% - min(31vw,360px)/2 - 95px)}.call-screen #call-status{top:calc(50% - min(31vw,360px)/2 - 55px);font-size:17px}.call-screen .call-controls{bottom:30px;padding:10px;background:#27282c;border-radius:46px;gap:10px}.call-screen .call-controls button{width:62px;height:62px;background:#4b4e5e}.call-screen .call-controls button.off{background:#fff;color:#24262b}.call-screen .call-controls .red{background:#cc4e63}.call-screen .local-video{width:210px;height:250px;max-height:none;top:90px;right:36px;border-radius:24px;background:#24262c;border:1px solid #ffffff17}.call-screen .remote-videos{z-index:2}.incoming-call-screen .call-ambient{background:radial-gradient(circle at 50% 53%,#5b3a8a99 0,transparent 31%),radial-gradient(circle at 50% 50%,#163f6c75 0,transparent 52%)}.incoming-center{display:flex;flex-direction:column;align-items:center;gap:9px;transform:translateY(-4vh)}.incoming-center h1{font-size:42px;font-weight:500}.incoming-center p{font-size:21px;color:#c2c3cc}.incoming-center .incoming-avatar{margin-top:34px;width:min(36vw,390px);height:min(36vw,390px);max-width:390px;max-height:390px}.incoming-actions{position:absolute;bottom:72px;display:flex;gap:110px}.incoming-action{display:flex;flex-direction:column;align-items:center;gap:10px;background:transparent!important;font-size:13px}.incoming-action .i{width:36px;height:36px}.incoming-action:before{content:'';position:absolute;width:90px;height:90px;border-radius:50%;z-index:-1;margin-top:-20px}.incoming-action.decline:before{background:#e5566a}.incoming-action.answer:before{background:#5bc958}.incoming-action.decline,.incoming-action.answer{width:92px;height:120px;padding-top:8px}.incoming-action.answer .i{transform:rotate(-20deg)}.incoming-action.decline .i{transform:rotate(135deg)}

@media(max-width:760px){.auth-card{width:100%;min-height:100dvh;border-radius:0;background:var(--bg);box-shadow:none}.auth-stage{padding:20px 22px 34px}.auth-stage h2{font-size:24px}.two-fields,.identity-card{grid-template-columns:1fr}.group-call-page{padding-top:18px}.ringtone-actions{grid-template-columns:1fr}.call-screen .call-top{top:calc(22px + env(safe-area-inset-top));left:18px;right:18px}.call-screen .call-top button{width:54px;height:54px}.call-screen .call-title{top:24%;left:18px;right:18px;font-size:31px}.call-screen #call-status{top:29%;left:18px;right:18px;font-size:17px}.call-screen .call-avatar{width:min(68vw,330px);height:min(68vw,330px);position:absolute;top:36%;margin:0}.call-screen .local-video{width:31vw;height:25vh;right:18px;top:calc(92px + env(safe-area-inset-top));border-radius:26px}.call-screen .call-controls{bottom:calc(28px + env(safe-area-inset-bottom));padding:8px;gap:7px}.call-screen .call-controls button{width:58px;height:58px}.call-screen .remote-videos{inset:34% 9px 122px}.incoming-center{transform:translateY(-2vh);gap:8px}.incoming-center h1{font-size:37px;text-align:center}.incoming-center p{font-size:18px}.incoming-center .incoming-avatar{position:static;width:min(66vw,330px);height:min(66vw,330px);margin-top:28px}.incoming-actions{bottom:calc(62px + env(safe-area-inset-bottom));gap:74px}.incoming-action:before{width:84px;height:84px}.call-screen.minimized{width:190px;height:150px;right:10px;bottom:calc(72px + env(safe-area-inset-bottom))}.call-screen.minimized .call-controls{display:none}.call-screen.minimized .call-title{position:static;font-size:14px}.call-screen.minimized #call-status{position:static;font-size:11px}.call-screen.minimized .incoming-center{transform:none}.call-screen.minimized .incoming-center .incoming-avatar,.call-screen.minimized .incoming-actions{display:none}}
.auth-steps span.on{background:var(--blue)}

/* NOVO 3.0 — call chat/participants panel */
.call-top-actions{display:flex;gap:8px;align-items:center}.call-top-actions button.active{background:#1688ff;color:#fff}.call-side-panel{position:absolute;z-index:8;top:78px;right:22px;bottom:118px;width:min(360px,32vw);border:1px solid #30323a;background:rgba(22,23,29,.96);backdrop-filter:blur(18px);border-radius:18px;box-shadow:0 18px 60px #0008;overflow:hidden;color:#fff}.call-side-panel[hidden]{display:none}.call-panel-head{height:54px;display:flex;align-items:center;justify-content:space-between;padding:0 14px 0 18px;border-bottom:1px solid #30323a}.call-panel-close{font-size:26px;line-height:1;width:36px;height:36px;border-radius:50%}.call-panel-loading{padding:22px;color:#9da1ad}.call-chat-list{height:calc(100% - 108px);overflow:auto;padding:12px;display:flex;flex-direction:column;gap:8px}.call-chat-msg{align-self:flex-start;max-width:86%;padding:8px 10px;border-radius:12px;background:#292b33;display:flex;flex-direction:column;gap:3px}.call-chat-msg.mine{align-self:flex-end;background:#176bd7}.call-chat-msg b{font-size:11px;color:#aeb4c2}.call-chat-msg.mine b{color:#dcecff}.call-chat-msg span{font-size:14px;line-height:1.3;white-space:pre-wrap;overflow-wrap:anywhere}.call-chat-form{height:54px;border-top:1px solid #30323a;display:flex;gap:8px;padding:8px}.call-chat-form input{flex:1;min-width:0;border:0;background:#2a2c34;border-radius:12px;padding:0 12px;color:#fff}.call-chat-form button{width:40px;border-radius:12px}.call-people-list{overflow:auto;height:calc(100% - 54px);padding:8px}.call-person{display:flex;align-items:center;gap:10px;padding:9px;border-radius:12px}.call-person:hover{background:#2a2c34}.call-person-avatar{width:38px;height:38px;border-radius:50%;display:grid;place-items:center;background:#1688ff;overflow:hidden;font-weight:700}.call-person-avatar img{display:block;width:100%;height:100%;object-fit:cover;object-position:center center;transform:scale(1.05)}.call-person div{display:flex;flex-direction:column;gap:2px}.call-person small{color:#9296a3}.call-screen.minimized .call-side-panel{display:none}
@media(max-width:760px){.call-top-actions{gap:5px}.call-top-actions button{width:42px;height:42px}.call-side-panel{top:72px;right:10px;left:10px;bottom:112px;width:auto;border-radius:18px}.call-side-panel~.call-controls{z-index:9}.call-chat-list{font-size:14px}}

/* NOVO 3.0.1 — reference-aligned UI patch */
:root{--bg:#0f1014;--panel:#191a20;--card:#282932;--input:#303137;--line:#ffffff12;--text:#f4f4f7;--muted:#9b9ca6;--blue:#0a86ff;--incoming:#202126}
body{font-weight:450}.shell{grid-template-columns:70px 354px minmax(0,1fr)}.rail{padding:12px 5px 10px;background:#18191f;gap:5px}.navbtn{width:60px;min-height:55px;padding:7px 0;font-size:10px;gap:3px}.navbtn svg{width:22px;height:22px}.rail-divider{width:54px;height:1px;background:#ffffff14;margin:6px 0}.rail-brand{margin-top:auto;width:34px;height:34px;padding:5px}.rail-brand img{width:24px;height:24px;border-radius:8px}.rail .settings-nav{margin-top:0}.sidebar{background:#191a20}.sidehead{height:57px;min-height:57px;padding:15px 14px 8px}.sidehead h2{font-size:22px;letter-spacing:-.25px}.round-btn{width:31px;height:31px;padding:6px}.searchbox{margin:0 13px 10px}.searchbox input{height:35px;border-radius:10px;background:#2d2e34}.chat-tabs{padding:0 14px;gap:24px;min-height:39px}.chat-tabs button{font-size:13px;font-weight:600}.tab-count{display:inline-grid;place-items:center;min-width:15px;height:15px;padding:0 4px;border-radius:9px;background:#087ff2;color:white;font-size:9px}.chat-item{padding:9px 13px;min-height:74px;gap:11px}.chat-item .avatar,.contact-row .avatar{width:45px;height:45px;min-width:45px}.chat-item .name,.contact-main b{font-size:14px;font-weight:700}.chat-item .preview,.contact-main p{font-size:13px;color:#a4a4ad}.chat-item.active{background:#363541}.chat-item:hover,.contact-row:hover{background:#2a2b32}.badge{font-size:10px;padding:2px 6px}.sidebar>.group-call-create{display:flex;align-items:center;gap:12px;width:calc(100% - 26px);margin:0 13px;padding:8px 10px;border-radius:8px;color:#0a86ff;font-weight:700}.call-tabs{padding-left:18px}.call-row{min-height:59px;padding-top:7px;padding-bottom:7px}.call-row.missed b{color:#ef4669}.call-row .call-info{font-size:17px;margin-left:4px;color:#f4f4f7}.call-select{width:22px;height:22px;border:2px solid #646773;border-radius:50%;flex:none}.call-select.on{border-color:#0a86ff;background:#0a86ff;box-shadow:inset 0 0 0 5px #191a20}.call-select-bar{display:flex;align-items:center;justify-content:space-between;padding:8px 12px;border-top:1px solid var(--line);background:#191a20}.call-select-bar span{font-size:12px;color:var(--muted)}
.contact-row{display:flex;align-items:center;min-height:51px;padding:2px 8px 2px 13px;position:relative}.contact-main{display:flex;align-items:center;gap:11px;text-align:left;flex:1;padding:4px;border-radius:0}.contact-main p{margin-top:2px}.contact-more{opacity:0;width:34px;height:34px;padding:6px;display:grid;place-items:center}.contact-row:hover .contact-more{opacity:1}
.settings-list{padding:0 14px 26px}.settings-profile{display:flex;align-items:center;width:100%;gap:11px;text-align:left;padding:6px 5px 11px;border-radius:12px}.settings-profile .avatar{width:50px;height:50px;min-width:50px}.settings-profile b{font-size:14px}.settings-profile p{font-size:12px;color:#d4d4dc;margin-top:2px}.settings-profile .chevron{font-size:28px;color:#747680}.settings-list .setting-row{height:54px;padding:0 10px;border-bottom:0;font-weight:650}.settings-list .setting-row:hover{background:#24252c}.settings-list .setting-row svg{width:21px;height:21px}.settings-list .right{font-size:22px;color:#73757f}.settings-separator{height:1px;background:#ffffff12;margin:5px 0}.settings-invite{margin-top:1px}
.panehead{height:60px;padding:0 22px;background:#191a20}.panehead h3{font-size:14px;font-weight:750;margin-right:44px}.page-scroll{padding:22px 22px 34px}.page{max-width:590px}.card{background:#282932;border-radius:14px}.setting-row{min-height:50px}.settings-section-label{display:block;font-size:11px;font-weight:700;color:#a7a8b2;margin:15px 10px 8px}
.profile-edit-ref{max-width:610px;margin:0 auto;padding-top:10px}.profile-edit-head{position:relative;width:92px;margin:0 auto 16px}.profile-edit-head .avatar.big{width:80px;height:80px;margin:0 auto}.profile-camera{position:absolute;right:0;bottom:0;width:30px;height:30px;padding:5px;border-radius:50%;background:#0a86ff;color:#fff;border:3px solid #0f1014}.profile-camera svg{width:15px;height:15px}.profile-edit-ref form{display:flex;flex-direction:column;gap:16px}.ref-input{position:relative;display:block}.ref-input input,.ref-input textarea{border:0;background:#292a32;border-radius:13px;min-height:47px;padding:13px 48px 13px 13px;font-size:14px}.ref-input textarea{height:83px;resize:none}.ref-input>span{position:absolute;right:13px;top:15px;font-size:10px;color:#c1c2cc}.ref-bio>span{top:auto;bottom:10px}.profile-primary-actions{display:flex;gap:16px;margin-top:2px}.profile-logout{height:53px;background:#454657;font-weight:700;flex:1}.profile-more{width:53px;height:53px;border-radius:50%;background:#454657;display:grid;place-items:center}.profile-bottom-actions{display:flex;gap:14px;margin-top:30vh}.profile-bottom-actions button{flex:1;height:54px;font-weight:700}.settings-yandex{margin:0}
.notifications-ref,.security-ref,.devices-ref,.folders-page,.appearance-ref,.language-ref,.shortcuts-ref,.about-ref{max-width:580px;margin:0 auto}.notify-card{padding:0 12px;margin-bottom:18px}.notification-check{width:100%;min-height:50px;display:flex;align-items:center;text-align:left;padding:8px 3px;border-radius:0;border-bottom:0}.notification-check+.notification-check{border-top:0}.check-circle{width:19px;height:19px;border:2px solid #5d606b;border-radius:50%;display:grid;place-items:center;font-size:12px;color:white}.check-circle.on{background:#0a86ff;border-color:#0a86ff}.ringtone-settings .notification-check{border-bottom:1px solid #ffffff0d}.ringtone-settings .notification-check:last-child{border-bottom:0}.push-permission{width:100%;margin-top:4px}.ring-choice{width:100%;display:flex;align-items:center;gap:12px;text-align:left;padding:12px;border-radius:10px}.ring-choice.active{background:#333540}.ring-choice>span:first-child{width:40px;height:40px;border-radius:50%;display:grid;place-items:center;background:#1f2026}.ring-choice div{flex:1}.ring-choice small{display:block;margin-top:3px}.ring-preview{width:36px;height:36px;padding:5px;border-radius:50%;background:#ffffff0a}
.security-card{padding:0 10px;margin-bottom:18px}.security-card .setting-row{padding:10px 7px;min-height:58px;border:0}.privacy-main{padding-bottom:8px}.security-line{height:1px;background:#ffffff12;margin:0 0 5px}.privacy-row{display:flex;align-items:center;width:100%;min-height:51px;padding:8px 7px;border-radius:0;text-align:left}.privacy-row b{font-size:14px;flex:1}.privacy-row span{font-size:13px;color:#a8a8b1}.safe-row:disabled{opacity:1;cursor:default}.safe-row:disabled .switch{opacity:.75}.info-card{margin-top:0}.security-card .muted{line-height:1.25}
.devices-hero{text-align:center;padding:22px 16px}.device-circle{width:64px;height:64px;border-radius:50%;background:#111217;margin:0 auto 14px;display:grid;place-items:center}.device-circle svg{width:30px;height:30px;color:#8f919b}.devices-hero h3{font-size:16px;margin-bottom:6px}.sessions-card{padding:6px 16px 12px}.session-row{display:flex;align-items:flex-start;gap:12px;padding:7px 0}.session-row b{font-size:14px}.session-row p,.session-row small{font-size:12px;color:#b7b8c2;display:block;line-height:1.35}.online-dot{color:#2ed06f;font-size:12px;padding-top:3px}.sessions-end-all{font-weight:700;text-align:left;margin-top:8px;color:#f14868}
.folder-hero{padding:18px}.folder-hero-icon{width:64px;height:64px;border-radius:50%;background:#111217;margin:0 auto 14px;display:grid;place-items:center;color:#777985}.folder-hero>p{text-align:center;color:#e2e2e8;line-height:1.35}.folder-hero>.primary{display:flex;align-items:center;gap:6px;margin:16px auto 18px;font-weight:700}.folder-divider{height:1px;background:#ffffff18;margin:0 0 10px}.folder-hero>small,.recommended-folders>small{display:block;margin-bottom:6px}.folder-static,.folder-item{display:flex;align-items:center;gap:11px;min-height:46px}.folder-item button{width:34px;height:34px;padding:6px}.folder-drag{color:#8b8d96;font-size:17px}.recommended-folders{padding:16px 18px}.recommended-folders .folder-static button{margin-left:auto;width:30px;height:30px;padding:5px;border-radius:50%;background:#0a86ff;color:white}.folder-editor{max-width:590px;margin:auto}.folder-name-card{padding:13px 16px}.folder-name-card>label{font-size:12px;color:#c2c3cb}.folder-name-wrap{position:relative;margin-top:8px}.folder-name-wrap input{height:47px;padding-right:50px}.folder-name-wrap span{position:absolute;right:12px;top:15px;font-size:10px;color:#bbbcc6}.folder-rules-card{padding:12px 16px;max-height:425px;overflow:auto}.folder-search{margin:0 0 12px}.folder-rules-card>small,.folder-explicit>small{font-size:11px;font-weight:700;color:#aaaab4}.folder-type-row,.folder-chat-row{display:flex;align-items:center;width:100%;gap:11px;min-height:50px;text-align:left;padding:6px 2px}.folder-type-icon{width:38px;height:38px;border-radius:50%;background:#111217;display:grid;place-items:center}.folder-type-row small{display:block;margin-top:2px}.choice-ring{width:20px;height:20px;border:2px solid #60626c;border-radius:50%;flex:none}.choice-ring.on{border-color:#0a86ff;background:#0a86ff;box-shadow:inset 0 0 0 5px #282932}.folder-only-title{display:block;margin:6px 10px}.folder-only-card{padding:0 12px}.folder-toggle-row{width:100%;display:flex;align-items:center;gap:12px;min-height:50px;text-align:left;padding:7px 2px}.folder-bottom{display:flex;gap:10px}.folder-bottom button{flex:1;height:48px}
.appearance-title{display:flex;justify-content:space-between;align-items:center;margin:0 8px 7px}.appearance-title button{padding:0;color:#d1d2da;font-size:12px}.font-card{display:flex;align-items:center;gap:14px;padding:12px 18px}.font-card input{padding:0;background:transparent;border:0}.font-small{font-size:13px}.font-large{font-size:22px}.theme-segment{display:grid;grid-template-columns:repeat(3,1fr);height:34px;background:#27282f;border-radius:9px;margin-bottom:20px;overflow:hidden}.theme-segment button{border-radius:0;padding:5px;font-weight:600;font-size:12px}.theme-segment button.active{background:#18191f;color:#0a86ff}.appearance-preview{height:407px;border:1px solid #ffffff12;border-radius:14px;position:relative;overflow:hidden;padding:15px 12px 118px}.preview-bubble{position:absolute;max-width:270px;padding:9px 10px 22px;border-radius:14px;font-size:15px;font-weight:650;line-height:1.2}.preview-bubble span{position:absolute;right:8px;bottom:6px;font-size:10px;font-weight:400;color:#bbb}.preview-bubble.in{left:10px;top:12px;background:#202126}.preview-bubble.out{right:10px;top:92px;background:linear-gradient(120deg,#0a8ff0,var(--out))}.preview-themes{position:absolute;left:0;right:0;bottom:0;height:104px;background:#2a2b31;display:flex;gap:10px;padding:13px 12px;overflow:auto}.preview-themes button{width:100px;min-width:100px;padding:0;color:#c9cad2}.preview-themes button span{display:block;width:100%;height:58px;border-radius:10px;background:linear-gradient(145deg,#111 20%,var(--pick) 100%);border:2px solid transparent}.preview-themes button.selected span{border-color:#fff}.preview-themes b{display:block;font-size:12px;margin-top:5px}.appearance-note{font-size:11px;color:#b6b7c1;line-height:1.3;margin-top:7px}
.language-ref .card{padding:5px 12px}.language-row{display:flex;align-items:center;width:100%;height:51px;text-align:left;padding:8px 2px}.language-row b{font-size:14px}.language-ref>p{margin-top:-9px}.shortcut-list{padding:6px 16px}.shortcut-row{display:flex;align-items:center;min-height:49px;gap:20px}.shortcut-row b{font-size:14px}.shortcut-row kbd{font:13px inherit;color:#c8c9d2;white-space:nowrap}.about-version{display:flex;align-items:center;padding:10px 16px}.about-version b{font-size:14px}.about-version button{color:#0a86ff}.business-card p{line-height:1.5;color:#c7c8d0;margin:10px 0 18px}
.invite-subtitle{color:#d8d8df;margin:-4px 0 14px}.invite-actions{display:flex;flex-direction:column}.invite-actions button{display:flex;align-items:center;gap:13px;min-height:47px;text-align:left;padding:7px 6px;border-radius:8px}.invite-actions svg{width:19px;height:19px}.phone-find{display:flex;flex-direction:column;gap:14px}.group-create{display:grid;grid-template-columns:66px 1fr;align-items:center;gap:12px}.group-avatar-pick{width:66px;height:66px;border-radius:50%;background:#33343c;display:grid;place-items:center;position:relative}.group-avatar-pick img{width:100%;height:100%;border-radius:50%;object-fit:cover}.group-avatar-pick span{position:absolute;right:5px;bottom:4px}.group-create>.modal-footer{grid-column:1/-1}.choose-users .choose-search{margin:0 0 10px}.choose-list{max-height:490px;overflow:auto}.user-choice{min-height:51px}.user-choice input[name=member]{display:none}.user-choice small{display:block;margin-top:2px}.choose-footer{position:sticky;bottom:0;background:#191a20;padding-top:10px}.choose-footer button{flex:1}.action-popover .modal{background:#191a20}.action-popover .modal-body{padding:4px 8px 8px}.action-popover .menu-item{min-height:43px}.action-popover .modal-head{display:none}
.group-call-page{max-width:670px;margin:auto}.group-call-page .call-share-card{padding:6px 16px}.group-call-page .setting-row{min-height:51px}.group-call-page .group-call-start{height:54px}.group-call-page>.secondary{display:none}.call-link-url{max-width:540px}
.round-note{--round-progress:0deg;width:226px;height:226px;border-radius:50%;position:relative;overflow:hidden;background:#111;border:1px solid #ffffff22}.round-note video{width:100%;height:100%;object-fit:cover;border-radius:50%;display:block}.round-note:after{content:'';position:absolute;inset:3px;border-radius:50%;pointer-events:none;background:conic-gradient(#0a86ff var(--round-progress),transparent 0);-webkit-mask:radial-gradient(circle,transparent calc(100% - 4px),#000 calc(100% - 3px));mask:radial-gradient(circle,transparent calc(100% - 4px),#000 calc(100% - 3px))}.round-toggle{position:absolute;left:50%;top:50%;transform:translate(-50%,-50%);width:52px;height:52px;border-radius:50%;background:#0009;color:white;display:grid;place-items:center;z-index:2}.round-toggle svg{width:27px;height:27px}.round-note.playing .round-toggle{opacity:0}.round-note:hover .round-toggle{opacity:1}.round-time{position:absolute;left:13px;bottom:12px;background:#0008;border-radius:9px;padding:3px 6px;font-size:10px;color:white;z-index:2}.message.round-message .bubble{background:transparent!important;padding:0;box-shadow:none}.message.round-message .meta{position:absolute;right:7px;bottom:8px;background:#0007;border-radius:8px;padding:3px 6px;color:white}
@media(min-width:761px){.modal{max-width:382px}.choose-users{min-height:590px}.choose-users+.x{display:none}.messages{padding-left:max(28px,calc((100% - 650px)/2));padding-right:max(28px,calc((100% - 650px)/2))}.composer-area{padding-left:max(28px,calc((100% - 650px)/2));padding-right:max(28px,calc((100% - 650px)/2));background:transparent}.composer{background:#17181d;border-radius:16px;padding:0 6px}.chathead{height:58px;background:#191a20}.page-scroll:has(.profile-edit-ref){padding-top:30px}.page-scroll:has(.group-call-page) .page{max-width:670px}}
@media(max-width:760px){.shell{grid-template-rows:minmax(0,1fr) 57px}.sidebar{padding-top:0;background:#191a20}.sidehead{height:55px;padding:15px 14px 6px}.sidehead h2{font-size:21px}.mobile-nav{height:57px;padding:4px 0 max(4px,env(safe-area-inset-bottom));background:#191a20}.mobile-nav .navbtn{min-height:49px;padding:3px 0;font-size:9px}.mobile-nav .navbtn svg{width:20px;height:20px}.searchbox{margin-left:13px;margin-right:13px}.chat-tabs{gap:23px;padding-left:18px}.chat-item{min-height:73px;padding:8px 14px}.settings-list{padding:0 14px 20px}.settings-profile{padding-top:6px}.settings-list .setting-row{height:50px}.settings-separator{margin:4px 0}.panehead{height:55px;padding:0 13px}.panehead h3{font-size:14px}.page-scroll{padding:19px 7px calc(22px + env(safe-area-inset-bottom))}.page{max-width:none}.notifications-ref,.security-ref,.devices-ref,.folders-page,.appearance-ref,.language-ref,.shortcuts-ref,.about-ref{max-width:none}.profile-edit-ref{padding:0 7px}.profile-bottom-actions{margin-top:70px}.modal{background:#191a20}.modal-head{padding:9px 17px 8px}.modal-body{padding:0 17px 18px}.action-popover .modal-head{display:none}.choose-users{min-height:65dvh}.choose-list{max-height:calc(65dvh - 118px)}.round-note{width:min(54vw,236px);height:min(54vw,236px)}.security-ref .card{border-radius:13px}.privacy-row{min-height:48px}.group-call-page{padding:8px 12px}.appearance-preview{height:390px}.composer{border-radius:18px}.contact-more{opacity:1}.call-row .call-info{margin-left:0}.page-scroll:has(.folder-editor){padding-bottom:10px}.folder-bottom{position:sticky;bottom:0;background:#0f1014;padding:8px 0}.folder-rules-card{max-height:none}}
.pane-edit-call{position:absolute;right:18px;width:38px;height:38px;padding:8px;display:grid;place-items:center}.panehead{position:relative}.edit-call-ref{max-width:670px;margin:0 auto;padding-top:18px}.edit-call-ref>small{display:block;font-size:11px;font-weight:700;color:#a9aab4;margin:0 10px 8px}.edit-call-ref .ref-input input{height:54px}.edit-call-ref .ref-input>span{top:20px}

/* === Reference alignment & mobile stability patch 2026-09-29 === */
html,body,#app{width:100%;height:100%;max-width:100%;overflow:hidden}.sidebar,.main,.messages,.page-scroll,.list{scrollbar-gutter:stable both-edges}.reply{appearance:none;border:0;width:100%;display:block;text-align:left;color:inherit;cursor:pointer}.reply:hover{background:#ffffff10}.message-focus .bubble{animation:messageFocus 1.8s ease}@keyframes messageFocus{0%,100%{box-shadow:0 1px 1px #0002}20%{box-shadow:0 0 0 3px #0a86ff99,0 0 30px #0a86ff55}55%{box-shadow:0 0 0 2px #0a86ff55}}.search-message-result{width:100%;text-align:left}.video-frame{position:relative;display:block;max-width:min(360px,100%);border-radius:14px;overflow:hidden;background:#0d0e12;min-height:120px}.video-frame video{display:block;width:100%;max-width:100%;background:#0d0e12}.video-frame.media-failed:after{content:'Видео не загрузилось';position:absolute;inset:0;display:grid;place-items:center;background:#0d0e12dd;color:#d9d9df;font-size:12px}.media-retry{position:absolute;left:50%;top:58%;transform:translate(-50%,-50%);z-index:3;background:#2c2d35;color:#fff;padding:8px 12px}.message.media-only .video-frame{max-width:min(350px,100%)}#upload-progress{position:fixed;left:50%;bottom:24px;transform:translate(-50%,20px);z-index:200;width:min(340px,calc(100vw - 28px));padding:10px 12px;border-radius:14px;background:#202127eF;box-shadow:0 10px 40px #0008;opacity:0;pointer-events:none;transition:.2s}#upload-progress.show{opacity:1;transform:translate(-50%,0)}#upload-progress>div{height:5px;border-radius:4px;background:#4a4b53;overflow:hidden}#upload-progress span{display:block;height:100%;background:#0a86ff;transition:width .12s linear}#upload-progress b{display:block;text-align:center;font-size:11px;margin-top:6px}.permission-intro>p{color:#c9cad1;line-height:1.45;margin-bottom:10px}.permission-list{display:flex;flex-direction:column}.permission-list>div{display:flex;align-items:center;gap:12px;padding:11px 2px;border-bottom:1px solid #ffffff0d}.permission-list>div:last-child{border-bottom:0}.permission-list svg{width:22px;height:22px;color:#f2f2f5}.permission-list span{display:flex;flex-direction:column;gap:3px}.permission-list small{line-height:1.3}.call-list{padding-bottom:8px}.call-row{position:relative;display:flex;align-items:center;gap:11px;min-height:59px;padding:7px 10px 7px 13px}.call-row:hover,.call-row.selected{background:#2f3038}.call-row>.avatar{width:42px;height:42px;min-width:42px}.call-link-avatar{background:#32bfd3!important;color:#fff}.call-link-avatar svg{width:23px;height:23px}.call-main{display:flex;flex-direction:column;align-items:flex-start;text-align:left;padding:2px 0;border-radius:0;min-width:0}.call-main b{max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:14px}.call-sub{display:flex;align-items:center;gap:4px;margin-top:3px;color:#9c9da7;font-size:12px;white-space:nowrap}.call-sub svg{width:13px;height:13px}.call-row.missed .call-main b{color:#ed466b}.call-stamp{margin-left:auto;color:#8f909a;white-space:nowrap;font-size:11px}.call-actions{display:flex;align-items:center;gap:2px;margin-left:2px;opacity:0;pointer-events:none}.call-row:hover .call-actions{opacity:1;pointer-events:auto}.call-actions button{width:32px;height:32px;padding:6px;border-radius:50%;display:grid;place-items:center}.call-actions svg{width:18px;height:18px}.call-pick{padding:0;width:42px;height:42px;display:grid;place-items:center}.call-select-bar{z-index:4}.rail-count{min-width:17px;height:17px;padding:1px 5px;display:grid;place-items:center;line-height:1}.chat-tabs .tab-count{vertical-align:1px}.messages{contain:layout paint style}.message{contain:layout style}.round-note,.video-frame{content-visibility:auto;contain-intrinsic-size:226px 226px}

@media(min-width:761px){.call-list .call-row{padding-left:13px;padding-right:10px}.call-row .call-actions{width:66px}.call-row:not(:hover) .call-actions{width:0;overflow:hidden;margin-left:0}.sidebar{min-width:0}.main{min-width:0}.messages{overscroll-behavior:contain}}

@media(max-width:760px){
 html,body,#app{width:100vw;max-width:100vw;min-width:0;height:var(--app-height,100dvh);overflow:hidden}
 body{position:fixed;inset:0;overscroll-behavior:none}
 .shell{display:grid!important;grid-template-columns:minmax(0,1fr)!important;grid-template-rows:minmax(0,1fr) calc(57px + env(safe-area-inset-bottom))!important;width:100vw!important;max-width:100vw!important;height:var(--app-height,100dvh)!important;overflow:hidden!important}
 .shell.detail{grid-template-rows:minmax(0,1fr)!important}
 .rail{display:none!important}
 .sidebar{grid-column:1!important;grid-row:1!important;width:100%!important;max-width:100vw!important;min-width:0!important;overflow:hidden!important;border-right:0!important;padding-top:max(env(safe-area-inset-top),0px)!important}
 .main{grid-column:1!important;grid-row:1!important;width:100%!important;max-width:100vw!important;min-width:0!important;overflow:hidden!important;display:none}
 .shell.detail .sidebar{display:none!important}.shell.detail .main{display:flex!important}
 .mobile-nav{grid-column:1!important;grid-row:2!important;display:grid!important;grid-template-columns:repeat(4,minmax(0,1fr));align-items:stretch;justify-content:stretch;width:100%!important;max-width:100vw!important;height:calc(57px + env(safe-area-inset-bottom))!important;padding:2px 0 env(safe-area-inset-bottom)!important;background:#191a20!important;border-top:1px solid #ffffff10!important;z-index:20}
 .shell.detail .mobile-nav{display:none!important}
 .mobile-nav .navbtn{width:100%!important;min-width:0!important;height:55px!important;min-height:55px!important;margin:0!important;padding:4px 0!important;gap:2px!important;font-size:9px!important;border-radius:0!important;justify-content:center}
 .mobile-nav .navbtn.active{background:transparent!important;color:#0785ff!important}.mobile-nav .navbtn svg{width:21px!important;height:21px!important}
 .sidehead{width:100%;min-width:0;height:52px!important;min-height:52px!important;padding:13px 14px 5px!important}.sidehead h2{font-size:20px!important;line-height:28px}.round-btn{width:30px;height:30px}
 .searchbox{width:auto;min-width:0;margin:0 13px 8px!important}.searchbox input{height:35px!important;font-size:13px}.chat-tabs{width:100%;max-width:100%;gap:21px!important;padding:0 18px!important;overflow-x:auto!important;overflow-y:hidden!important;scrollbar-width:none}.chat-tabs::-webkit-scrollbar{display:none}.chat-tabs button{flex:0 0 auto}
 .list{width:100%;min-width:0;overflow-x:hidden!important;overscroll-behavior:contain}.chat-item{width:100%;max-width:100%;min-width:0}.chat-item .grow{min-width:0}.chat-item .name,.chat-item .preview{max-width:100%}
 .contact-row{width:100%;max-width:100%;padding-right:8px}.contact-main{min-width:0}.contact-main .grow{min-width:0}.contact-main b,.contact-main p{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.contact-more{flex:none;opacity:1}
 .panehead{height:54px!important;min-height:54px!important;padding:0 13px!important;padding-top:env(safe-area-inset-top)!important;box-sizing:content-box;background:#191a20;position:relative;z-index:5}.panehead h3{font-size:14px!important;margin-right:36px!important}.panehead>button{width:36px;height:36px;padding:7px}
 .page-scroll{width:100%;max-width:100vw;min-width:0;padding:20px 7px calc(20px + env(safe-area-inset-bottom))!important;overflow-x:hidden!important}.page{width:100%;max-width:none!important;min-width:0}.card{max-width:100%}
 .settings-list{padding-left:14px!important;padding-right:14px!important}.settings-profile{min-width:0}.settings-profile .grow{min-width:0}.settings-profile b,.settings-profile p{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
 .chathead{width:100%;max-width:100vw;min-width:0;height:calc(54px + env(safe-area-inset-top))!important;padding:env(safe-area-inset-top) 8px 0!important;gap:6px!important;background:#191a20!important}.chathead .back{display:grid!important}.chathead .info{min-width:0}.chathead .info b,.chathead .info small{max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.chathead button{flex:none}.chathead button[data-action=menu]{display:none}
 .messages{width:100%;max-width:100vw;min-width:0;padding:10px 8px 14px!important;overflow-x:hidden!important;scroll-padding-top:66px;scroll-padding-bottom:90px}.message{max-width:90%!important;min-width:0}.message .bubble{max-width:100%;min-width:0}.message.media-only{max-width:86%!important}.message.media-only .attachment,.message.media-only .video-frame{max-width:min(82vw,330px)!important}.video-frame{max-width:min(82vw,330px)}.round-note{width:min(54vw,228px)!important;height:min(54vw,228px)!important}
 .composer-area{width:100%;max-width:100vw;padding:6px 7px calc(7px + env(safe-area-inset-bottom))!important;background:#15161bd9!important;backdrop-filter:blur(18px);z-index:6}.composer{width:100%;max-width:100%;min-width:0;padding:0 4px!important;border-radius:18px!important;background:#24252b!important}.composer textarea{min-width:0;flex:1;font-size:16px!important}.composer button{flex:none;padding-left:6px!important;padding-right:6px!important}
 .modal-shade{width:100vw;max-width:100vw;padding:0!important;align-items:flex-end!important;overflow:hidden}.modal{width:100%!important;max-width:100vw!important;max-height:min(88dvh,calc(var(--app-height,100dvh) - 12px))!important;border-radius:22px 22px 0 0!important}.modal-body{overflow-x:hidden}.action-popover .modal{max-width:100vw!important}
 .call-list{padding-bottom:2px}.call-row{min-height:56px;padding:5px 10px 5px 12px;gap:9px}.call-row>.avatar,.call-pick{width:40px;height:40px;min-width:40px}.call-main b{font-size:14px}.call-sub{font-size:12px}.call-stamp{font-size:10px}.call-actions{opacity:1;pointer-events:auto;gap:0}.call-actions button:first-child{display:none}.call-actions button{width:31px;height:31px}.call-row:hover{background:transparent}.call-row.selected,.call-row:active{background:#343541}.sidebar>.group-call-create{margin:0 13px 2px!important;width:calc(100% - 26px)!important;padding:6px 8px!important;min-height:39px}.call-tabs{padding-left:18px!important}.call-select-bar{position:absolute;left:0;right:0;bottom:0;padding-bottom:calc(8px + env(safe-area-inset-bottom));background:#191a20ee;backdrop-filter:blur(12px)}
 .profile-bottom-actions{margin-top:68px!important}.appearance-preview{max-width:100%}.folder-editor,.group-call-page,.edit-call-ref{width:100%;max-width:100%!important}.folder-bottom{bottom:0!important}
 #upload-progress{bottom:calc(70px + env(safe-area-inset-bottom))}.shell.detail~#upload-progress,#upload-progress{max-width:calc(100vw - 24px)}
}

/* Desktop reference geometry */
@media(min-width:761px){
 .shell{grid-template-columns:70px 354px minmax(0,1fr)}
 .rail{padding-left:3px;padding-right:3px}
 .sidebar .sidehead{padding-left:14px;padding-right:14px}
 .sidebar .searchbox{margin-left:14px;margin-right:14px}
 .call-tabs{padding-left:18px}
}

/* NOVO 3.2 mobile/media/permissions hardening */
.typing-preview{color:#9fa0aa!important;font-style:normal}.typing-preview::first-letter{color:#9fa0aa}.permission-card{margin-bottom:14px}.permission-center{padding:0!important;overflow:hidden}.permission-row{width:100%;min-height:58px;display:flex;align-items:center;gap:12px;padding:10px 14px;border-bottom:1px solid #ffffff0d;text-align:left}.permission-row:last-child{border-bottom:0}.permission-row>svg{width:22px;height:22px}.permission-row small{display:block;color:#9697a1;margin-top:3px}.permissions-ref>.full{margin-top:12px}.media-failed .media-retry{display:block!important}.round-note.media-failed::after{content:'Не удалось загрузить видео';position:absolute;inset:0;display:grid;place-items:center;text-align:center;padding:28px;background:#0c0d11e8;color:#d7d7dd;z-index:2}.round-note.media-failed .round-toggle{z-index:4}.gallery video{background:#090a0d;object-fit:cover}.gallery img,.gallery video{aspect-ratio:1/1;width:100%;min-width:0;max-width:100%;border-radius:8px}.gallery{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:4px}.voice-player audio{display:none}
@media(max-width:760px){
 html{-webkit-text-size-adjust:100%;text-size-adjust:100%;touch-action:manipulation}
 body{font-size:15px!important}
 input,textarea,select,.auth-stage input,.auth-stage textarea,.searchbox input,.composer textarea{font-size:16px!important}
 .auth,.auth-card,.auth-stage{width:100%!important;max-width:100vw!important;min-width:0!important;overflow-x:hidden!important}
 .auth{height:var(--app-height,100dvh)!important;min-height:var(--app-height,100dvh)!important}
 .auth-card{min-height:var(--app-height,100dvh)!important;height:var(--app-height,100dvh)!important;overflow-y:auto!important;overscroll-behavior-y:contain}
 .auth-stage{padding-left:20px!important;padding-right:20px!important;padding-bottom:calc(28px + env(safe-area-inset-bottom))!important}
 .auth-stage .field,.auth-stage input,.auth-stage button{max-width:100%!important;box-sizing:border-box}
 .auth-stage .brand-icon{max-width:96px}.auth-stage h1.brand{font-size:52px!important;letter-spacing:.1em}
 .shell,.sidebar,.main{transform:none!important;zoom:1!important}
 .keyboard-open .mobile-nav{display:none!important}.keyboard-open .shell{grid-template-rows:minmax(0,1fr)!important}.keyboard-open .composer-area{padding-bottom:6px!important}
 .keyboard-open .auth-card{height:var(--app-height,100dvh)!important;min-height:var(--app-height,100dvh)!important}
 .messages{overscroll-behavior-y:contain;-webkit-overflow-scrolling:touch}
 .round-note{max-width:236px!important;max-height:236px!important;min-width:180px;min-height:180px}
 .gallery{grid-template-columns:repeat(3,minmax(0,1fr));gap:3px}.gallery img,.gallery video{border-radius:5px}
 .profile-header .actions{display:grid!important;grid-template-columns:repeat(5,minmax(0,1fr));gap:7px!important;width:100%!important}.profile-header .actions button{min-width:0!important;padding:12px 4px!important;font-size:12px!important}
 .permission-row{min-height:62px;padding:11px 13px}.permission-card>p{line-height:1.45}
}
.avatar.online{position:relative;overflow:visible!important}.avatar.online::after{content:'';position:absolute;right:-1px;bottom:1px;width:10px;height:10px;border-radius:50%;background:#2acb66;border:2px solid #191a20;box-sizing:border-box}.chathead .avatar.online::after{right:0;bottom:0}.typing-preview{font-weight:500}

/* NOVO 3.2.1 — saved messages, presence, blocked profiles and call video fixes */
.saved-avatar{background:#0785ff!important;color:#fff!important}.saved-avatar svg{width:23px!important;height:23px!important;fill:#fff;stroke:#fff}.saved-chathead .saved-avatar{box-shadow:none}.saved-info-card{padding:0!important;overflow:hidden;max-width:650px;margin:0 auto}.saved-info-tabs{padding:0 20px!important;margin:0!important;border-bottom:1px solid #ffffff0d!important;gap:30px!important}.saved-info-tabs button{font-weight:650;padding:16px 0!important}.saved-info-card #saved-info-content{min-height:88px;padding:18px 20px}.saved-gallery{grid-template-columns:repeat(3,minmax(0,1fr))}.saved-gallery img,.saved-gallery video{width:100%;height:150px;object-fit:cover;border-radius:8px;background:#090a0d}.saved-locked{min-height:96px;width:100%;display:flex;align-items:center;justify-content:center;gap:8px;background:#1d1e24;border-radius:10px;color:#b8b9c3}.saved-link{padding:11px 0;border-bottom:1px solid #ffffff0d;overflow-wrap:anywhere}.saved-link:last-child{border-bottom:0}
.blocked-thread{display:grid!important;place-items:center!important;background:var(--bg)!important;padding:24px!important}.blocked-profile-card{width:min(330px,calc(100vw - 40px));text-align:center;padding:28px 24px;border:1px solid #ffffff14;border-radius:18px;background:linear-gradient(180deg,#1d1e23,#17181c);box-shadow:0 18px 55px #0005}.blocked-profile-card .blocked-warning{width:36px;height:36px;border-radius:50%;display:grid;place-items:center;margin:0 auto 12px;background:#ffc400;color:#141414;font-weight:900;font-size:23px}.blocked-profile-card h3{font-size:18px;margin-bottom:7px}.blocked-profile-card p{color:#b5b5bd;line-height:1.35}
.phonebook-result{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin-bottom:14px}.phonebook-stat{padding:14px;background:#272830;border-radius:13px;text-align:center}.phonebook-stat b{display:block;font-size:25px;color:#0a86ff}.phonebook-stat span{display:block;margin-top:3px;color:#a5a6b0;font-size:11px}.phonebook-found{max-height:270px;overflow:auto;border-top:1px solid #ffffff0d;border-bottom:1px solid #ffffff0d;margin:2px 0 12px}.phonebook-found .contact-main{width:100%;padding:8px 2px;text-align:left}.phonebook-found small{display:block;color:#92939d;margin-top:2px}
.call-screen .remote-videos{pointer-events:auto;grid-template-columns:minmax(0,1fr);align-items:center;justify-items:center}.call-screen .remote-tile{width:min(100%,1000px);height:100%;max-height:100%;border-radius:20px;overflow:hidden;background:transparent}.call-screen .remote-tile.has-video{background:#000;box-shadow:0 0 0 1px #ffffff0d}.call-screen .remote-tile video{display:block;width:100%;height:100%;object-fit:contain;background:#000;border-radius:20px}.peer-placeholder{width:min(360px,80%);height:min(360px,80%);display:flex;flex-direction:column;align-items:center;justify-content:center;gap:8px;text-align:center;color:#f3f3f6}.peer-placeholder .peer-avatar{width:min(210px,55%);aspect-ratio:1;border-radius:50%;display:grid;place-items:center;overflow:hidden;background:#343844;border:1px solid #ffffff18;font-size:54px;box-shadow:0 0 58px #4a50a54f}.peer-placeholder .peer-avatar img{display:block;width:100%;height:100%;object-fit:cover;object-position:center center;transform:scale(1.05)}.peer-placeholder b{font-size:18px}.peer-placeholder small{font-size:12px;color:#a7a8b2}.call-screen.has-remote-video .call-title,.call-screen.has-remote-video #call-status{z-index:5;text-shadow:0 1px 12px #000;background:#0b0c10a6;backdrop-filter:blur(8px);width:max-content;max-width:60vw;left:50%;right:auto;transform:translateX(-50%);padding:4px 10px;border-radius:10px}.call-screen.has-remote-video .call-title{top:20px}.call-screen.has-remote-video #call-status{top:58px}.call-screen .local-video{z-index:6;object-fit:cover;background:#22252c}.incoming-actions{z-index:4;align-items:flex-start}.incoming-action{position:relative!important;isolation:isolate;width:106px!important;height:122px!important;padding:0!important;gap:0!important;justify-content:flex-start!important;background:transparent!important}.incoming-action:before{top:0!important;left:50%!important;transform:translateX(-50%)!important;margin:0!important;z-index:-1!important}.incoming-action .i{margin-top:26px!important}.incoming-action span{display:block;width:120px;max-width:120px;margin-top:35px;line-height:1.15;text-align:center;white-space:nowrap;font-size:15px;color:#f3f3f6}.incoming-action.answer .i{transform:rotate(-20deg)}.incoming-action.decline .i{transform:rotate(135deg)}

@media(max-width:760px){
 .saved-info-card{border-radius:14px;margin:0}.saved-info-tabs{gap:24px!important;padding:0 13px!important}.saved-info-card #saved-info-content{padding:14px 12px}.saved-gallery img,.saved-gallery video{height:auto;aspect-ratio:1}.phonebook-result{grid-template-columns:1fr 1fr}.blocked-thread{padding:16px!important}
 .call-screen .remote-videos{inset:102px 8px 112px!important}.call-screen .remote-tile{width:100%;height:100%;border-radius:15px}.call-screen .remote-tile video{border-radius:15px}.call-screen.has-remote-video .call-title{top:calc(20px + env(safe-area-inset-top))!important;font-size:15px!important;max-width:48vw}.call-screen.has-remote-video #call-status{top:calc(49px + env(safe-area-inset-top))!important;font-size:11px!important;max-width:48vw}.peer-placeholder{width:88%;height:78%}.peer-placeholder .peer-avatar{width:min(54vw,240px);font-size:42px}.peer-placeholder b{font-size:17px}
 .incoming-actions{bottom:calc(44px + env(safe-area-inset-bottom))!important;gap:58px!important}.incoming-action{width:102px!important;height:118px!important}.incoming-action:before{width:82px!important;height:82px!important}.incoming-action .i{margin-top:23px!important}.incoming-action span{margin-top:33px!important;font-size:14px!important;width:108px;max-width:108px}
}

/* NOVO 3.2.2 — reference call layout + official NOVO service channel */
.system-avatar{background:transparent!important;box-shadow:none!important;overflow:hidden!important}.system-avatar img{width:100%!important;height:100%!important;object-fit:cover!important;border-radius:50%}.verified-badge{display:inline-grid;place-items:center;width:15px;height:15px;min-width:15px;border-radius:50%;background:#1688ff;color:#fff;font-size:10px;font-weight:900;line-height:1;margin-left:5px;vertical-align:1px}.chat-item .name,.system-chathead .info b,.official-profile h2{display:flex;align-items:center;min-width:0}.chat-item .name .verified-badge{width:14px;height:14px;min-width:14px;font-size:9px}.system-chathead .info b{gap:1px}.channel-readonly{min-height:42px;display:grid;place-items:center;background:#191a20;border-radius:18px;padding:8px 14px}.official-profile .system-avatar.big{width:92px;height:92px;margin:10px auto 14px}.official-profile h2{justify-content:center;font-size:22px;margin-top:2px}.official-handle{color:#1688ff;margin-top:4px}.official-profile>.muted{margin-top:4px}.official-actions{grid-template-columns:repeat(3,minmax(0,1fr))!important;max-width:580px;margin:22px auto 20px!important}.official-link-card,.official-media-card{max-width:650px;margin-left:auto;margin-right:auto}.official-link-card .copy-phone{font-size:14px}.official-media-card{padding:10px 18px 18px}.official-media-card>.tabs{padding:0 4px;margin-bottom:14px}.official-gallery{grid-template-columns:repeat(3,minmax(0,1fr))}.official-gallery img,.official-gallery video{width:100%;height:150px;object-fit:cover;border-radius:8px;background:#090a0d}

.call-screen.active-call-screen{overflow:hidden;background:#0d0f12}.call-screen.active-call-screen .call-ambient{background:radial-gradient(circle at 50% 46%,#173d5a42 0,transparent 34%),radial-gradient(circle at 50% 50%,#1e24375a 0,transparent 56%)}.call-screen.active-call-screen .call-top{z-index:20;top:16px!important;left:18px!important;right:18px!important}.call-screen.active-call-screen .call-top button{width:48px;height:48px!important;background:#484b58!important}.call-screen.active-call-screen .call-title{z-index:14;top:15px!important;left:120px!important;right:120px!important;transform:none!important;background:transparent!important;backdrop-filter:none!important;text-shadow:none!important;padding:0!important;max-width:none!important;width:auto!important;font-size:26px!important;line-height:30px;font-weight:760}.call-screen.active-call-screen #call-status{z-index:14;top:47px!important;left:120px!important;right:120px!important;transform:none!important;background:transparent!important;backdrop-filter:none!important;text-shadow:none!important;padding:0!important;max-width:none!important;width:auto!important;font-size:14px!important;line-height:18px;color:#a6a8b3}.call-screen.active-call-screen .call-avatar{position:absolute;z-index:3;left:50%;top:50%;transform:translate(-50%,-50%);margin:0!important;width:min(33vw,390px)!important;height:min(33vw,390px)!important;max-width:390px!important;max-height:390px!important;min-width:180px!important;min-height:180px!important;border-radius:50%;background:#343844!important;box-shadow:0 0 90px #3c5f9a50!important}.call-screen.active-call-screen .remote-videos{position:absolute!important;z-index:2!important;inset:68px 14px 72px!important;display:grid!important;grid-template-columns:minmax(0,1fr)!important;place-items:stretch!important;gap:10px!important;pointer-events:auto!important}.call-screen.active-call-screen .remote-videos.many{grid-template-columns:repeat(2,minmax(0,1fr))!important;grid-auto-rows:minmax(0,1fr)!important}.call-screen.active-call-screen .remote-tile{position:relative!important;width:100%!important;height:100%!important;max-width:none!important;max-height:none!important;border-radius:18px!important;overflow:hidden!important;background:#25262a!important;box-shadow:inset 0 0 0 1px #ffffff0c!important}.call-screen.active-call-screen .remote-tile video{position:absolute;inset:0;width:100%!important;height:100%!important;border-radius:18px!important;object-fit:contain!important;background:#25262a!important}.call-screen.active-call-screen .remote-tile:not(.has-video) video{opacity:0}.call-screen.active-call-screen .remote-tile.has-video video{opacity:1}.peer-placeholder{position:absolute;inset:0;width:100%!important;height:100%!important;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:10px;text-align:center;background:radial-gradient(circle at 50% 48%,#1d2c474a,transparent 40%)}.peer-placeholder[hidden]{display:none!important}.peer-placeholder .peer-avatar{width:min(28vw,310px)!important;height:min(28vw,310px)!important;max-width:310px!important;max-height:310px!important;border-radius:50%;background:#343844;box-shadow:0 0 72px #384d8355;font-size:58px}.peer-placeholder b{font-size:22px}.peer-placeholder small{font-size:13px}.self-preview{position:absolute;z-index:18;right:20px;top:76px;width:218px;height:168px;border-radius:22px;overflow:hidden;background:#24262c;border:2px solid #25d366;box-shadow:0 8px 32px #0007}.self-preview[hidden]{display:none!important}.self-preview .local-video{position:absolute!important;inset:0!important;display:block!important;width:100%!important;height:100%!important;max-height:none!important;border:0!important;border-radius:20px!important;object-fit:cover!important;background:#24262c!important}.self-preview .self-flip{position:absolute;left:10px;top:10px;z-index:2;width:34px;height:34px;border-radius:50%;display:grid;place-items:center;background:#343742d6;color:#fff;backdrop-filter:blur(10px);box-shadow:0 6px 20px #0005}.self-preview .self-flip[hidden]{display:none!important}.self-preview .self-flip .i{width:18px;height:18px}.self-preview .self-label{position:absolute;left:10px;bottom:9px;display:flex;align-items:flex-end;gap:3px;padding:3px 7px;border-radius:10px;background:#050608b8;color:#fff;font-size:12px;font-weight:750}.self-preview .self-label i{display:block;width:2px;border-radius:2px;background:#22d762;animation:selfBars 1.1s ease-in-out infinite}.self-preview .self-label i:nth-child(1){height:6px;animation-delay:0s}.self-preview .self-label i:nth-child(2){height:10px;animation-delay:.16s}.self-preview .self-label i:nth-child(3){height:8px;animation-delay:.32s}@keyframes selfBars{0%,100%{opacity:.35;transform:scaleY(.72)}50%{opacity:1;transform:scaleY(1)}}.call-screen.active-call-screen .call-controls{z-index:20!important;bottom:16px!important;padding:8px!important;gap:8px!important;background:#282a30!important;border-radius:40px!important}.call-screen.active-call-screen .call-controls button{width:56px!important;height:56px!important;border-radius:50%!important;background:#4b4f5f!important}.call-screen.active-call-screen .call-controls button.off{background:#fff!important;color:#24262b!important}.call-screen.active-call-screen .call-controls .red{background:#cf4c62!important}.call-screen.active-call-screen .audio-unlock{z-index:22}.call-screen.active-call-screen.has-peer .call-avatar{display:none!important}

@media(max-width:760px){
 .official-profile .system-avatar.big{width:88px;height:88px}.official-actions{grid-template-columns:repeat(3,minmax(0,1fr))!important;gap:7px!important}.official-link-card,.official-media-card{margin-left:0;margin-right:0}.official-media-card{padding:8px 12px 14px}.official-media-card>.tabs{gap:22px!important;overflow:auto}.official-gallery img,.official-gallery video{height:auto;aspect-ratio:1}
 .call-screen.active-call-screen .call-top{top:calc(10px + env(safe-area-inset-top))!important;left:12px!important;right:12px!important}.call-screen.active-call-screen .call-top button{width:44px!important;height:44px!important}.call-screen.active-call-screen .call-title{top:calc(10px + env(safe-area-inset-top))!important;left:66px!important;right:66px!important;font-size:17px!important;line-height:21px!important}.call-screen.active-call-screen #call-status{top:calc(31px + env(safe-area-inset-top))!important;left:66px!important;right:66px!important;font-size:12px!important;line-height:16px!important}.call-screen.active-call-screen .remote-videos{inset:calc(56px + env(safe-area-inset-top)) 6px calc(94px + env(safe-area-inset-bottom))!important;gap:5px!important}.call-screen.active-call-screen .remote-videos.many{grid-template-columns:1fr!important;grid-template-rows:repeat(2,minmax(0,1fr))!important}.call-screen.active-call-screen .remote-tile,.call-screen.active-call-screen .remote-tile video{border-radius:14px!important}.call-screen.active-call-screen .remote-tile video{object-fit:cover!important}.peer-placeholder .peer-avatar{width:min(66vw,290px)!important;height:min(66vw,290px)!important}.peer-placeholder b{font-size:18px}.peer-placeholder small{font-size:12px}.self-preview{top:calc(58px + env(safe-area-inset-top));right:10px;width:116px;height:154px;border-radius:18px}.self-preview .local-video{border-radius:16px!important}.self-preview .self-flip{left:7px;top:7px;width:30px;height:30px}.self-preview .self-label{left:7px;bottom:7px;font-size:11px;padding:3px 6px}.call-screen.active-call-screen .call-avatar{width:min(70vw,330px)!important;height:min(70vw,330px)!important;min-width:190px!important;min-height:190px!important}.call-screen.active-call-screen .call-controls{bottom:calc(14px + env(safe-area-inset-bottom))!important;padding:7px!important;gap:7px!important}.call-screen.active-call-screen .call-controls button{width:58px!important;height:58px!important}.call-screen.active-call-screen #share-screen{display:none!important}
}

/* 3.2.4 — channel creation flow matching the reference screens */
.channel-create-page{max-width:620px;margin:0 auto;min-height:calc(100dvh - 120px);display:flex;flex-direction:column;align-items:stretch;padding:8px 8px 0}.channel-create-intro{text-align:center;margin:12px 0 18px}.channel-create-intro h2{font-size:22px;margin-bottom:8px}.channel-avatar-pick{width:76px;height:76px;border-radius:50%;background:var(--card);margin:0 auto 20px;position:relative;display:grid;place-items:center;color:var(--muted);overflow:hidden}.channel-avatar-pick img{width:100%;height:100%;object-fit:cover}.channel-avatar-pick>span{position:absolute;right:11px;bottom:9px;background:var(--card);font-size:19px;line-height:16px}.ref-input,.ref-textarea{position:relative;display:block;margin:0 0 14px}.ref-input input,.ref-textarea textarea{background:var(--card);border-radius:12px;border:1px solid transparent}.ref-input>span,.ref-textarea>span{position:absolute;right:13px;bottom:10px;color:var(--muted);font-size:11px;pointer-events:none}.ref-textarea textarea{min-height:96px;padding-bottom:28px}.channel-create-bottom{margin-top:auto;display:flex;gap:10px;padding:22px 0 6px}.channel-create-bottom>button{flex:1;min-height:48px;font-weight:600}.channel-created-mark{text-align:center;font-size:42px;margin-top:8px}.channel-access-page>h2{text-align:center;margin-top:4px}.channel-access-page>.muted{margin:7px 0 18px}.channel-access-card,.channel-share-card{padding:10px 12px}.channel-choice{width:100%;display:flex;align-items:center;gap:12px;text-align:left;padding:11px 6px;border-radius:9px}.channel-choice.active{background:#ffffff05}.channel-choice>span:last-child{display:flex;flex-direction:column;gap:3px}.channel-choice small{color:var(--muted);font-size:12px}.choice-ring{width:18px;height:18px;border:2px solid #5b5a64;border-radius:50%;display:inline-block;flex:0 0 18px}.choice-ring.on{border:5px solid var(--blue)}.channel-slug-wrap{display:flex;align-items:center;background:var(--input);border-radius:10px;padding-left:12px;color:var(--muted);overflow:hidden}.channel-slug-wrap input{border:0;background:transparent;padding-left:2px}.channel-invite-row{border-top:1px solid var(--line);margin-top:12px;padding-top:8px}.channel-invite-row .copy-phone{width:100%;display:flex;align-items:center;text-align:left}.channel-share-card .setting-row:last-child{border-bottom:0}
@media(max-width:760px){.channel-create-page{min-height:calc(100dvh - 108px);padding:4px 0 0}.channel-create-intro{margin-top:4px}.channel-create-intro h2{font-size:20px}.channel-create-bottom{position:sticky;bottom:0;background:var(--bg);padding:12px 0 max(8px,env(safe-area-inset-bottom))}.channel-create-bottom>button{min-height:50px}.channel-access-card,.channel-share-card{border-radius:13px}.channel-slug-wrap span{font-size:12px}.channel-avatar-pick{width:72px;height:72px}}

/* === NOVO Control + mobile auth stability 3.2.5 === */
.rail .admin-control-nav{margin-top:auto;color:#9ea0aa}.rail .admin-control-nav:hover,.rail .admin-control-nav.active{color:#fff;background:#262833}.rail .admin-control-nav .rail-glyph{width:25px;height:25px}.admin-settings-entry{color:#dfe8ff}.admin-settings-entry svg{color:#3196ff}.page.admin-page{width:100%;max-width:1180px}.admin-scroll{padding:20px 24px 34px}.admin-shell{width:100%;max-width:1180px;grid-template-columns:210px minmax(0,1fr);gap:20px;align-items:start}.admin-tabs{top:0;background:#111217;border:1px solid #ffffff0b;border-radius:16px;padding:8px}.admin-tabs button{border-radius:10px;min-height:43px;font-weight:600}.admin-tabs button.active{background:#30313a;color:#fff;box-shadow:inset 3px 0 0 #0a86ff}.admin-work{min-width:0}.admin-head{min-height:58px;display:flex;align-items:center;justify-content:space-between;gap:14px;margin-bottom:14px;padding:10px 12px 10px 16px;background:#191a20;border:1px solid #ffffff0b;border-radius:16px}.admin-head>div{display:flex;flex-direction:column;gap:3px;min-width:0}.admin-head b{font-size:14px}.admin-head small{color:#8f919b;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.admin-head button{display:flex;align-items:center;gap:7px;min-height:38px}.admin-head button svg{width:17px;height:17px}.admin-body{gap:14px}.admin-hero{display:flex;align-items:center;justify-content:space-between;gap:22px;padding:21px 23px;border-radius:18px;background:linear-gradient(125deg,#202533,#202027 56%,#152944);border:1px solid #ffffff12}.admin-hero small{font-size:10px;letter-spacing:1.4px;color:#6eb4ff}.admin-hero h2{font-size:23px;margin:5px 0 6px}.admin-hero p{color:#a9abb5;line-height:1.4}.admin-live{display:flex;align-items:center;gap:7px;white-space:nowrap;color:#a9e8bd;background:#163024;padding:8px 11px;border-radius:999px;font-size:11px}.admin-live i{width:8px;height:8px;border-radius:50%;background:#43d678;box-shadow:0 0 0 4px #43d6781f}.admin-grid-main{grid-template-columns:repeat(4,minmax(0,1fr))}.admin-grid .metric{min-height:94px;text-align:left;justify-content:center;transition:.15s transform,.15s border-color}.admin-grid button.metric:hover{transform:translateY(-1px);border-color:#ffffff25;background:#2b2c34}.admin-grid .metric strong{font-size:25px;line-height:1.1}.admin-dashboard-columns{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px}.admin-stat-card{margin:0}.admin-stat-card h3,.admin-section-title h3{font-size:15px;margin-bottom:11px}.admin-kv{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:1px;background:#ffffff0b;border:1px solid #ffffff0b;border-radius:12px;overflow:hidden}.admin-kv span{background:#24252c;padding:10px 12px;display:flex;align-items:center;justify-content:space-between;gap:12px;color:#9b9da7;font-size:11px}.admin-kv b{color:#f2f2f5;font-size:12px;white-space:nowrap}.admin-quick{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px}.admin-quick button{display:flex;align-items:center;justify-content:center;gap:8px;min-height:48px;background:#24252c;border:1px solid #ffffff0d;font-weight:650}.admin-quick svg{width:18px;height:18px;color:#3b9cff}.admin-toolbar{position:relative;justify-content:space-between;margin-bottom:2px}.admin-toolbar.sticky{position:sticky;top:-1px;z-index:5;backdrop-filter:blur(16px);background:#1c1d23ef}.admin-toolbar-grow{display:grid;grid-template-columns:minmax(220px,1fr) 190px;gap:10px;flex:1;min-width:0}.admin-toolbar .primary{display:flex;align-items:center;gap:6px;white-space:nowrap}.admin-toolbar .primary svg{width:17px;height:17px}.admin-list-caption{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:0 4px;color:#858792;font-size:10px}.admin-row{min-height:70px;border-radius:13px;background:#23242b;border-color:#ffffff0c}.admin-row:hover{border-color:#ffffff19}.admin-row-title{display:flex;align-items:center;gap:6px;flex-wrap:wrap}.admin-row-title b{font-size:13px}.admin-row-actions{display:flex;align-items:center;gap:6px;flex-shrink:0}.admin-row-actions button{white-space:nowrap}.admin-user-row .avatar{width:42px;height:42px;min-width:42px}.admin-user-avatar{flex:0 0 auto}.admin-chip{display:inline-flex;align-items:center;min-height:20px;padding:2px 7px;border-radius:999px;background:#393a43;color:#bfc0c8;font-size:9px;font-weight:700}.admin-chip.blue{background:#0a86ff24;color:#70b7ff}.admin-chip.amber{background:#e69d2b24;color:#f2bd62}.admin-chip.red{background:#e3486824;color:#ff7890}.admin-section-title{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-top:4px;padding:0 4px}.admin-section-title p{margin-top:3px}.admin-user-head{display:flex;align-items:center;gap:12px;background:#24252c;border-radius:14px;padding:12px;margin-bottom:12px}.admin-user-head .avatar{width:50px;height:50px;min-width:50px}.admin-user-head>div{min-width:0}.admin-user-head p{margin:3px 0 6px}.admin-flags{background:#24252c;border-radius:12px;padding:3px 7px}.admin-flags .check-row{min-height:42px;border-bottom:1px solid #ffffff0b}.admin-flags .check-row:last-child{border-bottom:0}.admin-danger-zone{display:flex;gap:8px;margin-top:12px;padding-top:12px;border-top:1px solid #ffffff10}.admin-danger-zone button{flex:1;background:#25262d}.admin-danger-zone .danger{background:#3b2029}.admin-form-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:0 12px}.admin-form-grid .field{margin:8px 0}.admin-span{grid-column:1/-1}.audit-row details{margin:8px 0}.audit-row summary{cursor:pointer;color:#78baff;font-size:11px}.audit-row pre{margin:8px 0 0;padding:9px;background:#17181d;border-radius:8px;overflow:auto}.auth-steps span.on{background:var(--blue)}

@media(max-width:1000px) and (min-width:761px){.page.admin-page{max-width:100%}.admin-shell{grid-template-columns:176px minmax(0,1fr)}.admin-grid-main{grid-template-columns:repeat(2,minmax(0,1fr))}.admin-quick{grid-template-columns:repeat(2,minmax(0,1fr))}.admin-dashboard-columns{grid-template-columns:1fr}.admin-toolbar-grow{grid-template-columns:1fr 160px}}

@media(max-width:760px){
 .auth-v3{position:fixed;inset:0;width:100%;height:var(--app-height,100dvh);min-height:0;overflow-y:auto;overflow-x:hidden;display:block;padding:0;overscroll-behavior:contain;-webkit-overflow-scrolling:touch;scroll-padding-top:18px;scroll-padding-bottom:28px}
 .auth-v3 .auth-pattern{position:fixed;inset:0;height:100dvh}
 .auth-v3 .auth-card{width:100%;min-height:var(--app-height,100dvh);height:auto;border:0;border-radius:0;box-shadow:none;background:#101114;overflow:visible}
 .auth-v3 .auth-top{height:58px;padding:calc(10px + env(safe-area-inset-top)) 14px 8px;position:relative;z-index:3}
 .auth-v3 .auth-stage{min-height:calc(var(--app-height,100dvh) - 58px);padding:clamp(26px,8vh,76px) 22px calc(30px + env(safe-area-inset-bottom));display:flex;flex-direction:column;justify-content:flex-start;overflow:visible}
 .auth-v3 .auth-stage .brand-icon{width:70px;height:70px;flex:none;align-self:center}.auth-v3 .auth-stage .brand{font-size:34px;margin:7px 0 28px}.auth-v3 .auth-stage h2{font-size:27px}.auth-v3 .auth-stage>.muted{font-size:15px;line-height:1.45;margin-bottom:24px}
 .auth-v3 input,.auth-v3 textarea,.auth-v3 select{font-size:16px!important;line-height:1.25;min-height:48px}.auth-v3 .field>span{font-size:13px}.auth-v3 .auth-main,.auth-v3 .yandex-id-btn{min-height:50px}.auth-v3 .auth-back{top:-43px}
 body.keyboard-open .auth-v3{height:var(--app-height,100dvh)}body.keyboard-open .auth-v3 .auth-card{min-height:var(--app-height,100dvh)}body.keyboard-open .auth-v3 .auth-top{height:44px;padding-top:max(6px,env(safe-area-inset-top))}body.keyboard-open .auth-v3 .auth-stage{min-height:auto;padding-top:10px;padding-bottom:20px;justify-content:flex-start}body.keyboard-open .auth-v3 .auth-stage .brand-icon{width:44px;height:44px}body.keyboard-open .auth-v3 .auth-stage .brand{font-size:24px;letter-spacing:2px;margin:3px 0 8px}body.keyboard-open .auth-v3 .auth-steps{margin:7px 0 10px}body.keyboard-open .auth-v3 .auth-stage h2{font-size:23px;margin-bottom:5px}body.keyboard-open .auth-v3 .auth-stage>.muted{font-size:13px;margin-bottom:10px;line-height:1.35}body.keyboard-open .auth-v3 .field{margin:8px 0}body.keyboard-open .auth-v3 .stack{gap:7px}body.keyboard-open .auth-v3 .auth-back{top:-38px}
 .page.admin-page{max-width:none;width:100%}.admin-scroll{padding:10px 8px calc(18px + env(safe-area-inset-bottom))}.admin-shell{display:flex;flex-direction:column;gap:9px}.admin-tabs{position:sticky;top:-10px;z-index:8;display:flex;flex-direction:row;overflow-x:auto;overflow-y:hidden;width:100%;border-radius:12px;padding:6px;background:#17181eee;backdrop-filter:blur(16px);scrollbar-width:none}.admin-tabs::-webkit-scrollbar{display:none}.admin-tabs button{flex:0 0 auto;min-height:37px;padding:8px 11px;font-size:11px}.admin-tabs button.active{box-shadow:inset 0 -2px 0 #0a86ff}.admin-head{min-height:50px;margin:0;padding:8px 10px;border-radius:12px}.admin-head small{display:none}.admin-head button{padding:8px}.admin-head button span{display:none}.admin-body{gap:9px}.admin-hero{padding:16px;align-items:flex-start}.admin-hero h2{font-size:19px}.admin-hero p{font-size:12px}.admin-live{display:none}.admin-grid,.admin-grid-main{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}.admin-grid .metric{min-height:80px;padding:13px}.admin-grid .metric strong{font-size:20px}.admin-dashboard-columns{grid-template-columns:1fr;gap:9px}.admin-kv{grid-template-columns:1fr}.admin-kv span{padding:9px 10px}.admin-quick{grid-template-columns:repeat(2,minmax(0,1fr));gap:7px}.admin-quick button{font-size:11px}.admin-toolbar{position:sticky;top:49px;z-index:7;align-items:stretch;flex-direction:column;padding:8px}.admin-toolbar-grow{grid-template-columns:1fr;gap:7px}.admin-toolbar .primary{justify-content:center}.admin-list-caption{font-size:9px}.admin-list-caption span:last-child{display:none}.admin-row{padding:10px;min-height:65px}.admin-user-row{display:grid;grid-template-columns:42px minmax(0,1fr);align-items:start}.admin-user-row>button{grid-column:2;width:100%;margin-top:5px}.admin-row-actions{width:100%;justify-content:flex-end}.admin-row-actions button{flex:1}.admin-form-grid{grid-template-columns:1fr}.admin-span{grid-column:auto}.admin-danger-zone{flex-direction:column}.admin-user-head{align-items:flex-start}.admin-user-head .avatar{width:44px;height:44px;min-width:44px}
}

/* 3.3: touch targets, keyboard-safe sheets and responsive control panel */
.chat-item,.message{ -webkit-tap-highlight-color:transparent; }
.edge-back-ready::after{content:'‹';position:fixed;left:8px;top:46%;z-index:9999;background:var(--accent,#0785ff);color:white;border-radius:50%;width:42px;height:42px;display:grid;place-items:center;font-size:34px;pointer-events:none}
.admin-head{flex-wrap:wrap;gap:10px}.admin-body{min-width:0}.admin-row .grow{min-width:0;overflow-wrap:anywhere}.admin-body pre{white-space:pre-wrap;overflow-wrap:anywhere}.admin-tabs{overscroll-behavior:contain}
@media(max-width:760px){
 .modal-shade.message-actions,.modal-shade.action-popover{align-items:flex-end;padding:0}
 .message-actions .modal,.action-popover .modal{width:100%;max-width:100%;border-radius:24px 24px 0 0;max-height:85dvh;padding-bottom:env(safe-area-inset-bottom,0px)}
 .menu-item{min-height:48px}.quick-reaction{min-height:44px;min-width:36px}
 .admin-shell{display:flex!important;flex-direction:column!important;min-width:0}.admin-tabs{display:flex!important;flex-direction:row!important;overflow-x:auto;flex-wrap:nowrap;max-width:100%;padding:6px;gap:4px}.admin-tabs button{flex:0 0 auto;min-height:44px}
 .admin-dashboard-columns,.admin-form-grid,.admin-grid-main{grid-template-columns:1fr!important}.admin-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.admin-toolbar,.admin-toolbar-grow{flex-wrap:wrap}.admin-toolbar input,.admin-toolbar select{min-width:0;width:100%}.admin-row{flex-wrap:wrap;gap:10px}.admin-row-actions{flex-wrap:wrap}.admin-head button{min-height:44px}.admin-body textarea{max-width:100%}.two-fields{grid-template-columns:1fr!important}
 .chathead button,.composer-area button{min-width:42px;min-height:42px}.chathead .info{min-width:0}.chathead .info b{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;display:block}
}
@media(prefers-reduced-motion:reduce){*,*::before,*::after{animation-duration:.01ms!important;transition-duration:.01ms!important;scroll-behavior:auto!important}}

/* 3.3.1: measured viewport fallback also works on WebViews without dynamic viewport units. */
html,body{max-width:100%;overscroll-behavior-y:none}
.shell{height:100vh;height:var(--app-height,100vh);min-height:0}
@media(max-width:760px){
 html,body,#app{width:100%;max-width:100%;height:var(--app-height,100vh)}
 .shell{width:100%!important;max-width:100%!important;height:var(--app-height,100vh)!important}
 .modal{max-height:calc(var(--app-height,100vh) - 12px)!important}
 .call-screen{height:var(--app-height,100vh)}
 .auth,.auth-card{height:var(--app-height,100vh)!important;min-height:var(--app-height,100vh)!important}
 .auth-v3{height:var(--app-height,100vh);min-height:0!important}
 .auth-v3 .auth-card{height:auto!important;min-height:var(--app-height,100vh)!important}
}

/* 3.3.4 — call audio route. Desktop keeps its existing screen-share control;
   mobile gets the reference speaker / mic / camera / hang-up row. */
#toggle-speaker{display:none}
.call-screen.active-call-screen #toggle-speaker.speaker-on{background:#fff!important;color:#17191f!important}
@media(max-width:760px){
  .call-screen.active-call-screen #toggle-speaker{display:grid!important;place-items:center}
  .call-screen.active-call-screen .call-controls{max-width:calc(100vw - 28px)!important}
}


/* === NOVO 3.3.5: targeted mobile/header/avatar fixes === */
/* Online status must never disable the circular crop of the actual photo. */
.avatar.online>img,.chathead>.avatar>img,.chat-item .avatar>img,.contact-row .avatar>img{border-radius:50%!important;clip-path:circle(50% at 50% 50%);object-fit:cover!important}
.chathead>.avatar{flex:0 0 40px!important;width:40px!important;height:40px!important;min-width:40px!important;min-height:40px!important;aspect-ratio:1/1!important;border-radius:50%!important}
.chathead>.avatar.online{overflow:visible!important}
.chathead>.avatar.online>img{width:40px!important;height:40px!important;display:block!important}

@media(max-width:760px){
 html,body{width:100%!important;height:100%!important;max-width:100%!important;overflow:hidden!important;overscroll-behavior:none!important;background:var(--bg)}
 body{position:fixed!important;inset:0!important}
 .shell{position:fixed!important;left:var(--app-left,0px)!important;top:var(--app-top,0px)!important;width:var(--app-width,100vw)!important;max-width:100vw!important;height:var(--app-height,100dvh)!important;max-height:var(--app-height,100dvh)!important;min-height:0!important;overflow:hidden!important}
 .shell.detail{grid-template-rows:minmax(0,1fr)!important}
 .shell.detail .main{height:100%!important;min-height:0!important;max-height:100%!important;overflow:hidden!important}
 .chathead{flex:0 0 auto!important;min-width:0!important}
 .chathead>.avatar{flex-basis:34px!important;width:34px!important;height:34px!important;min-width:34px!important;min-height:34px!important}
 .chathead>.avatar.online>img{width:34px!important;height:34px!important}
 .messages{flex:1 1 auto!important;min-height:0!important;overscroll-behavior:contain!important;-webkit-overflow-scrolling:touch!important;padding-bottom:10px!important}
 .composer-area{position:relative!important;z-index:30!important;flex:0 0 auto!important;width:100%!important;min-height:58px!important;padding:6px 8px calc(7px + env(safe-area-inset-bottom))!important;background:linear-gradient(180deg,#18181ee8,#18181ef8)!important;-webkit-backdrop-filter:blur(18px)!important;backdrop-filter:blur(18px)!important}
 .composer{width:100%!important;min-height:48px!important;display:flex!important;align-items:center!important;gap:2px!important;padding:2px 5px!important;border-radius:24px!important;background:#24252b!important;box-shadow:inset 0 0 0 1px #ffffff08!important}
 .composer textarea{font-size:16px!important;line-height:20px!important;min-height:44px!important;max-height:112px!important;padding:12px 7px!important;margin:0!important}
 .composer button{flex:0 0 40px!important;width:40px!important;min-width:40px!important;height:40px!important;min-height:40px!important;padding:8px!important;display:grid!important;place-items:center!important}
 .composer button .i{width:24px!important;height:24px!important}
 body.keyboard-open .mobile-nav{display:none!important}
 body.keyboard-open .composer-area{padding-bottom:6px!important}
 body.keyboard-open .messages{padding-bottom:6px!important}
 body.keyboard-open .shell{height:var(--app-height,100dvh)!important;top:var(--app-top,0px)!important}
}

.call-screen .call-avatar img{min-width:100%;min-height:100%;align-self:stretch;justify-self:stretch;object-fit:cover}.sticker-grid img{width:100%;height:96px;object-fit:contain}.sticker-grid button{min-width:0}

/* NOVO 3.3.9 — camera flip parity + stable mobile chat viewport */
.messages{overflow-anchor:none}
.self-preview .self-flip{border:0!important;background:#4a4d59e8!important;color:#fff!important;box-shadow:0 5px 18px #0006,inset 0 0 0 1px #ffffff12!important;-webkit-backdrop-filter:blur(12px);backdrop-filter:blur(12px);touch-action:manipulation}
.self-preview .self-flip .i{width:20px!important;height:20px!important;stroke-width:2!important}
.self-preview .self-flip.switching .i{animation:novoCameraFlip .7s linear infinite}
.self-preview .self-flip:disabled{opacity:.72}
@keyframes novoCameraFlip{to{transform:rotate(360deg)}}
@media(max-width:760px){
 .self-preview .self-flip{display:grid!important;place-items:center!important;left:8px!important;top:8px!important;width:34px!important;height:34px!important;min-width:34px!important;min-height:34px!important;padding:7px!important;border-radius:50%!important;z-index:5!important}
 .self-preview .self-flip[hidden]{display:none!important}
}


/* NOVO 3.3.10 — iPhone/PWA local-camera preview + camera flip overlay + full call avatars */
.self-preview{isolation:isolate!important}
.self-preview .local-video{z-index:1!important;transform:translateZ(0);-webkit-transform:translateZ(0)}
.self-preview .self-flip{z-index:40!important;pointer-events:auto!important;visibility:visible}
.self-preview .self-label{z-index:30!important;pointer-events:none}
.call-screen .call-avatar,.peer-placeholder .peer-avatar{overflow:hidden!important;padding:0!important;isolation:isolate}
.call-screen .call-avatar img,.peer-placeholder .peer-avatar img{display:block!important;width:100%!important;height:100%!important;min-width:100%!important;min-height:100%!important;max-width:none!important;max-height:none!important;object-fit:cover!important;object-position:50% 50%!important;border-radius:50%!important;transform:scale(1.08)!important;transform-origin:center center!important}
@supports (-webkit-touch-callout:none){
 .self-preview .local-video{will-change:transform;backface-visibility:hidden;-webkit-backface-visibility:hidden}
 .self-preview .self-flip{z-index:60!important}
}

/* NOVO 3.3.13 — complete light theme + mobile performance polish */
body.light,html.light{--bg:#f4f6fb;--panel:#ffffff;--card:#eef1f7;--input:#edf1f7;--line:#11182714;--text:#151822;--muted:#707784;--incoming:#ffffff;color-scheme:light;background:var(--bg);color:var(--text)}
body.light #app,body.light .main,body.light .page-scroll,body.light .welcome{background-color:var(--bg);color:var(--text)}
body.light .rail,body.light .sidebar,body.light .chathead,body.light .panehead,body.light .composer-area,body.light .mobile-nav,body.light .modal,body.light .modal-head,body.light .choose-footer,body.light .call-select-bar,body.light .admin-head,body.light .admin-tabs{background:var(--panel)!important;color:var(--text)!important;border-color:var(--line)!important}
body.light .wallpaper{background-color:#edf2fb!important;background-image:url('/wallpaper.svg');filter:none}
body.light .card,body.light .security-card,body.light .sessions-card,body.light .font-card,body.light .language-list,body.light .folder-hero,body.light .recommended-folders,body.light .admin-kv span,body.light .admin-user-head,body.light .admin-flags,body.light .admin-quick button{background:var(--card)!important;color:var(--text)!important;border-color:var(--line)!important}
body.light input,body.light textarea,body.light select,body.light .ref-input,body.light .searchbox input{background:var(--input)!important;color:var(--text)!important;border-color:#11182710!important}
body.light input::placeholder,body.light textarea::placeholder{color:#8a919e!important}
body.light button:hover{background:#0f172a08}
body.light .secondary{background:#e6eaf2!important;color:#20242d!important}
body.light .settings-list .setting-row:hover,body.light .chat-item:hover,body.light .call-row:hover,body.light .call-row.selected{background:#e8edf6!important}
body.light .chat-item.active{background:#dfe9fb!important}
body.light .composer{background:#ffffff!important;box-shadow:inset 0 0 0 1px #11182712,0 5px 18px #1118270a!important}
body.light .composer textarea{color:#171a22!important}
body.light .composer-area{background:linear-gradient(180deg,#f4f6fbdd,#f4f6fbfa)!important}
body.light .day{background:#ffffffd9!important;color:#667080!important;border:1px solid #1118270b}
body.light .bubble{background:#fff!important;color:#151822!important;box-shadow:0 1px 2px #11182716,0 4px 16px #11182708}
body.light .mine .bubble{background:var(--out)!important;color:#fff!important}
body.light .bubble .sender{color:#4d67a8!important}
body.light .reply{background:#11182708!important;border-left-color:var(--out)!important}
body.light .reaction{background:#1118270c!important}
body.light .reaction.mine{background:#0785ff22!important}
body.light .pinbar,body.light .replybar,body.light .channel-readonly{background:#fff!important;color:#687180!important;border-color:var(--line)!important}
body.light .setting-row,body.light .privacy-row,body.light .language-row,body.light .notification-check,body.light .shortcut-row,body.light .session-row{border-color:var(--line)!important;color:var(--text)!important}
body.light .theme-segment{background:#e7eaf0!important;border-color:#1118270e!important}
body.light .theme-segment button{color:#6f7682!important}
body.light .theme-segment button.active{background:#fff!important;color:var(--blue)!important;box-shadow:0 2px 8px #11182710}
body.light .appearance-preview{background-color:#e8edf8!important}
body.light .appearance-preview .preview-bubble.in{background:#fff!important;color:#171a22!important;box-shadow:0 1px 2px #11182710}
body.light .appearance-preview .preview-bubble.out{color:#fff!important}
body.light .folder-type-icon,body.light .folder-hero-icon,body.light .device-circle{background:#e5e9f1!important;color:#5e6674!important}
body.light .profile-camera{border-color:#fff!important}
body.light .choice-ring.on{box-shadow:inset 0 0 0 5px var(--card)!important}
body.light .modal-shade{background:#10182755!important}
body.light .action-popover .modal{background:#fff!important}
body.light .menu-item{border-color:var(--line)!important}
body.light .connection{color:#fff!important}
body.light #toast{background:#1f2937!important;color:#fff!important;box-shadow:0 12px 35px #1118272b!important}
body.light .skeleton-message,body.light .skeleton-composer{background:linear-gradient(90deg,#e8ecf3 25%,#f4f6fa 38%,#e8ecf3 63%)!important;background-size:400% 100%!important}
body.light .admin-body,body.light .admin-shell{background:var(--bg)!important;color:var(--text)!important}
body.light .admin-row{border-color:var(--line)!important}
body.light .admin-list-caption,body.light .admin-section-title,body.light .admin-stat-card{color:var(--text)!important}
body.light .admin-toolbar{background:#fff!important;border-color:var(--line)!important}
body.light .audit-row pre{background:#e9edf4!important;color:#29303b!important}
body.light .permission-list>div{border-color:var(--line)!important}
body.light .permission-intro>p{color:#5f6875!important}
body.light .auth-v3,body.light .auth-v3 .auth-card{background:#f4f6fb!important;color:#151822!important}
body.light .auth-pattern{opacity:.28}
body.light .auth-provider-note{background:#fff!important;border-color:#11182710!important}
body.light .auth-card .muted{color:#737b89!important}
body.light .yandex-id-btn{background:#fff!important;color:#151822!important;border-color:#11182712!important}
body.light .video-frame,body.light .round-note{background:#0d0e12!important}
body.light .call-side-panel{background:rgba(255,255,255,.96)!important;color:#171a22!important;border-color:#11182718!important}
body.light .call-panel-head,body.light .call-chat-form{border-color:#11182714!important}
body.light .call-side-panel input{background:#eef1f6!important;color:#171a22!important}
body.light .call-screen .modal,body.light .call-screen .action-popover .modal{color:#fff}
body.light .verified-badge{box-shadow:0 0 0 2px #fff}
body.light .avatar.online::after{border-color:#fff!important}
body.light .rail-count{box-shadow:0 0 0 2px #fff}

@media(max-width:760px){
 body.light .sidebar,body.light .mobile-nav,body.light .panehead,body.light .chathead{background:#fff!important}
 body.light .mobile-nav{border-top-color:#11182710!important;box-shadow:0 -4px 16px #11182708!important}
 body.light .composer-area{background:linear-gradient(180deg,#f4f6fbdd,#f4f6fbfa)!important}
 body.light .composer{background:#fff!important}
 body.light .folder-bottom{background:#f4f6fb!important}
 body.light .modal{background:#fff!important}
 body.light .message-actions .modal,body.light .action-popover .modal{box-shadow:0 -12px 40px #11182720!important}
}

/* Rendering containment: keeps large lists/chats cheap on iPhone and Android WebView. */
.chat-item,.contact-row,.setting-row,.privacy-row,.language-row,.notification-check,.session-row,.admin-row{contain:layout style}
#chat-list,.settings-list,.page-scroll,.messages{overscroll-behavior:contain}
@supports(content-visibility:auto){
 .chat-item,.contact-row,.admin-row{content-visibility:auto;contain-intrinsic-size:auto 72px}
 .setting-row,.privacy-row,.language-row,.notification-check,.session-row{content-visibility:auto;contain-intrinsic-size:auto 52px}
}
@media(max-width:760px){
 .page-scroll,.list,.messages{-webkit-overflow-scrolling:touch;scrollbar-width:none}
 .page-scroll::-webkit-scrollbar,.list::-webkit-scrollbar,.messages::-webkit-scrollbar{display:none}
 .sidebar,.main,.page-scroll,.messages{transform:translateZ(0)}
 .setting-row,.privacy-row,.language-row,.notification-check{min-height:50px}
}

/* NOVO2 · reference parity pass 2026-09-30 — desktop + mobile web */
.attachment-draft{display:flex;flex-direction:column;gap:12px}.attachment-draft-preview{display:grid;place-items:center;min-height:180px;max-height:56dvh;overflow:hidden;border-radius:14px;background:#0c0d10}.attachment-draft-media{display:block;max-width:100%;max-height:56dvh;object-fit:contain}.attachment-draft-file{width:100%;min-height:92px;display:flex;align-items:center;gap:14px;padding:16px;background:var(--card);border-radius:14px}.attachment-draft-file>.i{width:34px;height:34px;color:var(--blue)}.attachment-draft-file span{display:flex;flex-direction:column;gap:5px;min-width:0}.attachment-draft-file b,.attachment-draft-meta span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.attachment-draft-meta{display:flex;align-items:center;justify-content:space-between;gap:14px;color:var(--muted);font-size:11px}.attachment-draft-meta span{min-width:0}.attachment-caption{margin:0}.attachment-caption textarea{min-height:54px;max-height:150px;resize:none}.attachment-draft .modal-footer{margin-top:0}
.voice-wrap{max-width:350px}.voice-player{max-width:350px}.voice-text-toggle{width:30px;height:30px;min-width:30px;padding:0;border-radius:50%;font-size:12px;font-weight:800;color:#d7d3ff;background:#ffffff10}.voice-text-toggle.active{color:#fff;background:#7362de}.voice-transcript{margin:5px 0 2px;padding:8px 10px;border-radius:10px;background:#00000020;font-size:13px;line-height:1.35;white-space:pre-wrap}.voice-transcript[hidden]{display:none!important}.record-transcript-state{display:grid;place-items:center;width:24px;height:24px;border-radius:50%;font-size:10px;font-weight:800;color:#d8d4ff;background:#6d5fd8;flex:0 0 auto}
body:not(.light){--bg:#0f1014;--panel:#191a20;--card:#25262e;--input:#25262e;--incoming:#2b2c35;--out:#7454cc;--line:#ffffff0d;--muted:#91939d}.wallpaper{background-position:center}.chat-item.active{background:#2d3038}.chat-item:hover{background:#24262d}.bubble{border-radius:15px 15px 15px 5px;padding:7px 10px}.mine .bubble{border-radius:15px 15px 5px 15px;background:linear-gradient(145deg,#5f70e7,#8850cf)}.bubble .body{line-height:1.36}.day{background:#1d1f25d9;border:1px solid #ffffff0a;color:#a0a2aa;backdrop-filter:blur(8px)}.composer-area{background:linear-gradient(180deg,#191a20e8,#191a20)}.composer{background:#23242b;border-radius:20px;padding:1px 5px;box-shadow:inset 0 0 0 1px #ffffff08}.composer textarea{min-height:44px}.replybar{background:#191a20e8}.action-popover .modal{background:#202127}.action-popover .menu-item:hover{background:#30313a}.settings-list .setting-row,.privacy-row,.notification-check,.language-row,.session-row{border-color:#ffffff0b}.security-card,.sessions-card,.font-card,.language-list{background:#222329}
@media(min-width:761px){.shell{grid-template-columns:70px 344px minmax(0,1fr)}.rail{padding-top:9px;gap:5px}.rail .navbtn{min-height:62px}.sidebar{background:#18191e}.sidehead{min-height:57px;padding:14px 14px 7px}.searchbox{margin:3px 11px 9px}.chat-item{min-height:70px;padding:8px 12px}.chat-item>.avatar{width:46px;height:46px;min-width:46px}.chat-item .preview{height:34px;line-height:17px}.chathead{height:56px;padding:6px 13px;background:#18191e}.chathead>.avatar{width:38px!important;height:38px!important;min-width:38px!important;min-height:38px!important}.messages{padding-top:14px;padding-bottom:12px;gap:5px}.composer-area{padding-top:6px;padding-bottom:10px}.page-scroll{padding-top:18px}.page{max-width:520px}.modal{border-radius:15px}.attachment-draft .modal-footer{justify-content:flex-end}}
@media(max-width:760px){.chat-item{min-height:68px!important;padding:7px 13px!important}.chat-item>.avatar{width:47px;height:47px;min-width:47px}.sidehead{background:#191a20}.searchbox input{border-radius:10px;background:#25262d}.chathead{background:#17181d!important}.messages{padding:9px 8px 12px!important;gap:4px}.message{max-width:88%!important}.bubble{padding:7px 9px;font-size:14px}.message.media-only{max-width:84%!important}.composer-area{padding:5px 5px max(6px,env(safe-area-inset-bottom))!important;background:#17181de8!important;backdrop-filter:blur(18px)}.composer{min-height:46px;border-radius:21px!important;background:#23242b!important}.composer textarea{min-height:44px!important;max-height:118px!important;padding-top:12px!important;padding-bottom:10px!important}.mobile-nav{background:#17181d!important;border-top-color:#ffffff0c!important}.modal{background:#191a20!important;border-radius:22px 22px 0 0!important}.modal-head{min-height:49px}.attachment-draft-preview{min-height:150px;max-height:43dvh}.attachment-draft-media{max-height:43dvh}.attachment-draft .modal-footer{display:grid;grid-template-columns:1fr 1fr;gap:9px}.attachment-draft .modal-footer button{width:100%;min-height:46px}.voice-wrap{max-width:min(330px,76vw)}.voice-player{min-width:min(260px,72vw);gap:7px}.voice-toggle{width:40px;height:40px;padding:10px}.voice-text-toggle{width:28px;height:28px;min-width:28px}.voice-speed{padding:5px}.voice-transcript{font-size:13px;line-height:1.32}.round-note{width:min(58vw,244px)!important;height:min(58vw,244px)!important}.page-scroll{background:#0f1014}.settings-list .setting-row{min-height:49px!important;padding-top:12px!important;padding-bottom:12px!important}}

/* === NOVO2 media reference parity · 2026-09-30 === */
body.viewer-open{overflow:hidden}
.media-open{position:absolute;right:8px;top:8px;width:34px;height:34px;padding:7px;border-radius:50%;display:grid;place-items:center;background:#15161bd9;color:#fff;opacity:0;transform:scale(.92);transition:opacity .16s,transform .16s;z-index:4;backdrop-filter:blur(8px)}
.media-open .i{width:18px;height:18px}.video-frame:hover .media-open,.video-frame:focus-within .media-open{opacity:1;transform:none}.gallery-video{cursor:pointer}
.profile-avatar-view{display:block;margin:0 auto 2px;padding:0;border-radius:50%;overflow:visible;background:transparent}.profile-avatar-view:hover{background:transparent}.profile-avatar-view .avatar.big{margin:18px auto 0;box-shadow:0 0 0 1px #ffffff18;transition:transform .15s,box-shadow .15s}.profile-avatar-view:hover .avatar.big{transform:scale(1.025);box-shadow:0 0 0 2px #0785ff88}

.media-viewer{display:block;background:#08090cf2;backdrop-filter:blur(2px);padding:0;overflow:hidden;isolation:isolate}
.media-viewer .viewer-head{position:absolute;z-index:7;left:0;right:0;top:0;height:60px;padding:max(8px,env(safe-area-inset-top)) 12px 8px;display:grid;grid-template-columns:52px minmax(0,1fr) auto minmax(0,1fr) 52px;align-items:center;border-bottom:1px solid #ffffff0b;background:linear-gradient(#111218f0,#111218d8);color:#f6f6f8}
.viewer-back,.viewer-close{width:40px;height:40px;padding:9px;border-radius:50%;display:grid;place-items:center;color:#f3f3f5;background:transparent}.viewer-back{grid-column:1}.viewer-close{grid-column:5;justify-self:end;background:#ffffff16}.viewer-back:hover,.viewer-close:hover{background:#ffffff1d}.viewer-count{grid-column:2;justify-self:end;padding-right:52px;font-size:12px;font-weight:700;color:#f0f0f3}.viewer-title{grid-column:3;justify-self:center;font-size:14px}.viewer-stage{position:absolute;z-index:2;inset:60px 0 76px;display:flex;align-items:center;justify-content:center;overflow:hidden;padding:16px 34px 8px}.viewer-media{display:block;object-fit:contain;max-width:min(92vw,1120px);max-height:calc(100dvh - 164px);user-select:none;-webkit-user-drag:none}.viewer-image{width:auto;height:auto;box-shadow:0 12px 48px #0007;border-radius:6px}.viewer-video{width:auto;height:auto;background:#000;border-radius:5px;box-shadow:0 12px 48px #0009}
.viewer-download{position:absolute;z-index:6;left:50%;bottom:max(12px,env(safe-area-inset-bottom));transform:translateX(-50%);width:min(660px,calc(100vw - 32px));height:56px;border-radius:18px;background:#030407ed;display:flex;align-items:center;justify-content:flex-end;padding:0 22px;box-shadow:0 10px 40px #0008}.viewer-download a{display:flex;align-items:center;gap:7px;color:#fff;font-weight:700;text-decoration:none}.viewer-download .i{width:18px;height:18px}
.viewer-controls{position:absolute;z-index:6;left:50%;bottom:18px;transform:translateX(-50%);width:min(760px,calc(100% - 36px));min-height:54px;padding:7px 9px;display:flex;align-items:center;gap:9px;border-radius:17px;background:#15161ce8;box-shadow:0 8px 36px #0009;backdrop-filter:blur(14px);opacity:.98;transition:opacity .18s}.viewer-controls button{width:38px;height:38px;min-width:38px;padding:8px;border-radius:50%;display:grid;place-items:center;background:#ffffff0d}.viewer-controls button:hover{background:#ffffff19}.viewer-controls .i{width:18px;height:18px}.viewer-current,.viewer-duration{font-size:11px;font-variant-numeric:tabular-nums;color:#d4d4d9;white-space:nowrap}.viewer-seek{appearance:none;-webkit-appearance:none;flex:1;width:auto;min-width:80px;height:24px;padding:0;background:transparent;border:0;cursor:pointer}.viewer-seek::-webkit-slider-runnable-track{height:4px;border-radius:4px;background:#ffffff35}.viewer-seek::-webkit-slider-thumb{-webkit-appearance:none;width:14px;height:14px;border-radius:50%;background:#fff;margin-top:-5px;box-shadow:0 0 0 3px #0785ff55}.viewer-seek::-moz-range-track{height:4px;border-radius:4px;background:#ffffff35}.viewer-seek::-moz-range-thumb{width:14px;height:14px;border:0;border-radius:50%;background:#fff;box-shadow:0 0 0 3px #0785ff55}.viewer-speed-wrap{position:relative}.viewer-speed{font-size:11px;font-weight:700;color:#fff}.viewer-speed-menu{position:absolute;right:0;bottom:46px;width:98px;padding:5px;background:#202128;border:1px solid #ffffff12;border-radius:12px;box-shadow:0 12px 36px #000a}.viewer-speed-menu button{width:100%;height:auto;min-width:0;border-radius:8px;padding:9px 10px;display:block;text-align:left}.viewer-speed-menu button:hover{background:#ffffff12}.media-viewer.video-viewer .viewer-stage{bottom:0;padding-bottom:84px}.media-viewer.video-viewer .viewer-download{display:none}
.media-viewer.viewer-immersive .viewer-head,.media-viewer.viewer-immersive .viewer-download{opacity:0;pointer-events:none}.media-viewer.viewer-immersive .viewer-stage{inset:0;padding:0}.media-viewer.viewer-immersive .viewer-media{max-width:100vw;max-height:100dvh;border-radius:0}.media-viewer.viewer-immersive .viewer-controls{bottom:max(10px,env(safe-area-inset-bottom))}

.message.round-message{max-width:min(90%,390px);padding-bottom:26px}.round-note{--round-progress:0deg;width:226px;height:226px;overflow:visible;border:1px solid #5d46d8;box-shadow:0 0 0 1px #5d46d866;background:#0b0b0e;transition:width .24s cubic-bezier(.2,.75,.25,1),height .24s cubic-bezier(.2,.75,.25,1),box-shadow .18s;touch-action:pan-y}.round-note.expanded{width:360px;height:360px;box-shadow:0 0 0 1px #6047e6,0 14px 48px #0006}.round-note video{overflow:hidden;background:#070708}.round-note:after{inset:-2px;background:conic-gradient(#fff var(--round-progress),#ffffff2c 0);-webkit-mask:radial-gradient(circle,transparent calc(100% - 4px),#000 calc(100% - 3px));mask:radial-gradient(circle,transparent calc(100% - 4px),#000 calc(100% - 3px));filter:drop-shadow(0 0 1px #fff)}.round-progress-dot{position:absolute;z-index:4;width:8px;height:8px;border-radius:50%;background:#fff;transform:translate(-50%,-50%);box-shadow:0 0 0 2px #ffffff45;pointer-events:none}.round-toggle{width:54px;height:54px;background:#121217b5;backdrop-filter:blur(8px);transition:opacity .14s,transform .14s}.round-note.playing .round-toggle{opacity:0;transform:translate(-50%,-50%) scale(.92)}.round-note.playing:hover .round-toggle,.round-note.scrubbing .round-toggle{opacity:1;transform:translate(-50%,-50%) scale(1)}.round-sound{position:absolute;z-index:5;left:50%;bottom:10px;transform:translateX(-50%);width:38px;height:38px;padding:8px;border-radius:50%;display:grid;place-items:center;background:#202027dc;color:#fff;backdrop-filter:blur(10px);box-shadow:0 4px 18px #0005}.round-sound .i{width:17px;height:17px}.round-sound.muted{background:#36343ddb}.round-time{left:7px;bottom:-24px;background:#26262c;color:#eee;padding:2px 5px;border-radius:5px;font-size:10px;font-variant-numeric:tabular-nums}.message.round-message .meta{right:4px;bottom:-24px;background:#26262c;color:#eee}.round-note.expanded .round-time{bottom:-25px}.round-note.media-failed:before{content:'Не удалось загрузить';position:absolute;z-index:3;inset:0;border-radius:50%;display:grid;place-items:center;background:#09090bdd;color:#ddd;font-size:12px}.round-note:focus-visible{outline:2px solid #0785ff;outline-offset:5px}

@media(max-width:760px){
 .media-open{opacity:1;right:6px;top:6px;width:32px;height:32px}
 .media-viewer .viewer-head{height:54px;grid-template-columns:44px minmax(0,1fr) auto minmax(0,1fr) 44px;padding-top:max(5px,env(safe-area-inset-top));background:#111218f5}.viewer-count{padding-right:18px}.viewer-stage{inset:54px 0 calc(68px + env(safe-area-inset-bottom));padding:8px 7px}.viewer-media{max-width:100%;max-height:calc(100dvh - 140px)}.viewer-image{border-radius:2px;box-shadow:none}.viewer-download{bottom:max(7px,env(safe-area-inset-bottom));height:50px;width:calc(100vw - 16px);border-radius:15px;padding:0 17px}.viewer-controls{bottom:max(8px,env(safe-area-inset-bottom));width:calc(100% - 14px);gap:5px;padding:5px 6px;border-radius:15px}.viewer-controls button{width:34px;height:34px;min-width:34px;padding:7px}.viewer-current,.viewer-duration{font-size:10px}.viewer-duration{display:none}.viewer-seek{min-width:54px}.viewer-speed-menu{bottom:41px}.media-viewer.video-viewer .viewer-stage{inset:54px 0 0;padding:4px 0 72px}.media-viewer.video-viewer .viewer-video{max-width:100vw;max-height:calc(100dvh - 126px);border-radius:0}
 .message.round-message{max-width:96%;padding-bottom:24px}.round-note{width:min(58vw,236px)!important;height:min(58vw,236px)!important}.round-note.expanded{width:min(86vw,360px)!important;height:min(86vw,360px)!important}.round-sound{bottom:8px;width:36px;height:36px}.round-time,.message.round-message .meta{bottom:-22px}
 .profile-avatar-view .avatar.big{width:86px;height:86px}
}
@media(pointer:coarse){.media-open{opacity:1}.round-note.playing .round-toggle{opacity:0}.round-note.playing:active .round-toggle{opacity:1}}


/* NOVO2 media reliability fix 2026-09-30 */
.video-frame{width:min(360px,100%);min-width:220px;min-height:150px;display:grid;place-items:center;isolation:isolate}
.video-frame .message-video{grid-area:1/1;width:100%;height:auto;min-height:150px;max-height:420px;object-fit:contain;background:#090a0d;cursor:pointer;border-radius:14px;margin:0}
.video-frame .message-video[poster]{object-fit:contain}
.video-inline-play{grid-area:1/1;z-index:3;width:52px;height:52px;padding:13px;border-radius:50%;display:grid;place-items:center;background:#111218c9;color:#fff;box-shadow:0 6px 22px #0008;backdrop-filter:blur(9px);transition:transform .15s,background .15s}
.video-inline-play:hover{background:#191a21e8;transform:scale(1.04)}
.video-inline-play .i{width:25px;height:25px}
.video-duration{position:absolute;left:8px;bottom:8px;z-index:3;padding:3px 7px;border-radius:8px;background:#08090bbd;color:#fff;font-size:10px;font-variant-numeric:tabular-nums;pointer-events:none}
.video-frame.media-ready .video-duration{display:block}
.video-frame.media-failed .video-inline-play{display:none}
.video-frame.media-failed:after{z-index:2}
.media-retry{z-index:5}
.message.media-only .video-frame{width:min(360px,100%)}

.round-note:after{content:none!important;display:none!important}
.round-ring{position:absolute;inset:0;z-index:3;width:100%;height:100%;overflow:visible;pointer-events:none;transform:rotate(-90deg)}
.round-ring-track,.round-ring-value{fill:none;vector-effect:non-scaling-stroke}
.round-ring-track{stroke:#ffffff55;stroke-width:1.15}
.round-ring-value{stroke:#fff;stroke-width:1.35;stroke-linecap:round;stroke-dasharray:100;stroke-dashoffset:100;filter:drop-shadow(0 0 1.2px #fff)}
.round-progress-dot{z-index:4;width:9px;height:9px;box-shadow:0 0 0 2px #ffffff55,0 1px 4px #0008}
.round-toggle{z-index:5}
.round-sound{z-index:6}
.round-note.scrubbing .round-ring-value{stroke-width:1.55}
.round-note.media-failed .round-ring,.round-note.media-failed .round-progress-dot{opacity:.25}
@media(max-width:760px){
 .video-frame{min-width:min(220px,72vw);min-height:132px;width:min(82vw,360px)}
 .video-frame .message-video{min-height:132px;max-height:min(58dvh,420px)}
 .video-inline-play{width:48px;height:48px;padding:12px}
 .round-ring-track{stroke-width:1.25}.round-ring-value{stroke-width:1.5}
}

/* Call history: stable desktop actions and visible touch controls. */
.calls-sidebar .call-list{flex:1;min-height:0;overflow-y:auto}
.calls-sidebar .call-row{display:flex;align-items:center;gap:10px;min-width:0;min-height:66px}
.calls-sidebar .call-row>.avatar,.calls-sidebar .call-pick{flex-shrink:0}
.calls-sidebar .call-main{min-width:0;overflow:hidden;text-align:left}
.calls-sidebar .call-main>b{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.calls-sidebar .call-sub{display:flex;align-items:center;gap:5px;min-width:0}
.calls-sidebar .call-kind,.calls-sidebar .call-group-media{display:inline-flex;flex-shrink:0}
.calls-sidebar .call-sub svg{width:14px;height:14px;margin:0}
.calls-sidebar .call-status-text{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.calls-sidebar .call-tail{position:relative;flex:0 0 72px;min-height:36px;display:flex;align-items:center;justify-content:flex-end}
.calls-sidebar .call-stamp{display:block;white-space:nowrap}
.calls-sidebar .call-actions{position:absolute;inset:0;display:flex;align-items:center;justify-content:flex-end;gap:2px;opacity:0;pointer-events:none}
.calls-sidebar .call-actions button,.calls-sidebar .call-actions button:first-child{display:grid;place-items:center;width:34px;height:36px;min-width:34px;padding:7px}
.calls-sidebar .call-row:hover .call-actions,.calls-sidebar .call-row:focus-within .call-actions{display:flex;opacity:1;pointer-events:auto}
.calls-sidebar:not(.calls-selecting) .call-row:hover .call-stamp,.calls-sidebar:not(.calls-selecting) .call-row:focus-within .call-stamp{visibility:hidden}
.calls-sidebar button:focus-visible{outline:2px solid var(--accent,#7d71ff);outline-offset:-2px}
.calls-sidebar .call-select-bar{position:static;flex-shrink:0;width:auto;gap:6px;padding:12px 10px;padding-bottom:max(12px,env(safe-area-inset-bottom));flex-wrap:wrap}
.calls-sidebar .call-select-bar span{flex:1;text-align:center}
.calls-sidebar .call-pick{min-width:44px;min-height:44px}
@media(hover:none),(pointer:coarse),(max-width:760px){
 .calls-sidebar .call-row{gap:8px;min-height:76px}
 .calls-sidebar .call-tail{flex-basis:88px;min-height:62px;flex-direction:column;align-items:flex-end;justify-content:center}
 .calls-sidebar .call-actions,.calls-sidebar .call-row:hover .call-actions{position:static;display:flex;opacity:1;pointer-events:auto}
 .calls-sidebar .call-actions button,.calls-sidebar .call-actions button:first-child{display:grid;width:44px;height:44px;min-width:44px;padding:11px}
 .calls-sidebar .call-stamp,.calls-sidebar:not(.calls-selecting) .call-row:hover .call-stamp,.calls-sidebar:not(.calls-selecting) .call-row:focus-within .call-stamp{display:block;visibility:visible;font-size:11px}
 .calls-sidebar.calls-selecting .call-tail{flex-basis:64px}
}
.calls-sidebar .call-row .call-actions,.calls-sidebar .call-row:not(:hover) .call-actions{width:100%;overflow:visible;margin-left:0}

/* NOVO 20261012.04 — unread anchor, stable thread scrolling and phonebook */
.main.wallpaper{position:relative}
.unread-divider{align-self:stretch;display:flex;align-items:center;gap:10px;color:#a9aab4;font-size:11px;font-weight:600;margin:8px 0 10px;user-select:none}
.unread-divider::before,.unread-divider::after{content:'';height:1px;flex:1;background:#ffffff19}
.unread-divider span{white-space:nowrap;padding:2px 8px;border-radius:9px;background:#25262c;color:#d6d7de}
.chat-scroll-bottom{position:absolute;right:22px;bottom:82px;z-index:12;width:42px;height:42px;border-radius:50%;padding:9px;display:grid;place-items:center;background:#202127e8;border:1px solid #ffffff12;box-shadow:0 6px 22px #0008;color:#d5d6de;opacity:0;pointer-events:none;transform:translateY(8px);transition:opacity .15s ease,transform .15s ease,background .15s ease}
.chat-scroll-bottom.show{opacity:1;pointer-events:auto;transform:none}
.chat-scroll-bottom:hover{background:#2a2b33}
.chat-scroll-bottom .i{width:21px;height:21px}
.chat-scroll-count{position:absolute;right:-5px;top:-7px;min-width:24px;height:19px;padding:1px 5px;border-radius:10px;background:#087ff2;color:#fff;font-size:10px;font-weight:700;line-height:17px;text-align:center;box-shadow:0 0 0 2px var(--bg);font-variant-numeric:tabular-nums}
.messages{overflow-anchor:none}
.messages [data-mid],.messages img.attachment,.messages .video-frame,.messages .round-note{overflow-anchor:none}
.contact-section-title{padding:14px 14px 7px;color:#858793;font-size:10px;font-weight:700;letter-spacing:.06em}
.phonebook-contact-row{min-height:62px}
.contact-invite{flex-shrink:0;color:var(--blue);font-size:12px;font-weight:600;padding:8px 9px;margin-right:4px}
.phonebook-explain{line-height:1.45;padding:2px 2px 12px}
.phonebook-browser-actions{padding-top:4px}
.phonebook-caption{display:block;padding:8px 4px 7px;color:#858793;font-size:10px;font-weight:700;letter-spacing:.05em}
.phonebook-result-row{display:flex;align-items:center;gap:10px;padding:9px 4px;border-bottom:1px solid #ffffff0c}
.phonebook-result-row:last-child{border-bottom:0}
.phonebook-result-row span{min-width:0}
.phonebook-result-row b,.phonebook-result-row small{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.phonebook-result-row button{color:var(--blue);font-size:12px;font-weight:600;background:#0a86ff14}
.phonebook-missing{max-height:280px;overflow:auto;margin-top:8px}
.phonebook-invite-card{margin-bottom:10px}
.phonebook-invite-card p{margin-top:5px}
.invite-action-button{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:8px;min-height:74px;padding:10px;color:inherit;background:var(--card);border-radius:13px;text-decoration:none}
.invite-action-button .i{color:var(--blue)}

@media(max-width:760px){
 .chat-scroll-bottom{right:12px;bottom:calc(74px + env(safe-area-inset-bottom));width:40px;height:40px}
 .chat-scroll-count{right:-4px;top:-7px}
 .unread-divider{margin:7px -2px 9px;font-size:10px}
 .contact-invite{font-size:11px;padding:8px 6px}
 .phonebook-missing{max-height:42dvh}
}


/* NOVO 2026-10-01 — call events in the conversation timeline */
.call-event-message{max-width:min(460px,78%)}
.call-event-message .call-event-bubble{padding:0;overflow:hidden;background:#24252b}
.call-event-message.mine .call-event-bubble{background:linear-gradient(135deg,#0b91ef,#5039df)}
.call-event-action{width:100%;display:grid;grid-template-columns:42px minmax(0,1fr) auto;align-items:center;gap:10px;padding:10px 12px;border:0;background:transparent;color:inherit;text-align:left;cursor:pointer}
.call-event-icon{width:38px;height:38px;border-radius:12px;display:grid;place-items:center;background:rgba(255,255,255,.12);color:#64b9ff;flex:none}
.call-event-message.mine .call-event-icon{background:rgba(255,255,255,.16);color:#fff}
.call-event-message.missed .call-event-icon,.call-event-message.cancelled .call-event-icon{color:#ff6c63}
.call-event-copy{min-width:0;display:flex;flex-direction:column;gap:2px}.call-event-copy b{font-size:14px;line-height:1.2;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.call-event-copy small{font-size:12px;opacity:.72;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.call-event-time{font-size:11px;opacity:.65;align-self:end;padding-bottom:1px}
@media(max-width:760px){.call-event-message{max-width:88%}.call-event-action{grid-template-columns:38px minmax(0,1fr) auto;padding:9px 10px}.call-event-icon{width:34px;height:34px;border-radius:11px}.call-event-copy b{font-size:13px}.call-event-copy small{font-size:11px}}

/* NOVO 2026-10-01 — call-card contrast fix (web / iPhone PWA / Android WebView) */
.call-event-copy b{
  color:#f7f8fb;
  opacity:1;
  font-weight:700;
}
.call-event-copy small{
  color:#c9ccd6;
  opacity:1;
  font-weight:550;
  line-height:1.25;
}
.call-event-time{
  color:#c5c8d1;
  opacity:1;
  font-weight:500;
}
.call-event-message.mine .call-event-copy b{
  color:#fff;
  opacity:1;
}
.call-event-message.mine .call-event-copy small{
  color:rgba(255,255,255,.90);
  opacity:1;
  font-weight:600;
}
.call-event-message.mine .call-event-time{
  color:rgba(255,255,255,.86);
  opacity:1;
}
.call-event-message.missed:not(.mine) .call-event-copy small,
.call-event-message.cancelled:not(.mine) .call-event-copy small{
  color:#d1d3da;
}
@media(max-width:760px){
  .call-event-copy small{font-size:11.5px}
  .call-event-time{font-size:10.5px}
}

/* Stable timeline: one anchoring mechanism, including media load and keyboard resize. */
#messages{overflow-anchor:none;scroll-behavior:auto}
#messages .round-note{touch-action:pan-y}
#messages .round-note video{object-fit:cover}
.admin-section-select{display:none}
.admin-work,.admin-body,.admin-head,.admin-shell{min-width:0;max-width:100%}
.admin-work{width:100%}
.admin-kv b{overflow-wrap:anywhere;white-space:normal;min-width:0}
.admin-dialog{max-height:calc(var(--app-height,100dvh) - 24px);overflow-y:auto;overscroll-behavior:contain}
.admin-dialog .two-fields>*{min-width:0}
.admin-page table{max-width:100%;overflow-wrap:anywhere}
@media(max-width:760px){
 .admin-page{width:100%;min-width:0;padding-bottom:calc(20px + env(safe-area-inset-bottom))}
 .admin-page .admin-tabs{display:none!important}
 .admin-section-select{display:block;width:100%;min-height:48px;margin:0 0 12px;font-size:16px;background:var(--panel);color:var(--text);border:1px solid var(--line);border-radius:12px;padding:10px}
 .admin-page .admin-work{align-self:stretch}
 .admin-page .admin-toolbar.sticky{position:static;top:auto}
 .admin-page input,.admin-page textarea,.admin-page select,.admin-dialog input,.admin-dialog textarea,.admin-dialog select{font-size:16px;max-width:100%;min-width:0}
 .admin-page button,.admin-dialog button{min-height:44px}
 .admin-page .admin-head>div{width:100%;overflow-wrap:anywhere}
 .admin-page .admin-head>button{flex:1;white-space:normal}
 .admin-page .admin-kv span{flex-wrap:wrap;gap:6px}
 .admin-page .admin-kv b{max-width:100%}
 .admin-page .admin-row-title{flex-wrap:wrap}
 .admin-page .admin-row-actions{width:100%;gap:8px}
 .admin-page .admin-row-actions button{flex:1 1 100px}
 .admin-dialog{width:calc(100% - 16px);max-width:100%;padding-bottom:calc(12px + env(safe-area-inset-bottom));max-height:calc(var(--app-height,100dvh) - 16px)}
 .admin-dialog .two-fields{display:grid;grid-template-columns:minmax(0,1fr)}
 .admin-dialog .row{flex-wrap:wrap}
 .admin-dialog .row>button{flex:1 1 120px}
 .admin-page pre,.admin-dialog pre{max-width:100%;white-space:pre-wrap;overflow-wrap:anywhere}
}

/* NOVO 3.3.18 — reliable outbox / drafts / upload manager / global search */
.delivery-status{display:inline-flex;align-items:center;gap:3px;white-space:nowrap;color:inherit;opacity:.78}
.delivery-status.error{color:#ff7979;opacity:1;cursor:pointer;text-decoration:underline;text-decoration-style:dotted;text-underline-offset:2px}
.draft-attachment-restore{display:flex;align-items:center;gap:8px;margin:0 8px 7px;padding:8px 10px;border-radius:12px;background:#24262d;border:1px solid #ffffff12;min-width:0}
.draft-attachment-restore>span{display:flex;align-items:center;gap:7px;min-width:0;flex:1}.draft-attachment-restore b{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.draft-attachment-restore svg{width:18px;height:18px;flex:none}.draft-attachment-restore button{min-height:32px;padding:5px 9px;border-radius:9px}.draft-attachment-restore [data-draft-drop]{width:32px;padding:6px}
#upload-progress{pointer-events:none}#upload-progress .upload-actions{display:flex;justify-content:center;gap:7px;margin-top:7px;pointer-events:none}#upload-progress .upload-actions button{pointer-events:auto;min-height:30px;padding:4px 10px;border-radius:9px;background:#343640;color:#f5f6f8}#upload-progress .upload-actions button:hover{background:#40434d}
.global-search-results{max-height:min(64vh,620px);overflow:auto;overscroll-behavior:contain}.search-section{display:flex;flex-direction:column;gap:5px}.search-section h4{position:sticky;top:0;z-index:2;margin:7px 0 3px;padding:5px 4px;color:#9fa2ad;background:var(--panel,#202127);font-size:11px;text-transform:uppercase;letter-spacing:.04em}.search-message-result,.search-file-result{display:block;text-align:left;width:100%;padding:9px 11px}.search-message-result p{margin:4px 0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.search-file-result b{display:flex;align-items:center;gap:7px;min-width:0}.search-file-result svg{width:17px;height:17px;flex:none}
@media(max-width:760px){.draft-attachment-restore{margin-left:5px;margin-right:5px}.global-search-results{max-height:70dvh}.search-section h4{top:-1px}}
.voice-middle{position:relative;min-width:0}.voice-waveform{position:absolute;left:0;right:0;top:2px;height:25px;display:flex;align-items:center;gap:2px;opacity:.58;pointer-events:none;overflow:hidden}.voice-waveform i{display:block;flex:1;max-width:3px;min-width:1px;border-radius:3px;background:currentColor}.voice-waveform+.voice-seek{position:relative;z-index:1;background:transparent}

/* NOVO 3.3.18 / 20261012.04 — synchronized tombstones */
.tombstone-message .bubble{opacity:.72;background:var(--card,#24252b);border:1px dashed color-mix(in srgb,currentColor 18%,transparent)}
.tombstone-body{font-style:italic;color:var(--muted,#9da0aa)}

/* NOVO 3.3.19 — channel creation/reference parity */
.channel-create-page,.channel-subpage,.channel-info-page,.channel-settings-page,.channel-reactions-page,.channel-admin-rights,.channel-stats{width:min(100%,560px);margin:0 auto}
.channel-create-page{min-height:calc(100dvh - 112px);padding-top:4px}.channel-create-intro h2{font-size:24px;line-height:1.15}.channel-create-intro p{font-size:13px;max-width:360px;margin:8px auto 0;line-height:1.35}.channel-avatar-pick{width:88px;height:88px;background:#24262d;box-shadow:inset 0 0 0 1px #ffffff08}.channel-avatar-pick>.i{width:28px;height:28px}.channel-avatar-pick>span{display:grid;place-items:center;width:24px;height:24px;right:6px;bottom:6px;border-radius:50%;background:#343640;color:#fff;font-size:18px}
.channel-create-page .ref-input input,.channel-create-page .ref-textarea textarea,.channel-settings-page .ref-input input,.channel-settings-page .ref-textarea textarea{background:#23252c;border-radius:12px;padding:14px 48px 14px 14px}.channel-create-page .ref-textarea textarea,.channel-settings-page .ref-textarea textarea{min-height:106px}.channel-create-bottom{gap:8px}.channel-create-bottom .primary,.channel-create-bottom .secondary{border-radius:12px;min-height:48px;font-weight:700}
.channel-created-mark{font-size:48px;margin:8px auto 3px}.channel-access-page>h2{font-size:20px}.channel-access-page>.muted{font-size:13px}.channel-access-card,.channel-share-card,.channel-management-card,.channel-media-card{background:#202228;border:1px solid #ffffff08}.channel-choice{min-height:62px;padding:10px 8px}.channel-choice b{font-size:15px}.channel-choice small{font-size:12px;line-height:1.25}.choice-ring{width:21px;height:21px;flex-basis:21px;border-color:#777984}.choice-ring.on{border-width:6px;border-color:#0b8cff}
.channel-invite-box{display:flex;align-items:center;gap:8px;margin-top:12px;padding:12px 4px 4px;border-top:1px solid #ffffff0d}.channel-invite-box .grow{display:flex;flex-direction:column;min-width:0}.channel-invite-box b{font-size:13px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.channel-invite-box small{margin-top:4px}.channel-invite-box button{width:36px;height:36px;padding:7px;border-radius:50%;background:#2b2d35;color:#9ea0aa}.channel-business-row{margin:0 0 16px;background:#202228;border-radius:14px;padding:13px 14px;border-bottom:0}.channel-business-row b,.channel-settings-page .setting-row b,.channel-subpage .setting-row b{display:block;font-size:14px}.channel-business-row small,.channel-settings-page .setting-row small,.channel-subpage .setting-row small{display:block;margin-top:3px;line-height:1.25}.channel-setting-icon{width:34px;height:34px;border-radius:10px;background:#2a2c34;display:grid;place-items:center;color:#8e91a0}.channel-setting-icon .i{width:19px;height:19px}
.channel-picker-search,.channel-page-search{height:42px;border-radius:11px;background:#272930;display:flex;align-items:center;gap:8px;padding:0 11px;margin-bottom:12px}.channel-picker-search .i,.channel-page-search .i{width:18px;height:18px;color:#8f929d}.channel-picker-search input,.channel-page-search input{border:0;background:transparent;padding:0;height:100%}.channel-picker-list{max-height:52dvh;overflow:auto}.channel-user-choice,.channel-member-row{display:flex;align-items:center;gap:11px;width:100%;min-height:62px;padding:8px 6px;text-align:left;border-radius:10px}.channel-user-choice:hover,.channel-member-row:hover{background:#ffffff08}.channel-user-choice .avatar,.channel-member-row .avatar{width:44px;height:44px;min-width:44px}.channel-user-choice b,.channel-member-row b{display:block;font-size:14px}.channel-user-choice small,.channel-member-row small{display:block;margin-top:3px}.channel-choice-check{width:24px;height:24px;border:2px solid #686a75;border-radius:50%;display:grid;place-items:center;color:#fff}.channel-user-choice.selected .channel-choice-check{background:#0785ff;border-color:#0785ff}.channel-picker-footer{position:sticky;bottom:0;background:#191a20;padding-top:12px;display:grid;grid-template-columns:1fr 1fr;gap:8px}.channel-picker-footer button{min-height:46px}
.channel-profile{padding-top:0}.channel-profile .avatar.big{width:92px;height:92px}.channel-info-actions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));max-width:280px;margin:18px auto 0}.channel-info-actions button{min-height:62px}.channel-description-card{font-size:14px;line-height:1.42}.channel-head-edit{margin-left:-42px;width:38px;height:38px;padding:7px;color:#e9eaf0}.channel-management-card .setting-row:last-child,.channel-media-card .setting-row:last-child{border-bottom:0}.channel-info-tabs{padding:0 2px;gap:18px}.channel-media-card{padding:10px}.channel-section-label{display:block;margin:12px 6px 7px;color:#777a86;font-size:11px;font-weight:700;letter-spacing:.04em}.channel-hint,.channel-setting-help{color:#7f828d;font-size:12px;line-height:1.35;margin:7px 8px 14px}.channel-invite-card{display:flex;align-items:center;gap:10px;padding:12px}.channel-invite-card .avatar{width:42px;height:42px;min-width:42px}.channel-invite-card .grow{display:flex;flex-direction:column;min-width:0}.channel-invite-card .grow>b{font-size:13px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.channel-invite-card .grow>small{margin-top:3px}.channel-invite-card>button{width:36px;height:36px;padding:7px;color:#8e91a0}.channel-blue-action{display:flex;align-items:center;gap:10px;width:100%;min-height:48px;padding:12px 8px;color:#158cff;text-align:left;font-weight:600}.channel-blue-action .i{width:21px;height:21px}.channel-member-list{display:flex;flex-direction:column}.channel-member-row .i{color:#7f828e}.channel-member-row .small{min-height:32px}.channel-confirm-copy{font-size:14px;line-height:1.45;color:#e9eaf0}.channel-confirm-actions{display:flex;flex-direction:column;gap:8px;margin-top:18px}.channel-confirm-actions button{min-height:46px;border-radius:12px}.channel-qr{text-align:center}.channel-qr svg{display:block;width:min(320px,78vw);height:auto;margin:0 auto 16px;background:#fff;border-radius:16px;padding:10px}.channel-qr p{font-size:12px;color:#8f929d;overflow-wrap:anywhere;margin-bottom:14px}
.channel-admin-rights .profile-header{padding-bottom:14px}.channel-admin-rights .setting-row{min-height:58px}.channel-admin-rights .setting-row small{max-width:360px}.channel-stats .channel-stat-grid{display:grid;grid-template-columns:1fr 1fr;gap:10px}.channel-stat-grid .card{margin:0;text-align:center;padding:20px 10px}.channel-stat-grid b{font-size:25px;display:block}.channel-stat-grid span{font-size:12px;color:#8d909b;display:block;margin-top:5px}
.channel-settings-avatar{position:relative;display:block;margin:0 auto 18px;padding:0}.channel-settings-avatar .avatar.big{margin:0}.channel-settings-avatar>span{position:absolute;right:-1px;bottom:0;width:30px;height:30px;display:grid;place-items:center;border-radius:50%;background:#168df5;color:#fff;border:3px solid #0f1014}.channel-settings-avatar>span .i{width:16px;height:16px}.channel-settings-page>.card{padding:0 8px}.channel-settings-page>.card .setting-row:last-child{border-bottom:0}.channel-delete-row{margin-top:12px;color:#ff496c;background:#202228;border-radius:14px;justify-content:center;border-bottom:0}.channel-reaction-limit{text-align:center}.channel-reaction-limit>b{display:block;font-size:16px;margin-bottom:17px}.channel-reaction-limit input[type=range]{accent-color:#0785ff;background:transparent;padding:0}.range-labels{display:flex;justify-content:space-between;color:#858893;font-size:11px}.channel-reaction-heading{margin:6px 5px}.channel-reaction-heading .channel-section-label{margin:0}.channel-reaction-heading button{color:#158cff}.channel-emoji-grid{display:grid;grid-template-columns:repeat(8,1fr);gap:5px}.channel-emoji-grid button{font-size:24px;padding:7px 3px;border-radius:10px;filter:grayscale(.45);opacity:.6}.channel-emoji-grid button.selected{background:#178dff2b;filter:none;opacity:1;box-shadow:inset 0 0 0 1px #168eff66}.channel-post-preview{max-height:38dvh;overflow:auto;white-space:pre-wrap}.channel-ready-wrap{margin:auto;display:flex;flex-direction:column;align-items:center;gap:10px;width:min(100%,440px);padding:30px 16px}.channel-ready-card{background:#22242b;border:1px solid #ffffff0b;border-radius:16px;padding:20px;text-align:center;width:100%}.channel-ready-card .avatar{margin:0 auto 12px;width:64px;height:64px}.channel-ready-card h3{font-size:17px}.channel-ready-card p{margin-top:6px;color:#90939d;font-size:13px}.channel-created-line{color:#8e919b;font-size:12px}.channel-readonly{min-height:45px;display:grid;place-items:center}.channel-create-page .setting-row,.channel-subpage .setting-row{border-color:#ffffff0c}
@media(max-width:760px){.channel-create-page,.channel-subpage,.channel-info-page,.channel-settings-page,.channel-reactions-page,.channel-admin-rights,.channel-stats{width:100%}.channel-create-page{min-height:calc(100dvh - 78px);padding:0 7px}.channel-create-intro{margin-top:10px}.channel-create-intro h2{font-size:22px}.channel-avatar-pick{width:82px;height:82px}.channel-create-bottom{margin-left:-1px;margin-right:-1px}.channel-access-card,.channel-share-card,.channel-description-card,.channel-management-card,.channel-media-card{border-radius:13px}.channel-business-row{border-radius:13px}.channel-info-page{padding:0 2px}.channel-profile .avatar.big{width:86px;height:86px}.channel-member-row{min-height:58px}.channel-emoji-grid{grid-template-columns:repeat(6,1fr)}.channel-emoji-grid button{font-size:25px;padding:8px 2px}.channel-stat-grid{padding:0 4px}.channel-invite-card{margin-left:2px;margin-right:2px}.channel-settings-page,.channel-reactions-page{padding:0 2px}.channel-confirm-actions{padding-bottom:max(2px,env(safe-area-inset-bottom))}.channel-picker-list{max-height:58dvh}.channel-picker-footer{padding-bottom:max(2px,env(safe-area-inset-bottom))}}
@media(min-width:761px){.channel-create-page{min-height:calc(100dvh - 110px)}.channel-subpage,.channel-info-page,.channel-settings-page,.channel-reactions-page,.channel-admin-rights,.channel-stats{padding-top:2px}.channel-picker-list{max-height:420px}}


/* NOVO 20261012.04 — voice waveform, reaction preview, channel header polish */
.chat-reaction-badge{display:grid;place-items:center;min-width:28px;height:28px;padding:2px 5px;border-radius:50%;background:#343640;border:1px solid #ffffff17;box-shadow:0 1px 4px #0004;font-size:17px;line-height:1;flex:none}
.voice-middle .voice-waveform{position:relative;left:auto;right:auto;top:auto;height:26px;display:flex;align-items:center;gap:2px;opacity:1;overflow:hidden;pointer-events:none;color:currentColor}
.voice-middle .voice-waveform i{display:block;flex:1;max-width:3px;min-width:1.5px;border-radius:3px;background:currentColor;opacity:.28;transition:opacity .1s ease,transform .1s ease;transform-origin:center}
.voice-middle .voice-waveform i.played{opacity:1;transform:scaleY(1.04)}
.voice-middle .voice-waveform+.voice-seek{position:absolute;left:0;right:0;top:0;width:100%;height:29px;margin:0;padding:0;opacity:0;z-index:3;cursor:pointer;touch-action:none}
.voice-middle .voice-clock{min-height:13px}
.channel-head-edit{position:absolute!important;right:14px!important;top:50%!important;transform:translateY(-50%)!important;margin:0!important;width:38px;height:38px;padding:7px;color:#e9eaf0;z-index:2}
.panehead:has(.channel-head-edit) h3{margin-left:44px!important;margin-right:44px!important}
.phone-find #phone-find-go{transition:opacity .15s ease}
.phone-user{border-radius:13px!important;background:#272830!important;margin-top:10px!important}
@media(max-width:760px){.chat-reaction-badge{min-width:27px;height:27px;font-size:16px}.channel-head-edit{right:10px!important}}

/* NOVO 20261012.04 — channel edit button right edge fix */
.channel-head-edit{
  position:absolute!important;
  left:auto!important;
  inset-inline-start:auto!important;
  right:14px!important;
  inset-inline-end:14px!important;
  top:50%!important;
  transform:translateY(-50%)!important;
  margin:0!important;
  width:38px!important;
  height:38px!important;
  z-index:6!important;
}
@media(max-width:760px){
  .channel-head-edit{
    left:auto!important;
    inset-inline-start:auto!important;
    right:10px!important;
    inset-inline-end:10px!important;
  }
}

/* NOVO 20261012.04 — channel settings mobile avatar safe layout */
@media(max-width:760px){
  .channel-settings-scroll{
    padding-top:14px!important;
    scroll-padding-top:14px!important;
    overflow-anchor:none;
  }
  .channel-settings-page{
    padding-top:0!important;
    overflow:visible!important;
  }
  .channel-settings-avatar{
    position:relative!important;
    display:block!important;
    width:92px!important;
    height:92px!important;
    min-width:92px!important;
    min-height:92px!important;
    margin:6px auto 20px!important;
    padding:0!important;
    overflow:visible!important;
    flex:0 0 92px!important;
    touch-action:manipulation;
  }
  .channel-settings-avatar .avatar.big{
    display:block!important;
    width:88px!important;
    height:88px!important;
    min-width:88px!important;
    min-height:88px!important;
    margin:0 auto!important;
    border-radius:50%!important;
    overflow:hidden!important;
  }
  .channel-settings-avatar .avatar.big>img{
    display:block!important;
    width:100%!important;
    height:100%!important;
    object-fit:cover!important;
  }
  .channel-settings-avatar>span{
    right:-1px!important;
    bottom:0!important;
    z-index:2!important;
  }
}

/* NOVO 3.3.20 — adaptive call quality / diagnostics */
.call-quality{position:absolute;z-index:21;top:71px;left:120px;display:inline-flex;align-items:center;gap:7px;min-height:28px;padding:4px 10px;border-radius:14px;background:#242731cc;color:#c8cad2;font-size:12px;font-weight:700;backdrop-filter:blur(10px);border:1px solid #ffffff0b}.call-quality i{width:8px;height:8px;border-radius:50%;background:#9aa0ad;box-shadow:0 0 0 3px #9aa0ad1f}.call-quality.high i{background:#31d17c}.call-quality.medium i{background:#67b7ff}.call-quality.low i{background:#f3b546}.call-quality.critical i{background:#ff6678}.call-quality.checking i{animation:callQualityPulse 1.1s infinite}@keyframes callQualityPulse{50%{opacity:.35}}.call-screen[data-phase="reconnecting"] .call-quality{background:#382f20dd}.call-screen[data-phase="failed"] .call-quality{background:#45242bdd}.remote-tile.portrait video{object-fit:contain!important}.call-diagnostics{display:grid;gap:10px}.call-diag-row{display:grid;gap:4px;padding:12px;border-radius:14px;background:#24262d}.call-diag-row span{font-size:13px;color:#c8cad2}.call-diag-row small{line-height:1.45;color:#9498a6}
@media(max-width:760px){.call-quality{top:calc(50px + env(safe-area-inset-top));left:66px;right:66px;justify-content:center;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.call-quality span{overflow:hidden;text-overflow:ellipsis}.call-screen.active-call-screen.has-remote-video .call-quality{top:calc(50px + env(safe-area-inset-top))}}


/* === NOVO AI 20261012.04 === */
.ai-avatar{position:relative;overflow:visible!important;background:radial-gradient(circle at 30% 20%,#8c72ff,#24134f 72%)!important;box-shadow:0 0 0 1px #7a69ff55,0 0 18px #5c43ff25}.ai-avatar img{border-radius:inherit;display:block}.ai-avatar i{position:absolute;right:-4px;bottom:-3px;min-width:22px;height:18px;padding:0 4px;border-radius:8px;display:grid;place-items:center;font-style:normal;font-size:9px;font-weight:900;letter-spacing:.3px;color:#fff;background:linear-gradient(135deg,#158dff,#7956ff);border:2px solid var(--panel);box-shadow:0 2px 8px #0008}.ai-name-badge{display:inline-grid;place-items:center;margin-left:6px;min-width:23px;height:17px;padding:0 5px;border-radius:7px;background:linear-gradient(135deg,#168cff,#7559ff);color:#fff;font-size:9px;font-weight:900;vertical-align:2px;letter-spacing:.35px}.ai-bot-thread .chathead{background:linear-gradient(90deg,#17181d 0%,#1c1930 55%,#17181d 100%)!important}.ai-bot-thread .composer [data-action="attach"],.ai-bot-thread .composer [data-action="round"]{display:none!important}.ai-bot-thread .composer{box-shadow:0 0 0 1px #7562ff22,0 10px 30px #0003}.message.ai-answer .bubble{background:linear-gradient(145deg,#24242d,#29263b);border:1px solid #7865ff26;box-shadow:0 6px 18px #0002}.ai-answer-label{display:inline-flex;align-items:center;margin-bottom:5px;padding:2px 7px;border-radius:999px;background:#725cff22;color:#a99cff;font-size:10px;font-weight:800;letter-spacing:.25px}.message.ai-streaming .body::after{content:'';display:inline-block;width:6px;height:14px;margin-left:3px;vertical-align:-2px;border-radius:2px;background:#8f7cff;animation:aiCursor .85s steps(1) infinite}.message.ai-error .bubble{border-color:#ff6a8033}.ai-about{text-align:center;display:grid;justify-items:center;gap:10px}.ai-about .avatar{width:76px;height:76px}.ai-about p{max-width:420px;line-height:1.5}.ai-about small{color:var(--muted);max-width:430px;line-height:1.45}.ai-admin-hero{background:linear-gradient(125deg,#231d3d,#20202a 55%,#162d45)!important}.admin-live.ai-offline{color:#ffc4cc;background:#3a1b24}.admin-live.ai-offline i{background:#ff6078;box-shadow:0 0 0 4px #ff60781c}.ai-admin-form h3{margin:0 0 4px}.ai-admin-form textarea{resize:vertical;min-height:90px}.ai-safety-list{display:grid;gap:7px}.ai-safety-list p{display:flex;align-items:flex-start;gap:8px;margin:0;padding:7px 9px;border-radius:10px;background:#ffffff06;color:#c9c9d0;font-size:11px;line-height:1.35}.ai-safety-list svg{width:15px;height:15px;flex:0 0 auto;color:#68aaff}.switch-label{display:flex;align-items:center;gap:8px;color:#c8c9d1;font-size:12px}.switch-label input{accent-color:#168cff}
@keyframes aiCursor{0%,49%{opacity:1}50%,100%{opacity:.15}}
@media(max-width:760px){.ai-avatar i{right:-3px;bottom:-2px}.ai-bot-thread .chathead .ai-name-badge{display:none}.ai-admin-form{padding:12px}.ai-admin-form textarea{min-height:110px}}
.ai-answer .body{line-height:1.52}.ai-paragraph{margin:0 0 7px}.ai-paragraph:last-child{margin-bottom:0}.ai-gap{height:5px}.ai-heading{margin:9px 0 5px;font-weight:800;font-size:1.03em;color:#f2efff}.ai-list{margin:4px 0 9px;padding-left:20px}.ai-list li{margin:3px 0}.ai-answer code{padding:1px 5px;border-radius:5px;background:#0f1016;color:#d8d1ff;font:500 .92em/1.4 ui-monospace,SFMono-Regular,Menlo,Consolas,monospace}.ai-code{margin:8px 0;padding:10px 12px;overflow:auto;border:1px solid #ffffff12;border-radius:10px;background:#101117;color:#e4e5eb;white-space:pre;max-width:min(680px,72vw)}.ai-code code{padding:0;background:transparent;color:inherit}
@media(max-width:760px){.ai-code{max-width:78vw;font-size:12px}}
.ai-info-header{padding-top:20px}.ai-info-header .ai-avatar.big{width:86px;height:86px}.ai-info-card{line-height:1.5}.ai-info-card h3{margin:0 0 8px}.ai-info-card p{margin:6px 0}

/* NOVO 20261012.04 — shared contacts, reliable search, channel verification */
.channel-verified-badge{
  display:inline-flex;align-items:center;justify-content:center;width:15px;height:15px;min-width:15px;
  margin-left:5px;border-radius:50%;background:#555861;color:#f4f5f8;font-size:10px;font-weight:900;line-height:1;
  vertical-align:1px;box-shadow:inset 0 0 0 1px rgba(255,255,255,.08)
}
.channel-verified-badge.large{width:38px;height:38px;min-width:38px;margin:0;font-size:23px;background:#50535b}
.user-mini-verified{display:inline-flex;align-items:center;justify-content:center;width:13px;height:13px;margin-left:5px;border-radius:50%;background:#2388f4;color:#fff;font-size:9px;vertical-align:1px}

.contact-message .bubble{padding:0!important;background:transparent!important;box-shadow:none!important;border:0!important;max-width:min(360px,88vw)!important}
.contact-message .body,.contact-message .contact-meta-hidden{display:none!important}
.contact-message .reactions{margin-top:5px}
.contact-share-card{
  position:relative;display:flex;align-items:center;gap:10px;width:min(340px,82vw);min-height:72px;padding:10px 12px;
  border-radius:15px;background:#24252a;border:1px solid rgba(255,255,255,.025);box-shadow:0 5px 20px rgba(0,0,0,.16);overflow:hidden
}
.message.mine .contact-share-card{background:#24252a;border-color:rgba(255,255,255,.035)}
.contact-share-person{display:flex;align-items:center;gap:10px;min-width:0;flex:1;padding:0;text-align:left;background:transparent!important}
.contact-share-avatar{width:46px!important;height:46px!important;min-width:46px!important;border-radius:50%;overflow:hidden}
.contact-share-copy{display:flex;flex-direction:column;min-width:0;padding-right:2px}
.contact-share-copy b{display:flex;align-items:center;max-width:150px;color:#f4f4f6;font-size:15px;line-height:1.25;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.contact-share-copy small{margin-top:3px;color:#92959e;font-size:13px;line-height:1.2}
.contact-share-actions{display:flex;align-items:center;gap:7px;margin-right:1px}
.contact-share-action{display:flex;align-items:center;justify-content:center;width:36px;height:36px;min-width:36px;padding:8px;border-radius:50%;background:#3a3b40!important;color:#babcc5;transition:background .16s ease,color .16s ease,transform .12s ease}
.contact-share-action:hover{background:#46484e!important;color:#fff}.contact-share-action:active{transform:scale(.94)}
.contact-share-action.added{color:#7fbdff;background:#343840!important}
.contact-share-action .i{width:19px;height:19px}
.contact-share-time{position:absolute;right:10px;bottom:5px;color:#8b8e96;font-size:10px;line-height:1;pointer-events:none}

.global-search-box{display:flex;align-items:center;gap:9px;min-height:48px;padding:0 13px;border-radius:13px;background:#292a31}
.global-search-box .i{width:20px;height:20px;color:#7f828c;flex:none}.global-search-box input{flex:1;min-width:0;border:0!important;background:transparent!important;padding:0!important;outline:none!important}
.global-search-hint{padding:13px 4px}.global-search-loading{display:flex;align-items:center;justify-content:center;gap:10px;min-height:90px;color:#8e919b}
.global-search-loading span{width:18px;height:18px;border:2px solid #4a4c55;border-top-color:#168cff;border-radius:50%;animation:novo-search-spin .8s linear infinite}
@keyframes novo-search-spin{to{transform:rotate(360deg)}}
.global-search-error{padding:16px;border-radius:13px;background:#24252b}.global-search-error p{margin:5px 0 12px;color:#9598a1}.global-search-error button{color:#168cff}
.search-user-result small,.search-chat-result small{display:block;margin-top:2px;color:#8f929d}.search-join-label{padding:5px 8px;border-radius:9px;background:#28394b;color:#4ba6ff;font-size:11px}
.contact-global-search{margin:6px 8px;color:#168cff!important;border-radius:11px;background:#20242a!important}

.channel-info-title{display:flex;align-items:center;justify-content:center;gap:1px}
.channel-info-actions{display:grid!important;grid-template-columns:repeat(2,76px)!important;justify-content:center!important;gap:12px!important;width:164px!important;max-width:none!important;margin:18px auto 0!important}
.channel-info-actions button{display:flex!important;flex-direction:column!important;align-items:center!important;justify-content:center!important;gap:6px!important;width:76px!important;min-width:76px!important;height:66px!important;min-height:66px!important;padding:8px 5px!important;border-radius:15px!important;background:#24262d!important;color:#168cff!important;white-space:normal!important}
.channel-info-actions button .i{width:23px!important;height:23px!important;flex:none!important}.channel-info-actions button span{font-size:11px!important;line-height:1.1!important;max-width:66px!important;overflow:hidden;text-overflow:ellipsis!important}
.channel-verification-entry{display:flex;align-items:center;gap:12px;width:100%;margin:14px 0;padding:14px 15px;text-align:left;border:1px solid rgba(255,255,255,.04);background:#22242a}
.channel-verification-entry .grow{display:flex;flex-direction:column;min-width:0}.channel-verification-entry b{font-size:14px}.channel-verification-entry small{margin-top:4px;color:#8f929c;font-size:12px;line-height:1.35}.channel-verification-entry>.i:last-child{width:18px;height:18px;color:#72757f;flex:none}
.channel-verify-entry-icon{display:flex;align-items:center;justify-content:center;width:38px;height:38px;min-width:38px;border-radius:12px;background:#30323a;color:#aeb0b8}.channel-verification-entry.ready .channel-verify-entry-icon{color:#168cff;background:#243346}.channel-verification-entry.pending .channel-verify-entry-icon{color:#e0ae52;background:#383129}.channel-verification-entry.rejected .channel-verify-entry-icon{color:#bf8484;background:#392c2e}.channel-verification-entry.approved .channel-verify-entry-icon{background:#303238}
.channel-verification-page{max-width:620px;margin:0 auto;padding-bottom:24px}.channel-verification-hero{display:flex;align-items:center;gap:14px;margin:4px 0 18px;padding:18px;border-radius:18px;background:linear-gradient(145deg,#25272e,#1f2026)}.channel-verification-hero.verified{background:linear-gradient(145deg,#2b2d33,#23242a)}.channel-verification-hero h2{margin:0;font-size:18px}.channel-verification-hero p{margin:4px 0 0;color:#9699a3}
.channel-verification-success,.verification-status-card,.verification-info-card{padding:16px;line-height:1.45}.channel-verification-success p,.verification-status-card p,.verification-info-card p{margin:7px 0;color:#aaaeb8}.channel-verification-success small,.verification-status-card small{display:block;color:#7f838e;margin-bottom:10px}
.channel-verification-form textarea{resize:vertical;min-height:110px}.channel-verification-form .field small{display:block;margin-top:5px;color:#777b86;font-size:11px;line-height:1.35}.verification-confirm{align-items:flex-start;line-height:1.35}

.admin-tabs button{position:relative}.admin-nav-count{display:inline-flex;align-items:center;justify-content:center;min-width:19px;height:19px;padding:0 5px;margin-left:auto;border-radius:10px;background:#168cff;color:#fff;font-style:normal;font-size:10px;font-weight:800}
.verification-admin-settings{margin-bottom:14px}.verification-admin-settings form{gap:12px}.verification-days{display:flex;align-items:center;gap:7px}.verification-days input{width:78px;min-width:78px;text-align:center}.verification-days span{color:#8d909a;font-size:12px}.verification-admin-list{display:flex;flex-direction:column;gap:12px}.verification-admin-card{padding:16px}.verification-admin-head{display:flex;align-items:center;gap:11px}.verification-admin-head .avatar{width:48px;height:48px;min-width:48px}.verification-admin-section{margin-top:14px;padding-top:12px;border-top:1px solid rgba(255,255,255,.055)}.verification-admin-section>b,.verification-admin-note>b{font-size:12px;color:#d9dae0}.verification-admin-section p,.verification-admin-note p{margin:6px 0 0;line-height:1.5;color:#aeb1ba;white-space:pre-wrap;overflow-wrap:anywhere}.verification-admin-note{margin-top:12px;padding:11px 12px;border-radius:11px;background:#1d1f24}.verification-admin-actions{display:flex;justify-content:flex-end;gap:8px;margin-top:14px}.verification-evidence{font-family:ui-monospace,SFMono-Regular,Menlo,monospace;font-size:12px}

@media(max-width:760px){
 .contact-share-card{width:min(326px,84vw);min-height:70px;padding:9px 10px}.contact-share-copy b{max-width:130px}.contact-share-action{width:34px;height:34px;min-width:34px;padding:7px}.contact-share-time{right:8px;bottom:5px}
 .global-search-box{margin:0 1px}.global-search-results{max-height:68dvh!important}
 .channel-info-actions{grid-template-columns:repeat(2,72px)!important;width:156px!important;gap:12px!important}.channel-info-actions button{width:72px!important;min-width:72px!important;height:64px!important;min-height:64px!important}
 .channel-verification-entry{margin:12px 0;padding:13px}.channel-verification-page{padding:0 2px 22px}.channel-verification-hero{margin-top:0;padding:15px}
 .verification-admin-settings form{align-items:flex-start;flex-wrap:wrap}.verification-admin-actions{flex-direction:column}.verification-admin-actions button{width:100%}
}


/* NOVO 20261012.04 — native mobile keyboard, without blur/refocus hacks */
@media(max-width:760px){
  .shell{height:var(--app-height,100dvh)!important;min-height:0!important;}
  body.keyboard-open .shell{height:var(--app-height,100dvh)!important;}
  body.keyboard-open .mobile-nav{display:none!important;}
  .composer textarea,
  .page input,.page textarea,.page select,
  .modal input,.modal textarea,.modal select{
    -webkit-user-select:text!important;user-select:text!important;
    -webkit-touch-callout:default!important;touch-action:auto!important;
  }
  .composer textarea{font-size:16px!important;line-height:21px!important;caret-color:var(--blue);}
  body.keyboard-open .composer-area{padding-bottom:max(6px,env(safe-area-inset-bottom))!important;}
}


/* NOVO 20261012.04 — readable messenger typography / density */
/* Desktop/web: slightly larger and heavier without changing the grid geometry. */
@media(min-width:761px){
  .sidehead h2{font-size:23px;font-weight:800;letter-spacing:-.2px}
  .searchbox input{font-size:14px;font-weight:500}
  .tabs button{font-size:13.5px;font-weight:650}
  .chat-item .name{font-size:15px;font-weight:700;letter-spacing:-.08px}
  .chat-item .preview{font-size:13.5px;line-height:18.5px;height:37px;font-weight:450}
  .chat-item .time{font-size:10.5px;font-weight:550}
  .chathead .info b{font-size:15.5px;font-weight:750}
  .chathead .info small{font-size:12px;font-weight:500}
  .bubble .body{font-size:15.5px;line-height:1.4;font-weight:450}
  .bubble .sender{font-size:12.5px;font-weight:700}
  .panehead h3{font-size:16px;font-weight:750}
  .setting-row{font-size:14.5px;font-weight:520}
  .modal-body,.page{font-size:14.5px}
  .menu-item{font-size:14.5px;font-weight:560}
}

/* iPhone Safari/PWA + Android WebView/browser: reference-like readable density. */
@media(max-width:760px){
  body{font-size:15px}
  .sidehead{height:60px!important;min-height:60px!important;padding:16px 15px 8px!important}
  .sidehead h2{font-size:24px!important;line-height:1.1;font-weight:800!important;letter-spacing:-.35px}
  .sidehead .round-btn{width:36px;height:36px;min-width:36px;padding:7px}
  .sidehead .round-btn .i{width:20px;height:20px}

  .searchbox{margin:4px 13px 10px!important}
  .searchbox input{min-height:42px;padding:10px 12px 10px 36px!important;font-size:15px!important;font-weight:500;border-radius:11px!important}
  .searchbox .i{left:11px;top:12px;width:17px;height:17px}
  .tabs,.chat-tabs{min-height:41px;gap:20px!important;padding-left:18px!important;padding-right:18px!important}
  .tabs button,.chat-tabs button{font-size:14px!important;font-weight:680!important;padding:9px 0!important}

  .chat-item{min-height:76px!important;padding:9px 14px!important;gap:11px!important}
  .chat-item>.avatar{width:50px!important;height:50px!important;min-width:50px!important;min-height:50px!important;font-size:20px}
  .chat-item .name{font-size:15.5px!important;line-height:19px;font-weight:750!important;letter-spacing:-.12px}
  .chat-item .preview{font-size:13.5px!important;line-height:19px!important;height:38px!important;margin-top:2px;font-weight:480}
  .chat-item .time{font-size:10.5px!important;font-weight:600!important}
  .badge{font-size:11px!important;line-height:16px;font-weight:750;padding:2px 6px}

  .mobile-nav{height:60px!important;min-height:60px!important}
  .mobile-nav .navbtn{min-height:52px!important;font-size:10px!important;font-weight:600!important;gap:4px!important}
  .mobile-nav .navbtn svg,.mobile-nav .i{width:23px!important;height:23px!important}

  .chathead{height:64px!important;min-height:64px!important;padding:7px 10px!important;gap:8px!important}
  .chathead>.avatar,.chathead .avatar{width:42px!important;height:42px!important;min-width:42px!important;min-height:42px!important}
  .chathead .info b{font-size:16px!important;line-height:19px;font-weight:780!important;letter-spacing:-.15px}
  .chathead .info small{font-size:12px!important;line-height:15px;font-weight:520}
  .chathead button{padding:8px 6px!important}
  .chathead button .i{width:23px;height:23px}

  .messages{padding:11px 9px 13px!important;gap:5px!important}
  .bubble{padding:8px 10px!important}
  .bubble .body{font-size:16px!important;line-height:1.36!important;font-weight:500;letter-spacing:-.08px}
  .bubble .sender{font-size:12.5px!important;font-weight:720!important}
  .bubble .meta{font-size:10.5px!important;font-weight:560!important}
  .reply{font-size:12.5px!important;line-height:17px}
  .day{font-size:11.5px!important;font-weight:620!important}
  .call-event-copy b{font-size:14px!important;font-weight:750!important}
  .call-event-copy small{font-size:12px!important;font-weight:580!important}
  .call-event-time{font-size:10.5px!important;font-weight:560!important}

  .composer-area{padding:6px 6px max(7px,env(safe-area-inset-bottom))!important}
  .composer{min-height:50px!important;border-radius:22px!important;padding:1px 4px!important}
  .composer textarea{min-height:48px!important;max-height:126px!important;padding:13px 7px 11px!important;font-size:16px!important;line-height:22px!important;font-weight:500!important}
  .composer button{padding:11px 7px!important}
  .composer button .i{width:23px;height:23px}

  .panehead{height:60px!important;min-height:60px!important;padding:0 13px!important}
  .panehead h3{font-size:16px!important;font-weight:780!important;letter-spacing:-.12px}
  .page-scroll{padding:18px 10px calc(24px + env(safe-area-inset-bottom))!important}
  .page{font-size:15px!important;line-height:1.4}
  .profile-header h2,.channel-profile h2{font-size:21px!important;font-weight:800!important}
  .setting-row,.settings-list .setting-row{min-height:54px!important;padding:14px 12px!important;font-size:15px!important;font-weight:580!important}
  .setting-row .right{font-size:12.5px!important}
  .setting-row small,.page small,.muted{font-size:12.5px}
  .field>span{font-size:13px!important;font-weight:600!important}
  .page input,.page textarea,.page select,.modal input,.modal textarea,.modal select{font-size:16px!important;font-weight:500!important}
  .primary,.secondary,.page button,.modal button{font-size:15px;font-weight:650}

  .modal-head{min-height:54px!important;padding:10px 17px 9px!important}
  .modal-head h3{font-size:18px!important;font-weight:800!important}
  .modal-body{padding:2px 17px 20px!important;font-size:15px!important;line-height:1.4}
  .menu-item{min-height:50px!important;font-size:15.5px!important;font-weight:600!important}

  .contacts-page .chat-item,.calls-page .call-row{font-size:15px}
  .call-row .call-info b{font-size:15px;font-weight:720}
  .call-row .call-info small{font-size:12.5px}
  .channel-member-row b,.channel-admin-row b{font-size:15px;font-weight:720}
  .channel-member-row small,.channel-admin-row small{font-size:12.5px}
  .admin-page,.admin-dialog{font-size:15px}
  .admin-page h2,.admin-page h3,.admin-dialog h3{font-weight:800}
  .admin-page input,.admin-page textarea,.admin-page select,.admin-dialog input,.admin-dialog textarea,.admin-dialog select{font-size:16px!important}
}


/* NOVO 20261012.04 — stale mobile viewport / missing keyboard safeguard */
@media(max-width:760px){
  html,body,#app{height:100dvh!important;min-height:100dvh!important;max-height:100dvh!important;}
  body{position:relative!important;inset:auto!important;overflow:hidden!important;}
  body:not(.keyboard-open) .shell{top:0!important;left:0!important;width:100vw!important;height:100dvh!important;max-height:100dvh!important;}
  body.keyboard-open .shell{top:var(--app-top,0px)!important;left:var(--app-left,0px)!important;width:var(--app-width,100vw)!important;height:var(--app-height,100dvh)!important;max-height:var(--app-height,100dvh)!important;}
  body.keyboard-open .messages{scroll-padding-bottom:76px!important;}
}

/* Recording preview is independent of chat videos and their lazy rendering. */
.round-record-dialog{width:min(460px,100%);max-height:calc(var(--app-height,100dvh) - 16px);overflow-y:auto}
.round-record-dialog .modal-body{min-height:0!important}
.round-recorder{display:flex;flex-direction:column;align-items:center;gap:12px;padding:8px 0 12px}
.round-record-camera{position:relative;width:min(220px,62vw);height:min(220px,62vw);flex:none;border-radius:50%;overflow:hidden;background:#08090c;isolation:isolate}
.round-record-camera .record-preview{position:absolute!important;inset:0!important;display:block!important;width:100%!important;height:100%!important;max-width:none!important;max-height:none!important;margin:0!important;opacity:1!important;visibility:visible!important;object-fit:cover!important;border-radius:50%;content-visibility:visible!important;contain:none!important;transform:none}
.round-record-status{max-width:340px;text-align:center;font-size:14px;line-height:1.4;color:var(--muted);min-height:20px}
.round-recorder .record-time{font-size:32px;line-height:1.2;font-variant-numeric:tabular-nums;margin:0}
.round-record-actions{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:6px;width:100%;margin-top:6px}
.round-record-actions button{min-height:46px;padding:10px 5px;font-size:14px;white-space:normal}
.round-record-retry{min-height:44px;max-width:100%}
@media(max-height:520px){.round-record-camera{width:132px;height:132px}.round-recorder{gap:6px}}
/* NOVO 3.3.21 reference additions */
.channel-directory-entry{display:flex;flex-direction:column;align-items:center;gap:8px;width:88px;margin:20px 4px 16px;padding:0!important;background:transparent!important;font-weight:700}.channel-directory-icon{width:72px;height:72px;border-radius:22px;display:grid;place-items:center;background:linear-gradient(145deg,#8756ff,#4f2cd2);box-shadow:inset 0 1px 0 #ffffff36,0 9px 24px #4525c75c}.channel-directory-icon .i{width:40px;height:40px;color:#eee9ff;stroke-width:1.5}.channel-catalog-avatar{background:linear-gradient(145deg,#8756ff,#4f2cd2)!important}.channel-catalog-avatar .i{width:25px}
.call-invite-picker{display:grid;gap:10px}.call-invite-search{padding:0 10px;border-radius:12px;background:#292b33}.call-invite-search input{border:0!important;background:transparent!important}.call-invite-person{display:flex;align-items:center;gap:10px;width:100%;padding:8px 6px;text-align:left;border-radius:10px}.call-invite-person.selected{background:#168cff18}.call-invite-person .call-person-avatar{width:42px;height:42px;min-width:42px}.call-invite-check{width:24px;height:24px;border-radius:50%;display:grid;place-items:center;border:1px solid #5d6069}.call-invite-person.selected .call-invite-check{background:#168cff;border-color:#168cff}
.round-lock-hint{display:flex;align-items:center;gap:7px;padding:7px 10px;border-radius:10px;background:#383943;color:#d8dae2;font-size:11px;line-height:1.25}.round-lock-hint .i{width:16px;height:16px}.round-gesture-locked .round-lock-hint{background:#51545f;color:#fff;transform:translateY(-5px)}
@media(max-width:760px){.round-record-dialog{width:100%!important;max-width:none!important}.round-recorder{padding-top:14px}.round-lock-hint{position:absolute;right:14px;bottom:126px}.round-record-dialog .modal-body{position:relative}.round-record-camera{width:min(76vw,330px)!important;height:min(76vw,330px)!important}}

/* NOVO 3.3.23 — reference parity: global search, calls and round-video recorder */
.sidehead-actions{display:flex;align-items:center;gap:8px}
.sidehead-actions .round-btn:first-child{background:#2a2d35;color:#d9dbe3}

/* Global search / channels — matches the mobile reference flow. */
.global-search-dialog{width:min(520px,100%);overflow:hidden}
.global-search-dialog>.modal-head{display:none!important}
.global-search-dialog>.modal-body{padding:0!important;min-height:560px}
.global-search-head{display:flex;align-items:center;gap:8px;padding:14px 14px 8px;position:sticky;top:0;z-index:4;background:var(--panel)}
.global-search-back{width:42px;height:42px;display:grid;place-items:center;padding:9px;flex:0 0 auto}
.global-search-box{height:44px;display:flex;align-items:center;gap:8px;flex:1;min-width:0;padding:0 12px;border-radius:11px;background:#2b2d31}
.global-search-box>.i{width:18px;height:18px;color:#969aa3;flex:none}
.global-search-box input{height:42px;padding:0!important;border:0!important;background:transparent!important;font-size:16px!important}
.global-search-results{padding:2px 12px 20px;overflow:auto}
.channel-directory-entry{display:flex!important;flex-direction:column;align-items:center;justify-content:center;gap:8px;width:92px!important;margin:20px 4px 25px!important;padding:0!important;background:transparent!important;font-size:14px;font-weight:700}
.channel-directory-icon{position:relative;width:76px;height:76px;border-radius:23px;display:grid;place-items:center;background:radial-gradient(circle at 58% 28%,#b78cff 0 9%,transparent 10%),linear-gradient(145deg,#8258ff,#5b2ee0 58%,#4824bf);box-shadow:inset 0 1px 0 #ffffff40,0 10px 28px #4b28db55}
.channel-directory-icon:after{content:'';position:absolute;inset:7px;border-radius:18px;background:linear-gradient(135deg,#ffffff16,transparent 45%);pointer-events:none}
.channel-directory-icon .i{width:42px!important;height:42px!important;color:#eeeaff;stroke-width:1.6}
.search-home-section,.search-section{display:block;margin:0 0 18px}
.search-home-title,.search-section>h4{min-height:30px;display:flex;align-items:center;justify-content:space-between;margin:0;padding:0 5px;color:#8e9099;font-size:12px;font-weight:760;letter-spacing:.02em}
.search-home-title button{padding:5px;color:#8e9099;font-size:12px}
.global-search-results .chat-item{padding:7px 4px!important;min-height:58px!important;border-radius:10px}
.global-search-results .chat-item>.avatar{width:46px!important;height:46px!important;min-width:46px!important}
.global-search-results .chat-item b{font-size:15px}.global-search-results .chat-item small{display:block;margin-top:3px;color:#999ba4;font-size:13px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.search-join-label{color:var(--blue);font-size:12px;font-weight:700}
.search-message-result{display:block;width:100%;text-align:left;padding:10px;border-radius:10px}.search-message-result p{margin-top:4px;color:var(--muted);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.global-search-loading,.global-search-error{display:grid;place-items:center;gap:10px;padding:48px 20px;text-align:center;color:var(--muted)}
.global-search-loading span{width:24px;height:24px;border-radius:50%;border:2px solid #ffffff24;border-top-color:var(--blue);animation:novoSpin .8s linear infinite}@keyframes novoSpin{to{transform:rotate(360deg)}}

/* Round-video recorder: full-screen mobile capture with hold / swipe-up lock. */
.round-record-shade{background:#08090bdd!important;backdrop-filter:none!important;-webkit-backdrop-filter:none!important}
.round-record-dialog{position:relative;width:min(520px,100%);height:min(820px,calc(100dvh - 24px));max-height:none!important;overflow:hidden!important;background:#0c0d11!important}
.round-record-dialog>.modal-head{display:none!important}
.round-record-dialog>.modal-body{height:100%;padding:0!important;overflow:hidden!important}
.round-recorder{position:relative;display:block;width:100%;height:100%;min-height:620px;overflow:hidden;background:#0d0e12;color:#fff;isolation:isolate}
.round-record-bg{position:absolute;z-index:-2;inset:-10%;width:120%;height:120%;object-fit:cover;filter:blur(44px) brightness(.45) saturate(1.15);transform:scale(1.12)}
.round-recorder:after{content:'';position:absolute;z-index:-1;inset:0;background:linear-gradient(180deg,#0b0c11b8 0,#0c0d1130 30%,#0a0b0edb 100%);pointer-events:none}
.round-record-back{position:absolute;z-index:5;left:14px;top:calc(14px + env(safe-area-inset-top));width:44px;height:44px;border-radius:50%;display:grid;place-items:center;background:#22242bc9;backdrop-filter:blur(12px)}
.round-record-camera{position:absolute;left:50%;top:42%;translate:-50% -50%;width:min(72vw,390px);height:min(72vw,390px);max-width:390px;max-height:390px;border-radius:50%;overflow:hidden;background:#15171d;box-shadow:0 0 0 1px #ffffff12,0 25px 80px #0009}
.round-record-camera .record-preview{position:absolute!important;inset:0!important;width:100%!important;height:100%!important;max-width:none!important;max-height:none!important;object-fit:cover!important;border-radius:50%!important;transform:none;background:#111}
.round-back-camera .round-record-camera .record-preview{transform:none}
.round-record-flip{position:absolute;left:14px;bottom:calc(64px + env(safe-area-inset-bottom));width:44px;height:44px;border-radius:50%;display:grid;place-items:center;background:#25272dd9;color:#fff}
.round-record-flip .i{width:21px;height:21px}
.round-record-lock{position:absolute;right:18px;bottom:calc(113px + env(safe-area-inset-bottom));width:42px;height:52px;display:grid;place-items:center;border-radius:12px;background:#3b3d44df;color:#fff;transition:.18s ease}
.round-record-lock span{display:grid;place-items:center}.round-record-lock .i{width:20px;height:20px}
.round-record-lock.active{background:#168cff;transform:translateY(-18px) scale(1.05)}
.round-record-hint{position:absolute;left:50%;bottom:calc(118px + env(safe-area-inset-bottom));translate:-50% 0;padding:7px 10px;border-radius:7px;background:#3a3b41d9;color:#ddd;text-align:center;font-size:10px;line-height:1.22;white-space:nowrap;transition:.18s ease}
.round-recording-locked .round-record-hint{opacity:0;transform:translateY(-12px)}
.round-record-clock{position:absolute;left:14px;bottom:calc(20px + env(safe-area-inset-bottom));display:flex;align-items:center;gap:7px;font:600 12px/1.2 ui-monospace,SFMono-Regular,Menlo,monospace;color:#e4e4e7}
.round-record-clock i{width:6px;height:6px;border-radius:50%;background:#ff416a;box-shadow:0 0 9px #ff416a}
.round-record-status{position:absolute;left:70px;right:70px;bottom:calc(75px + env(safe-area-inset-bottom));min-height:18px;text-align:center;color:#d7d8dd;font-size:12px;pointer-events:none}
.round-record-gesture{position:absolute;right:12px;bottom:calc(8px + env(safe-area-inset-bottom));width:84px;height:84px;display:grid;place-items:center}
.round-record-hold{width:68px!important;height:68px!important;min-width:68px;border-radius:50%!important;display:grid!important;place-items:center!important;padding:0!important;background:#078cff!important;color:#fff!important;box-shadow:0 5px 24px #078cff55,inset 0 0 0 1px #ffffff25;touch-action:none;transition:transform .12s ease}
.round-record-hold:active,.round-recording-live .round-record-hold{transform:scale(1.08)}.round-record-hold .i{width:28px;height:28px}
.round-record-locked-actions{position:absolute;left:12px;right:12px;bottom:calc(8px + env(safe-area-inset-bottom));height:70px;display:grid;grid-template-columns:1fr 1fr 1fr;align-items:center}
.round-record-locked-actions[hidden]{display:none!important}.round-record-locked-actions button{justify-self:center;width:54px;height:54px;border-radius:50%;display:grid;place-items:center;background:#22242b;color:#fff}.round-record-delete{color:#ff416a!important}.round-record-send{background:#078cff!important}.round-record-pause{color:#078cff!important;border:2px solid #078cff}.round-recording-paused .round-record-pause{background:#078cff!important;color:#fff!important}

/* Call surface: focused remote video, local PiP, participant strip and reactions. */
.call-screen.active-call-screen{background:#0c0d10!important}
.call-screen.active-call-screen .call-ambient{background:radial-gradient(circle at 50% 44%,#17233a 0,transparent 42%)!important}
.call-screen.active-call-screen .call-avatar{overflow:visible!important;box-shadow:0 0 0 1px #ffffff0d,0 0 50px 18px #445bff70,0 0 130px 44px #603cff42!important;transition:box-shadow .45s ease}
.call-screen.active-call-screen[data-phase="connected"] .call-avatar{box-shadow:0 0 0 1px #ffffff10,0 0 55px 18px #19d66d88,0 0 140px 46px #19d66d42!important}
.call-screen.active-call-screen .call-avatar img{border-radius:50%!important;overflow:hidden!important}
.call-screen.active-call-screen.has-remote-video .remote-videos{inset:0!important;padding:0!important;display:block!important;background:#090a0c!important}
.call-screen.active-call-screen.has-remote-video .remote-tile{position:absolute!important;inset:0!important;width:100%!important;height:100%!important;border-radius:0!important;border:0!important;background:#111!important}
.call-screen.active-call-screen.has-remote-video .remote-tile video{border-radius:0!important;object-fit:cover!important;background:#111!important}
.call-screen.group-call .remote-videos .remote-tile:not(.call-focus){display:none!important}
.call-screen.group-call .self-preview{display:none!important}
.call-participant-strip{position:absolute;z-index:24;left:50%;bottom:92px;translate:-50% 0;display:flex;gap:7px;max-width:min(92vw,680px);padding:3px;overflow-x:auto;scrollbar-width:none}.call-participant-strip::-webkit-scrollbar{display:none}.call-participant-strip[hidden]{display:none!important}
.call-participant-thumb{position:relative;flex:0 0 92px;width:92px;height:112px;padding:0!important;overflow:hidden;border-radius:17px;background:#24262d;box-shadow:inset 0 0 0 1px #ffffff12;color:#fff}.call-participant-thumb.active{box-shadow:inset 0 0 0 2px #2bdf72,0 0 0 1px #2bdf72}.call-thumb-media{position:absolute;inset:0;display:grid;place-items:center;font-size:28px;background:#30333b}.call-thumb-media video,.call-thumb-media img{width:100%;height:100%;object-fit:cover}.call-participant-thumb small{position:absolute;left:6px;bottom:6px;max-width:calc(100% - 12px);padding:3px 6px;border-radius:9px;background:#090a0bbf;color:#fff;font-size:10px;font-weight:700;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.call-participant-thumb.raised-hand:before{content:'✋';position:absolute;z-index:4;left:5px;top:5px;width:26px;height:26px;display:grid;place-items:center;border-radius:50%;background:#078cff;font-size:14px}
.call-screen.group-call .call-controls{bottom:14px!important}
.call-screen.active-call-screen .call-react{font-size:23px!important;line-height:1}.call-screen.active-call-screen .call-react:not([hidden]){display:grid!important;place-items:center}.call-screen.active-call-screen .call-react.active{background:#078cff!important}
.call-reaction-picker{position:absolute;z-index:40;left:50%;bottom:92px;translate:-50% 0;display:flex;gap:5px;padding:7px;border-radius:28px;background:#25272edb;backdrop-filter:blur(14px);box-shadow:0 10px 40px #0008}.call-reaction-picker button{width:43px;height:43px;padding:0;border-radius:50%;font-size:23px}
.call-reactions-layer{position:absolute;z-index:28;inset:70px 0 140px;pointer-events:none;overflow:hidden}.call-floating-reaction{position:absolute;left:var(--rx,50%);bottom:0;font-size:42px;filter:drop-shadow(0 8px 15px #0007);animation:callReactionFloat 2.1s cubic-bezier(.16,.8,.24,1) forwards}@keyframes callReactionFloat{0%{opacity:0;transform:translate(-50%,15px) scale(.65) rotate(-8deg)}20%{opacity:1;transform:translate(-50%,-30px) scale(1.05) rotate(6deg)}100%{opacity:0;transform:translate(-50%,-260px) scale(1.25) rotate(-5deg)}}

/* Call bottom menu / invite picker from the mobile reference. */
.call-menu-dialog>.modal-head{display:none!important}.reference-call-menu{gap:0!important;padding:6px 0}.reference-call-menu .menu-item{min-height:58px;border-radius:0;padding:10px 16px;gap:15px}.reference-call-menu .menu-item .i{width:22px;height:22px}.call-desktop-extra{border-top:1px solid #ffffff0b;margin-top:4px;padding-top:4px}
.call-invite-dialog{width:min(480px,100%);overflow:hidden}.call-invite-dialog>.modal-body{padding:0 14px 16px!important}.call-invite-search{display:flex;align-items:center;gap:7px;margin:4px 0 8px;padding:0 10px;border-radius:9px;background:#23252b}.call-invite-search>.i{width:17px;height:17px;color:#858892}.call-invite-search input{height:40px;padding:0!important;border:0!important;background:transparent!important}.call-invite-selected{display:flex;gap:9px;overflow-x:auto;min-height:0;padding:2px 0}.call-invite-chip{flex:0 0 54px;width:54px;padding:2px!important;text-align:center;background:transparent!important}.call-invite-chip .call-person-avatar{width:42px!important;height:42px!important;margin:auto}.call-invite-chip small{display:block;margin-top:2px;max-width:54px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.call-invite-tabs{display:flex;gap:18px;height:38px;align-items:flex-end;border-bottom:1px solid #ffffff08}.call-invite-tabs button{padding:8px 0 7px;border-radius:0;color:#92959e}.call-invite-tabs button.active{color:#fff;border-bottom:2px solid #168cff}.call-invite-list{max-height:55dvh;overflow:auto;padding:5px 0 65px}.call-invite-person{display:flex;align-items:center;gap:10px;width:100%;min-height:58px;padding:6px 2px;text-align:left;border-radius:8px}.call-invite-radio{width:22px;height:22px;flex:0 0 22px;border-radius:50%;display:grid;place-items:center;border:1.5px solid #555963;font-size:13px}.call-invite-person.selected .call-invite-radio{background:#078cff;border-color:#078cff}.call-invite-person .call-person-avatar{width:42px;height:42px;min-width:42px;border-radius:50%;display:grid;place-items:center;overflow:hidden;background:#333740}.call-invite-person .call-person-avatar img,.call-invite-chip .call-person-avatar img{width:100%;height:100%;object-fit:cover}.call-invite-person small{display:block;color:#888c96;font-size:12px;margin-top:2px}.call-invite-send-fab{position:absolute;right:16px;bottom:16px;width:54px!important;height:54px!important;border-radius:50%!important;display:grid!important;place-items:center!important;background:#078cff!important;color:#fff!important;box-shadow:0 8px 24px #0007}.call-invite-send-fab .i{width:23px;height:23px}
.call-profile-card{text-align:center;padding:12px}.call-profile-avatar{width:92px;height:92px;margin:0 auto 12px;border-radius:50%;display:grid;place-items:center;overflow:hidden;background:#343741;font-size:34px}.call-profile-avatar img{width:100%;height:100%;object-fit:cover}.call-profile-card p{margin-top:5px;color:var(--muted)}

/* Circular video playback: touchable circumference seek ring. */
.round-note{touch-action:pan-y}.round-note.scrubbing{touch-action:none}.round-ring{pointer-events:none}.round-progress-dot{pointer-events:none}

@media(max-width:760px){
 .global-search-shade{padding:0!important;align-items:stretch!important;background:var(--panel)!important}.global-search-dialog{width:100vw!important;height:var(--app-height,100dvh)!important;max-width:none!important;max-height:none!important;border-radius:0!important;box-shadow:none!important}.global-search-dialog>.modal-body{height:100%!important;display:flex;flex-direction:column}.global-search-head{padding:calc(8px + env(safe-area-inset-top)) 8px 7px}.global-search-results{flex:1;min-height:0;padding:2px 16px calc(18px + env(safe-area-inset-bottom));background:#17181c}.channel-directory-entry{margin-top:34px!important;margin-bottom:36px!important}.channel-directory-icon{width:82px;height:82px;border-radius:24px}.channel-directory-icon .i{width:46px!important;height:46px!important}
 .round-record-shade{padding:0!important;align-items:stretch!important}.round-record-dialog{width:100vw!important;height:var(--app-height,100dvh)!important;max-width:none!important;max-height:none!important;border-radius:0!important;box-shadow:none!important}.round-recorder{min-height:100%!important}.round-record-camera{top:43%;width:min(78vw,360px)!important;height:min(78vw,360px)!important}.round-record-status{bottom:calc(74px + env(safe-area-inset-bottom))}
 .call-screen.active-call-screen .call-quality{display:none!important}.call-screen.active-call-screen .call-title{z-index:27!important}.call-screen.active-call-screen #call-status{z-index:27!important}.call-screen.active-call-screen .call-top{z-index:28!important}.call-screen.active-call-screen.has-remote-video .self-preview{top:auto!important;right:10px!important;bottom:calc(92px + env(safe-area-inset-bottom))!important;width:96px!important;height:132px!important;border-radius:16px!important}.call-screen.group-call.has-remote-video .self-preview{display:none!important}.call-screen.group-call .call-participant-strip{bottom:calc(88px + env(safe-area-inset-bottom));max-width:calc(100vw - 10px)}.call-screen.group-call .call-participant-thumb{flex-basis:84px;width:84px;height:106px}.call-screen.group-call .remote-videos{bottom:0!important}.call-screen.group-call .call-controls{bottom:calc(8px + env(safe-area-inset-bottom))!important}.call-reaction-picker{bottom:calc(82px + env(safe-area-inset-bottom));max-width:calc(100vw - 20px)}
 .call-menu-shade{padding:0!important;align-items:flex-end!important}.call-menu-dialog{width:100%!important;max-width:none!important;border-radius:22px 22px 0 0!important;margin:0!important;padding-bottom:env(safe-area-inset-bottom)}.call-desktop-extra{display:none!important}.reference-call-menu .menu-item{min-height:60px!important;font-size:16px!important}
 .call-invite-shade{padding:0!important;align-items:stretch!important;background:#121317!important}.call-invite-dialog{width:100vw!important;height:var(--app-height,100dvh)!important;max-width:none!important;max-height:none!important;border-radius:0!important;box-shadow:none!important}.call-invite-dialog>.modal-head{height:54px!important;padding:calc(8px + env(safe-area-inset-top)) 10px 6px!important;position:relative!important}.call-invite-dialog>.modal-head h3{font-size:16px!important;text-align:center;flex:1}.call-invite-dialog>.modal-body{height:calc(100% - 54px);padding:0 12px!important;overflow:hidden!important}.call-invite-picker{height:100%;position:relative;display:flex!important;flex-direction:column!important;gap:0!important}.call-invite-list{flex:1;min-height:0;max-height:none;padding-bottom:76px}.call-invite-send-fab{bottom:calc(14px + env(safe-area-inset-bottom))}
}

/* NOVO 3.3.24 — iPhone round-video preview + stable mobile viewport + recorder spacing */
html{-webkit-text-size-adjust:100%;text-size-adjust:100%}
.round-record-camera{z-index:2}
.round-record-camera .record-preview{z-index:2!important;-webkit-backface-visibility:hidden;backface-visibility:hidden;will-change:transform;transform:translateZ(0)!important;-webkit-transform:translateZ(0)!important}
.round-back-camera .round-record-camera .record-preview{transform:translateZ(0)!important;-webkit-transform:translateZ(0)!important}
.round-recorder.round-static-bg,.round-static-bg .round-recorder{background:radial-gradient(circle at 50% 34%,#292d36 0,#17191f 34%,#0d0e12 72%)!important}
.round-static-bg .round-record-bg{display:none!important}
.round-preview-ready .round-record-camera{box-shadow:0 0 0 1px #ffffff17,0 25px 80px #0009}
.round-record-hold[hidden]{display:none!important}
.round-recording-locked .round-record-hint{display:none!important}
.round-recording-locked .round-record-status{bottom:calc(150px + env(safe-area-inset-bottom))!important}
.round-recording-locked .round-record-clock{left:50%!important;bottom:calc(91px + env(safe-area-inset-bottom))!important;translate:-50% 0!important;white-space:nowrap}
.round-recording-locked .round-record-flip{left:18px!important;bottom:calc(86px + env(safe-area-inset-bottom))!important}
.round-recording-locked .round-record-lock{right:18px!important;bottom:calc(86px + env(safe-area-inset-bottom))!important;transform:none!important}
.round-record-locked-actions{left:16px!important;right:16px!important;bottom:calc(8px + env(safe-area-inset-bottom))!important;height:68px!important;grid-template-columns:72px minmax(0,1fr) 72px!important;gap:8px!important;pointer-events:none}
.round-record-locked-actions button{pointer-events:auto;width:56px!important;height:56px!important;margin:0!important}
.round-record-locked-actions .round-record-delete{justify-self:start!important}
.round-record-locked-actions .round-record-pause{justify-self:center!important}
.round-record-locked-actions .round-record-send{justify-self:end!important}

@media(min-width:761px){
 .round-record-dialog{width:min(430px,calc(100vw - 32px))!important;height:min(820px,calc(100dvh - 28px))!important}
 .round-recorder{min-height:0!important;height:100%!important}
 .round-record-camera{top:39%!important;width:min(318px,72vw)!important;height:min(318px,72vw)!important}
 .round-record-hint{bottom:122px!important}
 .round-record-lock{bottom:118px!important}
 .round-record-status{bottom:80px!important}
 .round-record-flip{left:18px!important;bottom:66px!important}
 .round-record-clock{left:18px!important;bottom:18px!important}
 .round-record-gesture{right:16px!important;bottom:10px!important}
 .round-recording-locked .round-record-status{bottom:145px!important}
 .round-recording-locked .round-record-clock{bottom:88px!important}
 .round-recording-locked .round-record-flip,.round-recording-locked .round-record-lock{bottom:82px!important}
 .round-record-locked-actions{left:22px!important;right:22px!important;bottom:10px!important}
}

@media(max-width:760px){
 /* iOS Safari zooms focused controls below 16px; keep every editable search field at 16px. */
 .searchbox input,.global-search-box input,input[type="search"],input[type="text"],input[type="tel"],input[type="email"],input[type="password"],textarea,select{font-size:16px!important}
 .searchbox input{font-weight:500!important}
 .shell,body.keyboard-open .shell{left:0!important;top:0!important;width:100vw!important;max-width:100vw!important}
 .round-record-dialog{width:100vw!important;height:var(--app-height,100dvh)!important}
 .round-recorder{height:100%!important;min-height:100%!important}
 .round-record-camera{top:40%!important;width:min(76vw,350px)!important;height:min(76vw,350px)!important}
 .round-record-flip{left:18px!important;bottom:calc(70px + env(safe-area-inset-bottom))!important}
 .round-record-clock{left:18px!important;bottom:calc(18px + env(safe-area-inset-bottom))!important}
 .round-record-hint{bottom:calc(121px + env(safe-area-inset-bottom))!important;font-size:12px!important;padding:8px 12px!important}
 .round-record-lock{right:18px!important;bottom:calc(118px + env(safe-area-inset-bottom))!important;width:46px!important;height:58px!important}
 .round-record-status{left:74px!important;right:74px!important;bottom:calc(78px + env(safe-area-inset-bottom))!important;font-size:13px!important}
 .round-record-gesture{right:14px!important;bottom:calc(9px + env(safe-area-inset-bottom))!important;width:86px!important;height:86px!important}
 .round-record-hold{width:70px!important;height:70px!important;min-width:70px!important}
 .round-recording-locked .round-record-clock{bottom:calc(94px + env(safe-area-inset-bottom))!important}
 .round-recording-locked .round-record-flip,.round-recording-locked .round-record-lock{bottom:calc(89px + env(safe-area-inset-bottom))!important}
 .round-recording-locked .round-record-status{bottom:calc(153px + env(safe-area-inset-bottom))!important}
 .round-record-locked-actions{left:18px!important;right:18px!important;bottom:calc(9px + env(safe-area-inset-bottom))!important;height:70px!important;grid-template-columns:72px minmax(0,1fr) 72px!important}
}

@media(max-width:380px){
 .round-record-camera{width:min(74vw,305px)!important;height:min(74vw,305px)!important;top:39%!important}
 .round-record-hint{font-size:11px!important}
 .round-recording-locked .round-record-clock{bottom:calc(92px + env(safe-area-inset-bottom))!important}
 .round-recording-locked .round-record-flip,.round-recording-locked .round-record-lock{bottom:calc(88px + env(safe-area-inset-bottom))!important}
}


/* NOVO 3.3.25 — round camera switching and Android/WebView video reliability */
.round-record-flip[hidden]{display:none!important}
.round-record-flip.switching .i{animation:novoCameraFlip .7s linear infinite}
.round-record-flip:disabled{opacity:.65}

/* NOVO 3.3.27 — voice stability states; no layout changes to message bubbles. */
.voice-player.buffering .voice-toggle{position:relative;opacity:.82}
.voice-player.buffering .voice-toggle::after{content:'';position:absolute;inset:7px;border:2px solid currentColor;border-right-color:transparent;border-radius:50%;animation:novo-voice-spin .8s linear infinite}
.voice-player.buffering .voice-toggle>.i{opacity:.18}
@keyframes novo-voice-spin{to{transform:rotate(360deg)}}

/* NOVO 3.3.28 — charity channel + NOVO Control charity workspace */
.charity-avatar{position:relative;display:inline-grid;place-items:center;background:linear-gradient(145deg,#ff5b87,#7d4cff)!important;color:#fff!important;overflow:visible!important;box-shadow:0 8px 26px #7d4cff38,0 0 0 1px #ffffff18 inset}
.charity-avatar>img{width:100%;height:100%;object-fit:cover;border-radius:inherit;display:block}
.charity-avatar .charity-heart{display:grid;place-items:center;width:58%;height:58%}
.charity-avatar .charity-heart .i{width:100%;height:100%;stroke-width:1.75}
.charity-avatar>i{position:absolute;right:-2px;bottom:-2px;display:grid;place-items:center;width:18px;height:18px;border-radius:50%;background:#fff;color:#f04d7b;border:2px solid var(--bg,#19191f);font-size:13px;font-style:normal;font-weight:900;line-height:1;box-shadow:0 2px 8px #0006}
.charity-avatar.big>i{width:25px;height:25px;font-size:18px;right:0;bottom:0}
.charity-name-badge{display:inline-flex;align-items:center;justify-content:center;min-width:18px;height:18px;padding:0 5px;margin-left:6px;border-radius:7px;background:linear-gradient(135deg,#ff5b87,#8a58ff);color:#fff;font-size:11px;font-weight:900;vertical-align:1px;box-shadow:0 2px 8px #8a58ff38}
.charity-thread .chathead{border-bottom-color:#ff6d9a35}
.charity-thread .channel-readonly{background:linear-gradient(90deg,#ff5b8710,#8055d914);border:1px solid #ff6d9a26;border-radius:12px;margin:8px 12px;padding:10px 12px}
.charity-info-row{cursor:default!important}.charity-info-row>.i{color:#ff668f}.charity-info-row small{display:block;margin-top:3px;color:var(--muted)}

.charity-admin-hero{background:radial-gradient(circle at 78% 20%,#ff6a9630 0,transparent 34%),radial-gradient(circle at 14% 100%,#8055d932 0,transparent 42%),linear-gradient(135deg,#27232d,#1e1d26)!important;border-color:#ff6d9a2b!important}
.charity-admin-hero h2{letter-spacing:-.02em}.admin-live.charity-hidden{color:#c5c5ca;background:#ffffff0b;border-color:#ffffff14}.admin-live.charity-hidden i{background:#85858f;box-shadow:none}
.charity-admin-layout{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:14px;margin-top:14px}
.charity-settings-card,.charity-post-form{display:flex;flex-direction:column;gap:14px;min-width:0}
.charity-admin-title{align-items:flex-start;gap:16px}.charity-admin-title h3,.charity-post-form h3,.charity-recent-card h3{margin:0 0 4px}
.charity-admin-preview{display:flex;align-items:center;gap:14px;padding:13px;border-radius:16px;background:linear-gradient(135deg,#ff5b870d,#8055d912);border:1px solid #ffffff0b}
.charity-admin-preview .avatar.big{width:68px;height:68px;min-width:68px;border-radius:22px}.charity-admin-preview b{display:block;font-size:16px}.charity-admin-preview small{display:block;margin-top:5px;line-height:1.35;color:var(--muted);white-space:pre-wrap}
.charity-settings-actions,.charity-post-actions{flex-wrap:wrap;gap:8px}.charity-settings-actions .primary,.charity-post-actions .primary{margin-left:auto}
.charity-settings-actions button,.charity-post-actions button{display:inline-flex;align-items:center;justify-content:center;gap:7px}.charity-settings-actions .i,.charity-post-actions .i{width:18px;height:18px}
.charity-admin-note{font-size:12px;line-height:1.45;margin:0}
.charity-attachment{display:flex;align-items:center;gap:10px;border:1px solid #ffffff13;border-radius:13px;background:#ffffff08;padding:10px 12px;min-height:52px}.charity-attachment>span{display:grid;place-items:center;width:34px;height:34px;border-radius:10px;background:#8055d924;color:#aa8dff}.charity-attachment .i{width:19px;height:19px}.charity-attachment b,.charity-attachment small{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.charity-attachment small{color:var(--muted);margin-top:2px}
.charity-recent-card{margin-top:14px}.charity-admin-posts{display:grid;gap:10px;margin-top:14px}.charity-admin-post{padding:12px 14px;border-radius:14px;background:#ffffff06;border:1px solid #ffffff0b;overflow:hidden}.charity-admin-post-head{display:flex;align-items:center;gap:7px;color:var(--muted);font-size:12px}.charity-admin-post-head>span{display:grid;place-items:center}.charity-admin-post-head .i{width:16px;height:16px}.charity-admin-post-head b{color:var(--text);font-size:13px}.charity-admin-post-head small{margin-left:auto}.charity-admin-post p{margin:9px 0 0;white-space:pre-wrap;line-height:1.48}.charity-admin-post img,.charity-admin-post video{display:block;width:min(100%,520px);max-height:360px;object-fit:cover;border-radius:12px;margin-top:10px;background:#08090d}.charity-admin-post .file-link{margin-top:10px}
body.light .charity-admin-preview,body.light .charity-attachment,body.light .charity-admin-post{border-color:#1a1a2410;background:#15152507}
body.light .charity-admin-hero{background:radial-gradient(circle at 78% 20%,#ff6a9620 0,transparent 35%),radial-gradient(circle at 10% 100%,#8055d91d 0,transparent 44%),linear-gradient(135deg,#fff,#f7f3fb)!important}

@media(max-width:980px){.charity-admin-layout{grid-template-columns:1fr}}
@media(max-width:760px){.charity-admin-title{flex-direction:column}.charity-admin-title .switch-label{width:100%;justify-content:space-between}.charity-settings-actions,.charity-post-actions{display:grid;grid-template-columns:1fr 1fr}.charity-settings-actions .primary,.charity-post-actions .primary{margin-left:0;grid-column:1/-1}.charity-admin-preview .avatar.big{width:60px;height:60px;min-width:60px;border-radius:20px}.charity-recent-card>.row{align-items:flex-start;gap:10px}.charity-recent-card>.row>button{white-space:nowrap}}


/* NOVO 3.3.30 — channel thread left alignment + channel avatar auto-fit */
.channel-thread .message,
.channel-thread .message.mine{align-self:flex-start;align-items:flex-start;max-width:min(92%,560px)}
.channel-thread .message.channel-post .bubble{background:#2f313b;border-radius:16px 16px 16px 6px}
.channel-thread .message.channel-post .sender{display:block;margin-bottom:8px;color:#c5d5ff;font-size:12.5px;font-weight:700}
.channel-thread .message.channel-post .meta{justify-content:flex-end}
.channel-thread .message.channel-post .message-hover{right:auto;left:calc(100% + 8px)}
.channel-thread .message.channel-post.media-only .bubble{padding:8px}
.channel-thread .message.channel-post.contact-message .message-hover{left:calc(100% + 10px)}
@media (max-width:900px){
 .channel-thread .message,
 .channel-thread .message.mine{max-width:95%}
 .channel-thread .message.channel-post .message-hover{display:none}
}

/* NOVO 3.3.31 — group-wall identity and reference call controls */
.group-thread .message.group-message:not(.mine){display:grid;grid-template-columns:34px minmax(0,1fr);column-gap:8px;align-items:end;max-width:min(86%,610px)}
.group-thread .message.group-message:not(.mine)>.group-message-avatar{grid-column:1;grid-row:1;align-self:end;width:32px;height:32px;min-width:32px;margin:0 0 3px;padding:0;box-shadow:0 0 0 1px #ffffff12;background:#343844}
.group-thread .message.group-message:not(.mine)>.bubble{grid-column:2;grid-row:1;min-width:0}
.group-thread .message.group-message:not(.mine)>.message-hover{right:-78px;left:auto}
.message-sender-line{display:flex;align-items:center;justify-content:space-between;gap:12px;min-width:0;margin-bottom:5px}
.message-sender-line>.sender{margin:0!important;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.group-sender-role{flex:0 0 auto;color:#a9abb5;font-size:10px;font-weight:650;text-transform:lowercase}
.group-thread .message.group-message:not(.mine) .bubble{background:#2b2d35;border-radius:14px 14px 14px 5px}
.group-thread .message.group-message:not(.mine) .sender{color:#91b9ff}
.group-thread .message.group-message.mine .message-sender-line{display:none}

.call-invite-top{position:absolute;z-index:29;left:18px;top:16px;min-height:42px;padding:9px 14px;border-radius:22px;display:flex;align-items:center;gap:8px;background:#3e4149e8;color:#fff;font-size:13px;font-weight:750;box-shadow:0 8px 28px #0004;backdrop-filter:blur(12px)}
.call-invite-top .i{width:19px;height:19px}
.call-corner-tools{position:absolute;z-index:29;right:18px;bottom:18px;display:flex;align-items:center;gap:8px}
.call-corner-tools button{width:48px;height:48px;padding:0;border-radius:50%;display:grid;place-items:center;background:#3e4149e8;color:#fff;box-shadow:0 8px 28px #0004;backdrop-filter:blur(12px)}
.call-corner-tools .i{width:21px;height:21px}
.call-screen.active-call-screen #share-screen.active{background:#fff!important;color:#17191f!important}

@media(min-width:761px){
 .call-screen.active-call-screen .call-top{pointer-events:none!important}
 .call-screen.active-call-screen .call-top #min-call{position:absolute!important;right:0!important;top:0!important;pointer-events:auto!important}
 .call-screen.active-call-screen .call-top #call-settings{display:none!important}
 .call-screen.active-call-screen #toggle-speaker{display:none!important}
 .call-screen.active-call-screen #share-screen:not([hidden]){display:grid!important;place-items:center!important}
 .call-screen.active-call-screen .call-controls{left:50%!important;right:auto!important;translate:-50% 0!important}
}

@media(max-width:760px){
 .group-thread .message.group-message:not(.mine){grid-template-columns:30px minmax(0,1fr);column-gap:6px;max-width:94%!important}
 .group-thread .message.group-message:not(.mine)>.group-message-avatar{width:28px;height:28px;min-width:28px;margin-bottom:2px}
 .message-sender-line{gap:8px}.group-sender-role{font-size:9px}
 .call-invite-top{display:none!important}
 .call-corner-tools{display:none!important}
}

/* NOVO 3.3.31 hotfix 20261012.04 — adaptive camera framing + stable screen-share stage */
.call-screen.active-call-screen.has-remote-video .remote-tile.fit-contain video{
  object-fit:contain!important;
  object-position:center center!important;
  background:#090a0c!important;
}
.call-screen.active-call-screen.has-remote-video .remote-tile.fit-cover video{
  object-fit:cover!important;
  object-position:center center!important;
}
.call-screen.active-call-screen.remote-screen-active .remote-videos{
  inset:64px 12px 86px!important;
  padding:0!important;
  display:grid!important;
  place-items:center!important;
  overflow:hidden!important;
  border-radius:14px!important;
  background:#07080a!important;
  box-shadow:inset 0 0 0 1px #ffffff0a!important;
}
.call-screen.active-call-screen.remote-screen-active .remote-tile,
.call-screen.active-call-screen.remote-screen-active .remote-tile.call-focus{
  position:relative!important;
  inset:auto!important;
  width:100%!important;
  height:100%!important;
  max-width:none!important;
  max-height:none!important;
  border-radius:14px!important;
  background:#07080a!important;
}
.call-screen.active-call-screen.remote-screen-active .remote-tile video,
.call-screen.active-call-screen.remote-screen-active .remote-tile.fit-cover video,
.call-screen.active-call-screen.remote-screen-active .remote-tile.fit-contain video{
  position:absolute!important;
  inset:0!important;
  width:100%!important;
  height:100%!important;
  border-radius:14px!important;
  object-fit:contain!important;
  object-position:center center!important;
  background:#07080a!important;
}
.call-screen.active-call-screen.remote-screen-active .call-title,
.call-screen.active-call-screen.remote-screen-active #call-status{
  text-shadow:0 1px 12px #000!important;
}
.call-screen.active-call-screen.sharing-screen #share-screen{
  background:#fff!important;
  color:#17191f!important;
}
/* Local thumbnail always represents the camera, not a miniature copy of the shared desktop. */
.call-screen.active-call-screen.sharing-screen .self-preview .local-video{
  object-fit:cover!important;
}
@media(max-width:760px){
  .call-screen.active-call-screen.remote-screen-active .remote-videos{
    inset:calc(58px + env(safe-area-inset-top)) 6px calc(102px + env(safe-area-inset-bottom))!important;
    border-radius:10px!important;
  }
  .call-screen.active-call-screen.remote-screen-active .remote-tile,
  .call-screen.active-call-screen.remote-screen-active .remote-tile video{
    border-radius:10px!important;
  }
  .call-screen.active-call-screen.remote-screen-active.has-remote-video .self-preview{
    width:88px!important;
    height:118px!important;
    right:8px!important;
    bottom:calc(104px + env(safe-area-inset-bottom))!important;
    border-radius:15px!important;
  }
  .call-screen.active-call-screen.remote-screen-active.has-remote-video .self-preview .local-video{
    border-radius:13px!important;
  }
  .call-screen.active-call-screen.remote-screen-active .call-title{
    top:calc(8px + env(safe-area-inset-top))!important;
    left:64px!important;
    right:64px!important;
  }
  .call-screen.active-call-screen.remote-screen-active #call-status{
    top:calc(29px + env(safe-area-inset-top))!important;
    left:64px!important;
    right:64px!important;
  }
}

/* NOVO Reference Parity — grouped messages, group info, stories */
.group-thread .message.group-message:not(.mine){grid-template-columns:34px minmax(0,1fr)}
.group-thread .message.group-message:not(.mine)>.group-avatar-slot{grid-column:1;grid-row:1;align-self:end;width:32px;min-width:32px;height:32px;margin-bottom:3px;display:grid;place-items:center}
.group-thread .group-avatar-hit{width:32px;height:32px;padding:0;border-radius:50%;display:grid;place-items:center;background:transparent;overflow:visible}
.group-thread .group-avatar-hit .avatar{width:32px;height:32px;min-width:32px;margin:0}
.group-thread .message.group-continuation{margin-top:-4px}
.group-thread .message.group-first:not(.mine) .bubble{border-bottom-left-radius:7px}
.group-thread .message.group-continuation:not(.mine) .bubble{border-top-left-radius:7px;border-bottom-left-radius:7px}
.group-thread .message.group-last:not(.mine) .bubble{border-bottom-left-radius:5px}
.group-thread .message.group-continuation:not(.mine) .message-sender-line{display:none}
.group-thread .message.group-continuation.mine .bubble{border-top-right-radius:7px}
.group-thread .message.group-last{margin-bottom:4px}
.group-member-profile{text-align:center}.group-member-profile .actions{max-width:360px;margin:18px auto}.group-member-profile .card{text-align:left}
.group-info-ref{max-width:560px;margin:0 auto}.group-profile-header{padding-top:4px}.group-info-actions{justify-content:center;flex-wrap:nowrap}.group-info-actions button{min-width:0}.group-info-actions button span{font-size:10px}.group-admin-card{width:100%;display:flex;align-items:center;gap:12px;text-align:left}.group-admin-card .group-admin-icon{width:38px;height:38px;border-radius:12px;background:#ffffff0a;display:grid;place-items:center}.group-admin-card small{display:block;margin-top:3px}.group-content-card{padding-left:0;padding-right:0}.group-info-tabs{padding:0 16px}.group-info-ref #group-info-content{padding:8px 14px 14px}.group-member-row,.group-admin-person{min-height:60px}.group-add-member{color:var(--blue)}
.story-viewer{background:#05060bdc;backdrop-filter:blur(16px)}
.story-view{height:min(96dvh,860px);width:min(430px,100vw);border-radius:18px;background:#0f1015;box-shadow:0 30px 100px #0008}
.story-progress{position:absolute;z-index:5;left:10px;right:10px;top:8px;height:3px;border-radius:3px;background:#ffffff30;overflow:hidden}.story-progress i{display:block;width:100%;height:100%}.story-progress span{display:block;width:100%;height:100%;background:#fff;transform-origin:left center;transform:scaleX(0);will-change:transform}
.story-top{padding:18px 12px 12px;background:linear-gradient(#000b,transparent);z-index:4}.story-top .story-author{padding:0;text-align:left;display:flex;flex-direction:column;gap:2px;min-width:0}.story-top .story-author b{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.story-top .story-author small{font-size:10px}.story-top>button:not(.story-author){padding:7px}
.story-stage{position:absolute;inset:0;display:grid;place-items:center;overflow:hidden;touch-action:pan-y;background:#090a0e}.story-stage>img,.story-stage>video{width:100%;height:100%;object-fit:contain;user-select:none;-webkit-user-drag:none}.story-tap-zone{position:absolute;top:70px;bottom:90px;width:34%;z-index:1;pointer-events:none}.story-tap-left{left:0}.story-tap-right{right:0}.story-pause-indicator{position:absolute;z-index:6;width:58px;height:58px;border-radius:50%;background:#0008;display:grid;place-items:center;backdrop-filter:blur(8px)}.story-pause-indicator .i{width:26px;height:26px}.story-bottom{z-index:4;padding:60px 14px 16px;background:linear-gradient(transparent,#000c)}.story-reply-row{display:flex;align-items:center;gap:8px}.story-reply-row input{background:#ffffff18;border-color:#ffffff20;min-height:44px}.story-reply-row button{width:44px;height:44px;padding:0;border-radius:50%;display:grid;place-items:center;background:#ffffff18}.story-reply-row button.liked{color:#ff4f79;background:#ff4f7920}.story-caption{font-size:14px;line-height:1.4}.story-buffering .story-stage:after{content:'Загрузка…';position:absolute;z-index:7;padding:8px 12px;border-radius:16px;background:#0009;color:#fff;font-size:12px}
@media(max-width:760px){.group-thread .message.group-message:not(.mine)>.group-avatar-slot{width:28px;min-width:28px;height:28px;margin-bottom:2px}.group-thread .group-avatar-hit,.group-thread .group-avatar-hit .avatar{width:28px;height:28px;min-width:28px}.group-info-actions{gap:5px}.group-info-actions button{padding:9px 5px}.story-view{height:100dvh;width:100vw;border-radius:0;max-height:none}.story-top{padding-top:max(20px,env(safe-area-inset-top))}.story-bottom{padding-bottom:max(14px,env(safe-area-inset-bottom))}.story-progress{top:max(6px,env(safe-area-inset-top))}}


/* Reels */
.reels-page-note{padding:28px 22px;color:var(--muted);text-align:center;display:flex;flex-direction:column;gap:10px;align-items:center;justify-content:center;height:100%}
.reels-page-note .i{width:44px;height:44px;color:#6c82ff}
.reels-tabs{gap:12px;padding:0 16px 10px}
.reels-grid{display:flex;flex-direction:column;gap:10px;padding:10px 10px 18px}
.reel-card{width:100%;display:grid;grid-template-columns:86px minmax(0,1fr);gap:12px;padding:10px;background:#1d1f26;border:1px solid #ffffff0b;border-radius:16px;text-align:left;align-items:start}
.reel-card:hover{border-color:#ffffff20;background:#22242d}
.reel-thumb{width:86px;height:122px;border-radius:14px;overflow:hidden;background:#111318;position:relative;display:grid;place-items:center}
.reel-thumb img,.reel-thumb video{width:100%;height:100%;object-fit:cover}
.reel-thumb .reel-play{position:absolute;right:8px;bottom:8px;width:30px;height:30px;border-radius:50%;background:#0008;display:grid;place-items:center}
.reel-thumb .reel-play .i{width:16px;height:16px;color:#fff}
.reel-meta{min-width:0;display:flex;flex-direction:column;gap:6px}
.reel-headline{display:flex;align-items:center;gap:8px;min-width:0}
.reel-headline .avatar{width:32px;height:32px;min-width:32px;font-size:13px}
.reel-headline b,.reel-caption{overflow:hidden;text-overflow:ellipsis;display:-webkit-box;-webkit-box-orient:vertical}
.reel-headline b{-webkit-line-clamp:1}
.reel-caption{-webkit-line-clamp:2;color:#d8d9de;line-height:1.34}
.reel-tags{display:flex;gap:6px;flex-wrap:wrap}
.reel-tags span{padding:4px 8px;border-radius:999px;background:#2a2c35;color:#9fc3ff;font-size:11px}
.reel-stats{display:flex;gap:10px;flex-wrap:wrap;color:var(--muted);font-size:12px}
.reel-stats span{display:flex;align-items:center;gap:4px}
.reel-stats .i{width:14px;height:14px}
.reels-actions{padding:0 12px 12px}
.reels-empty-state{padding:34px 22px;text-align:center;color:var(--muted)}
.reel-create-preview{border-radius:18px;overflow:hidden;background:#13151a;margin-bottom:14px}
.reel-create-preview video{width:100%;max-height:46dvh;display:block;background:#000}
.reel-inline-hint{font-size:12px;color:var(--muted);margin-top:-4px}
.reel-viewer{position:fixed;inset:0;background:#000d;backdrop-filter:blur(8px);z-index:120;display:flex;align-items:center;justify-content:center;padding:18px}
.reel-stage{width:min(1120px,100%);height:min(92dvh,860px);display:grid;grid-template-columns:minmax(0,1fr) 340px;gap:0;background:#111318;border:1px solid #ffffff12;border-radius:24px;overflow:hidden;box-shadow:0 30px 90px #0008}
.reel-video-wrap{background:#050607;display:flex;align-items:center;justify-content:center;position:relative;min-width:0}
.reel-video-wrap video{width:100%;height:100%;object-fit:contain;background:#000}
.reel-close{position:absolute;top:14px;right:14px;z-index:2;background:#111a}
.reel-nav-arrow{position:absolute;top:50%;transform:translateY(-50%);background:#111a;width:42px;height:42px;border-radius:50%;display:grid;place-items:center;z-index:2}
.reel-nav-arrow.prev{left:14px}.reel-nav-arrow.next{right:14px}
.reel-side{display:flex;flex-direction:column;min-width:0;background:#17191f}
.reel-side-head{display:flex;align-items:center;gap:10px;padding:16px 18px;border-bottom:1px solid #ffffff10}
.reel-side-head .avatar{width:42px;height:42px;min-width:42px}
.reel-side-head .grow{min-width:0}.reel-side-head b{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.reel-side-body{padding:16px 18px 18px;display:flex;flex-direction:column;gap:14px;overflow:auto}
.reel-side-body p{white-space:pre-wrap;line-height:1.45;color:#dde0e8}
.reel-side-tags{display:flex;gap:8px;flex-wrap:wrap}
.reel-side-tags span{padding:5px 10px;border-radius:999px;background:#242733;color:#8db8ff;font-size:12px}
.reel-side-actions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
.reel-side-actions button{display:flex;align-items:center;justify-content:center;gap:8px;min-height:44px;background:#242733}
.reel-side-actions button.like.active{background:#142b49;color:#7bb7ff}
.reel-side-stats{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
.reel-side-stats div{padding:10px 12px;border-radius:14px;background:#1f222c;color:#a8acb8}
.reel-side-stats b{display:block;color:#fff;font-size:18px;margin-bottom:4px}
.reel-share-list{max-height:52dvh;overflow:auto;display:flex;flex-direction:column;gap:6px}
.reel-comment-list{display:flex;flex-direction:column;gap:10px;max-height:42dvh;overflow:auto;margin-top:8px}
.reel-comment{padding:10px 12px;border-radius:14px;background:#20222a}
.reel-comment-head{display:flex;align-items:center;gap:8px;margin-bottom:5px}.reel-comment-head .avatar{width:28px;height:28px;min-width:28px;font-size:12px}
.reel-comment-head b{font-size:13px}.reel-comment-head small{margin-left:auto;color:var(--muted);font-size:11px}
.reel-comment p{white-space:pre-wrap;line-height:1.4;color:#dfe1e6}
@media(max-width:920px){.reel-stage{grid-template-columns:1fr;height:min(96dvh,980px)}.reel-side{max-height:40dvh}.reel-video-wrap{min-height:42dvh}}
@media(max-width:760px){.reel-card{grid-template-columns:74px minmax(0,1fr);padding:9px}.reel-thumb{width:74px;height:110px}.reel-viewer{padding:0}.reel-stage{width:100%;height:100dvh;border-radius:0;border:0;grid-template-columns:1fr;grid-template-rows:minmax(0,1fr) auto}.reel-side{max-height:42dvh;border-top:1px solid #ffffff10}.reel-side-actions{grid-template-columns:repeat(3,minmax(0,1fr))}.reel-side-stats{grid-template-columns:repeat(4,minmax(0,1fr))}.reels-grid{padding:8px 8px 85px}.reels-actions{padding-bottom:85px}}

/* NOVO 3.3.33 — immersive Reels parity */
.shell.reels-mode{grid-template-columns:72px minmax(0,1fr)}
.shell.reels-mode .sidebar{display:none}
.shell.reels-mode .main{grid-column:2;display:flex;min-width:0;background:#08090c}
.reels-main{position:relative;overflow:hidden!important;background:#08090c!important}
.reels-feed{width:100%;height:100%;overflow-y:auto;overflow-x:hidden;scroll-snap-type:y mandatory;overscroll-behavior-y:contain;scrollbar-width:none;background:#08090c}
.reels-feed::-webkit-scrollbar{display:none}
.reel-slide{position:relative;width:100%;height:100%;min-height:100%;scroll-snap-align:start;scroll-snap-stop:always;overflow:hidden;background:#050609;display:flex;align-items:center;justify-content:center;isolation:isolate}
.reel-media{position:absolute;inset:0;display:flex;align-items:center;justify-content:center;background:#050609;cursor:pointer}
.reel-media video{display:block;width:100%;height:100%;object-fit:cover;object-position:center center;background:#050609}
.reel-media:before{content:'';position:absolute;inset:0;background:radial-gradient(circle at center,transparent 45%,#0005 100%);pointer-events:none;z-index:1}
.reel-pause-mark{position:absolute;left:50%;top:50%;transform:translate(-50%,-50%) scale(.88);width:68px;height:68px;border-radius:50%;display:grid;place-items:center;background:#0008;color:#fff;opacity:0;transition:.16s;z-index:4;pointer-events:none}
.reel-pause-mark .i{width:28px;height:28px}
.reel-video-hit.paused .reel-pause-mark{opacity:1;transform:translate(-50%,-50%) scale(1)}
.reel-top-glass{position:absolute;top:0;left:0;right:0;z-index:7;display:flex;align-items:center;justify-content:center;gap:14px;padding:16px 22px 48px;background:linear-gradient(#000c,transparent);pointer-events:none}
.reel-top-glass>*{pointer-events:auto}
.reel-add-button{position:absolute;left:20px;top:17px;width:42px;height:42px;padding:9px;border-radius:50%;background:#252832d9;color:#fff;backdrop-filter:blur(18px)}
.reel-mode-tabs{display:flex;align-items:center;gap:22px;padding:7px 13px;border-radius:999px;background:#11131a99;backdrop-filter:blur(18px)}
.reel-mode-tabs button{padding:5px 1px;border-radius:0;color:#b8bac3;font-weight:700;font-size:13px;border-bottom:2px solid transparent}
.reel-mode-tabs button.active{color:#fff;border-color:#fff}
.reel-overlay-bottom{position:absolute;z-index:6;left:max(22px,calc((100% - 650px)/2));right:min(132px,calc((100% - 650px)/2 + 112px));bottom:28px;color:#fff;text-shadow:0 1px 5px #000;display:flex;flex-direction:column;gap:8px;pointer-events:none}
.reel-overlay-bottom>*{pointer-events:auto}
.reel-author-line{display:flex;align-items:center;gap:10px;min-width:0}
.reel-author-line .avatar{width:38px;height:38px;min-width:38px;border:1px solid #ffffff66}
.reel-author-line .grow{min-width:0}
.reel-author-line b,.reel-author-line small{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.reel-author-line small{font-size:11px;color:#d4d6dc;margin-top:2px}
.reel-profile-btn{padding:7px 12px;border-radius:9px;background:#ffffff18;border:1px solid #ffffff30;color:#fff;font-size:11px;font-weight:700}
.reel-caption-feed{max-width:560px;line-height:1.42;font-size:14px;white-space:pre-wrap;display:-webkit-box;-webkit-line-clamp:3;-webkit-box-orient:vertical;overflow:hidden}
.reel-feed-tags{display:flex;gap:7px;flex-wrap:wrap;max-width:560px}
.reel-feed-tags button{padding:0;color:#d8e8ff;text-shadow:0 1px 5px #000;font-size:13px;font-weight:700}
.reel-actions-rail{position:absolute;right:max(22px,calc((100% - 650px)/2));bottom:32px;z-index:7;display:flex;flex-direction:column;align-items:center;gap:13px}
.reel-action{width:54px;min-height:54px;border-radius:50%;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:3px;background:#191b22d9;color:#fff;backdrop-filter:blur(16px);box-shadow:0 4px 22px #0004}
.reel-action .i{width:23px;height:23px}
.reel-action span{font-size:10px;line-height:1}
.reel-action.like.active{color:#ff476d;background:#311922e6}
.reel-view-count{position:absolute;right:max(24px,calc((100% - 650px)/2 + 4px));top:80px;z-index:6;display:flex;align-items:center;gap:5px;padding:6px 9px;border-radius:999px;background:#11131ab3;color:#dfe2e8;font-size:11px;backdrop-filter:blur(16px)}
.reel-view-count .i{width:13px;height:13px}
.reels-loading,.reels-empty{height:100%;width:100%;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:12px;text-align:center;color:var(--muted);padding:24px}
.reels-loading.small{height:auto;min-height:100px}.reels-empty>div .i,.reels-empty>.i{width:46px;height:46px;color:#638dff}.spinner{width:28px;height:28px;border-radius:50%;border:3px solid #ffffff18;border-top-color:#6fa9ff;animation:reelSpin .8s linear infinite}@keyframes reelSpin{to{transform:rotate(360deg)}}
.reel-sheet-shade{position:fixed;inset:0;z-index:180;background:#0009;backdrop-filter:blur(6px);display:flex;align-items:flex-end;justify-content:center}
.reel-sheet{width:min(520px,100%);max-height:min(84dvh,720px);display:flex;flex-direction:column;background:#1b1d24;border:1px solid #ffffff12;border-radius:22px 22px 0 0;box-shadow:0 -18px 70px #0009;overflow:hidden}
.reel-sheet-handle{width:42px;height:4px;border-radius:999px;background:#ffffff33;margin:9px auto 1px}
.reel-sheet header{height:56px;display:flex;align-items:center;gap:10px;padding:0 16px;border-bottom:1px solid #ffffff0d;flex-shrink:0}
.reel-sheet header h3{flex:1;font-size:17px}.reel-sheet-close{width:36px;height:36px;padding:8px;border-radius:50%;background:#292c35}.reel-sheet-body{min-height:0;overflow:auto;padding:14px 16px max(18px,env(safe-area-inset-bottom));overscroll-behavior:contain}
.reel-sheet-note{color:#9fa2ad;line-height:1.4;margin-bottom:12px}
.reel-comment-compose{display:grid;grid-template-columns:minmax(0,1fr) 46px;gap:8px;align-items:end;margin-bottom:13px;position:sticky;top:-14px;background:#1b1d24;padding:0 0 10px;z-index:2}
.reel-comment-compose textarea{min-height:44px;max-height:110px;resize:none;font-size:16px;background:#252830;border-radius:14px;padding:11px 13px}
.reel-comment-compose button{width:46px;height:44px;padding:10px;border-radius:14px}
.reel-comment-list{display:flex;flex-direction:column;gap:8px;max-height:none;overflow:visible;margin:0}
.reel-comment{padding:11px 12px;border-radius:14px;background:#22252d;border:1px solid #ffffff08}
.reel-comment-head{display:flex;align-items:center;gap:9px;margin-bottom:7px}.reel-comment-head .avatar{width:31px;height:31px;min-width:31px}.reel-comment-head .grow{min-width:0}.reel-comment-head b{display:block;font-size:13px}.reel-comment-head small{display:block;color:#888c98;font-size:10px;margin-top:1px}.reel-comment p{margin:0;white-space:pre-wrap;line-height:1.42;color:#e7e8ec;font-size:13px}
.reel-share-tools{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin-bottom:12px}.reel-share-tools button{min-height:50px;border-radius:14px;background:#272a33;display:flex;align-items:center;justify-content:center;gap:8px;font-weight:700}.reel-share-tools .i{width:20px;height:20px}
.reel-share-search{display:flex;align-items:center;gap:8px;background:#252830;border-radius:14px;padding:0 12px;margin-bottom:12px}.reel-share-search .i{width:18px;height:18px;color:#9396a2}.reel-share-search input{border:0;background:transparent;padding:12px 0;font-size:16px;min-width:0}
.reel-share-rows{display:flex;flex-direction:column;gap:4px;min-height:0}.reel-share-row{width:100%;display:flex;align-items:center;gap:11px;min-height:60px;padding:7px 8px;border-radius:13px;text-align:left}.reel-share-row:hover{background:#272a33}.reel-share-row>.avatar{width:43px;height:43px;min-width:43px}.reel-share-row .grow{min-width:0}.reel-share-row b,.reel-share-row small{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.reel-share-row small{color:#8e919c;margin-top:3px}.reel-share-row>.i{width:19px;height:19px;color:#7fb7ff;flex-shrink:0}
.reel-create{display:flex;flex-direction:column;gap:11px}.reel-create-preview{width:min(260px,78vw);aspect-ratio:9/16;max-height:45dvh;margin:0 auto 5px;border-radius:18px;overflow:hidden;background:#050609}.reel-create-preview video{width:100%;height:100%;object-fit:contain;background:#000}.reel-create .field textarea,.reel-create .field input{font-size:16px!important}.reel-inline-hint{color:#8f929e;font-size:12px;line-height:1.4;margin-top:-4px}
@media(min-width:761px){
 .reel-slide{padding:14px 0}.reel-media{left:50%;right:auto;width:min(520px,52vw);transform:translateX(-50%);border-radius:18px;overflow:hidden;box-shadow:0 16px 70px #0008}.reel-media:after{content:'';position:absolute;inset:0;border:1px solid #ffffff0d;border-radius:18px;pointer-events:none;z-index:2}.reel-top-glass{left:50%;right:auto;width:min(520px,52vw);transform:translateX(-50%);border-radius:18px 18px 0 0}.reel-overlay-bottom{left:calc(50% - min(260px,26vw) + 18px);right:calc(50% - min(260px,26vw) + 86px);bottom:28px}.reel-actions-rail{right:calc(50% - min(260px,26vw) - 72px);bottom:34px}.reel-view-count{right:calc(50% - min(260px,26vw) + 12px);top:30px}
}
@media(max-width:760px){
 .mobile-nav{grid-template-columns:repeat(5,minmax(0,1fr))!important}.mobile-nav .navbtn{font-size:8.5px!important;gap:1px!important}.mobile-nav .navbtn svg,.mobile-nav .i{width:21px!important;height:21px!important}
 .shell.reels-mode{grid-template-columns:minmax(0,1fr)!important;grid-template-rows:minmax(0,1fr) calc(57px + env(safe-area-inset-bottom))!important}.shell.reels-mode .sidebar{display:none!important}.shell.reels-mode .main{display:flex!important;grid-column:1!important;grid-row:1!important}
 .reels-main{padding-top:0!important}.reel-slide{height:100%;min-height:100%;padding:0}.reel-media{inset:0}.reel-media video{object-fit:cover;object-position:center center}.reel-top-glass{padding:max(10px,env(safe-area-inset-top)) 12px 46px}.reel-add-button{left:11px;top:max(10px,env(safe-area-inset-top));width:38px;height:38px;padding:8px}.reel-mode-tabs{gap:15px;padding:6px 10px;margin-top:max(0px,env(safe-area-inset-top))}.reel-mode-tabs button{font-size:12px}.reel-overlay-bottom{left:14px;right:76px;bottom:16px}.reel-author-line .avatar{width:34px;height:34px;min-width:34px}.reel-caption-feed{font-size:13px;-webkit-line-clamp:2}.reel-feed-tags{gap:5px}.reel-feed-tags button{font-size:12px}.reel-profile-btn{padding:5px 9px;font-size:10px}.reel-actions-rail{right:10px;bottom:18px;gap:10px}.reel-action{width:48px;min-height:48px}.reel-action .i{width:22px;height:22px}.reel-view-count{right:12px;top:calc(max(10px,env(safe-area-inset-top)) + 52px)}
 .reel-sheet{max-height:86dvh;border-radius:24px 24px 0 0}.reel-sheet-body{padding-left:13px;padding-right:13px}.reel-share-tools{grid-template-columns:1fr 1fr}.reel-share-row{min-height:58px}.reel-create-preview{width:min(240px,70vw);max-height:38dvh}
}
.reel-sound-button{position:absolute;right:20px;top:17px;width:42px;height:42px;padding:9px;border-radius:50%;background:#252832d9;color:#fff;backdrop-filter:blur(18px)}
.reel-sound-button .i{width:21px;height:21px}
@media(max-width:760px){.reel-sound-button{right:11px;top:max(10px,env(safe-area-inset-top));width:38px;height:38px;padding:8px}}


/* NOVO Reels controls + media parity hotfix · web revision 20261012.04 */
.reel-media img{display:block;width:100%;height:100%;object-fit:cover;object-position:center center;background:#050609;user-select:none;-webkit-user-drag:none}
.reel-author-line{border:0;padding:0;background:transparent;text-align:left;color:inherit;border-radius:12px;max-width:100%;cursor:pointer}
.reel-author-line:hover{background:#ffffff0c}
.reels-exit-button{position:absolute;top:20px;right:24px;z-index:20;width:46px;height:46px;padding:11px;border-radius:50%;display:grid;place-items:center;background:#20232cd9;color:#fff;backdrop-filter:blur(18px);box-shadow:0 7px 26px #0006}
.reels-exit-button .i{width:24px;height:24px}
.reels-desktop-switch{position:absolute;right:28px;top:50%;transform:translateY(-50%);z-index:19;display:flex;flex-direction:column;gap:12px}
.reels-desktop-switch button{width:50px;height:50px;padding:13px;border-radius:50%;display:grid;place-items:center;background:#20232cd9;color:#fff;backdrop-filter:blur(18px);box-shadow:0 7px 26px #0006}
.reels-desktop-switch button:disabled{opacity:.35}
.reels-desktop-switch .i{width:24px;height:24px}
.reel-heart-burst{position:absolute;left:50%;top:50%;width:0;height:0;z-index:30;pointer-events:none;filter:drop-shadow(0 5px 18px #0008)}
.reel-heart-burst span{position:absolute;left:0;top:0;color:#ff315d;font-size:76px;line-height:1;opacity:0;transform:translate(-50%,-50%) scale(.35);animation:novoReelHeart 2.25s cubic-bezier(.17,.89,.32,1.3) forwards}
.reel-heart-burst span:nth-child(2){font-size:38px;animation-delay:.10s;--hx:-62px;--hy:-72px}
.reel-heart-burst span:nth-child(3){font-size:30px;animation-delay:.18s;--hx:58px;--hy:-54px}
@keyframes novoReelHeart{0%{opacity:0;transform:translate(-50%,-50%) scale(.35)}12%{opacity:1;transform:translate(calc(-50% + var(--hx,0px)),calc(-50% + var(--hy,0px))) scale(1.15)}62%{opacity:1;transform:translate(calc(-50% + var(--hx,0px)),calc(-50% + var(--hy,-20px))) scale(1)}100%{opacity:0;transform:translate(calc(-50% + var(--hx,0px)),calc(-50% + var(--hy,-80px))) scale(.8)}}
.reel-create-preview img{width:100%;height:100%;object-fit:contain;background:#000;display:block}
.reel-user-profile .actions button{min-height:68px}
@media(max-width:760px){
 .shell{grid-template-rows:minmax(0,1fr) calc(64px + env(safe-area-inset-bottom))!important}
 .shell.reels-mode{grid-template-rows:minmax(0,1fr) calc(64px + env(safe-area-inset-bottom))!important}
 .mobile-nav{height:calc(64px + env(safe-area-inset-bottom))!important;min-height:64px!important;padding:3px 0 env(safe-area-inset-bottom)!important}
 .mobile-nav .navbtn{height:61px!important;min-height:61px!important;font-size:10.5px!important;font-weight:600!important;gap:3px!important;padding:5px 0 4px!important}
 .mobile-nav .navbtn svg,.mobile-nav .i{width:26px!important;height:26px!important}
 .reel-actions-rail{right:12px!important;bottom:20px!important;gap:11px!important;align-items:center!important}
 .reel-action{width:52px!important;height:52px!important;min-width:52px!important;min-height:52px!important;max-width:52px!important;max-height:52px!important;padding:7px!important;flex:0 0 52px!important;border-radius:50%!important}
 .reel-action .i{width:24px!important;height:24px!important}
 .reel-action span{font-size:10px!important;line-height:10px!important;min-height:10px}
 .reels-desktop-switch{display:none!important}
 .reels-exit-button{top:max(10px,env(safe-area-inset-top));right:11px;width:40px;height:40px;padding:9px;z-index:24}
 .reels-exit-button .i{width:22px;height:22px}
 .reel-sound-button{right:59px!important;top:max(10px,env(safe-area-inset-top))!important;width:40px!important;height:40px!important;padding:9px!important}
 .reel-add-button{width:40px!important;height:40px!important}
 .reel-mode-tabs{max-width:calc(100vw - 156px);gap:13px!important}
 .reel-overlay-bottom{bottom:20px!important}
 .reel-author-line{padding:2px 4px 2px 0!important}
 .reel-media img{object-fit:cover;object-position:center center}
 .reel-heart-burst span{font-size:68px}
}


/* NOVO Reels camera + edge-fill hotfix · web revision 20261012.04 */
.reel-camera-capture{display:flex;flex-direction:column;gap:12px}
.reel-camera-stage{position:relative;width:min(420px,92vw);aspect-ratio:9/16;max-height:68dvh;margin:0 auto;border-radius:20px;overflow:hidden;background:#050609;box-shadow:0 16px 50px #0007}
.reel-camera-preview{width:100%;height:100%;display:block;object-fit:cover;background:#050609}
.reel-camera-status{position:absolute;left:50%;top:50%;transform:translate(-50%,-50%);padding:8px 12px;border-radius:999px;background:#11131abf;color:#fff;font-size:12px;backdrop-filter:blur(12px)}
.reel-camera-flip{position:absolute;right:12px;top:12px;width:44px;height:44px;padding:10px;border-radius:50%;background:#20232cdb;display:grid;place-items:center;backdrop-filter:blur(16px)}
.reel-camera-flip .i{width:23px;height:23px}
.reel-camera-footer{display:grid;grid-template-columns:1fr auto 1fr;align-items:center;gap:14px;padding:0 8px}
.reel-camera-time{font-variant-numeric:tabular-nums;color:#c5c8d1;font-weight:700;min-width:48px}
.reel-camera-shutter{width:68px;height:68px;padding:6px;border-radius:50%;border:3px solid #fff;background:#ffffff18;display:grid;place-items:center;justify-self:center}
.reel-camera-shutter span{width:48px;height:48px;border-radius:50%;background:#fff;display:block;transition:.16s}
.reel-camera-shutter.video-mode span{background:#ff3d64}
.reel-camera-shutter.recording span{width:28px;height:28px;border-radius:7px;background:#ff3d64}
.reel-camera-cancel{justify-self:end;color:#d6d7dc;background:#2a2d36;min-width:76px}
@media(max-width:760px){
 .reel-camera-stage{width:min(94vw,430px);max-height:64dvh;border-radius:18px}
 .reel-camera-footer{padding:0 4px}.reel-camera-shutter{width:64px;height:64px}.reel-camera-shutter span{width:44px;height:44px}
 .reel-camera-flip{width:42px;height:42px}
}


/* NOVO 3.3.36 · reference-aligned long composer */
.composer{align-items:flex-end!important}
.composer textarea{overflow-y:hidden;overscroll-behavior:contain;scrollbar-width:thin;resize:none!important}
.composer textarea.composer-scroll{overflow-y:auto!important}
@media(min-width:761px){
 .composer textarea{max-height:min(260px,36dvh)!important}
 .composer button{align-self:flex-end!important}
}
@media(max-width:760px){
 .composer{align-items:flex-end!important}
 .composer textarea{max-height:min(310px,34dvh)!important}
 .composer button{align-self:flex-end!important}
 body.keyboard-open .composer textarea{max-height:min(310px,34dvh)!important}
}

/* NOVO 20261012.04 — composer touch reliability + password dialog */
.password-change-hint{line-height:1.45;margin:-2px 2px 2px}.password-change-actions{display:grid;grid-template-columns:1fr 1fr;gap:10px;margin-top:2px}.password-change-actions button{width:100%;min-height:44px}
.composer-area{isolation:isolate}.composer{position:relative;z-index:2;pointer-events:auto!important}.composer textarea#compose{position:relative;z-index:3;pointer-events:auto!important;touch-action:auto!important;-webkit-user-select:text!important;user-select:text!important;-webkit-touch-callout:default!important}
@media(max-width:760px){.composer-area{z-index:35!important;pointer-events:auto!important}.composer{z-index:36!important}.composer textarea#compose{z-index:37!important}.password-change-actions{position:sticky;bottom:0;background:var(--panel);padding-top:4px}}
/* 3.3.38: comments reference layout and explicit member role lines. */
.group-member-row .grow,.group-admin-person .grow{display:flex;flex-direction:column;align-items:flex-start;gap:4px;min-width:0;text-align:left}.group-member-row .grow b,.group-admin-person .grow b{display:block;max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.group-member-row .grow small,.group-admin-person .grow small{display:block;margin:0;font-size:13px;line-height:1.35;color:var(--muted)}
.reel-comments-shade{backdrop-filter:none;background:#0008;transition:none}.reel-comments-sheet{width:min(560px,100%);height:min(80dvh,740px);max-height:calc(var(--rc-height,100dvh) - 16px);background:#191919;border:0;border-radius:24px 24px 0 0;color:#dedee2;box-shadow:none}.reel-comments-sheet .reel-sheet-handle{display:none}.reel-comments-sheet header{height:65px;min-height:65px;position:relative;border:0;justify-content:center;padding:0 56px}.reel-comments-sheet header h3{flex:none;font-size:21px;font-weight:700;text-align:center}.reel-comments-sheet .reel-sheet-close{position:absolute;right:16px;top:15px;background:#292a2b;color:#b1b2b8;width:34px;height:34px}.reel-comments-sheet .reel-sheet-body{padding:0;overflow:hidden;display:flex;flex-direction:column;flex:1;min-height:0}.rc-stats{display:flex;gap:10px;align-items:center;margin:0 14px;padding:12px 0 16px;border-bottom:1px solid #ffffff10;color:#797a7f;font-size:14px;min-height:52px;flex-shrink:0}.rc-people{display:flex;padding-left:4px}.rc-people:empty{display:none}.rc-people .avatar{width:20px;height:20px;min-width:20px;border:1px solid #191919;margin-left:-4px}.rc-sort{display:flex;align-items:center;gap:6px;padding:13px 14px 8px;flex-shrink:0;width:max-content}.rc-sort select{border:0;padding:0;background:none;color:#d8d8dd;font-size:16px;width:auto;appearance:none;outline-offset:4px}.rc-sort .i{width:17px;height:17px;pointer-events:none}.rc-scroll{flex:1;min-height:0;overflow-y:auto;overscroll-behavior:contain;padding:6px 14px 15px;scrollbar-width:thin}.rc-thread{margin:11px 0 22px}.rc-comment{display:grid;grid-template-columns:38px minmax(0,1fr) auto;column-gap:12px;position:relative}.rc-comment>.avatar{width:38px;height:38px;min-width:38px;font-size:18px}.rc-copy{min-width:0}.rc-name{display:flex;flex-wrap:wrap;align-items:baseline;gap:6px;line-height:1.3}.rc-name b{font-size:15px;overflow-wrap:anywhere}.rc-name>span{font-size:14px;color:#797a7f}.rc-copy p{font-size:15px;line-height:1.35;white-space:pre-wrap;overflow-wrap:anywhere;margin:4px 0 6px}.rc-mention{color:#5794cc}.rc-meta{display:flex;gap:13px;align-items:baseline;flex-wrap:wrap;color:#797a7f;font-size:13px}.rc-meta button{padding:0;background:none;color:#a5a6ab;font-weight:600;font-size:13px}.rc-like{display:flex;align-items:center;align-self:end;gap:3px;padding:4px 0 0;color:#a6a7ad;background:none;font-size:13px;min-width:26px}.rc-like .i{width:18px;height:18px}.rc-like.active{color:#e56479}.rc-like.active svg{fill:currentColor}.rc-replies{padding-left:50px}.rc-child{grid-template-columns:24px minmax(0,1fr) auto;gap:10px;margin-top:16px}.rc-child>.avatar{width:24px;height:24px;min-width:24px;font-size:12px}.rc-show-replies{margin:13px 0 0 50px;padding:0;background:none;color:#929399;font-size:14px;text-align:left}.rc-inline{display:flex;align-items:center;gap:10px;background:none;color:#929399;margin:18px 0 0 50px;padding:0;width:calc(100% - 50px)}.rc-inline .avatar{width:24px;height:24px;min-width:24px}.rc-inline>span:last-child{border:1px solid #333438;border-radius:20px;font-size:15px;padding:7px 12px;flex:1;text-align:left}.rc-compose{border-top:1px solid #ffffff10;flex-shrink:0;background:#191919;padding:6px 10px max(6px,env(safe-area-inset-bottom))}.rc-compose-line{display:flex;align-items:center;gap:9px}.rc-compose button{background:none;color:#c7c8ce;padding:0}.rc-compose-line>#rc-emoji{width:28px;height:28px;border:2px solid currentColor;border-radius:50%;flex-shrink:0}.rc-compose-line>#rc-emoji .i{width:22px;height:22px}.rc-input-wrap{display:flex;align-items:center;flex:1;min-width:0;background:#292a2c;border-radius:28px;padding:5px 10px}.rc-input-wrap textarea{border:0;box-shadow:none;background:none;color:#ddd;font-size:16px;line-height:22px;min-height:36px;max-height:110px;padding:7px 0;resize:none;flex:1;width:0}.rc-input-wrap textarea::placeholder{color:#96979e}.rc-input-wrap button{width:26px;height:26px;flex-shrink:0}.rc-send{width:38px;height:38px;border-radius:50%;background:#305a83!important;color:#161b20!important;flex-shrink:0}.rc-send .i{width:24px;height:24px}.rc-reply{display:flex;align-items:center;justify-content:space-between;font-size:13px;color:#87add3;padding:3px 0 8px 37px}.rc-reply[hidden],.rc-emojis[hidden]{display:none}.rc-reply button{width:22px;height:22px}.rc-emojis{display:flex;justify-content:space-around;padding:10px}.rc-emojis button{font-size:23px}.rc-load{display:block;width:100%;padding:10px;background:none;color:#8cacce;text-align:center}.rc-load[hidden]{display:none}.rc-empty{padding:35px 12px;color:#888;text-align:center;font-size:14px}
@media(min-width:761px){.reel-comments-shade{align-items:center}.reel-comments-sheet{border-radius:24px;height:min(80vh,740px)}}
.message-virtual-space{flex-shrink:0;min-height:0;pointer-events:none;overflow-anchor:none}.messages>.message,.messages>.day{flex-shrink:0}
.attachment-tray{min-width:0}.at-list{display:flex;flex-direction:column;gap:10px;max-height:38dvh;overflow:auto}.at-item{display:flex;align-items:center;gap:10px;padding:8px;background:var(--card);border-radius:14px}.at-preview{width:60px;height:60px;flex-shrink:0;display:grid;place-items:center;border-radius:9px;overflow:hidden}.at-preview img,.at-preview video{width:100%;height:100%;object-fit:cover}.at-copy{flex:1;min-width:0}.at-copy b{display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font-size:13px}.at-copy small{display:block;margin-top:5px}.at-copy progress{width:100%;height:5px;accent-color:var(--blue)}.at-actions{display:flex;flex-wrap:wrap;gap:3px;justify-content:flex-end;max-width:108px}.at-actions button{padding:5px;font-size:11px}.at-actions .i{width:18px;height:18px}.at-tools{display:flex;justify-content:space-between;gap:8px;align-items:center;margin-top:10px;color:var(--muted);font-size:12px}.at-tools button{display:flex;gap:6px;align-items:center;color:var(--blue)}.attachment-tray .check-row{font-size:13px}.attachment-tray input[type=checkbox]{width:auto}.at-caption{font-size:16px}
.message-album{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:3px;width:min(360px,65vw);border-radius:12px;overflow:hidden}.album-tile{position:relative;aspect-ratio:1;padding:0;border-radius:0;overflow:hidden}.album-tile img,.album-tile video{display:block;width:100%;height:100%;object-fit:cover}.album-tile>span{position:absolute;inset:0;display:grid;place-items:center;color:white;background:#0002}.message-album[data-album-size="3"] .album-tile:first-child{grid-row:span 2;aspect-ratio:auto}.album-pending{aspect-ratio:1;background:var(--card);display:grid;place-items:center}.message:has(.message-album) .bubble{max-width:100%}
.rc-profile{align-self:start;padding:0;margin:0;border-radius:50%;width:38px;height:38px;background:none}.rc-profile>.avatar{width:38px;height:38px;min-width:38px;font-size:18px}.rc-child>.rc-profile,.rc-child .rc-profile>.avatar{width:24px;height:24px;min-width:24px;font-size:12px}

/* Chat switch hotfix 20261012.04: one initial position, stable media rectangles. */
#messages .round-note,#messages .video-frame{content-visibility:visible;contain-intrinsic-size:none}
#messages .chat-media-box{position:relative;display:block;width:var(--chat-media-width,360px);max-width:100%!important;min-width:0!important;height:auto;min-height:0!important;aspect-ratio:var(--chat-media-ratio,1);flex:none;overflow:hidden;background:#090a0d;border-radius:14px}
#messages .chat-media-box>.attachment{position:absolute;inset:0;display:block;width:100%!important;height:100%!important;min-height:0!important;max-width:100%!important;max-height:none!important;margin:0!important;object-fit:contain;border-radius:inherit}
#messages .chat-image-frame{margin-bottom:5px}
#messages .media-only .chat-image-frame{margin-bottom:0}
#messages .chat-media-box>.video-inline-play{position:absolute;inset:0;margin:auto}
.main.chat-transition-pending{cursor:progress}
.main.chat-transition-pending>*{pointer-events:none}
.main.chat-transition-pending::after{content:'';position:absolute;left:0;right:0;top:56px;height:2px;z-index:40;background:var(--blue);opacity:.5;pointer-events:none}
.chat-loading-composer{min-height:var(--loading-composer-height,50px);height:var(--loading-composer-height,50px);background:transparent;animation:none;pointer-events:none}
.chat-loading-composer .skeleton-composer{height:100%;width:100%;min-height:inherit}
@media(max-width:760px){
 .main.chat-transition-pending::after{top:calc(64px + env(safe-area-inset-top))}
 .chat-loading-composer{min-height:var(--loading-composer-height,50px)!important;height:var(--loading-composer-height,50px)!important}
}

/* 20261012.04: live appearance, actionable notices and outbox barrier. */
.appearance-preview .preview-bubble{font-size:var(--font);color:var(--text);font-weight:400;line-height:1.4}
.appearance-preview .preview-bubble.in{background:var(--incoming)!important}
.appearance-preview .preview-bubble.out{background:var(--out)!important;color:#fff}
.appearance-preview .preview-bubble span{color:inherit;opacity:.75}
body.light .appearance-preview .preview-bubble.out{color:#fff!important}
.appearance-save{display:flex;gap:10px;align-items:center;flex-wrap:wrap;min-height:34px;color:var(--muted);font-size:12px;margin-top:8px}
.appearance-save button{color:var(--blue);padding:8px}
.inapp-notice{position:fixed;top:max(14px,env(safe-area-inset-top));left:50%;transform:translateX(-50%);width:min(440px,calc(100vw - 24px));display:flex;align-items:center;border:1px solid var(--line);background:var(--panel);color:var(--text);border-radius:16px;box-shadow:0 6px 30px #0004;z-index:205;overflow:hidden}
.inapp-notice-open{flex:1;min-width:0;display:grid;gap:5px;text-align:left;padding:15px 18px;color:inherit;overflow-wrap:anywhere}
.inapp-notice-open b{font-size:14px}.inapp-notice-open span{font-size:13px;line-height:1.4}.inapp-notice-close{flex:none;min-width:44px;min-height:44px;font-size:24px;color:var(--muted)}
.outbox-barrier{display:flex;gap:10px;align-items:center;flex-wrap:wrap;border:1px solid #d5a34466;background:#d5a34412;border-radius:10px;padding:10px 12px;margin-bottom:8px;font-size:12px;line-height:1.4}
.outbox-barrier>div:first-child{flex:1;min-width:160px}.outbox-barrier p{margin:4px 0 0;color:var(--muted);overflow-wrap:anywhere}.outbox-barrier-actions{display:flex;gap:8px;flex-wrap:wrap}.outbox-barrier-actions button{min-height:40px;color:var(--blue);padding:8px}.rc-comment.notification-focus{outline:2px solid var(--blue);outline-offset:2px;border-radius:10px}

.mine .bubble{background:var(--out)}
.wallpaper{background-image:radial-gradient(ellipse at 50% 25%,var(--theme-tint,transparent),transparent 75%),url('/wallpaper.svg');background-size:auto,420px}

.appearance-preview{height:auto;min-height:407px;display:flex;flex-direction:column;gap:10px}
.appearance-preview .preview-bubble{position:relative;top:auto;left:auto;right:auto;max-width:90%;flex:none}
.appearance-preview .preview-bubble.in{align-self:flex-start}.appearance-preview .preview-bubble.out{align-self:flex-end}

/* Shared pending-work badges; safe for horizontal mobile tabs and desktop rail. */
.admin-tabs button>span{min-width:0}
.admin-tabs .admin-nav-count{flex:none;margin-left:auto;min-width:22px;height:22px;display:inline-flex;align-items:center;justify-content:center;padding:0 6px;border-radius:11px;background:#8055d9;color:#fff;font-size:12px;font-weight:700;font-style:normal;line-height:1}
.admin-tabs .admin-nav-count[hidden]{display:none}
.chat-list-progress{flex:none;width:100%;padding:10px 16px;border:0;background:var(--panel);color:var(--muted);font-size:13px;text-align:center}
.chat-list-progress:not(:disabled){color:var(--accent);cursor:pointer}
@media(max-width:760px){.admin-tabs .admin-nav-count{margin-left:8px;min-width:20px;height:20px}.admin-tabs button{gap:4px}}

/* Decoded media keeps its real aspect ratio; no artificial black photo frame. */
#messages .chat-image-frame{background:transparent}
.chat-loading-messages{justify-content:center;align-items:center}
.chat-loading-state{align-self:center;color:var(--muted);font-size:13px;text-align:center;padding:20px;animation:none}

/* NOVO .18 — channel management, scoped to these screens. */
.channel-management-pane{--channel-management-card:#24252b;background:#101011}
.channel-management-pane .page-scroll{background:transparent!important}
.channel-management-pane .page{width:100%;max-width:none;padding:20px 24px 24px}
.channel-management-pane .panehead{position:relative;display:flex;align-items:center;min-height:64px;padding:10px 24px;background:#171819}
.channel-management-pane .panehead h3{position:absolute;inset-inline:60px;text-align:center;font-size:16px;line-height:1.25;pointer-events:none}
.channel-management-pane #pane-back{width:36px;height:36px;padding:8px;flex:none}
.channel-management-pane .channel-head-edit{margin-left:auto!important;width:36px;height:36px;padding:8px}
.channel-management-pane :is(.channel-info-page,.channel-settings-page,.channel-people-page){width:100%;max-width:640px;margin:0 auto}
.channel-management-pane :is(.channel-invite-page,.channel-type-page,.channel-admin-rights,.channel-reactions-page){width:100%;max-width:none}
.channel-management-pane .card{background:var(--channel-management-card);border:0;border-radius:15px;box-shadow:none;margin-bottom:14px}
.channel-management-pane .setting-row{min-height:54px;padding:11px 14px;gap:12px;border-bottom:0;text-align:left;width:100%}
.channel-management-pane .setting-row b{font-size:14px;font-weight:600;line-height:1.3}
.channel-management-pane .setting-row small{display:block;color:var(--muted);font-size:12px;line-height:1.35;margin-top:3px}
.channel-management-pane .setting-row>.i{width:21px;height:21px;flex:none}
.channel-management-pane .setting-row>.i:last-child:not(:first-child){width:16px;height:16px;color:var(--muted)}
.channel-management-pane .setting-row .right{display:flex;align-items:center;gap:5px;color:var(--muted);font-size:13px;flex:none}
.channel-management-pane .setting-row .right .i{width:15px;height:15px}
.channel-management-pane .setting-row .grow{min-width:0}
.channel-management-pane .setting-row:disabled{opacity:.62;cursor:default}
.channel-management-pane .setting-row:not(:disabled):hover{background:#ffffff05}
.channel-management-pane .channel-profile{padding:4px 0 18px}
.channel-management-pane .channel-profile .avatar.big{width:88px;height:88px;margin:0 auto 12px}
.channel-management-pane .channel-profile h2{font-size:18px;line-height:1.35;margin-bottom:5px}
.channel-management-pane .channel-profile>p{font-size:13px}
.channel-management-pane .channel-info-actions{max-width:none;gap:12px;margin:16px 0 0}
.channel-management-pane .channel-info-actions button{background:var(--channel-management-card);border-radius:13px;min-height:66px;color:var(--blue);display:flex;flex-direction:column;align-items:center;justify-content:center;gap:5px;font-size:12px}
.channel-management-pane .channel-description-card{padding:12px 16px}
.channel-description-label{font-size:12px;color:var(--muted);display:block;margin-bottom:4px}
.channel-description-card p{white-space:pre-wrap;overflow-wrap:anywhere}
.channel-management-pane :is(.channel-management-card,.channel-stat-entry){padding:0 6px}
.channel-management-pane .channel-info-tabs{gap:22px;overflow:auto;white-space:nowrap}
.channel-management-pane .channel-info-tabs button{font-size:13px;flex:none}
.channel-management-pane .channel-media-card .empty-list{min-height:95px;display:grid;place-items:center;padding:16px;margin:0}
.channel-management-pane .channel-settings-avatar{margin:0 auto 18px;width:88px;height:88px;padding:0}
.channel-management-pane .channel-settings-avatar .avatar.big{width:88px;height:88px;margin:0}
.channel-management-pane .channel-settings-avatar>span{border-color:#101011}
.channel-management-pane :is(.ref-input input,.ref-textarea textarea){background:var(--channel-management-card);border:0;border-radius:14px;font-size:16px;padding:16px;width:100%}
.channel-management-pane .ref-textarea textarea{min-height:92px;padding-bottom:28px;resize:vertical}
.channel-management-pane .ref-textarea>span{font-size:11px;right:13px;bottom:12px}
.channel-management-pane .channel-section-label{font-size:11px;margin:14px 0 8px;letter-spacing:0}
.channel-management-pane .channel-settings-page>.card{padding:0 6px}
.channel-management-pane .channel-setting-help{margin:-7px 14px 18px;font-size:12px}
.channel-save-status{font-size:12px;line-height:1.4;color:var(--muted);margin:5px 0 12px;overflow-wrap:anywhere}
.channel-save-status:empty{display:none}
.channel-management-pane .channel-people-card{padding:12px}
.channel-management-pane .channel-page-search{height:38px;background:#303137;margin:0 0 8px}
.channel-management-pane .channel-page-search input{font-size:14px;min-width:0;width:100%}
.channel-management-pane .channel-blue-action{min-height:48px;padding:10px 6px;font-size:14px;font-weight:500}
.channel-management-pane .channel-member-row{min-height:58px;padding:8px 6px;border-radius:8px;gap:12px}
.channel-management-pane .channel-member-row .avatar{width:40px;height:40px;min-width:40px;flex:none}
.channel-management-pane .channel-member-row .grow{min-width:0}
.channel-management-pane .channel-member-row b{font-size:14px;font-weight:600;overflow-wrap:anywhere}
.channel-management-pane .channel-member-row small{font-size:12px;line-height:1.3;margin-top:4px;color:var(--muted)}
.channel-management-pane .channel-member-row:disabled{opacity:.5;cursor:default}
.channel-list-state{font-size:12px;color:var(--muted);padding:8px 2px;overflow-wrap:anywhere}
.channel-list-state:empty{display:none}
.channel-management-pane .channel-admin-rights .profile-header{padding:0 0 20px}
.channel-management-pane .channel-admin-rights .avatar.big{width:88px;height:88px;margin:0 auto 12px}
.channel-management-pane .channel-admin-rights h2{font-size:18px}
.channel-management-pane .channel-admin-rights .setting-row{min-height:54px}
.channel-management-pane .channel-admin-rights .setting-row small{max-width:none}
.channel-admin-save{padding:0 0 max(6px,env(safe-area-inset-bottom))}
.channel-admin-save button{min-height:46px;border-radius:12px;font-weight:600}
.channel-confirm-horizontal{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin-top:18px}
.channel-confirm-horizontal button{min-height:44px;border-radius:11px;font-size:14px}
.channel-picked-users{display:flex;flex-wrap:wrap;gap:6px;margin-bottom:10px}
.channel-picked-users:empty{display:none}
.channel-picked-users button{display:flex;align-items:center;gap:5px;padding:4px 7px 4px 4px;border-radius:18px;background:var(--input);font-size:12px;max-width:100%}
.channel-picked-users button span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.channel-picked-users .avatar{width:22px;height:22px;min-width:22px;flex:none}
.channel-picked-users .i{width:13px;height:13px;flex:none}
.channel-management-pane .channel-reactions-page{min-height:calc(100dvh - 116px);display:flex;flex-direction:column}
.channel-management-pane .channel-reaction-limit{padding:10px 14px}
.channel-management-pane .channel-reaction-limit>b{font-size:14px;margin-bottom:8px}
.channel-management-pane .channel-reaction-limit input{width:100%;min-height:24px}
.channel-management-pane .channel-reaction-heading{margin:4px 0 8px}
.channel-management-pane .channel-reaction-heading .channel-section-label{margin:0}
.channel-management-pane .channel-emoji-grid{grid-template-columns:repeat(auto-fill,minmax(36px,1fr));gap:7px;padding:14px}
.channel-emoji-grid>span{font-size:24px;line-height:1.3;text-align:center}
.channel-management-pane .channel-reactions-page .channel-create-bottom{position:sticky;bottom:0;margin-top:auto;padding:14px 0 max(8px,env(safe-area-inset-bottom));display:grid;grid-template-columns:1fr 1fr;gap:12px;background:#101011}
.channel-management-pane .channel-create-bottom button{min-height:44px;border-radius:12px}
.channel-management-pane .reactions-disabled .channel-reaction-limit{opacity:.55}
.channel-stats-dialog{width:min(380px,calc(100vw - 24px));max-height:82dvh}
.channel-stats-dialog .channel-stats{width:100%;font-size:13px}
.channel-stats-dialog select{width:auto;font-size:12px;padding:6px;min-width:76px}
.channel-stats-dialog .channel-stat-grid{margin-top:18px;gap:8px}
.channel-stats-dialog .channel-stat-grid .card{padding:14px 7px;background:var(--input);border-radius:12px}
.channel-stat-chart{display:flex;align-items:stretch;gap:2px;height:108px;margin:14px 0 7px;border-bottom:1px solid var(--line)}
.channel-stat-chart>div{flex:1;min-width:1px;display:flex;align-items:flex-end}
.channel-stat-chart>div>span{display:block;width:100%;background:var(--blue);border-radius:3px 3px 0 0;min-height:2px}
.channel-stat-growth{margin-top:16px;font-size:12px}
.channel-stat-growth small{display:block;color:var(--muted);line-height:1.45;margin-top:8px}
.channel-request-row{flex-wrap:wrap}
.channel-request-row .grow{flex-basis:130px}
.channel-post-comments{display:flex;align-items:center;gap:8px;width:100%;padding:10px 0 0;margin-top:6px;border-top:1px solid #ffffff18;color:var(--blue);font-size:13px;text-align:left;min-height:38px}
.channel-post-comments span{flex:1}.channel-post-comments .i{width:17px;height:17px}
.channel-discussion-dialog{width:min(640px,calc(100vw - 24px))}
.channel-discussion-post{color:var(--muted);font-size:13px;padding-bottom:12px;line-height:1.4;white-space:pre-wrap;overflow-wrap:anywhere}
.channel-discussion-top{display:flex;align-items:center;justify-content:space-between;gap:12px;font-size:13px;margin-bottom:10px}
.channel-discussion-list{max-height:48dvh;overflow:auto;overscroll-behavior:contain;-webkit-overflow-scrolling:touch}
.channel-discussion-comment{display:flex;gap:10px;padding:12px 0;border-top:1px solid var(--line)}
.channel-discussion-comment>.avatar{width:36px;height:36px;min-width:36px;flex:none}
.channel-discussion-comment .grow{min-width:0}.channel-discussion-comment b{font-size:14px;overflow-wrap:anywhere}
.channel-discussion-comment small{display:block;color:var(--muted);font-size:11px;margin-top:4px}
.channel-discussion-comment p{white-space:pre-wrap;overflow-wrap:anywhere;font-size:14px;line-height:1.4;margin:8px 0}
.channel-discussion-comment .row{gap:12px}.channel-discussion-comment .row button{font-size:12px;padding:4px 0}
.channel-discussion-comment .row .i{width:18px;height:18px}
.channel-comment-quote{border-left:2px solid var(--blue);padding:4px 8px;margin-top:8px;color:var(--muted)}
.channel-comment-quote b,.channel-comment-quote span{display:block;font-size:12px}
.channel-comment-reply{display:flex;align-items:center;gap:8px;padding:9px 0}
.channel-comment-reply>span{flex:1;min-width:0;font-size:12px}.channel-comment-reply small{display:block;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;color:var(--muted);margin-top:4px}
.channel-comment-reply[hidden]{display:none}
#channel-comment-form{display:flex;gap:8px;margin-top:10px;align-items:flex-end}
#channel-comment-form[hidden]{display:none}#channel-comment-input{flex:1;min-width:0;font-size:16px;line-height:1.35;resize:none;max-height:150px}
#channel-comment-form>button{width:44px;height:44px;padding:11px;flex:none;border-radius:12px}
body.light .channel-management-pane{--channel-management-card:var(--card);background:var(--panel)}
body.light .channel-management-pane .panehead,body.light .channel-management-pane .channel-reactions-page .channel-create-bottom{background:var(--panel)}
body.light .channel-management-pane .channel-page-search{background:var(--input)!important}
body.light .channel-management-pane :is(.ref-input input,.ref-textarea textarea){background:var(--input)!important}
body.light .channel-management-pane .channel-settings-avatar>span{border-color:var(--panel)}
body.light .channel-post-comments{border-color:var(--line)}
@media(max-width:760px){
 .channel-management-pane .page{padding:14px 12px max(22px,env(safe-area-inset-bottom))}
 .channel-management-pane .panehead{min-height:56px;padding:8px 12px}
 .channel-management-pane .setting-row{min-height:52px;padding:11px 8px}
 .channel-management-pane :is(.channel-info-page,.channel-settings-page,.channel-subpage,.channel-admin-rights,.channel-reactions-page){padding:0}
 .channel-management-pane .channel-settings-scroll{padding-top:0!important}
 .channel-management-pane .channel-settings-avatar{width:88px!important;height:88px!important;min-width:88px!important;min-height:88px!important;margin:6px auto 18px!important}
 .channel-management-pane .channel-profile .avatar.big{width:86px;height:86px}
 .channel-management-pane .channel-reactions-page{min-height:calc(100dvh - 96px - env(safe-area-inset-bottom))}
 .channel-management-pane .channel-settings-page>.card{padding:0 6px}
 .channel-management-pane .channel-people-card{padding:9px}
 .channel-management-pane .channel-info-tabs{gap:16px}
 .channel-management-pane .channel-info-actions button{min-height:60px}
 .channel-management-pane .channel-invite-card{gap:6px;padding:10px;margin:0 0 14px}
 .channel-management-pane .channel-invite-card>button{width:32px;height:36px;flex:none;padding:7px}
 .channel-management-pane .channel-invite-card .avatar{width:36px;height:36px;min-width:36px}
 .channel-confirm-horizontal{padding-bottom:max(2px,env(safe-area-inset-bottom))}
 .channel-discussion-dialog{width:100%;max-height:88dvh}
 .channel-discussion-list{max-height:40dvh}
}
.channel-management-pane .page-scroll{padding:0;scroll-padding-top:0}
.channel-stats-empty{background:var(--card);padding:18px 14px;margin-top:18px;border-radius:13px;font-size:13px;line-height:1.45}
.channel-stats-empty p{font-size:12px;color:var(--muted);margin-top:10px}
.channel-management-pane .channel-admin-rights>.card{padding:4px 6px}
.channel-management-pane .channel-admin-rights .setting-row{min-height:56px;padding:8px 14px}
.channel-management-pane .channel-admin-rights .setting-row b,.channel-management-pane .channel-settings-page .setting-row b{font-size:16px}
.channel-management-pane .channel-admin-rights .setting-row small{font-size:13px;line-height:1.2;margin-top:2px}
.message.media-only.has-channel-discussion .meta{position:static;margin:5px 10px 0;padding:0;background:transparent;text-align:right}
.message.media-only.has-channel-discussion .channel-post-comments{padding:10px 12px;margin-top:6px}
@media(max-width:760px){.channel-management-pane .channel-admin-rights .setting-row{padding:10px 8px;min-height:54px}.channel-management-pane .channel-admin-rights .setting-row b,.channel-management-pane .channel-settings-page .setting-row b{font-size:15px}}

/* NOVO .19: channel discussion is a chat page, not a blocking modal. */
.channel-discussion-screen{display:flex;flex-direction:column;min-height:0;overflow:hidden}
.channel-discussion-screen>.panehead{position:relative;flex:none;height:64px;background:var(--panel);border-bottom:1px solid var(--line)}
.channel-discussion-screen>.panehead h3{position:absolute;left:50%;transform:translateX(-50%);margin:0;pointer-events:none;font-size:15px;white-space:nowrap}
.channel-discussion-screen>.panehead #pane-back{display:grid;place-items:center;width:40px;height:40px}
.discussion-scroll{flex:1 1 auto;min-height:0;overflow-y:auto;overflow-x:hidden;overflow-anchor:none;overscroll-behavior:contain;display:flex;flex-direction:column;-webkit-overflow-scrolling:touch}
.discussion-column{flex:none;display:flex;flex-direction:column;justify-content:flex-end;min-height:100%;width:min(700px,calc(100% - 48px));margin:0 auto;padding:24px 0 14px;gap:10px}
.discussion-source-day.day{align-self:center;margin:0;padding:3px 9px;font-size:12px;flex:none}
.discussion-source{display:flex;align-items:flex-start;gap:8px;flex:none;min-width:0}
.discussion-source>.avatar{width:32px;height:32px;min-width:32px;font-size:13px}
.discussion-source-post{flex:1;min-width:0}
.channel-discussion-screen .discussion-source .message{width:auto!important;max-width:100%!important;align-self:flex-start;margin:0!important;contain:none;transform:none}
.channel-discussion-screen .discussion-source .message>.bubble{background:var(--incoming);border-radius:12px;max-width:100%;min-width:0}
.channel-discussion-screen .discussion-source .message-sender-line,.channel-discussion-screen .discussion-source .message-hover{display:none}
.channel-discussion-screen .discussion-source .chat-media-box{width:min(260px,100%)!important;max-width:100%!important;min-height:0!important;background:transparent}
.channel-discussion-screen .discussion-source .video-frame video,.channel-discussion-screen .discussion-source .chat-image-frame img{width:100%;object-fit:contain}
.channel-discussion-screen .discussion-source .message.media-only>.bubble{width:max-content;max-width:100%;padding:0;overflow:hidden}
.channel-discussion-screen .discussion-source .message.media-only .meta{font-size:11px}
.discussion-divider{align-self:center;background:var(--panel);padding:3px 9px;border-radius:9px;font-size:12px;text-align:center;flex:none}
.discussion-comments{display:flex;flex-direction:column;gap:10px;flex:none;min-width:0}
.discussion-message{position:relative;display:flex;align-items:flex-end;gap:8px;align-self:flex-start;max-width:85%;min-width:0;touch-action:pan-y;transition:none}
.discussion-message>.bubble{background:var(--incoming);color:var(--text);font-size:var(--font);padding:7px 10px;border-radius:12px 12px 12px 4px;min-width:72px;max-width:100%;overflow-wrap:anywhere}
.discussion-message.mine{align-self:flex-end}.discussion-message.mine>.bubble{background:var(--out);border-radius:12px 12px 4px 12px}.discussion-message.mine>.discussion-user-avatar{display:none}
.discussion-message .discussion-author{display:block;color:var(--text);font-size:12px;line-height:1.3;margin-bottom:3px;opacity:.85}
.discussion-message .body{white-space:pre-wrap;line-height:1.35}.discussion-message .meta{position:static;color:var(--muted);font-size:11px;float:none;display:block;text-align:right;padding-top:2px;line-height:1.2}
.discussion-message.mine .meta{color:inherit;opacity:.7}
.discussion-message .channel-comment-quote{width:100%;text-align:left;margin:3px 0 6px;border-radius:4px;background:#ffffff0a;color:inherit}
.discussion-message .channel-comment-quote[hidden]{display:none}
.discussion-message .reactions:empty{display:none}.discussion-message .reactions{display:flex;flex-wrap:wrap;gap:4px;margin-top:5px}
.discussion-user-avatar .avatar{width:32px;height:32px;min-width:32px}
.discussion-hover{position:absolute;left:100%;bottom:0;display:flex;gap:4px;padding:8px 10px;opacity:0;pointer-events:none;z-index:2;min-height:44px}
.discussion-message.mine .discussion-hover{left:auto;right:100%}
.discussion-hover button{width:32px;height:32px;display:grid;place-items:center;padding:7px;border-radius:50%;background:var(--out);color:var(--text)}
.discussion-hover svg.i{width:18px;height:18px}
.discussion-message:hover>.discussion-hover,.discussion-message:focus-within>.discussion-hover{opacity:1;pointer-events:auto}
.discussion-selected>.bubble{outline:2px solid var(--blue);outline-offset:3px}
.discussion-bottom{flex:none;width:min(700px,calc(100% - 48px));margin:0 auto;padding:0 0 max(10px,env(safe-area-inset-bottom));position:relative}
.discussion-bottom #channel-comment-form{background:var(--panel);border-radius:15px;display:flex;align-items:flex-end;gap:2px;margin:0;padding:0 5px;min-height:48px}
.discussion-bottom #channel-comment-form[hidden]{display:none}
.discussion-bottom #channel-comment-input{font-size:16px;line-height:1.35;min-height:42px;max-height:120px;padding:11px 10px;background:transparent;border:0;resize:none;flex:1}
.discussion-bottom #channel-comment-form>button{width:38px;height:38px;min-width:38px;padding:8px;margin-bottom:5px;border-radius:50%;background:transparent}
.discussion-bottom #channel-comment-form>.discussion-send{background:var(--blue);color:#fff;width:34px;height:34px;min-width:34px;margin:7px 3px}
.discussion-bottom .channel-comment-reply{background:var(--panel);border-radius:12px;padding:9px 12px;margin-bottom:5px}
.discussion-bottom .channel-hint{background:var(--panel);border-radius:12px;padding:12px;text-align:center;margin:0}
.discussion-state{font-size:12px;color:var(--muted);background:var(--panel);border-radius:10px;padding:8px;margin-bottom:5px}
.discussion-state:empty{display:none}.discussion-new{display:block;margin:0 auto 8px;font-size:12px;padding:7px 12px;min-height:32px}
.discussion-new[hidden],.discussion-selection[hidden]{display:none}
.discussion-selection{display:flex;align-items:center;gap:8px;background:var(--panel);padding:6px 8px;border-radius:12px;margin-bottom:5px}.discussion-selection>span{flex:1;font-size:12px}
.discussion-more{align-self:center;min-height:34px;font-size:12px;margin-bottom:6px}
.discussion-quick-reactions{display:flex;gap:1px;justify-content:space-between;margin-bottom:8px}.discussion-quick-reactions button{font-size:23px;padding:5px 3px;min-width:30px}
.modal:has(.channel-picker){max-width:400px;border-radius:28px}.modal:has(.channel-picker) .modal-head h3{font-size:24px;line-height:1.1}
.channel-picker .channel-picker-search{position:relative;margin:4px 0 22px}.channel-picker .channel-picker-search>.i{position:absolute;left:12px;top:9px;width:17px;height:17px;color:var(--muted)}
.channel-picker .channel-picker-search input{padding:9px 12px 9px 36px}
.channel-picker .channel-picker-list{max-height:min(46dvh,460px);overflow:auto;overscroll-behavior:contain}
.channel-picker .channel-user-choice{display:flex;align-items:center;width:100%;padding:8px 12px;gap:12px;min-height:56px;text-align:left}
.channel-picker .channel-user-choice>.avatar{width:40px;height:40px;min-width:40px}.channel-picker .channel-user-choice b{font-size:15px}.channel-picker .channel-user-choice small{font-size:12px;margin-top:4px;display:block}
.channel-picker .channel-choice-check{width:20px;height:20px;min-width:20px;border-radius:50%;border:2px solid var(--muted);display:grid;place-items:center;color:transparent;line-height:1}
.channel-picker .selected .channel-choice-check{background:var(--blue);border-color:var(--blue);color:#fff;font-size:12px}
.channel-history-choice{font-weight:600;font-size:14px;margin:18px 0 24px;padding-left:0}.channel-history-choice input{width:20px;height:20px;margin:0;accent-color:var(--blue)}
.channel-picker .channel-picker-footer{display:grid;grid-template-columns:1fr 1fr;gap:16px}.channel-picker .channel-picker-footer button{min-height:52px;border-radius:16px;font-weight:600}
.channel-picker .channel-picked-users{max-height:95px;overflow:auto}
body.light .channel-discussion-screen>.panehead,body.light .discussion-bottom #channel-comment-form,body.light .discussion-divider{background:var(--panel)}
@media(max-width:760px){
 .channel-discussion-screen>.panehead{height:calc(56px + env(safe-area-inset-top));padding-top:env(safe-area-inset-top)}
 .discussion-column{width:calc(100% - 20px);padding-top:14px;padding-bottom:12px}
 .discussion-bottom{width:calc(100% - 12px)}
 .discussion-message{max-width:88%}.discussion-hover{display:none}
 .channel-discussion-screen .discussion-source .chat-media-box{width:min(260px,66vw)!important}
 .discussion-source>.avatar,.discussion-user-avatar .avatar{width:28px;height:28px;min-width:28px;font-size:12px}
 .discussion-source{gap:6px}.discussion-message{gap:6px}
 .modal:has(.channel-picker) .modal-head h3{font-size:22px}
 .channel-picker .channel-picker-list{max-height:40dvh}
 .discussion-selection{flex-wrap:wrap}.discussion-selection button{padding:8px}
}
@media(prefers-reduced-motion:reduce){.channel-discussion-screen *{scroll-behavior:auto!important}}

/* Voice text disclosure preserves the existing audio player. */
.voice-text-toggle{flex:none;width:32px;min-width:32px;min-height:40px;border-radius:10px;font-size:13px;font-weight:600;background:transparent;color:inherit;touch-action:manipulation}
.voice-transcript{max-height:none;overflow-wrap:anywhere;user-select:text;-webkit-user-select:text;font-size:14px;line-height:1.45}
.voice-transcript-text{white-space:pre-wrap}.voice-transcript-retry{margin-top:9px;border-radius:10px;padding:8px 12px;min-height:40px;background:var(--card);color:var(--blue)}
.voice-transcript-note{display:block;margin-top:8px;font-size:11px;line-height:1.35;opacity:.7}.voice-transcript [hidden]{display:none!important}

/* 20261012.04: no message backplate around stickers, round notes or videos. */
#app .message.unframed-media > .bubble {
 background:transparent!important;
 background-image:none!important;
 box-shadow:none!important;
 border:0!important;
 padding:0!important;
 overflow:visible!important;
}
#app .message.sticker-message > .bubble > .chat-image-frame {
 background:transparent!important;
 border:0!important;
 box-shadow:none!important;
 border-radius:0;
}
#app .message.sticker-message > .bubble > .chat-image-frame > .attachment {
 border-radius:0;
}
/* Captions and author names stay readable on the wallpaper in the light theme. */
body.light #app .message.unframed-media > .bubble { color:var(--text)!important }
body.light #app .message.unframed-media > .bubble .sender,
body.light #app .message.unframed-media > .bubble a { color:var(--blue)!important }

/* 20261012.04: the media is unframed; its text caption has its own bubble. */
#app .message.media-caption-message > .bubble > .media-caption {
 margin-top:6px;
 padding:8px 10px;
 max-width:100%;
 min-width:0;
 background:var(--incoming);
 color:var(--text);
 border-radius:15px 15px 15px 5px;
 box-shadow:0 1px 1px #0002;
 overflow-wrap:anywhere;
}
#app .message.mine.media-caption-message > .bubble > .media-caption {
 background:var(--out);
 color:#fff;
 border-radius:15px 15px 5px 15px;
}
#app .message.media-caption-message > .bubble > .media-caption > .meta {
 position:static!important;
 inset:auto!important;
 margin:4px 0 -1px!important;
 padding:0!important;
 background:transparent!important;
 color:inherit!important;
 border-radius:0;
 opacity:.7;
 pointer-events:auto;
}
#app .message.round-message.media-caption-message { padding-bottom:0 }
#app .message.round-message.media-caption-message > .bubble > .media-caption { margin-top:28px }
body.light #app .message.mine.media-caption-message > .bubble > .media-caption a { color:#fff!important }

/* 20261012.04: caption reactions share the caption bubble in every theme. */
#app .message.media-caption-message > .bubble > .media-caption > .reactions {
 background:transparent;
 padding:0;
}
#app .message.media-caption-message > .bubble > .media-caption > .reactions:empty {
 display:none;
}

/* First-message requests: shared web / Android WebView / iPhone PWA. */
.request-panel{padding:16px max(16px,env(safe-area-inset-right)) max(16px,env(safe-area-inset-bottom));background:var(--panel);border-top:1px solid var(--line);text-align:center;flex-shrink:0}.request-panel>b{display:block;font-size:16px}.request-panel p{max-width:620px;margin:8px auto 14px;color:var(--muted);line-height:1.5}.request-actions{display:flex;justify-content:center;gap:8px;flex-wrap:wrap}.request-actions button{min-height:44px;padding:10px 16px}.request-thread .composer-area{flex-shrink:0;padding:0}.request-thread .message-hover,.request-thread .reactions,.request-thread #pin-slot{display:none}.request-thread .messages{min-height:0}.request-panel[role=status] p{margin-bottom:0}#request-report-reason{min-height:110px;margin-top:12px}@media(max-width:480px){.request-actions .primary{flex:1 0 100%}.request-actions .secondary{flex:1}.request-panel{padding-top:14px}}

/* 20261012.04: visible keyboard viewport and intentional empty-chat action. */
.empty-thread-write{display:inline-flex;align-items:center;justify-content:center;min-height:44px;margin-top:12px;padding:10px 16px;border-radius:12px;background:var(--blue);color:#fff;font-size:15px;line-height:1.4;white-space:normal}
.empty-thread-write:focus-visible{outline:2px solid var(--blue);outline-offset:3px}
@media(max-width:760px){
 body.keyboard-open .shell{top:var(--app-top,0px)!important;height:var(--app-height,100dvh)!important;max-height:var(--app-height,100dvh)!important}
 .empty-thread-write{font-size:16px;min-height:48px}
}

/* Topic navigation must fit before its lazy editor stylesheet loads. */
@media(max-width:760px){.topic-root-head:not(.saved-chathead) [data-action=call],.topic-root-head:not(.saved-chathead) [data-action=video],.topic-root-head:not(.saved-chathead) [data-action=search]{display:none!important}.topic-root-head .info{min-width:0;flex:1}.topic-root-head .info b{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;display:block}}

/* AI unread summary entry — reference appearance */
.ai-summary-shortcut{position:relative;isolation:isolate;flex-shrink:0;display:flex;align-items:center;gap:12px;min-width:0;width:calc(100% - 28px);min-height:78px;margin:10px 14px 12px;padding:12px 14px;border-radius:19px;border:1px solid rgba(225,246,255,.78);background:linear-gradient(110deg,#7651ff 0%,#4f62ff 46%,#23b6f4 83%,#23d6eb 100%);box-shadow:inset 0 0 0 1px #fff2,inset 0 1px 10px #fff5,0 0 10px #7352ff55,0 5px 17px #18bdff26;color:#fff;text-align:left;cursor:pointer;touch-action:manipulation;transition:box-shadow .16s ease,filter .16s ease;-webkit-tap-highlight-color:transparent}
.ai-summary-shortcut::before{content:"";position:absolute;z-index:-1;inset:3px;border-radius:15px;pointer-events:none;border:1px solid #fff2;background:linear-gradient(170deg,#ffffff14,transparent 56%)}
.ai-summary-shortcut .ai-summary-symbol{display:grid;place-items:center;flex:0 0 46px;width:46px;height:46px;border:1px solid #ffffff32;border-radius:15px;color:#fff;background:linear-gradient(145deg,#8c5dff,#5536ec 64%,#494bdd);box-shadow:inset 0 1px 5px #fff2,0 3px 10px #3631b345}
.ai-summary-symbol svg{display:block;width:32px;height:32px}.ai-summary-shortcut .ai-summary-copy{display:flex;flex-direction:column;flex:1;min-width:0;gap:5px}.ai-summary-copy b{font-size:15px;font-weight:650;line-height:1.25;color:#fff;letter-spacing:0}.ai-summary-copy small{font-size:12px;font-weight:400;line-height:1.4;color:#ffffffed;white-space:normal;overflow-wrap:anywhere;font-variant-numeric:tabular-nums}.ai-summary-shortcut .ai-summary-arrow{display:grid;place-items:center;flex:0 0 32px;width:32px;height:32px;border-radius:50%;color:#fff;background:linear-gradient(155deg,#52caff,#248ded);box-shadow:inset 0 1px 3px #fff4,0 2px 8px #266fe326}.ai-summary-arrow svg{display:block;width:20px;height:20px}.ai-summary-shortcut:hover{filter:brightness(1.06);box-shadow:inset 0 0 0 1px #fff3,inset 0 1px 10px #fff5,0 0 13px #7352ff66,0 5px 19px #18bdff33}.ai-summary-shortcut:active{filter:brightness(.96)}.ai-summary-shortcut:focus-visible{outline:2px solid var(--text);outline-offset:3px}@media(max-width:760px){.ai-summary-shortcut{min-height:76px;margin-top:9px;margin-bottom:11px}}@media(max-width:359px){.ai-summary-shortcut{gap:10px;padding:11px 12px}.ai-summary-shortcut .ai-summary-symbol{flex-basis:42px;width:42px;height:42px;border-radius:14px}.ai-summary-copy b{font-size:14px}.ai-summary-copy small{font-size:11px}.ai-summary-shortcut .ai-summary-arrow{flex-basis:30px;width:30px;height:30px}}@media(prefers-reduced-motion:reduce){.ai-summary-shortcut{transition:none}}
