
#jota-discord-chat{position:fixed;right:16px;bottom:100px;z-index:8500;font:14px system-ui;color:#fafafa}
#jota-discord-chat[hidden],#jdc-panel[hidden]{display:none}
#jdc-toggle,#jdc-panel button{background:#ffd335;color:#171717;border:0;border-radius:12px;padding:10px 14px;cursor:pointer;font-weight:700}
#jdc-panel{position:absolute;bottom:50px;right:0;width:min(370px,calc(100vw - 32px));max-height:calc(100dvh - 190px);overflow:auto;background:#202020;border:1px solid #555;border-radius:16px;padding:16px;box-shadow:0 12px 40px #0008}
#jdc-panel header{display:flex;align-items:center;justify-content:space-between;gap:12px}
#jdc-panel header button{background:transparent;color:white;font-size:24px}
#jdc-panel p{font-size:12px;line-height:1.5;color:#ddd;white-space:pre-wrap;overflow-wrap:anywhere}
#jdc-panel label{display:block;margin:10px 0}
#jdc-panel select,#jdc-panel textarea{width:100%;background:#111;color:#fff;border:1px solid #666;border-radius:8px;padding:8px;box-sizing:border-box;font:inherit}
#jdc-history{height:190px;overflow:auto;margin:12px 0}
#jdc-history>div{padding:8px 10px;border-radius:10px;margin:8px 0;background:#303030}
#jdc-history .jdc-own{background:#403b22;margin-left:20px}
#jdc-history .jdc-team{margin-right:20px}
#jdc-history p{margin:5px 0}
#jdc-panel details{border-top:1px solid #555;padding-top:10px}
#jdc-code{user-select:all}
#jdc-panel button:disabled{opacity:.5;cursor:wait}
@media(max-width:480px){#jota-discord-chat{right:12px;bottom:88px}#jdc-panel{max-height:calc(100dvh - 155px);bottom:48px}}

#jota-discord-panel-card{margin:20px 0;padding:20px;background:#202020;border:1px solid #555;border-radius:14px}
#jota-discord-panel-card button{background:#ffd335;color:#171717;border:0;border-radius:10px;padding:12px 16px;font-weight:700;cursor:pointer}
#jota-discord-panel-card a{display:inline-block;margin:12px}

#jdc-panel input{width:100%;background:#111;color:#fff;border:1px solid #666;border-radius:8px;padding:8px;box-sizing:border-box;font:inherit;margin-bottom:10px}
#jdc-history[hidden],#jdc-form[hidden],#jdc-identify[hidden]{display:none}

#jdc-admin-link input[type=checkbox]{width:auto;margin:0 5px 0 0}
#jdc-admin-link[hidden]{display:none}

/* Expandable native chat with reduced-motion support. */
#jdc-panel:not([hidden]){animation:jdc-open .24s ease-out;transform-origin:bottom right;box-sizing:border-box}
#jdc-panel header strong{flex:1}#jdc-panel #jdc-expand{font-size:22px;min-width:44px;min-height:44px;padding:6px}#jdc-panel #jdc-close{min-width:44px;min-height:44px}
#jota-discord-chat.jdc-expanded #jdc-panel{position:fixed;inset:5dvh auto auto 50%;transform:translateX(-50%);width:min(900px,94vw);height:88dvh;max-height:88dvh;display:flex;flex-direction:column;animation:jdc-expand .25s ease-out;padding:22px;z-index:8502;box-shadow:0 0 0 100vmax #0008,0 20px 70px #0008}
#jota-discord-chat.jdc-expanded #jdc-history{flex:1;min-height:100px;height:auto}#jota-discord-chat.jdc-expanded #jdc-form{flex:none}#jota-discord-chat.jdc-expanded #jdc-panel header{position:static;flex:none}
@keyframes jdc-open{from{opacity:0;translate:0 16px;scale:.96}to{opacity:1;translate:0 0;scale:1}}
@keyframes jdc-expand{from{opacity:.6;scale:.95}to{opacity:1;scale:1}}
@media(max-width:600px){#jota-discord-chat.jdc-expanded #jdc-panel{inset:8px 8px auto;transform:none;width:calc(100vw - 16px);height:calc(100dvh - 16px);max-height:calc(100dvh - 16px);padding:14px;padding-bottom:max(14px,env(safe-area-inset-bottom))}}
@media(prefers-reduced-motion:reduce){#jdc-panel:not([hidden]),#jota-discord-chat.jdc-expanded #jdc-panel{animation:none}}
