/* Comments and Social Sharing Styles */

/* Comments Section */
.comments-section {
    margin-top: 20px;
    border-top: 1px solid #e0e0e0;
    padding-top: 20px;
}

.comments-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.comments-title {
    font-size: 18px;
    font-weight: 500;
    color: #2c3e50;
    margin: 0;
}

.comments-count {
    background-color: #3498db;
    color: #fff;
    border-radius: 20px;
    padding: 2px 8px;
    font-size: 14px;
    margin-left: 10px;
}

/* Comment Form */
.comment-form {
    background-color: #f8f9fa;
    border-radius: 4px;
    padding: 15px;
    margin-bottom: 20px;
}

.comment-form-title {
    font-size: 16px;
    font-weight: 500;
    margin: 0 0 15px 0;
    color: #2c3e50;
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 500;
    color: #34495e;
}

.form-control {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-family: inherit;
    font-size: 14px;
    transition: border-color 0.3s, box-shadow 0.3s;
}

.form-control:focus {
    border-color: #3498db;
    box-shadow: 0 0 0 2px rgba(52, 152, 219, 0.2);
    outline: none;
}

textarea.form-control {
    min-height: 100px;
    resize: vertical;
}

.submit-comment {
    background-color: #3498db;
    color: #fff;
    border: none;
    border-radius: 4px;
    padding: 10px 15px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.3s;
}

.submit-comment:hover {
    background-color: #2980b9;
}

.submit-comment:disabled {
    background-color: #95a5a6;
    cursor: not-allowed;
}

/* Comments List */
.comments-list {
    margin-top: 20px;
}

.comment {
    background-color: #fff;
    border-radius: 4px;
    padding: 15px;
    margin-bottom: 15px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.comment-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
}

.comment-author {
    font-weight: 500;
    color: #2c3e50;
}

.comment-date {
    color: #7f8c8d;
    font-size: 12px;
}

.comment-body {
    color: #34495e;
    line-height: 1.5;
    white-space: pre-line;
}

.no-comments {
    text-align: center;
    color: #7f8c8d;
    padding: 20px;
    background-color: #f8f9fa;
    border-radius: 4px;
}

.comments-pagination {
    display: flex;
    justify-content: center;
    margin-top: 20px;
}

.pagination-button {
    background-color: #fff;
    border: 1px solid #ddd;
    padding: 5px 10px;
    margin: 0 5px;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s;
}

.pagination-button:hover {
    background-color: #f5f5f5;
}

.pagination-button.active {
    background-color: #3498db;
    color: #fff;
    border-color: #3498db;
}

.pagination-button.disabled {
    color: #ccc;
    cursor: not-allowed;
}

/* Social Sharing */
.social-sharing {
    margin-top: 20px;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.social-sharing-title {
    font-size: 16px;
    font-weight: 500;
    margin: 0 0 10px 0;
    color: #2c3e50;
    width: 100%;
}

.share-button {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 8px 15px;
    border-radius: 4px;
    color: #fff;
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
    transition: opacity 0.3s;
    cursor: pointer;
}

.share-button:hover {
    opacity: 0.9;
}

.share-button i {
    margin-right: 5px;
    font-size: 16px;
}

.share-facebook {
    background-color: #3b5998;
}

.share-twitter {
    background-color: #1da1f2;
}

.share-linkedin {
    background-color: #0077b5;
}

.share-whatsapp {
    background-color: #25d366;
}

.share-email {
    background-color: #7f8c8d;
}

/* Comment Form Validation */
.form-control.is-invalid {
    border-color: #e74c3c;
}

.invalid-feedback {
    color: #e74c3c;
    font-size: 12px;
    margin-top: 5px;
    display: none;
}

.form-control.is-invalid + .invalid-feedback {
    display: block;
}

/* Comment Status Messages */
.comment-status {
    padding: 10px 15px;
    border-radius: 4px;
    margin-bottom: 15px;
    display: none;
}

.comment-status.success {
    background-color: #d4edda;
    color: #155724;
    border-left: 4px solid #28a745;
}

.comment-status.error {
    background-color: #f8d7da;
    color: #721c24;
    border-left: 4px solid #dc3545;
}

/* Loading Indicator for Comments */
.comments-loading {
    text-align: center;
    padding: 20px;
    color: #7f8c8d;
}

.comments-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(52, 152, 219, 0.3);
    border-radius: 50%;
    border-top-color: #3498db;
    animation: spin 1s linear infinite;
    margin-right: 10px;
}

/* Responsive Styles */
@media (max-width: 768px) {
    .social-sharing {
        justify-content: center;
    }
    
    .share-button {
        padding: 8px 12px;
        font-size: 13px;
    }
}

/* Font Awesome Icons (CDN will be included in HTML) */
.fa {
    display: inline-block;
    font: normal normal normal 14px/1 FontAwesome;
    font-size: inherit;
    text-rendering: auto;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}
