* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #3b82f6;
    --primary-dark: #2563eb;
    --secondary-color: #64748b;
    --accent-color: #8b5cf6;
    --success-color: #10b981;
    --warning-color: #f59e0b;
    --error-color: #ef4444;
    --background-color: #ffffff;
    --background-secondary: #f8fafc;
    --background-tertiary: #f1f5f9;
    --text-primary: #90b4ed;
    --text-secondary: #64748b;
    --text-muted: #94a3b8;
    --border-color: #e2e8f0;
    --border-light: #f1f5f9;
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1);
    --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1);
    --border-radius: 0.5rem;
    --border-radius-lg: 0.75rem;
    --transition: all 0.2s ease-in-out;
}

[data-theme="dark"] {
    --background-color: #0f172a;
    --background-secondary: #1e293b;
    --background-tertiary: #334155;
    --text-primary: #ffffff;
    --text-secondary: #ffffff;
    --text-muted: #ffffff;
    --border-color: #334155;
    --border-light: #1e293b;
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.2);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.3);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.4);
    --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.5);
    /* Ensure search bar text inputs, blog search, thread inputs, and filter selects are white in dark mode */
    .search-box input,
    .reply-input,
    .form-textarea,
    .filter-selects select {
        color: #ffffff;
    }
    /* Ensure notification text is black in dark mode */
    .notification-content span {
        color: #000000;
    }
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: var(--text-primary);
    background-color: var(--background-color);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* Navigation */
.navbar {
    background: var(--background-color);
    border-bottom: 1px solid var(--border-light);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    backdrop-filter: blur(10px);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 4rem;
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-primary);
}

.nav-brand i {
    color: var(--primary-color);
    font-size: 1.5rem;
}

.nav-links {
    display: flex;
    gap: 2rem;
}

.nav-link {
    text-decoration: none;
    color: var(--text-secondary);
    font-weight: 500;
    transition: var(--transition);
    padding: 0.5rem 0;
    border-bottom: 2px solid transparent;
}

.nav-link:hover,
.nav-link.active {
    color: var(--primary-color);
    border-bottom-color: var(--primary-color);
}

.nav-auth {
    display: flex;
    gap: 0.75rem;
    align-items: center;
}

.theme-toggle {
    background: transparent;
    border: 1px solid var(--border-color);
    border-radius: 50%;
    width: 2.5rem;
    height: 2.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
    color: var(--text-secondary);
}

.theme-toggle:hover {
    background: var(--background-secondary);
    color: var(--primary-color);
    border-color: var(--primary-color);
}

.mobile-menu-btn {
    display: none;
    cursor: pointer;
    padding: 0.5rem;
    font-size: 1.25rem;
    color: var(--text-secondary);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
    font-weight: 500;
    border: 1px solid transparent;
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    white-space: nowrap;
}

.btn-primary {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.btn-primary:hover {
    background: var(--primary-dark);
    border-color: var(--primary-dark);
}

.btn-outline {
    background: transparent;
    color: var(--text-primary);
    border-color: var(--border-color);
}

.btn-outline:hover {
    background: var(--background-secondary);
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.btn-large {
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
}

.btn-small {
    padding: 0.25rem 0.75rem;
    font-size: 0.75rem;
}

.btn-block {
    width: 100%;
}

/* Sections */
.section {
    display: none;
    min-height: 100vh;
    padding-top: 4rem;
}

.section.active {
    display: block;
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, #1e293b 0%, #3730a3 50%, #1e293b 100%);
    color: white;
    padding: 6rem 0;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.3);
    z-index: 1;
}

.hero-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    position: relative;
    z-index: 2;
}

.hero h1 {
    font-size: 3.5rem;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1.5rem;
}

.highlight {
    color: #60a5fa;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: #e2e8f0;
    margin-bottom: 2rem;
    line-height: 1.6;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    margin-bottom: 3rem;
}

.hero-stats {
    display: flex;
    gap: 2rem;
}

.stat {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
}

.stat i {
    color: #60a5fa;
}

/* Code Window */
.hero-visual {
    display: flex;
    justify-content: center;
}

.code-window {
    background: rgba(30, 41, 59, 0.9);
    border-radius: var(--border-radius-lg);
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    overflow: hidden;
    width: 100%;
    max-width: 500px;
}

.window-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem;
    background: rgba(15, 23, 42, 0.8);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.window-controls {
    display: flex;
    gap: 0.5rem;
}

.control {
    width: 0.75rem;
    height: 0.75rem;
    border-radius: 50%;
}

.control.red {
    background: #ef4444;
}

.control.yellow {
    background: #f59e0b;
}

.control.green {
    background: #10b981;
}

.live-indicator {
    color: #10b981;
    font-size: 0.875rem;
}

.code-content {
    padding: 1.5rem;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 0.875rem;
    line-height: 1.6;
}

.code-line {
    margin-bottom: 0.25rem;
}

.code-line.comment {
    color: #64748b;
}

.code-line.indent {
    margin-left: 1rem;
}

.function {
    color: #fbbf24;
}

.param {
    color: #60a5fa;
}

.string {
    color: #34d399;
}

/* Features Section */
.features {
    padding: 6rem 0;
    background: var(--background-color);
}

.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-header h2 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.section-header p {
    font-size: 1.125rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
}

.feature-card {
    background: var(--background-color);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius-lg);
    padding: 2rem;
    transition: var(--transition);
    box-shadow: var(--shadow-sm);
}

.feature-card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-2px);
}

.feature-icon {
    font-size: 3rem;
    margin-bottom: 1.5rem;
}

.feature-card h3 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.feature-card p {
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

.feature-list {
    list-style: none;
}

.feature-list li {
    color: var(--text-secondary);
    font-size: 0.875rem;
    margin-bottom: 0.5rem;
}

/* Learning Paths Preview */
.learning-preview {
    padding: 6rem 0;
    background: var(--background-secondary);
}

.paths-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
}

.path-card {
    background: var(--background-color);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius-lg);
    overflow: hidden;
    transition: var(--transition);
    box-shadow: var(--shadow-sm);
}

.path-card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-2px);
}

.path-image {
    height: 200px;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
}

.path-image.web-dev {
    background: linear-gradient(135deg, #3b82f6, #8b5cf6);
}

.path-image.python {
    background: linear-gradient(135deg, #10b981, #3b82f6);
}

.path-image.ai-ml {
    background: linear-gradient(135deg, #8b5cf6, #ec4899);
}

.path-content {
    padding: 1.5rem;
}

.path-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1rem;
}

.path-header h3 {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
}

.badge {
    padding: 0.25rem 0.75rem;
    font-size: 0.75rem;
    font-weight: 500;
    border-radius: 1rem;
}

.badge-green {
    background: rgba(16, 185, 129, 0.1);
    color: #059669;
}

.badge-blue {
    background: rgba(59, 130, 246, 0.1);
    color: #2563eb;
}

.badge-red {
    background: rgba(239, 68, 68, 0.1);
    color: #dc2626;
}

.badge-secondary {
    background: var(--background-secondary);
    color: var(--text-secondary);
}

.path-content p {
    color: var(--text-secondary);
    margin-bottom: 1rem;
    line-height: 1.6;
}

.path-meta {
    display: flex;
    gap: 1rem;
    margin-bottom: 1rem;
    font-size: 0.875rem;
    color: var(--text-muted);
}

.progress-bar {
    background: var(--background-secondary);
    height: 0.5rem;
    border-radius: 0.25rem;
    margin-bottom: 1.5rem;
    overflow: hidden;
}

.progress-fill {
    background: var(--primary-color);
    height: 100%;
    transition: width 0.3s ease;
}

/* Call to Action */
.cta {
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    color: white;
    padding: 6rem 0;
    text-align: center;
}

.cta h2 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.cta p {
    font-size: 1.125rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

.cta-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
}

.cta .btn-outline {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border-color: rgba(255, 255, 255, 0.3);
}

.cta .btn-outline:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.5);
}

/* Page Header */
.page-header {
    text-align: center;
    padding: 4rem 0 3rem;
}

.page-header h1 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.page-header p {
    font-size: 1.125rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto;
}

/* Filters */
.filters-card {
    background: var(--background-color);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius-lg);
    padding: 1.5rem;
    margin-bottom: 2rem;
    display: flex;
    gap: 1rem;
    align-items: center;
    flex-wrap: wrap;
}

.search-box {
    position: relative;
    flex: 1;
    min-width: 250px;
}

.search-box i {
    position: absolute;
    left: 0.75rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
}

.search-box input {
    width: 100%;
    padding: 0.75rem 0.75rem 0.75rem 2.5rem;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    font-size: 0.875rem;
    background: var(--background-color);
    transition: var(--transition);
}

.search-box input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.filter-selects {
    display: flex;
    gap: 0.75rem;
}

.filter-selects select {
    padding: 0.75rem;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    background: var(--background-color);
    font-size: 0.875rem;
    cursor: pointer;
}

.results-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.sort-options {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Playground */
.playground-tabs {
    display: flex;
    gap: 0.25rem;
    margin-bottom: 2rem;
    border-bottom: 1px solid var(--border-color);
}

.tab-btn {
    padding: 0.75rem 1.5rem;
    background: transparent;
    border: none;
    border-bottom: 2px solid transparent;
    color: var(--text-secondary);
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
}

.tab-btn.active,
.tab-btn:hover {
    color: var(--primary-color);
    border-bottom-color: var(--primary-color);
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

.editor-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    height: 600px;
}

.editor-panel,
.output-panel {
    background: var(--background-color);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius-lg);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.editor-header,
.output-header {
    background: var(--background-secondary);
    padding: 1rem;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.editor-title {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-weight: 500;
}

.editor-input {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid var(--border-color);
}

.editor-input input {
    width: 100%;
    padding: 0.5rem;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    font-size: 0.875rem;
}

.code-editor {
    flex: 1;
    padding: 1rem;
}

.code-editor textarea {
    width: 100%;
    height: 100%;
    border: none;
    outline: none;
    resize: none;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 0.875rem;
    line-height: 1.6;
    background: #1e293b;
    color: #34d399;
    padding: 1rem;
    border-radius: var(--border-radius);
}

.editor-actions {
    padding: 1rem;
    border-top: 1px solid var(--border-color);
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.output-content {
    flex: 1;
    padding: 1rem;
    background: #1e293b;
    color: #34d399;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 0.875rem;
    line-height: 1.6;
    overflow-y: auto;
}

/* Snippets */
.snippets-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.snippets-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 1.5rem;
}

.snippet-card {
    background: var(--background-color);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius-lg);
    overflow: hidden;
    transition: var(--transition);
}

.snippet-card:hover {
    box-shadow: var(--shadow-md);
}

.snippet-header {
    padding: 1rem;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.snippet-title {
    font-weight: 600;
    color: var(--text-primary);
}

.snippet-lang {
    background: rgba(59, 130, 246, 0.1);
    color: var(--primary-color);
    padding: 0.25rem 0.5rem;
    border-radius: 0.25rem;
    font-size: 0.75rem;
}

.snippet-code {
    background: #1e293b;
    color: #34d399;
    padding: 1rem;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 0.875rem;
    line-height: 1.6;
    overflow-x: auto;
    max-height: 200px;
    overflow-y: auto;
}

.snippet-footer {
    padding: 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--text-muted);
    font-size: 0.875rem;
}

.empty-state {
    text-align: center;
    padding: 4rem 2rem;
    color: var(--text-secondary);
}

.empty-state i {
    font-size: 3rem;
    color: var(--text-muted);
    margin-bottom: 1rem;
}

.empty-state h3 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

/* Blog */
.featured-article {
    background: var(--background-color);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius-lg);
    overflow: hidden;
    margin-bottom: 3rem;
    display: grid;
    grid-template-columns: 1fr 1fr;
    box-shadow: var(--shadow-sm);
}

.featured-image {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.2), rgba(139, 92, 246, 0.2));
    min-height: 300px;
}

.featured-content {
    padding: 2rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.featured-meta {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.category-badge {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.25rem 0.75rem;
    border-radius: 1rem;
    font-size: 0.75rem;
    font-weight: 500;
}

.category-tutorial {
    background: rgba(59, 130, 246, 0.1);
    color: #2563eb;
}

.featured-title {
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--text-primary);
    line-height: 1.3;
}

.featured-excerpt {
    color: var(--text-secondary);
    margin-bottom: 2rem;
    line-height: 1.6;
}

.featured-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.author-info {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.author-avatar {
    width: 2rem;
    height: 2rem;
    border-radius: 50%;
    background: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 0.875rem;
}

.author-details {
    font-size: 0.875rem;
}

.author-name {
    font-weight: 500;
    color: var(--text-primary);
}

.article-date {
    color: var(--text-muted);
}

.articles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
}

.article-card {
    background: var(--background-color);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius-lg);
    overflow: hidden;
    transition: var(--transition);
    box-shadow: var(--shadow-sm);
}

.article-card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.article-image {
    height: 200px;
    background: linear-gradient(135deg, var(--background-secondary), rgba(59, 130, 246, 0.1));
}

.article-content {
    padding: 1.5rem;
}

.article-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.article-title {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
    color: var(--text-primary);
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.article-excerpt {
    color: var(--text-secondary);
    font-size: 0.875rem;
    line-height: 1.6;
    margin-bottom: 1rem;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.article-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.75rem;
}

/* Dashboard */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-bottom: 3rem;
}

.stat-card {
    background: var(--background-color);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius-lg);
    padding: 1.5rem;
    box-shadow: var(--shadow-sm);
}

.stat-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.stat-label {
    font-size: 0.875rem;
    color: var(--text-secondary);
    font-weight: 500;
    display: block;
}

.stat-value {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-primary);
    display: block;
}

.stat-subtitle {
    font-size: 0.75rem;
    color: var(--text-muted);
    display: block;
    margin-top: 0.25rem;
}

.stat-icon {
    width: 3rem;
    height: 3rem;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

.stat-icon.trending-up {
    background: rgba(59, 130, 246, 0.1);
    color: var(--primary-color);
}

.stat-icon.trending-up::before {
    content: '📈';
}

.stat-icon.book {
    background: rgba(16, 185, 129, 0.1);
    color: var(--success-color);
}

.stat-icon.book::before {
    content: '📚';
}

.stat-icon.target {
    background: rgba(59, 130, 246, 0.1);
    color: var(--primary-color);
}

.stat-icon.target::before {
    content: '🎯';
}

.stat-icon.zap {
    background: rgba(245, 158, 11, 0.1);
    color: var(--warning-color);
}

.stat-icon.zap::before {
    content: '⚡';
}

.dashboard-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 2rem;
}

.dashboard-card {
    background: var(--background-color);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius-lg);
    padding: 1.5rem;
    box-shadow: var(--shadow-sm);
    margin-bottom: 2rem;
}

.streak-card {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.1), rgba(139, 92, 246, 0.1));
    border-color: rgba(59, 130, 246, 0.2);
    text-align: center;
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
}

.card-header h3 {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-primary);
}

.progress-list {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.progress-item {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.progress-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.progress-title {
    font-weight: 500;
    color: var(--text-primary);
}

.progress-percentage {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--primary-color);
}

.progress-info {
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.activity-chart {
    margin-bottom: 1.5rem;
}

.chart-bars {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

.chart-bar {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.bar-label {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.bar-visual {
    width: 100%;
    height: 80px;
    background: var(--background-secondary);
    border-radius: 0.25rem;
    display: flex;
    align-items: end;
    padding: 2px;
}

.bar-fill {
    width: 100%;
    background: var(--primary-color);
    border-radius: 0.125rem;
    min-height: 4px;
}

.bar-value {
    font-size: 0.75rem;
    color: var(--text-secondary);
}

.chart-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    text-align: center;
}

.chart-stat .stat-value {
    font-size: 1.5rem;
    margin-bottom: 0.25rem;
}

.chart-stat .stat-label {
    font-size: 0.875rem;
}

.streak-content {
    padding: 1rem;
}

.streak-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
}

.streak-content h3 {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.streak-number {
    font-size: 3rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.achievements-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.achievement-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem;
    background: rgba(59, 130, 246, 0.05);
    border: 1px solid rgba(59, 130, 246, 0.1);
    border-radius: var(--border-radius);
}

.achievement-icon {
    width: 3rem;
    height: 3rem;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
}

.achievement-icon.yellow {
    background: rgba(245, 158, 11, 0.1);
    color: var(--warning-color);
}

.achievement-icon.blue {
    background: rgba(59, 130, 246, 0.1);
    color: var(--primary-color);
}

.achievement-icon.green {
    background: rgba(16, 185, 129, 0.1);
    color: var(--success-color);
}

.achievement-icon.purple {
    background: rgba(139, 92, 246, 0.1);
    color: var(--accent-color);
}

.achievement-info {
    flex: 1;
}

.achievement-name {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.875rem;
}

.achievement-desc {
    color: var(--text-secondary);
    font-size: 0.75rem;
    margin-top: 0.25rem;
}

.achievement-earned {
    color: var(--primary-color);
    font-size: 0.75rem;
    margin-top: 0.25rem;
}

.quick-stats {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.quick-stat {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--border-light);
}

.quick-stat:last-child {
    border-bottom: none;
}

.quick-stat i {
    color: var(--text-muted);
    margin-right: 0.5rem;
}

.quick-stat span {
    color: var(--text-secondary);
    font-size: 0.875rem;
}

.quick-stat strong {
    color: var(--text-primary);
    font-weight: 600;
}

.quick-actions {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

/* Footer */
.footer {
    background: white;
    color: white;
    padding: 4rem 0 2rem;
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.footer-brand i {
    color: var(--primary-color);
    font-size: 1.5rem;
}

.footer-section p {
    color: #94a3b8;
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

.social-links {
    display: flex;
    gap: 1rem;
}

.social-links a {
    color: #94a3b8;
    font-size: 1.25rem;
    transition: var(--transition);
}

.social-links a:hover {
    color: white;
}

.footer-section h4 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 0.5rem;
}

.footer-section ul li a {
    color: #94a3b8;
    text-decoration: none;
    transition: var(--transition);
}

.footer-section ul li a:hover {
    color: white;
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid #334155;
    color: #94a3b8;
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 2000;
    align-items: center;
    justify-content: center;
}

.modal.active {
    display: flex;
}

.modal-content {
    background: var(--background-color);
    border-radius: var(--border-radius-lg);
    max-width: 400px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: var(--shadow-xl);
}

.modal-header {
    padding: 1.5rem 1.5rem 1rem;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h2 {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
}

.close {
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-muted);
    line-height: 1;
}

.close:hover {
    color: var(--text-primary);
}

.modal-body {
    padding: 1.5rem;
}

.modal-body p {
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    text-align: center;
}

.divider {
    text-align: center;
    margin: 1rem 0;
    color: var(--text-muted);
    position: relative;
}

.divider::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: var(--border-color);
    z-index: 1;
}

.divider span {
    background: var(--background-color);
    padding: 0 1rem;
    position: relative;
    z-index: 2;
}

.form-input {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    font-size: 0.875rem;
    margin-bottom: 1rem;
    transition: var(--transition);
}

.form-input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.form-textarea {
    width: 100%;
    min-height: 120px;
    padding: 0.75rem;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    font-size: 0.875rem;
    font-family: inherit;
    resize: vertical;
    background: var(--background-color);
    color: var(--text-primary);
    transition: var(--transition);
}

.form-textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

/* Threads Section */
.thread-actions {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
    align-items: center;
}

.threads-container {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.thread-card {
    background: var(--background-color);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius-lg);
    padding: 1.5rem;
    transition: var(--transition);
    box-shadow: var(--shadow-sm);
}

.thread-card:hover {
    box-shadow: var(--shadow-md);
    border-color: var(--primary-color);
}

.thread-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1rem;
}

.thread-title {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
    cursor: pointer;
    transition: var(--transition);
}

.thread-title:hover {
    color: var(--primary-color);
}

.thread-meta {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: 0.875rem;
    color: var(--text-muted);
}

.thread-category {
    background: rgba(59, 130, 246, 0.1);
    color: var(--primary-color);
    padding: 0.25rem 0.75rem;
    border-radius: 1rem;
    font-size: 0.75rem;
    font-weight: 500;
}

.thread-excerpt {
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 1rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.thread-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 1rem;
    border-top: 1px solid var(--border-light);
}

.thread-author {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.thread-avatar {
    width: 2rem;
    height: 2rem;
    border-radius: 50%;
    background: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 0.875rem;
}

.thread-author-info {
    font-size: 0.875rem;
}

.thread-author-name {
    font-weight: 500;
    color: var(--text-primary);
}

.thread-date {
    color: var(--text-muted);
}

.thread-stats {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    font-size: 0.875rem;
    color: var(--text-muted);
}

.thread-stat {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.thread-stat i {
    color: var(--text-muted);
}

/* Thread Modal */
.thread-modal {
    max-width: 600px;
    width: 95%;
}

.thread-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.thread-form-actions {
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
    margin-top: 1rem;
}

.thread-view {
    max-height: 70vh;
    overflow-y: auto;
}

.thread-content {
    padding: 1.5rem 0;
    border-bottom: 1px solid var(--border-light);
}

.thread-replies {
    padding: 1rem 0;
}

.reply-item {
    display: flex;
    gap: 1rem;
    padding: 1rem;
    border-radius: var(--border-radius);
    background: var(--background-secondary);
    margin-bottom: 1rem;
}

.reply-avatar {
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 50%;
    background: var(--secondary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 0.875rem;
    flex-shrink: 0;
}

.reply-content {
    flex: 1;
}

.reply-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
    font-size: 0.875rem;
}

.reply-author {
    font-weight: 500;
    color: var(--text-primary);
}

.reply-date {
    color: var(--text-muted);
}

.reply-text {
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 0.75rem;
}

.reply-actions {
    display: flex;
    gap: 1rem;
    font-size: 0.875rem;
}

.reply-action {
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 0.25rem 0;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.reply-action:hover {
    color: var(--primary-color);
}

.reply-form {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    padding: 1rem;
    background: var(--background-tertiary);
    border-radius: var(--border-radius);
    margin-top: 1rem;
}

.reply-input {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    font-size: 0.875rem;
    background: var(--background-color);
    color: var(--text-primary);
    resize: vertical;
    min-height: 80px;
}

.reply-form-actions {
    display: flex;
    gap: 0.75rem;
    justify-content: flex-end;
}

.nested-reply {
    margin-left: 2rem;
    border-left: 2px solid var(--border-color);
    padding-left: 1rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .nav-links {
        display: none;
    }
    
    .nav-auth {
        display: none;
    }
    
    .mobile-menu-btn {
        display: block;
    }
    
    .hero-content {
        grid-template-columns: 1fr;
        gap: 2rem;
        text-align: center;
    }
    
    .hero h1 {
        font-size: 2.5rem;
    }
    
    .hero-buttons {
        justify-content: center;
    }
    
    .hero-stats {
        justify-content: center;
    }
    
    .features-grid {
        grid-template-columns: 1fr;
    }
    
    .paths-grid {
        grid-template-columns: 1fr;
    }
    
    .cta-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .filters-card {
        flex-direction: column;
        align-items: stretch;
    }
    
    .filter-selects {
        flex-direction: column;
    }
    
    .results-info {
        flex-direction: column;
        gap: 1rem;
        align-items: flex-start;
    }
    
    .editor-container {
        grid-template-columns: 1fr;
        height: auto;
    }
    
    .snippets-grid {
        grid-template-columns: 1fr;
    }
    
    .featured-article {
        grid-template-columns: 1fr;
    }
    
    .articles-grid {
        grid-template-columns: 1fr;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .dashboard-grid {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .chart-stats {
        grid-template-columns: 1fr;
    }
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.feature-card,
.path-card,
.article-card,
.snippet-card {
    animation: fadeIn 0.6s ease-out;
}

/* Responsive updates for threads */
@media (max-width: 768px) {
    .thread-actions {
        flex-direction: column;
        align-items: stretch;
    }
    
    .thread-footer {
        flex-direction: column;
        gap: 1rem;
        align-items: flex-start;
    }
    
    .thread-stats {
        align-self: flex-end;
    }
    
    .reply-item {
        gap: 0.75rem;
    }
    
    .nested-reply {
        margin-left: 1rem;
    }
    
    .theme-toggle {
        order: -1;
    }
}