@font-face { font-family: "Gochi Hand"; src: url("assets/fonts/gochi-hand-latin-400-normal.woff2") format("woff2"); font-display: swap; }
@font-face { font-family: "Figtree"; src: url("assets/fonts/figtree-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Figtree"; src: url("assets/fonts/figtree-latin-500-normal.woff2") format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Figtree"; src: url("assets/fonts/figtree-latin-600-normal.woff2") format("woff2"); font-weight: 600; font-display: swap; }

:root {
  --ink: #1f2a36;
  --gold: #a8834e;
  --gold-soft: #efe4d3;
  --gold-text: #7d5f34;
  --bg: #f4f4f1;
  --muted: #59626c;
  --line: #e2e2dc;
  --pill: #e8e8e3;
  --ease: cubic-bezier(.16, 1, .3, 1);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 1.0625rem/1.55 "Figtree", system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
  scrollbar-color: #c9c9c2 var(--bg);
}
body::before {
  content: "";
  position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background-image: radial-gradient(#d6d6cf 1.1px, transparent 1.2px);
  background-size: 22px 22px;
  -webkit-mask-image: radial-gradient(ellipse 70% 60% at 50% 35%, #000 30%, transparent 85%);
          mask-image: radial-gradient(ellipse 70% 60% at 50% 35%, #000 30%, transparent 85%);
}
::selection { background: var(--gold-soft); color: var(--ink); }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 4px; border-radius: 8px; }
a { color: inherit; }

.hand { font-family: "Gochi Hand", "Comic Sans MS", cursive; font-weight: 400; }

.top { display: flex; justify-content: center; padding: 28px 20px 0; }
.logo img { display: block; height: 34px; width: auto; }

/* hero */
.hero { max-width: 1040px; margin: 0 auto; padding: clamp(56px, 10vh, 110px) 20px 40px; text-align: center; }
.hero h1 {
  margin: 0 auto;
  font-size: clamp(2.3rem, 5.2vw, 3.6rem);
  line-height: 1.08;
  letter-spacing: .01em;
  color: #3a434d;
  transform: rotate(-3deg);
}

.tiles {
  list-style: none; margin: clamp(64px, 11vh, 110px) auto 0; padding: 0;
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; max-width: 860px;
}
.tile a { display: flex; flex-direction: column; align-items: center; gap: 22px; text-decoration: none; position: relative; }
.icon {
  display: block; width: 116px; height: 116px; border-radius: 30px; overflow: hidden;
  background: #fff; border: 4px solid #fff;
  box-shadow: 0 1px 2px rgba(31,42,54,.08), 0 10px 24px -8px rgba(31,42,54,.28);
  transform: rotate(var(--tilt));
  animation: galleggia 6s ease-in-out var(--d) infinite;
  transition: transform .5s var(--ease), box-shadow .5s var(--ease);
}
.icon img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: var(--o, 50% 50%); transform: scale(var(--z, 1)); transform-origin: var(--o, 50% 50%); border-radius: 25px; }
.tile--you .icon { border-color: var(--ink); background: var(--ink); }
.pill {
  display: inline-block; padding: 7px 16px; border-radius: 999px;
  background: var(--pill); font-weight: 500; font-size: .95rem; color: var(--ink);
  transition: background .3s, color .3s;
}
.note {
  position: absolute; top: -40px; left: 50%; white-space: nowrap;
  font-size: 1.2rem; color: var(--gold-text);
  opacity: 0; transform: translate(-50%, 6px) rotate(-4deg);
  transition: opacity .35s var(--ease), transform .45s var(--ease);
  pointer-events: none;
}
.tile a:hover .icon, .tile a:focus-visible .icon {
  animation-play-state: paused;
  transform: rotate(0deg) translateY(-8px) scale(1.07);
  box-shadow: 0 2px 4px rgba(31,42,54,.08), 0 22px 36px -12px rgba(31,42,54,.35);
}
.tile a:hover .pill, .tile a:focus-visible .pill { background: var(--ink); color: #fff; }
.tile a:hover .note, .tile a:focus-visible .note { opacity: 1; transform: translate(-50%, 0) rotate(-4deg); }
.tile a:focus-visible { outline: none; }

@keyframes galleggia {
  0%, 100% { translate: 0 0; }
  50% { translate: 0 -5px; }
}

.intro { max-width: 34rem; margin: clamp(60px, 10vh, 96px) auto 0; color: var(--muted); font-size: 1.125rem; text-wrap: pretty; }

/* sezioni */
section h2 { margin: 0 0 28px; font-size: clamp(2rem, 4vw, 2.6rem); line-height: 1.1; color: #3a434d; transform: rotate(-2deg); }
.prezzi, .come, .scrivimi { max-width: 860px; margin: 0 auto; padding: clamp(72px, 12vh, 120px) 20px 0; text-align: center; }

.conti { display: flex; align-items: center; justify-content: center; gap: 18px; }
.conto {
  flex: 0 1 300px; padding: 26px 26px 24px; background: #fff; border-radius: 22px; text-align: left;
  box-shadow: 0 1px 2px rgba(31,42,54,.06), 0 12px 28px -14px rgba(31,42,54,.25);
  transform: rotate(var(--tilt));
  transition: transform .5s var(--ease);
}
.conto:hover { transform: rotate(0deg); }
.conto p { margin: 0; color: var(--muted); }
.conto .cifra { font-size: 2.6rem; font-weight: 600; letter-spacing: -.02em; color: var(--ink); line-height: 1; font-variant-numeric: tabular-nums; }
.conto .cifra small { font-size: 1rem; font-weight: 500; letter-spacing: 0; color: var(--muted); margin-left: 2px; }
.conto .per { margin: 6px 0 14px; font-weight: 500; color: var(--gold-text); }
.piu { font-size: 2.6rem; color: var(--gold); }
.nota { margin: 26px auto 0; font-size: .95rem; color: var(--muted); }

.passi { list-style: none; margin: 0 auto; padding: 0; max-width: 520px; text-align: left; counter-reset: p; }
.passi li { position: relative; padding: 0 0 22px 56px; color: var(--muted); counter-increment: p; }
.passi li::before {
  content: counter(p); position: absolute; left: 0; top: -6px;
  width: 38px; height: 38px; display: grid; place-items: center; border-radius: 50%;
  background: var(--pill); font-family: "Gochi Hand", cursive; font-size: 1.35rem; color: var(--ink);
}
.passi li:not(:last-child)::after { content: ""; position: absolute; left: 18px; top: 38px; bottom: 6px; border-left: 2px dotted #cfcfc8; }
.passi strong { color: var(--ink); font-weight: 600; }

.scrivimi { padding-bottom: 40px; }
.scrivimi > p { margin: 0 0 24px; color: var(--muted); }
.mail {
  position: relative; display: inline-flex; align-items: center; gap: 6px; padding: 6px 6px 6px 22px;
  background: #fff; border-radius: 999px; box-shadow: 0 1px 2px rgba(31,42,54,.06), 0 12px 28px -14px rgba(31,42,54,.25);
}
.indirizzo { font-size: 1.25rem; font-weight: 600; text-decoration: none; margin-right: 10px; }
.indirizzo:hover { text-decoration: underline; text-decoration-color: var(--gold); text-underline-offset: 5px; }
.copia {
  font: inherit; font-weight: 500; font-size: .95rem; border: 0; cursor: pointer;
  padding: 10px 18px; border-radius: 999px; background: var(--ink); color: #fff;
  transition: background .25s, transform .2s var(--ease);
}
.copia:hover { background: #2e3d4d; }
.copia:active { transform: scale(.96); }
.copiata {
  position: absolute; right: -8px; top: -34px; font-size: 1.3rem; color: var(--gold-text);
  opacity: 0; transform: translateY(6px) rotate(6deg); transition: opacity .3s var(--ease), transform .4s var(--ease);
}
.mail.fatto .copiata { opacity: 1; transform: translateY(0) rotate(6deg); }

.piede { text-align: center; padding: 64px 20px 36px; font-size: .85rem; color: var(--muted); }
.piede p { margin: 0; }

@media (max-width: 720px) {
  .tiles { grid-template-columns: repeat(2, 1fr); row-gap: 56px; max-width: 360px; }
  .icon { width: 104px; height: 104px; border-radius: 27px; }
  .icon img { border-radius: 22px; }
  .conti { flex-direction: column; gap: 10px; }
  .conto { flex-basis: auto; width: 100%; max-width: 340px; }
  .piu { line-height: 1; }
  .prezzi, .come, .scrivimi { padding-top: 64px; }
  .intro { margin-top: 56px; }
  .mail { flex-direction: column; gap: 10px; padding: 18px 18px 14px; border-radius: 24px; }
  .indirizzo { margin: 0; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .icon { animation: none; }
  * { transition-duration: .01ms !important; }
}
