/* Hush: a minimal hover piece. A cloth of thin square sequins on warm paper, pale on one side and ink on the other.
   The cloth is drawn on a canvas; the colours below are read by the script once, when the cloth is laid. */
:root {
  --paper: #f1eee6;     /* the background */
  --face: #fbfaf6;      /* the pale side of a sequin */
  --back: #161514;      /* the dark side, where the word is written */
  --glint: #77726a;     /* the light that catches the dark side when a sequin tilts */
  --accent: #e0462a;    /* the dark side of the full stop */
  --edge: #8f897d;      /* the thin edge of a sequin seen side on */
  --muted: #8a8478;     /* the small print */
  --ink: #171614;       /* the reading */
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  height: 100%;
}

body {
  background: var(--paper);
  color: var(--ink);
  font-family: 'Archivo Variable', system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
  overflow: hidden;
}

.stage {
  position: fixed;
  inset: 0;
  overflow: hidden;
  touch-action: none;
  user-select: none;
  -webkit-user-select: none;
  -webkit-tap-highlight-color: transparent;
}

.cloth {
  position: absolute;
  left: 0;
  top: 0;
  display: block;
}

/* the word is drawn in sequins; the heading is there for screen readers */
.sr {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.note {
  position: absolute;
  left: 0;
  top: 0;
  margin: 0;
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 16px;
  font-size: 12px;
  line-height: 1.3;
  font-weight: 460;
  font-stretch: 100%;
  letter-spacing: 0.02em;
  color: var(--muted);
  white-space: nowrap;
  opacity: 0;
}

.note__r {
  font-variant-numeric: tabular-nums;
}

/* the reading: its weight follows how much of the word is written (set by the script) */
.note__value {
  display: inline-block;
  min-width: 3.2em;
  text-align: right;
  font-weight: 420;
  font-stretch: 96%;
  color: var(--ink);
}

@media (max-width: 560px) {
  .note {
    font-size: 11px;
    gap: 10px;
  }
}
