/* The pixel-block logo: a stage as big as the window, an SVG the script fills with the blocks and the logo, and the
   still lines of an old screen on top. Every colour is a variable here: a console palette of five. */
:root {
  --screen: #14112b;        /* the dark screen */
  --screen-edge: #0a0819;   /* the screen towards its corners */
  --logo: #f6ecd2;          /* the logo, and the light blocks */
  --red: #ef4a5a;           /* the red blocks */
  --gold: #f7b538;          /* the yellow blocks */
  --teal: #2ccdb6;          /* the green-blue blocks */
  --shadow: #ef4a5a;        /* the stepped shadow behind the logo */
  --ghost: #2c2756;         /* the faint outline of the board */
  --lines: #000000;         /* the lines of the screen */
  --hint: #7d76b0;          /* the small text */
  --tall: 100vh;
}
@supports (height: 100lvh) {
  :root { --tall: 100lvh; }
}

* { box-sizing: border-box; }
html,
body {
  margin: 0;
  height: 100%;
}
body {
  background: radial-gradient(130% 100% at 50% 45%, var(--screen) 50%, var(--screen-edge));
  background-color: var(--screen);
  overflow: hidden;
}

.scena {
  position: relative;
  height: var(--tall);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  user-select: none;
  -webkit-user-select: none;
}

/* the logo is set in this face: the script reads it to measure the letters */
.palco {
  display: block;
  width: 100%;
  height: 100%;
  overflow: hidden;
  font-family: 'Bricolage Grotesque Variable', 'Arial Black', sans-serif;
  font-weight: 800;
  shape-rendering: crispEdges;
}

/* the console palette */
.c0 { fill: var(--logo); }
.c1 { fill: var(--red); }
.c2 { fill: var(--gold); }
.c3 { fill: var(--teal); }
.ombra { fill: var(--shadow); }
.lampo { fill: #fff; }
.luce { fill: #fff; opacity: 0.4; }
.buio { fill: #000; opacity: 0.3; }
.tavola { fill: var(--ghost); }
.scansione { fill: #fff; opacity: 0; }
.luccichio { fill: #fff; opacity: 0; }
.nitido { fill: var(--logo); shape-rendering: geometricPrecision; }

/* the lines of an old screen, still */
.crt {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: repeating-linear-gradient(to bottom, transparent 0 2px, var(--lines) 2px 3px);
  opacity: 0.22;
}

.nota {
  position: absolute;
  left: 0;
  right: 0;
  bottom: max(18px, env(safe-area-inset-bottom));
  margin: 0;
  font-family: 'Bricolage Grotesque Variable', 'Arial Black', sans-serif;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.02em;
  text-align: center;
  color: var(--hint);
  pointer-events: none;
}
