:root {
  --fondo: #f1ede6;        /* the warm paper white behind the bottle */
  --fondo-alto: #e6e0d6;   /* the top of the background */
  --oro: #cdb58a;          /* the brushed champagne gold of the cap and the collar */
  --vetro: #eef0ec;        /* the clear glass of the flacon */
  --liquido: #c9822f;      /* the amber of the eau de parfum */
  --accento: #b9661d;      /* the small marks and the eyebrow lines, a deeper amber */
  --inchiostro: #1c1915;   /* the text */
}

* { box-sizing: border-box; }

html, body { margin: 0; }

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

p, h1, h2 { margin: 0; }

/* ---------------------------------------------------------------- the stage */
.vista {
  position: relative;
  height: 560lvh;
}

.palco {
  position: sticky;
  top: 0;
  height: 100vh;
  height: 100lvh;
  overflow: hidden;
  background:
    radial-gradient(90% 75% at 66% 58%, rgba(255, 252, 245, .75), transparent 62%),
    linear-gradient(to bottom, var(--fondo-alto), var(--fondo) 70%);
  touch-action: pan-y;
}

.tela {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
}

/* ---------------------------------------------------------------- the callouts on the parts */
.fili {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  overflow: visible;
}

.fili line {
  stroke: var(--inchiostro);
  stroke-width: 1;
  stroke-opacity: .45;
}

/* the anchor on the part: a small cross, like the marks on a technical drawing */
.fili path {
  fill: none;
  stroke: var(--accento);
  stroke-width: 1.4;
  stroke-linecap: round;
}

.etichette {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.etichetta {
  position: absolute;
  left: 0;
  top: 0;
  white-space: nowrap;
  font-size: clamp(10px, 1.1vw, 13px);
  line-height: 1.25;
  font-variation-settings: 'wdth' 82;
  /* a soft halo in the colour of the background, so the words read over the parts too */
  text-shadow: 0 0 4px var(--fondo), 0 0 8px var(--fondo), 0 0 12px var(--fondo);
  opacity: 0;
}

.etichetta b {
  display: block;
  font-weight: 650;
  font-size: 1.08em;
}

.etichetta span { opacity: .6; }

/* ---------------------------------------------------------------- the words over the stage */
.testata {
  position: absolute;
  top: clamp(14px, 3.4vh, 30px);
  left: clamp(16px, 5vw, 64px);
  right: clamp(16px, 5vw, 64px);
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 2;
}

.marchio {
  font-family: 'Fraunces Variable', Georgia, serif;
  font-size: clamp(17px, 2vw, 23px);
  font-weight: 420;
  font-variation-settings: 'opsz' 72, 'SOFT' 60;
  letter-spacing: .22em;
  text-transform: uppercase;
}

.sotto {
  font-size: clamp(11px, 1.1vw, 13px);
  letter-spacing: .14em;
  text-transform: uppercase;
  opacity: .7;
}

.racconto {
  position: absolute;
  left: clamp(16px, 5vw, 64px);
  top: clamp(64px, 15vh, 150px);
  width: min(30vw, 400px);
  z-index: 2;
}

.capitolo {
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  opacity: 0;
}

.occhiello {
  font-size: clamp(11px, 1.1vw, 13px);
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--accento);
  margin-bottom: .7em;
  font-weight: 650;
}

.titolo {
  font-weight: 620;
  font-size: clamp(26px, min(4.2vw, 7.4vh), 60px);
  line-height: 1.02;
  letter-spacing: -.025em;
  font-variation-settings: 'wdth' 92;
}

.titolo em {
  font-family: 'Fraunces Variable', Georgia, serif;
  font-style: italic;
  font-weight: 380;
  font-variation-settings: 'opsz' 96, 'SOFT' 100;
  letter-spacing: -.01em;
  padding-right: .06em;
}

.nota {
  position: absolute;
  left: clamp(16px, 5vw, 64px);
  bottom: clamp(14px, 3.4vh, 30px);
  font-size: clamp(11px, 1.1vw, 13px);
  letter-spacing: .12em;
  text-transform: uppercase;
  opacity: 0;
  z-index: 2;
}

/* ---------------------------------------------------------------- the last chapter: the price and the button */
.ordina {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px 18px;
  margin-top: clamp(14px, 3vh, 26px);
}

.prezzo {
  font-size: clamp(20px, min(2.4vw, 4.2vh), 30px);
  font-weight: 640;
  letter-spacing: -.02em;
  font-variation-settings: 'wdth' 96;
}

.pillola {
  display: inline-block;
  padding: 12px 24px;
  border-radius: 999px;
  background: var(--inchiostro);
  color: var(--fondo);
  text-decoration: none;
  font-size: 14px;
  font-weight: 600;
  font-variation-settings: 'wdth' 85;
  transition: font-variation-settings .45s cubic-bezier(.34, 1.56, .64, 1), transform .45s cubic-bezier(.34, 1.56, .64, 1);
}

@media (hover: hover) {
  .pillola:hover {
    font-variation-settings: 'wdth' 112;
    transform: scale(1.04);
  }
}

/* ---------------------------------------------------------------- the phone: words on top, the bottle below */
@media (max-width: 720px) {
  .racconto {
    width: auto;
    right: 16px;
    top: clamp(52px, 11vh, 90px);
  }

  .titolo { font-size: clamp(21px, min(6.4vw, 5.6vh), 34px); }

  .etichetta { font-size: 10px; }
}

@media (prefers-reduced-motion: reduce) {
  .vista { height: 100lvh; }
  .pillola { transition: none; }
}
