.feed-layout {
    display: grid;
    grid-template-columns: var(--sidebar-width) 1fr 280px;
    gap: 1.5rem;
    align-items: start;
}


.feed-nav {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    margin-bottom: 1rem;
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    padding: 0.25rem;
    border: 1px solid var(--border);
}

.feed-nav-btn {
    padding: 0.5rem 1rem;
    border-radius: var(--radius);
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--text-secondary);
    transition: all 0.2s;
}

.feed-nav-btn:hover {
    color: var(--text-primary);
    background: var(--bg-card-hover);
}

.feed-nav-btn.active {
    background: var(--accent);
    color: #fff;
}

.feed-nav-actions {
    margin-left: auto;
    display: flex;
    gap: 0.25rem;
}

.feed-nav-actions button {
    color: var(--text-muted);
    padding: 0.375rem 0.5rem;
    border-radius: var(--radius);
    font-size: 0.875rem;
    transition: all 0.2s;
}

.feed-nav-actions button:hover {
    color: var(--text-primary);
    background: var(--bg-card-hover);
}

.feed-posts {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.post-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1rem;
    transition: all 0.2s;
}

.post-card:hover {
    border-color: var(--border-light);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.post-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
}

.post-author-wrap {
    display: flex;
    flex-direction: column;
    line-height: 1.3;
}

.post-author {
    font-weight: 600;
    font-size: 0.875rem;
    color: var(--text-primary);
}

.post-author-role {
    font-size: 0.6875rem;
    color: var(--text-muted);
    font-weight: 400;
}

.post-time {
    font-size: 0.6875rem;
    color: var(--text-muted);
    margin-left: auto;
    padding-left: 0.75rem;
    white-space: nowrap;
    line-height: 1.5;
}

.post-topic {
    margin-bottom: 0.75rem;
}

.post-title-link {
    text-decoration: none;
    color: inherit;
    display: block;
}

.post-title-link:hover .post-title {
    color: var(--accent);
}

.post-title {
    font-size: 1.125rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
    line-height: 1.3;
    transition: color 0.15s ease;
}

.post-content {
    font-size: 0.875rem;
    color: var(--text-secondary);
    line-height: 1.65;
    margin-bottom: 1rem;
    word-break: break-word;
    display: -webkit-box;
    -webkit-line-clamp: 4;
    -webkit-box-orient: vertical;
    overflow: hidden;
    cursor: pointer;
    transition: color 0.15s ease;
}

.post-content:hover {
    color: var(--accent);
}

.post-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border);
}

.post-action-btn {
    line-height: 1;
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.375rem 0.75rem;
    border-radius: var(--radius);
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--text-muted);
    transition: all 0.2s;
    background: none;
    border: none;
    cursor: pointer;
}

.post-action-btn:hover {
    background: var(--bg-card-hover);
    color: var(--text-secondary);
}

.post-action-btn.voted,
.post-action-btn.vote-up {
    color: var(--accent);
}

.post-action-btn.vote-down {
    color: var(--danger);
}

.post-votes {
    display: inline-flex;
    align-items: center;
    gap: 0.125rem;
}

.post-vote-count {
    font-weight: 600;
    font-size: 0.8125rem;
    color: var(--text-secondary);
    min-width: 1.25rem;
    text-align: center;
}

.post-action-btn.share {
    margin-left: auto;
}

.feed-right {
    position: sticky;
    top: calc(var(--nav-height) + 1rem);
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.daily-topic-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1.25rem;
}

.daily-topic-label {
    font-size: 0.6875rem;
    font-weight: 700;
    color: var(--accent);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 0.5rem;
}

.daily-topic-card h4 {
    font-size: 0.875rem;
    margin-bottom: 0.375rem;
    line-height: 1.4;
}

.daily-topic-card p {
    font-size: 0.8125rem;
    color: var(--text-secondary);
    line-height: 1.5;
    margin-bottom: 0.75rem;
}

.daily-topic-card .topic-links {
    display: flex;
    gap: 0.75rem;
}

.daily-topic-card .topic-links a {
    font-size: 0.75rem;
    font-weight: 600;
}

.community-stats {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1.25rem;
}

.community-stats h3 {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-muted);
    margin-bottom: 0.75rem;
}

.stat-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.375rem 0;
    font-size: 0.8125rem;
}

.stat-row:not(:last-child) {
    border-bottom: 1px solid var(--border);
    margin-bottom: 0.25rem;
    padding-bottom: 0.5rem;
}

.stat-row .label {
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 0.375rem;
}

.stat-row .value {
    font-weight: 700;
    color: var(--text-primary);
    font-size: 0.9375rem;
}

.feed-fab {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: #e53935;
    color: #fff;
    font-size: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 16px rgba(229, 57, 53, 0.4);
    transition: all 0.2s;
    z-index: 100;
    border: none;
    cursor: pointer;
}

.feed-fab:hover {
    background: #c62828;
    transform: scale(1.05);
    box-shadow: 0 6px 20px rgba(229, 57, 53, 0.5);
}

.feed-comment-form {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 0.75rem;
    padding-top: 0.75rem;
    border-top: 1px solid var(--border);
}
.feed-comment-form input {
    flex: 1;
    padding: 0.375rem 0.75rem;
    font-size: 0.8125rem;
    min-height: auto;
}
.feed-comment-submit {
    padding: 0.375rem 0.75rem;
    background: var(--accent);
    color: #fff;
    border-radius: var(--radius);
    font-weight: 600;
    font-size: 0.8125rem;
    white-space: nowrap;
}
.feed-comment-submit:hover {
    background: var(--accent-hover);
}

@media (max-width: 1024px) {
    .feed-layout {
        grid-template-columns: 1fr;
    }
    .feed-right {
        display: none;
    }
}

@media (max-width: 768px) {
    .feed-nav {
        gap: 0.125rem;
        overflow-x: auto;
        flex-wrap: nowrap;
        -webkit-overflow-scrolling: touch;
    }

    .feed-nav-btn {
        padding: 0.375rem 0.625rem;
        font-size: 0.75rem;
        flex-shrink: 0;
    }
}

@media (max-width: 480px) {
    .feed-nav-actions {
        display: none;
    }

    .feed-nav-btn .icon {
        width: auto;
        margin-right: 0.125rem;
    }

    .feed-comment-form {
        flex-wrap: wrap;
    }

    .feed-comment-form input {
        min-width: 120px;
    }

    .post-card {
        padding: 0.75rem;
    }

    .post-header {
        gap: 0.5rem;
    }

    .post-time {
        font-size: 0.625rem;
    }

    .post-title {
        font-size: 1rem;
    }

    .post-actions {
        flex-wrap: wrap;
        gap: 0.25rem;
    }

    .post-action-btn {
        padding: 0.375rem 0.5rem;
        font-size: 0.75rem;
    }
}

@media (max-width: 360px) {
    .post-header {
        flex-wrap: wrap;
    }

    .post-time {
        margin-left: 0;
        padding-left: 0;
        width: 100%;
    }
}
