Here is a modest improvement on the upper bound that shows $d=O(n\log\log n)$.

The base of the construction is the following.
Order the vertices according to some permutation as $v_1,\ldots,v_n$.
Fix $2n$ independent vectors from $\mathbb F_2^d$ and assign two vectors, $\ell_i$ and $r_i$, to each vertex $v_i$.
Assign to the edge $v_iv_j$ the vector $r_i+\ell_j$ if $i<j$ and $\ell_i+r_j$ if $i>j$.
Notice that this *usually* gives a nonzero sum for long cycles.

Our strategy will be to take $t\approx \log \frac nk$ permutations (with $t\cdot 2n$ independent vectors) and take the sums on each edge to take care of all cycles longer than $k$.
The standard probabilistic approach with $\approx k\log n$ further independent vectors takes care of all cycles whose length is at most $k$.
This in total gives $d\approx t\cdot n + k\log n =O(n\log\log n)$.

Claim. $t\approx \log \frac nk$ permutations are enough to take care of all cycles longer than $k$.

Proof of the claim.
Divide $n$ into groups of size $k$.
Fix an order inside each group, this will be the same in each permutation, which thus practically act on $m=\frac nk$ elements.
For every cycle $C=c_1\ldots c_k$ of length $k$, either there are three different groups that contain three consecutive vertices from $C$ (thus $c_{i-1}\in G_1$, $c_{i}\in G_2$, $c_{i+1}\in G_3$), or two different groups, one of which contains the first two of three consecutive vertices and the other group the third one (thus $c_{i-1},c_{i}\in G_1$, $c_{i+1}\in G_2$)


In this latter case, all we need is a permutation where $G_2$ is after $G_1$, then $c_i$ will be between its neighbors and thus the respective $\ell$ and $r$ vectors won't be negated when taking the sum over the edges of $C$.
Similarly, in the first case, we need that $G_2$ is between $G_1$ and $G_3$.

Therefore, it is enough to show that for $m=\frac nk$ elements there are $O(\log m)$ permutations such that for any three elements $G_1,G_2,G_3$ there is a permutation in which $G_1<G_2<G_3$.
A standard probabilistic argument shows that $O(\log m)$ random permutations work.
In more detail, there are $m^3$ ordered triples, each permutation has probability $\frac 16$ to work for each triple, thus if we take $t$ independent permutations, the chance for any ordered tripe that none of the permutations work for it is $(1-\frac 16)^t$ and taking the union bound we need $m^3(1-\frac 16)^t<1$.