I have an answer using data.table and DT, its a bit tricky. Here it is:
library(data.table)
library(DT)
store <- setDT(store)
store[,plouf := paste0(tempr,"(",value,")")]
store[,color := ifelse(value > 0,1,0)]
table1 <- dcast(store[,.SD[1],.SDcols = c("product","shop"),by = plouf],product ~ shop,value.var = "plouf")
table2 <- dcast(store[,.SD[1],.SDcols = c("product","shop","color"),by = plouf],product ~ shop,value.var = "color")
table2[,names(table2)[-1] := lapply(.SD,function(x){ifelse(is.na(x),0,x)}),.SDcols = names(table2)[-1] ]
setnames(table2,paste0(names(table1),"_col"))
plouf <- cbind(table1,table2[,-1])
datatable(plouf) %>%
formatStyle(names(table1)[-1],paste0(names(table1)[-1],"_col"), backgroundColor = styleEqual(c(0, 1), c('red', 'green')))
The explanation: first, i redo your store2 table using dacst (passing to large format), which is more convenient, and that i ll reuse to define the colors:
store <- setDT(store)
store[,plouf := paste0(tempr,"(",value,")")]
table1 <- dcast(store[,.SD[1],.SDcols = c("product","shop"),by = plouf],product ~ shop,value.var = "plouf")
product fghj sad sadas xzzv
1: ab NA 35(0) NA NA
2: ac 14(4) 14(-6) 24(8) 5(0)
Here store[,.SD[1],.SDcols = c("product","shop"),by = plouf] allow to have only one line per data you want, to avoid replica
Then I do the same, but with a variable that gives the color (1 for green, 0 for red):
store[,color := ifelse(value > 0,1,0)]
table2 <- dcast(store[,.SD[1],.SDcols = c("product","shop","color"),by = plouf],product ~ shop,value.var = "color")
product fghj sad sadas xzzv
1: ab NA 0 NA NA
2: ac 1 0 1 0
I tranform Nas into 0 in all column exept the first one:
table2[,names(table2)[-1] := lapply(.SD,function(x){ifelse(is.na(x),0,x)}),.SDcols = names(table2)[-1] ]
product fghj sad sadas xzzv
1: ab 0 0 0 0
2: ac 1 0 1 0
and modify the names of the second table (giving the colors):
setnames(table2,paste0(names(table1),"_col"))
you then bind the two
plouf <- cbind(table1,table2[,-1])
and use DT where you specify different column : one for the target, one for the background color
datatable(plouf) %>%
formatStyle(names(table1)[-1],paste0(names(table1)[-1],"_col"), backgroundColor = styleEqual(c(0, 1), c('red', 'green')))

I had to change your data, because there wasn't an unique set for each shop. Here are the data:
product<-c("ab","ab","ac","ac","ac","ac")
shop<-c("sad","sad","sad","sadas","fghj","xzzv")
category<-c("a","a","a","b","b","b")
tempr<-c(35,35,14,24,14,5)
value<-c(0,0,-6,8,4,0)
store<-data.frame(product,shop,category,tempr,value)