/* ==========================================================
   WANGLE 2.5 INTERACTION SYSTEM
   Compact threaded comments + live activity indicator
========================================================== */

.activity-button {
    position: relative;
}

.activity-icon {
    display: inline-block;
}

.activity-dot {
    position: absolute;
    top: 3px;
    right: 3px;
    width: 9px;
    height: 9px;
    background: #d90429;
    border: 2px solid #fff;
    border-radius: 50%;
    box-sizing: content-box;
    pointer-events: none;
}

.activity-dot.hidden {
    display: none;
}

.comments-wrap {
    margin-top: 8px;
    padding-top: 9px;
    border-top: 1px solid #ededed;
}

.comments-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.comments-empty {
    padding: 8px 4px;
    font-size: .86rem;
    opacity: .7;
}

.comment-thread-node {
    position: relative;
    transition: background .18s ease;
}

.comment-depth-1 {
    margin-left: 24px;
}

.comment-depth-2 {
    margin-left: 48px;
}

.comment-depth-3 {
    margin-left: 68px;
}

.comment-thread-node.comment-highlight {
    background: rgba(255, 218, 68, .18);
    border-radius: 12px;
}

.comment-item {
    display: flex;
    gap: 7px;
    align-items: flex-start;
}

.comment-avatar {
    width: 28px;
    height: 28px;
    min-width: 28px;
    padding: 0;
    overflow: hidden;
    border: 0;
    border-radius: 50%;
    background: #181818;
    color: #fff;
    font-size: .72rem;
    font-weight: 800;
    cursor: pointer;
}

.comment-avatar img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.comment-content {
    flex: 1;
    min-width: 0;
}

.comment-body {
    display: inline-block;
    max-width: 100%;
    background: #f2f1ed;
    border-radius: 12px;
    padding: 6px 9px;
}

.comment-name {
    display: block;
    margin: 0 0 1px;
    padding: 0;
    border: 0;
    background: transparent;
    color: inherit;
    font-size: .90rem;
    font-weight: 600;
    text-align: left;
    cursor: pointer;
}

.comment-text {
    font-size: .73rem;
    line-height: 1.28;
    overflow-wrap: anywhere;
}

.comment-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 2px 0 0 7px;
}

.comment-action-button {
    padding: 1px 0;
    border: 0;
    background: transparent;
    color: #5a5a5a;
    font-size: .7rem;
    font-weight: 700;
    cursor: pointer;
}

.comment-action-button:hover {
    text-decoration: underline;
}

.comment-delete-button {
    color: #a11e2b;
}

.comment-form {
    display: flex;
    gap: 7px;
    margin-top: 9px;
}

.comment-form input,
.comment-reply-controls input {
    flex: 1;
    min-width: 0;
    border: 1px solid #d8d7d2;
    border-radius: 999px;
    padding: 8px 12px;
    font-size: .88rem;
}

.comment-form button,
.comment-reply-controls button[type="submit"] {
    border: 0;
    border-radius: 999px;
    padding: 0 14px;
    background: #181818;
    color: #fff;
    font-size: .8rem;
    font-weight: 700;
    cursor: pointer;
}

.comment-reply-form {
    margin: 5px 0 3px 35px;
}

.comment-reply-label {
    margin-bottom: 4px;
    font-size: .7rem;
    color: #666;
}

.comment-reply-controls {
    display: flex;
    gap: 6px;
}

.comment-reply-cancel {
    border: 0;
    background: transparent;
    color: #666;
    font-size: .72rem;
    font-weight: 700;
    cursor: pointer;
}

.notification-identity {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    width: 100%;
}

.notification-avatar {
    width: 30px;
    height: 30px;
    min-width: 30px;
    border-radius: 50%;
    object-fit: cover;
}

.notification-copy {
    display: flex;
    flex: 1;
    min-width: 0;
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
}

@media (max-width: 640px) {
    .comment-depth-1 {
        margin-left: 16px;
    }

    .comment-depth-2 {
        margin-left: 30px;
    }

    .comment-depth-3 {
        margin-left: 42px;
    }

    .comment-avatar {
        width: 26px;
        height: 26px;
        min-width: 26px;
    }

    .comment-body {
        padding: 5px 8px;
    }

    .comment-reply-form {
        margin-left: 31px;
    }
}


/* ==========================================================
   WANGLE 2.5 COMMENT OVERRIDES
   Force threaded comment layout above legacy Wangle styles
========================================================== */

.comments-wrap,
.comments-list,
.comment-thread-node,
.comment-item,
.comment-content,
.comment-body,
.comment-actions,
.comment-reply-form,
.comment-reply-controls {
    background-image: none !important;
    box-shadow: none !important;
}

.comment-thread-node {
    width: auto !important;
    min-height: 0 !important;
    padding: 0 !important;
}

.comment-item {
    width: auto !important;
    min-height: 0 !important;
    padding: 0 !important;
    margin: 0 !important;
    border: 0 !important;
    background: transparent !important;
}

.comment-content {
    width: auto !important;
    min-height: 0 !important;
    background: transparent !important;
}

.comment-body {
    width: auto !important;
    min-height: 0 !important;
    margin: 0 !important;
    background: #f2f1ed !important;
    font-size: .76rem;
}

.comment-avatar {
    flex: 0 0 28px !important;
    min-width: 28px !important;
    max-width: 28px !important;
    min-height: 28px !important;
    max-height: 28px !important;
}

.comment-actions {
    width: auto !important;
    min-height: 0 !important;
    background: transparent !important;
}

.comment-action-button,
.comment-delete-button {
    appearance: none !important;
    -webkit-appearance: none !important;

    width: auto !important;
    min-width: 0 !important;
    height: auto !important;
    min-height: 0 !important;

    padding: 1px 0 !important;
    margin: 0 !important;

    border: 0 !important;
    border-radius: 0 !important;

    background: transparent !important;
    box-shadow: none !important;
}

.comment-reply-form {
    width: auto !important;
    min-height: 0 !important;
    padding: 0 !important;
    background: transparent !important;
}

.comment-reply-controls {
    width: auto !important;
    min-height: 0 !important;
    background: transparent !important;
}

.comment-reply-controls input {
    height: 34px !important;
    min-height: 34px !important;
}

.comment-reply-controls button[type="submit"] {
    height: 34px !important;
    min-height: 34px !important;
}

.comment-form {
    width: 100% !important;
    min-height: 0 !important;
    background: transparent !important;
}

.comment-form input {
    height: 38px !important;
    min-height: 38px !important;
}

.comment-form button {
    height: 38px !important;
    min-height: 38px !important;
}

@media (max-width: 640px) {
    .comment-avatar {
        flex-basis: 26px !important;
        min-width: 26px !important;
        max-width: 26px !important;
        min-height: 26px !important;
        max-height: 26px !important;
    }
}
