/* Full-window companion to D@vi. No global typography or generic dialog overrides. */
#messengerDialog { position:absolute; inset:0; z-index:65; color:#e9edf4; background:#10171e; overflow:hidden; }
#messengerDialog[hidden], #messengerDialog [hidden], #messengerButton [hidden] { display:none !important; }
#messengerDialog *, #messengerButton { box-sizing:border-box; }
#messengerButton { position:absolute; right:0; top:50%; transform:translateY(-50%); z-index:80; width:36px; height:74px; padding:7px 4px; border:1px solid #71859066; border-right:0; border-radius:18px 0 0 18px; background:#1e303cee; color:#bde3e6; box-shadow:-4px 3px 18px #0004; cursor:pointer; touch-action:manipulation; }
#messengerButton svg { width:27px; height:38px; fill:none; stroke:currentColor; stroke-width:1.6; stroke-linejoin:round; transition:transform .25s ease; }
#messengerButton .mv-open-envelope, #messengerButton .mv-trowel { display:none; }
#messengerButton.has-unread { background:#39625c; color:#e0ffcc; }
#messengerButton.has-unread .mv-envelope, #messengerButton.is-open .mv-envelope, #messengerButton.is-open .mv-open-envelope { display:none; }
#messengerButton.has-unread:not(.is-open) .mv-open-envelope, #messengerButton.is-open .mv-trowel { display:block; }
#messengerBadge { position:absolute; top:0; left:-6px; min-width:19px; border-radius:12px; padding:2px 4px; background:#d8ff72; color:#17230c; font:700 10px/14px system-ui; }
#messengerDialog button, #messengerDialog input, #messengerDialog textarea { font:inherit; color:inherit; }
#messengerDialog button { border:1px solid #72899533; background:#263944; border-radius:10px; padding:9px 12px; cursor:pointer; min-height:40px; }
#messengerDialog button:hover { background:#324d5a; }
#messengerDialog button:disabled { opacity:.45; cursor:default; }
#messengerDialog button:focus-visible, #messengerButton:focus-visible, #messengerDialog input:focus-visible, #messengerDialog textarea:focus-visible { outline:2px solid #d8ff72; outline-offset:2px; }
#messengerDialog .mv-primary { background:#bddf9b; color:#182913; border-color:transparent; font-weight:650; }
#messengerDialog .mv-danger { background:#633b43; color:#ffe2e6; }
#messengerDialog input, #messengerDialog textarea { border:1px solid #72899544; border-radius:12px; padding:11px 13px; background:#101c25; min-width:0; }
#messengerDialog input { width:100%; }
#messengerDialog small, #messengerDialog .mv-muted { color:#a4b7c4; }
.mv-shell { position:relative; display:grid; grid-template-columns:300px minmax(0,1fr); height:100%; }
.mv-sidebar { display:flex; flex-direction:column; min-height:0; background:#15212bde; border-right:1px solid #72899526; z-index:1; }
.mv-sidebar-head { padding:max(20px,env(safe-area-inset-top)) 18px 14px; }
.mv-brand { display:flex; align-items:center; justify-content:space-between; gap:12px; margin-bottom:17px; }
.mv-brand strong { font-size:20px; letter-spacing:-.4px; }
.mv-brand small { display:block; margin-top:3px; font-size:11px; font-weight:400; letter-spacing:1.4px; }
#messengerDialog .mv-new { border-radius:50%; width:40px; font-size:23px; padding:0; }
.mv-contacts { overflow-y:auto; padding:0 8px 10px; flex:1; }
#messengerDialog .mv-contact { display:flex; align-items:center; text-align:left; gap:12px; width:100%; border:0; border-radius:12px; background:transparent; padding:13px 10px; }
#messengerDialog .mv-contact[aria-current="true"] { background:#28414a; }
.mv-avatar { display:grid; place-items:center; flex:0 0 43px; height:43px; border-radius:50%; background:linear-gradient(145deg,#4a787c,#324657); color:#e4f4e9; font-size:16px; font-weight:600; }
.mv-contact-copy { flex:1; min-width:0; }
.mv-contact-copy strong, .mv-contact-copy small { display:block; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.mv-contact-copy strong { font-size:14px; font-weight:600; margin-bottom:5px; }
.mv-contact-copy small { font-size:12px; }
.mv-counter { background:#badf9c; border-radius:10px; color:#23351b; padding:2px 6px; font-size:11px; }
.mv-sidebar-foot { padding:15px 18px max(15px,env(safe-area-inset-bottom)); font-size:11px; line-height:1.6; border-top:1px solid #72899520; color:#9fb4c0; }
.mv-main { min-width:0; min-height:0; display:grid; grid-template-columns:minmax(0,1fr); grid-template-rows:auto minmax(0,1fr) auto auto auto; position:relative; }
.mv-chat-head { display:flex; align-items:center; gap:12px; min-height:80px; padding:16px 48px 16px 24px; background:#17252ee8; border-bottom:1px solid #72899526; z-index:1; }
.mv-chat-title { flex:1; min-width:0; }
.mv-chat-title strong { display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.mv-chat-title small { display:block; margin-top:4px; font-size:11px; }
#messengerDialog .mv-icon { padding:7px; width:39px; border:0; background:transparent; font-size:20px; }
.mv-icon svg { width:22px; height:22px; vertical-align:middle; fill:none; stroke:currentColor; stroke-width:1.7; }
#messengerDialog .mv-mobile-back { display:none; }
.mv-history { overflow-y:auto; overscroll-behavior:contain; display:flex; flex-direction:column; gap:8px; padding:22px 50px 20px 25px; min-height:0; scroll-behavior:auto; }
.mv-empty { margin:auto; max-width:370px; text-align:center; padding:30px 22px; color:#aabec9; line-height:1.65; }
.mv-empty strong { display:block; font-weight:500; color:#e0eced; font-size:23px; margin:12px 0; }
.mv-empty svg { width:64px; height:64px; stroke:#81a9ad; fill:none; stroke-width:1; }
#messengerDialog .mv-older { align-self:center; font-size:12px; min-height:32px; padding:6px 14px; background:#1d303be0; }
.mv-bubble { align-self:flex-start; max-width:min(78%,610px); padding:10px 13px 7px; border-radius:15px 15px 15px 4px; background:#203541ed; box-shadow:0 2px 7px #0002; white-space:pre-wrap; overflow-wrap:anywhere; line-height:1.45; font-size:14px; }
.mv-bubble.mine { align-self:flex-end; border-radius:15px 15px 4px 15px; background:#34514ceF; }
.mv-bubble time { display:block; text-align:right; font-size:10px; color:#a6c0c3; margin-top:5px; }
.mv-bubble img, .mv-bubble video { max-width:100%; max-height:330px; border-radius:9px; display:block; margin-top:7px; }
.mv-bubble audio { max-width:100%; width:270px; display:block; margin-top:7px; }
#messengerDialog .mv-file { background:#10252b77; border:0; text-align:left; font-size:13px; max-width:100%; white-space:normal; overflow-wrap:anywhere; }
.mv-composer { display:flex; gap:8px; align-items:flex-end; padding:12px 48px max(18px,env(safe-area-inset-bottom)) 20px; background:#17252ef2; z-index:1; }
.mv-composer textarea { flex:1; resize:none; min-height:44px; max-height:128px; line-height:1.45; }
#messengerDialog .mv-send { background:#bddf9b; color:#182913; border-radius:50%; width:44px; padding:8px; min-height:44px; }
.mv-status { margin:0; padding:6px 48px 6px 23px; background:#192d36; font-size:12px; color:#c6dcbb; min-height:28px; }
.mv-overlay { position:absolute; inset:0; z-index:8; background:#0a131cd9; display:grid; place-items:center; padding:22px 44px 22px 22px; overflow:auto; }
.mv-card { width:min(100%,430px); padding:26px; border:1px solid #627f8944; background:#1a2b36; border-radius:22px; box-shadow:0 24px 90px #0007; }
.mv-card h2 { margin:0 0 12px; font-size:21px; }
.mv-card p { line-height:1.65; font-size:14px; }
.mv-card label { display:block; margin:18px 0; font-size:13px; }
.mv-card label input { margin-top:8px; }
.mv-actions { display:flex; flex-wrap:wrap; gap:8px; margin-top:17px; }
.mv-card audio { width:100%; }
.mv-bottom-tools { padding:5px 48px 5px 20px; display:flex; align-items:center; gap:8px; background:#17252ee8; position:relative; z-index:3; }
.mv-call { width:100%; position:relative; display:flex; flex-direction:column; gap:5px; }
.mv-call-title { display:flex; align-items:baseline; flex-wrap:wrap; gap:8px; font-size:12px; }
.mv-call-title strong { font-size:13px; }
.mv-call-actions { display:flex; gap:8px; align-items:center; }
#messengerDialog .mv-phone, #messengerDialog .mv-reject { border-radius:50%; background:#426f59; color:#e9fff1; width:42px; height:42px; }
#messengerDialog .mv-reject { background:#ad354b; }
#messengerDialog .mv-active-call { background:#426f59; }
.mv-active-call svg, .mv-reject svg { transform:rotate(135deg); }
.mv-call button[aria-pressed="true"] { opacity:.5; }
.mv-main > .mv-chat-head { grid-area:1 / 1; }
.mv-main > .mv-history { grid-area:2 / 1; }
.mv-main > .mv-status { grid-area:3 / 1; }
.mv-main > .mv-bottom-tools { grid-area:4 / 1; }
.mv-main > .mv-composer { grid-area:5 / 1; }
.mv-main > .mv-call-media { grid-area:2 / 1; position:relative; min-width:0; min-height:0; overflow:hidden; background:#0a141b; z-index:2; }
.mv-call-media .mv-remote { position:absolute; inset:0; width:100%; height:100%; object-fit:contain; }
.mv-call-media .mv-local { position:absolute; right:14px; bottom:14px; width:clamp(70px,22%,150px); max-height:30%; object-fit:contain; background:#17252e; border:1px solid #6b8790; border-radius:10px; z-index:1; }
.mv-call-actions { flex-wrap:wrap; }
#messengerDialog .mv-video-toggle { font-size:12px; padding:6px 9px; }
#messengerDialog .mv-sound-settings { display:block; font-size:12px; margin-bottom:9px; }
#messengerDialog .mv-ringtone-name { overflow-wrap:anywhere; }
.mv-quick-replies { position:absolute; left:0; bottom:52px; display:flex; flex-direction:column; gap:5px; padding:8px; background:#203640; border:1px solid #66827c; border-radius:14px; box-shadow:0 8px 25px #0006; z-index:8; }
#messengerDialog .mv-quick-replies button.selected { background:#bddf9b; color:#182913; }
#messengerDialog .mv-reject { touch-action:none; }
.mv-call-bar { position:absolute; left:16px; bottom:16px; z-index:81; border:1px solid #8aaca8; background:#213d38; color:#e4f6eb; border-radius:18px; padding:10px 18px; }
.mv-graph { position:absolute; inset:0; width:100%; height:100%; pointer-events:none; opacity:.65; }
.mv-graph-label { position:absolute; bottom:100px; right:53px; font-size:9px; letter-spacing:1.2px; color:#86a8ad66; pointer-events:none; }
@media (max-width:680px) {
 .mv-shell { grid-template-columns:1fr; }
 .mv-main { display:none; }
 .mv-shell.has-peer .mv-sidebar { display:none; }
 .mv-shell.has-peer .mv-main { display:grid; }
 #messengerDialog .mv-mobile-back { display:block; }
 .mv-chat-head { min-height:72px; padding:14px 39px 14px 8px; gap:5px; }
 .mv-chat-head .mv-avatar { flex-basis:35px; height:35px; font-size:14px; }
 .mv-chat-title small { max-width:180px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
 .mv-history { padding:16px 40px 16px 13px; }
 .mv-bubble { max-width:92%; }
 .mv-composer { gap:4px; padding:9px 37px max(10px,env(safe-area-inset-bottom)) 8px; }
 #messengerDialog .mv-composer .mv-icon { width:32px; }
 .mv-composer textarea { padding:10px; font-size:16px; }
 .mv-sidebar-head { padding-right:42px; }
 .mv-overlay { padding:14px 38px 14px 12px; }
 .mv-card { padding:20px; }
}
@media (prefers-reduced-motion:reduce) { #messengerButton svg { transition:none; } }

.mv-media-note { font-size:12px; text-align:center; max-width:420px; }

@media (max-width:680px) { .mv-bottom-tools { padding:4px 42px 4px 10px; } }

#messengerDialog .mv-revoke-choices { max-height: 35vh; overflow: auto; display: grid; gap: 8px; }
#messengerDialog .mv-revoke-choice { display: flex; align-items: center; gap: 10px; text-align: left; padding: 6px; }
#messengerDialog .mv-revoke-choice input { width: 20px; height: 20px; flex: 0 0 20px; }
#messengerDialog .mv-revoke-choice span { overflow-wrap: anywhere; }
#messengerDialog .mv-revoked-label { display: block; opacity: .65; font-size: 11px; margin-top: 6px; }

.mv-touch-shield { position: fixed; inset: 0; z-index: 2147483647; background: #000; color: #888; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 32px; touch-action: none; user-select: none; -webkit-user-select: none; padding: 24px; }
.mv-touch-shield .mv-touch-unlock { color: #aaa; background: #111; border: 1px solid #333; border-radius: 20px; padding: 24px; max-width: 320px; font: inherit; touch-action: none; }
.mv-touch-shield .mv-touch-unlock.holding { border-color: #aaa; background: #292929; }

#messengerDialog .mv-network-route { font-size:11px; color:#b7d2c3; overflow-wrap:anywhere; }

/* Terracotta friezes frame the entire Spheno window. */
@font-face { font-family:'Spheno Inscription'; src:url('/spheno-inscription.woff2') format('woff2'); font-style:normal; font-weight:400; font-display:swap; }
#messengerDialog { --clay:#c48b53; --ink:#2e1e13; font-family:'Spheno Inscription',Georgia,serif; font-size:18px; font-weight:400; color:var(--ink); background:var(--clay) url('/spheno-clay.webp') center / 500px 500px repeat; }
#messengerDialog button, #messengerDialog input, #messengerDialog textarea { font-family:'Spheno Inscription',Georgia,serif; font-weight:400; }
#messengerDialog button { color:var(--ink); background:#ebbc867d; border:1px solid #56351e50; border-radius:6px; }
#messengerDialog button:hover { background:#f3cca5aa; }
#messengerDialog button:focus-visible, #messengerDialog input:focus-visible, #messengerDialog textarea:focus-visible, #messengerButton:focus-visible { outline:2px solid #643b22; outline-offset:2px; }
#messengerDialog button:disabled { opacity:.42; }
#messengerDialog input, #messengerDialog textarea { color:#28190f; background:#f5dab2a8; border:1px solid #68422261; border-radius:6px; }
#messengerDialog input::placeholder, #messengerDialog textarea::placeholder { color:#513924; opacity:.85; }
#messengerDialog small, #messengerDialog .mv-muted { color:#49321f; }
#messengerDialog .mv-primary, #messengerDialog .mv-send { background:#e9b87eae; color:#2e1e13; border:1px solid #52321b60; font-weight:400; }
#messengerDialog .mv-danger, #messengerDialog .mv-reject { background:#923d2dd9; color:#fff0d9; }
#messengerDialog .mv-shell { display:grid; grid-template-columns:300px minmax(0,1fr); grid-template-rows:76px minmax(0,1fr) 90px auto; height:100%; }
#messengerDialog .mv-top-panel { grid-area:1 / 1 / 2 / -1; position:relative; display:grid; grid-template-columns:300px minmax(0,1fr); padding-top:25px; border-bottom:2px solid #51341c; z-index:2; }
#messengerDialog .mv-top-panel::before { content:''; position:absolute; inset:0 0 auto; height:25px; background:url('/spheno-gorgon.webp') left top / auto 180px repeat-x; border-bottom:1px solid #51341c; }
#messengerDialog .mv-brand { padding:0 20px; margin:0; gap:8px; min-width:0; }
#messengerDialog .mv-brand strong { font-family:'Spheno Inscription',serif; font-size:29px; font-weight:400; letter-spacing:3px; text-transform:uppercase; }
#messengerDialog .mv-new { width:34px; height:34px; min-height:34px; background:#f3c18b70; }
#messengerDialog .mv-chat-head { background:transparent; border:0; min-height:0; padding:3px 46px 3px 15px; }
#messengerDialog .mv-chat-title strong { font-size:20px; font-weight:400; }
#messengerDialog .mv-chat-title small { font-size:12px; margin:0; }
#messengerDialog .mv-chat-head .mv-avatar { flex-basis:33px; height:33px; }
#messengerDialog .mv-sidebar { grid-area:2 / 1; position:relative; isolation:isolate; background:transparent; border:0; z-index:1; }
#messengerDialog .mv-gorgon-art { position:absolute; inset:0; z-index:-1; background:url('/spheno-gorgon-portrait.webp') center / cover no-repeat; opacity:.88; }
#messengerDialog .mv-sidebar-head { padding:13px 16px 10px; }
#messengerDialog .mv-contacts { padding:0 9px 12px; }
#messengerDialog .mv-contact { margin-bottom:5px; background:#edc38c8c; border:1px solid #5e3b2030; border-radius:6px; }
#messengerDialog .mv-contact[aria-current="true"] { background:#f3d4aab3; border-color:#603a2059; }
#messengerDialog .mv-contact-copy strong { font-size:18px; font-weight:400; }
#messengerDialog .mv-contact-copy small { font-size:14px; }
#messengerDialog .mv-avatar { background:#593822b3; color:#ffe6c0; font-size:18px; font-weight:400; }
#messengerDialog .mv-counter { background:#643b27; color:#ffe1b2; }
#messengerDialog .mv-main { grid-area:2 / 2; display:grid; grid-template-rows:minmax(0,1fr); min-height:0; background:transparent; }
#messengerDialog .mv-main>.mv-history, #messengerDialog .mv-main>.mv-call-media { grid-area:1 / 1; }
#messengerDialog .mv-history { padding:18px 45px 18px 22px; }
#messengerDialog .mv-lower-frieze { grid-area:3 / 1 / 4 / -1; background:url('/spheno-lower.webp') left top / auto 157px repeat-x; border-top:2px solid #54351f; border-bottom:2px solid #54351f; z-index:2; }
#messengerDialog .mv-controls { grid-area:4 / 1 / 5 / -1; display:grid; grid-template-columns:auto minmax(0,1fr); align-items:center; background:#c8905778; z-index:3; }
#messengerDialog .mv-sidebar-foot { grid-area:1 / 1; padding:4px 12px; margin:0; background:none; border:0; }
#messengerDialog .mv-sound-settings { font-size:13px; margin:0; min-height:29px; padding:3px 8px; background:#f4d0a16e; }
#messengerDialog .mv-status { grid-area:1 / 2; min-height:22px; font-size:13px; padding:3px 44px 3px 0; background:none; color:#49301d; }
#messengerDialog .mv-bottom-tools { grid-area:2 / 1 / 3 / -1; background:none; padding:4px 45px 4px 18px; }
#messengerDialog .mv-composer { grid-area:3 / 1 / 4 / -1; background:none; padding:6px 45px max(9px,env(safe-area-inset-bottom)) 18px; }
#messengerDialog .mv-composer .mv-icon { background:#efc28b80; }
#messengerDialog .mv-composer textarea { font-size:18px; min-height:42px; }
#messengerDialog .mv-icon { color:#322012; }
#messengerDialog .mv-bubble { color:#2b1a10; background:#f5d7b09c; font-size:18px; border:1px solid #6946272b; box-shadow:none; }
#messengerDialog .mv-bubble.mine { background:#eabc84b3; }
#messengerDialog .mv-bubble time { color:#574026; font-size:12px; }
#messengerDialog .mv-file { background:#e9bb835c; font-size:16px; }
#messengerDialog .mv-empty { color:#48301d; }
#messengerDialog .mv-empty strong { color:#352011; font-size:26px; font-weight:400; }
#messengerDialog .mv-empty svg { stroke:#503321; }
#messengerDialog .mv-contacts .mv-empty { padding:14px 13px; font-size:17px; }
#messengerDialog .mv-contacts .mv-empty strong { font-size:22px; }
#messengerDialog .mv-older { background:#edc28f9e; color:#352011; }
#messengerDialog .mv-overlay { background:#42281788; }
#messengerDialog .mv-card { background:#deb07dde; border:1px solid #54352066; border-radius:12px; }
#messengerDialog .mv-card h2 { font-size:25px; font-weight:400; }
#messengerDialog .mv-card p, #messengerDialog .mv-card label { font-size:18px; }
#messengerDialog .mv-call { gap:3px; }
#messengerDialog .mv-call-title { font-size:14px; background:none; padding:0; }
#messengerDialog .mv-call-title strong { font-size:16px; font-weight:400; }
#messengerDialog .mv-media-note { font-size:13px; text-align:left; max-width:none; }
#messengerDialog .mv-call-actions { gap:6px; }
#messengerDialog .mv-phone, #messengerDialog .mv-active-call { background:#563723ba; color:#ffe1b2; }
#messengerDialog .mv-network-route { color:#3d2818; font-size:13px; border-left:2px solid var(--connection-color,#725a42); padding:0 6px; background:none; }
#messengerDialog .mv-video-toggle { font-size:14px; padding:5px 8px; background:#edc38c8c; }
#messengerDialog .mv-call-media, #messengerDialog .mv-local { background:#241b15; border-color:#6e492b; }
#messengerDialog .mv-quick-replies { background:#e3b77edb; border-color:#604020; }
#messengerDialog .mv-quick-replies button.selected { background:#603e28; color:#ffe2b7; }
#messengerDialog .mv-graph { opacity:1; }
#messengerDialog .mv-graph-label { color:#57382160; bottom:190px; right:48px; font-size:10px; letter-spacing:.4px; }
#messengerButton { background:#bf875ac7; color:#432b1b; border-color:#63402177; box-shadow:-2px 2px 12px #4c2c1830; }
#messengerButton.has-unread { background:#e7b87bdd; color:#43251a; }
#messengerBadge { background:#733d28; color:#ffe5bd; }
.mv-call-bar { font-family:'Spheno Inscription',serif; background:#d5a36fcf; color:#332014; border-color:#6b442b; }
@media (max-width:680px) {
 #messengerDialog .mv-shell { grid-template-columns:minmax(0,1fr); grid-template-rows:70px minmax(0,1fr) 64px auto; }
 #messengerDialog .mv-top-panel { grid-template-columns:minmax(0,1fr); padding-top:23px; }
 #messengerDialog .mv-top-panel::before { height:23px; }
 #messengerDialog .mv-top-panel .mv-brand { padding:0 45px 0 18px; }
 #messengerDialog .mv-chat-head { display:none; padding:2px 40px 2px 8px; }
 #messengerDialog .has-peer .mv-top-panel .mv-brand { display:none; }
 #messengerDialog .has-peer .mv-chat-head { display:flex; }
 #messengerDialog .mv-main { display:none; grid-area:2 / 1; }
 #messengerDialog .has-peer .mv-main { display:grid; }
 #messengerDialog .mv-sidebar { grid-area:2 / 1; }
 #messengerDialog .has-peer .mv-sidebar { display:none; }
 #messengerDialog .mv-gorgon-art { display:block; background-size:cover; }
 #messengerDialog .mv-sidebar-head { padding-right:18px; }
 #messengerDialog .mv-lower-frieze { background-size:auto 112px; }
 #messengerDialog .mv-controls { grid-template-columns:auto minmax(0,1fr); }
 #messengerDialog .mv-sidebar-foot { padding:3px 8px; }
 #messengerDialog .mv-sound-settings { font-size:12px; }
 #messengerDialog .mv-status { font-size:12px; padding-right:35px; }
 #messengerDialog .mv-bottom-tools { padding:3px 38px 3px 9px; }
 #messengerDialog .mv-composer { gap:4px; padding:4px 36px max(7px,env(safe-area-inset-bottom)) 8px; }
 #messengerDialog .mv-composer textarea { padding:9px; font-size:18px; }
 #messengerDialog .mv-history { padding:13px 38px 13px 12px; }
 #messengerDialog .mv-graph-label { display:none; }
}
@media (max-height:560px) {
 #messengerDialog .mv-shell { grid-template-rows:58px minmax(0,1fr) 40px auto; }
 #messengerDialog .mv-lower-frieze { background-size:auto 70px; }
 #messengerDialog .mv-top-panel { padding-top:17px; }
 #messengerDialog .mv-top-panel::before { height:17px; background-size:auto 125px; }
 #messengerDialog .mv-gorgon-art { display:block; }
}
/* Mirrored frame and a separate, non-overlapping figure well. */
#messengerDialog .mv-shell { grid-template-rows:88px minmax(0,1fr) 90px auto 25px; }
#messengerDialog .mv-top-panel { padding-bottom:12px; border-bottom:0; }
#messengerDialog .mv-top-panel::after { content:''; position:absolute; inset:auto 0 0; height:12px; background:url('/spheno-lower.webp') left top / auto 157px repeat-x; transform:scaleY(-1); }
#messengerDialog .mv-bottom-ornament { grid-area:5 / 1 / 6 / -1; background:url('/spheno-gorgon.webp') left top / auto 180px repeat-x; transform:scaleY(-1); z-index:3; }
#messengerDialog .mv-sidebar { container-type:size; }
#messengerDialog .mv-sidebar-head { order:0; flex:0 0 auto; }
#messengerDialog .mv-contacts { order:1; flex:1 1 0; min-height:0; overflow-y:auto; overscroll-behavior:contain; }
#messengerDialog .mv-gorgon-art { order:2; position:relative; inset:auto; z-index:auto; flex:0 0 auto; align-self:center; width:66.6667%; height:auto; aspect-ratio:1.4; margin:0 auto 8px; background-position:center; background-size:100% auto; opacity:1; }
@supports (width:1cqh) { #messengerDialog .mv-gorgon-art { width:min(66.6667%,50cqh); } }
#messengerDialog .mv-main { background:#211f18; isolation:isolate; }
#messengerDialog .mv-history { position:relative; z-index:1; }
#messengerDialog .mv-main .mv-empty { color:#c9ae86; }
#messengerDialog .mv-main .mv-empty strong { color:#ebc99e; }
#messengerDialog .mv-main .mv-empty svg { stroke:#c99661; }
#messengerDialog .mv-graph { z-index:0; }
#messengerDialog .mv-graph-label { color:#bc996b88; }
#messengerDialog .mv-mobile-back { flex:0 0 42px; width:42px; height:42px; min-height:42px; padding:7px; color:#2d1d13; background:#efc898bf; border:1px solid #6b432d70; }
#messengerDialog .mv-mobile-back svg { display:block; width:26px; height:26px; fill:none; stroke:currentColor; stroke-width:2.4; stroke-linecap:round; stroke-linejoin:round; }
@media (max-width:680px) {
 #messengerDialog .mv-shell { grid-template-rows:82px minmax(0,1fr) 64px auto 23px; }
 #messengerDialog .mv-top-panel { padding-bottom:12px; }
 #messengerDialog .mv-bottom-ornament { background-size:auto 180px; }
 #messengerDialog .has-peer .mv-mobile-back { display:inline-flex; align-items:center; justify-content:center; }
 #messengerDialog .mv-gorgon-art { background-size:100% auto; }
}
@media (max-height:560px) {
 #messengerDialog .mv-shell { grid-template-rows:70px minmax(0,1fr) 40px auto 17px; }
 #messengerDialog .mv-bottom-ornament { background-size:auto 125px; }
}

/* Compact composer: one action row above an edge-to-edge text field. */
#messengerDialog .mv-shell { grid-template-rows:76px minmax(0,1fr) 74px auto; }
#messengerDialog .mv-top-panel { padding-bottom:0; }
#messengerDialog .mv-top-panel::after { content:none; }
#messengerDialog .mv-brand { justify-content:flex-end; }
#messengerDialog .mv-gorgon-art { order:-1; margin:8px auto 0; }
#messengerDialog .mv-lower-frieze { background-position:left -16px; border-top:0; }
#messengerDialog .mv-controls { display:flex; flex-direction:column; align-items:stretch; padding:0; }
#messengerDialog .has-peer .mv-sidebar-foot { display:none; }
#messengerDialog .mv-sidebar-foot { align-self:flex-start; }
#messengerDialog .mv-status { padding:2px 8px; min-height:0; order:2; }
#messengerDialog .mv-composer { display:grid; grid-template-columns:repeat(7,minmax(0,1fr)); gap:0; align-items:center; padding:3px 0 max(3px,env(safe-area-inset-bottom)); margin:0; width:100%; position:relative; }
#messengerDialog .mv-composer textarea { grid-area:6 / 1 / 7 / -1; width:100%; margin:3px 0 0; border-radius:0; min-height:44px; }
#messengerDialog .mv-composer .mv-icon { width:40px; min-height:42px; height:42px; padding:7px; justify-self:center; margin:0; }
#messengerDialog .mv-attach { grid-area:1 / 1; }
#messengerDialog .mv-record { grid-area:1 / 6; }
#messengerDialog .mv-send { grid-area:1 / 7; }
#messengerDialog .mv-bottom-tools, #messengerDialog .mv-call, #messengerDialog .mv-call-actions { display:contents; }
#messengerDialog .mv-phone { grid-area:1 / 4; }
#messengerDialog .mv-call-video { grid-area:1 / 2; }
#messengerDialog .mv-reject { grid-area:1 / 5; }
#messengerDialog .mv-call-title { grid-area:2 / 1 / 3 / -1; padding:1px 8px; }
#messengerDialog .mv-network-route { grid-area:3 / 1 / 4 / -1; margin:0 8px; }
#messengerDialog .mv-media-note { grid-area:4 / 1 / 5 / -1; padding:0 8px; }
#messengerDialog .mv-media-note:empty { display:none; }
#messengerDialog .mv-enable-ring { grid-area:5 / 1 / 6 / -1; }
#messengerDialog .mv-call-more { grid-area:1 / 3; justify-self:center; position:static; }
#messengerDialog .mv-call-more summary { display:grid; place-items:center; width:40px; height:42px; cursor:pointer; list-style:none; border-radius:6px; background:#efc28b80; font-size:23px; }
#messengerDialog .mv-call-more summary::-webkit-details-marker { display:none; }
#messengerDialog .mv-call-more[open] summary { background:#f3cca5; }
#messengerDialog .mv-call-options { position:absolute; bottom:100%; left:8px; right:8px; display:flex; flex-wrap:wrap; align-items:center; gap:6px; padding:8px; background:#e3b77ef5; border:1px solid #604020; border-radius:8px; box-shadow:0 -4px 18px #0004; z-index:8; }
#messengerDialog .mv-quick-replies { bottom:100%; left:50%; transform:translateX(-50%); width:min(300px,95%); }
#messengerDialog .mv-graph-label { display:none; }
@media (max-width:680px) {
 #messengerDialog .mv-shell { grid-template-rows:70px minmax(0,1fr) 52px auto; }
 #messengerDialog .mv-top-panel { padding-bottom:0; }
 #messengerDialog .mv-lower-frieze { background-position:left -12px; }
 #messengerDialog .mv-composer { padding:3px 0 max(3px,env(safe-area-inset-bottom)); }
}
@media (max-height:560px) {
 #messengerDialog .mv-shell { grid-template-rows:58px minmax(0,1fr) 32px auto; }
 #messengerDialog .mv-lower-frieze { background-position:left -8px; }
}

#messengerDialog .mv-composer .mv-phone { background:#563723ba; color:#ffe1b2; }
#messengerDialog .mv-composer .mv-reject { background:#923d2dd9; color:#fff0d9; }

/* A shared network field behind floating contacts and the interrupted top band. */
#messengerDialog .mv-shell { grid-template-rows:48px minmax(0,1fr) 74px auto; isolation:isolate; }
#messengerDialog .mv-network-field { grid-area:1 / 1 / 3 / -1; position:relative; min-width:0; min-height:0; background:#211f18; overflow:hidden; z-index:0; pointer-events:none; }
#messengerDialog .mv-main { background:transparent; }
#messengerDialog .mv-sidebar { background:transparent; }
#messengerDialog .mv-contact { box-shadow:0 5px 16px #0005; }
#messengerDialog .mv-contacts .mv-empty { color:#d7bd98; }
#messengerDialog .mv-contacts .mv-empty strong { color:#f0d7b3; }
#messengerDialog .mv-top-panel { padding:0; align-items:center; background:transparent; border:0; }
#messengerDialog .mv-top-panel::before { top:50%; transform:translateY(-50%); height:25px; border:0; }
#messengerDialog .mv-brand { position:relative; z-index:1; justify-self:end; padding:0 6px; margin:0 16px; width:auto; height:44px; background:#211f18; }
#messengerDialog .mv-chat-head { justify-self:start; width:max-content; max-width:calc(100% - 32px); height:44px; margin:0 16px; padding:1px 5px; gap:6px; background:#211f18; color:#f0d7b3; }
#messengerDialog .mv-chat-title { flex:0 1 auto; }
#messengerDialog .mv-chat-title strong { max-width:300px; }
#messengerDialog .mv-chat-title small { display:none; }
#messengerDialog .mv-chat-head:empty { display:none; }
#messengerDialog .mv-chat-head .mv-icon { flex-shrink:0; color:#f0d7b3; }
#messengerDialog .mv-chat-head .mv-mobile-back { display:inline-flex; align-items:center; justify-content:center; color:#2d1d13; }
#messengerDialog .mv-chat-head .mv-avatar { width:33px; flex:0 0 33px; }
#messengerDialog .mv-bubble, #messengerDialog .mv-bubble .mv-file { color:#080604; font-weight:600; }
#messengerDialog .mv-bubble time { font-weight:400; }
@media (max-width:680px) {
 #messengerDialog .mv-shell { grid-template-rows:48px minmax(0,1fr) 52px auto; }
 #messengerDialog .mv-top-panel::before { height:23px; }
 #messengerDialog .mv-top-panel .mv-brand { padding:0 6px; }
 #messengerDialog .mv-chat-title strong { max-width:calc(100vw - 172px); }
}
@media (max-height:560px) {
 #messengerDialog .mv-shell { grid-template-rows:48px minmax(0,1fr) 32px auto; }
 #messengerDialog .mv-top-panel::before { height:17px; }
}

/* Standard full-width header: identity / market strip / actions. */
#messengerDialog .mv-shell { grid-template-rows:58px minmax(0,1fr) 51px auto; }
#messengerDialog .mv-top-panel { display:flex; gap:12px; padding:7px 12px; min-width:0; background:#33291feb; }
#messengerDialog .mv-top-panel::before, #messengerDialog .mv-top-panel::after { content:none; }
#messengerDialog .mv-chat-head { display:flex; flex:0 1 auto; width:auto; max-width:40%; min-width:0; height:44px; margin:0; padding:0; background:none; }
#messengerDialog .mv-chat-title { min-width:0; }
#messengerDialog .mv-chat-title strong { max-width:none; }
#messengerDialog .mv-list-title { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; font-size:18px; font-weight:400; }
#messengerDialog .mv-top-actions, #messengerDialog .mv-peer-actions { display:flex; align-items:center; flex:none; }
#messengerDialog .mv-top-panel .mv-brand, #messengerDialog .has-peer .mv-top-panel .mv-brand { display:flex; margin:0; padding:0; height:44px; background:none; }
#messengerDialog .mv-top-actions .mv-icon, #messengerDialog .mv-new { width:42px; min-height:42px; color:#f0d7b3; }
#messengerDialog .mv-market-ticker { flex:1; min-width:30px; overflow:hidden; border:0; border-radius:0; padding:0; height:40px; min-height:40px; text-align:left; background:transparent; color:#f0d7b3; font:14px Georgia,serif; }
#messengerDialog .mv-ticker-track { display:flex; width:max-content; animation:mv-market-scroll linear infinite; }
#messengerDialog .mv-ticker-track>span { display:block; white-space:pre; flex:none; }
#messengerDialog .mv-market-ticker:hover .mv-ticker-track, #messengerDialog .mv-market-ticker:focus .mv-ticker-track { animation-play-state:paused; }
#messengerDialog .mv-market-items { display:grid; gap:14px; }
#messengerDialog .mv-market-items a { color:inherit; text-decoration:underline; line-height:1.5; }
@keyframes mv-market-scroll { to { transform:translateX(-50%); } }
#messengerDialog .mv-lower-frieze { background-position:left -17px; border:0; }
#messengerDialog .mv-wallet { grid-area:2 / 1; z-index:1; align-self:end; justify-self:center; display:block; width:190px; max-width:75%; margin-bottom:6px; line-height:0; border-radius:8px; }
#messengerDialog .mv-wallet img { display:block; width:100%; height:auto; }
#messengerDialog .mv-wallet:focus-visible { outline:1px solid #f4d9ab; outline-offset:3px; }
#messengerDialog .mv-sidebar { padding-bottom:138px; }
@media (max-width:680px) {
 #messengerDialog .mv-shell { grid-template-rows:56px minmax(0,1fr) 36px auto; }
 #messengerDialog .mv-top-panel { padding:6px; gap:5px; }
 #messengerDialog .mv-chat-head { max-width:48%; gap:4px; }
 #messengerDialog .mv-chat-head .mv-avatar { flex:0 0 26px; width:26px; height:26px; font-size:15px; }
 #messengerDialog .mv-chat-title strong { font-size:16px; }
 #messengerDialog .mv-market-ticker { font-size:12px; }
 #messengerDialog .mv-lower-frieze { background-position:left -12px; }
 #messengerDialog .mv-wallet { grid-area:2 / 1; }
 #messengerDialog .has-peer .mv-wallet { width:105px; justify-self:end; margin-right:8px; }
 #messengerDialog .has-peer .mv-history { padding-bottom:82px; }
}
@media (max-height:560px) {
 #messengerDialog .mv-shell { grid-template-rows:56px minmax(0,1fr) 22px auto; }
 #messengerDialog .mv-lower-frieze { background-position:left -8px; }
 #messengerDialog .mv-wallet { width:95px; }
 #messengerDialog .mv-sidebar { padding-bottom:70px; }
}
@media (prefers-reduced-motion:reduce) { #messengerDialog .mv-ticker-track { animation:none; } }

/* Wallet sits beside the two composer rows, outside chat content. */
#messengerDialog .mv-controls { display:grid; grid-template-columns:clamp(94px,26vw,140px) minmax(0,1fr); grid-template-rows:auto auto; align-items:end; }
#messengerDialog .mv-controls .mv-wallet { grid-area:1 / 1; align-self:end; justify-self:stretch; width:100%; max-width:none; height:94px; margin:0; padding:2px 4px; }
#messengerDialog .mv-controls .mv-wallet img { width:100%; height:100%; object-fit:contain; }
#messengerDialog .mv-controls .mv-composer, #messengerDialog .mv-controls .mv-sidebar-foot { grid-area:1 / 2; min-width:0; }
#messengerDialog .mv-controls .mv-status { grid-area:2 / 1 / 3 / -1; }
#messengerDialog .mv-sidebar { padding-bottom:0; }
#messengerDialog .has-peer .mv-history { padding-bottom:18px; }
#messengerDialog .mv-composer .mv-video-toggle { grid-area:1 / 5; font-size:11px; padding:2px; overflow-wrap:anywhere; background:#efc28b80; color:#352217; }
#messengerDialog .mv-message-text { user-select:text; -webkit-user-select:text; }
#messengerDialog .mv-message-text a { color:inherit; text-decoration:underline; }
@media (max-width:380px) {
 #messengerDialog .mv-composer .mv-icon, #messengerDialog .mv-call-more summary { width:30px; padding:4px; }
 #messengerDialog .mv-composer .mv-video-toggle { font-size:10px; padding:0; }
}

#messengerDialog .mv-call .mv-video-toggle[aria-pressed="true"] { opacity:1; }

/* Protected archive and explicit command recipes. */
#messengerDialog .mv-sidebar-head { display:flex; gap:6px; }
#messengerDialog .mv-sidebar-head input { min-width:0; flex:1; }
#messengerDialog .mv-archive-open { flex:none; }
#messengerDialog .mv-archive-card { max-height:90dvh; overflow:auto; }
#messengerDialog .mv-archive-list { display:grid; gap:8px; }
#messengerDialog .mv-archive-contact { text-align:left; }
#messengerDialog .mv-command-row { display:flex; gap:6px; align-items:center; flex-wrap:wrap; margin:6px 0; }
#messengerDialog .mv-command-row strong, #messengerDialog .mv-command-row span { flex:1; }
#messengerDialog .mv-card select, #messengerDialog .mv-card textarea { width:100%; box-sizing:border-box; padding:10px; margin:5px 0; background:rgba(232,195,146,.9); color:#160e08; font:inherit; }
#messengerDialog [data-archive-peer] { cursor:pointer; user-select:none; }

/* Invitation landing and saved profiles (2026-09-29). Outside #messengerDialog: shown before sign-in. */
.mv-landing { position:fixed; inset:0; z-index:2147483000; display:grid; place-items:center; padding:16px; overflow-y:auto; background:#0a1015f2; color:#e9edf4; font:15px/1.45 Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif; }
.mv-landing * { box-sizing:border-box; }
.mv-landing-card { width:min(440px,100%); display:flex; flex-direction:column; gap:10px; padding:22px 20px; border:1px solid #72899544; border-radius:18px; background:#15212b; box-shadow:0 18px 60px #0008; }
.mv-landing-card:focus { outline:none; }
.mv-landing h2 { margin:0 0 4px; font-size:21px; letter-spacing:-.3px; }
.mv-landing h3 { margin:8px 0 0; font-size:13px; font-weight:600; color:#a4b7c4; }
.mv-landing p { margin:0 0 6px; overflow-wrap:anywhere; }
.mv-landing small { color:#a4b7c4; font-size:12px; overflow-wrap:anywhere; }
.mv-landing small:empty { display:none; }
.mv-landing button, .mv-landing input { font:inherit; color:inherit; }
.mv-landing button { width:100%; min-height:44px; border:1px solid #72899533; border-radius:12px; padding:10px 14px; background:#263944; cursor:pointer; }
.mv-landing button:hover:not(:disabled) { background:#324d5a; }
.mv-landing button:disabled { opacity:.45; cursor:default; }
.mv-landing .mv-primary { background:#bddf9b; color:#182913; border-color:transparent; font-weight:650; }
.mv-landing .mv-primary:hover:not(:disabled) { background:#cbe8ad; }
.mv-landing button:focus-visible, .mv-landing input:focus-visible { outline:2px solid #d8ff72; outline-offset:2px; }
.mv-landing-node { display:flex; flex-direction:column; gap:8px; padding:12px; border-radius:14px; background:#101c25; }
.mv-landing-node[hidden] { display:none; }
.mv-landing-node label { display:flex; flex-direction:column; gap:6px; font-size:13px; color:#a4b7c4; }
.mv-landing-node input { width:100%; border:1px solid #72899544; border-radius:12px; padding:11px 13px; background:#0c151c; }
.mv-landing-profiles, #messengerDialog .mv-profile-list { display:flex; flex-direction:column; gap:8px; margin-bottom:8px; }
.mv-landing-actions { margin-top:6px; }
#messengerDialog .mv-profile-row { display:grid; grid-template-columns:minmax(0,1fr) auto; gap:8px; }
#messengerDialog .mv-wallet { cursor:pointer; touch-action:manipulation; -webkit-tap-highlight-color:transparent; }

/* Explicit device-code verification, scoped to the keys dialog. */
.mv-my-device-code{width:100%;min-height:5em;font:14px/1.5 ui-monospace,monospace;overflow-wrap:anywhere;user-select:text}.mv-key-row{display:block;padding:8px 0}.mv-key-row input:not([type=checkbox]){display:block;width:100%;margin-top:6px;font:13px ui-monospace,monospace}.mv-key-row input[type=checkbox]{margin-right:8px}

/* Local preview is not a call and is never sent before pressing the handset. */
#messengerDialog .mv-camera-preview .mv-preview-video { width:100%; height:100%; object-fit:contain; }
#messengerDialog .mv-preview-caption { position:absolute; bottom:0; left:0; right:0; padding:12px; margin:0; background:#241b15cc; color:#fff; text-align:center; }
#messengerDialog .mv-camera-armed { outline:2px solid #ab7445; }
#messengerDialog .mv-call-video { touch-action:none; -webkit-user-select:none; user-select:none; }

/* Spheno calls 10.10: call focus, diagnostic overlay, relay selection */
.mv-history { transition: opacity .45s ease, filter .45s ease; }
.mv-shell.mv-call-focus .mv-graph, #messengerDialog .mv-shell.mv-call-focus .mv-graph { opacity: 1; }
.mv-shell.mv-call-focus .mv-main, #messengerDialog .mv-shell.mv-call-focus .mv-main { background: transparent; }
.mv-shell.mv-call-focus:not(.mv-call-messages) .mv-history,
#messengerDialog .mv-shell.mv-call-focus:not(.mv-call-messages) .mv-history { opacity: .07; filter: blur(1.5px); pointer-events: none; }
.mv-call-diag { position: absolute; left: 50%; top: 18%; transform: translateX(-50%); z-index: 2; max-width: min(92%, 420px);
  pointer-events: none; text-align: center; font-size: 13px; line-height: 1.5; color: #e8d7b8; text-shadow: 0 1px 2px #000a;
  opacity: 0; transition: opacity .45s ease; }
.mv-call-diag > div:first-child { font-size: 15px; letter-spacing: .3px; }
.mv-shell.mv-call-focus:not(.mv-call-messages) .mv-call-diag { opacity: 1; }
#messengerDialog .mv-call-diag { color: #3d2818; text-shadow: none; }
#messengerDialog .mv-shell.mv-call-focus .mv-call-diag { color: #f1dfbf; text-shadow: 0 1px 2px #000c; }
.mv-relay-bar { display: flex; align-items: center; gap: 8px; padding: 8px 10px; flex-wrap: wrap; }
.mv-relay-bar label { flex: 1; font-size: 13px; }
.mv-relay-pick { display: flex; align-items: center; gap: 4px; margin-left: auto; font-size: 11px; white-space: nowrap; }
.mv-relay-tag { margin-left: auto; font-size: 10px; letter-spacing: .4px; padding: 1px 5px; border-radius: 6px; border: 1px solid currentColor; opacity: .7; }
@media (prefers-reduced-motion: reduce) { .mv-history, .mv-call-diag { transition: none; } }
