
.rchat{--rc-accent:#0020AB; --rc-accent-2:#0B1233; --rc-ink:#111522; --rc-mute:#6b7080;
  --rc-bg:#ffffff; --rc-soft:#F4F6FB; --rc-line:rgba(0,32,171,.14); --rc-radius:18px; --rc-btn-radius:999px;
  --rc-font:inherit; --rc-launch-bg:linear-gradient(135deg,#0020AB,#00157A); --rc-launch-fg:#fff;
  --rc-head:linear-gradient(135deg,#0020AB,#00106A); --rc-dot:#FFCB08;
  --rc-right:20px; --rc-bottom:20px; --rc-z:8500;
  position:fixed; right:var(--rc-right); bottom:var(--rc-bottom); z-index:var(--rc-z); font-family:var(--rc-font)}
.rchat-launch{display:inline-flex; align-items:center; gap:10px; height:50px; padding:0 20px 0 17px; border:0;
  border-radius:var(--rc-btn-radius); background:var(--rc-launch-bg); color:var(--rc-launch-fg); cursor:pointer;
  font:600 14px/1 var(--rc-font); letter-spacing:.01em;
  box-shadow:0 16px 38px -14px rgba(31,23,34,.6), 0 0 0 1px rgba(255,255,255,.08) inset;
  transition:transform .35s cubic-bezier(.16,1,.3,1), box-shadow .35s ease}
.rchat-launch:hover{transform:translateY(-2px); box-shadow:0 20px 44px -14px rgba(31,23,34,.7)}
.rchat-launch:focus-visible{outline:2px solid var(--rc-accent); outline-offset:3px}
.rchat.on .rchat-launch{transform:scale(.92); opacity:.0; pointer-events:none}
.rchat-panel{position:absolute; right:0; bottom:0; width:min(380px,calc(100vw - 24px)); height:min(560px,calc(100vh - 110px));
  display:flex; flex-direction:column; overflow:hidden; background:var(--rc-bg); color:var(--rc-ink);
  border-radius:var(--rc-radius); border:1px solid var(--rc-line);
  box-shadow:0 40px 90px -30px rgba(31,23,34,.55), 0 12px 30px -12px rgba(31,23,34,.25);
  transform-origin:100% 100%; opacity:0; transform:translateY(14px) scale(.97);
  transition:opacity .3s ease, transform .42s cubic-bezier(.16,1,.3,1)}
.rchat.on .rchat-panel{opacity:1; transform:none}

.rchat-panel[hidden]{display:none !important}
.rchat-head{display:flex; align-items:center; gap:12px; padding:16px 16px 16px 18px;
  background:var(--rc-head); color:#fff}
.rchat-mark{width:44px; height:44px; flex:none; display:grid; place-items:center; border-radius:50%;
  background:rgba(255,255,255,.08); box-shadow:0 0 0 1px rgba(255,255,255,.16) inset}
.rchat-mark img{width:30px; height:auto}
.rchat .rchat-launch{display:none}
.rchat-who{display:flex; flex-direction:column; gap:4px; min-width:0; flex:1}
.rchat-who b{font-size:15px; font-weight:600; letter-spacing:.01em}
.rchat-who i{font-style:normal; font-size:12px; color:rgba(255,255,255,.72); display:flex; align-items:center; gap:7px}
.rchat-dot{width:7px; height:7px; border-radius:50%; background:var(--rc-dot); box-shadow:0 0 0 3px rgba(255,203,8,.25)}
.rchat-x{width:40px; height:40px; flex:none; display:grid; place-items:center; border:0; border-radius:50%;
  background:transparent; color:#fff; cursor:pointer; transition:background .2s ease}
.rchat-x:hover,.rchat-x:focus-visible{background:rgba(255,255,255,.12)}
.rchat-log{flex:1; overflow-y:auto; padding:18px 16px 8px; display:flex; flex-direction:column; gap:10px;
  background:var(--rc-soft); scroll-behavior:smooth}
.rchat-msg{max-width:86%; padding:11px 14px; font-size:14px; line-height:1.5; border-radius:14px;
  animation:rc-in .38s cubic-bezier(.16,1,.3,1)}
.rchat-msg.them{align-self:flex-start; background:var(--rc-bg); border:1px solid var(--rc-line); border-bottom-left-radius:4px}
.rchat-msg.me{align-self:flex-end; background:var(--rc-accent); color:#fff; border-bottom-right-radius:4px}
.rchat-msg ul{margin:8px 0 8px 18px; padding:0}
.rchat-msg li{margin:2px 0}
.rchat-msg a{color:var(--rc-accent); font-weight:600; text-decoration:underline; text-underline-offset:2px}
.rchat-typing{display:flex; gap:5px; padding:14px 16px}
.rchat-typing i{width:7px; height:7px; border-radius:50%; background:var(--rc-mute); opacity:.4; animation:rc-dot 1s infinite}
.rchat-typing i:nth-child(2){animation-delay:.15s} .rchat-typing i:nth-child(3){animation-delay:.3s}

.rchat-quick{display:flex; flex-direction:column; background:var(--rc-soft); padding:0 16px}
.rchat-quick:empty{display:none}
.rchat-quick button{display:flex; align-items:center; justify-content:space-between; gap:10px; width:100%;
  min-height:40px; padding:9px 2px; border:0; border-top:1px solid var(--rc-line); background:transparent;
  color:var(--rc-accent-2); font:500 13.5px/1.3 var(--rc-font); text-align:left; cursor:pointer}
.rchat-quick button::after{content:"\2192"; color:var(--rc-accent); transition:transform .25s ease}
.rchat-quick button:hover::after,.rchat-quick button:focus-visible::after{transform:translateX(3px)}
.rchat-quick button:last-child{border-bottom:1px solid var(--rc-line); margin-bottom:10px}
.rchat-form{display:flex; gap:8px; padding:12px; border-top:1px solid var(--rc-line); background:var(--rc-bg)}
.rchat-form input{flex:1; min-width:0; height:44px; padding:0 14px; border:1px solid var(--rc-line);
  border-radius:calc(var(--rc-radius) * .6); background:var(--rc-soft); color:var(--rc-ink); font:400 16px var(--rc-font); outline:none}
.rchat-form input:focus{border-color:var(--rc-accent); background:#fff}
.rchat-form button{width:44px; height:44px; flex:none; border:0; border-radius:calc(var(--rc-radius) * .6);
  background:var(--rc-accent); color:#fff; display:grid; place-items:center; cursor:pointer}
.rchat-sr{position:absolute; width:1px; height:1px; overflow:hidden; clip:rect(0 0 0 0)}
@keyframes rc-in{from{opacity:0; transform:translateY(6px)}to{opacity:1; transform:none}}
@keyframes rc-dot{0%,100%{opacity:.3; transform:translateY(0)}50%{opacity:.9; transform:translateY(-3px)}}
@media (max-width:640px){
  .rchat-panel{position:fixed; right:8px; left:8px; bottom:8px; width:auto; height:min(78vh,600px)}
  .rchat-launch span{display:none}
  .rchat-launch{width:52px; height:52px; padding:0; justify-content:center}
}
@media (prefers-reduced-motion:reduce){
  .rchat-panel,.rchat-launch,.rchat-msg{transition:none; animation:none}
}
.rchat-panel:focus{outline:none}

body:has(.rchat.on) .jg-fabs,body:has(.rchat.on) #rs-fab,body:has(.rchat.on) .jg-dock,body:has(.rchat.on) .to-top,
body:has(.rchat.on) .pswitch,body:has(.rchat.on) .pswitch-tab{opacity:0 !important;pointer-events:none !important;transition:opacity .25s ease}
@media (max-width:860px){body:has(.rchat.on) .arail{opacity:0;pointer-events:none;transition:opacity .25s ease}}
