/* ════════════════════════════════════════════════════════════════
   WINR v31 — Community chat interactions styles
   Reaction active/grey states · inline edit · hover-flip action
   buttons · composer-hint + mention-picker cleanup.
   Scoped to body.in-community where possible. Additive; remove the
   v31 link tag to revert.
   ════════════════════════════════════════════════════════════════ */

/* ── Reactions: clear reacted vs not-reacted ──────────────────── */
.cv2-reaction{
  transition:background .16s ease, border-color .16s ease, transform .12s ease, color .16s ease;
  cursor:pointer;
}
.cv2-reaction:hover{ transform:translateY(-1px); }
/* not-reacted = muted/grey baseline (in case Tony's default is brighter) */
.cv2-msg .cv2-reaction:not(.v31-reacted){
  background:rgba(255,255,255,0.04);
  border:1px solid rgba(255,255,255,0.08);
  color:var(--text-mid, #A1A1AA);
}
/* reacted = lights up in the user's WINR accent */
.cv2-msg .cv2-reaction.v31-reacted{
  background:var(--v31-accent-soft, rgba(57,255,20,0.16)) !important;
  border:1px solid var(--v31-accent-bd, rgba(57,255,20,0.5)) !important;
  color:#fff !important;
  box-shadow:0 0 10px var(--v31-accent-soft, rgba(57,255,20,0.16));
}

/* ── Hover-flip / label-reveal on message action buttons ──────── */
/* The "Not delivered → spin" delight, applied to reply / pin / react
   / edit. Icon nudges + a label slides out from the button on hover. */
body.in-community .cv2-msg-hover button{
  position:relative;
  transition:transform .15s ease, background .15s ease, color .15s ease;
}
body.in-community .cv2-msg-hover button:hover{ transform:translateY(-1px); }
body.in-community .cv2-msg-hover button:hover svg{ transform:scale(1.12); }
body.in-community .cv2-msg-hover button svg{ transition:transform .25s cubic-bezier(0.34,1.56,0.64,1); }
/* React smiley + edit pencil get a playful rotate on hover */
body.in-community .cv2-msg-hover button[title="React"]:hover svg{ transform:scale(1.12) rotate(8deg); }
body.in-community .cv2-msg-hover .v31-edit-btn:hover svg{ transform:rotate(-12deg) scale(1.1); }

/* tooltip-style label that expands from the button on hover */
body.in-community .cv2-msg-hover button[title]::after,
body.in-community .cv2-msg-hover .v31-edit-btn[data-label]::after{
  content:attr(title);
  position:absolute; bottom:calc(100% + 6px); left:50%;
  transform:translateX(-50%) translateY(4px) scale(.9);
  background:rgba(10,11,15,0.96); color:#fff;
  font-size:10.5px; font-weight:700; letter-spacing:.2px;
  padding:3px 8px; border-radius:6px; white-space:nowrap;
  border:1px solid rgba(255,255,255,0.1);
  box-shadow:0 6px 16px rgba(0,0,0,0.5);
  opacity:0; pointer-events:none;
  transition:opacity .15s ease, transform .15s cubic-bezier(0.34,1.56,0.64,1);
  z-index:50;
}
body.in-community .cv2-msg-hover .v31-edit-btn[data-label]::after{ content:attr(data-label); }
body.in-community .cv2-msg-hover button:hover::after{
  opacity:1; transform:translateX(-50%) translateY(0) scale(1);
}

/* Edit button sits in Tony's cluster, matches sibling styling */
.v31-edit-btn{
  display:inline-flex; align-items:center; justify-content:center;
  background:transparent; border:0; color:inherit; cursor:pointer;
  padding:0; width:auto;
}

/* ── Inline message edit ──────────────────────────────────────── */
.v31-edit-input{
  width:100%; min-height:38px; max-height:200px; resize:none;
  padding:9px 12px; border-radius:10px;
  background:var(--bg-input, #0E0E12); border:1px solid rgba(255,255,255,0.14);
  color:var(--text-hi, #fff); font-size:14.5px; line-height:1.45; font-family:inherit;
  outline:none; transition:border-color .15s ease, box-shadow .15s ease;
}
.v31-edit-input:focus{ border-color:rgba(255,255,255,0.3); box-shadow:0 0 0 3px rgba(255,255,255,0.06); }
.v31-edit-actions{ display:flex; align-items:center; gap:8px; margin-top:8px; }
.v31-edit-save, .v31-edit-cancel{
  height:30px; padding:0 14px; border-radius:var(--radius-pill, 999px);
  font-size:12px; font-weight:700; cursor:pointer; border:1px solid transparent;
  transition:transform .12s ease, background .15s ease, border-color .15s ease;
}
.v31-edit-save{ background:#fff; color:#0b0b0e; }
.v31-edit-save:hover{ transform:translateY(-1px); background:#e8e8ec; }
.v31-edit-cancel{ background:transparent; color:var(--text-mid, #A1A1AA); border-color:rgba(255,255,255,0.12); }
.v31-edit-cancel:hover{ color:#fff; border-color:rgba(255,255,255,0.25); }
.v31-edit-hint{ font-size:10.5px; color:var(--text-lo, #71717A); margin-left:2px; }
.v31-edited{ font-size:10.5px; color:var(--text-lo, #71717A); margin-left:6px; font-style:italic; }

/* ── Composer hint cleanup (the bar under the input) ──────────── */
body.in-community .cv2-composer-hint{
  display:flex; align-items:center; gap:7px; flex-wrap:wrap;
  font-size:11px; color:var(--text-lo, #71717A);
  padding-top:7px; opacity:.85;
}
body.in-community .cv2-composer-hint kbd{
  display:inline-flex; align-items:center; justify-content:center;
  min-width:18px; height:18px; padding:0 5px;
  font-family:inherit; font-size:10px; font-weight:700; line-height:1;
  color:var(--text-mid, #A1A1AA);
  background:rgba(255,255,255,0.06); border:1px solid rgba(255,255,255,0.12);
  border-radius:5px; box-shadow:0 1px 0 rgba(0,0,0,0.3);
}

/* ── Mention picker cleanup ───────────────────────────────────── */
body.in-community #cv2MentionPicker.cv2-mention-picker,
body.in-community .cv2-mention-picker{
  background:rgba(12,13,17,0.97) !important;
  border:1px solid rgba(255,255,255,0.1) !important;
  border-radius:14px !important;
  box-shadow:0 18px 50px rgba(0,0,0,0.6) !important;
  backdrop-filter:blur(20px) saturate(130%);
  padding:6px !important; overflow:hidden;
}
body.in-community .cv2-mention-item{
  display:flex; align-items:center; gap:10px;
  padding:7px 10px; border-radius:9px; cursor:pointer;
  transition:background .12s ease;
}
body.in-community .cv2-mention-item.active,
body.in-community .cv2-mention-item:hover{ background:rgba(255,255,255,0.07); }
body.in-community .cv2-mention-name{ font-weight:600; color:var(--text-hi, #fff); font-size:13px; }
body.in-community .cv2-mention-handle{ color:var(--text-lo, #71717A); font-size:12px; margin-left:auto; }
