/* Custom styling for django-comments-xtd */
.comment {
    margin-bottom: 1.5rem;
}
.comment:last-child {
    margin-bottom: 0;
}

.comment-header {
    display: flex;
    align-items: center;
    margin-bottom: 0.5rem;
}

.comment .avatar {
    border-radius: 9999px;
    width: 2.5rem;
    height: 2.5rem;
    margin-right: 0.75rem;
    background-color: #E0F2FE; /* primary-100 */
    display: flex;
    align-items: center;
    justify-content: center;
    color: #0284C7; /* primary-600 */
    overflow: hidden;
}

.comment .comment-user {
    font-weight: 500;
    color: #1e293b; /* slate-800 */
}

.comment .comment-date {
    font-size: 0.75rem;
    color: #64748b; /* slate-500 */
    margin-left: 0.5rem;
}

.comment .comment-body {
    color: #334155; /* slate-700 */
    margin-bottom: 0.75rem;
    font-size: 0.875rem;
}

.comment-footer {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: 0.75rem;
    color: #64748b; /* slate-500 */
}

.comment-replies {
    margin-top: 1rem;
}

/* Style feedback & flagging indicators */
.comment-footer .text-red-600 {
    color: #dc2626;
}

/* Django Comments XTD Form Styles */
.form-react {
    margin-top: 1rem;
}

.form-group {
    margin-bottom: 1rem;
}

.form-control {
    width: 100%;
    border: 1px solid #cbd5e1; /* slate-300 */
    border-radius: 0.375rem;
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    padding: 0.5rem 0.75rem;
}
.form-control:focus {
    outline: none;
    box-shadow: 0 0 0 2px rgba(14, 165, 233, 0.3); /* primary-500 with opacity */
    border-color: #0EA5E9; /* primary-500 */
}

.form-group label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    color: #334155; /* slate-700 */
    margin-bottom: 0.25rem;
}

.btn-primary {
    display: inline-flex;
    align-items: center;
    border-radius: 0.375rem;
    border: 1px solid transparent;
    background-color: #0284C7; /* primary-600 */
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
    font-weight: 500;
    color: white;
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
}
.btn-primary:hover {
    background-color: #0369A1; /* primary-700 */
}
.btn-primary:focus {
    outline: none;
    box-shadow: 0 0 0 2px rgba(14, 165, 233, 0.3); /* primary-500 with opacity */
}

.btn-secondary {
    display: inline-flex;
    align-items: center;
    border-radius: 0.375rem;
    border: 1px solid #cbd5e1; /* slate-300 */
    background-color: white;
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
    font-weight: 500;
    color: #334155; /* slate-700 */
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
}
.btn-secondary:hover {
    background-color: #f8fafc; /* slate-50 */
}
.btn-secondary:focus {
    outline: none;
    box-shadow: 0 0 0 2px rgba(14, 165, 233, 0.3); /* primary-500 with opacity */
}

.text-muted {
    color: #64748b; /* slate-500 */
    font-size: 0.875rem;
}

/* Comment actions */
.comment-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.comment-action-link {
    color: #0284C7; /* primary-600 */
    font-size: 0.75rem;
    font-weight: 500;
}
.comment-action-link:hover {
    color: #075985; /* primary-800 */
}

/* Like/dislike buttons */
.comment-reaction-buttons {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.comment-like-btn, .comment-dislike-btn {
    display: flex;
    align-items: center;
}
.comment-like-btn:hover, .comment-dislike-btn:hover {
    color: #0284C7; /* primary-600 */
}

.badge {
    display: inline-flex;
    align-items: center;
    border-radius: 9999px;
    background-color: #E0F2FE; /* primary-100 */
    padding: 0.125rem 0.625rem;
    font-size: 0.75rem;
    font-weight: 500;
    color: #075985; /* primary-800 */
}

/* Flag button */
.comment-flag-btn {
    color: #dc2626; /* red-600 */
}
.comment-flag-btn:hover {
    color: #b91c1c; /* red-700 */
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    margin-top: 1rem;
}

.pagination .page-item {
    margin: 0 0.25rem;
}

.pagination .page-link {
    padding: 0.25rem 0.75rem;
    border: 1px solid #cbd5e1; /* slate-300 */
    border-radius: 0.25rem;
}
.pagination .page-link:hover {
    background-color: #f8fafc; /* slate-50 */
}

.pagination .active .page-link {
    background-color: #0284C7; /* primary-600 */
    color: white;
    border-color: #0284C7; /* primary-600 */
}

/* Modal for replies and flag dialogs */
.modal-content {
    background-color: white;
    border-radius: 0.5rem;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

.modal-header {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid #e2e8f0; /* slate-200 */
}

.modal-body {
    padding: 1rem;
}

.modal-footer {
    padding: 0.75rem 1rem;
    border-top: 1px solid #e2e8f0; /* slate-200 */
    display: flex;
    justify-content: flex-end;
    gap: 0.5rem;
}

/* Form styling */
#id_comment {
    width: 100%;
    min-height: 100px;
    padding: 0.75rem;
    border: 1px solid #e2e8f0; /* slate-200 */
    border-radius: 0.375rem;
    resize: vertical;
    font-family: inherit;
    font-size: 0.875rem;
    color: #334155; /* slate-700 */
    transition: border-color 0.2s ease-in-out;
}

#id_comment:focus {
    outline: none;
    border-color: #0EA5E9; /* primary-500 */
    box-shadow: 0 0 0 2px rgba(14, 165, 233, 0.3); /* primary-500 with opacity */
}

/* Checkbox styling */
#id_followup {
    margin-right: 0.5rem;
    border: 1px solid #e2e8f0;
    border-radius: 0.25rem;
    width: 1rem;
    height: 1rem;
    cursor: pointer;
}

/* Button styling */
.comment-form-container button {
    font-size: 0.875rem;
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 0.375rem;
    transition: all 0.2s ease-in-out;
}

/* Style the alert for errors */
.alert-danger {
    background-color: #fee2e2; /* red-100 */
    color: #b91c1c; /* red-700 */
    padding: 0.75rem 1rem;
    border-radius: 0.375rem;
    margin-bottom: 1rem;
}

/* Style the preview container */
.comment-preview {
    background-color: #f8fafc; /* slate-50 */
    border: 1px solid #e2e8f0; /* slate-200 */
    padding: 1rem;
    border-radius: 0.375rem;
    margin-bottom: 1rem;
}

.comment-preview-title {
    font-weight: 600;
    color: #0284C7; /* primary-600 */
    margin-bottom: 0.75rem;
    font-size: 0.875rem;
}

/* Comment form */
.comment-form-container {
    margin-top: 2rem;
}

.comment-form-container form {
    width: 100%;
}

.comment-form-container textarea {
    width: 100%;
    min-height: 8rem;
    padding: 0.75rem;
    border: 1px solid #ffffff; /* slate-200 */
    border-radius: 0.375rem;
    margin-bottom: 1rem;
}

.comment-form-container input[type="submit"] {
    background-color: #0284C7; /* primary-600 */
    color: white;
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 0.375rem;
    border: none;
    cursor: pointer;
}

.comment-form-container input[type="submit"]:hover {
    background-color: #0369a1; /* primary-700 */
}

/* Basic comment styling that works with django-comments-xtd defaults */
.comments-list {
    margin-bottom: 2rem;
}

/* Custom avatar style */
.comment .avatar {
    border-radius: 9999px;
    background-color: #E0F2FE; /* primary-100 */
    color: #0284C7; /* primary-600 */
    overflow: hidden;
}

/* Improved nested comment styling */
.comment-reply {
    margin-top: 1rem;
}

/* Form styling enhancements */
.comment-form-container {
    margin-top: 2rem;
    background-color: #f8fafc; /* slate-50 */
    padding: 1rem;
    border-radius: 0.375rem;
}

.comment-form-container form {
    width: 100%;
}

textarea#id_comment {
    width: 100%;
    min-height: 8rem;
    padding: 0.75rem;
    border: 1px solid #e2e8f0; /* slate-200 */
    border-radius: 0.375rem;
    margin-bottom: 1rem;
    font-family: inherit;
}

input[type="submit"].submit-post {
    background-color: #0284C7; /* primary-600 */
    color: white;
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 0.375rem;
    border: none;
    cursor: pointer;
}

input[type="submit"].submit-post:hover {
    background-color: #0369a1; /* primary-700 */
}

/* Links within comments */
.comment a {
    color: #0284C7; /* primary-600 */
}

.comment a:hover {
    color: #075985; /* primary-800 */
}

/* Basic comment styling to enhance django-comments-xtd defaults */

/* Comments list container */
.comments-list {
    margin-bottom: 2rem;
}

/* Comment form container styling */
.comment-form-container {
    background-color: #f8fafc; /* slate-50 */
    padding: 1rem;
    border-radius: 0.375rem;
    margin-top: 1rem;
}

/* Form field enhancements */
#id_comment {
    width: 100%;
    min-height: 8rem;
    padding: 0.75rem;
    border: 1px solid #e2e8f0; /* slate-200 */
    border-radius: 0.375rem;
    margin-bottom: 1rem;
    font-family: inherit;
}

/* Submit button styling */
.form-submit input[type="submit"] {
    background-color: #0284C7; /* primary-600 */
    color: white;
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 0.375rem;
    border: none;
    cursor: pointer;
}

.form-submit input[type="submit"]:hover {
    background-color: #0369a1; /* primary-700 */
}

/* Basic color enhancements for links */
.comment a {
    color: #0284C7; /* primary-600 */
}

.comment a:hover {
    color: #075985; /* primary-800 */
} 