/* Collaboration Section Styles */
.collaboration-section {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 2px solid var(--border-color, #3a3a3a);
}

/* Edit Actions */
.edit-actions {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.edit-button,
.report-button {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.25rem;
    background: linear-gradient(135deg, #2a2a2a 0%, #1a1a1a 100%);
    color: #c9a961;
    text-decoration: none;
    border: 1px solid #3a3a3a;
    border-radius: 4px;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.edit-button:before,
.report-button:before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(201, 169, 97, 0.2), transparent);
    transition: left 0.5s ease;
}

.edit-button:hover,
.report-button:hover {
    background: linear-gradient(135deg, #3a3a3a 0%, #2a2a2a 100%);
    border-color: #c9a961;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(201, 169, 97, 0.2);
}

.edit-button:hover:before,
.report-button:hover:before {
    left: 100%;
}

.edit-button svg,
.report-button svg {
    width: 16px;
    height: 16px;
}

/* Discussion Section */
.discussion-section {
    margin-top: 2rem;
}

.discussion-section h3 {
    color: #c9a961;
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
    font-family: 'Cinzel', serif;
}

.discussion-intro {
    color: #999;
    margin-bottom: 1.5rem;
    font-size: 0.95rem;
}

#giscus-container {
    min-height: 200px;
    padding: 1rem;
    background: #1a1a1a;
    border: 1px solid #2a2a2a;
    border-radius: 8px;
}

/* Giscus Theme Overrides */
#giscus-container .giscus {
    max-width: 100%;
}

#giscus-container .giscus-frame {
    border: none !important;
    color-scheme: dark;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .edit-actions {
        flex-direction: column;
    }
    
    .edit-button,
    .report-button {
        width: 100%;
        justify-content: center;
    }
}

/* Dark Souls Theme Integration */
.collaboration-section {
    position: relative;
}

.collaboration-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 2px;
    background: linear-gradient(90deg, transparent, #c9a961, transparent);
}

/* Contribution Guidelines Link */
.contribution-link {
    display: inline-block;
    margin-top: 1rem;
    color: #888;
    font-size: 0.85rem;
    text-decoration: none;
    transition: color 0.3s ease;
}

.contribution-link:hover {
    color: #c9a961;
}

/* Loading State for Comments */
#giscus-container.loading {
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0.6;
}

#giscus-container.loading::after {
    content: 'Loading comments...';
    color: #666;
    font-style: italic;
}

/* Success/Error Messages */
.collaboration-message {
    padding: 0.75rem 1rem;
    margin: 1rem 0;
    border-radius: 4px;
    font-size: 0.9rem;
}

.collaboration-message.success {
    background: rgba(76, 175, 80, 0.1);
    border: 1px solid rgba(76, 175, 80, 0.3);
    color: #81c784;
}

.collaboration-message.error {
    background: rgba(244, 67, 54, 0.1);
    border: 1px solid rgba(244, 67, 54, 0.3);
    color: #e57373;
}

.collaboration-message.info {
    background: rgba(33, 150, 243, 0.1);
    border: 1px solid rgba(33, 150, 243, 0.3);
    color: #64b5f6;
}

/* Contribute Page Styles */
.contribute-options {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}

.contribute-card {
    background: #1a1a1a;
    border: 1px solid #2a2a2a;
    border-radius: 8px;
    padding: 1.5rem;
    transition: all 0.3s ease;
}

.contribute-card:hover {
    transform: translateY(-4px);
    border-color: #c9a961;
    box-shadow: 0 8px 24px rgba(201, 169, 97, 0.15);
}

.contribute-card h3 {
    color: #c9a961;
    margin-top: 0;
    margin-bottom: 0.75rem;
}

.contribute-card p {
    color: #aaa;
    margin-bottom: 1rem;
    font-size: 0.95rem;
}

.contribute-card .btn {
    display: inline-block;
    padding: 0.5rem 1rem;
    background: linear-gradient(135deg, #2a2a2a, #1a1a1a);
    color: #c9a961;
    text-decoration: none;
    border: 1px solid #3a3a3a;
    border-radius: 4px;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.contribute-card .btn:hover {
    background: linear-gradient(135deg, #3a3a3a, #2a2a2a);
    border-color: #c9a961;
}

.needs-list {
    list-style: none;
    padding: 0;
    margin: 1rem 0;
}

.needs-list li {
    padding: 0.75rem;
    margin-bottom: 0.5rem;
    background: #1a1a1a;
    border-left: 3px solid #c9a961;
    border-radius: 2px;
    color: #ddd;
    transition: all 0.3s ease;
}

.needs-list li:hover {
    background: #2a2a2a;
    transform: translateX(4px);
}

/* Category Collaboration Section */
.category-collaboration-section {
    margin-top: 2rem;
    padding: 2rem;
    background: linear-gradient(135deg, #1a1a1a 0%, #0a0a0a 100%);
    border: 1px solid #2a2a2a;
    border-radius: 8px;
    position: relative;
}

.category-collaboration-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 2px;
    background: linear-gradient(90deg, transparent, #c9a961, transparent);
}

.category-edit-actions {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
    justify-content: center;
}

.add-new-button,
.request-button,
.cms-button {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.25rem;
    background: linear-gradient(135deg, #2a2a2a 0%, #1a1a1a 100%);
    color: #c9a961;
    text-decoration: none;
    border: 1px solid #3a3a3a;
    border-radius: 6px;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    min-width: 140px;
    justify-content: center;
}

.add-new-button {
    background: linear-gradient(135deg, #4a4a2a 0%, #3a3a1a 100%);
    border-color: #c9a961;
}

.add-new-button:hover {
    background: linear-gradient(135deg, #5a5a3a 0%, #4a4a2a 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(201, 169, 97, 0.3);
}

.request-button:hover,
.cms-button:hover {
    background: linear-gradient(135deg, #3a3a3a 0%, #2a2a2a 100%);
    border-color: #c9a961;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(201, 169, 97, 0.2);
}

.add-new-button svg,
.request-button svg,
.cms-button svg {
    width: 16px;
    height: 16px;
}

.category-help {
    text-align: center;
    padding: 1rem;
    background: rgba(201, 169, 97, 0.05);
    border-radius: 4px;
    border: 1px solid rgba(201, 169, 97, 0.2);
}

.category-help-text {
    color: #aaa;
    margin: 0;
    font-size: 0.95rem;
}

.category-help-text strong {
    color: #c9a961;
}

/* Mobile responsive for category collaboration */
@media (max-width: 768px) {
    .category-edit-actions {
        flex-direction: column;
        align-items: stretch;
    }
    
    .add-new-button,
    .request-button,
    .cms-button {
        width: 100%;
        min-width: auto;
    }
    
    .category-collaboration-section {
        padding: 1.5rem;
        margin-top: 1.5rem;
    }
}