/* Messages owns its layout. No inherited dashboard cards or page headings. */
body[data-view="conversations"] { min-height:100dvh; }
body[data-view="conversations"] .app-shell { height:100dvh; padding:0 0 0 220px; }
body[data-view="conversations"] .topbar { display:none; }
body[data-view="conversations"] .main { height:100%; width:100%; max-width:none; margin:0; padding:0; }
.m-screen { height:100%; display:grid; grid-template-columns:334px minmax(0,1fr); color:#242529; }
.m-screen button { font:inherit; }
.m-screen svg,.m-contact-dialog svg { width:22px; height:22px; stroke-width:1.7; flex:none; }
.m-inbox { min-width:0; display:flex; flex-direction:column; border-right:1px solid #ececef; background:#fff; min-height:0; }
.m-inbox-head { padding:24px 22px 12px; flex:none; }
.m-inbox-title { display:flex; align-items:center; justify-content:space-between; margin-bottom:18px; }
.m-inbox-title h1 { font-size:27px; letter-spacing:-.75px; line-height:1.15; font-weight:700; margin:0; }
.m-icon-button { display:grid; place-items:center; flex:none; width:44px; height:44px; padding:0; border:0; border-radius:50%; color:#6b6d73; background:transparent; }
.m-icon-button:hover { background:#f2f3f5; color:#292b30; }
.m-icon-button:active { background:#e9ebed; }
.m-search { display:flex; align-items:center; gap:9px; background:#f1f2f4; border-radius:12px; padding:0 12px; color:#797c83; }
.m-search svg { width:18px; height:18px; }
.m-search input { width:100%; min-width:0; height:42px; padding:0; font-size:14px; border:0; background:transparent; color:#27292d; }
.m-search input::placeholder { color:#656a72; }
.m-filters { display:flex; gap:5px; margin-top:16px; }
.m-filters button { display:flex; align-items:center; gap:7px; min-height:38px; border:0; border-radius:20px; padding:0 14px; background:transparent; color:#666970; font-size:13px; font-weight:550; }
.m-filters button[aria-pressed="true"] { background:#e7f4f1; color:#09645e; }
.m-filters button:hover { background:#f1f3f4; }
.m-filters button span { font-size:11px; }
.m-conversations { min-height:0; flex:1; overflow:auto; padding:0 10px 20px; overscroll-behavior:contain; scrollbar-width:thin; }
.m-conversation { width:100%; display:flex; align-items:center; gap:13px; min-width:0; padding:16px 12px; border:0; background:transparent; border-radius:12px; color:inherit; text-align:left; transition:background .12s; }
.m-conversation:hover { background:#f5f6f7; }
.m-conversation.is-selected { background:#edf6f4; }
.m-avatar { display:grid; place-items:center; flex:none; width:50px; height:50px; border-radius:50%; font-size:15px; font-weight:550; letter-spacing:.2px; }
.m-tone-0 { color:#586575; background:#e7edf3; }.m-tone-1 { color:#746257; background:#f0e8e1; }.m-tone-2 { color:#736382; background:#eee9f4; }.m-tone-3 { color:#506e64; background:#e4eee9; }
.m-row-copy { flex:1; min-width:0; }
.m-row-top { display:flex; gap:10px; align-items:baseline; margin-bottom:5px; }
.m-row-top strong { font-size:14px; font-weight:650; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; letter-spacing:-.15px; }
.m-row-top time { margin-left:auto; font-size:11px; color:#656a72; white-space:nowrap; }
.m-preview { display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; overflow:hidden; font-size:13px; line-height:1.45; color:#656a72; overflow-wrap:anywhere; }
.m-reply-label { display:block; font-size:11px; color:#08776f; font-weight:600; margin-top:5px; }
.m-thread { display:flex; flex-direction:column; min-height:0; min-width:0; background:#fff; }
.m-thread-head { display:flex; align-items:center; gap:12px; min-height:88px; padding:16px 30px; border-bottom:1px solid #f0f0f2; flex:none; }
.m-thread-head .m-avatar { width:42px; height:42px; font-size:12px; }
.m-thread-person { flex:1; min-width:0; }
.m-thread-person h2 { margin:0; font-size:16px; font-weight:650; letter-spacing:-.25px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.m-thread-person p { margin:5px 0 0; font-size:12px; color:#70737a; }
.m-back { display:none; }
.m-history { flex:1; min-height:0; overflow:auto; overscroll-behavior:contain; scrollbar-width:thin; padding:0 32px 20px; }
.m-history-inner { display:flex; flex-direction:column; gap:16px; max-width:860px; margin:0 auto; }
.m-date { font-size:11px; font-weight:500; color:#656a72; text-align:center; margin:26px 0 8px; }
.m-message { display:flex; flex-direction:column; align-items:flex-start; align-self:flex-start; max-width:min(82%,480px); gap:5px; }
.m-bubble { padding:12px 16px; border-radius:19px; background:#f0f1f3; color:#282b30; font-size:15px; line-height:1.5; white-space:pre-wrap; overflow-wrap:anywhere; }
.m-in .m-bubble { border-bottom-left-radius:6px; }
.m-out { align-self:flex-end; align-items:flex-end; }
.m-out .m-bubble { background:#b8eee6; color:#173b35; border-bottom-right-radius:6px; }
.m-message-meta { padding:0 5px; font-size:11px; line-height:1.4; color:#656a72; }
.m-compose-area { flex:none; width:100%; max-width:924px; margin:0 auto; padding:12px 32px 16px; }
.m-assistant-hint { font-size:11px; color:#656a72; margin:0 0 10px 5px; }
.m-assistant-hint[hidden] { display:none; }
.m-input-wrap { display:flex; align-items:flex-end; gap:10px; padding:6px; border-radius:26px; background:#f3f4f6; }
.m-input-wrap:focus-within { outline:2px solid #08776f; outline-offset:2px; }
.m-input-wrap textarea { flex:1; min-width:0; background:transparent; resize:none; border:0; outline:none; font:inherit; font-size:15px; line-height:24px; min-height:38px; max-height:144px; padding:7px 0 7px 13px; margin:0; color:#282b30; }
.m-input-wrap textarea:focus-visible { outline:none; }
.m-input-wrap textarea::placeholder { color:#656a72; }
.m-send { display:grid; place-items:center; flex:none; width:38px; height:38px; padding:0; border:0; border-radius:50%; background:#2ec9bc; color:#103a34; transition:background .12s; }
.m-send:hover { background:#50d5c7; }
.m-send:disabled { opacity:1; cursor:default; background:#e2e5e8; color:#898e94; }
.m-send svg { width:21px; height:21px; stroke-width:2; }
.m-demo-note { margin:9px 0 0; font-size:11px; text-align:center; color:#656a72; }
.m-send-error { font-size:13px; color:#a13232; margin:10px 5px 0; }
.m-empty-list { padding:42px 16px; text-align:center; }.m-empty-list strong { font-weight:600; font-size:15px; }.m-empty-list p { font-size:13px; line-height:1.5; color:#656a72; }
.m-text-button { background:none; border:0; color:#08776f; min-height:44px; font-size:13px; }
.m-no-thread { align-items:center; justify-content:center; text-align:center; padding:30px; }.m-no-thread > span { color:#b4bebc; }.m-no-thread svg { width:42px; height:42px; stroke-width:1.3; }.m-no-thread h2 { font-size:20px; font-weight:600; margin:18px 0 0; letter-spacing:-.4px; }.m-no-thread p,.m-no-messages { color:#656a72; font-size:14px; line-height:1.5; }.m-no-messages { text-align:center; margin-top:32px; }
.m-contact-dialog { width:390px; max-width:calc(100vw - 32px); max-height:calc(100dvh - 32px); overflow:auto; border:0; border-radius:22px; padding:38px 28px 28px; color:#242529; box-shadow:0 20px 80px #1d2a3026; }
.m-contact-dialog::backdrop { background:#18282e26; }.m-contact-close { position:absolute; top:10px; right:10px; }.m-avatar-profile { width:76px; height:76px; font-size:23px; margin:0 auto 18px; }.m-contact-dialog h2 { text-align:center; font-size:22px; font-weight:650; letter-spacing:-.5px; margin:0 0 6px; }.m-contact-dialog > p { text-align:center; color:#6d7178; margin:0; font-size:13px; }.m-contact-dialog dl { margin:30px 0 0; }.m-contact-dialog dt { color:#656a72; font-size:12px; margin-top:22px; }.m-contact-dialog dd { margin:5px 0 0; font-size:14px; line-height:1.5; overflow-wrap:anywhere; }
@media (min-width:801px) and (max-width:1100px) { body[data-view="conversations"] .app-shell { padding-left:196px; }.m-screen { grid-template-columns:270px minmax(0,1fr); }.m-inbox-head { padding-inline:16px; }.m-conversations { padding-inline:5px; }.m-conversation { gap:10px; padding-inline:10px; }.m-avatar { width:42px; height:42px; font-size:13px; }.m-row-top { gap:4px; }.m-row-top strong { font-size:13px; }.m-row-top time { font-size:10px; }.m-history { padding-inline:20px; }.m-compose-area { padding-inline:20px; }.m-thread-head { padding-inline:18px; } }
@media (max-width:800px) {
 body[data-view="conversations"] .app-shell { height:100dvh; padding:0 0 calc(64px + env(safe-area-inset-bottom)); }
 .m-screen { display:block; }.m-inbox { height:100%; border:0; }.m-inbox-head { padding:20px 22px 8px; }.m-inbox-title { margin-bottom:18px; }.m-inbox-title h1 { font-size:32px; letter-spacing:-1px; }.m-search input { font-size:16px; height:44px; }.m-search { border-radius:12px; }.m-filters { margin-top:14px; }.m-filters button { min-height:44px; font-size:14px; padding-inline:15px; }
 .m-conversations { padding:0 10px 12px; }.m-conversation { padding:16px 12px; gap:15px; border-radius:0; }.m-conversation.is-selected { background:transparent; }.m-avatar { width:54px; height:54px; font-size:16px; }.m-row-top strong { font-size:16px; }.m-row-top time { font-size:12px; }.m-preview { font-size:14px; line-height:1.45; }
 .m-thread { display:none; height:100%; }.m-thread-open .m-inbox { display:none; }.m-thread-open .m-thread { display:flex; }.m-back { display:grid; color:#08776f; margin-left:-8px; }.m-thread-head { min-height:78px; padding:12px 12px; gap:9px; }.m-thread-head .m-avatar { width:38px; height:38px; font-size:12px; }.m-thread-head .m-icon-button { width:44px; }.m-thread-person h2 { font-size:16px; }.m-thread-person p { font-size:11px; }.m-thread-person { margin-right:0; }.m-history { padding:0 18px 16px; }.m-history-inner { gap:16px; }.m-date { margin-top:22px; }.m-message { max-width:min(87%,480px); }.m-bubble { font-size:16px; padding:11px 15px; }.m-compose-area { padding:10px 14px max(12px,env(safe-area-inset-bottom)); }.m-input-wrap textarea { font-size:16px; }.m-send { width:44px; height:44px; }.m-input-wrap textarea { min-height:44px; padding-block:10px; }.m-demo-note { font-size:11px; }
 body[data-view="conversations"].message-thread-open .app-shell { padding-bottom:0; }
 body[data-view="conversations"].message-thread-open .bottom-nav { display:none; }
 body[data-view="conversations"].message-thread-open .toast { bottom:108px; }
}
@media (prefers-reduced-motion:reduce) { .m-conversation,.m-send { transition:none; } }

.m-row-alert { display:block; font-size:12px; color:#a13232; margin-top:5px; font-weight:550; }
