.discussion-interactions { min-width: 0; }
.discussion-interactions .post-actions { flex-wrap: wrap; gap: 4px 6px; margin-bottom: 0; }
.post-actions > a, .post-actions > button, .post-actions > form > button, .post-actions > .book-share-menu > summary { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 8px 10px; border-radius: 10px; line-height: 1.25; white-space: nowrap; }
.post-actions > a:hover, .post-actions button:not(:disabled):hover, .post-actions > a[aria-expanded=true], .post-actions > .book-share-menu > summary:hover, .post-actions > .book-share-menu > summary:focus-visible, .post-actions > .book-share-menu[open] > summary { background: var(--surface-soft); color: var(--green); }
.post-actions span:empty { display: none; }
.post-actions [data-discussion-target=likes], .post-actions [data-discussion-target=count] { font-variant-numeric: tabular-nums; }
.post-actions button:disabled { opacity: .5; cursor: not-allowed; }
.interaction-status { margin: 0 0 12px; color: var(--muted); font-size: var(--text-small); }
.inline-comments:not([hidden]) { padding-top: 12px; animation: comments-in .22s ease-out; }
.comments-loading { display: flex; align-items: center; gap: 11px; border-top: 1px solid var(--line); padding: 18px 0; }
.comments-loading-avatar, .comments-loading-lines::before, .comments-loading-lines::after { display: block; background: var(--line); animation: comment-loading 1.4s ease-in-out infinite; }
.comments-loading-avatar { flex: 0 0 34px; height: 34px; border-radius: 50%; }
.comments-loading-lines { display: grid; gap: 9px; width: min(220px, 65%); }
.comments-loading-lines::before, .comments-loading-lines::after { content: ''; height: 8px; border-radius: 4px; }
.comments-loading-lines::before { width: 42%; }
.inline-thread { border-top: 1px solid var(--line); padding: 16px 0 0; }
.inline-thread-heading { display: flex; flex-wrap: wrap; gap: 6px 12px; align-items: baseline; margin-bottom: 16px; font-size: var(--text-base); }
.inline-thread [data-comment-list] > .empty-note { padding: 0; margin: 0 0 16px; text-align: left; }
.inline-thread-heading span { color: var(--muted); font-size: var(--text-base); }
.inline-comment { display: grid; grid-template-columns: 34px minmax(0, 1fr); gap: 11px; margin: 0 0 18px; }
.inline-comment .avatar, .inline-compose .avatar { width: 34px; height: 34px; }
.inline-comment header { display: flex; flex-wrap: wrap; align-items: baseline; gap: 5px 12px; font-size: var(--text-small); }
.inline-comment time { font-size: var(--text-small); color: var(--muted); }
.inline-comment p { margin: 5px 0 0; line-height: 1.6; font-size: var(--text-base); overflow-wrap: anywhere; }
.inline-compose { display: grid; grid-template-columns: 34px minmax(0, 1fr); gap: 11px; padding: 15px 0 5px; border-top: 1px solid var(--line); }
.inline-compose textarea { min-height: 78px; resize: vertical; background: var(--surface); }
.inline-compose label { font-size: var(--text-small); }
.inline-thread-pages { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; }
.inline-thread-pages { margin: 12px 0; font-size: var(--text-small); }
@keyframes comments-in { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: none; } }
@keyframes comment-loading { 0%, 100% { opacity: .35; } 50% { opacity: .7; } }
@media (max-width: 600px) {
    .discussion-interactions .post-actions { column-gap: 4px; }
    .post-actions > a, .post-actions > button, .post-actions > form > button, .post-actions > .book-share-menu > summary { gap: 6px; padding-inline: 8px; }
}
@media (prefers-reduced-motion: reduce) { .inline-comments:not([hidden]), .comments-loading-avatar, .comments-loading-lines::before, .comments-loading-lines::after { animation: none; } }

.content-menu { position: relative; flex: 0 0 auto; margin-left: auto; }
.content-menu summary { display: flex; align-items: center; justify-content: center; width: 36px; height: 36px; border-radius: 50%; cursor: pointer; color: var(--muted); list-style: none; }
.content-menu summary::-webkit-details-marker { display: none; }
.content-menu summary:hover, .content-menu[open] summary { background: var(--sage); color: var(--green); }
.content-menu summary:focus-visible { outline: 2px solid var(--green); outline-offset: 2px; }
.content-menu-panel { position: absolute; right: 0; top: calc(100% + 4px); z-index: 20; width: max-content; max-width: min(260px, 80vw); min-width: 190px; padding: 6px; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 8px 24px color-mix(in srgb,var(--shadow-color) 10.2%,transparent); }
.content-menu-panel > a, .content-menu-panel > button { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 42px; padding: 10px; border: 0; border-radius: 6px; background: transparent; color: var(--ink); font: inherit; font-size: var(--text-base); text-align: left; cursor: pointer; }
.content-menu-panel > :hover { background: var(--surface-soft); }
.content-menu-panel .content-menu-danger { color: var(--error); }
.post-heading > .content-menu { margin-left: 0; }
.content-edited { font-size: var(--text-small); color: var(--muted); }
.content-action-dialog { width: min(540px, calc(100vw - 32px)); max-height: calc(100dvh - 40px); margin: auto; padding: 24px; border: 1px solid var(--line); border-radius: 16px; background: var(--surface); color: var(--ink); box-shadow: 0 20px 80px color-mix(in srgb,var(--shadow-color) 20.0%,transparent); }
.content-action-dialog::backdrop { background: var(--scrim); }
.content-action-form { padding: 0; }
.content-action-form header { display: flex; align-items: start; justify-content: space-between; gap: 16px; }
.content-action-form h2 { font-size: var(--text-section); margin: 0; }
.content-action-form header > button { font-size: var(--text-base); min-width: 32px; }
.content-action-form > p { font-size: var(--text-base); line-height: 1.5; margin: 12px 0 20px; }
.content-action-buttons { display: flex; justify-content: flex-end; flex-wrap: wrap; gap: 10px; margin-top: 20px; }
.inline-comment header { flex-wrap: wrap; }
.inline-comment header .content-menu { margin-left: auto; }

.content-menu-panel[popover] { position: fixed; inset: auto; margin: 0; color: var(--ink); }

.like-actions { display: inline-flex; align-items: center; gap: 2px; }
.like-actions > form > button, .like-actions > a { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 8px 10px; border-radius: 10px; line-height: 1.25; white-space: nowrap; }
.like-actions > .like-count { min-width: 36px; padding-inline: 8px; text-decoration: underline; text-underline-offset: 3px; font-weight: 600; }
.like-actions > a:hover { background: var(--surface-soft); color: var(--green); }
.like-actions > [hidden] { display: none; }
.likes-dialog { padding: 20px; }
.likes-panel > header { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 0; margin: 0 0 12px; }
.likes-panel > header > h2 { margin: 0; padding: 0; font-size: var(--text-section); line-height: 1.2; }
.likes-panel > header > .icon-button { flex: 0 0 44px; width: 44px; height: 44px; margin: 0; padding: 0; }
.likes-panel h2 small { font: inherit; color: var(--muted); }
.likes-people { list-style: none; padding: 0; margin: 0; }
.likes-people li + li { border-top: 1px solid var(--line); }
.likes-people a, .likes-private { display: flex; align-items: center; gap: 12px; padding: 12px 0; }
.likes-people a > span { min-width: 0; overflow-wrap: anywhere; }
.likes-people small { display: block; color: var(--muted); }
.likes-people .avatar { width: 42px; height: 42px; flex-shrink: 0; }
.likes-private { color: var(--muted); }

.content-action-form .button.danger { --button-face:var(--error); --button-hover:var(--error-hover); --button-ink:var(--error-ink); --button-hover-ink:var(--error-ink); }
.content-action-form h1 .icon { margin-right:.5rem; color:var(--green); }

.post:target, .is-discussion-target { scroll-margin-top:calc(var(--header-height, 86px) + 24px); }
.inline-comment.is-discussion-target { background:var(--sage); border-radius:10px; padding:12px; outline:2px solid var(--green); outline-offset:2px; }

.friendship-response { display:flex; flex-wrap:wrap; align-items:stretch; gap:10px; width:100%; }
.friendship-response > form { flex:1 1 auto; margin:0; }
.friendship-response .button { width:100%; height:100%; gap:8px; }

.comment-actions { display:flex; flex-wrap:wrap; align-items:center; gap:4px 10px; margin-top:6px; }
.comment-actions form { margin:0; }
.comment-actions button, .comment-like-total { display:inline-flex; align-items:center; justify-content:center; gap:7px; min-height:40px; padding:6px 10px; border:0; border-radius:8px; background:transparent; color:var(--muted); font:inherit; font-size:var(--text-base); font-weight:650; cursor:pointer; }
.comment-actions button:hover, .comment-actions button[aria-pressed=true] { color:var(--green); background:var(--sage); }
:is(.post-actions, .comment-actions) button[aria-pressed=true],
:is(.post-actions, .comment-actions) button[aria-pressed=true]:hover { color:var(--love); background:var(--love-bg); }
.comment-actions button:focus-visible, .comment-recipient:focus-visible, .comment-more-replies:focus-visible { outline:2px solid var(--green); outline-offset:2px; }
.comment-actions button:disabled { opacity:.55; cursor:wait; }
.comment-actions [data-comment-likes]:empty { display:none; }
.comment-reply-context { display:flex; gap:8px; align-items:center; padding:0; margin:0 0 6px; color:var(--green); font-size:var(--text-small); }
.comment-reply-context[hidden] { display:none; }
.comment-reply-context > div { flex:1; min-width:0; }
.comment-reply-context .icon-button { flex:0 0 44px; width:44px; height:44px; }
@media (max-width:600px) { .comment-actions button { min-height:44px; } }

.comment-thread-group { min-width:0; margin:0 0 24px; }
.comment-thread-item { margin:0; gap:8px; }
.comment-thread-body { min-width:0; }
.comment-bubble { padding:10px 14px; border-radius:14px; background:var(--surface-soft); color:var(--ink); }
.comment-bubble header { align-items:center; gap:4px 8px; margin-bottom:4px; }
.comment-bubble header > a { min-width:0; overflow-wrap:anywhere; font-size:var(--text-base); }
.comment-bubble .content-menu summary { width:32px; height:32px; }
.comment-bubble p { margin:0; line-height:1.5; }
.comment-meta { display:flex; flex-wrap:wrap; align-items:center; gap:0 10px; margin-top:4px; }
.comment-meta .comment-actions { margin:0; gap:0 4px; }
.comment-meta .comment-actions button { min-height:32px; padding:4px 6px; font-size:var(--text-small); gap:5px; }
.comment-meta time { overflow-wrap:anywhere; }
.comment-recipient { display:inline-block; margin:0 0 4px; color:var(--green); font-size:var(--text-small); text-decoration:underline; text-underline-offset:3px; }
.comment-more-replies { display:inline-flex; align-items:center; min-height:44px; margin-top:8px; color:var(--green); font-size:var(--text-small); font-weight:650; overflow-wrap:anywhere; }
.comment-more-replies[hidden], .comment-replies-list > [hidden] { display:none; }
.comment-more-replies[aria-disabled="true"] { opacity:.6; cursor:wait; }
.comment-replies { margin:12px 0 0 17px; padding-left:16px; border-left:2px solid var(--line); }
.comment-replies-list { display:grid; gap:12px; min-width:0; }
.comment-thread-item--reply { grid-template-columns:28px minmax(0, 1fr); }
.comment-thread-item--reply .avatar { width:28px; height:28px; }
.comment-reply-slot:empty { display:none; }
.comment-thread-group > .comment-reply-slot { margin-left:33px; }
.comment-reply-slot .inline-compose { border:0; padding:4px 0 12px; }
.comment-reply-slot .form-card { padding:12px 0; margin:0; border:0; background:transparent; box-shadow:none; }
[data-comment-composer] .social-editor .ql-editor { min-height:44px; max-height:240px; padding:10px 12px; line-height:1.5; }
[data-comment-composer] textarea { min-height:44px; }
.comment-compose-body { min-width:0; }
.comment-compose-body > .social-editor { margin-bottom:0; }
.comment-editor-footer { display:flex; align-items:center; gap:8px; margin-top:4px; }
.inline-compose .social-editor.is-enhanced .comment-editor-footer .editor-tools { flex:1 1 auto; min-width:0; flex-wrap:wrap; gap:0; margin:0; padding:0; }
.inline-compose .comment-editor-footer .editor-tools button { flex:0 0 32px; min-width:32px; min-height:36px; padding:0; }
.comment-editor-footer .comment-editor-send { flex:none; min-height:36px; margin-left:auto; padding:6px 12px; }
.inline-compose .social-editor .ql-editor.ql-blank::before { inset-inline:12px; }
.inline-compose .comment-reply-context .icon-button { flex-basis:32px; width:32px; min-width:32px; height:32px; min-height:32px; }
@media (max-width:600px) {
    .comment-meta .comment-actions button { min-height:44px; }
    .comment-editor-footer { gap:4px; }
    .inline-compose .comment-editor-footer .editor-tools button { flex-basis:28px; min-width:28px; min-height:44px; }
    .comment-editor-footer .editor-tools-divider { display:none; }
    .comment-editor-footer .comment-editor-send { width:44px; min-height:44px; padding:0; }
    .comment-editor-send > span { display:none; }
    .inline-compose .comment-reply-context .icon-button { flex-basis:44px; width:44px; min-width:44px; height:44px; min-height:44px; }
    .comment-bubble { padding:8px 12px; }
    .comment-replies { margin-left:12px; padding-left:10px; }
    .comment-thread-group > .comment-reply-slot { margin-left:24px; }
    .comment-thread-item--reply { grid-template-columns:24px minmax(0, 1fr); gap:6px; }
    .comment-thread-item--reply .avatar { width:24px; height:24px; }
    .comment-bubble .content-menu summary { width:44px; height:44px; }
}
@media (max-width:360px) {
    .inline-compose .comment-editor-footer .editor-tools button { flex-basis:24px; min-width:24px; }
}
