/* ==========================================
   Feature: Require JS Warning
   ========================================== */
.mutyun-js-warning {
    color: #b91c1c;
    font-weight: 700;
    margin: .75em 0;
    padding: 10px;
    border: 1px solid #b91c1c;
    background-color: #fff5f5;
    border-radius: 4px;
}

/* ==========================================
   Feature: Comment Customizer & Popout
   ========================================== */
.st-comment-body {
    position: relative;
    border: none;
    background: transparent;
    padding: 0;
    margin-bottom: 1em;
}

.st-comment-meta {
    font-size: 0.9em;
    color: #666;
    margin-bottom: 8px;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: baseline;
}
.st-comment-author img.avatar {
    vertical-align: middle;
    border-radius: 50%;
    margin-right: 6px;
}
.commentID, .trip {
    font-family: monospace;
    font-weight: bold;
    color: #444;
}

/* Reply Link Wrapper (for Non-Inline mode) */
.reply-link {
    text-align: right;
    margin-top: 8px;
}

/* Reply Button (Restored to Text Link Style) */
.mutyun-reply-btn {
    display: inline;
    padding: 0;
    margin: 0;
    background: transparent;
    border: none;
    box-shadow: none;
    border-radius: 0;
    color: #0073aa; /* WordPress Link Color */
    text-decoration: none;
    font-size: 0.9em;
    cursor: pointer;
}
.mutyun-reply-btn:hover {
    background: transparent;
    color: #0096cc;
    text-decoration: underline;
}

/* Self Reply Warning Icon */
.mutyun-self-reply-warning {
    display: inline-block;
    width: 16px;
    height: 16px;
    line-height: 16px;
    text-align: center;
    color: #fff;
    background-color: #dc3545; /* Default Red */
    border-radius: 50%;
    font-size: 11px;
    font-weight: bold;
    cursor: help;
    margin-right: 4px;
    vertical-align: middle;
}

/* Children List */
.mutyun-children {
    margin-top: 10px;
    padding: 8px;
    background: rgba(0,0,0,0.03);
    border-radius: 4px;
    font-size: 0.85em;
}
.mutyun-children-title {
    font-weight: bold;
    margin-bottom: 4px;
}
.mutyun-children-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

/* View Mode Toggle Bar */
.comment-view-toggle {
    margin: 1em 0;
    padding: 8px;
    background: #f7f7f7;
    border-radius: 4px;
    display: flex;
    gap: 8px;
    align-items: center;
    font-size: 0.9em;
}
.comment-view-toggle button {
    padding: 4px 10px;
    border: 1px solid #ccc;
    background: #fff;
    border-radius: 3px;
    cursor: pointer;
}
.comment-view-toggle button.active {
    background: #0073aa;
    color: #fff;
    border-color: #0073aa;
}

/* Tree Mode Styles */
body.comment-tree-mode ul.pseudo-tree-children {
    margin-left: var(--cc-tree-indent, 20px);
    border-left: 2px solid #eee;
    padding-left: 10px;
    list-style: none;
    margin-bottom: 1em;
}
body.comment-tree-mode .mutyun-children {
    display: none !important;
}

/* Popout (Popup Card) */
.mutyun-popout {
    position: absolute;
    z-index: 99999;
    /* Default mapping, overridden by PHP injected styles */
    background-color: var(--cc-bg, #ffffff);
    color: var(--cc-text, #333333);
    border: var(--cc-bd-w, 1px) solid var(--cc-bd, #999999);
    border-radius: var(--cc-bd-r, 4px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, var(--cc-sh, 0.2));
    
    padding: 12px;
    max-width: 400px;
    width: 90vw;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s;
    pointer-events: none;
}

/* Specific styling for Self-Reply Warning Popup */
.mutyun-popout.mutyun-warning {
    background-color: var(--sr-bg, #fff5f5);
    color: var(--sr-text, #b91c1c);
    border: var(--sr-bd-w, 1px) solid var(--sr-bd, #cc0000);
    border-radius: var(--sr-bd-r, 4px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, var(--sr-sh, 0.2));
}

.mutyun-popout.is-visible {
    opacity: 1;
    visibility: visible;
}
.mutyun-popout .st-comment-body {
    margin: 0;
    padding: 0;
    background: transparent;
}
.mutyun-popout .st-comment-meta {
    border-bottom: 1px solid #eee;
    padding-bottom: 6px;
    margin-bottom: 6px;
}
