/* Menu da telefono nello stile delle pagine restyling (31/10/2026).
   Il contenitore resta l'offcanvas .menumobile di main.css (posizione, scorrimento, apertura):
   qui solo l'aspetto, tutto sotto .mm. */
.offcanvas.menumobile.mm {
  --mm-brand: #005578; --mm-deep: #06364c; --mm-cyan: #6EC5D8; --mm-sole: #ffc93c;
  --mm-line: #d3e2e9; --mm-tenue: #cfe7ef; --mm-velo: #e9f4f8; --mm-ink2: #43606c; --mm-ink3: #7d99a5;
  background: #fff; border: 0; border-radius: 24px; overflow: hidden;
  box-shadow: 0 30px 70px -20px rgba(0, 40, 60, .55);
  font-family: Montserrat, Helvetica, Arial, sans-serif; color: var(--mm-deep);
  transition: transform .34s cubic-bezier(.2, .9, .3, 1), visibility .34s;
}
.mm * { box-sizing: border-box; }

/* testata: logo e X ben visibile */
.mm-testa { display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 16px 16px 14px 20px; border-bottom: 1px solid var(--mm-velo); flex: none; }
.mm-logo img { height: 26px; width: auto; display: block; }
.mm-chiudi { width: 44px; height: 44px; border-radius: 14px; border: 0; background: var(--mm-brand); color: #fff;
  display: grid; place-items: center; cursor: pointer; box-shadow: 0 3px 0 #003c55; flex: none; }
.mm-chiudi svg { width: 22px; height: 22px; }
.mm-chiudi:active { transform: translateY(2px); box-shadow: 0 1px 0 #003c55; }
.mm-chiudi:focus-visible { outline: 3px solid var(--mm-sole); outline-offset: 2px; }

.mm-corpo { flex: 1 1 auto; overflow-y: auto; overflow-x: hidden; -webkit-overflow-scrolling: touch; padding: 16px 16px 20px;
  background: linear-gradient(#f4fbfd, #fff 160px); }
.mm-eyebrow { margin: 0 0 8px 4px; font-size: .7rem; font-weight: 700; letter-spacing: .18em; text-transform: uppercase; color: var(--mm-brand); }

/* le voci */
.mm-voci { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.mm-voce { display: flex; align-items: center; gap: 12px; padding: 9px 10px 9px 8px; border-radius: 16px;
  text-decoration: none; color: var(--mm-deep); border: 1.5px solid transparent; transition: background .15s, border-color .15s; }
.mm-voce:hover, .mm-voce:focus-visible { background: var(--mm-velo); border-color: var(--mm-tenue); color: var(--mm-deep); outline: 0; }
.mm-voce:active { background: #dff0f6; }
.mm-ico { width: 40px; height: 40px; flex: none; display: block; }
.mm-testo { flex: 1; min-width: 0; line-height: 1.2; }
.mm-testo b { display: block; font-size: 1rem; font-weight: 700; }
.mm-testo small { display: block; font-size: .78rem; color: var(--mm-ink3); margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mm-freccia { width: 18px; height: 18px; color: var(--mm-ink3); flex: none; }

/* il gruppo Vendi, con i bottoni della home */
.mm-vendi { margin-top: 16px; background: linear-gradient(155deg, #005578 0%, #0a6288 55%, #07506f 100%); border-radius: 22px;
  padding: 16px 16px 14px; color: #fff; position: relative; overflow: hidden; }
.mm-vendi:before { content: ""; position: absolute; width: 220px; height: 220px; border-radius: 50%; right: -90px; top: -110px;
  background: radial-gradient(closest-side, rgba(110, 197, 216, .45), transparent); pointer-events: none; }
.mm-vendi .mm-eyebrow { color: var(--mm-cyan); position: relative; }
.mm-vendi-t { position: relative; margin: 0 4px 12px; font-size: .95rem; font-weight: 700; line-height: 1.3; }
.mm-bt { position: relative; display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; min-height: 50px;
  margin-top: 10px; border-radius: 999px; font-weight: 800; font-size: .95rem; text-decoration: none; padding: 12px 12px; white-space: nowrap; }
.mm-bt svg { width: 18px; height: 18px; }
.mm-bt-giallo { background: linear-gradient(180deg, #ffd45e, #ffb300); color: #4a3300; box-shadow: 0 5px 0 #d99500; }
.mm-bt-giallo:hover { color: #4a3300; filter: brightness(1.03); }
.mm-bt-azzurro { background: var(--mm-cyan); color: var(--mm-deep); box-shadow: 0 5px 0 #4aa9bf; }
.mm-bt-azzurro:hover { color: var(--mm-deep); }
.mm-bt-contorno { border: 2px solid rgba(255, 255, 255, .85); color: #fff; background: transparent; }
.mm-bt-contorno:hover { color: #fff; background: rgba(255, 255, 255, .1); }
.mm-bt:active { transform: translateY(3px); }
.mm-micro { position: relative; margin: 12px 4px 0; font-size: .78rem; color: #bfe0ea; }

/* contatti rapidi e piede */
.mm-contatti { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 14px; }
.mm-rapido { display: flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; border-radius: 16px;
  border: 1.5px solid var(--mm-tenue); background: #fff; color: var(--mm-deep); font-weight: 700; font-size: .92rem; text-decoration: none;
  box-shadow: 0 3px 0 var(--mm-tenue); }
.mm-rapido:hover { color: var(--mm-deep); background: var(--mm-velo); }
.mm-rapido svg { width: 22px; height: 22px; }
.mm-wa i { color: #1fa855; font-size: 1.25rem; line-height: 1; }
.mm-piede a { color: inherit; text-decoration: underline; }
.mm-piede { margin: 16px 0 0; text-align: center; font-size: .75rem; color: var(--mm-ink3); }

/* apertura leggera: le parti entrano una dopo l'altra */
@keyframes mmEntra { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
.mm.showing .mm-voci > li, .mm.show .mm-voci > li,
.mm.showing .mm-vendi, .mm.show .mm-vendi, .mm.showing .mm-contatti, .mm.show .mm-contatti { animation: mmEntra .38s both; }
.mm-voci > li:nth-child(2) { animation-delay: .03s !important; }
.mm-voci > li:nth-child(3) { animation-delay: .06s !important; }
.mm-voci > li:nth-child(4) { animation-delay: .09s !important; }
.mm-voci > li:nth-child(5) { animation-delay: .12s !important; }
.mm-voci > li:nth-child(6) { animation-delay: .15s !important; }
.mm-voci > li:nth-child(7) { animation-delay: .18s !important; }
.mm .mm-vendi { animation-delay: .2s; }
.mm .mm-contatti { animation-delay: .24s; }
@media (prefers-reduced-motion: reduce) {
  .offcanvas.menumobile.mm { transition: none; }
  .mm * { animation: none !important; }
}

/* sfondo dietro al menu un po' più morbido */
.offcanvas-backdrop.show { opacity: .45; }

/* il bottone dell'assistenza non copre le voci quando il menu è aperto */
body:has(#offcanvas.show) #assistenza-wrapper,
body:has(#offcanvas.showing) #assistenza-wrapper,
body.mm-aperto #assistenza-wrapper { display: none !important; }

/* telefoni stretti (360 e meno) */
@media (max-width: 370px) {
  .mm-corpo { padding: 12px 12px 16px; }
  .mm-testo small { font-size: .74rem; }
  .mm-bt { font-size: .88rem; gap: 6px; }
  .mm-vendi { padding: 14px 12px 12px; }
}
