/* Lo stile degli effetti (effetti.js) e dei segni del mockup, comune alle
   tre proposte. I colori li dà ogni pagina con le sue variabili. */

/* Blur Text */
.da-rivelare .parola { display: inline-block; opacity: 0; filter: blur(10px); transform: translateY(.25em); transition: opacity .9s, filter .9s, transform .9s cubic-bezier(.2, .8, .2, 1); transition-delay: calc(var(--k) * 70ms); }
.da-rivelare.rivelato .parola { opacity: 1; filter: none; transform: none; }

/* Spotlight Card */
[data-luce] { position: relative; overflow: hidden; }
[data-luce]::after {
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: 0; transition: opacity .4s;
  background: radial-gradient(260px circle at var(--lx, 50%) var(--ly, 50%), var(--luce, rgba(255, 236, 200, .28)), transparent 70%);
}
[data-luce]:hover::after { opacity: 1; }

/* Tilted Card e Magnet: il ritorno morbido */
[data-inclina] { transition: transform .5s cubic-bezier(.2, .8, .2, 1); will-change: transform; }
[data-calamita] { transition: transform .45s cubic-bezier(.2, .8, .2, 1); }

/* Circular Text */
[data-giro] { position: relative; display: block; width: var(--giro, 7.5rem); height: var(--giro, 7.5rem); border-radius: 50%; animation: gira 22s linear infinite; }
[data-giro] span { position: absolute; left: 50%; top: 0; height: 50%; transform-origin: 0 100%; font-size: .72rem; letter-spacing: .1em; text-transform: uppercase; }
@keyframes gira { to { transform: rotate(360deg); } }

/* Scroll Velocity */
[data-scorre] { overflow: hidden; white-space: nowrap; touch-action: pan-y; cursor: grab; -webkit-user-select: none; user-select: none; }
[data-scorre]:active { cursor: grabbing; }
[data-scorre] > * { display: inline-flex; will-change: transform; }

/* Stack */
[data-pila] { position: relative; touch-action: none; }
/* le foto della pila restano dentro la pila: non passano sopra la testata */
[data-pila] { isolation: isolate; }
[data-pila] > * { position: absolute; inset: 0; transition: transform .55s cubic-bezier(.2, .8, .2, 1); cursor: grab; user-select: none; }
[data-pila] > *:active { cursor: grabbing; }

/* Line Waves sul legno */
[data-venature] { position: relative; }
[data-venature] > .venature { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
[data-venature] > :not(.venature) { position: relative; }

/* Rotating Text */
[data-ruota] { display: inline-block; white-space: nowrap; }
[data-ruota] .lettera { display: inline-block; }
[data-ruota] .lettera.entra { animation: entra .55s cubic-bezier(.2, .9, .3, 1.2) both; animation-delay: calc(var(--i) * 30ms); }
[data-ruota].esce .lettera { transition: transform .4s, opacity .4s; transform: translateY(-.6em); opacity: 0; }
@keyframes entra { from { transform: translateY(.7em); opacity: 0; } to { transform: none; opacity: 1; } }

/* Magnet Lines */
[data-fibre] { position: relative; }
[data-fibre] > .venature { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
[data-fibre] > :not(.venature) { position: relative; }

/* Horizontal Scroll: sui computer la sezione si allunga e il binario resta fermo in vista */
.orizzontale-attivo { position: relative; }
.orizzontale-attivo > .ferma { position: sticky; top: 0; height: 100vh; overflow: hidden; display: flex; flex-direction: column; justify-content: center; }
.orizzontale-attivo .binario { will-change: transform; }

/* Niente scorrimento di lato: quello che sporge dai bordi (le fasce
   inclinate, la spirale che gira…) si taglia. "clip" e non "hidden": non
   crea un contenitore che scorre, così la pagina e le parti ferme (sticky)
   continuano a funzionare. */
html, body { overflow-x: clip; }

/* Pezzi comuni a tutte le proposte, nei colori di ciascuna (currentColor) */
/* i rimandi di heylink: lista dei gin e playlist */
.rimandi { display: flex; flex-wrap: wrap; gap: .6rem 1.6rem; margin: 2rem 0 0; }
.rimandi a { color: inherit; text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: .25em; }
/* il logo dentro la testata, accanto al nome; l'icona di Instagram */
.testa .nome svg { display: block; width: 2rem; height: 2rem; flex: none; }
.testa a:has(> .icona-ig) { display: inline-grid; place-items: center; width: 2.4rem; height: 2.4rem; margin: -.4rem -.45rem -.4rem 0; color: inherit; }
.testa .icona-ig { display: block; width: 1.4rem; height: 1.4rem; }

/* Fil, il padrone di casa. La sua firma è scritta come il "dock" del logo. */
.firma { font-family: "Kaushan Script", cursive; white-space: nowrap; }

/* il Fil del mese: un calendario da muro, carta bianca e anelli di metallo */
/* il calendario sta davanti a Fil che sbuca (frecce sempre da toccare), sotto la testata */
.calendario { position: relative; z-index: 18; margin: 0; width: min(22rem, 100%); flex: none; }
.calendario .anelli { position: absolute; z-index: 2; left: 10%; right: 10%; top: -.75rem; height: 1.6rem; pointer-events: none;
  background: radial-gradient(ellipse .3rem .75rem at 50% 50%, transparent 52%, #4a403b 58%, #6d625c 72%, transparent 80%) 0 0 / 1.5rem 100% space no-repeat; }
.calendario .foglio { position: relative; padding: .9rem .9rem 1.1rem; border-radius: .45rem; background: #fffdf8; color: #2a211b; touch-action: pan-y; cursor: grab;
  box-shadow: 0 1px 0 rgba(0, 0, 0, .05), 0 26px 44px -22px rgba(30, 15, 10, .6); }
/* il foglio che se ne va: una copia sopra quello vero, sotto gli anelli */
.calendario .volante { position: absolute; z-index: 1; margin: 0; pointer-events: none; }
/* strappo: si stacca dagli anelli e vola via in alto, ruotando */
.calendario .via-strappo { transform-origin: 100% 0; animation: strappo .7s cubic-bezier(.45, 0, .7, .3) forwards; }
@keyframes strappo {
  0% { transform: none; }
  20% { transform: rotate(-3deg) translateY(-1%); }
  100% { transform: translate(-25%, -110%) rotate(-24deg); opacity: 0; }
}
/* giro: si ribalta sopra gli anelli, con l'ombra che scurisce la carta */
.calendario .via-giro { transform-origin: 50% 0; backface-visibility: hidden; animation: giro .6s cubic-bezier(.45, .05, .55, .95) forwards; }
@keyframes giro {
  0% { transform: perspective(1400px) rotateX(0); filter: brightness(1); }
  100% { transform: perspective(1400px) rotateX(178deg); filter: brightness(.55); }
}
/* all'indietro la stessa animazione, al contrario: il foglio torna */
.calendario .torna { animation-direction: reverse; animation-timing-function: cubic-bezier(.3, .7, .55, 1); }
.calendario .scatto { position: relative; aspect-ratio: 4 / 5; border-radius: .3rem; background-size: cover; background-position: center; }
.calendario figcaption { display: flex; justify-content: space-between; align-items: baseline; margin-top: .8rem; }
.calendario .mese { font: 400 2rem/1 "Kaushan Script", cursive; text-transform: capitalize; }
.calendario .anno { font: 600 .78rem/1 system-ui, sans-serif; letter-spacing: .16em; color: #8a7a6c; }
.calendario .sfoglia { display: flex; justify-content: center; gap: .6rem; margin-top: 1.1rem; }
.calendario .sfoglia button { width: 2.9rem; height: 2.9rem; border: 0; border-radius: 50%; background: none; color: inherit; font-size: 1.15rem; cursor: pointer; box-shadow: inset 0 0 0 1.5px currentColor; }

/* Fil che sbuca: una piccola foto al bancone, con le bottiglie, da cui
   esce la sua testa. Sale dal fondo dello schermo (il bordo basso della
   foto resta sotto); il fumetto spunta accanto alla testa. */
.sbuca { position: fixed; z-index: 15; right: clamp(.6rem, 2.5vw, 2rem); bottom: 0; width: clamp(11.5rem, 20vw, 17rem); padding: 0; border: 0; background: none; cursor: pointer;
  transform: translateY(105%) rotate(2deg); transition: transform .7s cubic-bezier(.3, 1.35, .5, 1); }
.sbuca.fuori { transform: translateY(5%) rotate(-2deg); }
.sbuca.saluta { transform: translateY(0) rotate(3deg); transition-duration: .25s; }
.sbuca img { display: block; width: 100%; height: auto; filter: drop-shadow(var(--ox, 0) var(--oy, 10px) 22px rgba(0, 0, 0, .4)); }
/* in 3D: la foto si inclina (--rx, --ry) e il riflesso segue la luce (--lx, --ly) */
.sbuca { perspective: 650px; }
.sbuca .corpo { position: relative; display: block; transform-origin: 50% 90%; transform: rotateX(var(--rx, 0)) rotateY(var(--ry, 0)); will-change: transform; }
.sbuca .lucido { position: absolute; inset: 0; pointer-events: none; mix-blend-mode: soft-light;
  background: radial-gradient(circle at var(--lx, 50%) var(--ly, 30%), rgba(255, 255, 255, .75), rgba(255, 255, 255, 0) 55%);
  -webkit-mask-size: 100% 100%; mask-size: 100% 100%; -webkit-mask-repeat: no-repeat; mask-repeat: no-repeat; }
.sbuca .fumetto { position: absolute; left: -.6rem; top: 0; padding: .45rem .8rem; border-radius: 1rem 1rem .2rem 1rem; background: #fff; color: #1b1714; white-space: nowrap;
  font: 400 1.15rem/1.1 "Kaushan Script", cursive; box-shadow: 0 8px 20px -8px rgba(0, 0, 0, .4); opacity: 0; transform: scale(.5) rotate(-4deg); transform-origin: 100% 100%; transition: opacity .25s, transform .4s cubic-bezier(.3, 1.6, .5, 1); }
.sbuca.fuori .fumetto { opacity: 1; transform: scale(1) rotate(-4deg); transition-delay: .55s; }
.sbuca.saluta .fumetto { opacity: 0; transition-delay: 0s; }
/* toccato, prima di andarsene saluta: "Grazie mille e arrivederci!" (l'altra
   sua frase), in un fumetto accanto alla testa che si allarga verso sinistra */
.sbuca .congedo { position: absolute; right: 62%; top: -1.2rem; width: max-content; max-width: 11rem; padding: .45rem .8rem; border-radius: 1rem 1rem .2rem 1rem; background: #fff; color: #1b1714; text-align: left;
  font: 400 1.15rem/1.15 "Kaushan Script", cursive; box-shadow: 0 8px 20px -8px rgba(0, 0, 0, .4); opacity: 0; transform: scale(.5) rotate(-4deg); transform-origin: 100% 100%; pointer-events: none;
  transition: opacity .2s, transform .4s cubic-bezier(.3, 1.6, .5, 1); }
.sbuca.saluta .congedo { opacity: 1; transform: scale(1) rotate(-4deg); }
/* sul telefono più piccolo: non deve prendersi mezzo schermo né i bottoni */
@media (max-width: 40rem) { .sbuca { width: 8.6rem; right: .4rem; } .sbuca .fumetto { font-size: .9rem; left: -1.6rem; } .sbuca .congedo { font-size: .95rem; max-width: 9rem; right: 55%; } }

/* l'avviso di Fil: un biglietto di carta in apertura, sopra il testo */
.avviso { position: relative; z-index: 3; width: min(23rem, 100%); margin: 0 0 1.4rem; display: grid; grid-template-columns: 3.2rem 1fr auto; gap: .85rem; align-items: start;
  padding: .9rem .9rem 1rem 1rem; border-radius: .4rem; background: #fffaf0; color: #2a211b; font-size: .95rem; line-height: 1.45; box-shadow: 0 20px 40px -16px rgba(20, 10, 5, .5);
  opacity: 0; visibility: hidden; transform: translateY(-1.5rem) rotate(-1.5deg); transition: opacity .4s, transform .6s cubic-bezier(.3, 1.35, .5, 1), visibility 0s .6s; }
.avviso.su { opacity: 1; visibility: visible; transform: translateY(0) rotate(-1.5deg); transition-delay: 0s; }
.avviso .faccia { display: block; width: 3.2rem; height: 3.2rem; border-radius: 50%; object-fit: cover; }
.avviso p { margin: 0; }
.avviso b { font-weight: 600; }
.avviso .firma { font-size: 1.1rem; }
.avviso .chiudi { margin: -.3rem -.2rem 0 0; padding: .2rem .45rem; border: 0; background: none; color: inherit; font-size: 1.4rem; line-height: 1; cursor: pointer; opacity: .6; }

/* "Oh ma… ciuccio bene?": la stampa della felpa della Domus. In alto a
   sinistra OH MA, la spirale, in basso a destra BENE ? */
.ciuccio { position: relative; width: min(30rem, 100%); aspect-ratio: 1; margin: 0 auto; color: #1b1714; }
/* touch-action: none (11 ottobre 2026): girando la ruota col dito la pagina sta ferma, anche nei movimenti in verticale */
.ciuccio .spirale { cursor: grab; touch-action: none; -webkit-user-select: none; user-select: none; }
.ciuccio .spirale:active { cursor: grabbing; }
.ciuccio .spirale svg { display: block; width: 100%; height: 100%; }
/* le lettere girano in un livello loro (trasformazione CSS, senza ridisegnare); il filo sotto e sopra, fermo */
.ciuccio .spirale .ruota { position: relative; will-change: transform; }
.ciuccio .spirale .filo-sotto, .ciuccio .spirale .filo-sopra { position: absolute; inset: 0; pointer-events: none; }
.ciuccio .spirale .filo-sopra { z-index: 1; }
.ciuccio .oh, .ciuccio .bene { position: absolute; margin: 0; font: 400 clamp(1.15rem, 4.4vw, 1.7rem)/1 "Archivo Black", system-ui, sans-serif; letter-spacing: -.01em; }
.ciuccio .oh { left: 2%; top: -3%; }
.ciuccio .bene { right: 2%; bottom: -3%; }

/* La ruota come il poster appeso alla Domus (11 ottobre 2026, data-spirale="poster"), sullo sfondo del sito:
   OH MA in alto a sinistra, la spirale in basso al centro, BENE ? in basso a destra, carattere Poppins (da
   caricare nella pagina). Il filo arancione sta fermo e le lettere girano sotto e sopra. */
.ciuccio.poster { width: min(30rem, 100%); aspect-ratio: 4 / 5; color: #1d1a1a; }
.ciuccio.poster .spirale { position: absolute; left: 1%; width: 98%; top: 16%; aspect-ratio: 1; }
.ciuccio.poster .spirale svg { overflow: visible; }
.ciuccio.poster .filo { stroke: #f19a4f; stroke-opacity: .72; }
.ciuccio.poster .oh, .ciuccio.poster .bene { font: 700 clamp(1.7rem, 8vw, 2.6rem)/1 "Poppins", system-ui, sans-serif; letter-spacing: -.02em; }
.ciuccio.poster .oh { left: 3%; top: 2%; }
.ciuccio.poster .bene { right: 3%; bottom: 1%; }

/* Le tre prove per far vedere di più "Ciuccio bene" */
/* A · al posto del fumetto, accanto a Fil, la spirale che gira (senza fondo né
   contorno); toccato risponde */
.sbuca .fumetto.tondo { left: -1.9rem; top: -2rem; width: clamp(4.4rem, 6vw, 5.4rem); height: clamp(4.4rem, 6vw, 5.4rem); padding: 0; border-radius: 0; background: none; box-shadow: none; color: #1b1714; }
.sbuca .fumetto.tondo .mini, .sbuca .fumetto.tondo .mini svg { display: block; width: 100%; height: 100%; }
.sbuca .risposta { position: absolute; right: 85%; top: 18%; padding: .45rem .7rem; border-radius: .9rem .9rem .2rem .9rem; background: #1b1714; color: #fff; white-space: nowrap;
  font: 400 .95rem/1 "Archivo Black", system-ui, sans-serif; opacity: 0; transform: scale(.6); transform-origin: 100% 100%; transition: opacity .2s, transform .35s cubic-bezier(.3, 1.6, .5, 1); }
.sbuca.saluta .fumetto.tondo { opacity: 1; }
.sbuca.saluta .risposta { opacity: 1; transform: none; }
/* quando arriva la spirale grande in fondo, la piccola ci finisce dentro:
   gira veloce e si rimpicciolisce fino a sparire (al contrario se si risale) */
.sbuca.assorbito .fumetto.tondo { opacity: 0; transform: scale(.08) rotate(400deg); transition: transform .8s cubic-bezier(.55, -.3, .7, 1), opacity .4s .4s; }
/* B · la parola che si allunga, in una riga sotto la testata */
.ciuuu { position: absolute; left: 0; right: 0; top: 100%; padding: .3rem var(--pad, 1rem) .4rem; overflow: hidden; white-space: nowrap; text-align: center;
  font: 400 .8rem/1 "Archivo Black", system-ui, sans-serif; letter-spacing: .02em; opacity: 0; transition: opacity .4s; pointer-events: none; }
.scorsa .ciuuu { opacity: 1; background: rgba(245, 239, 227, .96); box-shadow: 0 1px 0 rgba(0, 0, 0, .12); }
.ciuuu .piu, .ciuuu .bene { display: inline-block; overflow: hidden; vertical-align: top; white-space: pre; }
/* C · la fascia stampata, un nastro di carta che scorre */
.fascia-felpa { position: relative; z-index: 1; margin: 2.2rem -1rem; padding: .85rem 0; background: #f5efe3; color: #1b1714; border-block: 2px solid #1b1714;
  font: 400 clamp(1.3rem, 4.5vw, 2.2rem)/1 "Archivo Black", system-ui, sans-serif; letter-spacing: -.01em; transform: rotate(-1.6deg); box-shadow: 0 16px 30px -18px rgba(40, 25, 15, .55); }
.fascia-felpa[data-al-contrario] { transform: rotate(1.4deg); }
.fascia-felpa span span { padding-right: 1.6rem; }
.fascia-felpa { text-transform: uppercase; } /* come la stampa, anche se nel CMS si scrive in minuscolo */

/* il logo vero caricato dal CMS, al posto di quello ridisegnato */
[data-logo] > .logo-vero { display: block; width: 100%; height: 100%; object-fit: contain; }
.testa .nome > .logo-vero { width: 2rem; height: 2rem; flex: none; }

/* I segni del mockup: quello che è provvisorio si vede */
.prov { background: none; color: inherit; border-bottom: 1.5px dashed currentColor; padding-bottom: .05em; }
.bollino { position: absolute; z-index: 3; right: .75rem; bottom: .75rem; padding: .25rem .55rem; border-radius: 999px; font: 600 .62rem/1.2 system-ui, sans-serif; letter-spacing: .06em; text-transform: uppercase; background: rgba(0, 0, 0, .45); color: #fff; backdrop-filter: blur(6px); }
.per-foto .nota-mockup { display: none; }
.nota-mockup { position: fixed; z-index: 90; left: 50%; bottom: .75rem; transform: translateX(-50%); padding: .45rem .9rem; border-radius: 999px; font: 500 .72rem/1.2 system-ui, sans-serif; background: rgba(20, 16, 14, .82); color: #f5ede2; backdrop-filter: blur(8px); white-space: nowrap; }

@media (prefers-reduced-motion: reduce) {
  [data-giro] { animation: none; }
  [data-pila] > * { transition: none; }
  .sbuca, .sbuca .fumetto, .avviso { transition: none; }
}
