/* NuzLabs v6.40.5 — Rich Messaging & Safe Attachments */
.organization-message-attachment-picker{margin-top:10px;padding:13px;border:1px solid rgba(120,144,160,.3);border-radius:12px;background:rgba(255,255,255,.55)}
.organization-message-attachment-picker>label{display:grid;gap:7px}
.organization-message-attachment-picker>label>b{font-size:13px;color:var(--ink,#142b3a)}
.organization-message-attachment-picker>label>b span{font-weight:600;color:var(--muted,#647985)}
.organization-message-attachment-picker input[type=file]{width:100%;max-width:100%;font:inherit}
.organization-message-attachment-picker small{font-size:12px;line-height:1.4;color:var(--muted,#647985)}
.organization-message-attachment-selection{display:grid;gap:6px;margin-top:10px}
.organization-message-attachment-selection>span{display:flex;align-items:center;justify-content:space-between;gap:12px;min-width:0;padding:8px 10px;border-radius:9px;background:rgba(37,112,135,.08)}
.organization-message-attachment-selection>span b{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:12px}
.organization-message-attachment-selection>span small{flex:0 0 auto;font-size:11px}
.organization-message-attachment-selection>span.empty{justify-content:flex-start;color:var(--muted,#647985);background:transparent;padding:2px 0}
.organization-message-attachment-security{display:grid;gap:2px;margin-top:9px;padding-top:9px;border-top:1px solid rgba(120,144,160,.18)}
.organization-message-attachment-security b{font-size:11px;letter-spacing:.02em}
.organization-message-attachment-security span{font-size:11px;line-height:1.4;color:var(--muted,#647985)}
.organization-message-attachments{display:grid;gap:7px;margin-top:10px}
.organization-message-attachment{width:100%;display:grid;grid-template-columns:auto minmax(0,1fr) auto;align-items:center;gap:10px;padding:9px 10px;border:1px solid rgba(120,144,160,.28);border-radius:10px;background:rgba(255,255,255,.74);color:inherit;text-align:left;cursor:pointer}
.organization-message-attachment:hover{border-color:rgba(38,118,139,.58);background:rgba(236,247,250,.92)}
.organization-message-attachment-kind{display:inline-flex;align-items:center;justify-content:center;min-width:48px;height:30px;padding:0 7px;border-radius:7px;font-size:10px;font-weight:800;letter-spacing:.07em;background:#eaf3f6;color:#236d82}
.organization-message-attachment-kind.pdf{background:#f7ecec;color:#a13e3e}
.organization-message-attachment-kind.video{background:#efeaf8;color:#65489b}
.organization-message-attachment-copy{display:grid;gap:2px;min-width:0}
.organization-message-attachment-copy b{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:12px}
.organization-message-attachment-copy small{font-size:11px;color:var(--muted,#647985)}
.organization-message-attachment-viewer{z-index:10080}
.organization-message-attachment-viewer-card{width:min(940px,calc(100vw - 28px));max-height:min(90vh,900px);overflow:auto}
.organization-message-attachment-viewer-card h2{padding-right:42px;overflow-wrap:anywhere}
.organization-message-attachment-viewer-body{display:grid;gap:14px;margin-top:14px}
.organization-message-attachment-viewer-body img,.organization-message-attachment-viewer-body video{display:block;max-width:100%;max-height:66vh;margin:auto;border-radius:10px;background:#0b1117}
.organization-message-attachment-viewer-body iframe{display:block;width:100%;height:min(68vh,720px);border:1px solid rgba(120,144,160,.3);border-radius:10px;background:#fff}
.organization-message-attachment-no-preview{display:grid;gap:5px;padding:22px;border:1px dashed rgba(120,144,160,.45);border-radius:10px;text-align:center}
.organization-message-attachment-no-preview span{font-size:12px;color:var(--muted,#647985)}
.organization-message-attachment-viewer-actions{display:flex;flex-wrap:wrap;gap:8px;justify-content:flex-end}
.organization-message-bubble.mine .organization-message-attachment{background:rgba(255,255,255,.82)}
html[data-theme=dark] .organization-message-attachment-picker,body.dark .organization-message-attachment-picker{background:rgba(7,18,26,.46);border-color:rgba(161,188,202,.22)}
html[data-theme=dark] .organization-message-attachment-picker>label>b,body.dark .organization-message-attachment-picker>label>b{color:#ecf5f8}
html[data-theme=dark] .organization-message-attachment,body.dark .organization-message-attachment{background:rgba(12,27,37,.78);border-color:rgba(161,188,202,.22);color:#edf7fa}
html[data-theme=dark] .organization-message-attachment:hover,body.dark .organization-message-attachment:hover{background:rgba(21,49,61,.88)}
html[data-theme=dark] .organization-message-attachment-kind,body.dark .organization-message-attachment-kind{background:rgba(53,131,151,.25);color:#aee6f2}
html[data-theme=dark] .organization-message-attachment-kind.pdf,body.dark .organization-message-attachment-kind.pdf{background:rgba(159,69,69,.25);color:#f0b5b5}
html[data-theme=dark] .organization-message-attachment-kind.video,body.dark .organization-message-attachment-kind.video{background:rgba(111,80,164,.3);color:#d2bff2}
@media (max-width:640px){
 .organization-message-attachment-picker{padding:11px}
 .organization-message-attachment-selection>span{align-items:flex-start;flex-direction:column;gap:2px}
 .organization-message-attachment{grid-template-columns:auto minmax(0,1fr) auto;padding:9px}
 .organization-message-attachment-kind{min-width:42px}
 .organization-message-attachment-viewer-card{width:calc(100vw - 16px);max-height:94vh;padding-left:14px;padding-right:14px}
 .organization-message-attachment-viewer-body iframe{height:65vh}
 .organization-message-attachment-viewer-actions{display:grid;grid-template-columns:1fr}
 .organization-message-attachment-viewer-actions .button{width:100%;text-align:center}
}

/* v6.40.5.1 — keep Message / Announcement modals reachable at every viewport height. */
.organization-message-overlay{overflow-y:auto!important;overscroll-behavior:contain;-webkit-overflow-scrolling:touch;padding-top:max(10px,env(safe-area-inset-top));padding-bottom:max(10px,env(safe-area-inset-bottom))}
.organization-message-overlay>.organization-message-thread-card,.organization-message-overlay>.organization-message-compose-card,.organization-message-overlay>.organization-message-email-preferences-card{max-height:calc(100dvh - 20px)!important;overflow-y:auto!important;overscroll-behavior:contain;-webkit-overflow-scrolling:touch;margin-top:auto;margin-bottom:auto}
.organization-message-overlay>.organization-message-thread-card .organization-message-thread-list{max-height:none!important;overflow:visible!important}
@supports not (height:100dvh){
 .organization-message-overlay>.organization-message-thread-card,.organization-message-overlay>.organization-message-compose-card,.organization-message-overlay>.organization-message-email-preferences-card{max-height:calc(100vh - 20px)!important}
}
@media (max-width:640px){
 .organization-message-overlay{padding:6px!important}
 .organization-message-overlay>.organization-message-thread-card,.organization-message-overlay>.organization-message-compose-card,.organization-message-overlay>.organization-message-email-preferences-card{max-height:calc(100dvh - 12px)!important}
}

/* v6.40.5.2 — keep reply / announcement controls in normal document flow while the message card scrolls. */
.organization-message-overlay>.organization-message-thread-card .organization-message-reply,
.organization-message-overlay>.organization-message-thread-card .organization-message-announcement-note{
 position:static!important;
 top:auto!important;
 right:auto!important;
 bottom:auto!important;
 left:auto!important;
 inset:auto!important;
 z-index:auto!important;
 transform:none!important;
 margin-top:14px!important;
}
.organization-message-overlay>.organization-message-thread-card .organization-message-reply{width:100%;max-width:100%;box-sizing:border-box}
.organization-message-overlay>.organization-message-thread-card .organization-message-thread-list{position:relative;z-index:0}

/* v6.40.5.3 — let the full message history participate in card layout instead of overflowing a fixed-height thread list. */
.organization-message-overlay>.organization-message-thread-card .organization-message-thread-list{
 height:auto!important;
 min-height:0!important;
 max-height:none!important;
 overflow:visible!important;
}

/* v6.40.5.4 — remove the legacy fixed grid track so message history and reply controls share one normal document flow. */
.organization-message-overlay>.organization-message-thread-card{
 display:block!important;
 grid-template-columns:none!important;
 grid-template-rows:none!important;
 align-content:normal!important;
}
.organization-message-overlay>.organization-message-thread-card>.organization-message-thread-head,
.organization-message-overlay>.organization-message-thread-card>.organization-message-thread-participants,
.organization-message-overlay>.organization-message-thread-card>.organization-message-thread-list,
.organization-message-overlay>.organization-message-thread-card>.organization-message-reply,
.organization-message-overlay>.organization-message-thread-card>.organization-message-announcement-note{
 width:100%;
 max-width:100%;
 box-sizing:border-box;
}
.organization-message-overlay>.organization-message-thread-card>.organization-message-thread-list{
 margin-top:14px;
 margin-bottom:0;
}
