@import url("/demo-typography.css");







@media(max-width:700px){


 .chat-row{min-height:50px!important;padding:6px!important;gap:8px!important;border-radius:0;border-bottom:1px solid #edf0ee}


 .chat-row>div:not(.chat-meta){min-width:0;flex:1}.chat-row strong{font-size:15px!important;line-height:1.2}.chat-row small{font-size:11px!important;margin-top:2px!important;line-height:1.2}


 .chat-row .avatar{width:34px;height:34px;min-width:34px;flex:0 0 34px;font-size:14px}


 .chat-row .chat-meta{flex:0 0 auto;max-width:70px;align-self:center;line-height:1.1}.chat-meta time{display:block;font-size:9px;color:#6f7b74;white-space:nowrap}.chat-meta time span{display:block}.chat-row .chat-meta small{font-size:9px!important}.chat-meta small:empty{display:none}.chat-meta .unread{font-size:10px;min-width:16px;padding:2px 4px;margin-top:2px}


}




.chat-emoji-panel[hidden]{display:none}.chat-emoji-panel{display:flex;flex-wrap:wrap;gap:4px;padding:6px;background:#fff}.chat-emoji-panel button{font-size:22px!important;min-height:40px;min-width:40px;padding:4px!important}

@media(max-width:700px){.message-form{display:flex!important;align-items:center;gap:2px!important;padding:6px 4px!important;max-width:100%;box-sizing:border-box}.message-form input[name=body]{flex:1 1 0;min-width:0!important;width:0!important;font-size:14px!important;padding:8px 5px!important}.message-form button{flex:0 0 34px;width:34px;min-width:34px!important;min-height:42px;padding:4px!important;font-size:18px!important}.message-form #messageInput{order:1}.message-form #chatEmoji{order:0}.message-form #attachFile{order:2}.message-form #cameraCapture{order:3}.message-form #recordVoice{order:4}.message-form button[type=submit]{order:5}.chat-head{gap:6px!important;padding:7px!important}.chat-head strong{font-size:15px!important}.chat-head button{min-width:34px;min-height:40px;padding:5px!important}.menu-grid button{font-size:14px!important}}


/* Real conversation messages use .bubble, not .message. */
@media(max-width:700px){
 .messages{padding:10px!important;gap:8px!important}
 .bubble{font-size:16px!important;line-height:1.35!important;padding:7px 10px!important;border-radius:14px;max-width:88%;overflow-wrap:anywhere}
 .bubble p,.bubble li,.bubble blockquote{font-size:16px!important;line-height:1.35!important}
 .bubble small{font-size:9px!important;line-height:1.25!important;margin-top:3px!important}
}

/* The submit button already contains its accessible visible icon. */
@media(max-width:700px){.message-form button[type=submit]::after{content:none}}

/* Keep typing usable on narrow phones without removing attachment or call controls. */
@media(max-width:359px){
 #sendForm.message-form{display:grid!important;grid-template-columns:repeat(5,minmax(0,1fr));gap:4px;padding:6px 8px;}
 #sendForm #messageInput{grid-column:1 / -1;grid-row:1;width:100%!important;min-width:0;}
 #sendForm>button{grid-row:2;justify-self:center;min-width:44px!important;min-height:44px;}
}



/* The open conversation already reports offline state in its sync-status row. */


/* Keep long territory labels within narrow search cards. */
@media(max-width:700px){
 #main .page h1,#main .market-page h1{font-size:20px!important;line-height:1.25}
 #main .page h2,#main .market-page h2{font-size:18px!important;line-height:1.3}
 #searchForm>label{min-width:0;max-width:100%;box-sizing:border-box}
 #searchForm>label select{width:100%;min-width:0;max-width:100%;box-sizing:border-box}
}

/* Keep history navigation tappable while retaining compact message typography. */
@media(max-width:700px){.history-tools button{min-height:44px;max-width:100%;box-sizing:border-box;white-space:normal;line-height:1.2}}
@media(max-width:700px){
 #sendForm.message-form{display:grid!important;grid-template-columns:44px minmax(0,1fr) repeat(4,44px)!important;gap:2px!important;padding:4px!important;align-items:center}
 #sendForm #messageInput{grid-column:2!important;grid-row:1!important;width:100%!important;min-width:0!important;box-sizing:border-box;min-height:44px}
 #sendForm button{grid-row:1!important;min-width:44px!important;width:44px!important;min-height:44px!important;box-sizing:border-box}
 #sendForm #chatEmoji{grid-column:1!important}
 #sendForm #attachFile{grid-column:3!important}
 #sendForm #cameraCapture{grid-column:4!important}
 #sendForm #recordVoice{grid-column:5!important}
 #sendForm button[type=submit]{grid-column:6!important}
}

@media(max-width:700px){html{-webkit-text-size-adjust:100%;text-size-adjust:100%}body{font-size:14px!important;line-height:1.4}h1{font-size:22px!important;line-height:1.2}h2{font-size:19px!important;line-height:1.25}h3{font-size:16px!important}p,li,label{font-size:14px!important}small{font-size:11px!important}button,select{font-size:14px!important}input,textarea{font-size:16px}dialog{padding:16px!important;max-width:calc(100vw - 24px)!important;font-size:14px!important}dialog button{min-height:42px;padding:8px 12px!important}dialog h2{margin:4px 0 12px}.actions{gap:6px!important}.page{padding:14px!important}.chat-row strong{font-size:14px!important}.chat-row small{font-size:12px!important}.bottom small{font-size:10px!important}.chat-head button{font-size:19px!important}body.melars-android input,body.melars-android textarea{font-size:14px!important}}





.melars-offline #recordVoice:not([data-offline-local="true"]):not([data-recording="1"]):not([aria-label="Завершить запись"]),.melars-offline #sendForm button[type=submit]:not([data-offline-local="true"]){opacity:.45;pointer-events:none}.melars-offline .top{margin-top:28px}





.call-page-head,.call-person{display:flex;align-items:center;gap:8px}.call-page-head h2{margin-right:auto}.call-page-head a{text-decoration:none;font-size:20px}.call-person{padding:10px 0;border-bottom:1px solid #e8ece9;text-align:left}.call-person>span:nth-child(2){flex:1;min-width:0}.call-person b{font-size:14px}.call-person small{display:block;font-size:11px}.call-person-avatar{width:36px;height:36px;flex:0 0 36px;display:grid;place-items:center;border-radius:50%;background:#e4f1df}.call-person button{min-width:36px;padding:6px;font-size:19px}.call-picker{width:420px;max-width:calc(100vw - 24px);max-height:80vh;overflow:auto}.call-picker input,[data-call-search]{box-sizing:border-box;width:100%;margin:8px 0;padding:10px}





.history-tools{flex:none;text-align:center}.history-tools button{padding:5px 10px;font-size:12px!important;min-height:30px;margin:3px}










@media(max-width:700px){.call-person{gap:6px}.call-person>span:nth-child(2){overflow-wrap:anywhere}.call-person button{box-sizing:border-box;flex:0 0 56px;min-width:0;width:56px;min-height:40px;padding:5px 3px!important;font-size:11px!important;line-height:1.2;white-space:normal}.call-person small{font-size:11px!important;line-height:1.3}}








@media(max-width:700px){



 .inbox,.messenger,.chat-space,.chat-filters,.inbox-tools,.mobile-swipes{min-width:0;max-width:100%;box-sizing:border-box}



 .chat-filters{display:flex;flex-wrap:wrap;overflow:visible;gap:4px;padding:6px 0}



 .chat-filters button{flex:0 1 auto;min-width:0;max-width:100%;white-space:normal;overflow-wrap:anywhere;font-size:11px!important;line-height:1.2;padding:6px 8px!important;min-height:32px}



 .inbox-tools{display:flex;flex-wrap:wrap;gap:4px}.inbox-tools button,.inbox-tools a{flex:1 1 80px;min-width:0;max-width:100%;white-space:normal;overflow-wrap:anywhere;box-sizing:border-box;font-size:11px!important;line-height:1.25;padding:6px!important;min-height:36px}



 .mobile-swipes{display:flex;flex-wrap:wrap;gap:4px}.mobile-swipes button{flex:1 1 70px;min-width:0;white-space:normal;font-size:11px!important;padding:6px!important;min-height:36px}



 .chat-row{min-height:56px!important;padding:8px 6px!important;gap:8px!important}.chat-row strong{font-size:13px!important}.chat-row small{font-size:11px!important}.chat-row .avatar{width:36px;height:36px;min-width:36px;font-size:14px}



 .message{font-size:13px!important;line-height:1.4}.message p,.message li{font-size:13px!important}.message small{font-size:10px!important}.chat-head strong{font-size:13px!important}.chat-head button{font-size:17px!important}



 .bottom button{font-size:20px!important}.bottom small{font-size:10px!important}.inbox-head h1{font-size:20px!important}.compact-features a{font-size:11px!important;min-width:0;overflow-wrap:anywhere}.compact-features span{font-size:20px!important}



}

@media(max-width:700px){#sendForm.message-form{grid-template-columns:44px minmax(0,1fr) repeat(3,44px)!important}#sendForm #recordVoice,#sendForm button[type=submit]{grid-column:5!important}#sendForm button[hidden]{display:none!important}}

@media(max-width:700px) and (max-height:500px){
 .messenger:not(.open) .inbox{display:block;overflow-y:auto;overscroll-behavior:contain}
 .messenger:not(.open) .inbox-list{overflow:visible;height:auto}
 .messenger:not(.open) .inbox-head{margin:6px 0}
 .messenger:not(.open) .inbox-tools{flex-wrap:nowrap;overflow-x:auto}
 .messenger:not(.open) .inbox-tools button,.messenger:not(.open) .inbox-tools a{flex:0 0 auto}
}

/* Conversation owns its header and Back action; shell tabs must not cover drafts. */
@media(max-width:700px){
 .shell:has(.messenger.open)>.top,.shell:has(.messenger.open)>.bottom{display:none!important}
 
}

@media(max-width:700px){.messenger.open .chat-head #chatBack{display:block!important;min-width:44px;min-height:44px;flex:0 0 44px}}

/* Connection state is an in-flow first row, above contact/call controls. */
.shell>#offlineBanner{order:-100;flex:none;position:relative!important;min-width:0;overflow-wrap:anywhere;padding-top:max(6px,env(safe-area-inset-top,0px))!important}
.shell:has(>#offlineBanner:not([hidden]))>#networkStatus{display:none!important}
.shell>#offlineBanner[hidden]{display:none!important}

/* Keep compact call icons easy to hit without enlarging the conversation header. */
@media(max-width:700px){.messenger.open .chat-head>button{width:44px!important;height:44px!important;min-width:44px!important;min-height:44px!important;flex:0 0 44px;padding:0!important}.messenger.open .chat-head>div{min-width:0}}

/* Keep text entry at a readable size on iPhone; small fonts can trigger focus zoom. */
@media(max-width:700px){
 body:not(.melars-android) #sendForm #messageInput{font-size:16px!important}
 .history-tools button{min-height:44px}
}

.draft-versions-strip{flex:none;padding:0 8px;text-align:right}.draft-versions-strip button{min-height:32px;padding:4px 8px;font:11px system-ui;background:transparent;border:0;color:#47665d}

.draft-versions-strip[hidden]{display:none}

/* Call controls occupy the available screen, including narrow phones and safe areas. */
dialog.melars-call-screen{position:fixed!important;inset:0!important;width:100vw!important;max-width:100vw!important;height:100dvh!important;max-height:100dvh!important;margin:0!important;padding:max(12px,env(safe-area-inset-top,0px)) max(12px,env(safe-area-inset-right,0px)) max(12px,env(safe-area-inset-bottom,0px)) max(12px,env(safe-area-inset-left,0px))!important}
.melars-call-screen .call-screen-content{min-width:0;min-height:100%!important;gap:12px!important;box-sizing:border-box}
.melars-call-screen h2{font-size:22px!important;line-height:1.2;max-width:100%;overflow-wrap:anywhere}
.melars-call-screen p{max-width:100%;overflow-wrap:anywhere}
.melars-call-screen[data-call-stage="incoming"] .call-screen-actions{display:grid!important;grid-template-columns:minmax(0,1fr) minmax(0,1fr);width:100%;gap:12px!important;padding:12px 0 0!important;flex-shrink:0}
.melars-call-screen[data-call-stage="incoming"] .call-screen-actions button{width:100%;min-width:0!important;min-height:72px!important;padding:12px 8px!important;font-size:18px!important}
@media(max-height:500px){
 .melars-call-screen .call-screen-content{gap:6px!important}
 .melars-call-screen[data-call-stage="incoming"] [data-call-avatar]{margin-top:0!important;width:56px!important;height:56px!important;font-size:28px!important;flex-shrink:0}
 .melars-call-screen[data-call-stage="incoming"] h2{font-size:18px!important}
 .melars-call-screen[data-call-stage="incoming"] p{margin:0!important;font-size:13px}
 .melars-call-screen[data-call-stage="incoming"] .call-screen-actions{padding-top:6px!important}
 .melars-call-screen[data-call-stage="incoming"] .call-screen-actions button{min-height:56px!important;font-size:16px!important}
}

/* Keep live-call actions visible while video takes the remaining space. */
.melars-call-screen[data-call-stage="active"] .call-screen-content{height:100%;min-height:0!important;gap:8px!important}
.melars-call-screen[data-call-stage="active"] .call-screen-content>small,.melars-call-screen[data-call-stage="active"] h2,.melars-call-screen[data-call-stage="active"] p{flex-shrink:0;margin:0!important}
.melars-call-screen[data-call-stage="active"] [data-call-avatar]{margin-top:0!important;width:64px!important;height:64px!important;font-size:28px!important;flex-shrink:0}
.melars-call-screen[data-call-stage="active"]:has([data-remote]:not([hidden])) [data-call-avatar]{display:none!important}
.melars-call-screen[data-call-stage="active"] [data-remote]:not([hidden]){flex:1 1 0;min-height:0;max-height:none!important;width:100%;object-fit:contain}
.melars-call-screen[data-call-stage="active"] .call-screen-actions{display:grid!important;grid-template-columns:minmax(0,1fr) minmax(0,1fr);width:100%;gap:8px!important;padding:8px 0 0!important;flex-shrink:0}
.melars-call-screen[data-call-stage="active"] .call-screen-actions button{min-width:0!important;min-height:52px!important;width:100%;font-size:13px!important;line-height:1.2;padding:8px!important;overflow-wrap:anywhere;color:#142d2a!important;background:#fff!important}
.melars-call-screen[data-call-stage="active"] .call-screen-actions [data-end]{order:99;grid-column:2;color:#fff!important;background:#da394b!important}
.melars-call-screen[data-call-stage="active"] [data-enable-sound]{flex-shrink:0;min-height:44px}
.melars-call-screen[data-call-stage="active"] [data-local-preview]{top:auto!important;bottom:202px;right:max(16px,env(safe-area-inset-right,0px));width:56px!important;height:72px!important}
@media(max-height:500px){
 .melars-call-screen[data-call-stage="active"] .call-screen-content{gap:4px!important}
 .melars-call-screen[data-call-stage="active"] [data-call-avatar]{display:none!important}
 .melars-call-screen[data-call-stage="active"] h2{font-size:18px!important}
 .melars-call-screen[data-call-stage="active"] p{font-size:12px;line-height:1.2}
 .melars-call-screen[data-call-stage="active"] .call-screen-actions{gap:6px!important;padding-top:4px!important;grid-template-columns:repeat(3,minmax(0,1fr))}
 .melars-call-screen[data-call-stage="active"] .call-screen-actions button{min-height:48px!important;font-size:12px!important}
 .melars-call-screen[data-call-stage="active"] .call-screen-actions [data-end]{grid-column:3}
 .melars-call-screen[data-call-stage="active"] [data-local-preview]{bottom:128px;width:40px!important;height:48px!important}
}

@media(max-width:700px){.top #profileButton{width:44px!important;height:44px!important;min-width:44px!important;max-width:44px!important;min-height:44px!important;flex:0 0 44px!important}}

/* The device fallback must also stay above content when offline-client cannot load. */
.shell>#networkStatus{order:-100;position:relative!important;top:auto!important;left:auto!important;right:auto!important;min-width:0;overflow-wrap:anywhere;padding-top:max(6px,env(safe-area-inset-top,0px))!important}
.shell>#networkStatus[hidden]{display:none!important}

/* Offline call buttons open the explicit SIM offer; they do not start VoIP. */
.melars-offline [data-audio-call],.melars-offline [data-video-call]{opacity:.65;pointer-events:auto}

/* Secondary incoming action stays readable without shrinking the answer target. */
.melars-call-screen[data-call-stage="incoming"] .call-screen-actions [data-call-reply]{grid-column:1 / -1;min-height:44px!important;font-size:14px!important;padding:10px 12px!important}

/* Keep update actions away from camera cutouts even on older native shells. */
[data-native-update-banner],[data-native-update-success]{position:fixed!important;top:auto!important;bottom:calc(96px + env(safe-area-inset-bottom,0px))!important;left:max(12px,env(safe-area-inset-left,0px))!important;right:max(12px,env(safe-area-inset-right,0px))!important;width:auto!important;max-height:calc(100dvh - 160px);overflow:auto;z-index:1000;border-radius:16px;padding:12px!important;box-shadow:0 4px 20px #142d2a33;pointer-events:auto}
[data-native-update-banner]>span,[data-native-update-success]>span{flex:1 0 100%!important;min-width:0!important}
[data-native-update-banner]>button,[data-native-update-success]>button{min-height:44px;min-width:104px;flex:1;font-size:14px;padding:10px 12px}
body:has(dialog.melars-call-screen[open]) [data-native-update-banner],body:has(dialog.melars-call-screen[open]) [data-native-update-success]{display:none!important}

/* Short phones: keep all live call actions inside the safe viewport. */
@media(max-width:600px) and (max-height:640px){
 .melars-call-screen:is([data-call-stage="outgoing"],[data-call-stage="active"]) .call-screen-content{gap:6px!important}
 .melars-call-screen:is([data-call-stage="outgoing"],[data-call-stage="active"]) [data-call-avatar]{margin-top:4px!important;width:72px!important;height:72px!important;font-size:32px!important;flex-shrink:0}
 .melars-call-screen:is([data-call-stage="outgoing"],[data-call-stage="active"]) h2{font-size:20px!important}
 .melars-call-screen:is([data-call-stage="outgoing"],[data-call-stage="active"]) .call-screen-actions{display:grid!important;grid-template-columns:minmax(0,1fr) minmax(0,1fr);width:100%;gap:8px!important;padding:8px 0!important;flex-shrink:0}
 .melars-call-screen:is([data-call-stage="outgoing"],[data-call-stage="active"]) .call-screen-actions button:not([hidden]){min-width:0!important;min-height:48px!important;padding:8px 6px!important;font-size:13px!important;overflow-wrap:anywhere}
}

.message-reaction-picker{display:flex;flex-wrap:wrap;gap:6px;margin:12px 0}.message-reaction-picker button{min-width:44px;min-height:44px;border-radius:22px;font-size:24px;padding:6px;background:#edf4ef;border:1px solid transparent}.message-reaction-picker button[aria-pressed="true"]{border-color:#246f52;background:#d9eddf}.message-reaction-summary{display:flex;flex-wrap:wrap;gap:4px;margin:4px 0}.message-reaction-chip{font-size:13px;line-height:1.5;border:1px solid #b5cabe;border-radius:12px;padding:1px 6px;background:#f6faf7;color:#142d2a}.message-reaction-chip.mine{border-color:#246f52;background:#d9eddf}
/* Short outgoing screens need room for real controls before the peer answers. */
@media(max-height:400px){
 .melars-call-screen[data-call-stage="outgoing"] .call-screen-content{gap:4px!important}
 .melars-call-screen[data-call-stage="outgoing"] [data-call-avatar]{display:none!important}
 .melars-call-screen[data-call-stage="outgoing"] h2{font-size:18px!important;max-width:calc(100% - 100px)}
 .melars-call-screen[data-call-stage="outgoing"] p{margin:0!important;font-size:12px;line-height:1.2}
 .melars-call-screen[data-call-stage="outgoing"] .call-screen-actions{grid-template-columns:repeat(3,minmax(0,1fr))!important;gap:6px!important;padding:4px 0!important}
 .melars-call-screen[data-call-stage="outgoing"] .call-screen-actions button{min-height:44px!important;font-size:12px!important}
 .melars-call-screen[data-call-stage="outgoing"] .call-screen-actions [data-end]{order:99;grid-column:3}
 .melars-call-screen[data-call-stage="outgoing"] [data-local-preview]{top:12px!important;right:12px!important;width:40px!important;height:48px!important}
}
@media(max-height:300px){
 .melars-call-screen[data-call-stage="outgoing"] .call-screen-content{gap:2px!important}
 .melars-call-screen[data-call-stage="outgoing"] .call-screen-content>small{font-size:10px;line-height:1.2}
 .melars-call-screen[data-call-stage="outgoing"] h2{font-size:16px!important;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
 .melars-call-screen[data-call-stage="outgoing"] p{font-size:11px;line-height:1.2}
 .melars-call-screen[data-call-stage="outgoing"] .call-screen-actions button:not([hidden]){min-height:44px!important;font-size:12px!important;line-height:1.1;padding:6px!important}
}
/* Preserve the end-call action when the connected video screen is short. */
@media(max-height:400px){
 .melars-call-screen[data-call-stage="active"] .call-screen-content{gap:2px!important}
 .melars-call-screen[data-call-stage="active"] h2{font-size:16px!important;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:calc(100% - 100px)}
 .melars-call-screen[data-call-stage="active"] p{font-size:11px;line-height:1.2}
 .melars-call-screen[data-call-stage="active"] .call-screen-content>small{font-size:10px;line-height:1.2}
 .melars-call-screen[data-call-stage="active"] .call-screen-actions{gap:4px!important;padding:4px 0 0!important}
 .melars-call-screen[data-call-stage="active"] .call-screen-actions button:not([hidden]){min-height:44px!important;font-size:12px!important;line-height:1.1;padding:6px!important}
 .melars-call-screen[data-call-stage="active"] [data-local-preview]{top:12px!important;bottom:auto!important;right:12px!important;width:40px!important;height:48px!important}
}
@media(max-height:400px) and (min-width:480px){
 .melars-call-screen[data-call-stage="active"] .call-screen-actions{grid-template-columns:repeat(4,minmax(0,1fr))!important}
 .melars-call-screen[data-call-stage="active"] .call-screen-actions [data-end]{grid-column:4}
}
@media(max-height:300px){
 .melars-call-screen[data-call-stage="active"] .call-screen-content>small{display:none}
 .melars-call-screen[data-call-stage="active"] .call-screen-actions{grid-template-columns:repeat(4,minmax(0,1fr))!important}
 .melars-call-screen[data-call-stage="active"] .call-screen-actions [data-end]{grid-column:4}
}
@media(max-height:300px){.melars-call-screen[data-call-stage="active"] .call-screen-actions button:not([hidden]){padding:4px!important}}

/* Keep the reply action visible beside answer/reject on very short screens. */
@media(max-height:300px){
 .melars-call-screen[data-call-stage="incoming"] [data-call-avatar],.melars-call-screen[data-call-stage="incoming"] .call-screen-content>small{display:none!important}
 .melars-call-screen[data-call-stage="incoming"] .call-screen-content{gap:4px!important}
 .melars-call-screen[data-call-stage="incoming"] h2{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:100%;font-size:16px!important}
 .melars-call-screen[data-call-stage="incoming"] p{font-size:12px;line-height:1.2}
 .melars-call-screen[data-call-stage="incoming"] .call-screen-actions{gap:6px!important;padding-top:4px!important}
}

/* Compact symbols retain a usable touch area in the conversation header. */
@media(max-width:700px){.messenger.open .chat-head button{min-width:44px!important;min-height:44px!important;width:44px!important;height:44px!important;flex:0 0 44px!important;box-sizing:border-box}}


body,input,textarea,select,button{font-family:Roboto,Arial,sans-serif!important}
body{font-size:18px!important;line-height:1.4}
.bubble,.bubble p,.bubble li,.bubble blockquote{font-size:18px!important;line-height:1.42!important}
.bubble small{font-size:12px!important;line-height:1.35!important}
.chat-row strong,.chat-head strong{font-size:18px!important;line-height:1.3!important}
.chat-row small{font-size:15px!important;line-height:1.35!important}
.message-form input[name=body],.message-form #messageInput{font-size:18px!important;line-height:1.4!important}
.menu-grid button,.chat-filters button,.inbox-tools button{font-size:15px!important}
.bottom small{font-size:13px!important}.sync-status,.ttl-banner{font-size:12px!important}
label,input:not([type=checkbox]):not([type=radio]),textarea,select{font-size:17px!important}
#main h1{font-size:24px!important}#main h2{font-size:21px!important}
/* Owner request: keep the connection strip slightly below the system edge. */
.shell>#networkStatus,.shell>#offlineBanner{margin-top:4px!important}
/* Personal account control belongs to the menu, not the public header. */
.header-menu #profileButton{display:block!important;width:100%!important;height:auto!important;min-height:48px!important;border-radius:10px!important;text-align:left!important;white-space:normal!important;padding:10px 12px!important}
.header-menu #profileButton::before,.header-menu #profileButton::after{display:none!important}
/* One compact utility row; preserve 44px touch targets. */
.inbox-head .inbox-head-tools{display:flex;align-items:center;gap:2px;flex-wrap:nowrap}
.inbox-head .inbox-head-tools button,.inbox-head .inbox-head-tools a{display:inline-grid;place-items:center;min-width:44px;min-height:44px;margin:0;padding:6px;font-size:21px}
.chat-filters{display:flex;flex-wrap:nowrap;overflow-x:auto;gap:4px}
.chat-filters button{flex:none;min-height:40px;white-space:nowrap}
.header-menu > [hidden],.header-menu #profileButton[hidden],header details.header-actions[hidden]{display:none!important}

/* Preserve the owner-approved composer size over earlier platform selectors. */
body #sendForm.message-form #messageInput{font-size:18px!important;line-height:1.4!important}

/* Narrow phones keep a full-width composer above five 44px actions. */
@media(max-width:399px){
 #sendForm.message-form{grid-template-columns:repeat(5,minmax(44px,1fr))!important;gap:4px!important}
 #sendForm #messageInput{grid-column:1 / -1!important;grid-row:1!important}
 #sendForm button{grid-row:2!important;justify-self:center}
 #sendForm #chatEmoji{grid-column:1!important}
 #sendForm #attachFile{grid-column:2!important}
 #sendForm #cameraCapture{grid-column:3!important}
 #sendForm #recordVoice{grid-column:4!important}
 #sendForm button[type=submit]{grid-column:5!important}
}

/* Recent-call status: color supplements the existing readable status text. */
[data-call-history] .call-person button[data-call-status="ended"]{color:#137a3f!important}
[data-call-history] .call-person button[data-call-status="missed"]{color:#c62828!important}
