:root{color-scheme:light;--ink:#202d29;--muted:#7b8781;--line:#e6ebe7;--green:#25694e;--green-light:#eaf4ee;--paper:#fff;--background:#f7f9f6;font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;font-size:14px}*{box-sizing:border-box}body{margin:0;background:var(--background);color:var(--ink)}button,input,textarea,select{font:inherit}button{cursor:pointer;border:0;border-radius:9px;font-weight:600;transition:background .15s}button:disabled{opacity:.5;cursor:not-allowed}button:focus-visible,a:focus-visible{outline:3px solid #8bc4a5;outline-offset:3px}input,textarea,select{border:1px solid #dbe3dc;border-radius:8px;padding:11px 12px;background:#fff;color:var(--ink);width:100%;outline:none}input:focus,textarea:focus,select:focus{border-color:#549674;box-shadow:0 0 0 3px #dceee2}textarea{resize:vertical}label{display:block;font-size:13px;font-weight:600;margin:16px 0 8px}label input,label textarea,label select{margin-top:7px;font-weight:400}h1,h2,h3,p{margin-top:0}h1{font-size:28px;letter-spacing:-.8px;margin-bottom:0}h2{font-size:18px;letter-spacing:-.35px}p{line-height:1.6}.muted{color:var(--muted)}.small{font-size:12px;line-height:1.5}.hidden{display:none!important}.primary{background:var(--green);color:white;padding:12px 18px}.primary:hover{background:#1b543c}.secondary{background:#edf3ed;color:#315e45;padding:11px 16px}.secondary:hover{background:#e0ece1}.danger{color:#a34236;background:#faeee9}.icon-button{background:none;font-size:23px;padding:5px 9px;color:var(--muted)}.pill{display:inline-flex;align-items:center;gap:7px;background:#eef3ec;border:1px solid #e3eadf;color:#58714c;font-size:12px;padding:8px 12px;border-radius:30px}.pill:before,.small-dot{content:"";display:inline-block;width:6px;height:6px;background:#83a16f;border-radius:50%}.eyebrow{color:#8b978d;font-size:10px;font-weight:700;letter-spacing:1.6px;margin-bottom:8px}.brand{display:flex;align-items:center;font-size:29px;font-weight:750;letter-spacing:-1.5px;gap:2px}.brand-mark{display:flex;align-items:center;justify-content:center;background:#2c6c50;color:#fff;font-size:28px;font-weight:600;height:38px;width:38px;border-radius:11px;margin-right:10px;padding-bottom:4px}.brand-dot{color:#6e9c70}.app{display:grid;grid-template-columns:222px minmax(0,1fr);height:100dvh;min-height:600px}.sidebar{display:flex;flex-direction:column;border-right:1px solid var(--line);background:#f5f7f2;padding:29px 18px 15px}.sidebar .brand{padding:0 10px}.workspace-label{font-size:9px;letter-spacing:1.6px;color:#9aa497;font-weight:700;margin:45px 13px 16px}nav{display:grid;gap:7px}.nav-item{display:flex;align-items:center;text-align:left;width:100%;padding:12px 13px;color:#75806f;background:none;gap:11px;font-size:13px;font-weight:500}.nav-item>span:first-child{font-size:20px;width:20px}.nav-item.active{background:#e4eddf;color:#3d6244;font-weight:650}.nav-item:hover{background:#eaf0e6}.nav-count{font-size:11px;background:#cbdcbe;color:#496542;border-radius:6px;padding:2px 6px;margin-left:auto}.sidebar-note{margin-top:auto;padding:25px 10px 18px;font-size:11px;color:#75856f;line-height:1.5}.sidebar-note .small-dot{margin-right:5px}.sidebar-note p{font-size:11px;color:#9aa493;margin:8px 0 0}.profile{display:flex;align-items:center;gap:10px;padding:18px 4px 0;border-top:1px solid #e2e8dc}.avatar{display:flex;align-items:center;justify-content:center;border-radius:50%;width:32px;height:32px;background:#e3e9da;color:#60714d;font-size:12px;flex:none}.profile strong{font-size:12px;font-weight:600;display:block}.profile small{display:block;color:#98a08f;font-size:10px;margin-top:3px}.profile .icon-button{margin-left:auto;font-size:18px}.main{display:flex;flex-direction:column;min-width:0;background:#fff}.topbar{height:105px;flex-shrink:0;display:flex;justify-content:space-between;align-items:center;padding:24px 32px;border-bottom:1px solid var(--line)}.top-actions{display:flex;align-items:center;gap:15px}.view{min-height:0;flex:1}.inbox-view{display:flex}.conversation-panel{width:323px;flex-shrink:0;border-right:1px solid var(--line);display:flex;flex-direction:column}.list-header{display:flex;justify-content:space-between;align-items:center;padding:26px 22px 16px}.list-header h2{font-size:14px;margin:0}.search{width:calc(100% - 40px);margin:0 20px 18px;border-color:transparent;background:#f4f6f1;font-size:12px;padding:11px 12px}.conversation-list{overflow:auto;flex:1}.conversation-item{width:100%;border-radius:0;background:white;text-align:left;padding:19px 21px;border-top:1px solid #f0f2ee;position:relative;font-weight:400}.conversation-item:hover{background:#f8faf6}.conversation-item.selected{background:#eef5ec}.conversation-item.selected:before{content:"";position:absolute;inset:0 auto 0 0;width:3px;background:#658f5c}.conversation-row{display:flex;align-items:center;justify-content:space-between;gap:12px}.conversation-name{font-size:13px;font-weight:650;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.conversation-time{font-size:10px;color:#9ba498;flex:none}.conversation-preview{font-size:12px;color:#8e9989;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;margin:9px 0}.conversation-meta{display:flex;align-items:center;gap:7px}.channel-label{display:inline-block;font-size:9px;letter-spacing:.3px;color:#63845d;background:#e9f0e3;padding:3px 6px;border-radius:4px}.unread{margin-left:auto;background:#6c955e;color:white;border-radius:50%;min-width:17px;height:17px;padding:2px 4px;text-align:center;font-size:10px}.empty-chat{display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center;flex:1;background:radial-gradient(ellipse at center,#f8fbf5,white 70%);gap:5px}.empty-symbol{width:80px;height:80px;background:#edf3e8;border:1px solid #e3ecdc;border-radius:24px;display:grid;place-items:center;font-size:38px;color:#7e9a6b;margin-bottom:20px}.empty-chat h2{font-size:21px;margin:0 0 8px}.empty-chat p{color:#929e8b;font-size:13px;margin-bottom:16px}.empty-chat .small{margin-top:12px}.chat-panel{flex:1;display:flex;flex-direction:column;min-width:0}.chat-header{min-height:86px;padding:19px 29px;border-bottom:1px solid var(--line);display:flex;align-items:center;justify-content:space-between;gap:15px}.chat-header h2{font-size:16px;margin:0 0 5px}.chat-header p{font-size:11px;margin:0}.assignee-label{margin:0;color:#99a28f;font-size:9px;font-weight:400}.assignee-label select{padding:5px 20px 5px 7px;margin-top:4px;font-size:11px;border-color:#edf1e9;width:160px}.messages{flex:1;overflow:auto;background:#fbfcf9;padding:26px 30px;display:flex;flex-direction:column;gap:14px}.message{max-width:80%;align-self:flex-start}.message.outbound{align-self:flex-end}.bubble{padding:12px 15px;background:white;border:1px solid #e9eee4;border-radius:12px 12px 12px 2px;white-space:pre-wrap;overflow-wrap:anywhere;font-size:13px;line-height:1.55}.outbound .bubble{background:#eaf3e4;border-color:#e1ecd8;border-radius:12px 12px 2px 12px}.message-footer{display:flex;align-items:center;gap:7px;color:#9aa491;font-size:9px;margin-top:6px}.outbound .message-footer{justify-content:flex-end}.message-error{font-size:11px;color:#a46843;margin:5px 0;max-width:400px;line-height:1.5}.message-footer button{font-size:10px;padding:2px 5px}.composer{border-top:1px solid var(--line);padding:20px 27px 18px}.composer textarea{border:0;box-shadow:none;padding:4px 0 12px;min-height:54px;max-height:160px;font-size:13px;resize:none}.composer-bottom{display:flex;align-items:center;justify-content:space-between}.composer-bottom .small{font-size:10px;color:#adb5a5}.composer .primary{font-size:12px;padding:11px 16px}.page-view{background:#fafcf8;overflow:auto;padding:32px}.page-intro{max-width:700px;margin:0 0 27px}.page-intro h2{font-size:22px;margin-bottom:8px}.page-intro p{font-size:13px;color:#8b9784;margin-bottom:0}.channel-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:20px;max-width:1000px}.channel-card,.settings-card{border:1px solid var(--line);background:white;border-radius:14px;padding:25px}.channel-card-top{display:flex;align-items:center;gap:13px;margin-bottom:20px}.channel-icon{display:grid;place-items:center;width:43px;height:43px;border-radius:12px;font-size:21px;font-weight:700;background:#eaf3e5;color:#59954c}.channel-icon.telegram{background:#e6f2f9;color:#509bc2}.channel-icon.viber{background:#efebf9;color:#8d73bf}.channel-icon.whatsapp{background:#e6f6e9;color:#4b9e62}.channel-card h3{font-size:17px;margin:0 0 5px}.status{font-size:11px;color:#8c9784}.status.connected{color:#52804c}.status.error,.status.needs_login{color:#b0804f}.channel-card p{font-size:12px;color:#8c9784;min-height:42px}.channel-buttons{display:flex;gap:8px;flex-wrap:wrap}.channel-buttons button{font-size:12px;padding:10px 13px}.notice{max-width:1000px;border-radius:12px;background:#edf3e8;border:1px solid #e0ead8;margin-top:26px;padding:20px 23px;color:#667d58}.notice strong{font-size:12px}.notice p{font-size:12px;margin:7px 0 0}.event-list{background:white;border:1px solid var(--line);border-radius:12px;overflow:hidden}.event-row{display:grid;grid-template-columns:155px 1fr 140px;gap:15px;padding:15px 20px;border-bottom:1px solid #eff2eb;align-items:center;font-size:12px}.event-type{font-family:ui-monospace,monospace;font-size:11px;color:#557e4b}.event-detail{color:#8b9783;overflow-wrap:anywhere}.event-time{color:#a0aa97;font-size:10px;text-align:right}.settings-grid{display:grid;grid-template-columns:1fr 1fr;gap:22px;max-width:1100px}.settings-card>p{font-size:12px}.settings-card form{border-top:1px solid var(--line);margin-top:20px;padding-top:5px}.settings-card form button{margin-top:10px}.user-row,.hook-row{display:flex;justify-content:space-between;align-items:center;gap:10px;padding:12px 0;border-bottom:1px solid #f0f3ec;font-size:12px}.hook-row span{overflow-wrap:anywhere;min-width:0}.login-screen{min-height:100dvh;display:grid;place-items:center;padding:25px;background:radial-gradient(ellipse at top,#edf4e7,#fafcf8 70%)}.login-card{width:420px;max-width:100%;padding:38px;background:#fff;border:1px solid #e0e9da;border-radius:20px;box-shadow:0 20px 70px #526f3910}.login-card .brand{margin-bottom:35px}.login-card h1{font-size:26px;margin-bottom:12px}.login-card>.primary{width:100%;margin:5px 0 20px}.login-card>.small{margin-bottom:0;text-align:center;font-size:10px}.login-card>.eyebrow{font-size:9px}.error{font-size:12px;color:#b44c42;min-height:15px;margin-top:12px}dialog{border:1px solid #dce6d7;border-radius:17px;padding:0;max-width:calc(100% - 40px);width:450px;box-shadow:0 20px 90px #19291630}dialog::backdrop{background:#21332555;backdrop-filter:blur(3px)}.dialog-form{padding:27px}.dialog-heading{display:flex;justify-content:space-between;align-items:center;gap:10px;margin-bottom:16px}.dialog-heading h2{margin:0;font-size:20px}.dialog-form>p{font-size:12px}.dialog-form .primary{margin-top:18px;width:100%}.dialog-form a{color:var(--green)}.auth-qr{display:block;max-width:100%;width:280px;margin:20px auto}.toast{position:fixed;z-index:30;bottom:24px;left:50%;transform:translateX(-50%);background:#22382d;color:white;padding:13px 20px;border-radius:11px;max-width:calc(100% - 40px);font-size:13px;box-shadow:0 8px 40px #0002}.list-empty{padding:35px 22px;font-size:12px;color:#9aa58f;text-align:center}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}@media(max-width:1050px){.app{grid-template-columns:180px 1fr}.sidebar{padding:25px 12px 12px}.sidebar .brand{font-size:24px;padding:0 5px}.brand-mark{width:31px;height:31px;font-size:24px}.workspace-label{font-size:8px;margin-left:8px}.conversation-panel{width:265px}.topbar{padding:22px}.top-actions{gap:8px}.top-actions .pill{display:none}.chat-header{padding:17px}.messages{padding:20px}.composer{padding:15px 17px}.composer-bottom .small{display:none}.settings-grid{grid-template-columns:1fr}.event-row{grid-template-columns:130px 1fr}.event-time{grid-column:2;text-align:left}.profile strong{max-width:80px;overflow:hidden;text-overflow:ellipsis}}@media(max-width:750px){.app{grid-template-columns:1fr;height:auto;min-height:100dvh}.sidebar{padding:12px 15px;border-right:0;border-bottom:1px solid var(--line);display:block}.sidebar>.brand,.workspace-label,.sidebar-note,.profile{display:none}nav{display:flex;gap:5px}.nav-item{justify-content:center;padding:8px;font-size:11px;gap:6px}.nav-item>span:first-child{font-size:17px;width:auto}.topbar{height:85px;padding:17px}.topbar h1{font-size:24px}.topbar .eyebrow{font-size:8px}.topbar .primary{font-size:11px;padding:10px}.inbox-view{height:calc(100dvh - 151px)}.conversation-panel{width:200px}.list-header{padding:18px 12px}.list-header h2{font-size:12px}.search{width:calc(100% - 20px);margin:0 10px 10px;padding:9px 7px;font-size:10px}.conversation-item{padding:15px 12px}.conversation-name{font-size:11px}.conversation-time{display:none}.conversation-preview{font-size:11px}.chat-header{min-height:75px;padding:12px;flex-wrap:wrap;gap:8px}.chat-header h2{font-size:13px}.assignee-label{display:none}.messages{padding:13px}.message{max-width:95%}.bubble{font-size:12px;padding:10px}.message-footer{font-size:8px;flex-wrap:wrap}.composer{padding:12px}.composer textarea{font-size:12px}.composer-bottom{justify-content:flex-end}.page-view{padding:20px 15px}.channel-grid{grid-template-columns:1fr}.empty-chat{padding:20px}.empty-chat h2{font-size:16px}.empty-chat p{font-size:11px}.empty-chat .small{display:none}.empty-symbol{width:55px;height:55px;font-size:30px;border-radius:16px}.event-row{padding:12px;grid-template-columns:1fr}.event-time{grid-column:1}.login-card{padding:28px}.nav-count{display:none}}

.demo-notice{margin:0;padding:12px 24px;background:#fff4dc;color:#745117;border-bottom:1px solid #efd79d;font-size:13px;line-height:1.5}
/* Each column owns its scroll; composing never leaves the visible viewport. */
html,body{height:100%;overflow:hidden}.app{height:100dvh;min-height:0}.main,.inbox-view,.chat-panel,.conversation-panel{min-height:0;overflow:hidden}.main{height:100%;min-width:0}.view{min-height:0}.page-view{overflow:auto}.chat-panel{height:100%;position:relative}.chat-header,.composer,.chat-tabs,.filter-label,.list-header,.search{flex-shrink:0}.messages{min-height:0;flex:1 1 0;overscroll-behavior:contain;overflow:auto;overflow-wrap:anywhere}.composer{position:relative;bottom:0;background:#fff;padding-bottom:max(15px,env(safe-area-inset-bottom))}.composer textarea{max-height:150px;min-height:60px}.composer-bottom{gap:10px}.composer-bottom>.small{flex:1}.chat-contact{min-width:0}.chat-contact h2{overflow-wrap:anywhere}.chat-owner{margin-left:auto;display:flex;align-items:center;gap:9px;flex-shrink:0}.owner-controls{display:flex;flex-direction:column;gap:6px;align-items:flex-end}.owner-actions{display:flex;gap:7px;align-items:center}.owner-actions button{font-size:11px;padding:9px 11px}.assignee-label{margin:0;display:block!important}.assignee-label select{width:145px;margin:0;padding:7px;font-size:11px}.chat-header{gap:10px;flex-wrap:wrap}.chat-tabs{display:flex;border-bottom:1px solid var(--line);padding:0 16px}.chat-tabs button{background:none;border-radius:0;padding:12px 5px;flex:1;color:var(--muted);font-size:12px;border-bottom:2px solid transparent}.chat-tabs button[aria-selected=true]{color:var(--green);border-bottom-color:var(--green)}.filter-label{margin:10px 20px}.filter-label select{font-size:12px;margin:0;padding:8px}.conversation-preview{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.conversation-right{display:flex;gap:7px;align-items:center;flex-shrink:0}.avatar{overflow:hidden;border-radius:50%;color:white;background:#497d66;object-fit:cover;display:inline-flex;align-items:center;justify-content:center;flex-shrink:0;vertical-align:middle}.avatar img{width:100%;height:100%;object-fit:cover}.avatar.small-avatar{width:23px;height:23px;font-size:11px}.avatar.large-avatar{width:60px;height:60px;font-size:24px}.profile .icon-button{padding:3px;margin-left:auto;font-size:17px}.profile #logout{margin-left:0}.system-message{align-self:center;text-align:center;font-size:11px;color:#829086;padding:10px 12px;max-width:90%;white-space:pre-line;line-height:1.6}.user-row{flex-wrap:wrap}.user-identity{display:flex;align-items:center;gap:10px;min-width:0;flex:1}.user-identity span{overflow-wrap:anywhere}.user-actions{display:flex;gap:7px}.user-actions button{font-size:11px;padding:8px}.own-profile{display:flex;align-items:center;gap:12px;margin-bottom:16px}.reaction-bar{display:flex;gap:5px;flex-wrap:wrap;margin-top:5px}.reaction-chip{background:#edf3ed;border:1px solid #dce7dc;border-radius:14px;padding:3px 7px;font-size:13px}.reaction-chip.mine{border-color:var(--green);background:#dcefe0}.react-button{background:none;padding:2px 5px;color:var(--muted);font-size:15px}.reaction-picker{display:flex;gap:4px;flex-wrap:wrap;margin-top:5px}.reaction-picker button{background:#f2f6f0;padding:5px;font-size:17px}.reaction-picker button:disabled{cursor:default}.emoji-options{display:flex;gap:8px;margin:10px 0}.emoji-options select:first-child{flex:1}.emoji-options select:last-child{width:68px}.emoji-grid{display:grid;grid-template-columns:repeat(8,1fr);gap:3px;max-height:310px;overflow:auto;overscroll-behavior:contain;min-height:100px}.emoji-grid button{font-family:"Apple Color Emoji","Segoe UI Emoji","Noto Color Emoji",sans-serif;font-size:25px;padding:5px 2px;min-height:38px;background:none}.emoji-grid button:hover{background:#edf4e9}.settings-grid{align-items:start}.profile strong{max-width:100px;overflow:hidden;text-overflow:ellipsis}#back-chats{display:none}.demo-notice{flex-shrink:0}.message{flex-shrink:0}.message-footer{flex-wrap:wrap}.message-error{overflow-wrap:anywhere}
@media(max-width:1050px){.owner-actions{flex-wrap:wrap;justify-content:flex-end}.chat-header{padding:12px 16px}.chat-owner .avatar{width:25px;height:25px}.owner-actions button{font-size:10px;padding:7px}.assignee-label select{width:120px}.chat-owner{gap:5px}}
@media(max-width:750px){.app{display:grid;grid-template-columns:1fr;grid-template-rows:auto minmax(0,1fr);height:100dvh;min-height:0}.main{height:100%;min-height:0}.inbox-view{height:auto}.conversation-panel{width:100%;border-right:0}.inbox-view:not(.has-selection) .chat-panel,.inbox-view:not(.has-selection) .empty-chat{display:none}.inbox-view.has-selection .conversation-panel{display:none}.chat-header{min-height:95px}.chat-owner{margin-left:auto}.owner-controls{max-width:240px}.owner-actions{flex-wrap:wrap}.chat-contact{flex:1}.messages{min-height:0}#back-chats{display:block}.composer-bottom>.small{display:none}.avatar.small-avatar{width:22px;height:22px}.conversation-time{display:inline}.conversation-name{font-size:13px}.conversation-preview{font-size:12px}.emoji-grid{grid-template-columns:repeat(7,1fr)}.page-view{padding-bottom:30px}.topbar{height:75px}}

.reaction-chip:disabled{opacity:.8;cursor:default}.composer-emoji-control{display:inline-flex;flex-shrink:0}
/* direct brand and compact navigation */
:root{--green:#cf1738;--text:#252931;--muted:#7d8590;--line:#e5e8ed;--bg:#f7f8fa;--soft:#f2f3f6}.primary{background:#292e37}.primary:hover{background:#151a22}.secondary{background:#f0f2f5;color:#434b56}.secondary:hover{background:#e7eaf0}.sidebar .brand{margin:0;width:204px;height:68px;display:flex;align-items:center}.brand-full{display:block;width:190px;height:68px;object-fit:contain}.brand-symbol{display:none;width:42px;height:42px}.login-card .brand{display:flex;justify-content:center}.login-card .brand-full{width:230px;height:86px}.app{grid-template-columns:72px minmax(0,1fr)}.app.nav-pinned{grid-template-columns:232px minmax(0,1fr)}.sidebar{position:relative;z-index:20;width:72px;padding:18px 10px;overflow:hidden;background:#fff;transition:width .18s ease,box-shadow .18s ease;border-right:1px solid var(--line);display:flex;flex-direction:column}.sidebar.expanded{width:232px;box-shadow:14px 0 35px #20252e12}.sidebar:not(.expanded) .brand-symbol{display:block}.sidebar:not(.expanded) .brand-full{display:none}.sidebar:not(.expanded) .brand{width:50px;justify-content:center}.sidebar .workspace-label{white-space:nowrap;margin:15px 8px 10px}.sidebar:not(.expanded) .workspace-label{visibility:hidden;height:0;margin:8px 0}.sidebar nav{width:210px;display:flex;flex-direction:column;gap:7px}.nav-item{white-space:nowrap;position:relative;min-height:44px;font-size:13px;padding:11px 13px;justify-content:flex-start;gap:14px}.nav-label{transition:opacity .12s;overflow:hidden}.sidebar:not(.expanded) .nav-item{width:50px;gap:0;justify-content:center;padding:10px}.sidebar:not(.expanded) .nav-label{position:absolute;opacity:0;width:0}.nav-item.active{color:#c91839;background:#fff0f3}.nav-count{background:#d5183b;color:#fff}.sidebar:not(.expanded) .nav-count{position:absolute;top:1px;right:0;min-width:16px;font-size:9px;padding:1px 4px}.sidebar-note{width:200px;margin-top:auto;color:#8b919a}.sidebar:not(.expanded) .sidebar-note{display:none}.profile{width:210px;gap:8px}.sidebar:not(.expanded) .profile{width:50px;margin-top:auto;padding:12px 0;justify-content:center}.sidebar:not(.expanded) .profile>div,.sidebar:not(.expanded) #my-profile,.sidebar:not(.expanded) #logout{display:none}#profile-avatar{cursor:pointer;flex-shrink:0}.profile-avatar-wrapper .avatar{width:34px;height:34px}.profile strong{max-width:90px}.sidebar-shade{position:fixed;inset:0;background:#1b233144;z-index:19;border-radius:0}.outbound .bubble{background:#f0f2f7;border-color:#e3e6ee}.reaction-chip.mine{background:#fff0f3;border-color:#e77e93}.status.connected{color:#2f835d}.pill{background:#f0f4f2}.conversation-item.selected{background:#f1f3f8;border-left-color:#d81c3d}.template-toolbar,.template-heading,.template-actions{display:flex;align-items:center;gap:10px}.template-toolbar{margin-bottom:24px;justify-content:space-between}.template-toolbar input{max-width:450px;margin:0}.template-heading{justify-content:space-between}.template-heading h3{font-size:15px;margin:0}.template-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(280px,1fr));gap:18px}.template-card{border:1px solid var(--line);border-radius:15px;padding:20px;background:white;min-width:0}.template-body-preview{font-family:inherit;font-size:12px;line-height:1.7;white-space:pre-wrap;overflow:hidden;max-height:180px;color:#626d7c}.template-actions{flex-wrap:wrap;margin-top:16px}.template-actions button{font-size:11px;padding:8px 12px}.variable-list{display:flex;gap:5px;flex-wrap:wrap;margin:12px 0}.variable-chip{font-size:11px;padding:6px 8px}.inline-label{display:flex;align-items:center;gap:8px}.inline-label input{width:auto;margin:0}#template-editor,#template-picker{width:640px;max-height:90dvh;overflow:auto}#template-body,#template-preview-text{min-height:180px}.template-picker-list{display:flex;flex-wrap:wrap;gap:8px;max-height:180px;overflow:auto}.template-choice{font-size:12px;background:#f0f2f7;color:#363f4f;padding:10px;border-radius:8px}.template-choice:hover{background:#fff0f3;color:#c31839}#sidebar-toggle{align-self:flex-start;width:46px;margin-bottom:4px}#composer-template{color:#687184}
@media(max-width:1050px){.app{grid-template-columns:64px minmax(0,1fr)}.sidebar{width:64px;padding:14px 6px}.sidebar.expanded{width:232px}.sidebar .brand{font-size:initial;padding:0}}@media(max-width:750px){.app,.app.nav-pinned{grid-template-columns:56px minmax(0,1fr);grid-template-rows:minmax(0,1fr)}.sidebar{width:56px;height:100dvh;padding:10px 3px;border-bottom:0;display:flex}.sidebar.expanded{position:fixed;inset:0 auto 0 0;width:232px;padding:15px 10px}.sidebar>.brand{display:flex}.sidebar nav{display:flex;flex-direction:column;width:210px}.sidebar .nav-item{font-size:13px}.sidebar .nav-item>span:first-child{width:20px}.sidebar .profile{display:flex}.sidebar.expanded .sidebar-note{display:block}.sidebar:not(.expanded) .sidebar-note{display:none}.main{min-width:0}.topbar{height:75px;padding:14px}.topbar h1{font-size:22px}.topbar .eyebrow{font-size:7px}.chat-owner .owner-actions{max-width:230px}.chat-contact{min-width:80px}.conversation-panel{min-width:0}.template-toolbar{align-items:stretch;flex-direction:column}.template-grid{grid-template-columns:minmax(0,1fr)}.page-view{padding:18px 12px}.sidebar .brand-symbol{width:40px;height:40px}.sidebar .brand{height:52px}.sidebar:not(.expanded) #sidebar-toggle{width:46px}.composer-bottom{gap:7px}}
@media(prefers-reduced-motion:reduce){.sidebar,.nav-label{transition:none}}

.customer-avatar{width:36px;height:36px;font-size:15px}.conversation-identity{display:flex;align-items:center;gap:10px;min-width:0;flex:1}.conversation-identity .conversation-name{overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.conversation-preview,.conversation-meta{margin-left:46px}.chat-contact{display:flex;align-items:center;gap:10px}.chat-contact>div{min-width:0}.chat-contact .customer-avatar{width:40px;height:40px}.conversation-row{gap:6px}.conversation-right{gap:5px}.conversation-time{font-size:10px}.conversation-panel{width:320px}@media(max-width:1050px){.conversation-panel{width:270px}}@media(max-width:750px){.conversation-panel{width:100%}.customer-avatar{width:32px;height:32px}.chat-contact .customer-avatar{width:32px;height:32px}.conversation-preview,.conversation-meta{margin-left:42px}}
/* CRM keeps a separate scroll surface; the conversation composer stays visible. */
.inbox-view{position:relative}.crm-panel{width:340px;flex:0 0 340px;min-height:0;display:flex;flex-direction:column;background:#fff;border-left:1px solid var(--line)}.crm-heading{display:flex;align-items:center;justify-content:space-between;padding:16px;border-bottom:1px solid var(--line);flex-shrink:0}.crm-content{padding:18px;overflow:auto;min-height:0;flex:1;overscroll-behavior:contain;display:flex;flex-direction:column;gap:13px}.crm-content h3{font-size:17px;margin:0}.crm-content h4{font-size:13px;margin:12px 0 0}.crm-content input,.crm-content select,.crm-content textarea{margin:0;font-size:12px}.crm-content label{margin:0}.crm-content button{font-size:12px}.crm-field{display:flex;flex-direction:column;gap:3px;font-size:12px;overflow-wrap:anywhere}.crm-link{font-size:17px;font-weight:700;color:#b51e39;overflow-wrap:anywhere}.crm-stage{padding:7px 10px;align-self:flex-start;border-radius:7px;border-left:4px solid var(--stage-color);background:#f3f4f6;color:#343d49;font-size:12px}.crm-item{display:flex;flex-direction:column;gap:5px;border-bottom:1px solid var(--line);padding-bottom:10px;font-size:12px;overflow-wrap:anywhere}.crm-notice{font-size:11px;line-height:1.6;padding:10px;border:1px solid #ebe5d5;background:#fffaf0;color:#786443;border-radius:8px;margin:0}.crm-notice button{margin-top:8px}.crm-create{border-top:1px solid var(--line);padding-top:12px}.crm-create summary{cursor:pointer;margin-bottom:10px;font-size:12px}.crm-create input{margin-bottom:10px}.crm-bind-results{display:flex;flex-direction:column;gap:7px}.crm-group-row{display:flex;flex-direction:column;gap:7px;margin:12px 0}.crm-search-results{overflow:auto;max-height:35%;flex-shrink:0}.crm-search-hit{display:block;text-align:left;border-bottom:1px solid var(--line);border-radius:0;background:#fff7f8;font-size:11px;width:100%;padding:12px 17px;overflow-wrap:anywhere}.crm-search-results>p{padding:10px 16px}#crm-action-status{margin:10px;flex-shrink:0}#crm-toggle{font-size:11px;padding:9px;white-space:nowrap}.inbox-view:has(.crm-panel:not(.hidden)) .chat-header{padding:15px}.inbox-view:has(.crm-panel:not(.hidden)) .conversation-panel{width:280px}
@media(min-width:1200px) and (max-width:1440px){.crm-panel{width:300px;flex-basis:300px}.inbox-view:has(.crm-panel:not(.hidden)) .conversation-panel{width:240px}.crm-content{padding:15px}.inbox-view:has(.crm-panel:not(.hidden)) .chat-owner{width:100%;justify-content:flex-end}}
@media(max-width:1199px){.crm-panel{position:absolute;right:0;top:0;bottom:0;width:min(390px,100%);z-index:15;box-shadow:-14px 0 35px #2223}.crm-heading{min-height:65px}.inbox-view:has(.crm-panel:not(.hidden)) .conversation-panel{width:270px}}
@media(max-width:750px){.inbox-view:has(.crm-panel:not(.hidden)) .conversation-panel{width:100%}#crm-toggle{font-size:10px}.crm-content{padding:16px}.crm-panel{width:100%}}
.message-media{display:flex;flex-direction:column;gap:7px;max-width:100%;overflow:hidden;background:#f2f3f7;border:1px solid var(--line);padding:8px;border-radius:12px}.message-media img{display:block;max-width:100%;max-height:420px;object-fit:contain;border-radius:7px}.message-media video{max-width:100%;max-height:400px;display:block;border-radius:7px}.message-media audio{width:min(300px,100%);max-width:100%}.media-download{font-size:11px;overflow-wrap:anywhere;color:#596577;padding:4px}.message-media button{font-size:11px}.attachment-drafts{max-height:145px;overflow:auto;display:flex;flex-direction:column;gap:8px;margin-bottom:7px;flex-shrink:0}.attachment-draft{display:flex;flex-wrap:wrap;align-items:center;gap:7px;background:#f3f4f7;border-radius:8px;padding:8px;font-size:11px}.attachment-draft>span:first-child{flex:1;min-width:110px;overflow-wrap:anywhere}.attachment-draft progress{max-width:90px;height:6px;accent-color:#ba2341}.attachment-draft button{font-size:10px;padding:5px}.attachment-draft audio{height:34px;width:min(250px,100%)}.attachment-mode{display:flex;align-items:center;gap:3px;font-size:10px;margin:0;color:#747e8c;white-space:nowrap}.attachment-mode input{width:auto;margin:0}.file-drag:after{content:'Отпустите файлы, чтобы прикрепить';position:absolute;inset:6px;display:grid;place-items:center;background:#fff6f8e8;border:2px dashed #cd2347;border-radius:14px;color:#af1835;pointer-events:none;z-index:12}.composer-bottom{flex-wrap:wrap}.message:has(.message-media){min-width:170px}.message-media+.bubble{margin-top:5px}.composer{flex-shrink:0}@media(max-width:750px){.composer-bottom{gap:4px}.composer-bottom>.icon-button{padding:6px}.attachment-mode{font-size:9px}.composer #send-button{font-size:11px;padding:9px}.message-media img{max-height:300px}.message-media video{max-height:280px}}

#attachment-format{font-size:10px;max-width:115px;padding:5px;border:1px solid var(--line);border-radius:7px;background:#fff;color:var(--text)}

/* 0.9: compact, independently scrollable conversation workspace. */
.ui-icon{display:inline-flex;width:21px;height:21px;align-items:center;justify-content:center;flex:0 0 auto}.ui-icon svg{width:100%;height:100%}.icon-button:has(.ui-icon){display:inline-flex;align-items:center;justify-content:center;width:38px;height:38px;padding:8px;flex-shrink:0}
.inbox-view{display:grid;grid-template-columns:var(--list-width,320px) 6px minmax(0,1fr);grid-template-rows:84px minmax(0,1fr);flex:1;min-height:0;overflow:hidden}.inbox-view:not(.has-selection){grid-template-rows:minmax(0,1fr)}
.inbox-view .conversation-panel,.inbox-view:has(.crm-panel:not(.hidden)) .conversation-panel{width:auto;min-width:0;grid-column:1;grid-row:1/-1;border-right:0}.inbox-view .empty-chat{grid-column:3;grid-row:1/-1;min-width:0}.inbox-view:not(.has-selection) .chat-header{display:none}
.inbox-view .chat-header,.inbox-view:has(.crm-panel:not(.hidden)) .chat-header{grid-column:3/-1;grid-row:1;height:84px;min-height:84px;max-height:84px;padding:12px 18px;flex-wrap:nowrap;justify-content:flex-start;min-width:0;overflow:hidden;background:#fff}
.chat-contact{flex:1;min-width:0}.chat-contact h2,.chat-contact p{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.chat-contact .avatar{flex-shrink:0}.chat-header-actions{display:flex;align-items:center;gap:8px;flex-shrink:0;margin-left:auto}.chat-header-actions .avatar{width:30px;height:30px;font-size:13px}.chat-action{display:inline-flex;align-items:center;justify-content:center;gap:7px;border:1px solid transparent;border-radius:10px;padding:10px 12px;font-size:12px;white-space:nowrap;min-height:39px;font-weight:650}.take-action{background:#eaf6ee;color:#286746;border-color:#d9eddf}.finish-action{background:#f2f6f2;color:#45674e;border-color:#e0e9e0}.crm-action{background:#eef2fa;color:#415f8b;border-color:#e1e7f4}#crm-toggle{font-size:12px;padding:10px 12px}.crm-action[aria-expanded=true]{background:#e1e9f9;color:#2d508a}.chat-action:hover{filter:brightness(.97)}.chat-action .ui-icon{width:17px;height:17px}
.inbox-view .chat-panel{grid-column:3;grid-row:2;min-width:0;height:auto;min-height:0;overflow:hidden}.column-resizer{position:relative;z-index:10;cursor:col-resize;touch-action:none;background:#f4f5f7;border-inline:1px solid #edf0f3;outline-offset:-2px}.column-resizer::after{content:'';position:absolute;top:50%;left:1px;right:1px;height:42px;border-radius:4px;background:#d8dde5;transition:background .15s}.column-resizer:hover::after,.column-resizer:focus-visible::after{background:#cf4964}#list-resizer{grid-column:2;grid-row:1/-1}#crm-resizer{display:none;grid-column:4;grid-row:2}.resizing,.resizing *{cursor:col-resize!important;user-select:none!important}
.inbox-view .crm-panel{position:absolute;right:0;top:84px;bottom:0;width:min(var(--crm-width,360px),100%);min-width:0;z-index:20;box-shadow:-10px 0 28px #2433481a}.inbox-view.crm-docked{grid-template-columns:var(--list-width,320px) 6px minmax(0,1fr) 6px var(--crm-width,360px)}.inbox-view.crm-docked .crm-panel{position:relative;top:auto;bottom:auto;right:auto;width:auto;grid-column:5;grid-row:2;box-shadow:none}.crm-docked #crm-resizer{display:block}.crm-heading{padding:12px 16px;min-height:54px;height:54px}.crm-content{padding:16px;gap:12px}#crm-action-status{position:absolute;top:60px;left:12px;right:12px;margin:0;z-index:25;box-shadow:0 6px 20px #26314415}.crm-panel{isolation:isolate}
.list-header{gap:10px;padding:18px 18px 12px}.list-header h2{font-size:14px}.list-heading-title{display:flex;align-items:center;gap:8px;min-width:0}.list-heading-title h2{min-width:0}.list-heading-title #conversation-count{flex-shrink:0}.list-heading-actions{display:flex;align-items:center;gap:9px}.new-chat-button{width:37px;height:37px;border-radius:50%;display:inline-flex;align-items:center;justify-content:center;background:#cf2149;color:#fff;border:0;box-shadow:0 3px 8px #cf21491a;flex-shrink:0}.new-chat-button:hover{background:#b9193e}.new-chat-button .ui-icon{width:24px;height:24px}
.composer{padding:12px 17px max(12px,env(safe-area-inset-bottom));min-width:0}.composer textarea{padding:4px 0 8px;min-height:52px;max-height:160px;line-height:1.55}.composer-bottom{display:flex;justify-content:space-between;gap:10px;flex-wrap:nowrap}.composer-tools{margin-left:auto;display:flex;align-items:center;gap:5px;min-width:0}.composer-tools .icon-button{color:#6b7484}.composer #send-button{font-size:12px;padding:10px 15px;white-space:nowrap}.attachment-control{position:relative;flex-shrink:0}.attachment-menu{position:absolute;left:0;bottom:calc(100% + 8px);width:228px;background:#fff;border:1px solid #e1e5eb;border-radius:13px;padding:6px;box-shadow:0 9px 35px #1f293727;z-index:30}.attachment-menu button{display:flex;align-items:center;gap:10px;width:100%;padding:12px 10px;text-align:left;background:#fff;border:0;border-radius:8px;font-size:12px;color:#374151}.attachment-menu button:hover,.attachment-menu button:focus-visible{background:#f3f5f8}
.channel-fieldset{border:0;padding:0;margin:0 0 18px;min-width:0}.channel-fieldset legend{font-size:12px;font-weight:650;margin-bottom:10px}.channel-choices{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:9px}.channel-choices label{position:relative;margin:0;min-width:0;cursor:pointer}.channel-choices input{position:absolute;inset:0;width:100%;height:100%;opacity:0;margin:0;cursor:pointer}.channel-tile{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:8px;min-height:104px;padding:12px 6px;border:2px solid #e7e9ee;border-radius:13px;background:#fff;color:#5a6473;font-size:12px;font-weight:600;pointer-events:none}.channel-brand{width:37px;height:37px;border-radius:12px;display:flex;align-items:center;justify-content:center;color:#fff}.channel-brand svg{width:27px;height:27px;stroke-width:1.45}.channel-choices input:checked+.channel-tile{border-color:#cf2149;background:#fff4f6;color:#8b1832;box-shadow:0 0 0 2px #cf21490b}.channel-choices input:checked+.channel-tile::after{content:'✓';position:absolute;top:7px;right:9px;color:#b4193d;font-weight:800}.channel-choices input:focus-visible+.channel-tile{outline:2px solid #3e65a0;outline-offset:3px}.channel-choices input:disabled+.channel-tile{opacity:.4}.channel-tile small{font-size:9px;font-weight:400}.template-in-new{width:100%;margin:0 0 7px}
.note-label{font-size:12px;font-weight:650;margin-top:8px!important}.note-editor{border:1px solid #dfe3ea;border-radius:11px;overflow:hidden;background:#fff}.note-body{min-height:155px;max-height:340px;overflow:auto;padding:12px;font-size:14px;line-height:1.65;outline:none;overflow-wrap:anywhere;white-space:pre-wrap}.note-body:focus{box-shadow:inset 0 0 0 2px #ebd4dc}.note-body[aria-disabled=true]{background:#f7f8fa;color:#8a93a2}.note-body[data-empty=true]::before{content:attr(data-placeholder);color:#9da5b1;pointer-events:none}.note-body p,.note-body div{margin:0 0 5px}.note-body p:last-child{margin-bottom:0}.note-body font[size='2']{font-size:12px}.note-body font[size='3']{font-size:14px}.note-body font[size='4']{font-size:18px}.note-body font[size='5']{font-size:22px}.note-toolbar{display:flex;align-items:center;flex-wrap:wrap;gap:3px;padding:6px;border-top:1px solid #e6e9ee;background:#fafbfc}.crm-content .note-toolbar select{width:95px;font-size:11px;padding:5px;align-self:stretch;min-width:0}.crm-content .note-format-button{display:inline-flex;align-items:center;justify-content:center;min-width:27px;height:29px;padding:4px;border:0;border-radius:5px;background:transparent;color:#566174;font-size:13px}.note-format-button:hover{background:#e9edf3}.note-format-button .ui-icon{width:18px;height:18px}.note-counter{display:block;padding:3px 9px 5px;text-align:right;font-size:9px;color:#a0a8b4}
.settings-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:22px;max-width:none;width:100%;align-items:start}.settings-column{display:flex;flex-direction:column;gap:22px;min-width:0}.settings-column>div:empty{display:none}.settings-column>.settings-card,.settings-column>div>.settings-card{margin-top:0;margin-bottom:0}.settings-column:not(:has(.settings-card:not(.hidden))){display:none}.settings-grid:not(:has(.settings-column:nth-child(2) .settings-card:not(.hidden))){grid-template-columns:minmax(0,1fr)}.settings-card{min-width:0;width:100%;padding:24px}.settings-card form{margin-top:17px}
@media(max-width:1050px){.settings-grid{grid-template-columns:minmax(0,1fr)}.settings-column{gap:18px}.inbox-view .chat-header,.inbox-view:has(.crm-panel:not(.hidden)) .chat-header{padding:10px 12px}.chat-header-actions{gap:5px}.chat-action,#crm-toggle{padding:8px;font-size:11px}}
@media(max-width:750px){.inbox-view,.inbox-view.crm-docked{grid-template-columns:minmax(0,1fr);grid-template-rows:76px minmax(0,1fr)}.inbox-view:not(.has-selection){grid-template-rows:minmax(0,1fr)}.inbox-view .conversation-panel,.inbox-view:has(.crm-panel:not(.hidden)) .conversation-panel{grid-column:1;grid-row:1/-1;width:auto}.inbox-view .chat-panel,.inbox-view .empty-chat{grid-column:1}.inbox-view .chat-header,.inbox-view:has(.crm-panel:not(.hidden)) .chat-header{grid-column:1;grid-row:1;height:76px;min-height:76px;max-height:76px;gap:6px;padding:8px}.inbox-view .crm-panel{top:76px;width:100%}#list-resizer,#crm-resizer{display:none!important}.chat-header-actions .avatar{display:none}.chat-contact h2{font-size:13px}.chat-contact p{font-size:10px}.chat-header-actions{gap:4px}.chat-action .action-label{display:none}.chat-action .ui-icon{width:19px;height:19px}.chat-action,#crm-toggle{width:35px;height:35px;padding:7px;min-height:35px}.composer{padding:9px 10px max(10px,env(safe-area-inset-bottom))}.composer textarea{min-height:48px}.composer-tools{gap:1px}.composer-tools .icon-button,.composer-bottom .attachment-control>.icon-button{width:33px;height:33px;padding:6px}.composer #send-button{padding:9px 10px;font-size:11px}.settings-card{padding:19px}.settings-grid{gap:18px}.channel-tile{font-size:11px;min-height:96px}.channel-brand{width:33px;height:33px}.crm-heading{height:50px;min-height:50px}.crm-content{padding:14px}.note-body{min-height:170px}}
.sidebar .profile{margin-top:auto}
/* Card content scrolls as a whole; fields and the note toolbar must not shrink. */
.crm-content>*{flex-shrink:0}.note-editor{flex-shrink:0}

/* Match the native CRM paragraph/heading choices instead of inline pixel sizes. */
.note-body h2{font-size:22px;line-height:1.35;margin:0 0 8px}.note-body h3{font-size:19px;line-height:1.4;margin:0 0 7px}.note-body h4{font-size:16px;line-height:1.45;margin:0 0 6px}

/* Vue3 workspace: compact floating panels, unchanged resize handles and widths. */
body{background:#eef0f4}.app{padding:8px;gap:8px;min-height:0}.sidebar{border:1px solid var(--line);border-radius:20px;height:100%;box-shadow:0 2px 8px #28324405}.sidebar.expanded{border-radius:20px}.main{background:transparent;min-width:0}.inbox-view{background:transparent;row-gap:8px}.conversation-panel{border:1px solid var(--line);border-radius:18px;background:#fff;overflow:hidden}.inbox-view .chat-header,.inbox-view:has(.crm-panel:not(.hidden)) .chat-header{border:1px solid var(--line);border-radius:18px}.inbox-view .chat-panel{background:#fcfcfd;border:1px solid var(--line);border-radius:18px;overflow:hidden}.inbox-view .crm-panel{border:1px solid var(--line);border-radius:18px;overflow:hidden}.empty-chat{background:#ffffff99;border:1px solid #e5e8ee;border-radius:18px}.conversation-item{border-left-width:3px}.conversation-item.selected{border-radius:13px}.conversation-list{padding:4px}.column-resizer{border-radius:8px}.column-resizer:hover,.column-resizer:focus-visible{background:#cad3e3}.bubble{border-radius:17px}.composer{background:#fff}.composer textarea{border-radius:12px}.media-host{max-width:100%;min-width:0}.ai-button{color:#8d47a4!important}.assistant-admin-tabs,.assistant-modes{display:flex;gap:8px;flex-wrap:wrap;margin-bottom:18px}.assistant-admin-tabs .selected,.assistant-modes .selected{background:#eee5f5;color:#753b8a}.assistant-settings-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:22px;align-items:start}.assistant-settings-grid .settings-card{border:1px solid var(--line);border-radius:18px;background:#fff}.assistant-settings-grid textarea{line-height:1.55;resize:vertical}.assistant-settings-grid .inline-label input{width:auto}.ai-status-list{display:grid;grid-template-columns:auto 1fr;gap:10px;font-size:12px;margin:20px 0}.ai-status-list dt{color:var(--muted)}.ai-status-list dd{margin:0;text-align:right}.ai-product-results{display:grid;gap:5px;max-height:280px;overflow:auto;margin:12px 0}.ai-product-results button{background:#f5f6f9;text-align:left;padding:12px;display:flex;flex-direction:column;gap:6px;color:#3e4857}.ai-rule-target,.ai-rule-summary{border:1px solid var(--line);border-radius:12px;padding:14px;margin:12px 0}.ai-rule-summary>small,.ai-rule-target>small{display:block;margin:6px 0}.ai-rule-summary p{font-size:12px}.ai-preview{padding:12px;background:#f8f5fb;border-radius:10px;margin-top:12px}.ai-preview p{white-space:pre-wrap;font-size:13px;margin:10px 0 0}.assistant-panel .dialog-heading{align-items:start}.assistant-panel .dialog-heading p{margin-bottom:0}.assistant-panel .ai-variant{border:1px solid #e4deeb;border-radius:15px;padding:17px;margin-top:18px}.ai-variant-title{display:flex;justify-content:space-between;gap:10px}.ai-variant>textarea{min-height:120px;line-height:1.6}.ai-variant .template-actions button{font-size:12px}#assistant-dialog{width:780px;max-width:calc(100vw - 24px);max-height:90dvh;overflow:auto}.ai-template-form{margin-top:20px;border-top:1px solid var(--line);padding-top:8px}.assistant-diagnostics{display:grid;gap:20px}.assistant-diagnostics .settings-card{background:#fff;border:1px solid var(--line);border-radius:18px}.diagnostic-table{overflow:auto;max-height:420px}.diagnostic-table table{width:100%;border-collapse:collapse;font-size:11px;text-align:left}.diagnostic-table td,.diagnostic-table th{border-bottom:1px solid var(--line);padding:9px;overflow-wrap:anywhere}.diagnostic-table td:last-child{max-width:180px}.ai-trace{font-size:11px;white-space:pre-wrap;max-height:500px;overflow:auto;background:#f6f7f9;padding:15px;border-radius:10px}.topbar{background:#fff;border:1px solid var(--line);border-radius:18px}.page-view{border-radius:18px}
@media(max-width:1050px){.assistant-settings-grid{grid-template-columns:minmax(0,1fr)}}
@media(max-width:750px){.app{padding:4px;gap:4px}.sidebar{height:100%;border-radius:15px}.sidebar.expanded{inset:4px auto 4px 4px;height:auto;border-radius:15px}.inbox-view{row-gap:5px}.conversation-panel,.inbox-view .chat-panel,.inbox-view .crm-panel,.inbox-view .chat-header,.inbox-view:has(.crm-panel:not(.hidden)) .chat-header{border-radius:14px}.assistant-settings-grid{gap:16px}.assistant-admin-tabs{gap:5px}.assistant-admin-tabs button{font-size:11px;padding:9px}.ai-variant-title{flex-direction:column;gap:5px}.composer-tools .ai-button{width:29px;padding:4px}.composer #send-button{padding:9px 7px;font-size:10px}.assistant-panel .ai-variant{padding:12px}.assistant-panel .template-actions{align-items:stretch;flex-direction:column}}

/* Prevent focus/scrollIntoView from horizontally scrolling the narrow rail. */
.sidebar{overflow:clip}

/* Detached composer, preserved DOM and bounded growth. */
.composer{display:grid;grid-template-columns:44px minmax(0,1fr) 44px;gap:9px;align-items:end;container-type:inline-size;background:transparent;border:0;padding:10px 14px max(12px,env(safe-area-inset-bottom))}.composer>.attachment-drafts{grid-column:1/-1}.composer>.attachment-control{align-self:end;margin-bottom:2px}.composer-input-shell{display:flex;align-items:flex-end;min-width:0;gap:2px;padding:5px 7px 5px 13px;background:#fff;border:1px solid #e1e5ed;border-radius:24px;box-shadow:0 2px 7px #26334b06}.composer .composer-input-shell textarea{display:block;flex:1;min-width:0;width:100%;min-height:34px;height:34px;max-height:none;padding:6px 0;line-height:22px;font-size:14px;resize:none;border:0;border-radius:0;outline:0;background:transparent;box-shadow:none;margin:0}.composer-input-shell:focus-within{border-color:#bbc6d8;box-shadow:0 0 0 2px #b5c4dc20}.composer .composer-tools{margin:0;gap:1px;flex-shrink:0;padding:0;align-items:center;height:34px}.composer .composer-tools .icon-button{width:32px;height:32px;padding:7px;border-radius:50%;font-size:19px}.composer .composer-circle{width:44px;height:44px;min-height:44px;padding:11px;border-radius:50%;display:flex;align-items:center;justify-content:center;border:1px solid #e1e5ed;background:#fff;color:#6e798a;flex-shrink:0}.composer #send-button{width:44px;height:44px;padding:11px;border-radius:50%;background:#292e37;color:#fff;font-size:14px}.composer #send-button[aria-busy=true]{opacity:.65}.composer #send-button .ui-icon{width:22px;height:22px}.composer-submit{align-self:end;margin-bottom:2px}.integration-settings{margin-top:22px;border:1px solid var(--line);background:#fff;border-radius:18px}.integration-settings form{display:flex;flex-direction:column;gap:12px}.integration-settings summary{font-size:12px;cursor:pointer;color:#6e798a}.integration-settings details label{margin-top:12px}#nova-settings .integration-settings{margin-top:0}
@container (max-width:480px){.composer-input-shell{flex-wrap:wrap;padding:5px 10px}.composer .composer-input-shell textarea{flex-basis:100%}.composer .composer-tools{margin-left:auto;height:29px}.composer .composer-tools .icon-button{width:29px;height:29px;padding:5px}}
@media(max-width:750px){.composer{grid-template-columns:36px minmax(0,1fr) 36px;gap:6px;padding:8px 7px max(8px,env(safe-area-inset-bottom))}.composer .composer-circle,.composer #send-button{width:36px;height:36px;min-height:36px;padding:8px}.composer-input-shell{border-radius:20px}.composer .composer-input-shell textarea{font-size:16px}.integration-settings{margin-top:16px}}

.crm-tabs{display:flex;gap:4px;padding:7px 12px;border-bottom:1px solid var(--line);flex-shrink:0}.crm-tabs button{flex:1;background:transparent;color:#77818f;border-radius:9px;padding:10px 5px;font-size:12px}.crm-tabs button[aria-selected=true]{background:#edf1f8;color:#345682}.order-panel{font-size:12px}.order-panel fieldset{border:0;margin:0;padding:0;min-width:0}.order-panel label{display:flex;flex-direction:column;gap:6px;margin:12px 0;font-weight:600}.order-panel input,.order-panel select,.order-panel textarea{width:100%;min-width:0;border:1px solid #dce2e9;border-radius:9px;padding:10px;background:#fff;color:#303a47}.order-panel select{font-size:12px}.order-panel .inline-label{flex-direction:row;font-weight:400;align-items:start}.order-panel .inline-label input{width:auto;flex:none}.order-autofill{display:flex;gap:6px;flex-wrap:wrap;margin:12px 0}.order-autofill button{font-size:11px;padding:9px}.order-suggestions{display:flex;flex-direction:column;gap:4px;max-height:190px;overflow:auto}.order-suggestions button{font-weight:400;text-align:left;line-height:1.45;background:#f3f5f8;color:#394454;padding:10px;border-radius:8px}.order-item{border:1px solid var(--line);border-radius:12px;padding:11px;margin-top:10px}.order-item>small{display:block;margin-top:5px}.order-item-values{display:grid;grid-template-columns:1fr 1fr;gap:8px}.order-item-values input{padding:8px}.order-item>button{font-size:11px;margin-top:9px}.order-total{font-size:17px;font-weight:650}.order-panel details{margin:14px 0}.order-panel summary{cursor:pointer;line-height:1.5}.order-panel .crm-notice button{display:block;margin-top:8px}.order-panel fieldset:disabled{opacity:.7}#order-create{width:100%;padding:13px;margin:12px 0}.order-panel .small{line-height:1.5;overflow-wrap:anywhere}#crm-order-root{display:block}#crm-order-root.hidden{display:none}
.meta-connections{border-top:1px solid var(--line,#e4e7ed);margin-top:20px;padding-top:18px}.meta-asset{padding:14px 0;border-bottom:1px solid var(--line,#e4e7ed)}.meta-asset .row{margin-top:10px;gap:20px}.meta-connections details{margin:16px 0}.meta-connections input[readonly]{font-size:12px}.chat-contact p{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}

/* Compact page chrome and a single CRM tab/close row. */
.main>.topbar{position:absolute;width:1px;height:1px;min-height:0;padding:0;margin:-1px;overflow:hidden;clip-path:inset(50%);border:0}.main>.page-view{flex:1;min-height:0;padding:26px 28px;background:#fafbf9}.page-intro{max-width:900px;margin-bottom:22px}.channel-grid{max-width:none;gap:18px}.channel-card{padding:24px}.crm-tabbar{display:flex;align-items:center;gap:4px;padding:6px 8px;border-bottom:1px solid var(--line);min-height:53px;flex-shrink:0}#crm-tabs-root{flex:1;min-width:0}.crm-tabbar .crm-tabs{padding:0;border:0;gap:4px}.crm-tabbar #crm-close{display:flex;align-items:center;justify-content:center;align-self:center;flex:none;width:32px;height:32px;padding:6px;border-radius:50%;line-height:1}.crm-tabbar #crm-close .ui-icon{width:20px;height:20px}.crm-tabbar #crm-close svg{display:block}.crm-tabbar #crm-close:hover{background:#f1f3f7}.order-panel [aria-invalid=true]{border-color:#d54357;background:#fff8f9;box-shadow:0 0 0 1px #d5435726}.order-errors{padding:12px;background:#fff3f5;border:1px solid #efc7ce;border-radius:11px;color:#a82f43;margin:10px 0}.order-errors>strong{display:block;margin-bottom:7px}.order-errors>button{display:block;text-align:left;background:transparent;color:inherit;font-size:12px;font-weight:400;padding:4px 0;text-decoration:underline;line-height:1.4}.settings-card textarea{width:100%;resize:vertical}
/* Profile connection is the primary Meta action; account controls stay independent. */
#meta-settings .integration-settings{padding:24px;margin-top:22px}.meta-connections{border:0;padding:0;margin-top:22px}.meta-toolbar{display:flex;align-items:center;justify-content:space-between;gap:18px;flex-wrap:wrap}.meta-toolbar h3{font-size:17px;margin:0 0 5px}.meta-toolbar p{margin:0}.meta-toolbar-actions{display:flex;flex-wrap:wrap;gap:8px}.meta-toolbar-actions button{font-size:12px;padding:11px 15px}.meta-access-status{display:flex;align-items:center;gap:6px;color:#3a7854;font-size:12px;margin:18px 0}.meta-assets{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,270px),1fr));gap:12px}.meta-asset{border:1px solid var(--line);border-radius:14px;padding:16px;background:#fff;min-width:0}.meta-asset-heading{display:flex;gap:11px;align-items:center;min-height:44px}.meta-asset-heading>div{min-width:0;flex:1}.meta-asset-heading small{font-size:11px}.meta-asset-heading strong{display:block;margin-top:3px;overflow-wrap:anywhere;font-size:13px}.meta-platform-icon{display:flex;justify-content:center;align-items:center;width:39px;height:39px;flex:none;border-radius:12px;font-size:28px;font-weight:700}.meta-platform-icon.instagram{background:#fbecf4;color:#b03f80}.meta-platform-icon.facebook{background:#eaf1ff;color:#3866b0}.meta-enabled-dot{width:7px;height:7px;border-radius:50%;background:#629b72;flex:none}.meta-toggles{display:grid;grid-template-columns:1fr 1fr;gap:12px;margin-top:16px}.meta-switch{display:flex;align-items:center;justify-content:space-between;gap:8px;margin:0!important;font-weight:400;font-size:12px}.meta-switch input{appearance:none;width:32px!important;height:19px;flex:none;border:0;border-radius:15px;background:#d9dee5;padding:2px!important;cursor:pointer;transition:background .15s}.meta-switch input:before{content:'';display:block;width:15px;height:15px;border-radius:50%;background:#fff;box-shadow:0 1px 3px #25354b25;transition:transform .15s}.meta-switch input:checked{background:#629b72}.meta-switch input:checked:before{transform:translateX(13px)}.meta-switch input:focus-visible{outline:2px solid #477ab1;outline-offset:2px}.meta-consent{margin-top:12px;border-top:1px solid var(--line);padding-top:8px}.meta-footer{margin:18px 0 0}.meta-app-settings,.meta-webhook-settings{border-top:1px solid var(--line);padding-top:16px;margin-top:20px}.meta-app-settings summary,.meta-webhook-settings summary{font-weight:600;color:#536074!important}.meta-app-settings form{display:grid;grid-template-columns:1fr 1fr;gap:12px 18px;margin-top:18px}.meta-app-settings form>details,.meta-app-settings form>button{grid-column:1/-1}.meta-app-settings form>button{justify-self:start}.meta-webhook-settings label{display:block;margin:12px 0}.meta-webhook-settings input{display:block;width:100%;margin-top:6px}.nova-key-settings{margin:0}.nova-key-settings:not([open]){display:none}
@media(max-width:750px){.main>.page-view{padding:18px 14px}.meta-app-settings form{grid-template-columns:1fr}.meta-toolbar-actions{width:100%}.meta-toolbar-actions button{flex:1}.channel-card{padding:18px}#meta-settings .integration-settings{padding:18px}.crm-tabbar{min-height:49px}.meta-toggles{gap:16px}}
/* Keep navigation targets at the same height when the rail expands on hover. */
.sidebar .workspace-label{display:none}
@media(hover:hover) and (pointer:fine){#sidebar-toggle{display:none}.sidebar .brand{margin-top:0}}
.order-evidence{margin:5px 0 14px}.order-evidence strong{font-size:12px}.order-product-lookup{position:relative}.order-product-lookup .order-suggestions{border-radius:10px;margin-top:5px}.order-field-note{margin-top:3px}
.media-image-open{display:block;padding:0;background:transparent;border:0;max-width:100%;cursor:zoom-in}.image-viewer{position:fixed;inset:12px;width:calc(100vw - 24px);height:calc(100dvh - 24px);max-width:none;max-height:none;margin:0;padding:0;border:1px solid #434955;border-radius:18px;background:#171b22;color:#fff;overflow:hidden}.image-viewer[open]{display:flex;flex-direction:column}.image-viewer::backdrop{background:#090c11c9;backdrop-filter:blur(5px)}.image-viewer-toolbar{display:flex;align-items:center;gap:16px;min-height:56px;padding:10px 16px;flex-shrink:0}.image-viewer-toolbar>span{flex:1;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.image-viewer-toolbar button,.image-viewer-toolbar a{color:#fff;background:#ffffff16;border-radius:9px;padding:8px 11px;text-decoration:none}.image-viewer-canvas{flex:1;min-height:0;overflow:auto;display:flex;align-items:center;justify-content:center;padding:10px}.image-viewer-canvas img{max-width:100%;max-height:100%;object-fit:contain}.image-viewer.original-size .image-viewer-canvas{display:block}.image-viewer.original-size img{max-width:none;max-height:none;display:block;margin:auto}
#notification-settings .inline-label{display:flex;align-items:center;gap:9px;margin:13px 0;font-size:13px;font-weight:400}#notification-settings input[type=checkbox]{width:16px;height:16px;flex:none}#notification-permission{line-height:1.5}

.new-crm-match{padding:12px 14px;margin:0 0 15px;border:1px solid #e1e6ed;border-radius:12px;background:#f7f9fc}.new-crm-match p{margin:0 0 7px}.new-crm-match p:empty{display:none}.new-crm-match label{margin:10px 0 0}.new-crm-match select{width:100%;min-width:0;padding:9px;border:1px solid #dce2e9;border-radius:8px;background:#fff;color:var(--ink)}.new-crm-match button{font-size:11px;padding:8px 10px;margin-top:5px}#new-template-stale{font-size:12px;line-height:1.5;margin:0 0 12px}

/* Navigation icon and notification badge have independent geometry. */
.sidebar .nav-item{display:flex;align-items:center}.sidebar .nav-item>.nav-icon{display:grid;place-items:center;flex:0 0 22px;width:22px;height:22px;line-height:1}.nav-icon .ui-icon,.nav-icon svg{display:block;width:22px;height:22px}.sidebar:not(.expanded) .nav-item{height:44px;padding:0;justify-content:center;gap:0}.sidebar .nav-count{position:absolute;right:9px;top:50%;transform:translateY(-50%);margin:0;line-height:14px;min-width:16px;text-align:center}.sidebar.expanded .nav-label{padding-right:22px}.sidebar:not(.expanded) .nav-count{top:1px;right:0;transform:none}.sidebar .nav-count.hidden{display:none}

.ai-cost-report{grid-column:1/-1}.cost-range{display:flex;flex-wrap:wrap;gap:12px;align-items:end;margin-bottom:18px}.cost-range label{margin:0;flex:1;min-width:150px}.cost-range button{min-height:42px}.cost-table-wrap{overflow:auto;max-height:420px}.cost-table{border-collapse:collapse;width:100%;font-size:13px}.cost-table th,.cost-table td{text-align:left;padding:12px 8px;border-bottom:1px solid var(--line)}.cost-table td:last-child,.cost-table th:last-child{text-align:right;white-space:nowrap}.cost-table small{display:block;margin-top:4px}.cost-table thead{position:sticky;top:0;background:white}

.payment-admin-grid{display:grid;grid-template-columns:minmax(300px,.85fr) minmax(0,1.3fr);gap:24px;align-items:start}.payment-accounts-list{display:grid;grid-template-columns:repeat(auto-fit,minmax(280px,1fr));gap:18px}.payment-account-heading{display:flex;align-items:center;justify-content:space-between;gap:10px}.payment-account-heading h3{margin-bottom:12px}.payment-account dt{font-size:12px;color:var(--muted);margin-top:12px}.payment-account dd{margin:4px 0}.payment-iban{overflow-wrap:anywhere;font-family:ui-monospace,monospace}.payment-hint{margin-top:16px;margin-bottom:0}.composer-library{position:relative;display:flex;align-items:center}.composer-library-menu{right:0;left:auto;min-width:215px}.payment-picker{width:min(580px,calc(100vw - 24px));max-height:calc(100dvh - 32px);overflow:auto}.payment-picker .modal-heading{display:flex;align-items:center;justify-content:space-between;gap:16px}.payment-picker .modal-heading h2{margin:0}.payment-format{border:1px solid var(--line);border-radius:14px;padding:12px 16px;margin:18px 0;display:flex;flex-wrap:wrap;gap:12px}.payment-format legend{font-weight:600;font-size:13px}.payment-format label{margin:0}.payment-preview{background:#f7f8fa;border-radius:16px;padding:18px;margin:16px 0}.payment-preview pre{font:inherit;font-size:13px;line-height:1.6;white-space:pre-wrap;overflow-wrap:anywhere;margin:0}.payment-preview img{display:block;margin:16px auto;max-width:100%;height:auto}.payment-link-preview{font-size:12px;overflow-wrap:anywhere;margin:16px 0 0}.payment-link-preview span{color:#344d79}.payment-picker>.primary{width:100%;margin-top:12px}@media(max-width:900px){.payment-admin-grid{grid-template-columns:minmax(0,1fr)}}

.sidebar .nav-count:not(.hidden){display:block}

/* Payment sheet: scroll the content while keeping its heading and action visible. */
.payment-picker{width:min(680px,calc(100vw - 32px));max-width:calc(100vw - 32px);max-height:calc(100dvh - 40px);padding:0;overflow:hidden;border:1px solid var(--line);border-radius:24px;background:#fff;box-shadow:0 24px 90px #18213235}
.payment-sheet{display:flex;flex-direction:column;max-height:inherit;min-height:0}
.payment-heading{display:flex;align-items:center;justify-content:space-between;gap:20px;padding:24px 28px 20px;border-bottom:1px solid var(--line);flex:none;background:#fff}
.payment-heading h2{margin:5px 0 0;font-size:22px;line-height:1.25;color:var(--ink)}
.payment-eyebrow{font-size:10px;font-weight:700;letter-spacing:1.4px;color:var(--muted)}
.payment-picker .payment-close{display:grid;place-items:center;width:36px;height:36px;padding:8px;border-radius:50%;flex:none;background:#f3f4f7;color:#7b8391}
.payment-picker .payment-close:hover{background:#e9ecf2;color:var(--ink)}
.payment-body{padding:24px 28px;overflow-y:auto;overscroll-behavior:contain;min-height:0;scrollbar-gutter:stable}
.payment-body>.notice{margin:0}.payment-order{display:flex;align-items:center;gap:12px;padding:14px 16px;background:#f4f6fa;border:1px solid #e9edf4;border-radius:14px;margin-bottom:24px;color:#53657f}
.payment-order>.ui-icon{width:24px;height:24px;flex:none}.payment-order strong,.payment-order span{display:block}.payment-order strong{font-size:13px;color:#36465b}.payment-order span{font-size:12px;margin-top:4px}
.payment-section{margin:0 0 24px}.payment-section h3{font-size:13px;margin:0 0 12px;font-weight:650;color:var(--ink)}
.payment-account-options{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;overflow:visible;padding:2px}
.payment-account-option{display:flex;align-items:center;justify-content:space-between;gap:10px;width:100%;padding:14px;text-align:left;background:#fff;border:1px solid #e2e6ed;border-radius:14px;color:var(--ink);min-width:0}
.payment-account-option:hover{background:#f8f9fc;border-color:#c7cedb}.payment-account-option.selected{background:#fff5f7;border-color:#d5264a;box-shadow:0 0 0 1px #d5264a10}
.payment-account-copy{min-width:0}.payment-account-copy strong{display:block;font-size:13px;line-height:1.4;overflow-wrap:anywhere}.payment-account-copy small{display:block;font-size:11px;color:#7d8796;margin-top:6px;font-weight:400;line-height:1.4}
.payment-account-check{display:grid;place-items:center;flex:none;width:20px;height:20px;border:1px solid #d6dce5;border-radius:50%;color:white}.selected>.payment-account-check{border-color:#d5264a;background:#d5264a}.payment-account-check .ui-icon{width:13px;height:13px}
.payment-fields{display:grid;gap:16px;margin-bottom:24px}.payment-fields label{margin:0;font-size:13px}.payment-fields input{padding:12px 14px;border-color:#e0e5ed;border-radius:12px;line-height:1.4}.payment-optional{font-weight:400;font-size:11px;color:var(--muted);margin-left:5px}
.payment-section-heading{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:12px}.payment-section-heading h3{margin:0}
.payment-select-all{display:inline-flex;align-items:center;gap:5px;background:transparent;color:#66758a;padding:7px 9px;font-size:11px;white-space:nowrap;border-radius:8px}.payment-select-all.selected{background:#eaf0fa;color:#345e99}.payment-select-all .ui-icon{width:14px;height:14px}
.payment-format-buttons{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}.payment-format-buttons button{display:flex;flex-direction:column;justify-content:center;align-items:center;gap:8px;min-width:0;min-height:76px;padding:12px 8px;background:#f7f8fb;border:1px solid #e6e9f0;border-radius:13px;color:#687587;font-size:11px;line-height:1.35;text-align:center}.payment-format-buttons button.selected{background:#edf2fb;border-color:#9aafd2;color:#345c94}.payment-format-buttons button:hover:not(:disabled){border-color:#9aafd2}.payment-format-buttons .ui-icon{width:21px;height:21px;flex:none}
.payment-preview{margin:0;padding:20px;background:#f7f8fb;border:1px solid #e9ecf2;border-radius:16px}.payment-preview h3{margin:0 0 18px;font-size:11px;font-weight:600;letter-spacing:.3px;color:#8a93a1}.payment-preview pre{font:inherit;font-size:13px;line-height:1.65;white-space:pre-wrap;overflow-wrap:anywhere;color:#344052;margin:0}
.payment-link-preview{margin:20px 0 0}.payment-preview h3+.payment-link-preview{margin-top:0}.payment-link-preview a{display:inline-flex;align-items:center;gap:8px;color:#3b6399;text-decoration:none;font-weight:600;font-size:13px}.payment-link-preview a:hover{text-decoration:underline}.payment-link-preview small{display:block;color:#8b94a3;margin-top:5px;font-size:11px}.payment-link-preview .ui-icon{width:16px;height:16px}
.payment-preview img{display:block;margin:20px auto;max-width:min(240px,100%);height:auto;border:8px solid white;border-radius:12px}.payment-instructions{font-size:12px;line-height:1.6;color:#748096;margin:18px 0 0}.payment-empty-preview{margin:0;padding:20px;border:1px dashed #dfe4ec;border-radius:14px;text-align:center;color:var(--muted);font-size:12px}.payment-progress{margin:-12px 0 12px}
.payment-footer{padding:18px 28px;border-top:1px solid var(--line);background:#fff;flex:none}.payment-footer>.primary{display:flex;align-items:center;justify-content:center;gap:8px;width:100%;border-radius:12px;min-height:46px;margin:0}.payment-footer .ui-icon{width:19px;height:19px}
@media(max-width:600px){.payment-picker{max-height:calc(100dvh - 24px);width:calc(100vw - 24px);max-width:calc(100vw - 24px);border-radius:20px}.payment-heading{padding:20px 18px 16px}.payment-heading h2{font-size:19px}.payment-body{padding:20px 18px}.payment-footer{padding:14px 18px}.payment-account-option{padding:11px;gap:6px}.payment-account-copy strong{font-size:12px}.payment-account-copy small{font-size:10px}.payment-format-buttons{grid-template-columns:repeat(3,minmax(0,1fr));gap:6px}.payment-format-buttons button{font-size:10px;padding:10px 5px}.payment-preview{padding:16px}.payment-section-heading{gap:5px}.payment-section-heading h3{font-size:12px}.payment-optional{display:inline-block}}
.payment-sheet{max-height:calc(100dvh - 42px)}
@media(max-width:600px){.payment-sheet{max-height:calc(100dvh - 26px)}}

/* CRM workspace: the card and order form share compact, responsive surfaces. */
#crm-panel{container-type:inline-size;background:#f7f8fb}.crm-tabbar{background:#fff}.crm-tabbar .crm-tabs button{padding:11px 7px;border-radius:11px}.crm-tabbar .crm-tabs button[aria-selected=true]{background:#edf2fa;color:#365e94}
#crm-content,#crm-order-root{padding:12px;gap:12px;scrollbar-gutter:stable;scroll-padding-block:16px}.crm-section{border:1px solid #e5e9f0;border-radius:16px;background:#fff;padding:16px;min-width:0;display:flex;flex-direction:column;gap:12px}.crm-content .crm-section-title,.order-panel .crm-section-title{font-size:12px;line-height:1.4;font-weight:700;margin:0;color:#526177;letter-spacing:.1px}.crm-section-heading{display:flex;align-items:center;gap:7px;min-width:0}.crm-eyebrow{display:block;color:#919bab;font-size:9px;line-height:1.4;font-weight:700;letter-spacing:1.1px;text-transform:uppercase}.crm-client-heading{display:flex;align-items:center;gap:11px}.crm-client-heading>div{min-width:0}.crm-content .crm-client-name{font-size:18px;line-height:1.3;margin:4px 0 0;overflow-wrap:anywhere}.crm-client-initial{display:grid;place-items:center;width:42px;height:42px;flex:none;border-radius:14px;background:#ecf0f7;color:#586e94;font-size:18px;font-weight:650}.crm-contacts{display:flex;flex-wrap:wrap;gap:6px}.crm-contact{font-size:12px;color:#53667f;text-decoration:none;padding:7px 9px;border-radius:9px;background:#f5f7fa;overflow-wrap:anywhere}.crm-contact:hover{background:#edf1f7}.crm-client-summary>.ui-icon{width:27px;height:27px;color:#7c90ad}.crm-order-count{color:#8b96a6;font-size:11px}.crm-content .crm-refresh{display:inline-flex;align-items:center;justify-content:center;gap:5px;padding:5px 6px;background:transparent;color:#6d7f98;margin-left:auto;font-size:10px;min-height:26px}.crm-refresh .ui-icon{width:13px;height:13px}.crm-refresh:hover{background:#f0f3f8}.crm-order-options{display:grid;gap:7px}.crm-content .crm-order-option{display:flex;flex-direction:column;gap:5px;text-align:left;width:100%;min-width:0;padding:11px 12px;background:#f8f9fc;color:#46536a;border:1px solid #e9edf4;border-radius:11px;line-height:1.45}.crm-order-option strong{font-size:12px;overflow-wrap:anywhere}.crm-order-meta{font-size:10px;color:#8995a6;font-weight:400;overflow-wrap:anywhere}.crm-content .crm-order-option[aria-pressed=true]{background:#edf2fc;border-color:#9bafd0;color:#355f98;box-shadow:inset 3px 0 #738eb9}.crm-content .crm-order-option:disabled{opacity:.85}.crm-content .crm-order-option:hover:not(:disabled){background:#f0f3fa;border-color:#b5c4dc}.crm-empty{font-size:12px;line-height:1.6;color:#8b96a5;margin:0;padding:13px;border:1px dashed #dfe5ee;border-radius:12px;background:#fbfcfd}.crm-section .crm-empty{padding:0;background:transparent;border:0}.crm-order-overview .crm-link{font-size:16px;line-height:1.5;color:#be2346;text-underline-offset:3px;text-decoration-thickness:1px}.crm-order-overview .crm-stage{font-size:11px;padding:7px 10px;border-radius:9px}.crm-order-date{font-size:10px;color:#919baa;margin-top:-5px}.crm-money-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:7px}.crm-field.crm-money{padding:11px 8px;border:1px solid #e9edf3;border-radius:11px;background:#f8f9fc;gap:7px;min-width:0}.crm-money>.small{font-size:9px;white-space:nowrap}.crm-money>span:last-child{font-size:12px;font-weight:700;line-height:1.4;color:#354358;overflow-wrap:anywhere}.crm-money.paid{background:#f3f8f5;border-color:#e4eee7}.crm-money.paid>span:last-child{color:#4f7b60}.crm-money.due{background:#edf2fc;border-color:#e1e8f5}.crm-money.due>span:last-child{color:#345e98}.crm-details-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.crm-field{gap:5px;line-height:1.5}.crm-field>.small{font-size:10px;color:#939dab}.crm-field>span:last-child{font-size:12px}.crm-products .crm-group-title{font-size:10px;font-weight:650;color:#8996a6;margin:0 0 9px;line-height:1.4}.crm-product-group+.crm-product-group{padding-top:14px;border-top:1px solid #edf0f5}.crm-products .crm-item{display:flex;flex-direction:row;align-items:start;gap:10px;border:0;padding:0;margin-top:12px}.crm-products .crm-item:first-of-type{margin-top:0}.crm-item-copy{flex:1;min-width:0}.crm-item-copy strong{display:block;font-size:12px;line-height:1.5;font-weight:600}.crm-item-copy small{display:block;margin-top:5px;font-size:10px;line-height:1.5}.crm-item-price{font-size:11px;color:#67758a;font-weight:600;line-height:1.5;flex:0 1 auto;max-width:35%;text-align:right}.crm-delivery .crm-field+.crm-field{border-top:1px solid #f0f2f6;padding-top:10px}.crm-stage-section>.secondary,.crm-notes>.secondary{width:100%;border-radius:10px;padding:10px 12px;color:#526b8d;background:#edf2f8}.crm-notes .note-editor{border-color:#e1e6ef;border-radius:12px}.crm-notes .note-body{min-height:140px}.crm-notes .note-toolbar{background:#f8f9fc}.crm-content .crm-relink{color:#8b96a5;background:transparent;font-size:11px;padding:10px;text-align:center}.crm-content .crm-relink:hover{background:#eef1f6;color:#526984}
.crm-content select,.order-panel select{appearance:none;background-color:#fff;background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 16 16'%3E%3Cpath d='m4 6 4 4 4-4' fill='none' stroke='%238594a9' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");background-repeat:no-repeat;background-position:right 11px center;background-size:14px;padding:11px 32px 11px 11px;min-height:41px;border:1px solid #e0e6ee;border-radius:10px;color:#4d5c70;line-height:1.5;font-size:12px;width:100%;min-width:0;text-overflow:ellipsis}.crm-content .note-toolbar select{min-height:29px;padding:4px 22px 4px 6px;background-position:right 5px center;font-size:10px}.crm-content input,.crm-content textarea{border-color:#e0e6ee;border-radius:10px;line-height:1.5}.crm-section input:focus,.crm-section select:focus,.crm-section textarea:focus{border-color:#91a8cd;box-shadow:0 0 0 3px #e8edf7}
.order-panel{display:flex;flex-direction:column;gap:12px}.order-panel fieldset{display:flex;flex-direction:column;gap:12px}.order-panel .crm-section{gap:10px}.order-panel .order-intro h3{font-size:17px;margin:0 0 2px}.order-panel .order-intro .crm-eyebrow{margin-bottom:-5px}.order-panel .crm-section>label{margin:3px 0;font-size:11px;font-weight:600;color:#637187;line-height:1.5}.order-panel .crm-section input,.order-panel .crm-section textarea{border-color:#e0e6ee;border-radius:10px;color:#364458;font-size:13px;line-height:1.5;padding:10px 11px;font-weight:400;margin:0}.order-panel .crm-section select{margin:0}.order-panel .small{font-size:10px;margin:0;color:#939daa}.order-panel .order-autofill{margin:0}.order-autofill>.secondary{width:100%;display:flex;justify-content:center;padding:10px;border:1px solid #dfe7f5;background:#edf2fb;color:#536f97;border-radius:10px}.order-panel .crm-section>details{margin:2px 0;font-size:11px;line-height:1.5}.order-panel details[open]{border-top:1px solid #edf0f5;padding-top:12px}.order-panel details>summary{color:#8290a2}.order-panel details>label,.order-panel details>input{margin:10px 0}.order-panel details>p{margin-top:10px}.order-panel .order-suggestions:empty{display:none}.order-panel .order-suggestions button{font-size:11px}.order-panel .order-field-note{margin-top:-4px}.order-panel .order-item{background:#f8f9fc;border:1px solid #e8ecf3;border-radius:12px;margin:0;padding:12px}.order-item>strong{font-size:12px;line-height:1.5;display:block;overflow-wrap:anywhere}.order-item>small{font-size:10px}.order-item-values label{font-size:10px;color:#8b96a5;margin:12px 0;gap:5px}.order-panel .order-item>button{background:transparent;padding:6px 0;color:#ad6775;font-size:10px}.order-segmented{display:grid;grid-template-columns:1fr 1fr;gap:3px;padding:3px;border:1px solid #e2e7ef;border-radius:10px;background:#f0f3f8}.order-panel .order-segmented button{font-size:10px;padding:8px 5px;border-radius:7px;background:transparent;color:#8a96a8;line-height:1.4;min-width:0}.order-panel .order-segmented button[aria-pressed=true]{background:#fff;box-shadow:0 1px 4px #26385412;color:#49688f}.order-panel .order-checkout{background:#f0f4fc;border-color:#e0e7f5}.order-panel .order-total{font-size:23px;line-height:1.3;color:#385c92;margin:0;font-weight:700}.order-panel .order-checkout #order-create{background:#3f5f8e;margin:3px 0 0;border-radius:11px;padding:12px;font-size:12px}.order-panel .order-checkout #order-create:hover{background:#334f78}.order-checkout .small:last-child{text-align:center}.order-panel [aria-invalid=true]{border-color:#d54357!important;background-color:#fff8f9!important}.crm-section .order-evidence{margin:0}.order-comment label{margin:0!important}
@container (max-width:330px){.crm-section{padding:13px}.crm-money-grid{grid-template-columns:1fr 1fr}.crm-money.due{grid-column:1/-1;flex-direction:row;justify-content:space-between;align-items:center}.crm-money>span:last-child{font-size:12px}.crm-details-grid{grid-template-columns:1fr}.crm-contact{font-size:11px}.crm-client-heading{gap:9px}}
@media(max-width:750px){#crm-content,#crm-order-root{padding:10px}.crm-section{border-radius:14px}.order-panel .crm-section input,.order-panel .crm-section textarea,.order-panel .crm-section select{font-size:16px}.crm-section input,.crm-section select{font-size:16px}}
.crm-order-options{grid-template-columns:repeat(2,minmax(0,1fr))}.crm-order-option:only-child{grid-column:1/-1}.crm-money>span:last-child{font-variant-numeric:tabular-nums}
@container (max-width:370px){.crm-money-grid{grid-template-columns:1fr 1fr}.crm-money.due{grid-column:1/-1;flex-direction:row;justify-content:space-between;align-items:center}}

/* Keep the reaction action on the sender/time/status line, including narrow chats. */
.message-footer{min-width:0;line-height:1.5}.message-footer:has(.react-button){flex-wrap:nowrap}.message-author{display:inline-flex;align-items:center;gap:4px;min-width:0}.message-author-name{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.message-author>span:last-child,.message-footer:has(.react-button) .message-status{flex:none;white-space:nowrap}.message-footer .react-button{display:grid;place-items:center;flex:0 0 22px;width:22px;height:22px;padding:3px;border-radius:50%;line-height:1}.message-footer .react-button .ui-icon,.message-footer .react-button svg{display:block;width:16px;height:16px}.message-footer .react-button:hover{background:#edf0f5;color:#53647b}

/* Match the composer tools geometrically while retaining the solid assistant star. */
#assistant-open .ui-icon svg{fill:currentColor;stroke:none}

/* Usage history: the selected period, total and graph are one snapshot. */
.ai-cost-report{grid-column:1/-1;background:#fff;border:1px solid var(--line);border-radius:18px;max-width:1200px}.cost-report-heading,.cost-chart-heading{display:flex;justify-content:space-between;align-items:center;gap:14px}.cost-report-heading h3{font-size:21px;margin:5px 0}.cost-eyebrow{font-size:10px;letter-spacing:1.3px;font-weight:700;color:#8992a2}.cost-report-heading p{margin:4px 0}.cost-presets{display:flex;gap:5px;flex-wrap:wrap;margin:22px 0 16px}.cost-presets button{background:#f3f4f8;color:#667083;padding:9px 14px;font-size:12px;border:1px solid transparent}.cost-presets button.selected{background:#eee9f6;border-color:#e0d4ec;color:#794399}.cost-range{display:flex;align-items:end;gap:12px;margin:0!important}.cost-range label{margin:0;max-width:200px;flex:1;font-size:11px;color:#758094}.cost-range input{padding:10px;font-size:12px;margin-top:5px}.cost-summary{display:grid;grid-template-columns:1.6fr 1fr 1.2fr;gap:20px;align-items:center;padding:24px 0;border-bottom:1px solid var(--line)}.cost-summary span{font-size:12px;color:#7b8495}.cost-total strong{display:block;margin:8px 0;font-size:34px;letter-spacing:-1px;color:#292c36;overflow-wrap:anywhere;font-variant-numeric:tabular-nums}.cost-total small{font-size:11px;color:#8992a0}.cost-stat strong{display:block;margin:9px 0;font-size:21px;font-variant-numeric:tabular-nums}.cost-reserved{font-size:12px;padding:12px;background:#fff8ed;border-radius:10px;color:#957440}.cost-chart{margin:24px 0 18px}.cost-chart h4,.cost-breakdown h4{font-size:13px;margin:0}.cost-chart-heading{align-items:start;min-height:38px}.cost-chart-selection{font-size:11px;color:#748097;text-align:right}.cost-chart svg{display:block;width:100%;height:auto;max-height:290px}.cost-grid-line{stroke:#e9ecf2;stroke-width:1}.cost-axis{font-family:inherit;font-size:10px;fill:#959ead}.cost-bar{fill:#a27cb8;transition:fill .12s}.cost-bar.selected{fill:#73428f}.cost-bar.zero{fill:#e1e5ed}.cost-chart g:focus{outline:none}.cost-chart g:focus .cost-bar{fill:#73428f;stroke:#422755;stroke-width:2}.cost-empty{font-size:12px;text-align:center;color:#8992a2}.cost-breakdown{border-top:1px solid var(--line);padding:20px 0}.cost-breakdown-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;margin-top:14px}.cost-breakdown-item{display:flex;gap:12px;align-items:center;justify-content:space-between;background:#f6f7fa;border-radius:11px;padding:14px;font-size:12px}.cost-breakdown-item small{display:block;margin-top:5px;font-size:10px;color:#8992a2;overflow-wrap:anywhere}.cost-breakdown-item b{white-space:nowrap;font-variant-numeric:tabular-nums}.cost-details{margin-top:10px;font-size:12px}.cost-details summary{color:#748095}.cost-table-wrap{max-height:300px;overflow:auto}.cost-table{width:100%;border-collapse:collapse;font-size:12px}.cost-table td,.cost-table th{padding:10px;border-bottom:1px solid var(--line);text-align:right}.cost-table td:first-child,.cost-table th:first-child{text-align:left}.cost-loading{padding:55px 0;color:#8992a2;text-align:center;min-height:270px}
/* A quiet report entry is always available without competing with navigation. */
.sidebar nav{min-height:0;overflow-y:auto;flex-shrink:1;scrollbar-width:thin}.sidebar .report-launcher{flex-shrink:0;display:flex;align-items:center;gap:10px;margin: auto 0 8px;padding:9px 12px;color:#959eab;background:transparent;min-height:36px;font-size:11px;white-space:nowrap;text-align:left}.sidebar .report-launcher:hover{background:#f3f4f7;color:#58647a}.sidebar .report-launcher .ui-icon{width:19px;height:19px;flex-shrink:0}.sidebar .profile{margin-top:0;flex-shrink:0}.sidebar:not(.expanded) .report-launcher{width:40px;height:36px;margin-left:auto;margin-right:auto;justify-content:center;padding:8px}.sidebar:not(.expanded) .report-launcher>span:not(.ui-icon){display:none}
/* Problem reports stay local; the screenshot is a preview of the app viewport. */
#problem-report-dialog{width:850px;max-width:calc(100vw - 24px);max-height:92dvh;padding:0;border:1px solid #e2e6ee;border-radius:22px;overflow:auto}#problem-report-dialog .report-compose{padding:25px}#problem-report-dialog .dialog-heading{align-items:start;gap:18px}#problem-report-dialog .dialog-heading h2{font-size:21px;margin:0 0 6px}#problem-report-dialog .dialog-heading p{margin:0 0 18px;line-height:1.5}#problem-report-dialog .icon-button{display:inline-flex;align-items:center;justify-content:center;flex-shrink:0;padding:9px;min-width:34px;height:34px}.report-preview{position:relative;width:100%;border:1px solid var(--line);border-radius:13px;overflow:hidden;background:#eef0f4}.report-preview img{width:100%;height:auto;display:block;pointer-events:none}.report-preview svg{position:absolute;inset:0;width:100%;height:100%;pointer-events:none}.report-preview.marking{cursor:crosshair;touch-action:none}.report-preview-tools{display:flex;gap:8px;margin:10px 0 18px}.report-preview-tools button{font-size:11px;padding:8px 11px}.report-preview-tools button[aria-pressed=true]{background:#f9e9ee;color:#bc244b}#problem-report-dialog form{margin:0}#problem-report-dialog label{font-size:13px;display:block;margin-bottom:8px}#report-comment{min-height:105px;max-height:220px;line-height:1.6;resize:vertical;font-size:13px}.required-marker{color:#ce2151}.report-submit-row{display:flex;gap:15px;align-items:center;justify-content:space-between;margin-top:18px}.report-submit-row>span{max-width:320px;font-size:11px;line-height:1.6}.report-submit-row button{font-size:12px;white-space:nowrap}.report-capturing{display:flex;justify-content:center;align-items:center;min-height:180px;color:#8a94a5;background:#f6f7fa;border-radius:13px;margin-bottom:20px}.report-success{text-align:center;padding:30px 0}.report-success>.ui-icon{width:40px;height:40px;margin:0 auto 18px;color:#47805c}.report-success strong{font-size:30px;display:block}.report-success p{color:#8892a2;font-size:13px;margin:14px 0 25px}
.reports-heading{display:flex;align-items:center;justify-content:space-between;gap:15px;margin-bottom:22px}.reports-heading h2{margin:0 0 8px;font-size:23px}.reports-heading p{margin:0;font-size:12px}.reports-heading>button{display:flex;align-items:center;gap:7px;font-size:12px}.reports-layout{display:grid;grid-template-columns:minmax(250px,340px) minmax(0,1fr);gap:20px;align-items:start}.reports-list-panel{min-width:0;border:1px solid var(--line);border-radius:16px;background:#fff;overflow:hidden}.reports-filters{padding:14px;display:flex;flex-wrap:wrap;gap:9px;border-bottom:1px solid var(--line)}.reports-filters input,.reports-filters select{font-size:12px;padding:11px;flex:1;min-width:100px}.report-row{width:100%;display:block;padding:17px;text-align:left;border-radius:0;border-bottom:1px solid var(--line);background:#fff;color:#354050;border-left:3px solid transparent}.report-row:last-child{border-bottom:0}.report-row:hover{background:#f8f9fc}.report-row.selected{background:#f0f3fa;border-left-color:#6a83ad}.report-row.unseen .report-row-top strong:before{content:'';display:inline-block;width:6px;height:6px;border-radius:50%;background:#d52954;margin-right:7px}.report-row-top{display:flex;justify-content:space-between;align-items:center;gap:8px}.report-row-top strong{font-size:13px}.report-row p{font-size:12px;line-height:1.6;margin:12px 0;color:#69768c;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;overflow-wrap:anywhere}.report-row small{font-size:10px;color:#95a0af}.report-status{font-size:10px;padding:5px 8px;border-radius:7px;display:inline-block;white-space:nowrap}.report-status.new{background:#fcebf1;color:#c92b57}.report-status.in_progress{background:#eef2fc;color:#5477a7}.report-status.resolved{background:#ebf5ed;color:#4e8660}.report-detail{border:1px solid var(--line);border-radius:17px;background:#fff;padding:24px;min-width:0}.report-detail>header{display:flex;justify-content:space-between;align-items:center}.report-detail h2{font-size:25px;margin:5px 0 12px}.report-meta{display:flex;flex-wrap:wrap;gap:8px 15px;font-size:11px;color:#929bad}.report-comment{white-space:pre-wrap;overflow-wrap:anywhere;font-size:14px;line-height:1.65;margin:22px 0}.report-detail-image{padding:0;width:100%;border:1px solid var(--line);border-radius:12px;overflow:hidden;display:block;background:#f2f3f6;cursor:zoom-in}.report-detail-image img{display:block;width:100%;height:auto}.report-status-actions{display:flex;gap:7px;flex-wrap:wrap;margin:18px 0}.report-status-actions button{font-size:11px;padding:9px 12px}.report-status-actions .selected{background:#e9eef8;color:#5373a8}.report-diagnostics{border-top:1px solid var(--line);padding-top:18px;margin-top:22px;font-size:12px}.report-diagnostics summary{color:#7c899f}.report-diagnostics dl{display:grid;grid-template-columns:auto 1fr;gap:8px;font-size:11px}.report-diagnostics dd{margin:0;overflow-wrap:anywhere}.report-diagnostics dt{color:#929bad}.report-diagnostics h3{font-size:12px;margin-top:20px}.report-log-table{overflow:auto;max-height:300px}.report-log-table table{width:100%;font-size:10px;border-collapse:collapse}.report-log-table td,.report-log-table th{padding:8px;border-bottom:1px solid var(--line);text-align:left;overflow-wrap:anywhere;min-width:90px}.report-log-table td small{display:block;font-size:9px;color:#97a1b0}.report-diagnostics pre{white-space:pre-wrap;overflow-wrap:anywhere;background:#f5f6f9;padding:12px;border-radius:9px;font-size:10px;max-height:300px;overflow:auto}.reports-detail-empty{text-align:center;padding:90px 15px;border:1px dashed var(--line);border-radius:16px}.reports-detail-empty>.ui-icon{width:38px;height:38px;color:#a1aabb;margin:0 auto 15px}.reports-detail-empty h3{font-size:15px}.reports-detail-empty p{font-size:12px}.reports-empty{padding:30px 15px;font-size:12px;text-align:center;color:#98a2b0}.report-pagination{display:flex;gap:8px;justify-content:space-between;align-items:center;padding:12px;font-size:11px}.report-pagination button{font-size:10px;padding:7px 9px}.report-image-viewer{padding:38px 6px 6px;background:#edf0f5;border:1px solid var(--line);border-radius:15px;max-width:96vw;max-height:94dvh}.report-image-viewer img{display:block;max-width:92vw;max-height:85dvh;object-fit:contain}.report-image-viewer>.icon-button{position:absolute;right:5px;top:2px;width:30px;height:30px;padding:5px}.meta-connections>.meta-assets{margin-top:12px}.meta-app-settings{margin:16px 0}.meta-app-settings form{margin-top:16px}
@media(max-width:1000px){.reports-layout{grid-template-columns:minmax(210px,280px) minmax(0,1fr);gap:12px}.report-detail{padding:18px}.cost-breakdown-grid{grid-template-columns:1fr}}
@media(max-width:750px){.sidebar .report-launcher{min-height:28px;height:28px;margin-bottom:4px}.sidebar nav{flex-shrink:1}.sidebar .profile{padding-top:10px}.cost-summary{grid-template-columns:1fr 1fr;gap:12px}.cost-total{grid-column:1/-1}.cost-total strong{font-size:30px}.cost-stat strong{font-size:17px}.cost-chart-heading{flex-direction:column;gap:8px;min-height:62px}.cost-chart-selection{text-align:left}.cost-breakdown-item{padding:12px;font-size:11px}.cost-report-heading h3{font-size:19px}.cost-presets{margin-top:16px}.cost-presets button{font-size:11px;padding:8px 10px}.cost-summary span{font-size:11px}.reports-layout{grid-template-columns:minmax(0,1fr)}.reports-list-panel{max-height:330px;overflow:auto}.reports-heading h2{font-size:19px}.reports-heading>button{padding:9px;font-size:11px}.reports-detail-empty{padding:30px 15px}.report-detail{padding:16px}.report-row{padding:13px}.report-row p{margin:8px 0}#problem-report-dialog .report-compose{padding:17px}#problem-report-dialog .dialog-heading h2{font-size:18px}.report-submit-row{flex-wrap:wrap;gap:12px}.report-submit-row>span{max-width:none;flex-basis:100%}.report-submit-row button{flex:1}.report-preview-tools{margin-bottom:16px}.report-diagnostics dl{grid-template-columns:1fr}.cost-range{flex-wrap:wrap}.cost-range label{max-width:none}}
.report-preview-viewport{max-height:40dvh;overflow:auto;border-radius:13px;border:1px solid var(--line);background:#eef0f4;overscroll-behavior:contain}.report-preview-viewport .report-preview{border:0;border-radius:0}.meta-maintenance{margin:18px 0}.meta-maintenance>summary{font-size:13px;color:#768297}.meta-maintenance>.meta-connections{margin-top:15px}.meta-maintenance .meta-toolbar{flex-direction:column;align-items:start}.meta-maintenance .meta-toolbar-actions{flex-wrap:wrap}.meta-maintenance .meta-toolbar-actions button{font-size:11px}.meta-maintenance .meta-webhook-settings summary{font-size:11px}

/* Footer stays together at the bottom; pointing at it does not open navigation. */
.sidebar .brand{flex-shrink:0}
.sidebar nav{width:100%;flex:0 1 auto}
.sidebar-footer{display:flex;flex-direction:column;flex-shrink:0;margin-top:auto;padding-top:12px;min-width:0}
.sidebar .sidebar-footer .report-launcher{margin:0 0 8px;width:100%;justify-content:flex-start}
.sidebar .sidebar-footer .profile{margin-top:0}
.sidebar:not(.expanded) .sidebar-footer{align-items:center}
.sidebar:not(.expanded) .sidebar-footer .report-launcher{width:40px;justify-content:center}

/* Compact searchable template cards and a stable, editable preview. */
#template-picker{width:940px;max-width:calc(100vw - 28px);height:min(700px,90dvh);max-height:90dvh;overflow:hidden;padding:0;border-radius:20px}
.template-picker-sheet{display:flex;flex-direction:column;height:100%;min-height:0;padding:24px}
.template-picker-sheet>.dialog-heading{flex-shrink:0;margin-bottom:20px;align-items:flex-start}
.template-picker-sheet>.dialog-heading h2{margin:0 0 5px;font-size:21px}
.template-picker-sheet>.dialog-heading p{margin:0}
.template-picker-sheet>.dialog-heading .icon-button{display:grid;place-items:center;width:36px;height:36px;flex-shrink:0;border-radius:50%;padding:0;line-height:1}
.template-picker-sheet>.dialog-heading .icon-button:hover{background:#f0f2f6}
.template-picker-workspace{display:grid;grid-template-columns:minmax(0,1.1fr) minmax(0,1fr);gap:22px;min-height:0;flex:1}
.template-picker-library{display:flex;flex-direction:column;min-height:0;min-width:0}
#template-picker-search{padding:11px 13px;border-radius:11px;flex-shrink:0}
.template-picker-library-heading{display:flex;justify-content:space-between;gap:10px;color:#7b8494;font-size:11px;font-weight:600;margin:15px 1px 9px}
#template-picker-list{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;align-content:start;min-height:0;max-height:none;overflow:auto;padding:2px 4px 5px 2px;scrollbar-width:thin}
#template-picker-list .template-choice{display:flex;flex-direction:column;gap:8px;min-width:0;min-height:106px;padding:12px;text-align:left;border:1px solid #e3e7ee;border-radius:12px;background:#fff;color:#343f50;transition:background .12s,border-color .12s,box-shadow .12s}
#template-picker-list .template-choice:hover{background:#faf7f9;border-color:#e2b4c0}
#template-picker-list .template-choice.selected{border-color:#cf2046;background:#fff6f8;box-shadow:0 0 0 1px #cf204619}
.template-choice-heading{display:flex;align-items:flex-start;justify-content:space-between;gap:6px;width:100%}
.template-choice-name{font-size:12px;line-height:1.4;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;overflow-wrap:anywhere}
.template-choice-check{visibility:hidden;color:#c91e43;line-height:1.4;flex-shrink:0}
.template-choice.selected .template-choice-check{visibility:visible}
.template-choice-meta{display:flex;flex-wrap:wrap;gap:4px 7px;align-items:center;font-size:10px;font-weight:500;color:#818b9a}
.template-choice-shortcut{font-size:10px;color:#6b7789;background:#f0f2f6;padding:2px 5px;border-radius:5px}
.template-choice-snippet{display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;font-size:10px;line-height:1.5;font-weight:400;color:#87909d;overflow-wrap:anywhere}
.template-picker-empty{grid-column:1/-1;font-size:12px;color:var(--muted);text-align:center;padding:30px 12px}
.template-picker-preview{display:flex;flex-direction:column;min-width:0;min-height:0;background:#f8f9fc;border:1px solid #e7eaf0;border-radius:14px;padding:16px}
.template-preview-heading{flex-shrink:0;margin-bottom:12px}
.template-preview-heading h3{font-size:15px;margin:7px 0 0;line-height:1.4;overflow-wrap:anywhere}
#template-preview-text{flex:1;min-height:100px;width:100%;resize:none;font-size:13px;line-height:1.65;background:white;border:1px solid #e1e5ed;border-radius:11px;padding:13px}
#template-preview-note{flex-shrink:0;font-size:11px;margin:12px 0 0;max-height:70px;overflow:auto;line-height:1.5}
.template-picker-footer{display:flex;align-items:center;justify-content:space-between;gap:20px;flex-shrink:0;border-top:1px solid #edf0f4;margin-top:20px;padding-top:16px}
.template-picker-footer>span{font-size:11px;max-width:230px}
.template-picker-footer>.primary{border-radius:11px;flex-shrink:0}
@media(max-width:750px){.sidebar-footer{padding-top:8px}.sidebar .sidebar-footer .report-launcher{margin-bottom:4px}#template-picker{max-width:calc(100vw - 16px);height:92dvh;max-height:92dvh;border-radius:16px}.template-picker-sheet{padding:16px}.template-picker-sheet>.dialog-heading{margin-bottom:14px}.template-picker-sheet>.dialog-heading h2{font-size:19px}.template-picker-workspace{grid-template-columns:minmax(0,1fr);grid-template-rows:minmax(130px,.9fr) minmax(180px,1fr);gap:12px}.template-picker-library-heading{margin:9px 1px 6px}.template-picker-preview{padding:12px}.template-preview-heading{margin-bottom:8px}.template-preview-heading h3{font-size:13px;margin-top:5px}#template-picker-list .template-choice{min-height:88px;padding:10px;gap:6px}.template-choice-snippet{-webkit-line-clamp:1}.template-picker-footer{margin-top:12px;padding-top:12px;gap:10px}.template-picker-footer>span{display:none}.template-picker-footer>.primary{width:100%}#template-preview-text{font-size:12px;padding:10px}#template-preview-note{font-size:10px;max-height:46px;margin-top:8px}}
@media(prefers-reduced-motion:reduce){#template-picker-list .template-choice{transition:none}}
/* Replies retain the same visual hierarchy in the composer and conversation. */
.message{position:relative}.message-content.with-reply{padding:9px;border:1px solid #e2e8e4;border-radius:17px;background:#fff}.outbound .message-content.with-reply{background:#edf5f0;border-color:#d5e5da}.with-reply>.bubble{padding:9px 5px 3px;border:0;background:transparent;border-radius:0}.reply-preview{display:flex;align-items:center;gap:9px;min-width:0;width:100%;padding:8px 11px;text-align:left;border-left:3px solid var(--green);border-radius:4px 9px 9px 4px;background:#25694e0c;color:var(--ink);font-size:12px;line-height:1.45;font-weight:400;overflow:hidden}.reply-preview:hover:not(:disabled){background:#25694e16}.reply-preview:disabled{opacity:1;cursor:default}.reply-preview-copy{display:flex;flex-direction:column;min-width:0;flex:1}.reply-preview strong{color:var(--green);font-size:12px;font-weight:650;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.reply-preview-copy>span{display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;white-space:pre-wrap;overflow-wrap:anywhere}.reply-preview img{width:34px;height:34px;object-fit:cover;border-radius:5px;flex-shrink:0}.composer-reply{grid-column:1/-1;display:flex;align-items:center;gap:8px;min-width:0;padding:0 1px 7px}.composer-reply .reply-preview{flex:1;background:transparent;padding-top:3px;padding-bottom:3px}.composer-reply-icon{color:var(--green);font-size:24px;width:34px;text-align:center;flex-shrink:0}.composer-reply>.icon-button{flex-shrink:0}.message-reply-action{position:absolute;top:8px;right:-34px;width:29px;height:29px;border-radius:50%;background:#fff;color:#6d7e73;box-shadow:0 1px 5px #263b2e12;font-size:20px;opacity:0;transition:opacity .12s}.message.outbound>.message-reply-action{right:auto;left:-34px}.message:hover>.message-reply-action,.message:focus-within>.message-reply-action{opacity:1}.message-reply-menu{position:absolute;top:38px;right:0;z-index:5;background:#fff;border:1px solid var(--line);box-shadow:0 6px 25px #1d302523;border-radius:12px;padding:5px;display:flex;min-width:150px;flex-direction:column}.message-reply-menu button{background:transparent;text-align:left;padding:11px 14px}.message-reply-menu button:hover{background:var(--green-light)}.reply-highlight .message-content{animation:reply-flash 1.8s ease-out}.reply-highlight .bubble{animation:reply-flash 1.8s ease-out}@keyframes reply-flash{0%,30%{box-shadow:0 0 0 4px #72b99677}100%{box-shadow:0 0 0 0 transparent}}@media(hover:none){.message-reply-action{opacity:1;position:static;width:30px;height:26px;margin:2px 0;background:transparent;box-shadow:none;float:right}.message.outbound>.message-reply-action{float:left}}@media(prefers-reduced-motion:reduce){.reply-highlight .message-content,.reply-highlight .bubble{animation:none;outline:2px solid #72b996;outline-offset:2px}}
.message-reply-action{display:grid;place-items:center}.message-reply-action .ui-icon{width:18px;height:18px}.composer-reply-icon{display:grid;place-items:center}.composer-reply-icon .ui-icon{width:23px;height:23px}.message-reply-menu button{display:flex;align-items:center;gap:8px}
