@font-face {
  font-family: "ChunkFive";
  src: url("../fonts/ChunkFive-Regular.woff2") format("woff2"),
       url("../fonts/ChunkFive-Regular.otf") format("opentype");
  font-weight: 400;
  font-style: normal;
  font-display: block;
}

/* Poppins (Google Fonts, licenza OFL) servito dal sito: niente collegamenti a Google */
@font-face {
  font-family: "Poppins";
  src: url("../fonts/poppins-400-latin-ext.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Poppins";
  src: url("../fonts/poppins-400-latin.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Poppins";
  src: url("../fonts/poppins-600-latin-ext.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Poppins";
  src: url("../fonts/poppins-600-latin.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Poppins";
  src: url("../fonts/poppins-700-latin-ext.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Poppins";
  src: url("../fonts/poppins-700-latin.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Poppins";
  src: url("../fonts/poppins-800-latin-ext.woff2") format("woff2");
  font-weight: 800;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Poppins";
  src: url("../fonts/poppins-800-latin.woff2") format("woff2");
  font-weight: 800;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --purple: #441798;
  --purple-deep: #2B0D66;      /* ombre "a blocco" sotto i bottoni */
  --gold: #E4B138;
  --white: #FFFFFF;
  /* il logo resta in ChunkFive (le misure del wordmark sono ricavate dalle sue metriche) */
  --font-logo: "ChunkFive", "Rockwell Extra Bold", "Rockwell", Georgia, serif;
  --font-brand: "Poppins", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --font-text: "Poppins", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --gutter: clamp(16px, 4vw, 48px);
}

*, *::before, *::after { box-sizing: border-box; }

html, body { margin: 0; }
html { scroll-behavior: smooth; }

body {
  min-height: 100vh;
  min-height: 100dvh;
  background: var(--purple);
  color: var(--white);
  font-family: var(--font-brand);
  font-weight: 600;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

.js body.is-intro { overflow: hidden; }
html:not(.js) .intro { display: none; }

::selection { background: var(--gold); color: var(--purple); }

/* i bottoni non ereditano il peso del body: senza questo restano a 400 */
button { font-weight: inherit; }

/* ------------------------------------------------------------------
   WORDMARK "duck / link"
   Misure in em ricavate dalle metriche di Chunk Five:
   - "link" rientra di 0.24em e la sua linea di base sta 0.66em sotto
     quella di "duck" (le due parole si sovrappongono come nel logo)
   - la testa di papera sostituisce il puntino della "i" (0.66em sopra la base)
   ------------------------------------------------------------------ */
.wordmark {
  display: inline-block;
  font-family: var(--font-logo);
  font-weight: 400;
  line-height: 1;
  white-space: nowrap;
  user-select: none;
}

.wm-duck,
.wm-link { display: block; }

.wm-duck { color: var(--white); position: relative; z-index: 1; }

.wm-link {
  color: var(--gold);
  position: relative;
  z-index: 2;
  margin-top: -0.34em;
  padding-left: 0.24em;
  /* contorno viola che "buca" la scritta bianca dove le parole si toccano */
  --k: 0.032em;
  text-shadow:
    var(--k) 0 0 var(--purple), calc(var(--k) * -1) 0 0 var(--purple),
    0 var(--k) 0 var(--purple), 0 calc(var(--k) * -1) 0 var(--purple),
    var(--k) var(--k) 0 var(--purple), calc(var(--k) * -1) var(--k) 0 var(--purple),
    var(--k) calc(var(--k) * -1) 0 var(--purple), calc(var(--k) * -1) calc(var(--k) * -1) 0 var(--purple);
}

.wordmark .ch { display: inline-block; }

.ch-i { position: relative; display: inline-block; }

/* Il centro della testa (38% della larghezza) sta sull'asta della "i" */
.dot {
  position: absolute;
  left: 50%;
  top: 0.19em;            /* 0.85em (base) − 0.66em (centro puntino) */
  width: 0.3em;
  height: 0.234em;
  transform: translate(-38%, -50%);
}

.dot .head {
  display: block;
  width: 100%;
  height: 100%;
  overflow: visible;
  transform-origin: 38% 90%;
}

/* ------------------------------------------------------------------
   INTRO
   ------------------------------------------------------------------ */
.intro {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  background: var(--purple);
  cursor: pointer;
}

.wordmark--intro {
  font-size: clamp(64px, 25vw, 230px);
  transform-origin: 0 0;
  /* compensa lo spazio vuoto sopra le ascendenti per un centraggio ottico */
  margin-top: -0.1em;
}

.wordmark--intro .ch { transform-origin: 50% 85%; will-change: transform; }

.wordmark--intro .sparks {
  position: absolute;
  left: 92%;
  bottom: 58%;
  width: 0.24em;
  height: 0.24em;
  fill: var(--gold);
  stroke: var(--purple);
  stroke-width: 5;
  stroke-linejoin: round;
  paint-order: stroke;
  overflow: visible;
  transform-origin: 0% 100%;
  opacity: 0;
}

.ripple {
  position: absolute;
  left: 38%;
  top: 70%;
  width: 0.5em;
  height: 0.16em;
  margin: -0.08em 0 0 -0.25em;
  border: 0.018em solid var(--gold);
  border-radius: 50%;
  opacity: 0;
}

/* Stato iniziale (solo con JS attivo): tutto nascosto finché parte l'animazione */
.js .wordmark--intro .ch,
.js .wordmark--intro .head { opacity: 0; }

/* ------------------------------------------------------------------
   BOTTONI
   ------------------------------------------------------------------ */
.btn {
  --shadow: var(--purple-deep);
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 16px 26px 15px;
  border-radius: 999px;
  font-family: var(--font-brand);
  font-size: 21px;
  line-height: 1;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: transform 0.18s var(--ease-out), box-shadow 0.18s var(--ease-out),
              background-color 0.2s, border-color 0.2s, color 0.2s;
}

.btn__icon {
  width: 18px;
  height: 18px;
  flex: none;
  transition: transform 0.25s var(--ease-out);
}

.btn:focus-visible { outline: 3px solid var(--white); outline-offset: 4px; }

.btn--gold {
  background: var(--gold);
  color: var(--purple);
  box-shadow: 0 5px 0 var(--shadow);
}

.btn--ghost,
.btn--outline {
  color: var(--white);
  border: 2px solid rgba(255, 255, 255, 0.35);
  padding: 14px 24px 13px;
}

.btn--small { font-size: 18px; padding: 11px 18px 10px; }

@media (hover: hover) {
  .btn--gold:hover { transform: translateY(-3px); box-shadow: 0 8px 0 var(--shadow); }
  .btn--ghost:hover,
  .btn--outline:hover { border-color: var(--white); background: rgba(255, 255, 255, 0.06); }
  .btn:hover .btn__icon { transform: translateX(4px); }
  .btn:hover .btn__icon--down { transform: translateY(3px); }
}

.btn--gold:active { transform: translateY(3px); box-shadow: 0 2px 0 var(--shadow); }
.btn:active { transition-duration: 0.06s; }

/* ------------------------------------------------------------------
   HEADER
   ------------------------------------------------------------------ */
/* logo a sinistra, menu al centro, "Parliamo" a destra */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  padding: 22px var(--gutter);
}
.site-header > .brand { justify-self: start; }
.site-header > .header-cta { justify-self: end; }

/* lo sfondo sfocato sta su uno strato a parte: un backdrop-filter sull'header
   stesso farebbe da contenitore al pannello fisso del menu da telefono */
.site-header::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  transition: background-color 0.3s, box-shadow 0.3s;
}
.site-header.is-scrolled::before {
  background: rgba(68, 23, 152, 0.9);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.08);
}

/* ------------------------------------------------------------------
   MENU
   Da PC: voci al centro dell'header, "Servizi" apre una tendina.
   Da telefono/tablet (≤1100px): l'hamburger apre un pannello a tutto
   schermo che si allarga dal bottone; "Servizi" si apre a fisarmonica.
   ------------------------------------------------------------------ */
.nav__list {
  display: flex;
  align-items: center;
  gap: 4px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.nav__item { position: relative; }

.nav__link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 14px;
  border: 0;
  border-radius: 999px;
  background: none;
  color: rgba(255, 255, 255, 0.86);
  font-family: var(--font-brand);
  font-size: 16px;
  line-height: 1.2;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: color 0.2s, background-color 0.2s;
  -webkit-tap-highlight-color: transparent;
}
.nav__link[aria-current="true"] { color: var(--gold); }
@media (hover: hover) {
  .nav__link:hover { color: var(--white); background: rgba(255, 255, 255, 0.08); }
  .nav__link[aria-current="true"]:hover { color: var(--gold); }
}
.nav__link:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }

.nav__chevron {
  width: 16px;
  height: 16px;
  transition: transform 0.3s var(--ease-out);
}
.nav__item--drop.is-open .nav__chevron { transform: rotate(180deg); }

/* --- Tendina dei servizi (PC) --- */
.nav__drop {
  position: absolute;
  top: calc(100% + 14px);
  left: 50%;
  width: 340px;
  translate: -50% 0;
  visibility: hidden;
  opacity: 0;
  transform: translateY(-8px) scale(0.97);
  transform-origin: 50% 0;
  transition: opacity 0.2s ease, transform 0.25s var(--ease-out), visibility 0s linear 0.25s;
}
/* ponte invisibile: passando col mouse dal bottone alla tendina non si chiude */
.nav__drop::before {
  content: "";
  position: absolute;
  inset: -16px 0 auto;
  height: 16px;
}
.nav__item--drop.is-open .nav__drop {
  visibility: visible;
  opacity: 1;
  transform: none;
  transition: opacity 0.2s ease, transform 0.3s var(--ease-out), visibility 0s;
}

.nav__drop-inner {
  padding: 10px;
  border: 2px solid rgba(255, 255, 255, 0.14);
  border-radius: 22px;
  background: var(--purple-deep);
  box-shadow: 0 24px 40px rgba(0, 0, 0, 0.35);
}

.nav__svcs {
  display: grid;
  gap: 2px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.nav__svc {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 6px 12px 6px 6px;
  border-radius: 14px;
  color: var(--white);
  font-size: 16px;
  text-decoration: none;
  transition: background-color 0.2s, color 0.2s;
}
.nav__svc img {
  flex: none;
  width: 44px;
  height: 44px;
  object-fit: contain;
  transition: transform 0.35s var(--ease-spring);
}
@media (hover: hover) {
  .nav__svc:hover { background: rgba(255, 255, 255, 0.07); color: var(--gold); }
  .nav__svc:hover img { transform: scale(1.12) rotate(-6deg); }
}
.nav__svc:focus-visible { outline: 3px solid var(--gold); outline-offset: -3px; }

.nav__drop-all {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 8px;
  padding: 12px;
  border-top: 2px dashed rgba(228, 177, 56, 0.45);
  color: var(--gold);
  font-size: 15px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  text-decoration: none;
}
.nav__drop-all .btn__icon { transition: transform 0.25s var(--ease-out); }
@media (hover: hover) {
  .nav__drop-all:hover .btn__icon { transform: translateX(4px); }
}
.nav__drop-all:focus-visible { outline: 3px solid var(--gold); outline-offset: -3px; border-radius: 12px; }

/* --- Hamburger (solo telefono/tablet) --- */
.nav-toggle {
  display: none;
  position: relative;
  z-index: 2;
  justify-self: end;
  width: 48px;
  height: 48px;
  padding: 0;
  border: 2px solid rgba(255, 255, 255, 0.4);
  border-radius: 50%;
  background: none;
  color: var(--white);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition: border-color 0.2s, background-color 0.2s, color 0.2s;
}
.nav-toggle:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; }
.nav-toggle__bar {
  position: absolute;
  left: 13px;
  width: 18px;
  height: 2.5px;
  border-radius: 2px;
  background: currentColor;
  transition: transform 0.35s var(--ease-out), opacity 0.2s;
}
.nav-toggle__bar:nth-child(1) { top: 15px; }
.nav-toggle__bar:nth-child(2) { top: 21px; }
.nav-toggle__bar:nth-child(3) { top: 27px; }
/* aperto: le tre righe diventano una X */
.site-header.is-open .nav-toggle { border-color: var(--gold); background: var(--gold); color: var(--purple); }
.site-header.is-open .nav-toggle__bar:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.site-header.is-open .nav-toggle__bar:nth-child(2) { opacity: 0; }
.site-header.is-open .nav-toggle__bar:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

body.is-menu-open { overflow: hidden; }

@media (max-width: 1100px) {
  .site-header { grid-template-columns: 1fr auto; }
  .site-header > .brand { position: relative; z-index: 2; }
  .header-cta { display: none; }
  .nav-toggle { display: block; }

  /* il pannello si allarga in un cerchio che parte dall'hamburger */
  .site-nav {
    --origin: calc(100% - var(--gutter) - 24px) 46px;
    position: fixed;
    inset: 0;
    z-index: 1;
    overflow-y: auto;
    padding: 112px var(--gutter) 48px;
    background: var(--purple);
    background-image: radial-gradient(120% 60% at 100% 0%, rgba(228, 177, 56, 0.1), transparent 60%);
    clip-path: circle(0 at var(--origin));
    visibility: hidden;
    transition: clip-path 0.55s cubic-bezier(0.65, 0, 0.35, 1), visibility 0s linear 0.55s;
  }
  .site-header.is-open .site-nav {
    clip-path: circle(150% at var(--origin));
    visibility: visible;
    transition: clip-path 0.65s cubic-bezier(0.65, 0, 0.35, 1), visibility 0s;
  }

  .nav__list { flex-direction: column; align-items: stretch; gap: 0; }
  .nav__item { border-bottom: 2px solid rgba(255, 255, 255, 0.1); }

  .nav__link {
    width: 100%;
    justify-content: space-between;
    padding: 18px 4px;
    border-radius: 0;
    font-size: clamp(26px, 7vw, 34px);
    font-weight: 800;
    color: var(--white);
  }
  .nav__link[aria-current="true"] { color: var(--gold); }
  .nav__chevron { width: 26px; height: 26px; }

  /* le voci salgono una dopo l'altra quando il pannello si apre */
  .nav__item { opacity: 0; translate: 0 24px; transition: opacity 0.2s, translate 0s linear 0.2s; }
  .site-header.is-open .nav__item {
    opacity: 1;
    translate: none;
    transition: opacity 0.5s var(--ease-out) calc(180ms + var(--i) * 60ms),
                translate 0.6s var(--ease-out) calc(180ms + var(--i) * 60ms);
  }

  /* la tendina diventa una fisarmonica */
  .nav__drop {
    position: static;
    width: auto;
    display: grid;
    grid-template-rows: 0fr;
    translate: none;
    transform: none;
    opacity: 1;
    visibility: visible;
    transition: grid-template-rows 0.4s var(--ease-out);
  }
  .nav__drop::before { display: none; }
  .nav__item--drop.is-open .nav__drop { grid-template-rows: 1fr; transition: grid-template-rows 0.45s var(--ease-out); }
  .nav__drop-inner {
    min-height: 0;
    overflow: hidden;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: none;
    box-shadow: none;
  }
  .nav__svcs { padding-bottom: 10px; }
  .nav__svc { font-size: 18px; padding: 6px 4px; }
  .nav__drop-all { justify-content: flex-start; margin: 0 0 16px; padding: 14px 4px 0; }
}
@media (max-width: 1100px) and (hover: hover) {
  .nav__link:hover { background: none; color: var(--gold); }
}

.brand {
  display: inline-block;
  text-decoration: none;
  border-radius: 8px;
}

.brand:focus-visible { outline: 3px solid var(--gold); outline-offset: 6px; }

.wordmark--header { font-size: 40px; }

/* L'header mostra il logo solo quando l'intro ci è "atterrato" sopra */
.js body.is-intro .wordmark--header { visibility: hidden; }

.js body:not(.is-revealed) :is(.header-cta, .nav__list, .nav-toggle) { opacity: 0; }
.is-revealed :is(.header-cta, .nav-toggle) { animation: fade-in 0.6s var(--ease-out) 0.7s both; }
@media (min-width: 1101px) {
  .is-revealed .nav__list { animation: fade-in 0.6s var(--ease-out) 0.8s both; }
}

/* ------------------------------------------------------------------
   ENTRATA DEGLI ELEMENTI (parte quando il logo vola nell'header)
   ------------------------------------------------------------------ */
.js body:not(.is-revealed) [data-reveal] { opacity: 0; }
.js body:not(.is-revealed) .line > span { transform: translateY(110%); }

.is-revealed [data-reveal] {
  animation: reveal-up 0.9s var(--ease-out) var(--d, 0ms) backwards;
}
.is-revealed [data-reveal="pop"] {
  animation: reveal-pop 1.1s var(--ease-spring) var(--d, 0ms) backwards;
}
/* le righe del titolo salgono da sotto una "maschera" */
.is-revealed .line[data-reveal] { animation: none; }
.is-revealed .line > span {
  animation: line-up 0.95s var(--ease-out) var(--d, 0ms) backwards;
}

@keyframes reveal-up {
  from { opacity: 0; transform: translateY(28px); }
  to   { opacity: 1; transform: none; }
}
@keyframes reveal-pop {
  from { opacity: 0; transform: translateY(40px) scale(0.85) rotate(4deg); }
  to   { opacity: 1; transform: none; }
}
@keyframes line-up {
  from { transform: translateY(110%); }
  to   { transform: none; }
}
@keyframes fade-in {
  from { opacity: 0; }
  to   { opacity: 1; }
}

/* ------------------------------------------------------------------
   HERO
   ------------------------------------------------------------------ */
.hero {
  max-width: 1320px;
  margin: 0 auto;
  padding: clamp(110px, 14vh, 150px) var(--gutter) clamp(48px, 8vw, 96px);
}

.hero__top {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  align-items: center;
  gap: clamp(24px, 4vw, 64px);
}

/* cartello "attenzione": nastro a strisce ai lati, come un segnale di pericolo */
.warning {
  --stripe: 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin: 0 0 28px;
  padding: 13px calc(var(--stripe) + 18px) 12px;
  border-radius: 8px;
  background:
    repeating-linear-gradient(-45deg, var(--purple-deep) 0 5px, var(--gold) 5px 10px) left / var(--stripe) 100% no-repeat,
    repeating-linear-gradient(-45deg, var(--purple-deep) 0 5px, var(--gold) 5px 10px) right / var(--stripe) 100% no-repeat,
    var(--gold);
  box-shadow: 0 4px 0 var(--purple-deep);
  /* viola scuro sull'oro: contrasto ~10:1, più nitido del viola pieno */
  color: var(--purple-deep);
  font-family: var(--font-brand);
  font-weight: 700;
  font-size: 22px;
  line-height: 1.2;
  letter-spacing: 0.02em;
  text-align: center;
}

.warning__icon { width: 28px; height: 28px; flex: none; }
.warning[hidden] { display: none; }

.hero__title {
  margin: 0;
  font-weight: 800;
  font-size: clamp(46px, 6.3vw, 96px);
  line-height: 0.98;
  letter-spacing: -0.01em;
}

.line {
  display: block;
  overflow: hidden;
  /* spazio per l'onda sotto "a galla" senza che la maschera la tagli */
  padding-bottom: 0.14em;
  margin-bottom: -0.14em;
}
.line > span { display: inline-block; }

.hl {
  position: relative;
  color: var(--gold);
}

.wave {
  position: absolute;
  left: 0;
  bottom: -0.1em;
  width: 92%;
  height: 0.2em;
  overflow: visible;
}
.wave path {
  fill: none;
  stroke: var(--gold);
  stroke-width: 5;
  stroke-linecap: round;
  stroke-dasharray: 340;
  stroke-dashoffset: 340;
}
.is-revealed .wave path { animation: draw 1.1s var(--ease-out) 1.05s forwards; }
@keyframes draw { to { stroke-dashoffset: 0; } }

.hero__lead {
  max-width: 33em;
  margin: 30px 0 0;
  font-family: var(--font-text);
  font-weight: 400;
  font-size: clamp(17px, 1.35vw, 20px);
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.82);
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px 16px;
  margin-top: 36px;
}

/* --- Mascotte --- */
.hero__visual {
  position: relative;
  width: min(100%, 520px);
  aspect-ratio: 1;
  justify-self: center;
}

.ring {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  animation: spin 38s linear infinite;
}
.ring text {
  fill: var(--gold);
  font-family: var(--font-brand);
  font-size: 22px;
  letter-spacing: 0.06em;
}
@keyframes spin { to { transform: rotate(360deg); } }

.mascot {
  position: absolute;
  inset: 19%;
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
  border-radius: 50%;
  -webkit-tap-highlight-color: transparent;
  transform: translate(var(--tx, 0px), var(--ty, 0px)) rotate(var(--rot, 0deg));
}
.mascot:focus-visible { outline: 3px solid var(--gold); outline-offset: 8px; }

.mascot__squash { display: block; transform-origin: 50% 90%; }

.mascot__img {
  display: block;
  width: 100%;
  height: auto;
  filter: drop-shadow(0 26px 30px rgba(20, 4, 50, 0.5));
  animation: bob 4.5s ease-in-out infinite;
}

@keyframes bob {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50%      { transform: translateY(-14px) rotate(-1.5deg); }
}

.quack {
  position: absolute;
  top: 8%;
  left: 2%;
  margin: 0;
  padding: 12px 20px 12px;
  border-radius: 22px;
  background: var(--white);
  color: var(--purple-deep);
  width: max-content;
  max-width: min(16em, 90%);
  font-size: clamp(17px, 1.6vw, 22px);
  line-height: 1.2;
  letter-spacing: 0.02em;
  text-align: center;
  pointer-events: none;
  transform-origin: 80% 100%;
  transform: scale(0) rotate(-8deg);
  opacity: 0;
}
.quack::after {
  /* punta del fumetto: triangolo tutto sotto il bordo, così non copre il testo */
  content: "";
  position: absolute;
  right: 18%;
  top: calc(100% - 1px);
  width: 22px;
  height: 13px;
  background: var(--white);
  clip-path: polygon(0 0, 100% 0, 50% 100%);
}
.quack.is-on {
  animation: quack-pop 2.6s var(--ease-spring) both;
}
@keyframes quack-pop {
  0%   { opacity: 0; transform: scale(0) rotate(-14deg); }
  12%  { opacity: 1; transform: scale(1) rotate(-6deg); }
  86%  { opacity: 1; transform: scale(1) rotate(-6deg); }
  100% { opacity: 0; transform: scale(0.85) rotate(-6deg) translateY(-8px); }
}

/* 5° tocco: la papera e l'anello se ne vanno */
/* scale/opacity separati dal transform, così la rotazione continua senza scatti */
.ring.is-leaving {
  opacity: 0;
  scale: 0.6;
  transition: opacity 0.6s, scale 0.7s var(--ease-out);
}
.mascot.is-gone { visibility: hidden; }

.told {
  position: absolute;
  inset: 4%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  outline: none;
}
.told[hidden] { display: none; }

.told__title {
  margin: 0;
  color: var(--gold);
  font-size: clamp(38px, 5vw, 70px);
  line-height: 0.95;
  transform: rotate(-4deg);
}
.told__text {
  max-width: 17em;
  margin: 22px 0 0;
  font-family: var(--font-text);
  font-weight: 400;
  font-size: clamp(17px, 1.5vw, 20px);
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.88);
}
.told__link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 18px;
  color: var(--gold);
  font-size: 18px;
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 6px;
}
.told__link:focus-visible { outline: 3px solid var(--white); outline-offset: 4px; border-radius: 6px; }
.told__link .btn__icon { animation: nudge-down 1.6s ease-in-out infinite; }
@keyframes nudge-down {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(4px); }
}

.told.is-on .told__title { animation: told-stamp 0.7s var(--ease-spring) backwards; }
.told.is-on .told__text  { animation: reveal-up 0.7s var(--ease-out) 0.35s backwards; }
.told.is-on .told__link  { animation: reveal-up 0.7s var(--ease-out) 0.55s backwards; }
@keyframes told-stamp {
  from { opacity: 0; transform: scale(1.8) rotate(-12deg); }
  to   { opacity: 1; transform: rotate(-4deg); }
}

/* ------------------------------------------------------------------
   LINEA DI SEZIONE (l'etichetta "Cosa facciamo", "Contatti"… è solo per i lettori di schermo)
   ------------------------------------------------------------------ */
/* resta solo la linea: il testo sta in uno .sr-only, nascosto alla vista
   ma letto dai lettori di schermo */
.section-label {
  display: flex;
  align-items: center;
  margin: 0 0 clamp(28px, 3vw, 40px);
}
.section-label::after {
  content: "";
  flex: 1;
  height: 2px;
  background: rgba(255, 255, 255, 0.14);
}

/* ------------------------------------------------------------------
   SERVIZI (dentro la hero)
   Ogni card ha due facce: davanti la papera, il nome e "Scopri di più";
   dietro la descrizione, "Seleziona servizio" e "Torna alla papera".
   ------------------------------------------------------------------ */
.services { margin-top: clamp(56px, 7vw, 96px); scroll-margin-top: 90px; }

/* --- DuckLink in numeri: il box orizzontale tra hero e servizi --- */
.stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin: 0 0 clamp(48px, 6vw, 80px);
  padding: clamp(22px, 3vw, 34px) clamp(12px, 3vw, 40px);
  list-style: none;
  border: 2px solid rgba(255, 255, 255, 0.14);
  border-radius: 26px;
  background: var(--purple-deep);
}

.stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 0 clamp(8px, 2vw, 24px);
  text-align: center;
}
/* separatore tratteggiato "da buono" tra un numero e l'altro */
.stat + .stat { border-left: 2px dashed rgba(228, 177, 56, 0.45); }

.stat__num {
  margin: 0;
  font-weight: 800;
  font-size: clamp(30px, 4.4vw, 60px);
  line-height: 1;
  letter-spacing: -0.01em;
  color: var(--gold);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.stat__plus { margin-right: 0.04em; }
.stat__unit { font-size: 0.5em; letter-spacing: 0; }

.stat__label {
  margin: 0;
  font-size: clamp(12px, 1.2vw, 16px);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.85);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.services__head { margin-bottom: clamp(28px, 4vw, 48px); text-align: center; }

.services__title {
  max-width: 16em;
  margin: 0 auto;
  font-weight: 800;
  font-size: clamp(36px, 4.6vw, 64px);
  line-height: 1.05;
  letter-spacing: -0.01em;
  text-wrap: balance;
}

.services__grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}

.service { perspective: 1600px; scroll-margin-top: 110px; }

/* le due facce stanno nella stessa cella: la card è alta quanto la faccia più alta */
.service__inner {
  display: grid;
  height: 100%;
  transform-style: preserve-3d;
  transition: transform 0.8s cubic-bezier(0.65, 0, 0.25, 1);
}
.service.is-flipped .service__inner { transform: rotateY(180deg); }

.service__face {
  grid-area: 1 / 1;
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 18px 18px 24px;
  border: 2px solid rgba(255, 255, 255, 0.14);
  border-radius: 26px;
  background: var(--purple);
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
}
.service__front {
  background-image: linear-gradient(rgba(255, 255, 255, 0.035), rgba(255, 255, 255, 0.035));
}
.service__back {
  transform: rotateY(180deg);
  padding: 52px 22px 22px;
  border-color: rgba(228, 177, 56, 0.6);
  background: var(--purple-deep);
}

.service__num {
  position: absolute;
  top: 20px;
  left: 24px;
  z-index: 3;
  font-size: 15px;
  letter-spacing: 0.1em;
  color: var(--gold);
}

/* --- Fronte --- */
/* niente riquadro né ombre: solo la papera. overflow: hidden resta
   perché all'entrata la papera "torna a galla" dal bordo inferiore */
.service__stage {
  position: relative;
  /* se il retro è più alto, lo spazio in più va sopra la papera
     e non sotto "Scopri di più" */
  flex: 1 0 auto;
  aspect-ratio: 1 / 0.8;
  overflow: hidden;
}

.service__duck {
  position: absolute;
  left: 6%;
  bottom: 0;
  width: 88%;
  height: auto;
}

.service__title,
.service__back-title {
  margin: 14px 0 0;
  font-weight: 700;
  font-size: clamp(22px, 2vw, 27px);
  line-height: 1.1;
  text-align: center;
}

/* --- Retro --- */
.service__back-title {
  margin: 0 0 14px;
  color: var(--gold);
  text-align: left;
}

.service__desc {
  margin: 0;
  font-family: var(--font-text);
  font-weight: 400;
  font-size: 15px;
  line-height: 1.55;
  color: rgba(255, 255, 255, 0.85);
}

.service__back .service__btn { margin-top: auto; }
.service__back .service__desc { margin-bottom: 20px; }

.service__return {
  align-self: center;
  margin-top: 14px;
  padding: 6px 4px;
  border: 0;
  background: none;
  color: rgba(255, 255, 255, 0.8);
  font-family: var(--font-brand);
  font-size: 15px;
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 5px;
  text-decoration-color: rgba(228, 177, 56, 0.6);
  cursor: pointer;
  transition: color 0.2s, text-decoration-color 0.2s;
}
@media (hover: hover) {
  .service__return:hover { color: var(--gold); text-decoration-color: var(--gold); }
}
.service__return:focus-visible { outline: 3px solid var(--white); outline-offset: 4px; border-radius: 6px; }

/* --- Pulsanti: al passaggio cambia solo colore --- */
.service__btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 58px;
  margin-top: 16px;
  padding: 16px 24px 15px;
  border: 0;
  border-radius: 999px;
  background: var(--gold);
  color: var(--purple);
  box-shadow: 0 5px 0 rgba(20, 4, 50, 0.55);
  font-family: var(--font-brand);
  font-size: 20px;
  line-height: 1.1;
  letter-spacing: 0.04em;
  text-align: center;
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition: background-color 0.25s, color 0.25s;
}

@media (hover: hover) {
  .service__btn:hover { background: var(--white); }
}
.service__btn:focus-visible {
  background: var(--white);
  outline: 3px solid var(--white);
  outline-offset: 4px;
}

/* --- Entrata dei servizi (services.js aggiunge .is-in quando entrano in vista) ---
   La card arriva da sotto inclinata, come una carta servita sul tavolo;
   la papera "torna a galla" dal fondo del riquadro con un piccolo dondolio;
   poi salgono il nome e il bottone. --sd è il ritardo a cascata. */
.js .services__head:not(.is-in),
.js .stats:not(.is-in) { opacity: 0; translate: 0 28px; }
.js .services__head,
.js .stats {
  transition: opacity 0.7s var(--ease-out), translate 0.9s var(--ease-out);
}

.js .service:not(.is-in) {
  opacity: 0;
  transform: perspective(1200px) translateY(90px) rotateX(26deg) scale(0.92);
}
.js .service {
  transform-origin: 50% 100%;
  transition: opacity 0.6s var(--ease-out) var(--sd, 0ms),
              transform 1s var(--ease-out) var(--sd, 0ms);
}
.js .service:not(.is-in) :is(.service__duck, .service__num, .service__title, .service__front .service__btn) { opacity: 0; }

.service.is-in .service__duck {
  animation: duck-surface 1.1s var(--ease-out) calc(var(--sd, 0ms) + 220ms) backwards;
  transform-origin: 50% 100%;
}
.service.is-in .service__num   { animation: fade-in 0.5s ease calc(var(--sd, 0ms) + 300ms) backwards; }
.service.is-in .service__title { animation: reveal-up 0.7s var(--ease-out) calc(var(--sd, 0ms) + 420ms) backwards; }
.service.is-in .service__front .service__btn { animation: reveal-up 0.7s var(--ease-out) calc(var(--sd, 0ms) + 520ms) backwards; }

@keyframes duck-surface {
  0%   { opacity: 0; transform: translateY(80%) rotate(-10deg); }
  45%  { opacity: 1; transform: translateY(-7%) rotate(5deg); }
  70%  { transform: translateY(2%) rotate(-3deg); }
  85%  { transform: translateY(-1%) rotate(1deg); }
  100% { transform: none; }
}

/* ------------------------------------------------------------------
   LO SAPEVI?
   La Papera Maestra al centro, sei punti attorno su un'orbita.
   Ogni punto apre una scheda al centro (la papera si fa da parte).
   ------------------------------------------------------------------ */
.facts {
  max-width: 1320px;
  margin: 0 auto;
  padding: clamp(64px, 9vw, 120px) var(--gutter) clamp(24px, 4vw, 48px);
  scroll-margin-top: 70px;
}

.facts__head { text-align: center; }

.facts__title {
  margin: 0;
  font-weight: 800;
  font-size: clamp(38px, 4.6vw, 64px);
  line-height: 1;
  letter-spacing: -0.01em;
}

.facts__stage {
  --dot: 56px;
  position: relative;
  display: grid;
  width: min(100%, 620px);
  aspect-ratio: 1;
  margin: clamp(24px, 4vw, 48px) auto 0;
}

.facts__orbit {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: visible;
  animation: spin 60s linear infinite;
}
.facts__orbit circle {
  fill: rgba(255, 255, 255, 0.03);
  stroke: rgba(228, 177, 56, 0.45);
  stroke-width: 0.4;
  stroke-dasharray: 1.2 2.2;
  stroke-linecap: round;
}

.facts__duck {
  grid-area: 1 / 1;
  place-self: center;
  width: 60%;
  height: auto;
  filter: drop-shadow(0 26px 30px rgba(20, 4, 50, 0.5));
  transition: opacity 0.35s, transform 0.5s var(--ease-out);
}
.facts.is-open .facts__duck { opacity: 0.15; transform: scale(0.9); }

/* --- I punti: angolo --a, raggio 42% (come l'orbita) --- */
.facts__dot {
  position: absolute;
  z-index: 2;
  left: calc(50% + cos(var(--a)) * 42%);
  top: calc(50% + sin(var(--a)) * 42%);
  display: grid;
  place-items: center;
  width: var(--dot);
  height: var(--dot);
  margin: calc(var(--dot) / -2) 0 0 calc(var(--dot) / -2);
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: var(--gold);
  color: var(--purple);
  box-shadow: 0 5px 0 var(--purple-deep);
  font-family: var(--font-brand);
  font-weight: 800;
  font-size: 26px;
  line-height: 1;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition: transform 0.25s var(--ease-spring), background-color 0.25s, color 0.25s, box-shadow 0.25s;
}
/* anello che "chiama" il clic, finché non se ne apre uno */
.facts__dot::before {
  content: "";
  position: absolute;
  inset: -6px;
  border: 2px solid var(--gold);
  border-radius: 50%;
  opacity: 0;
  pointer-events: none;
}
.facts.is-in:not(.is-touched) .facts__dot::before {
  animation: dot-call 2.4s var(--ease-out) calc(var(--i) * 0.4s + 1.2s) infinite;
}
@keyframes dot-call {
  0%   { opacity: 0.8; transform: scale(0.9); }
  70%, 100% { opacity: 0; transform: scale(1.5); }
}

@media (hover: hover) {
  .facts__dot:hover { transform: translateY(-3px) scale(1.06); }
}
.facts__dot:focus-visible { outline: 3px solid var(--white); outline-offset: 4px; }
.facts__dot.is-seen {
  background: var(--purple-deep);
  color: var(--gold);
  box-shadow: 0 0 0 2px var(--gold), 0 5px 0 var(--purple-deep);
}
.facts__dot[aria-expanded="true"] {
  background: var(--white);
  color: var(--purple);
  box-shadow: 0 5px 0 var(--purple-deep);
  transform: scale(1.12);
}

/* --- La scheda --- */
.facts__card {
  grid-area: 1 / 1;
  place-self: center;
  position: relative;
  z-index: 3;
  width: min(62%, 400px);
  padding: 26px 26px 20px;
  border: 2px solid rgba(228, 177, 56, 0.6);
  border-radius: 26px;
  background: var(--purple-deep);
  box-shadow: 0 24px 50px rgba(20, 4, 50, 0.5);
  transform-origin: calc(50% + cos(var(--a, 0deg)) * 50%) calc(50% + sin(var(--a, 0deg)) * 50%);
}
.facts__card[hidden] { display: none; }
.facts__card.is-on { animation: card-pop 0.5s var(--ease-spring) backwards; }
@keyframes card-pop {
  from { opacity: 0; transform: scale(0.4); }
}
/* cambiando fatto con le frecce il testo scorre di lato */
.facts__card-body.is-swap { animation: card-swap 0.4s var(--ease-out) backwards; }
@keyframes card-swap {
  from { opacity: 0; transform: translateX(calc(var(--dir, 1) * 24px)); }
}

.facts__close {
  position: absolute;
  top: 10px;
  right: 10px;
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  padding: 0 0 3px;
  border: 0;
  border-radius: 50%;
  background: none;
  color: rgba(255, 255, 255, 0.75);
  font-size: 30px;
  line-height: 1;
  cursor: pointer;
  transition: color 0.2s, background-color 0.2s;
}
.facts__close:hover { color: var(--white); background: rgba(255, 255, 255, 0.08); }
.facts__close:focus-visible { outline: 3px solid var(--white); outline-offset: 2px; }

.fact { list-style: none; }

.fact__eyebrow {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin: 0 40px 12px 0;
  font-size: 15px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gold);
}
.fact__num {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.6);
  font-variant-numeric: tabular-nums;
}

.fact__text {
  margin: 0;
  font-weight: 600;
  font-size: clamp(18px, 1.7vw, 22px);
  line-height: 1.4;
  text-wrap: pretty;
}
.fact__text strong { font-weight: 800; color: var(--gold); }

.facts__card-nav {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 18px;
}
.facts__step {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  background: none;
  color: var(--white);
  cursor: pointer;
  transition: border-color 0.2s, background-color 0.2s, color 0.2s;
}
.facts__step[data-step="-1"] .btn__icon { transform: rotate(180deg); }
@media (hover: hover) {
  .facts__step:hover { border-color: var(--gold); background: var(--gold); color: var(--purple); }
}
.facts__step:focus-visible { outline: 3px solid var(--white); outline-offset: 3px; }

.facts__progress {
  margin: clamp(20px, 3vw, 32px) 0 0;
  text-align: center;
  font-size: 13px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.6);
}
.facts__progress a {
  color: var(--gold);
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 5px;
}
.facts__progress a:focus-visible { outline: 3px solid var(--white); outline-offset: 4px; border-radius: 6px; }

/* con JS: l'elenco resta nascosto, i fatti si leggono nella scheda */
.js .facts__list { display: none; }

/* entrata: la papera sale, i punti spuntano uno alla volta */
.js .facts:not(.is-in) .facts__duck { opacity: 0; transform: translateY(32px) scale(0.92); }
.js .facts:not(.is-in) .facts__dot { opacity: 0; transform: scale(0); }
.js .facts .facts__dot.is-entering {
  transition: opacity 0.3s, transform 0.6s var(--ease-spring);
  transition-delay: calc(var(--i) * 90ms + 250ms);
}

/* senza JS: niente punti né scheda, i sei fatti in griglia sotto la papera */
html:not(.js) .facts__dot,
html:not(.js) .facts__card,
html:not(.js) .facts__progress { display: none; }
html:not(.js) .facts__stage { aspect-ratio: auto; width: 100%; }
html:not(.js) .facts__orbit { display: none; }
html:not(.js) .facts__duck { width: min(60%, 320px); }
html:not(.js) .facts__list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
  margin: 32px 0 0;
  padding: 0;
}
html:not(.js) .fact {
  padding: 24px;
  border: 2px solid rgba(255, 255, 255, 0.14);
  border-radius: 26px;
}

/* ------------------------------------------------------------------
   PROMOZIONI
   A sinistra la Papera Promo, a destra un carosello: la card attiva
   al centro, le due vicine ai lati più piccole e sfocate.
   promo.js dà a ogni card --o (distanza dalla attiva, −2…2) e --abs.
   ------------------------------------------------------------------ */
.promo {
  max-width: 1320px;
  margin: 0 auto;
  padding: clamp(64px, 9vw, 120px) var(--gutter) clamp(24px, 4vw, 48px);
  scroll-margin-top: 70px;
  /* le card nascoste ai lati non devono allargare la pagina */
  overflow-x: clip;
}

.promo__head { text-align: center; }

.promo__title {
  max-width: 16em;
  margin: 0 auto;
  font-weight: 800;
  font-size: clamp(36px, 4.6vw, 64px);
  line-height: 1.05;
  letter-spacing: -0.01em;
  text-wrap: balance;
}

.promo__grid {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  align-items: center;
  gap: clamp(24px, 4vw, 56px);
  margin-top: clamp(28px, 4vw, 48px);
}

.promo__duck {
  display: block;
  justify-self: center;
  width: min(100%, 440px);
  height: auto;
  filter: drop-shadow(0 26px 30px rgba(20, 4, 50, 0.5));
  animation: bob 4.5s ease-in-out infinite;
}

/* --- Carosello --- */
.promo__carousel {
  --card: min(48%, 360px);
  --shift: 74%;                    /* quanto si spostano le card laterali (della loro larghezza) */
  position: relative;
  min-width: 0;
  outline: none;
}

.promo__track {
  display: grid;
  padding: 12px 0 18px;
  touch-action: pan-y;
}

.promo-card {
  --o: 0;
  --abs: 0;
  grid-area: 1 / 1;
  justify-self: center;
  position: relative;
  display: flex;
  flex-direction: column;
  width: var(--card);
  min-height: 470px;               /* tutte alte uguali: la griglia le allinea alla più alta */
  padding: 26px 24px 24px;
  border: 2px solid rgba(255, 255, 255, 0.14);
  border-radius: 26px;
  background: var(--purple-deep);
  background-image: radial-gradient(90% 50% at 50% 0%, rgba(228, 177, 56, 0.12), transparent 70%);
  z-index: calc(10 - var(--abs));
  transform: translateX(calc(var(--o) * var(--shift))) scale(calc(1 - var(--abs) * 0.18));
  filter: blur(calc(var(--abs) * 3px)) brightness(calc(1 - var(--abs) * 0.28));
  opacity: calc(1 - max(0, var(--abs) - 1));
  transition: transform 0.7s var(--ease-out), filter 0.7s var(--ease-out),
              opacity 0.5s var(--ease-out), border-color 0.4s;
  -webkit-tap-highlight-color: transparent;
  user-select: none;
}

.js .promo-card:not(.is-active) { cursor: pointer; }
@media (hover: hover) {
  .js .promo-card:not(.is-active):hover { filter: blur(calc(var(--abs) * 1.5px)) brightness(calc(1 - var(--abs) * 0.15)); }
}

.promo-card.is-active { border-color: var(--gold); }

/* bordo tratteggiato "da buono sconto" tra intestazione e testo */
.promo-card__tag {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin: 0;
  padding-bottom: 16px;
  border-bottom: 2px dashed rgba(228, 177, 56, 0.45);
  font-size: 14px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold);
}
.promo-card__tag span {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.6);
  font-variant-numeric: tabular-nums;
}

.promo-card__title {
  margin: 20px 0 0;
  font-weight: 800;
  font-size: clamp(28px, 2.7vw, 36px);
  line-height: 1.05;
  text-wrap: balance;
}

.promo-card__desc {
  margin: 14px 0 0;
  font-family: var(--font-text);
  font-weight: 400;
  font-size: 16px;
  line-height: 1.55;
  color: rgba(255, 255, 255, 0.85);
}

.promo-card__desc strong { font-weight: 700; color: var(--gold); }

/* prezzo: il nuovo grande in oro, il vecchio barrato accanto */
.promo-card__price {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin: auto 0 0;
  padding: 18px 0 20px;
}
.promo-card__now {
  font-weight: 800;
  font-size: clamp(38px, 3.4vw, 48px);
  line-height: 1;
  letter-spacing: -0.01em;
  color: var(--gold);
}
.promo-card__was {
  font-family: var(--font-text);
  font-weight: 400;
  font-size: 16px;
  color: rgba(255, 255, 255, 0.7);
}

.promo-card__btn {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 0;
  min-height: 54px;
  padding: 14px 20px 13px;
  border-radius: 999px;
  background: var(--gold);
  color: var(--purple);
  box-shadow: 0 5px 0 rgba(20, 4, 50, 0.55);
  font-size: 16px;
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: 0.04em;
  text-align: center;
  text-transform: uppercase;
  text-decoration: none;
  transition: background-color 0.25s;
}
@media (hover: hover) {
  .promo-card.is-active .promo-card__btn:hover { background: var(--white); }
}
.promo-card__btn:focus-visible { background: var(--white); outline: 3px solid var(--white); outline-offset: 4px; }
/* le card laterali si cliccano intere per portarle al centro */
.js .promo-card:not(.is-active) .promo-card__btn { pointer-events: none; }

/* la card che arriva al centro fa un piccolo salto e il testo sale */
.promo-card.is-arriving .promo-card__title,
.promo-card.is-arriving .promo-card__desc {
  animation: reveal-up 0.6s var(--ease-out) backwards;
}
.promo-card.is-arriving .promo-card__price {
  animation: reveal-up 0.6s var(--ease-out) backwards;
}
.promo-card.is-arriving .promo-card__desc { animation-delay: 80ms; }
.promo-card.is-arriving .promo-card__price { animation-delay: 160ms; }

/* --- Frecce e puntini --- */
.promo__controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  margin-top: 10px;
}

.promo__arrow {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  padding: 0;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  background: none;
  color: var(--white);
  cursor: pointer;
  transition: border-color 0.2s, background-color 0.2s, color 0.2s;
}
.promo__arrow[data-move="-1"] .btn__icon { transform: rotate(180deg); }
@media (hover: hover) {
  .promo__arrow:hover { border-color: var(--gold); background: var(--gold); color: var(--purple); }
}
.promo__arrow:focus-visible { outline: 3px solid var(--white); outline-offset: 3px; }

.promo__dots { display: flex; gap: 4px; }
.promo__dot {
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
}
.promo__dot::before {
  content: "";
  width: 24px;
  height: 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.3);
  /* la pillola si allunga con clip-path: niente ricalcolo del layout */
  clip-path: inset(0 7px round 999px);
  transition: clip-path 0.4s var(--ease-out), background-color 0.3s;
}
.promo__dot[aria-current="true"]::before { clip-path: inset(0 0 round 999px); background: var(--gold); }
.promo__dot:focus-visible { outline: 3px solid var(--white); outline-offset: 2px; border-radius: 8px; }

.promo__status {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

/* senza JS: le card in fila, si scorrono di lato */
html:not(.js) .promo__controls { display: none; }
html:not(.js) .promo__track {
  display: flex;
  gap: 16px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
}
html:not(.js) .promo-card {
  flex: 0 0 min(80%, 320px);
  scroll-snap-align: center;
}

/* entrata: la papera sale, le card si aprono a ventaglio dal centro */
.js .promo:not(.is-in) .promo__duck { opacity: 0; translate: 0 32px; scale: 0.92; }
.js .promo:not(.is-in) .promo-card { opacity: 0; transform: translateX(0) scale(0.8); }
/* translate/scale separati dal transform, così l'entrata non interrompe il dondolio */
.js .promo__duck { transition: opacity 0.7s var(--ease-out), translate 0.9s var(--ease-out), scale 0.9s var(--ease-out); }

/* ------------------------------------------------------------------
   CONTATTI
   ------------------------------------------------------------------ */
.contact {
  max-width: 1320px;
  margin: 0 auto;
  padding: clamp(64px, 9vw, 120px) var(--gutter) clamp(24px, 4vw, 48px);
  scroll-margin-top: 70px;
}

.contact__grid {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
  grid-template-areas:
    "head head"
    "duck form";
  align-items: center;
  gap: clamp(28px, 4vw, 48px) clamp(28px, 5vw, 72px);
}
.contact__head { grid-area: head; text-align: center; }
.contact__duck { grid-area: duck; }
.cform { grid-area: form; }

.contact__title {
  margin: 0;
  font-weight: 800;
  font-size: clamp(38px, 4.6vw, 64px);
  line-height: 1;
  letter-spacing: -0.01em;
}

.contact__duck {
  display: block;
  justify-self: center;
  width: min(100%, 460px);
  height: auto;
  filter: drop-shadow(0 26px 30px rgba(20, 4, 50, 0.5));
}

/* --- Il form a step --- */
.cform {
  position: relative;
  padding: clamp(22px, 3vw, 36px);
  border: 2px solid rgba(255, 255, 255, 0.14);
  border-radius: 26px;
  background: rgba(255, 255, 255, 0.035);
}

/* barra di avanzamento 1 · 2 · 3 */
.cform__progress { padding: 4px 6px 0; }

.cform__track {
  --p: 0;                          /* 0 → 0.5 → 1, impostato dal JS */
  position: relative;
  height: 4px;
  margin: 0 14px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.14);
}
.cform__track-fill {
  position: absolute;
  inset: 0 auto 0 0;
  width: calc(var(--p) * 100%);
  border-radius: inherit;
  background: var(--gold);
  transition: width 0.6s var(--ease-out);
}

.cform__dot {
  position: absolute;
  top: 50%;
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  margin: -14px 0 0 -14px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  background: var(--purple);
  color: rgba(255, 255, 255, 0.7);
  font-size: 13px;
  line-height: 1;
  transition: background-color 0.3s, border-color 0.3s, color 0.3s;
}
.cform__dot[data-dot="1"] { left: 0; }
.cform__dot[data-dot="2"] { left: 50%; }
.cform__dot[data-dot="3"] { left: 100%; }
.cform__dot.is-done {
  background: var(--gold);
  border-color: var(--gold);
  color: var(--purple);
}

.cform__count {
  margin: 22px 0 0;
  font-size: 13px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.6);
}

/* gli step stanno uno sopra l'altro: l'altezza resta quella del più alto */
.cform__steps { display: grid; margin-top: 10px; }

.cform__step {
  grid-area: 1 / 1;
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
}

.js .cform__step {
  opacity: 0;
  visibility: hidden;
  transform: translateX(48px);
  transition: opacity 0.3s, transform 0.5s var(--ease-out), visibility 0s linear 0.5s;
}
.js .cform__step.is-past { transform: translateX(-48px); }
.js .cform__step.is-current {
  opacity: 1;
  visibility: visible;
  transform: none;
  transition: opacity 0.45s 0.12s, transform 0.6s var(--ease-out) 0.12s, visibility 0s;
}
html:not(.js) .cform__done,
html:not(.js) .cform__progress,
html:not(.js) .cform__count,
html:not(.js) .cform [data-next],
html:not(.js) .cform [data-prev] { display: none; }

.cform__q {
  float: left;                     /* il legend smette di "bucare" il bordo del fieldset */
  width: 100%;
  margin: 0 0 22px;
  padding: 0;
  font-size: clamp(26px, 2.6vw, 34px);
  line-height: 1.05;
}
.cform__q + * { clear: both; }

.cform__hint {
  margin: -12px 0 18px;
  font-family: var(--font-text);
  font-weight: 400;
  font-size: 15px;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.7);
}

.cform__row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

/* --- Campi --- */
.field { display: flex; flex-direction: column; }

.field__label {
  margin-bottom: 8px;
  font-size: 15px;
  color: var(--white);
}
.field__opt {
  font-family: var(--font-text);
  font-weight: 400;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.6);
}

.field__input {
  width: 100%;
  padding: 15px 18px;
  border: 2px solid rgba(255, 255, 255, 0.2);
  border-radius: 16px;
  background: rgba(43, 13, 102, 0.55);
  color: var(--white);
  font-family: var(--font-text);
  font-weight: 400;
  font-size: 16px;
  line-height: 1.4;
  transition: border-color 0.2s, background-color 0.2s;
}
.field__input::placeholder { color: rgba(255, 255, 255, 0.45); }
.field__input:hover { border-color: rgba(255, 255, 255, 0.35); }
.field__input:focus {
  outline: none;
  border-color: var(--gold);
  background: rgba(43, 13, 102, 0.8);
}
.field__input--area { min-height: 132px; resize: vertical; }

.field__counter {
  align-self: flex-end;
  margin: 6px 4px 0;
  font-family: var(--font-text);
  font-weight: 400;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.5);
  font-variant-numeric: tabular-nums;
}

.field__error {
  display: none;
  margin: 8px 4px 0;
  font-family: var(--font-text);
  font-size: 14px;
  font-weight: 600;
  color: #FFB4A6;
}
.field__error.is-shown { display: block; animation: nudge 0.4s var(--ease-out); }
.field__input[aria-invalid="true"] { border-color: #FFB4A6; }
@keyframes nudge {
  0%   { transform: translateX(0); }
  25%  { transform: translateX(-5px); }
  60%  { transform: translateX(4px); }
  100% { transform: translateX(0); }
}

/* --- Servizi a scelta multipla --- */
.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.chip { position: relative; cursor: pointer; }
.chip input {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
}
.chip span {
  display: inline-flex;
  align-items: center;
  gap: 0;
  padding: 12px 18px 11px;
  border: 2px solid rgba(255, 255, 255, 0.25);
  border-radius: 999px;
  font-size: 17px;
  line-height: 1;
  user-select: none;
  transition: background-color 0.25s, border-color 0.25s, color 0.25s, gap 0.3s var(--ease-out);
}
/* la spunta "si apre" dentro la pillola quando il servizio è scelto */
.chip span::before {
  content: "";
  width: 0;
  height: 7px;
  border-left: 2.5px solid currentColor;
  border-bottom: 2.5px solid currentColor;
  opacity: 0;
  transform: rotate(-45deg) translateY(-2px);
  transition: width 0.3s var(--ease-out), opacity 0.2s;
}
@media (hover: hover) {
  .chip:hover span { border-color: rgba(255, 255, 255, 0.55); }
}
.chip input:checked + span {
  gap: 9px;
  background: var(--gold);
  border-color: var(--gold);
  color: var(--purple);
}
.chip input:checked + span::before { width: 12px; opacity: 1; }
.chip input:focus-visible + span { outline: 3px solid var(--white); outline-offset: 3px; }

/* --- Navigazione tra gli step --- */
.cform__nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 14px 20px;
  margin-top: 28px;
}
.cform__nav:has([data-prev]) { justify-content: space-between; }

.cform__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}
.cform__actions .btn--ghost { cursor: pointer; }

.cform__back {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 4px;
  border: 0;
  background: none;
  color: rgba(255, 255, 255, 0.75);
  font-family: var(--font-brand);
  font-size: 16px;
  cursor: pointer;
  transition: color 0.2s;
}
.cform__back .btn__icon { transform: rotate(180deg); }
.cform__back:hover { color: var(--white); }
.cform__back:hover .btn__icon { transform: rotate(180deg) translateX(4px); }
.cform__back:focus-visible { outline: 3px solid var(--white); outline-offset: 4px; border-radius: 8px; }

/* --- Conferma --- */
.cform__done {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  outline: none;
}
.cform__done .cform__q { margin-bottom: 18px; }
.cform__done .cform__hint { margin: 0; }
.cform__done-head {
  width: 64px;
  height: 50px;
  margin-bottom: 18px;
  overflow: visible;
  transform-origin: 38% 90%;
}
.cform__done.is-current .cform__done-head { animation: done-pop 0.9s var(--ease-spring) 0.2s backwards; }
@keyframes done-pop {
  0%   { transform: scale(0) rotate(-20deg); }
  55%  { transform: scale(1.1) rotate(8deg); }
  75%  { transform: rotate(-6deg); }
  100% { transform: none; }
}

/* ------------------------------------------------------------------
   RECENSIONI
   Carosello ad anello che si gira solo con le frecce. Le card stanno
   tutte nella stessa cella: reviews.js dà a ognuna --o (distanza "ad
   anello" dalla attiva, −4…4) e --ap (il suo valore assoluto). Il CSS le
   sposta di lato e le ruota attorno a un perno lontano sotto di loro,
   come se stessero su una grande ruota; oltre ±3 spariscono, così chi
   fa il giro dell'anello passa da un lato all'altro senza farsi vedere.
   ------------------------------------------------------------------ */
.reviews {
  max-width: 1320px;
  margin: 0 auto;
  padding: clamp(64px, 9vw, 120px) var(--gutter) clamp(72px, 10vw, 128px);
  scroll-margin-top: 70px;
}

.reviews__title {
  max-width: 16em;
  margin: 0 auto;
  text-align: center;
  font-weight: 800;
  font-size: clamp(36px, 4.6vw, 64px);
  line-height: 1.05;
  letter-spacing: -0.01em;
  text-wrap: balance;
}
.reviews__title .hl { white-space: nowrap; }

/* la fila esce dai margini della sezione e occupa tutta la finestra;
   le frecce stanno nella stessa cella, ai fianchi della card centrale */
.reviews__rail {
  --card: min(80vw, 370px);
  --gap: 112px;                    /* abbastanza largo da tenerci la freccia */
  display: grid;
  isolation: isolate;               /* gli z-index delle card restano qui dentro */
  margin: clamp(20px, 3vw, 36px) calc(50% - 50vw) -48px;
  padding: 24px 0 96px;
  overflow-x: clip;
}

.reviews__track {
  display: grid;
  grid-area: 1 / 1;
  margin: 0;
  padding: 0;
  list-style: none;
}

.review {
  --o: 0;
  --ap: 0;
  grid-area: 1 / 1;
  justify-self: center;
  display: flex;
  width: var(--card);
  transform-origin: 50% 320%;
  transform: translateX(calc(var(--o) * (var(--card) + var(--gap))))
             rotate(calc(var(--o) * 3.5deg))
             scale(calc(1 - var(--ap) * 0.08));
  opacity: calc(1 - var(--ap) * 0.28);
  transition: transform 0.75s var(--ease-out), opacity 0.5s var(--ease-out);
}

.review__card {
  position: relative;
  display: flex;
  flex-direction: column;
  width: 100%;
  margin: 0;
  padding: 30px 28px 26px;
  border: 2px solid rgba(255, 255, 255, 0.14);
  border-radius: 26px;
  background: var(--purple-deep);
  box-shadow: 0 18px 30px rgba(20, 4, 50, 0.35);
  transition: border-color 0.4s, background-color 0.4s;
}
.review.is-active .review__card { border-color: var(--gold); }

.review__quote {
  width: 46px;
  height: 35px;
  color: var(--gold);
  transition: transform 0.6s var(--ease-spring);
}
.review:not(.is-active) .review__quote { transform: scale(0.8); }

.review__text {
  flex: 1;
  margin: 20px 0 0;
}
.review__text p {
  margin: 0;
  font-family: var(--font-text);
  font-weight: 400;
  font-size: 17px;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.88);
}

.review__author {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 24px;
  padding-top: 20px;
  border-top: 2px dashed rgba(228, 177, 56, 0.45);
}

.review__avatar {
  display: grid;
  place-items: center;
  flex: none;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--gold);
  color: var(--purple);
  font-weight: 800;
  font-size: 16px;
  letter-spacing: 0.02em;
}

.review__name {
  font-weight: 700;
  font-size: 18px;
}

/* --- Frecce ai fianchi della card centrale --- */
.reviews__arrow {
  --side: -1;
  grid-area: 1 / 1;
  align-self: center;
  justify-self: center;
  z-index: 20;
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: var(--gold);
  color: var(--purple);
  box-shadow: 0 5px 0 rgba(20, 4, 50, 0.55);
  /* di base a metà dello spazio tra le card; da telefono sul bordo della card */
  translate: calc(var(--side) * var(--arrow-x, calc(var(--card) / 2 + var(--gap) / 2))) 0;
  cursor: pointer;
  transition: background-color 0.2s, scale 0.15s var(--ease-out);
  -webkit-tap-highlight-color: transparent;
}
.reviews__arrow[data-move="1"] { --side: 1; }
.reviews__arrow[data-move="-1"] .btn__icon { transform: rotate(180deg); }
.reviews__arrow:active { scale: 0.92; }
@media (hover: hover) {
  .reviews__arrow:hover { background: var(--white); }
}
.reviews__arrow:focus-visible { background: var(--white); outline: 3px solid var(--white); outline-offset: 4px; }

.reviews__status {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

/* senza JS: niente frecce, le card in fila si scorrono di lato */
html:not(.js) .reviews__arrow { display: none; }
html:not(.js) .reviews__track {
  display: flex;
  gap: 16px;
  padding: 0 calc(50% - var(--card) / 2);
  overflow-x: auto;
  scroll-snap-type: x mandatory;
}
html:not(.js) .review { flex: 0 0 var(--card); transform: none; opacity: 1; scroll-snap-align: center; }

/* --- Entrata: l'onda si disegna, le card salgono una dopo l'altra --- */
.reviews .wave path { stroke-dashoffset: 0; }
.is-revealed .reviews .wave path { animation: none; }
.js .reviews:not(.is-in) .wave path { stroke-dashoffset: 340; }
.js .reviews .wave path { transition: stroke-dashoffset 1.1s var(--ease-out) 0.3s; }
.js .reviews:not(.is-in) .review__card { opacity: 0; translate: 0 48px; }
.js .review__card {
  transition: opacity 0.6s var(--ease-out), translate 0.9s var(--ease-out),
              border-color 0.4s, background-color 0.4s;
  transition-delay: calc(min(var(--ap), 3) * 90ms), calc(min(var(--ap), 3) * 90ms), 0s, 0s;
}
.js .reviews.is-settled .review__card { transition-delay: 0s; }

/* ------------------------------------------------------------------
   FOOTER
   In cima un'onda: la papera ci galleggia sopra (cliccandola si torna su).
   Sotto: logo e slogan, menu, servizi, contatti; in fondo il copyright.
   ------------------------------------------------------------------ */
.site-footer {
  --shadow: rgba(0, 0, 0, 0.45);   /* l'ombra "a blocco" dei bottoni sul viola scuro */
  position: relative;
  z-index: 5;                       /* sopra le card delle recensioni: la papera si vede sempre */
  margin-top: clamp(56px, 7vw, 96px);
  background: var(--purple-deep);
}

.footer__wave {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 100%;
  height: clamp(36px, 5vw, 72px);
  margin-bottom: -1px;               /* niente fessura tra onda e footer */
  pointer-events: none;
}
.footer__wave svg { display: block; width: 100%; height: 100%; }
.footer__wave path { fill: var(--purple-deep); }

/* la papera sta a cavallo dell'onda e dondola */
.footer__duck {
  position: absolute;
  right: clamp(24px, 8vw, 140px);
  bottom: calc(100% - clamp(14px, 2vw, 26px));   /* seduta sull'acqua */
  z-index: 1;
  display: block;
  width: clamp(88px, 10vw, 140px);
  border-radius: 50%;
  -webkit-tap-highlight-color: transparent;
}
.footer__duck img {
  display: block;
  width: 100%;
  height: auto;
  filter: drop-shadow(0 10px 8px rgba(0, 0, 0, 0.25));
  animation: bob 4.5s ease-in-out infinite;
}
.footer__duck:focus-visible { outline: 3px solid var(--gold); outline-offset: 6px; }

/* fumetto "Torna su!" al passaggio del mouse */
.footer__duck-tip {
  position: absolute;
  right: 70%;
  bottom: 78%;
  padding: 8px 14px 7px;
  border-radius: 999px 999px 4px 999px;
  background: var(--white);
  color: var(--purple);
  font-size: 15px;
  white-space: nowrap;
  opacity: 0;
  transform: translateY(6px) scale(0.9);
  transform-origin: 100% 100%;
  transition: opacity 0.2s, transform 0.3s var(--ease-spring);
  pointer-events: none;
}
@media (hover: hover) {
  .footer__duck:hover .footer__duck-tip { opacity: 1; transform: none; }
}
.footer__duck:focus-visible .footer__duck-tip { opacity: 1; transform: none; }

.footer__inner {
  max-width: 1320px;
  margin: 0 auto;
  padding: clamp(48px, 6vw, 80px) var(--gutter) 28px;
}

.footer__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) repeat(3, minmax(0, 1fr));
  gap: clamp(32px, 4vw, 56px);
}

/* il wordmark sul viola scuro: il contorno della "link" segue lo sfondo */
.footer__logo { display: inline-block; border-radius: 8px; text-decoration: none; }
.footer__logo:focus-visible { outline: 3px solid var(--gold); outline-offset: 6px; }
.wordmark--footer { --purple: var(--purple-deep); font-size: 56px; }

.footer__tagline {
  margin: 24px 0 0;
  font-weight: 800;
  font-size: clamp(22px, 2vw, 28px);
  line-height: 1.15;
}

.footer__cta { margin-top: 28px; font-size: 18px; }

.footer__heading {
  margin: 0 0 18px;
  font-size: 14px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold);
}

.footer__links {
  display: grid;
  gap: 4px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.footer__links a {
  display: inline-block;
  padding: 5px 0;
  color: rgba(255, 255, 255, 0.82);
  font-size: 16px;
  text-decoration: none;
  transition: color 0.2s, transform 0.25s var(--ease-out);
}
@media (hover: hover) {
  .footer__links a:hover { color: var(--gold); transform: translateX(4px); }
}
.footer__links a:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; border-radius: 4px; }

.footer__text {
  margin: 0;
  font-family: var(--font-text);
  font-weight: 400;
  font-size: 16px;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.82);
}

.footer__more,
.footer__top {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--gold);
  font-size: 16px;
  text-decoration: none;
}
.footer__more { margin-top: 16px; }
@media (hover: hover) {
  .footer__more:hover .btn__icon { transform: translateX(4px); }
  .footer__top:hover .btn__icon { transform: rotate(180deg) translateY(3px); }
}
.footer__more:focus-visible,
.footer__top:focus-visible { outline: 3px solid var(--gold); outline-offset: 4px; border-radius: 4px; }
.footer__top .btn__icon { transform: rotate(180deg); }

.footer__bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 24px;
  margin-top: clamp(40px, 5vw, 64px);
  padding-top: 24px;
  border-top: 2px dashed rgba(228, 177, 56, 0.35);
}

.footer__copy {
  margin: 0;
  font-family: var(--font-text);
  font-weight: 400;
  font-size: 14px;
  color: rgba(255, 255, 255, 0.7);
}

@media (max-width: 960px) {
  .footer__grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .footer__brand { grid-column: 1 / -1; }
}

@media (max-width: 600px) {
  .footer__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 36px 20px; }
  .footer__grid > .footer__col:last-child { grid-column: 1 / -1; }
  .wordmark--footer { font-size: 44px; }
  .footer__cta { width: 100%; justify-content: center; }
  .footer__bottom { flex-direction: column-reverse; align-items: flex-start; }
}

/* ------------------------------------------------------------------
   PAGINE DEI SERVIZI (siti-web.html)
   In alto titolo e bottoni, a fianco la papera. Poi il perché, i quattro
   punti di forza, il metodo a step e il form contatti della home.
   ------------------------------------------------------------------ */
.phero,
.pintro,
.pfeat,
.pmethod {
  max-width: 1320px;
  margin: 0 auto;
  padding-inline: var(--gutter);
}

/* --- Hero --- */
.phero {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 0.75fr);
  align-items: center;
  gap: clamp(32px, 4vw, 64px);
  padding-top: clamp(120px, 15vh, 160px);
  padding-bottom: clamp(48px, 7vw, 96px);
}

.phero__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 26px;
  padding: 10px 20px 9px;
  border: 2px solid rgba(228, 177, 56, 0.5);
  border-radius: 999px;
  color: var(--gold);
  font-size: 15px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.phero__title {
  margin: 0;
  font-weight: 800;
  font-size: clamp(36px, 4.1vw, 62px);
  line-height: 1.02;
  letter-spacing: -0.01em;
}

.phero__lead {
  max-width: 34em;
  margin: 30px 0 0;
  font-family: var(--font-text);
  font-weight: 400;
  font-size: clamp(17px, 1.35vw, 20px);
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.82);
}

.phero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px 16px;
  margin-top: 36px;
}

/* --- Papera --- */
.phero__visual {
  width: min(100%, 600px);
  justify-self: center;
}

.phero__duck {
  display: block;
  width: 100%;
  height: auto;
  filter: drop-shadow(0 26px 30px rgba(20, 4, 50, 0.5));
  animation: bob 4.5s ease-in-out infinite;
}

/* --- Perché un sito --- */
.pintro { padding-top: clamp(24px, 4vw, 48px); padding-bottom: clamp(48px, 7vw, 96px); }

.pintro__grid {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  align-items: start;
  gap: clamp(24px, 5vw, 80px);
}

.pintro__title,
.pfeat__title,
.pmethod__title {
  margin: 0;
  font-weight: 800;
  font-size: clamp(32px, 3.8vw, 54px);
  line-height: 1.05;
  letter-spacing: -0.01em;
  text-wrap: balance;
}

.pintro__text p {
  margin: 0;
  font-family: var(--font-text);
  font-weight: 400;
  font-size: clamp(17px, 1.3vw, 19px);
  line-height: 1.65;
  color: rgba(255, 255, 255, 0.84);
}
/* i due paragrafi scorrono come un unico blocco di testo, senza andare a capo */
.pintro__text p { display: inline; }
.pintro__text p + p::before { content: " "; }

/* --- Punti di forza --- */
.pfeat { padding-bottom: clamp(48px, 7vw, 96px); }

.pfeat__head { margin-bottom: clamp(28px, 4vw, 48px); text-align: center; }
.pfeat__title { max-width: 14em; margin-inline: auto; }

.pfeat__grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 20px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.feat {
  position: relative;
  padding: 26px 24px 28px;
  border: 2px solid rgba(255, 255, 255, 0.14);
  border-radius: 26px;
  background: var(--purple);
  background-image: linear-gradient(rgba(255, 255, 255, 0.035), rgba(255, 255, 255, 0.035));
}

.feat__num {
  position: absolute;
  top: 24px;
  right: 24px;
  font-size: 15px;
  letter-spacing: 0.1em;
  color: var(--gold);
}

.feat__icon {
  display: grid;
  place-items: center;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--gold);
  color: var(--purple);
  box-shadow: 0 5px 0 var(--purple-deep);
  transition: transform 0.35s var(--ease-spring);
}
.feat__icon svg { width: 32px; height: 32px; }

.feat__title {
  margin: 24px 0 10px;
  font-weight: 700;
  font-size: clamp(21px, 1.7vw, 24px);
  line-height: 1.15;
}

.feat__text {
  margin: 0;
  font-family: var(--font-text);
  font-weight: 400;
  font-size: 15.5px;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.84);
}

@media (hover: hover) {
  .feat:hover .feat__icon { transform: scale(1.08) rotate(-8deg); }
}

/* --- Metodo --- */
.pfeat,
.pmethod { scroll-margin-top: 90px; }

.pmethod__box {
  padding: clamp(32px, 5vw, 64px) clamp(20px, 5vw, 64px);
  border: 2px solid rgba(255, 255, 255, 0.14);
  border-radius: 32px;
  background: var(--purple-deep);
  text-align: center;
}

.steps {
  position: relative;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin: clamp(32px, 4vw, 48px) 0 0;
  padding: 0;
  list-style: none;
}
/* linea tratteggiata "da buono" che collega i quattro step */
.steps::before {
  content: "";
  position: absolute;
  top: 28px;
  left: 12.5%;
  right: 12.5%;
  border-top: 2px dashed rgba(228, 177, 56, 0.45);
}

.step {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}

.step__dot {
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  border: 2px solid var(--gold);
  border-radius: 50%;
  background: var(--purple-deep);
  color: var(--gold);
  font-size: 22px;
  font-weight: 800;
}

.step__label {
  max-width: 11em;
  font-size: 17px;
  line-height: 1.3;
}

.pmethod__text {
  max-width: 40em;
  margin: clamp(32px, 4vw, 48px) auto 0;
  font-family: var(--font-text);
  font-weight: 400;
  font-size: clamp(17px, 1.3vw, 19px);
  line-height: 1.65;
  color: rgba(255, 255, 255, 0.86);
}

.pmethod__text + .pmethod__text { margin-top: 1em; }

.pmethod__cta { margin-top: 32px; }

/* --- Entrata (inview.js aggiunge .is-in) --- */
.js [data-inview]:not(.is-in) { opacity: 0; translate: 0 28px; }
.js [data-inview] {
  transition: opacity 0.7s var(--ease-out) var(--sd, 0ms), translate 0.9s var(--ease-out) var(--sd, 0ms);
}
.js .pmethod__box:not(.is-in) .step { opacity: 0; }
.pmethod__box.is-in .step {
  animation: reveal-up 0.7s var(--ease-out) calc(350ms + var(--i) * 140ms) backwards;
}
.pmethod__box.is-in .steps::before {
  animation: steps-line 1s var(--ease-out) 300ms backwards;
  transform-origin: 0 50%;
}
@keyframes steps-line { from { transform: scaleX(0); } }

@media (max-width: 1100px) {
  .pfeat__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 960px) {
  .phero { grid-template-columns: minmax(0, 1fr); }
  /* da telefono e tablet etichetta, titolo, testo e bottoni stanno al centro */
  .phero__copy { text-align: center; }
  .phero__lead { margin-inline: auto; }
  .phero__actions { justify-content: center; }
  .phero__visual { width: min(86vw, 440px); }
  .pintro__grid { grid-template-columns: 1fr; }
}

@media (max-width: 760px) {
  /* gli step vanno in colonna, la linea diventa verticale */
  .steps { grid-template-columns: 1fr; gap: 18px; max-width: 420px; margin-inline: auto; text-align: left; }
  .steps::before { top: 20px; bottom: 20px; left: 19px; right: auto; border-top: 0; border-left: 2px dashed rgba(228, 177, 56, 0.45); }
  .pmethod__box.is-in .steps::before { animation-name: steps-line-v; transform-origin: 50% 0; }
  .step { flex-direction: row; gap: 16px; }
  /* da telefono cerchi e numeri più piccoli */
  .step__dot { flex: none; width: 40px; height: 40px; font-size: 17px; }
  .step__label { max-width: none; }
}
@keyframes steps-line-v { from { transform: scaleY(0); } }

@media (max-width: 600px) {
  .phero { padding-top: calc(48px + 1.66 * 30px); }
  .phero__eyebrow { font-size: 13px; }
  .phero__actions .btn,
  .pmethod__cta { flex: 1 1 auto; justify-content: center; }
  /* le CTA lunghe ("Scopri cosa puoi automatizzare") vanno a capo invece di allargare la pagina */
  .phero__actions .btn,
  .pmethod__cta { white-space: normal; text-align: center; line-height: 1.2; }
  .pmethod__cta { width: 100%; }
  .pfeat__grid { grid-template-columns: 1fr; max-width: 460px; margin-inline: auto; }
}

/* ------------------------------------------------------------------
   PAGINA CONTATTI (contatti.html)
   Hero come le pagine dei servizi, poi il form a 4 step al centro,
   i recapiti con i dati aziendali e le due papere dei social.
   ------------------------------------------------------------------ */
.contact--page { scroll-margin-top: 90px; padding-top: clamp(24px, 4vw, 48px); }
.contact--page .contact__head { margin-bottom: clamp(28px, 4vw, 44px); text-align: center; }
.contact--page .contact__title { text-wrap: balance; }
.contact--page .cform { max-width: 780px; margin-inline: auto; }

.cinfo,
.csocial {
  max-width: 1320px;
  margin: 0 auto;
  padding: clamp(56px, 8vw, 104px) var(--gutter) 0;
  scroll-margin-top: 70px;
}

.cinfo__title {
  margin: 0 0 clamp(28px, 4vw, 48px);
  font-weight: 800;
  font-size: clamp(32px, 3.8vw, 54px);
  line-height: 1.05;
  letter-spacing: -0.01em;
  text-align: center;
  text-wrap: balance;
}

/* --- Recapiti --- */
.cinfo__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
  max-width: 980px;
  margin-inline: auto;
}

.cinfo__card {
  padding: clamp(24px, 3vw, 36px);
  border: 2px solid rgba(255, 255, 255, 0.14);
  border-radius: 26px;
  background: var(--purple);
  background-image: linear-gradient(rgba(255, 255, 255, 0.035), rgba(255, 255, 255, 0.035));
}
@media (hover: hover) {
  .cinfo__card:hover .feat__icon { transform: scale(1.08) rotate(-8deg); }
}

.cinfo__heading {
  margin: 22px 0 14px;
  font-weight: 700;
  font-size: clamp(22px, 1.8vw, 26px);
  line-height: 1.15;
}

.cinfo__phones,
.cinfo__data { margin: 0; padding: 0; list-style: none; }

/* righe separate dal tratteggio "da buono", come nel footer */
.cinfo__phones li + li,
.cinfo__row + .cinfo__row { border-top: 2px dashed rgba(228, 177, 56, 0.3); }

.cinfo__phone,
.cinfo__row {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 4px 16px;
  padding: 14px 0;
}

.cinfo__phone {
  color: var(--white);
  text-decoration: none;
  border-radius: 8px;
}
.cinfo__name,
.cinfo__row dt {
  font-family: var(--font-text);
  font-weight: 400;
  font-size: 16px;
  color: rgba(255, 255, 255, 0.75);
}
.cinfo__num,
.cinfo__row dd {
  margin: 0;
  font-size: clamp(19px, 1.6vw, 22px);
  font-variant-numeric: tabular-nums;
  transition: color 0.2s;
}
.cinfo__row dd a {
  color: inherit;
  text-decoration: none;
  overflow-wrap: anywhere;
  border-radius: 4px;
  transition: color 0.2s;
}
@media (hover: hover) {
  .cinfo__phone:hover .cinfo__num,
  .cinfo__row dd a:hover { color: var(--gold); }
}
.cinfo__phone:focus-visible,
.cinfo__row dd a:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }

/* --- Social --- */
.csocial__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(24px, 5vw, 80px);
  max-width: 900px;
  margin: 0 auto;
  padding: 0;
  list-style: none;
}

.csocial__item {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.csocial__duck {
  display: block;
  width: min(100%, 340px);
  height: auto;
  filter: drop-shadow(0 22px 26px rgba(20, 4, 50, 0.5));
  animation: bob 4.5s ease-in-out infinite;
}
/* le due papere non dondolano all'unisono */
.csocial__item + .csocial__item .csocial__duck { animation-delay: -2.25s; }

.csocial__name {
  margin: 18px 0 0;
  font-weight: 800;
  font-size: clamp(24px, 2.2vw, 30px);
  line-height: 1.1;
}
.csocial__handle {
  margin: 6px 0 0;
  font-family: var(--font-text);
  font-weight: 400;
  font-size: 16px;
  color: rgba(255, 255, 255, 0.72);
}

.csocial__btn { margin-top: 22px; text-transform: uppercase; letter-spacing: 0.04em; }

@media (max-width: 760px) {
  .cinfo__grid { grid-template-columns: 1fr; max-width: 520px; }
}

@media (max-width: 600px) {
  /* la papera del footer siede sull'onda: spazio perché non copra il pulsante di Facebook */
  .csocial { padding-bottom: 72px; }
  .csocial__grid { gap: 32px 16px; }
  .csocial__duck { width: 100%; }
  .csocial__btn { font-size: 17px; padding: 13px 18px 12px; }
  .csocial__name { font-size: 22px; }
  .csocial__handle { font-size: 14px; overflow-wrap: anywhere; }
}

/* ------------------------------------------------------------------
   PAGINA APPROFONDIMENTI (approfondimenti.html)
   Hero come le pagine dei servizi, poi le sei domande a fisarmonica:
   cliccandone una si apre sotto la risposta, a tutta larghezza. In fondo il box "prossimo passo".
   ------------------------------------------------------------------ */
.faq {
  max-width: 1080px;
  margin: 0 auto;
  padding: clamp(24px, 4vw, 48px) var(--gutter) clamp(48px, 7vw, 96px);
  scroll-margin-top: 90px;
}

.faq__list {
  display: grid;
  gap: 14px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.faq__item {
  border: 2px solid rgba(255, 255, 255, 0.14);
  border-radius: 26px;
  background-color: var(--purple);
  background-image: linear-gradient(rgba(255, 255, 255, 0.035), rgba(255, 255, 255, 0.035));
  scroll-margin-top: 130px;   /* sotto l'header fisso */
  transition: border-color 0.3s, background-color 0.3s;
}
/* l'entrata di inview.js riscriverebbe la transition: qui le teniamo tutte */
.js .faq__item[data-inview] {
  transition: opacity 0.7s var(--ease-out) var(--sd, 0ms), translate 0.9s var(--ease-out) var(--sd, 0ms),
              border-color 0.3s, background-color 0.3s;
}
.faq__item.is-open {
  border-color: rgba(228, 177, 56, 0.55);
  background-color: var(--purple-deep);
  background-image: none;
}

.faq__q { margin: 0; font-weight: 700; font-size: clamp(20px, 1.8vw, 24px); line-height: 1.3; }

/* la domanda è tutta la riga: numero, testo e cerchio con la freccia */
.faq__btn {
  display: flex;
  align-items: center;
  gap: clamp(14px, 2vw, 24px);
  width: 100%;
  padding: clamp(20px, 2.4vw, 28px) clamp(18px, 2.6vw, 32px);
  border: 0;
  border-radius: 24px;
  background: none;
  color: var(--white);
  font: inherit;
  text-align: left;
  cursor: pointer;
}
.faq__btn:focus-visible { outline: 3px solid var(--white); outline-offset: 4px; }

.faq__num {
  flex: none;
  font-size: 15px;
  letter-spacing: 0.1em;
  color: var(--gold);
  font-variant-numeric: tabular-nums;
}

.faq__text { flex: 1; text-wrap: pretty; transition: color 0.2s; }

.faq__icon {
  flex: none;
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--gold);
  color: var(--purple);
  transition: transform 0.45s var(--ease-spring), scale 0.3s var(--ease-spring);
}
.faq__icon svg { width: 24px; height: 24px; }
.faq__item.is-open .faq__icon { transform: rotate(180deg); }

@media (hover: hover) {
  .faq__btn:hover .faq__text { color: var(--gold); }
  .faq__btn:hover .faq__icon { scale: 1.08; }
}
.faq__btn:active .faq__icon { scale: 0.94; transition-duration: 0.06s; }

/* apertura: la riga della griglia passa da 0 all'altezza del contenuto.
   Senza JS le risposte restano tutte aperte. */
.faq__panel {
  display: grid;
  grid-template-rows: 1fr;
  transition: grid-template-rows 0.5s var(--ease-out), visibility 0s;
}
.js .faq__item:not(.is-open) .faq__panel {
  grid-template-rows: 0fr;
  visibility: hidden;
  transition: grid-template-rows 0.4s var(--ease-out), visibility 0s linear 0.4s;
}
.faq__inner { min-height: 0; overflow: hidden; }

.faq__body {
  margin: 0 clamp(18px, 2.6vw, 32px);
  padding: clamp(20px, 2.4vw, 28px) 0 clamp(24px, 3vw, 36px);
  border-top: 2px dashed rgba(228, 177, 56, 0.3);
}

.faq__answer p {
  margin: 0;
  font-family: var(--font-text);
  font-weight: 400;
  font-size: clamp(16px, 1.2vw, 18px);
  line-height: 1.7;
  color: rgba(255, 255, 255, 0.86);
}
.faq__answer p + p { margin-top: 1em; }

/* il testo sale mentre il pannello si apre */
.faq__item.is-open .faq__answer {
  animation: reveal-up 0.6s var(--ease-out) 0.12s backwards;
}

/* --- Il prossimo passo --- */
.pnext { padding-bottom: clamp(56px, 8vw, 104px); }
.pnext .pmethod__title { max-width: 16em; margin-inline: auto; }
.pnext__strong { font-weight: 700; color: var(--gold); }


@media (max-width: 600px) {
  .faq__btn { gap: 12px; }
  .faq__num { font-size: 13px; }
  .faq__icon { width: 40px; height: 40px; }
  .faq__icon svg { width: 20px; height: 20px; }
  /* la papera del footer siede sull'onda: spazio perché non copra il bottone */
  .pnext { padding-bottom: 88px; }
}

/* ------------------------------------------------------------------
   RESPONSIVE
   ------------------------------------------------------------------ */
@media (max-width: 1100px) {
  /* sotto i 1100px tre colonne sono troppo strette per i testi del retro */
  .services__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 960px) {
  /* in colonna: prima il cartello, poi la papera, poi titolo e testo */
  .hero__top { grid-template-columns: 1fr; gap: 0; }
  .hero__copy { display: contents; }
  .warning { order: -2; justify-self: center; margin-bottom: 36px; }
  .hero__visual { width: min(72vw, 380px); order: -1; margin-bottom: 36px; }
  .services__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .contact__grid {
    grid-template-columns: 1fr;
    grid-template-areas: "head" "duck" "form";
  }
  .contact__duck { width: min(50vw, 260px); }
  .promo__grid { grid-template-columns: 1fr; }
  .promo__duck { width: min(50vw, 260px); }
  .promo__carousel { --card: min(56%, 340px); }
}

@media (max-width: 600px) {
  .site-header { padding-top: 16px; padding-bottom: 16px; }
  .wordmark--header { font-size: 30px; }
  /* il cartello parte subito sotto l'header: 16+16 di padding + logo su due righe (1.66em) */
  .hero { padding-top: calc(32px + 1.66 * 30px); }
  /* titolo su due righe: "Il tuo business," / "finalmente a galla."
     la riga lunga misura ~9.7em in Poppins 800, quindi la dimensione segue la larghezza utile
     e nowrap impedisce che "a galla." scenda su una terza riga */
  .hero__title { font-size: min(54px, calc((100vw - 2 * var(--gutter)) / 10)); white-space: nowrap; }
  .hero__title .line:nth-child(n+2) { display: inline-block; }
  .btn { font-size: 19px; }
  .hero__actions .btn { flex: 1 1 auto; justify-content: center; }
  /* da telefono il cartello è a tutta larghezza, dritto e più leggibile */
  .warning {
    --stripe: 14px;
    width: 100%;
    gap: 8px;
    margin: 0 0 40px;
    padding: 14px calc(var(--stripe) + 6px) 13px;
    font-size: 19px;
    letter-spacing: 0.01em;
    line-height: 1.25;
    text-wrap: balance;
  }
  .warning__icon { width: 36px; height: 36px; }
  .hero__visual { margin-bottom: 32px; }
  .hero__lead { margin-top: 22px; }
  .ring text { font-size: 24px; }
  .services__grid { grid-template-columns: 1fr; max-width: 420px; margin-inline: auto; }
  /* da telefono il box dei numeri non si mostra */
  .stats { display: none; }
  .contact__grid {
    grid-template-columns: 1fr;
    grid-template-areas: "head" "duck" "form";
  }
  .contact__duck { width: min(70%, 260px); }
  /* da telefono le card laterali escono dallo schermo: si vede solo un bordo */
  .promo__carousel { --card: 76%; --shift: 66%; }
  .promo__track { margin-inline: calc(var(--gutter) * -1); overflow-x: clip; }
  .promo-card { min-height: 0; padding: 22px 20px 20px; }
  .facts__stage { --dot: 46px; }
  .facts__dot { font-size: 22px; }
  /* da telefono la scheda occupa quasi tutto il cerchio */
  .facts__card { width: 94%; padding: 20px 18px 16px; }
  .fact__eyebrow { font-size: 13px; margin-bottom: 10px; }
  .fact__text { font-size: 17px; }
  .facts__card-nav { margin-top: 12px; }
  .cform__row { grid-template-columns: 1fr; }
  .cform__nav--end .cform__actions { width: 100%; }
  .cform__actions .btn { flex: 1 1 auto; justify-content: center; }
  /* da telefono la ruota sposta molto le card laterali: le avviciniamo così se ne vede un bordo */
  .reviews__rail { --card: 76vw; --gap: -90px; --arrow-x: calc(var(--card) / 2); }
  .reviews__arrow { width: 46px; height: 46px; }
  .review__card { padding: 24px 22px 22px; }
  .review__text p { font-size: 16px; }
}

/* ------------------------------------------------------------------
   POP-UP CONTATTO (pagine dei servizi, js/contact-popup.js)
   Si sceglie WhatsApp / telefono / email, poi compare il campo giusto.
   ------------------------------------------------------------------ */
html.has-cpop { overflow: hidden; }

.cpop {
  width: min(520px, calc(100vw - 32px));
  max-height: calc(100dvh - 32px);
  margin: auto;
  padding: clamp(28px, 5vw, 44px);
  border: 2px solid rgba(255, 255, 255, 0.14);
  border-radius: 28px;
  background: var(--purple);
  color: var(--white);
  box-shadow: 0 10px 0 var(--purple-deep), 0 30px 80px rgba(20, 4, 50, 0.55);
  overflow-y: auto;
  overscroll-behavior: contain;
}
.cpop::backdrop { background: rgba(20, 4, 50, 0.7); }

.cpop[open] { animation: cpop-in 0.45s var(--ease-out) both; }
.cpop[open]::backdrop { animation: fade-in 0.3s ease both; }
.cpop.is-closing { animation: cpop-out 0.2s ease-in both; }
.cpop.is-closing::backdrop { animation: fade-in 0.2s ease-in reverse both; }
@keyframes cpop-in {
  from { opacity: 0; transform: translateY(24px) scale(0.96); }
}
@keyframes cpop-out {
  to { opacity: 0; transform: translateY(12px) scale(0.98); }
}

.cpop__close {
  position: absolute;
  top: 14px;
  right: 14px;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: rgba(255, 255, 255, 0.75);
  cursor: pointer;
  transition: background-color 0.2s, color 0.2s;
}
.cpop__close svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.6;
  stroke-linecap: round;
}
.cpop__close:focus-visible { outline: 3px solid var(--white); outline-offset: 2px; }
@media (hover: hover) {
  .cpop__close:hover { background: rgba(255, 255, 255, 0.08); color: var(--white); }
}

.cpop__view:not(.is-current) { display: none; }

.cpop__eyebrow {
  margin: 0 48px 10px 0;
  font-size: 14px;
  letter-spacing: 0.02em;
  color: var(--gold);
}
.cpop__eyebrow:empty { display: none; }

.cpop__title {
  margin: 0 40px 26px 0;
  font-size: clamp(28px, 4vw, 36px);
  line-height: 1.05;
}

.cpop [hidden] { display: none !important; }

.cpop__methods {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: 0;
  padding: 0;
  border: 0;
}
.cpop__method { position: relative; cursor: pointer; }
.cpop__method input {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
}
.cpop__method span {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 18px;
  border: 2px solid rgba(255, 255, 255, 0.25);
  border-radius: 20px;
  font-size: 16px;
  line-height: 1;
  user-select: none;
  transition: background-color 0.25s, border-color 0.25s, color 0.25s, transform 0.18s var(--ease-out);
}
.cpop__method svg {
  flex: none;
  width: 26px;
  height: 26px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linejoin: round;
  stroke-linecap: round;
}
.cpop__method svg .fill { fill: currentColor; stroke: none; }
@media (hover: hover) {
  .cpop__method:hover span { border-color: rgba(255, 255, 255, 0.55); }
}
.cpop__method:active span { transform: scale(0.97); }
.cpop__method input:checked + span {
  background: var(--gold);
  border-color: var(--gold);
  color: var(--purple);
}
.cpop__method input:focus-visible + span { outline: 3px solid var(--white); outline-offset: 3px; }

/* il campo "si apre" sotto le scelte quando se ne sceglie una */
.cpop__reveal {
  display: grid;
  grid-template-rows: 0fr;
  opacity: 0;
  transition: grid-template-rows 0.45s var(--ease-out), opacity 0.3s;
}
.cpop__reveal.is-open { grid-template-rows: 1fr; opacity: 1; }
.cpop__reveal-inner {
  min-height: 0;
  overflow: hidden;
  /* spazio per il focus del campo e l'ombra del bottone */
  margin: 0 -6px;
  padding: 0 6px 8px;
}
.cpop__reveal .field { margin-top: 24px; }
.cpop__send { margin-top: 22px; }
.cpop__video { margin-top: 24px; }
.cpop__video .cpop__hint { margin-bottom: 20px; }

.cpop__done { text-align: left; }
.cpop__done .cpop__title { margin-bottom: 12px; }
.cpop__done.is-current .cform__done-head { animation: done-pop 0.9s var(--ease-spring) 0.2s backwards; }
.cpop__hint {
  margin: 0 0 26px;
  font-family: var(--font-text);
  font-weight: 400;
  font-size: 16px;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.8);
}
.cpop__done:focus { outline: none; }

@media (max-width: 420px) {
  .cpop__method span { flex-direction: column; gap: 10px; padding: 16px 4px 14px; font-size: 14px; }
  :is(.cpop__send, .cpop__video .btn) { width: 100%; justify-content: center; }
}

/* ------------------------------------------------------------------
   MOVIMENTO RIDOTTO
   ------------------------------------------------------------------ */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .is-revealed [data-reveal],
  .is-revealed [data-reveal="pop"],
  .is-revealed :is(.header-cta, .nav-toggle, .nav__list) { animation: fade-in 0.4s ease both; }
  .site-nav, .site-header.is-open .site-nav { transition-duration: 0.01s; }
  .nav__item, .site-header.is-open .nav__item { translate: none; transition-delay: 0s; }
  .nav__drop, .nav__chevron { transition-duration: 0.01s; }
  .is-revealed .line[data-reveal] { animation: none; }
  .is-revealed .line > span { animation: none; transform: none; }
  .wave path { stroke-dashoffset: 0; }
  .is-revealed .wave path { animation: none; }
  .ring, .mascot__img, .told__link .btn__icon { animation: none; }
  .ring.is-leaving { scale: 1; transition-duration: 0.3s; }
  .told.is-on :is(.told__title, .told__text, .told__link) { animation: fade-in 0.4s ease both; }
  .js .cform__step, .js .cform__step.is-past { transform: none; }
  .cform__track-fill, .service__inner { transition-duration: 0.01s; }
  .js .service:not(.is-in) { transform: none; }
  .js .services__head:not(.is-in), .js .stats:not(.is-in) { translate: none; }
  .service.is-in :is(.service__duck, .service__num, .service__title, .service__front .service__btn) { animation: fade-in 0.4s ease both; }
  .field__error.is-shown, .cform__done.is-current .cform__done-head { animation: none; }
  .facts__orbit, .facts__dot::before { animation: none !important; }
  .js .facts:not(.is-in) .facts__duck,
  .js .facts:not(.is-in) .facts__dot { transform: none; }
  .facts.is-open .facts__duck { transform: none; }
  .facts__card.is-on, .facts__card-body.is-swap { animation: fade-in 0.2s ease both; }
  .promo__duck { animation: none; }
  .footer__duck img { animation: none; }
  .js .promo:not(.is-in) .promo__duck { translate: none; scale: none; }
  .promo-card { transition-duration: 0.01s; }
  .promo-card.is-arriving :is(.promo-card__title, .promo-card__desc, .promo-card__price) { animation: none; }
  .review { transform: translateX(calc(var(--o) * (var(--card) + var(--gap)))); transition-duration: 0.01s; }
  .review__quote { transition: none; }
  .js .reviews:not(.is-in) .review__card { translate: none; }
  .js .reviews .wave path { transition: none; }
  .phero__duck { animation: none; }
  .js [data-inview]:not(.is-in) { translate: none; }
  .pmethod__box.is-in .step { animation: fade-in 0.4s ease both; }
  .pmethod__box.is-in .steps::before { animation: none; }
  .csocial__duck { animation: none; }
  .faq__panel, .js .faq__item:not(.is-open) .faq__panel { transition: none; }
  .faq__icon { transition-duration: 0.01s; }
  .faq__item.is-open .faq__answer { animation: fade-in 0.3s ease both; }
  .cpop[open] { animation: fade-in 0.2s ease both; }
  .cpop__reveal { transition-duration: 0.01s; }
  .cpop__done.is-current .cform__done-head { animation: none; }
}

/* ------------------------------------------------------------------
   PRIVACY: link legali nel footer, nota sotto i form
   ------------------------------------------------------------------ */
.footer__legal {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 20px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.footer__legal :is(a, button) {
  padding: 4px 0;
  border: 0;
  background: none;
  font-family: var(--font-text);
  font-weight: 400;
  font-size: 14px;
  color: rgba(255, 255, 255, 0.7);
  text-decoration: underline;
  text-decoration-color: rgba(255, 255, 255, 0.3);
  text-underline-offset: 3px;
  cursor: pointer;
  transition: color 0.2s, text-decoration-color 0.2s;
}
@media (hover: hover) {
  .footer__legal :is(a, button):hover { color: var(--gold); text-decoration-color: currentColor; }
}
.footer__legal :is(a, button):focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; border-radius: 4px; }

.cform__privacy {
  flex-basis: 100%;
  margin: 4px 0 0;
  font-family: var(--font-text);
  font-weight: 400;
  font-size: 13px;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.65);
}
.cform__nav .cform__privacy { text-align: right; }
.cform__privacy a { color: inherit; text-underline-offset: 2px; }
.cform__privacy a:hover { color: var(--gold); }
.cform__privacy a:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; border-radius: 3px; }
.cform__privacy[hidden] { display: none; }

/* recapiti sotto nome e cognome; invio in corso / non riuscito */
.cform__row + .cform__row { margin-top: 16px; }
#cfContattoErr { margin-top: 8px; }
.btn:disabled { opacity: 0.6; cursor: progress; transform: none; }
.cform__send-err { flex-basis: 100%; margin: 0; line-height: 1.5; }
.cform__nav .cform__send-err { text-align: right; }
.cform__send-err a { color: inherit; text-underline-offset: 2px; }
@media (max-width: 600px) {
  .cform__nav .cform__send-err { text-align: left; }
}
@media (max-width: 600px) {
  .cform__nav .cform__privacy { text-align: left; }
}

/* ------------------------------------------------------------------
   BANNER COOKIE (js/cookie-consent.js)
   Una card in basso a sinistra; su telefono occupa tutta la larghezza.
   ------------------------------------------------------------------ */
.cookie {
  --shadow: rgba(0, 0, 0, 0.45);
  position: fixed;
  z-index: 80;                      /* sopra l'header, sotto l'intro e i pop-up */
  left: var(--gutter);
  bottom: 20px;
  width: min(460px, calc(100vw - 2 * var(--gutter)));
  max-height: calc(100dvh - 40px);
  overflow-y: auto;
  padding: 26px 24px 22px;
  border: 2px solid rgba(228, 177, 56, 0.45);
  border-radius: 22px;
  background: var(--purple-deep);
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.45);
  opacity: 0;
  translate: 0 16px;
  transition: opacity 0.35s var(--ease-out), translate 0.45s var(--ease-out);
}
.cookie.is-open { opacity: 1; translate: none; }
.cookie[hidden] { display: none; }

.cookie__close {
  position: absolute;
  top: 12px;
  right: 12px;
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: none;
  color: rgba(255, 255, 255, 0.7);
  cursor: pointer;
  transition: color 0.2s, background-color 0.2s;
}
.cookie__close svg { width: 18px; height: 18px; }
.cookie__close:hover { color: var(--white); background: rgba(255, 255, 255, 0.08); }
.cookie__close:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }

.cookie__title {
  margin: 0 40px 10px 0;
  font-weight: 800;
  font-size: 21px;
  line-height: 1.2;
}

.cookie__text {
  margin: 0;
  font-family: var(--font-text);
  font-weight: 400;
  font-size: 15px;
  line-height: 1.55;
  color: rgba(255, 255, 255, 0.82);
}
.cookie__text a { color: var(--gold); text-underline-offset: 3px; }
.cookie__text a:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; border-radius: 3px; }

.cookie__prefs {
  display: grid;
  gap: 4px;
  margin-top: 18px;
  padding-top: 14px;
  border-top: 2px dashed rgba(228, 177, 56, 0.35);
}
.cookie__prefs[hidden] { display: none; }

.cookie__cat {
  position: relative;
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 10px 0;
  cursor: pointer;
}
.cookie__cat input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.cookie__cat:has(input:disabled) { cursor: default; }

/* interruttore */
.cookie__switch {
  position: relative;
  flex: none;
  width: 44px;
  height: 26px;
  margin-top: 1px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  transition: background-color 0.2s;
}
.cookie__switch::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--white);
  transition: transform 0.25s var(--ease-spring);
}
.cookie__cat input:checked + .cookie__switch { background: var(--gold); }
.cookie__cat input:checked + .cookie__switch::after { transform: translateX(18px); background: var(--purple); }
.cookie__cat input:disabled + .cookie__switch { opacity: 0.6; }
.cookie__cat input:focus-visible + .cookie__switch { outline: 3px solid var(--white); outline-offset: 3px; }

.cookie__cat-body { display: grid; gap: 3px; }
.cookie__cat-name { font-size: 16px; }
.cookie__cat-name em {
  margin-left: 6px;
  font-style: normal;
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold);
}
.cookie__cat-text {
  font-family: var(--font-text);
  font-weight: 400;
  font-size: 14px;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.7);
}

.cookie__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 20px;
}
.cookie__actions .btn { font-size: 16px; padding: 11px 16px 10px; }
.cookie__actions .btn--outline { padding: 9px 14px 8px; margin-right: auto; background: none; }
.cookie__actions .btn[hidden] { display: none; }

@media (max-width: 600px) {
  .cookie { left: 12px; right: 12px; bottom: 12px; width: auto; padding: 22px 18px 18px; }
  .cookie__actions .btn { flex: 1 1 auto; justify-content: center; }
  .cookie__actions .btn--outline { flex-basis: 100%; margin-right: 0; order: 1; }
}

/* ------------------------------------------------------------------
   PAGINE LEGALI (privacy-policy.html, cookie-policy.html)
   ------------------------------------------------------------------ */
.legal {
  max-width: 860px;
  margin: 0 auto;
  padding: clamp(120px, 15vh, 160px) var(--gutter) 0;
}
.legal .phero__title { font-size: clamp(36px, 5vw, 58px); }
.legal__updated {
  margin: 18px 0 0;
  font-family: var(--font-text);
  font-weight: 400;
  font-size: 15px;
  color: rgba(255, 255, 255, 0.65);
}
.legal__body {
  counter-reset: legal;
  margin-top: clamp(36px, 5vw, 56px);
  font-family: var(--font-text);
  font-weight: 400;
  font-size: 17px;
  line-height: 1.7;
  color: rgba(255, 255, 255, 0.86);
}
.legal__body h2 {
  margin: 48px 0 14px;
  font-family: var(--font-brand);
  font-weight: 700;
  font-size: clamp(22px, 2.2vw, 27px);
  line-height: 1.25;
  color: var(--white);
}
.legal__body h2::before {
  content: counter(legal) ". ";
  counter-increment: legal;
  color: var(--gold);
}
.legal__body h3 {
  margin: 28px 0 8px;
  font-family: var(--font-brand);
  font-weight: 600;
  font-size: 18px;
  color: var(--gold);
}
.legal__body p { margin: 0 0 14px; }
.legal__body ul { margin: 0 0 14px; padding-left: 1.3em; }
.legal__body li { margin-bottom: 6px; }
.legal__body li::marker { color: var(--gold); }
.legal__body strong { font-weight: 600; color: var(--white); }
.legal__body a { color: var(--gold); text-underline-offset: 3px; overflow-wrap: anywhere; }
.legal__body a:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; border-radius: 3px; }

.legal__card {
  margin: 0 0 14px;
  padding: 20px 22px;
  border: 2px solid rgba(228, 177, 56, 0.35);
  border-radius: 18px;
  background: rgba(0, 0, 0, 0.12);
}
.legal__card p:last-child { margin-bottom: 0; }

.legal__table-wrap { margin: 0 0 18px; overflow-x: auto; }
.legal__table {
  width: 100%;
  min-width: 560px;
  border-collapse: collapse;
  font-size: 15px;
  line-height: 1.5;
}
.legal__table :is(th, td) {
  padding: 12px 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.14);
  text-align: left;
  vertical-align: top;
}
.legal__table th {
  font-family: var(--font-brand);
  font-weight: 600;
  font-size: 13px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold);
}

/* dati ancora da inserire: ben visibili finché non vengono compilati */
.legal__todo {
  padding: 1px 6px;
  border-radius: 4px;
  background: var(--gold);
  color: var(--purple);
  font-weight: 600;
}

.legal__btn { margin: 6px 0 14px; }

/* --- Pagina 404 --- */
.notfound { text-align: center; }
.notfound__duck { display: block; width: clamp(160px, 22vw, 230px); height: auto; margin: 0 auto 24px; }
.notfound .phero__lead { margin-inline: auto; }
.notfound .phero__actions { justify-content: center; }

@media (prefers-reduced-motion: reduce) {
  .cookie { translate: none; transition: opacity 0.2s ease; }
  .cookie__switch::after { transition-duration: 0.01s; }
}
