/* Keep reply context visible before typing; ownership actions stay quiet. */
.reply-to,.room-reply-to,.library-reply-to{padding:10px 12px;margin:0 0 10px;border-left:3px solid #bd9275;background:#f7f1e8;border-radius:4px;color:#584b40;font-size:12px;line-height:1.6;display:flex;align-items:start;justify-content:space-between;gap:12px;white-space:pre-line}
.reply-to[hidden],.room-reply-to[hidden],.library-reply-to[hidden]{display:none!important}
.reply-to button,.room-reply-to button,.library-reply-to button{flex:none;border:0;background:none;padding:0 3px;font-size:18px;color:#77695e}
.comment-compose-label{display:block;margin:8px 0;color:#536358;font-size:12px;font-weight:600}
.comment-inline-editor{margin:10px 0;padding:12px;border:1px solid #d9dfd5;border-radius:8px;background:#fcfbf6}
.comment-inline-editor label{display:grid;gap:8px;color:#536358;font:600 12px/1.5 system-ui}
.comment-inline-editor textarea{display:block;box-sizing:border-box;width:100%;min-height:90px;margin-top:8px;padding:10px 12px;border:1px solid #c7d1cb;border-radius:5px;background:#fffefa;font:14px/1.5 system-ui;color:#284a3d}
.comment-edit-controls,.comment-delete-confirm{display:flex;align-items:center;gap:12px;flex-wrap:wrap;margin-top:8px;font-size:12px}
.comment-edit-controls button,.comment-delete-confirm button{border:1px solid #cdd5c8;border-radius:5px;padding:6px 10px;background:#fff;color:#445c4d;font:inherit;cursor:pointer}
.comment-edit-status{width:100%;margin:0;font-size:12px;color:#a05243}.comment-edit-status:empty{display:none}
.comment-inline-editor textarea:focus-visible{outline:2px solid #7d9d91;outline-offset:-2px}
.comment-inline-editor .comment-edit-controls{justify-content:flex-end;gap:8px}
.comment-inline-editor .comment-edit-controls button{min-height:34px;border-radius:7px;padding:6px 12px}
.comment-inline-editor .comment-edit-controls button[type="submit"]{border-color:#a9c4cf;background:#e0edf1;color:#345769;font-weight:650}
:where(#room-comments,#community-dialog,.library-comments-dialog) :is(.comment-actions,.room-comment-actions,.library-comment-actions){gap:8px}
:is(#room-comments,#community-dialog,.library-comments-dialog) :is(.comment-actions,.room-comment-actions,.library-comment-actions) button{
 box-sizing:border-box;display:inline-flex;align-items:center;justify-content:center;gap:5px;min-height:34px;padding:5px 9px;
 border:1px solid #d9dfdc;border-radius:7px;background:#fffefa;color:#4c615b;font:500 12px/1.2 system-ui!important;box-shadow:none;
}
:is(#room-comments,#community-dialog,.library-comments-dialog) :is(.comment-actions,.room-comment-actions,.library-comment-actions) button:hover{border-color:#a7b7ae;background:#f2f5f1}
:is(#room-comments,#community-dialog,.library-comments-dialog) :is(.comment-actions,.room-comment-actions,.library-comment-actions) button[aria-pressed=true]{color:#b75e50;border-color:#e5b8ad;background:#fff0eb}
.comment.is-reply,.room-comment-list .is-reply{background:#faf9f5;border-left:2px solid #d8c2ae;margin-left:16px;padding-left:12px}

/* Shared reaction controls: feed, writing rooms, and library comments. */
:is(.comment-actions,.room-comment-actions,.library-comment-actions){display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin-top:12px}
:is(.comment-actions,.room-comment-actions,.library-comment-actions) :is(.comment-reaction-control,.comment-reply-control){box-sizing:border-box;display:inline-flex;align-items:center;justify-content:center;gap:6px;min-height:34px;min-width:68px;padding:6px 10px;border:1px solid #d9dfdc;border-radius:8px;background:#fff;color:#4c615b;font:500 12px/1.2 system-ui!important;cursor:pointer;box-shadow:0 1px 2px #243b2c08;vertical-align:middle}
:is(.comment-reaction-control,.comment-reply-control) svg{display:block;flex:none;width:16px;height:16px;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}
.comment-reaction-control b{font:600 12px/1 system-ui;font-variant-numeric:tabular-nums}
:is(.comment-actions,.room-comment-actions,.library-comment-actions) .comment-reaction-control[aria-pressed=true]{color:#b75e50;border-color:#e5b8ad;background:#fff0eb}
.comment-reaction-control[aria-pressed=true] svg{fill:currentColor}
:is(.comment-reaction-control,.comment-reply-control):hover{border-color:#a7b7ae;background:#f7f9f7}
:is(.comment-reaction-control,.comment-reply-control):focus-visible{outline:2px solid #7d9d91;outline-offset:3px}
:is(.comment-reaction-control,.comment-reply-control):disabled{opacity:.6;cursor:wait}

/* Mark the linked comment without painting outside its row. */
[data-notice-comment]{background-color:#eef3ec;box-shadow:inset 3px 0 #829e86}
:is(.comment.is-reply,.room-comment-list .is-reply)[data-notice-comment]{
 background-color:#eef3ec;
 border-left-color:#829e86;
 box-shadow:none;
}

:is(#room-comments,#community-dialog.feed-comments-dialog,.library-comments-dialog) .comment-inline-editor {
 display: grid;
 gap: 8px;
 min-width: 0;
 box-sizing: border-box;
}
:is(#room-comments,#community-dialog.feed-comments-dialog,.library-comments-dialog) .comment-inline-editor label {
 margin: 0;
}
.comment-inline-editor .comment-edit-controls {margin-top: 0;}
