#gpog-chat-app{--purple:#673ab7;--blue:#2463c7;display:grid;grid-template-columns:310px minmax(0,1fr);min-height:640px;background:#fff;border:1px solid #e5e7eb;border-radius:16px;overflow:hidden;box-shadow:0 12px 38px #18213b12;color:#202432;font-family:inherit}
#gpog-chat-app *{box-sizing:border-box}.gpog-chat-sidebar{background:#faf9fd;border-right:1px solid #eceaf1;padding:18px;min-width:0}.gpog-chat-brand{display:flex;align-items:center;gap:12px;padding:5px 2px 20px}.gpog-chat-brand strong{display:block;font-size:19px}.gpog-chat-brand small,.gpog-chat-conv-head small{display:block;color:#777;font-size:12px;margin-top:3px}.gpog-chat-mark{display:grid;place-items:center;width:42px;height:42px;border-radius:50%;background:linear-gradient(135deg,#783de0,#2868cb);color:white;font-weight:800;font-size:23px}.gpog-chat-search input{width:100%;border:1px solid #dedbe7;border-radius:10px;padding:12px;background:white}.gpog-chat-results{margin-top:8px}.gpog-chat-user{display:flex;align-items:center;gap:10px;width:100%;border:0;background:white;padding:10px;border-radius:9px;text-align:left;cursor:pointer;margin:4px 0;color:#252535}.gpog-chat-user:hover{background:#f0ebfb}.gpog-chat-user img{width:34px;height:34px;border-radius:50%}.gpog-chat-list-title{font-size:10px;letter-spacing:1px;color:#8a8792;font-weight:700;margin:22px 0 10px}.gpog-chat-empty-list,.gpog-chat-no-results{font-size:13px;line-height:1.6;color:#85818e}.gpog-chat-main{min-width:0;position:relative;min-height:640px}.gpog-chat-welcome{height:100%;min-height:640px;display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center;padding:30px}.gpog-chat-welcome h2{margin:15px 0 4px}.gpog-chat-welcome p,.gpog-chat-welcome small{color:#777;max-width:420px}.gpog-chat-welcome-icon{width:72px;height:72px;border-radius:24px;background:#f0eafd;color:var(--purple);display:grid;place-items:center;font-size:34px}.gpog-chat-conversation{height:100%;min-height:640px;display:flex;flex-direction:column}.gpog-chat-conv-head{display:flex;align-items:center;gap:12px;padding:16px 20px;border-bottom:1px solid #eee}.gpog-chat-avatar{width:42px;height:42px;border-radius:50%;display:grid;place-items:center;background:#eee5ff;color:var(--purple);font-weight:700;font-size:20px}.gpog-chat-notice{padding:8px 18px;font-size:12px;color:#28724a;background:#f3fbf6}.gpog-chat-notice.error{background:#fff2f1;color:#b42318}.gpog-chat-messages{flex:1;min-height:360px;max-height:520px;overflow:auto;padding:20px;display:flex;flex-direction:column;gap:10px;background:linear-gradient(#fff,#fcfbff)}.gpog-chat-bubble{max-width:78%;padding:11px 14px;border-radius:14px;background:#f0eef5;align-self:flex-start;white-space:pre-wrap;overflow-wrap:anywhere}.gpog-chat-bubble.mine{background:#eee6ff;align-self:flex-end}.gpog-chat-bubble small{display:block;text-align:right;color:#777;font-size:10px;margin-top:6px}.gpog-chat-compose{display:flex;gap:10px;padding:14px 18px;border-top:1px solid #eee}.gpog-chat-compose textarea{resize:vertical;min-height:46px;max-height:130px;flex:1;border:1px solid #ddd8e8;border-radius:11px;padding:12px}.gpog-chat-compose button{border:0;border-radius:10px;background:var(--purple);color:#fff;padding:0 22px;font-weight:700;cursor:pointer}.gpog-chat-compose button:disabled{opacity:.5}.gpog-chat-compose-foot{font-size:10px;color:#888;padding:0 18px 12px}@media(max-width:700px){#gpog-chat-app{grid-template-columns:1fr;min-height:70vh}.gpog-chat-sidebar{border-right:0;border-bottom:1px solid #eee;padding:12px}.gpog-chat-main,.gpog-chat-conversation,.gpog-chat-welcome{min-height:55vh}.gpog-chat-welcome{min-height:55vh}.gpog-chat-messages{min-height:260px;max-height:45vh}.gpog-chat-compose{padding:10px}.gpog-chat-compose button{padding:0 14px}}
.gpog-chat-new-group{width:100%;border:1px solid #ded7ee;border-radius:9px;background:#f0eafd;color:#5d35a8;padding:10px 12px;font-weight:700;cursor:pointer;margin:4px 0 10px}.gpog-chat-thread-list{display:flex;flex-direction:column;gap:6px}.gpog-chat-thread{display:flex;align-items:center;gap:10px;width:100%;padding:10px;border:0;border-radius:10px;background:#fff;text-align:left;cursor:pointer;color:#252535}.gpog-chat-thread:hover,.gpog-chat-thread:focus{background:#f0ebfb}.gpog-chat-thread-avatar{width:36px;height:36px;border-radius:50%;display:grid;place-items:center;background:#eee5ff;color:#673ab7;font-weight:800;flex:0 0 36px}.gpog-chat-thread-info{display:flex;flex:1;min-width:0;flex-direction:column;gap:3px}.gpog-chat-thread-info strong{font-size:13px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.gpog-chat-thread-info small{font-size:11px;color:#888}.gpog-chat-unread{background:#2463c7;color:#fff;border-radius:20px;min-width:21px;height:21px;display:grid;place-items:center;font-size:11px;padding:0 5px}.gpog-chat-user.selected{background:#e9e0fb;border:1px solid #b9a2e8}.gpog-chat-sender{font-weight:700;color:#673ab7;text-align:left!important;margin:0 0 5px!important}

.gpog-chat-tools{display:flex;align-items:center;gap:8px;flex-wrap:wrap;padding:10px 18px 0}.gpog-chat-tool{border:1px solid #d9d0ec;background:#f7f3ff;color:#5d35a8;border-radius:9px;padding:8px 12px;font-size:12px;font-weight:700;cursor:pointer}.gpog-chat-tools span{font-size:11px;color:#777}.gpog-chat-attachment-image{display:block;max-width:220px;max-height:220px;object-fit:contain;border-radius:10px}.gpog-chat-attachment-video{display:block;max-width:260px;width:100%;border-radius:10px}.gpog-chat-bubble audio{display:block;max-width:230px;width:100%}.gpog-chat-file-link{color:#5632a4;font-weight:700;text-decoration:underline;overflow-wrap:anywhere}.gpog-chat-attachment-error{color:#a33;font-size:12px}

/* v0.5.0 calling */
.gpog-chat-conv-head{display:flex;align-items:center;gap:12px}
.gpog-chat-conv-title{display:flex;flex-direction:column;min-width:0;flex:1}
.gpog-chat-call-actions{display:flex;gap:7px;margin-left:auto}
.gpog-chat-call-actions button{border:0;border-radius:12px;background:#eee7fb;color:#6336b5;font-size:20px;font-weight:700;width:42px;height:42px;cursor:pointer}
.gpog-chat-call-actions button[hidden]{display:none}
.gpog-chat-call-panel{margin:12px 0;padding:16px;border:1px solid #e4deef;border-radius:18px;background:#fbfaff;box-shadow:0 8px 24px rgba(40,20,70,.08)}
.gpog-chat-call-panel[hidden]{display:none}
.gpog-chat-call-top{display:flex;flex-direction:column;gap:5px;margin-bottom:12px}
.gpog-chat-call-top strong{font-size:17px;color:#282334}
.gpog-chat-call-top span{font-size:14px;color:#6a6474}
.gpog-chat-call-media{position:relative;display:flex;align-items:center;justify-content:center;min-height:180px;max-height:420px;overflow:hidden;border-radius:14px;background:#17131f}
.gpog-chat-call-media video{display:block;max-width:100%;max-height:420px;object-fit:contain}
#gpog-chat-remote-video{width:100%;min-height:180px}
#gpog-chat-local-video{position:absolute;right:10px;bottom:10px;width:26%;max-height:130px;border:2px solid #fff;border-radius:10px;background:#292333}
#gpog-chat-remote-audio{position:absolute;width:1px;height:1px;opacity:.01;pointer-events:none}
.gpog-chat-call-placeholder{display:flex;align-items:center;justify-content:center;width:84px;height:84px;border-radius:50%;background:#7041bd;color:#fff;font-size:38px;font-weight:700}
.gpog-chat-call-controls{display:flex;justify-content:center;align-items:center;gap:8px;flex-wrap:wrap;margin-top:14px}
.gpog-chat-call-controls button{border:0;border-radius:999px;padding:11px 16px;background:#6840b5;color:#fff;font-weight:700;cursor:pointer}
.gpog-chat-call-controls button#gpog-chat-call-reject,
.gpog-chat-call-controls button#gpog-chat-call-end{background:#c93645}
.gpog-chat-call-controls button[hidden]{display:none}
.gpog-chat-call-controls button:disabled{opacity:.55;cursor:wait}
@media(max-width:600px){
 .gpog-chat-call-panel{margin:8px;padding:12px}
 .gpog-chat-call-media{min-height:150px}
 #gpog-chat-remote-video{min-height:150px}
 .gpog-chat-call-controls button{padding:10px 12px;font-size:13px}
 .gpog-chat-call-actions button{width:38px;height:38px}
}

.gpog-chat-identity-tools{display:flex;flex-wrap:wrap;gap:8px;justify-content:center;margin-top:18px;max-width:440px}.gpog-chat-identity-tools button{border:1px solid #d9d2e8;background:#fff;color:#49327a;border-radius:8px;padding:9px 12px;font-size:12px}.gpog-chat-identity-tools p{flex-basis:100%;font-size:12px;color:#777}


.gpog-chat-alerts{margin-left:auto;border:1px solid #ded5f0;background:#f1eaff;color:#6036a9;border-radius:8px;padding:8px 10px;font-size:11px;font-weight:700;cursor:pointer}.gpog-chat-alerts:disabled{opacity:.7}.gpog-chat-missed-calls{padding:8px 14px;background:#fff7e8;color:#8a4b08;font-size:12px}.gpog-chat-missed-item{padding:4px 0}

.gpog-chat-missed-summary{margin-top:12px;padding:10px;border-radius:10px;background:#fff7e8}.gpog-chat-missed-heading{font-size:10px;font-weight:800;letter-spacing:1px;color:#92520a;margin-bottom:5px}.gpog-chat-missed-item{display:block;width:100%;padding:7px 4px;border:0;background:transparent;color:#87470a;text-align:left;font-size:12px;cursor:pointer}

.gpog-chat-call-actions button svg{display:block;width:23px;height:23px;fill:currentColor}
.gpog-chat-alert-status{display:block;flex-basis:100%;width:100%;font-size:11px;color:#7655a8;margin:4px 0 0;text-align:right}
.gpog-chat-brand{flex-wrap:wrap}
.gpog-chat-alerts{white-space:nowrap}

/* v0.6.8 incoming answer visibility */
.gpog-chat-call-panel:not([hidden]){scroll-margin:24px}
#gpog-chat-call-accept{background:#16864a!important;color:#fff!important;min-width:100px}
#gpog-chat-call-reject{min-width:100px}

/* v0.7.0 active call controls and video self-view */
.gpog-chat-call-panel{position:relative;z-index:20}
.gpog-chat-call-media video{background:#17131f}
#gpog-chat-local-video{z-index:2;object-fit:cover}
#gpog-chat-call-mute{background:#4f3a78}
#gpog-chat-call-end{background:#c93645!important}

/* v0.7.1: keep video-call controls visible above mobile sticky navigation */
.gpog-chat-call-panel:not([hidden]){overflow:visible}
.gpog-chat-call-media{height:min(58vh,520px);min-height:260px;max-height:520px;display:block;position:relative}
.gpog-chat-call-media video#gpog-chat-remote-video{position:absolute;inset:0;width:100%;height:100%;max-width:100%;max-height:100%;object-fit:contain;z-index:1}
.gpog-chat-call-media video#gpog-chat-local-video{position:absolute;right:10px;top:10px;width:clamp(88px,28%,150px);height:auto;max-height:32%;aspect-ratio:3/4;object-fit:cover;border:2px solid #fff;border-radius:12px;z-index:3;background:#302b39}
.gpog-chat-call-media video[hidden]{display:none}
.gpog-chat-call-controls{position:absolute;left:8px;right:8px;bottom:10px;z-index:5;margin:0;padding:9px 7px;border-radius:16px;background:rgba(20,17,27,.82);backdrop-filter:blur(8px);gap:7px}
.gpog-chat-call-controls button{min-height:42px;padding:10px 14px;font-size:13px}
.gpog-chat-call-controls button#gpog-chat-call-end,.gpog-chat-call-controls button#gpog-chat-call-reject{background:#d93645}
.gpog-chat-call-top{position:relative;z-index:2}
@media(max-width:520px){.gpog-chat-call-media{height:54vh;min-height:240px}.gpog-chat-call-controls button{padding:10px 12px;font-size:12px}}
