:root {
  --fondo: #f6f4ef;
  --inchiostro: #151514;
  --grigio: #8d8b85;
  --linea: #d6d3cb;
  --accento: #e8452c;
  /* the mark is sized on both sides of the window, so the whole name stays inside the phone's short box */
  --larghezza: min(80vw, 110vh, 860px);
}

* { box-sizing: border-box; margin: 0; }

html, body { height: 100%; overflow: hidden; }

body {
  background: var(--fondo);
  color: var(--inchiostro);
  font-family: 'Mona Sans Variable', system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
}

.palco {
  position: relative;
  height: 100vh;
  max-height: 100vh;
  display: grid;
  place-items: center;
}

.blocco {
  width: var(--larghezza);
  display: grid;
  justify-items: center;
  gap: clamp(6px, 1.6vh, 14px);
}

.marchio {
  display: block;
  width: 100%;
  height: auto;
  overflow: visible;
}

.barre rect { fill: var(--inchiostro); }

.scansione { opacity: 0; }
.scansione__riga { fill: var(--accento); }

/* the digits printed under the barcode: data, in a monospace, they leave as the lines move */
.cifre {
  font-family: 'Geist Mono Variable', ui-monospace, monospace;
  font-size: clamp(9px, min(1.9vw, 2.6vh), 13px);
  letter-spacing: 0.32em;
  color: var(--grigio);
  height: 1.2em;
  white-space: nowrap;
}

.nome {
  position: absolute;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

.frase {
  font-family: 'Geist Mono Variable', ui-monospace, monospace;
  font-size: clamp(10px, min(2vw, 2.8vh), 14px);
  letter-spacing: 0.06em;
  color: var(--grigio);
  height: 1.3em;
  white-space: nowrap;
}
.frase .caret {
  display: inline-block;
  width: 1px;
  height: 1em;
  margin-left: 2px;
  vertical-align: -0.12em;
  background: var(--accento);
}

.replay {
  position: absolute;
  right: clamp(12px, 3vw, 28px);
  bottom: clamp(12px, 3vh, 28px);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 12px 7px 10px;
  border: 1px solid var(--linea);
  border-radius: 999px;
  background: transparent;
  color: var(--inchiostro);
  font: 500 12px/1 'Mona Sans Variable', system-ui, sans-serif;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
}
.replay svg { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round; }
@media (hover: hover) {
  .replay:hover { border-color: var(--inchiostro); }
}
