/* Help Center Styles */

.help-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px;
    padding-top: 80px; /* Add space for language selector */
    min-height: 100vh;
}

.help-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid #e0e0e0;
    position: relative;
}

/* Override language selector position for help page */
.language-selector {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1001;
}

.help-header h1 {
    color: #2c3e50;
    margin: 0;
}

.back-link {
    color: #3498db;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s;
}

.back-link:hover {
    color: #2980b9;
}

/* Layout */
.help-layout {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 2rem;
}

/* Sidebar */
.help-sidebar {
    background: #f8f9fa;
    padding: 1.5rem;
    border-radius: 8px;
    height: fit-content;
    position: sticky;
    top: 20px;
}

.help-sidebar h2 {
    font-size: 1.2rem;
    color: #2c3e50;
    margin-bottom: 1rem;
}

.category-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.category-group {
    background: white;
    border-radius: 6px;
    padding: 1rem;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.category-group h3 {
    font-size: 1rem;
    color: #2c3e50;
    margin-bottom: 0.5rem;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.category-group h3:hover {
    color: #3498db;
}

.category-toggle {
    font-size: 0.8rem;
    transition: transform 0.3s;
}

.category-group.collapsed .category-toggle {
    transform: rotate(-90deg);
}

.topic-list {
    margin-left: 0.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
}

.category-group.collapsed .topic-list {
    display: none;
}

.topic-link {
    color: #5a6c7d;
    text-decoration: none;
    font-size: 0.9rem;
    padding: 0.3rem 0.5rem;
    border-radius: 4px;
    transition: all 0.2s;
}

.topic-link:hover {
    background: #e8f4fd;
    color: #3498db;
}

.topic-link.active {
    background: #3498db;
    color: white;
}

/* Main Content */
.help-content {
    background: white;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.article-content {
    min-height: 400px;
}

.welcome-message {
    text-align: center;
    padding: 3rem 0;
}

.welcome-message h2 {
    color: #2c3e50;
    margin-bottom: 1rem;
}

.welcome-message p {
    color: #5a6c7d;
    font-size: 1.1rem;
    margin-bottom: 2rem;
}

.popular-topics {
    margin-top: 3rem;
}

.popular-topics h3 {
    color: #2c3e50;
    margin-bottom: 1rem;
}

.popular-topics ul {
    list-style: none;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    max-width: 400px;
    margin: 0 auto;
}

.popular-topics a {
    color: #3498db;
    text-decoration: none;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    display: block;
    transition: all 0.3s;
}

.popular-topics a:hover {
    background: #e8f4fd;
}

/* Article Styles */
.article-content h1 {
    color: #2c3e50;
    border-bottom: 2px solid #e0e0e0;
    padding-bottom: 1rem;
    margin-bottom: 1.5rem;
}

.article-content h2 {
    color: #2c3e50;
    margin-top: 2rem;
    margin-bottom: 1rem;
}

.article-content h3 {
    color: #34495e;
    margin-top: 1.5rem;
    margin-bottom: 0.8rem;
}

.article-content p {
    line-height: 1.8;
    color: #4a5568;
    margin-bottom: 1rem;
}

.article-content ul,
.article-content ol {
    margin-bottom: 1rem;
    padding-left: 2rem;
}

.article-content li {
    margin-bottom: 0.5rem;
    line-height: 1.6;
    color: #4a5568;
}

.article-content code {
    background: #f4f4f4;
    padding: 0.2rem 0.4rem;
    border-radius: 4px;
    font-family: 'Courier New', monospace;
    font-size: 0.9em;
}

.article-content pre {
    background: #f4f4f4;
    padding: 1rem;
    border-radius: 6px;
    overflow-x: auto;
    margin-bottom: 1rem;
}

.article-content blockquote {
    border-left: 4px solid #3498db;
    padding-left: 1rem;
    margin: 1rem 0;
    color: #5a6c7d;
    font-style: italic;
}

/* Feedback Section */
.feedback-section {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid #e0e0e0;
    text-align: center;
}

.feedback-section h3 {
    color: #2c3e50;
    margin-bottom: 1rem;
}

.feedback-buttons {
    display: flex;
    justify-content: center;
    gap: 1rem;
}

.feedback-btn {
    padding: 0.5rem 1.5rem;
    border: 2px solid #ddd;
    background: white;
    border-radius: 6px;
    cursor: pointer;
    font-size: 1rem;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.feedback-btn:hover {
    border-color: #3498db;
    transform: translateY(-2px);
}

.feedback-btn.helpful:hover {
    background: #e8f5e9;
    border-color: #4caf50;
}

.feedback-btn.not-helpful:hover {
    background: #ffebee;
    border-color: #f44336;
}

.feedback-message {
    margin-top: 1rem;
    color: #4caf50;
    font-weight: 500;
}

/* Related Articles */
.related-section {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid #e0e0e0;
}

.related-section h3 {
    color: #2c3e50;
    margin-bottom: 1rem;
}

#related-list {
    list-style: none;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

#related-list a {
    color: #3498db;
    text-decoration: none;
    padding: 0.5rem;
    border-radius: 4px;
    display: block;
    transition: all 0.3s;
}

#related-list a:hover {
    background: #e8f4fd;
}

/* Loading State */
.loading {
    text-align: center;
    padding: 3rem;
    color: #5a6c7d;
}

.loading::after {
    content: '...';
    animation: dots 1.5s steps(4, end) infinite;
}

@keyframes dots {
    0%, 20% { content: ''; }
    40% { content: '.'; }
    60% { content: '..'; }
    80%, 100% { content: '...'; }
}

/* Error State */
.error-message {
    background: #fee;
    border: 1px solid #fcc;
    color: #c33;
    padding: 1rem;
    border-radius: 6px;
    text-align: center;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .help-layout {
        grid-template-columns: 1fr;
    }
    
    .help-sidebar {
        position: relative;
        top: 0;
        margin-bottom: 2rem;
    }
    
    .help-header {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
    
    .feedback-buttons {
        flex-direction: column;
    }
    
    .popular-topics ul {
        max-width: 100%;
    }
}