/* fan/razer.css: /worlds/razer/ only. Added 2026-11-21.

   Black, and the green coming up through a keyboard. The backdrop is a key
   plate seen from above in the dark: a static grid of gaps laid over a band
   of green light that sweeps along underneath it, so the light only shows
   through where the keys are. That is the wave effect every lit Razer board
   has shipped with since Chroma in 2014. Only the band moves, on transform,
   so the page stays cheap.

   He has a Razer keyboard, mouse and headset and named no models (see
   fan-razer.js), so the hero drawing is generic: four keycaps, W, A, S and
   D, not any particular board. The company's mark is described in the copy
   and never drawn. */

body[data-fan="razer"] { --a: #44d62c; }

/* ── the backdrop ── */
.rz-sky {
  position: fixed; inset: 0; z-index: 0; pointer-events: none; overflow: hidden;
  background: radial-gradient(96% 78% at 50% 0%, #0b130a 0%, #060906 46%, #030403 100%);
}

.rz-sky > * { position: absolute; inset: 0; }

.rz-glow { background: radial-gradient(46% 30% at 50% 6%, rgba(68,214,44,.16), transparent 72%); }

/* the light under the keys: one soft band, seven-tenths of the screen wide,
   swept from fully off the left edge to fully off the right (1 / 0.7 = 143%) */
.rz-wave {
  inset: 0 auto 0 0; width: 70%;
  background: linear-gradient(90deg, transparent, rgba(68,214,44,.06) 38%, rgba(140,240,90,.10) 50%, rgba(68,214,44,.06) 62%, transparent);
  transform: translateX(-100%);
  mask-image: linear-gradient(transparent, #000 24%, #000 68%, transparent);
  -webkit-mask-image: linear-gradient(transparent, #000 24%, #000 68%, transparent);
  will-change: transform; animation: rz-sweep 11s linear infinite;
}

@keyframes rz-sweep { to { transform: translateX(143%); } }

/* the plate: 6px dark gaps every 46px both ways, which leaves 40px squares
   open for the light to come through, the pitch of a real key */
.rz-plate {
  background-image:
    linear-gradient(#050805 0 6px, transparent 6px),
    linear-gradient(90deg, #050805 0 6px, transparent 6px);
  background-size: 46px 46px;
  mask-image: linear-gradient(transparent, #000 20%, #000 72%, transparent);
  -webkit-mask-image: linear-gradient(transparent, #000 20%, #000 72%, transparent);
  opacity: .9;
}

.rz-horizon { top: auto; height: 38%; background: linear-gradient(180deg, transparent, rgba(3,4,3,.94)); }

@media (prefers-reduced-motion: reduce) {
  .rz-wave { animation: none; transform: translateX(21%); }
}

/* ── hero ── */
/* Razer sets its name in squared, wide capitals; the mono already on the
   page is the nearest squared letter, tracked out and lit in the green */
body[data-fan="razer"] .fan-title {
  font-family: var(--mono);
  font-weight: 700; text-transform: uppercase; letter-spacing: 0.18em;
  color: var(--a);
  text-shadow: 0 0 28px rgba(68,214,44,.45);
}

/* ── the keys ── */
.rz-art { padding: 0 var(--gutter); max-width: var(--maxw); margin: 2.6rem 0 0; }

.rz-art svg { display: block; width: min(420px, 100%); margin-inline: auto; overflow: visible; }

/* the light under the board, leaking out round every cap */
.rza-keys { filter: drop-shadow(0 0 14px rgba(68,214,44,.38)); }

.rza-cap { fill: #121513; stroke: rgba(68,214,44,.55); stroke-width: 1.5; }

.rza-top { fill: #1d2220; }

.rza-l {
  font-family: var(--mono); font-size: 30px; font-weight: 700;
  text-anchor: middle; fill: #7dff5c;
}

/* the legends brighten one after another, left to right, the way the wave
   in the backdrop does; opacity only */
.rza-key .rza-l { animation: rz-lit 3.6s ease-in-out infinite; }
.rza-key:nth-child(2) .rza-l { animation-delay: -2.7s; }
.rza-key:nth-child(1) .rza-l { animation-delay: -1.8s; }
.rza-key:nth-child(3) .rza-l { animation-delay: -1.8s; }
.rza-key:nth-child(4) .rza-l { animation-delay: -0.9s; }

@keyframes rz-lit { 0%, 100% { opacity: .62; } 50% { opacity: 1; } }

@media (prefers-reduced-motion: reduce) { .rza-key .rza-l { animation: none; } }

.rz-art figcaption {
  margin-top: 0.9rem; text-align: center;
  font-family: var(--mono); font-size: 0.66rem; letter-spacing: 0.16em;
  text-transform: uppercase; color: var(--mute);
}
