/* template-parts/t10t-shorts/comments-style.css */

/* نظام التعليقات الجديد - تصميم يشبه الفيسبوك */
.t10t-comments-system {
    background: #fff;
    border-radius: 12px;
    padding: 0;
    margin: 30px 0;
    border: 1px solid #e4e6eb;
}

/* هيدر التعليقات */
.t10t-comments-header {
    padding: 20px 20px 0;
    border-bottom: 1px solid #e4e6eb;
}

.t10t-comments-title {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 20px;
}

.t10t-comments-title i {
    color: #65676b;
    font-size: 18px;
}

.t10t-comments-title h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    color: #1c1e21;
}

/* نموذج التعليق الجديد */
.t10t-new-comment-form {
    display: flex;
    gap: 12px;
    padding: 20px;
    border-bottom: 1px solid #e4e6eb;
}

.t10t-comment-form-avatar img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
}

.t10t-comment-form {
    flex: 1;
}

.t10t-comment-input-wrapper {
    background: #f0f2f5;
    border-radius: 20px;
    padding: 8px 12px;
    transition: all 0.2s;
}

.t10t-comment-input-wrapper:focus-within {
    background: #e4e6eb;
}

.t10t-comment-textarea {
    width: 100%;
    border: none;
    background: none;
    resize: none;
    font-size: 15px;
    line-height: 1.4;
    color: #1c1e21;
    min-height: 40px;
    max-height: 120px;
    padding: 0;
    outline: none;
    font-family: inherit;
}

.t10t-comment-textarea::placeholder {
    color: #65676b;
}

.t10t-comment-actions {
    display: flex;
    justify-content: flex-end;
    margin-top: 8px;
}

.t10t-submit-comment {
    background: #1b74e4;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 6px;
}

.t10t-submit-comment:hover:not(:disabled) {
    background: #166fe5;
    transform: translateY(-1px);
}

.t10t-submit-comment:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* مطالبة تسجيل الدخول */
.t10t-login-prompt {
    padding: 20px;
    border-bottom: 1px solid #e4e6eb;
    text-align: center;
}

.t10t-login-btn {
    background: #1b74e4;
    color: white;
    text-decoration: none;
    padding: 12px 24px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: all 0.2s;
}

.t10t-login-btn:hover {
    background: #166fe5;
    transform: translateY(-1px);
}

/* قائمة التعليقات */
.t10t-comments-list {
    max-height: 600px;
    overflow-y: auto;
}

.t10t-no-comments {
    text-align: center;
    padding: 60px 20px;
    color: #65676b;
}

.t10t-no-comments i {
    font-size: 48px;
    margin-bottom: 16px;
    display: block;
    opacity: 0.5;
}

.t10t-no-comments p {
    margin: 0 0 8px 0;
    font-size: 16px;
    font-weight: 600;
}

.t10t-no-comments span {
    font-size: 14px;
    opacity: 0.7;
}

/* التعليق الفردي */
.t10t-comment {
    display: flex;
    gap: 12px;
    padding: 16px 20px;
    border-bottom: 1px solid #f0f2f5;
    transition: background-color 0.2s;
}

.t10t-comment:hover {
    background: #fafbfb;
}

.t10t-comment:last-child {
    border-bottom: none;
}

.t10t-comment-avatar img,
.t10t-reply-avatar img {
    border-radius: 50%;
    object-fit: cover;
}

.t10t-comment-avatar img {
    width: 40px;
    height: 40px;
}

.t10t-comment-content {
    flex: 1;
    min-width: 0;
}

/* رأس التعليق */
.t10t-comment-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 4px;
}

.t10t-comment-author-info {
    display: flex;
    flex-direction: column;
}

.t10t-comment-author,
.t10t-reply-author {
    font-weight: 600;
    font-size: 14px;
    color: #1c1e21;
    margin-bottom: 2px;
}

.t10t-comment-time,
.t10t-reply-time {
    font-size: 12px;
    color: #65676b;
}

.t10t-comment-delete {
    background: none;
    border: none;
    color: #65676b;
    cursor: pointer;
    padding: 4px;
    border-radius: 4px;
    transition: all 0.2s;
    opacity: 0;
}

.t10t-comment:hover .t10t-comment-delete {
    opacity: 1;
}

.t10t-comment-delete:hover {
    background: #f0f2f5;
    color: #e41e3f;
}

/* نص التعليق */
.t10t-comment-text,
.t10t-reply-text {
    font-size: 14px;
    line-height: 1.4;
    color: #1c1e21;
    margin-bottom: 8px;
    word-wrap: break-word;
}

/* تفاعلات التعليق */
.t10t-comment-actions,
.t10t-reply-actions {
    display: flex;
    gap: 16px;
    align-items: center;
}

.t10t-comment-like,
.t10t-comment-reply {
    background: none;
    border: none;
    color: #65676b;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    padding: 6px 8px;
    border-radius: 4px;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 6px;
}

.t10t-comment-like:hover,
.t10t-comment-reply:hover {
    background: #f0f2f5;
}

.t10t-comment-like.t10t-liked {
    color: #f91880;
}

.t10t-comment-like.t10t-liked:hover {
    background: #ffe4ee;
}

/* نموذج الرد */
.t10t-reply-form {
    display: none;
    gap: 8px;
    margin-top: 12px;
    align-items: flex-start;
}

.t10t-reply-avatar img {
    width: 32px;
    height: 32px;
}

.t10t-reply-input-form {
    flex: 1;
}

.t10t-reply-input-wrapper {
    background: #f0f2f5;
    border-radius: 18px;
    padding: 8px 12px;
    transition: all 0.2s;
}

.t10t-reply-input-wrapper:focus-within {
    background: #e4e6eb;
}

.t10t-reply-textarea {
    width: 100%;
    border: none;
    background: none;
    resize: none;
    font-size: 14px;
    line-height: 1.4;
    color: #1c1e21;
    min-height: 20px;
    max-height: 80px;
    padding: 0;
    outline: none;
    font-family: inherit;
}

.t10t-reply-textarea::placeholder {
    color: #65676b;
}

.t10t-reply-actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    margin-top: 8px;
}

.t10t-submit-reply,
.t10t-cancel-reply {
    padding: 6px 12px;
    border: none;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.t10t-submit-reply {
    background: #1b74e4;
    color: white;
}

.t10t-submit-reply:hover {
    background: #166fe5;
}

.t10t-cancel-reply {
    background: #e4e6eb;
    color: #65676b;
}

.t10t-cancel-reply:hover {
    background: #d8dadf;
}

/* الردود */
.t10t-comment-replies {
    margin-top: 12px;
    padding-left: 12px;
    border-left: 2px solid #f0f2f5;
}

.t10t-reply {
    display: flex;
    gap: 8px;
    padding: 12px 0;
    border-bottom: 1px solid #f8f9fa;
}

.t10t-reply:last-child {
    border-bottom: none;
}

.t10t-reply:hover {
    background: #fafbfb;
}

.t10t-reply-content {
    flex: 1;
    min-width: 0;
}

.t10t-reply-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 2px;
}

/* تجاوبية */
@media (max-width: 768px) {
    .t10t-comments-system {
        margin: 20px 0;
        border-radius: 8px;
    }
    
    .t10t-comments-header,
    .t10t-new-comment-form {
        padding: 16px;
    }
    
    .t10t-comment {
        padding: 12px 16px;
    }
    
    .t10t-comment-avatar img {
        width: 36px;
        height: 36px;
    }
    
    .t10t-reply-avatar img {
        width: 28px;
        height: 28px;
    }
    
    .t10t-comment-replies {
        padding-left: 8px;
    }
    
    .t10t-comment-delete {
        opacity: 1;
    }
}

@media (max-width: 480px) {
    .t10t-new-comment-form {
        gap: 8px;
    }
    
    .t10t-comment-form-avatar {
        display: none;
    }
    
    .t10t-comment-actions {
        gap: 12px;
    }
    
    .t10t-comment-like,
    .t10t-comment-reply {
        font-size: 11px;
        padding: 4px 6px;
    }
    
    .t10t-reply-form {
        gap: 6px;
    }
    
    .t10t-reply-avatar {
        display: none;
    }
}

/* شريط التمرير */
.t10t-comments-list::-webkit-scrollbar {
    width: 6px;
}

.t10t-comments-list::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 3px;
}

.t10t-comments-list::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 3px;
}

.t10t-comments-list::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}